Henrik Rydgård
3de70aa71e
Depal from dynamic CLUT: When detecting bounds, be more conservative.
...
Followup to #16188 .
Further fixes the lens flare.
It confused me before that there are two sections of the track on
Sunset Drive where the sun is visible, but only on the second is the
lens flare sprite actually shown, which is rather weird.
Verified that exactly the same thing happens on hardware, so it's not a
glitch!
2022-10-09 20:53:28 +02:00
Henrik Rydgård
9422b05ee3
Fix depal bounds with dynamic CLUT. Fixes lens flare glitches in Ridge Racer
...
With this wrong, we ended up drawing pixels that came from a DONT_CARE
init of the depal temp buffer, which was a pile of garbage on Android
and blank on PC.
Now, we seem to end up not drawing anything because the depal operation
results in transparent black into whatever is actually intended, but at
least the screen isn't full of glitches when the sun is visible on Adreno.
See issue #16083
2022-10-09 20:27:45 +02:00
Henrik Rydgård
28bc45451c
Merge pull request #16184 from unknownbrackets/depth-download
...
GPU: Hook Gods Eater Burst avatar read
2022-10-09 16:37:42 +02:00
Henrik Rydgård
49de375bff
Merge pull request #16183 from unknownbrackets/depth-usage
...
GPU: Ignore depth when masked and ALWAYS
2022-10-09 10:41:40 +02:00
Unknown W. Brackets
ad3220f857
GLES: Hook up depth download.
...
Currently, only used by one hook.
2022-10-09 01:08:04 -07:00
Unknown W. Brackets
bc84d6345b
Vulkan: Disable geometry shaders for Mali <= 18.
...
These drivers apparently have some weird behavior.
2022-10-09 00:57:10 -07:00
Unknown W. Brackets
d0eb14ec02
GPU: Correct sizing account on block transfer.
2022-10-09 00:54:59 -07:00
Unknown W. Brackets
e7e7528fbc
GPU: Consider depth buffers in block transfer.
...
Right now, only with an explicit flag (not yet used.)
2022-10-09 00:50:45 -07:00
Unknown W. Brackets
b2ce4d2c3f
GPU: Refuse to set fb_address == z_address.
...
We don't do it when creating framebufs either, so don't update to
matching values.
2022-10-08 17:50:18 -07:00
Unknown W. Brackets
7d331f1928
GPU: Ignore depth when masked and ALWAYS.
...
Seen in NFS Pro Street, for example. Shouldn't be interpreted as depth
usage.
2022-10-08 17:49:25 -07:00
Unknown W. Brackets
157ffed57f
D3D9: Add simple rendered CLUT handling.
...
I think there's still a deeper half-pixel offset issue, but this fixes
Brave Story.
2022-10-08 15:36:36 -07:00
Henrik Rydgård
bf25f4b283
Shader uniforms (VK/D3D11): Fix issue where we could overwrite the fourth component padding.
2022-10-06 10:52:58 +02:00
Unknown W. Brackets
3aa863ec41
GPU: Clip against neg Z even w/o cull support.
...
This should fix rendering issues on Apple devices.
2022-10-06 00:34:02 -07:00
Henrik Rydgård
87d00f79da
Merge pull request #16165 from unknownbrackets/geo-shader
...
Vulkan: Clip clamped depth in geometry shader
2022-10-06 09:18:08 +02:00
Henrik Rydgård
3da1b46104
Merge pull request #16166 from unknownbrackets/hwtess
...
GPU: Verify generated shader buffer length
2022-10-06 08:24:46 +02:00
Unknown W. Brackets
aee2ad46a2
GPU: Verify generated shader buffer length.
...
Hardware tessellation + uberlighting + clamp was exceeding the buffer,
causing memory corruption. Let's try to catch it, but also increase
buffers to be safe.
2022-10-05 21:41:09 -07:00
Unknown W. Brackets
bc3d3cf9fb
GPU: Optimize clip distances needed.
...
We only need to write one clip distance to clip clamped depth, since we
don't clamp when it needs clipping on both sides.
2022-10-05 21:17:17 -07:00
Unknown W. Brackets
14bf9d1923
Vulkan: Correct clamped Z clip when clipping neg Z.
...
In the geometry shader, if used, we need to output the clip distance from
the clamped Z clip or it gets lost.
2022-10-05 20:48:38 -07:00
Unknown W. Brackets
8663541403
Vulkan: Avoid max_vertices=12 if unnecessary.
2022-10-05 20:11:10 -07:00
Unknown W. Brackets
3e5c09d432
Vulkan: Clip clamped depth in geometry shader.
...
This corrects deformed geometry on Mali devices which don't support
user-space clipping but do support depth clamp.
2022-10-05 19:41:59 -07:00
Henrik Rydgård
d6bd08cae7
Merge pull request #16162 from unknownbrackets/geo-shader
...
Implement negative Z clipping in geometry shader
2022-10-06 01:00:41 +02:00
Unknown W. Brackets
5d88e50201
Vulkan: Generate indices in clipping.
2022-10-04 23:04:25 -07:00
Unknown W. Brackets
f24edbe8a8
Compat: Remove DisableRangeCulling.
...
This hack was used because culling previously incorrectly handled Z, which
was fixed in #14833 .
2022-10-04 22:19:40 -07:00
Unknown W. Brackets
8025def8d2
Vulkan: Clip to neg z in the geometry shader.
...
This is only used when clip distance is unsupported, such as on Mali.
2022-10-04 22:10:24 -07:00
Henrik Rydgård
362391b9d8
Fix Kurohyou again. See #9576
2022-10-04 20:56:41 +02:00
Henrik Rydgård
b333695cd1
Merge pull request #16160 from unknownbrackets/vram-mirrors
...
GPU: Use flags to fix triggered upload/download
2022-10-04 08:45:06 +02:00
Unknown W. Brackets
9ac4523fd2
GPU: Skip matching a framebuf for RAM.
2022-10-03 20:22:27 -07:00
Unknown W. Brackets
a1efed31b9
GPU: Use flags to fix triggered upload/download.
...
No longer using mirror hacks.
2022-10-03 20:17:25 -07:00
Henrik Rydgård
1469a32a9d
Vertex decoder: Add fallback for non-SSE4.1
...
See #16157
2022-10-03 19:06:17 +02:00
Henrik Rydgård
973d0435c1
Fix another crash with non-buffered rendering
2022-10-03 19:02:16 +02:00
Henrik Rydgård
ed3cd1dc26
Merge pull request #16150 from unknownbrackets/vram-mirrors
...
GPU: Mask away unused bits in framebuf/zbuf ptr, cleanup
2022-10-03 11:56:24 +02:00
Herman Semenov
29b87e0c0b
Merge branch 'master' into master
2022-10-03 07:49:13 +00:00
Unknown W. Brackets
0be891c7ff
softgpu: Minor opt, ignore unused z_stride.
2022-10-02 21:31:07 -07:00
Unknown W. Brackets
58a4376998
GPU: Normalize framebuf addresses.
...
In VRAM, always store without mirror. In RAM, always store without
cache/kernel bits.
2022-10-02 21:28:53 -07:00
Unknown W. Brackets
73040ebb8f
GE Debugger: Ignore mirrors for target in record.
2022-10-02 20:48:28 -07:00
Unknown W. Brackets
4a17ab8070
GE Debugger: Correct mask in target breakpoints.
2022-10-02 20:47:12 -07:00
Unknown W. Brackets
b9b59f7806
GPU: Mask away unused bits in framebuf/zbuf ptr.
...
Lower 4 bits are ignored during rendering, and mirrors (even even the 8
bit at the top) are ignored.
2022-10-02 20:44:35 -07:00
Unknown W. Brackets
4df7a8f357
Vulkan: Cleanup unused geometry shader vars.
...
Without clipping, these aren't used (but could be in the future with
manual clipping.)
2022-10-02 07:43:35 -07:00
Unknown W. Brackets
2832edcc37
Vulkan: Allow configuring geometry shaders on/off.
2022-10-02 07:42:22 -07:00
Unknown W. Brackets
8df956b036
Vulkan: Block geometry shaders on older Mali.
...
They're too slow to be usable.
2022-10-02 07:42:22 -07:00
Unknown W. Brackets
36eb0d9ad5
Vulkan: Use geo clip distance only where supported.
...
It might be supported without cull or GS. Otherwise we may need to clip
the triangles manually.
2022-10-02 07:42:22 -07:00
Unknown W. Brackets
2ce0cda333
Vulkan: Enable geo shader for culling.
...
The compat setting was really for some previously buggy cases that
couldn't work without cull.
2022-10-02 07:42:22 -07:00
Unknown W. Brackets
bfaa304461
Vulkan: Correct geometry shader culling.
2022-10-02 07:42:17 -07:00
Henrik Rydgård
ac248338be
Vulkan: Cull in geoshader, hack to on for now.
2022-10-02 07:42:17 -07:00
Henrik Rydgård
cdee10fe86
Vulkan: Basic geoshader code generation.
2022-10-02 07:42:17 -07:00
Unknown W. Brackets
fbdb278168
Vulkan: Update shader cache format for geo shaders.
2022-10-02 07:42:16 -07:00
Unknown W. Brackets
d16caa71af
Vulkan: Add geometry shader ID tracking.
...
We're still not generating them, yet. But this tracks the objects and
IDs through the pipeline.
2022-10-02 07:42:16 -07:00
Unknown W. Brackets
38e16324f0
Vulkan: Clean up shader module tag.
2022-10-02 07:42:16 -07:00
Unknown W. Brackets
878a049f60
GPU: Add dirtying for geo shader state.
...
Not yet used, but dirtied at the right times.
2022-10-02 07:42:16 -07:00
Henrik Rydgård
b36bfc37d5
Merge pull request #16139 from hrydgard/tighten-up-format-checks
...
Tighten up some color format checks with displays and copies
2022-10-02 15:39:51 +02:00