Moved osg::Impostor to osgSim::Impostor, as Impostor isn't a core feature.

This commit is contained in:
Robert Osfield
2005-05-01 19:48:49 +00:00
parent 7de1265059
commit 03232ec667
41 changed files with 702 additions and 845 deletions

View File

@@ -56,6 +56,18 @@ void DisplayRequirementsVisitor::apply(Node& node)
osg::StateSet* stateset = node.getStateSet();
if (stateset) applyStateSet(*stateset);
if (strcmp(node.className(),"Impostor")==0)
{
if (!_ds) _ds = new osg::DisplaySettings;
unsigned int min = 1; // number alpha bits we need at least.
if (min>_ds->getMinimumNumAlphaBits())
{
// only update if new minimum exceeds previous minimum.
_ds->setMinimumNumAlphaBits(min);
}
}
traverse(node);
}
@@ -70,17 +82,3 @@ void DisplayRequirementsVisitor::apply(Geode& geode)
if (stateset) applyStateSet(*stateset);
}
}
void DisplayRequirementsVisitor::apply(Impostor& impostor)
{
if (!_ds) _ds = new osg::DisplaySettings;
unsigned int min = 1; // number alpha bits we need at least.
if (min>_ds->getMinimumNumAlphaBits())
{
// only update if new minimum exceeds previous minimum.
_ds->setMinimumNumAlphaBits(min);
}
apply((Node&)impostor);
}