WebP quality options

Reported bugs that have been closed and/or resolved

Moderators: helmut, XnTriq, xnview, Dreamer

Post Reply
Danny
Posts: 578
Joined: Sat Sep 04, 2004 5:09 pm

WebP quality options

Post by Danny »

Since lossy WebP images store colors in YUV format with 4:2:0 chroma sub-sampling, they tend to have severe color bleeding even at high quality settings.

A good if not necessary means to improve on that is to use the "sharp_yuv" parameter of cwebp (the command line tool). It'd be great, if XnConvert supported that in its WebP settings.

Other options would be nice to have, too, of course, but aren't as pressing IMHO.
nooneinpart
Posts: 4
Joined: Thu Dec 29, 2022 12:33 am

Re: WebP quality options

Post by nooneinpart »

Hi all,

I created an account so I could also ask for this feature. WebP's default subsampling behavior just does not look as good as it could without Sharp YUV enabled. There's quite a handy example displayed on another forum here: https://irfanview-forum.de/forum/progra ... ests/12925

As shown, enabling Sharp YUV improves the areas around the color boundaries by quite a decent amount, putting it nearly at parity with the original PNG. This would improve WebP performance when encoding digital artwork, where sharp color boundaries can be quite prevalent. As another example, here's a section from a digital "poster" I made with red text over a background.
livyexcerpt.png
livyexcerpt.png (84.3 KiB) Viewed 2180 times
Here's a CWEBP encode done with

Code: Select all

-q 100 -m 6
(and converted back to PNG for consistency):
livyexcerpt_q100.png
livyexcerpt_q100.png (90.03 KiB) Viewed 2180 times
And this is what it looks like with

Code: Select all

-q 100 -m 6 -sharp_yuv
:
livyexcerpt_q100_sharp.png
livyexcerpt_q100_sharp.png (92.73 KiB) Viewed 2180 times
With Sharp YUV enabled, the color of the red text appears nearly as sharp as the original, whereas without it there seems to be a sort of dark inline despite being encoded at quality 100.

None of the various save presets (Default, Photo, Picture, Drawing, Icon, Text) seem to enable this feature, so it would be nice if it could be added as a separate encoding option, maybe in an upcoming release.

Thank you!
User avatar
xnview
Author of XnView
Posts: 46235
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: WebP quality options

Post by xnview »

See issue for current status and some details.
Pierre.
User avatar
xnview
Author of XnView
Posts: 46235
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: WebP quality options

Post by xnview »

This problem is supposed to be fixed in XnView MP 1.4.1. Please check and confirm the bug fix here.
Pierre.
nooneinpart
Posts: 4
Joined: Thu Dec 29, 2022 12:33 am

Re: WebP quality options

Post by nooneinpart »

I have tested XnView MP 1.4.1 and I can confirm that the new "Use sharp (and slow) RGB->YUV conversion" setting operates correctly and provides an output matching that of the test files from the command line encoder with Sharp YUV enabled.

Thanks once again!
Danny
Posts: 578
Joined: Sat Sep 04, 2004 5:09 pm

Re: WebP quality options

Post by Danny »

Cheers!
Post Reply