From 2a7bf4af351660d7f5419184fa8e0c7751b5dacc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Erik=20Dahlstr=C3=B6m?= Date: Tue, 23 Jan 2018 10:39:47 +0100 Subject: [PATCH] Use the WARP software fallback in release builds too. Fixes issue #10. --- glTF-Toolkit/src/DeviceResources.cpp | 7 ------- 1 file changed, 7 deletions(-) diff --git a/glTF-Toolkit/src/DeviceResources.cpp b/glTF-Toolkit/src/DeviceResources.cpp index 0e5ae15..9505dbe 100644 --- a/glTF-Toolkit/src/DeviceResources.cpp +++ b/glTF-Toolkit/src/DeviceResources.cpp @@ -105,12 +105,6 @@ void DeviceResources::CreateDeviceResources() context.GetAddressOf() // Returns the device immediate context. ); } -#if defined(NDEBUG) - else - { - throw std::exception("No Direct3D hardware device found"); - } -#else if (FAILED(hr)) { // If the initialization fails, fall back to the WARP device. @@ -134,7 +128,6 @@ void DeviceResources::CreateDeviceResources() OutputDebugStringA("Direct3D Adapter - WARP\n"); } } -#endif ThrowIfFailed(hr);