This commit is contained in:
Branimir Karadžić
2016-02-29 11:43:09 -08:00
parent c691521563
commit e8a0e69097
4 changed files with 13 additions and 7 deletions

View File

@@ -791,13 +791,16 @@ namespace bgfx { namespace d3d11
}
#endif // USE_D3D11_DYNAMIC_LIB
HRESULT hr = S_OK;
IDXGIFactory* factory = NULL;
HRESULT hr;
IDXGIFactory* factory;
#if BX_PLATFORM_WINRT
// WinRT requires the IDXGIFactory2 interface, which isn't supported on older platforms
hr = CreateDXGIFactory1(__uuidof(IDXGIFactory2), (void**)&factory);
#elif BX_PLATFORM_WINDOWS
hr = CreateDXGIFactory(IID_IDXGIFactory, (void**)&factory);
#else
hr = S_OK;
factory = NULL;
#endif // BX_PLATFORM_*
BX_WARN(SUCCEEDED(hr), "Unable to create DXGI factory.");
if (FAILED(hr) )