Module: wine
Branch: master
Commit: ba2f78922f84f0576694fef17be7bec2cc9da19b
URL: https://gitlab.winehq.org/wine/wine/-/commit/ba2f78922f84f0576694fef17be7be…
Author: Elizabeth Figura <zfigura(a)codeweavers.com>
Date: Fri Mar 15 18:59:35 2024 -0500
wined3d: Remove no longer used support for drawing to an onscreen render target.
Now that we require ORM_FBO, wined3d backbuffers are always offscreen (and we
never draw directly to the frontbuffer, which is the only truly onscreen
surface).
We could reintroduce support for drawing directly to the backbuffer, and this
would presumably improve performance by avoiding a blit from the wined3d
backbuffer to the real GL backbuffer.
However, this is not always possible or performant due to mismatching
dimensions, or the need to use a depth buffer which is also used with offscreen
RTVs, and for d3d1-9 it may not be possible at all due to issues related to
preserving invariance between flipped and non-flipped geometry.
It *may* be possible to identify situations where we can render directly to the
backbuffer for d3d10+, but at that point we can rely on the Vulkan backend to
work, and given other unfixable performance problems with the GL backend (most
notably the inability to properly stream index buffer data) it does not really
make much sense to go out of our way to perform such a minor optimization there.
---
dlls/wined3d/adapter_gl.c | 1 -
dlls/wined3d/arb_program_shader.c | 4 +-
dlls/wined3d/context_gl.c | 101 +++++++++++---------------------------
dlls/wined3d/ffp_gl.c | 95 +++++++++--------------------------
dlls/wined3d/glsl_shader.c | 4 +-
dlls/wined3d/shader.c | 4 +-
dlls/wined3d/utils.c | 2 +-
dlls/wined3d/wined3d_private.h | 10 +---
8 files changed, 60 insertions(+), 161 deletions(-)
Module: wine
Branch: master
Commit: 4ad68d4e0429c1caef88203c0bf5ee489ba5a3b1
URL: https://gitlab.winehq.org/wine/wine/-/commit/4ad68d4e0429c1caef88203c0bf5ee…
Author: Elizabeth Figura <zfigura(a)codeweavers.com>
Date: Fri Mar 15 18:44:37 2024 -0500
wined3d: Use wined3d_resource_is_offscreen() directly in ffp_blitter_clear_rendertargets().
This is the only user of context->render_offscreen that is not related to draw
state.
The use here is synonymous with using wined3d_resource_is_offscreen() on the
actual colour target.
---
dlls/wined3d/texture.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c
index 9edfc38c01c..a4eee054528 100644
--- a/dlls/wined3d/texture.c
+++ b/dlls/wined3d/texture.c
@@ -5955,7 +5955,7 @@ static void ffp_blitter_clear_rendertargets(struct wined3d_device *device, unsig
if (target)
{
- render_offscreen = context->render_offscreen;
+ render_offscreen = wined3d_resource_is_offscreen(&target->resource);
wined3d_rendertarget_view_get_drawable_size(rtv, context, &drawable_width, &drawable_height);
}
else