Commit Graph

469 Commits

Author SHA1 Message Date
Henrik Rydgård 1b2f87bf1a Rename GPUgstate to GEState 2026-07-02 20:34:09 +02:00
Henrik Rydgård 87cc608df1 Add the necessary logic to use in-shader CLUT lookups for regular textures 2026-06-11 12:42:16 +02:00
Henrik Rydgård 5c340ccd09 Remove the concept of scaled/offset depth buffers. 2026-06-10 10:41:30 +02:00
Henrik Rydgård ce7da78b17 Invalidate texture hashes on readbacks 2026-06-09 23:49:54 +02:00
Henrik Rydgård ae98055cec Delete a lot of legacy depth and viewport code, fix OpenGL 2026-05-30 19:07:58 +02:00
Henrik Rydgård f60e27a9b7 Just some refactoring of the GPUStatistics struct, and more use of StringWriter 2026-05-29 14:40:31 +02:00
Henrik Rydgård b65bbaf92c Merge pull request #21678 from nintendo424/gpu-save-first-frame
gpu: Preserve first-frame font render targets
2026-05-27 12:22:47 +02:00
Henrik Rydgård 06a7793f57 Fix some y-flip issues in D3D11. It got broken by recent refactorings.
Fixes #21726
2026-05-26 15:51:24 +02:00
nintendo424 e5689d1adc gpu: Preserve first-frame font render targets
Some games render HLE sceFont glyphs into small VRAM-backed framebuffers and immediately sample them as textures. This needs both the source glyph buffer and the temporary render target to be preserved before later commands overwrite or rebind them.

Save first-frame data from the previous render target before creating a new framebuffer, since ResizeFramebufFBO() makes the new framebuffer current. Also flush pending draws before PGF writes over a glyph buffer that may still be referenced by queued texture draws.

Backend software transform normally reports safe framebuffer size during draw flush, but first-frame readback can happen before queued draws reach that path. Estimate through-mode rectangle/triangle bounds before SubmitPrim() and feed those bounds to SetSafeSize(), using actual vertices clamped to scissor instead of a tiny-target heuristic.

Fixes missing text in Evangelion JO.
2026-05-15 12:23:14 -04:00
Henrik Rydgård 85de7fdc50 Add new flag that will simplify the GL path 2026-05-14 22:20:35 +02:00
Henrik Rydgård e0d6664e85 Fix issue with raw screenshots not always being cropped correctly
Fixes #21664
2026-05-12 10:12:41 +02:00
Herman Semenoff 8f4fb77f79 gameinfocache: fbmanager: use const ref and modernize to for range C++17
From #21606
2026-04-28 10:54:55 +02:00
Herman Semenoff 5e2f51af8e gpu: elf: using reserve() for optimize inserts in for loop
From #21611
2026-04-28 10:53:32 +02:00
Henrik Rydgård df5ad56546 Merge pull request #21324 from hrydgard/silent-hill-shadows
WIP: Apply changes by fcrwr, fixing (mostly) shadows in Silent Hill: Shattered memories
2026-03-18 09:06:55 +01:00
Henrik Rydgård c1f8421dc2 Merge pull request #21342 from fcrwr/block-transfer-clipping
Fix block transfer clipping
2026-03-17 22:28:04 +01:00
Henrik Rydgård 0a1be41fa7 Additional fixes to ZipFileLoader 2026-03-08 12:33:46 +01:00
fcrwr cc4bf75717 Fix block transfer clipping
Fix block transfer clipping that happened due to code not taking block
transfer offsets into account when finding framebuffers for block
transfer and when creating ram framebuffer.
2026-03-04 19:46:28 +05:00
fcrwr f3c98442d5 Apply changes by fcrwr, fixing (mostly) shadows in Silent Hill: Shattered Memories
The game actually implements proper shadow mapping using some wicked
trickery, including framebuffer color reinterpretation. This finally
gets it working, by filling in some gaps in the existing mechanisms.

