Sybio/ImageWorkshop

White or Black bars with PNG and transparent background

Closed this issue · 0 comments

Q A
Bug report? no
Feature request? yes
Usage question? yes
PHP version used 7.2

Hello,

I have a similar problem of the following issue : #95

In short, black bars are appearing in my case too.

I searched in the library code, and I found this :
https://github.com/Sybio/ImageWorkshop/blob/2.0.9/src/PHPImageWorkshop/Core/ImageWorkshopLayer.php#L1564

Why don't we just add imagecolortransparent($image) in the next line, in case of $backgroundColor equals transparent ? I tested it directly in the lib, it works like a charm ^^'

Thanks in advance for your answer :)