Public Types | Public Member Functions

mln::fun::v2v::rgb8_to_rgbn< n > Struct Template Reference

Convert a rgb8 value to a rgn, n < 8. More...

#include <rgb8_to_rgbn.hh>

Inheritance diagram for mln::fun::v2v::rgb8_to_rgbn< n >:
Inheritance graph

List of all members.

Public Types

typedef value::rgb8 argument
typedef Function_v2v< void > category
typedef rgb8_to_rgbn< n > exact_t
typedef void mutable_result
typedef value::rgb< n > result

Public Member Functions

result operator() (const argument &c) const
 Convert a rgb8 value to a rgn, n < 8.

Detailed Description

template<unsigned n>
struct mln::fun::v2v::rgb8_to_rgbn< n >

Convert a rgb8 value to a rgn, n < 8.

Parameters:
n defines the output quantification used for the transformation.

Definition at line 56 of file rgb8_to_rgbn.hh.


Member Typedef Documentation

template<unsigned n>
typedef value::rgb8 mln::fun::v2v::rgb8_to_rgbn< n >::argument

Definition at line 58 of file rgb8_to_rgbn.hh.

typedef Function_v2v<void> mln::Function_v2v< rgb8_to_rgbn< n > >::category [inherited]

Reimplemented from mln::Function< rgb8_to_rgbn< n > >.

Definition at line 126 of file function.hh.

typedef rgb8_to_rgbn< n > mln::Object< rgb8_to_rgbn< n > >::exact_t [inherited]

Definition at line 173 of file object.hh.

typedef void mln::Function_v2v< rgb8_to_rgbn< n > >::mutable_result [inherited]

Definition at line 127 of file function.hh.

template<unsigned n>
typedef value::rgb<n> mln::fun::v2v::rgb8_to_rgbn< n >::result

Definition at line 59 of file rgb8_to_rgbn.hh.


Member Function Documentation

template<unsigned n>
rgb8_to_rgbn< n >::result mln::fun::v2v::rgb8_to_rgbn< n >::operator() ( const argument c  )  const

Convert a rgb8 value to a rgn, n < 8.

Parameters:
[in] v the rgb8 value to convert.

Conversion is done by computing the size by which we divide each rgb component.

Parameters:
n defines the output quantification used for the transformation.

Definition at line 83 of file rgb8_to_rgbn.hh.

References mln::value::rgb< n >::blue(), mln::value::rgb< n >::green(), and mln::value::rgb< n >::red().