Commit Graph

9440 Commits

Author SHA1 Message Date
baldurk 7fe044faaf Fix display of 64-bit integers in buffer viewer 2019-09-07 09:24:46 +01:00
baldurk 54f271930c Use correct draw count when replaying glMultiDraw*IndirectCount 2019-09-07 09:13:11 +01:00
baldurk 02dcd2183a Fix linux compilation 2019-09-06 23:19:38 +01:00
baldurk e1eaf07f2e Display longs as hex if xlong is used 2019-09-06 22:24:56 +01:00
baldurk a50513e561 Correctly handle long format elements 2019-09-06 22:19:28 +01:00
baldurk 9c6bfa6788 Remove static resource lists, make them members of the device 2019-09-06 22:19:28 +01:00
baldurk 1eecd56896 Fix gl prefix on function checks 2019-09-06 22:19:28 +01:00
Aliya Pazylbekova 141f28dfc9 Update GGP integration 2019-09-06 18:42:43 +01:00
baldurk c9f13a657d Add test cases of shader editing on GL and Vulkan 2019-09-05 20:36:12 +01:00
baldurk 852e538145 Add missing boundary check in MemRefInterval iteration. Closes #1510 2019-09-05 20:36:12 +01:00
baldurk 190cba427c Refactor shader editing to more reliable approach
* When we replace a shader in GL there are a few knock-ons: we need to replace
  the programs that use this shader, and then from there we need to replace the
  pipelines that use the program. We also need to beware of programs created
  with glCreateShaderProgramv which refer to themselves as both a program and a
  shader.
* Previously we'd look at the edited shader, then recurse and look at programs,
  then recurse and look at pipelines. We'd try to remember which one replaced
  which so we could undo it again.
* Now we just do this in subsequent passes since there is only a one-way
  dependency: First replace the shader as needed, then update any programs and
  either replace or remove replacement as needed, and finally update any
  pipelines.
* On Vulkan and D3D12 it's simpler as we just have shaders -> pipelines but the
  same principle applies.
2019-09-05 20:36:12 +01:00
baldurk 9627332667 Add a utility function to tests to pick a pixel and check its value 2019-09-05 20:33:25 +01:00
baldurk ce474e07e1 Remove programs and pipelines when they are deleted
* This prevents shader editing from trying to modify deleted programs
2019-09-05 20:33:25 +01:00
baldurk 0df24b2d7d Don't fetch uniform values if we get a -1 location 2019-09-05 20:33:25 +01:00
baldurk c48578fdd9 Add new location remapping when editing shaders on GL
* If they're autogenerated then unfortunately the locations in a shader can
  change over edits depending on what the shader is doing. We need to remap
  across this as well as composing that onto any capture-replay remapping.
