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

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

PROCESSING: CREATIVE CODING AND COMPUTATIONAL ART<br />

322<br />

Polygon (int x, int y, int w, int h, int pts){<br />

//Optional call to superclass constructor must come first<br />

super(x, y, w, h);<br />

// add any remaining initializations<br />

this.pts = pts;<br />

}<br />

//method to draw poly<br />

void create(){<br />

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

float angle = 0;<br />

beginShape();<br />

for (int i=0; i

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

Saved successfully!

Ooh no, something went wrong!