Contents User Forum Source Index APIs by Task APIs by Level Data


G3D::Color4 Class Reference

Do not subclass-- this implementation makes assumptions about the memory layout. More...

#include <Color4.h>

List of all members.

Public Member Functions

 Color4 (const Color4 &other)
 Color4 (float value[4])
 Color4 (float r, float g, float b, float a=1.0)
 Color4 (const class Vector4 &v)
 Color4 (class BinaryInput &bi)
 Color4 (const class Color4uint8 &c)
 Color4 (const Color3 &c3, float a=1.0)
 Color4 ()
void deserialize (class BinaryInput &bi)
bool fuzzyEq (const Color4 &other) const
bool fuzzyNe (const Color4 &other) const
size_t hashCode () const
Color4 lerp (const Color4 &other, float a) const
Color4 max (const Color4 &other) const
Color4 min (const Color4 &other) const
Color4 operator * (float fScalar) const
Color4operator *= (float fScalar)
 operator const float * () const
 operator float * ()
bool operator!= (const Color4 &rkVector) const
Color4 operator+ (const Color4 &rkVector) const
Color4operator+= (const Color4 &rkVector)
Color4 operator- () const
Color4 operator- (const Color4 &rkVector) const
Color4operator-= (const Color4 &rkVector)
Color4 operator/ (float fScalar) const
Color4operator/= (float fScalar)
Color4operator= (const Color4 &rkVector)
bool operator== (const Color4 &rkVector) const
float & operator[] (int i) const
Color3 rgb () const
void serialize (class BinaryOutput &bo) const
float sum () const
std::string toString () const

Static Public Member Functions

static const Color4clear ()
static Color4 fromARGB (uint32)
static const Color4inf ()
static const Color4zero ()

Public Attributes

float a
float b
float g
float r

Friends

Color4 operator * (double fScalar, const Color4 &rkVector)


Detailed Description

Do not subclass-- this implementation makes assumptions about the memory layout.


Constructor & Destructor Documentation

G3D::Color4::Color4 (  )  [inline]

Does not initialize fields.

G3D::Color4::Color4 ( const Color3 c3,
float  a = 1.0 
) [inline]

G3D::Color4::Color4 ( const class Color4uint8 c  ) 

G3D::Color4::Color4 ( class BinaryInput bi  ) 

G3D::Color4::Color4 ( const class Vector4 v  ) 

G3D::Color4::Color4 ( float  r,
float  g,
float  b,
float  a = 1.0 
) [inline]

Initialize from G3D::Reals.

G3D::Color4::Color4 ( float  value[4]  )  [inline]

Initialize from array of G3D::Reals.

G3D::Color4::Color4 ( const Color4 other  )  [inline]

Initialize from another color.


Member Function Documentation

static const Color4& G3D::Color4::clear (  )  [static]

void G3D::Color4::deserialize ( class BinaryInput bi  ) 

static Color4 G3D::Color4::fromARGB ( uint32   )  [static]

Initialize from an HTML-style color (e.g.

0xFFFF0000 == RED)

bool G3D::Color4::fuzzyEq ( const Color4 other  )  const [inline]

bool G3D::Color4::fuzzyNe ( const Color4 other  )  const [inline]

size_t G3D::Color4::hashCode (  )  const

static const Color4& G3D::Color4::inf (  )  [static]

Color4 G3D::Color4::lerp ( const Color4 other,
float  a 
) const [inline]

Color4 G3D::Color4::max ( const Color4 other  )  const [inline]

Color4 G3D::Color4::min ( const Color4 other  )  const [inline]

Color4 G3D::Color4::operator * ( float  fScalar  )  const [inline]

Color4 & G3D::Color4::operator *= ( float  fScalar  )  [inline]

G3D::Color4::operator const float * (  )  const [inline]

G3D::Color4::operator float * (  )  [inline]

bool G3D::Color4::operator!= ( const Color4 rkVector  )  const [inline]

Color4 G3D::Color4::operator+ ( const Color4 rkVector  )  const [inline]

Color4 & G3D::Color4::operator+= ( const Color4 rkVector  )  [inline]

Color4 G3D::Color4::operator- (  )  const [inline]

Color4 G3D::Color4::operator- ( const Color4 rkVector  )  const [inline]

Color4 & G3D::Color4::operator-= ( const Color4 rkVector  )  [inline]

Color4 G3D::Color4::operator/ ( float  fScalar  )  const

Color4& G3D::Color4::operator/= ( float  fScalar  ) 

Color4 & G3D::Color4::operator= ( const Color4 rkVector  )  [inline]

bool G3D::Color4::operator== ( const Color4 rkVector  )  const [inline]

float & G3D::Color4::operator[] ( int  i  )  const [inline]

Color3 G3D::Color4::rgb (  )  const [inline]

void G3D::Color4::serialize ( class BinaryOutput bo  )  const

float G3D::Color4::sum (  )  const [inline]

r + g + b + a

std::string G3D::Color4::toString (  )  const

static const Color4& G3D::Color4::zero (  )  [static]


Friends And Related Function Documentation

Color4 operator * ( double  fScalar,
const Color4 rkVector 
) [friend]


Member Data Documentation

Channel values.


The documentation for this class was generated from the following file:
Generated on Thu Aug 2 11:40:45 2007 for G3D by doxygen 1.5.2
Hosted by SourceForge.net Logo