forked from Kitware/VTK
-
Notifications
You must be signed in to change notification settings - Fork 0
/
vtkResliceCursorActor.h
126 lines (102 loc) · 3.51 KB
/
vtkResliceCursorActor.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
/*=========================================================================
Program: Visualization Toolkit
Module: vtkResliceCursorActor.h
Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
All rights reserved.
See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
This software is distributed WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the above copyright notice for more information.
=========================================================================*/
/**
* @class vtkResliceCursorActor
* @brief Represent a reslice cursor
*
* A reslice cursor consists of a pair of lines (cross hairs), thin or thick,
* that may be interactively manipulated for thin/thick reformats through the
* data.
* @sa
* vtkResliceCursor vtkResliceCursorPolyDataAlgorithm vtkResliceCursorWidget
* vtkResliceCursorRepresentation vtkResliceCursorLineRepresentation
*/
#ifndef vtkResliceCursorActor_h
#define vtkResliceCursorActor_h
#include "vtkInteractionWidgetsModule.h" // For export macro
#include "vtkProp3D.h"
class vtkResliceCursor;
class vtkResliceCursorPolyDataAlgorithm;
class vtkPolyDataMapper;
class vtkActor;
class vtkProperty;
class vtkBoundingBox;
class VTKINTERACTIONWIDGETS_EXPORT vtkResliceCursorActor : public vtkProp3D
{
public:
//@{
/**
* Standard VTK methods
*/
static vtkResliceCursorActor *New();
vtkTypeMacro(vtkResliceCursorActor,vtkProp3D);
void PrintSelf(ostream& os, vtkIndent indent) override;
//@}
//@{
/**
* Get the cursor algorithm. The cursor must be set on the algorithm
*/
vtkGetObjectMacro( CursorAlgorithm, vtkResliceCursorPolyDataAlgorithm );
//@}
/**
* Support the standard render methods.
*/
int RenderOpaqueGeometry(vtkViewport *viewport) override;
/**
* Does this prop have some translucent polygonal geometry? No.
*/
vtkTypeBool HasTranslucentPolygonalGeometry() override;
/**
* Release any graphics resources that are being consumed by this actor.
* The parameter window could be used to determine which graphic
* resources to release.
*/
void ReleaseGraphicsResources(vtkWindow *) override;
/**
* Get the bounds for this Actor as (Xmin,Xmax,Ymin,Ymax,Zmin,Zmax).
*/
double *GetBounds() override;
/**
* Get the actors mtime plus consider its algorithm.
*/
vtkMTimeType GetMTime() override;
//@{
/**
* Get property of the internal actor.
*/
vtkProperty *GetCenterlineProperty( int i );
vtkProperty *GetThickSlabProperty( int i );
//@}
/**
* Get the centerline actor along a particular axis
*/
vtkActor * GetCenterlineActor(int axis);
/**
* Set the user matrix on all the internal actors.
*/
virtual void SetUserMatrix( vtkMatrix4x4 *matrix);
protected:
vtkResliceCursorActor();
~vtkResliceCursorActor() override;
void UpdateViewProps( vtkViewport * v = nullptr );
void UpdateHoleSize( vtkViewport * v );
vtkResliceCursorPolyDataAlgorithm * CursorAlgorithm;
vtkPolyDataMapper * CursorCenterlineMapper[3];
vtkActor * CursorCenterlineActor[3];
vtkPolyDataMapper * CursorThickSlabMapper[3];
vtkActor * CursorThickSlabActor[3];
vtkProperty * CenterlineProperty[3];
vtkProperty * ThickSlabProperty[3];
private:
vtkResliceCursorActor(const vtkResliceCursorActor&) = delete;
void operator=(const vtkResliceCursorActor&) = delete;
};
#endif