xxxxxxxxxx
38
let myFont;
function preload() {
myFont = loadFont('SpaceGrotesk-Light.otf');
}
function setup() {
createCanvas(800, 800);
background('#ccc');
fill('red');
stroke('12');
strokeWeight(2);//épaisseur du contour
//noStroke();
rect(400,250,180,180);
fill('green');
stroke(100);
strokeWeight(10);
rect(20,20,30,30);
ellipse(150,150,200);
arc(50, 50, 80, 80, 0, PI + QUARTER_PI, PIE);
stroke(250);
fill(0);
textSize(150);
text('bonjour', 200, 390);
textFont(myFont);
text('hel\nlo', 200, 590);
}
function draw() {
}