VTK
vtkImageOrthoPlanes.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageOrthoPlanes.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 =========================================================================*/
31 #ifndef vtkImageOrthoPlanes_h
32 #define vtkImageOrthoPlanes_h
33 
34 #include "vtkInteractionWidgetsModule.h" // For export macro
35 #include "vtkObject.h"
36 
38 class vtkTransform;
39 class vtkMatrix4x4;
40 
41 class VTKINTERACTIONWIDGETS_EXPORT vtkImageOrthoPlanes : public vtkObject
42 {
43 public:
44  static vtkImageOrthoPlanes *New();
46  void PrintSelf(ostream& os, vtkIndent indent) override;
47 
49 
52  void SetPlane(int i, vtkImagePlaneWidget *imagePlaneWidget);
53  vtkImagePlaneWidget* GetPlane(int i);
55 
59  void ResetPlanes();
60 
64  vtkTransform *GetTransform() { return this->Transform; };
65 
69  void HandlePlaneEvent(vtkImagePlaneWidget *imagePlaneWidget);
70 
71 protected:
73  ~vtkImageOrthoPlanes() override;
74 
75  void HandlePlaneRotation(vtkImagePlaneWidget *imagePlaneWidget,
76  int indexOfModifiedPlane);
77  void HandlePlanePush(vtkImagePlaneWidget *imagePlaneWidget,
78  int indexOfModifiedPlane);
79  void HandlePlaneTranslate(vtkImagePlaneWidget *imagePlaneWidget,
80  int indexOfModifiedPlane);
81  void HandlePlaneScale(vtkImagePlaneWidget *imagePlaneWidget,
82  int indexOfModifiedPlane);
83 
84  void SetTransformMatrix(vtkMatrix4x4 *matrix,
85  vtkImagePlaneWidget *currentImagePlane,
86  int indexOfModifiedPlane);
87 
88  void GetBounds(double bounds[3]);
89 
90  // The plane definitions prior to any rotations or scales
91  double Origin[3][3];
92  double Point1[3][3];
93  double Point2[3][3];
94 
95  // The current position and orientation of the bounding box with
96  // respect to the origin.
98 
99  // An array to hold the planes
101 
102  // The number of planes.
104 
105  // The observer tags for these planes
107 
108 private:
109  vtkImageOrthoPlanes(const vtkImageOrthoPlanes&) = delete;
110  void operator=(const vtkImageOrthoPlanes&) = delete;
111 };
112 
113 #endif
114 
115 
abstract base class for most VTK objects
Definition: vtkObject.h:59
represent and manipulate 4x4 transformation matrices
Definition: vtkMatrix4x4.h:41
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
Connect three vtkImagePlaneWidgets together.
vtkTransform * Transform
describes linear transformations via a 4x4 matrix
Definition: vtkTransform.h:60
vtkImagePlaneWidget ** Planes
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkTransform * GetTransform()
Get the transform for the planes.
3D widget for reslicing image data
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
Transform
Definition: ADIOSDefs.h:40