Milena (Olena)  User documentation 2.0a Id
 All Classes Namespaces Functions Variables Typedefs Enumerator Groups Pages
mln::value::rgb< n > Struct Template Reference

Color class for red-green-blue where every component is n-bit encoded. More...

#include <rgb.hh>

Inherits mln::value::Vectorial< E >, and mln::value::internal::value_like_< V, C, N, E >.

Public Member Functions

rgb< n > & operator= (const rgb< n > &rhs)
 Assignment.
 
 rgb ()
 Constructor without argument.
 
 rgb (int r, int g, int b)
 Constructor from component values.
 
 rgb (const algebra::vec< 3, int > &rhs)
 Constructor from a algebra::vec.
 
int_u< n > red () const
 Acces to red/green/blue component.
 
 rgb (const mln::literal::white_t &)
 Constructors with literals.
 

Static Public Attributes

static const rgb< n > zero
 Zero value.
 

Detailed Description

template<unsigned n>
struct mln::value::rgb< n >

Color class for red-green-blue where every component is n-bit encoded.

Definition at line 248 of file value/rgb.hh.

Constructor & Destructor Documentation

template<unsigned n>
rgb< n >::rgb ( )
inline

Constructor without argument.

Definition at line 422 of file value/rgb.hh.

template<unsigned n>
rgb< n >::rgb ( int  r,
int  g,
int  b 
)
inline

Constructor from component values.

Definition at line 458 of file value/rgb.hh.

template<unsigned n>
rgb< n >::rgb ( const algebra::vec< 3, int > &  rhs)
inline

Constructor from a algebra::vec.

Definition at line 428 of file value/rgb.hh.

template<unsigned n>
rgb< n >::rgb ( const mln::literal::white_t )
inline

Constructors with literals.

Definition at line 473 of file value/rgb.hh.

Member Function Documentation

template<unsigned n>
rgb< n > & rgb< n >::operator= ( const rgb< n > &  rhs)
inline

Assignment.

Definition at line 645 of file value/rgb.hh.

template<unsigned n>
int_u<n> mln::value::rgb< n >::red ( ) const
inline

Acces to red/green/blue component.

Definition at line 264 of file value/rgb.hh.

Referenced by mln::fun::v2v::rgb8_to_rgbn< n >::operator()().

Member Data Documentation

template<unsigned n>
const rgb< n > rgb< n >::zero
static

Zero value.

Definition at line 322 of file value/rgb.hh.