xxxxxxxxxx
let w = 100;
let h = 200;
function setup() {
createCanvas(874, 620);
background(255);
rectMode(CENTER);
}
function draw() {
translate(50, height/2);
for (let i=0; i<100; i+=10) {
for(let y=0; y<30; y+=0.5) {
push();
//let a = map(i, 0, 30, 0, 90);
let sw = map(i, 0, 100, 1, 20);
translate(i*15, y*15, 0);
//rotate(a);
rotate(sw);
rect(0, 0, w, h);
//ellipse(0, 0, w, h);
pop();
}
}
for (let x=0; x<5; x+=10) {
//ellipse (375, -200, 75, 75);
ellipse(375, -200, mouseX, mouseY);
}
/*
rect(125, height/2, w, h);
rect(200, height/2, w, h);
rect(275, height/2, w, h);
rect(350, height/2, w, h);
rect(425, height/2, w, h);
rect(500, height/2, w, h);
rect(575, height/2, w, h);
rect(650, height/2, w, h);
rect(725, height/2, w, h);
rect(800, height/2, w, h);
*/
}