VTK  9.2.5
vtkNrrdReader.h
Go to the documentation of this file.
1// -*- c++ -*-
2/*=========================================================================
3
4 Program: Visualization Toolkit
5 Module: vtkNrrdReader.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 vtkNrrdReader_h
43#define vtkNrrdReader_h
44
45#include "vtkIOImageModule.h" // For export macro
46#include "vtkImageReader.h"
47
48class vtkCharArray;
49
50class VTKIOIMAGE_EXPORT vtkNrrdReader : public vtkImageReader
51{
52public:
54 static vtkNrrdReader* New();
55 void PrintSelf(ostream& os, vtkIndent indent) override;
56
57 int CanReadFile(VTK_FILEPATH const char* filename) override;
58
59protected:
61 ~vtkNrrdReader() override;
62
64 vtkInformationVector* outputVector) override;
65
66 int RequestData(vtkInformation* request, vtkInformationVector** inputVector,
67 vtkInformationVector* outputVector) override;
68
69 int ReadHeaderInternal(vtkCharArray* headerBuffer);
70 virtual int ReadHeader();
71 virtual int ReadHeader(vtkCharArray* headerBuffer);
72
73 virtual int ReadDataAscii(vtkImageData* output);
74
75 template <typename T>
77 virtual int ReadDataGZip(vtkImageData* output);
78
80
81 enum
82 {
85 ENCODING_GZIP
86 };
87
89
90private:
91 vtkNrrdReader(const vtkNrrdReader&) = delete;
92 void operator=(const vtkNrrdReader&) = delete;
93};
94
95#endif // vtkNrrdReader_h
dynamic, self-adjusting array of char
Definition: vtkCharArray.h:52
topologically and geometrically regular array of data
Definition: vtkImageData.h:54
Superclass of transformable binary file readers.
a simple class to control print indentation
Definition: vtkIndent.h:40
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Read nrrd files file system.
Definition: vtkNrrdReader.h:51
virtual int ReadDataAscii(vtkImageData *output)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkStringArray * DataFiles
Definition: vtkNrrdReader.h:79
int ReadHeaderInternal(vtkCharArray *headerBuffer)
static vtkNrrdReader * New()
~vtkNrrdReader() override
int CanReadFile(VTK_FILEPATH const char *filename) override
int vtkNrrdReaderReadDataGZipTemplate(vtkImageData *output, T *outBuffer)
virtual int ReadDataGZip(vtkImageData *output)
int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
Subclasses can reimplement this method to collect information from their inputs and set information f...
int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
This is called in response to a REQUEST_DATA request from the executive.
virtual int ReadHeader(vtkCharArray *headerBuffer)
virtual int ReadHeader()
a vtkAbstractArray subclass for strings
#define VTK_FILEPATH