Image File Types Most digital cameras record files in JPEG format - (they have a .jpg filename extension), but they use a special variation of JPEG called Exif. This is a standard that allows extra information to be recorded by the camera into the image file.
The Exif standard was developed by the Japanese Electronics Industry Development Association (JEIDA) and is used in almost all models of digital camera. The extra information in the file relates to picture-taking conditions, such as camera settings, color encoding information, and sounds recorded when the picture was taken. Exactly what is recorded depends on the model of camera.
JPEG — Joint Photographic Experts Group
JPEG is an acronym for Joint Photographics Experts Group (the group that devised this standard). It is used for color photographs or artwork with lots of colors and gradations that will be placed on Web pages and in computer slide shows
JPEG has better on-disk compression than GIF, which means that JPEG files will take up less space on your hard drive.
JPEG is widely used by digital cameras. The advantage is that JPEGs use compression, so the image takes up less space in the camera's memory. However, compression also leads to loss of quality. The more you compress an image, the worse the quality. Most people don't realize the following: every time you open a JPG, make a minor change, and save it, the JPG is compressed yet again. So the first version is 20%, the second version is 20% of 20%, the third is 20% of 20% of 20%, and so on. The more you work with a JPG, the worse it gets.
The JPEG (“jay-peg”) format is likely to be replaced at some point in the future by the updated JPEG2000 format.
GIF — Graphics Interchange Format
The Graphics Interchange Format was originally developed by CompuServe in 1987. It is most commonly used for bitmap images composed of line drawings or blocks of a few distinct colors. (variously pronounced “gif” or “jif”). GIF files can be saved with a maximum of 256 colors. This makes it a poor format for photographic images. It is used for images that are made up of 256 or fewer colors with large areas of the same color such as logos, some computer screen captures, line drawings, text headings, etc Compuserve’s 8-bit GIF format has long been the most popular on the Internet, mainly because of its small size. It is ideal for small navigational icons and simple diagrams and illustrations where accuracy is required, or graphics with large blocks of a single color.
PNG — Portable Network Graphics
PNG is a format iinvented specifically for the web in response to a licensing scheme introduced which meant the creators of any software that supported the GIF format had to pay five thousand dollars for the privilege (this tax has since expired). While they were at it however, the creators of PNG (“ping”) went ahead and created a format superior to GIF in almost every way and will likely be the successor to the GIF file format. PNG is expected to become a mainstream format for Web images and could replace GIF entirely. Compared with GIF, PNG offers greater color support and better compression
One version of the format, PNG-8, like the GIF format,it can be saved with a maximum of 256 colors. Filesizes when saved in a capable image editor will be noticeably smaller than the GIF counterpart, as PNGs save their color data more efficiently.
PNG-24 is another flavor of PNG, with 24-bit color support, allowing ranges of color akin to a high color JPG. PNG-24 is in no way a replacement format for JPG, however, because it is a loss-less compression format. This means that filesizes can be rather big against a comparable JPG.
BMP — Bitmap
BMP: The Bitmap file format is used for bitmap graphics on the Windows platform only. Unlike other file formats the BMP format stores image data from bottom to top and pixels in blue/green/red order. Compression of BMP files is not supported, so they are usually very large. A familiar application for BMP files is the wallpaper background displayed on the Windows desktop. BMP graphics can be monochrome or color (up to 256 colors in 16-bit mode, or several million in 32 bit mode), but usually cannot be compressed when written to a file. Microsoft Paint, a Windows accessory, is primarily oriented toward the BMP format. This is why you will find BMP files used by so many Windows owners.
TIFF — Tagged Image File Format
TIFF: The Tagged Image File Format is a tag-based format that was developed and maintained by Aldus (now Adobe). It is most commonly used to place photographs and graphics in page layout applications (desktop publishing) or word processors. TIFF produces large file sizes as it preserves a high-quality image. Most applications can read TIFF file formats; however, there are several different “flavors” of TIFFs. If you have a problem with a TIFF file, Adobe Photoshop can resave the file into a TIFF version that most programs can use. TIFF, which is used for bitmap images, is compatible with a wide range of software applications and can be used across platforms such as Macintosh, Windows, and UNIX. The TIFF format is complex, so TIFF files are generally larger than GIF or JPEG files. TIFFs take longer to open.
TIFF supports monochrome, gray-scale, and color graphics (up to 256 16.7 million colors or shades of gray), and saves graphics in compressed or uncompressed format. Corel Draw, among other photo editing programs, uses the TIFF format.
RAW, JPEG and TIFF
There seems to be a lot of confusion among some new digital camera owners about exactly what the difference is between RAW, JPEG and TIFF files. The following is a guide to the file types and how they are related in a typical digital camera.
The digital sensor in the majority of digital cameras is what is known as a BAYER PATTERN sensor. This relates to the arrangement of red, green and blue sensitive areas.
A conventional digital image has pixels which can be red, green, blue of any one of millions of other colors, so to generate such an image from the data output by the sensor, a significant amount of signal processing is required. This processing is called Bayer interpolation because it must calculate what the color of each pixel should be. The color and intensity of each pixel is calculated based on the relative strengths of the red, green and blue channel data from all the neighboring pixels. Each pixel in the converted image now has three parameters: red:intensity, blue:intensity and green:intensity.
RAW data (which Nikon call NEF data) is the output from each of the original red, green and blue sensitive pixels of the image sensor, after being read out of the array by the array electronics and passing through an analog to digital converter. The readout electronics collect and amplify the sensor data and it's at this point that "ISO" (relative sensor speed) is set.
Now one of two things can be done with the RAW data. It can be stored on the memory card, or it can be further processed to yield a JPEG image. The diagram below shows the processes involved:
If the data is stored as a JPEG file, it goes through the Bayer interpolation, is modified by in camera set parameters such as white balance, saturation, sharpness, contrast etc, is subject to JPEG compression and then stored. The advantage of saving JPEG data is that the file size is smaller and the file can be directly read by many programs or even sent directly to a printer. The disadvantage is that there is a quality loss, the amount of loss depending on how much compression is used, the more compression, the smaller the file but the lower the image quality. Lightly compressed JPEG files can save a significant amount of space and lose very little quality.
RAW to JPEG or TIFF conversion
If you save the RAW data, you can then convert it to a viewable JPEG or TIFF file at a later time on a PC. Since it's on a PC you can now pick whatever white balance, contrast, saturation, sharpness etc. you want. So here's the first advantage of saving RAW data. You can change many of the shooting parameters AFTER exposure.
A second advantage of shooting a RAW file is that you can also perform the conversion to a TIFF file. TIFF files are larger than JPEG files, but they retain the full quality of the image. They can be compressed or uncompressed, but the compression scheme is lossless, meaning that although the file gets a little smaller, no information is lost.
When to shoot RAW, when to shoot JPEG?
The main reason to shoot JPEG is that you get more shots on a memory card and it's faster, both in camera and afterwards. If you shoot RAW files you have to then convert them to TIFF or JPEG on a PC before you can view or print them. If you have hundreds of images, this can take some time. If you know you have the correct exposure and white balance as well as the optimum camera set parameters, then a high quality JPEG will give you a print just as good as one from a converted RAW file, so you may as well shoot JPEG.
You shoot RAW when you expect to have to do some post exposure processing. If you're not sure about exposure or white balance, or if you want to maintain the maximum possible allowable post exposure processing, then you'll want to shoot RAW files, convert to 16-bit TIFF, do all your processing, then convert to 8-bit files for printing.
Note that some cameras can store a JPEG image along with the RAW file. This is the best of both worlds, you have a JPEG image which you can quickly extract from the file, but you also have the RAW data which you can later convert and process if there is a problem with the JPEG. The disadvantage is, of course, that this takes up even more storage space