This class is what generates our random art. More...
#include <Art.h>
Public Member Functions | |
Expr * | build (int depth, G3D::Random &randomGenerator) |
Called to create a random expression. More... | |
shared_ptr< Image > | nextImage () |
Get the next random art image. More... | |
Static Public Member Functions | |
static shared_ptr< Art > | create (float timeIncr, int genDepth, uint32 num) |
time increment is how fast we step through the different art frames of the randomly generated 2d art animation. More... | |
Protected Member Functions | |
Art (float timeIncr, int genDepth, uint32 num) | |
shared_ptr< Image > | doRandomGray (float step) |
float | toReal (int i, int N) |
Scales our inputs to be less than 1. More... | |
Protected Attributes | |
shared_ptr< Expr > | expression1 |
Our randomly generated expressions, one for each color: r, g, b. More... | |
shared_ptr< Expr > | expression2 |
shared_ptr< Expr > | expression3 |
float | ourTime |
float | step |
float | timeIncrement |
This class is what generates our random art.
It takes in a time increment, the depth of the random expression to generate, and a seed number. From calling nextImage() one is able to get the next image step in the 2d random art animation.
|
protected |
Expr * Art::build | ( | int | depth, |
G3D::Random & | randomGenerator | ||
) |
Called to create a random expression.
This is a recursive method call where depth determines how many more recursive expansions we will use.
|
static |
time increment is how fast we step through the different art frames of the randomly generated 2d art animation.
genDepth is related to the generation of the random function. Check the Expr class for more details on how the random math function is created/represented and the Art::build() on how depth is used
|
protected |
shared_ptr< Image > Art::nextImage | ( | ) |
Get the next random art image.
|
protected |
Scales our inputs to be less than 1.
The behavior of the trigonometric functions in our random math expression is less desirable as input > 1.
|
protected |
Our randomly generated expressions, one for each color: r, g, b.
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |