Example/OpenGL Error Testing: Difference between revisions

From OpenGL Wiki
Jump to navigation Jump to search
Error testing code snippet.
(No difference)

Revision as of 02:18, 21 September 2017

A simple loop to extract the current OpenGL errors:

GLenum err;
while((err = glGetError()) != GL_NO_ERROR)
{
  //Process/log the error.
}