Hi John,

The CompositeViewer already supports dynamically adding and removing
views, there isn't any need for any new API.  As J.P. suggested using
viewer.stopThreading() method will stop the threading while you make
the changes, then call viewer.startThreading() to kick them back into
life.

Robert.

On Thu, Oct 22, 2009 at 8:36 PM, John Morris <[email protected]> wrote:
> Hi,
>
> I'm trying to add a new View to a CompositeViewer, while the program is 
> running.
> I have a dialog toggle button that I want to use to pop up a new view.
> The second time I click the button I want to remove the second view.
>
> I added functions to the Viewer to accomplish this, but when I call my 
> AddNewView function, my program generates an exception in the frame loop.  I 
> think that there might be some sort of threading issue between the GUI and 
> the Viewer, but I'm not sure where to look.
>
> Has anybody done something similar to this?
>
> Thank you!
>
> Cheers,
> John
>
> ------------------
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=18567#18567
>
>
>
>
>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to