diff options
Diffstat (limited to 'src/mesa/main/colormac.h')
-rw-r--r-- | src/mesa/main/colormac.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mesa/main/colormac.h b/src/mesa/main/colormac.h index 245fb658bb..065f9f937a 100644 --- a/src/mesa/main/colormac.h +++ b/src/mesa/main/colormac.h @@ -198,12 +198,19 @@ do { \ ((((B) & 0xf8) >> 1) | (((G) & 0xc0) >> 6) | (((G) & 0x38) << 10) | (((R) & 0xf8) << 5) | \ ((A) ? 0x80 : 0)) +#define PACK_COLOR_2101010( A, B, G, R ) \ + (((B) << 22) | ((G) << 12) | ((R) << 2) | \ + (((A) & 0xc0) << 24)) + #define PACK_COLOR_4444( R, G, B, A ) \ ((((R) & 0xf0) << 8) | (((G) & 0xf0) << 4) | ((B) & 0xf0) | ((A) >> 4)) #define PACK_COLOR_4444_REV( R, G, B, A ) \ ((((B) & 0xf0) << 8) | (((A) & 0xf0) << 4) | ((R) & 0xf0) | ((G) >> 4)) +#define PACK_COLOR_44( L, A ) \ + (((L) & 0xf0) | (((A) & 0xf0) >> 4)) + #define PACK_COLOR_88( L, A ) \ (((L) << 8) | (A)) |