xxxxxxxxxx
17
/*
* Creative Coding Workshop #3 Demo - Circle at X Based on Sin
*
* Jack B. Du (github@jackbdu.com)
*/
function setup() {
// create a 400px by 400px canvas
createCanvas(400, 400);
}
function draw() {
// specify a background for each frame
background(220);
// circle whose x is based on sin
circle(200+200*sin(frameCount/50),200,50);
}