JPEG vs. RAW

One of the ongoing arguments among photo enthusiasts is whether to shoot RAW or JPEG. Since you now understand how a digital camera captures these RAW and processed images, it is reasonable to talk about the advantages and disadvantages of each format.

The native format for most DSLR cameras is JPEG. This is the file format every computer recognizes, the one you see on the web, the file format that is all but universal for saving graphics files. JPEG is a compressed file format, however, and some tools like Photoshop (and even some DSLRs' internal processing) allow varying compression algorithms to improve resolution (larger file size) or create a smaller file (less resolution).


JPEG stands for "Joint Photographic Expert Group" and it is a compression standard developed specifically for photographs. However, anyone who has worked with compression algorithms, even very good ones, soon realizes the greater the compression the more likely details (resolution) will be lost. That is one reason most serious cameras offer varying levels of JPEG compression, so the end user can choose between file size and resolution. Also, like any other compression scheme, some subjects, as you see above, are better suited for compression than others.

This tradeoff between compression and file size mattered a great deal when flash memory was very expensive. Today's cheap flash memory, however, has made these kinds of compromises almost a moot point. Today you can buy huge flash cards at relatively cheap prices so there is no longer much justification for heavy compression choices to save flash memory. The other reason - faster in-camera image processing - still matters, but the rapidly improving camera computing power is also making that less important than it was just a couple of years ago.

The JPEG file is what is saved after the camera has processed a digital image. This is after the cameras have applied whatever corrections, enhancements, color balance and noise reduction schemes the camera maker believes improve the image. This is not an exact art and camera makers have different ideas about what constitutes a "good" image. The camera manufacturers also tend to vary in their ability to achieve certain results in the design of their image processing electronics in the camera.

You will see heated arguments on photography forums and page after of page of review coverage at photo sites on the success or lack of success of a particular camera's JPEG processing. This is akin to arguing about the merits of a friend's personality and the beauty or ugliness depends on who is talking. The same is true of the various photo sites as they also have their own very strong ideas of what is "right" and what is "wrong" in JPEG processing.

Most "serious" cameras also can capture images in RAW mode. RAW is supposed to be the unprocessed and unmanipulated image - the digital equivalent of a negative. On the surface this sounds like we should always compare RAW files, as this removes the post-processing and looks only at the capture abilities of the sensor. It would be very nice if things were that simple, but they aren't.

First of all there is currently no standard for how RAW images are created and saved. This is proprietary to each individual camera maker. This is important because you cannot even view a RAW image unless the software you are using supports that camera's RAW storage format. To complicate this further RAW formats even vary among models from a single camera maker.

Adobe is trying to standardize RAW with a format called DNG or Digital Negative. It's a great idea and Adobe has added the capability to convert and save RAW formats it recognizes into DNG format in their Photoshop programs. Ideally cameras would capture DNG as a standard format, but camera manufacturers like Canon and Nikon do not easily give up proprietary advantages they believe they have in their own formats. Thus far the only camera maker who offers DNG capture as a RAW option is Pentax.

RAW also ignores a large part of what we are paying for when we buy a DSLR. The user is buying a computer to capture and process digital images. It is much easier and cheaper to design a camera that only captures RAW and leaves the processing to a computer program. A good example of that is the Sigma Foveon-sensor DSLRs. Until the recent models like the SD14 the cameras only captured RAW. It was much cheaper to design and manufacture the electronics for RAW capture only. It also required much less processing power if the comparison were apples-to-apples.

Unfortunately the Foveon example was more complicated than this surface analysis. The reality is that the Foveon sensor required a lot of processing power just to separate the three colors it "captured" natively with the Foveon sensor. There was only so much processing power available to do in-camera work, and this was also part of the reason conversion to JPEG got moved to the computer until the recent models. However, the fact remains that a camera that just captures RAW is much cheaper and simpler to build that one with powerful in-camera processing for JPEGs.

How a Digital Image File is Created Technical Advantages of RAW and JPEG
Comments Locked

22 Comments

View All Comments

  • Wesley Fink - Tuesday, May 20, 2008 - link

    The goal was to produce a fair comparison and as staed in the article we do have the TIFF files available. The purpose was never to show there is minimal difference in RAW and JPEG. As we were preparing to post there were concerns that the TIFFs, at 45mb each, might cripple our server as a direct image view "click to see". That is the ONLY reason we converted to Maximum JPEG format directly from the RAW file.

    Since there is some interest we will likely produce a ZIP of the TIFFS and create a download link on the RAW examples page.
  • Wesley Fink - Tuesday, May 20, 2008 - link

    Another option would be to post a ZIP of the RAW files. The latest Adobe Camera RAW can handle the PEF format in either Photoshop CS3 or Elements 5 and 6. OR we could save in Adobe DNG format and the DNG files could be read in almost any recent Photoshop or Elements - but not other programs. If either of these is a preferred option please let us know in these comments and we will go with what readers want.
  • pinto4402 - Tuesday, May 20, 2008 - link

    A ZIP file of images in RAW or DNG format would be great. I don't think any other review site is doing this. Although I won't download them each time I read an article, I would absolutely look at them VERY carefully if I'm interested in a camera.
  • pinto4402 - Tuesday, May 20, 2008 - link

    For your sample images, have you thought about using a high quality mannequin head (sounds creepy, I know), or silk flowers? Although not perfect, this would be much preferable to the product boxes you’ve been using. This will allow you to precisely control your test protocol while at the same time obtaining useful information about the imaging capabilities of cameras being tested).

    Overall, your camera reviews are better than average and if you’re serious about it, why not make your testing as good as possible?
  • haplo602 - Tuesday, May 20, 2008 - link

    "Serious photo hobbyists will also be facing difficult decisions today and even more so in the near future. The cost of larger and larger sensors has been dropping rapidly; and CMOS sensor development from all the sensor manufacturers is also a factor in lowering costs and increasing resolution. Like it or not Canon and Nikon have already begun segregating their SLR line into full-frame and APS-C sensors. Those who wondered why Sony was introducing mainly full-frame lenses will finally get their answer later this year with Sony's 24.6MP full-frame flagship model."

    This exactly makes me a happy film shooter :-) There's one disdvantage to full frame sensors however. They increase demand for full frame lenses and increase the prices for me :-(

    Anyway good article. I'd have one comment and one request.

    Comment: There was lots of heated discussion about your sample images (there is one again so far). Would be good if you could shoot manual with f/4.0 and whatever shutter reading for the selected ISO but same for all cameras to make the captured EV consistent. This should in theory lead to all images having same brightness. Of course that will vary by camera processing, but at least you get one more point you can compare from the same series of shots.

    Request: Can you make an article on the processing path of different camera makes and sensors ? You covered the digital conversion so far, but the A/D part would be nice to have too. F.e how ISO is controlled (analog gain or digital interpolation) etc. Also explanation what a higher bit-depth sensor means (12 vs 16 bit sensor and A/D). I know these things are pretty basic, but this will create some common group which you can reference in the future and avoid stupid questions (well some of them at least).
  • 7thSerapHim - Tuesday, May 20, 2008 - link

    Does anyone agree that a better object with clearly defined lines and colors should be used instead, for the comparison crops?

    Most of the time these mass-produced product boxes have mediocre color matching and well-defined lines so it shouldn't be used as a 100% comparison crop.

    The shots also seem to have a substantial amount of chromatic aberration, or maybe just due to pixel peeping, hmmm...
  • sprockkets - Tuesday, May 20, 2008 - link

    JPEG compression control would be nice on the p&s. The Canon SD1000 has compression artifacts all over, thus making the pictures it takes look worse than a $90 Nikon.
  • dblevitan - Tuesday, May 20, 2008 - link

    There are two key advantages of RAW that you missed and that could be useful to even people who are slighly interested in improving images.

    First, RAW provides 12 or 14 bits/pixel while JPEG only provides 8 bits. This is extremely relevant if you edit at all in Photoshop/Lightroom because any kind of level adjustment (even auto) will cause more color degradation with an 8 bit image than with a 16 bit image (which is what the 12 bit RAW files are generally processed into).

    Second, RAW provides a better chance of recovering improperly exposed images by allowing at least 1/2 stop of exposure correction without any penalty and often more without significant issues. With JPEG you simply won't get this.
  • Wesley Fink - Tuesday, May 20, 2008 - link

    You are absolutely correct that while JPEG is 24 bits per pixel it is only 8 bits per color channel (red, green, blue). The Pentax K20D is specified as a 14-bit A/D processor.

    Photoshop and other processing software, as you point out, normally processes this in 16-bit. However, it really doesn't matter in the end how the program processed it or saved it, what matters is the input bit depth. Many are not aware of this, but Photoshop also processes JPEGS as 16-bit on more powerful computers, but this just speeds up processing because you start with 8-bit and save as 8-bit with JPEG. There is no real advantage processing 12-bit files as 16-bit except processing speed as you don't gain real resolution improvements.

    I agree RAW SHOULD allow more dynamic range, but some of the newest models like the Nikon D300 can actually do just as well or better in dynamic range in JPEG. However, in general what you say is true although it is changing as the processing power in DSLRs is improving.

    What we really need is a higher bit-width JPEG standard. Let's hope the JPEG standards committee is hard at work on just that.
  • Bull Dog - Monday, May 19, 2008 - link

    Is it just me or is the third page missing?

Log in

Don't have an account? Sign up now