i965: use vbo_set_[indirect]_draw_func()
authorBrian Paul <brianp@vmware.com>
Thu, 18 Jan 2018 20:50:04 +0000 (13:50 -0700)
committerBrian Paul <brianp@vmware.com>
Wed, 24 Jan 2018 17:12:49 +0000 (10:12 -0700)
Instead of poking into the vbo_context object.

Reviewed-by: Roland Scheidegger <sroland@vmware.com>
src/mesa/drivers/dri/i965/brw_draw.c

index 8692b886e5b2a3f23c35f8c67a06b7b0536f6a15..fe7e8c478faa3c9c9afa349b02f09b6b8dfe02fc 100644 (file)
@@ -1057,12 +1057,11 @@ void
 brw_draw_init(struct brw_context *brw)
 {
    struct gl_context *ctx = &brw->ctx;
-   struct vbo_context *vbo = vbo_context(ctx);
 
    /* Register our drawing function:
     */
-   vbo->draw_prims = brw_draw_prims;
-   vbo->draw_indirect_prims = brw_draw_indirect_prims;
+   vbo_set_draw_func(ctx, brw_draw_prims);
+   vbo_set_indirect_draw_func(ctx, brw_draw_indirect_prims);
 
    for (int i = 0; i < VERT_ATTRIB_MAX; i++)
       brw->vb.inputs[i].buffer = -1;