Commit Graph

211 Commits

Author SHA1 Message Date
baldurk a0a373a8e1 Fix handling of buffer truncation and zero-sized buffers 2020-05-29 17:26:29 +01:00
baldurk b0cd8584fb Fix placement & handling of final next page button in buffer viewer 2020-05-27 22:38:23 +01:00
baldurk 0736a977a2 Handle nested struct offsets properly in raw buffer viewer 2020-05-26 13:53:25 +01:00
baldurk 571b286eb3 Fix bytesize calculation of vertex output attributes 2020-05-20 11:52:24 +01:00
baldurk 3bd09bd4a9 Fix applying offset wrongly on unclamped length 2020-05-11 18:04:22 +01:00
baldurk 90c10ea1fc Handle boolean inputs in vulkan shader parameters
* We change to use VarType instead of CompType for signature parameters which
  allows us to represent different types of variables beyond just
  unsigned/signed integer and float.
2020-05-07 22:46:41 +01:00
baldurk 7c265efe2e Configure ShaderConstant descriptor for vertex inputs 2020-04-28 18:15:33 +01:00
baldurk 133b8a41b9 Fix handling of column-major matrices in buffer viewer. Closes #1848 2020-04-27 13:46:58 +01:00
baldurk a7b4fe9167 Don't clamp length against buffer size after applying offset
* If we have a given view length that fits in the buffer, we shouldn't apply the
  offset before clamping. Instead we apply the offset on the buffer length if
  that's what we're using as our size.
2020-04-27 13:03:47 +01:00
baldurk 068f4998c7 Fix buffer viewer export to handle pagination. Closes #1837 2020-04-21 17:09:32 +01:00
baldurk a3dc3dde2b Use mesh property format when displaying secondary data in buffer view 2020-04-21 17:09:32 +01:00
baldurk 44f46b6ae9 Clamp buffer offset for mesh view input
* If the calculated offset is larger than the buffer size we should be sure to
  clamp it.
2020-04-15 20:33:57 +01:00
baldurk cc64061172 Fix issues with paging in raw buffer viewer 2020-03-16 20:01:47 +00:00
baldurk 4f39279578 When opening a texture in raw buffer viewer, scroll to selected point 2020-03-13 18:00:34 +00:00
baldurk 208a023f12 Fix buffer viewer pagination, allow row offset updates to change page 2020-03-11 18:00:53 +00:00
baldurk ce58f991f0 Apple compile fix 2020-02-25 19:06:58 +00:00
baldurk 4703012a87 Add pagination for very large range buffer viewers 2020-02-25 18:19:52 +00:00
baldurk c23825292d Remove redundant instOffset/vertOffset parameters from DebugVertex() 2020-02-20 19:07:29 +00:00
baldurk 1e8c24fa56 Remove debug print 2020-02-19 11:33:51 +00:00
baldurk 9c091cf791 Fix memory leak in error case 2020-02-13 11:01:44 +00:00
Steve Karolewics dd69f8642a Add APIProperties for debugging and pixel history
Checks to enable debugging and pixel history are gated by the
APIProperties instead of whether the capture is D3D11. Shader
debugging for D3D12 is gated on a config option, which can be enabled
by adding "d3d12ShaderDebugging": "true" to the ConfigSettings
2020-02-12 21:58:33 +00:00
baldurk 661ee35f30 Refactor ShaderDebugTrace to not return a single list of complete states
* The ShaderDebugTrace now only sets up the initial state of an opaque
  ShaderDebugger handle.
* This handle can then be passed to a new function - ContinueDebug - to
  iteratively return N more states. The number of states is implementation
  defined and may be a fixed number or it may run for a fixed time.
* The states themselves no longer contain a complete snapshot of all variables,
  but instead only the changed variables for that iteration. The changes are
  stored as before and after value to make it easier to step forwards and
  backwards (only the ShaderDebugState is needed to move forward or backwards,
  you don't have to search back for the last set value of a variable to 'undo' a
  change).
