If there are manufacturers which don't support linear framebuffers out
there, then there is probably someone who want a 15-bit mode, too.
}
break;
+ case PXF_LE_RGB15_555:
+ {
+ uint16_t pxv =
+ ((bgra >> 3) & 0x1f) +
+ ((bgra >> (2+8-5)) & (0x1f << 5)) +
+ ((bgra >> (3+16-10)) & (0x1f << 10));
+
+ *(uint16_t *)ptr = pxv;
+ ptr = (uint16_t *)ptr + 1;
+ }
+ break;
+
case PXF_NONE: /* Shuts up gcc */
break;
}
(mi->memory_layout == 6 && mi->rpos == 11 && mi->gpos == 5 &&
mi->bpos == 0)))
pxf = PXF_LE_RGB16_565;
+ else if (mi->bpp == 15 &&
+ (mi->memory_layout == 4 ||
+ (mi->memory_layout == 6 && mi->rpos == 10 && mi->gpos == 5 &&
+ mi->bpos == 0)))
+ pxf = PXF_LE_RGB15_555;
if (pxf < bestpxf) {
debug("Best mode so far, pxf = %d\n", pxf);
PXF_BGR24, /* 24-bit BGR */
PXF_BGRA32, /* 32-bit BGRA */
PXF_LE_RGB16_565, /* 16-bit littleendian 5:6:5 RGB */
+ PXF_LE_RGB15_555, /* 15-bit littleendian 5:5:5 RGB */
PXF_NONE
};