summaryrefslogtreecommitdiff
path: root/src/video_core/engines
diff options
context:
space:
mode:
authorGravatar ReinUsesLisp2020-02-05 12:18:33 -0300
committerGravatar ReinUsesLisp2020-02-05 12:19:09 -0300
commitbf9a822b87ff362805ffefb8f76eea3c46f606a1 (patch)
treee88bfba5992eaf3a2eb6c5f9d751f7aba7999792 /src/video_core/engines
parentMerge pull request #3377 from ReinUsesLisp/bitset-vk (diff)
downloadyuzu-bf9a822b87ff362805ffefb8f76eea3c46f606a1.tar.gz
yuzu-bf9a822b87ff362805ffefb8f76eea3c46f606a1.tar.xz
yuzu-bf9a822b87ff362805ffefb8f76eea3c46f606a1.zip
shader/decode: Fix constant buffer offsets
Some instances were using cbuf34.offset instead of cbuf34.GetOffset(). This returned the an invalid offset. Address those instances and rename offset to "shifted_offset" to avoid future bugs.
Diffstat (limited to 'src/video_core/engines')
-rw-r--r--src/video_core/engines/shader_bytecode.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/video_core/engines/shader_bytecode.h b/src/video_core/engines/shader_bytecode.h
index 81b6d9eff..955f981bd 100644
--- a/src/video_core/engines/shader_bytecode.h
+++ b/src/video_core/engines/shader_bytecode.h
@@ -1657,11 +1657,11 @@ union Instruction {
1657 } xmad; 1657 } xmad;
1658 1658
1659 union { 1659 union {
1660 BitField<20, 14, u64> offset; 1660 BitField<20, 14, u64> shifted_offset;
1661 BitField<34, 5, u64> index; 1661 BitField<34, 5, u64> index;
1662 1662
1663 u64 GetOffset() const { 1663 u64 GetOffset() const {
1664 return offset * 4; 1664 return shifted_offset * 4;
1665 } 1665 }
1666 } cbuf34; 1666 } cbuf34;
1667 1667