2020-02-06 17:58:42 +00:00
baldurk 08c0b13aaa Add further checks for windows being deleted during long async callbacks
* This is not really a full solution but fixes the common cases at least.
2020-02-05 15:06:53 +00:00
baldurk 7dd116abd4 Remove redundant/tautological comparisons identified by PVS Studio 2020-01-21 18:28:56 +00:00
baldurk baac06ca93 Remove redundant/dead code identified by PVS Studio 2020-01-21 18:28:56 +00:00
baldurk a5c54b3ce7 Don't pass event ID to PickVertex()
* It's meaningless to try and pick on any other event but the current one
2020-01-20 17:44:34 +00:00
baldurk 210626ae18 When updating postvs position/secondary configs, reset camera properties 2020-01-20 14:32:22 +00:00
baldurk cd3ef3dd55 Fix near/far plane specifiers being backwards 2020-01-20 14:28:59 +00:00
baldurk 4a587da167 Account for byte offset when expanding arrays in bufferviewer formatter 2020-01-17 19:53:38 +00:00
baldurk 2916c0f9f7 Update copyright years to 2020 2020-01-06 16:20:45 +00:00
baldurk 27098f8f70 Give our threads debugger-friendly names 2019-12-19 21:50:13 +00:00
baldurk c82d0f58b9 Rename WASD to Flycam in mesh viewer controls
* This should now work regardless of keyboard layout, e.g. on AZERTY the same
  physical keys will still work. We also add arrow keys as a backup
2019-12-13 16:37:14 +00:00
baldurk 24e4f4179f Fix projection guessing controls sometimes being enabled when unused 2019-12-13 16:36:44 +00:00
baldurk f514815e3c Update buffer formatter help text, save its visibility in config 2019-11-29 13:53:45 +00:00
baldurk e205054317 Add UI support for GPU typed pointers in buffers 2019-11-29 13:53:44 +00:00
baldurk b3979262a5 Replace FormatElement with ShaderConstant/ShaderVariableType
* FormatElement is now a static BufferFormatter class to help generate and parse
  buffer formatting strings
2019-11-29 13:53:44 +00:00
baldurk 324b96c977 Remove FormatElement::byteSize(), move to ResourceFormat 2019-11-29 13:53:44 +00:00
baldurk 00170e2ec3 Make GetVariants a free function taking interpreting format directly
* We also store the format in BufferElementProperties for the buffer viewer
  since we'll later remove the ResourceFormat stored in FormatElement
2019-11-29 13:53:44 +00:00
baldurk f046423664 Split buffer-centric properties out of FormatElement 2019-11-29 13:53:44 +00:00
baldurk db563bb0bf Refactor public interface around handling of textures
* Subresource handling is more consistent - we pass around a struct now that
  contains the array slice, mip level, and sample. We remove the concept of
  'MSAA textures count samples as extra slices within the real slices' and
  internalise that completely. This also means we have a consistent set
  everywhere that we need to refer to a subresource.
* Functions that used to be in the ReplayOutput and use a couple of implicit
  parameters from the texture viewer configuration are now in the
  ReplayController and take them explicitly. This includes GetMinMax,
  GetHistogram, and PickPixel.
* Since these functions aren't ReplayOutput relative, if you want to decode the
  custom shader texture or the overlay texture you need to pass that ID
  directly.
2019-11-26 17:38:25 +00:00
baldurk 6201183504 Fix broken buffer viewer UI protection 2019-11-15 18:33:17 +00:00
baldurk 07e8731776 Protect against buffer view being closed during async render thread work 2019-11-13 17:25:01 +00:00
baldurk a08455c4fb Don't crash if vertex buffer stride is 0 when picking vertices 2019-10-23 11:23:32 +01:00
baldurk 03ddc61779 Support rich resource text in buffer viewer 2019-10-15 15:05:38 +01:00
baldurk d48b84d8f5 Pass buffer length to format string parse, for better default format
* If we are only looking at a 4-byte buffer, don't use a uint4 default or it
  will fail to display anything
2019-10-15 10:54:42 +01:00
baldurk 54291b0e29 Fix linux compilation (again) 2019-09-07 12:06:05 +01:00
baldurk 7fe044faaf Fix display of 64-bit integers in buffer viewer 2019-09-07 09:24:46 +01:00
baldurk 07158ad24c Fix support for triangle fans on GL/Vulkan 2019-08-20 15:33:12 +01:00
baldurk 61de35bfc6 Pass through primitive restart state when rendering meshes 2019-08-12 17:53:22 +01:00
Tillmann Karras 622c8bdb0e BufferViewer: fix 2/4-byte primitive restart 2019-07-24 11:24:09 +01:00