//erzeugt zufaellige, nicht rechtwinklige Viereckige Formate. //Mit der taste h laesst sich das naechste bild erzeugen //Linien koennen sich dabei ueberschneiden int m; float a,b,c,d,e,f,g,h; void setup () { size (800,800); fill (200); smooth(); reset(); } void reset() { background (255); a = random (0,800); b = random (0,800); c = random (0,800); d = random (0,800); e = random (0,800); f = random (0,800); g = random (0,800); h = random (0,800); } void draw () { background (255); line (g, h,a,b); line (a,b,c,d); line (c,d,e,f); line (e,f,g,h); fill (0); quad(g, h, a,b,c,d,e,f); } void keyPressed() { if ((key == 'h') ) { reset(); if (key == 'a'); } } void mousePressed() { if (mousePressed == true) { int x = 0; if(x < 100) { line(x, 0, x, 100); x = x + 1; } else { noLoop(); } // Saves each frame as screen-0000.tif, screen-0001.tif, etc. saveFrame(); } }