VTK  9.1.0
vtkInteractorStyleTrackballActor.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkInteractorStyleTrackballActor.h
5
6 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7 All rights reserved.
8 See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9
10 This software is distributed WITHOUT ANY WARRANTY; without even
11 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12 PURPOSE. See the above copyright notice for more information.
13
14=========================================================================*/
46#ifndef vtkInteractorStyleTrackballActor_h
47#define vtkInteractorStyleTrackballActor_h
48
49#include "vtkInteractionStyleModule.h" // For export macro
50#include "vtkInteractorStyle.h"
51
52class vtkCellPicker;
53
54class VTKINTERACTIONSTYLE_EXPORT vtkInteractorStyleTrackballActor : public vtkInteractorStyle
55{
56public:
59 void PrintSelf(ostream& os, vtkIndent indent) override;
60
62
66 void OnMouseMove() override;
67 void OnLeftButtonDown() override;
68 void OnLeftButtonUp() override;
69 void OnMiddleButtonDown() override;
70 void OnMiddleButtonUp() override;
71 void OnRightButtonDown() override;
72 void OnRightButtonUp() override;
74
75 // These methods for the different interactions in different modes
76 // are overridden in subclasses to perform the correct motion. Since
77 // they might be called from OnTimer, they do not have mouse coord parameters
78 // (use interactor's GetEventPosition and GetLastEventPosition)
79 void Rotate() override;
80 void Spin() override;
81 void Pan() override;
82 void Dolly() override;
83 void UniformScale() override;
84
85protected:
88
89 void FindPickedActor(int x, int y);
90
92 vtkProp3D* prop3D, double* boxCenter, int NumRotation, double** rotate, double* scale);
93
95
98
99private:
101 void operator=(const vtkInteractorStyleTrackballActor&) = delete;
102};
103
104#endif
ray-cast cell picker for all kinds of Prop3Ds
Definition: vtkCellPicker.h:76
a simple class to control print indentation
Definition: vtkIndent.h:43
manipulate objects in the scene independent of each other
void OnMiddleButtonUp() 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 FindPickedActor(int x, int y)
void OnRightButtonDown() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
void OnRightButtonUp() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
void OnLeftButtonDown() 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 Rotate() override
These methods for the different interactions in different modes are overridden in subclasses to perfo...
static vtkInteractorStyleTrackballActor * New()
void Prop3DTransform(vtkProp3D *prop3D, double *boxCenter, int NumRotation, double **rotate, double *scale)
void OnMouseMove() 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)
represents an 3D object for placement in a rendered scene
Definition: vtkProp3D.h:53
@ scale
Definition: vtkX3D.h:235