1 // -------------------------------------------------------------------------
2 // @author Leonardo Florez-Valencia (florez-l@javeriana.edu.co)
3 // -------------------------------------------------------------------------
5 #ifndef __CPPLUGINS__EXTENSIONS__ALGORITHMS__RGBEXTRACTFUNCTION__H__
6 #define __CPPLUGINS__EXTENSIONS__ALGORITHMS__RGBEXTRACTFUNCTION__H__
10 #include <vnl/vnl_math.h>
12 #include <itkRGBPixel.h>
13 #include <itkVector.h>
24 struct RGBExtractFunction
26 typedef RGBExtractFunction Self;
27 typedef itk::Vector< O, 3 > TOutPixel;
29 template< class Tr, class Tg, class Tb >
30 TOutPixel operator()( const Tr& r, const Tg& g, const Tb& b ) const
40 TOutPixel operator()( const itk::RGBPixel< C >& rgb ) const
44 rgb.GetRed( ), rgb.GetGreen( ), rgb.GetBlue( )
56 #endif // __CPPLUGINS__EXTENSIONS__ALGORITHMS__RGBEXTRACTFUNCTION__H__