diff options
author | Eric Anholt <[email protected]> | 2011-01-04 16:29:26 -0800 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2011-01-04 16:43:35 -0800 |
commit | 06cb1a6a5bdba5654408e3568584e1ab168266b7 (patch) | |
tree | b88347f16bcae3a14e787db8bd8b8e5c91938be8 /src/mesa/drivers/dri/intel | |
parent | 5a3f31575bf0657661c3e66a4c95c3298c78e441 (diff) |
i965: Add support for SRGB DXT1 formats.
This makes
fbo-generatemipmap-formats GL_EXT_texture_sRGB-s3tc
match
fbo-generatemipmap-formats GL_EXT_texture_compression_s3tc
and swrast in bad DXT1_RGBA alpha=0 handling, but it means we won't
unpack and repack someone's textures into uncompressed SARGB8 format.
Diffstat (limited to 'src/mesa/drivers/dri/intel')
-rw-r--r-- | src/mesa/drivers/dri/intel/intel_context.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_context.c b/src/mesa/drivers/dri/intel/intel_context.c index 4255c0ea73a..34deb2c2fc9 100644 --- a/src/mesa/drivers/dri/intel/intel_context.c +++ b/src/mesa/drivers/dri/intel/intel_context.c @@ -734,7 +734,11 @@ intelInitContext(struct intel_context *intel, /* GL_EXT_texture_sRGB */ ctx->TextureFormatSupported[MESA_FORMAT_SARGB8] = GL_TRUE; - ctx->TextureFormatSupported[MESA_FORMAT_SRGB_DXT1] = GL_TRUE; + if (intel->gen >= 5 || intel->is_g4x) + ctx->TextureFormatSupported[MESA_FORMAT_SRGB_DXT1] = GL_TRUE; + ctx->TextureFormatSupported[MESA_FORMAT_SRGBA_DXT1] = GL_TRUE; + ctx->TextureFormatSupported[MESA_FORMAT_SRGBA_DXT3] = GL_TRUE; + ctx->TextureFormatSupported[MESA_FORMAT_SRGBA_DXT5] = GL_TRUE; if (intel->has_luminance_srgb) { ctx->TextureFormatSupported[MESA_FORMAT_SL8] = GL_TRUE; ctx->TextureFormatSupported[MESA_FORMAT_SLA8] = GL_TRUE; |