Hack to avoid redrawing the whole scene another time when only light volume are requested

This commit is contained in:
Frederic Bouvier 2012-05-19 19:39:38 +02:00
parent 23d4628d88
commit e692e7c119

View File

@ -52,6 +52,8 @@ CullVisitor* EffectCullVisitor::clone() const
void EffectCullVisitor::apply(osg::Geode& node)
{
if (node.getNodeMask() != simgear::MODELLIGHT_BIT ) // HACK
node.setNodeMask(node.getNodeMask() & ~simgear::MODELLIGHT_BIT);
if (isCulled(node))
return;
EffectGeode *eg = dynamic_cast<EffectGeode*>(&node);