Unfortunately there's some precision issue that needs to be looked at,
as it can currently look quite stripy, very typical of shadow mapping.
2026-03-02 19:23:43 +01:00
Henrik Rydgård 5dc169ecbe Fix more race conditions if you exit during game bootup 2026-02-24 00:56:45 +01:00
Henrik Rydgård 202259eb09 Add a quick workaround for Mahjongg Artifacts framebuffer expiration.
Fixes #15828, well at least except for savestate support.
2026-02-22 23:42:13 +01:00
Henrik Rydgård 5a5c7028b9 Assorted warning fixes and data initialization to please valgrind 2026-02-19 11:24:46 +01:00
Henrik Rydgård 386fc442a6 Rework the internal screenshot API, fix bug causing screenshotting to get stuck 2026-02-13 12:34:26 +01:00
Henrik Rydgård d8b8a51309 Correct a bunch of edge cases, move some code around 2026-02-08 17:07:22 +01:00
Henrik Rydgård df2d00208e Improve screenshots in "Skip buffer effects" mode 2026-02-08 16:33:48 +01:00
Henrik Rydgård eb234a1563 Finish the split. Greatly simplifies the render code in EmuScreen. 2026-02-08 10:46:16 +01:00
Henrik Rydgård 2ea94534e6 Split up FramebufferManagerCommon::CopyDisplayToOutput 2026-02-08 10:17:42 +01:00
Henrik Rydgård aa17599f66 Make things more consistent in the no-present case 2026-02-08 10:13:34 +01:00
Henrik Rydgård 814713e932 More refactor 2026-02-08 01:06:35 +01:00
Henrik Rydgård c139d4aaff Split up Presentation::CopyToOutput into passes and output. 2026-02-08 01:06:35 +01:00
Henrik Rydgård 34108551da Fix a problem with copies to RAM - forgot to set up the copy dest rectangle
Fixes #21187
2026-02-05 14:04:34 +01:00
Henrik Rydgård 475390a968 Add workaround for Tales of Phantasia X.
Fixes #21162
2026-01-29 23:16:51 +01:00
Henrik Rydgård d6ebfed432 Fix some bugs and warnings from a pass of static analysis 2026-01-29 17:41:54 +01:00
Henrik Rydgård 60a065b242 Make the Brave Story hack safer, hide it behind a compat flag. 2026-01-23 23:39:11 +01:00
Henrik Rydgård 732288c03a Brave Story: Hack to make the bloom effect run much more efficiently.
Fixes #19820

Not ready for merge, it needs more checks and maybe a compat flag.
2026-01-23 23:13:04 +01:00
Henrik Rydgård 30e23000c0 Correct the fallback path for intra-framebuffer block copies 2026-01-22 14:25:09 +01:00
Henrik Rydgård 7bca84252e Vulkan: Add support for doing intra-buffer block copies with vkCmdCopyImage. 2026-01-22 13:47:41 +01:00
Henrik Rydgård 1ac218960f OpenGL / FramebufferManager: Improve asserts for raster blits 2026-01-01 14:15:37 +01:00
Henrik Rydgård c999367471 Fix crash in DrawPixels in "skip framebuffer effects" mode 2025-12-15 17:18:17 +01:00
Henrik Rydgård 4ba197bc77 Crashfix in FramebufferManager 2025-11-27 10:31:08 +01:00
sum2012 553ee27629 Remove spam of "Rendering from framebuf with offset"
It spam in all games.
Only output in debug mode.
2025-11-15 19:33:58 +08:00
Henrik Rydgård 67010ff2af Split the display layout config between landscape and portrait orientations 2025-11-05 12:49:51 +01:00
Henrik Rydgård 176c55da25 Remove unused "interval" concept from presentation mode 2025-10-19 18:18:06 +02:00
Henrik Rydgård a80756574c Fix really wacky edge case when switching to Auto FrameSkip from "skip buffered" mode.
Fixes issue #20596
2025-07-08 20:08:23 +02:00
Henrik Rydgård b0cfeed766 Make the check for framebuffer copy targets slightly more lenient for tiny copies.
- Fixes #20556
2025-06-26 18:23:56 +02:00
Henrik Rydgård 6cfea96e58 Remove D3D9 support, to make future changes easier 2025-06-10 15:07:16 +02:00
Henrik Rydgård 2e7f2ffcd4 Same as previous commit for the framebuffermanager debug UI 2025-05-26 19:39:51 +02:00
Henrik Rydgård 751e4fad2e Move more of GPU init to the loader thread. Some log cleanup. 2025-05-15 11:43:37 +02:00
Henrik Rydgård 41b77bf1ae More log cleanup 2025-04-14 22:27:51 +02:00
Henrik Rydgård 78141d602e GPU assert fix 2025-04-03 13:44:36 +02:00
Henrik Rydgård 8d6593b92b Remove compat flag AllowDelayedReadback 2025-01-05 09:18:13 +01:00