Representing Images
Computer Science: OCR GCSE, topic 1.2.26
Bitmap
Most digital images are stored as bitmaps.

Bitmap
- A bitmap image is split up into tiny squares called pixels.
- The colour of each pixel is stored as a binary number.

Colour-depth
- The amount of bits used to store the colour of each pixel is known as the colour depth.
- The greater the number of bits used to represent each pixel, the more unique colours can be stored.
- Common colour depths are 1-bit, 8-bit, 16-bit, and 24-bit.

Resolution
- Resolution represents the number of pixels in an image.
- The number of pixels is found by multiplying the width by the height of the image.
- An example resolution is 1080p which is 1920x1080.

Metadata
- Metadata is extra information that is added to an image file such as:
- The resolution.
- The colour-depth.
- The encoding format.
- The time and date of taking the photo.

File size
- The size (in bits) of an image file is calculated as follows:
- File size (in bits) = image width x image height x colour depth (in bits)
- The size of the image file in bytes is equal to:
- File size (in bytes) = file size (in bits) ÷ 8