[osg-users] switching between multiple sub-scenes, with different manipulators

Sebastian Messerschmidt sebastian.messerschmidt at gmx.de
Mon Jul 18 04:38:07 PDT 2016

Hi Roozbeh,
> Hi all,
> I have (virtually) independent scene graphs in my application and I want to switch between them. Each sub-scene has its own manipulator, camera, ... although some stuff can be common too.
> The obvious way to do it, to best of my understanding, is to use different osgViewer::View s for each scene and add them to an osgViewer::CompositeViewer and then switch between these views. BUT, this makes problems with multi-threading and Qt5.
> Is there another solution? The bottle neck here I think is that I have to set manipulators for views. If I could do it differently, e.g. to cameras, it could work. Wishful thinking of course :D
Can't you simply switch the manipulators and the scenes independently?
Switching manipulators is easy (see KeySwitchManipulator) and switching 
scene is easy too, if you place your scenes under a switch/multiswitch 
node or control the displayed scene via nodemasks.
Do you have multiple views visible at the same time?

> Thank you!
> Have fun,
> Roozbeh
> ------------------
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=68150#68150
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

More information about the osg-users mailing list