-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Add JPEG XL Open/Read support via libjxl #7848
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
base: main
Are you sure you want to change the base?
Conversation
for more information, see https://pre-commit.ci
|
May you please commit the images as LFS? |
|
Do you mean those |
|
They already setup lfs and they only use for other larger stuff. Let it stay as you did. |
Removed jxl feature
for more information, see https://pre-commit.ci
|
Mac OS builds were failing because clang complained about goto labels being declared before variables in scope. |
|
I've merged in And this is failing to build for me with: Full log: log2.txt |
Thanks for reporting. The |
Not only that, Google seems now to "consider" to add JXL back to Chrome. https://groups.google.com/a/chromium.org/g/blink-dev/c/WjCKcBw219k/m/NmOyvMCCBAAJ They will add it, they just try to save face right now by talking nonsense about now seeing "developer signals". |
42a1b66 to
285c9ad
Compare
6219234 to
0503c3d
Compare
2f64f24 to
612de5a
Compare
@j99ca if you have any sample float32 JXL image that we can distribute as part of our test suite under the Pillow license, that would be helpful. Ideally, with an attached version in another format so that we know if we have read it correctly |
5c4a55b to
52912c3
Compare
0cbf808 to
f2082ab
Compare
fc49a44 to
7db30e0
Compare
82f7e02 to
e24b3eb
Compare
|
I've created libjxl/libjxl#4548 with my latest problem in this PR, if anyone here has wisdom to offer. |

Helps #4247
This PR enables opening and reading JPEG XL images and animations.
Supported image modes are: RGB, RGBA, RGBa, L, LA, La.
A relatively recent libjxl version is needed to compile Pillow with libjxl support.
The main changes are the addition of
_jxl.candJxlImagePlugin.py.I'm also the author of jxlpy so this PR was influenced by the work of contributors there. This PR is also largely based on
WebPImagePlugin.pywhich had similar implementation.Why?
JPEG XL has recently seen increased adoption especially in Apple ecosystem. A lot of users are requesting Pillow support for JPEG XL as their products use Pillow and need to be able to handle
jxlfiles.I'm open to suggestions and comments. I understand such change would need a lot of testing and probably changes. After all Pillow would need to become somewhat dependent on libjxl. Creating documentation will not be a big problem however I decided to wait for feedback from Pillow core developers.