2008年5月6日 星期二

花!!


void setup(){
size(600,600);
background(0);
smooth();
stroke(255,120);
}
void draw(){
if (mousePressed == true){
translate(mouseX, mouseY);
for (int i=0;i<25; i++)
{
strokeWeight(i);
rotate(PI/12);
line(0, 0, 100, 0);
stroke(random(0,255),random(0,255),random(0,255),180);
fill(random(0,255),random(0,255),random(0,255),180);
triangle(30,40,20,50,60,20);
}
}
}

沒有留言: