Added debugging messages to setTrackerNode

This commit is contained in:
Robert Osfield
2004-11-02 17:04:06 +00:00
parent ce3d785751
commit fae2416584

View File

@@ -74,13 +74,24 @@ void NodeTrackerManipulator::setNode(osg::Node* node)
void NodeTrackerManipulator::setTrackNode(osg::Node* node)
{
if (!node)
{
osg::notify(osg::NOTICE)<<"NodeTrackerManipulator::setTrackNode(Node*): Unable to set tracked node due to null Node*"<<std::endl;
return;
}
CollectParentPaths cpp;
node->accept(cpp);
if (!cpp._nodePaths.empty())
{
osg::notify(osg::INFO)<<"NodeTrackerManipulator::setTrackNode(Node*): Path set"<<std::endl;
_trackNodePath = cpp._nodePaths[0];
}
else
{
osg::notify(osg::NOTICE)<<"NodeTrackerManipulator::setTrackNode(Node*): Unable to set tracked node due to empty parental path."<<std::endl;
}
}
const osg::Node* NodeTrackerManipulator::getNode() const