having a hard time incorporating this into a code, any help would be great.
the directions state to do this for my assignment
- each key a,s,d,f,g will be assigned to call a different function
- use noLoop(), loop(), combined with the function mouseReleased() to make the brush a stencil, or not.
- use booleans to help control mouse and keyboard input.
- incorporate iterative loops to create sophisticated patterns.
- create a function that will erase the sketch so you can start again without having to run the program.
// INITIALIZE VARIABLES // SETUP size, background, etc. // DRAW // if the mouse is pressed //also, if the 'a' key is pressed // call the brush #1 // and make it so draw() DOES loop // else if the 's' key is pressed // call the stencil #2 // and make it so draw() DOES NOT loop // USER DEFINED FUNCTION // custom brush #1 // USER DEFINED FUNCTION // custom stencil #2 // USE mouseReleased() to turn // each time the mouse is released make sure that draw function is (re)set to loop() if it isn't