summaryrefslogtreecommitdiffstats
path: root/src/mesa/tnl/t_draw.c
diff options
context:
space:
mode:
authorMathias Fröhlich <[email protected]>2018-04-01 20:18:36 +0200
committerMathias Fröhlich <[email protected]>2018-05-10 07:06:16 +0200
commit881d2fcafaddd391b03753173d126148c9dafbcf (patch)
tree74835b8cb2393239e5257f567daa5f2429c456af /src/mesa/tnl/t_draw.c
parent899476b6b1d41c5ed08391843110c7d62b2ca863 (diff)
mesa: Remove Array._DrawArrays.
Only tnl based drivers still use this array. So remove it from core mesa and use Array._DrawVAO instead. Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Mathias Fröhlich <[email protected]>
Diffstat (limited to 'src/mesa/tnl/t_draw.c')
-rw-r--r--src/mesa/tnl/t_draw.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/mesa/tnl/t_draw.c b/src/mesa/tnl/t_draw.c
index a83b98eede1..9814cdcec18 100644
--- a/src/mesa/tnl/t_draw.c
+++ b/src/mesa/tnl/t_draw.c
@@ -537,12 +537,12 @@ void _tnl_draw_prims(struct gl_context *ctx,
}
-void
+const struct gl_vertex_array*
_tnl_bind_inputs( struct gl_context *ctx )
{
TNLcontext *tnl = TNL_CONTEXT(ctx);
- _mesa_set_drawing_arrays(ctx, tnl->draw_arrays.inputs);
_vbo_update_inputs(ctx, &tnl->draw_arrays);
+ return tnl->draw_arrays.inputs;
}
@@ -558,12 +558,11 @@ _tnl_draw(struct gl_context *ctx,
struct gl_transform_feedback_object *tfb_vertcount,
unsigned stream, struct gl_buffer_object *indirect)
{
- /* Update TNLcontext::draw_arrays and set that pointer
- * into Array._DrawArrays.
+ /* Update TNLcontext::draw_arrays and return that pointer.
*/
- _tnl_bind_inputs(ctx);
+ const struct gl_vertex_array* arrays = _tnl_bind_inputs(ctx);
- _tnl_draw_prims(ctx, ctx->Array._DrawArrays, prim, nr_prims, ib,
+ _tnl_draw_prims(ctx, arrays, prim, nr_prims, ib,
index_bounds_valid, min_index, max_index,
tfb_vertcount, stream, indirect);
}