check for null effect in EffectCullVisitor
An EffectGeode might not have any effect.
This commit is contained in:
@@ -54,8 +54,9 @@ void EffectCullVisitor::apply(osg::Geode& node)
|
|||||||
CullVisitor::apply(node);
|
CullVisitor::apply(node);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
Technique* technique = eg->getEffect()->chooseTechnique(&getRenderInfo());
|
Effect* effect = eg->getEffect();
|
||||||
if (!technique) {
|
Technique* technique = 0;
|
||||||
|
if (!(effect && (technique = effect->chooseTechnique(&getRenderInfo())))) {
|
||||||
CullVisitor::apply(node);
|
CullVisitor::apply(node);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user