]> git.tdb.fi Git - libs/gl.git/commitdiff
Fix render area Y coordinate calculation
authorMikko Rasa <tdb@tdb.fi>
Sun, 12 Dec 2021 10:57:19 +0000 (12:57 +0200)
committerMikko Rasa <tdb@tdb.fi>
Sun, 12 Dec 2021 10:57:19 +0000 (12:57 +0200)
source/backends/vulkan/commands_backend.cpp

index 8243b58fe1ba66849b10a2cf2d94538f5d4450a8..643710d5aefeb103d7e3380f5c9f50423ce4ed4f 100644 (file)
@@ -102,7 +102,7 @@ void VulkanCommands::begin_render_pass(bool clear, const ClearValue *clear_value
        if(viewport)
        {
                begin_info.renderArea.offset.x = viewport->left;
-               begin_info.renderArea.offset.y = viewport->bottom;
+               begin_info.renderArea.offset.y = framebuffer->get_height()-(viewport->bottom+viewport->height);
                begin_info.renderArea.extent.width = viewport->width;
                begin_info.renderArea.extent.height = viewport->height;
        }