Fills full image with given colour gradients. More...
#include <gradientgenerator.h>
Inheritance diagram for Mezzanine::Graphics::Procedural::GradientGenerator:
Collaboration diagram for Mezzanine::Graphics::Procedural::GradientGenerator:Public Member Functions | |
| GradientGenerator () | |
| Class constructor. | |
| virtual | ~GradientGenerator () |
| Class destructor. | |
| virtual void | AddToTextureBuffer (TextureBuffer &Buffer) const |
| Replaces and populates the pixels as configured in this generator to a TextureBuffer. More... | |
| virtual String | GetName () const |
| Gets the name of this generator. More... | |
| GradientGenerator & | SetBottomLeftColour (const ColourValue &Colour) |
| Sets the colour of the bottom-left corner. More... | |
| GradientGenerator & | SetBottomLeftColour (const Real Red, const Real Green, const Real Blue, const Real Alpha=1.0) |
| Sets the colour of the bottom-left corner. More... | |
| GradientGenerator & | SetBottomRightColour (const ColourValue &Colour) |
| Sets the colour of the bottom-right corner. More... | |
| GradientGenerator & | SetBottomRightColour (const Real Red, const Real Green, const Real Blue, const Real Alpha=1.0) |
| Sets the colour of the bottom-right corner. More... | |
| GradientGenerator & | SetColours (const ColourValue &TopLeft, const ColourValue &TopRight, const ColourValue &BottomLeft, const ColourValue &BottomRight) |
| Sets the colours of the image corners. More... | |
| GradientGenerator & | SetTopLeftColour (const ColourValue &Colour) |
| Sets the colour of the top-left corner. More... | |
| GradientGenerator & | SetTopLeftColour (const Real Red, const Real Green, const Real Blue, const Real Alpha=1.0) |
| Sets the colour of the top-left corner. More... | |
| GradientGenerator & | SetTopRightColour (const ColourValue &Colour) |
| Sets the colour of the top-right corner. More... | |
| GradientGenerator & | SetTopRightColour (const Real Red, const Real Green, const Real Blue, const Real Alpha=1.0) |
| Sets the colour of the top-right corner. More... | |
Public Member Functions inherited from Mezzanine::Graphics::Procedural::TextureGenerator | |
| TextureGenerator () | |
| Blank constructor. | |
| virtual | ~TextureGenerator () |
| Class destructor. | |
| TextureBuffer | BuildTextureBuffer (const Whole SquareSize) const |
| Creates a TextureBuffer with the pixels as configured in this generator. More... | |
| TextureBuffer | BuildTextureBuffer (const Whole TexWidth, const Whole TexHeight) const |
| Creates a TextureBuffer with the pixels as configured in this generator. More... | |
| Image * | GenerateImage (const Whole SquareSize, const Graphics::PixelFormat Format=Graphics::PF_R8G8B8A8) const |
| Generates the Image. More... | |
| Image * | GenerateImage (const Whole TexWidth, const Whole TexHeight, const Graphics::PixelFormat Format=Graphics::PF_R8G8B8A8) const |
| Generates the Image. More... | |
| Texture * | GenerateTexture (const Whole SquareSize, const String &TexName, const String &TexGroup, const Graphics::PixelFormat Format=Graphics::PF_R8G8B8A8) const |
| Generates the Texture. More... | |
| Texture * | GenerateTexture (const Whole TexWidth, const Whole TexHeight, const String &TexName, const String &TexGroup, const Graphics::PixelFormat Format=Graphics::PF_R8G8B8A8) const |
| Generates the Texture. More... | |
Protected Attributes | |
| ColourValue | GenBottomLeftColour |
| The colour of the bottom-left corner. More... | |
| ColourValue | GenBottomRightColour |
| The colour of the bottom-right corner. More... | |
| ColourValue | GenTopLeftColour |
| The colour of the top-left corner. More... | |
| ColourValue | GenTopRightColour |
| The colour of the top-right corner. More... | |
Fills full image with given colour gradients.
Each corner of the image has unique colour.
Definition at line 82 of file gradientgenerator.h.
|
virtual |
Replaces and populates the pixels as configured in this generator to a TextureBuffer.
| Buffer | The buffer to place this generators pixels in. |
Implements Mezzanine::Graphics::Procedural::TextureGenerator.
Definition at line 91 of file gradientgenerator.cpp.
|
virtual |
Gets the name of this generator.
Implements Mezzanine::Graphics::Procedural::TextureGenerator.
Definition at line 111 of file gradientgenerator.cpp.
| GradientGenerator & Mezzanine::Graphics::Procedural::GradientGenerator::SetBottomLeftColour | ( | const ColourValue & | Colour | ) |
Sets the colour of the bottom-left corner.
| Colour | The colour to be applied to the bottom-left corner of the generated image. |
Definition at line 141 of file gradientgenerator.cpp.
| GradientGenerator & Mezzanine::Graphics::Procedural::GradientGenerator::SetBottomLeftColour | ( | const Real | Red, |
| const Real | Green, | ||
| const Real | Blue, | ||
| const Real | Alpha = 1.0 |
||
| ) |
Sets the colour of the bottom-left corner.
| Red | The Red component for the bottom-left corner colour. Range: [0.0, 1.0]. |
| Green | The Green component for the bottom-left corner colour. Range: [0.0, 1.0]. |
| Blue | The Blue component for the bottom-left corner colour. Range: [0.0, 1.0]. |
| Alpha | The Alpha component for the bottom-left corner colour. Range: [0.0, 1.0]. |
Definition at line 147 of file gradientgenerator.cpp.
| GradientGenerator & Mezzanine::Graphics::Procedural::GradientGenerator::SetBottomRightColour | ( | const ColourValue & | Colour | ) |
Sets the colour of the bottom-right corner.
| Colour | The colour to be applied to the bottom-right corner of the generated image. |
Definition at line 153 of file gradientgenerator.cpp.
| GradientGenerator & Mezzanine::Graphics::Procedural::GradientGenerator::SetBottomRightColour | ( | const Real | Red, |
| const Real | Green, | ||
| const Real | Blue, | ||
| const Real | Alpha = 1.0 |
||
| ) |
Sets the colour of the bottom-right corner.
| Red | The Red component for the bottom-right corner colour. Range: [0.0, 1.0]. |
| Green | The Green component for the bottom-right corner colour. Range: [0.0, 1.0]. |
| Blue | The Blue component for the bottom-right corner colour. Range: [0.0, 1.0]. |
| Alpha | The Alpha component for the bottom-right corner colour. Range: [0.0, 1.0]. |
Definition at line 159 of file gradientgenerator.cpp.
| GradientGenerator & Mezzanine::Graphics::Procedural::GradientGenerator::SetColours | ( | const ColourValue & | TopLeft, |
| const ColourValue & | TopRight, | ||
| const ColourValue & | BottomLeft, | ||
| const ColourValue & | BottomRight | ||
| ) |
Sets the colours of the image corners.
| TopLeft | The colour to be applied to the top-left corner of the generated image. |
| TopRight | The colour to be applied to the top-right corner of the generated image. |
| BottomLeft | The colour to be applied to the bottom-left corner of the generated image. |
| BottomRight | The colour to be applied to the bottom-right corner of the generated image. |
Definition at line 165 of file gradientgenerator.cpp.
| GradientGenerator & Mezzanine::Graphics::Procedural::GradientGenerator::SetTopLeftColour | ( | const ColourValue & | Colour | ) |
Sets the colour of the top-left corner.
| Colour | The colour to be applied to the top-left corner of the generated image. |
Definition at line 117 of file gradientgenerator.cpp.
| GradientGenerator & Mezzanine::Graphics::Procedural::GradientGenerator::SetTopLeftColour | ( | const Real | Red, |
| const Real | Green, | ||
| const Real | Blue, | ||
| const Real | Alpha = 1.0 |
||
| ) |
Sets the colour of the top-left corner.
| Red | The Red component for the top-left corner colour. Range: [0.0, 1.0]. |
| Green | The Green component for the top-left corner colour. Range: [0.0, 1.0]. |
| Blue | The Blue component for the top-left corner colour. Range: [0.0, 1.0]. |
| Alpha | The Alpha component for the top-left corner colour. Range: [0.0, 1.0]. |
Definition at line 123 of file gradientgenerator.cpp.
| GradientGenerator & Mezzanine::Graphics::Procedural::GradientGenerator::SetTopRightColour | ( | const ColourValue & | Colour | ) |
Sets the colour of the top-right corner.
| Colour | The colour to be applied to the top-right corner of the generated image. |
Definition at line 129 of file gradientgenerator.cpp.
| GradientGenerator & Mezzanine::Graphics::Procedural::GradientGenerator::SetTopRightColour | ( | const Real | Red, |
| const Real | Green, | ||
| const Real | Blue, | ||
| const Real | Alpha = 1.0 |
||
| ) |
Sets the colour of the top-right corner.
| Red | The Red component for the top-right corner colour. Range: [0.0, 1.0]. |
| Green | The Green component for the top-right corner colour. Range: [0.0, 1.0]. |
| Blue | The Blue component for the top-right corner colour. Range: [0.0, 1.0]. |
| Alpha | The Alpha component for the top-right corner colour. Range: [0.0, 1.0]. |
Definition at line 135 of file gradientgenerator.cpp.
|
protected |
The colour of the bottom-left corner.
Definition at line 93 of file gradientgenerator.h.
|
protected |
The colour of the bottom-right corner.
Definition at line 96 of file gradientgenerator.h.
|
protected |
The colour of the top-left corner.
Definition at line 87 of file gradientgenerator.h.
|
protected |
The colour of the top-right corner.
Definition at line 90 of file gradientgenerator.h.
1.8.9.1. Thanks to the
Open Icon Library
for help with some of the icons.