xxxxxxxxxx
//variáveis para o diâmetro das pizzas
let tamPizzaG;
let tamPizzaP;
let img;
function preload() {
//carregar a imagem antes de tudo
img = loadImage('https://deckard.openprocessing.org/user3417/visual1612966/h6eba2de5af63015753eaa5fe6a3b68ce/pizza_PNG43991_2.png');
}
function setup() {
createCanvas(windowWidth, windowHeight,WEBGL);
//modo WEBGL para usar uma imagem como textura do circulo
background(0);
tamPizzaG=width*0.2;
tamPizzaP=tamPizzaG/2;
}
function draw() {
texture(img);
ellipse(width/9*-1,0,tamPizzaG,tamPizzaG);
texture(img);
ellipse(width/9,0,tamPizzaP,tamPizzaP);
}