Commit graph

52 commits

Author SHA1 Message Date
Henrik Rydgård
d125fa00e1 Make sure the renderpass cache hashmap is never accessed from the main thread at runtime. Should help #10811 2018-03-27 14:45:41 +02:00
Henrik Rydgård
2d3655ea23 Vulkan: Get rid of more explicit barriers by merging the finalLayout color transitions into renderpasses. 2018-03-18 12:03:23 +01:00
Henrik Rydgård
6d5f0665fe Add a super focused workaround for the Mali bug, see #10723
Minimizes the performance penalty.
2018-03-18 11:20:45 +01:00
Henrik Rydgård
f43935b030 Merge framebuffer layout pre-transitions into render pass subpass dependencies.
With this, drivers should be able to completely get rid of layout
transitions into render passes that use CLEAR, at least.
2018-03-18 09:55:36 +01:00
Henrik Rydgård
33a1e6a080 Vulkan Clear-renderpass merging: If a copy step is found that reads from the affected buffer, don't merge the clear into the later renderpass. 2018-03-18 09:44:00 +01:00
Henrik Rydgård
c5ebb2d73f Oops, remove logging 2018-03-16 14:58:45 +01:00
Henrik Rydgård
a08464eb77 Vulkan: Also check for empty clearing renderpasses later in the frame. 2018-03-16 14:57:41 +01:00
Henrik Rydgård
df8dac4aae If the first renderpass is an empty clear, merge it into the next one that touches the same framebuffer. Works around #10723 in Wipeout. 2018-03-16 13:44:56 +01:00
Henrik Rydgård
3cd92b4d90 Vulkan: Add a (disabled) facility to force image layouts to GENERAL, for debugging barrier issues 2018-03-15 16:23:23 +01:00
Unknown W. Brackets
0e2a586c1b Global: Fix some type comparison/shadow warnings. 2018-02-11 07:03:23 -08:00
Unknown W. Brackets
3eb6d38d75 Vulkan: Fix stencil-only clear for stencil upload.
Fixes stencil issues in Star Ocean.
2018-01-27 15:10:17 +01:00
Henrik Rydgård
b9d0bf9842 Remove outdated comment. 2017-12-31 00:10:55 +01:00
Henrik Rydgård
a0f718ace1 Start separating depth and stencil renderpass actions, only internally in the Vulkan code so far. 2017-12-30 22:40:57 +01:00
Henrik Rydgård
1e64919392 Vulkan: Create renderpass objects on demand. Just a refactoring to prepare for some later features/optimizations. 2017-12-30 22:35:43 +01:00
Henrik Rydgård
2250ef799c Avoid including platform-specific headers in VulkanContext.h 2017-12-18 12:54:25 +01:00
Henrik Rydgård
bd40479224 Vulkan: Add facility to auto-generate mipmap levels. Not yet used.
Intended for replacement textures and optional quality improvements
later.
2017-12-07 09:28:18 +01:00
Henrik Rydgård
85b743c732 Just some debug output for future decisions 2017-12-05 11:42:51 +01:00
Henrik Rydgård
b84c15c663 Vulkan: Remove misguided assert about backbuffer clearing mode. 2017-12-02 11:05:10 +01:00
Henrik Rydgård
5fbbb3e115 Try a silly workaround for an otherwise unexplainable crash seen in Google Play Console 2017-12-01 19:56:53 +01:00
Henrik Rydgård
b6f69b71ab Still seeing asserts in this function, weakening remaining to debug-only.. but these really shouldn't trigger. 2017-11-30 16:29:15 +01:00
Henrik Rydgård
168d89284c Vulkan transitions after render: Add a missing case that seems like it could be common? 2017-11-29 22:14:01 +01:00
Henrik Rydgård
bc959470e5 Loosen up some asserts that seem to trigger unexpectedly... need investigation. 2017-11-29 19:07:07 +01:00
Henrik Rydgård
27a60f5e58 Fix message asserts on Android. Add more of them to check things in Vulkan code. 2017-11-20 12:11:47 +01:00
Henrik Rydgård
10792cc8e7 Windows/Vulkan: implement screenshots. Something is iffy with the red/blue swap though... 2017-11-15 13:18:29 +01:00
Henrik Rydgård
232e30f4db Vulkan: When deriving stencilref from color, don't forget to update the value.
Plus minor cleanups.
2017-11-12 19:33:21 +01:00
Henrik Rydgård
afa5b23abb Vulkan readback: Resize the readback buffer dynamically as necessary. 2017-11-12 09:54:30 +01:00
Henrik Rydgård
e18a023ce8 Vulkan: Noticed a framebuffer refcount leak, and changed my mind regarding those :) Let's do it this way instead. 2017-11-11 19:41:43 +01:00
Henrik Rydgård
ee768ca949 Logging improvements, avoid resetting the Android text drawer unnecessarily 2017-11-10 13:02:24 +01:00
Henrik Rydgård
8b42d83123 Vulkan: Remove duplicate depalShaderCache, fix a number of instances where we didn't use the deleter properly.
Plus more logging, of course.
2017-11-09 17:25:37 +01:00
Henrik Rydgård
6eb58b1252 Keep the draw context up to date in a bunch of places. More logging. 2017-11-09 16:28:22 +01:00
Henrik Rydgård
ca3be1877e Vulkan: Apply simple workaround for Mali driver bug (see #10070), and minor cleanup. 2017-11-08 17:03:27 +01:00
Henrik Rydgård
b280e30a27
Merge pull request #10060 from unknownbrackets/debugger
Show texture, depth, and stencil preview in Vulkan
2017-11-06 09:39:19 +01:00
Unknown W. Brackets
3a84b63777 Vulkan: Convert depth format on readback.
Although, the GPU debugger stuff already handles more formats, it's hard
to get the current format to avoid the conversion...
2017-11-06 00:29:02 -08:00
Unknown W. Brackets
138837ac54 Vulkan: Add texture image readback.
This way we can see how it was decoded, scaled, etc.  This also helps
seeing texture cache invalidation issues.
2017-11-06 00:29:01 -08:00
Unknown W. Brackets
4a08410d7d Vulkan: Fix non-16 bit indexed drawing.
Only really affects softgpu, since games are rewritten to 16 bit.
2017-11-05 22:15:27 -08:00
Unknown W. Brackets
9dfc9ff6ae Vulkan: Allow clearing the backbuffer to any color.
Helps with debugging sometimes.
2017-11-05 22:14:53 -08:00
Unknown W. Brackets
63e78ef3e8 Vulkan: Fix framebuffer leak.
Evident in God of War.
2017-11-05 14:21:41 -08:00
Unknown W. Brackets
2ad9eb047e Vulkan: Refcount framebuffer deletes.
Fixes crash in GoW when using a thread.
2017-11-05 08:44:12 -08:00
Henrik Rydgård
d5f8d484dd Tiny cleanups. 2017-11-04 10:08:53 +01:00
Henrik Rydgård
b9443e54e3 Vulkan: Minor fixes. 2017-11-03 00:03:35 +01:00
Henrik Rydgård
ca7a2d06ca Vulkan: Implement stencil upload (for Star Ocean). 2017-11-01 14:18:39 +01:00
Henrik Rydgård
6a8f72a327 Use the global curFrame counter. No need for a vector for pushing cmdbufs. 2017-11-01 08:47:50 +01:00
Henrik Rydgård
90d4296a6a Add a QueueRunner logging facility. Set up a subpass dependency for the backbuffer pass. 2017-11-01 08:45:14 +01:00
Henrik Rydgård
74861d2d73 Vulkan: Make backbuffer transitions part of backbuffer render pass. Optimize depth buffer memory operations. 2017-11-01 08:42:49 +01:00
Henrik Rydgård
97dced543e Share the conversion code between vulkan and D3D, fixing the missing format thing. 2017-10-29 14:42:51 +01:00
Henrik Rydgård
93c785b76d Color-convert directly during the readback, saves a copy. Like we already do in D3D11. 2017-10-29 10:56:36 +01:00
Henrik Rydgård
a9f01c45e0 Use the CPU color conversion from GLES for readbacks in Vulkan (and D3D11). Fix bug. 2017-10-28 19:20:46 +02:00
Henrik Rydgård
34b65c0ca9 Fix Vulkan framebuffer readbacks, as long as they're in R8G8B8A8. 2017-10-28 18:41:54 +02:00
Henrik Rydgård
b98d4e5c9d Vulkan: Rough untested implementation of synchronous readbacks. 2017-10-28 18:03:27 +02:00
Henrik Rydgård
3f918ed328 Refactor: Split out VulkanQueueRunner from VulkanRenderManager
Should be no functionality change, but good to do before adding more
functionality.
2017-10-27 22:11:01 +02:00