18 #ifndef __itkRGBAPixel_h
19 #define __itkRGBAPixel_h
28 #include "vnl/vnl_math.h"
58 template<
typename TComponent =
unsigned short >
70 itkStaticConstMacro(
Length,
unsigned int, 4);
85 template<
class TRGBAPixelValueType >
118 static_cast< double >( this->
operator[](0) )
119 * static_cast< double >( this->
operator[](0) )
120 + static_cast< double >( this->
operator[](1) )
121 * static_cast< double >( this->
operator[](1) )
122 + static_cast< double >( this->
operator[](2) )
123 * static_cast< double >( this->
operator[](2) ) ) );
167 template<
typename TComponent >
168 ITK_EXPORT std::ostream &
operator<<(std::ostream & os,
169 const RGBAPixel< TComponent > & c);
171 template<
typename TComponent >
172 ITK_EXPORT std::istream &
operator>>(std::istream & is,
173 RGBAPixel< TComponent > & c);
177 #define ITK_TEMPLATE_RGBAPixel(_, EXPORT, TypeX, TypeY) \
180 _( 1 ( class EXPORT RGBAPixel< ITK_TEMPLATE_1 TypeX > ) ) \
181 namespace Templates \
183 typedef RGBAPixel< ITK_TEMPLATE_1 TypeX > RGBAPixel##TypeY; \
187 #if ITK_TEMPLATE_EXPLICIT
188 #include "Templates/itkRGBAPixel+-.h"
202 #include "itkRGBAPixel.hxx"