Skip to content
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

Text gets blurry after recompress #12

Closed
steveh80 opened this issue Oct 6, 2014 · 4 comments
Closed

Text gets blurry after recompress #12

steveh80 opened this issue Oct 6, 2014 · 4 comments
Labels

Comments

@steveh80
Copy link

steveh80 commented Oct 6, 2014

Hi there,

first of all, thanks for that great work. We're considering jpeg-recompress to use in production, but we experience strange behavior when we have text in that image.

I've tried all different compression methods, but text gets blurry with all of them. See attached images. I even tried to use best quality and accurate settings:

jpeg-recompress --accurate --quality veryhigh --min 100 image.jpg image_recompress.jpg

You have any ideas what to do to to get this text sharp? (Adept.sh and jpeg-mini gets it sharp anyway)

Image before recompress:
skyscraper_xenofit_v4

After recompress:
skyscraper_xenofit_v4_recompress

@danielgtaylor
Copy link
Owner

Confirmed this bug, but I'm not sure what might be causing it. I'll need to investigate further as mozjpeg nears its 3.0 release.

@ghost
Copy link

ghost commented Feb 13, 2015

The text gets blurry, because jpeg-recompress allways produce jpeg's with chroma-subsampling.
All jpeg are saved with chroma-subsampling 2x2 (4:2:0). As far as i know, jpeg-recompress uses moz-jpeg source to create jpreg's, and moz-jpeg uses 2x2 as default.

It' would be nice, the next version has an option to keep the original sampling method (1x1,2x1,1x2) or compress all to 2x2.

And btw, thanks for jpeg-recompress.

danielgtaylor added a commit that referenced this issue Apr 8, 2015
For now, this just allows either the default (4:2:0) or disabling subsampling
(4:4:4). Future values could allow more control over the method. This should
address #12.
@danielgtaylor
Copy link
Owner

I've gone ahead and added a method to set 4:4:4 sampling and it produces the correct image, but it compresses to 86% of the original size instead of 78%, so realize that this option may not be desired in the general case and is almost certainly not desired for long-term photo storage.

jpeg-recompress --subsample disable file.jpg compressed.jpg

@danielgtaylor
Copy link
Owner

This fix is now released in version 2.1.0.

danielgtaylor added a commit that referenced this issue Apr 21, 2015
For now, this just allows either the default (4:2:0) or disabling subsampling
(4:4:4). Future values could allow more control over the method. This should
address #12.
szepeviktor added a commit to szepeviktor/jpeg-archive that referenced this issue Jan 19, 2020
danielgtaylor added a commit that referenced this issue Sep 4, 2020
XiNGRZartis added a commit to XiNGRZartis/jpeg-archive that referenced this issue Jan 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants