Closed bjornblissing closed 9 years ago
Enabled OpenGL debugging in OpenSceneGraph by setting the environment variable:
OSG_GL_ERROR_CHECKING=ON
This gave the more detailed error message:
Warning: detected OpenGL error 'invalid operation' after applying attribute Viewport
But deeper debugging showed that the glGetError
flag was not cleared before reaching this point inside OpenSceneGraph.
So I was forced to fence all OpenGL calls that was close to the error location with glGetError
calls. This revealed that the causing calls were calls to glDrawBuffer
and glReadBuffer
. These must be disabled for the RTT cameras when using direct mode rendering.
The console window outputs OpenGL errors when running in OculusViewConfigExample and OculusViewerExample (OculusCompositeViewerExample works without errors).
Warning: detected OpenGL error 'invalid operation' at after RenderBin::draw(..)