TextureVisitor: remove redundant code for Geode handling
This commit is contained in:
parent
4457df9a8a
commit
dc2689f779
@ -626,7 +626,6 @@ class OSGUTIL_EXPORT Optimizer
|
||||
_changeClientImageStorage(changeClientImageStorage), _valueClientImageStorage(valueClientImageStorage),
|
||||
_changeAnisotropy(changeAnisotropy), _valueAnisotropy(valueAnisotropy) {}
|
||||
|
||||
virtual void apply(osg::Geode& node);
|
||||
virtual void apply(osg::Node& node);
|
||||
|
||||
void apply(osg::StateSet& stateset);
|
||||
|
@ -2968,33 +2968,6 @@ void Optimizer::TextureVisitor::apply(osg::Node& node)
|
||||
traverse(node);
|
||||
}
|
||||
|
||||
void Optimizer::TextureVisitor::apply(osg::Geode& geode)
|
||||
{
|
||||
if (!isOperationPermissibleForObject(&geode)) return;
|
||||
|
||||
osg::StateSet* ss = geode.getStateSet();
|
||||
|
||||
if (ss && isOperationPermissibleForObject(ss))
|
||||
{
|
||||
apply(*ss);
|
||||
}
|
||||
|
||||
for(unsigned int i=0;i<geode.getNumDrawables();++i)
|
||||
{
|
||||
osg::Drawable* drawable = geode.getDrawable(i);
|
||||
if (drawable)
|
||||
{
|
||||
ss = drawable->getStateSet();
|
||||
if (ss &&
|
||||
isOperationPermissibleForObject(drawable) &&
|
||||
isOperationPermissibleForObject(ss))
|
||||
{
|
||||
apply(*ss);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void Optimizer::TextureVisitor::apply(osg::StateSet& stateset)
|
||||
{
|
||||
for(unsigned int i=0;i<stateset.getTextureAttributeList().size();++i)
|
||||
|
Loading…
Reference in New Issue
Block a user