From 98fa394f8432e5af2cec7a6563fc55b798b7bdf5 Mon Sep 17 00:00:00 2001 From: Matt Borgerson Date: Fri, 26 Jul 2024 17:21:01 -0700 Subject: [PATCH] nv2a: Add note about downloading dirty surfaces during flush --- hw/xbox/nv2a/pgraph/gl/surface.c | 3 +++ hw/xbox/nv2a/pgraph/vk/surface.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/hw/xbox/nv2a/pgraph/gl/surface.c b/hw/xbox/nv2a/pgraph/gl/surface.c index a2a00d09ac..c0aa4a4f26 100644 --- a/hw/xbox/nv2a/pgraph/gl/surface.c +++ b/hw/xbox/nv2a/pgraph/gl/surface.c @@ -1396,6 +1396,9 @@ static void flush_surfaces(NV2AState *d) SurfaceBinding *s, *next; QTAILQ_FOREACH_SAFE(s, &r->surfaces, entry, next) { + // FIXME: We should download all surfaces to ram, but need to + // investigate corruption issue + // pgraph_gl_surface_download_if_dirty(d, s); pgraph_gl_surface_invalidate(d, s); } } diff --git a/hw/xbox/nv2a/pgraph/vk/surface.c b/hw/xbox/nv2a/pgraph/vk/surface.c index 9df98666bf..43b0e743d7 100644 --- a/hw/xbox/nv2a/pgraph/vk/surface.c +++ b/hw/xbox/nv2a/pgraph/vk/surface.c @@ -1477,6 +1477,9 @@ void pgraph_vk_surface_flush(NV2AState *d) SurfaceBinding *s, *next; QTAILQ_FOREACH_SAFE(s, &r->surfaces, entry, next) { + // FIXME: We should download all surfaces to ram, but need to + // investigate corruption issue + pgraph_vk_surface_download_if_dirty(d, s); invalidate_surface(d, s); } prune_invalid_surfaces(r, 0);