VTK
dox/Imaging/Color/vtkImageRGBToHSV.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkImageRGBToHSV.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 =========================================================================*/
00026 #ifndef __vtkImageRGBToHSV_h
00027 #define __vtkImageRGBToHSV_h
00028 
00029 
00030 #include "vtkImagingColorModule.h" // For export macro
00031 #include "vtkThreadedImageAlgorithm.h"
00032 
00033 class VTKIMAGINGCOLOR_EXPORT vtkImageRGBToHSV : public vtkThreadedImageAlgorithm
00034 {
00035 public:
00036   static vtkImageRGBToHSV *New();
00037   vtkTypeMacro(vtkImageRGBToHSV,vtkThreadedImageAlgorithm);
00038   void PrintSelf(ostream& os, vtkIndent indent);
00039 
00040 
00041   // Hue is an angle. Maximum specifies when it maps back to 0.  HueMaximum
00042   // defaults to 255 instead of 2PI, because unsigned char is expected as
00043   // input.  Maximum also specifies the maximum of the Saturation.
00044   vtkSetMacro(Maximum,double);
00045   vtkGetMacro(Maximum,double);
00046 
00047 protected:
00048   vtkImageRGBToHSV();
00049   ~vtkImageRGBToHSV() {}
00050 
00051   double Maximum;
00052 
00053   void ThreadedExecute (vtkImageData *inData, vtkImageData *outData,
00054                        int ext[6], int id);
00055 private:
00056   vtkImageRGBToHSV(const vtkImageRGBToHSV&);  // Not implemented.
00057   void operator=(const vtkImageRGBToHSV&);  // Not implemented.
00058 };
00059 
00060 #endif
00061 
00062 
00063