Improved the handling a releaseGLObjects() and add setThreadSafeRefUnref and resizeGLObjectsBuffers methods

This commit is contained in:
Robert Osfield
2007-01-08 20:40:29 +00:00
parent 77f0f74920
commit 709d2fa435
4 changed files with 68 additions and 6 deletions

View File

@@ -1639,6 +1639,24 @@ void Text::accept(osg::PrimitiveFunctor& pf) const
}
void Text::setThreadSafeRefUnref(bool threadSafe)
{
Drawable::setThreadSafeRefUnref(threadSafe);
getActiveFont()->setThreadSafeRefUnref(threadSafe);
}
void Text::resizeGLObjectBuffers(unsigned int maxSize)
{
Drawable::resizeGLObjectBuffers(maxSize);
_autoTransformCache.resize(maxSize);
getActiveFont()->resizeGLObjectBuffers(maxSize);
}
void Text::releaseGLObjects(osg::State* state) const
{
Drawable::releaseGLObjects(state);
@@ -1646,7 +1664,6 @@ void Text::releaseGLObjects(osg::State* state) const
}
void Text::setBackdropType(BackdropType type)
{
if (_backdropType==type) return;