Heriberto Delgado
03-03-2007, 07:21 AM
Ok. Let's settle this.
Of course, calling glGetError() between glBegin() / glEnd() is an error; in fact, a GL_INVALID_OPERATION_ERROR. I can imagine that any queries to GL state must go through some kind of complex software/hardware structures before getting any results; however, I also imagine that any non-permitted operations shall ***not*** go through these structures.
Either way, glGetError() must still return something. Does glGetError() jump over all security measures to return the last error, even if it is ***it's own error*** (GL_INVALID_OPERATON_ERROR), or it just returns the aforementioned value without asking for anything else? Or, (worse yet), does it return 0 (since it can't check for error conditions anymore)???
In other words, what must glGetError() return when issued between glBegin() / glEnd() calls???
Of course, calling glGetError() between glBegin() / glEnd() is an error; in fact, a GL_INVALID_OPERATION_ERROR. I can imagine that any queries to GL state must go through some kind of complex software/hardware structures before getting any results; however, I also imagine that any non-permitted operations shall ***not*** go through these structures.
Either way, glGetError() must still return something. Does glGetError() jump over all security measures to return the last error, even if it is ***it's own error*** (GL_INVALID_OPERATON_ERROR), or it just returns the aforementioned value without asking for anything else? Or, (worse yet), does it return 0 (since it can't check for error conditions anymore)???
In other words, what must glGetError() return when issued between glBegin() / glEnd() calls???