summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965/brw_wm_state.c
diff options
context:
space:
mode:
authorKenneth Graunke <kenneth@whitecape.org>2012-08-21 23:54:19 -0700
committerKenneth Graunke <kenneth@whitecape.org>2013-08-19 13:16:59 -0700
commitdecc708c7c3ab53922cf3ac94cd74231196fd0cb (patch)
treea3592f10a9cdde5c8426800ff14634bc400b6032 /src/mesa/drivers/dri/i965/brw_wm_state.c
parent9525bcf5f799ffdf6db4cfa41da0daee142e6d3a (diff)
downloadexternal_mesa3d-decc708c7c3ab53922cf3ac94cd74231196fd0cb.zip
external_mesa3d-decc708c7c3ab53922cf3ac94cd74231196fd0cb.tar.gz
external_mesa3d-decc708c7c3ab53922cf3ac94cd74231196fd0cb.tar.bz2
i965: Upload separate per-stage sampler state tables.
Also upload separate sampler default/texture border color entries. At the moment, this is completely idiotic: both tables contain exactly the same contents, so we're simply wasting batch space and CPU time. However, soon we'll only upload data for textures actually /used/ in a particular stage, which will usually make the VS table empty and very likely eliminate all redundancy. This is just a stepping stone. Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Paul Berry <stereotype441@gmail.com>
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_wm_state.c')
-rw-r--r--src/mesa/drivers/dri/i965/brw_wm_state.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_wm_state.c b/src/mesa/drivers/dri/i965/brw_wm_state.c
index 106d628..404fdad 100644
--- a/src/mesa/drivers/dri/i965/brw_wm_state.c
+++ b/src/mesa/drivers/dri/i965/brw_wm_state.c
@@ -150,7 +150,7 @@ brw_upload_wm_unit(struct brw_context *brw)
if (brw->wm.sampler_count) {
/* reloc */
wm->wm4.sampler_state_pointer = (brw->batch.bo->offset +
- brw->sampler.offset) >> 5;
+ brw->wm.sampler_offset) >> 5;
} else {
wm->wm4.sampler_state_pointer = 0;
}
@@ -229,9 +229,9 @@ brw_upload_wm_unit(struct brw_context *brw)
drm_intel_bo_emit_reloc(brw->batch.bo,
brw->wm.state_offset +
offsetof(struct brw_wm_unit_state, wm4),
- brw->batch.bo, (brw->sampler.offset |
- wm->wm4.stats_enable |
- (wm->wm4.sampler_count << 2)),
+ brw->batch.bo, (brw->wm.sampler_offset |
+ wm->wm4.stats_enable |
+ (wm->wm4.sampler_count << 2)),
I915_GEM_DOMAIN_INSTRUCTION, 0);
}