summaryrefslogtreecommitdiff
path: root/src/mesa/drivers/dri/i965/brw_vtbl.c
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2008-01-09 14:08:12 -0800
committerEric Anholt <eric@anholt.net>2008-01-09 14:41:53 -0800
commitdc1608ae9d90a490ce32aa005488e3591a6d8369 (patch)
treed4c1c87e3a4e3ebedd35f7cf3c1a03d5bcc7107a /src/mesa/drivers/dri/i965/brw_vtbl.c
parent5f86ae057a645c03dc1e0c51c2fb1b2628a50e0a (diff)
[965] Replace the always_update dirty flag with BRW_NEW_BATCH.
This allows us to avoid re-emitting some state when validate_state happens multiple times per batchbuffer. Even though we flush batch per primitive currently, that may still happen already if the primitive changed (this should probably be fixed as well).
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_vtbl.c')
-rw-r--r--src/mesa/drivers/dri/i965/brw_vtbl.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vtbl.c b/src/mesa/drivers/dri/i965/brw_vtbl.c
index 4575ff0321..277c8dca8b 100644
--- a/src/mesa/drivers/dri/i965/brw_vtbl.c
+++ b/src/mesa/drivers/dri/i965/brw_vtbl.c
@@ -75,6 +75,9 @@ static void brw_set_draw_region( struct intel_context *intel,
{
struct brw_context *brw = brw_context(&intel->ctx);
+ if (brw->state.depth_region != depth_region)
+ brw->state.dirty.brw |= BRW_NEW_DEPTH_BUFFER;
+
intel_region_release(&brw->state.draw_region);
intel_region_release(&brw->state.depth_region);
intel_region_reference(&brw->state.draw_region, draw_region);