OSDN Git Service

mesa: Don't choose S3TC for generic compression if we can't compress.
authorEric Anholt <eric@anholt.net>
Thu, 29 Aug 2013 15:09:05 +0000 (08:09 -0700)
committerEric Anholt <eric@anholt.net>
Fri, 30 Aug 2013 18:49:09 +0000 (11:49 -0700)
commitbdf3f50e9a85e4c063b46ceaf23bceb07b06b82e
tree769c8f05670cc09f6ed7885e49751004393d6e68
parentb188467fdf71d8f4c5fab4aafae1253f64d9aab4
mesa: Don't choose S3TC for generic compression if we can't compress.

If the app is asking us to do GL_COMPRESSED_RGBA, then the app obviously
doesn't have pre-compressed data to hand us.  So don't choose a storage
format that we won't actually be able to compress and store.

Fixes black screen in warzone2100 when libtxc_dxtn is not present.  Also
66 piglit tests.

NOTE: This is a candidate for the 9.2 branch.
Reported-by: Paul Wise <pabs@debian.org>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/main/texformat.c