Slicer 5.9
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
Loading...
Searching...
No Matches
vtkMRMLVolumeHeaderlessStorageNode.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: vtkMRMLVolumeHeaderlessStorageNode.h,v $
10 Date: $Date: 2006/03/19 17:12:29 $
11 Version: $Revision: 1.3 $
12
13=========================================================================auto=*/
14
15#ifndef __vtkMRMLVolumeHeaderlessStorageNode_h
16#define __vtkMRMLVolumeHeaderlessStorageNode_h
17
18#include "vtkMRMLStorageNode.h"
19
20class vtkImageData;
21
26{
27public:
30 void PrintSelf(ostream& os, vtkIndent indent) override;
31
33
36 void ReadXMLAttributes(const char** atts) override;
37
40 void WriteXML(ostream& of, int indent) override;
41
44 void Copy(vtkMRMLNode* node) override;
45
48 const char* GetNodeTagName() override { return "VolumeHeaderlessStorage"; }
49
52 vtkGetStringMacro(FileScanOrder);
53 vtkSetStringMacro(FileScanOrder);
54
57 vtkGetVector3Macro(FileDimensions, int);
58 vtkSetVector3Macro(FileDimensions, int);
59
62 vtkGetVector3Macro(FileSpacing, double);
63 vtkSetVector3Macro(FileSpacing, double);
64
68 vtkSetMacro(FileScalarType, int);
69 vtkGetMacro(FileScalarType, int);
70
71 void SetFileScalarTypeToUnsignedChar() { this->SetFileScalarType(VTK_UNSIGNED_CHAR); };
72
73 void SetFileScalarTypeToChar() { this->SetFileScalarType(VTK_CHAR); };
74 void SetFileScalarTypeToShort() { this->SetFileScalarType(VTK_SHORT); };
75 void SetFileScalarTypeToUnsignedShort() { this->SetFileScalarType(VTK_UNSIGNED_SHORT); };
76 void SetFileScalarTypeToInt() { this->SetFileScalarType(VTK_INT); };
77 void SetFileScalarTypeToUnsignedInt() { this->SetFileScalarType(VTK_UNSIGNED_INT); };
78 void SetFileScalarTypeToLong() { this->SetFileScalarType(VTK_LONG); };
79 void SetFileScalarTypeToUnsignedLong() { this->SetFileScalarType(VTK_UNSIGNED_LONG); };
80 void SetFileScalarTypeToFloat() { this->SetFileScalarType(VTK_FLOAT); };
81 void SetFileScalarTypeToDouble() { this->SetFileScalarType(VTK_DOUBLE); };
82
84
85 void SetFileScalarTypeAsString(const char*);
86
92
97 vtkGetMacro(FileLittleEndian, int);
98 vtkSetMacro(FileLittleEndian, int);
99 vtkBooleanMacro(FileLittleEndian, int);
100
103 vtkGetMacro(CenterImage, int);
104 vtkSetMacro(CenterImage, int);
105
107 bool CanReadInReferenceNode(vtkMRMLNode* refNode) override;
108 bool CanWriteFromReferenceNode(vtkMRMLNode* refNode) override;
109
110protected:
115
118
120 int ReadDataInternal(vtkMRMLNode* refNode) override;
121
123 int WriteDataInternal(vtkMRMLNode* refNode) override;
124
129 double FileSpacing[3];
131
133};
134
135#endif
static vtkMRMLVolumeHeaderlessStorageNode * New()
void PrintSelf(ostream &os, vtkIndent indent) override
void operator=(const vtkMRMLVolumeHeaderlessStorageNode &)
vtkMRMLNode * CreateNodeInstance() override
Create instance of the default node. Like New only virtual.
void InitializeSupportedWriteFileTypes() override
Initialize all the supported write file types.
const char * GetNodeTagName() override
Get node XML tag name (like Storage, Model)
bool CanWriteFromReferenceNode(vtkMRMLNode *refNode) override
void ReadXMLAttributes(const char **atts) override
Read node attributes from XML file.
void WriteXML(ostream &of, int indent) override
Write this node's information to a MRML file in XML format.
int WriteDataInternal(vtkMRMLNode *refNode) override
Write data from a referenced node.
bool CanReadInReferenceNode(vtkMRMLNode *refNode) override
Return true if node can be read in.
void SetFileScalarTypeAsString(const char *)
vtkMRMLVolumeHeaderlessStorageNode(const vtkMRMLVolumeHeaderlessStorageNode &)
int ReadDataInternal(vtkMRMLNode *refNode) override
Read data and set it in the referenced node.
void Copy(vtkMRMLNode *node) override
Copy the node's attributes to this object.