mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-25 17:20:10 +01:00
gallium/ntt: Fix emitting UBO declarations.
Fixes: d70fff99c5 ("nir: Use a single list for all shader variables")
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8196>
This commit is contained in:
parent
e109f5ea0f
commit
ec0bab8ca9
1 changed files with 4 additions and 2 deletions
|
|
@ -259,8 +259,6 @@ ntt_setup_uniforms(struct ntt_compile *c)
|
|||
var->data.image.format,
|
||||
!var->data.read_only,
|
||||
false);
|
||||
} else if (var->data.mode == nir_var_mem_ubo) {
|
||||
ureg_DECL_constant2D(c->ureg, 0, 0, var->data.driver_location + 1);
|
||||
} else {
|
||||
unsigned size;
|
||||
if (packed) {
|
||||
|
|
@ -275,6 +273,10 @@ ntt_setup_uniforms(struct ntt_compile *c)
|
|||
}
|
||||
}
|
||||
|
||||
nir_foreach_variable_with_modes(var, c->s, nir_var_mem_ubo) {
|
||||
ureg_DECL_constant2D(c->ureg, 0, 0, var->data.driver_location + 1);
|
||||
}
|
||||
|
||||
for (int i = 0; i < PIPE_MAX_SAMPLERS; i++) {
|
||||
if (c->s->info.textures_used & (1 << i))
|
||||
ureg_DECL_sampler(c->ureg, i);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue