diff options
author | Erik Faye-Lund <[email protected]> | 2019-02-25 13:34:41 +0100 |
---|---|---|
committer | Erik Faye-Lund <[email protected]> | 2019-05-29 10:54:09 +0200 |
commit | b9e9d701dc8f08e6f9934de00a4059800a23d159 (patch) | |
tree | a9b6c814272d6057bfaf06eb5f2d2493468db32c /src | |
parent | 34ade0dc7c1d8cc974435432d1ce4bdb034443c8 (diff) |
mesa/main: correct extension-checks for GL_PRIMITIVE_RESTART_FIXED_INDEX
This shouldn't be allowed in GLES 1/2.
Signed-off-by: Erik Faye-Lund <[email protected]>
Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/main/enable.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/mesa/main/enable.c b/src/mesa/main/enable.c index 42b862b6258..3d59d322ca5 100644 --- a/src/mesa/main/enable.c +++ b/src/mesa/main/enable.c @@ -1108,7 +1108,7 @@ _mesa_set_enable(struct gl_context *ctx, GLenum cap, GLboolean state) break; case GL_PRIMITIVE_RESTART_FIXED_INDEX: - if (!_mesa_is_gles3(ctx) && !ctx->Extensions.ARB_ES3_compatibility) + if (!_mesa_is_gles3(ctx) && !_mesa_has_ARB_ES3_compatibility(ctx)) goto invalid_enum_error; if (ctx->Array.PrimitiveRestartFixedIndex != state) { FLUSH_VERTICES(ctx, 0); @@ -1739,9 +1739,8 @@ _mesa_IsEnabled( GLenum cap ) return ctx->Array.PrimitiveRestart; case GL_PRIMITIVE_RESTART_FIXED_INDEX: - if (!_mesa_is_gles3(ctx) && !ctx->Extensions.ARB_ES3_compatibility) { + if (!_mesa_is_gles3(ctx) && !_mesa_has_ARB_ES3_compatibility(ctx)) goto invalid_enum_error; - } return ctx->Array.PrimitiveRestartFixedIndex; /* GL3.0 - GL_framebuffer_sRGB */ |