Skylark wrote: > Hi Markus, > > > > I'm using osg 2.9.8 and trying to do intersection tests in a thread. The > > code is real straightforwards and works well when not threaded: > > > > [...] > > > > Is this a known issue? > > > > Err, you say what you want to do, that it works when not threaded, but > not what happens when you try to do it in a thread. Do you get crashes? > Do you get error messages? Do you get erroneous results? > > Without this info it's hard to help you out... > > I don't see why it wouldn't work /a priori/, unless your thread is > running while some other part of your app is modifying the scene graph. > That might invalidate iterators that the IntersectionVisitor is using or > things like that, which might lead to crashes. > > J-S > -- > ______________________________________________________ > Jean-Sebastien Guay > http://www.cm-labs.com/ > http://whitestar02.webhop.org/ > _______________________________________________ > osg-users mailing list > > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > > ------------------ > Post generated by Mail2Forum
Thanks for addressing this Skylark. Yes, the application crashes due to what I think you described (accessing the scene graph while it is being modified) I am using osgEarth and running threads concurrently that need to intersect with the surface of the earth model. Is there any thread-safe way to achieve this without running everything on the main thread? More generally, is there a way to ensure that you only traverse the scene graph's nodes when you're supposed to? ------------------ Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=30698#30698 _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

