Hi Robert, Thanks for the explanation. It clears quite a lot of confusion.
I've added the stopThreading(), and this build is going to go through a test cycle tonight, so I will know fairly soon if the problem still appears. Cheers, Tanguy -----Original Message----- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Robert Osfield Sent: 05 August 2009 17:20 To: OpenSceneGraph Users Subject: Re: [osg-users] osgText texture not reloading correctly thesecondtime? Hi Tanguy, On Wed, Aug 5, 2009 at 4:53 PM, Tanguy Fautre<tang...@aristechnologies.com> wrote: > Robert, could you confirm that the rendering thread is not supposed to > be actively culling/drawing when being outside of Viewer::run() (or more > precisely, Viewer::frame())? If you are using DrawThreadPerContext or CullThreadPerCameraDrawThreadPerContext then the draw thread will run over the end of frame() or even run(). Call viewer.stopThreading(); to ensure the threads are stopped. -- W.r.t osgText not clearing it's GL objects properly, in theory releaseGLobjects() should work, and should purge the graphics context just fine. Looking at the implementation of Tex void Text::releaseGLObjects(osg::State* state) const { TextBase::releaseGLObjects(state); getActiveFont()->releaseGLObjects(state); } And void Font::releaseGLObjects(osg::State* state) const { if (_stateset.valid()) _stateset->releaseGLObjects(state); for(GlyphTextureList::const_iterator itr=_glyphTextureList.begin(); itr!=_glyphTextureList.end(); ++itr) { (*itr)->releaseGLObjects(state); } // const_cast<Font*>(this)->_glyphTextureList.clear(); // const_cast<Font*>(this)->_sizeGlyphMap.clear(); } Which broadly looks to be the right thing. Robert. _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.or g _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org