Skip to content

Commit

Permalink
VulkanDevice: Fix download inside render pass
Browse files Browse the repository at this point in the history
  • Loading branch information
stenzek committed Aug 11, 2024
1 parent 290c44f commit 5f80827
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/util/vulkan_texture.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1158,9 +1158,15 @@ void VulkanDownloadTexture::Flush()

// Need to execute command buffer.
if (dev.GetCurrentFenceCounter() == m_copy_fence_counter)
{
if (dev.InRenderPass())
dev.EndRenderPass();
dev.SubmitCommandBuffer(true);
}
else
{
dev.WaitForFenceCounter(m_copy_fence_counter);
}
}

void VulkanDownloadTexture::SetDebugName(std::string_view name)
Expand Down

0 comments on commit 5f80827

Please sign in to comment.