zen-browser / desktop

🌀 Experience tranquillity while browsing the web without people tracking you!
https://zen-browser.app
Mozilla Public License 2.0
17.98k stars 439 forks source link

Complete JPEG-XL Support #726

Closed gianni-rosato closed 2 months ago

gianni-rosato commented 2 months ago

What feature would you like to see?

Currently, there is a flag disabled by default to support the JPEG-XL image format which works similarly to Firefox Nightly. This is great! However, there's a bit more to the story when it comes to complete JXL support:

Other details

Here's a proper implementation (via Waterfox):

waterfox_jxl

And here's Zen's current implementation (presumably carried over from Firefox Nightly):

zen_jxl

I think it is super awesome that the JPEG-XL flag is enabled in the first place, but this is an opportunity to go the extra mile for JXL support as it continues to improve elsewhere. The entire Apple ecosystem supports JPEG-XL, and Cloudinary cites serving billions of JPEG-XL images regularly. In addition, there are rumors that the iPhone 16 may shoot JPEG-XL images by default.

If you're interested in making this work, I can point you in the direction of the patchset & connect you with some developers who may be interested in helping make this work. Zen is really cool by the way, and given this issue is addressed, I'll happily switch from Waterfox to Zen without question! Thanks for your great work!

mauro-balades commented 2 months ago

This is fixed for the next release

junedabat commented 2 months ago

As of 1.0.0-a.35, JPEG-XL support still isn't enabled by default for me.

image

Setting the image.jxl.enabled flag in about:config to true manually does enable it, but animated JPEG-XLs don't work.

Essentially, the problem is the same. image

zzzsyyy commented 1 month ago

As of 1.0.0-a.39, the jxl support is still incomplete

onzecki commented 1 month ago

This is fixed for the next release

JXL is now indeed enabled by default but it still lacks the patches needed for the aforementioned issues to be fixed. Check the JPEG XL test page to see it yourself. The issue isn't quite yet resolved.

NOCanoa commented 1 month ago

@onzecki are the patches in ff under a about:config flag? or wold we need to do it ourselvs?

onzecki commented 1 month ago

@onzecki are the patches in ff under a about:config flag? or wold we need to do it ourselvs?

As @gianni-rosato mentioned, they're not under FF sadly, however several Firefox forks, (Waterfox f.e., as mentioned) have applied patches for animations, transparency, color profiles and more to work correctly

gianni-rosato commented 1 month ago

JXL support continues to be incomplete in 1.0.1-a.7. I think this should be reopened, as the initial issue still exists; any updates?

mauro-balades commented 1 month ago

It would be great if you could send those patches other forks do to have complet jxl

junedabat commented 1 month ago

Here's the history of patches relating to the JXL library in Waterfox : https://github.com/BrowserWorks/Waterfox/commits/current/third_party/jpeg-xl

And here's the link to the JXL lib, https://github.com/libjxl/libjxl/tree/main/lib/jxl

I don't know if this is enough to be any helpful

onzecki commented 1 month ago

I also found this resource describing the patches, which might be useful: https://discussion.fedoraproject.org/t/introducing-a-firefox-package-with-jpeg-xl-enabled/117139

zzzsyyy commented 1 month ago

these links might be useful

https://github.com/BrowserWorks/Waterfox/pull/2938

https://codeberg.org/librewolf/source/src/branch/main/patches/JXL_improved_support.patch