Data compression

EasyMedium
1234567891011121314151617181920212223242526272829303132333435363738394041
Question 33
Easy

A black and white image has been compressed using run-length encoding (RLE).

Each run of pixels is encoded using a single byte (8 bits):

  • The first bit of each byte represents the colour: 0 for black, 1 for white.
  • The remaining seven bits represent the number of pixels in that run.

Figure 1 shows the bit pattern representing a run of 40 black pixels followed by a run of 75 white pixels.

Figure 1

0010100011001011

Using the same RLE method, give the 16-bit pattern for a run of 18 white pixels followed by a run of 85 black pixels.

Write your answer in Table 1.

Table 1

[2]

Data compression Questions

  1. GCSE
  2. /Computer Science
  3. /Data compression