![]() |
RTFX
0.3
Real time special effects collaborative visualization and production library.
|
A class to represent several formats of colours. More...
#include <algebra.hpp>
Public Member Functions | |
Colour () | |
~Colour () | |
Colour (const Colour &_other) | |
Colour & | operator= (const Colour &_other) |
void | SetRGB (double _r, double _g, double _b) |
void | SetRed (double _r) |
void | SetGreen (double _g) |
void | SetBlue (double _b) |
void | SetHSV (double _h, double _s, double _v) |
void | SetHue (double _h) |
void | SetSaturation (double _s) |
void | SetValue (double _v) |
double * | GetRGB () |
double | GetRed () |
double | GetGreen () |
double | GetBlue () |
double * | GetHSV () |
double | GetHue () |
double | GetSaturation () |
double | GetValue () |
void | SetAlpha (double _alpha) |
double | GetAlpha () |
void | MultiplyByScalar (double _s) |
void | AddColour (Colour _c) |
bool | operator== (Colour &_c) |
Private Member Functions | |
void | Init () |
template<class Archive > | |
void | serialize (Archive &_ar, const unsigned int _version) |
Private Attributes | |
double | rgb [3] |
double | hsv [3] |
double | alpha |
Friends | |
class | boost::serialization::access |
A class to represent several formats of colours.
|
inline |
Constructor: calls Init function
|
inline |
Destructor
|
inline |
|
inline |
Add another colour to this one
References GetAlpha(), GetBlue(), GetGreen(), GetHue(), GetRed(), GetSaturation(), and GetValue().
|
inline |
Get alpha
|
inline |
Get B
|
inline |
Get G
|
inline |
Get HSV
|
inline |
Get H
|
inline |
Get R
|
inline |
Get RGB
|
inline |
Get S
|
inline |
Get V
|
inlineprivate |
Init colour values to zeros
|
inline |
Multiply colour by scalar value
|
inline |
Determine if this colour equals the input one
References GetAlpha(), GetBlue(), GetGreen(), GetHue(), GetRed(), GetSaturation(), and GetValue().
|
inline |
Set Alpha
|
inline |
Set B
|
inline |
Set G
|
inline |
Set HSV
|
inline |
Set H
|
inline |
Set R
|
inline |
Set RGB
|
inline |
Set S
|
inline |
Set V
|
private |
the alpha value
|
private |
The array which holds the HSV colour data
|
private |
The array which holds the RGB colour data