diff options
author | Eric Anholt <[email protected]> | 2019-04-08 21:39:08 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2019-04-10 11:45:30 -0700 |
commit | 0204fb77e0133f9e365bd9d7749984b3421bbed5 (patch) | |
tree | 029656a0878681e0b7ff85e49dc4b8cd98ce4257 /src/gallium/drivers/vc4/vc4_program.c | |
parent | 7347d09d6ab822ba2430c41a40312393580bd422 (diff) |
vc4: Split UBO0 and UBO1 address uniform handling.
I'm going to extend how UBO0 works in a moment.
Diffstat (limited to 'src/gallium/drivers/vc4/vc4_program.c')
-rw-r--r-- | src/gallium/drivers/vc4/vc4_program.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gallium/drivers/vc4/vc4_program.c b/src/gallium/drivers/vc4/vc4_program.c index 135d4bc7198..4c284b6cd7c 100644 --- a/src/gallium/drivers/vc4/vc4_program.c +++ b/src/gallium/drivers/vc4/vc4_program.c @@ -135,7 +135,7 @@ indirect_uniform_load(struct vc4_compile *c, nir_intrinsic_instr *intr) qir_ADD_dest(c, qir_reg(QFILE_TEX_S_DIRECT, 0), indirect_offset, - qir_uniform(c, QUNIFORM_UBO_ADDR, 0)); + qir_uniform(c, QUNIFORM_UBO0_ADDR, 0)); c->num_texture_samples++; @@ -147,7 +147,7 @@ indirect_uniform_load(struct vc4_compile *c, nir_intrinsic_instr *intr) static struct qreg vc4_ubo_load(struct vc4_compile *c, nir_intrinsic_instr *intr) { - unsigned buffer_index = nir_src_as_uint(intr->src[0]); + int buffer_index = nir_src_as_uint(intr->src[0]); assert(buffer_index == 1); assert(c->stage == QSTAGE_FRAG); @@ -160,7 +160,7 @@ vc4_ubo_load(struct vc4_compile *c, nir_intrinsic_instr *intr) qir_ADD_dest(c, qir_reg(QFILE_TEX_S_DIRECT, 0), offset, - qir_uniform(c, QUNIFORM_UBO_ADDR, buffer_index)); + qir_uniform(c, QUNIFORM_UBO1_ADDR, 0)); c->num_texture_samples++; |