VTK  9.3.20240425
vtkResliceCursor.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
23#ifndef vtkResliceCursor_h
24#define vtkResliceCursor_h
25
26#include "vtkInteractionWidgetsModule.h" // For export macro
27#include "vtkObject.h"
28
29VTK_ABI_NAMESPACE_BEGIN
30class vtkImageData;
31class vtkPolyData;
32class vtkPlane;
34
35class VTKINTERACTIONWIDGETS_EXPORT vtkResliceCursor : public vtkObject
36{
37public:
39
41
43
46 virtual void SetImage(vtkImageData*);
47 vtkGetObjectMacro(Image, vtkImageData);
49
51
54 virtual void SetCenter(double, double, double);
55 virtual void SetCenter(double center[3]);
56 vtkGetVector3Macro(Center, double);
58
60
63 vtkSetVector3Macro(Thickness, double);
64 vtkGetVector3Macro(Thickness, double);
66
68
71 vtkSetMacro(ThickMode, vtkTypeBool);
72 vtkGetMacro(ThickMode, vtkTypeBool);
73 vtkBooleanMacro(ThickMode, vtkTypeBool);
75
80
85
89 void PrintSelf(ostream& os, vtkIndent indent) override;
90
96 virtual vtkPlane* GetPlane(int n);
97
101 virtual void Update();
102
104
107 vtkGetVector3Macro(XAxis, double);
108 vtkGetVector3Macro(YAxis, double);
109 vtkGetVector3Macro(ZAxis, double);
110 vtkSetVector3Macro(XAxis, double);
111 vtkSetVector3Macro(YAxis, double);
112 vtkSetVector3Macro(ZAxis, double);
113 virtual double* GetAxis(int i);
115
119 vtkGetVector3Macro(XViewUp, double);
120 vtkGetVector3Macro(YViewUp, double);
121 vtkGetVector3Macro(ZViewUp, double);
122 vtkSetVector3Macro(XViewUp, double);
123 vtkSetVector3Macro(YViewUp, double);
124 vtkSetVector3Macro(ZViewUp, double);
125 double* GetViewUp(int i);
126
128
132 vtkSetMacro(Hole, int);
133 vtkGetMacro(Hole, int);
135
137
140 vtkSetMacro(HoleWidth, double);
141 vtkGetMacro(HoleWidth, double);
143
145
149 vtkSetMacro(HoleWidthInPixels, double);
150 vtkGetMacro(HoleWidthInPixels, double);
152
157
163 virtual void Reset();
164
165protected:
168
169 virtual void BuildCursorGeometry();
170 virtual void BuildPolyData();
171 virtual void BuildCursorTopology();
176 virtual void ComputeAxes();
177
179 int Hole;
180 double HoleWidth;
182 double Thickness[3];
183 double Center[3];
184 double XAxis[3];
185 double YAxis[3];
186 double ZAxis[3];
187 double XViewUp[3];
188 double YViewUp[3];
189 double ZViewUp[3];
192
193 vtkPolyData* CenterlineAxis[3];
194
197
198private:
199 vtkResliceCursor(const vtkResliceCursor&) = delete;
200 void operator=(const vtkResliceCursor&) = delete;
201};
202
203VTK_ABI_NAMESPACE_END
204#endif
topologically and geometrically regular array of data
a simple class to control print indentation
Definition vtkIndent.h:108
abstract base class for most VTK objects
Definition vtkObject.h:162
maintain a list of planes
perform various plane computations
Definition vtkPlane.h:135
concrete dataset represents vertices, lines, polygons, and triangle strips
Geometry for a reslice cursor.
double * GetViewUp(int i)
~vtkResliceCursor() override
virtual void SetImage(vtkImageData *)
Set the image (3D) that we are slicing.
virtual double * GetAxis(int i)
Get the computed axes directions.
virtual void SetCenter(double center[3])
Set/Get the cente of the reslice cursor.
virtual void BuildCursorTopology()
static vtkResliceCursor * New()
void PrintSelf(ostream &os, vtkIndent indent) override
Printself method.
vtkMTimeType GetMTime() override
Get the MTime.
virtual void ComputeAxes()
virtual void Reset()
Reset the cursor to the default position, ie with the axes, normal to each other and axis aligned and...
virtual void SetCenter(double, double, double)
Set/Get the cente of the reslice cursor.
vtkImageData * Image
vtkPolyData * PolyData
virtual void BuildCursorGeometry()
virtual void BuildCursorTopologyWithoutHole()
vtkPlaneCollection * ReslicePlanes
vtkTimeStamp PolyDataBuildTime
virtual void Update()
Build the polydata.
virtual vtkPolyData * GetCenterlineAxisPolyData(int axis)
Get the slab and centerline polydata along an axis.
virtual void BuildCursorTopologyWithHole()
virtual vtkPolyData * GetPolyData()
Get the 3D PolyData representation.
virtual void BuildCursorGeometryWithHole()
virtual void BuildPolyData()
virtual void BuildCursorGeometryWithoutHole()
virtual vtkPlane * GetPlane(int n)
Get the planes that represent normals along the X, Y and Z.
record modification and/or execution time
int vtkTypeBool
Definition vtkABI.h:64
vtkTypeUInt32 vtkMTimeType
Definition vtkType.h:270