From 0cc841bc76eda21793f2a158b0ededad5a5ae3bf Mon Sep 17 00:00:00 2001 From: assiduous Date: Wed, 16 Sep 2020 16:11:56 -0700 Subject: Added GPU vendor and memory size detection (API 240071), closed https://github.com/DiligentGraphics/DiligentCore/issues/144. Fixed shader model selection in D3D12 backend --- Graphics/GraphicsEngineD3D11/src/RenderDeviceD3D11Impl.cpp | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) (limited to 'Graphics/GraphicsEngineD3D11') diff --git a/Graphics/GraphicsEngineD3D11/src/RenderDeviceD3D11Impl.cpp b/Graphics/GraphicsEngineD3D11/src/RenderDeviceD3D11Impl.cpp index 420b2035..338ea5a9 100644 --- a/Graphics/GraphicsEngineD3D11/src/RenderDeviceD3D11Impl.cpp +++ b/Graphics/GraphicsEngineD3D11/src/RenderDeviceD3D11Impl.cpp @@ -130,17 +130,7 @@ RenderDeviceD3D11Impl::RenderDeviceD3D11Impl(IReferenceCounters* pRefCo if (auto pDXGIAdapter1 = DXGIAdapterFromD3D11Device(pd3d11Device)) { - DXGI_ADAPTER_DESC1 AdapterDesc = {}; - - auto hr = pDXGIAdapter1->GetDesc1(&AdapterDesc); - if (SUCCEEDED(hr)) - { - m_DeviceCaps.AdaterType = (AdapterDesc.Flags & DXGI_ADAPTER_FLAG_SOFTWARE) ? ADAPTER_TYPE_SOFTWARE : ADAPTER_TYPE_HARDWARE; - } - else - { - LOG_ERROR_MESSAGE("Failed to get DXGIDevice adapter desc. Adapter type will be unknown."); - } + ReadAdapterInfo(pDXGIAdapter1); } #define UNSUPPORTED_FEATURE(Feature, Name) \ -- cgit v1.2.3