Hello: the osg::Image object is referenced object and will be automatically deleted once the final ref count goes to 0. On the osg::Texture object you can specify if you want OSG to unref the image object after the image has been applied by using the method:
setUnRefImageDataAfterApply I think that should be it. Take care Garrett On Jan 19, 2010, at 9:30 AM, Joachim Diepstraten wrote: > Hello, > > I am not sure if this has been asked before I tried a search on this forum > but I think it is too specific so the search didn't come up with anything > remotely close. > > Anyway my question is is there a safeway to release osg::Image after it has > been uploaded to the card or better say into it's memory space. > Deconstructors of osg::Image are all protected so I don't know how you could > actually tell it unless I write my own memory manager for it, which is > possible (but I would rather like to avoid that). > > The reason I ask is I've got quite a big volume stored in an osg::Image and I > am running rather low on system resource memory the reason for that is it is > actually kept twice in memory (the first time in osg::Image and the second > time around due to OpenGL's / OS internal texture memory context mapping). So > I rather would like to get rid of at least of one of them. > > But I don't know when and how since I just recently restarted using OSG. > > ------------------ > Read this topic online here: > http://forum.openscenegraph.org/viewtopic.php?p=22893#22893 > > > > > > _______________________________________________ > osg-users mailing list > osg-users@lists.openscenegraph.org > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org