diff options
author | Ian Romanick <[email protected]> | 2015-11-10 15:18:54 -0800 |
---|---|---|
committer | Ian Romanick <[email protected]> | 2016-01-11 15:38:04 -0800 |
commit | 5be700e5cc7c391ed197e46d2928856761409e8b (patch) | |
tree | 5f0f3c9f1dbc58c58d4f98473091d309ed13090a /src/mesa/drivers/common/meta.c | |
parent | 1799eddb510bef502901c097ddce9e40d58ff09d (diff) |
meta: Unconditionally set GL_SKIP_DECODE_EXT
The path that depends on this will be avoided (by fallback_required) if
the extension is not supported. _mesa_set_sampler_srgb_decode does not
generate GL errors (by design), so there are no problems there.
I kept this change separate and last because it is one of the few in the
series that is not a candidate for the stable branch.
Signed-off-by: Ian Romanick <[email protected]>
Reviewed-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'src/mesa/drivers/common/meta.c')
-rw-r--r-- | src/mesa/drivers/common/meta.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/mesa/drivers/common/meta.c b/src/mesa/drivers/common/meta.c index b026e476b65..1ed0e4d1f59 100644 --- a/src/mesa/drivers/common/meta.c +++ b/src/mesa/drivers/common/meta.c @@ -3132,10 +3132,8 @@ decompress_texture_image(struct gl_context *ctx, /* nearest filtering */ _mesa_set_sampler_filters(ctx, decompress->samp_obj, GL_NEAREST, GL_NEAREST); - /* No sRGB decode or encode.*/ - if (ctx->Extensions.EXT_texture_sRGB_decode) { - _mesa_set_sampler_srgb_decode(ctx, decompress->samp_obj, GL_SKIP_DECODE_EXT); - } + /* We don't want to encode or decode sRGB values; treat them as linear. */ + _mesa_set_sampler_srgb_decode(ctx, decompress->samp_obj, GL_SKIP_DECODE_EXT); } _mesa_bind_sampler(ctx, ctx->Texture.CurrentUnit, decompress->samp_obj); |