From: Keith Whitwell Date: Fri, 6 Nov 2009 14:18:28 +0000 (+0000) Subject: i965g: propogate index size state X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=4d1ae7a546250548332e432f305ce47bd97967c3;p=mesa.git i965g: propogate index size state --- diff --git a/src/gallium/drivers/i965/brw_draw.c b/src/gallium/drivers/i965/brw_draw.c index 88cb31ad546..84803e43bef 100644 --- a/src/gallium/drivers/i965/brw_draw.c +++ b/src/gallium/drivers/i965/brw_draw.c @@ -194,8 +194,10 @@ brw_draw_range_elements(struct pipe_context *pipe, * XXX: do we need to go through state validation to achieve this? * Could just call upload code directly. */ - if (brw->curr.index_buffer != index_buffer) { + if (brw->curr.index_buffer != index_buffer || + brw->curr.index_size != index_size) { pipe_buffer_reference( &brw->curr.index_buffer, index_buffer ); + brw->curr.index_size = index_size; brw->state.dirty.mesa |= PIPE_NEW_INDEX_BUFFER; }