mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-08-04 13:50:59 +00:00
Fix Vulkan Wireframe overlay fallback when fillModeNonSolid is false
Change the RenderState properties after calling PatchLineStripIndexBuffer() Mark the draw as an Indexed action
This commit is contained in:
@@ -1268,7 +1268,6 @@ ResourceId VulkanReplay::RenderOverlay(ResourceId texid, FloatVector clearCol, D
|
||||
|
||||
if(ia)
|
||||
ia->topology = VK_PRIMITIVE_TOPOLOGY_LINE_STRIP;
|
||||
state.primitiveTopology = VK_PRIMITIVE_TOPOLOGY_LINE_STRIP;
|
||||
|
||||
// thankfully, primitive restart is always supported! This makes the index buffer a bit
|
||||
// more
|
||||
@@ -1276,10 +1275,12 @@ ResourceId VulkanReplay::RenderOverlay(ResourceId texid, FloatVector clearCol, D
|
||||
// three lines, instead we have a single restart index after each triangle.
|
||||
if(ia)
|
||||
ia->primitiveRestartEnable = true;
|
||||
state.primRestartEnable = true;
|
||||
|
||||
GetDebugManager()->PatchLineStripIndexBuffer(mainDraw, patchedIB, patchedIndexCount);
|
||||
|
||||
state.primitiveTopology = VK_PRIMITIVE_TOPOLOGY_LINE_STRIP;
|
||||
state.primRestartEnable = true;
|
||||
|
||||
if(m_pDriver->ShaderObject())
|
||||
state.dynamicStates[VkDynamicLineWidth] = true;
|
||||
}
|
||||
@@ -1433,6 +1434,7 @@ ResourceId VulkanReplay::RenderOverlay(ResourceId texid, FloatVector clearCol, D
|
||||
action.numIndices = patchedIndexCount;
|
||||
action.baseVertex = 0;
|
||||
action.indexOffset = 0;
|
||||
action.flags |= ActionFlags::Indexed;
|
||||
m_pDriver->ReplayDraw(cmd, action);
|
||||
state.EndRenderPass(cmd);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user