mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-05-14 11:21:40 +00:00
D3D12: Wait for GPU on device destruction
This commit is contained in:
parent
f9c39d021e
commit
afdcf7d828
@ -101,6 +101,10 @@ namespace d3d12 {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Device::~Device() {
|
Device::~Device() {
|
||||||
|
// Wait for all in-flight commands to finish exeuting
|
||||||
|
const uint64_t currentSerial = GetSerial();
|
||||||
|
NextSerial();
|
||||||
|
WaitForSerial(currentSerial);
|
||||||
}
|
}
|
||||||
|
|
||||||
ComPtr<ID3D12Device> Device::GetD3D12Device() {
|
ComPtr<ID3D12Device> Device::GetD3D12Device() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user