//created by luis gil //http://www.legil.org import processing.opengl.*; PImage obama; float angle = 0; void setup() { size(640, 510, OPENGL); //match size to image size obama = loadImage("obama.jpg"); //load whatever image you want } void draw() { background(55); translate(width/2, 0, -100); rotateY(angle); translate(-width/2, 0, -100); beginShape(); for (int i = 10; i < width; i += 10) { for (int j = 10; j < height; j +=10) { color pix = obama.get(i, j); float bright = brightness(pix); float mappedSize = map(bright, 0, 255, 0, 100); stroke(pix); //line(i, j, 0, i, j, mappedSize); vertex(i,j, mappedSize); } } endShape(); angle += 0.025; }