Re: [osg-users] Problems shutting down Composite Viewer/View/Custom drawables

2009-03-30 Thread Jean-Sébastien Guay
Hi Charles, That was the problem. The destructor of my derived class was public. I changed it to protected and to use a ref_ptr for the class and no more crashes. I'm not sure I would have ever found this bug. I wasn't even looking in that direction. So, thanks so much! Glad I could he

Re: [osg-users] Problems shutting down Composite Viewer/View/Custom drawables

2009-03-30 Thread Cole, Charles E. (LARC-B702)[RAYTHEON TECHNICAL SERVICES COMPANY]
users-boun...@lists.openscenegraph.org] On Behalf Of David Spilling Sent: Friday, March 27, 2009 8:02 PM To: OpenSceneGraph Users Subject: Re: [osg-users] Problems shutting down Composite Viewer/View/Custom drawables Chuck, I have had similar issues (with crashes in releaseGLObjects when views get destroyed)

Re: [osg-users] Problems shutting down Composite Viewer/View/Custom drawables

2009-03-30 Thread Cole, Charles E. (LARC-B702)[RAYTHEON TECHNICAL SERVICES COMPANY]
Hi J-S, > One thing you need to be careful of when deriving classes from OSG base > classes which themselves derive from osg::Referenced ... In most cases, > the destructors of those classes should be protected. Since they're > normally protected already (as in osg::Object, osg::Drawable, etc) you

Re: [osg-users] Problems shutting down Composite Viewer/View/Custom drawables

2009-03-27 Thread David Spilling
Chuck, I have had similar issues (with crashes in releaseGLObjects when views get destroyed) but can't actually recall what I did to fix them. You could try calling viewer->releaseGLObjects() before you destroy the view. (previous posts seem to suggest that this might be the right thing to do) D

Re: [osg-users] Problems shutting down Composite Viewer/View/Custom drawables

2009-03-27 Thread Jean-Sébastien Guay
Hi Charles, When I referred to "destroy", what I'm doing is calling 'delete' on the classes that contain the ref_ptrs. For instance, I call delete on my view class, and in the view class' destructor, I (eventually) call delete on the drawables. So I'm in effect doing what you're saying, with

Re: [osg-users] Problems shutting down Composite Viewer/View/Custom drawables

2009-03-27 Thread Cole, Charles E. (LARC-B702)[RAYTHEON TECHNICAL SERVICES COMPANY]
t; boun...@lists.openscenegraph.org] On Behalf Of Jean-Sébastien Guay > Sent: Friday, March 27, 2009 1:45 PM > To: OpenSceneGraph Users > Subject: Re: [osg-users] Problems shutting down Composite > Viewer/View/Custom drawables > > Hi Charles, > > > My attempted process to

Re: [osg-users] Problems shutting down Composite Viewer/View/Custom drawables

2009-03-27 Thread Jean-Sébastien Guay
Hi Charles, My attempted process to close is that I (1) set a flag on a render thread to stop calling viewer->frame (very similar to setDone(true)); (2) destroy the loaded drawables and free their associated libraries; (3) destroy the view, and thus it's associated camera and graphics context

Re: [osg-users] Problems shutting down Composite Viewer/View/Custom drawables

2009-03-27 Thread Cole, Charles E. (LARC-B702)[RAYTHEON TECHNICAL SERVICES COMPANY]
ECHNICAL SERVICES COMPANY] > Sent: Friday, March 27, 2009 12:51 PM > To: OpenSceneGraph Users > Subject: [osg-users] Problems shutting down Composite > Viewer/View/Custom drawables > > Hi all, > > I've been chasing an error in my code for many, many days that I'm >

[osg-users] Problems shutting down Composite Viewer/View/Custom drawables

2009-03-27 Thread Cole, Charles E. (LARC-B702)[RAYTHEON TECHNICAL SERVICES COMPANY]
Hi all, I've been chasing an error in my code for many, many days that I'm hoping that someone can help me track down. I'll try to explain my application as best I can. I'm using a composite viewer to load multiple views. In each view, I'm loading a database scene (generally a TXP database)