mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-07-08 16:50:44 +00:00
Make sure swapchain images are given TRANSFER_SOURCE usage
This commit is contained in:
@@ -307,7 +307,12 @@ VkResult WrappedVulkan::vkCreateSwapchainKHR(
|
||||
const VkSwapchainCreateInfoKHR* pCreateInfo,
|
||||
VkSwapchainKHR* pSwapChain)
|
||||
{
|
||||
VkResult ret = ObjDisp(device)->CreateSwapchainKHR(Unwrap(device), pCreateInfo, pSwapChain);
|
||||
VkSwapchainCreateInfoKHR createInfo = *pCreateInfo;
|
||||
|
||||
// make sure we can readback to get the screenshot
|
||||
createInfo.imageUsageFlags |= VK_IMAGE_USAGE_TRANSFER_SOURCE_BIT;
|
||||
|
||||
VkResult ret = ObjDisp(device)->CreateSwapchainKHR(Unwrap(device), &createInfo, pSwapChain);
|
||||
|
||||
if(ret == VK_SUCCESS)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user