[Overview] 01 02 03 04 05 06 07 08 09 void setup() { size(200, 100); } void draw() { if (mousePressed) { fill(0); } else { fill(255); } ellipse(mouseX, mouseY, 40, 30); } The syntax is Java-based. Your browser does not support the canvas tag. JavaScript is required to view the contents of this page. Move mouse to leave trail of white ellipses. Hold down a mouse key for black ellipses.
void setup() { size(200, 100); } void draw() { if (mousePressed) { fill(0); } else { fill(255); } ellipse(mouseX, mouseY, 40, 30); }
Your browser does not support the canvas tag.
JavaScript is required to view the contents of this page.