mirror of
https://github.com/doitsujin/dxvk.git
synced 2024-12-11 10:24:10 +01:00
[dxvk] Use new barrier helpers in resolveImageDs
This commit is contained in:
parent
7b436a63fb
commit
7b65ee00d9
@ -4041,9 +4041,8 @@ namespace dxvk {
|
|||||||
"\n src format: ", srcImage->info().format));
|
"\n src format: ", srcImage->info().format));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_execBarriers.isImageDirty(dstImage, dstSubresourceRange, DxvkAccess::Write)
|
flushPendingAccesses(*dstImage, dstSubresourceRange, DxvkAccess::Write);
|
||||||
|| m_execBarriers.isImageDirty(srcImage, srcSubresourceRange, DxvkAccess::Write))
|
flushPendingAccesses(*srcImage, srcSubresourceRange, DxvkAccess::Read);
|
||||||
m_execBarriers.recordCommands(m_cmd);
|
|
||||||
|
|
||||||
// Transition both images to usable layouts if necessary. For the source image we
|
// Transition both images to usable layouts if necessary. For the source image we
|
||||||
// can be fairly leniet since writable layouts are allowed for resolve attachments.
|
// can be fairly leniet since writable layouts are allowed for resolve attachments.
|
||||||
@ -4095,23 +4094,17 @@ namespace dxvk {
|
|||||||
m_cmd->cmdEndRendering();
|
m_cmd->cmdEndRendering();
|
||||||
|
|
||||||
// Add barriers for the resolve operation
|
// Add barriers for the resolve operation
|
||||||
m_execBarriers.accessImage(srcImage, srcSubresourceRange,
|
accessImage(DxvkCmdBuffer::ExecBuffer,
|
||||||
srcLayout,
|
*srcImage, srcSubresourceRange, srcLayout,
|
||||||
VK_PIPELINE_STAGE_EARLY_FRAGMENT_TESTS_BIT |
|
VK_PIPELINE_STAGE_2_EARLY_FRAGMENT_TESTS_BIT |
|
||||||
VK_PIPELINE_STAGE_LATE_FRAGMENT_TESTS_BIT,
|
VK_PIPELINE_STAGE_2_LATE_FRAGMENT_TESTS_BIT,
|
||||||
VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_READ_BIT,
|
VK_ACCESS_2_DEPTH_STENCIL_ATTACHMENT_READ_BIT);
|
||||||
srcImage->info().layout,
|
|
||||||
srcImage->info().stages,
|
|
||||||
srcImage->info().access);
|
|
||||||
|
|
||||||
m_execBarriers.accessImage(dstImage, dstSubresourceRange,
|
accessImage(DxvkCmdBuffer::ExecBuffer,
|
||||||
dstLayout,
|
*dstImage, dstSubresourceRange, dstLayout,
|
||||||
VK_PIPELINE_STAGE_EARLY_FRAGMENT_TESTS_BIT |
|
VK_PIPELINE_STAGE_2_EARLY_FRAGMENT_TESTS_BIT |
|
||||||
VK_PIPELINE_STAGE_LATE_FRAGMENT_TESTS_BIT,
|
VK_PIPELINE_STAGE_2_LATE_FRAGMENT_TESTS_BIT,
|
||||||
VK_ACCESS_DEPTH_STENCIL_ATTACHMENT_WRITE_BIT,
|
VK_ACCESS_2_DEPTH_STENCIL_ATTACHMENT_WRITE_BIT);
|
||||||
dstImage->info().layout,
|
|
||||||
dstImage->info().stages,
|
|
||||||
dstImage->info().access);
|
|
||||||
|
|
||||||
m_cmd->trackResource<DxvkAccess::Write>(dstImage);
|
m_cmd->trackResource<DxvkAccess::Write>(dstImage);
|
||||||
m_cmd->trackResource<DxvkAccess::Read>(srcImage);
|
m_cmd->trackResource<DxvkAccess::Read>(srcImage);
|
||||||
|
Loading…
Reference in New Issue
Block a user