summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/formats.c
diff options
context:
space:
mode:
authorJason Ekstrand <[email protected]>2014-08-22 20:32:27 -0700
committerIago Toral Quiroga <[email protected]>2015-01-12 11:20:27 +0100
commit96fe6191cb8c61ca5ae7c49f54db83f3b44ed126 (patch)
tree2fb827970e9532c18d18be63c5b7a60602612f96 /src/mesa/main/formats.c
parent3e4669a8f3f61dab54faf1ae8512569bca1e54da (diff)
mesa: Fix A1R5G5B5 packing/unpacking
As with B5G6R5, these have been left broken with comments saying they are. Signed-off-by: Jason Ekstrand <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src/mesa/main/formats.c')
-rw-r--r--src/mesa/main/formats.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/main/formats.c b/src/mesa/main/formats.c
index 1315d368c27..676ac2781ae 100644
--- a/src/mesa/main/formats.c
+++ b/src/mesa/main/formats.c
@@ -1487,7 +1487,8 @@ _mesa_format_matches_format_and_type(mesa_format mesa_format,
!swapBytes;
case MESA_FORMAT_A1R5G5B5_UNORM:
- return GL_FALSE;
+ return format == GL_BGRA && type == GL_UNSIGNED_SHORT_5_5_5_1 &&
+ !swapBytes;
case MESA_FORMAT_L4A4_UNORM:
return GL_FALSE;