Adding an error message code to the "smooth_opengl3" demo per e-mail from Diederick Niehorster dated 12/9/2011 as 12:22 AM

git-svn-id: https://svn.code.sf.net/p/freeglut/code/trunk@949 7f0cb862-5218-0410-a997-914c9d46530a
This commit is contained in:
fayjf 2011-12-13 03:48:26 +00:00
parent 2f61654254
commit 7225768c0b

View File

@ -52,8 +52,9 @@
void checkError(const char *functionName)
{
GLenum error;
while (( error = glGetError() ) != GL_NO_ERROR) {
fprintf (stderr, "GL error 0x%X detected in %s\n", error, functionName);
while (( error = glGetError() ) != GL_NO_ERROR) {
const GLubyte* sError = gluErrorString(error);
fprintf (stderr, "GL error 0x%X, %s, detected in %s\n", error, sError, functionName);
}
}