D3D12: move fence signaling out of d3d12_gfx_sync. (#15179)

This commit is contained in:
aliaspider 2023-04-10 15:37:36 +01:00 committed by GitHub
parent e8ec3031a8
commit a79dc19b6c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -96,7 +96,6 @@ static gfx_ctx_driver_t d3d12_fake_context;
static void d3d12_gfx_sync(d3d12_video_t* d3d12)
{
D3D12SignalCommandQueue(d3d12->queue.handle, d3d12->queue.fence, ++d3d12->queue.fenceValue);
if (D3D12GetCompletedValue(d3d12->queue.fence) < d3d12->queue.fenceValue)
{
D3D12SetEventOnCompletion(
@ -2901,6 +2900,8 @@ static bool d3d12_gfx_frame(
D3D12ExecuteGraphicsCommandLists(d3d12->queue.handle, 1,
&d3d12->queue.cmd);
D3D12SignalCommandQueue(d3d12->queue.handle, d3d12->queue.fence, ++d3d12->queue.fenceValue);
DXGIPresent(d3d12->chain.handle, d3d12->chain.swap_interval, present_flags);