Creates a marble structured image. More...
#include <marblegenerator.h>
Public Member Functions | |
MarbleGenerator () | |
Class constructor. | |
virtual | ~MarbleGenerator () |
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... | |
MarbleGenerator & | SetColour (const ColourValue &Colour) |
Sets the colour of the marble structure. More... | |
MarbleGenerator & | SetColour (const Real Red, const Real Green, const Real Blue, const Real Alpha=1.0) |
Set the colour of the marble structure. More... | |
MarbleGenerator & | SetSeed (const Whole Seed) |
Sets the seed for the "random" number generator. More... | |
MarbleGenerator & | SetTurbulence (const Real Turb) |
Sets the turbulence that will modify the generated pattern. More... | |
![]() | |
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 | GenColour |
The colour to be applied to the marble structure. More... | |
Whole | GenSeed |
The seed to be used for the random number generator. More... | |
Real | GenTurbulence |
The amount of disruption to apply to the pattern. More... | |
Creates a marble structured image.
Creates a marbel structure from a specified perlin noise on a coloured background.
Definition at line 82 of file marblegenerator.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 94 of file marblegenerator.cpp.
|
virtual |
Gets the name of this generator.
Implements Mezzanine::Graphics::Procedural::TextureGenerator.
Definition at line 119 of file marblegenerator.cpp.
MarbleGenerator & Mezzanine::Graphics::Procedural::MarbleGenerator::SetColour | ( | const ColourValue & | Colour | ) |
Sets the colour of the marble structure.
Colour | The colour to be applied to the marble structure to be generated. |
Definition at line 125 of file marblegenerator.cpp.
MarbleGenerator & Mezzanine::Graphics::Procedural::MarbleGenerator::SetColour | ( | const Real | Red, |
const Real | Green, | ||
const Real | Blue, | ||
const Real | Alpha = 1.0 |
||
) |
Set the colour of the marble structure.
Red | The Red component for the marble structure colour. Range: [0.0, 1.0]. |
Green | The Green component for the marble structure colour. Range: [0.0, 1.0]. |
Blue | The Blue component for the marble structure colour. Range: [0.0, 1.0]. |
Alpha | The Alpha component for the marble structure colour. Range: [0.0, 1.0]. |
Definition at line 131 of file marblegenerator.cpp.
MarbleGenerator & Mezzanine::Graphics::Procedural::MarbleGenerator::SetSeed | ( | const Whole | Seed | ) |
Sets the seed for the "random" number generator.
Seed | The seed value for the random number generator. Initial Value: 5120. |
Definition at line 143 of file marblegenerator.cpp.
MarbleGenerator & Mezzanine::Graphics::Procedural::MarbleGenerator::SetTurbulence | ( | const Real | Turb | ) |
Sets the turbulence that will modify the generated pattern.
Turb | The amount of disruption to apply to the pattern. Initial Value: 2.0. |
Definition at line 137 of file marblegenerator.cpp.
|
protected |
The colour to be applied to the marble structure.
Definition at line 87 of file marblegenerator.h.
|
protected |
The seed to be used for the random number generator.
Definition at line 93 of file marblegenerator.h.
|
protected |
The amount of disruption to apply to the pattern.
Definition at line 90 of file marblegenerator.h.