PDA

View Full Version : Recent experiments with JPG with unexpected results



OzzieTraveller
11-03-2012, 9:18pm
G'day all

This post covers some recent experiments I have done with JPG saving of images where I would like some feedback from others who have also done experiments.
I am not after comment from arm-chair experts quoting magazines, other internet sites or third-hand pronouncements from other sources

For starters...
I guess that I, like you, have read & been told "don't use JPG, you'll lose too much image quality" ...
I have also read photo magazine articles "claiming & showing test images" that purport to show that JPG images go fuzzy from pixellation if you save a JPG to another JPG - so I decided to try a number of things and see where it got me

Firstly I took a 12mpx [4000 x 3000px] ex-camera jpg image as my 'base-line' image

experiment-1
a) I opened the image [original]
b) then cropped the image to a smaller size
c) then chose 'undo' to return it back to its former size
d) then saved the ex-camera image as JPG > JPG with PS Quality=12/12, & renamed the file as 'image-1'
ie- no real & lasting change to the image occurred, but it was saved JPG > JPG

This was repeated 4 times with image-1 being opened, altered, undone, then saved as image-2; then repeated image-2 to image-3; image-3 to image-4 etc.
The 1st result was- the ex-camera JPG image is 6,2Mb in size, the image-1 -2 -3 -4 & -5 saved images are all 6,1Mb in size and all still 4000 x 3000px in size
Experiment result- no loss of image size either via pixel dimensions or file size

experiment-2
I repeated experiment-1 with a 3mpx [2048 x 1536px] image and using a Win-95 version of Photo Express software [rather than PSE]. The ex-camera image was 1.04Mb in size, ALL the saved images were all 660kb in size when using the default JPG > JPG saving regime
result- again no loss of image size either via pixel dimensions or file size beyond the initial JPG > JPG save

experiment-3
Involved printing the image(s) - I wanted to see what visible changes occurred via JPG > JPG saving of the image
I then saved the 12mpx image [from experiment-1] with JPG > JPG format and set PSE Image Quality as 12/12, then 9/12, then 6/12, then 3/12 and finally 1/12. To ensure no mixups occurred during printing, a small text comment was inserted into each image via a text layer then flattened before saving & printing

I then took the above 12mpx ex-camera jpg image & all the saved copies down to my local print shop. Each was printed as 12" x 8" prints
So with a series of 6x 12" x 8" prints on the table, I sought the comment from the local photo-professional as to each image

He was unable to see any visible difference between any of the 12" x 8" prints - and expressed amazement that the details in the PSE 1/12 quality image was just as sharp as the 12/12 quality image. [the image subject was my missus, and we were looking at the weave of her dress fabric along with fine-ness of her hair] He did locate a very slight colour-shift in one small portion of the image, but stated that "without the original to compare it with, he would not have noticed anything"

Overall he was astonished and could not answer the basic Question - why is there so little IQ difference between PSE quality 12/12 versus 1/12

Attached here is a 1024px image showing a portion of the image from experiment-3, where a new canvas of 4000px wide was prepared and partial images from the experiment-1 images were pasted and some text added. This image has been reduced to <250kb for posting here and you can see the resulting "loss" of sharpness from repeated JPG saves

http://i44.tinypic.com/4hvztf.jpg

So - over to you ... what's going on? ... why do we keep getting told that "JPG > JPG saves will cripple our images?" when quite obviously from the above it does nothing of the sort

Regards, Phil

martycon
11-03-2012, 11:00pm
Thanks for your enquiring mind. I have noticed that sometimes when using high quality save, the file size increases. I presume you reduced file size to < 240k to publish. As you say all are excellent. To be pedantic, I thought that detail of weave on strap around neck of your model is ever so slightly better on the original, and reduces with saves. However, I believe, that we have been given a biased opinion by purists. You have certainly changed my opinion.

