The Raw and the Cooked – Choosing an Image File Format – Wildlife Photography Tips #4

This article was also published in The Blue Bill, the Quarterly Journal of the Kingston Field Naturalists, Volume 67, No 2, June 2020.

JPEG vs Raw
Rufous-capped Antthrush at ISO 8000

I started this article intending to talk about post- processing – the business of editing your wildlife images. But I rapidly realized that it is too big a subject to deal with at once, so I’m going to break it into manageable chunks.

How the Camera Creates an Image

The first stage of the journey requires us to look at what happens when you snap the shutter. In the days of film cameras it was relatively straightforward – light passed through the lens and onto a film of celluloid or plastic. Light-sensitive chemicals on the film reacted to the exposure, producing a negative or a slide.

Digital cameras use a different process to capture an image. As photographers we need to have a basic understanding of how this works so we can understand how the different image file formats work.

In very simple terms, in a digital camera the light is focused on a sensor, which is a grid made up of very small photosites. Each photosite contains a diode that converts light into digital information. In simplistic terms the diode counts the number of photons that fall onto it while the shutter is open, and the circuitry in the photosite coverts that information into a numerical value.

In order to provide a digital image that matches the level of detail and colour that the eye can see, a camera sensor needs to contain millions of these photosites. This density of information allows a digital image to be at least as good as an image from a film camera. But it also explains why digital image files tend to be very large. Each of those millions of photosites generates a numerical value expressed as a byte of between 12 and 24 bits. To give you an idea of how that adds up, with my current camera set to the highest resolution the information stored by those photosites totals 62 million bytes of data for a single image.

Image Formats

JPEG vs Raw

The camera’s onboard processors convert those digital values into an image file. There are two main formats for an image file – JPEG and Raw. These formats take very different approaches to the challenge of storing all this data. In simple terms, JPEG transforms data within the camera to produce a finished image, while Raw stores all the information and the user then processes the information at a workstation. Each approach has its the pros and cons. I want to briefly illustrate the difference so you can make an informed choice about which format to use.

JPEG

JPEG (Joint Photographic Experts Group) has emerged as the standard format for most photography tasks. For virtually all digital cameras JPEG is the default format, so if you have not been experimenting with the settings menu you are almost certainly shooting JPEG.

The JPEG format was developed to allow onboard compression of digital images. If you recall that figure of 62 million bytes you will see why for many applications there is a need to compress digital images.

Large files are problematic for several reasons:

  • They demand large storage capacity on your camera’s memory card
  • They take more time to write to the memory card, which can limit the number of images you can take in quick succession
  • They take up a lot of room on the storage drives of your PC, laptop, or mobile device
  • They require a lot of bandwidth to transmit, so websites will be slow to load and sharing is tedious

To avoid these problems the JPEG format compresses the raw information gathered by your camera sensor and then transforms it into a finished image. This image is stored on your camera’s memory card.

JPEG Advantages

For many uses JPEG format is ideal:

  • JPEG images are small enough to be easily viewable and shareable.*
  • Virtually all devices and software are compatible with JPEG files.
  • The simple image editing software available on your cell phone, tablet or computer is designed to use JPEG images.
  • JPEG is supported by HTML, the language used in creating web pages.

*Note: JPEG files can be created using different compression levels. Lower compression levels lead to better quality but also larger file size. JPEG Fine files are the least compressed (4:1) but therefore the largest. At about 10MB each in the Large size they are not easily shareable.

JPEG Disadvantages

However, there are limitations to JPEG that you should consider. Most of these limitations result from the way the JPEG algorithm compresses the image file size.

The process by which JPEG compresses a file is highly technical bordering on incomprehensible, but in the simplest possible terms it reduces the size of the file by calculating average values for 8×8 blocks of photosites (thus each block replaces 64 sets of information with one). It then reduces the level of information about colour. Based on the understanding that humans have difficulty discerning small variations of colour, JPEG looks for areas that have similar hues and replaces these small variations with a single average colour.

This process can result in a much smaller image file, but the key thing to remember about the JPEG conversion process is that once the image is created any information that the conversion algorithm considered unnecessary is lost and unrecoverable.

This is why JPEG is classified as a “lossy” format. As noted, a certain amount of information is discarded when the image is originally created. Moreover, each time you recompress the image, by making a change and then re-saving it, some additional information is irrecoverably lost. And if you crop an image – for example to provide a close-up view – the parts of the image that you cropped out are lost forever.

A further implication of JPEG is that, because it produces a final image, the camera settings in use when the image was taken are “baked in”. If you realize afterwards that you had the wrong white balance or picture control settings for example it may not be possible to correct the image.

Raw

Raw is a generic term for a file that saves all of the information from an image, with only minimal processing. This information needs to be converted and edited at a workstation before an image is produced.

