From 42ed81a7c3eec215a543c47239cc30536f284ada Mon Sep 17 00:00:00 2001 From: Ian Romanick Date: Fri, 10 Aug 2012 22:28:27 -0700 Subject: mesa/es3: Add support for GL_PRIMITIVE_RESTART_FIXED_INDEX This requires some derived state. The cut vertex used is either the value specified by glPrimitiveRestartIndex or it's hard-coded to ~0. The derived state gl_array_attrib::_RestartIndex captures this value. In addition, the derived state gl_array_attrib::_PrimitiveRestart is set whenever either gl_array_attrib::PrimitiveRestart or gl_array_attrib::PrimitiveRestartFixedIndex is set. v2: Use _mesa_is_gles3. Signed-off-by: Ian Romanick --- src/mesa/state_tracker/st_draw.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/mesa/state_tracker/st_draw.c') diff --git a/src/mesa/state_tracker/st_draw.c b/src/mesa/state_tracker/st_draw.c index 4800e1c879f..7de2bb9b853 100644 --- a/src/mesa/state_tracker/st_draw.c +++ b/src/mesa/state_tracker/st_draw.c @@ -230,8 +230,8 @@ st_draw_vbo(struct gl_context *ctx, /* The VBO module handles restart for the non-indexed GLDrawArrays * so we only set these fields for indexed drawing: */ - info.primitive_restart = ctx->Array.PrimitiveRestart; - info.restart_index = ctx->Array.RestartIndex; + info.primitive_restart = ctx->Array._PrimitiveRestart; + info.restart_index = ctx->Array._RestartIndex; } else { /* Transform feedback drawing is always non-indexed. */ -- cgit v1.2.3