OSDN Git Service

mesa: Do something sensible when on-line compression is requested but not possible
authorIan Romanick <ian.d.romanick@intel.com>
Tue, 21 Aug 2012 22:20:23 +0000 (15:20 -0700)
committerIan Romanick <ian.d.romanick@intel.com>
Wed, 29 Aug 2012 22:09:38 +0000 (15:09 -0700)
commit42723d88d370a7599398cc1c2349aeb951ba1c57
tree6125f14627d325767430677e578455eea066b247
parent0e0d66446194ab0b2d114dc83e76ec9c9b1a01f1
mesa: Do something sensible when on-line compression is requested but not possible

It is possible to force S3TC extensions to be enabled.  This is
generally done to support applications that will only supply
pre-compressed textures.  This accounts for the vast majority of
applications.

However, there is still the possibility of an application asking for
on-line compression.  In that case, generate a warning and substitute a
generic compressed format.  The driver will either pick an uncompressed
format or a compressed format that Mesa can handle on-line (e.g., FXT1).

This should only cause problems for applications that request on-line
compression and read the compressed texture back.  This is likely an
infinitesimal subset of an already infinitesimal subset.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/main/teximage.c