OCR GCSE J277

Topic: Image Representation (Extended)

Master pixels, colour depth, complex file size calculations, and metadata.

1. Bitmaps and Pixels

Definitions

  • Pixel: Defined as the "smallest unit" or "single part" of an image.
  • Bitmap: A bitmap image is constructed from a grid of pixels.

Binary Representation

  • Computers use binary because hardware (transistors) consists of two states (on/off).
  • Each pixel is assigned a specific binary code corresponding to a colour.
  • Grid Mapping: You must be able to interpret a binary bit stream into a grid of pixels using a colour lookup table (e.g., converting 0010 to "Green").

Quiz: Bitmaps & Binary

1. What is the definition of a "Pixel"?
2. Why do computers represent images in binary?
3. Which of the following best describes a "Bitmap"?
4. In a simple black and white image (1-bit depth), how many bits are required to store a single pixel?

2. Image Attributes

Resolution

Image Resolution is the number of pixels in an image.

$$Width \times Height$$

Colour Depth

Colour Depth is the number of bits used to store the colour for each pixel.

e.g., 8-bit depth allows for 256 colours.

Effects of Increasing Colour Depth

If you increase depth (e.g., from 4 bits to 16 bits):

  • File Size: Increases (more bits per pixel).
  • Quality: Improves (more distinct colours/detail).

Quiz: Attributes

5. What happens to the file size if you increase the colour depth?
6. Define "Colour Depth".
7. What is Image Resolution?
8. How does increasing the colour depth affect the image quality?

3. Mathematical Calculations

Calculating Colours & Bits

  • Max Colours: Use formula \(2^n\) (where \(n\) is bits). E.g., 4 bits = \(2^4 = 16\) colours.
  • Bits Needed: For a specific number of colours, find the power of 2 that covers it.
  • Example: A logo with 3 distinct colours requires 2 bits (because \(2^1=2\) is too low, \(2^2=4\) is sufficient).

Calculating File Size

Calculate total file size using:

$$Width \times Height \times Colour\:Depth$$

Unit Conversion (Memorise this):

  • Result is in Bits.
  • Divide by 8 to get Bytes.
  • Divide by 1000 (or 1024) to get Kilobytes.

Quiz: Hard Calculations

No workings are provided. You must determine the steps.

9. An image uses 16 colours. What is the minimum bit depth required per pixel?
bits
10. An icon is 50 x 50 pixels and uses 4 colours. Calculate the file size in bytes.
bytes

Hint: Determine the bit depth first ($2^?=4$). Then (W*H*D)/8.

11. An image is 100 x 200 pixels with a colour depth of 4 bits. Calculate the file size in Kilobytes (KB).

(Use 1000 bytes = 1 KB for this calculation)

KB
12. How many distinct colours can be represented with a bit depth of 3 bits?
colours
13. A small sprite is 10 x 10 pixels with a colour depth of 8 bits. Calculate the file size in bits.
bits
14. An image is purely Black and White (2 colours). What is the minimum bit depth required?
bit

4. Metadata

Definition

Metadata is "data about the data" or "information about the file". It is stored alongside the raw image data.

Examples of Metadata

You need to be able to identify these examples:

  • Height and Width (Dimensions)
  • Colour Depth
  • Resolution
  • Date/Time created
  • Geolocation (GPS)
  • File Type

Important Note: Metadata does NOT store the colour of individual pixels.

Quiz: Metadata

15. Which of the following is NOT an example of metadata?
16. What is the standard definition of Metadata?
17. Which item would be found in the image metadata?
18. True or False: Metadata contains the raw binary data for every single pixel in the image.

Revision Complete!

Well done, Student!

You have covered the core Image Representation concepts for J277.

Your Score:
0 / 18