Issue 232 in webp: Red and blue colors change during jpg converstion to webp

96 views
Skip to first unread message

we...@googlecode.com

unread,
Dec 8, 2014, 5:32:03 PM12/8/14
to webp-d...@webmproject.org
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 232 by zin...@gmail.com: Red and blue colors change during jpg
converstion to webp
https://code.google.com/p/webp/issues/detail?id=232

What steps will reproduce the problem?
cwebp input_jpg.jpg -o output_webp.webp

What is the expected output? What do you see instead?
The red and blue letters experience color change during conversion to webp.

What version of the product are you using? On what operating system?
libwebp v0.4.1 Also present in most recent Master Branch.

MIPS: fix functions to use generic BPS istead of hardcoded value …
djpimg authored 4 days ago
Change-Id: I2d68abef886eff7f8df230f155b758dccd7d04fd

Windows 7


Please provide any additional information below.
May be related to Issue 218: Image's colors change when converted to WebP



Attachments:
input_jpg.jpg 340 KB
output_webp.webp 46.0 KB

--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings

we...@googlecode.com

unread,
Dec 8, 2014, 7:11:44 PM12/8/14
to webp-d...@webmproject.org

Comment #1 on issue 232 by jz...@google.com: Red and blue colors change
This could be due to the color profile or the fact that the input is 444.
Can you try '-pre 4' to see if it helps in this case?

we...@googlecode.com

unread,
Dec 9, 2014, 1:56:47 AM12/9/14
to webp-d...@webmproject.org
Updates:
Status: Started
Owner: pascal.m...@gmail.com

Comment #2 on issue 232 by pascal.m...@gmail.com: Red and blue colors
change during jpg converstion to webp
https://code.google.com/p/webp/issues/detail?id=232

the color change is mostly due to the yuv444->yuv420 downsampling.
Using the '-pre 4' option helps in that case, by using a 'smart' converter
for yuv420,
albeit a slower one than the default.

Attached, the result from 'cwebp input_jpg.jpg -pre 4 -o
output_pre4_webp.webp'
(using code at HEAD)

Attachments:
output_pre4_webp.webp 47.5 KB

we...@googlecode.com

unread,
Jan 9, 2015, 4:03:58 PM1/9/15
to webp-d...@webmproject.org

Comment #3 on issue 232 by zin...@gmail.com: Red and blue colors change
Thank you for looking at this. The -pre 4 option seems to correct the red
letters, however the blue letters now show shades of red that do not exist
in the input.

Attachments:
zoom_input.jpg 36.0 KB
zoom_pre4_webp.jpg 46.0 KB

we...@googlecode.com

unread,
Jan 15, 2015, 7:13:34 AM1/15/15
to webp-d...@webmproject.org

Comment #4 on issue 232 by pascal.m...@gmail.com: Red and blue colors
change during jpg converstion to webp
https://code.google.com/p/webp/issues/detail?id=232

the color bleeding seems to be an "expected" chroma compression artifact,
that one starts to see when quality setting is getting lower. Chroma plane
is quantized more aggressively than luma one, and in this particular case
(thin blue features over a white background) its shows more prominently
than usual.

I tried raising the quality to -q 90, and the effect is less pronounced
(while the file size is still reasonable).
See example attached.

Attachments:
output_pre4_q90.webp 70.8 KB

we...@googlecode.com

unread,
Apr 1, 2015, 2:36:47 PM4/1/15
to webp-d...@webmproject.org

Comment #5 on issue 232 by zin...@gmail.com: Red and blue colors change
That looks great, pascal. Do you know when -pre 4 is going into a release?
It's disabled in 0.4.3, because of the flag in encode.h

#define WEBP_ENCODER_ABI_VERSION 0x0202 // MAJOR(8b) + MINOR(8b)

we...@googlecode.com

unread,
Apr 3, 2015, 8:52:42 AM4/3/15
to webp-d...@webmproject.org

Comment #6 on issue 232 by pascal.m...@gmail.com: Red and blue colors
change during jpg converstion to webp
https://code.google.com/p/webp/issues/detail?id=232

There's ongoing work to make it faster (like:
https://gerrit.chromium.org/gerrit/74014). Right now this function is still
too slow to be switched on by default.
But, agreed, we'll activate this function asap by removing this VERSION
check, even if it's not made default for RGB->YUV conversion.

we...@googlecode.com

unread,
Apr 3, 2015, 3:11:57 PM4/3/15
to webp-d...@webmproject.org

Comment #7 on issue 232 by jz...@google.com: Red and blue colors change
This check only exists in the 0.4.x release branches for compatibility
purposes. 0.5.0 branched from master will expose the function, but there
are still a few things to be done before we release that. To test this for
now a tip of tree build will be best.
Reply all
Reply to author
Forward
0 new messages