在OpenSceneGraph中, osgManipulator.TabBoxTrackballDragger
是一种可以通过拖拽改变包围盒(bounding box)的位置和大小的交互器(manipulator)。
osg::Object
→ osgManipulator::Dragger
→ osgManipulator::TabBoxDragger
→ osgManipulator::TabBoxTrackballDragger
TabBoxTrackballDragger();
osgManipulator::TabBoxDragger
virtual bool handle(const osgManipulator::PointerInfo& pi, const osgGA::GUIEventAdapter& ea, osgGA::GUIActionAdapter& aa);
osgManipulator::Dragger
void setMatrix(const osg::Matrixd& matrix);
virtual void setHandleEvents(bool handleEvents);
virtual bool getHandleEvents() const;
virtual void setActivationModKeyMask(int activationModKeyMask);
virtual int getActivationModKeyMask() const;
virtual void setActivationKeyEvent(int activationKeyEvent);
virtual int getActivationKeyEvent() const;
virtual void setDraw(bool draw);
virtual bool getDraw() const;
virtual void setParent(osgManipulator::CompositeDragger* parent);
virtual osgManipulator::CompositeDragger* getParent();
virtual const osgManipulator::CompositeDragger* getParent() const;
osg::ref_ptr<osgManipulator::TabBoxTrackballDragger> dragger = new osgManipulator::TabBoxTrackballDragger;
dragger->setupDefaultGeometry();
dragger->setActivationKeyEvent(osgGA::GUIEventAdapter::KEY_Space);