57 template<
typename TComponent =
unsigned short >
72 itkStaticConstMacro(Length,
unsigned int, 3);
85 template<
typename TRGBPixelValueType >
91 template<
typename TRGBPixelValueType >
94 BaseArray::operator=(r);
99 Self & operator=(
const ComponentType r[3]);
106 const Self & operator+=(
const Self & vec);
108 const Self & operator-=(
const Self & vec);
110 Self
operator *(
const ComponentType & f)
const;
112 bool operator<(
const Self & vec)
const;
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) ) ) );
149 this->operator[](0) = red;
150 this->operator[](1) = green;
151 this->operator[](2) = blue;
165 LuminanceType GetLuminance()
const;
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
ConstNeighborhoodIterator< TImage > operator-(const ConstNeighborhoodIterator< TImage > &it, const typename ConstNeighborhoodIterator< TImage >::OffsetType &ind)
std::istream & operator>>(std::istream &is, Point< T, NPointDimension > &v)
RGBPixel(const ComponentType r[3])
CovariantVector< T, NVectorDimension > operator*(const T &scalar, const CovariantVector< T, NVectorDimension > &v)
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 SetNthComponent(int c, const ComponentType &v)
Simulate a standard C array with copy semnatics.
ConstNeighborhoodIterator< TImage > operator+(const ConstNeighborhoodIterator< TImage > &it, const typename ConstNeighborhoodIterator< TImage >::OffsetType &ind)
FixedArray< TComponent, 3 > Superclass
ComponentType GetScalarValue() const
const unsigned int Dimension
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
void SetGreen(ComponentType green)
static unsigned int GetNumberOfComponents()
bool ITKIOXML_EXPORT operator==(itk::FancyString &s, const std::string &)
void SetRed(ComponentType red)
void SetBlue(ComponentType blue)