Vulkan DebugPixel support for multiview debugging

Output "ViewIndex" into the pixel shader hits array
Select the pixel shader input which matches the viewIndex to the passed in view
Ignore the view parameter if set to ~0U (rd.ReplayController.NoPreference)
Ignore the view parameter if any subpass has empty multiviews
This commit is contained in:
Jake Turner
2024-01-17 10:46:32 +00:00
parent b36b7cf6b8
commit 3cb8998841
8 changed files with 145 additions and 19 deletions
+3 -1
View File
@@ -611,7 +611,7 @@ private:
}
};
PixelHistoryView::PixelHistoryView(ICaptureContext &ctx, ResourceId id, QPoint point,
PixelHistoryView::PixelHistoryView(ICaptureContext &ctx, ResourceId id, QPoint point, uint32_t view,
const TextureDisplay &display, QWidget *parent)
: QFrame(parent), ui(new Ui::PixelHistoryView), m_Ctx(ctx)
{
@@ -622,6 +622,7 @@ PixelHistoryView::PixelHistoryView(ICaptureContext &ctx, ResourceId id, QPoint p
m_Pixel = point;
m_Display = display;
m_ID = id;
m_View = view;
updateWindowTitle();
@@ -770,6 +771,7 @@ void PixelHistoryView::startDebug(EventTag tag)
DebugPixelInputs inputs;
inputs.sample = m_Display.subresource.sample;
inputs.primitive = tag.primitive;
inputs.view = m_View;
trace = r->DebugPixel((uint32_t)m_Pixel.x(), (uint32_t)m_Pixel.y(), inputs);
if(trace->debugger == NULL)