Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WebP transparency support #1923

Open
JokaJukka opened this issue Aug 17, 2023 · 1 comment
Open

WebP transparency support #1923

JokaJukka opened this issue Aug 17, 2023 · 1 comment

Comments

@JokaJukka
Copy link

Please describe the new functionality as best as you can.

Hey there!
As webp is becoming a new standard for images on the web, I would like to ask you if you are comsidering supporting transparency for webp images?
Nowadays when I include a webp image in the pdf, it will render it with black background, and the non-transparent parts look quite choppy.

Thanks for any information!

@finwe
Copy link
Member

finwe commented Aug 18, 2023

PDF itself has no internal support for wepb images, AFAIK. At least not in versions officially supported by mPDF.

Currently, WEBPs are internally converted to JPG, which has no transparency capabilities, but are smaller than 24bit PNGs would.

It will always be more precise to convert WEBPs to appropriate format on user side based on desired outcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants