Type + Code: Processing For Designers

Page 36

Type + Code page >L< even {12} page Yeohyun Ahn. Viviana Cordova.

PFont myFont; void setup() { size(250,250); myFont = createFont("Helvetica",48); textFont(myFont,10); background(255); for(int i=-5;i<250;i=i+5) { // Write an additional for( ) statement here with a value j, creating a pattern across both the x and y coordinates filling the tile completely. // Examples on following page: for(int j=-5;j<250;j=j+10) { fill(0,0,0); textFont(myFont, 22); text("T",i,j); } }

for(int i=-5;i<250;i=i+5)

The letter “T” is repeated along the x coordinate, -5, 0, 5,10,15, 20, 25, ... and the y coordinate, -5, 0, 5,10,15, 20, 25, ... creating the diagonal effect.


Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.