phalcon / phalcon

[WIP] Phalcon Framework. Work will continue after release of v5.0
https://phalcon.io
MIT License
219 stars 46 forks source link

[BUG]: Phalcon\Image\Adapter\GD: When resizing .png loosing transparency #83

Open veryayskiy opened 3 years ago

veryayskiy commented 3 years ago

Description When using Phalcon\Image\Adapter\GD resize() method on png with alpha channel the new image has a black background.

Steps to reproduce the behavior:

$image = new \Phalcon\Image\Adapter\GD('image-with-transparent-background.png'); //image with a transparent background
$image->resize(500,500); //any new size
$image->save(); //after saving the image has a black background

Probably need to add imagealphablending();

ghost commented 3 years ago

Isn't this v5.0 issues? I think you need to post this @ https://github.com/phalcon/cphalcon/issues