Ogre Procedural  0.3.0 unstable
Procedural Geometry & Textures for Ogre3D
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Procedural::Labyrinth Class Reference

Creates a labyrinth structured image. More...

#include <ProceduralTextureGenerator.h>

Inheritance diagram for Procedural::Labyrinth:
Inheritance graph
[legend]

Public Member Functions

 Labyrinth (TextureBufferPtr pBuffer)
 Default constructor. More...
 
LabyrinthsetColour (Ogre::ColourValue colour)
 Set the colour of the background. More...
 
LabyrinthsetColour (Ogre::Real red, Ogre::Real green, Ogre::Real blue, Ogre::Real alpha=1.0f)
 Sets the colour of the background. More...
 
LabyrinthsetSeed (Ogre::uint seed)
 Set the seed for "random" number generator. More...
 
TextureBufferPtr process ()
 Run image generation. More...
 
Ogre::String getName ()
 Get name of the filter as string. More...
 
void setLog (bool enable=true)
 Enable/Disable logging. More...
 

Protected Member Functions

void logMsg (Ogre::String msg)
 

Protected Attributes

TextureBufferPtr mBuffer
 
Ogre::String mName
 
bool mLog
 

Detailed Description

Creates a labyrinth structured image.

Creates a labyrinth structure from a specified perlin noise on a coloured background.

Example:

Procedural::TextureBuffer bufferLabyrinth(256);
Procedural::Labyrinth(&bufferLabyrinth).process();

Constructor & Destructor Documentation

◆ Labyrinth()

Procedural::Labyrinth::Labyrinth ( TextureBufferPtr  pBuffer)

Default constructor.

Parameters
pBufferImage buffer where to store the generated image.

Member Function Documentation

◆ getName()

Ogre::String Procedural::TextureProcessing::getName ( )
inherited

Get name of the filter as string.

◆ logMsg()

void Procedural::TextureProcessing::logMsg ( Ogre::String  msg)
protectedinherited

◆ process()

TextureBufferPtr Procedural::Labyrinth::process ( )
virtual

Run image generation.

Returns
Pointer to image buffer which has been set in the constructor.

Implements Procedural::TextureProcessing.

◆ setColour() [1/2]

Labyrinth& Procedural::Labyrinth::setColour ( Ogre::ColourValue  colour)

Set the colour of the background.

Parameters
colourNew colour for background (default Ogre::ColourValue::White)

◆ setColour() [2/2]

Labyrinth& Procedural::Labyrinth::setColour ( Ogre::Real  red,
Ogre::Real  green,
Ogre::Real  blue,
Ogre::Real  alpha = 1.0f 
)

Sets the colour of the background.

Parameters
redRed value of background colour [0.0, 1.0] (default 1.0)
greenGreen value of background colour [0.0, 1.0] (default 1.0)
blueBlue value of background colour [0.0, 1.0] (default 1.0)
alphaAlpha value of background colour [0.0, 1.0] (default 1.0)

◆ setLog()

void Procedural::TextureProcessing::setLog ( bool  enable = true)
inherited

Enable/Disable logging.

Parameters
enabletrue enables logging of filter actions

◆ setSeed()

Labyrinth& Procedural::Labyrinth::setSeed ( Ogre::uint  seed)

Set the seed for "random" number generator.

Parameters
seedSeed value where to set the random number generator (default 5120)

Member Data Documentation

◆ mBuffer

TextureBufferPtr Procedural::TextureProcessing::mBuffer
protectedinherited

◆ mLog

bool Procedural::TextureProcessing::mLog
protectedinherited

◆ mName

Ogre::String Procedural::TextureProcessing::mName
protectedinherited

The documentation for this class was generated from the following file:
Procedural::Labyrinth::process
TextureBufferPtr process()
Run image generation.
Procedural::Labyrinth
Creates a labyrinth structured image.
Definition: ProceduralTextureGenerator.h:375
Procedural::TextureBuffer
class to store image data while processing
Definition: ProceduralTextureBuffer.h:50