![]() |
ACloudViewer
3.9.4
A Modern Library for 3D Data Processing
|
#include <CameraInteractorLogic.h>


Public Member Functions | |
| CameraInteractorLogic (Camera *c, double min_far_plane) | |
| void | SetBoundingBox (const ccBBox &bounds) override |
| void | Rotate (int dx, int dy) override |
| void | RotateZ (int dx, int dy) override |
| Rotates about the forward axis of the matrix. More... | |
| void | Dolly (float dy, DragType type) override |
| void | Dolly (float z_dist, Camera::Transform matrix_in) override |
| void | Pan (int dx, int dy) override |
| void | Zoom (int dy, DragType drag_type) |
| Sets camera field of view. More... | |
| void | RotateLocal (float angle_rad, const Eigen::Vector3f &axis) |
| void | MoveLocal (const Eigen::Vector3f &v) |
| void | RotateFly (int dx, int dy) |
| void | StartMouseDrag () override |
| void | ResetMouseDrag () |
| void | UpdateMouseDragUI () override |
| void | EndMouseDrag () override |
Public Member Functions inherited from cloudViewer::visualization::rendering::RotationInteractorLogic | |
| RotationInteractorLogic (Camera *camera, double min_far_plane) | |
| ~RotationInteractorLogic () | |
| virtual void | SetCenterOfRotation (const Eigen::Vector3f ¢er) |
Public Member Functions inherited from cloudViewer::visualization::rendering::MatrixInteractorLogic | |
| virtual | ~MatrixInteractorLogic () |
| void | SetViewSize (int width, int height) |
| int | GetViewWidth () const |
| int | GetViewHeight () const |
| const ccBBox & | GetBoundingBox () const |
| Eigen::Vector3f | GetCenterOfRotation () const |
| void | SetMouseDownInfo (const Camera::Transform &matrix, const Eigen::Vector3f ¢er_of_rotation) |
| const Camera::Transform & | GetMatrix () const |
| virtual void | RotateWorld (int dx, int dy, const Eigen::Vector3f &x_axis, const Eigen::Vector3f &y_axis) |
| virtual void | RotateZWorld (int dx, int dy, const Eigen::Vector3f &forward) |
Definition at line 16 of file CameraInteractorLogic.h.
| cloudViewer::visualization::rendering::CameraInteractorLogic::CameraInteractorLogic | ( | Camera * | c, |
| double | min_far_plane | ||
| ) |
Definition at line 14 of file CameraInteractorLogic.cpp.
|
overridevirtual |
Moves the matrix along the forward axis. (This is one type of zoom.)
Reimplemented from cloudViewer::visualization::rendering::MatrixInteractorLogic.
Definition at line 44 of file CameraInteractorLogic.cpp.
References cloudViewer::visualization::rendering::RotationInteractorLogic::camera_, cloudViewer::visualization::rendering::MatrixInteractorLogic::center_of_rotation_, cloudViewer::visualization::rendering::MatrixInteractorLogic::Dolly(), cloudViewer::visualization::rendering::Camera::GetModelMatrix(), cloudViewer::visualization::rendering::MatrixInteractorLogic::MOUSE, cloudViewer::visualization::rendering::MatrixInteractorLogic::SetMouseDownInfo(), and type.
Referenced by Zoom().
|
overridevirtual |
Reimplemented from cloudViewer::visualization::rendering::MatrixInteractorLogic.
Definition at line 52 of file CameraInteractorLogic.cpp.
References cloudViewer::visualization::rendering::RotationInteractorLogic::camera_, cloudViewer::visualization::rendering::MatrixInteractorLogic::Dolly(), cloudViewer::visualization::rendering::MatrixInteractorLogic::GetMatrix(), cloudViewer::visualization::rendering::Camera::SetModelMatrix(), and cloudViewer::visualization::rendering::RotationInteractorLogic::UpdateCameraFarPlane().
|
overridevirtual |
Reimplemented from cloudViewer::visualization::rendering::RotationInteractorLogic.
Definition at line 143 of file CameraInteractorLogic.cpp.
| void cloudViewer::visualization::rendering::CameraInteractorLogic::MoveLocal | ( | const Eigen::Vector3f & | v | ) |
|
overridevirtual |
Reimplemented from cloudViewer::visualization::rendering::RotationInteractorLogic.
Definition at line 60 of file CameraInteractorLogic.cpp.
References cloudViewer::visualization::rendering::RotationInteractorLogic::camera_, cloudViewer::visualization::rendering::MatrixInteractorLogic::GetMatrix(), cloudViewer::visualization::rendering::RotationInteractorLogic::Pan(), and cloudViewer::visualization::rendering::Camera::SetModelMatrix().
| void cloudViewer::visualization::rendering::CameraInteractorLogic::ResetMouseDrag | ( | ) |
Definition at line 139 of file CameraInteractorLogic.cpp.
References StartMouseDrag().
|
overridevirtual |
Rotates about an axis defined by dx * matrixLeft, dy * matrixUp. dy is assumed to be in window-style coordinates, that is, going up produces a negative dy. The axis goes through the center of rotation.
Reimplemented from cloudViewer::visualization::rendering::MatrixInteractorLogic.
Reimplemented in cloudViewer::visualization::rendering::CameraSphereInteractorLogic.
Definition at line 25 of file CameraInteractorLogic.cpp.
References cloudViewer::visualization::rendering::RotationInteractorLogic::camera_, cloudViewer::visualization::rendering::MatrixInteractorLogic::GetMatrix(), cloudViewer::visualization::rendering::MatrixInteractorLogic::Rotate(), and cloudViewer::visualization::rendering::Camera::SetModelMatrix().
| void cloudViewer::visualization::rendering::CameraInteractorLogic::RotateFly | ( | int | dx, |
| int | dy | ||
| ) |
Definition at line 35 of file CameraInteractorLogic.cpp.
References cloudViewer::visualization::rendering::RotationInteractorLogic::camera_, cloudViewer::visualization::rendering::MatrixInteractorLogic::GetMatrix(), cloudViewer::visualization::rendering::Camera::GetModelMatrix(), cloudViewer::visualization::rendering::Camera::GetPosition(), cloudViewer::visualization::rendering::MatrixInteractorLogic::Rotate(), cloudViewer::visualization::rendering::Camera::SetModelMatrix(), and cloudViewer::visualization::rendering::MatrixInteractorLogic::SetMouseDownInfo().
| void cloudViewer::visualization::rendering::CameraInteractorLogic::RotateLocal | ( | float | angle_rad, |
| const Eigen::Vector3f & | axis | ||
| ) |
|
overridevirtual |
Rotates about the forward axis of the matrix.
Reimplemented from cloudViewer::visualization::rendering::MatrixInteractorLogic.
Definition at line 30 of file CameraInteractorLogic.cpp.
References cloudViewer::visualization::rendering::RotationInteractorLogic::camera_, cloudViewer::visualization::rendering::MatrixInteractorLogic::GetMatrix(), cloudViewer::visualization::rendering::MatrixInteractorLogic::RotateZ(), and cloudViewer::visualization::rendering::Camera::SetModelMatrix().
|
overridevirtual |
Reimplemented from cloudViewer::visualization::rendering::MatrixInteractorLogic.
Definition at line 17 of file CameraInteractorLogic.cpp.
References cloudViewer::visualization::rendering::RotationInteractorLogic::camera_, ccBBox::GetCenter(), cloudViewer::visualization::rendering::Camera::GetModelMatrix(), cloudViewer::visualization::rendering::MatrixInteractorLogic::SetBoundingBox(), and cloudViewer::visualization::rendering::MatrixInteractorLogic::SetMouseDownInfo().
|
overridevirtual |
Reimplemented from cloudViewer::visualization::rendering::RotationInteractorLogic.
Reimplemented in cloudViewer::visualization::rendering::CameraSphereInteractorLogic.
Definition at line 134 of file CameraInteractorLogic.cpp.
References cloudViewer::visualization::rendering::RotationInteractorLogic::camera_, cloudViewer::visualization::rendering::MatrixInteractorLogic::center_of_rotation_, cloudViewer::visualization::rendering::Camera::GetFieldOfView(), cloudViewer::visualization::rendering::Camera::GetModelMatrix(), and cloudViewer::visualization::rendering::MatrixInteractorLogic::SetMouseDownInfo().
Referenced by ResetMouseDrag(), and cloudViewer::visualization::rendering::CameraSphereInteractorLogic::StartMouseDrag().
|
overridevirtual |
Reimplemented from cloudViewer::visualization::rendering::RotationInteractorLogic.
Definition at line 141 of file CameraInteractorLogic.cpp.
| void cloudViewer::visualization::rendering::CameraInteractorLogic::Zoom | ( | int | dy, |
| DragType | drag_type | ||
| ) |
Sets camera field of view.
Definition at line 78 of file CameraInteractorLogic.cpp.
References cloudViewer::visualization::rendering::RotationInteractorLogic::camera_, cloudViewer::visualization::rendering::MatrixInteractorLogic::center_of_rotation_, cloudViewer::visualization::rendering::MatrixInteractorLogic::center_of_rotation_at_mouse_down_, Dolly(), cloudViewer::visualization::rendering::Camera::GetFar(), cloudViewer::visualization::rendering::Camera::GetFieldOfView(), cloudViewer::visualization::rendering::Camera::GetFieldOfViewType(), cloudViewer::visualization::rendering::Camera::GetModelMatrix(), cloudViewer::visualization::rendering::Camera::GetNear(), cloudViewer::visualization::rendering::Camera::GetPosition(), M_PI, cloudViewer::visualization::rendering::MatrixInteractorLogic::matrix_at_mouse_down_, max(), min(), cloudViewer::visualization::rendering::MatrixInteractorLogic::MOUSE, cloudViewer::visualization::rendering::Camera::SetProjection(), cloudViewer::visualization::rendering::MatrixInteractorLogic::TWO_FINGER, cloudViewer::visualization::rendering::MatrixInteractorLogic::view_height_, cloudViewer::visualization::rendering::MatrixInteractorLogic::view_width_, and cloudViewer::visualization::rendering::MatrixInteractorLogic::WHEEL.