d3d8/test: Add slop to some fog tests.

oldstable
Stefan Dösinger 2011-09-15 23:01:44 +02:00 committed by Alexandre Julliard
parent 7759729fc7
commit 8b57a585ad
1 changed files with 12 additions and 6 deletions

View File

@ -509,13 +509,17 @@ static void fog_test(IDirect3DDevice8 *device)
}
color = getPixelColor(device, 160, 360);
ok(color == 0x00FF0000, "Untransformed vertex with no table or vertex fog has color %08x\n", color);
ok(color_match(color, D3DCOLOR_ARGB(0x00, 0xFF, 0x00, 0x00), 1),
"Untransformed vertex with no table or vertex fog has color %08x\n", color);
color = getPixelColor(device, 160, 120);
ok(color == 0x0000FF00, "Untransformed vertex with linear vertex fog has color %08x\n", color);
ok(color_match(color, D3DCOLOR_ARGB(0x00, 0x00, 0xFF, 0x00), 1),
"Untransformed vertex with linear vertex fog has color %08x\n", color);
color = getPixelColor(device, 480, 120);
ok(color == 0x00FFFF00, "Transformed vertex with linear vertex fog has color %08x\n", color);
ok(color_match(color, D3DCOLOR_ARGB(0x00, 0xFF, 0xFF, 0x00), 1),
"Transformed vertex with linear vertex fog has color %08x\n", color);
color = getPixelColor(device, 480, 360);
ok(color == 0x0000FF00, "Transformed vertex with linear table fog has color %08x\n", color);
ok(color_match(color, D3DCOLOR_ARGB(0x00, 0x00, 0xFF, 0x00), 1),
"Transformed vertex with linear table fog has color %08x\n", color);
IDirect3DDevice8_Present(device, NULL, NULL, NULL, NULL);
@ -557,7 +561,8 @@ static void fog_test(IDirect3DDevice8 *device)
color = getPixelColor(device, 160, 360);
ok(color_match(color, 0x00ff0000, 4), "Unfogged quad has color %08x\n", color);
color = getPixelColor(device, 160, 120);
ok(color == 0x0000ff00, "Fogged out quad has color %08x\n", color);
ok(color_match(color, D3DCOLOR_ARGB(0x00, 0x00, 0xff, 0x00), 1),
"Fogged out quad has color %08x\n", color);
IDirect3DDevice8_Present(device, NULL, NULL, NULL, NULL);
@ -594,7 +599,8 @@ static void fog_test(IDirect3DDevice8 *device)
color = getPixelColor(device, 160, 360);
todo_wine ok(color_match(color, 0x00e51900, 4), "Partially fogged quad has color %08x\n", color);
color = getPixelColor(device, 160, 120);
ok(color == 0x0000ff00, "Fogged out quad has color %08x\n", color);
ok(color_match(color, D3DCOLOR_ARGB(0x00, 0x00, 0xff, 0x00), 1),
"Fogged out quad has color %08x\n", color);
IDirect3DDevice8_Present(device, NULL, NULL, NULL, NULL);