mesa: test for GL_EXT_framebuffer_sRGB in glPopAttrib()

To avoid spurious GL_INVALID_ENUM errors if the extension isn't supported.
(cherry picked from commit 1aee8803f8)
This commit is contained in:
Brian Paul 2012-08-27 21:52:07 -06:00 committed by Andreas Boll
parent db8cb22503
commit 2286bd68a8

View file

@ -993,7 +993,8 @@ _mesa_PopAttrib(void)
_mesa_ClampColorARB(GL_CLAMP_READ_COLOR_ARB, color->ClampReadColor);
/* GL_ARB_framebuffer_sRGB / GL_EXT_framebuffer_sRGB */
_mesa_set_enable(ctx, GL_FRAMEBUFFER_SRGB, color->sRGBEnabled);
if (ctx->Extensions.EXT_framebuffer_sRGB)
_mesa_set_enable(ctx, GL_FRAMEBUFFER_SRGB, color->sRGBEnabled);
}
break;
case GL_CURRENT_BIT: