Signed-off-by: Henri Verbeet hverbeet@codeweavers.com --- dlls/d3d10core/tests/d3d10core.c | 7 ++++--- dlls/d3d11/tests/d3d11.c | 2 +- dlls/wined3d/texture.c | 11 +++++++++-- 3 files changed, 14 insertions(+), 6 deletions(-)
diff --git a/dlls/d3d10core/tests/d3d10core.c b/dlls/d3d10core/tests/d3d10core.c index def80870fd5..6c381f62840 100644 --- a/dlls/d3d10core/tests/d3d10core.c +++ b/dlls/d3d10core/tests/d3d10core.c @@ -16217,8 +16217,9 @@ static void test_format_compatibility(void) colour = get_readback_color(&rb, x, y); 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); + todo_wine_if(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);
@@ -16231,7 +16232,7 @@ static void test_format_compatibility(void) y = j / 4; colour = get_readback_color(&rb, x, y); expected = test_data[i].success ? bitmap_data[j] : initial_data[j]; - todo_wine_if(test_data[i].src_ds) + todo_wine_if(test_data[i].dst_ds || test_data[i].src_format == DXGI_FORMAT_R16_TYPELESS) ok(colour == expected, "Test %u: Got unexpected colour 0x%08x at (%u, %u), expected 0x%08x.\n", i, colour, x, y, expected); } diff --git a/dlls/d3d11/tests/d3d11.c b/dlls/d3d11/tests/d3d11.c index c1834540484..36c3995e7ad 100644 --- a/dlls/d3d11/tests/d3d11.c +++ b/dlls/d3d11/tests/d3d11.c @@ -28306,7 +28306,7 @@ 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]; - todo_wine_if(test_data[i].src_ds || test_data[i].dst_ds) + todo_wine_if(!test_data[i].dst_ds && test_data[i].src_format == DXGI_FORMAT_R16_TYPELESS) ok(colour == expected, "Test %u: Got unexpected colour 0x%08x at (%u, %u), expected 0x%08x.\n", i, colour, x, y, expected); } diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c index 5c85b2c91bb..f3a48faf5ca 100644 --- a/dlls/wined3d/texture.c +++ b/dlls/wined3d/texture.c @@ -6082,12 +6082,19 @@ static DWORD raw_blitter_blit(struct wined3d_blitter *blitter, enum wined3d_blit unsigned int src_level, src_layer, dst_level, dst_layer; struct wined3d_blitter *next; GLuint src_name, dst_name; + bool src_ds, dst_ds; DWORD location;
+ src_ds = src_texture->resource.format->depth_size || src_texture->resource.format->stencil_size; + dst_ds = dst_texture->resource.format->depth_size || dst_texture->resource.format->stencil_size; + /* If we would need to copy from a renderbuffer or drawable, we'd probably * be better off using the FBO blitter directly, since we'd need to use it - * to copy the resource contents to the texture anyway. */ - if (op != WINED3D_BLIT_OP_RAW_BLIT + * to copy the resource contents to the texture anyway. + * + * We also can't copy between depth/stencil and colour resources, since + * the formats are considered incompatible in OpenGL. */ + if (op != WINED3D_BLIT_OP_RAW_BLIT || (src_ds != dst_ds) || (src_texture->resource.format->id == dst_texture->resource.format->id && (!(src_location & (WINED3D_LOCATION_TEXTURE_RGB | WINED3D_LOCATION_TEXTURE_SRGB)) || !(dst_location & (WINED3D_LOCATION_TEXTURE_RGB | WINED3D_LOCATION_TEXTURE_SRGB)))))
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=90002
Your paranoid android.
=== w8adm (32 bit report) ===
d3d10core: 0cd8:d3d10core: unhandled exception c0000005 at 7FE95178
=== w1064_tsign (32 bit report) ===
d3d10core: d3d10core.c:4766: Test failed: Got unexpected IAVertices count: 0. d3d10core.c:4767: Test failed: Got unexpected IAPrimitives count: 0. d3d10core.c:4768: Test failed: Got unexpected VSInvocations count: 0. d3d10core.c:4771: Test failed: Got unexpected CInvocations count: 0. d3d10core.c:4772: Test failed: Got unexpected CPrimitives count: 0.
=== w1064 (64 bit report) ===
d3d10core: d3d10core.c:4766: Test failed: Got unexpected IAVertices count: 0. d3d10core.c:4767: Test failed: Got unexpected IAPrimitives count: 0. d3d10core.c:4768: Test failed: Got unexpected VSInvocations count: 0. d3d10core.c:4771: Test failed: Got unexpected CInvocations count: 0. d3d10core.c:4772: Test failed: Got unexpected CPrimitives count: 0.
=== debiant2 (32 bit Japanese:Japan report) ===
d3d11: d3d11.c:9661: Test failed: d3d11.c:15141: Test marked todo: Got hr 0 for WRITE_DISCARD.