Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itkScalarToRGBPixelFunctor.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkScalarToRGBPixelFunctor.h,v $
00005   Language:  C++
00006   Date:      $Date: 2003/01/31 23:57:40 $
00007   Version:   $Revision: 1.2 $
00008 
00009   Copyright (c) 2002 Insight Consortium. All rights reserved.
00010   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
00011 
00012      This software is distributed WITHOUT ANY WARRANTY; without even 
00013      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00014      PURPOSE.  See the above copyright notices for more information.
00015 
00016 =========================================================================*/
00017 #ifndef _itkScalarToRGBPixelFunctor_h
00018 #define _itkScalarToRGBPixelFunctor_h
00019 
00020 #include "itkRGBPixel.h"
00021 
00022 namespace itk {
00023 
00024 namespace Functor {  
00025 
00041 template< class TScalar >
00042 class ScalarToRGBPixelFunctor
00043 {
00044 public:
00045   ScalarToRGBPixelFunctor();
00046   ~ScalarToRGBPixelFunctor() {};
00047 
00048   typedef unsigned char               RGBComponentType;
00049   typedef RGBPixel<RGBComponentType>  RGBPixelType;
00050   typedef TScalar                     ScalarType;
00051   
00052   RGBPixelType operator()( const TScalar &) const;
00053 
00054   void SetLittleEndian()
00055   {
00056     m_IsBigEndian = false;
00057   }
00058   void SetBigEndian()
00059   {
00060     m_IsBigEndian = true;
00061   }
00062   
00063 private:
00064   bool m_IsBigEndian;
00065   ::size_t m_Index[3];
00066   
00067 };
00068   
00069 } // end namespace functor
00070 
00071 } // end namespace itk
00072 
00073 #ifndef ITK_MANUAL_INSTANTIATION
00074 #include "itkScalarToRGBPixelFunctor.txx"
00075 #endif
00076 
00077 #endif

Generated at Fri May 21 01:15:17 2004 for ITK by doxygen 1.2.15 written by Dimitri van Heesch, © 1997-2000