mirror of
https://github.com/doitsujin/dxvk.git
synced 2025-03-15 16:29:16 +01:00
[dxvk] Add debug label for render target clears
This commit is contained in:
parent
1b9ea8c6e3
commit
ca2afb0b8b
@ -1798,6 +1798,12 @@ namespace dxvk {
|
|||||||
|
|
||||||
flushPendingAccesses(*imageView, DxvkAccess::Write);
|
flushPendingAccesses(*imageView, DxvkAccess::Write);
|
||||||
|
|
||||||
|
if (unlikely(m_features.test(DxvkContextFeature::DebugUtils))) {
|
||||||
|
const char* imageName = imageView->image()->info().debugName;
|
||||||
|
m_cmd->cmdBeginDebugUtilsLabel(DxvkCmdBuffer::ExecBuffer,
|
||||||
|
vk::makeLabel(0xe6f0dc, str::format("Clear render target (", imageName ? imageName : "unknown", ")").c_str()));
|
||||||
|
}
|
||||||
|
|
||||||
// Set up a temporary render pass to execute the clear
|
// Set up a temporary render pass to execute the clear
|
||||||
VkImageLayout imageLayout = ((clearAspects | discardAspects) & VK_IMAGE_ASPECT_COLOR_BIT)
|
VkImageLayout imageLayout = ((clearAspects | discardAspects) & VK_IMAGE_ASPECT_COLOR_BIT)
|
||||||
? imageView->pickLayout(VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL)
|
? imageView->pickLayout(VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL)
|
||||||
@ -1883,6 +1889,9 @@ namespace dxvk {
|
|||||||
imageView->image()->info().stages,
|
imageView->image()->info().stages,
|
||||||
imageView->image()->info().access);
|
imageView->image()->info().access);
|
||||||
|
|
||||||
|
if (unlikely(m_features.test(DxvkContextFeature::DebugUtils)))
|
||||||
|
m_cmd->cmdEndDebugUtilsLabel(DxvkCmdBuffer::ExecBuffer);
|
||||||
|
|
||||||
m_cmd->track(imageView->image(), DxvkAccess::Write);
|
m_cmd->track(imageView->image(), DxvkAccess::Write);
|
||||||
} else {
|
} else {
|
||||||
// Perform the operation when starting the next render pass
|
// Perform the operation when starting the next render pass
|
||||||
|
Loading…
x
Reference in New Issue
Block a user