Henrik Rydgård
c75784351b
Merge pull request #14859 from unknownbrackets/vertexcache-gles
...
GLES: Re-enable vertex cache
2021-10-19 08:02:03 +02:00
Unknown W. Brackets
12ad2b05ef
GPU: Blit framebuf depth on create too.
...
Before we only did it for an existing target framebuffer, and never for a
fresh one. But there's not really a good reason to skip that, and this
may improve effects that are cemented after a single frame.
2021-10-17 21:53:23 -07:00
Unknown W. Brackets
9306bbd4e4
GPU: Refactor framebuffer depth blit for reuse.
...
Shouldn't change anything yet, just moving logic around.
2021-10-17 21:51:45 -07:00
Unknown W. Brackets
24c77dc937
GPU: Fix matrix uvgen in software transform.
...
Fixes #15015 .
2021-10-16 23:41:24 -07:00
Unknown W. Brackets
3e9d1e0b00
GLES: Re-enable vertex cache.
...
Was accidentally left disabled during GL threading effort.
2021-10-12 20:41:18 -07:00
Unknown W. Brackets
275baccc5b
GLES: Support GL_APPLE_clip_distance too.
...
Seems modern Apple mobile chips only support clip.
2021-10-12 20:34:44 -07:00
Unknown W. Brackets
33598f2e75
GPU: Support clip and cull distances separately.
...
Older GL devices, and it seems Apple devices, may not support cull.
2021-10-12 20:34:44 -07:00
Unknown W. Brackets
7b00c4a572
GPU: Move Z/W equal hack to bugs from supports.
...
It's really a bug (might even ideally cap the version?), and we already
have other bugs handled the same way.
2021-10-12 20:34:44 -07:00
Unknown W. Brackets
5e6f54033e
GPU: Split clip and cull caps.
...
GL_ARB_cull_distance is needed, sometimes available on older GL.
2021-10-12 20:34:43 -07:00
Unknown W. Brackets
c6a52909f9
D3D11: Support vertex clip/cull planes.
2021-10-12 20:34:43 -07:00
Unknown W. Brackets
1a603fedf5
Vulkan: Cull verts fully outside depth.
...
Following PSP rules of -1 to 1 pre-viewport Z. This also enables it for
GLES/OpenGL.
2021-10-12 20:34:43 -07:00
Unknown W. Brackets
7d00b6ca90
GLES: Enable/disable clip distance 0.
2021-10-12 20:34:42 -07:00
Unknown W. Brackets
046a5c548b
GLES: Check clip/cull distance support.
...
Pretty limited on GLES3+. Also D3D11.
Seems like doing it on D3D9 might be a bit tricky.
2021-10-12 20:34:42 -07:00
Unknown W. Brackets
2271b41d07
Vulkan: Use clip distance only if supported.
2021-10-12 20:34:42 -07:00
Unknown W. Brackets
273b9a3dc1
Vulkan: Add negative Z clipping.
2021-10-12 20:34:42 -07:00
Unknown W. Brackets
24011c3754
GPU: Correct depth handling for guardband.
...
This culls based on pre-viewport Z and avoids culling based on the clip
range at negative Z.
2021-10-12 20:34:41 -07:00
Unknown W. Brackets
6252241c0f
GPU: Verify throughmode for clears/rects.
2021-10-12 20:34:41 -07:00
Unknown W. Brackets
4ac36cb810
GPU: Cull rectangles more when depth clamp off.
...
If any vert is outside Z, it's culled when not clamping/clipping.
2021-10-12 20:34:41 -07:00
Unknown W. Brackets
5315c404c5
GPU: Cull rectangles outside valid Z.
...
Both TL and BR must be outside in the same direction to be culled when
depth clamp is enabled.
2021-10-12 20:34:41 -07:00
Henrik Rydgård
14bf5de83c
Merge pull request #14994 from hrydgard/more-crash-fixes
...
More crash fixes
2021-10-08 22:56:08 +02:00
Henrik Rydgård
e57770977b
We don't use primitiveRestart for anything, let's not enable it. It has costs on some hardware.
2021-10-08 22:22:08 +02:00
Henrik Rydgård
d7ac6aa63d
Fix an assortment of minor VK barrier bugs in mostly texture upload
2021-10-08 21:58:03 +02:00
Henrik Rydgård
b426d12a17
More best-practices adjustments
2021-10-08 21:32:40 +02:00
Henrik Rydgård
ddc0f0829b
Replaced textures: Don't leak handles on failure, check allocation success
2021-10-08 19:09:43 +02:00
Henrik Rydgård
59ac4d3e27
Vulkan: Rework mipmap generation and its image barrier/layout handling.
...
Fixes bugs on mobile with texture scaling + auto max quality texturing
(since that generates mipmaps with blits from an image which was just generated from
compute, making proper barriers very critical).
2021-10-05 22:50:49 +02:00
Henrik Rydgård
887f6101d5
Remove the "Auto" texture scale factor. It's a performance trap and not really useful.
2021-10-05 20:41:40 +02:00
Unknown W. Brackets
b1009f70f9
softgpu: Allow end coordinate at bounds.
...
Oops, was excluding some valid usage that wouldn't wrap.
2021-09-30 06:33:25 -07:00
Unknown W. Brackets
953916a842
softgpu: Avoid fast path for clamp/wrap cases.
...
It doesn't clamp or wrap, and those are uncommon for the fast path.
Fixes #14951 .
2021-09-29 19:19:21 -07:00
Henrik Rydgård
992ad801e7
Add a crude way to blacklist post/texture shaders from certain vendors.
...
Use it to work around #14530 for now.
2021-09-28 23:39:52 +02:00
Unknown W. Brackets
2d9719ed26
TexCache: Avoid hashing videos at all in lazy mode.
2021-09-19 07:35:25 -07:00
Unknown W. Brackets
e2c7366c92
TexCache: Prevent lazy cache on video textures.
2021-09-19 07:31:31 -07:00
Unknown W. Brackets
c755dedbf6
Merge pull request #14842 from unknownbrackets/texfilt
...
Vulkan: Expand 16-bit textures to generate mips
2021-09-13 07:26:43 -07:00
Unknown W. Brackets
c37c078254
Vulkan: Only force 32-bit if needed.
...
If there are mips already, we can keep 16-bit.
2021-09-13 00:07:01 -07:00
Unknown W. Brackets
d9f62d690a
Vulkan: Expand 16-bit textures to generate mips.
...
When using "Auto Max Quality", we can't use 16-bit formats.
See #14804 .
2021-09-13 00:03:42 -07:00
Unknown W. Brackets
6762903087
TexCache: Correct confusing red/blue var names.
...
This decodes to RGBA (R least significant), so it's confusing to refer to
it as BGRA. It's actually the 565 colors in the DXT data that are BGR.
2021-09-12 17:21:45 -07:00
Unknown W. Brackets
08816a544d
softgpu: Implement DXT5 in samplerx86.
2021-09-12 17:17:09 -07:00
Unknown W. Brackets
c4de5bfb9f
softgpu: Implement DXT3 in samplerx86.
2021-09-12 14:53:55 -07:00
Unknown W. Brackets
ee9d19430f
softgpu: Implement DXT1 decoding in samplerx86.
2021-09-12 13:57:28 -07:00
Unknown W. Brackets
a0eeb52444
softgpu: Decode DXT texels directly.
...
This improves performance a lot compared to decoding the whole block.
Eventually we may implement a cache, but threading makes that complex to
make properly fast.
2021-09-12 09:37:34 -07:00
Unknown W. Brackets
1ee5352d3e
TexCache: Correct DXT5 alpha calculation.
...
This matches PSP alpha values from an exhaustive test.
2021-09-12 09:35:53 -07:00
Unknown W. Brackets
121c56e6db
softgpu: Clip only on -Z, cull if entirely outside.
...
This is important for several issues, like #12058 or #12060 , where
something is drawn entirely outside valid Z, and should be culled.
2021-09-09 20:13:42 -07:00
Unknown W. Brackets
0b73c1ce83
softgpu: Correct guardband cull behavior.
...
Culling is based on whether clipping happens, not whether clamping
happens. This is important for issues like #12348 .
2021-09-09 20:05:41 -07:00
Henrik Rydgård
5876388c65
Vulkan scissor fix (validation errors).
2021-09-10 01:15:29 +02:00
Stuart Kenny
f442f4012c
Expose texture shader core option.
2021-09-08 16:42:11 +01:00
Henrik Rydgård
5dab9994b6
Bezier/Spline: Fix logical error (must flush buffered data before we modify submitType).
...
Should fix #14774
2021-09-07 23:52:06 +02:00
Henrik Rydgård
e2b0137400
VK: Only autogenerate mipmaps for R8G8B8A8 format textures.
...
Quickfix for bug with Auto High Quality texture filtering.
Fixes #14804 (good enough for now at least).
2021-09-07 23:41:03 +02:00
Unknown W. Brackets
b5ba469826
softgpu: Prevent pixel gaps when drawing sprites.
...
If you end a sprite at 255.9, it draws the pixel at 255. This uses the
same logic to handle that as in the triangle path.
2021-09-06 22:05:39 -07:00
Henrik Rydgård
b5e8e22dc9
Merge pull request #14789 from hrydgard/auto-max-quality-texfilter
...
Add new texture filtering mode "Auto Max Quality"
2021-09-07 00:58:48 +02:00
Unknown W. Brackets
7addc18a6b
softgpu: Avoid overflow infinite loop.
...
For certain large values, it would overflow and continue looping
endlessly.
2021-09-05 23:24:08 -07:00
Henrik Rydgård
1df31e9304
Fix windows menus for the new tex filtering options.
2021-09-05 23:54:41 +02:00