STIRA
0.1
|
class to generate different kinds of textures code slightly adapted from http://lodev.org/cgtutor/randomnoise.html More...
#include <TextureGenerator.h>
Public Types | |
enum | TextureType { TEXTURE_PERLIN, TEXTURE_WOOD, TEXTURE_MARBLE } |
Public Member Functions | |
TextureGenerator (int width, int height, TextureType myTextureType) | |
constructor | |
~TextureGenerator () | |
destructor | |
Image * | GenerateClouds () |
Image * | GenerateMarble (double xPeriod, double yPeriod, double turbPower, double turbSize) |
Generates marble like texture. More... | |
Image * | GenerateWood (double xyPeriod, double turbPower, double turbSize) |
class to generate different kinds of textures code slightly adapted from http://lodev.org/cgtutor/randomnoise.html
Image * stira::imagetools::TextureGenerator::GenerateMarble | ( | double | xPeriod, |
double | yPeriod, | ||
double | turbPower, | ||
double | turbSize | ||
) |
Generates marble like texture.
xPeriod | defines repetition of marble lines in x direction |
yPeriod | defines repetition of marble lines in y direction |
turbPower | makes twists |
turbSize | initial size of the turbulence |
References stira::imagedata::Image::SetColor().
Image * stira::imagetools::TextureGenerator::GenerateWood | ( | double | xyPeriod, |
double | turbPower, | ||
double | turbSize | ||
) |
Generate wood-like texture
xyPeriod | number of rings |
turbPower | makes twists |
turbSize | initial size of the turbulence |
References stira::imagedata::Image::SetColor().