glsl: Accept nonconstant array references in lower_ubo_reference
authorChris Forbes <chrisf@ijw.co.nz>
Fri, 16 May 2014 10:07:24 +0000 (22:07 +1200)
committerChris Forbes <chrisf@ijw.co.nz>
Sat, 26 Jul 2014 04:46:03 +0000 (16:46 +1200)
commitbe237a61297936227b2f4afc2ac28f60c3c76bbf
tree81883e71375d3e77935079314ea218d1b4cd28d7
parentc59802d3a147956d4f33586bb6221cd236987ee2
glsl: Accept nonconstant array references in lower_ubo_reference

Instead of falling back to just the block name (which we won't find),
look for the first element of the block array. We'll deal with the rest
in the backend by arranging for the blocks to be laid out contiguously.

V2: Squashed together patches 3, 5 of V1, plus a naming tweak.

Signed-off-by: Chris Forbes <chrisf@ijw.co.nz>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/glsl/lower_ubo_reference.cpp