I would like to provide webp images for browsers which support this image format.
We have big images (533x800) and small images (240x360) of the same photo.
As a first step I was interested in a comparison of small images in jpg and webp format.
So I created two webp images in two different ways:
1) resize big image by convert utility with Lanczos filter (resized_q100.jpg) and then convert it to webp format (external_resize_q90.webp)
2) both resize and compress by means of cwebp (internal_resize_q90.webp)
Results are:
external_resize_q90.webp contains visible artifacts. It appears as white lines around man.
These artifacts exist even if lossless compression is used. I thought lossless compression has no difference with original and was rather surprised with such a difference.
I used Chromium Version 28.0.1500.71 Ubuntu 13.04 (28.0.1500.71-0ubuntu1.13.04.1) to compare quality visually.
Artifacts don't exist if internal resize is used (see internal_resize_q90.webp). But seems like internal resize is worse than Lanczos one.
I have two questions:
1. Is these artifacts is a bug or artifacts comes from design of compression format and can't be fixed? Please note that artifacts exist even with lossless compression. May be it is possible to get rid of these artifacts by using some command line options?
2. Is it possible to change resize algorithm used by cwebp with some command line option?
I'm going to create webp alternative of images for relatively big site and now I'm blocked with these issues.
Here are images:
resized_q100.jpg

external_resize_q90.webp

internal_resize_q90.webp

external_resize_lossless.webp

What steps will reproduce the problem?
wget http://static.kupivip.ru/V0/00/97/87/59/1b.jpg
convert 1b.jpg -filter Lanczos -resize 240x360 -quality 100 resized_q100.jpg
cwebp -m 6 -resize 240 360 -q 90 1b.jpg -o internal_resize_q90.webp
cwebp -m 6 -q 90 resized_q100.jpg -o external_resize_q90.webp
cwebp -lossless resized_q100.jpg -o external_resize_lossless.webp
What version of the product are you using? On what operating system?
I use official build libwebp-0.3.1-linux-x86-64. Operating system is Ubuntu 13.04.