Friday, August 27, 2010

Raw compression explained

This picture is from La Rochelle, in France. It's an old customs building, adjacent to the port's fortifications, in very good shape. La Rochelle used to be a very important French port during the Middle Age.

The picture is a 3-exposure HDR, taken a f/6.7, ISO 100, 19mm, tonemapped in Photomatix and adjusted in Photoshop (cleaned a corner with an annoying dark cloud, sharpened and increased detail in the bricks of the building).

It also shows the tragic fate of my 16-50mm f/2.8 Pentax lens: this one is among the most damaged pictures, just look at how soft it is on the right side. Fortunately I composed with the subject on the left side. :-)

Raw compression explained

I found this very interesting article today which explains what the mechanism and impact of Nikon's lossy RAW compression are. It has taken some time finding explanations that are scientific enough, so I thought I'd share it.

In very, very short: the lossy compression reduces the 12-bit depth to a 9.4-bit depth, but in a way that makes a lot of sense. Because the sensor captures light in a linear way, but we see it in a logarithmic way, the same absolute difference of tonal levels will have a lot of impact on detail in the shadows, while it will have less impact in the highlights. Or, to put it another way, the single brightest f-stop spans over half the sensor's range, while darker f-stops take up much less of that same range. Thus the lossy compression maps the sensor's recorded tonal levels with a function that does not alter them in the shadow parts but compresses them in the highlight areas, because you won't see the impact (it's almost a "waste" to have so many possible tonal values in the highlights, it's more than you can see). The potential negative impact lies in the heavy retouching work you might want to do to bring detail back: in such cases, posterization risk is increased. Go a head and read it, it will be clearer!

I have yet to make up my mind on whether to use this feature and save space, or turn it off and play it safe!

No comments:

Post a Comment