summaryrefslogtreecommitdiffstats
path: root/src/mesa/main
diff options
context:
space:
mode:
authorBenjamin Franzke <[email protected]>2011-01-21 14:24:11 +0100
committerKristian Høgsberg <[email protected]>2011-01-24 16:41:29 -0500
commitf1452844fe2522387bbc6633f22aec09b8a06204 (patch)
treeab27386ad00145a83539ccffb298804a52a5f87a /src/mesa/main
parent811ee32a9ef177bec46c82692eeac8bc7297753c (diff)
mesa: allow internalFormat=GL_BGRA_EXT in TexImage2D
Diffstat (limited to 'src/mesa/main')
-rw-r--r--src/mesa/main/teximage.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c
index 47d509396a7..c3cd6b66ae6 100644
--- a/src/mesa/main/teximage.c
+++ b/src/mesa/main/teximage.c
@@ -183,6 +183,15 @@ _mesa_base_tex_format( struct gl_context *ctx, GLint internalFormat )
; /* fallthrough */
}
+ if (ctx->Extensions.EXT_texture_format_BGRA8888) {
+ switch (internalFormat) {
+ case GL_BGRA_EXT:
+ return GL_RGBA;
+ default:
+ ; /* fallthrough */
+ }
+ }
+
if (ctx->Extensions.EXT_paletted_texture) {
switch (internalFormat) {
case GL_COLOR_INDEX: