From 287b1e1abc98ef3f01d8530e0b428b58d8e77e96 Mon Sep 17 00:00:00 2001 From: Connor McLaughlin Date: Fri, 29 Oct 2021 13:59:58 +1000 Subject: [PATCH] D3D12HostDisplay: IDXGIDevice is not a parent of ID3D12Device --- src/frontend-common/d3d12_host_display.cpp | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/src/frontend-common/d3d12_host_display.cpp b/src/frontend-common/d3d12_host_display.cpp index 4ae92e687..ecf050904 100644 --- a/src/frontend-common/d3d12_host_display.cpp +++ b/src/frontend-common/d3d12_host_display.cpp @@ -241,18 +241,7 @@ bool D3D12HostDisplay::CreateRenderDevice(const WindowInfo& wi, std::string_view return false; } -#if 0 - // we need the specific factory for the device, otherwise MakeWindowAssociation() is flaky. - ComPtr dxgi_device; - if (FAILED(m_device.As(&dxgi_device)) || FAILED(dxgi_device->GetParent(IID_PPV_ARGS(dxgi_adapter.GetAddressOf()))) || - FAILED(dxgi_adapter->GetParent(IID_PPV_ARGS(m_dxgi_factory.GetAddressOf())))) - { - Log_WarningPrint("Failed to get parent adapter/device/factory"); - return false; - } -#else m_dxgi_factory = std::move(temp_dxgi_factory); -#endif m_allow_tearing_supported = false; ComPtr dxgi_factory5;