Hi Cedric, On Tue, Sep 8, 2009 at 9:24 AM, Cedric Pinson<[email protected]> wrote: > Hi Robert, > > Here the time frame where i have a problem: > a thread A do > osg::Object* obj = osgDB::readObjectFile(url); > the obj is returned from cache, and later i do >
Could you try using: osg::ref_ptr<osg::Object> obj = osgDB::readRefObjectFile(url); As this will ensure that ref_ptr<>'s are used throughout the read, as it sounds like in your case in the readObjectFile method the reference is being reset to before your thread is getting a chance to increment the reference. Inside osgDB::DatabasePager it actually uses the Ref versions of read*File() to avoid this issue. Robert. _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

