Commit Graph

8500 Commits

Author SHA1 Message Date
baldurk 4bded8be29 Add missing GL_DYNAMIC_STORAGE_BIT specifiers in GL_Buffer_Updates test 2019-01-24 13:21:03 +00:00
baldurk 4f230ab625 Ensure we sync GPU work before destroying an output window on D3D12 2019-01-24 11:33:52 +00:00
baldurk 465c114ce0 Check for errors when creating replay D3D12 command list 2019-01-24 11:28:12 +00:00
baldurk 69a76bfb41 Use ASCII name for duration column in draw list export. Refs #1246 2019-01-24 10:15:36 +00:00
baldurk 953661fc81 Add missing commas in string name of vkCmdClearAttachments 2019-01-23 18:36:39 +00:00
baldurk 604854b87c On D3D12 and Vulkan start first frame capture on API init. Closes #1195
* On GL/D3D11 we delay the start of the 'first frame' until a swapchain has been
  created for D3D11, or an attribs-created context has been created for GL. This
  makes it more useful and doesn't fire when creating devices/contexts for
  enumeration or trampolining.
* On Vulkan/D3D12 the first device that's created is useful, so we can start
  capturing immediately once it's available.
2019-01-23 16:19:43 +00:00
baldurk 35f7273379 Fix missing egl functions in eglGetProcAddress, use hook set macro 2019-01-23 14:41:03 +00:00
baldurk 0f8573d4a5 Enable VK_AMD_shader_core_properties on replay if it's available
* This extension is used by GPA
2019-01-23 13:45:18 +00:00
baldurk 7044754065 Update GPUPerfAPI to 3.3 2019-01-23 13:44:18 +00:00
baldurk ae3a6da6bd Use shader declared register array sizes to clamp descriptor tables
* When a descriptor table is unbounded in the root signature we don't want to
  pass potentially multiple 100k descriptors through just because they're
  technically available.
* Instead use the declared array size of the last register in the space (since a
  descriptor table in the RS might correspond to multiple HLSL variables) to
  limit which registers are actually available, which is possibly orders of
  magnitude less.
2019-01-23 12:33:18 +00:00
baldurk b0a694df46 Fix case fall-through when making string name for ETC2 2019-01-23 11:39:21 +00:00
baldurk 017b291b18 Install newer libstdc++-dev package in linux build scripts
* Older ones like 4.9 that was used originally didn't fully support C++11.
2019-01-23 09:33:34 +00:00
baldurk f50ba1272f Add missing explicit include for <type_traits> 2019-01-23 09:32:51 +00:00
baldurk eb5c416130 Reserve space up front when fetching resources on Vulkan/D3D12 2019-01-22 18:51:54 +00:00
baldurk 3f8e2e7f99 Change the check for when copyRange/destroyRange can be trivially done
* Even if a struct isn't trivial (e.g. it contains a constructor) it can still
  be trivially copyable (just POD with memcpy), or trivially destructable (with
  no destructor). Make sure we don't fall back to slower copies/destroys for
  this case as it's relatively common.
2019-01-22 18:48:07 +00:00
baldurk 9443423389 Don't do expensive string work for resource rows that are hidden 2019-01-22 18:02:14 +00:00
baldurk eeae73042c Don't serialise map data writes on D3D12 if we've baked to cached buffer
* When we have a cached buffer that already has the map contents, reserialising
  the byte buffer is pointless as we don't use it for anything.
* The serialise involves allocating a buffer, memcpy'ing it, then freeing it
  which can add up for large map writes.
2019-01-22 17:46:23 +00:00
baldurk f2253404f7 Add test that verifies postvs data is correct with separable GS shaders 2019-01-22 16:56:04 +00:00
baldurk 0cee61558a Mention the index when some PostVS data doesn't match ref data in test 2019-01-22 16:55:39 +00:00
baldurk f140cd9669 Handle shader-program created shaders in GL post-vs fetch. Closes #1244 2019-01-22 16:40:52 +00:00
baldurk d64ad19f16 Add an optional timeout to Socket::AcceptClient
* This is needed since sometimes on tests a localhost socket won't immediately
  be available to accept()
2019-01-17 17:51:07 +00:00
baldurk 5d9d77f361 Expand GL buffer updates test to check various combinations of updates 2019-01-17 11:50:09 +00:00
baldurk 7a6e74d158 Refactor GL persistent mapped buffer handling to be more usable
* We now take a more vulkan-like approach, by forcing READ_BIT on for
  buffers/maps that are coherent, and leaving it alone while idle. During
  capture we do the same memcmp & save updates as before.
* This is signifcantly faster while idle, though still slow to capture due to
  the number of sync points in GL (per draw). Roughly scales with O(m*n) where m
  = number of bytes of memory coherently mapped and n = number of draws in a
  frame.
