Tracing the managed entities

The main point that we are interested in is how osg::ref_ptr<> binds and handles an osg::Referenced object, and when the managed object will be destroyed. What we have already learnt is: the managed object will be automatically destroyed when it is no longer referenced by any smart pointers, or when its referrer is out of the declaration scope. Now let's see how this is performed in practice.

Get OpenSceneGraph 3.0 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.