ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
CameraInteractorLogic.h
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // - CloudViewer: www.cloudViewer.org -
3 // ----------------------------------------------------------------------------
4 // Copyright (c) 2018-2024 www.cloudViewer.org
5 // SPDX-License-Identifier: MIT
6 // ----------------------------------------------------------------------------
7 
8 #pragma once
9 
11 
12 namespace cloudViewer {
13 namespace visualization {
14 namespace rendering {
15 
18 
19 public:
20  CameraInteractorLogic(Camera* c, double min_far_plane);
21 
22  void SetBoundingBox(const ccBBox& bounds) override;
23 
24  void Rotate(int dx, int dy) override;
25  void RotateZ(int dx, int dy) override;
26  void Dolly(float dy, DragType type) override;
27  void Dolly(float z_dist, Camera::Transform matrix_in) override;
28 
29  void Pan(int dx, int dy) override;
30 
32  void Zoom(int dy, DragType drag_type);
33 
34  void RotateLocal(float angle_rad, const Eigen::Vector3f& axis);
35  void MoveLocal(const Eigen::Vector3f& v);
36 
37  void RotateFly(int dx, int dy);
38 
39  void StartMouseDrag() override;
40  void ResetMouseDrag();
41  void UpdateMouseDragUI() override;
42  void EndMouseDrag() override;
43 
44 private:
45  double fov_at_mouse_down_;
46 };
47 
48 } // namespace rendering
49 } // namespace visualization
50 } // namespace cloudViewer
char type
Bounding box structure.
Definition: ecvBBox.h:25
void RotateLocal(float angle_rad, const Eigen::Vector3f &axis)
void Zoom(int dy, DragType drag_type)
Sets camera field of view.
void RotateZ(int dx, int dy) override
Rotates about the forward axis of the matrix.
Eigen::Transform< float, 3, Eigen::Affine > Transform
Definition: Camera.h:29
Generic file read and write utility for python interface.