[osg-users] osg::ref ptr and memory leaks.

2013-06-07 Thread Roman Grigoriev
Hi, Sorry for newbee question. But I found that my program memory usage grows up to 200 k per cycle. I try to find memory leak and maybe some guru look to this code portion and give me some advice. (sorry because on linux when I copy code from qtcreator I've got some mess.) Code:

Re: [osg-users] osg::ref ptr and memory leaks.

2013-06-07 Thread Robert Osfield
Hi Roman, The scene graph uses ref_ptr internally to make sure that it's memory management is robust. In your own application you should also use ref_ptr for almost all cases where you would have used a C pointer before. Exceptions are cases such as inner loops where you don't want to pay the

Re: [osg-users] osg::ref ptr and memory leaks.

2013-06-07 Thread Roman Grigoriev
Hi, Robert Thanx for your quick reply, Is there any way to calculate memory usage of my custom particle system class? If I query this-smoke_right.valid() it returns false, when i remove children but As far as you've seen I don't have destructor on my node and I suspect that internal geode and

Re: [osg-users] osg::ref ptr and memory leaks.

2013-06-07 Thread Bram Vaessen
Another idea might be to use valgrind, memory doctor or some similar program to detect actuall memory leaks. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=54491#54491 ___ osg-users mailing list