Differences in Image File Formats

Any artist who works with digital images will inevitably face the decision of what image file format to use. Believe it or not, the little abbreviation at the end of your file names has a big impact on the size and quality of your image. Different file formats are used for different purposes – additionally, file formats may be limited by memory constraints (size) and other factors.  It’s easy to get confused between formats – when should you use a .JPG or a .GIF or a .PNG?  Are the file formats situationally dependent?  How do you know which one to use and when to use it? This guide will help you decide.

Digital Photographers: JPG vs. RAW

More and more digital cameras, and certainly all of the higher-end models and DSLRS, offer the user the choice between shooting images in JPG format and RAW format. When you shoot in JPG format, the image you see on the screen isn’t the same as what was actually captured at first. The camera takes the original image and applies adjustments such as saturation, contrast, and sharpness to it. Each of these attributes is on its own layer of data at first, but after adjusting, the camera compresses them all down into one image – the resulting JPG photograph. Because the image is compressed, the file size is smaller and some of the processing work is done for you. However, the adjustments the camera made cannot be reversed or altered, so you have less control. RAW images, on the other hand, are the original files – the photo you took, without any adjustments made by the camera. RAW images are uncompressed and allow you much more freedom in editing them, but they also take up much more space. So if you’re willing to sacrifice space for control, RAW shooting may be for you. But if you don’t need all that and would prefer more space, using JPG will be much simpler.

Image Formatting: JPG, GIF, PNG, and BMP

There are four main image file formats in use today: JPG, GIF, PNG, and BMP. Each has its benefits and each is suitable for certain types of images, but not so suitable for others.
JPGs are the most common image format. Most images you see on the internet, whether they’re photos, drawings, or website elements, are saved in JPG format. JPGs have low filesizes and are the ideal format for most images. However, JPG is a lossy format, which means that each time a JPG image is saved, it loses data. This isn’t a big deal at first, but if you edit and save a single JPG image enough, the quality will be negatively effected. JPGs have a sliding scale of compression, and most programs compress JPGs heavily by default. This makes them have smaller filesizes, but also make them less sharp and can add ugly artifacts. Saving in the higher qualities is recommended if you use JPGs.

GIFs are also common, but have one significant limitation: a single GIF image can only contain 256 colors. For simpler images, like backgrounds, buttons, or small graphics, this is fine, but photos and larger images with lots of colors should not be saved in GIF format. GIFs can also have transparent backgrounds (ideal for web use) and even be animated. They also have a small filesize.
PNGs are best used for web graphics with more than 256 colors. They are more high-quality than GIFs and JPGs, and are lossless, meaning that you can save them as many times as you want with no compression. Like GIFs, they can be transparent. However, they have large filesizes and cannot be animated.
BMPs are quickly falling out of use, due to being overtaken by the other three main filetypes. BMPs used to be the most popular image format, but they had extremely large filesizes and were unsuitable for web use. Other than local backups for very important images, they do not have many applicable modern uses.

Image Types: Vector vs. Raster

Designers and graphic artists use both vector and raster images in their work, but each has a different purpose. Raster images rely on pixels, but vector images rely on math. When resizing an image, the quality of the result will depend largely on whether it is a vector or a raster. Vector images resize mathematically to retain their smoothness and clarity, while raster images simply stretch their individual pixels to fit the new area. Enlarging a vector image will produce a result that looks just like the original, while resizing a raster will produce a blockier result. However, most images are rasters, and it is very hard to convert a raster to a vector image (although you can convert a vector to a raster easily). Vectors aren’t suitable for photographs and can be difficult to transfer between platforms. Rasters can have more effects applied to them and are more suitable for photos. It all depends what the content of your image is and what you want to use it for.

Print Friendly, PDF & Email