MediaFoundationDxgiCapabilities: GPU preference & Hybrid GPU systems

I added a section that enumerates DXGI adapters with the help IDXGIFactory6::EnumAdapterByGpuPreference – this is included into the produced output.

Unfortunately the method does not distinguish between dual GPU systems, such as with discrete GPU and additional CPU integrated Intel GPU…

DXGI Capabilities
 NOTE: Baseline capabilities are corresponding to DXGI 1.1
 Windowed Stereo: 0
 DXGI_FEATURE_PRESENT_ALLOW_TEARING: 1
 Adapters by Preference:
 DXGI_GPU_PREFERENCE_UNSPECIFIED: Radeon RX 570 Series (0.0x0000D18A), Intel(R) UHD Graphics 630 (0.0x8E94827B), Microsoft Basic Render Driver (0.0x0000D163)
 DXGI_GPU_PREFERENCE_MINIMUM_POWER: Intel(R) UHD Graphics 630 (0.0x8E94827B), Radeon RX 570 Series (0.0x0000D18A), Microsoft Basic Render Driver (0.0x0000D163)
 DXGI_GPU_PREFERENCE_HIGH_PERFORMANCE: Radeon RX 570 Series (0.0x0000D18A), Intel(R) UHD Graphics 630 (0.0x8E94827B), Microsoft Basic Render Driver (0.0x0000D163)
 Factory Interfaces: IDXGIObject, IDXGIFactory, IDXGIFactory1, IDXGIFactory2, IDXGIFactory3, IDXGIFactory4, IDXGIFactory5, IDXGIFactory6, IDXGIFactory7, IDXGIDisplayControl 

Adapters
 Radeon RX 570 Series
 Intel(R) UHD Graphics 630 

…and hybrid systems such as NVIDIA Optimus and AMD PowerXpress. Those from AMD seem to be discontinued and AMD is traditionally provides zero helpful feedback to developers (although NVIDIA is not any better).

However this time I might have spotted something interesting. On an NVIDIA hybrid system when an app is executed on iGPU, the output is this (expected):

DXGI Capabilities
 NOTE: Baseline capabilities are corresponding to DXGI 1.1
 Windowed Stereo: 0
 DXGI_FEATURE_PRESENT_ALLOW_TEARING: 1
 Adapters by Preference:
 DXGI_GPU_PREFERENCE_UNSPECIFIED: Intel(R) HD Graphics 520 (0.0x00010765), NVIDIA GeForce 940MX (0.0x00010A9D), Microsoft Basic Render Driver (0.0x00010A66)
 DXGI_GPU_PREFERENCE_MINIMUM_POWER: Intel(R) HD Graphics 520 (0.0x00010765), NVIDIA GeForce 940MX (0.0x00010A9D), Microsoft Basic Render Driver (0.0x00010A66)
 DXGI_GPU_PREFERENCE_HIGH_PERFORMANCE: NVIDIA GeForce 940MX (0.0x00010A9D), Intel(R) HD Graphics 520 (0.0x00010765), Microsoft Basic Render Driver (0.0x00010A66)
 Factory Interfaces: IDXGIObject, IDXGIFactory, IDXGIFactory1, IDXGIFactory2, IDXGIFactory3, IDXGIFactory4, IDXGIFactory5, IDXGIFactory6, IDXGIFactory7, IDXGIDisplayControl 

Adapters
 Intel(R) HD Graphics 520
 NVIDIA GeForce 940MX 

[...]

Output Protection Manager (OPM Semantics)
 Certificate Subject: IntelVpgOpm2011
 OPM_GET_OUTPUT_ID: OutputId 0x0000000000040F04
 OPM_GET_ADAPTER_BUS_TYPE: ulInformation OPM_BUS_TYPE_OTHER | OPM_BUS_IMPLEMENTATION_MODIFIER_INSIDE_OF_CHIPSET | OPM_COPP_COMPATIBLE_BUS_TYPE_INTEGRATED
 OPM_GET_CONNECTOR_TYPE: ulInformation OPM_CONNECTOR_TYPE_DISPLAYPORT_EMBEDDED 

[...]
 
Output Duplication
 Direct3D 11 Feature Level: D3D_FEATURE_LEVEL_11_1; https://msdn.microsoft.com/en-us/library/windows/desktop/ff476876#Overview
 Mode Description:
 Width: 1 920
 Height: 1 080
 Refresh Rate: 138 500 000/2 310 880 (59,934)
 Format: DXGI_FORMAT_B8G8R8A8_UNORM
 Scanline Ordering: DXGI_MODE_SCANLINE_ORDER_PROGRESSIVE
 Scaling: DXGI_MODE_SCALING_UNSPECIFIED
 Rotation: DXGI_MODE_ROTATION_IDENTITY
 Desktop Image In System Memory: 0 

However, when the app is started on dGPU, adapter enumeration order is expectedly changed, and also Desktop Duplication API is dysfunctional as documented here: Error generated when Desktop Duplication API-capable application is run against discrete GPU, but…

DXGI Capabilities
 NOTE: Baseline capabilities are corresponding to DXGI 1.1
 Windowed Stereo: 0
 DXGI_FEATURE_PRESENT_ALLOW_TEARING: 1
 Adapters by Preference:
 DXGI_GPU_PREFERENCE_UNSPECIFIED: NVIDIA GeForce 940MX (0.0x00010A9D), Intel(R) HD Graphics 520 (0.0x00010765), Microsoft Basic Render Driver (0.0x00010A66)
 DXGI_GPU_PREFERENCE_MINIMUM_POWER: Intel(R) HD Graphics 520 (0.0x00010765), NVIDIA GeForce 940MX (0.0x00010A9D), Microsoft Basic Render Driver (0.0x00010A66)
 DXGI_GPU_PREFERENCE_HIGH_PERFORMANCE: NVIDIA GeForce 940MX (0.0x00010A9D), Intel(R) HD Graphics 520 (0.0x00010765), Microsoft Basic Render Driver (0.0x00010A66)
 Factory Interfaces: IDXGIObject, IDXGIFactory, IDXGIFactory1, IDXGIFactory2, IDXGIFactory3, IDXGIFactory4, IDXGIFactory5, IDXGIFactory6, IDXGIFactory7, IDXGIDisplayControl 

Adapters
 NVIDIA GeForce 940MX
 Intel(R) HD Graphics 520 

[...]

Output Protection Manager (OPM Semantics)
 Certificate Subject: IntelVpgOpm2011
 OPM_GET_OUTPUT_ID: OutputId 0x0000000000040F04
 OPM_GET_ADAPTER_BUS_TYPE: ulInformation OPM_BUS_TYPE_OTHER | OPM_BUS_IMPLEMENTATION_MODIFIER_INSIDE_OF_CHIPSET | OPM_COPP_COMPATIBLE_BUS_TYPE_INTEGRATED
 OPM_GET_CONNECTOR_TYPE: ulInformation OPM_CONNECTOR_TYPE_DISPLAYPORT_EMBEDDED

[...]
 
Output Duplication
 Exception: Указанный интерфейс устройства или уровень компонента не поддерживается в данной системе (0x887A0004; DXGI_ERROR_UNSUPPORTED); https://support.microsoft.com/en-ie/help/3019314/error-generated-when-desktop-duplication-api-capable-application-is-ru 

…here is the news: NVIDIA DXGI adapter is enumerated with Intel OPM certificate… What a find!

Download links

Leave a Reply