The difference in RAW files. 12 bit raw VS 14 bit raw

It is often said that RAW image format provides maximum image quality. On the one hand, RAW is the raw data from the camera matrix, on the other hand, RAW has its own special settings.

RAW - thoughts from Radozhiva

RAW - thoughts from Radozhiva

I will write only about the Nikon system, since I work with it, and over the years I have gained some experience working with RAW files.

Nikon DSLR cameras have some RAW features. RAW files themselves have an extension NEF (Nikon Electronic Format - Nikon Electronic Format). In the camera menu, in order not to confuse a person who has read a lot and heard a lot about RAW, marketers carefully write NEF (RAW).

In the menu of some cameras there is only one item that is responsible for setting the RAW. It "Record Image NEF (RAW)". Depending on the type of camera, in this menu you can choose color depth and compression type. And in some cameras there is generally no way to select the RAW setting.

For example, in advanced cameras by type Nikon D300, D700 and even in Nikon D7000 You can select the color depth for RAW.

Also, in some advanced cameras, for example in the same Nikon D300, D700 you can select the compression level for RAW files, the “TYPE” setting is responsible for this:

  1. Lossless compression
  2. Normal compression
  3. Without compression

Thus, we can use a combination of 6 RAW recording options

  1. 12 bit lossless compression
  2. 12 bit regular compression
  3. 12 bit uncompressed
  4. 14 bit lossless compression
  5. 14 bit regular compression
  6. 14 bit uncompressed

Attention: 14-bit RAW reduces the burst speed in some cameras, such as Nikon D300, D300s in RAW mode, 14 bit burst speed drops to 2.5 fps. D7100 with a color depth of 14 bits can not shoot at a speed of 7 fps in 1.3x mode. D5300 и D5500 with a color depth of 14 bits can not shoot at a speed of 5 k / s.

The main question is how much compression affects image quality?

It is logical to think that with Lossless Compression the camera simply compresses the source material using algorithms that do not lose data after decompression. For example, this is how an archiver works on a computer, with which you can archive or compress files, and then unzip them back without losing data. In practice, Lossless Compression practically does not 'truncate' the original data. "Normal compression" implies compression using incomprehensible algorithms, and, most likely, with a strong loss of quality. "No compression" - this option allows you to get the real raw data obtained from the camera matrix without any compression or cropping.

Attention: the frame counter correctly shows the number of frames that can fit on a camera card only in the “WITHOUT COMPRESSION” mode, since in this mode all files have the same weight and the camera knows exactly how many pictures can be placed. In the modes “Lossless compression” and “Normal compression”, the frame counter on Nikon cameras is very wrong, since the camera does not know exactly how much it will be possible to “shrink” the resulting image, therefore, it takes the maximum possible volume and calculates quantity. It is sometimes unnerving.

What type of compression to choose?

  1. Lossless compression - the best option, no loss in compression, strong space savings and preservation of the full potential of the RAW file
  2. Normal compression - the option is suitable for those who, on the one hand, want to shoot in RAW, and on the other hand, greatly save on disk space
  3. Without compression - the best option, no loss in quality, the absolute maximum that the camera can give out. A serious drawback of the format is the huge file size.

For example, not to talk about abstract things, my Nikon D700 in RAW 14 bit mode and without compression produces files of 25MB each. When switching to RAW 14 bit with lossless compression, files average 15MB. Get 10MB savings in one picture, you see, the gain is simply colossal. Well, if you use RAW 14 bit with conventional compression, the file weighs from 10 to 15MB.

What color depth to choose? 12 bits or 14 bits?

14 bits are better than 12 bits. True, the psychological aspect can play a huge role here: when shooting at 14 bit color depth, you can be calm that you use the maximum that the camera is capable of. Personally, from my practice, 14 bits seems more flexible for processing.

Personal experience:

On the Internet you can meet a lot of battles on the topic 12 or 14 bits, but I’m sure that if you show two pictures with different color depths, it will be very difficult for professionals to distinguish from each other. I use RAW 14 bit + lossless compression on cameras by type Nikon D700, D300, D300s, D7000 etc. and RAW 12 bit + uncompressed on cameras by type Nikon D200. Well, on amateur cameras like Nikon D40, D40x, D60, D80, D90, D3000, D3100, D3200, D5000, at all there is no choice, it uses the default 12 bit + lossless compression. In the cameras Nikon D5100, D5200 uses 14 bit + lossless compression. You can also read my thoughts on the topic software implementation of RAWand RAW benefits when editing photos.


RAW has different compression levels, with which you can seriously save space on the card and the hard drive of the computer.

The material was prepared by Arkady Shapoval. My Youtube channeland Radozhiva's group on Facebook и VK.

Add a comment:



