xxxxxxxxxx
25
let points = [];
let xoff = 0;
let inc = 0.01;
function setup() {
createCanvas(800, 400);
for (let i=0; i<width; i++){
noiseDetail(4);
let n = map(noise(xoff), 0, 1, 0, height);
// let n = random(0, height);
points[i] = n;
xoff += inc;
}
}
function draw() {
background(246,242,228);
strokeWeight(2);
for (let i=0; i<width-1; i++){
// point(i, points[i]);
line(i, points[i], i+1, points[i+1]);
}
}