Added new Node/Drawable::s/getInitialBound and Node/Drawable::s/getComputeBoundCallback
methods and reimplement computeBound so that it passes back a bounding volume rather than modifying the local one.
This commit is contained in:
@@ -101,14 +101,11 @@ void TXPNode::traverse(osg::NodeVisitor& nv)
|
||||
Group::traverse(nv);
|
||||
}
|
||||
|
||||
bool TXPNode::computeBound() const
|
||||
osg::BoundingSphere TXPNode::computeBound() const
|
||||
{
|
||||
if (getNumChildren() == 0)
|
||||
{
|
||||
_bsphere.init();
|
||||
_bsphere.expandBy(_extents);
|
||||
_bsphere_computed = true;
|
||||
return true;
|
||||
return osg::BoundingSphere( _extents );
|
||||
}
|
||||
return Group::computeBound();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user