421 Commits

Author SHA1 Message Date
Henrik Rydgård 87a16b0386 Fix the stats 2023-03-15 10:19:00 +01:00
Henrik Rydgård 089b63c22f Address feedback, except the stats. 2023-03-15 10:09:39 +01:00
Henrik Rydgård 2ac74e3d37 Remove the PushBufferType enum 2023-03-15 09:59:00 +01:00
Henrik Rydgård 181ddf8266 Change the API of the old VulkanPushBuffer to match VulkanPushPool. 2023-03-15 09:56:32 +01:00
Henrik Rydgård 6d3a25e81f Tweak some sizes. 2023-03-15 01:25:03 +01:00
Henrik Rydgård 9fcd6d6612 Use thin3d's push pool in the draw engine too. 2023-03-15 01:25:03 +01:00
Henrik Rydgård 700b1cd6a7 More conversion to pushPool 2023-03-15 01:25:03 +01:00
Henrik Rydgård 3d372400e1 Start converting over to it 2023-03-15 01:25:03 +01:00
Henrik Rydgård 72bed6f2b5 Some DeviceLost/DeviceRestore cleanup 2023-02-26 11:05:52 +01:00
Henrik Rydgård af2fd7b038 Move Vulkan clear detection logic into DrawEngine like the other backends. 2023-02-25 19:23:07 +01:00
Unknown W. Brackets 1c8bedbed9 Vulkan: Align for all Apple devices, not just M1. 2023-01-18 07:28:12 -08:00
Unknown W. Brackets 8d4007ce3f Vulkan: Force align verts to 4 on Apple devices. 2023-01-18 07:24:18 -08:00
Henrik Rydgård 784e8ab782 Fix a race condition during Vulkan shader cache load.
Could lead to unnecessary pipelines being created.
2023-01-13 10:35:04 +01:00
Henrik Rydgård 1cfc7b11b8 Only force indexed draws on PowerVR / Vulkan. 2023-01-11 22:59:30 +01:00
Henrik Rydgård beed3c06d2 Vulkan: Don't use non-indexed draws for pure tristrips and fans, creates extra pipelines.
Bump shader cache version
2023-01-11 22:57:23 +01:00
Henrik Rydgård 85e6b4e592 Increment numFlushes near the other stat increments
Might be better for the cache, heh.
2023-01-04 17:10:56 +01:00
Henrik Rydgård f069de2dd2 Pass the vertex decoder into the vertex shader IDs generator
Instead of just the vertex type.

This will allow things like the vertex decoder supplying defaults, in
order to reduce the number of unique vertex shaders at the cost of
slightly larger vertex data.

This doesn't actually do that yet though, it's just a refactor that can
be done separately.

