#include <SO3ColourGradient.h>
Public Types | |
| typedef ColourFrames::value_type | ColourFrame |
| A single colour frame. | |
Public Member Functions | |
| SColourGradient (bool fillBoundsWithDefault=true) | |
| SColourGradient (const Ogre::ColourValue &overridedMinDefaultColour, const Ogre::ColourValue &overridedMaxDefaultColour) | |
| ~SColourGradient () | |
| void | AddColourFrame (const ColourFrame &colourFrame) |
| void | AddColourFrame (const float &gradientPosition, const Ogre::ColourValue &colour) |
| void | Clear () |
| const Ogre::ColourValue | GetColour (float gradientPosition) const |
Optimized gradient class, idea comes from SkyX, but totally rewritten in order to be more efficient.
Definition at line 39 of file SO3ColourGradient.h.
| typedef ColourFrames::value_type SO3::SColourGradient::ColourFrame |
A single colour frame.
Definition at line 50 of file SO3ColourGradient.h.
| SO3::SColourGradient::SColourGradient | ( | bool | fillBoundsWithDefault = true |
) |
Constructor
| fillBoundsWithDefault | If true, and no colour frame with index 0.0 was provided, provide a default black colour for this position of the gradient. In the same way, if no colour frame is provided for 1.0 value, a default white colour is provided for this position of the gradient. |
Definition at line 33 of file SO3ColourGradient.cpp.
| SO3::SColourGradient::SColourGradient | ( | const Ogre::ColourValue & | overridedMinDefaultColour, | |
| const Ogre::ColourValue & | overridedMaxDefaultColour | |||
| ) |
Constructor, bound filling is automatically activated when using this constructor.
| overridedMinDefaultColour | The default "black" colour used by automatic bound filling will be replaced by the provided colour | |
| overridedMaxDefaultColour |
Definition at line 39 of file SO3ColourGradient.cpp.
| SO3::SColourGradient::~SColourGradient | ( | ) |
Destructor
Definition at line 45 of file SO3ColourGradient.cpp.
| void SO3::SColourGradient::AddColourFrame | ( | const float & | gradientPosition, | |
| const Ogre::ColourValue & | colour | |||
| ) | [inline] |
Add colour frame
| colour | Coulour of this frame | |
| gradientPosition | Position of this frame in the gradient (overwrite if value exists). |
Definition at line 85 of file SO3ColourGradient.h.
| void SO3::SColourGradient::AddColourFrame | ( | const ColourFrame & | colourFrame | ) | [inline] |
Add colour frame
| colourFrame | Colour frame |
Definition at line 75 of file SO3ColourGradient.h.
| void SO3::SColourGradient::Clear | ( | ) | [inline] |
Clear colour gradient
Definition at line 97 of file SO3ColourGradient.h.
| const Ogre::ColourValue SO3::SColourGradient::GetColour | ( | float | gradientPosition | ) | const |
Get colour value
| gradientPosition | The gradient point in [0,1] range |
Definition at line 49 of file SO3ColourGradient.cpp.
1.6.3