Newer OSs don't show this, but I remember getting confused about this in Windows XP, where you had the opion for 24-bit and 32-bit color. 32-bit color generally includes an alpha channel, but we haven't yet developed transparent displays which can display blacks, so what is the extra 8 bytes for?
3 Answers
The screen display itself might not be "transparent" but the desktop effects certainly can be and are.
24-bit is basically a desktop or screen that does not support any kind of transparent effects. 32-bits allows the software and graphics card hardware to make a window or area show things that are behind.
Windows uses this a great deal with it's "glass" effects. Windows 11 and 10 have areas such as the task bar where the alpha channel is used to define which pixels are transparent and how transparent they are.
The graphics card uses the alpha channel for compositing and merging images together and uses it to work out whether things behind other things are visible or not. It is not present at the display.
From Wikipedia: DisplayPort Resolution and refresh frequency limits (emphasis is mine)
The 8 extra bits are for alpha channel information, which is only present in software. At the transmission stage, this information has already been incorporated into the primary color channels, so the actual video data transmitted across the cable only contains 24 bits per pixel.
As a visual example Windows 7 used the alpha channel to do this:
Notice that you can see the desktop background image through the Start Menu. Without the alpha channel what you get is something similar to this, where the Start menu is a solid colour and you cannot see the desktop background image through it:
2Data alignment – 32-bit values are a natural size for CPUs used today; if each pixel is a 32-bit value it can be easily read or written in a single instruction, whereas if you pack it into 24 bits you might end up needing to bit-shift it into the right position or even handle as two or three separate values (like three 8-bit bytes) because there's no instruction to write a 24-bit value at once.
Consider that 24-bit in physical display terms to really be 32-bit with 8 bits thrown away. See Wikipedia - Color Depth
These days you would actually tend towards calling them 8-bit displays, as they use 8 bits per channel.
New higher bit-depth screens are referred to as 10-bit displays.
See this article for further detail - 8-Bit, 10-Bit, What Does It All Mean for Your Videos?
