From 9698653055a7805b165b8cdf0aa0a40e9a5fbc0a Mon Sep 17 00:00:00 2001 From: Philip Rebohle Date: Fri, 11 Oct 2024 23:09:01 +0200 Subject: [PATCH] [dxvk] Use new barrier helper in initImage --- src/dxvk/dxvk_context.cpp | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) diff --git a/src/dxvk/dxvk_context.cpp b/src/dxvk/dxvk_context.cpp index aff9855b7..c03306bcf 100644 --- a/src/dxvk/dxvk_context.cpp +++ b/src/dxvk/dxvk_context.cpp @@ -1035,12 +1035,9 @@ namespace dxvk { const VkImageSubresourceRange& subresources, VkImageLayout initialLayout) { if (initialLayout == VK_IMAGE_LAYOUT_PREINITIALIZED) { - m_initBarriers.accessImage(image, subresources, - initialLayout, - VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT, 0, - image->info().layout, - image->info().stages, - image->info().access); + accessImage(DxvkCmdBuffer::InitBuffer, + *image, subresources, initialLayout, + VK_PIPELINE_STAGE_2_NONE, 0); m_cmd->trackResource(image); } else { @@ -1119,13 +1116,10 @@ namespace dxvk { } } - m_initBarriers.accessImage(image, subresources, - clearLayout, - VK_PIPELINE_STAGE_TRANSFER_BIT, - VK_ACCESS_TRANSFER_WRITE_BIT, - image->info().layout, - image->info().stages, - image->info().access); + accessImage(DxvkCmdBuffer::InitBuffer, + *image, subresources, clearLayout, + VK_PIPELINE_STAGE_2_TRANSFER_BIT, + VK_ACCESS_2_TRANSFER_WRITE_BIT); m_cmd->trackResource(image); }