mirror of
https://github.com/yuzu-emu/yuzu.git
synced 2024-11-15 09:30:05 +00:00
gl_shader_decompiler: Fix TEXS mask and dest.
This commit is contained in:
parent
ce46fb27ca
commit
fd715e54a1
@ -766,13 +766,16 @@ private:
|
||||
// goes into gpr28+0 and gpr28+1
|
||||
size_t texs_offset{};
|
||||
|
||||
size_t src_elem{};
|
||||
for (const auto& dest : {instr.gpr0.Value(), instr.gpr28.Value()}) {
|
||||
size_t dest_elem{};
|
||||
for (unsigned elem = 0; elem < 2; ++elem) {
|
||||
if (!instr.texs.IsComponentEnabled(elem)) {
|
||||
if (!instr.texs.IsComponentEnabled(src_elem++)) {
|
||||
// Skip disabled components
|
||||
continue;
|
||||
}
|
||||
regs.SetRegisterToFloat(dest, elem + texs_offset, texture, 1, 4, false, elem);
|
||||
regs.SetRegisterToFloat(dest, elem + texs_offset, texture, 1, 4, false,
|
||||
dest_elem++);
|
||||
}
|
||||
|
||||
if (!instr.texs.HasTwoDestinations()) {
|
||||
|
Loading…
Reference in New Issue
Block a user