xxxxxxxxxx
30
let rectWidth = 8;
let rectHeight = 100;
let yLoc;
function setup() {
createCanvas(400, 400);
yLoc = random(height)
rectMode(CENTER)
// let r = random(100);
// let g = random(100);
// let b = random(100);
// noLoop();
}
function draw() {
background(255);
for (let i = rectWidth/2; i < width; i += rectWidth){
let noiseValue = noise(frameCount*0.01, i*0.001);
let angle = noiseValue * TWO_PI;
// yLoc = noiseValue*height;
push();
translate(i, yLoc);
rotate(angle);
rect(0, 0, rectWidth, rectHeight);
pop();
}
}