PDA

View Full Version : Why use raw format?


Randy
Jul 11th, 2007, 1:28 pm
In an earlier post I suggested that the best way to store digital image captures was in the camera’s native raw format. Here is a brief explanation of what a raw file is and why it is a good idea.
Raw file capture is available on almost every digital SLR and on many high end point and shoot digital cameras. You would need to consult your owner’s manual to see if your camera supports the raw format.

What is the raw format?

All digital cameras use an image sensor which creates a digital conversion of the image you capture. This digital conversion contains 100% of the data your image sensor records. In a camera that supports the raw format this digital data is stored, without alteration or compression, as a raw image file. This data is not processed for color balance, luminance or color saturation – it is exactly representative of the light that the sensor captures. Most of the manufactures employ a lossless compression scheme on the raw files, but these files are still close to one megabyte per megapixel.

Why JPEG?

JPEG (http://en.wikipedia.org/wiki/JPEG) is an acronym for Joint Photographic Experts Group. This group came up with a file format as well as the codec to compress and decompress the digital image. JPEG employs ‘lossy’ compression which means that some of the picture data is lost in the conversion. JPEG can be adjusted to minimize the data loss or to minimize the stored file size. JPEG only applies to still images. In my large 16 megapixel digital SLR a full sized image with only minimal compression will be stored in a file of approximately 1.5 megabytes. The raw file for that same image will be over ten times that size. Since JPEG uses compression, the final size of the stored file will be affected by the amount of noise in the image, the actual image and the amount of compression used in creating the JPEG. A picture of just the bright blue sky will compress more than an image of a forest, because there is little detail in the sky.

Because JPEG is lossy by nature, there will be some data that is lost forever in the compression and encoding of the image. When you take a picture in your digital camera and save it as a JPEG a number of things take place: The image sensor captures the light (image) based upon the mechanical exposure controls of aperture and exposure time. The ISO setting of the camera will affect this capture as well, as ISO settings usually control the actual gain of the sensor, affecting the digital values for a given amount of light captured. The output of the sensor is raw data and a raw file would store this data.
This captured data is output from the sensor and then processed by the camera for white balance, luminance and color levels. These adjustments are imposed by the cameras white balance settings and the auto leveling parameters built into the camera. The auto leveling sets arbitrary values for black and white, then discards all data above or below those arbitrary values. Auto leveling also sets mid tone levels, which will affect the contrast, shadow detail and other elements of the image which fall between black and white. Most cameras add a little color saturation to give the image a little more dynamic impact.
The image is sharpened. All digital images need to be artificially sharpened or they will look a little soft. This sharpening is usually done at an arbitrary level and cannot be changed in the cameras JPEG conversion. Sharpening is a process where light level changes from one pixel to the next are altered to give the impression of sharper edges on objects within the image.
After all of the processing the image is compressed and stored on the cameras memory media as a JPEG imageAs you can tell from the description above, a lot of what your camera ‘sees’ is simply discarded in the JPEG conversion process. This is usually not a problem on a properly exposed image without any technical difficulties involved.

I will attempt to illustrate, by example, why raw image capture can be really beneficial. I am going to use an image from a recent trip of mine that illustrates what can happen when you do not get a proper exposure of a technically difficult capture. This image was strongly back lit on a sunny day and I was careless and neglected to let my camera meter on the proper item in the image. Focus was good, but the exposure was awful. This is the opening gate to Yellowstone at the north entrance. I will first show the JPEG that came out of the camera with normal processing parameters.
You can click on any picture in this post, except for the graphs, for a larger view.

http://www.prades.net/images/jpeg1sm.JPG (http://www.prades.net/images/jpeg1.JPG)

As you can see, the sun and a bright blue sky were behind the gate and my camera’s metering used the very dark stone of the gate averaged against the little bit of blue sky in the center of the archway to determine the metering value. This made the whole exposure dark, as you can see in this graph of the raw image. The left of the graph represents the low levels or black in the image and the right side represents highlights or whites. It is underexposed by more than one full stop.

http://www.prades.net/images/rawbefore.JPG

There is the possibility to alter the levels in a JPEG image, but because of the lost data there are severe limits as to what you can recover. The following image will show a quick and dirty attempt at regaining the shadow detail in the gate. More could be done with some time in PhotoShop, but this still gives a good representation of the challenge.

http://www.prades.net/images/jpegprocsm.JPG (http://www.prades.net/images/jpegproc.JPG)

As you can see there is some shadow detail to be recovered, but there is also a lot of noise. The highlights also lose all of their detail. Again, a better job could be done with the recovery, but the amount of shadow detail that is lost in the JPEG conversion is considerable.

With raw conversion the first thing I can do is to impose some exposure compensation. This will recover a tremendous amount of shadow detail that is buried in the raw file, which was discarded in the JPEG conversion. Here is a graphic of the image luminance data after exposure compensation.

http://www.prades.net/images/rawafter.JPG

This is a screen capture from BreezeBrowser. As you can see there are many other items I can adjust in this raw conversion. I can set the final image size, adjust color saturation, set black point, white point and even mid tones. I can choose sharpening methods and amounts, image gamma and even correct for certain types of lens distortion. Below is the image, processed from raw in PhotoShop CS3. Most of the image adjustments were done in the raw conversion adjustments. There was little to do other than sharpening and resizing before saving it as a JPEG.

http://www.prades.net/images/jpegfromrawsm.jpg (http://www.prades.net/images/jpegfromraw.jpg)

As you can see, the raw file had enough data to help me recover from this disaster of an image. In most cases I would have been more careful in the first place, reviewed the histogram of the image on the spot and adjusted the exposure properly when I captured the image. I was driving through and only captured it once. Without the raw file, there would have been little to do. I realize this is not a great image, I only chose it to illustrate the challenges that a raw file can help you overcome.

A raw file will not help you if there is motion blur in the image, either by motion in the camera or the subject. It cannot help you if the image is not focused or composed properly. A raw file can help you recover from exposure problems or white balance problems.

Almost every camera that is capable of raw image storage comes with software to process that raw file. I use BreezeBrowser for the vast majority of my images, because I like and am accustomed to the workflow. Adobe PhotoShop also includes ACR for raw conversion. Photoshop is robust and complicated, but the learning curve to get started is not too steep. There are also programs that come with the camera, Canon provides DPP with theirs. There are also dozens of other raw conversion applications from the professional Capture One to the popular Bibble. I highly recommend that you look into raw image storage and processing as it will appreciably improve your results. It will also make a better photographer out of you as you learn the pitfalls of complicated exposure situations. You will begin to pay much more attention to light, which is the absolute key element in any quality photograph.

BreezeBrowser (http://www.breezesys.com/BreezeBrowser/index.htm)
Capture One (http://www.phaseone.com/Content/Software/ProSoftware/ProductOverview.aspx)
Bibble (http://www.bibblelabs.com/)
PhotoShop (http://www.adobe.com/products/photoshop/photoshop/)

Hope this helps!

If you want an even more technical treatise of the raw conversion, Northlight Images has a good one here (http://www.northlight-images.co.uk/article_pages/why_use_raw.html).

lnowell
Jul 11th, 2007, 1:44 pm
That is really interesting.

Here I am trying to figure out how to upload one simple jpeg picture I took of my self installed downlights so I can post it - and you post this. Do I feel humble?? Yep.

Woolly
Jul 11th, 2007, 2:56 pm
Randy, hellua good post. Thanks. Only prob I can see is when you're 'on the road', RAW images take up a lot more space - how do you get round this - I really have to think for each piccky, what do I want as a 'quick snap', or do I want as a 'good photograph' - if I saved all of mine as RAW, I would spend more time downloading the camera. The majority of my best photographs are 'opportunist', not pre-considered. This is one of my favourites, taken early one morning in Norway - camera on automatic, OK, no motion, nothing much gonna happen for a while, but it was just a 'quick snap' before I had to ride onto a ferry. I would welcome your objective critiscm and let me know how much better it could have been, if I'd set the shot up manually, and saved it as RAW.

Thanks,

Wool.

Randy
Jul 11th, 2007, 3:24 pm
Randy, hellua good post. Thanks. Only prob I can see is when you're 'on the road', RAW images take up a lot more space - how do you get round this - I really have to think for each piccky, what do I want as a 'quick snap', or do I want as a 'good photograph' - if I saved all of mine as RAW, I would spend more time downloading the camera. The majority of my best photographs are 'opportunist', not pre-considered. This is one of my favourites, taken early one morning in Norway - camera on automatic, OK, no motion, nothing much gonna happen for a while, but it was just a 'quick snap' before I had to ride onto a ferry. I would welcome your objective critiscm and let me know how much better it could have been, if I'd set the shot up manually, and saved it as RAW.

Thanks,

Wool.
I am not sure I want to criticize the shot. It looks like a great image, but in downsizing and compression it is full of artifacts. I am sure the full sized image looks much better. More to the point, if you took the raw image, re sampled for size, then applied adjustments and sharpening for the web, it would certainly have more detail.

As far as storage goes, my camera has a slot for CF and for SD. I put an 8gb card in each slot. If I am traveling without a backup device, I record the image simultaneously to both cards. Even with raw and a small JPEG an 8gb card will store more than 250 images from my 1Ds MarkII. I usually carry a small battery operated image vault for backup, in that case I just write to one card and back it up when full. An 8gb card is now less than $100.

I suppose the critical question is how much a single image is worth. The bulk of my pictures are exposed correctly and require little post processing. But for that one image that really captures a moment for me, the storage and processing is worth the added effort. I always capture a raw plus a small JPEG, so I really don't have to do anything with a raw file for most pictures.

On a trip to Canada a few years back we happened on Bow Lake in Banff National Park, when the light was great and the wind was calm. While only identifying images to many, they really captured the feeling of the moment for Michelle and me. I have subsequently printed several of them at 24X36 to decorate my home and office. They would not have been the same as JPEG captures.

These were taken with a 11 megapixel Canon 1Ds:

http://www.prades.net/canada2004/HTML/493t1801_std.jpg (http://www.prades.net/canada2004/493T1801.jpg)

http://www.prades.net/canada2004/HTML/493t1806_std.jpg (http://www.prades.net/canada2004/493T1806a.jpg)

To see the bottom one in its full 11 megapixel size click here (http://www.prades.net/canada2004/493T1806.jpg). This image has not been Processed in PhotoShop, where I cloned out the dust spots and fixed the CA on the edges prior to printing.

Seattle
Jul 11th, 2007, 6:48 pm
I'm going to have to side with Randy on this. RAW is the way to go, period.

Memory is cheap, so if memory is the argument then buy some larger memory cards. Consider how many shots you could miss by not having the flexibility of tweaking that once in a life time shot that came out under exposed. Or maybe the blues just don't pop in scene the way you remembered? In RAW you can fix that.

I have a couple Canon 5D's and they allow you to shoot simutaniously in RAW and JPG. I see Randy has the mack daddy in Canon's line which has tons of flexibility that you would expect in an $8K camera. In the professional environment this allows you to preview pictures in a rough format with the JPG's with your client to determine which shots you and/or they wish to clean up later in the Dry Room from the RAW format. Will the avg consumer need this? Probably not.

RAW allows you tons of flexibility in making what looks like a great shot outstanding. For those people who have the ability to shoot in RAW it is a no brainer 98% of the time. Most people do not have cameras capable of this though or the software to edit it other than what should have come with the systems.

For most people JPG's are fine for what they shoot and give people what they expect, in fact most consumer cameras will shoot only shoot JPG. Opening up people's eyes to RAW is like taking off the tupperware from your BMW and realizing suddenly just how much more you can actually do with it.

JPG's are the most compressed of digital files and do not contain enough information for most professional use. TIFF files are generally considered to be the happy medium between JPG's and RAW pictures.

Look at RAW files like an actual film negative. I can't imagine why anyone would want to throw away their negatives? Well I could, but not in an ethical case. Anyway, as a professional photographer I can easily say that RAW is the way to go if you are passionate about film, but you want to be as detached as possible from the medium and are only shooting scenes that you could care less about if they came out properly or not and didn't care about tweaking them much, then JPG files w/auto exposure is the way to go.

If you can shoot RAW I would encourage trying it out. The more familiar you become with it the easier it gets.

(on a side note, sorry if this wasn't written well, I wanted to expand more eloquently but I am being rushed out the door for dinner!)

Randy, hellua good post. Thanks. Only prob I can see is when you're 'on the road', RAW images take up a lot more space - how do you get round this - I really have to think for each piccky, what do I want as a 'quick snap', or do I want as a 'good photograph' - if I saved all of mine as RAW, I would spend more time downloading the camera. The majority of my best photographs are 'opportunist', not pre-considered. This is one of my favourites, taken early one morning in Norway - camera on automatic, OK, no motion, nothing much gonna happen for a while, but it was just a 'quick snap' before I had to ride onto a ferry. I would welcome your objective critiscm and let me know how much better it could have been, if I'd set the shot up manually, and saved it as RAW.

Thanks,

Wool.

jhsonderb
Jul 11th, 2007, 7:03 pm
Randy ...thanks for taking the time to post your detailed analysis. it was very helpful to my understanding and will help me take better pictures.

Jerod521
Jul 11th, 2007, 9:15 pm
Randy, Thanks alot for this post. I didn't know what I was missing not using RAW. I am truely bummed out when I think of the possiblities I've missed out on. I have Photoshop CS2 and I thought everything was great shooting in large Jpeg and editing it. here are some pics of when my dad, brother and I went snowshoeing this last winter. A phenomenon called "whore-frost" had happened and I tried to get artsy with some shots. Just think of what I could have come up with in RAW.


Original

http://www.bmwlt.com/gallery/files/8/6/0/9/frost-org.jpg

And the artsy image I came up with

http://www.bmwlt.com/gallery/files/8/6/0/9/icystem2.jpg

I can't imagine what I could have pulled out of the stem. The full size images you can see the crystal structure quite well but the blacks and whites limited what I could do.

Metzen
Jul 12th, 2007, 7:02 am
Wow, thanks for the post Randy.

Being somewhat the stubborn type, I recently switched to digital after forty years of Canon 35mm film slr's. I am absolutely amazed at the freedom digital photography provides us all. I welcome your insight and thank you once again for shedding some much needed light (pardon the pun) on our second pastime. I hope to be able to draw on your experience in the future.

Best regards,

brianbeemer
Jul 12th, 2007, 8:25 am
My camera doesn't have the ability to save in raw format, but it does give me the option of how to set the exposure - as well as a lot of other things, most importantly for me how big an area is the autofocus looking at. My default setting is to expose based on a small section in the center of the view (highlighted by a rectangle). If I look at (say) the darker area on your picture of the gate and press the shutter halfway, that set's the exposure for the whole picture and I can then frame the subject knowing that the area I want to see clearly will be exposed correctly. I can also set the camera to pinpoint one small part of the pic for the exposure, but I rarely use this feature as it's too sensitive for most quick snaps.

Pretty good I think for a camera that only cost me $175 !!! Plus $10 for the 2GB storage.... Oh, and it's 5MB with a 10x optical zoom and further 5x digital zoom (which is far too much in total). Plenty for my non-professional uses, and even at high quality the 2GB card will hold almost 400 pictures. Even I can't manage that number...

Gino
Jul 12th, 2007, 2:18 pm
To see the bottom one in its full 11 megapixel size click here (http://www.prades.net/canada2004/493T1806.jpg). This image has not been Processed in PhotoShop, where I cloned out the dust spots and fixed the CA on the edges prior to printing.

What lens was this that causes the CA, or is this inherent in the body? Is that issue common with the Canons (or do all dig. cams. exhibit some CA based on lens used)?

Randy
Jul 12th, 2007, 3:25 pm
What lens was this that causes the CA, or is this inherent in the body? Is that issue common with the Canons (or do all dig. cams. exhibit some CA based on lens used)?CA exists in all lenses to one degree or another. The lens I like to keep mounted on my camera and the one used in those photos is a 28-300mm zoom. At the wider settings it exhibits more CA than a similar sized fixed focus lens. I am willing to tolerate the CA for several reasons. The single lens covers a 10X range of focal lengths The CA is really easy to take out with PhotoShop What you can see in a 100% crop of a full sized image cannot be seen in a print or an image sized for web viewing. Another factor at play is that the camera is a full 35mm sensor size. On cropped cameras, 1.3 or 1.6 for Canon and 1.5 for all Nikon SLRs, it is more difficult to see CA because the sensor is only exposed to the central portion, or sweet zone of the lens. CA is not a product of the body or of digital cameras - the same aberrations in my image would be on film as well.

Point and Shoot cameras will generally exhibit much more CA because of their pixel density. Most point and shoot sensors can out resolve their lenses.

Jerod521
Jul 23rd, 2007, 11:56 pm
Ok am I an idiot? I thought that my Cannon digital rebel XTi 10MP DSLR would/could save in RAW. If it does I can't figure out how to change to it.
I am in the process of moving so getting at the owners manual isn't an option
right now. Anyone know if it is possible and how to switch to it? In the setup
menu I have the option of S,M,L file storage on either what looks like a curved line (larger file) or a stair stepped line (smaller file) both are jpeg though. And the two large file size setting only vary by about 1mb in size. Not 10mb as it would be in RAW.

Thanks

scottydawg
Jul 24th, 2007, 12:33 am
Ok am I an idiot? I thought that my Cannon digital rebel XTi 10MP DSLR would/could save in RAW. If it does I can't figure out how to change to it.
I am in the process of moving so getting at the owners manual isn't an option
right now. Anyone know if it is possible and how to switch to it? In the setup
menu I have the option of S,M,L file storage on either what looks like a curved line (larger file) or a stair stepped line (smaller file) both are jpeg though. And the two large file size setting only vary by about 1mb in size. Not 10mb as it would be in RAW.

Thanks

You can go to the Canon website www.powershot.com (http://www.powershot.com) and look up your manual under support.
I looked up your camera and it says you go to the tab that shows a camera with the number 1 beside it and select "Quality" (using the "Set" button). You should see RAW under that menu.

Jerod521
Jul 25th, 2007, 9:21 am
Thanks. Turns out that the camera will only save in raw in the manual setting modes. Any of the preset modes and it reverts to large Jpeg. A little annoying but that is probalby one of the functions they unlock at the next price tier / camera.

danbrew
Jul 28th, 2007, 8:31 pm
There's simply no question - shoot raw. Carry lots of memory. I've got a D1X, a D100, and a D80. I use the D80 the most. I also carry about 10 gigs worth of SD cards with the D80.

After you get done thinking about raw, go think about Adobe Lightroom. It's freaken' awesome.

OKUIII
Jul 28th, 2007, 11:23 pm
Randy and everyone,

Thanks alot for the magnificant information. My wife and I are going to Galapagos in August. I am going to start shooting in raw +jpeg.for our trip. I am going to take my Powerbook G4 and plenty of memory. What program would you guys recommend for editing that does not cost a second mortage?

scottydawg
Jul 29th, 2007, 4:47 am
Randy and everyone,

Thanks alot for the magnificant information. My wife and I are going to Galapagos in August. I am going to start shooting in raw +jpeg.for our trip. I am going to take my Powerbook G4 and plenty of memory. What program would you guys recommend for editing that does not cost a second mortage?

A program that has most of the power of Photoshop but cost much less is Photoshop Elements.

Ranger
Jul 31st, 2007, 10:39 am
Thanks. Turns out that the camera will only save in raw in the manual setting modes.

Jerod,

There's an old guideline that was taught to photography students for manual settings called the "sunny 16" rule. This is only for sunny days but works quite well. Choose any of the following combinations:

ISO 100, shutter speed 1/125, and aperture f/16
ISO 400, shutter speed 1/500, and aperture f/16

There are other combinations and you'll get slightly different effects depending on your choice. But this is just a start.

Shoot away and most of your exposures will be good. This should allow you to use your cameras manual settings, RAW image capture, and not require you or your wife to be an expert (yet!).

dandiver
Aug 1st, 2007, 7:39 am
Guys, Thanks for the education, sincerely.. Wife just got the new Canon EOS Rebel XTi and I've just started to play. Now I'm starting to understand some of the terms and technology. Previous threads are helping more than the owners manual. Last camera was a simple Sony point and shot! Now on to underwater housing........ Talk about jumping into the fire.

JCabranes
Aug 1st, 2007, 1:02 pm
Brilliant post. Thank you for the information