xxxxxxxxxx
void setup()
{
size(500,540);
background(0);
}
void draw()
{
noStroke();
background(0);
translate(250,270);
float sec=map(second(),0,60,0,2*PI);
float min=map(minute(),0,60,0,2*PI);
float hr=map(hour(),0,12,0,2*PI);
float d=map(day(),0,365,0,2*PI);
pushMatrix();
fill(random(255));
rect(141,93,114,177);
rect(-17,255,148,19);
popMatrix();
pushMatrix();
rotate(sec);
println(degrees(sec));
fill(255,0,0);
rect(-250,-270,224,210);
popMatrix();
pushMatrix();
rotate(-sec);
println(degrees(sec));
fill(255,255,255);
rect(-17,-270,267,210);
popMatrix();
pushMatrix();
rotate(min);
println(degrees(min));
fill(255,255,255);
rect(-250,-41,224,120);
popMatrix();
pushMatrix();
rotate(-min);
println(degrees(min));
fill(255,255,255);
rect(-17,-41,267,120);
popMatrix();
pushMatrix();
float hr2=map(hour(),0,60,0,4*PI);
rotate(hr2);
println(degrees(hr2));
fill(255,255,255);
rect(-197,93,171,177);
popMatrix();
pushMatrix();
rotate(d);
println(degrees(d));
fill(0,0,255);
rect(-17,93,148,153);
popMatrix();
pushMatrix();
rotate(hr);
println(degrees(hr));
fill(#FEFF0A);
rect(0,0,44,177);
popMatrix();
}