brettwiesner wrote on Thursday, August 21, 2008 9:01 AM: > Hi, > > I was wondering if update callbacks are suppose to occur in between > calls to glBegin and glEnd? I think this test code demonstrates that > they do. > > I'm using a glGet command (in this case glGetIntegerv) and checking for > it's error code. From the open GL docs: > > "GL_INVALID_OPERATION is generated if glGet is executed between the > execution of glBegin and the corresponding execution of glEnd." > > I'm making that call inside the update callback and getting that error, > suggesting that the update callback occurs somewhere in between a > glBegin and glEnd. Is this correct?
More likely it is because you don't have a valid OpenGL context during the update call. If I understand correctly, running the OSG viewer single-threaded will cause the update traversal to have a valid context, but it would be better to simply do OpenGL calls from a draw or cull callback. -- Bryan Thrall FlightSafety International [EMAIL PROTECTED] _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

