Main Page   Class Hierarchy   Compound List   Header Files   Compound Members  

ddgColor4 Class Reference

A convenience object to support colors. More...

#include <render/ddgcolor.h>

List of all members.


Public Members

 ddgColor4 ( unsigned char r, unsigned char g, unsigned char b, unsigned char a)
Construct a color from R,G,B values.

 ddgColor4 ( void )
Create a default white color.

 operator const unsigned char * ()
return the value of the vector as a unsigned char array.

 operator ddgColor4 * ()
return a pointer to a vector from a vector.

unsigned char operator[] (int n) const
Get value of one dimension of the vector.

void set (const ddgColor4 *c)
Set color into color object.

void set (unsigned char r, unsigned char g,unsigned char b, unsigned char a)
Set color into color object.

void enable (void)
Set the color into the graphics system.

void linterp (const ddgColor4 *a, const ddgColor4 *b, float t)
Interpolate a new color from two other colors.

void einterp (const ddgColor4 *a, const ddgColor4 *b, float t)
Exponentially Interpolate a new color from two other colors.

void cinterp (const ddgColor4 *a, const ddgColor4 *b, float t)
Cosine Interpolate a new color from two other colors.

void binterp (const ddgColor4 *a, const ddgColor4 *b, float t)
Bilinear Interpolate a new color from two other colors.

unsigned char r (void)
Return red component.

unsigned char g (void)
Return green component.

unsigned char b (void)
Return blue component.

unsigned char a (void)
Return alpha component.

 ddgColor4 ( unsigned char r, unsigned char g, unsigned char b, unsigned char a)
Construct a color from R,G,B values.

 ddgColor4 ( void )
Create a default white color.

 operator const unsigned char * ()
return the value of the vector as a unsigned char array.

 operator ddgColor4 * ()
return a pointer to a vector from a vector.

unsigned char operator[] (int n) const
Get value of one dimension of the vector.

void set (const ddgColor4 *c)
Set color into color object.

void set (unsigned char r, unsigned char g,unsigned char b, unsigned char a)
Set color into color object.

void linterp (const ddgColor4 *a, const ddgColor4 *b, float t)
Interpolate a new color from two other colors.

void einterp (const ddgColor4 *a, const ddgColor4 *b, float t)
Exponentially Interpolate a new color from two other colors.

void cinterp (const ddgColor4 *a, const ddgColor4 *b, float t)
Cosine Interpolate a new color from two other colors.

void binterp (const ddgColor4 *a, const ddgColor4 *b, float t)
Bilinear Interpolate a new color from two other colors.

unsigned char r (void)
Return red component.

unsigned char g (void)
Return green component.

unsigned char b (void)
Return blue component.

unsigned char a (void)
Return alpha component.

unsigned char v [4]
ddgColor data.


Static Public Members

void test ( ddgColor4 *cs, ddgColor4 *ce )
Test.

void test ( ddgColor4 *cs, ddgColor4 *ce )
Test.


Detailed Description

A convenience object to support colors.

This a 4 component color, with R,G,B and Alpha values from 0 to 1.


The documentation for this class was generated from the following files:
Generated at Sun Sep 17 19:27:52 2000 for Digital Dawn Graphics Toolkit by doxygen 0.49-991205 written by Dimitri van Heesch, © 1997-1999