Serene Life

by garik

submit your photo


Hall of Fame
View past winners from this year

Please participate in Meta
and help us grow.

Take the 2-minute tour ×
Photography Stack Exchange is a question and answer site for professional, enthusiast and amateur photographers. It's 100% free, no registration required.

If I take a picture taken with my EOS 60D, put it into Photoshop, edit it as I wish and save it as JPEG with maximum quality, the file goes from 5 to 12 mb in size. Obviously if I didn't increase the resolution, and I am starting with a certain image, I cannot really increase the image quality. So what is it that makes this huge difference? What are those 7 mb that get added to my original file?

Also, if I open the same file in Paint and save it, I can get back to its original size, if not lower. Why?

share|improve this question

3 Answers 3

JPEG is a lossy format and it has variable quality levels which result in larger or smaller file sizes. Whenever you save a file in a lossy format, additional detail is lost, so even though you saved the finished version as a higher quality JPEG, it is still actually lower quality than the original was, despite the growth in the file size. It is still closer to the original image than it would have been if you had used a lower compression quality and re-compressed the image.

Put really basically, JPEG is trying to fit an image to a pattern. The lower the quality of the compression, the more looser the fit is allowed to be, which reduces the file size, but also means more detail is lost. Conversely, a high quality requires that the compressed file much more exactly match whatever you had originally opened, but means that the file also must be much larger.

One other way to think about it is that the actual data held in a JPEG, uncompressed, is much larger than the size of the JPEG. You can open a very highly compressed image or a very slightly compressed image, but both actually have the same number of pixels with the same bit depth, which takes far more space than compressed file size. When you choose a higher quality, you get less compression of that large amount of data than if you use a low quality/high compression setting.

This is one of the reasons that it is best to shoot RAW if you plan on doing post production work on an image because RAW generally does not use lossy compression and will preserve the quality of the image until you are done with your manipulation and ready to make a final export of the image.

share|improve this answer

When you open a JPEG file that was originally saved to a given quality, it will be decoded and decompressed to a certain image in Photoshop. That becomes the new "original" when you save the second time. When you save that image at 100% quality Photoshop tries to preserve whatever image it is as close as possible.

You aren't getting the quality of the original image, you are getting quality approximating the decoded/decompressed representation of the image.

To answer your second question, Paint is using lower than 100% quality.

share|improve this answer

The image in a JPEG isn't encoded as pixel values but as a mathematical function whose output approximates the shapes in the image that is being saved - as AJ said, an attempt to fit it into a pattern. As you increase quality, what you're doing is allowing a more sophisticated approximation, but it will always be an approximation. Eventually, the approximation will have to be more complex than the image itself, and yet it will still be an approximation, so, in that regard, it will still be lossy.

Add to that that the algorithms used vary from program to program, so when you re-save a JPEG that has been created by a different program, you'll be introducing even more error. If the program is the same, the amount of error will exist be be less noticeable because the data lost in the current compression will be more the less the same that had already been lost last time, so, ideally, there is nothing there already to lose. On the other hand, a different program will try to preserve noise that was introduced by others, because it will look at it as data, so not only the noise will be preserved and in modifies form, as there will remain less space to preserve the actual data.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.