From: Marek Olšák Date: Fri, 26 Apr 2013 12:45:06 +0000 (+0200) Subject: st/mesa: remove dependency on _NEW_BUFFER_OBJECT for vertex arrays X-Git-Tag: mesa-9.2.1~1224 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F54%2F6554%2F1;p=platform%2Fupstream%2Fmesa.git st/mesa: remove dependency on _NEW_BUFFER_OBJECT for vertex arrays _NEW_BUFFER_OBJECT means glBufferData was called. We can just set our own flag in BufferData. Reviewed-by: Brian Paul --- diff --git a/src/mesa/state_tracker/st_atom_array.c b/src/mesa/state_tracker/st_atom_array.c index 2437245..87a0a17 100644 --- a/src/mesa/state_tracker/st_atom_array.c +++ b/src/mesa/state_tracker/st_atom_array.c @@ -589,7 +589,7 @@ static void update_array(struct st_context *st) const struct st_tracked_state st_update_array = { "st_update_array", /* name */ { /* dirty */ - _NEW_BUFFER_OBJECT, /* mesa */ + 0, /* mesa */ ST_NEW_VERTEX_ARRAYS | ST_NEW_VERTEX_PROGRAM, /* st */ }, update_array /* update */ diff --git a/src/mesa/state_tracker/st_cb_bufferobjects.c b/src/mesa/state_tracker/st_cb_bufferobjects.c index c868d5e..2e5e253 100644 --- a/src/mesa/state_tracker/st_cb_bufferobjects.c +++ b/src/mesa/state_tracker/st_cb_bufferobjects.c @@ -264,8 +264,8 @@ st_bufferobj_data(struct gl_context *ctx, pipe_buffer_write(pipe, st_obj->buffer, 0, size, data); } - /* BufferData may change a uniform buffer, need to update it */ - st->dirty.st |= ST_NEW_UNIFORM_BUFFER; + /* BufferData may change an array or uniform buffer, need to update it */ + st->dirty.st |= ST_NEW_VERTEX_ARRAYS | ST_NEW_UNIFORM_BUFFER; return GL_TRUE; }