glsl: support packing of arrays of arrays

Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
This commit is contained in:
Timothy Arceri 2015-02-27 22:43:39 +11:00
parent fda5f7bb2f
commit f00c5f85b8
1 changed files with 2 additions and 8 deletions

View File

@ -645,14 +645,8 @@ lower_packed_varyings_visitor::needs_lowering(ir_variable *var)
if (var->data.explicit_location)
return false;
const glsl_type *type = var->type;
if (this->gs_input_vertices != 0) {
assert(type->is_array());
type = type->element_type();
}
if (type->is_array())
type = type->fields.array;
if (type->vector_elements == 4 && !type->is_double())
if (var->type->without_array()->vector_elements == 4 &&
!var->type->is_double())
return false;
return true;
}