diff options
author | Rob Clark <[email protected]> | 2013-04-24 17:45:00 -0400 |
---|---|---|
committer | Rob Clark <[email protected]> | 2013-04-24 21:09:46 -0400 |
commit | 49a7624973870289a10b17778709c4c2a676fb12 (patch) | |
tree | 4af201a91c6f90e4285fb01a728ec1fe3be43e52 /src/gallium/drivers/freedreno/freedreno_state.c | |
parent | 9495ee12c66798ac776f1a38dbb9c7416ba68c6b (diff) |
freedreno: fix bogus IMM const reg index
We were assigning incorrect const register for immediates, and
potentially writing immediate const to the wrong location. This fixes
an incorrect-rendering bug with xonotic.
Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno/freedreno_state.c')
-rw-r--r-- | src/gallium/drivers/freedreno/freedreno_state.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/drivers/freedreno/freedreno_state.c b/src/gallium/drivers/freedreno/freedreno_state.c index 070a0429a0c..064a2faf787 100644 --- a/src/gallium/drivers/freedreno/freedreno_state.c +++ b/src/gallium/drivers/freedreno/freedreno_state.c @@ -279,7 +279,7 @@ emit_constants(struct fd_ringbuffer *ring, uint32_t base, if (shader) { for (i = 0; i < shader->num_immediates; i++) { OUT_PKT3(ring, CP_SET_CONSTANT, 5); - OUT_RING(ring, base); + OUT_RING(ring, start_base + (4 * (shader->first_immediate + i))); OUT_RING(ring, shader->immediates[i].val[0]); OUT_RING(ring, shader->immediates[i].val[1]); OUT_RING(ring, shader->immediates[i].val[2]); |