lunes, 20 de enero de 2020

RELOJ ANALÓGICO

int R=250;
float angulo=0;
void setup(){
fullScreen();
background(0);
smooth();
}
void draw(){
noStroke();
fill(0,20);
rect(0,0,width,height);
ellipseMode(CENTER);
stroke(255);
strokeWeight(2);
fill(255,20);
ellipse(width/2,height/2,600,600);
strokeWeight(10);
stroke(255);
point(width/2,height/2);
strokeWeight(2);
stroke(255,0,150);
line(width/2,height/2,width/2+R*cos(angulo),height/2+R*sin(angulo));
angulo=angulo+0.005;
}
Share:

0 comentarios:

Publicar un comentario