tgsi_to_nir: fix 2-component system values like tess_level_inner_default
Reviewed-by: Connor Abbott <cwabbott0@gmail.com> Reviewed-by: Eric Anholt <eric@anholt.net>
This commit is contained in:
parent
3906fce88b
commit
09447ccc78
|
@ -659,7 +659,9 @@ ttn_src_for_file_and_index(struct ttn_compile *c, unsigned file, unsigned index,
|
|||
unreachable("bad system value");
|
||||
}
|
||||
|
||||
if (load->num_components == 3)
|
||||
if (load->num_components == 2)
|
||||
load = nir_swizzle(b, load, SWIZ(X, Y, Y, Y), 4);
|
||||
else if (load->num_components == 3)
|
||||
load = nir_swizzle(b, load, SWIZ(X, Y, Z, Z), 4);
|
||||
|
||||
src = nir_src_for_ssa(load);
|
||||
|
|
Loading…
Reference in New Issue