#include <SO3ColourGradient.h>
|
typedef ColourFrames::value_type | ColourFrame |
| A single colour frame.
|
|
Optimized gradient class, idea comes from SkyX, but totally rewritten in order to be more efficient.
Definition at line 36 of file SO3ColourGradient.h.
◆ ColourFrame
◆ SColourGradient() [1/2]
SO3::SColourGradient::SColourGradient |
( |
const bool & |
fillBoundsWithDefault = true | ) |
|
Constructor
- Parameters
-
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 30 of file SO3ColourGradient.cpp.
◆ SColourGradient() [2/2]
SO3::SColourGradient::SColourGradient |
( |
const Ogre::ColourValue & |
overridedMinDefaultColour, |
|
|
const Ogre::ColourValue & |
overridedMaxDefaultColour |
|
) |
| |
Constructor, bound filling is automatically activated when using this constructor.
- Parameters
-
overridedMinDefaultColour | The default "black" colour used by automatic bound filling will be replaced by the provided colour |
overridedMaxDefaultColour | |
Definition at line 36 of file SO3ColourGradient.cpp.
◆ ~SColourGradient()
SO3::SColourGradient::~SColourGradient |
( |
| ) |
|
◆ AddColourFrame() [1/2]
void SO3::SColourGradient::AddColourFrame |
( |
const ColourFrame & |
colourFrame | ) |
|
|
inline |
◆ AddColourFrame() [2/2]
void SO3::SColourGradient::AddColourFrame |
( |
const float & |
gradientPosition, |
|
|
const Ogre::ColourValue & |
colour |
|
) |
| |
|
inline |
Add colour frame
@param colour Coulour of this frame
- Parameters
-
gradientPosition | Position of this frame in the gradient (overwrite if value exists). |
Definition at line 82 of file SO3ColourGradient.h.
◆ Clear()
void SO3::SColourGradient::Clear |
( |
| ) |
|
|
inline |
◆ GetColour()
const Ogre::ColourValue SO3::SColourGradient::GetColour |
( |
const float & |
gradientPosition | ) |
const |
Get colour value
- Parameters
-
gradientPosition | The gradient point in [0,1] range |
- Returns
- Colour at the given gradient position
Definition at line 46 of file SO3ColourGradient.cpp.
The documentation for this class was generated from the following files: