我使用绘制圆的处理创建了一个循环,整体形状应该是一个圆.然而,它们主要靠近X和Y轴绘制.我已经随机化了它的位置微积分的角度,我看不出问题出在哪里.
代码如下:
for (int omega = 0; omega<1080; omega++){ //loop for circle creation
radius = (int)random(80); //random radius for each circle
int color1= (int)random(100); //little variation of color for each circle
int color2= (int)random(100);
int locationY = (int)(sin(radians(omega))*random(width/2+1)); //location calcualtion
int locationX = (int)(cos(radians(omega))*random(width/2+1));
fill(0,color1+200,color2+200,50);
ellipse(locationX,locationY,radius,radius); //draw circles
}