VTK  9.3.0
vtkInteractorStyleTrackballCamera.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
32#ifndef vtkInteractorStyleTrackballCamera_h
33#define vtkInteractorStyleTrackballCamera_h
34
35#include "vtkInteractionStyleModule.h" // For export macro
36#include "vtkInteractorStyle.h"
37
38VTK_ABI_NAMESPACE_BEGIN
39class VTKINTERACTIONSTYLE_EXPORT vtkInteractorStyleTrackballCamera : public vtkInteractorStyle
40{
41public:
44 void PrintSelf(ostream& os, vtkIndent indent) override;
45
47
51 void OnMouseMove() override;
52 void OnLeftButtonDown() override;
53 void OnLeftButtonUp() override;
54 void OnMiddleButtonDown() override;
55 void OnMiddleButtonUp() override;
56 void OnRightButtonDown() override;
57 void OnRightButtonUp() override;
58 void OnMouseWheelForward() override;
59 void OnMouseWheelBackward() override;
61
62 // These methods for the different interactions in different modes
63 // are overridden in subclasses to perform the correct motion. Since
64 // they are called by OnTimer, they do not have mouse coord parameters
65 // (use interactor's GetEventPosition and GetLastEventPosition)
66 void Rotate() override;
67 void Spin() override;
68 void Pan() override;
69 void Dolly() override;
70 void EnvironmentRotate() override;
71
73
76 vtkSetMacro(MotionFactor, double);
77 vtkGetMacro(MotionFactor, double);
79
80protected:
83
85
86 virtual void Dolly(double factor);
87
88private:
90 void operator=(const vtkInteractorStyleTrackballCamera&) = delete;
91};
92
93VTK_ABI_NAMESPACE_END
94#endif
a simple class to control print indentation
Definition vtkIndent.h:29
interactive manipulation of the camera
void OnRightButtonUp() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
virtual void Dolly(double factor)
static vtkInteractorStyleTrackballCamera * New()
void OnLeftButtonDown() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void OnMouseWheelForward() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
void OnMiddleButtonUp() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
void OnMouseMove() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
void Rotate() override
These methods for the different interactions in different modes are overridden in subclasses to perfo...
void OnMouseWheelBackward() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
void OnRightButtonDown() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
void OnLeftButtonUp() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
void OnMiddleButtonDown() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
provide event-driven interface to the rendering window (defines trackball mode)