VTK
vtkSLCReader.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkSLCReader.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 =========================================================================*/
15 
28 #ifndef vtkSLCReader_h
29 #define vtkSLCReader_h
30 
31 #include "vtkIOImageModule.h" // For export macro
32 #include "vtkImageReader2.h"
33 
34 class VTKIOIMAGE_EXPORT vtkSLCReader : public vtkImageReader2
35 {
36 public:
37  static vtkSLCReader *New();
39  void PrintSelf(ostream& os, vtkIndent indent) override;
40 
42 
45  vtkGetMacro(Error,int);
47 
51  int CanReadFile(const char* fname) override;
55  const char* GetFileExtensions() override
56  {
57  return ".slc";
58  }
59 
63  const char* GetDescriptiveName() override
64  {
65  return "SLC";
66  }
67 
68 protected:
70  ~vtkSLCReader() override;
71 
72  // Reads the file name and builds a vtkStructuredPoints dataset.
74 
76  vtkInformationVector** inputVector,
77  vtkInformationVector* outputVector) override;
78 
79  // Decodes an array of eight bit run-length encoded data.
80  unsigned char *Decode8BitData( unsigned char *in_ptr, int size );
81  int Error;
82 private:
83  vtkSLCReader(const vtkSLCReader&) = delete;
84  void operator=(const vtkSLCReader&) = delete;
85 };
86 
87 #endif
88 
89 
vtkSLCReader::New
static vtkSLCReader * New()
vtkSLCReader::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkSLCReader::ExecuteDataWithInformation
void ExecuteDataWithInformation(vtkDataObject *, vtkInformation *) override
This is a convenience method that is implemented in many subclasses instead of RequestData.
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:42
vtkSLCReader::RequestInformation
int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
Subclasses can reimplement this method to collect information from their inputs and set information f...
vtkSLCReader::GetFileExtensions
const char * GetFileExtensions() override
.slc
Definition: vtkSLCReader.h:55
vtkSLCReader::~vtkSLCReader
~vtkSLCReader() override
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:40
vtkX3D::size
@ size
Definition: vtkX3D.h:253
vtkImageReader2
Superclass of binary file readers.
Definition: vtkImageReader2.h:59
vtkSLCReader::vtkSLCReader
vtkSLCReader()
vtkSLCReader::Error
int Error
Definition: vtkSLCReader.h:81
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:87
vtkSLCReader
read an SLC volume file.
Definition: vtkSLCReader.h:35
vtkSLCReader::GetDescriptiveName
const char * GetDescriptiveName() override
SLC.
Definition: vtkSLCReader.h:63
vtkSLCReader::CanReadFile
int CanReadFile(const char *fname) override
Is the given file an SLC file?
vtkDataObject
general representation of visualization data
Definition: vtkDataObject.h:65
vtkImageReader2.h
vtkSLCReader::Decode8BitData
unsigned char * Decode8BitData(unsigned char *in_ptr, int size)