osgGA::MatrixManipulator Class Reference

Inheritance diagram for osgGA::MatrixManipulator:

osgGA::GUIEventHandler osg::NodeCallback osg::Drawable::EventCallback osg::Object osg::Object osg::Referenced osg::Referenced osgGA::AnimationPathManipulator osgGA::DriveManipulator osgGA::FlightManipulator osgGA::KeySwitchMatrixManipulator osgGA::NodeTrackerManipulator osgGA::TerrainManipulator osgGA::TrackballManipulator osgGA::UFOManipulator

List of all members.

Public Member Functions

virtual const char * className () const
virtual void setMinimumDistance (float minimumDistance)
float getMinimumDistance () const
virtual void setCoordinateFrameCallback (CoordinateFrameCallback *cb)
CoordinateFrameCallbackgetCoordinateFrameCallback ()
const CoordinateFrameCallbackgetCoordinateFrameCallback () const
osg::CoordinateFrame getCoordinateFrame (const osg::Vec3d &position) const
osg::Vec3d getSideVector (const osg::CoordinateFrame &cf) const
osg::Vec3d getFrontVector (const osg::CoordinateFrame &cf) const
osg::Vec3d getUpVector (const osg::CoordinateFrame &cf) const
virtual void setByMatrix (const osg::Matrixd &matrix)=0
virtual void setByInverseMatrix (const osg::Matrixd &matrix)=0
virtual osg::Matrixd getMatrix () const =0
virtual osg::Matrixd getInverseMatrix () const =0
virtual
osgUtil::SceneView::FusionDistanceMode 
getFusionDistanceMode () const
virtual float getFusionDistanceValue () const
void setIntersectTraversalMask (unsigned int mask)
unsigned int getIntersectTraversalMask () const
virtual void setNode (osg::Node *)
virtual const osg::NodegetNode () const
virtual osg::NodegetNode ()
virtual void setHomePosition (const osg::Vec3d &eye, const osg::Vec3d &center, const osg::Vec3d &up, bool autoComputeHomePosition=false)
virtual void getHomePosition (osg::Vec3d &eye, osg::Vec3d &center, osg::Vec3d &up) const
virtual void setAutoComputeHomePosition (bool flag)
bool getAutoComputeHomePosition () const
virtual void computeHomePosition ()
virtual void home (const GUIEventAdapter &, GUIActionAdapter &)
virtual void home (double)
virtual void init (const GUIEventAdapter &, GUIActionAdapter &)
virtual bool handle (const GUIEventAdapter &ea, GUIActionAdapter &us)

Protected Member Functions

 MatrixManipulator ()
virtual ~MatrixManipulator ()

Protected Attributes

double _minimumDistance
unsigned int _intersectTraversalMask
bool _autoComputeHomePosition
osg::Vec3d _homeEye
osg::Vec3d _homeCenter
osg::Vec3d _homeUp
osg::ref_ptr
< CoordinateFrameCallback
_coordinateFrameCallback

Classes

class  CoordinateFrameCallback


Detailed Description

MatrixManipulator is an abstract base class defining the interface, and a certain amount of default functionality, for classes which wish to control OSG cameras in response to GUI events.

Constructor & Destructor Documentation

osgGA::MatrixManipulator::MatrixManipulator (  )  [protected]

virtual osgGA::MatrixManipulator::~MatrixManipulator (  )  [protected, virtual]


Member Function Documentation

virtual const char* osgGA::MatrixManipulator::className (  )  const [inline, virtual]

virtual void osgGA::MatrixManipulator::setMinimumDistance ( float  minimumDistance  )  [inline, virtual]

set the minimum distance (as ratio) the eye point can be zoomed in towards the center before the center is pushed forward.

Reimplemented in osgGA::KeySwitchMatrixManipulator.

float osgGA::MatrixManipulator::getMinimumDistance (  )  const [inline]

get the minimum distance (as ratio) the eye point can be zoomed in

virtual void osgGA::MatrixManipulator::setCoordinateFrameCallback ( CoordinateFrameCallback cb  )  [inline, virtual]

set the coordinate frame which callback tells the manipulator which way is up, east and north.

Reimplemented in osgGA::KeySwitchMatrixManipulator.

CoordinateFrameCallback* osgGA::MatrixManipulator::getCoordinateFrameCallback (  )  [inline]

get the coordinate frame callback which tells the manipulator which way is up, east and north.

const CoordinateFrameCallback* osgGA::MatrixManipulator::getCoordinateFrameCallback (  )  const [inline]

get the coordinate frame callback which tells the manipulator which way is up, east and north.

osg::CoordinateFrame osgGA::MatrixManipulator::getCoordinateFrame ( const osg::Vec3d position  )  const [inline]

osg::Vec3d osgGA::MatrixManipulator::getSideVector ( const osg::CoordinateFrame cf  )  const [inline]

osg::Vec3d osgGA::MatrixManipulator::getFrontVector ( const osg::CoordinateFrame cf  )  const [inline]

osg::Vec3d osgGA::MatrixManipulator::getUpVector ( const osg::CoordinateFrame cf  )  const [inline]

virtual void osgGA::MatrixManipulator::setByMatrix ( const osg::Matrixd matrix  )  [pure virtual]

