Aug 092011
 

You may be photographing  in raw rather than jpeg because you know that raw files contain more information and because they are unprocessed, giving you more flexibility.  But how do they contain more information?  Among other things, digital photography raw files are captured at a higher bit depth — depending on the camera, 12, 14 or 16 bit, compared to 8 bit for jpegs.   Whether 12, 14 or 16, these higher bit-depth files potentially contain much more information than 8 bit files.

So what is bit depth?

For each pixel in your image, the tonal value or brightness of the scene you are photographing  is stored in the image file on your memory card, along with the color.   Computer files store information in zeros and ones.  Bit depth refers to how many digits  the tonal information for each pixel is stored in.   Imagine if your camera used a bit-depth of one:  you would have one digit to store how dark each piece of the scene was, the only possible values would be 0 and 1, and the only two tones that could be represented are black and white:

Image From File with Bit Depth of One

This image of course has very little detail, since it contains no shades of gray.

If the file had a bit depth of two, there would be two digits, and the four values of 00, 01, 10, and 11 would be possible, so the image could have black, dark gray, light gray, and white:

Image from File with Bit Depth of 2

Notice that we have gained some detail, but that the image is still very choppy.  In the histogram for this image, below, we see huge gaps between the tones, confirming the choppiness or posterization.  (The histogram is a graph of the tones in an image, going from pure black on the left side to pure white on the right side.)

Histogram for File with Bit Depth of 2

Let’s jump to a file with a bit depth of 5, which allows 2 to the 5th, or 32 possible values from 00000 to 11111:

Image from File with Bit Depth of 5

We gain alot of detail, but there is still obvious posterization in the sky (click on the image to see it larger).  The histogram supports this:

 

Histogram for Image with Bit Depth of 5

Now let’s jump to 8, which allows 2 to the 8th, or 256 values, and is what a jpeg supports:

Image with Bit Depth of 8

Histogram of Image with Bit Depth of 8

This image shows the full detail of the scene with no visible posterization, even when viewed at full size, and the histogram looks much better.  (If you see any posterization, it is not real, but rather just the result of my blog save process.)  So why not stop here, with 8 bits and 256 tones?

The problem is that as soon as you start enhancing your image, you start compressing and expanding the tonal range.  This creates choppiness in the histogram and potentially, visible posterization in your image.  To show this, I took this 8 bit image into Photoshop, and added contrast and darkened it:

Darkened and Added Contrast to 8 Bit Image

Notice how this pulled apart the histogram:

Result of Working 8 Bit Image

The more heavy-handed your adjustments, the more and wider gaps you will end up with in your histogram, and the greater possibility that you will see posterization in your image.  256 tones is often not enough for the fine detail in the image to hold together.

12 bit files have over 4,000 tones, and 14 bit files have over 16,000.  This is vastly better, and with almost any work you could do to an image, it would hold together.  Here is the histogram from the 12 bit version of the above image, with the darkening and increased contrast:

Histogram from 12 Bit Version with Darkening and Contrast Boost

To have this additional “editing headroom”, you have to capture a high bit-depth image, i.e. a raw file, and you have to enhance it as a high-bit depth file.  It does no good to convert a raw file into 8 bit as you move into Photoshop to work it.  While you are working in Lightroom or Camera Raw, your work on your raw file is in 16 bit (standardized to accomodate 12, 14 and 16).  When you move a file from Lightroom or ACR to Photoshop, you need to ensure that the Photoshop file stays in 16 bit.  In Lightroom, go to Edit or Lightroom>Preferences>External Editing, and set your PSD or TIFF preference to 16 bit.  In ACR, click on the workflow options at the bottom of the screen and do the same.

Higher bit depth files also potentially have a much larger number of colors:  an 8-bit  jpeg can represent around 16 million colors, whereas a high bit-depth file can represent over 28 billion.  16 million may seem like enough, but again, with heavy editing, you can see color banding or blotchiness in your photo. Your high-bit-depth photo with billions of potential colors will hold up much better.

