|
void | reset (void) override |
| Resets camera to initial position and orientation. More...
|
|
void | updateViewMatrix () override |
| Compose rotation and translation. More...
|
|
void | strideLeft (void) override |
| Translates the view matrix to the left. More...
|
|
void | strideRight (void) override |
| Translates the view matrix to the right. More...
|
|
void | moveBack (void) override |
| Translates the view matrix back. More...
|
|
void | moveForward (void) override |
| Translates the view matrix forward. More...
|
|
void | moveDown (void) override |
| Translates the view matrix down. More...
|
|
void | moveUp (void) override |
| Translates the view matrix up. More...
|
|
void | rotate (Eigen::Vector2f new_mouse_pos) override |
| Rotates the camera view direction around X and Y axes. More...
|
|
void | rotateZ (Eigen::Vector2f new_mouse_pos) override |
| Rotates the camera view direction around Z axis. More...
|
|
| ~Flycamera () |
| Default destructor. More...
|
|
void | initOpenGLMatrices (void) |
| Initializes the view and projection matrices. They are all initialized as Identity matrices, but view is then translated by the defaultTranslation vector. More...
|
|
| Flycamera () |
| Default constructor. More...
|
|
void | setDefaultView (Eigen::Affine3f view) |
| Set default rotation and translation from and Affine3f matrix. More...
|
|
Eigen::Vector3f | getDefaultTranslation (void) |
| Returns the default translation for placing the camera outside the trackball sphere. More...
|
|
void | renderAtCorner (void) |
| Renders the camera's coordinate axis at the lower right corner of the screen. More...
|
|
Eigen::Vector2f | normalizePosition (const Eigen::Vector2f &pos) |
| Nomalizes a screen position to range [-1,1]. More...
|
|
void | startRotation (Eigen::Vector2f pos) |
| Begin view direction rotation. More...
|
|
void | setSpeed (const float &speed) |
| Changes the camera speed. More...
|
|
void | resetViewMatrix (void) |
| Reset view matrix. More...
|
|
void | resetProjectionMatrix (void) |
| Reset projection matrix. More...
|
|
void | reset (void) |
| Resets trackball to initial position and orientation. More...
|
|
Eigen::Vector3f | getCenter (void) const |
| Returns the center of the camera in world space. More...
|
|
void | getViewMatrix (GLdouble *matrix) |
| Return the modelview matrix as a GLdouble array. More...
|
|
void | getProjectionMatrix (GLdouble *matrix) |
| Return the projection matrix as a GLdouble array. More...
|
|
Eigen::Vector3f | projectPoint (const Eigen::Vector4f &pt, Eigen::Vector4f &viewport) |
| Returns screen space coordinates of a 3D point. More...
|
|
Eigen::Affine3f | getViewMatrix (void) const |
| Returns the view matrix as an Affine 3x3 matrix. More...
|
|
Eigen::Affine3f * | viewMatrix (void) |
| Returns a pointer to the view matrix as an Affine 3x3 matrix. More...
|
|
Eigen::Matrix4f | getProjectionMatrix (void) const |
| Returns the view matrix as an 4x4 matrix. More...
|
|
Eigen::Matrix4f * | projectionMatrix (void) |
| Returns a pointer to the projection matrix as an 4x4 matrix. More...
|
|
Eigen::Matrix3f | getRotationMatrix (void) const |
| Returns a 3x3 matrix containing only the rotation of the view matrix. More...
|
|
Eigen::Vector3f | getTranslationMatrix (void) const |
| Returns the translation part of the view matrix as a vector. More...
|
|
float | getPerspectiveScale (void) const |
| Returns the perspective scale. More...
|
|
Eigen::Vector4f | getViewport (void) const |
| Returns the viewport coordinates. More...
|
|
Eigen::Vector2i | getViewportSize (void) const |
| Returns the dimensions of the viewport. More...
|
|
float | getViewportAspectRatio (void) const |
| Returns the viewport aspect ratio. More...
|
|
void | setViewport (const Eigen::Vector4f &vp) |
| Sets the viewport coordinates. More...
|
|
void | setViewport (const Eigen::Vector2i &vp) |
|
void | setViewport (const Eigen::Vector2f &vp) |
| Sets the viewport coordinates considering that the minimum coordinates are zero. More...
|
|
void | setProjectionMatrix (const Eigen::Matrix4f &mat) |
| Sets the projection matrix from a given 4x4 matrix. More...
|
|
void | setViewMatrix (const Eigen::Affine3f &mat) |
| Sets the view matrix from a given an affine 3x3 matrix. More...
|
|
float | getNearPlane (void) const |
| Returns near plane value. More...
|
|
float | getFarPlane (void) const |
| Returns far plane value. More...
|
|
| ~Camera () |
| Default destructor. More...
|
|
float | getFovy (void) const |
| Returns current field of view angle in y axis. More...
|
|
| Camera (void) |
| Default constructor. More...
|
|
Eigen::Matrix4f | setPerspectiveMatrix (float fy, float in_aspect_ratio, float in_near_plane, float in_far_plane) |
| Sets the projection matrix as a perspective matrix. More...
|
|
void | changeFovy (float new_fovy) |
| Changes the fovy and computes new perspective projection matrix. More...
|
|
Eigen::Matrix4f | setOrthographicMatrix (float left, float right, float bottom, float top, float near_plane, float far_plane) |
| Sets the projection matrix as a orthographic matrix. More...
|
|
void | incrementFov (float inc) |
| Increases the fov of the perspective matrix by a given increment. More...
|
|
void | translate (const Eigen::Vector3f &translation) |
| Translates the view matrix by a given vector. More...
|
|
void | rotate (const Eigen::Quaternion< float > &rotation) |
| Rotate the view matrix by a given quaternion. More...
|
|
void | scale (const Eigen::Vector3f &scale_factors) |
| Scales the view matrix by given factors. More...
|
|
void | scale (float scale_factor) |
| Scales the view matrix by given factor in all axis. More...
|
|
Free camera class for manipulating a camera.
This class simulates a free camera which apply transformations based on camera's frame, instead of world's frame.