vtkImageMapToWindowLevelColors2.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkImageMapToWindowLevelColors2.h,v $
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 =========================================================================*/
00015 // .NAME vtkImageMapToWindowLevelColors2 - map the input image through a lookup table and window / level it
00016 // .SECTION Description
00017 // The vtkImageMapToWindowLevelColors2 filter will take an input image of any
00018 // valid scalar type, and map the first component of the image through a
00019 // lookup table.  This resulting color will be modulated with value obtained
00020 // by a window / level operation. The result is an image of type 
00021 // VTK_UNSIGNED_CHAR. If the lookup table is not set, or is set to NULL, then 
00022 // the input data will be passed through if it is already of type 
00023 // UNSIGNED_CHAR.
00024 //
00025 // .SECTION See Also
00026 // vtkLookupTable vtkScalarsToColors
00027 
00028 #ifndef VTKIMAGEMAPTOWINDOWLEVELCOLORS2_H
00029 #define VTKIMAGEMAPTOWINDOWLEVELCOLORS2_H
00030 
00031 #include "vtkImageMapToColors.h"
00032 
00033 class VTK_EXPORT vtkImageMapToWindowLevelColors2 : public vtkImageMapToColors
00034 {
00035 public:
00036   static vtkImageMapToWindowLevelColors2 *New();
00037   vtkTypeRevisionMacro(vtkImageMapToWindowLevelColors2,vtkImageMapToColors);
00038   void PrintSelf(ostream& os, vtkIndent indent);
00039 
00040   // Description:
00041   // Set / Get the Window to use -> modulation will be performed on the 
00042   // color based on (S - (L - W/2))/W where S is the scalar value, L is
00043   // the level and W is the window.
00044   vtkSetMacro( Window, double );
00045   vtkGetMacro( Window, double );
00046   
00047   // Description:
00048   // Set / Get the Level to use -> modulation will be performed on the 
00049   // color based on (S - (L - W/2))/W where S is the scalar value, L is
00050   // the level and W is the window.
00051   vtkSetMacro( Level, double );
00052   vtkGetMacro( Level, double );
00053   
00054 protected:
00055   vtkImageMapToWindowLevelColors2();
00056   ~vtkImageMapToWindowLevelColors2();
00057 
00058   virtual int RequestInformation (vtkInformation *, vtkInformationVector **, vtkInformationVector *);
00059   void ThreadedRequestData(vtkInformation *request,
00060                            vtkInformationVector **inputVector,
00061                            vtkInformationVector *outputVector,
00062                            vtkImageData ***inData, vtkImageData **outData,
00063                            int extent[6], int id);
00064   virtual int RequestData(vtkInformation *request,
00065                           vtkInformationVector **inputVector,
00066                           vtkInformationVector *outputVector);
00067 
00068   double Window;
00069   double Level;
00070   
00071 private:
00072   vtkImageMapToWindowLevelColors2(const vtkImageMapToWindowLevelColors2&);  // Not implemented.
00073   void operator=(const vtkImageMapToWindowLevelColors2&);  // Not implemented.
00074 };
00075 
00076 #endif
00077 
00078 
00079 
00080 
00081 
00082 
00083 

Generated on Sat Dec 4 2010 08:58:49 for GDCM by doxygen 1.7.2
SourceForge.net Logo