VTK
vtkInteractorStyleTerrain.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkInteractorStyleTerrain.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 =========================================================================*/
49 #ifndef vtkInteractorStyleTerrain_h
50 #define vtkInteractorStyleTerrain_h
51 
52 #include "vtkInteractionStyleModule.h" // For export macro
53 #include "vtkInteractorStyle.h"
54 
55 class vtkPolyDataMapper;
56 class vtkSphereSource;
57 class vtkExtractEdges;
58 
59 class VTKINTERACTIONSTYLE_EXPORT vtkInteractorStyleTerrain : public vtkInteractorStyle
60 {
61 public:
66 
68  void PrintSelf(ostream& os, vtkIndent indent) override;
69 
71 
75  void OnMouseMove() override;
76  void OnLeftButtonDown() override;
77  void OnLeftButtonUp() override;
78  void OnMiddleButtonDown() override;
79  void OnMiddleButtonUp() override;
80  void OnRightButtonDown() override;
81  void OnRightButtonUp() override;
83 
87  void OnChar() override;
88 
89  // These methods for the different interactions in different modes
90  // are overridden in subclasses to perform the correct motion.
91  void Rotate() override;
92  void Pan() override;
93  void Dolly() override;
94 
96 
99  vtkSetMacro(LatLongLines,vtkTypeBool);
100  vtkGetMacro(LatLongLines,vtkTypeBool);
101  vtkBooleanMacro(LatLongLines,vtkTypeBool);
103 
104 protected:
106  ~vtkInteractorStyleTerrain() override;
107 
108  // Internal helper attributes
110 
115 
116  void SelectRepresentation();
117  void CreateLatLong();
118 
119  double MotionFactor;
120 
121 private:
123  void operator=(const vtkInteractorStyleTerrain&) = delete;
124 
125 };
126 
127 #endif
128 
vtkPolyDataMapper
map vtkPolyData to graphics primitives
Definition: vtkPolyDataMapper.h:36
vtkInteractorStyle::Dolly
virtual void Dolly()
Definition: vtkInteractorStyle.h:293
vtkInteractorStyle.h
vtkExtractEdges
extract cell edges from any type of data
Definition: vtkExtractEdges.h:34
vtkInteractorStyle::Pan
virtual void Pan()
Definition: vtkInteractorStyle.h:292
vtkInteractorStyle::OnChar
void OnChar() override
OnChar is triggered when an ASCII key is pressed.
vtkInteractorStyle::OnMiddleButtonUp
virtual void OnMiddleButtonUp()
Definition: vtkInteractorStyle.h:227
vtkInteractorStyleTerrain::LatLongMapper
vtkPolyDataMapper * LatLongMapper
Definition: vtkInteractorStyleTerrain.h:112
vtkInteractorStyle::OnMouseMove
virtual void OnMouseMove()
Generic event bindings can be overridden in subclasses.
Definition: vtkInteractorStyle.h:223
vtkInteractorStyleTerrain::LatLongSphere
vtkSphereSource * LatLongSphere
Definition: vtkInteractorStyleTerrain.h:111
vtkInteractorStyle::OnMiddleButtonDown
virtual void OnMiddleButtonDown()
Definition: vtkInteractorStyle.h:226
vtkSphereSource
create a polygonal sphere centered at the origin
Definition: vtkSphereSource.h:40
vtkInteractorStyle::OnRightButtonDown
virtual void OnRightButtonDown()
Definition: vtkInteractorStyle.h:228
vtkInteractorStyle::OnLeftButtonDown
virtual void OnLeftButtonDown()
Definition: vtkInteractorStyle.h:224
vtkActor
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:45
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkInteractorStyleTerrain
manipulate camera in scene with natural view up (e.g., terrain)
Definition: vtkInteractorStyleTerrain.h:59
vtkInteractorStyle
provide event-driven interface to the rendering window (defines trackball mode)
Definition: vtkInteractorStyle.h:135
vtkInteractorStyleTerrain::LatLongLines
vtkTypeBool LatLongLines
Definition: vtkInteractorStyleTerrain.h:109
vtkInteractorStyle::OnLeftButtonUp
virtual void OnLeftButtonUp()
Definition: vtkInteractorStyle.h:225
vtkInteractorStyle::New
static vtkInteractorStyle * New()
This class must be supplied with a vtkRenderWindowInteractor wrapper or parent.
vtkInteractorStyleTerrain::LatLongActor
vtkActor * LatLongActor
Definition: vtkInteractorStyleTerrain.h:113
vtkInteractorStyle::Rotate
virtual void Rotate()
These methods for the different interactions in different modes are overridden in subclasses to perfo...
Definition: vtkInteractorStyle.h:290
vtkInteractorStyle::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkInteractorStyle::OnRightButtonUp
virtual void OnRightButtonUp()
Definition: vtkInteractorStyle.h:229
vtkInteractorStyleTerrain::LatLongExtractEdges
vtkExtractEdges * LatLongExtractEdges
Definition: vtkInteractorStyleTerrain.h:114
vtkInteractorStyleTerrain::MotionFactor
double MotionFactor
Definition: vtkInteractorStyleTerrain.h:119
vtkTypeBool
int vtkTypeBool
Definition: vtkABI.h:69