From: Elizabeth Figura <zfigura@codeweavers.com> Currently d3d10 raw resolve is done as a colour or depth blit, but we interpret it as raw anyway. Meanwhile, true d3d9 non-raw resolve avoids being treated as raw by being filtered out by the logic changing src_location, which matches on the absence of a typeless format. This is not declarative. We have a raw blit op, so we should use it, and filter on that instead of the presence of a typeless format. As a first step, make our handling of raw resolve explicit. --- dlls/wined3d/texture_gl.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/dlls/wined3d/texture_gl.c b/dlls/wined3d/texture_gl.c index 87f02cbaa6f..e93451e2c58 100644 --- a/dlls/wined3d/texture_gl.c +++ b/dlls/wined3d/texture_gl.c @@ -653,6 +653,13 @@ static bool fbo_blitter_supported(enum wined3d_blit_op blit_op, const struct win if (src_ds != dst_ds) return false; + /* We can't do raw blits, but we are the only blitter that can do resolve, + * so we handle this case by delegating the format conversion to the raw + * blitter. */ + if (blit_op == WINED3D_BLIT_OP_RAW_BLIT && src_resource->multisample_type != WINED3D_MULTISAMPLE_NONE + && dst_resource->multisample_type == WINED3D_MULTISAMPLE_NONE) + blit_op = src_ds ? WINED3D_BLIT_OP_DEPTH_BLIT : WINED3D_BLIT_OP_COLOR_BLIT; + switch (blit_op) { case WINED3D_BLIT_OP_COLOR_BLIT: @@ -1085,7 +1092,7 @@ static DWORD fbo_blitter_blit(struct wined3d_blitter *blitter, enum wined3d_blit resolve_format); } - if (blit_op == WINED3D_BLIT_OP_COLOR_BLIT) + if (blit_op == WINED3D_BLIT_OP_COLOR_BLIT || blit_op == WINED3D_BLIT_OP_RAW_BLIT) { TRACE("Colour blit.\n"); texture2d_blt_fbo(device, context, filter, src_texture, src_sub_resource_idx, src_location, -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/10465