Cleanup.
This commit is contained in:
parent
8a367819e6
commit
8f3708fe28
@ -543,6 +543,8 @@ namespace bgfx { namespace d3d11
|
||||
g_caps.gpu[ii].deviceId = (uint16_t)desc.DeviceId;
|
||||
++g_caps.numGPUs;
|
||||
|
||||
if (NULL == m_adapter)
|
||||
{
|
||||
if ( (BGFX_PCI_ID_NONE != g_caps.vendorId || 0 != g_caps.deviceId)
|
||||
&& (BGFX_PCI_ID_NONE == g_caps.vendorId || desc.VendorId == g_caps.vendorId)
|
||||
&& ( 0 == g_caps.deviceId || desc.DeviceId == g_caps.deviceId) )
|
||||
@ -559,6 +561,7 @@ namespace bgfx { namespace d3d11
|
||||
m_driverType = D3D_DRIVER_TYPE_REFERENCE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
DX_RELEASE(adapter, adapter == m_adapter ? 1 : 0);
|
||||
}
|
||||
|
@ -380,6 +380,8 @@ namespace bgfx { namespace d3d9
|
||||
g_caps.gpu[ii].vendorId = (uint16_t)desc.VendorId;
|
||||
g_caps.gpu[ii].deviceId = (uint16_t)desc.DeviceId;
|
||||
|
||||
if (D3DADAPTER_DEFAULT == m_adapter)
|
||||
{
|
||||
if ( (BGFX_PCI_ID_NONE != g_caps.vendorId || 0 != g_caps.deviceId)
|
||||
&& (BGFX_PCI_ID_NONE == g_caps.vendorId || desc.VendorId == g_caps.vendorId)
|
||||
&& ( 0 == g_caps.deviceId || desc.DeviceId == g_caps.deviceId) )
|
||||
@ -387,13 +389,13 @@ namespace bgfx { namespace d3d9
|
||||
m_adapter = ii;
|
||||
}
|
||||
|
||||
#if BGFX_CONFIG_DEBUG_PERFHUD
|
||||
if (0 != strstr(desc.Description, "PerfHUD") )
|
||||
if (BX_ENABLED(BGFX_CONFIG_DEBUG_PERFHUD)
|
||||
&& 0 != strstr(description, "PerfHUD"))
|
||||
{
|
||||
m_adapter = ii;
|
||||
m_deviceType = D3DDEVTYPE_REF;
|
||||
}
|
||||
#endif // BGFX_CONFIG_DEBUG_PERFHUD
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user