39#ifndef EASY3D_RENDERER_MANIPULATED_FRAME_H
40#define EASY3D_RENDERER_MANIPULATED_FRAME_H
42#include <easy3d/renderer/frame.h>
125 rotationSensitivity_ = sensitivity;
129 translationSensitivity_ = sensitivity;
133 wheelSensitivity_ = sensitivity;
201 enum ScreenAxis { NONE, HORIZONTAL, VERTICAL, ORTHOGONAL };
202 virtual void action_rotate(
int mouse_x,
int mouse_y,
int mouse_dx,
int mouse_dy, Camera* camera, ScreenAxis axis);
203 virtual void action_translate(
int mouse_x,
int mouse_y,
int mouse_dx,
int mouse_dy, Camera* camera, ScreenAxis axis);
204 virtual void action_zoom(
int dy_wheel, Camera* camera);
211 quat deformedBallQuaternion(
int x,
int y,
int pre_x,
int pre_y,
float cx,
float cy,
int w,
int h)
const;
213 Constraint *previousConstraint_;
216 float wheelDelta(
int wheel_dy)
const;
222 float rotationSensitivity_;
223 float translationSensitivity_;
224 float wheelSensitivity_;
225 float zoomSensitivity_;
The Frame class represents a coordinate system, defined by a position and an orientation.
Definition: frame.h:152
A Frame that can be rotated and translated using the mouse.
Definition: manipulated_frame.h:110
float zoomSensitivity() const
Definition: manipulated_frame.h:179
ManipulatedFrame()
Definition: manipulated_frame.cpp:54
void setRotationSensitivity(float sensitivity)
Definition: manipulated_frame.h:124
float wheelSensitivity() const
Definition: manipulated_frame.h:188
void setZoomSensitivity(float sensitivity)
Definition: manipulated_frame.h:136
virtual void action_end()
Definition: manipulated_frame.cpp:99
virtual void action_start()
Definition: manipulated_frame.cpp:95
float translationSensitivity() const
Definition: manipulated_frame.h:170
void setTranslationSensitivity(float sensitivity)
Definition: manipulated_frame.h:128
virtual void action_rotate(int mouse_x, int mouse_y, int mouse_dx, int mouse_dy, Camera *camera, ScreenAxis axis)
Definition: manipulated_frame.cpp:113
ManipulatedFrame & operator=(const ManipulatedFrame &mf)
Definition: manipulated_frame.cpp:66
float rotationSensitivity() const
Definition: manipulated_frame.h:148
~ManipulatedFrame() override=default
void setWheelSensitivity(float sensitivity)
Definition: manipulated_frame.h:132
Definition: collider.cpp:182
Quat< float > quat
A quaternion of float type.
Definition: types.h:86