From 5cfa3b410818286022b33b87cb4e34b8c9b82cfd Mon Sep 17 00:00:00 2001 From: "Erik W. Gren" Date: Fri, 27 Dec 2024 21:00:20 +0100 Subject: [PATCH] vulkan: shift viewport y by height --- blade-graphics/src/vulkan/command.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blade-graphics/src/vulkan/command.rs b/blade-graphics/src/vulkan/command.rs index 1d1753f..a31a7ab 100644 --- a/blade-graphics/src/vulkan/command.rs +++ b/blade-graphics/src/vulkan/command.rs @@ -857,7 +857,7 @@ impl crate::Viewport { fn to_vk(&self) -> vk::Viewport { vk::Viewport { x: self.x, - y: self.y, + y: self.y + self.h, // shift since always flipped y and vulkan >= 1.1 width: self.w, height: -self.h, // flip Y min_depth: self.depth.start,