if (vid_priv->colour_bg)
val = 255 - val;
- out = val | val << 8 | val << 16;
+ if (vid_priv->format == VIDEO_X2R10G10B10)
+ out = val << 2 | val << 12 | val << 22;
+ else
+ out = val | val << 8 | val << 16;
if (vid_priv->colour_fg)
*dst++ |= out;
else
for (i = 0; i < width; i++) {
int out;
- out = val | val << 8 | val << 16;
+ if (vid_priv->format == VIDEO_X2R10G10B10)
+ out = val << 2 | val << 12 | val << 22;
+ else
+ out = val | val << 8 | val << 16;
if (vid_priv->colour_fg)
*dst++ |= out;
else