Part of #16567
2022-12-30 22:57:05 +01:00
Unknown W. Brackets 49f6c461ad Reporting: Fix some header includes.
Particularly in Common, avoid including Core/Reporting.h.
2022-12-27 14:58:20 -08:00
Unknown W. Brackets e5dbdba638 GPU: Keep prevPrim_ set on flush.
For continuing previous verts, see #16612.  We still don't handle these
quite accurately (outside software rendering), but this should be better.
2022-12-18 07:14:19 -08:00
Henrik Rydgård 26884150d7 Remove the 0th descriptor set, move everything else back to 0 2022-12-16 13:05:40 +01:00
Henrik Rydgård 11366a2ded Don't refer directly to g_Config.iMultiSampleLevel, it can contain unsupported modes. 2022-12-14 16:43:37 +01:00
Henrik Rydgård 41e5b1e95a Plumb through multiSampleLevel so PipelineManager doesn't read config. 2022-12-14 16:43:37 +01:00
Henrik Rydgård 80a0c97e9e Drop the input attachment descriptor from the layout when unused 2022-12-13 15:17:39 +01:00
Henrik Rydgård 331d024a8c Add a flags parameter to InvalidateCachedState and rename it Invalidate.
Also rename the old InvalidationFlags enum to InvalidateCallbackFlags.
2022-12-01 19:15:38 +01:00
Henrik Rydgård 3dd45c6561 Can't forget the texture in the callback, breaks texture-from-framebuffer-copy.
Was probably redundant anyway.
2022-11-24 11:02:21 +01:00
Henrik Rydgård 70d1d8fa07 Replace the "GetCurrentStepId"-based state invalidation with callbacks 2022-11-24 10:52:42 +01:00
Henrik Rydgård 8f103f3f47 Extract the Vulkan descriptor binding cleanup from #16345 2022-11-21 20:30:20 +01:00
Unknown W. Brackets 70c3205564 GPU: Correct equal depth checks. 2022-11-09 20:34:29 -08:00
Unknown W. Brackets 1c0a37f252 GPU: Correct vertex decoder in software transform.
It was meant to flip to skin in decode.
2022-11-09 07:07:39 -08:00
Unknown W. Brackets 3333f2a5aa GPU: Avoid clears for non-simple depth values.
Some drivers don't round depth the same way for a clear vs for drawing,
which can cause mismatches.  We only do this if we see equals-style depth
comparison funcs used in drawing.
2022-11-08 20:06:08 -08:00
Henrik Rydgård 41c812651d Merge pull request #16347 from unknownbrackets/softgpu-skin
Always skin in decode for software transform and rendering
2022-11-06 20:21:02 +01:00
Unknown W. Brackets 3de2557ecb GPU: Always skin in decode for software transform. 2022-11-06 08:55:07 -08:00
Unknown W. Brackets 6c36f03a0d GPU: Purify vertTypeIsSkinningEnabled(). 2022-11-06 08:40:54 -08:00
Henrik Rydgård ad6725b684 VK/D3D11: Move the rarely used "u_rotation" uniform to the frame uniform buffer.
This uniform is used in two cases:

* Non-buffered rendering in Vulkan, software transform
* Non-buffered rendering in D3D11 level 9 on Windows Phone, software transform
  - which I don't think anyone builds for anymore

Nice to not have it in the main uniform buffer, but mainly a
demonstrator/test of moving stuff to the new frame-global buffer, and
setting up the infrastructure.
2022-11-05 22:14:05 +01:00
Henrik Rydgård c6fe91224a Vulkan: Fixes validation errors with "null" textures
These arise in non-buffered rendering when we don't have a framebuffer
to texture from.
2022-10-28 18:40:55 +02:00
Henrik Rydgård d9cfcf215e Need to request the proper type of uniform buffer descriptors.
Otherwise, assert on Mali.
2022-10-28 10:20:47 +02:00
Henrik Rydgård ab1cebec51 Actually bind a global uniform buffer, too. Not yet used. 2022-10-28 10:15:36 +02:00
Henrik Rydgård 96a5c52037 Vulkan: Reserve descriptor set 0 for frame-global data, move everything else to set 1 2022-10-28 09:39:56 +02:00
Henrik Rydgård 31fd928a5c Name more image views. Very useful with a little patch to the Vulkan debug layers. 2022-10-27 11:05:59 +02:00
Henrik Rydgård 0de12f5ca9 Some refactoring of framebuffer views, layer issues, more work. 2022-10-27 11:05:58 +02:00
Henrik Rydgård fb250c4b29 More multiview work 2022-10-27 11:05:58 +02:00
Henrik Rydgård 9b8a5d1db3 Rename GPU_SUPPORTS_ to GPU_USE_ 2022-10-17 08:47:03 +02:00
Henrik Rydgård daca0b2109 Rename gstate_c.Supports to gstate_c.Use 2022-10-17 08:46:37 +02: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 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 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 ac7ca963db Make valgrind happy 2022-09-23 12:24:43 +02:00
Henrik Rydgård 262a306b9a Flag shader blending as broken on Adreno for now. 2022-09-16 19:19:42 +02:00
Henrik Rydgård 5f5277a409 Need to have input attachments in the descriptor pool. 2022-09-16 19:19:42 +02:00
Henrik Rydgård ce82fce8de Use subpass dependencies to implement shader framebuffer read in Vulkan. 2022-09-16 19:19:42 +02:00