🎨 Draws over the entire canvas with a color or image.
Like the color function, this function can accept colors in a wide range of formats: CSS color string, grayscale value, and color component values.
color
await Canvas(200, 100);background('crimson'); Copy
await Canvas(200, 100);background('crimson');
q5.draw = function () { background(0.5, 0.2); circle(mouseX, mouseY, 20);}; Copy
q5.draw = function () { background(0.5, 0.2); circle(mouseX, mouseY, 20);};
🎨 Draws over the entire canvas with a color or image.
Like the
colorfunction, this function can accept colors in a wide range of formats: CSS color string, grayscale value, and color component values.