[osg-users] Making the composite window disappear

Sashidhar Guntury sashidhar.moony at gmail.com
Fri Oct 19 10:24:26 PDT 2007


           As a matter of fact, I would want the view to come back by
pressing some other key and that can be done using the setNodeMask()
function. thanks a lot...


On 10/19/07, Robert Osfield <robert.osfield at gmail.com> wrote:
> Hi Shadhidar,
> On 10/19/07, Sashidhar Guntury <sashidhar.moony at gmail.com> wrote:
> >               Oops, I forgot to mention that I'm not removing (i.edeleting)
> > view variable. I actually tried that but since the destructor is
> protected,
> > it would not work.
> To delete just set all the ref_ptr<View> to 0 and it'll delete.
> I suspect the reason why the removed View's cameras are still visiable
> is that the view hasn't been deleted, and the cameras still have the
> graphics window attached so are still being renderer by the graphics
> window on each frame.
> If you didn't hold a global to the View then it'd delete automatically
> when you removed the View from the CompositeViewer and its associated
> Camera would be deleted along with it, removing itself completely from
> being associated with the GraphicsWindow.
> If you want to keep the view around for future use then perhaps the
> easiest way to do it would be to disable the View's camera by setting
> its NodeMask to 0x0 i.e.
>   view->getCamera()->setNodeMask(0x0);
> Robert.
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20071019/f6a470fa/attachment-0003.htm>

More information about the osg-users mailing list