Slicer 5.6
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
Loading...
Searching...
No Matches
vtkMRMLMarkupsAngleNode.h
Go to the documentation of this file.
1/*==============================================================================
2
3 Program: 3D Slicer
4
5 Portions (c) Copyright Brigham and Women's Hospital (BWH) All Rights Reserved.
6
7 See COPYRIGHT.txt
8 or http://www.slicer.org/copyright/copyright.txt for details.
9
10 Unless required by applicable law or agreed to in writing, software
11 distributed under the License is distributed on an "AS IS" BASIS,
12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 See the License for the specific language governing permissions and
14 limitations under the License.
15
16==============================================================================*/
17
18#ifndef __vtkMRMLMarkupsAngleNode_h
19#define __vtkMRMLMarkupsAngleNode_h
20
21// MRML includes
23
24// Markups includes
25#include "vtkSlicerMarkupsModuleMRMLExport.h"
27#include "vtkMRMLMarkupsNode.h"
28
35class VTK_SLICER_MARKUPS_MODULE_MRML_EXPORT vtkMRMLMarkupsAngleNode : public vtkMRMLMarkupsNode
36{
37public:
41 void PrintSelf(ostream& os, vtkIndent indent) override;
42
43 const char* GetIcon() override {return ":/Icons/MarkupsAngle.png";}
44 const char* GetAddIcon() override {return ":/Icons/MarkupsAngleMouseModePlace.png";}
45 const char* GetPlaceAddIcon() override {return ":/Icons/MarkupsAngleMouseModePlaceAdd.png";}
46
52 {
56 AngleMeasurementMode_Last
57 };
58
59 //--------------------------------------------------------------------------
60 // MRMLNode methods
61 //--------------------------------------------------------------------------
62
65 const char* GetNodeTagName() override {return "MarkupsAngle";}
66
68 const char* GetMarkupType() override {return "Angle";};
69
70 // Get markup type GUI display name
71 const char* GetTypeDisplayName() override {return "Angle";};
72
74 const char* GetDefaultNodeNamePrefix() override {return "A";};
75
77 void ReadXMLAttributes( const char** atts) override;
78
80 void WriteXML(ostream& of, int indent) override;
81
85
88 vtkGetMacro(AngleMeasurementMode, int);
114
117 vtkGetVector3Macro(OrientationRotationAxis, double);
120 virtual void SetOrientationRotationAxis(double r, double a, double s);
123 virtual void SetOrientationRotationAxis(double ras[3]);
124
128
129protected:
134
137
138protected:
142 double OrientationRotationAxis[3];
143
150};
151
152#endif
MRML node to represent an angle markup Angle Markups nodes contain three control points....
vtkMRMLMarkupsAngleNode(const vtkMRMLMarkupsAngleNode &)
virtual void SetOrientationRotationAxis(double r, double a, double s)
const char * GetNodeTagName() override
Get node XML tag name (like Volume, Model)
const char * GetMarkupType() override
Get markup type internal name.
const char * GetAddIcon() override
void SetAngleMeasurementModeToOrientedPositive()
~vtkMRMLMarkupsAngleNode() override
void SetAngleMeasurementModeToOrientedSigned()
static vtkMRMLMarkupsAngleNode * New()
virtual void SetOrientationRotationAxis(double ras[3])
void operator=(const vtkMRMLMarkupsAngleNode &)
int GetAngleMeasurementModeFromString(const char *name)
void PrintSelf(ostream &os, vtkIndent indent) override
Print out the node information to the output stream.
void SetAngleMeasurementModeToMinimal()
vtkMRMLNode * CreateNodeInstance() override
MRMLNode methods.
const char * GetIcon() override
const char * GetTypeDisplayName() override
const char * GetPlaceAddIcon() override
vtkMRMLCopyContentMacro(vtkMRMLMarkupsAngleNode)
const char * GetDefaultNodeNamePrefix() override
Get markup short name.
void ReadXMLAttributes(const char **atts) override
Read node attributes from XML file.
void SetAngleMeasurementMode(int type)
void WriteXML(ostream &of, int indent) override
Write this node's information to a MRML file in XML format.
const char * GetAngleMeasurementModeAsString(int id)
void UpdateInteractionHandleToWorldMatrix() override
Calculates the handle to world matrix based on the current control points.
Abstract Superclass for all specific types of MRML nodes.