|  | OGRE-Next 3.0.0
    Object-Oriented Graphics Rendering Engine | 
Class representing colour. More...
#include <OgreColourValue.h>
| Public Member Functions | |
| ColourValue (float red=1.0f, float green=1.0f, float blue=1.0f, float alpha=1.0f) | |
| ColourValue (Vector3 v) | |
| ColourValue (Vector4 v) | |
| void | fromVector3 (Vector3 v) | 
| Sets 'this' RGB from xyz. Alpha component is left intact. | |
| void | fromVector4 (Vector4 v) | 
| Sets 'this' RGBA from xyzw. | |
| ABGR | getAsABGR () const | 
| Retrieves colours as ABGR. | |
| ARGB | getAsARGB () const | 
| Retrieves colour as ARGB. | |
| BGRA | getAsBGRA () const | 
| Retrieves colour as BGRA. | |
| RGBA | getAsRGBA () const | 
| Retrieves colour as RGBA. | |
| void | getHSB (Real *hue, Real *saturation, Real *brightness) const | 
| Convert the current colour to Hue, Saturation and Brightness values. | |
| bool | operator!= (const ColourValue &rhs) const | 
| ColourValue | operator* (const ColourValue &rhs) const | 
| ColourValue | operator* (const float fScalar) const | 
| ColourValue & | operator*= (const float fScalar) | 
| ColourValue | operator+ (const ColourValue &rkVector) const | 
| ColourValue & | operator+= (const ColourValue &rkVector) | 
| ColourValue | operator- (const ColourValue &rkVector) const | 
| ColourValue & | operator-= (const ColourValue &rkVector) | 
| ColourValue | operator/ (const ColourValue &rhs) const | 
| ColourValue | operator/ (const float fScalar) const | 
| ColourValue & | operator/= (const float fScalar) | 
| bool | operator== (const ColourValue &rhs) const | 
| float & | operator[] (const size_t i) | 
| Array accessor operator. | |
| float | operator[] (const size_t i) const | 
| Array accessor operator. | |
| float * | ptr () | 
| Pointer accessor for direct copying. | |
| const float * | ptr () const | 
| Pointer accessor for direct copying. | |
| void | saturate () | 
| Clamps colour value to the range [0, 1]. | |
| ColourValue | saturateCopy () const | 
| As saturate, except that this colour value is unaffected and the saturated colour value is returned as a copy. | |
| void | setAsABGR (const ABGR val) | 
| Sets colour as ABGR. | |
| void | setAsARGB (const ARGB val) | 
| Sets colour as ARGB. | |
| void | setAsBGRA (const BGRA val) | 
| Sets colour as BGRA. | |
| void | setAsRGBA (const RGBA val) | 
| Sets colour as RGBA. | |
| void | setHSB (Real hue, Real saturation, Real brightness) | 
| Set a colour value from Hue, Saturation and Brightness. | |
| Vector3 | toVector3 () const | 
| Returns the RGB in xyz as a Vector3. | |
| Vector4 | toVector4 () const | 
| Returns the RGBA in xyzw component as a Vector4. | |
| Public Attributes | |
| float | a | 
| float | b | 
| float | g | 
| float | r | 
| Static Public Attributes | |
| static const ColourValue | Black | 
| static const ColourValue | Blue | 
| static const ColourValue | Green | 
| static const ColourValue | Red | 
| static const ColourValue | White | 
| static const ColourValue | ZERO | 
Class representing colour.
| 
 | inlineexplicit | 
| 
 | inlineexplicit | 
| 
 | inlineexplicit | 
| 
 | inline | 
Sets 'this' RGB from xyz. Alpha component is left intact.
References Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z.
| 
 | inline | 
Sets 'this' RGBA from xyzw.
References Ogre::Vector4::w, Ogre::Vector4::x, Ogre::Vector4::y, and Ogre::Vector4::z.
| ABGR Ogre::ColourValue::getAsABGR | ( | ) | const | 
Retrieves colours as ABGR.
| ARGB Ogre::ColourValue::getAsARGB | ( | ) | const | 
Retrieves colour as ARGB.
| BGRA Ogre::ColourValue::getAsBGRA | ( | ) | const | 
Retrieves colour as BGRA.
| RGBA Ogre::ColourValue::getAsRGBA | ( | ) | const | 
Retrieves colour as RGBA.
Convert the current colour to Hue, Saturation and Brightness values.
| hue | Output hue value, scaled to the [0,1] range as opposed to the 0-360 | 
| saturation | Output saturation level, [0,1] | 
| brightness | Output brightness level, [0,1] | 
| bool Ogre::ColourValue::operator!= | ( | const ColourValue & | rhs | ) | const | 
| 
 | inline | 
| 
 | inline | 
| 
 | inline | 
| 
 | inline | 
| 
 | inline | 
| 
 | inline | 
| 
 | inline | 
| 
 | inline | 
| 
 | inline | 
| 
 | inline | 
| bool Ogre::ColourValue::operator== | ( | const ColourValue & | rhs | ) | const | 
| 
 | inline | 
Array accessor operator.
| 
 | inline | 
Array accessor operator.
| 
 | inline | 
Pointer accessor for direct copying.
| 
 | inline | 
Pointer accessor for direct copying.
| 
 | inline | 
Clamps colour value to the range [0, 1].
Referenced by saturateCopy().
| 
 | inline | 
As saturate, except that this colour value is unaffected and the saturated colour value is returned as a copy.
References saturate().
| void Ogre::ColourValue::setAsABGR | ( | const ABGR | val | ) | 
Sets colour as ABGR.
| void Ogre::ColourValue::setAsARGB | ( | const ARGB | val | ) | 
Sets colour as ARGB.
| void Ogre::ColourValue::setAsBGRA | ( | const BGRA | val | ) | 
Sets colour as BGRA.
| void Ogre::ColourValue::setAsRGBA | ( | const RGBA | val | ) | 
Sets colour as RGBA.
Set a colour value from Hue, Saturation and Brightness.
| hue | Hue value, scaled to the [0,1] range as opposed to the 0-360 | 
| saturation | Saturation level, [0,1] | 
| brightness | Brightness level, [0,1] | 
| 
 | inline | 
Returns the RGBA in xyzw component as a Vector4.
| float Ogre::ColourValue::a | 
Referenced by operator*(), operator*(), operator+(), operator+=(), operator-(), operator-=(), operator/(), and operator/().
| float Ogre::ColourValue::b | 
Referenced by operator*(), operator*(), operator+(), operator+=(), operator-(), operator-=(), operator/(), and operator/().
| 
 | static | 
| 
 | static | 
| float Ogre::ColourValue::g | 
Referenced by operator*(), operator*(), operator+(), operator+=(), operator-(), operator-=(), operator/(), and operator/().
| 
 | static | 
| float Ogre::ColourValue::r | 
Referenced by operator*(), operator*(), operator+(), operator+=(), operator-(), operator-=(), operator/(), and operator/().
| 
 | static | 
| 
 | static | 
| 
 | static |