Thea

Monochrome luminance value in [0, 1], with automatic scaling by 255 when switching between integer (ColorL8) and floating point (ColorL) formats. More...
#include <ColorL.hpp>
Public Types  
typedef Real  value_type 
The numerical type of the luminance value. More...  
Public Member Functions  
ColorL ()  
Default constructor, initializes color to 0. More...  
ColorL (Real v)  
Initializing constructor. More...  
ColorL (ColorL8 const &other)  
Initialize from an integer color, automatically dividing by 255. More...  
ColorL (ColorRgba const &other)  
Initialize from a 32bit RGBA color. More...  
Real const *  data () const 
Get the address of the color value. More...  
Real *  data () 
Get the address of the color value. More...  
void  fill (Real v) 
Set the luminance value, for consistency with multichannel colors. More...  
ColorL  max (ColorL const &other) const 
Get the maximum of two color values. More...  
ColorL  min (ColorL const &other) const 
Get the minimum of two color values. More...  
ColorL  operator* (ColorL const &other) const 
Multiplication operator. More...  
ColorL  operator* (Real other) const 
Multiply by a scalar. More...  
ColorL &  operator*= (ColorL const &other) 
Multiplyandassign. More...  
ColorL &  operator*= (Real other) 
Multiply by a scalar and assign. More...  
ColorL  operator+ (ColorL const &other) const 
Addition operator. More...  
ColorL &  operator+= (ColorL const &other) 
Addandassign. More...  
ColorL  operator () const 
Negation operator. More...  
ColorL  operator (ColorL const &other) const 
Subtraction operator. More...  
ColorL &  operator= (ColorL const &other) 
Subtractandassign. More...  
ColorL  operator/ (ColorL const &other) const 
Division operator. More...  
ColorL  operator/ (Real other) const 
Divide by a scalar. More...  
ColorL &  operator/= (ColorL const &other) 
Divideandassign. More...  
ColorL &  operator/= (Real other) 
Divide by a scalar and assign. More...  
template<typename IntegerT >  
Real const &  operator[] (IntegerT channel) const 
Arraystyle channel access. More...  
template<typename IntegerT >  
Real &  operator[] (IntegerT channel) 
Arraystyle channel access. More...  
std::string  toString () const 
Get a string representation of the color. More...  
Real  value () const 
The value of the color. More...  
Real &  value () 
The value of the color. More...  
Static Public Member Functions  
static ColorL const &  zero () 
Color with zero luminance (black). More...  
Monochrome luminance value in [0, 1], with automatic scaling by 255 when switching between integer (ColorL8) and floating point (ColorL) formats.
Derived from the G3D library: http://g3d.sourceforge.net
Definition at line 46 of file ColorL.hpp.
typedef Real value_type 
The numerical type of the luminance value.
Definition at line 52 of file ColorL.hpp.
ColorL  (  ) 
Default constructor, initializes color to 0.
Definition at line 55 of file ColorL.hpp.

explicit 
Initializing constructor.
Definition at line 58 of file ColorL.hpp.
Initialize from an integer color, automatically dividing by 255.
Definition at line 34 of file ColorL.cpp.
Initialize from a 32bit RGBA color.
For conversion from a consistent source type.
Definition at line 38 of file ColorL.cpp.
Real const* data  (  )  const 
Get the address of the color value.
Definition at line 73 of file ColorL.hpp.
Real* data  (  ) 
Get the address of the color value.
Definition at line 76 of file ColorL.hpp.
void fill  (  Real  v  ) 
Set the luminance value, for consistency with multichannel colors.
Definition at line 93 of file ColorL.hpp.
Get the maximum of two color values.
Definition at line 180 of file ColorL.hpp.
Get the minimum of two color values.
Definition at line 186 of file ColorL.hpp.
Multiplication operator.
Definition at line 114 of file ColorL.hpp.
ColorL operator*  (  Real  other  )  const 
Multiply by a scalar.
Definition at line 120 of file ColorL.hpp.
Multiplyandassign.
Definition at line 152 of file ColorL.hpp.
ColorL& operator*=  (  Real  other  ) 
Multiply by a scalar and assign.
Definition at line 166 of file ColorL.hpp.
Addition operator.
Definition at line 102 of file ColorL.hpp.
Addandassign.
Definition at line 138 of file ColorL.hpp.
ColorL operator  (  )  const 
Negation operator.
Definition at line 96 of file ColorL.hpp.
Subtraction operator.
Definition at line 108 of file ColorL.hpp.
Subtractandassign.
Definition at line 145 of file ColorL.hpp.
Division operator.
Definition at line 126 of file ColorL.hpp.
ColorL operator/  (  Real  other  )  const 
Divide by a scalar.
Definition at line 132 of file ColorL.hpp.
Divideandassign.
Definition at line 159 of file ColorL.hpp.
ColorL& operator/=  (  Real  other  ) 
Divide by a scalar and assign.
Definition at line 173 of file ColorL.hpp.
Real const& operator[]  (  IntegerT  channel  )  const 
Arraystyle channel access.
Definition at line 79 of file ColorL.hpp.
Real& operator[]  (  IntegerT  channel  ) 
Arraystyle channel access.
Definition at line 86 of file ColorL.hpp.
std::string toString  (  )  const 
Get a string representation of the color.
Definition at line 43 of file ColorL.cpp.
Real value  (  )  const 
The value of the color.
Definition at line 67 of file ColorL.hpp.
Real& value  (  ) 
The value of the color.
Definition at line 70 of file ColorL.hpp.

static 
Color with zero luminance (black).
Definition at line 192 of file ColorL.hpp.