blob: 9132cdb947b8a69e93dcf7fe459a56444999bcff [file] [log] [blame]
Erik Faye-Lund4d066832020-06-12 20:09:42 +02001Debugging Tips
2==============
3
4Normally Mesa (and OpenGL) records but does not notify the user of
5errors. It is up to the application to call ``glGetError`` to check for
6errors. Mesa supports an environment variable, ``MESA_DEBUG``, to help
7with debugging. If ``MESA_DEBUG`` is defined, a message will be printed
8to stdout whenever an error occurs.
9
10More extensive error checking is done in DEBUG builds
Erik Faye-Lund0c906622020-09-29 19:01:13 +020011(``--buildtype debug`` for Meson, ``build=debug`` for SCons).
Erik Faye-Lund4d066832020-06-12 20:09:42 +020012
13In your debugger you can set a breakpoint in ``_mesa_error()`` to trap
14Mesa errors.
15
16There is a display list printing/debugging facility. See the end of
17``src/dlist.c`` for details.