Ballet of Pixels


Processing Code

void setup(){
size(500, 500);
smooth();
frameRate(10);
}

void draw(){
int c = 50;
color color_one = color(249,218,185);
color color_two = color(199,178,201);
color color_three = color(251,176,135);
color color_four = color(217,191,220);
color color_five = color(191,209,220);
background(249,158,158);

for (int x = 0; x <= 450; x += 50) {
for (int y = 0; y <= 450; y += 50) {
fill(color_one);
noStroke();
rect(x*2,y*2,c,c);
}
}

for (int x = 50; x <= 450; x += 100) {
for (int y = 0; y <= 450; y += 50) {
fill(color_two);
noStroke();
rect(x*2,y*2,c,c);
}
}

for (int x = 25; x <= 450; x += 50) {
for (int y = 50; y <= 450; y += 100) {
fill(color_three);
noStroke();
rect(x*2,y,c,c);
}
}

for (int x = 75; x <= 450; x += 100) {
for (int y = 50; y <= 450; y += 100) {
fill(color_four);
noStroke();
rect(x*2,y,c,c);
}
}

translate(random(0, 350), random(0, 0));
for (int x = 25; x <= 450; x += 500) {
for (int y = 25; y <= 450; y += 500) {
fill(color_five);
noStroke();
ellipse(x, y, c, c);
}
}

translate(random(0, 350), random(50, 50));
for (int x = 75; x <= 450; x += 500) {
for (int y = 75; y <= 450; y += 500) {
fill(color_five);
noStroke();
ellipse(x, y, c, c);
}
}

translate(random(-350, 0), random(75, 75));
for (int x = 100; x <= 450; x += 500) {
for (int y = 100; y <= 450; y += 500) {
fill(color_five);
noStroke();
ellipse(x, y, c, c);
}
}

translate(random(-350, 0), random(100, 100));
for (int x = 100; x <= 450; x += 500) {
for (int y = 100; y <= 450; y += 500) {
fill(color_five);
noStroke();
ellipse(x, y, c, c);
}
}

translate(random(0, 350), random(100, 100));
for (int x = 100; x <= 450; x += 500) {
for (int y = 100; y <= 450; y += 500) {
fill(color_five);
noStroke();
ellipse(x, y, c, c);
}
}
}