The downside to higher bit-depth is larger image files — all else equal, a 16 bit image file is twice as big as an 8 bit image file.  But large memory cards and hard drives are so much cheaper these days than they used to be.

Note: I have printed these histograms from Photoshop. Lightroom smooths out the histogram, so you won’t see these gaps — nevertheless, the quality issue issues still exist.


Share

  69 Responses to “8 bit, 12 bit, 14 bit, 16 bit — What Does It Really Mean to Digital Photographers?”

  1. This is a good explanation. I hope I can remember all of this, the next time someone asks me about raw.

  2. [...] This post was mentioned on Twitter by Scott Rouse, Tawcan and Forrest Tanaka, Alyce Taylor. Alyce Taylor said: 8 versus 16 bit — What Does It Really Mean? http://is.gd/4YXV3 RAW vs JPEG #photography [...]

  3. [...] This post was Twitted by Tawcan [...]

  4. exactly what I was looking for. And now, here comes the consequence:
    does it worth upgrading for a camera that can save in 14bit Raw? (Like 40d or d300..)? I hope it does…

    • Hi Paul, sorry, I just noticed your question. I’m assuming you are asking if it is worth upgrading from 12-bit to 14-bit Raw. I don’t believe so — yes, you would be going from 4,096 tones to 16,384, but I don’t believe you would ever visually notice the difference. Both are just so much higher than a jpeg’s 8-bit 256 tones. Yes, more is better, but I would look to other camera features to justify the expense.

  5. Thank you. I feel your answer is pertinent and correct. I’ve already get used with marketing strategies. Al those fancy features don’t add to image quality so much… I still might choose a 40d for it’s sRAW capability….

    • Hi Paul, just to play devil’s advocate, why pay $1000+ for the ability to get smaller raw files? Why not capture the most information your camera is capable of, and when needed, export downsized jpegs/tiffs from Lightroom? Memory cards and hard drives are cheap these days, exporting (especially using templates) is very quick and easy.

  6. you think like an American… Because I’m NOT an American, and my computing (PC) systems it has also limited resources and I usually downsize all pictures to less than 1500px and so that small raw format is really a good thing. It takes the best of the image, not a lot of useless noisy pixels…
    *Anyway, Lightroom (a software stupidly written in a script language! not C++ or something…) is quite lazy when it comes to raw files, so reducing their size is an extremely good thing…

    • Lol, Paul … well since I am an American it is hard to refute that, but primarily I think like someone who wants the ability to do high quality (and occassonally large) prints. I definitely couldn’t do that with a 1500 pixel image, and I fear that I would LOVE something that I shot small, and not be able to print it to my satisfaction. But I agree, if you only need small images and you’re confident of that, no need to waste space and money.

  7. Paul, Thanks for that, I think I can see now how it works.
    The fog is lifting.

    Vincent

  8. Nice intro and explanation of this topic! I just shared on Twitter as well (@davidkammphoto, @thegreekcat).

    I essentially always shoot RAW and process in LR3 now. Love that combo.

  9. Very helpful. As so often, you have enabled me to understand an important concept for the first time. I’m so pleased to have found you!

  10. Why is it then that some of my filters are greyed out when I’m working on a 16bit image, but not an 8 bit image.
    I use the pinch tool often and I can’t access it on a 16 bit image so my only choice is 8 bit

    • Garry, because many Photoshop filters don’t work with 16 bit files — you have to first convert them to 8.

      • If you convert a PS file to 8 bit, then does it degrade your image? is it permanent?

        Thanks for this explanation about bits. Very clear, and helpful.

        • Nancy, it doesn’t directly degrade the image, but if you need to do a lot of enhancement afterwards, you may see banding. Do the heavy duty work first, then if you need to convert it to 8-bit to use Photoshop filters, do so afterwards.

  11. I want to know something, I’m doing a project in that, I get 8bit hex values(00 to FF) of each pixel and process that then I’ll have 12bit hex values (00 to FFF) that is I increase the bit depth. Now I want to show the compressed image, In VB.NET bitmap accepts 8bit,24bit, etc. So I have to convert the 12 bit depth to 8 bit. This is my problem. How can I proceed?

  12. Well-constructed explanation. I couldn’t understand this subject as explained on other site. Whom ever you are, you should be teaching the subject at a college somewhere.

  13. What a fantasticly clear explanation! Thank you.

  14. Hi Laura, So my lab wants 8 bit jpegs in RGB format. I was editing in pro photo 16bit and converted it to 8 bit as a jpeg. I switched to sRGB after seeing a seminar on the fact that prophoto has so many colors and most prints can’t print that many colors anyway. So I switched to sRGB. Given that I will be sending my photos to a lab, should I edit in 8 bit so I can edit for printing and make sure what ever I am doing doesn’t look awful when it’s then converted to 8bits? Should I use pro photo, srgb, 8 bit 16bit? I want to provide my clients with files they can print up to 8×10. What do you recommend? There is so much out there, it’s hard to know what is the best thing to do. My eye can’t see the difference! I am simply taking portraits and sending the files to a lab for printing, or my clients are printing. so confused! thanks!

    • Hi Rebecca, assuming your images are raw files, you are automatically editing in 16 bit ProPhoto in Lightroom (you have no choice.) When you make those final 8 bit sRGB jpeg copies for your clients, the fact that you are going down to 8 bit is fine, and won’t produce a visible change in quality (you had all the extra 16 bit data for your editing phase, which is what matters). However, if you have richly saturated colors in your photos, because you are going to the smaller sRGB color space, you may in fact lose saturation. You can preview this affect by using soft proofing in the Develop module in Lightroom 4. (If your output is always to sRGB, you could in fact do all your Develop work with soft proofing turned on and the color space set to sRGB.) If you don’t tend to have really richly saturated colors, you will in fact see no difference, so soft-proofing may in fact not be something for you to sweat.

      I should mention that if your lab provides a profile to download, ideally you would soft-proof and output to that, rather than to sRGB. However, for files you are sending to consumers who could print them anywhere, sRGB is a good safe bet, and if you just don’t want to get into profiles, sRGB is a safe bet to send to your lab as well.)

      All this said, the most important thing you can do to get predictable results is to calibrate your monitor, so that it is telling you the truth about what your photos look like.

      Color spaces, soft proofing, profiles, monitor calibration and much more are covered in my Lightroom 4: Producing Great Output series.

  15. I have a question regarding post editing. I shot with a D800, raw and jpg files. I downloaded with Nikon Transfer and apparently that corrupted the raw files, making them unusable. I had to edit my jpgs in camera raw thru PS CS5 Bridge. These files will be used for creating large posters (20×30) for a corporate client. The jpg goes from 8bit to 16bit when I bring it into camera raw. Should I keep the file at 8bit or is 16bit better? My output is saved as a tiff file. 8bit file is 103mb and 16bit is 206mb. File size is not the issue, quality of the file is paramount. Any suggestions would be appreciated. Thanks!

    • Hi Steve, it’s definitely not the same as starting out with a 16 bit file, but I would go ahead and do your editing in 16 bits if you are going to do a lot of editing. It certainly can’t hurt (other than from a file size perspective.)

  16. Nice explanation of what larger bit files represent. I occasionally shoot landscapes , but primarily shoot wildlife and find that the larger bit files over saturate wildlife images. I’m shooting a D300S Nikon and the 14 bit mode slows the buffer down as well as drops the shutter speed one step. I do notice the 14 bit is great for those fall colors shots and anything I want really saturated with color – but it makes my animals and background way too much for routine editing. I have recently installed Lightroom 4 and CS 6 – and not had a chance to explore the upgrades from CS 3. Are my 14 bit files more easily raw edited in Lightroom 4 ?

    • Hi John, a higher bit depth would not cause higher saturation. what you are really comparing in your observations about your camera is raw files vs. jpegs, and in the case of raw files, how Adobe by default interprets color from your paticular Nikon D300S. (The jpegs have color interpreted in-camera). What you are really saying (as interpreted by me ;-)) is that you are not satisfied with how Adobe interprets that color for your raw files. In this case you should use one of the Nikon-specific profiles in the Camera Calibration panel in the Develop module. Here is an article that refers to this (a little different twist, but bottom line, experiment with the profiles): http://laurashoe.com/2010/01/04/why-do-i-see-my-images-change-after-they-are-imported-into-lightroom/

      It does not surprise me that the buffer slows down, as the raw file is over twice as large as a jpeg. It does not make sense to me, however that you would lose a stop of light. Perhaps someone else will chime in on that.

      • Hi Laura,

        Late reply but I think that John is referring to the “motor drive” speed rather than shutter speed. eg the maximum burst rate would be 5fps rather than 6fps so the buffer has a chance to process the image data.

        Cheers,

        Matt

  17. Laura,
    Your article was very helpful, thank you. I am currently uploading images onto e commerce sites. One site only makes prints for the customers. One allows for you to sell prints, but also to sell downloads (Rights Managed or Royalty Free). Both sites prefer images to be uploaded in jpeg so I imagine that also means in sRGB and in 8 bit? Is 8 bit good enough for printing even at large sizes? Is 8 bit good enough to be sold as high resolution downloads for a company possible wanting to use it for a billboard? Also, when I convert the color profile should I check the rendering intent for relative or perceptual? I notice when I convert to sRGB from ProPhoto (I use Adobe Photoshop 6) that sometimes I see a change in hue especially when it is a blue sky at twilight – it gets a bit more purple -ish after I convert it to sRGB. Is this something I just need to live with?
    Thanks, Joan

    • Hi Joan, I would convert them to sRGB. 8 bit is the only option for JPEG — and in any case is fine. It is only important to work in 16 bit as you are editing your photo. For rendering intent, I would choose relative. You can soft proof your photos (in LR or PS) to preview what they will look like — this would cause me to back off on the blue saturation to not get that purple shift.

  18. Laura, I have another question. The e-commerce sites (that I will be uploading my images to) ask that I not use any file compression. How do I make sure when saving my images in jpeg file (Photoshop CS6) that they are not being compressed? I only see where I can use a slider to adjust image quality (size?) and I have been leaving it at the highest at 12 and then below I check optimized. Am I doing this correctly?
    Thanks again,
    Joan

    • Hi Joan, I’m sorry I didn’t see your questions. The JPEG format always applies compression — even the highest quality setting. For no compression, choose the TIFF file format.

  19. very good and clear job Laura, I just had to argue with a “pro” who shot in JPG in “sharp” mode and delivered posterized picture for a catalogue.

    congratulation

  20. this is a very clear article. I have tried many times to understand the lot about 8-bit depth etc…. Read many things about it but somehow my attention kept being stuck on it. For the first time, I finally understood it. Thank you for making this so crystal clear with samples.

  21. [...] ou en format RAW. C’est un peu plus complex d’expliquer 8 versus 14 bit mais il y a un bon article écrit par Laura Shoe (en anglais seulement) qui explique très bien la différence. Elle fait référence à la [...]

  22. Many thanks for including the histogram with the explanation! As others have said, I have never seen this phenomenon explained so nicely.
    I’ve been scanning my b+w negatives as a tiff file (my scanner’s limitation) then editing in PS using Color Effects Pro. My images certainly are not RAW but still print out beautifully using piezography K7 Split Tone Inkset on Moab and Hahnemuhle paper. I take the tiff file and convert it to PS native and print as a PS native file.
    Is it possible to maximize the amt of info in my tiff file before working on it as a psd file? Also can this be applied by converting to tiff from my NEF file on my D7100? Thanks for this terrific blog! Gar

    • Hi Gary, you aren’t really gaining anything by converting it from TIFF to PSD. I would just continue to save as a TIFF, including your layers (if you have PS layers).

      • I should also mention, Gary, that you aren’t losing anything either by converting to PSD — it doesn’t matter – both will preserve all the data. Just be sure you are scanning in 16 (48) bit mode.

  23. [...] May 2, 2013: Laura Shoe has an excellent tutorial on bit depth over on her site: 8 bit, 12 bit, 14 bit, 16 bit — What Does It Really Mean to Digital Photographers?  She also has an article on Chromatic Aberration that explains it [...]

  24. Thank you, Laura, for a great article. I learned from it and from your replies to the comments as well.

  25. Laura, I got an issue with bit depth in LR:
    LR 4 and 5 let you manage 32 bit images, which is so good. It’s really easy to detect 8 bits files from 16 files but not quite easy with 32 files if you have a bunch of pictures to process. PS show on the name the bit deep but LR doesn’t. Any ideas to resolve this? I’ve tried by metadata without any luck.

    • Hi Diego, fortunately with Lightroom 5 you can now build a smart collection with bit depth as a criterion. In the drop-down, choose Color > Bits per Channel.

  26. So how many levels of tone does a 32 bit image have when we work with it in LR 5?

    • Depending on what you captured amongst your HDR images, Armando, it potentially has up to 2^32, Armando, or over 4 billion. Because our monitors and output devices can’t display this many, highlights will continue to appear blown out, and shadows blocked up, until you “tone map” them — i.e. bring them down into a range that can be displayed, using the Basic and other panels.

  27. Thanks, Laua, for one of the most lucid explanations of bit depth I’ve read!

    Jan Armor

  28. Hi, Laura. Thanks very much for this article! I hope you can answer this question. Even after reading all the above comments, I’m still a bit confused.

    I’m not a pro. I have a Sony RX100M2 that shoots 14-bit RAW images. I use Photoshop Elements 12. When I open a RAW image into PSE12’s raw editor, I can select 8- or 16-bit.

    From your article and the comments above, it seems that I should choose 16-bit in order to gain as much color space as possible in order to recover shadow areas, etc., correct?

    You talk above about the problems with posterization with 8-bit. My question is this: if my workflow is the above and the image looks great in the raw editor, then I convert it to 8-bit (in order to edit in PSE12), will I get posterization (using your example, in the sky areas, etc.)? If so, any way to avoid this?

    Thanks so much!
    David

    • Hi David,

      No, you won’t get posterization by converting – what you see is what you’ll get. Work after it is in 8 bits is what’s at risk.

      • Laura, thanks so much for replying. Perhaps you could comment on this problem, as I’m sure it would help a lot of us:

        I’m now getting my feet wet with RAW files. When they open in Adobe Camera Raw, it’s very difficult to figure out which adjustments to make and in which order to make them. For example, should I adjust Exposure then Blacks then Highlights then Whites, or ??? No matter what adjustments I make trying to make the image look right, the Auto button in ACR always produces a much better image.

        Can you offer any guidelines for us? Thanks!
        David

  29. Hi, Laura. Thanks very much for this article.
    I hope you can answer this question.
    How can I convert 8 bit image into 4 bit image.
    I couldn’t do it in Photoshop, because there were no 4 bit option.

    Thanks in advance!
    Basem

  30. Hi Laura,
    My question has to do with the conversion. When I open a 14 bit image in LR, does it automatically convert to 16 bit? Then when I edit it in 32 bit in PS, it auto converts to 32 bit?

    When you say 32 bit offers over 4 billion levels, that is per channel right? So 4 billion ^3 is the total number of colors and tones possible per pixel?

    Thanks so much for helping me (us) understand this topic!

    • AE, Lightroom does work in 16 bit, so your file will get more decimal places for work done on it, but it really doesn’t matter – you’re not going to gain anything (or much of anything). The fact that you’re capturing in high-bit depth is what really counts. Same with PS – yes, if you convert your file to 32 bit, your file will be much larger and there will be more decimal places to store work, but you don’t gain “HDR” dynamic range.

  31. hello, thanks for your explaination.
    theoretically i get your point. more shades for each color give you a bigger variety of lossless adjustments.
    but: i never realised any difference between 8bit and 16bit when working in photoshop (you can only choose between 8 and 16). even when i used 5 adjustment layers. i have to say: i am not doing any huge adjustments. its more about fine tuning and digital developing.
    oh well, there is one very big difference when editing 16bit images compared to 8 bit ones: every adjustment takes at least twice the time. plus when you are editing hundreds of photos the double file size really comes into play.
    but honestly: who is doing adjustments which cut of 90 percent of the image’s tonal range and then expanding it back to the fullest?
    to see what i mean look at this article: http://www.photoshopessentials.com/essentials/16-bit/
    but the reason might be that i am working on photos. and those always contain noise and do not have a super clean gradient. concerning this here a very interesting article and at the beginning not too scientifical: http://theory.uchicago.edu/~ejm/pix/20d/tests/noise/noise-p3.html#bitdepth
    finally a histogram that contains holes might only be annoying when you think of the lost information theoretically. but in an image i never realised any bad impact of this.
    best wishes, clemens

    • Thank you for your comments, Clemens. I certainly agree that often 8 bits of information is more than adequate. Note that my article really isn’t about whether to do Photoshop editing in 8 bit or 16 bit – it is about whether to capture your original file as a high bit (12, 14, 16 – whatever your camera captures), as opposed to an 8 bit JPEG. I do definitely see value in capturing in raw, then if file size or speed is a consideration, making a decision based on the amount of editing you plan to do in Photoshop on what bit-depth file to work on in Photoshop.

      In terms of the original capture, in addition to other benefits of raw files, I prefer to capture a high-bit raw file to ensure that I always have enough information to do whatever level of adjustments I need, and I am happy to risk filling up my hard drive more quickly. If you watch me develop the beach photo in this video, this image would not have held together if I had shot it as an 8 bit JPEG. (Note that the video is very old – it uses LR 3 and requires flash to watch – but it is a good illustration of where heavy adjustments are needed.)

  32. Hi Laura, interesting article!

    I understand the difference between 8-bit and 16-bit processing in terms of possible posterization.
    But concerning the difference between RAW and JPG, there is more. A RAW file supplies a greater dynamic range than a JPG file. Some of the RAW file’s bits are spent to cover this extra range.

    Speaking from my experience in working with RAW files, I would say that RAW covers 2-3 more stops than JPG. (Obviously, this depends on camera brand and model.)
    Assuming a 12-bit RAW file, this implies that 2-3 bits are needed for the extra range. Only the remaining 9-10 bits are really there for increased granularity, i.e. to prevent banding etc.
    Is my conclusion right?

    • I haven’t worked the numbers, Gerald, but yes, a higher bit-depth file can store a greater dynamic range. (This is why HDR files are 32-bit. The process of tone mapping is used to shrink the result down to 16 or smaller.)

  33. Laura, I am somewhat of a novice, so I appreciate reading your expert advice concerning bit depth files. I downloaded a photo off the internet (5514 X 3678) with a bit depth of 24. I want to have it resized to postcard size about 3.5″ X 5.5″, so I’m guessing the detail will be very good?

    • Hi Mike,

      A bit depth of 24 is really 8-bit. Each file has 3 color channels, so sometimes 8 bit is specified as 24, and 16 as 48. In any case, the detail is exactly what you see. The only issue you might have is if you do heavy edits to the photo – then you MAY see color or tonal banding.

  34. I do a lot of nature shooting and I tell other that shoot with me to use the raw format instead of JPG you article explains it well and I will have to remember the main points that you mention. I also try to get them to expose to the right for less noise and more detail.

    You might find this interesting it is the concept of exposing to the right to gain the most S/N ratio where the camera has more detail in the bright area than in the dark areas.

    http://www.luminous-landscape.com/tutorials/expose-right.shtml

  35. Thanks for the crystal clear description. I already knew most of what you explained but you touched on a couple of points I didn’t fully understand. Excellent explanation: thank you Laura!

 Leave a Reply

(required)

(required, but will not be displayed)

Sign Up Today!
  • Laura’s Lightroom Newsletter Updates
  • Access to Free Lightroom Webinars
  • New Lightroom Video Tutorials and Articles
  • PDF of Laura’s Favorite Lightroom Shortcuts

Your trusted source for all things Lightroom!
I will not share your email. Unsubscribe anytime.
Sign up!