Hi Tim, On 5/6/07, Tim Moore <[EMAIL PROTECTED]> wrote:
I've gone a little way down this road, creating an extremely minimal GraphicsWindowSDL that can't even do its own window creation or event processing. It seems to work pretty well, after some minimal testing.
Cool. Is this what you have attached? Would it be possible to use this to evolve the OSG's osgsimpleviewerSDL example? However, I see a problem with the StatsHandler, the use of which is my
entire motivation for doing this. The stats handler works in SingleThreaded mode, but in DrawThreadPerContext, which seems to be the default on a two processor machine, I get: Error: In Texture::Extensions::setupGLExtensions(..) OpenGL version test failed, requires valid graphics context. Segmentation fault As far as I know, SDL doesn't have a notion of changing graphics context - -- there's only one, that created with the rendering surface -- so I created a dummy method for makeCurrentImplementation. Is it actually necessary for the graphics context to be available outside of the thread that implements draw?
In DrawThreadPerContext the rendering has its own thread, while event, update, cull traversals are all done in the main thread. The problem with SDL is that its a bit brain dead when it comes to multi-threaded usage, let alone multiple window usage. SDL could support it with a bit of developement. It would probably be quicker just to add the missing features to osgViewer as its graphic window support is far more capable. Robert.
_______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/
