summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2020-03-21 20:01:37 -0400
committerMarge Bot <[email protected]>2020-04-27 11:56:06 +0000
commit00b57915414da01868ff40ecacfe61db9af0d9c5 (patch)
treee05ef60cd6abb4f2c84db6fc7ec95560ceae02dd /src/mesa
parentee0263e03fbc897767bf8b787dc0cc917481e826 (diff)
mesa: reset primitive restart state in glClientAttribDefaultEXT
Reviewed-by: Erik Faye-Lund <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4758>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/main/attrib.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/mesa/main/attrib.c b/src/mesa/main/attrib.c
index b7e06ca21da..e3df99b0396 100644
--- a/src/mesa/main/attrib.c
+++ b/src/mesa/main/attrib.c
@@ -1926,6 +1926,15 @@ _mesa_ClientAttribDefaultEXT( GLbitfield mask )
}
_mesa_ClientActiveTexture(GL_TEXTURE0);
+
+ _mesa_PrimitiveRestartIndex_no_error(0);
+ if (ctx->Version >= 31)
+ _mesa_Disable(GL_PRIMITIVE_RESTART);
+ else if (_mesa_has_NV_primitive_restart(ctx))
+ _mesa_DisableClientState(GL_PRIMITIVE_RESTART_NV);
+
+ if (_mesa_has_ARB_ES3_compatibility(ctx))
+ _mesa_Disable(GL_PRIMITIVE_RESTART_FIXED_INDEX);
}
}