Shoot RAW!

Status
Not open for further replies.

WayneF

Senior Member
My RAW files are 14 bit. It gives you the choice in the menu to shoot 12 bit or 14 bit compressed or uncompressed.

From the Nikon Site
File format

  • NEF (RAW): 12 or 14 bit, lossless compressed or compressed
  • JPEG: JPEG-Baseline compliant with fine (approx. 1:4), normal (approx. 1:8) or basic (approx. 1:16) compression (Size priority); Optimal quality compression available
Nikon | Imaging Products | Nikon D750

I would bet this is the case for the majority of the Nikon cameras

But of course, raw is still only one color per pixel.

The cameras have had 14 bits for a while, but I'm skeptical about the majority of users. Default raw is 12 bits.
My guess is the majority output JPG anyway. :)
 
Last edited:
But...... it takes 3 colors (8 each of red, green and blue) to create a 24-bit JPEG, no? So with 12-bit raws, there'd be 12-bits of Red, 12-bits of Green and 12-bits of Blue. Last time I went to skule, that ciphers up to 36.

You can't just say a single sensor pixel is 12-bit, so the final decomposed pixel is 12-bit because if you used only one sensor pixel to create one image pixel, it would only be one shade of red, green or blue. You need to add the other two colors (along with their 12-bits of color data) to make an 8-bit )or in your case, 24-bit) RGB impage pixel.


14 bit RAW for me
 
14 bit RAW for me


8 bit , which allows 2 to the 8th, or 256 values, and is what a jpeg supports:

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.


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.

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.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.
 

WayneF

Senior Member
But...... it takes 3 colors (8 each of red, green and blue) to create a 24-bit JPEG, no? So with 12-bit raws, there'd be 12-bits of Red, 12-bits of Green and 12-bits of Blue. Last time I went to skule, that ciphers up to 36.

But that 36 bits of color comes from three adjacent pixels. That's less detail, less spatial resolution than your pixel count might imagine.

The color of three raw pixels is interpolated back into each pixel, and each JPG pixel does become 24 bits of color (three bytes of three colors). But two of the three colors were sampled elsewhere.

You can't just say a single sensor pixel is 12-bit, so the final decomposed pixel is 12-bit because if you used only one sensor pixel to create one image pixel, it would only be one shade of red, green or blue. You need to add the other two colors (along with their 12-bits of color data) to make an 8-bit )or in your case, 24-bit) RGB impage pixel.

That is exactly right, now you've got it. Raw is one color per pixel. Red OR green OR blue, but NOT RGB.
JPG is three colors per pixel (made from three raw pixels, but a necessary step, regardless if we shoot raw or JPG).
 

WayneF

Senior Member
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.

No, simply apples and oranges.

One raw pixel only contains one color, and 14 bits is 16384 shades of that one color. Red OR green OR blue. NOT RGB color.

JPG pixels contain 8 bits of each of three colors, for 16.7 million colors... RGB color.

Now JPG from the camera is 24 bits. I am doubting that the camera provides any 16 bit RGB memory.

And JPG from our raw software is 24 bits, but in 16 bit computer memory, it could have have been processed as 12 or 14 bits color (six bytes of three colors, or 48 bit RGB data) up until we output 24 bit JPG files. That, and that we can SEE the image before having to otherwise guess at White Balance and color profile are the advantages of shooting raw (and of course for the better tools, and lossless edits, etcetera, etcetera.) But still, the final JPG color comes from three adjacent raw pixels.

Don't misunderstand me, I only shoot only raw, and am for processing it later, and better. It's the good way, actually the easy way. So I'm not sure what the debate is about, other than understanding the numbers.
 
Last edited:
No, simply apples and oranges.

One raw pixel only contains one color, and 14 bits is 16384 shades of that one color. Red OR green OR blue. NOT RGB color.

JPG pixels contain 8 bits of each of three colors, for 16.7 million colors... RGB color.


I guess you and I and the internet will have to agree to disagree.
 

WayneF

Senior Member
I guess you and I and the internet will have to agree to disagree.

