Fix #130161: Vulkan: Grid overlay artifact when copying to swap chain
When copying the window to the swap chain the image needs to be copied upside down to match Vulkan/OpenGL image coordinate differences. There was an of by 1 error when copying resulting in minor drawing glitch which was noticeable when looking at the viewport grid. Pull Request: https://projects.blender.org/blender/blender/pulls/130328
This commit is contained in:
@@ -319,7 +319,7 @@ void VKContext::swap_buffers_pre_handler(const GHOST_VulkanSwapChainData &swap_c
|
||||
blit_image.filter = VK_FILTER_NEAREST;
|
||||
|
||||
VkImageBlit ®ion = blit_image.region;
|
||||
region.srcOffsets[0] = {0, color_attachment->height_get() - 1, 0};
|
||||
region.srcOffsets[0] = {0, color_attachment->height_get(), 0};
|
||||
region.srcOffsets[1] = {color_attachment->width_get(), 0, 1};
|
||||
region.srcSubresource.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT;
|
||||
region.srcSubresource.mipLevel = 0;
|
||||
|
||||
Reference in New Issue
Block a user