Added new getCurrentCamaeraManipulator(), and removed and debugging message.

This commit is contained in:
Robert Osfield
2003-01-17 14:12:25 +00:00
parent c406d2476f
commit c2c38955c6
2 changed files with 5 additions and 1 deletions

View File

@@ -36,8 +36,13 @@ public:
*/
void addNumberedCameraManipulator(CameraManipulator *cm);
CameraManipulator* getCurrentCameraManipulator() { return _current.get(); }
const CameraManipulator* getCurrentCameraManipulator() const { return _current.get(); }
// Overrides from CameraManipulator...
virtual void setCamera(osg::Camera* c) { _current->setCamera(c); }
virtual const osg::Camera * getCamera() const { return _current->getCamera(); }

View File

@@ -27,7 +27,6 @@ bool KeySwitchCameraManipulator::handle(const GUIEventAdapter& ea,GUIActionAdapt
KeyManipMap::iterator it=_manips.find(ea.getKey());
if(it != _manips.end()){
osg::notify(osg::INFO)<<"Switching to manipulator: "<<(*it).second.first<<std::endl;
std::cout<<"***Switching to manipulator: "<<(*it).second.first<<std::endl;
it->second.second->setNode(_current->getNode());
it->second.second->setCamera(_current->getCamera());
it->second.second->init(ea,aa);