Slicer 5.9
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
Loading...
Searching...
No Matches
vtkMRMLAnnotationPointDisplayNode.h
Go to the documentation of this file.
1// .NAME vtkMRMLAnnotationPointDisplayNode - MRML node to represent display properties for tractography.
2// .SECTION Description
3// vtkMRMLAnnotationPointDisplayNode nodes store display properties of trajectories
4// from tractography in diffusion MRI data, including color type (by bundle, by fiber,
5// or by scalar invariants), display on/off for tensor glyphs and display of
6// trajectory as a line or tube.
7//
8
9#ifndef __vtkMRMLAnnotationPointDisplayNode_h
10#define __vtkMRMLAnnotationPointDisplayNode_h
11
12#include "vtkMRML.h"
14#include "vtkSlicerAnnotationsModuleMRMLExport.h"
15
16class VTK_SLICER_ANNOTATIONS_MODULE_MRML_EXPORT vtkMRMLAnnotationPointDisplayNode : public vtkMRMLAnnotationDisplayNode
17{
18public:
21 void PrintSelf(ostream& os, vtkIndent indent) override;
22
23 //--------------------------------------------------------------------------
24 // MRMLNode methods
25 //--------------------------------------------------------------------------
26
28
29 // Description:
30 // Read node attributes from XML (MRML) file
31 void ReadXMLAttributes(const char** atts) override;
32
33 // Description:
34 // Write this node's information to a MRML file in XML format.
35 void WriteXML(ostream& of, int indent) override;
36
37 // Description:
38 // Copy the node's attributes to this object
39 void Copy(vtkMRMLNode* node) override;
40
41 // Description:
42 // Get node XML tag name (like Volume, Annotation)
43 const char* GetNodeTagName() override { return "AnnotationPointDisplay"; }
44
45 // Description:
46 // Finds the storage node and read the data
47 void UpdateScene(vtkMRMLScene* scene) override;
48
49 // Description:
50 // alternative method to propagate events generated in Display nodes
51 void ProcessMRMLEvents(vtkObject* /*caller*/, unsigned long /*event*/, void* /*callData*/) override;
52
74
77
79 void SetGlyphType(int type);
80 vtkGetMacro(GlyphType, int);
82 int GlyphTypeIs3D(int glyphType);
83 int GlyphTypeIs3D() { return this->GlyphTypeIs3D(this->GlyphType); };
84
86 const char* GetGlyphTypeAsString();
87 const char* GetGlyphTypeAsString(int g);
88 void SetGlyphTypeFromString(const char* glyphString);
89
92 void SetGlyphScale(double scale);
93 vtkGetMacro(GlyphScale, double);
94
96 void CreateBackup() override;
98 void RestoreBackup() override;
99
103
107
112
117
128
129protected:
134
137 static const char* GlyphTypesNames[GlyphMax + 2];
138};
139
140//----------------------------------------------------------------------------
145
146//----------------------------------------------------------------------------
151
152//----------------------------------------------------------------------------
157
158//----------------------------------------------------------------------------
163
164#endif
virtual int GetSliceProjection()
virtual void SetSliceProjection(int)
void SetGlyphScale(double scale)
void UpdateScene(vtkMRMLScene *scene) override
void PrintSelf(ostream &os, vtkIndent indent) override
void ReadXMLAttributes(const char **atts) override
void WriteXML(ostream &of, int indent) override
void ProcessMRMLEvents(vtkObject *, unsigned long, void *) override
Propagate events generated in mrml.
void operator=(const vtkMRMLAnnotationPointDisplayNode &)
const char * GetGlyphTypeAsString()
Return a string representing the glyph type, set it from a string.
int GlyphTypeIs3D(int glyphType)
Returns 1 if the type is a 3d one, 0 else.
void RestoreBackup() override
Restore an attached backup of this node.
int GetMinimumGlyphType()
Return the min/max glyph types, for iterating over them in tcl.
void CreateBackup() override
Create a backup of this node and attach it.
~vtkMRMLAnnotationPointDisplayNode() override=default
static vtkMRMLAnnotationPointDisplayNode * New()
vtkMRMLAnnotationPointDisplayNode(const vtkMRMLAnnotationPointDisplayNode &)
void Copy(vtkMRMLNode *node) override
Copy node contents from another node of the same type. Does not copy node ID and Scene....
const char * GetGlyphTypeAsString(int g)
vtkMRMLNode * CreateNodeInstance() override
Create instance of the default node. Like New only virtual.
void SetGlyphTypeFromString(const char *glyphString)
void SetGlyphType(int type)
The glyph type used to display this fiducial.
Abstract Superclass for all specific types of MRML nodes.
A set of MRML Nodes that supports serialization and undo/redo.