Standard File Formats

Designers should select Standard File Formats carefully when planning a software product to:

  • minimise delays in displaying content

  • reduce the overall application size

  • ensure compatibility with different computer systems

Audio

There are two file formats for sound we will look at:

  • WAV and MP3

WAV stands for Waveform Audio and its file extension is wav it usually an uncompressed audio format and can be very high quality.

MP3 stands for Mpeg Layer 3 and its File Extension is mp3. It is a lossy compressed Audio Format. This means that it will remove data in order to reduce the file size.

Graphics

GIF

A GIF (Graphics Interchange Format) is a lossless compressed bitmap format.

It can only support up to 8 bit colour depth which means it can only support 256 colours. It has one feature that no other image format has and that is that can support animation natively.

JPEG

JPEG (Joint Photographic Expert Group) files use maths to reduce the amount of colour data stored in an image so that it is a smaller file size. Its file extension is jpg although can have the jpeg file extension too. It is a lossy compressed bitmap style format. It can support up to 24bit colour depth (16,777,216 colours). It can have a file extension of JPG or JPEG.

JPEG’s also support metadata when images are taken such as in the image below the time taken etc has been attached to the image as metadata.

Metadata such as the location, time and date can be embedded inside a JPG file.

PNG

PNG (Portable Network Graphics) was originally created as an improvement for the GIF standard. It will have a file extension of PNG.

It is a lossless compressed bitmap style format which means it reduces file size without any loss of quality from the image. It can support transparency and up to 24 bit colour depth.

on the left and the same image as a png on the right.

JPEG Version

The JPG version of the dolphin image does not support transparency.

PNG Version

The PNG version of the dolphin image supports transparency. so we are able to see the background behind the image.

File Types Summary

Graphic File Formats Summary

Sound File Formats Summary

Video File Formats Summary

Factors Affecting Size and Quality

The sampling rate is defined by the number of samples per second taken from an analogue audio recording to create a digital audio recording. It is usually measured in Hertz.

In digital audio the most common sampling rates are 44.1 kHz, 48 kHz, 96 kHz and 192 kHz. The higher the sampling rate is, the better the audio quality. However more samples require a larger amount of storage space.

In the images to the right the blue bars are the digital samples trying to represent the red analogue data as accurately as possible.

You will notice that the more samples we take the more accurately we can

Sample Resolution

Sample resolution is defined by the number of bits used to store each audio sample. CD audio is recorded at 16-bit sample resolution and is considered high quality.

The higher the sample resolution is, the lower the signal to noise ratio. However, as before, the file size increases with the resolution.

Image Resolution

Resolution is a measure of the number of pixels in an image. The higher the resolution, the smoother the image appears. High resolution images have large file sizes due to the fact they store more pixels.

Colour Depth

Colour depth (reminder here) is the number of bits used to store the colour of each pixel in an image, each colour is represented using a binary value. The higher the colour depth, the more colours can be represented in the image. Images with high colour depth have larger file sizes.

Compression

All software products – especially those with multimedia elements – should make use of file compression to:

  • reduce overall application size

  • increase transmission speeds over networks

  • decrease time taken to load from storage devices

Designers need to be careful when using certain types of compression as some loss of media quality may occur.

As images become larger and more complex the need for compression is becoming more important. Compression is the process of reducing the file size of a file. One method would be to reduce the bit depth of the image, but this could mean a visible loss in quality.

Types of Compression

There are two main methods of compression:

Lossy Compression

This is when detail from the file is removed. Too much of this will significantly reduce the quality of the file if applied too much. JPG files are a good example of this.

Lossless Compression

This is when the data of the file is manipulated so that for example repeated data can be manipulated and stored in a more efficient manner. The key fact being that the original source file can always be re-created. PNG's can use lossless compression.

Examples of JPEG Compression

The gallery below shows the effects of increasing JPEG compression on an image. The higher the level of compression the smaller the file size but you will also notice that there are artefacts appearing where too much information has been removed.

This file is licensed under the Creative Commons Attribution-Share Alike 3.0 Unported license. Subject to disclaimers.

Attribution: Toytoy at English Wikipedia