Hi Todd,
Thanks for the suggestions. I just tried that, and unfortunately this
particular exception seems to occur *after* exit. It seems to be this
error:
http://social.msdn.microsoft.com/Forums/en-US/vblanguage/thread/afebacc2-65e6-43f8-b7aa-73bfd5ade11d
Anyway, thanks again. I'm pretty sure this isn't an OSG problem, but
I'll post an update if it turns out to be one.
Well that post relates to VB garbage collection and Crystal Reports, so
I'm pretty sure it's not related :-)
A crash on exit is generally a double-delete... Are you using ref_ptrs
for all your OSG variables? Or are you doing weird things with memory
allocation?
Small anecdote on that subject:
A while ago we had a class in our code base that derived from an OSG
class (so from osg::Referenced indirectly) but declared its destructor
public. So users of that class could delete it while it was still in the
scene graph, and when OSG (through ref counts falling to 0 and cascading
deletes of ref_ptrs) came to delete it, it had already been deleted,
thus the app crashed on exit. So making the destructor of an
osg::Referenced-derived class public is a no-no, unless you can make
sure to remove it from all OSG structures before you delete it (which is
a lot of work for not much gain, IMHO, so just keep that destructor
protected and all will be fine).
Hope this helps,
J-S
--
______________________________________________________
Jean-Sebastien Guay [email protected]
http://www.cm-labs.com/
http://whitestar02.webhop.org/
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org