ddraw: Return empty D3D hardware flags for RGB device enumeration.

This commit is contained in:
Erich E. Hoover 2014-02-16 14:14:42 -07:00 committed by Alexandre Julliard
parent a56ea6e5d9
commit 45147b82ef
2 changed files with 14 additions and 0 deletions

View File

@ -3683,6 +3683,8 @@ static HRESULT WINAPI d3d3_EnumDevices(IDirect3D3 *iface, LPD3DENUMDEVICESCALLBA
| D3DPTEXTURECAPS_NONPOW2CONDITIONAL | D3DPTEXTURECAPS_PERSPECTIVE);
/* RGB, RAMP and MMX devices have a HAL dcmColorModel of 0 */
hal_desc.dcmColorModel = 0;
/* RGB, RAMP and MMX devices cannot report HAL hardware flags */
hal_desc.dwFlags = 0;
hr = callback((GUID *)&IID_IDirect3DRGBDevice, reference_description,
device_name, &hal_desc, &hel_desc, context);

View File

@ -537,12 +537,18 @@ static HRESULT WINAPI enumDevicesCallback(GUID *Guid, char *DeviceDescription,
ok(hal->dcmColorModel == 0, "RGB Device %u hal caps has colormodel %u\n", ver, hal->dcmColorModel);
ok(hel->dcmColorModel == D3DCOLOR_RGB, "RGB Device %u hel caps has colormodel %u\n", ver, hel->dcmColorModel);
ok(hal->dwFlags == 0, "RGB Device %u hal caps has hardware flags %x\n", ver, hal->dwFlags);
ok(hel->dwFlags != 0, "RGB Device %u hel caps has hardware flags %x\n", ver, hel->dwFlags);
}
else if(IsEqualGUID(&IID_IDirect3DHALDevice, Guid))
{
trace("HAL Device %d\n", ver);
ok(hal->dcmColorModel == D3DCOLOR_RGB, "HAL Device %u hal caps has colormodel %u\n", ver, hel->dcmColorModel);
ok(hel->dcmColorModel == 0, "HAL Device %u hel caps has colormodel %u\n", ver, hel->dcmColorModel);
ok(hal->dwFlags != 0, "HAL Device %u hal caps has hardware flags %x\n", ver, hal->dwFlags);
ok(hel->dwFlags != 0, "HAL Device %u hel caps has hardware flags %x\n", ver, hel->dwFlags);
}
else if(IsEqualGUID(&IID_IDirect3DRefDevice, Guid))
{
@ -587,6 +593,9 @@ static HRESULT WINAPI enumDevicesCallback(GUID *Guid, char *DeviceDescription,
ok(hal->dcmColorModel == 0, "Ramp Device %u hal caps has colormodel %u\n", ver, hal->dcmColorModel);
ok(hel->dcmColorModel == D3DCOLOR_MONO, "Ramp Device %u hel caps has colormodel %u\n",
ver, hel->dcmColorModel);
ok(hal->dwFlags == 0, "Ramp Device %u hal caps has hardware flags %x\n", ver, hal->dwFlags);
ok(hel->dwFlags != 0, "Ramp Device %u hel caps has hardware flags %x\n", ver, hel->dwFlags);
}
else if(IsEqualGUID(&IID_IDirect3DMMXDevice, Guid))
{
@ -610,6 +619,9 @@ static HRESULT WINAPI enumDevicesCallback(GUID *Guid, char *DeviceDescription,
ok(hal->dcmColorModel == 0, "MMX Device %u hal caps has colormodel %u\n", ver, hal->dcmColorModel);
ok(hel->dcmColorModel == D3DCOLOR_RGB, "MMX Device %u hel caps has colormodel %u\n", ver, hel->dcmColorModel);
ok(hal->dwFlags == 0, "MMX Device %u hal caps has hardware flags %x\n", ver, hal->dwFlags);
ok(hel->dwFlags != 0, "MMX Device %u hel caps has hardware flags %x\n", ver, hel->dwFlags);
}
else
{