You can edit the below JavaScript code to customize the image tool.
Apply Changes
function processImage(originalImg, summonText = "КЕША, ПРИДИ!", glowColor = "#00ffcc", magicIntensity = 30) {
const canvas = document.createElement("canvas");
const width = originalImg.width;
const height = originalImg.height;
canvas.width = width;
canvas.height = height;
const ctx = canvas.getContext("2d");
// Draw the original image
ctx.drawImage(originalImg, 0, 0, width, height);
// Darken the background to give a magical summoning vibe
ctx.fillStyle = "rgba(0, 0, 0, 0.65)";
ctx.fillRect(0, 0, width, height);
const cx = width / 2;
const cy = height / 2;
const radius = Math.min(width, height) * 0.35;
const intensity = Number(magicIntensity) || 30;
// Apply magical glow
ctx.shadowBlur = intensity;
ctx.shadowColor = glowColor;
ctx.strokeStyle = glowColor;
ctx.fillStyle = glowColor;
ctx.lineWidth = Math.max(2, radius * 0.015);
// Draw outer summoning circle
ctx.beginPath();
ctx.arc(cx, cy, radius, 0, Math.PI * 2);
ctx.stroke();
// Draw inner summoning circle
ctx.beginPath();
ctx.arc(cx, cy, radius * 0.85, 0, Math.PI * 2);
ctx.stroke();
// Draw summoning pentagram inside
ctx.beginPath();
for (let i = 0; i <= 5; i++) {
const p = (i * 2) % 5;
const angle = -Math.PI / 2 + (p * 2 * Math.PI / 5);
const x = cx + Math.cos(angle) * (radius * 0.85);
const y = cy + Math.sin(angle) * (radius * 0.85);
if (i === 0) {
ctx.moveTo(x, y);
} else {
ctx.lineTo(x, y);
}
}
ctx.stroke();
// Draw magical runes / text between the circles
const runes = ["К", "Е", "Ш", "А", "П", "О", "Я", "В", "И", "С", "Ь", "🦜"];
ctx.font = `bold ${Math.max(10, radius * 0.1)}px Courier New, monospace`;
ctx.textAlign = "center";
ctx.textBaseline = "middle";
for (let i = 0; i < runes.length; i++) {
const angle = -Math.PI / 2 + (i * 2 * Math.PI) / runes.length;
const rx = cx + Math.cos(angle) * (radius * 0.925);
const ry = cy + Math.sin(angle) * (radius * 0.925);
ctx.save();
ctx.translate(rx, ry);
// Rotate text to follow the circle's curvature
ctx.rotate(angle + Math.PI / 2);
ctx.fillText(runes[i], 0, 0);
ctx.restore();
}
// Embed the ultimate Kesha (Parrot) in the center of the pentagram
ctx.shadowBlur = intensity / 2; // reduce blur for emoji clarity
const emojiSize = radius * 0.6;
ctx.font = `${emojiSize}px sans-serif`;
ctx.fillText("🦜", cx, cy + emojiSize * 0.1); // slight y-adjustment for better optical centering
// Draw primary Summon Text
ctx.shadowBlur = intensity;
ctx.shadowColor = "#000000";
const titleSize = Math.max(16, radius * 0.25);
ctx.font = `bold ${titleSize}px Impact, sans-serif`;
ctx.fillStyle = glowColor;
// Top summoning text
ctx.fillText(summonText, cx, cy - radius - (titleSize * 0.8));
return canvas;
}
Apply Changes