xxxxxxxxxx
19
let noiseX = 0.0
function setup() {
createCanvas(400 , 400);
}
function draw() {
// Move over one pixel every frame
let x = frameCount;
// Scale the noise value to the height of the canvas
let y = noise(noiseX) * 400;
point(x, y);
// Increase the noise x position a little bit each tick of the draw loop
noiseX = noiseX + 0.01;
}