imageresizer transparent white png

104 views Asked by At

Imageresizer is awesome in so many ways.

But, I have a problem with cropping/trimming an all white png.

With png images saved as square image with many transparent pixels either on the top & bottom, or many transparent pixels on the left & right. I cannot crop the image to its transparency maximums.

I’ve been able to use the WhitespaceTrimmer with 100% success on images with color information at the transparency edge, but I have a few 100% white logos & the WhiteSpaceTrimmer results in a 3x3 pixel (like here), since it's trimming all the whitespace - the whole image.

I’m just looking for a solution to crop/trim a 100% white transparent png to a bounding box of all opaque pixels.

Thanks!

1

There are 1 answers

0
dhulting On

Imageresizer Support (a.k.a. Nathaniael Jones) asnwered my question. Transparency is not conscidered when doing the energy calculation.

They would need to re-implement the WhitespaceTrimmer in C++ to maintain performance. This involves Imageresizer's custom development team.