( ′∀`)σ≡σ☆))Д′)レ(゚∀゚;)ヘ=З=З=Зε≡(ノ´_ゝ`)ノ HEX
HEX
Server: Apache/2.4.58 (Ubuntu)
System: Linux mail.thebrand.ai 6.8.0-107-generic #107-Ubuntu SMP PREEMPT_DYNAMIC Fri Mar 13 19:51:50 UTC 2026 x86_64
User: www-data (33)
PHP: 8.3.6
Disabled: NONE
Upload Files
File: /var/www/html/tmpr/../tmpr/..//tmpr/..//tmpr/../roundedimages.php
<?php $filename = "v/uploads/raw/cf8b44b8a5faa9f819f1a8c7aac6a168.jpg";
$backgroundX_s = imagecreatefromstring(file_get_contents($filename));
$width = imagesx($backgroundX_s);
$height = imagesy($backgroundX_s);

$newwidth = 200;
$newheight = 200;

$backgroundX = imagecreatetruecolor($newwidth, $newheight);
imagealphablending($backgroundX, true);
imagecopyresampled($backgroundX, $backgroundX_s, 0, 0, 0, 0, $newwidth, $newheight, $width, $height);

//create masking
$mask = imagecreatetruecolor($newwidth, $newheight);

$transparent = imagecolorallocate($mask, 255, 0, 0);
imagecolortransparent($mask,$transparent);

imagefilledellipse($mask, $newwidth/2, $newheight/2, $newwidth, $newheight, $transparent);

$red = imagecolorallocate($mask, 0, 0, 0);
imagecopymerge($backgroundX, $mask, 0, 0, 0, 0, $newwidth, $newheight, 100);
imagecolortransparent($backgroundX,$red);
imagefill($backgroundX, 0, 0, $red);

//output, save and free memory
header('Content-type: image/png');
imagepng($backgroundX);
imagepng($backgroundX,'output.png');
imagedestroy(imagecopy);?>