Hi Loinel, There is a third way, and that is to have one of the native GraphcisWindow implementations inherit your window data. The osgviewerMFC takes this approach. Window inheritance is supported under Win32 and Carbon right now, X11 to come.
W.r.t slave camera, you might not need to create one unless you have something like a HUD or a camera insert. The osgViewer::Viewer is subclassed from osgViewer::View which in term subclasses from osg::View, the later of which has a master osg::Camera and a list of slave osg::Camera. Most apps will just require one Camera and then master camera will do just fine for this, no need to set a slave unless you need it. Robert. On 6/20/07, Lionel Lagarde <[EMAIL PROTECTED]> wrote:
Hi, I'm porting my osg layer to 2.0 and I have some design questions. I have a view class (for the moment, it contains a sceneview) that manage a scene and a camera. It doesn't handle window creation, gl contexts or window events. It is used by a higher level application that control all the windowing stuff. This application can create and destroy windows (one view per window) on the fly. And the 2.0 comes ... I see 2 ways to achieve this. - my view class is a osgViewer::Viewer + setUpViewerAsEmbeddedInWindow to create another window I need to add a slave camera (configured with the graphic context returned by setUpViewerAsEmbeddedInWindow) But the first thing that setUpViewerAsEmbeddedInWindow do is to reset the threading model to single thread - implement my own GraphicWindow and use them in the slave cameras any suggestion ? _______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/
_______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/
