25 #ifndef WGEADVANCEDMANIPULATOR_H
26 #define WGEADVANCEDMANIPULATOR_H
28 #include <osgGA/TrackballManipulator>
47 virtual void setByMatrix(
const osg::Matrixd& matrix );
75 virtual void home(
double currentTime );
84 virtual bool handle(
const osgGA::GUIEventAdapter& ea, osgGA::GUIActionAdapter& us );
112 void setThrow(
bool allowThrow =
true );
130 bool zoom(
const osgGA::GUIEventAdapter& ea, osgGA::GUIActionAdapter& us );
TrackballManipulator with added mouse wheel zoom.
void setPaintMode(int mode)
setter for paint mode when set to something different from 0, a left drag should move the scene
bool getThrow() const
Checks whether throwing is active.
void setZoom(double zoom)
Set zoom factor.
double getZoom() const
Get zoom factor.
double m_zoom
Zoom factor.
int m_paintMode
paint mode
WGEAdvancedManipulator()
Default constructor.
void setThrow(bool allowThrow=true)
En-/Disables throwing.
bool zoom(const osgGA::GUIEventAdapter &ea, osgGA::GUIActionAdapter &us)
Handles events related to zooming.
bool m_allowThrow
Do we want the auto-rotation thingy?
virtual osg::Matrixd getMatrix() const
Get the position of the manipulator as 4x4 matrix.
virtual osg::Matrixd getInverseMatrix() const
Get the position of the manipulator as a inverse matrix of the manipulator, typically used as a model...
virtual bool handle(const osgGA::GUIEventAdapter &ea, osgGA::GUIActionAdapter &us)
Handle events, return true if handled, false otherwise.
virtual osg::Matrixd getMatrixWithoutZoom() const
Get the manipulator only containing rotation and translation.
virtual void setByMatrix(const osg::Matrixd &matrix)
Set the position of the manipulator using a 4x4 matrix.
virtual void home(double currentTime)
Move the camera to the default position.