glsl: Add ir_variable::is_in_uniform_block predicate

The way a variable is tested for this property is about to change, and
this makes the code easier to modify.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Carl Worth <cworth@cworth.org>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
Ian Romanick
2012-12-14 12:00:14 -08:00
parent 17e6f19044
commit 13be1f4a10
8 changed files with 16 additions and 8 deletions
+1 -1
View File
@@ -78,7 +78,7 @@ lower_ubo_reference_visitor::handle_rvalue(ir_rvalue **rvalue)
return;
ir_variable *var = deref->variable_referenced();
if (!var || var->uniform_block == -1)
if (!var || !var->is_in_uniform_block())
return;
mem_ctx = ralloc_parent(*rvalue);