VTK
vtkInteractorStyleRubberBand3D.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkInteractorStyleRubberBand3D.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 =========================================================================*/
15 /*-------------------------------------------------------------------------
16  Copyright 2008 Sandia Corporation.
17  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
18  the U.S. Government retains certain rights in this software.
19 -------------------------------------------------------------------------*/
38 #ifndef vtkInteractorStyleRubberBand3D_h
39 #define vtkInteractorStyleRubberBand3D_h
40 
41 #include "vtkInteractionStyleModule.h" // For export macro
43 
45 
46 class VTKINTERACTIONSTYLE_EXPORT vtkInteractorStyleRubberBand3D : public vtkInteractorStyleTrackballCamera
47 {
48 public:
51  void PrintSelf(ostream& os, vtkIndent indent) override;
52 
53  void OnLeftButtonDown() override;
54  void OnLeftButtonUp() override;
55  void OnMiddleButtonDown() override;
56  void OnMiddleButtonUp() override;
57  void OnRightButtonDown() override;
58  void OnRightButtonUp() override;
59  void OnMouseMove() override;
60  void OnMouseWheelForward() override;
61  void OnMouseWheelBackward() override;
62 
64 
67  vtkSetMacro(RenderOnMouseMove, bool);
68  vtkGetMacro(RenderOnMouseMove, bool);
69  vtkBooleanMacro(RenderOnMouseMove, bool);
71 
75  enum
76  {
77  SELECT_NORMAL = 0,
78  SELECT_UNION = 1
79  };
80 
82 
85  vtkGetMacro(Interaction, int);
87 
88  enum
89  {
94  SELECTING
95  };
96 
98 
103  vtkGetVector2Macro(StartPosition,int);
104  vtkGetVector2Macro(EndPosition,int);
106 
107 protected:
109  ~vtkInteractorStyleRubberBand3D() override;
110 
111  // The interaction mode
113 
114  // Draws the selection rubber band
115  void RedrawRubberBand();
116 
117  // The end position of the selection
118  int StartPosition[2];
119 
120  // The start position of the selection
121  int EndPosition[2];
122 
123  // The pixel array for the rubber band
125 
126  // Whether to trigger a render when the mouse moves
128 
129 private:
131  void operator=(const vtkInteractorStyleRubberBand3D&) = delete;
132 };
133 
134 #endif
vtkInteractorStyleTrackballCamera::OnMouseWheelForward
void OnMouseWheelForward() override
vtkInteractorStyleRubberBand3D::NONE
Definition: vtkInteractorStyleRubberBand3D.h:90
vtkInteractorStyleRubberBand3D::PixelArray
vtkUnsignedCharArray * PixelArray
Definition: vtkInteractorStyleRubberBand3D.h:124
vtkInteractorStyleTrackballCamera::New
static vtkInteractorStyleTrackballCamera * New()
vtkInteractorStyleRubberBand3D::ROTATING
Definition: vtkInteractorStyleRubberBand3D.h:93
vtkUnsignedCharArray
dynamic, self-adjusting array of unsigned char
Definition: vtkUnsignedCharArray.h:41
vtkInteractorStyleTrackballCamera::OnLeftButtonUp
void OnLeftButtonUp() override
vtkInteractorStyleTrackballCamera::OnMouseWheelBackward
void OnMouseWheelBackward() override
vtkInteractorStyleRubberBand3D::ZOOMING
Definition: vtkInteractorStyleRubberBand3D.h:92
vtkInteractorStyleRubberBand3D::RenderOnMouseMove
bool RenderOnMouseMove
Definition: vtkInteractorStyleRubberBand3D.h:127
vtkInteractorStyleTrackballCamera::OnRightButtonUp
void OnRightButtonUp() override
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkInteractorStyleTrackballCamera::OnRightButtonDown
void OnRightButtonDown() override
vtkInteractorStyleTrackballCamera::OnMouseMove
void OnMouseMove() override
Event bindings controlling the effects of pressing mouse buttons or moving the mouse.
vtkInteractorStyleRubberBand3D::Interaction
int Interaction
Definition: vtkInteractorStyleRubberBand3D.h:112
vtkInteractorStyleRubberBand3D::PANNING
Definition: vtkInteractorStyleRubberBand3D.h:91
vtkInteractorStyleTrackballCamera::OnLeftButtonDown
void OnLeftButtonDown() override
vtkInteractorStyleTrackballCamera
interactive manipulation of the camera
Definition: vtkInteractorStyleTrackballCamera.h:47
vtkInteractorStyleTrackballCamera::OnMiddleButtonDown
void OnMiddleButtonDown() override
vtkInteractorStyleTrackballCamera::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkInteractorStyleRubberBand3D
A rubber band interactor for a 3D view.
Definition: vtkInteractorStyleRubberBand3D.h:46
vtkInteractorStyleTrackballCamera::OnMiddleButtonUp
void OnMiddleButtonUp() override
vtkInteractorStyleTrackballCamera.h