virtual void osgGA::MatrixManipulator::setByInverseMatrix ( const osg::Matrixd matrix  )  [pure virtual]

virtual osg::Matrixd osgGA::MatrixManipulator::getMatrix (  )  const [pure virtual]

virtual osg::Matrixd osgGA::MatrixManipulator::getInverseMatrix (  )  const [pure virtual]

get the position of the manipulator as a inverse matrix of the manipulator, typically used as a model view matrix.

Implemented in osgGA::AnimationPathManipulator, osgGA::DriveManipulator, osgGA::FlightManipulator, osgGA::KeySwitchMatrixManipulator, osgGA::NodeTrackerManipulator, osgGA::TerrainManipulator, osgGA::TrackballManipulator, and osgGA::UFOManipulator.

virtual osgUtil::SceneView::FusionDistanceMode osgGA::MatrixManipulator::getFusionDistanceMode (  )  const [inline, virtual]

Get the FusionDistanceMode. Used by SceneView for setting up stereo convergence.

Reimplemented in osgGA::KeySwitchMatrixManipulator, osgGA::NodeTrackerManipulator, osgGA::TerrainManipulator, and osgGA::TrackballManipulator.

References osgUtil::SceneView::PROPORTIONAL_TO_SCREEN_DISTANCE.

virtual float osgGA::MatrixManipulator::getFusionDistanceValue (  )  const [inline, virtual]

Get the FusionDistanceValue. Used by SceneView for setting up stereo convergence.

Reimplemented in osgGA::KeySwitchMatrixManipulator, osgGA::NodeTrackerManipulator, osgGA::TerrainManipulator, and osgGA::TrackballManipulator.

void osgGA::MatrixManipulator::setIntersectTraversalMask ( unsigned int  mask  )  [inline]

Set the mask to use when set up intersection traversal such as used in manipulators that follow terrain or have collision detection. The intersection traversal mask is useful for controlling what parts of the scene graph should be used for intersection purposes.

unsigned int osgGA::MatrixManipulator::getIntersectTraversalMask (  )  const [inline]

Get the mask to use when set up intersection traversal such as used in manipulators that follow terrain or have collision detection.

virtual void osgGA::MatrixManipulator::setNode ( osg::Node  )  [inline, virtual]

Attach a node to the manipulator, automatically detaching any previously attached node. setNode(NULL) detaches previous nodes. May be ignored by manipulators which do not require a reference model.

Reimplemented in osgGA::DriveManipulator, osgGA::FlightManipulator, osgGA::KeySwitchMatrixManipulator, osgGA::NodeTrackerManipulator, osgGA::TerrainManipulator, osgGA::TrackballManipulator, and osgGA::UFOManipulator.

virtual const osg::Node* osgGA::MatrixManipulator::getNode (  )  const [inline, virtual]

virtual osg::Node* osgGA::MatrixManipulator::getNode (  )  [inline, virtual]

virtual void osgGA::MatrixManipulator::setHomePosition ( const osg::Vec3d eye,
const osg::Vec3d center,
const osg::Vec3d up,
bool  autoComputeHomePosition = false 
) [inline, virtual]

Manually set the home position, and set the automatic compute of home position.

Reimplemented in osgGA::KeySwitchMatrixManipulator.

virtual void osgGA::MatrixManipulator::getHomePosition ( osg::Vec3d eye,
osg::Vec3d center,
osg::Vec3d up 
) const [inline, virtual]

Get the manually set home position.

virtual void osgGA::MatrixManipulator::setAutoComputeHomePosition ( bool  flag  )  [inline, virtual]

Set whether the automatic compute of the home position is enabled.

Reimplemented in osgGA::KeySwitchMatrixManipulator.

bool osgGA::MatrixManipulator::getAutoComputeHomePosition (  )  const [inline]

Get whether the automatic compute of the home position is enabled.

virtual void osgGA::MatrixManipulator::computeHomePosition (  )  [inline, virtual]

virtual void osgGA::MatrixManipulator::home ( const GUIEventAdapter ,
GUIActionAdapter  
) [inline, virtual]

Move the camera to the default position. May be ignored by manipulators if home functionality is not appropriate.

Reimplemented in osgGA::AnimationPathManipulator, osgGA::DriveManipulator, osgGA::FlightManipulator, osgGA::KeySwitchMatrixManipulator, osgGA::NodeTrackerManipulator, osgGA::TerrainManipulator, osgGA::TrackballManipulator, and osgGA::UFOManipulator.

virtual void osgGA::MatrixManipulator::home ( double   )  [inline, virtual]

Move the camera to the default position. This version does not require GUIEventAdapter and GUIActionAdapter so may be called from somewhere other than a handle() method in GUIEventHandler. Application must be aware of implications.

Reimplemented in osgGA::AnimationPathManipulator, osgGA::TrackballManipulator, and osgGA::UFOManipulator.

virtual void osgGA::MatrixManipulator::init ( const GUIEventAdapter ,
GUIActionAdapter  
) [inline, virtual]

virtual bool osgGA::MatrixManipulator::handle ( const GUIEventAdapter ea,
GUIActionAdapter us 
) [virtual]


Member Data Documentation


The documentation for this class was generated from the following file:

Generated on Wed Jul 30 23:59:04 2008 for openscenegraph by  doxygen 1.5.6