diff --git a/src/hardware/hw_cache.c b/src/hardware/hw_cache.c index a284b8ed0..0b3169147 100644 --- a/src/hardware/hw_cache.c +++ b/src/hardware/hw_cache.c @@ -34,11 +34,7 @@ static INT32 format2bpp(GLTextureFormat_t format) { if (format == GL_TEXFMT_RGBA) return 4; - else if (format == GL_TEXFMT_RGB_565 - || format == GL_TEXFMT_ARGB_1555 - || format == GL_TEXFMT_ARGB_4444 - || format == GL_TEXFMT_ALPHA_INTENSITY_88 - || format == GL_TEXFMT_AP_88) + else if (format == GL_TEXFMT_ALPHA_INTENSITY_88 || format == GL_TEXFMT_AP_88) return 2; else return 1; diff --git a/src/hardware/hw_data.h b/src/hardware/hw_data.h index 1e1381d7c..e5477d729 100644 --- a/src/hardware/hw_data.h +++ b/src/hardware/hw_data.h @@ -29,16 +29,14 @@ typedef enum GLTextureFormat_e { - GL_TEXFMT_ALPHA_8 = 0x2, /* (0..0xFF) alpha */ - GL_TEXFMT_INTENSITY_8 = 0x3, /* (0..0xFF) intensity */ - GL_TEXFMT_ALPHA_INTENSITY_44 = 0x4, - GL_TEXFMT_P_8 = 0x5, /* 8-bit palette */ - GL_TEXFMT_RGBA = 0x6, /* 32 bit RGBA! */ - GL_TEXFMT_RGB_565 = 0xa, - GL_TEXFMT_ARGB_1555 = 0xb, - GL_TEXFMT_ARGB_4444 = 0xc, - GL_TEXFMT_ALPHA_INTENSITY_88 = 0xd, - GL_TEXFMT_AP_88 = 0xe, /* 8-bit alpha 8-bit palette */ + GL_TEXFMT_P_8 = 0x01, /* 8-bit palette */ + GL_TEXFMT_AP_88 = 0x02, /* 8-bit alpha, 8-bit palette */ + + GL_TEXFMT_RGBA = 0x10, /* 32 bit RGBA! */ + + GL_TEXFMT_ALPHA_8 = 0x20, /* (0..0xFF) alpha */ + GL_TEXFMT_INTENSITY_8 = 0x21, /* (0..0xFF) intensity */ + GL_TEXFMT_ALPHA_INTENSITY_88 = 0x22, } GLTextureFormat_t; // data holds the address of the graphics data cached in heap memory diff --git a/src/hardware/r_opengl/r_opengl.c b/src/hardware/r_opengl/r_opengl.c index 04bbd916d..49dbcd08f 100644 --- a/src/hardware/r_opengl/r_opengl.c +++ b/src/hardware/r_opengl/r_opengl.c @@ -2971,11 +2971,7 @@ EXPORT INT32 HWRAPI(GetTextureUsed) (void) int format = tmp->format; if (format == GL_TEXFMT_RGBA) bpp = 4; - else if (format == GL_TEXFMT_RGB_565 - || format == GL_TEXFMT_ARGB_1555 - || format == GL_TEXFMT_ARGB_4444 - || format == GL_TEXFMT_ALPHA_INTENSITY_88 - || format == GL_TEXFMT_AP_88) + else if (format == GL_TEXFMT_ALPHA_INTENSITY_88 || format == GL_TEXFMT_AP_88) bpp = 2; // Add it up!