Stenzek
b4019f325c
GPU/HW: Fix black dots with some texture filters
...
JINC2 specifically ended up with NaNs propagating through.
2025-04-21 13:06:09 +10:00
Stenzek
7971bb949b
GPU/HW: Add Scale2x/Scale3x texture filters
2025-04-08 20:10:58 +10:00
Stenzek
dfa96e080d
GPU: Implement MMPX texture filter
2025-04-06 23:16:59 +10:00
Stenzek
62d7a73381
GPU/HW: Add 'Scaled Interlacing' option
...
Disabling this option causes rendering to skip N lines instead of 1
line, where N is the internal resolution multiplier.
2025-03-22 01:19:01 +10:00
Stenzek
58dc7562a3
GPU/HW: Add in-pass clear depth pipeline
...
Instead of clearing the entire buffer, we only need to wipe out the
current drawing area. Saves a decent chunk of memory bandwidth in games
that end up spamming clears.
2025-03-07 21:33:06 +10:00
Stenzek
bee2dabc77
Misc: Replace stringstream str() with C++20 move str()
...
No extra heap allocation/copy.
2025-02-05 22:38:48 +10:00
Stenzek
70c45f7cf8
GPU/TextureCache: Handle replacements larger than 256x256
...
I left this unfinished because it was a pain...
2025-01-28 17:36:00 +10:00
Stenzek
d7c78eedce
GPU/HW: Fix box downsampling on OpenGL ES
2025-01-28 15:59:35 +10:00
Stenzek
df8822760a
GPU/HW: Further tweaks to replacement alpha handling
...
We can't simply clear the alpha channel unconditionally here, because that
would result in any black pixels with zero alpha being transparency-culled.
Instead, we set it to a minimum value (2/255 in case of rounding error, I
don't trust drivers here) so that transparent polygons in the source still
set bit 15 to zero in the framebuffer, but are not transparency-culled.
Silent Hill needs it to be zero, I'm not aware of anything that needs
specific values yet. If it did, we'd need a different dumping technique.
2025-01-23 12:12:58 +10:00
Stenzek
19ca9cb47d
GPU/HW: Use texture loads for native resolution
...
Hopefully work around sampling precision issues in older AMD drivers
and Mali Midgard if we're lucky. But I don't have anything this old
to verify with.
2025-01-21 20:15:07 +10:00
Stenzek
cd8a160d8d
GPU/HW: Clear alpha channel in opaque replacements
...
This is the value for bit15 in the framebuffer. Silent Hill
needs it to be zero, I'm not aware of anything that needs
specific values yet. If it did, we'd need a different dumping
technique.
2025-01-16 23:25:24 +10:00
Stenzek
d9c9b3038d
GPU/HW: Fix ROV depth being written with semitransparency
2025-01-09 21:21:12 +10:00
Stenzek
b9186139d0
GPU/HW: Use sized tristrips instead of fullscreen quads
2025-01-07 23:20:25 +10:00
Stenzek
c5bd4101b3
GPU: Refactor and simplify deinterlacing
...
Both HW and SW deal with half-height buffers coming in now.
2024-12-30 14:36:17 +10:00
Stenzek
8f19912c64
GPU/ShaderGen: Use sample instead of load at 1x as well
...
Consistency. Mali ends up ever-so-slightly faster with sample versus
texel loads, apparently.
Also fixes compile errors when using texture filtering on GLSL ES.
2024-12-13 14:36:21 +10:00
Stenzek
97700b85de
GPU/HW: Clear ROV depth on fill/copy/write
...
It wasn't being specified before, whoops.
2024-11-27 17:52:31 +10:00
Stenzek
be7a20fef2
GPU/TextureCache: Map replacement non-255 alpha to fully transparent
...
That way if during the scaling process you end up with interpolated
colours, the cutout alpha is preserved.
Ideally we'd blend it, but that tends to create more problems than it
solves on PSX.
2024-11-26 13:08:32 +10:00
Stenzek
57595c47af
GPU/TextureCache: Move replacement cache onto the GPU
...
And enforce a maximum. Should sort out the upload spam.
2024-11-25 19:37:28 +10:00
Stenzek
a804801a1b
GPU/HW: Support filtering with texture cache
2024-11-25 13:23:39 +10:00
Stenzek
0ae8fcced3
GPU/HW: Fix incorrect sampling at 1x with TC
2024-11-25 13:15:07 +10:00
Stenzek
d24e8fda83
GPU/HW: Only enable fbfetch/DSB when needed
...
Thanks Adreno...
2024-10-30 15:19:10 +10:00
Stenzek
dadc994ba8
GPU/HW: GLSL ES compile fix
2024-10-30 15:19:10 +10:00
Stenzek
6cf8ac340b
GPU/HW: Make copy/write shaders resolution independent
2024-10-27 15:15:20 +10:00
Stenzek
aa0c0068ce
GPU/HW: Move shadergen parameters to functions
2024-10-27 13:50:47 +10:00
Stenzek
52389f48a6
GPU/HW: Fix force-round-coords with texture cache
2024-10-05 13:06:43 +10:00
Stenzek
c740fd9e11
GPU/TextureCache: Disable bilinear page upscaling by default
...
And fix it.
2024-10-04 14:48:10 +10:00
Stenzek
0730a361a3
GPU/HW: Fix batch shader compiling with GLSL ES
2024-10-01 21:14:58 +10:00
Stenzek
e06f1f1002
GPU: Add hardware texture cache
2024-09-29 13:37:47 +10:00
Stenzek
fd8f97f4d3
GPU/HW: Fix adaptive downsampling
...
Also rewrite shaders to improve blurring around edges of 3D objects
(e.g. FF7).
As a trade-off, the background does blur slightly less, but (imo)
it looks better overall, since you'll notice the foreground being
blurred much more than the background.
2024-09-26 13:25:53 +10:00
Stenzek
986e207cff
GPU/HW: Make batch shaders independent on resolution
...
Almost a 6x reduction in *compressed* shader cache size.
2024-09-22 21:06:05 +10:00
Stenzek
f9941c3f68
GPU/HW: Reduce shader dependence on global constants
...
Step 1 of making resolution-independent shaders.
2024-09-22 21:06:05 +10:00
Stenzek
0538b95d9b
GPU/HW: Reduce number of shaders/pipelines in default config
...
~3x speedup in shader compile time on a cold cache.
2024-09-19 22:18:58 +10:00
Stenzek
7f4e5d55db
Misc: Update copyright headers
2024-09-01 22:08:31 +10:00
Stenzek
7df5764835
Data: Remove license-incompatible shaders
2024-09-01 20:01:34 +10:00
Stenzek
a2f98541b3
Misc: Slim down some header includes
2024-08-04 14:49:55 +10:00
Stenzek
2a617c505a
GPU/HW: Support using ROV for accurate blending
2024-07-23 14:46:06 +10:00
Stenzek
ef152c47a6
GPU/HW: Interpolate native texture coordinates when upscaling
2024-07-03 15:44:12 +10:00
Stenzek
34d5cdec96
GPU/HW: Expose depth buffer to internal postprocessing
2024-06-29 14:25:36 +10:00
Stenzek
1cb3e6bd49
ShaderGen: Support multiple render target output
2024-06-29 13:09:45 +10:00
Stenzek
34f20798a1
GPU/HW: Add separate 3D/2D (sprite) texture filtering
2024-06-17 15:56:56 +10:00
Stenzek
8455c9c3c6
GPU/HW: Add 'Force Round Upscaled Texture Coordinates'
2024-06-16 19:09:46 +10:00
Stenzek
1582b2ae5d
GPU/HW: Make texture filtering a fragment shadergen parameter
2024-06-16 19:09:46 +10:00
Stenzek
c1792108f4
GPU/HW: Eliminate raw texture pipeline permutations
2024-06-16 17:09:24 +10:00
Stenzek
ef69c31e9f
GPUDevice: Support transpiling shaders at compile time
...
And use it for GLSL postprocessing shaders.
2024-06-14 21:21:34 +10:00
Stenzek
74f3c8d1aa
GPU/HW: Enable feedback loops for rendering
2024-04-01 18:12:52 +10:00
Stenzek
e70f0e1bc1
GPU/HW: Use texelFetch() instead of sampler
2024-03-20 21:56:20 +10:00
Stenzek
1ab7850ed0
GPU: Rewrite deinterlacing and add adaptive/blend modes
2024-03-16 14:14:15 +10:00
Stenzek
687e212dfe
GPU/HW: Shader compile fix
2024-01-20 02:14:36 +10:00
Hugo Locurcio
cc94b76037
Add debanding option to improve gradient smoothness with truecolor
...
This option only has an effect if true color is also enabled.
2024-01-19 01:05:21 +01:00
Stenzek
e86cf51a48
GPU/HW: Handle palette VRAM wrapping
...
Fixes block colours in The Next Tetris.
2024-01-13 13:54:51 +10:00