ICameraState Class Reference

Stores camera parameters. More...

#include <camera.h>

Inheritance diagram for ICameraState:

CCameraState

List of all members.

Public Types

enum  projMode_e { PROJECT_ORTHO, PROJECT_FRUSTUM }
 Defines camera projection modes. More...

Public Member Functions

virtual ~ICameraState (void)
 Destructor.
virtual void resetCamera (void)=0
 Reset camera to initial position and angles.
virtual void setCameraRotation (const mat4_t &matrix)=0
 Sets the camera rotation matrix.
virtual void getCameraRotation (mat4_t &matrix)=0
 Get the camera rotation matrix.
virtual void setCameraTranslation (const vec3_t &t)=0
 Sets the new camera translation vector.
virtual void getCameraTranslation (vec3_t &t)=0
 Get the current camera translation vector.
virtual void setProjectionMode (projMode_e mode)=0
 Set the projection mode.
virtual void setFovY (float fovY)=0
 Set the vertical field-of-view in degree.


Detailed Description

Stores camera parameters.

This interface is used to manipulate camera related parameters like projection mode and transformation.


Member Enumeration Documentation

enum ICameraState::projMode_e

Defines camera projection modes.


Constructor & Destructor Documentation

virtual ICameraState::~ICameraState ( void   )  [inline, virtual]

Destructor.


Member Function Documentation

virtual void ICameraState::resetCamera ( void   )  [pure virtual]

Reset camera to initial position and angles.

Does not change the projection mode

Implemented in CCameraState.

virtual void ICameraState::setCameraRotation ( const mat4_t matrix  )  [pure virtual]

Sets the camera rotation matrix.

The matrix is 4x4 and all matrix elements are used. The matrix is strored in column major order.

Parameters:
matrix The rotation matrix
Precondition:
Assumes the matrix is a rotation matrix. If this is not the case, results are undefined.

Implemented in CCameraState.

virtual void ICameraState::getCameraRotation ( mat4_t matrix  )  [pure virtual]

Get the camera rotation matrix.

The matrix is 4x4 and all elements are used.

Parameters:
matrix The rotation maxtrix buffer.

Implemented in CCameraState.

virtual void ICameraState::setCameraTranslation ( const vec3_t t  )  [pure virtual]

Sets the new camera translation vector.

This translation is applied after the camera was rotated.

Parameters:
t Translation vector.

Implemented in CCameraState.

virtual void ICameraState::getCameraTranslation ( vec3_t t  )  [pure virtual]

Get the current camera translation vector.

Parameters:
t The translation vector will be stored there.

Implemented in CCameraState.

virtual void ICameraState::setProjectionMode ( projMode_e  mode  )  [pure virtual]

Set the projection mode.

The default is PROJECT_FRUSTUM.

Parameters:
mode Projection mode.

Implemented in CCameraState.

virtual void ICameraState::setFovY ( float  fovY  )  [pure virtual]

Set the vertical field-of-view in degree.

The value can range from >0 degree up to < 180 degree. If the value is outside this range, it is set to 50. The horizontal fov depends on the width/height aspect of the viewport, where fovX = ( width / height ) * fovY. The default value is 50.

Parameters:
fovY Vertical field-of-view in degree.

Implemented in CCameraState.


The documentation for this class was generated from the following file:
Generated on Sun Mar 2 17:12:32 2008 for Shader Maker by  doxygen 1.5.4