04.04.2013 Views

Processing: Creative Coding and Computational Art

Processing: Creative Coding and Computational Art

Processing: Creative Coding and Computational Art

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

draw triangle fan<br />

void drawPoly(float x, float y, int pts, float initAngle, float rad){<br />

strokeWeight(1.5);<br />

float px = 0, py = 0;<br />

float angle = initAngle;<br />

// needs to rotate clockwise<br />

beginShape(TRIANGLE_FAN);<br />

vertex(x, y);<br />

for (int i=0; i

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!