Speedway
12-03-2012, 12:08am
I think a lot of this goes back to the days of very low megapixle cameras where a small loss made a big difference, these days with 10+ megapixles you would have to do a lot of reworking and resaving to lose a noticeable amount. I very rarely use RAW as when I have, I have seen virtually no difference in the final image weather converted from RAW or prepared direct from the camera JPEG. The only situation I might use RAW is where the lighting is very difficult.
Also I noticed in your workflow you used the undo option between saves this replaces any data lost in the save so in effect you are working on the original image again meaning no matter how often you repeated this you are still only resaving it once.
Keith.

rodw
12-03-2012, 7:27am
I think a lot of this goes back to the days of very low megapixle cameras where a small loss made a big difference, these days with 10+ megapixles you would have to do a lot of reworking and resaving to lose a noticeable amount.
Keith.

Actually, I think the rule predates digital photography when any photo manipulation was done from a scanned image. It was pretty simple to deal with back then. All you had to do was to save as TIFF or PSD as soon as you first opened it and stay in that format until you were finished editing. In the printing industry, we always worked with TIFF which was lossless and also supported clipping paths which were required to deep etch an image to remove the background.

I think as time has gone on, a lot of the old rules from that era have remained when the technology has improved to a point that many of them have became less important or obsolete.

arthurking83
12-03-2012, 8:18am
Another issue for Phil to muse over is that for a single jpg to jpg file save you aren't going to really see much difference at the size of print you made anyhow.

A point you may have not considered in your testing is that even tho you saved from original to smaller file size, to smaller again and so on, did you close the program you used and do it again?
There may have been no loss in quality from one save to another, because you may have been (inadvertently/unwittingly) been working from a single file buffered into memory and each save being done from this one jpg.

To do this properly you would have to clean out the memory/buffer/cache that the software is using to be sure that from each jpg to jpg save step is actually a single step in the process.
Best way, but most tedious, is to close the software each time you make a save to jpg and manually delete any images in the cache file.
Alternatively, you could simply close the program and open the jpg file with another and do a new jpg save with that other program, alternating between software for each save step.

If you made many edits to the original and then continuously made saves to the jpg format .. say 10 edits and 10 saves to jpg along the way, how does the image subsequently look both on the monitor and in a print.


There are more reasons to shoot in raw as opposed to jpg than just this loss of quality in saving jpgs to jpgs.
The loss of pixel fidelity is just one aspect of the equation.

MarkChap
12-03-2012, 8:31am
Great read Phil, I was always of the belief, that if you chose "save as" and created a new file, as you have done, then you pretty much don't have any file degradation, as you have shown.
I was of the understanding that it is when you open a JPG file, look at it, work on it etc, then just chose "save" so that those changes are saved to the original file is when you got degradation.

rodw
12-03-2012, 12:24pm
Great read Phil, I was always of the belief, that if you chose "save as" and created a new file, as you have done, then you pretty much don't have any file degradation, as you have shown.
I was of the understanding that it is when you open a JPG file, look at it, work on it etc, then just chose "save" so that those changes are saved to the original file is when you got degradation.

I don't think the Save/Save As is an issue with JPEG files but it is certainly a big issue with Adobe software in the creative suite. The reason for this is the adobe software has been optimised for speed of performance from the user's perspective so as you edit objects anything you delete is just marked as deleted in the file and new stuff is appended to the end. By doing a "Save As" the software rewrites the content as one contiguous stream and ignores any of the deleted objects in the original file. This means the new file is streamlined and can be a lot smaller. I have seen 200 Mb pruned off files in this manner. I am not sure if Photoshop PSD's work like this but certainly InDesign, Illustrator and Acrobat do.

Because JPEG is a standard format, there is nowhere to "hide" this deleted data so I doubt if this is the case. It is my understanding that opening a JPEG in Photoshop converted it back to a full bitmapped file format (eg. TIFF or equivalent) that would be preserved in the PSD so that further edits made no difference to the picture quality. However, if you then save the PSD as a JPEG you are then degrading the image via compression. So the moral of the story is to never re-edit a JPEG that has been edited or altered. Always revert to the source file or a non-lossy TIFF or PSD rendition of that original. I think this is the reason why I have seen some tutorials on PS where the first thing the tutor does is to duplicate the image onto a new layer so he can revert to the original content easily by returning to the background layer.