28 #include "vnl/vnl_math.h"
57 template<
typename TComponent =
unsigned short >
72 itkStaticConstMacro(
Length,
unsigned int, 3);
85 template<
typename TRGBPixelValueType >
91 template<
typename TRGBPixelValueType >
126 static_cast< double >( this->
operator[](0) )
127 * static_cast< double >( this->
operator[](0) )
128 + static_cast< double >( this->
operator[](1) )
129 * static_cast< double >( this->
operator[](1) )
130 + static_cast< double >( this->
operator[](2) )
131 * static_cast< double >( this->
operator[](2) ) ) );
168 template<
typename TComponent >
170 const RGBPixel< TComponent > & c);
172 template<
typename TComponent >
174 RGBPixel< TComponent > & c);
188 #ifndef ITK_MANUAL_INSTANTIATION
189 #include "itkRGBPixel.hxx"
const ComponentType & GetBlue(void) const
FixedArray< TComponent, 3 > BaseArray
reference operator[](short index)
std::istream & operator>>(std::istream &is, Point< T, NPointDimension > &v)
const Self & operator+=(const Self &vec)
RGBPixel(const ComponentType r[3])
const ComponentType & GetGreen(void) const
std::ostream & operator<<(std::ostream &os, const Array< TValue > &arr)
NumericTraits< ComponentType >::RealType LuminanceType
void Set(ComponentType red, ComponentType green, ComponentType blue)
RGBPixel(const RGBPixel< TRGBPixelValueType > &r)
void Fill(const ValueType &)
void SetNthComponent(int c, const ComponentType &v)
Self operator-(const Self &vec) const
Simulate a standard C array with copy semnatics.
LuminanceType GetLuminance() const
const Self & operator-=(const Self &vec)
bool operator==(const Self &vec) const
static const unsigned int Dimension
FixedArray< TComponent, 3 > Superclass
ComponentType GetScalarValue() const
static const unsigned int Length
Self operator*(const ComponentType &f) const
FixedArray & operator=(const FixedArray< TFixedArrayValueType, VLength > &r)
Self operator+(const Self &vec) const
RGBPixel(const ComponentType &r)
Represent Red, Green and Blue components for color images.
Self & operator=(const RGBPixel< TRGBPixelValueType > &r)
ComponentType GetNthComponent(int c) const
const ComponentType & GetRed(void) const
bool operator<(const Self &vec) const
void SetGreen(ComponentType green)
static unsigned int GetNumberOfComponents()
void SetRed(ComponentType red)
void SetBlue(ComponentType blue)