Mesa (master): mesa/main: clean up extension-check for GL_STENCIL_TEST_TWO_SIDE
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed Apr 1 11:21:52 UTC 2020
Module: Mesa
Branch: master
Commit: 67a7022f83965795c5a5080f3ac5aedb7d9387b3
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=67a7022f83965795c5a5080f3ac5aedb7d9387b3
Author: Erik Faye-Lund <erik.faye-lund at collabora.com>
Date: Mon Feb 25 12:54:13 2019 +0100
mesa/main: clean up extension-check for GL_STENCIL_TEST_TWO_SIDE
Signed-off-by: Erik Faye-Lund <erik.faye-lund at collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/329>
---
src/mesa/main/enable.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/src/mesa/main/enable.c b/src/mesa/main/enable.c
index 945c7cf6aab..09ac6ab5db3 100644
--- a/src/mesa/main/enable.c
+++ b/src/mesa/main/enable.c
@@ -1067,9 +1067,8 @@ _mesa_set_enable(struct gl_context *ctx, GLenum cap, GLboolean state)
/* GL_EXT_stencil_two_side */
case GL_STENCIL_TEST_TWO_SIDE_EXT:
- if (ctx->API != API_OPENGL_COMPAT)
+ if (!_mesa_has_EXT_stencil_two_side(ctx))
goto invalid_enum_error;
- CHECK_EXTENSION(EXT_stencil_two_side);
if (ctx->Stencil.TestTwoSide == state)
return;
FLUSH_VERTICES(ctx, ctx->DriverFlags.NewStencil ? 0 : _NEW_STENCIL);
@@ -1832,9 +1831,8 @@ _mesa_IsEnabled( GLenum cap )
/* GL_EXT_stencil_two_side */
case GL_STENCIL_TEST_TWO_SIDE_EXT:
- if (ctx->API != API_OPENGL_COMPAT)
+ if (!_mesa_has_EXT_stencil_two_side(ctx))
goto invalid_enum_error;
- CHECK_EXTENSION(EXT_stencil_two_side);
return ctx->Stencil.TestTwoSide;
case GL_FRAGMENT_PROGRAM_ARB:
More information about the mesa-commit
mailing list