From 33182c555fa29de5bd70716fe0910b9a2f2187ba Mon Sep 17 00:00:00 2001 From: Emma Anholt Date: Mon, 2 Aug 2021 10:47:54 -0700 Subject: [PATCH] nir/nir_lower_uniforms_to_ubo: Set the explicit stride of the UBO 0 uniform. Normal UBOs have explicit strides on them, make our lowered one behave the same. Reviewed-by: Adam Jackson Acked-by: Mike Blumenkrantz Part-of: --- src/compiler/nir/nir_lower_uniforms_to_ubo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/compiler/nir/nir_lower_uniforms_to_ubo.c b/src/compiler/nir/nir_lower_uniforms_to_ubo.c index b1116e07a9d..12f835c3f0e 100644 --- a/src/compiler/nir/nir_lower_uniforms_to_ubo.c +++ b/src/compiler/nir/nir_lower_uniforms_to_ubo.c @@ -147,7 +147,7 @@ nir_lower_uniforms_to_ubo(nir_shader *shader, bool dword_packed, bool load_vec4) if (shader->num_uniforms > 0) { const struct glsl_type *type = glsl_array_type(glsl_vec4_type(), - shader->num_uniforms, 0); + shader->num_uniforms, 16); nir_variable *ubo = nir_variable_create(shader, nir_var_mem_ubo, type, "uniform_0"); ubo->data.binding = 0;