Improved the constness of parameters the Node::getWorldMatrices(..) method.

Added Drawable::getWorldMatrices(const Node*) method.
This commit is contained in:
Robert Osfield
2008-09-18 10:38:18 +00:00
parent 93d4090169
commit 0969a5384b
6 changed files with 27 additions and 6 deletions

View File

@@ -250,6 +250,19 @@ Drawable::~Drawable()
dirtyDisplayList();
}
osg::MatrixList Drawable::getWorldMatrices(const osg::Node* haltTraversalAtNode) const
{
osg::MatrixList matrices;
for(ParentList::const_iterator itr = _parents.begin();
itr != _parents.end();
++itr)
{
osg::MatrixList localMatrices = (*itr)->getWorldMatrices(haltTraversalAtNode);
matrices.insert(matrices.end(), localMatrices.begin(), localMatrices.end());
}
return matrices;
}
void Drawable::computeDataVariance()
{
if (getDataVariance() != UNSPECIFIED) return;