diff options
author | Ian Romanick <[email protected]> | 2012-09-18 15:19:18 +0200 |
---|---|---|
committer | Ian Romanick <[email protected]> | 2012-09-20 11:42:56 +0200 |
commit | ae3023e9675a033ff66b9bb14598aa1f02530d7f (patch) | |
tree | 2da4fd93212aa898ca41795d6befd450db23eb64 /src/mesa/main | |
parent | bd8fb9e80562fbe0ff76cae50fc411635096f3a9 (diff) |
mesa: Allow glGetTexParameter of GL_TEXTURE_SRGB_DECODE_EXT
This was already (correctly) supported for glGetSamplerParameter paths.
NOTE: This is a candidate for stable branches.
Signed-off-by: Ian Romanick <[email protected]>
Reviewed-by: Brian Paul <[email protected]>
Diffstat (limited to 'src/mesa/main')
-rw-r--r-- | src/mesa/main/texparam.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/mesa/main/texparam.c b/src/mesa/main/texparam.c index 63a63b732a5..f73e2b5f022 100644 --- a/src/mesa/main/texparam.c +++ b/src/mesa/main/texparam.c @@ -1440,6 +1440,12 @@ _mesa_GetTexParameterfv( GLenum target, GLenum pname, GLfloat *params ) *params = (GLfloat) obj->Immutable; break; + case GL_TEXTURE_SRGB_DECODE_EXT: + if (!ctx->Extensions.EXT_texture_sRGB_decode) + goto invalid_pname; + *params = (GLfloat) obj->Sampler.sRGBDecode; + break; + default: goto invalid_pname; } @@ -1612,6 +1618,12 @@ _mesa_GetTexParameteriv( GLenum target, GLenum pname, GLint *params ) *params = obj->RequiredTextureImageUnits; break; + case GL_TEXTURE_SRGB_DECODE_EXT: + if (!ctx->Extensions.EXT_texture_sRGB_decode) + goto invalid_pname; + *params = obj->Sampler.sRGBDecode; + break; + default: goto invalid_pname; } |