main: Fix block index when mixing UBO and SSBO blocks
authorIago Toral Quiroga <itoral@igalia.com>
Tue, 29 Sep 2015 11:34:20 +0000 (13:34 +0200)
committerIago Toral Quiroga <itoral@igalia.com>
Thu, 1 Oct 2015 07:25:30 +0000 (09:25 +0200)
commit74553240301c60e3520fb55e09391993dac28f5d
treeb91ccec67b2c36f6b46ab0442204155d3ac849f3
parentca2e16d26ec46e604c76ab72d3ec14a7a8643cc8
main: Fix block index when mixing UBO and SSBO blocks

Since we store both in UniformBlocks, we can't just compute the index by
subtracting the array address start, we need to count the number of
buffers of the approriate type.

v2:
  - Just fall back to calc_resource_index (Tapani)

Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
src/mesa/main/shader_query.cpp