第一部分:
一直有波浪的圈圈,
迴圈一直跑,看了頭很暈
程式碼:
void setup(){
size(500,500);
}
void draw(){
background(255);
for(int i=-1;i<20;i++){
for(int j=-1;j<20;j++){
float a=500.0/18.0;
float r=a*2-10;
float t=((i+j)*5+frameCount)/13.0;
noFill();
ellipse(i*a, j*a, r, r);
fill(0);
ellipse(i*a+r*cos(t), j*a+r*sin(t), 5,5);
}
}
}
-----------------------------------------------------------------------------------------------------
沒有留言:
張貼留言