Comments: 82, on the topic: The difference in RAW files. 12 bit raw VS 14 bit raw

  • Marina

    Good afternoon. If it’s not difficult, tell me please. I have a Nikon d3100 camera. I take pictures in RAU + file, but when I reset to the computer the two files are exactly the same in jpg format, the same size, but where is RAU? .Thanks

    • Arkady Shapoval

      Most likely, you simply reset via USB, use a card reader or look for how to configure a normal camera connection to a computer.

  • Vyacheslav

    What about the D610? Well, or just the D600? As I understand it, there is no difference :-)

    • Arkady Shapoval

      The camera can use 12 or 14 bit RAW files with normal compression or lossless compression.

  • Denis

    Good afternoon!
    Arkady, please explain the details about the color depth of the RAW file. Let's say the camera recorded data from a matrix with a depth of 12 or 14 bits per channel, and the converter (and the sRGB standard) allows you to record files with a depth of 8 or 16 bits. Why does this difference appear in the color depth of the camera and file after conversion, and how is the information used (12-8 bits or 14-8 bits), or where is the missing (16-12 or 16-14 bits) taken?

    • Arkady Shapoval

      8 bits is enough to encode an image of all possible colors, a larger range is taken as a reserve for processing.

  • Anatoly

    There was nikon 700, photoshop opened raw files.
    I bought nikon 750 raw does not open with Photoshop. What should I do?
    I can not figure out the software on the disk in English.
    Maybe there are some converters in Russian? Tell me. Thank you!

  • Igor

    I would like to clarify.
    The signal from the sensor passed to the ADC. Here the signal was converted into a data array.
    Further this array can be
    - saved in JPG / TIFF
    - saved in RAW
    If the array is stored in RAW, not JPG / TIFF, then this RAW (depending on the specifics of the camera) may be
    - without compression (uncompressed);
    - compressed without loss (lossless);
    - compressed with loss (lossy).
    So ?

    • yarkiy


  • Pacman

    in my camera jpeg files weigh an average of 5mb, raw files of 10mb each. And when I convert them to lightroom, with maximum quality settings, then Jpeg already weigh only 2mb, and their quality is noticeably better than direct jpeg files from the camera. Why is that?

    • anonym

      Lightroom handles jipeg better, but what is your camera?

  • Vladimir

    Why shoot in RAW format, if when printing, transferring pictures you need to convert to JPG format. And this is 8 bits instead of 14.

    • Arkady Shapoval

      This is an amateurish question :)

    • Valery A.

      So edit the exposure, colors, etc. as possible (in RAV). Because of this, I’m shooting in RAV.

  • Charles

    Well, do not shoot, no one forces you.

  • Alexey

    As I understand it, the RAW format is used to expand the dynamic range of the image, that is, instead of the usual 8 bits (as in JPG), 12, 14 bits are used. This is true if the plot is a big difference in brightness on the screen.
    1) How then to pull out the necessary part of the dynamic range from the RAW format (for example, the brightest or the darkest), being able to smoothly control which part to pull out?
    2) Is it possible to narrow the dynamic range of the picture (non-linear) so that all 14 bits of the original picture fit into 8 bits of JPG?

    • Alexey

      It is for this, in order to compress the range for getting into an 8-bit jeep and shooting is done in the rav. With subsequent processing, which allows you to stretch parts, reduce noise, enhance colors without rough gradations of differences.

  • Kobakokh

    In my opinion, the advantages of 14 bits are manifested most of all when pulling shadows in kg converters - at the same time, colors are not lost, although they go a little towards red, and when pulling out from 12 bit files, everything goes much towards green, and also colors are lost a lot, appear also quite noticeable artifacts in certain places in the files, in deep shadows like and the noise is slightly added when they are pulled.

  • R'RёS,R ° F "RёR№

    Good day ! Dear Arkady, I have a Nikon D2XS camera with NEF (RAW) + JPEG FINE (high quality) settings. Frame size: L (large). After shooting, the camera produces a file: Jpeg (2448X4228) 3,4 MB and NEF (2448X4228) 20,3 Mb Snapshots: in (NEF) for long-term storage after shooting, you can send it to a DVD or external drive for recording without processing, or you need processing. In our city, when printing photos in Digital-Photo with Nef files do not work, only Jpeg. I want to save the files to Nef. I’ll ask for your recommendations since you used to be related to the Nikon D2Xs camera.

    • Arkady Shapoval

      Convert NEF to JPEG using native utilities.

  • Nikolay Merkulov

    Arkady, hello! If you look at the histogram of 12 and 14 bit snapshots, you will notice that all the shadows are in these two bits. Often these two bits are very important. For example, when shooting a landscape.

  • Dmitriy

    (Well, on amateur cameras such as Nikon D40, D40x, D60, D80, D90, D3000, D3100, D3200, D5000, there is no choice at all, it uses the default 12 bit + lossless compression). All the same, it seems to me that the Nikon D3200 uses 12 bit + conventional compression.

  • Just an amateur

    Amateur in the photo but ... I read the arguments about coding and admired.
    1. Lossless compression == lossless compression, otherwise it is lossy compression. Specifically, jpeg-ls is most likely used here.
    2. Compression algorithms are all known for lossless compression using the standard described in ITU-T Rec. T.870 is such a 60 page document describing all the nuances. Small enough, because for the h265 codec this document is already around 500 pages.
    3. Nobody ever writes directly from the matrix !!!
    Before the signal from the matrix reaches recording in any format, very strange things called
    OOTF (Optical-optical Transfer Function) and
    OETF (Opto-Electric transfer function)
    Both pieces nonlinearly affect the signal received from the matrix. You could stumble upon them while reading about HDR, however they are both in any digital system.
    Therefore, if someone told you that they say RAW is a direct recording of the matrix, he was mistaken to put it mildly
    4. There are also inverse nonlinear things according to paragraph 3, which convert the raw signal into a picture, say on a monitor ...
    5. You will not see the difference between a 14-bit signal and a 12-bit one on the monitor, simply because the Dolby Professional Reference Monitor PRM-4220 12-bit monitor costs $ 21 thousand.
    You can observe only the result of various transformations, including coding, and there bitness matters.
    6. Even HDR is encoded in 10 bit format, and in general the latter was thought up to get away from 16 bit format, there are all sorts of things from pp. 3 and 4 are much more complex.

    No offense to you, just to expand knowledge. So I think that you can freely use lossless compression and the quality will be the same as just for a raw file. Otherwise, you can sue Nikon for misleading the user.

    • Onotole

      I totally agree with the part about lossless compression. But ... you can see that you are a fan of photography:

      according to p. 5, the difference between 12 and 14 bits in the literal sense is not to be seen, especially since the color output of almost all is 8-bit, and do not care what kind of monitor it is. However, I can easily see the difference between two identical 12 and 14 bit RAW files on the 6 2006-bit TN matrix, which has sat down, provided that I open these files in the converter and move the exposure sliders.

      according to claim 3. - you are wrong too. All of these OOTFs and OETFs of yours happen when transformed into a bitmap. RAW is for RAW because it records a digitized (“quantized”) signal from a matrix without nonlinear transformations. Just because it is not necessary. Not to mention, HDR to RAW has the same relationship as steering wheel to gearbox. If you still think that you are right on this point, please provide proofs.

      • Just an amateur

        Left soap, if interested.
        I am an amateur in photography, but not in digital signal processing.
        I may not really understand some of your terminology, or, as always, we call the same thing by different names. When you say that it is easy to erase the difference by moving the sliders…. Well, I agree and I said earlier “You can only observe the result of different transformations” exactly the difference in the results of transformations (in this particular case, exposure) you observe :-)

        Now about p. 3 you are right about OETF (after all, it refers more to sRGB colors), but you can’t get rid of OOTF in any way. No one can record light directly. Quantums of light falling on the photocell cause a current, which is then removed, and then the signal is sampled. That is, we say that a current of such a magnitude is so much a bit, and of another magnitude is so many bits. The current is converted into bits by an Analog-to-digital converter, ADC, and the result of its operation is recorded as a RAW file. In the Russian RAW wiki, there is a link to an article about these files and instructions on the stages that the signal goes through until recording. The quality and algorithms of the ADC, as well as calibration tables affect the quality of RAW, that is, options that can be done with it. Not all frequencies are equally useful; at the upper and lower values ​​of the sensor, they try to discretize the signal less often than in the middle.

        Regards, Just a photography enthusiast.

  • R'RёS,R ° F "RёR№

    I do not quite agree with the phrase:
    “Lossless compression is the best option, low compression loss, strong space savings and preserves almost the full potential of the RAW file”
    Without losses, this is a losless compression, actually an archiver, but adapted for working with data taken from the matrix.
    There are no losses at all. There is only one minus - a greater load on the processor due to the
    that the camera has to compress data before writing to the card.
    Theoretically, it leads to more battery consumption and micro delays before recording to a card. In practice, it will be imperceptible.

    • Arkady Shapoval


  • R'RёS,R ° F "RёR№

    I would recommend “no compression” only in one case:
    If you suspect that the manufacturer is cheating and uses lossy compression in low bits. But this is already from the field of conspiracy theory.

Add a comment

Copyright © Blog author - Photographer in Kiev Arkady Shapoval. 2009-2020

English-version of this article