Graphics/FrameGraph: Fix depth stencil input not being taken into account for graph dependency

This commit is contained in:
Jérôme Leclercq 2021-07-17 21:10:10 +02:00
parent 1ee2122b3d
commit 52ec5d88f0
1 changed files with 14 additions and 0 deletions

View File

@ -900,6 +900,20 @@ namespace Nz
}
}
}
if (std::size_t dsInput = framePass.GetDepthStencilInput(); dsInput != FramePass::InvalidAttachmentId)
{
auto it = m_pending.attachmentWriteList.find(dsInput);
if (it != m_pending.attachmentWriteList.end())
{
const PassList& dependencyPassList = it->second;
for (std::size_t dependencyPass : dependencyPassList)
{
if (dependencyPass != passIndex)
TraverseGraph(dependencyPass);
}
}
}
}
void FrameGraph::RemoveDuplicatePasses()