D3D12 Add check for DXGI_ERROR_DEVICE_REMOVED real device removed
Bug: dawn:269 Change-Id: I9a078efde0f0def29c9abfcc06d9f3ef2323cb55 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/18560 Reviewed-by: Corentin Wallez <cwallez@chromium.org> Reviewed-by: Rafael Cintron <rafael.cintron@microsoft.com> Reviewed-by: Austin Eng <enga@chromium.org> Commit-Queue: Natasha Lee <natlee@microsoft.com>
This commit is contained in:
parent
373a3ff26e
commit
5b29904d76
|
@ -23,7 +23,12 @@ namespace dawn_native { namespace d3d12 {
|
|||
}
|
||||
|
||||
std::string message = std::string(context) + " failed with " + std::to_string(result);
|
||||
return DAWN_INTERNAL_ERROR(message);
|
||||
|
||||
if (result == DXGI_ERROR_DEVICE_REMOVED) {
|
||||
return DAWN_DEVICE_LOST_ERROR(message);
|
||||
} else {
|
||||
return DAWN_INTERNAL_ERROR(message);
|
||||
}
|
||||
}
|
||||
|
||||
MaybeError CheckOutOfMemoryHRESULT(HRESULT result, const char* context) {
|
||||
|
|
Loading…
Reference in New Issue