VTK  9.3.20240424
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
141#ifndef vtkInteractorStyleTrackballCamera_h
142#define vtkInteractorStyleTrackballCamera_h
143
144#include "vtkInteractionStyleModule.h" // For export macro
145#include "vtkInteractorStyle.h"
146#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
147
148VTK_ABI_NAMESPACE_BEGIN
150 : public vtkInteractorStyle
151{
152public:
155 void PrintSelf(ostream& os, vtkIndent indent) override;
156
158
162 void OnMouseMove() override;
163 void OnLeftButtonDown() override;
164 void OnLeftButtonUp() override;
165 void OnMiddleButtonDown() override;
166 void OnMiddleButtonUp() override;
167 void OnRightButtonDown() override;
168 void OnRightButtonUp() override;
169 void OnMouseWheelForward() override;
170 void OnMouseWheelBackward() override;
172
173 // These methods for the different interactions in different modes
174 // are overridden in subclasses to perform the correct motion. Since
175 // they are called by OnTimer, they do not have mouse coord parameters
176 // (use interactor's GetEventPosition and GetLastEventPosition)
177 void Rotate() override;
178 void Spin() override;
179 void Pan() override;
180 void Dolly() override;
181 void EnvironmentRotate() override;
182
184
187 vtkSetMacro(MotionFactor, double);
188 vtkGetMacro(MotionFactor, double);
190
191protected:
194
196
197 virtual void Dolly(double factor);
198
199private:
201 void operator=(const vtkInteractorStyleTrackballCamera&) = delete;
202};
203
204VTK_ABI_NAMESPACE_END
205#endif
a simple class to control print indentation
Definition vtkIndent.h:108
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)
#define VTK_MARSHALAUTO