Originally posted by coder
View Post
Announcement
Collapse
No announcement yet.
FFmpeg Lands JPEG-XL Support
Collapse
X
-
Originally posted by arun54321 View PostAre you aware of the fact that jpg output differs between jpg decoders?
One could control for some of that by using a monochrome or 4:4:4 JPEG file and potentially even skipping the colorspace transform - either by outputting native YUV or encoding in RGB (i.e. if the image isn't monochrome).
However, that would tell one less about what we actually want to know, which is the nature and significance of the differences between the original JPEG file and the JPEG-XL version. For that, it would be instructive to stick to more "typical" YUV 4:2:0 files and either analyze the differences between the two decoded outputs or ideally to compute PSNR vs. a raw original.
The potential benefit from this investigation could be informing users interested in maximizing the fidelity of their image collection that their best option would in fact be a full transcode.
Comment
-
Originally posted by coder View PostSure, there are differing DCT/IDCT implementations, as well as how chroma interpolation is performed, how much intermediate precision is carried forward to the colorspace transform, and how it rounds the results. Perhaps I was naive in assuming the reference JPEG-XL tools would treat each of these in a manner consistent with the original libjpeg.
One could control for some of that by using a monochrome or 4:4:4 JPEG file and potentially even skipping the colorspace transform - either by outputting native YUV or encoding in RGB (i.e. if the image isn't monochrome).
However, that would tell one less about what we actually want to know, which is the nature and significance of the differences between the original JPEG file and the JPEG-XL version. For that, it would be instructive to stick to more "typical" YUV 4:2:0 files and either analyze the differences between the two decoded outputs or ideally to compute PSNR vs. a raw original.
The potential benefit from this investigation could be informing users interested in maximizing the fidelity of their image collection that their best option would in fact be a full transcode.
Viewers or decoders are so inconsistent between each other. I can still remember the same .mp4 looked different in brightness / gamma when in Quicktime in comparison to Media Player Classic within the same computer. Factor in variation due to monitors, it is silly for one to expect even the same file can look the same to everyone in the world.
Comment
-
Originally posted by billyswong View PostWhen a conversion is reversible, it is by definition lossless.
Furthermore, the state of reversibility seems affected by the tools. In time, bugs, fixes, or enhancements of other aspects could break the ability to exactly recover the original file. Therefore, I wouldn't depend on this path for lossless recovery of the original image.
Originally posted by billyswong View PostViewers or decoders are so inconsistent between each other.
Originally posted by billyswong View PostI can still remember the same .mp4 looked different in brightness / gamma when in Quicktime in comparison to Media Player Classic within the same computer.
Presumably, JPEG-XL has done the same. If anyone can confirm one way or another, it'd be good to know.
Originally posted by billyswong View PostFactor in variation due to monitors, it is silly for one to expect even the same file can look the same to everyone in the world.
Comment
-
Okay coder you win. Let's see if anyone actually do a more rigorous comparison of "do jxl converted from jpg output exactly the same image" to validate / invalidate the lossless transcoding claim by jpeg-xl. Which method shall we use? Convert both of them into bmp? Or do a printscreen for each of them?
Comment
-
My goal is to learn and educate. Even if I turn out to be wrong, as long as it draws more quality information into the discussion, I figure we all win.
I don't pretend for a second that I'm without an ego, but if I remind myself that learning is what counts, then it's easier to accept being wrong about something.
Originally posted by billyswong View PostLet's see if anyone actually do a more rigorous comparison of "do jxl converted from jpg output exactly the same image" to validate / invalidate the lossless transcoding claim by jpeg-xl.
Originally posted by billyswong View PostWhich method shall we use? Convert both of them into bmp? Or do a printscreen for each of them?
Next, I'd examine the diffs for quantized DCT artifacts around areas with large gradient magnitudes. If we see this in areas of constant chroma (most likely grayscale images), then that's pretty clear evidence they're indeed changing DCT sizes.
Finally, I'd look for chroma fringing around sharp color transitions, with images using 4:2:0 or 4:2:2 chroma sampling. If we see this but not luma atifacts, it would be clear evidence of the decoders using different chroma reconstruction filters.
I guess one more scenario is that differences are basically uncorrelated noise, which could be evidence the JPEG-XL decoder is carrying more intermediate precision between the stages.
The second approach would involve starting with an original raw image. We could encode that to JPEG, then transcode the JPEG to JPEG-XL, and decode both. Now, compute the PSNR between the raw and the decoded JPEG. Do the same for the raw and the JPEG-XL transcoded version. Now, which has the lowest PSNR? It's conceivable that JPEG-XL could actually come out better, by virtue of a better chroma interpolation filter and/or more intermediate precision, assuming everything else (DCT blocks & colorspace) is the same.
- Likes 1
Comment
-
why argue over the use case of a 1Bx1B image? i think the only relevant point here is that no silly arbitrary limit was imposed, or if 1Bx1B is that limit, it was chosen to not be a limiting factor for anyone. how daft do you have to be to argue over the use case of the max possible theoretical thing? if i make a filesystem with no arbitrarily-imposed filesize limit, are you retards going to spend 8 pages of comments arguing over the use case and practicality of an infinitely large file? the autism struggle is real i guess
- Likes 1
Comment
-
Originally posted by coder View Post
The second approach would involve starting with an original raw image. We could encode that to JPEG, then transcode the JPEG to JPEG-XL, and decode both. Now, compute the PSNR between the raw and the decoded JPEG. Do the same for the raw and the JPEG-XL transcoded version. Now, which has the lowest PSNR? It's conceivable that JPEG-XL could actually come out better, by virtue of a better chroma interpolation filter and/or more intermediate precision, assuming everything else (DCT blocks & colorspace) is the same.
I don't see a good way to test this with objective metrics... unless you simply average the diff, perhaps.
Comment
-
Originally posted by brucethemoose View PostIs PSNR going to have any meaning when the outputs are so close to each other? Even a max quality 4:4:4 jpeg will be massively lossy compared to those decoding differences.
Comment
Comment