summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMat M <mathew1800@gmail.com>2020-04-13 16:15:12 +0200
committerGitHub <noreply@github.com>2020-04-13 16:15:12 +0200
commitd37d89943123edc386cfec66773374772e661473 (patch)
tree83e82d5d6b9273028b93fe0a065fc401613700e5
parentMerge pull request #3633 from ReinUsesLisp/clean-texdec (diff)
parentgl_shader_decompiler: Implement merges with bitfieldInsert (diff)
downloadyuzu-d37d89943123edc386cfec66773374772e661473.tar
yuzu-d37d89943123edc386cfec66773374772e661473.tar.gz
yuzu-d37d89943123edc386cfec66773374772e661473.tar.bz2
yuzu-d37d89943123edc386cfec66773374772e661473.tar.lz
yuzu-d37d89943123edc386cfec66773374772e661473.tar.xz
yuzu-d37d89943123edc386cfec66773374772e661473.tar.zst
yuzu-d37d89943123edc386cfec66773374772e661473.zip
Diffstat (limited to '')
-rw-r--r--src/video_core/renderer_opengl/gl_shader_decompiler.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp
index 160ae4340..1f1f01313 100644
--- a/src/video_core/renderer_opengl/gl_shader_decompiler.cpp
+++ b/src/video_core/renderer_opengl/gl_shader_decompiler.cpp
@@ -1819,15 +1819,15 @@ private:
}
Expression HMergeH0(Operation operation) {
- std::string dest = VisitOperand(operation, 0).AsUint();
- std::string src = VisitOperand(operation, 1).AsUint();
- return {fmt::format("(({} & 0x0000FFFFU) | ({} & 0xFFFF0000U))", src, dest), Type::Uint};
+ const std::string dest = VisitOperand(operation, 0).AsUint();
+ const std::string src = VisitOperand(operation, 1).AsUint();
+ return {fmt::format("bitfieldInsert({}, {}, 0, 16)", dest, src), Type::Uint};
}
Expression HMergeH1(Operation operation) {
- std::string dest = VisitOperand(operation, 0).AsUint();
- std::string src = VisitOperand(operation, 1).AsUint();
- return {fmt::format("(({} & 0x0000FFFFU) | ({} & 0xFFFF0000U))", dest, src), Type::Uint};
+ const std::string dest = VisitOperand(operation, 0).AsUint();
+ const std::string src = VisitOperand(operation, 1).AsUint();
+ return {fmt::format("bitfieldInsert({}, {}, 16, 16)", dest, src), Type::Uint};
}
Expression HPack2(Operation operation) {