Thursday, August 18, 2011

Pixels

void setup() {  
  size(800, 500);
}

void draw() {  
  for (int x=0; x<40; x++) { 
    for (int y=0; y<25; y++) { 

      if (random(0, 1)<0.5) {
        fill(0);
      } 
      else {
        fill(255);
      }       
      rect(x*20, y*20, 20, 20);
    }
  }
}

info info

submitted by: davidedc
views: 



treeThis sketch has a parent
Tags:

comments comment

loading loading...

 

Add a comment: