xxxxxxxxxx
16
function setup() {
createCanvas(400, 400);
colorMode(HSB);
noStroke();
}
function draw() {
background(220);
let leftHue = map(mouseX, 0, width, 0, 360);
fill(leftHue, 100, 100);
rect(0, 0, width/4, height);
for (let i = 1; i < 4; i +=1) {
fill((leftHue + i*30)%360, 100, 100);
rect(width/4*i, 0, width/2, height);
}
}