man_in_shack
public text v1 · immutablevoid check_gl_error()
{
int error = glGetError();
if (error != GL_NO_ERROR)
fprintf(stderr, "%s\n", gluErrorString(error));
}
GLuint g;
glGenTextures(1,&g);
glBindTexture(GL_TEXTURE_2D,g);
check_gl_error(); /* No output, and no I'm not redirecting stderr either */