VTK
vtkPNrrdReader.h
Go to the documentation of this file.
1 // -*- c++ -*-
2 /*=========================================================================
3 
4  Program: Visualization Toolkit
5  Module: vtkPNrrdReader.h
6 
7  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
8  All rights reserved.
9  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
10 
11  This software is distributed WITHOUT ANY WARRANTY; without even
12  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
13  PURPOSE. See the above copyright notice for more information.
14 
15 =========================================================================*/
16 /*----------------------------------------------------------------------------
17  Copyright (c) Sandia Corporation
18  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
19 ----------------------------------------------------------------------------*/
20 
42 #ifndef vtkPNrrdReader_h
43 #define vtkPNrrdReader_h
44 
45 #include "vtkIOMPIImageModule.h" // For export macro
46 #include "vtkNrrdReader.h"
47 
48 class vtkCharArray;
50 class vtkMPIOpaqueFileHandle;
51 
53 {
54 public:
55  vtkTypeMacro(vtkPNrrdReader, vtkNrrdReader);
56  static vtkPNrrdReader *New();
57  virtual void PrintSelf(ostream &os, vtkIndent indent);
58 
60 
62  vtkGetObjectMacro(Controller, vtkMultiProcessController);
63  virtual void SetController(vtkMultiProcessController *);
65 
66 protected:
68  ~vtkPNrrdReader();
69 
70  virtual int ReadHeader();
71  virtual int ReadHeader(vtkCharArray *headerBuffer);
72 
75  int GetDataScalarTypeSize();
76 
81  virtual void PartitionController(const int extent[6]);
82 
85  virtual unsigned long GetHeaderSize(vtkMPIOpaqueFileHandle &file);
86 
91  virtual void SetupFileView(vtkMPIOpaqueFileHandle &file, const int extent[6]);
92 
97  virtual void ReadSlice(int slice, const int extent[6], void *buffer);
98 
101  virtual void TransformData(vtkImageData *data);
102 
104 
106  void SetGroupedController(vtkMultiProcessController *);
109 
111  vtkInformation *outInfo);
112 
114 
115 private:
116  vtkPNrrdReader(const vtkPNrrdReader &); // Not implemented.
117  void operator=(const vtkPNrrdReader &); // Not implemented.
118 };
119 
120 #endif //vtkPNrrdReader_h
Read nrrd files efficiently from parallel file systems (and reasonably well elsewhere).
Store vtkAlgorithm input/output information.
vtkMultiProcessController * GroupedController
unsigned long GetHeaderSize()
#define VTKIOMPIIMAGE_EXPORT
dynamic, self-adjusting array of char
Definition: vtkCharArray.h:42
a simple class to control print indentation
Definition: vtkIndent.h:38
void ExecuteDataWithInformation(vtkDataObject *data, vtkInformation *outInfo)
topologically and geometrically regular array of data
Definition: vtkImageData.h:44
vtkMultiProcessController * Controller
Read nrrd files file system.
Definition: vtkNrrdReader.h:49
virtual int ReadHeader()
static vtkNrrdReader * New()
virtual void PrintSelf(ostream &os, vtkIndent indent)
general representation of visualization data
Definition: vtkDataObject.h:64
Multiprocessing communication superclass.