max_vector_size is used in the vec4 backend to pad out the uniform
components to match a size that is a multiple of a vec4. Double and dvec2
uniforms only require a single vec4 slot, not two.
Signed-off-by: Samuel Iglesias Gonsálvez <siglesias@igalia.com>
Signed-off-by: Iago Toral Quiroga <itoral@igalia.com>
Reviewed-by: Timothy Arceri <timothy.arceri@collabora.com>
Reviewed-by: Matt Turner <mattst88@gmail.com>
unsigned max_vector_size = 4;
if (storage->type->base_type == GLSL_TYPE_DOUBLE) {
vector_size *= 2;
- max_vector_size *= 2;
+ if (vector_size > 4)
+ max_vector_size = 8;
}
for (unsigned s = 0; s < vector_count; s++) {