As SetPrimitiveTopology will call SignalStateChange so no need to call it again.

This commit is contained in:
sunshineinabox 2024-09-22 17:25:34 -07:00
parent 9fbfcae162
commit 92f8d211c6

View file

@ -658,7 +658,7 @@ namespace Ryujinx.Graphics.Vulkan
bool oldStencilTestEnable; bool oldStencilTestEnable;
bool oldDepthTestEnable; bool oldDepthTestEnable;
bool oldDepthWriteEnable; bool oldDepthWriteEnable;
Silk.NET.Vulkan.PrimitiveTopology oldTopology; PrimitiveTopology oldTopology;
Array16<Silk.NET.Vulkan.Viewport> oldViewports = DynamicState.Viewports; Array16<Silk.NET.Vulkan.Viewport> oldViewports = DynamicState.Viewports;
uint oldViewportsCount; uint oldViewportsCount;
@ -668,7 +668,7 @@ namespace Ryujinx.Graphics.Vulkan
oldStencilTestEnable = DynamicState.StencilTestEnable; oldStencilTestEnable = DynamicState.StencilTestEnable;
oldDepthTestEnable = DynamicState.DepthTestEnable; oldDepthTestEnable = DynamicState.DepthTestEnable;
oldDepthWriteEnable = DynamicState.DepthWriteEnable; oldDepthWriteEnable = DynamicState.DepthWriteEnable;
oldTopology = DynamicState.Topology; oldTopology = _topology;
oldViewportsCount = DynamicState.ViewportsCount; oldViewportsCount = DynamicState.ViewportsCount;
} }
else else
@ -705,8 +705,6 @@ namespace Ryujinx.Graphics.Vulkan
srcRegion, srcRegion,
dstRegion); dstRegion);
SetPrimitiveTopology(oldTopology);
if (_supportExtDynamic) if (_supportExtDynamic)
{ {
DynamicState.SetCullMode(oldCullMode); DynamicState.SetCullMode(oldCullMode);
@ -722,9 +720,9 @@ namespace Ryujinx.Graphics.Vulkan
_newState.ViewportsCount = oldViewportsCount; _newState.ViewportsCount = oldViewportsCount;
} }
DynamicState.SetViewports(ref oldViewports, oldViewportsCount); SetPrimitiveTopology(oldTopology);
SignalStateChange(); DynamicState.SetViewports(ref oldViewports, oldViewportsCount);
} }
} }