vk/vec4: Use the right constant for offset into a UBO
authorKristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>
Tue, 25 Aug 2015 23:14:59 +0000 (16:14 -0700)
committerKristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>
Tue, 25 Aug 2015 23:14:59 +0000 (16:14 -0700)
We were using constant 0, which is the set.

Signed-off-by: Kristian Høgsberg Kristensen <kristian.h.kristensen@intel.com>
src/mesa/drivers/dri/i965/brw_vec4_nir.cpp

index ee353b22330d5f8a82299d89ccf23421f77ab9ba..fd3d556bfb6a68b0157e4b6c660e25f6ad9a09ad 100644 (file)
@@ -644,7 +644,7 @@ vec4_visitor::nir_emit_intrinsic(nir_intrinsic_instr *instr)
                                shader_prog->NumUniformBlocks - 1);
       }
 
-      unsigned const_offset = instr->const_index[0];
+      unsigned const_offset = instr->const_index[1];
       src_reg offset;
 
       if (!has_indirect)  {