Commit Graph
62 Commits
Author SHA1 Message Date
Shahbaz Youssefi 390e610687 Support VK_EXT_depth_clip_control
This extension adds a viewport pipeline state: negativeOneToOne
2022-08-31 09:55:12 +01:00
baldurk f6ac09c4e1 Workaround intel mesa issue reading invalid sample locations 2022-06-16 15:53:49 +01:00
baldurk 5ff8f2c4da Fix state inheritance properly for library pipelines 2022-06-07 22:22:02 +01:00
baldurk 20c986fc06 Add support for EXT_graphics_pipeline_library 2022-04-13 13:57:48 +01:00
Remi Palandri 79aee1df43 full implementation of compute msaa-to-buffer 2022-03-09 12:10:47 +00:00
baldurk fcdea67879 Update copyright years to 2022 2022-02-17 17:38:32 +00:00
baldurk 2c98999a80 Fix mistaken flag set 2022-02-08 18:07:39 +00:00
baldurk 6ab4c1ad74 Add support for VK_KHR_fragment_shading_rate. Closes #2426 2022-02-04 16:45:15 +00:00
baldurk 3996d037b9 Add support for Vulkan 1.3 and Roadmap 2022 profile 2022-01-25 13:10:37 +00:00
baldurk c6a915f4b4 Only use VkPipelineRasterizationStateStreamCreateInfoEXT if stream set 2021-11-16 16:18:30 +00:00
baldurk bb3343786b Add support for VK_KHR_dynamic_rendering 2021-11-05 14:15:01 +00:00
baldurk cab76389c7 Add fatal (device lost/out of memory) error checking to backends
* We check for errors to try to catch them as soon as possible, and early-out
  return even in the middle of functions. The idea being even if this leaves us
  in a weird state we won't get called again as the replay controller will
  detect the error and substitute out a dummy driver.
2021-08-18 20:12:07 +01:00
baldurk 1ed4b561e6 Fix discard patterns to work correctly with multisampled UINT textures 2021-05-27 14:18:05 +01:00
baldurk 90d7bc1926 Fix configuration of spec constants when patching compute pipelines 2021-03-15 12:33:13 +00:00
baldurk 026da176bb Update copyright years to 2021 2021-01-13 13:56:10 +00:00
baldurk 54db5aaf3b Store entries in vulkan shader cache for GLSL generation inputs
* GenerateGLSLShader is reasonably expensive because it uses glslang to
  preprocess the shaders. If we can cache the input hash and look up the cache
  with that hash then we can skip it entirely.
2020-09-04 16:53:38 +01:00
baldurk 2bfa2c0ced Move histogram/minmax shaders into vulkan shader cache
* This lets us cache all shaders instead of having some be regenerated outside
  the cache and looked up into it.
2020-09-04 16:39:42 +01:00
baldurk 02a54be6ad When replaying resource discards fill with explicit pattern. Closes #284
* This helps catches cases where a discarded image is accidentally used and in
  many cases may still have valid data. Particularly on Vulkan this is relevant
  for DONT_CARE renderpass load and store ops.
2020-07-13 17:29:11 +01:00
Aliya Pazylbekova 0fd3d65a6f Vk Pixel History: support other depth formats MSAA
- Separate the pixel history copy pixel shader into two separate
  shaders, one for colour copy and one for depth
- Allocate and update descriptor sets on demand
- Add another compute shader for pixel history depth copy
2020-05-26 21:19:55 +01:00
baldurk a5fe4ebde5 Use enabled not available features to determine what shaders to create
* We still check available features to know which shaders we could create on
  replay, to determine whether we should add STORAGE_BIT to MSAA images we want
  to store into.
2020-05-19 12:57:28 +01:00
baldurk 5b5bd49a43 Serialise device create info exactly as-is, without patching
* Previously we serialised after enabling a few features at capture-time.
2020-05-15 19:03:27 +01:00
Aliya Pazylbekova 41b911d1d0 Vk Pixel History: MSAA depth/stencil copy, shader out
Use a separate compute shader module for MSAA copy, and output
directly into the destination buffer instead of creating
staging resources.

Support case where there is no depth stencil attachment to get post mod
values in per fragment reporting. Previously used the original
framebuffer that might not have had depth/stencil view, so couldn't
count the fragments. Now use the sub image.

To get the post mod color, we need to blend with the premod color, so
we use vkCmdCopyImage to copy from the original image.
2020-05-06 19:35:25 +01:00
baldurk 914268333d Ensure pipeline cache data actually reaches the driver 2020-04-23 19:14:09 +01:00
baldurk 18713f644e Implement OpImageQueryLod by faking derivatives on sample quad 2020-04-23 19:14:09 +01:00
baldurk ed799cb1e3 Serialise pipeline cache in vkshaders.cache 2020-04-22 20:40:14 +01:00
Aliya Pazylbekova 8d2ad78f05 Vk Pixel History: refactoring, per fragment depth
- Refactor to use common funcs
- Add per fragment depth data
- Rename pixelhistory.frag to pixelhistory_primid.frag
- Fix how some per fragment pipelines are created

