Slicer  5.0
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
vtkMRMLAnnotationSnapshotNode.h
Go to the documentation of this file.
1 // .NAME vtkMRMLAnnotationSnapshotNode - MRML node to represent scene snapshot including description and screenshot
2 // .SECTION Description
3 // n/A
4 //
5 
6 #ifndef __vtkMRMLAnnotationSnapshotNode_h
7 #define __vtkMRMLAnnotationSnapshotNode_h
8 
9 #include "vtkSlicerAnnotationsModuleMRMLExport.h"
11 #include "vtkMRMLAnnotationNode.h"
12 
13 #include <vtkStdString.h>
14 class vtkImageData;
15 class vtkStringArray;
16 class vtkMRMLStorageNode;
17 
19 class VTK_SLICER_ANNOTATIONS_MODULE_MRML_EXPORT vtkMRMLAnnotationSnapshotNode : public vtkMRMLAnnotationNode
20 {
21 public:
24 
25  //--------------------------------------------------------------------------
26  // MRMLNode methods
27  //--------------------------------------------------------------------------
28 
29  vtkMRMLNode* CreateNodeInstance() override;
30  // Description:
31  // Get node XML tag name (like Volume, Model)
32  const char* GetNodeTagName() override {return "AnnotationSnapshot";}
33 
34  const char* GetIcon() override {return ":/Icons/ViewCamera.png";}
35 
36  void SetSnapshotDescription(const vtkStdString& newDescription);
37  vtkGetMacro(SnapshotDescription, vtkStdString)
38 
39  void WriteXML(ostream& of, int nIndent) override;
40  void ReadXMLAttributes(const char** atts) override;
41 
43  virtual void SetScreenShot(vtkImageData* );
44  vtkGetObjectMacro(ScreenShot, vtkImageData);
45 
47  vtkGetMacro(ScaleFactor, double);
48  vtkSetMacro(ScaleFactor, double);
49 
56  // TODO use an enum for the types
57  void SetScreenShotType(int type);
58  vtkGetMacro(ScreenShotType, int);
59 
62 
63  enum
64  {
65  SnapshotNodeAddedEvent = 0,
67  };
68 
69 protected:
74 
76  vtkStdString SnapshotDescription;
77 
79  vtkImageData* ScreenShot;
80 
88 
89  double ScaleFactor;
90 
91 };
92 
93 #endif
void ReadXMLAttributes(const char **atts) override
Read node attributes from XML file
vtkMRMLNode * CreateNodeInstance() override
MRMLNode methods.
const char * GetNodeTagName() override
Get node XML tag name (like Volume, Model)
vtkStdString SnapshotDescription
The associated Description.
void operator=(const vtkMRMLAnnotationNode &)
A superclass for other storage nodes.
static vtkMRMLAnnotationNode * New()
vtkMRMLStorageNode * CreateDefaultStorageNode() override
void WriteXML(ostream &of, int indent) override
Write this node&#39;s information to a MRML file in XML format.
Abstract Superclass for all specific types of MRML nodes.
Definition: vtkMRMLNode.h:167
vtkImageData * ScreenShot
The vtkImageData of the screenshot.