summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2022-12-18 08:55:05 +0100
committerbunnei <bunneidev@gmail.com>2023-06-03 09:05:27 +0200
commit18527a8c42ddd97befd76d44413ff6b7652faf31 (patch)
tree18ce461b5a3334ceef6fb1d13c1b9dd91af73315 /src
parentcommon: error: Fix for Android. (diff)
downloadyuzu-18527a8c42ddd97befd76d44413ff6b7652faf31.tar
yuzu-18527a8c42ddd97befd76d44413ff6b7652faf31.tar.gz
yuzu-18527a8c42ddd97befd76d44413ff6b7652faf31.tar.bz2
yuzu-18527a8c42ddd97befd76d44413ff6b7652faf31.tar.lz
yuzu-18527a8c42ddd97befd76d44413ff6b7652faf31.tar.xz
yuzu-18527a8c42ddd97befd76d44413ff6b7652faf31.tar.zst
yuzu-18527a8c42ddd97befd76d44413ff6b7652faf31.zip
Diffstat (limited to 'src')
-rw-r--r--src/video_core/renderer_vulkan/vk_blit_screen.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/video_core/renderer_vulkan/vk_blit_screen.cpp b/src/video_core/renderer_vulkan/vk_blit_screen.cpp
index 1e0fdd3d9..df948292f 100644
--- a/src/video_core/renderer_vulkan/vk_blit_screen.cpp
+++ b/src/video_core/renderer_vulkan/vk_blit_screen.cpp
@@ -76,10 +76,18 @@ struct ScreenRectVertex {
constexpr std::array<f32, 4 * 4> MakeOrthographicMatrix(f32 width, f32 height) {
// clang-format off
+#ifdef ANDROID
+ // Android renders in portrait, so rotate the matrix.
+ return { 0.f, 2.f / width, 0.f, 0.f,
+ -2.f / height, 0.f, 0.f, 0.f,
+ 0.f, 0.f, 1.f, 0.f,
+ 1.f, -1.f, 0.f, 1.f};
+#else
return { 2.f / width, 0.f, 0.f, 0.f,
0.f, 2.f / height, 0.f, 0.f,
0.f, 0.f, 1.f, 0.f,
-1.f, -1.f, 0.f, 1.f};
+#endif // ANDROID
// clang-format on
}