Image Read

Erratica - Image Processing

Reading the pixel data of an image to drive the color and scale of circles.

Next step will be to draw the webcam video using the ellipses. Now its just changing based on a random number linked to the brightness.

Erratica - Image Processing

Some image downloaded from the web…

Erratica - Image Processing

PImage img;

void setup (){
size (360,360);
img = loadImage ("artlife4.jpg");
noStroke ();
smooth ();
tint (255,255,255,0);
image (img, 0,0);
frameRate (8);
}

void draw (){

for (int i = 0; i < width; i += 10){
for (int j = 0; j < height; j += 10){

int posX = i;
int posY = j;
color c = img.get (posX,posY);
float b = (random(brightness (c)/4));

fill (c, 200);
ellipseMode (CENTER);
ellipse (i, j,b,b);

}
}

}

Tags:

Comments are closed.