Skip to content

i420_rgb: fix 24-bit/32-bit shifts and add 16-bit/15-bit support

Steve Lhomme requested to merge robUx4/vlc:i420_rgb_shift into master

Since RGB32+mask and RGB24+mask the equivalent chromas without a mask don't have a... mask. We need to set the value shift for these chromas.

Add 16/15 bits support. The shifts are the same regardless of endianness. But we can only write RGB values in the system endianness. For example writing a uint16_t value of 0x07e0 will write [e0][07] on a little-endian machine which does correspond to 0x07e0 when read back as a uint16_t.

Merge request reports