|
|
@ -318,14 +318,17 @@ void RigGeometry::accept(osg::NodeVisitor &nv)
|
|
|
|
cull(&nv);
|
|
|
|
cull(&nv);
|
|
|
|
else if (nv.getVisitorType() == osg::NodeVisitor::UPDATE_VISITOR)
|
|
|
|
else if (nv.getVisitorType() == osg::NodeVisitor::UPDATE_VISITOR)
|
|
|
|
updateBounds(&nv);
|
|
|
|
updateBounds(&nv);
|
|
|
|
else if (nv.getVisitorType() == osg::NodeVisitor::INTERSECTION_VISITOR)
|
|
|
|
|
|
|
|
nv.apply(*getGeometry(mLastFrameNumber));
|
|
|
|
|
|
|
|
else
|
|
|
|
else
|
|
|
|
nv.apply(*this);
|
|
|
|
nv.apply(*this);
|
|
|
|
|
|
|
|
|
|
|
|
nv.popFromNodePath();
|
|
|
|
nv.popFromNodePath();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void RigGeometry::accept(osg::PrimitiveFunctor& func) const
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
getGeometry(mLastFrameNumber)->accept(func);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
osg::Geometry* RigGeometry::getGeometry(unsigned int frame) const
|
|
|
|
osg::Geometry* RigGeometry::getGeometry(unsigned int frame) const
|
|
|
|
{
|
|
|
|
{
|
|
|
|
return mGeometry[frame%2].get();
|
|
|
|
return mGeometry[frame%2].get();
|
|
|
|