Using 4 Bits per Pixel

The 4-bpp format usually is a palettized format. The frame buffer itself can be implemented either as 2 pixels packed into each byte or as 1 pixel per byte. The following illustration shows the arrangement of memory for the format.

If you choose to implement just 1 pixel per byte, the driver should represent the display mode as 8 bpp with a 16-color palette. The relevant bits in each byte should be the 4 lowest bits, while the 4 highest bits should always be 0. For more information on formats in which single pixels do not fill entire bytes, see Using 5 or 6 Bits per Pixel Format. For best results, use the following standard Windows CE 16-color palette.