const { createCanvas, loadImage } = require('canvas');
const canvas = createCanvas(1000, 200)
const ctx = canvas.getContext('2d');
loadImage("https://cdn.discordapp.com/avatars/276060004262477825/80ec456b92db2eabbcca79bd9bf07ee6.png?size=4096")
.then(image => {
ctx.fillStyle = "rgb(0, 0, 0)";
ctx.fillRect(0, 0, 1000, 200);
ctx.drawImage(image, 250, 250, 250, 250);
ctx.fillStyle = "rgba(255, 255, 255, 0.5)";
ctx.fillRect(500, 140, 450, 30);
const fs = require("fs");
const out = fs.createWriteStream(__dirname + '/test.png')
const stream = canvas.createPNGStream()
stream.pipe(out)
out.on('finish', () => console.log('The PNG file was created.'))
});
@pale vessel master, one of your disciples is in serious trouble
help him
