From e62b82a693e6835dce809e924b4a2335486659d4 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Mathias=20Fr=C3=B6hlich?= Date: Tue, 11 Dec 2018 18:45:43 +0100 Subject: [PATCH] i965: Make use of the vertex format functions in i965. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit v2: Style fixes. Reviewed-by: Matt Turner Reviewed-by: Ian Romanick Signed-off-by: Mathias Fröhlich Part-of: --- src/mesa/drivers/dri/i965/brw_draw.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_draw.c b/src/mesa/drivers/dri/i965/brw_draw.c index 152012a6c16..815dc2bc969 100644 --- a/src/mesa/drivers/dri/i965/brw_draw.c +++ b/src/mesa/drivers/dri/i965/brw_draw.c @@ -347,9 +347,8 @@ brw_merge_inputs(struct brw_context *brw) unsigned vaomask = vs_inputs & _mesa_draw_array_bits(ctx); while (vaomask) { const gl_vert_attrib i = u_bit_scan(&vaomask); - const struct gl_array_attributes *glattrib = - _mesa_draw_array_attrib(vao, i); - const uint8_t wa_flags = get_wa_flags(&glattrib->Format); + const uint8_t wa_flags = + get_wa_flags(_mesa_draw_array_format(vao, i)); if (brw->vb.attrib_wa_flags[i] != wa_flags) { brw->vb.attrib_wa_flags[i] = wa_flags; @@ -360,9 +359,8 @@ brw_merge_inputs(struct brw_context *brw) unsigned currmask = vs_inputs & _mesa_draw_current_bits(ctx); while (currmask) { const gl_vert_attrib i = u_bit_scan(&currmask); - const struct gl_array_attributes *glattrib = - _mesa_draw_current_attrib(ctx, i); - const uint8_t wa_flags = get_wa_flags(&glattrib->Format); + const uint8_t wa_flags = + get_wa_flags(_mesa_draw_current_format(ctx, i)); if (brw->vb.attrib_wa_flags[i] != wa_flags) { brw->vb.attrib_wa_flags[i] = wa_flags; -- 2.30.2