2019-01-17 11:49:41 +00:00
baldurk 7957ef4a33 Fix display string name for ETC texture formats. Closes #1239
* EAC has a four-component version, GL_COMPRESSED_RGBA8_ETC2_EAC /
  GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC.
* ETC2 has a version with 1-bit alpha.
2019-01-17 10:31:12 +00:00
baldurk 07dbadc0bc Remove unneeded common v2f code 2019-01-16 16:49:08 +00:00
baldurk 3a064eda7b Fix GL_Mip_Gen_RT test 2019-01-16 16:48:10 +00:00
baldurk f395f244eb Add initial contents and dirtying for high-frequency samplers
* For samplers that are updated a lot we fall back to fetching & applying their
  state as initial contents.
2019-01-16 13:47:56 +00:00
baldurk adbf24da77 Use latest set of shaders attached to program for initial states
* If multiple shaders are attached to a program only use the latest set as they
  override anything that came before.
2019-01-16 13:23:40 +00:00
baldurk 27a4353ffa Fix out of date python use in documentation examples 2019-01-16 12:38:10 +00:00
baldurk c4f1062cdd Don't trash state of uniform buffer offset & size in GLPushPopState 2019-01-16 12:02:30 +00:00
baldurk 62a5e6e8bd Error if an unsupported device extension is used. Refs #1238 2019-01-15 13:40:57 +00:00
baldurk 26d35d4214 Pass pLayerName correctly when enumerating device extensions
* We want to enumerate extensions from the right source, and also only add our
  own added extensions if pLayerName == NULL.
2019-01-15 13:40:22 +00:00
baldurk 2ba624adb8 Save the capture settings on launch, offer button to load most recent
* This gives a one-click way to run the last capture, if it's not
  complex/regular enough to be worth saving to a settings file on its own.
* Doesn't save much if you're selecting an exe as the previous exe location is
  remembered, but if you also have command line parameters or a working
  directory it can help.
2019-01-15 10:51:31 +00:00
baldurk 145f4bdb15 Handle GL applications changing BASE_LEVEL / MAX_LEVEL dynamically
* This is the only way in GL to do rendering from one mip to another. We handle
  it and display the whole texture even if it's temporarily constricted, and
  display the mip state in the pipeline viewer.
* If the mip state is constricted at the start of the frame capture, only mips
  0..MAX will be visible at all and other mips will be assumed to not be valid.
2019-01-14 18:02:44 +00:00
baldurk 2afcd9868a Fix a case where existing root parameters could overlap with added one 2019-01-14 16:29:29 +00:00
baldurk 5ca0e50939 Fix duplicated enum definition 2019-01-14 16:27:33 +00:00
baldurk f3092b7df5 Add support for new KHR vulkan extensions
* VK_KHR_depth_stencil_resolve
* VK_KHR_shader_float16_int8
* VK_KHR_shader_float_controls
* VK_KHR_swapchain_mutable_format
2019-01-14 16:03:03 +00:00
baldurk 6508bffcda Update vulkan headers to 1.1.97 2019-01-14 16:03:02 +00:00
baldurk e56166838c Sort some enum lists that were unsorted 2019-01-14 16:03:02 +00:00
baldurk 540cb7ce29 Track eglBindAPI to see if EGL is used with desktop GL. Closes #1233 2019-01-14 13:20:00 +00:00
baldurk 992311c2da Fix shader compilation for triangle size overlay program 2019-01-14 13:20:00 +00:00
baldurk ed18828a98 If a layer isn't present on replay, it's not fatal. Refs #1237 2019-01-14 13:20:00 +00:00
baldurk 465278c996 Use typeHint as a forced view cast on vulkan 2019-01-14 13:19:59 +00:00
baldurk 44da10be06 Change SRGB to be a component type, not a ResourceFormat flag
* This allows us to have sRGB as a type hint, and better matches API format
  types.
* It's currently impossible and unlikely to ever be the case that srgb is
  applied to anything other than UNorm, so having it be independent from the
  component type was a degree of freedom that was unused.
2019-01-14 13:19:59 +00:00
baldurk d72d924c39 Fix copy-paste error on display of D3D12 ClearRTV color. Closes #1236 2019-01-14 09:57:08 +00:00
baldurk 2da62da01a Other IB/VB params in indirect call come from view in indirect data 2019-01-11 19:00:26 +00:00
baldurk 5e33353e79 Fix linux compile 2019-01-11 16:27:13 +00:00
baldurk f39be022a3 Satisfy strange Qt thread-ownership requirements around QProcess objects 2019-01-11 16:03:35 +00:00
baldurk 8b28e0ed6d Avoid doing a 0-byte glCopyBufferSubData as this can crash on AMD 2019-01-11 15:23:35 +00:00
baldurk 32dbfd6263 Fix resource usage tracking around indirect executes on D3D12 2019-01-11 15:23:04 +00:00