summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2011-11-06 22:51:53 -0800
committerKenneth Graunke <[email protected]>2011-11-10 22:51:19 -0800
commit29fc0d8c8af486d79298650b7e07dee16b3ec4ba (patch)
tree16d64ed58caf7740dd0796e1147d40ab6a953963 /src/mesa/drivers/dri
parent32dfa6e5ef3d1fb703ec34942c55408be22e7ec3 (diff)
i965: Upload SAMPLER_STATE pointers for the VS on Ivybridge.
See similar code in gen7_wm_state.c. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri')
-rw-r--r--src/mesa/drivers/dri/i965/gen7_vs_state.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/gen7_vs_state.c b/src/mesa/drivers/dri/i965/gen7_vs_state.c
index e3234b593b0..558933c2c4c 100644
--- a/src/mesa/drivers/dri/i965/gen7_vs_state.c
+++ b/src/mesa/drivers/dri/i965/gen7_vs_state.c
@@ -40,6 +40,12 @@ upload_vs_state(struct brw_context *brw)
OUT_BATCH(brw->bind.bo_offset);
ADVANCE_BATCH();
+ /* CACHE_NEW_SAMPLER */
+ BEGIN_BATCH(2);
+ OUT_BATCH(_3DSTATE_SAMPLER_STATE_POINTERS_VS << 16 | (2 - 2));
+ OUT_BATCH(brw->sampler.offset);
+ ADVANCE_BATCH();
+
if (brw->vs.push_const_size == 0) {
/* Disable the push constant buffers. */
BEGIN_BATCH(7);
@@ -104,7 +110,7 @@ const struct brw_tracked_state gen7_vs_state = {
BRW_NEW_VERTEX_PROGRAM |
BRW_NEW_VS_BINDING_TABLE |
BRW_NEW_BATCH),
- .cache = CACHE_NEW_VS_PROG
+ .cache = CACHE_NEW_VS_PROG | CACHE_NEW_SAMPLER
},
.emit = upload_vs_state,
};