diff --git a/src/backend/d3d12/D3D12Backend.cpp b/src/backend/d3d12/D3D12Backend.cpp index 04e772d1e1..94a34b357a 100644 --- a/src/backend/d3d12/D3D12Backend.cpp +++ b/src/backend/d3d12/D3D12Backend.cpp @@ -101,6 +101,10 @@ namespace d3d12 { } Device::~Device() { + // Wait for all in-flight commands to finish exeuting + const uint64_t currentSerial = GetSerial(); + NextSerial(); + WaitForSerial(currentSerial); } ComPtr Device::GetD3D12Device() {