VTK
/Users/kitware/Dashboards/MyTests/VTK_BLD_Release_docs/Utilities/Doxygen/dox/Imaging/Core/vtkImageMapToColors.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkImageMapToColors.h
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00034 #ifndef vtkImageMapToColors_h
00035 #define vtkImageMapToColors_h
00036 
00037 
00038 #include "vtkImagingCoreModule.h" // For export macro
00039 #include "vtkThreadedImageAlgorithm.h"
00040 
00041 class vtkScalarsToColors;
00042 
00043 class VTKIMAGINGCORE_EXPORT vtkImageMapToColors : public vtkThreadedImageAlgorithm
00044 {
00045 public:
00046   static vtkImageMapToColors *New();
00047   vtkTypeMacro(vtkImageMapToColors,vtkThreadedImageAlgorithm);
00048   void PrintSelf(ostream& os, vtkIndent indent);
00049 
00051 
00052   virtual void SetLookupTable(vtkScalarsToColors*);
00053   vtkGetObjectMacro(LookupTable,vtkScalarsToColors);
00055 
00057 
00058   vtkSetMacro(OutputFormat,int);
00059   vtkGetMacro(OutputFormat,int);
00060   void SetOutputFormatToRGBA() { this->OutputFormat = VTK_RGBA; };
00061   void SetOutputFormatToRGB() { this->OutputFormat = VTK_RGB; };
00062   void SetOutputFormatToLuminanceAlpha() { this->OutputFormat = VTK_LUMINANCE_ALPHA; };
00063   void SetOutputFormatToLuminance() { this->OutputFormat = VTK_LUMINANCE; };
00065 
00067 
00068   vtkSetMacro(ActiveComponent,int);
00069   vtkGetMacro(ActiveComponent,int);
00071 
00073 
00076   vtkSetMacro(PassAlphaToOutput,int);
00077   vtkBooleanMacro(PassAlphaToOutput,int);
00078   vtkGetMacro(PassAlphaToOutput,int);
00080 
00082   virtual unsigned long GetMTime();
00083 
00085 
00086   vtkSetVector4Macro(NaNColor, unsigned char);
00087   vtkGetVector4Macro(NaNColor, unsigned char);
00089 
00090 protected:
00091   vtkImageMapToColors();
00092   ~vtkImageMapToColors();
00093 
00094   virtual int RequestInformation (vtkInformation *, vtkInformationVector **, vtkInformationVector *);
00095 
00096   void ThreadedRequestData(vtkInformation *request,
00097                            vtkInformationVector **inputVector,
00098                            vtkInformationVector *outputVector,
00099                            vtkImageData ***inData, vtkImageData **outData,
00100                            int extent[6], int id);
00101 
00102   virtual int RequestData(vtkInformation *request,
00103                           vtkInformationVector **inputVector,
00104                           vtkInformationVector *outputVector);
00105 
00106   vtkScalarsToColors *LookupTable;
00107   int OutputFormat;
00108 
00109   int ActiveComponent;
00110   int PassAlphaToOutput;
00111 
00112   int DataWasPassed;
00113 
00114   unsigned char NaNColor[4];
00115 private:
00116   vtkImageMapToColors(const vtkImageMapToColors&);  // Not implemented.
00117   void operator=(const vtkImageMapToColors&);  // Not implemented.
00118 };
00119 
00120 #endif
00121 
00122 
00123 
00124 
00125 
00126 
00127