d3drm: Set light alpha to 1.0 in d3drm_light_SetColor().

Signed-off-by: Jeff Smith <whydoubt@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Jeff Smith 2020-06-16 22:29:37 +04:30 committed by Alexandre Julliard
parent 0801337496
commit 12be3c43bd
2 changed files with 6 additions and 1 deletions

View File

@ -165,7 +165,7 @@ static HRESULT WINAPI d3drm_light_SetColor(IDirect3DRMLight *iface, D3DCOLOR col
TRACE("iface %p, color 0x%08x.\n", iface, color);
light->color = color;
light->color = 0xff000000 | color;
return D3DRM_OK;
}

View File

@ -2589,6 +2589,11 @@ static void test_Light(void)
color = IDirect3DRMLight_GetColor(light);
ok(color == 0xff180587, "wrong color (%x)\n", color);
hr = IDirect3DRMLight_SetColor(light, 0x00c0c0c0);
ok(hr == D3DRM_OK, "Got unexpected hr %#x.\n", hr);
color = IDirect3DRMLight_GetColor(light);
ok(color == 0xffc0c0c0, "Got unexpected color 0x%08x.\n", color);
hr = IDirect3DRMLight_SetColorRGB(light, 0.5, 0.5, 0.5);
ok(hr == D3DRM_OK, "Cannot set color (hr = %x)\n", hr);
color = IDirect3DRMLight_GetColor(light);