-
-
Notifications
You must be signed in to change notification settings - Fork 101
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
"sharp_yuv"-option #267
Comments
Found solution in the documentation
Maybe add similar option to imagickbinary? To be able to set additional parameters, e.g. "-define webp:use-sharp-yuv=1" |
It seems to be an overlooked option, which deserves to be promoted in webp-convert, by implementing it as a separate option. Will do! |
Which default do you think would be appropriate? |
Setting default to "off" would be sensible in the sense that it doesn't change the current behavior. But on the other hand, it is a weak argument if "on" generally provides better visual quality. Before deciding, it should be tested how much longer conversion takes with this setting. We don't want big images to take forever to convert. |
I implemented the option for cwebp and imagemagick. It is called "sharp-yuv" (note the dash rather than underscore). I will see if it can be implemented in more converters before I close the issue |
ffmpeg and vips does not currently support the sharp_yuv option, which means I'm done |
Actually, I just discovered that vips does support use_sharp_yuv. It just called it something else! ("smart-subsample"). This means I must deprecate that special option for vips and use "sharp-yuv" instead Bwt: Found out by looking in the Vips sourcecode: https://github.com/libvips/libvips/blob/master/libvips/foreign/vips2webp.c |
Created a new issue for it: #280 |
…=true" - to keep in line with the other definitions. #267
Hello! I think, jpeg's also need "on" by default. Potentially, in autogeneration-mode (on demand, for example) this give higher picture quality at the cost of an insignificant increase in bytes. Me using sharp_yuv with %86-quallity, and result is great (better is avif only). |
But, by several hostings installed cwebp 0.3.0, which haven't "-sharp_yuv" command. This may cause error during converting with "on"-option by default. |
Good thing you discovered this before it was published :) The solution is to only pass the option to versions of cwebp that supports it. We must now examine which versions of cwebp that supports the option. |
It seems that the sharp_yuv option it was added in cwebp 0.6.0-rc2: |
Yes, cwebp 0.5.0 fails with the following error (when called with the option): |
Fixed for cwebp. |
Reopened, because it must be checked for imagickbinary with old libraries installed |
Hello! Tested on ImageMagick 6.9.10-68 Q16 x86_64 2021-02-24 with CentOS Linux release 7.9.2009 (Core) Launched two command, and visually result haven't differences (in my opinion, webp:use-sharp-yuv=1 isn't working on this version, but I cannot verify it exactly, because generally using cwebp and haven't any test VPS).
Also processed test picture with cwebp, using these commands (to compare sharp_yuv between imagemagick and cwebp):
Result images also available here |
Ok, as expected. Thanks for testing! ImageMagick, GraphicsMagick and their extensions generally ignore unknown options - at least on newer libraries. Just wanted to be completely sure that the old libraries didn't abort when called with unknown options. |
@HDDen: Just want to let you know that I just released 2.6.0, so the sharp-yuv option is available now |
What about passing "sharp_yuv"-argument to cwebp? It increases result's webp quality, especially on contrast red-blue patterns. Details, for example, is here https://www.ctrl.blog/entry/webp-sharp-yuv.html
The text was updated successfully, but these errors were encountered: