Hi, There is this thing with the otherwise fantastic OpenSceneGraph that has been bothering me for some time and that is the relative ease with which I seem to lose the benefit of multithreaded rendering and how hard it is to fix.
Our application runs with the default DrawThreadPerContext threading model, but a quick look at the stats view reveals that all stages are running in sequence. There is no overlap of draw with the next frame's update/cull as expected and so the application performs the same as if it was running single threaded (which a switch to single threaded mode also confirms). Now the reason for this is that the last entry to be drawn has ended up as being marked dynamic by OSG and therefore the entire draw stage needs to finish before the update thread can be unlocked. This is by design and I understand the reasoning behind it. In our case it turned out to be Wang Rui's EffectCompositor (which is also otherwise a great tool for post-processing). It uses a quad that is repeatedly rendered for each of the post-processing stages and that quad was the last to render. Even though the quad itself was not marked dynamic it was still sitting in a render leaf that was marked dynamic and I don't know why. My point is that I think it is easy to "accidentally" get into this situation and thereby lose the performance benefits that the multithreaded modes are supposed to provide. My questions are: How do you avoid this situation (if possible) and how do you identify the offending part of the scene graph if it has happened? Thank you! Cheers, Michael ------------------ Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=58033#58033 _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org