ntg::color< ncomps, qbits, color_system > Struct Template Reference

Generic type for color. More...

#include <color.hh>

Inheritance diagram for ntg::color< ncomps, qbits, color_system >:

Inheritance graph
[legend]
Collaboration diagram for ntg::color< ncomps, qbits, color_system >:

Collaboration graph
[legend]
List of all members.

Public Types

typedef int_u< qbits > comp_type
typedef vec< ncomps, comp_type > vec_type
typedef vec< ncomps, float > float_vec_type

Public Member Functions

 color (const vec_type &vec)
 color (const float_vec_type &vec)
 color (const comp_type &c1, const comp_type &c2, const comp_type &c3)
vec_type & as_vec ()
const vec_type & as_vec () const
float_vec_type to_float () const
bool operator== (const color &r) const

Detailed Description

template<unsigned ncomps, unsigned qbits, template< unsigned > class color_system>
struct ntg::color< ncomps, qbits, color_system >

Generic type for color.

Specific color types (such as rgb, xyz, etc.) are defined by specifying ncomps, qbits and a color_system trait.

ncomps: number of components. qbits: number of bits of each unsigned integer component. color_system: traits defining the intervals of each component.

Colors are implemented and seen as a vector of components.

Definition at line 182 of file color/color.hh.


The documentation for this struct was generated from the following file:
Generated on Thu Apr 15 20:13:45 2004 for Olena by doxygen 1.3.6-20040222