xxxxxxxxxx
const canvasMag = 0.425;
let pg;
const palette = ["#ffff00", "#00ffff", "#ff00ff"];
const emoji = ["🌺", "🦋", "🥀", "🦄", "🍒"]
function setup() {
createCanvas(2123 * canvasMag, 1461 * canvasMag);
pixelDensity(1 / canvasMag);
strokeJoin(ROUND);
pg = createGraphics(width, height);
noLoop();
}
function draw() {
background(255);
pg.textAlign(CENTER, CENTER);
pg.textSize(600);
pg.text(random(emoji), pg.width / 2, pg.height / 2);
image(pg, 0, 0);
for (let p = 0; p < 50; p++) {
const imgW = random(10, 100);
const imgH = random(10, 100);
const imgX = random(0, width - imgW);
const imgY = random(0, height - imgH);
let img = pg.get(imgX, imgY, imgW, imgH);
img.filter(INVERT);
image(img, imgX, imgY);
}
const imgNum = 15;
for (let q = 0; q < imgNum; q++) {
const imgW = width;
const imgH = random(5, 20);
const imgX = 0;
const imgY = random(height);
push();
let img = pg.get(imgX, imgY, imgW, imgH);
tint(random(palette));
const deltaX = random(-100, 100);
noStroke();
fill(255);
rect(0, imgY, width, imgH*0.9);
image(img, deltaX, imgY);
pop();
}
}