I have a viewer with a context. It is being drawn on the UI which has another separate context. (I am using QT for UI, and trying to draw widgets ontop of viewer.)
wglMakeCurrent() which gets called in the viewer code, fails and says from GetLastError(): wglMakeCurrent() failed. The handle is invalid.
This is how it is called:
... if (wglMakeCurrent ((HDC )myWindowDC, (HGLRC )myGContext) != TRUE) ...
I uploaded the project if anyone wants to take a look.
What is a likely cause of this?