xxxxxxxxxx
var counter = 0;
function setup() {
createCanvas(windowWidth, windowHeight);
background(0);
}
function draw() {
background(0);
rectMode(CENTER);
translate(10, height / 2);
let num = map(mouseX, 20, width, 10, 400);
//let num = map(sin(millis()/1000), -1, 1, 10, 200);
for (let y = 0; y < num; y += 1) {
let rot = map(y, 0, num, 0, PI);
let posx = map(y, 0, num, 0, width);
//let col = map(y, 0, num, 0, 255);
//stroke(col);
push();
translate(posx, 0);
rotate(rot);
noFill();
stroke(20, 95, 110, 100);
//rect(0, 90, 200, 50);
arc(100, 150, mouseX, 200, 100, PI);
//line(0, 200, 200, 0);
pop();
}
}