Gallery of conducted experiments
----------
Each category contain a variation of sketches to look into and play with. Feel free to
change the code (it will
and just press 'RECOMPILE' in upper right to submit your commands. The changes are only
temporary and reset upon
changing sketches. If you want to keep playing with a sketch, just copy and paste into
P5LIVE to save and create versions of
changes.
Shortcuts:
CTRL + ENTER » Recompile
CTRL + E » Toggle Code Editor
CTRL + I » Toggle Gallery & Information
CTRL + P » Pause/Play
CTRL + S » Save/Export PNG
Background & Guidance
----------
Try to find and exchange the following functions (while x is being a given variable or
parameter)
mod(x,0.5); // return x modulo of 0.5
fract(x); // return only the fraction part of a number
ceil(x); // nearest integer that is greater than or equal to x
floor(x); // nearest integer less than or equal to x
sign(x); // extract the sign of x
abs(x); // return the absolute value of x
clamp(x,0.0,1.0); // constrain x to lie between 0.0 and 1.0
min(0.0,x); // return the lesser of x and 0.0
max(0.0,x); // return the greater of x and 0.0
Many thanks to
Ted Davis for support and inspiration
through his sandbox.