For per fragment data we create 3 pipelines
1) Post modification pipeline
changes the stencil state and scissors around the target pixel
2) Shader output pipeline
in addition to above, disables rasterization discard, depth bounds test,
culling and turns off blending
3) Primitive ID pipe
in addition to above, disables depth test and depth write, and changes
the fragment shader to only output primitive ID
2020-03-20 16:16:12 +00:00
Aliya Pazylbekova 83623af8d8 Vk Pixel History: per fragment data
- For now only per fragment primitive ID, and colour values, not depth
information.
2020-03-20 16:16:12 +00:00
baldurk 2916c0f9f7 Update copyright years to 2020 2020-01-06 16:20:45 +00:00
baldurk 667f1cf8d1 Remove std::vector/std::string use from Vulkan driver 2019-12-16 18:10:31 +00:00
baldurk 1772222d66 Remove std::string/std::vector from shader projects 2019-12-16 18:10:31 +00:00
baldurk 6d1d302491 Fix a number of warnings identified by higher clang warning levels
* We enable a couple of high signal-to-noise warnings in all clang builds
2019-12-02 20:41:28 +00:00
baldurk 938056a67c Add support for serialising MSAA initial states on GL 2019-11-26 17:38:27 +00:00
baldurk edc8fb6bd6 Be more precise with texture remapping to handle integer textures 2019-11-26 17:38:26 +00:00
baldurk a4e152c999 Fix bit-packing output on vulkan 2019-11-25 23:36:44 +00:00
Dominic Filion Guay 57c60cdfb8 Fixed issue with MSAA textures on Oculus Quest. 2019-09-18 19:28:42 +01:00
baldurk 556cc5b4ae Refactor spec constants to be stored as uint64_t
* A single spec constant can only contain one scalar (vectors are created with
  composites). We can always store a scalar in uint64_t.
2019-08-16 17:38:35 +01:00
baldurk 936876234c Move SPIR-V utility/parsing/editing code into rdcspv namespace
* Everything except the reflection code which will be replaced
2019-08-16 17:38:35 +01:00
baldurk ef269e2b92 Add support for VK_EXT_line_rasterization 2019-08-15 18:27:39 +01:00
baldurk 7bd13f5508 Handle extension pipeline structs when reconstructing pipeline info 2019-08-15 17:29:44 +01:00
baldurk f80964d84c Remove redundant manually maintained list of enabled vulkan extensions 2019-08-15 16:21:34 +01:00
baldurk 22203fbb02 Add checks for quad overdraw and triangle size overlays on mac
* These features aren't supported by the underlying implementation.
* Triangle size we can feature-detect properly - by checking for geometry shader
  support. Quad resolve should be supported but metal doesn't allow atomics on
  images so we have to check specifically for a metal backend.
2019-06-26 12:45:58 +01:00
baldurk a5c909ec0c Don't try to use MSAA array textures on MoltenVK 2019-06-21 12:51:52 +01:00
baldurk a27234c28c Split apart some of the SPIR-V headers
* We don't want to have glslang specific bits mixed in with general SPIR-V bits.
  This is also preparing for moving some SPIR-V structs into common code that
  can be re-used in new reflection/disassembly as well as editing.
2019-06-03 14:16:42 +01:00
baldurk 7206a0cd25 Removing 'use std::vector' 2019-05-17 16:32:56 +01:00
baldurk 5b10d2f794 When recreating pipelines, don't make them derivatives 2019-04-05 14:23:01 +01:00
baldurk 7e363261a4 Add explicit metal check for MS<->Array copies
* Two parts of this feature don't seem to work - MSAA Arrays and writeable MSAA
  textures. It's easier to disable it completely when running on Metal.
2019-02-18 17:23:21 +00:00
baldurk 11819ed3be Refactor and clean up internal shaders to be better organised
* Split up old uber-cbuffers used for unrelated shaders into shader-specific
  cbuffers (DebugPixelCBufferData -> TexDisplayPSCBuffer / CheckerboardCBuffer /
  MeshPixelCBuffer).
* Split up HLSL files so not everything is lumped into 'debugdisplay.hlsl' but
  has separate files as appropriate.
* Use #include in GLSL and HLSL to better organise shader code together rather
  than relying on lumping files together on the C++ side.
* Renamed files like 'debugcbuffers.h' to 'hlsl_cbuffers.h'.
* Trimmed out some extensions/cruft that isn't needed in the GLSL side since we
  no longer use separable shaders.
* Combine some shaders like Outline/Checkerboard that were similar into central
  place.
2019-02-13 18:50:53 +00:00
baldurk 354b37be56 Add support for VK_EXT_sample_locations 2019-02-05 18:40:31 +00:00
baldurk 86ff87863e Update copyright years to 2019 2019-02-01 18:32:13 +00:00
baldurk 18958fedd0 Workaround ARM driver bug, hide UBOs unless they're used. Closes #1225 2019-01-04 12:26:30 +00:00