Zebediah Figura (@zfigura) commented about dlls/wined3d/context_gl.c:
+ if (wined3d_settings.offscreen_rendering_mode == ORM_FBO) + { + if (location != WINED3D_LOCATION_DRAWABLE) + { + if (format->depth_size || format->stencil_size) + wined3d_context_gl_apply_fbo_state_blit(context_gl, target, NULL, + 0, &texture->resource, sub_resource_idx, location); + else + wined3d_context_gl_apply_fbo_state_blit(context_gl, target, &texture->resource, + sub_resource_idx, NULL, 0, location); + } + else + { + context_gl->current_fbo = NULL; + wined3d_context_gl_bind_fbo(context_gl, target, 0); + } wined3d_context_gl_apply_fbo_state_blit() already does this. Do we need it? Perhaps more importantly, is it safe to skip that rebind_fbo logic?
I really am not familiar with this code [I don't even know what the rebind_fbo stuff is for] and haven't spent a lot of effort to bring myself up to speed, so I'm hoping you are more familiar, enough to be able to answer those questions more easily :-) -- https://gitlab.winehq.org/wine/wine/-/merge_requests/3211#note_37704