xxxxxxxxxx
38
function setup() {
createCanvas(400, 400);
}
function draw() {
background("black");
let dias = map(mouseX, 0, width, 0,250)
fill("#FFFFFF")
noStroke();
circle(0,0,dias);
circle(400,0,dias);
circle(400,400,dias);
circle(0,400,dias);
fill("#FFC107")
noStroke();
let dia = map(mouseX, 0, width, 0,200)
circle(0,0,dia);
circle(400,0,dia);
circle(400,400,dia);
circle(0,400,dia);
let parameter = map(mouseY, 0, height, 200, 800)
fill("#E91E63")
circle(width/2,height/2,parameter/4);
fill("#2196F3")
let side_length = map(mouseY, 0, height, 0, mouseX)
square(200,200,-dia/4);
square(200,200,dia/4);
fill("#FFFFFF")
text('Please use your mouse to draw a circle on the canvas', 10, 20);
}