/* * Framework for rotational mandala * * Author: Michael Goldwasser */ void setup() { size(700, 700); } // This is the main draw for the entire sketch. void draw() { background(0); translate(0.5*width, 0.5*height); // put origin at center of canvas // ... } //****************************************************** // The following is an example of how to define a // Pattern named Point, which consists of a single point. // // You may use this as a template for developing more // interesting patterns //****************************************************** // A simple example of a point as a Pattern // Note that stroke color and width can be set before use class Point implements Pattern { void draw() { point(0,0); // draw one point at origin } } //****************************************************** // Do not make any changes below this line //****************************************************** interface Pattern { void draw(); } /* * render 'number' copies of the model pattern, with each drawn at * given radius from center and at given scale, and with the first * placed at angle theta. */ void stamp(Pattern model, int number, float radius, float scale, float theta) { float incr = TWO_PI/number; for (int j=0; j