From 955cfd151f79d704e10749f89aad8b692c6673db Mon Sep 17 00:00:00 2001 From: UnknownShadow200 Date: Mon, 7 Oct 2019 19:40:55 +1100 Subject: [PATCH] Fix textures on big-endian systems. We must not forget our PowerPC comrades --- src/Bitmap.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Bitmap.h b/src/Bitmap.h index 6c662612f..89442efeb 100644 --- a/src/Bitmap.h +++ b/src/Bitmap.h @@ -13,6 +13,11 @@ typedef cc_uint32 BitmapCol; #define BITMAPCOL_G_SHIFT 8 #define BITMAPCOL_B_SHIFT 16 #define BITMAPCOL_A_SHIFT 24 +#elif defined CC_BIG_ENDIAN +#define BITMAPCOL_A_SHIFT 0 +#define BITMAPCOL_R_SHIFT 8 +#define BITMAPCOL_G_SHIFT 16 +#define BITMAPCOL_B_SHIFT 24 #else #define BITMAPCOL_B_SHIFT 0 #define BITMAPCOL_G_SHIFT 8