mesa/es3: Add support for GL_PRIMITIVE_RESTART_FIXED_INDEX
authorIan Romanick <ian.d.romanick@intel.com>
Sat, 11 Aug 2012 05:28:27 +0000 (22:28 -0700)
committerIan Romanick <ian.d.romanick@intel.com>
Fri, 11 Jan 2013 18:57:25 +0000 (10:57 -0800)
commit42ed81a7c3eec215a543c47239cc30536f284ada
tree0f71500ae3bf3a99f98f2481670a88124feb399e
parent00d8ad81ffeda1d2a10b1ee65f4a144467d0afd1
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 <ian.d.romanick@intel.com>
src/mesa/drivers/dri/i965/brw_primitive_restart.c
src/mesa/main/api_arrayelt.c
src/mesa/main/attrib.c
src/mesa/main/enable.c
src/mesa/main/mtypes.h
src/mesa/main/varray.c
src/mesa/state_tracker/st_draw.c
src/mesa/vbo/vbo_exec_array.c
src/mesa/vbo/vbo_primitive_restart.c