VTK
vtkImageMapToColors.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkImageMapToColors.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=========================================================================*/
35#ifndef vtkImageMapToColors_h
36#define vtkImageMapToColors_h
37
38
39#include "vtkImagingCoreModule.h" // For export macro
41
43
44class VTKIMAGINGCORE_EXPORT vtkImageMapToColors : public vtkThreadedImageAlgorithm
45{
46public:
49 void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
50
52
56 vtkGetObjectMacro(LookupTable,vtkScalarsToColors);
58
60
63 vtkSetMacro(OutputFormat,int);
64 vtkGetMacro(OutputFormat,int);
65 void SetOutputFormatToRGBA() { this->OutputFormat = VTK_RGBA; };
66 void SetOutputFormatToRGB() { this->OutputFormat = VTK_RGB; };
67 void SetOutputFormatToLuminanceAlpha() { this->OutputFormat = VTK_LUMINANCE_ALPHA; };
68 void SetOutputFormatToLuminance() { this->OutputFormat = VTK_LUMINANCE; };
70
72
75 vtkSetMacro(ActiveComponent,int);
76 vtkGetMacro(ActiveComponent,int);
78
80
84 vtkSetMacro(PassAlphaToOutput,int);
85 vtkBooleanMacro(PassAlphaToOutput,int);
86 vtkGetMacro(PassAlphaToOutput,int);
88
92 virtual vtkMTimeType GetMTime() VTK_OVERRIDE;
93
95
99 vtkSetVector4Macro(NaNColor, unsigned char);
100 vtkGetVector4Macro(NaNColor, unsigned char);
102
103protected:
106
107 virtual int RequestInformation(vtkInformation *,
109 vtkInformationVector *) VTK_OVERRIDE;
110
111 void ThreadedRequestData(vtkInformation *request,
112 vtkInformationVector **inputVector,
113 vtkInformationVector *outputVector,
114 vtkImageData ***inData, vtkImageData **outData,
115 int extent[6], int id) VTK_OVERRIDE;
116
117 virtual int RequestData(vtkInformation *request,
118 vtkInformationVector **inputVector,
119 vtkInformationVector *outputVector) VTK_OVERRIDE;
120
121 vtkScalarsToColors *LookupTable;
122 int OutputFormat;
123
124 int ActiveComponent;
125 int PassAlphaToOutput;
126
127 int DataWasPassed;
128
129 unsigned char NaNColor[4];
130private:
131 vtkImageMapToColors(const vtkImageMapToColors&) VTK_DELETE_FUNCTION;
132 void operator=(const vtkImageMapToColors&) VTK_DELETE_FUNCTION;
133};
134
135#endif
136
137
138
139
140
141
142
topologically and geometrically regular array of data
Definition: vtkImageData.h:46
map the input image through a lookup table
virtual vtkMTimeType GetMTime() override
We need to check the modified time of the lookup table too.
static vtkImageMapToColors * New()
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual void SetLookupTable(vtkScalarsToColors *)
Set the lookup table.
a simple class to control print indentation
Definition: vtkIndent.h:40
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for mapping scalar values to colors.
Generic filter that has one input.
@ extent
Definition: vtkX3D.h:345
vtkSetMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkBooleanMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
#define VTK_LUMINANCE_ALPHA
#define VTK_RGBA
#define VTK_RGB
#define VTK_LUMINANCE
vtkTypeUInt64 vtkMTimeType
Definition: vtkType.h:248