D3D12GetInterface function (d3d12.h)

Selects an SDK version at runtime when the system is in Windows Developer Mode. Supports debug, tools, DRED, and SDK configuration interfaces.


HRESULT D3D12GetInterface(
  REFCLSID rclsid,
  REFIID   riid,
  void     **ppvDebug




The CLSID associated with the data and code that will be used to create the object.

The following CLSIDs are defined.

  • DEFINE_GUID(CLSID_D3D12Debug, 0xf2352aeb, 0xdd84, 0x49fe, 0xb9, 0x7b, 0xa9, 0xdc, 0xfd, 0xcc, 0x1b, 0x4f);
  • DEFINE_GUID(CLSID_D3D12Tools, 0xe38216b1, 0x3c8c, 0x4833, 0xaa, 0x09, 0x0a, 0x06, 0xb6, 0x5d, 0x96, 0xc8);
  • DEFINE_GUID(CLSID_D3D12DeviceRemovedExtendedData, 0x4a75bbc4, 0x9ff4, 0x4ad8, 0x9f, 0x18, 0xab, 0xae, 0x84, 0xdc, 0x5f, 0xf2);
  • DEFINE_GUID(CLSID_D3D12SDKConfiguration, 0x7cda6aca, 0xa03e, 0x49c8, 0x94, 0x58, 0x03, 0x34, 0xd2, 0x0e, 0x07, 0xce);

They correspond, respectively, to the following interfaces.


Type: _In_ REFIID

The globally unique identifier (GUID) for the SDK configuration interface. The REFIID, or GUID, of the interface can be obtained by using the __uuidof macro. For example, __uuidof(ID3D12SDKConfiguration) will retrieve the GUID of the debug interface.


Type: _COM_Outptr_opt_ void**

The out parameter that contains the requested interface on return (for example, the SDK configuration interface), as a pointer to pointer to void. See ID3D12SDKConfiguration.

Return value


If the function succeeds, then it returns S_OK. Otherwise, it returns one of the Direct3D 12 return codes.


Minimum supported client Windows 10 Build 20348
Minimum supported server Windows 10 Build 20348
Target Platform Windows
Header d3d12.h
Library D3D12.lib
DLL D3D12.dll

See also