void setup() {
size(600, 600);
smooth();
}
void drawShell(float angle, int r1, int r2, int r3) {
pushMatrix();
translate(width/2, height/2);
strokeWeight(4);
noFill();
stroke(50);
for (int r = r1; r < r2; r+=4) arc(0, 0, r, r, angle+0, angle+PI/2);
stroke(0);
for (int r = r2; r <= r3; r+=4) arc(0, 0, r, r, angle+0, angle+PI/2);
stroke(200);
for (int r = r1; r < r2; r+=4) arc(0, 0, r, r, angle+PI, angle+3*PI/2);
stroke(255);
for (int r = r2; r <= r3; r+=4) arc(0, 0, r, r, angle+PI, angle+3*PI/2);
//arc(0,0,55,55,0,PI/3*2);
popMatrix();
}
void draw() {
background(150);
float angle = frameCount / 120.0 * PI;
for (int i = 0; i < 10; i++) {
drawShell(angle*(i+1) + (i%2)*PI, 40+i*50, 50+i*50, 80+i*50);
}
}