searching for a bug, I came across some strange behavior of my app. Actually this behavior shows shortly before exiting (in some destructur in a class wrapping occulsion culling). I assume, that the opengl context is already destroyed BUT how do I know for sure.
Basically I am doing the following to check if there is a context:
The programs crashes when calling glIsQuery (which is called several times during lifetime of the application, therefor there is no problem with taht extension so something like that).
I tried the following code for debugging purposes and it became even stranger:
char* version = (char*)glGetString(GL_VERSION);
GLenum error = glGetError();
// version is NULL now and error as well 0
So is there anyway, that wglGetCurrentContext returns a non-invalid handle but the context is not really valid anymore?
Did somebody had similar problems?
Thanks and regards,