VTK
vtkImageReader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageReader.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
32 #ifndef vtkImageReader_h
33 #define vtkImageReader_h
34 
35 #include "vtkIOImageModule.h" // For export macro
36 #include "vtkImageReader2.h"
37 
38 class vtkTransform;
39 
40 #define VTK_FILE_BYTE_ORDER_BIG_ENDIAN 0
41 #define VTK_FILE_BYTE_ORDER_LITTLE_ENDIAN 1
42 
44 {
45 public:
46  static vtkImageReader *New();
48  void PrintSelf(ostream& os, vtkIndent indent);
49 
51 
53  vtkSetVector6Macro(DataVOI,int);
54  vtkGetVector6Macro(DataVOI,int);
56 
58 
64  vtkGetMacro(DataMask, vtkTypeUInt64);
65  vtkSetMacro(DataMask, vtkTypeUInt64);
67 
69 
72  virtual void SetTransform(vtkTransform*);
73  vtkGetObjectMacro(Transform,vtkTransform);
75 
76  // Warning !!!
77  // following should only be used by methods or template helpers, not users
78  void ComputeInverseTransformedExtent(int inExtent[6],
79  int outExtent[6]);
80  void ComputeInverseTransformedIncrements(vtkIdType inIncr[3],
81  vtkIdType outIncr[3]);
82 
83  int OpenAndSeekFile(int extent[6], int slice);
84 
86 
87  vtkSetStringMacro(ScalarArrayName);
88  vtkGetStringMacro(ScalarArrayName);
90 
91 protected:
93  ~vtkImageReader();
94 
95  vtkTypeUInt64 DataMask;
96 
98 
99  void ComputeTransformedSpacing (double Spacing[3]);
100  void ComputeTransformedOrigin (double origin[3]);
101  void ComputeTransformedExtent(int inExtent[6],
102  int outExtent[6]);
103  void ComputeTransformedIncrements(vtkIdType inIncr[3],
104  vtkIdType outIncr[3]);
105 
106  int DataVOI[6];
107 
109 
110  virtual int RequestInformation(vtkInformation* request,
111  vtkInformationVector** inputVector,
112  vtkInformationVector* outputVector);
113 
115 private:
116  vtkImageReader(const vtkImageReader&); // Not implemented.
117  void operator=(const vtkImageReader&); // Not implemented.
118 };
119 
120 #endif
static vtkImageReader2 * New()
Store vtkAlgorithm input/output information.
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
describes linear transformations via a 4x4 matrix
Definition: vtkTransform.h:59
int vtkIdType
Definition: vtkType.h:275
vtkTypeUInt64 DataMask
a simple class to control print indentation
Definition: vtkIndent.h:38
Superclass of transformable binary file readers.
vtkTransform * Transform
Superclass of binary file readers.
void PrintSelf(ostream &os, vtkIndent indent)
Store zero or more vtkInformation instances.
char * ScalarArrayName
#define VTKIOIMAGE_EXPORT
virtual void ExecuteDataWithInformation(vtkDataObject *data, vtkInformation *outInfo)
general representation of visualization data
Definition: vtkDataObject.h:64