Have you tried Google's jpegli encoder? I find that it generally matches webp for most image types. Quantized png is usually best for anything with a limited color palette though.
Does AVIF carry the same patent risks as full/motion AV1?
(I’m not saying I support the claims or not, I have no idea about their technical and let alone legal merit, just thinking that there are attempts at enforcement against sites streaming AV1 and whether choosing AV1 puts say my site at risk)
Hard to say, but possibly less since it's a still image, not a video, so it inherently corresponds only to a part of AV1.
No need to worry about these risks for using it though. You can never say that no patent troll will surface tomorrow for literally anything. That's not a reason not to use things.
> Even YouTube is preparing to move beyond AV1 and begin streaming video using AV2, potentially as early as 2027. If a company handling the enormous amount of video that YouTube does sees the benefits of a more efficient format, shouldn't the rest of the internet be taking a closer look at what we can do with images and video too?
not an odd argument. AVIF is based on AV1, so what they mean is that since we accept YouTube's AV1 usage as mainstream nowadays, so should be it's image part
AVIF consumes around 25 times more CPU during encoding as JPEG. Take this in consideration if you pay for the power consumption. And on the user-facing side, if you upload an images it takes f.ex. 12 seconds (sic!) and not half a second.
12 seconds? It takes 7 seconds on my phone, in a wasm runtime using an older version of the encoder.
From my experience throwing random JPEGs at it, it's 3 to 4 times smaller, that's a good chunk of data saved, which in turn is a lot of energy saved on visitors' radios being active.
Unlike with jpeg, you don't need 85 or 95 percent on the quality score, 50 is more than good enough for most pictures on a website.
If you're hosting images and want a fully lossless encoding the CPU time may become a factor, but if you're hosting user generated content, I don't think it's all that bad. Plus, you can just move the encoding part to the user side of the equation and pretend it's part of the upload progress bar if you're desperate to pay the power bill.
Because whenever I download an image and its webp, the next thing i do is i google "webp to png/jpg" conversation because yeah service XY or Tool Z doesn't support it.
Or my Fire TV Stick :(
I configure my nginx to serve everything available though. Thats what i can do.
You can throw almost any image format with open standards into squoosh.app if you're still using software that doesn't open webp.
It's been a while since Photoshop finally got support, though, I can't recall the last time webp posed a problem for me. Then again I don't use a Firestick, no idea how that would deal with image formats, I guess it's no longer being maintained?
Enough keyframe-based "image" formats, please! The internet and the world at large needs a real and proper modern format, not some quick hacks from bored engineers that only contribute to the endless fragmentation online and do not leverage any existing infrastructure for serving video. There's more than just crappy ultra-low-quality thumbnails around. WebP, AVIF are the webscale equivalent of serving images.
You could make an argument that we should have AVIF everywhere on the web. But if you want a single image format to be everywhere, I think JPEG-XL is just better suited. AVIF has restrictions on resolutions and number of planes, and doesn't do lossless very well. It's competitive with AVIF on lossy image quality (even though yes, AVIF does seem like it tends to consistently have the advantage there).
Image formats goes in era, and there's no need for monoculture. But given we're talking exabytes of data, for this era, the author rightly articulates why AVIF should win. Should JPEGXL2 beat it in the future then it can take over for a decade. We seem to essentially have gone through like 4 formats so far: gif, jpg, PNG and webp. On vector side, SVG has no real competition - it's solid.
> Jpeg-XL's key win was only lossless translation of existing jpeg to a modern format.
Huh?
JpegXL is the only widely supported format (once it comes to the various browser as is planned) that can store true HDR linear images in floating point (fp16 and fp32) formats.
AVIF can only do 10 bit integer ranges, sure that HDR compared to 8bit but it is not sufficient for useful extended range color spaces.
Agree, though I do miss the clarity of if an image is lossy or lossless just by extension. (Obviously a png could be produced from a heavily compressed jpg, but it is still a handy heuristic in my image pipelines)
Only just started habitually using WebP...
I added AVIF support to my personal image resizing tool recently - https://tools.simonwillison.net/image-resize-quality - I mostly use that for screenshots though, and WebP works better for those.
Have you tried Google's jpegli encoder? I find that it generally matches webp for most image types. Quantized png is usually best for anything with a limited color palette though.
> for screenshots though, and WebP works better for those
Interesting! Better in terms of more quality preserved or smaller file size? Have you found other types of images where this applies?
Does AVIF carry the same patent risks as full/motion AV1?
(I’m not saying I support the claims or not, I have no idea about their technical and let alone legal merit, just thinking that there are attempts at enforcement against sites streaming AV1 and whether choosing AV1 puts say my site at risk)
[delayed]
Yes. It’s just an AV1 container. Doesn’t even need to be limited to a single frame (just like GIF and APNG).
Hard to say, but possibly less since it's a still image, not a video, so it inherently corresponds only to a part of AV1.
No need to worry about these risks for using it though. You can never say that no patent troll will surface tomorrow for literally anything. That's not a reason not to use things.
> Even YouTube is preparing to move beyond AV1 and begin streaming video using AV2, potentially as early as 2027. If a company handling the enormous amount of video that YouTube does sees the benefits of a more efficient format, shouldn't the rest of the internet be taking a closer look at what we can do with images and video too?
Odd argument.
Image isn’t video and we are not YouTube.
not an odd argument. AVIF is based on AV1, so what they mean is that since we accept YouTube's AV1 usage as mainstream nowadays, so should be it's image part
AVIF consumes around 25 times more CPU during encoding as JPEG. Take this in consideration if you pay for the power consumption. And on the user-facing side, if you upload an images it takes f.ex. 12 seconds (sic!) and not half a second.
12 seconds? It takes 7 seconds on my phone, in a wasm runtime using an older version of the encoder.
From my experience throwing random JPEGs at it, it's 3 to 4 times smaller, that's a good chunk of data saved, which in turn is a lot of energy saved on visitors' radios being active.
Unlike with jpeg, you don't need 85 or 95 percent on the quality score, 50 is more than good enough for most pictures on a website.
If you're hosting images and want a fully lossless encoding the CPU time may become a factor, but if you're hosting user generated content, I don't think it's all that bad. Plus, you can just move the encoding part to the user side of the equation and pretend it's part of the upload progress bar if you're desperate to pay the power bill.
Regular JPEG can also be compressed much more than it usually is:
https://symbiogenesis.github.io/DotJpegli/
However, video would matter so much more than images, to the overall internet, that images don't even matter by comparison.
It's pretty frustrating that JPEG encoding generally got stuck with libjpeg-turbo.
Absolutely agree, for my photo portfolio website AVIF allows me to serve higher quality photos faster to potential clients.
I’ll just drop my AVIF local support for Wordpress plugin here: https://github.com/ddegner/avif-local-support
Yeah why not?
Because whenever I download an image and its webp, the next thing i do is i google "webp to png/jpg" conversation because yeah service XY or Tool Z doesn't support it.
Or my Fire TV Stick :(
I configure my nginx to serve everything available though. Thats what i can do.
You can throw almost any image format with open standards into squoosh.app if you're still using software that doesn't open webp.
It's been a while since Photoshop finally got support, though, I can't recall the last time webp posed a problem for me. Then again I don't use a Firestick, no idea how that would deal with image formats, I guess it's no longer being maintained?
Enough keyframe-based "image" formats, please! The internet and the world at large needs a real and proper modern format, not some quick hacks from bored engineers that only contribute to the endless fragmentation online and do not leverage any existing infrastructure for serving video. There's more than just crappy ultra-low-quality thumbnails around. WebP, AVIF are the webscale equivalent of serving images.
Say more please, what’s up with keyframes?
Maybe a middle out compression is the way to go.
Yes, but sites are super slow to enable it.
* https://gitlab.com/gitlab-org/gitlab/-/work_items/428012
* https://github.com/orgs/community/discussions/138164
I swear I saw this exact post here on HN last week
Seems about time we have ANOTHER round of serious investigations into collusion in the memory industry artificially driving up prices ...
Don't you mean JPEG XL?
JPEG XL vs. AVIF for web use-cases
https://news.ycombinator.com/item?id=50120224
Jpeg-XL's key win was only lossless translation of existing jpeg to a modern format. Mostly for archives where you don't want a lossy translation.
In terms of picture quality for given size, AVIF has it solidly beat.
You could make an argument that we should have AVIF everywhere on the web. But if you want a single image format to be everywhere, I think JPEG-XL is just better suited. AVIF has restrictions on resolutions and number of planes, and doesn't do lossless very well. It's competitive with AVIF on lossy image quality (even though yes, AVIF does seem like it tends to consistently have the advantage there).
Image formats goes in era, and there's no need for monoculture. But given we're talking exabytes of data, for this era, the author rightly articulates why AVIF should win. Should JPEGXL2 beat it in the future then it can take over for a decade. We seem to essentially have gone through like 4 formats so far: gif, jpg, PNG and webp. On vector side, SVG has no real competition - it's solid.
The author is explicitly arguing for an AVIF monoculture. AVIF isn't an appropriate format for an image format monoculture, but JPEG-XL could be.
"We should use AVIF for most web images" is a different statement which I have no problem with.
> Jpeg-XL's key win was only lossless translation of existing jpeg to a modern format.
Huh?
JpegXL is the only widely supported format (once it comes to the various browser as is planned) that can store true HDR linear images in floating point (fp16 and fp32) formats.
AVIF can only do 10 bit integer ranges, sure that HDR compared to 8bit but it is not sufficient for useful extended range color spaces.
Agree, though I do miss the clarity of if an image is lossy or lossless just by extension. (Obviously a png could be produced from a heavily compressed jpg, but it is still a handy heuristic in my image pipelines)