JPEG data loss when saving?

Weatherstorm

Well-known member
Messages
202
Reaction score
0
Location
CA, US
I keep hearing that JPEGs lose quality whenever they are altered/saved. Does anybody have a side-by-side comparison of such data loss? Or any articles that show the amount of data loss? I sometimes heavily alter my images and the quality gets better (due to the type of editing I do)... so I don't understand what the fuss is about. Thanks!
 
Data loss within JPEG's is a complicated issue...best seen than explained. If you have Photoshop CS then "save for the web" and then you will see a comparison of the type of compression that is being applied to the image. JPEG also has a knack of washing out colours.

You may think you are getting better images because of your type of editing, but because of the way JPEG compression works, every time you edit and save you are editing more compression data, rather than the detail that was caught when the picture was taken.

I'm a digital artist by trade and in the editing process we always use a lossless file format...basically because I want to edit the colours and data that I have control over...in lossy file formats some of that control is lost.

Cheers
 
I keep hearing that JPEGs lose quality whenever they are
altered/saved. Does anybody have a side-by-side comparison of such
data loss? Or any articles that show the amount of data loss? I
sometimes heavily alter my images and the quality gets better (due
to the type of editing I do)... so I don't understand what the fuss
is about. Thanks!
The way that JPEG works is to throw away data that it thinks you won't notice, in order to reduce the file size, when you save it. OK, that's a very simplistic explanation, but I'm guessing you won't want the full explanation based on sine waves, etc, from my Computer Science course notes that I could give :-) Repeated saving will gradually degrade image quality - you'll get increased pixellation, noise patterns, and sharpening halos. However, at high quality settings, it's not really noticeable until a lot of saves have been made - kind of insidious really.

If you want to see a worst case scenario, create a dark-coloured diamond, on a white background, and save it with a bit of compression. It should become quite pixellated.

Don't have any side by side pictures though - sorry.
 
OK, that's a very simplistic explanation, but I'm guessing you
won't want the full explanation based on sine waves, etc, from my
Computer Science course notes that I could give :-)
Ah, what the heck, if you want the full explanation of what it does, how it works, and what artifacts you're going to get, the Wikipedia article is pretty thorough: http://en.wikipedia.org/wiki/JPEG
 
Try this:

make a copy of an image, open the copy in an image editor, and then save it without editing. Then save the image over and over and after several savings you will notice the degradation. But this shouldn't be a big problem, because the image starts to visually degrade only after several savings.

Best regards,
Sebastjan
 
Does it degrade only when saving at higher compression? I always save my files as "excellent quality" (Quality setting 12 i believe). Most of the time it actually INCREASES the file size when I do that... this is on Photoshop. So I was assuming it went to extra efforts to keep all of the qualty intact.
 
I did it over 100 times to an image. No one could tell which was the original and which one had been opened and saved 100 times. This was a little over a year ago. I used Nikon View to do this.
Save the same image 20 times at the highest quality setting. Do you
see any difference?

--
Charles / Equipment in profile / http://www.pbase.com/okeo
--
Everything happens for a reason.
  1. 1 reason: poor planning
 
Weatherman, you already appear to know more about this than these other people. JPEG has a variable compression rate. At Excellent quality there won't be a visible change.

Advice to save at "compress for the web" and then see that JPEGs lower quality is absolutley stupid.

Pavi is right.

--
ShooterPS
 
Most people crop as their last editting process, but I've recently found jpeg lossless cropping and I do that first and then edit for colors and levels etc after cropping.

I use a free program called JPEGcrops. Faststone also does lossless jpeg cropping.

Neither Nikonview nor Irfanview do. I'm also pretty sure that Photohop and Nion Capture don't have this feature.

Guy Moscoso
 
Does it degrade only when saving at higher compression? I always
save my files as "excellent quality"
Technically, no, the process of converting to the JPEG file format (i.e. encoding the image from the application to a file on disk), will* degrade the quality of the image - this is why it's classed as "lossy" (destructive) compression. Obviously the difference is more noticable at higher compression ratios/lower quality settings. However, as I and others have said, at the highest quality settings, I doubt you'd be able to tell the difference between the original and a copy that had been saved as a JPEG a few times at 100%.

from a technical perspective, this should probably read "almost always", as I'm sure it's possible to create an image that will not change at all when encoded as a JPEG. However, I highly doubt that this would occur in a "real world" situation.

Read the WikiPedia article if you want a correct, technical explanation. :-)
 
Making multiple saves of a JPEG, without any changes to the image, should not degrade the resulting images. If an image has not been changed, then the algorithms, used by the JPEG compression, should see nothing further to compress; and, the saved image should be the same as the original image. So, saving over and over, without making any changes to the image, should not result in any degradation of the image. In other words, there should be no further compression from save to save.

