class: ege::Camera
Description:
Constructor and Destructor:
+ Camera (const vec3 & _eye,
float _angleZ,
float _angleTeta,
float _distance);
Synopsis:
# mat4 m_matrix;
# float m_offsetFactor;
# void update (void );
# vec3 m_eye;
+ void setEye (const vec3 & _eye);
+ const vec3 & getEye (void ) const;
# vec3 m_calculatedOrigin;
+ const vec3 & getOrigin (void ) const;
# vec3 m_calculatedViewVector;
+ const vec3 & getViewVector (void ) const;
# float m_angleZ;
+ void setAngleZ (float _angleZ);
+ float getAngleZ (void ) const;
# float m_angleTeta;
+ void setAngleTeta (float _angleTeta);
+ float getAngleTeta (void ) const;
# float m_distance;
+ void setDistance (float _distance);
+ float getDistance (void ) const;
+ const mat4 & getMatrix (void ) const;
# bool m_forceViewTop;
+ void setForcingViewTop (bool _newState);
+ void periodicCall (float _step);
+ vec3 projectOnZGround (const vec2 & _cameraDeltaAngle,
float _zValue);
Detail:
m_matrix
# mat4 m_matrix;
transformation matrix.
m_offsetFactor
# float m_offsetFactor;
this variable is used to move the camera to the top position of the system == > automaticly
update
# void update (void );
update the matrix property
Camera
+ Camera (const vec3 & _eye,
float _angleZ,
float _angleTeta,
float _distance);
Constructor.
Parameter [input]: | _eye | Position of the camera destination view. |
Parameter [input]: | _angleZ | Z rotation angle. |
Parameter [input]: | _angleTeta | Angle of the camera inclinason. |
Parameter [input]: | _distance | distance to the eye point |
m_eye
# vec3 m_eye;
position where the camera see
setEye
+ void setEye (const vec3 & _eye);
set the position of the camera.
Parameter [input]: | pos | Position of the camera. |
getEye
+ const vec3 & getEye (void ) const;
get the curent Camera Eye position.
Return: | | the current position. |
m_calculatedOrigin
# vec3 m_calculatedOrigin;
getOrigin
+ const vec3 & getOrigin (void ) const;
get the curent Camera origin position.
Return: | | the current position. |
m_calculatedViewVector
# vec3 m_calculatedViewVector;
getViewVector
+ const vec3 & getViewVector (void ) const;
Get the camera viewing vector.
Return: | | the current position. |
m_angleZ
# float m_angleZ;
setAngleZ
+ void setAngleZ (float _angleZ);
set the angle on the camera
Parameter [input]: | _angleZ | Rotation angle in Z |
getAngleZ
+ float getAngleZ (void ) const;
get the curent Camera angles.
Return: | | the current angles Z. |
m_angleTeta
# float m_angleTeta;
setAngleTeta
+ void setAngleTeta (float _angleTeta);
set the angle on the camera
Parameter [input]: | _angleTeta | Rotation angle in Teta |
getAngleTeta
+ float getAngleTeta (void ) const;
get the curent Camera angles.
Return: | | the current angles Teta. |
m_distance
# float m_distance;
setDistance
+ void setDistance (float _distance);
set the angle on the camera
Parameter [input]: | _distance | Distance to the eye |
getDistance
+ float getDistance (void ) const;
get the curent Camera angles.
Return: | | the current distance to the eye. |
getMatrix
+ const mat4 & getMatrix (void ) const;
get the transformation matix for the camera.
Return: | | the current transformation matrix |
m_forceViewTop
# bool m_forceViewTop;
setForcingViewTop
+ void setForcingViewTop (bool _newState);
change camera mode of view == > force to the top view
periodicCall
+ void periodicCall (float _step);
It is really needed to call the camera periodicly for performing automatic movement
Parameter [input]: | _step | step time of moving |
projectOnZGround
+ vec3 projectOnZGround (const vec2 & _cameraDeltaAngle,
float _zValue);