[PATCH 2/4] ddraw/tests: The testbot applies color keying without a key.
Stefan Dösinger
stefan at codeweavers.com
Fri Mar 20 06:47:11 CDT 2015
The alternative way to fix these failures would be to disable color
keying. This is covered by the ddraw2 version of this test. I prefer to
accept the testbot result as broken to avoid introducing the same
mistake in Wine.
test_ck_rgba is broken on the testbot as well, but in a different way
that I don't fully understand yet.
---
dlls/ddraw/tests/ddraw1.c | 18 ++++++++++++++----
1 file changed, 14 insertions(+), 4 deletions(-)
diff --git a/dlls/ddraw/tests/ddraw1.c b/dlls/ddraw/tests/ddraw1.c
index f59355e..ca61f13 100644
--- a/dlls/ddraw/tests/ddraw1.c
+++ b/dlls/ddraw/tests/ddraw1.c
@@ -6211,14 +6211,24 @@ static void test_texturemapblend(void)
hr = IDirect3DDevice_EndScene(device);
ok(SUCCEEDED(hr), "Failed to end scene, hr %#x.\n", hr);
+ /* WARP (Win8 testbot) emulates color keying with the alpha channel like Wine does,
+ * but even applies it when there's no color key assigned. The surface alpha is zero
+ * here, so nothing gets drawn.
+ *
+ * The ddraw2 version of this test draws these quads with color keying off due to
+ * different defaults in ddraw1 and ddraw2. */
color = get_surface_color(rt, 5, 5);
- ok(compare_color(color, 0x00ff0040, 2), "Got unexpected color 0x%08x.\n", color);
+ ok(compare_color(color, 0x00ff0040, 2) || broken(compare_color(color, 0x00000000, 1)),
+ "Got unexpected color 0x%08x.\n", color);
color = get_surface_color(rt, 400, 5);
- ok(compare_color(color, 0x00ff0080, 2), "Got unexpected color 0x%08x.\n", color);
+ ok(compare_color(color, 0x00ff0080, 2) || broken(compare_color(color, 0x00000000, 1)),
+ "Got unexpected color 0x%08x.\n", color);
color = get_surface_color(rt, 5, 245);
- ok(compare_color(color, 0x00800080, 2), "Got unexpected color 0x%08x.\n", color);
+ ok(compare_color(color, 0x00800080, 2) || broken(compare_color(color, 0x00000000, 1)),
+ "Got unexpected color 0x%08x.\n", color);
color = get_surface_color(rt, 400, 245);
- ok(compare_color(color, 0x008000ff, 2), "Got unexpected color 0x%08x.\n", color);
+ ok(compare_color(color, 0x008000ff, 2) || broken(compare_color(color, 0x00000000, 1)),
+ "Got unexpected color 0x%08x.\n", color);
IDirect3DTexture_Release(texture);
ref = IDirectDrawSurface_Release(surface);
--
2.3.2
More information about the wine-patches
mailing list