Slicer 5.4
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
Loading...
Searching...
No Matches
vtkMRMLSceneViewNode.h
Go to the documentation of this file.
1/*=auto=========================================================================
2
3 Portions (c) Copyright 2005 Brigham and Women's Hospital (BWH) All Rights Reserved.
4
5 See COPYRIGHT.txt
6 or http://www.slicer.org/copyright/copyright.txt for details.
7
8 Program: 3D Slicer
9 Module: $RCSfile: vtkMRMLSceneViewNode.h,v $
10 Date: $Date: 2006/03/19 17:12:29 $
11 Version: $Revision: 1.13 $
12
13=========================================================================auto=*/
14
15#ifndef __vtkMRMLSceneViewNode_h
16#define __vtkMRMLSceneViewNode_h
17
18#include "vtkMRMLStorableNode.h"
19
20// VTK includes
21#include <vtkStdString.h>
22class vtkCollection;
23class vtkImageData;
24
26class VTK_MRML_EXPORT vtkMRMLSceneViewNode : public vtkMRMLStorableNode
27{
28 public:
31 void PrintSelf(ostream& os, vtkIndent indent) override;
32
34
35 void SetScene(vtkMRMLScene* scene) override;
36
39 void ReadXMLAttributes( const char** atts) override;
40
43 void WriteXML(ostream& of, int indent) override;
44
47 void WriteNodeBodyXML(ostream& of, int indent) override;
48
51 void Copy(vtkMRMLNode *node) override;
52
55 const char* GetNodeTagName() override {return "SceneView";}
56
59 void UpdateScene(vtkMRMLScene *scene) override;
60
63 virtual void UpdateStoredScene();
64
68 void ProcessChildNode(vtkMRMLNode *node) override;
69
72
76 void StoreScene();
77
81
91 bool RestoreScene(bool removeNodes = true);
92
94
96 void SetSceneViewDescription(const vtkStdString& newDescription);
97 vtkGetMacro(SceneViewDescription, vtkStdString);
98
100 virtual void SetScreenShot(vtkImageData* newScreenShot);
101 vtkGetObjectMacro(ScreenShot, vtkImageData);
102
109 // TODO use an enum for the types
110 virtual void SetScreenShotType(int type);
111 vtkGetMacro(ScreenShotType, int);
112
113
117
121 int GetNodesByClass(const char *className, std::vector<vtkMRMLNode *> &nodes);
126 vtkCollection* GetNodesByClass(const char *className);
127
132
133 void SetSceneViewRootDir( const char* name);
134
135protected:
140
141
143
146
148 vtkImageData* ScreenShot;
149
152
153};
154
155#endif
Abstract Superclass for all specific types of MRML nodes.
vtkMRMLScene * GetStoredScene()
void SetSceneViewRootDir(const char *name)
vtkStdString SceneViewDescription
The associated Description.
int ScreenShotType
The type of the screenshot.
virtual void SetScreenShotType(int type)
vtkCollection * GetNodesByClass(const char *className)
static vtkMRMLSceneViewNode * New()
void UpdateScene(vtkMRMLScene *scene) override
Updates scene nodes.
~vtkMRMLSceneViewNode() override
vtkMRMLStorageNode * CreateDefaultStorageNode() override
Create default storage node or nullptr if does not have one.
bool RestoreScene(bool removeNodes=true)
int GetNodesByClass(const char *className, std::vector< vtkMRMLNode * > &nodes)
void Copy(vtkMRMLNode *node) override
Copy the node's attributes to this object.
void ReadXMLAttributes(const char **atts) override
Read node attributes from XML file.
vtkMRMLNode * CreateNodeInstance() override
MRMLNode methods.
void PrintSelf(ostream &os, vtkIndent indent) override
void operator=(const vtkMRMLSceneViewNode &)
vtkImageData * ScreenShot
The vtkImageData of the screenshot.
const char * GetNodeTagName() override
Get node XML tag name (like Volume, Model)
void ProcessChildNode(vtkMRMLNode *node) override
bool IncludeNodeInSceneView(vtkMRMLNode *node)
void SetScene(vtkMRMLScene *scene) override
This method is for internal use only. Use AddNode method of vtkMRMLScene to add a node to the scene.
vtkMRMLSceneViewNode(const vtkMRMLSceneViewNode &)
void WriteXML(ostream &of, int indent) override
Write this node's information to a MRML file in XML format.
virtual void UpdateStoredScene()
Updates internal nodes.
void SetSceneViewDescription(const vtkStdString &newDescription)
A description of this sceneView.
void WriteNodeBodyXML(ostream &of, int indent) override
Write this node's body to a MRML file in XML format.
virtual void SetScreenShot(vtkImageData *newScreenShot)
The attached screenshot of this sceneView.
void SetAbsentStorageFileNames()
A set of MRML Nodes that supports serialization and undo/redo.
MRML node to represent a 3D surface model.
A superclass for other storage nodes.