Not the first time we have disagreed. :) Raw is 12 or 14 bits per pixel, which is (by definition) one single R or G or B color. There is no other way it can be said. And yes, this can be used as 12 or 14 bit color, but it requires mixing three adjacent pixels to use it (raw is a Bayer pattern, each pixel is filtered to be R or G or B, but one color per pixel). This has a cost in spatial detail. It is one reason the DxO tests always report 24 megabit sensors to have less than 24 megabit resolution (and also the fact that they are actually testing individual lenses). But it is a fact of life, our digital cameras only handle raw images.

The only detail in an image is the color differences. A pixel only consists of a color, there is nothing else. And differences in color is the only visible detail in our images. So the color from three adjacent raw pixels is necessarily mixed to simulate (create) the RGB color, which yes, you can call it 36 or 42 bit color, but it comes from three places (from three 12 bit pixels). So not quite truthful actual detail, but a pretty close approximation (and just how things are). In later JPG conversion (to make the image be usable), it becomes 24 bits per pixel (three 8 bit RGB colors), compared to 12 or 14 bits single color per pixel for raw images.

So (the original point) regarding size of the data, raw data is 12 or 14 bits per pixel, and JPG data is 24 bits per pixel. Both can be compressed in the file to some degree. For JPG, dramatically but destructably so, making us think JPG is smaller (the file may be, but the data is not). I'm not sure of the actual Bayer demosic algorithm, but the same raw color components are necessarily used in three RGB pixels, which must aid JPG compression effectiveness.

This is no disadvantage to us, it is the same thing regardless if we shoot raw or JPG, because in all cases, the camera starts with a raw file, and in all cases, we end up with a RGB file to be able to use the image. So it is a pointless debate in that regard, no differences exist. But the beauty of shooting raw certainly offers us a few advantages, including much better choices than letting camera automation process our initial guesses (like white balance), to choose better JPG results during our own processing, after we can see and verify and accept or modify it.
 
Last edited:

480sparky

Senior Member
But that .......color comes from three adjacent pixels. ............

Which is exactly how you make an RGB 8-bit JPG pixel. Software will demosaic the 12-bit data from a red pixel, a green 12-bit pixel, AND a blue 12-bit pixel. Or 14-bit, if that's what you're shooting.
 

WayneF

Senior Member
Yep, thanks, my opinion too. That's what I just said a few times... if creating RGB from raw. Raw pixels are not RGB.

It does not matter if the camera makes the JPG or if we do it later in raw software. It happens.

So that point was therefore a pointless debate. Because either way, it is still always true that raw is 12 bits per pixel, and JPG is 24 bits per pixel (other than grayscale JPG). Raw can be 36 bit color if interpolated from three pixels, but it is still going to make 24 bit JPG pixels before we ever see it.
 

480sparky

Senior Member
Yet the fact remains that in order to create an RGB JPG pixel, the software MUST use three raw pixels.

So 12 + 12 + 12 = 36. Or 14 + 14 + 14 = 42, if you're shooting 14-bit.


If you can force the demosaicing to use just one raw pixel data set, you will have a JPEG pixel of either red, green or blue. Just one, not all three.


Plus, if JPEGs are 'truly' 24-bit, then who is making 24-bit software that allows you to edit them? If they're really 24-bit, how can 8-bit software edit a JPEG?
 

WayneF

Senior Member
Plus, if JPEGs are 'truly' 24-bit, then who is making 24-bit software that allows you to edit them? If they're really 24-bit, how can 8-bit software edit a JPEG?

All software wlil process 24 bit data. It is called 8 bit color.

The confusion is that there are TWO TERMS for TWO CONCEPTS. Color or Data.

Most image file formats are 8 bit COLOR. Meaning each RGB color channel is 8 bits. But RBG is three channels, so the data is 24 bit DATA. A byte of red, a byte of green, and a byte of blue is three bytes, which is 24 bit data. These are not the same words or the same concepts, but they are the same files and same image. 8 bit RGB color is 24 bit data. Don't make it hard. :)

We also discuss 8 bit or 16 bit tools, but these process 24 bit or 48 bit data (or 8 or 16 bit grayscale data).

One term and use refers to 8 bit color, and one term and use refers to the 24 bit data (of three 8 bit RGB bytes).