Raw format is not available on all cameras. All modern digital single lens reflex cameras (DSLRs) and mirrorless cameras can shoot Raw, but only a minority of bridge cameras have the capability and point-and-shoot cameras generally do not.

Raw Disadvantages

There are several disadvantages to shooting in Raw:

  • Raw files are big. With the camera set-up I currently use, each image file is about 29MB. So a 64GB card will hold about 1,300 Raw files instead of 13,000 JPEGs.
  • You need to process your Raw files at home in order to generate finished images. This is time-consuming compared to the instant image generated by JPEG.
  • To process the files you need specialized image editing software (though note that you can download free editing software from your camera manufacturer – all the major camera brands provide this).
  • Each camera manufacturer has its own a proprietary standard, so a for example a CRW file from a Canon camera is not compatible with a NEF file a Nikon generates.
  • For Raw files to be printed, shared on a mobile device or posted on the internet you need to create and export a JPEG image.

So why do most professional wildlife photographers shoot in Raw?

Raw Advantages

Lossless. Raw files are lossless. All the information your camera gathered is available to you. Nothing is averaged out or approximated. As an example, an 8-bit JPEG image is limited to about 16.8 million colours, whereas a 12-bit Raw image can show up to 68.7 billion. What this means in the real world is that you will get more even transition between colours, without the possibility of the pixilation that sometime happens with JPEG (remember that JPEG averages out colours into larger blocks).

Non-destructive. The adjustments you make in post-processing do not change the original file. All changes are saved in a separate hidden file called a sidecar. So regardless of how much you crop and adjust an image, you always have the original file available. With JPEG every significant change degrades the image, and things that are cropped out cannot be recovered.

Settings are not baked in. With Raw you have complete ability to adjust most of the camera settings during post-processing, including exposure, white balance, sharpening, colour gamut, picture control, and contrast.

Greater dynamic range. Raw files are typically created in 12 or 14-bit format, compared to 8-bit for JPEG. This may not seem like a big numerical difference, but remember we are looking at a file made up of millions of bytes. The math is somewhat beyond my ken, but the impact is that in each stop of a camera’s dynamic range there is far more information space available in a Raw file. At the bottom end of the dynamic range – areas of deep shadow in a photograph – there are 65 times as many gradations in a Raw file as in a JPEG.

This has important implications for wildlife photographers. We often find ourselves trying to capture images in areas where there is both bright light and deep shadow. Using JPEG, those shadows will tend to be featureless dark blobs, whereas with Raw we will be able to see the same details that our eyes would see.

Moreover, the greater ability of Raw to capture detail in shadow allows us to apply shadow reduction – a very useful capability that I will talk about in future articles on post-processing.

Exposure Correction

But perhaps the most striking advantage comes when we shoot images at incorrect exposures. The perfect photographer would never do this, but for the rest of us there will be numerous situations were we have the camera set up for bright daylight only to have a momentary glimpse of a bird – and typically it’s a good one – peeping out of a dark corner.

The higher dynamic range of the Raw format means we can correct a badly underexposed shot in post-processing and end up with a good image.

Consider this example. I deliberately underexposed this shot of an American Goldfinch in my garden.  I did this as an experiment, so please ignore the uninteresting composition. The camera took two simultaneous images – one in Raw and one in JPEG Fine.

Original image

The images were very dark – I had to increase exposure by about four stops. But the results are clear. The quality of the Raw image is pretty good: there is full feather detail and the colours look right . The JPEG image on the other hand is dreadful. The colour is over-saturated, green blobs have appeared in the breast and belly plumage, and the whole bird looks flat and dull.

Recommendations

If you have read this far, you have probably realized that I am a fan of the Raw format. I believe that in wildlife photography the aim is should be to produce an image that replicates as closely as possible how the creature (bird/animal/plant/butterfly/reptile) looked in the wild. I have found that using Raw format and carefully post-processing the image gives me the best chance of doing that. And there is an element of craftsmanship involved that I find appealing – I prefer to make my own choices rather than having the camera make decisions on my behalf. I am also not worried about file size given that hard drive storage capacity has become increasingly inexpensive.

So is there an argument for using JPEG? The fact remains that some very good images have been created using JPEG. You may well decide that you prefer the simplicity and efficiency of JPEG. If so, I would recommend that you use the lowest compression setting: JPEG Fine. This setting creates a 4:1 compression, so the files are still fairly large, but at 4:1 you will not see any of the artifacts or errors that can creep in at higher compression ratios.

Other topics in this series

Wildlife Photography Tips #1 – Exposure Compensation

Wildlife Photography Tips #2 – Shutter Speed

Wildlife Photography Tips #3 – Back-Button Focus

One thought on “The Raw and the Cooked – Choosing an Image File Format – Wildlife Photography Tips #4”

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.