osg::CameraView Class Reference

CameraView - is a Transform that is used to specify camera views from within the scene graph. More...

Inheritance diagram for osg::CameraView:

Inheritance graph
[legend]

List of all members.

Public Types

enum  FieldOfViewMode { UNCONSTRAINED, HORIZONTAL, VERTICAL }

Public Member Functions

 CameraView ()
 CameraView (const CameraView &pat, const CopyOp &copyop=CopyOp::SHALLOW_COPY)
 META_Node (osg, CameraView)
void setPosition (const Vec3d &pos)
 Set the position of the camera view.
const Vec3dgetPosition () const
 Get the position of the camera view.
void setAttitude (const Quat &quat)
 Set the attitide of the camera view.
const QuatgetAttitude () const
 Get the attitide of the camera view.
void setFieldOfView (double fieldOfView)
 Set the field of view.
double getFieldOfView () const
 Get the field of view.
void setFieldOfViewMode (FieldOfViewMode mode)
 Set the field of view mode - controlling how the field of view of the camera is contrained by the CameaView settings.
FieldOfViewMode getFieldOfViewMode () const
 Get the field of view mode.
void setFocalLength (double focalLength)
 Set the focal length of the camera.
double getFocalLength () const
 Get the focal length of the camera.
virtual bool computeLocalToWorldMatrix (Matrix &matrix, NodeVisitor *nv) const
virtual bool computeWorldToLocalMatrix (Matrix &matrix, NodeVisitor *nv) const

Protected Member Functions

virtual ~CameraView ()

Protected Attributes

Vec3d _position
Quat _attitude
double _fieldOfView
FieldOfViewMode _fieldOfViewMode
double _focalLength


Detailed Description

CameraView - is a Transform that is used to specify camera views from within the scene graph.

The application must attach a camera to a CameraView via the NodePath from the top of the scene graph to the CameraView node itself, and accimulate the view matrix from this NodePath.


Member Enumeration Documentation

enum osg::CameraView::FieldOfViewMode

Enumerator:
UNCONSTRAINED 
HORIZONTAL 
VERTICAL 


Constructor & Destructor Documentation

osg::CameraView::CameraView (  ) 

osg::CameraView::CameraView ( const CameraView pat,
const CopyOp copyop = CopyOp::SHALLOW_COPY 
) [inline]

virtual osg::CameraView::~CameraView (  )  [inline, protected, virtual]


Member Function Documentation

osg::CameraView::META_Node ( osg  ,
CameraView   
)

void osg::CameraView::setPosition ( const Vec3d pos  )  [inline]

Set the position of the camera view.

const Vec3d& osg::CameraView::getPosition (  )  const [inline]

Get the position of the camera view.

void osg::CameraView::setAttitude ( const Quat quat  )  [inline]

Set the attitide of the camera view.

const Quat& osg::CameraView::getAttitude (  )  const [inline]

Get the attitide of the camera view.

void osg::CameraView::setFieldOfView ( double  fieldOfView  )  [inline]

Set the field of view.

The cameras field of view can be contrained to either the horizontal or vertex axis of the camera, or unconstrained in which case the camera/application are left to choose an appropriate field of view. The default value if 60 degrres.

double osg::CameraView::getFieldOfView (  )  const [inline]

Get the field of view.

void osg::CameraView::setFieldOfViewMode ( FieldOfViewMode  mode  )  [inline]

Set the field of view mode - controlling how the field of view of the camera is contrained by the CameaView settings.

FieldOfViewMode osg::CameraView::getFieldOfViewMode (  )  const [inline]

Get the field of view mode.

void osg::CameraView::setFocalLength ( double  focalLength  )  [inline]

Set the focal length of the camera.

A focal length of 0.0 indicates that the camera/application should determine the focal length. The default value is 0.0.

double osg::CameraView::getFocalLength (  )  const [inline]

Get the focal length of the camera.

virtual bool osg::CameraView::computeLocalToWorldMatrix ( Matrix matrix,
NodeVisitor nv 
) const [virtual]

Reimplemented from osg::Transform.

virtual bool osg::CameraView::computeWorldToLocalMatrix ( Matrix matrix,
NodeVisitor nv 
) const [virtual]

Reimplemented from osg::Transform.


Member Data Documentation

Vec3d osg::CameraView::_position [protected]

Quat osg::CameraView::_attitude [protected]

double osg::CameraView::_fieldOfView [protected]

FieldOfViewMode osg::CameraView::_fieldOfViewMode [protected]

double osg::CameraView::_focalLength [protected]


The documentation for this class was generated from the following file:
Generated at Sun Oct 14 02:12:06 2007 for the OpenSceneGraph by doxygen 1.5.3.