VTK  9.5.20251012
vtkBMPReader.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
83#ifndef vtkBMPReader_h
84#define vtkBMPReader_h
85
86#include "vtkIOImageModule.h" // For export macro
87#include "vtkImageReader.h"
88VTK_ABI_NAMESPACE_BEGIN
89class vtkLookupTable;
90
91class VTKIOIMAGE_EXPORT vtkBMPReader : public vtkImageReader
92{
93public:
94 static vtkBMPReader* New();
96
97 void PrintSelf(ostream& os, vtkIndent indent) override;
98
100
103 vtkGetMacro(Depth, int);
105
109 int CanReadFile(VTK_FILEPATH const char* fname) override;
110
116 const char* GetFileExtensions() override { return ".bmp"; }
117
121 const char* GetDescriptiveName() override { return "Windows BMP"; }
122
124
129 vtkSetMacro(Allow8BitBMP, vtkTypeBool);
130 vtkGetMacro(Allow8BitBMP, vtkTypeBool);
131 vtkBooleanMacro(Allow8BitBMP, vtkTypeBool);
133
134 vtkGetObjectMacro(LookupTable, vtkLookupTable);
135
137
140 vtkGetMacro(Colors, unsigned char*);
142
143protected:
145 ~vtkBMPReader() override;
146
147 unsigned char* Colors;
148 short Depth;
151
152 void ComputeDataIncrements() override;
153 void ExecuteInformation() override;
155
156private:
157 vtkBMPReader(const vtkBMPReader&) = delete;
158 void operator=(const vtkBMPReader&) = delete;
159};
160VTK_ABI_NAMESPACE_END
161#endif
read Windows BMP files
int CanReadFile(const char *fname) override
Is the given file a BMP file?
const char * GetDescriptiveName() override
Return a descriptive name for the file format that might be useful in a GUI.
const char * GetFileExtensions() override
Get the file extensions for this format.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void ExecuteDataWithInformation(vtkDataObject *out, vtkInformation *outInfo) override
This is a convenience method that is implemented in many subclasses instead of RequestData.
void ExecuteInformation() override
~vtkBMPReader() override
void ComputeDataIncrements() override
static vtkBMPReader * New()
vtkLookupTable * LookupTable
unsigned char * Colors
vtkTypeBool Allow8BitBMP
general representation of visualization data
Superclass of transformable binary file readers.
a simple class to control print indentation
Definition vtkIndent.h:108
Store vtkAlgorithm input/output information.
map scalar values into colors via a lookup table
int vtkTypeBool
Definition vtkABI.h:64
#define VTK_FILEPATH