-
-
Save btipling/5dba656537e100b8f2ae3ff5b9517ad9 to your computer and use it in GitHub Desktop.
gl error checker
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void Graphics::check_error(const char * filename, int line_number) { | |
GLenum error; | |
while ((error = glGetError()) != 0) { | |
printf("GL Error %x: %s:%d\n", error, filename, line_number); | |
exit(1); | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment