Commit Graph
761 Commits
Author SHA1 Message Date
Henrik Rydgård 0530dc57a8 Implement frame time measurement on Android using VK_GOOGLE_display_timing 2023-08-03 12:59:25 +02:00
Henrik Rydgård 9b038d6574 Vulkan: Show enabled extensions separately in sysinfo 2023-08-03 11:11:35 +02:00
Henrik Rydgård e16cac6548 Initial work on supporting VK_GOOGLE_display_timing. Not working yet. 2023-08-03 11:11:16 +02:00
Henrik Rydgård 1a1a6fe15d Load the functions for VK_GOOGLE_display_timing 2023-08-03 09:52:48 +02:00
Henrik Rydgård 14377259b5 Use VK_KHR_present_wait to get numbers on how much latency we have to screen
This extension is not available on Android, there they have
VK_GOOGLE_display_timing, which they also have an abstraction library
for, so will look at that later.

Early part of work on #17685
2023-08-02 20:34:22 +02:00
Henrik Rydgård cda59e8510 Vulkan: Keep track of some timestamps in a frame 2023-08-02 16:25:17 +02:00
Henrik Rydgård b118e25b6a Vulkan: Make multithreaded rendering an option.
Multi-threaded rendering is good for smoothing out performance spikes
and increasing performance on low-power devices. However, the way we use
it it doesn't benefit latency (input lag) at all, rather the opposite.

So make it an option.
2023-07-23 22:06:01 +02:00
Henrik Rydgård 8f6662aa55 Fix an initialLayout issue with the image we use as the backbuffers's depth 2023-07-21 23:17:24 +02:00
Henrik Rydgård 1c83c4a1fe Vulkan: Enable the present-id/present-wait/display-timing extensions
Doesn't actually use any of them yet, just making sure enabling them
doesn't cause any weird issues. They will be used for the future display
timing rewrite.
2023-07-14 10:43:47 +02:00
Henrik Rydgård c17b84b3d4 Implement RetroAchievements challenge mode restrictions, and fix related bugs 2023-07-08 21:55:32 +02:00
Henrik Rydgård ae29fd2951 Vulkan profiler: Show CPU command buffer recording timing even if GPU timing is unavailable 2023-06-14 09:15:29 +02:00
Henrik Rydgård 6d8069dfd1 Vulkan: Remove the remains of the input attachment experiment
Haven't been using these for a while.

I've come to the conclusion here that I think it's better to try to
deal with the issues using safe workarounds like copies, instead of
relying on features with somewhat iffy driver support that are not
universal across APIs anyway.
2023-06-13 20:46:27 +02:00
Henrik Rydgård d90671e877 Add some comments. 2023-06-12 13:16:13 +02:00
Henrik Rydgård e9e95d23ce VulkanDebug log fix, reduce log spam 2023-05-30 18:32:33 +02:00
Henrik Rydgård 49ecc01556 Fix image leak bug when pausing and we're just displaying a framebuffer in memory 2023-05-30 18:29:50 +02:00
Henrik Rydgård 364c205d95 Quick, suboptimal barrier fix for the new UpdateImageLevels functionality 2023-05-30 18:29:49 +02:00
Henrik Rydgård 7c4b9bac90 Cache textures created by MakePixelsTexture and reuse where appropriate. 2023-05-30 14:07:44 +02:00
Henrik Rydgård 0b1abf1de9 Add untested UpdateTextureLevels functionality to three of the four backends 2023-05-30 13:28:04 +02:00
Henrik Rydgård f54f905be5 Vulkan: Remove support for other index types than 16-bit.
We don't have any use for them anyway.
2023-05-30 10:15:34 +02:00
Henrik Rydgård 0eec89c853 Fix a very tiny memory leak 2023-05-29 23:11:35 +02:00
Henrik Rydgård 5eb94350fa Show the class name in refcount debug asserts 2023-05-29 12:50:45 +02:00
Henrik Rydgård dfb446f89d Allow other backends than Vulkan to have GPU memory stats. Implement for GL. 2023-05-24 14:33:01 +02:00
Henrik Rydgård f1f0bfae2d Driveby simplification, reduce logspam 2023-05-23 17:09:40 +02:00
Henrik Rydgård 234c1f05b8 Apply the same optimizations to the Vulkan backend. Smaller effect than for OpenGL. 2023-05-23 08:54:41 +02:00
Henrik Rydgård 0b9dfac844 Make sure VKRRenderThreadTask isn't copied. 2023-05-23 08:54:41 +02:00
Henrik Rydgård cf9a628a2e AndroidContentURI: Move code from the header to cpp. Some assorted cleanup, add a unit test for Download paths 2023-05-16 16:08:51 +02:00
Henrik Rydgård 0d0b0fc60b Turn some reported crashes into asserts, to try to confirm what's going on 2023-05-05 23:26:21 +02:00
Henrik Rydgård 38178d34b5 Sanity checks in InitSwapchain 2023-05-05 00:03:20 +02:00
Henrik Rydgård 7e1f907826 VulkanPushPool: Sprinkle a couple of asserts. 2023-05-04 10:25:16 +02:00
Henrik Rydgård 2cca0b265e Vulkan: Turn off the ubershader on T880, T860 and T830 on old driver versions. 2023-05-03 11:53:32 +02:00
Henrik Rydgård 97488c0a79 Vulkan: Before cleaning the shader managers, drain the shader compile queue.
Mainly paranoia, but might help with the mutex crash from #17364
2023-05-02 22:05:28 +02:00
Henrik Rydgård d4249c1d73 OpenGL: Add an assert to catch a class of crash bugs early. Also assorted paranoia. 2023-05-01 11:56:26 +02:00
Henrik Rydgård a41fc74dba Add a debug assert in VulkanPushPool 2023-05-01 11:41:25 +02:00
Henrik Rydgård 42ce619705 Vulkan fastforward: Check the current presentation mode instead of the Vsync setting.
After 1.15, I'm gonna clean up the presentation mode/vsync management
across the code base. This works around #17308 for now.
2023-04-26 12:02:42 +02:00
Henrik Rydgård c81ec8c74d List Vulkan present modes in system info, show the current one 2023-04-20 00:21:06 +02:00
Henrik Rydgård f376f3cb5f Another piece of the fix for #17250 (opensuse build error) 2023-04-09 16:57:39 +02:00
Henrik Rydgård 42efc08e64 Couple buildfixes after the g_display refactoring
Should help #17250
2023-04-08 09:25:16 +02:00
Henrik Rydgård 9ae1e10a1b Texture upload: Correct the initial barrier before upload.
Validation caught some weirdness here.

Might possibly help #14774 ?
2023-04-01 23:48:24 +02:00
Henrik Rydgård 885415949e Vulkan: Fix ordering of debug labels, fixing a new validation error. 2023-04-01 23:29:30 +02:00
Henrik Rydgård b13c5c2d1b Add compat setting to force using maximum depth resolution
Fixes #17014

Even if our depth-testing-equal heuristic believes that the game needs
lower depth resolution.

This removes some depth-fighting artifacts (that are present on the real
PSP, but nice to avoid) in Outrun, Split/Second and Cars: Race-o-Rama -
essentially reverting these to the behavior we had before the heuristic.

(The heuristic is good though - it means less compat.ini hacks going in
the other direction).

In the case of Outrun, this relies on two passes that pass exactly the
same vertex coordinates twice resulting in the exact same final
geometry. This is actually guaranteed by the spec if the vertex math is
exactly the same and "invariant" is set on the position output, though
I guess you never know.. Haven't seen any issues at least.

Also sneak in disabling some validation messages from using extra Vulkan
validation layers other than the default.
2023-03-26 00:27:58 +01:00
Henrik RydgårdandGitHub ae8c804328 Merge pull request #17134 from hrydgard/more-replacement-work
Refactor the replacement cache
2023-03-16 12:37:48 +01:00
Unknown W. Brackets de4eb64298 Build: Fix MSVC 2019 again. 2023-03-15 21:28:46 -07:00
Henrik Rydgård 34926472aa Log fix 2023-03-16 00:30:20 +01:00
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 f3bdf324f9 Garbage collect old buffers in push pool. 2023-03-15 01:25:03 +01:00
Henrik Rydgård c8b25e50b0 Better debug vis for push pools 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