PetaPixel

A Higher Quality Setting in Photoshop Sometimes Reduces JPEG Quality

While looking into the new compression service JPEGmini yesterday, the following statement caught my eye in an interview they did with Megapixel:

[…] sometimes you increase the quality setting in Photoshop and the actual quality of the image is reduced…

I had never heard of that before, so I decided to dig a little deeper.

According to an article cited in the interview, there’s a fundamental change that happens between the values 6 and 7 when choosing the JPEG save quality in Photoshop:

What many people don’t know is that there is a quirk in the way that Photoshop defines its quality range. […] Quality level 6 is the last point in which chroma subsampling is used. At Quality level 7 and higher, no chroma subsampling is used at all. With the amount of color information encoded now doubled, the file size would have naturally increased significantly at this level versus the previous level.

However, it is likely that Adobe decided to allocate the various quality levels with some relationship to the final compressed file size. Therefore, Adobe chose a poorer luminance and chrominance compression quality (i.e. higher level of compression) in Quality level 7 than Quality level 6! What this means is that the image quality of Quality level 7 is actually lower than Quality level 6.

Did you catch that? What they’re saying is that there’s a different compression strategy is used for a quality of 7 compared to 6. Holding the JPEG image quality constant, this change would normally drastically increase the file size of the photograph. However, not wanting to have a giant leap in file size between 6 and 7, Adobe actually reduces the image quality when going from 6 to 7 in order to compensate for the larger file size!

So basically, don’t ever use a quality of 7 when saving JPEGs with Photoshop. Either use 6, or something higher than 7 if you want to actually increase the quality of the photo.

JPEG Compression Quality from Quantization Tables [ImpulseAdventure]


