vtkgdcm
vtkImageMapToColors16.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: GDCM (Grassroots DICOM). A DICOM library
4 
5  Copyright (c) 2006-2011 Mathieu Malaterre
6  All rights reserved.
7  See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details.
8 
9  This software is distributed WITHOUT ANY WARRANTY; without even
10  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11  PURPOSE. See the above copyright notice for more information.
12 
13 =========================================================================*/
14 /*=========================================================================
15 
16  Portions of this file are subject to the VTK Toolkit Version 3 copyright.
17 
18  Program: Visualization Toolkit
19  Module: $RCSfile: vtkImageMapToColors16.h,v $
20 
21  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
22  All rights reserved.
23  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
24 
25  This software is distributed WITHOUT ANY WARRANTY; without even
26  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
27  PURPOSE. See the above copyright notice for more information.
28 
29 =========================================================================*/
44 #ifndef VTKIMAGEMAPTOCOLORS16_H
45 #define VTKIMAGEMAPTOCOLORS16_H
46 
47 
48 #include "vtkThreadedImageAlgorithm.h"
49 
50 class vtkScalarsToColors;
51 
52 class VTK_EXPORT vtkImageMapToColors16 : public vtkThreadedImageAlgorithm
53 {
54 public:
56  vtkTypeMacro(vtkImageMapToColors16,vtkThreadedImageAlgorithm);
57  void PrintSelf(ostream& os, vtkIndent indent);
58 
60 
63  virtual void SetLookupTable(vtkScalarsToColors*);
64  vtkGetObjectMacro(LookupTable,vtkScalarsToColors);
66 
68 
71  vtkSetMacro(OutputFormat,int);
72  vtkGetMacro(OutputFormat,int);
73  void SetOutputFormatToRGBA() { this->OutputFormat = VTK_RGBA; };
74  void SetOutputFormatToRGB() { this->OutputFormat = VTK_RGB; };
75  void SetOutputFormatToLuminanceAlpha() { this->OutputFormat = VTK_LUMINANCE_ALPHA; };
76  void SetOutputFormatToLuminance() { this->OutputFormat = VTK_LUMINANCE; };
78 
80 
83  vtkSetMacro(ActiveComponent,int);
84  vtkGetMacro(ActiveComponent,int);
86 
88 
92  vtkSetMacro(PassAlphaToOutput,int);
93  vtkBooleanMacro(PassAlphaToOutput,int);
94  vtkGetMacro(PassAlphaToOutput,int);
96 
98 
101 #ifdef VTK_HAS_MTIME_TYPE
102  virtual vtkMTimeType GetMTime();
103 #else
104  virtual unsigned long GetMTime();
105 #endif
107 
108 protected:
111 
112  virtual int RequestInformation (vtkInformation *, vtkInformationVector **, vtkInformationVector *);
113 
114  void ThreadedRequestData(vtkInformation *request,
115  vtkInformationVector **inputVector,
116  vtkInformationVector *outputVector,
117  vtkImageData ***inData, vtkImageData **outData,
118  int extent[6], int id);
119 
120  virtual int RequestData(vtkInformation *request,
121  vtkInformationVector **inputVector,
122  vtkInformationVector *outputVector);
123 
124  vtkScalarsToColors *LookupTable;
126 
129 
131 private:
132  vtkImageMapToColors16(const vtkImageMapToColors16&); // Not implemented.
133  void operator=(const vtkImageMapToColors16&); // Not implemented.
134 };
135 
136 #endif
map the input image through a lookup table
void ThreadedRequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector, vtkImageData ***inData, vtkImageData **outData, int extent[6], int id)
virtual void SetLookupTable(vtkScalarsToColors *)
Set the lookup table.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
vtkScalarsToColors * LookupTable
virtual unsigned long GetMTime()
We need to check the modified time of the lookup table too.
virtual int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
void PrintSelf(ostream &os, vtkIndent indent)
static vtkImageMapToColors16 * New()