If, however, the image is changed in any manner, then the JPEG algorithm will recompress the file, and there will be some degrading of the image. The amount and types of the changes will have an effect on how the file willl be compressed, and, therefore, on how much loss of information there will be in the resulting JPEG save.

Cliff
Save the same image 20 times at the highest quality setting. Do you
see any difference?

--
Charles / Equipment in profile / http://www.pbase.com/okeo
--
http://www.pbase.com/cliffb
 
Better editing software (Photoshop CS) will not re-render the portions of a Jpeg that have not changed. So re-saving an unaltered image will have no impact. With CS, from what I have read, you can even change a section of an image and only that affected segment will be re-rendered. Note that any global change such as Curves, Contrast etc.. will affect the entire image.

--
D70 SB800 18-70 50mm/f1.8 70-300ED/f4
http://www.pbase.com/solfried
 
Weatherman, you already appear to know more about this than these
other people. JPEG has a variable compression rate. At Excellent
quality there won't be a visible change.

Advice to save at "compress for the web" and then see that JPEGs
lower quality is absolutley stupid.

Pavi is right.

--
ShooterPS
Hmm...save for web is a good way to see how compression affects an image because you have a side by side comparrison.

JPEG is a lossy file format so saving at any quality setting WILL affect quality.

Having worked with digital effects for 20 years I like to think I have some clue as to what I'm talking about.

Why do you think lossless formats are always worked with at the editing stage within the film industry?

Cheers
 
Having worked with digital effects for 20 years I like to think I
have some clue as to what I'm talking about.

Why do you think lossless formats are always worked with at the
editing stage within the film industry?

Cheers
No one disputes that jpg compression is not lossless. This is basic knowledge. The fact that the loss almost always has to be measured with a computer is basic knowledge. It is very hard if not impossible for most people to see with their eyes.

--
Everything happens for a reason.
  1. 1 reason: poor planning
 
I have some nice close ups of flowers takem with my little Nikon point and shoot. I am saving the jpeg keepers "as" nef files before doing any processing on them. To my way of thinking I have created "negatives" which will not further degrade at all.

What do y'all think?
--
Regards
Clive Liddell
Pietermaritzburg, South Africa
 
It's the best you can do with what you have. You have some compression due to the internal jpeg processing, but it won't get worse.

Provided of course that further saves (after the nef) are tif files.
I have some nice close ups of flowers takem with my little Nikon
point and shoot. I am saving the jpeg keepers "as" nef files
before doing any processing on them. To my way of thinking I have
created "negatives" which will not further degrade at all.

What do y'all think?
--
Regards
Clive Liddell
Pietermaritzburg, South Africa
 
Clive,

Nikon is trying to pull a fast one on us. They are starting to force us use NEF so we can use some of their fancy features on their editing programs. If you need one of those functions that only can be used from a NEF file, then you have to save as NEF. But if the picture started as jpeg, it's really not going to get any better than the original jpeg.

If you are sort of suggesting that jpegs deteriorate, you are wrong. When you save a jpeg again and again- at lower quality jpeg compression, yes, you can have problems- but you are not doing that are you?.

The fact that you are asking about this means that jpeg is good enough for your abilities at present. Now if you were to ask about taking a picture from the start in NEF on a NIkon camera, that is another question. Ask that question seperately.

Guy Moscoso
I have some nice close ups of flowers takem with my little Nikon
point and shoot. I am saving the jpeg keepers "as" nef files
before doing any processing on them. To my way of thinking I have
created "negatives" which will not further degrade at all.

What do y'all think?
--
Regards
Clive Liddell
Pietermaritzburg, South Africa
 
Just a question when we "save for the web" are we not more or less optimising the image so that Joe bloggs down the road can access this image quicker on his computer?

In an age where broadband/cable/ connections are the norm is this really neccesary any more?? Maybe I've got it all wrong as normal? Please enlighten me.
--



be bop ba loo lop bu lop bam bam
 
Ah, but you are forgetting one important detail... we should 'save for the web' when we share, so that only we have a good quality copy to make nice enlargements and prints ;)

I'm not disputing that there is some loss. But at excellent quality, saved in Photoshop, it is 100.0% percent indistinguishable from the previous version when viewed at all reasonable sizes. I zoomed way in to check, and thought I could 'sort of' tell a difference, then realized I was looking at pixels almost an inch wide... that would be a billboard 250 feet wide!

--
ShooterPS
 

Keyboard shortcuts

Back
Top