2019-09-05 20:33:25 +01:00
baldurk 7f838fc88c Don't trash SPIR-V shaders on GL after compiling them 2019-09-05 20:33:25 +01:00
AJ Weeks 1961495390 Disable/enable (rather than show/hide) toggles 2019-09-05 20:33:14 +01:00
AJ Weeks 0a973130ac Keep "Show hidden rows" text constant now that checkbox appears 2019-09-05 20:33:14 +01:00
AJ Weeks 7231de0ed0 Allow hidden errors and warnings to be shown again
* Fix copy paste typos (lines 322, 329)
* Allow hidden rows in Errors and Warnings tab to be made visible again
2019-09-05 20:33:14 +01:00
baldurk 878d4140c3 Fix support for checkable menu items in RDStyle 2019-09-05 11:48:48 +01:00
baldurk 588025fc6c Add test case for misaligned dirty regions on vulkan 2019-09-05 11:48:47 +01:00
baldurk 4a4884129b Allow overriding replay options in test cases 2019-09-05 11:48:47 +01:00
baldurk bfad3dac2f Don't set optimisation level until we have replay options on Vulkan 2019-09-05 11:48:47 +01:00
Benson Joeris a14141eb52 Align MemRef intervals (#1510)
When initializing VkDeviceMemory resources, some regions may be cleared
using vkCmdFillBuffer, rather than having initial data copied.
vkCmdFillBuffer requires that the interval offset and size are multiples
of 4.

This change aligns all of the intervals containing the `FrameRefType`s
used to determine the initialization requirements for VkDeviceMemory.
This alignment is done as the intervals are loaded so that the
initialization (before the first replay) and reset (before subsequent
replays) use consisent alignment.

Change-Id: Icb1a1ba5fc0045fc4ec1ccbfe9caad06154f2338
2019-09-05 10:51:02 +01:00
baldurk 16164d5157 Fix off-by-one error accessing deferred shadow buffers in D3D11 record 2019-09-05 00:55:35 +01:00
baldurk 205ec0ecf8 Update misaligned dirty demo to have interesting data in all bytes 2019-09-04 18:40:43 +01:00
baldurk bae2ea3767 Add demo program that misaligns the dirty region of a buffer 2019-09-04 18:13:41 +01:00
baldurk 6db13115a3 Fix access to array after target element has been removed 2019-09-04 16:22:29 +01:00
baldurk 60faef5ce5 Fix byte size calculation of ETC2 format textures 2019-09-04 15:40:51 +01:00
baldurk c761f675c4 Add test that SPIR-V 1.3 shaders are disassembled, reflected, and edited 2019-09-04 14:33:13 +01:00
baldurk c9e668cdfc Create highest vulkan instance possible in tests, and save version 2019-09-04 13:17:11 +01:00
baldurk 244d96c1cd Reduce log spam when creating proxy drivers 2019-09-04 10:43:22 +01:00
baldurk 1cd2b4fc0a Don't enable counter libraries when running as a replay proxy 2019-09-04 10:42:40 +01:00
baldurk b0cc357933 Ensure D3D init params are fully initialised including adapter desc 2019-09-04 10:41:37 +01:00
baldurk 01c1b5bc71 Respect RENDERBUFFER target in glCopyImageSubData. Closes #1509 2019-09-03 14:40:06 +01:00
baldurk cd8fccc19b Fix crash with fetching mesh output if no descriptor sets are bound 2019-09-03 10:43:25 +01:00
baldurk 60ae75d810 Fix wrong return type on SDObject 2019-09-03 10:36:17 +01:00
baldurk 3d33d9f961 Fix compilation on mac 2019-09-02 19:52:46 +01:00
baldurk 3aeada9fa5 Don't use deprecated vulkan enum values 2019-09-02 16:24:15 +01:00
baldurk 6e7f5691b5 Handle 0-length strings correctly when doing reflection emulation 2019-09-02 16:14:51 +01:00
baldurk 224b1877f4 Remove dangling 'using std::string' 2019-09-02 15:20:19 +01:00
baldurk 6d40bbb783 Add experimental wayland support. Refs #853
* This is only lightly tested and may break heavily. It is disabled by default
 and must be explicitly enabled.
* In particular this is only known to work for Wayland use at capture time.
 Wayland on replay is still unsupported. Known issues include: EGL pbuffer
 surfaces are not implemented on Wayland, Wayland cannot get window dimensions,
 and there are hangs/failures with GL and vulkan presentation with Wayland.
2019-09-02 15:02:27 +01:00
baldurk 9b501d88a1 Initialise shaders to 0 2019-09-02 14:34:20 +01:00
baldurk 16dd362db1 Revert "missed one change for the vulkan in app api capture fix"
This reverts commit da289fdbcc.
2019-09-02 14:02:04 +01:00
baldurk 8246c01198 Revert "fixed in app api capture"
This reverts commit 98b623cfcc.
2019-09-02 14:01:52 +01:00
baldurk 2d0b18b18b Don't crash if shader viewer is closed while shader compilation is going 2019-09-02 12:54:08 +01:00
baldurk 1107462f05 Use pipeline layout from descriptor set binds to iterate descriptor sets
* If a pipeline doesn't statically access a descriptor set, the corresponding
  descriptor set layout in its pipeline layout can be essentially anything and
  it doesn't have to match the actual descriptor set bound at a draw. It's just
  ignored.
* Rather than check for static access ourselves we take advantage of another
  fact - when the descriptor set is bound it must be compatible with the set
  layout from the bind call's pipeline layout. If the pipeline *does* statically
  use the descriptor set, its pipeline layout must be compatible with the bind
  call's pipeline layout for that set.
* So the end result is that we can safely use the bind call's pipeline layout
  for iterating over bound descriptors, secure in the knowledge that it's always
  valid for that data, and if the pipeline uses it then it's also valid for the
  pipeline.
2019-09-02 12:19:37 +01:00
baldurk e6d0c93b41 Fix wrong Qt cmake variable for qmake command being used 2019-09-02 11:37:55 +01:00
baldurk e15a10a0e6 Don't bind GL_QUERY_BUFFER if the extension isn't supported 2019-08-30 11:54:33 +01:00
baldurk 608c283c9b Use all non-negative shader lengths, not just positive. Closes #1508 2019-08-30 11:54:30 +01:00