Signed-off-by: Henri Verbeet hverbeet@codeweavers.com --- dlls/d3d11/tests/d3d11.c | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-)
diff --git a/dlls/d3d11/tests/d3d11.c b/dlls/d3d11/tests/d3d11.c index 95d7c847720..c1834540484 100644 --- a/dlls/d3d11/tests/d3d11.c +++ b/dlls/d3d11/tests/d3d11.c @@ -28184,6 +28184,8 @@ static void test_format_compatibility(void) DXGI_FORMAT dst_format; size_t texel_size; BOOL success; + BOOL src_ds; + BOOL dst_ds; } test_data[] = { @@ -28213,6 +28215,10 @@ static void test_format_compatibility(void) {DXGI_FORMAT_R32G32_FLOAT, DXGI_FORMAT_R32G32_UINT, 8, TRUE}, {DXGI_FORMAT_R32G32_UINT, DXGI_FORMAT_R32G32_SINT, 8, TRUE}, {DXGI_FORMAT_R32G32_SINT, DXGI_FORMAT_R32G32_TYPELESS, 8, TRUE}, + {DXGI_FORMAT_D16_UNORM, DXGI_FORMAT_R16_UNORM, 2, TRUE, TRUE}, + {DXGI_FORMAT_R16_UNORM, DXGI_FORMAT_D16_UNORM, 2, TRUE, FALSE, TRUE}, + {DXGI_FORMAT_R16_TYPELESS, DXGI_FORMAT_R16_TYPELESS, 2, TRUE, TRUE}, + {DXGI_FORMAT_R16_TYPELESS, DXGI_FORMAT_R16_TYPELESS, 2, TRUE, FALSE, TRUE}, }; static const DWORD initial_data[16] = {0}; static const DWORD bitmap_data[] = @@ -28235,7 +28241,6 @@ static void test_format_compatibility(void) texture_desc.ArraySize = 1; texture_desc.SampleDesc.Count = 1; texture_desc.SampleDesc.Quality = 0; - texture_desc.BindFlags = D3D11_BIND_SHADER_RESOURCE; texture_desc.CPUAccessFlags = 0; texture_desc.MiscFlags = 0;
@@ -28247,7 +28252,8 @@ static void test_format_compatibility(void)
texture_desc.Width = sizeof(bitmap_data) / (texture_desc.Height * test_data[i].texel_size); texture_desc.Format = test_data[i].src_format; - texture_desc.Usage = D3D11_USAGE_IMMUTABLE; + texture_desc.Usage = test_data[i].src_ds ? D3D11_USAGE_DEFAULT : D3D11_USAGE_IMMUTABLE; + texture_desc.BindFlags = test_data[i].src_ds ? D3D11_BIND_DEPTH_STENCIL : D3D11_BIND_SHADER_RESOURCE;
resource_data.pSysMem = bitmap_data; resource_data.SysMemPitch = texture_desc.Width * test_data[i].texel_size; @@ -28258,6 +28264,7 @@ static void test_format_compatibility(void)
texture_desc.Format = test_data[i].dst_format; texture_desc.Usage = D3D11_USAGE_DEFAULT; + texture_desc.BindFlags = test_data[i].dst_ds ? D3D11_BIND_DEPTH_STENCIL : D3D11_BIND_SHADER_RESOURCE;
resource_data.pSysMem = initial_data;
@@ -28282,10 +28289,11 @@ static void test_format_compatibility(void) x = j % 4; y = j / 4; colour = get_readback_color(&rb, x, y, 0); - expected = test_data[i].success && x >= texel_dwords && y - ? bitmap_data[j - (4 + texel_dwords)] : initial_data[j]; - ok(colour == expected, "Test %u: Got unexpected colour 0x%08x at (%u, %u), expected 0x%08x.\n", - i, colour, x, y, expected); + expected = test_data[i].success && !test_data[i].src_ds && !test_data[i].dst_ds + && x >= texel_dwords && y ? bitmap_data[j - (4 + texel_dwords)] : initial_data[j]; + todo_wine_if((test_data[i].src_ds || test_data[i].dst_ds) && colour) + ok(colour == expected, "Test %u: Got unexpected colour 0x%08x at (%u, %u), expected 0x%08x.\n", + i, colour, x, y, expected); } release_resource_readback(&rb);
@@ -28298,8 +28306,9 @@ static void test_format_compatibility(void) y = j / 4; colour = get_readback_color(&rb, x, y, 0); expected = test_data[i].success ? bitmap_data[j] : initial_data[j]; - ok(colour == expected, "Test %u: Got unexpected colour 0x%08x at (%u, %u), expected 0x%08x.\n", - i, colour, x, y, expected); + todo_wine_if(test_data[i].src_ds || test_data[i].dst_ds) + ok(colour == expected, "Test %u: Got unexpected colour 0x%08x at (%u, %u), expected 0x%08x.\n", + i, colour, x, y, expected); } release_resource_readback(&rb);
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=90000
Your paranoid android.
=== w1064v1809 (32 bit report) ===
d3d11: d3d11.c:5811: Test failed: Got unexpected IAVertices count: 0. d3d11.c:5812: Test failed: Got unexpected IAPrimitives count: 0. d3d11.c:5813: Test failed: Got unexpected VSInvocations count: 0. d3d11.c:5816: Test failed: Got unexpected CInvocations count: 0. d3d11.c:5817: Test failed: Got unexpected CPrimitives count: 0.
=== w1064 (32 bit report) ===
d3d11: d3d11.c:5811: Test failed: Got unexpected IAVertices count: 0. d3d11.c:5812: Test failed: Got unexpected IAPrimitives count: 0. d3d11.c:5813: Test failed: Got unexpected VSInvocations count: 0. d3d11.c:5816: Test failed: Got unexpected CInvocations count: 0. d3d11.c:5817: Test failed: Got unexpected CPrimitives count: 0.
=== debiant2 (32 bit French report) ===
d3d11: d3d11.c:9661: Test failed: d3d11.c:15022: Test marked todo: Got hr 0 for WRITE.