P.S. Another interesting fact found in the article is an explanation of why the quality values go from 1-12 instead of the standard 1-10. They say it’s because the maximum value people are expected to use is 10. For the values 11 and 12 (included for “experimental reasons”), you don’t actually get much noticeable change in image quality, but file size balloons like crazy!


 
  • Jen_u_win

    What about 8, 9, 10…are they worse than 6, too?

  • http://www.facebook.com/Rawwhhh Ashley Bennett

    Yeah, is 7 the ONLY number that reduces quality apart from 1-5?

  • http://oceanaircycles.com/ Rob

    any idea how this plays into the 1-100 scale in Lightrom?

  • http://profiles.google.com/slimspidey Spider- Man

    I saved a 5×30 panorama as 12 and it came out sharp and awesome. So I wonder if saving as 10 would have changed that?

    OY PHOTOSHOP WHY YOU SO HARD!?

  • http://www.petapixel.com Michael Zhang

    Apparently Lightroom’s 0-100 is mapped to Photoshop’s 0-12 (only 13 quality outputs for 101 different value options), and the change happens between 47-53 quality and 54-61 quality, which corresponds exactly to Photoshop’s 6-7.

    http://regex.info/blog/lightroom-goodies/jpeg-quality

  • http://www.petapixel.com Michael Zhang

    No, they should be better quality, but lead to noticeably larger files.

  • Jan

    No it wouldn’t, maybe if you would resave it multiple times you could see some degradation after a while, but if you just save your tiff as jpeg to send to the print shop 10 is fine.

  • http://twitter.com/zeptom Joakim Bidebo

    So that’s the same in Save for web in PS (Save for web also use 0-100) as in Lightroom?

    I never really use anything else then save for web in PS or just use LR.

  • http://www.petapixel.com Michael Zhang

    Hmm. Not sure about Save for Web. I think I read that Lightrooms 0-100 isn’t the equivalent of Photoshop’s Save for Web, so it might be different.

  • http://www.petapixel.com Michael Zhang

    Hmm. Not sure about Save for Web. I think I read that Lightrooms 0-100 isn’t the equivalent of Photoshop’s Save for Web, so it might be different.

  • http://profiles.google.com/slimspidey Spider- Man

    well I guess I’ll keep it 10 from now on LOL thanks!

  • http://shutterpopphoto.com Spencer Hopkins

    Not sure why someone would ever save at 6 or 7 quality. I guess people have their reasons, but whenever I need a good looking yet smaller file, scaling down then using Save for Web is a good method and I can keep the high quality original file.

  • http://shutterpopphoto.com Spencer Hopkins

    Not sure why someone would ever save at 6 or 7 quality. I guess people have their reasons, but whenever I need a good looking yet smaller file, scaling down then using Save for Web is a good method and I can keep the high quality original file.

  • http://shutterpopphoto.com Spencer Hopkins

    Not sure why someone would ever save at 6 or 7 quality. I guess people have their reasons, but whenever I need a good looking yet smaller file, scaling down then using Save for Web is a good method and I can keep the high quality original file.

  • gcruz

    I want my jpeg quality to go to 11

  • Oliver Seidel

    In case you’re interested:

    I have done a side by side comparison of JPEG compression results between *Riot* & *JPEGmini*, here:https://plus.google.com/111262146038004038186/posts/SQhs4JMf3Ay

  • Boyd

    Like Spinal Tap’s amps go to 11 so they’re louder than anyone else, your pictures would be better than anyone elses.

  • http://www.facebook.com/matt.clara Matt Clara

    This must be somewhat dependent on the contents of the image itself, yes?

  • http://pulse.yahoo.com/_JH2RRLQJIKDZR6M6FEAKHTSLDM kruemi

    That’s what happens when using software that tries to be smart. And when den developers think that the users are too stupid to understand the stuff anyway.

    I know, the gimp-jpeg dialog is bigger and not really intuitive. But with preview enabled I can choose quality with a slider from 1% to 100%, can choose the subsampling and other stuff and directly see the result in the preview as well as the resulting file size. So I can decie what I want and what settings are best for me (and my image). Not every image needs the same settings. Sometimes the photoshop settings do really myke sense. Sometimes apparently not… I like software that let’s me do it the way I want it.

    And as about saving with values >95%. Don’t do it! Use tiff if you want lossless (or png for that matter).
    And just as a nice finger training to make your own observations:
    – Take an image (best develped from raw saved as tiff)
    – Save it with different compression settings
    – load the jpg image again as a layer over the original
    – let photoshop make a difference image (i.e. by subtracting one image from the other)
    – Now you see every difference between the images as non black pixels. You won’t see any difference with settings over 90% with “natural” images (i.E. photos).

    Once you found out what is acceptable for you note it down and be happy.

    For web use I found 75% quality quite good enough (I don’t know what setting this would be in PS). People are not going to pixel peep on the images on a website. But they will notice long loading times!

  • http://pulse.yahoo.com/_JH2RRLQJIKDZR6M6FEAKHTSLDM kruemi

    Sure. JPEG has it’s biggest weaknesses with hard edges within big unicolor areas (fast change of frequency). For example power lines or building edges in a uniform blue sky.

    And easy way to reduce the size for images that are used for the web is to remove the preview. Removing the exif information can save you some kb as well.

  • http://pulse.yahoo.com/_JH2RRLQJIKDZR6M6FEAKHTSLDM kruemi

    Don’t use jpg for saving images that you might want to work on again later. Use tiff, png or psd (preferable if you only work with photoshop anyway).
    For putting it on the web you can reduce the quality quite a bit without loosing a lot. It is more critical when printing.

  • http://pulse.yahoo.com/_JH2RRLQJIKDZR6M6FEAKHTSLDM kruemi

    There is an interesting article here already: http://www.petapixel.com/2010/02/04/saving-jpeg-photos-hundreds-of-times/

    Just to note that this only applies if you save the image, close it an open it again. It does NOT happen if you click on “save” 500 times.

    And I can’t imagine a workflow where someone would have to open an image and work on it more than 2 times!
    For intermediate saving use tiff, png or psd. This will save you from such worries.

  • Anonymous

    wow, this should be documented and written there in big bold letters! Anybody knows if Save for Web has the same limitations? I will have to check on that.

  • http://twitter.com/zeptom Joakim Bidebo

    But then saving those extra KB on a JPEG ain’t that important anymore tho. :) Not that many anymore that use Internet on a modem. All my friends have at least 5Mbit (I have 100Mbit) and the web host cost of storage is lot cheaper now days.

    It was important on the 90th tho where most people where using <512Kbit and web hosts often just had a storage of 1-100MB.

  • http://twitter.com/zeptom Joakim Bidebo

    But then saving those extra KB on a JPEG ain’t that important anymore tho. :) Not that many anymore that use Internet on a modem. All my friends have at least 5Mbit (I have 100Mbit) and the web host cost of storage is lot cheaper now days.

    It was important on the 90th tho where most people where using <512Kbit and web hosts often just had a storage of 1-100MB.

  • http://www.lenmoserphotography.com/ Len Moser

    I often wondered why the JPEG quality in Photoshop goes from 1 to 12, while in camera raw the maximum is only 10.  Now I know.  Thanks for sharing.

  • Fred

    We get that you got it

  • http://twitter.com/richardford Richard Ford

    Boyd ruined the gag for us all.

  • http://twitter.com/Soiden Sebastián Soto

    Never wondered about the 1-12 scale instead of 1-10 :P
    Now, I always save my JPEG at least in 10.

  • http://twitter.com/Soiden Sebastián Soto

    Never wondered about the 1-12 scale instead of 1-10 :P
    Now, I always save my JPEG at least in 10.

  • http://twitter.com/Soiden Sebastián Soto

    Never wondered about the 1-12 scale instead of 1-10 :P
    Now, I always save my JPEG at least in 10.

  • http://twitter.com/Soiden Sebastián Soto

    Never wondered about the 1-12 scale instead of 1-10 :P
    Now, I always save my JPEG at least in 10.

  • http://twitter.com/Soiden Sebastián Soto

    Never wondered about the 1-12 scale instead of 1-10 :P
    Now, I always save my JPEG at least in 10.

  • http://twitter.com/Soiden Sebastián Soto

    Never wondered about the 1-12 scale instead of 1-10 :P
    Now, I always save my JPEG at least in 10.

  • Piratejabez

    Thanks, Michael for looking into this, but I disagree with your conclusion that quality 7 should never be used. For my work, I notice a huge and consistent visual loss of quality between 6 and 7; 6 looks much worse due to the chroma compression (reds especially). For this reason I almost never save at quality 6 or below.

    You can try this for yourself by saving an image with red text; see what happens in the save preview when you compare 6 and 7. It comes down to personal preference, but to me, the sacrifice in chroma compression far outweighs the slight boost in luminance compression between 6 and 7.

    I agree that there’s some non-intuitive stuff going on here, but I see Adobe’s reasoning for making it the way they did.

  • Piratejabez

    Thanks, Michael for looking into this, but I disagree with your conclusion that quality 7 should never be used. For my work, I notice a huge and consistent visual loss of quality between 6 and 7; 6 looks much worse due to the chroma compression (reds especially). For this reason I almost never save at quality 6 or below.

    You can try this for yourself by saving an image with red text; see what happens in the save preview when you compare 6 and 7. It comes down to personal preference, but to me, the sacrifice in chroma compression far outweighs the slight boost in luminance compression between 6 and 7.

    I agree that there’s some non-intuitive stuff going on here, but I see Adobe’s reasoning for making it the way they did.

  • Piratejabez

    Thanks, Michael for looking into this, but I disagree with your conclusion that quality 7 should never be used. For my work, I notice a huge and consistent visual loss of quality between 6 and 7; 6 looks much worse due to the chroma compression (reds especially). For this reason I almost never save at quality 6 or below.

    You can try this for yourself by saving an image with red text; see what happens in the save preview when you compare 6 and 7. It comes down to personal preference, but to me, the sacrifice in chroma compression far outweighs the slight boost in luminance compression between 6 and 7.

    I agree that there’s some non-intuitive stuff going on here, but I see Adobe’s reasoning for making it the way they did.

  • Piratejabez

    Thanks, Michael for looking into this, but I disagree with your conclusion that quality 7 should never be used. For my work, I notice a huge and consistent visual loss of quality between 6 and 7; 6 looks much worse due to the chroma compression (reds especially). For this reason I almost never save at quality 6 or below.

    You can try this for yourself by saving an image with red text; see what happens in the save preview when you compare 6 and 7. It comes down to personal preference, but to me, the sacrifice in chroma compression far outweighs the slight boost in luminance compression between 6 and 7.

    I agree that there’s some non-intuitive stuff going on here, but I see Adobe’s reasoning for making it the way they did.

  • Boyd

    OK I guess I could have been a bit more subtle, but I thought it was too obscure a reference for the average reader.

  • Nparker8

    “”And I can’t imagine a workflow where someone would have to open an image and work on it more than 2 times!”” -Really?!

  • http://www.flickr.com/photos/47218202@N02/ Nparker8

    i agree

  • Amkcasca

    I am shocked

  • http://twitter.com/topscientist Top Scientist

    And I can’t imagine anyone dumb enough to save anything as jpg unless it’s the final file.

  • http://twitter.com/andrewccm andrewccm

    Shooting for news wires requires full resolution images to be kept around 2MB. When shooting with a camera such as 5D3, etc.. saving at lower levels is a necessity for their automated ingesting tools to work properly.

  • michael kinney

    Link didn’t work, but would like to see this.