Some common exceptions:
TIF and PNG files have options, and can be 8 bit or 16 bit color, meaning 24 bit or 48 bit data (3 bytes or 6 bytes).
TIF and PNG can also be 8 or 16 graycale color, which is then 8 or 16 bit DATA.
And TIF and PNG can also be 1 bit line art, or can be indexed color.

TIF is very versatile, it uses "tags" to describe internal data fields, which can mean anything the developers want it to mean. So our Nikon raw NEF files (and many other uses) are just special TIF files, with special tags describing raw data, but known only to raw software (Not compatible with TIF software not knowing these special tags).

So some files have options, but JPG can only be 8 bit color or 8 bit grayscale, which is 24 bit or 8 bit Data.

JPG color data is always 3 8-bit bytes of RGB color per every pixel (24 bit data), so 24 megapixels is 72 million bytes of RGB data.
JPG data compression makes the files look much smaller.
 

480sparky

Senior Member
..........
JPG color data is always 3 8-bit bytes of RGB color per every pixel (24 bit data), ........


Yes, we get that. But those three colors come from THREE raw pixels.

Even JPEG (Joint Photographic Experts Group) says JPEGs are 8-bit.
 

WayneF

Senior Member
Yes, we get that. But those three colors come from THREE raw pixels.

Yeah, which is not the best resolution result, color resolution nor spatial resolution. We can interpolate 36 bits of new data from three near pixels, a new creation fabricated and arranged in a certain way, and it is close, but the raw file data captured by the camera is only 12 bits per pixel. But unfortunately each sensor pixel can only be filtered once, to store one color, either red or green or blue. So we deal with it.

Even JPEG (Joint Photographic Experts Group) says JPEGs are 8-bit.

What is your source link you try to quote? Show me where is this that you see, because I feel sure I can read its words to you better. :) If it says 8-bits, it also says Color, or RGB, or such. It should also say 24 bit data.

How hard are you trying? Here from Wikipedia for JPEG:

Encoding

Many of the options in the JPEG standard are not commonly used, and as mentioned above, most image software uses the simpler JFIF format when creating a JPEG file, which among other things specifies the encoding method. Here is a brief description of one of the more common methods of encoding when applied to an input that has 24 bits per pixel (eight each of red, green, and blue). This particular option is a lossy data compression method.


It's not rocket science, should be obvious that 8 bits of red, and 8 bits of green, and 8 bits of blue, make 24 bit data. 3 bytes per pixel in JPG RGB.
And 2^8 is 256, and 256 x 256 x 256 = 16.7 million possible color combinations in JPG.

You're a hard sell. Here is a fail safe argument... Try ignoring this one:

Do this yourself. Actually do it.
Open any JPG file you can find in Photoshop. Or open a dozen of them.

Open PS menu Image - Image Size. Here's one for example (some random little image from the internet):

jp.png


It will show the image size in pixels. On any JPG image you can find and open, multiply image width x height. In this one, 1024 x 934 pixels.
Then multiply by 3 bytes per pixel (multiply by the number 3, for size of 24 bit data). You get data size in bytes.

This one is 1024 x 934 x 3 = 2,869,248 bytes (this is 2.869 MILLION bytes, which is not same unit as megabytes)

The red circled number is showing data size in megabytes, so convert your number to MB by dividing MILLIONS of bytes by 1024 twice (once for K and once for M), and then you get the data size shown, here 2,869,248 / (1024 x 1024) = 2.74 MB.

See? Photoshop is showing the data size computed from the image size x 3 bytes per pixel (for 24 bit data). It is computing actual data size (uncompressed here). No one doubts 8-bit RGB is 24 bit data. :) (but 16 bit color is computed as 6 bytes per pixel, or 48 bit data). This is extremely basic.

Photoshop shows you the 8-bit color JPG data size computed as 24 bit data. Not just JPG, all 8 bit color RGB is 3 bytes per pixel, or 24 bit data. RGB implies three color channels, all three of which are included in the image data.

Any JPG image you can find will repeat this result, because JPG is 24 bit data.

I assumed it would be an easy answer, but if you cannot believe what you see, then sorry, I can't help.
 
Last edited:
Status
Not open for further replies.
Top