Commit Graph
10393 Commits
Author SHA1 Message Date
baldurk b52a4ae553 Only unwrap command lists at the level we need
* This prevents us from accidentally unwrapping at List2 level when List2 might
  not be available, and we only need List.
* If we need higher list levels we can unwrap explicitly, and it's clearer that
  it needs an availability check.
2018-08-10 18:12:28 +01:00
Alex SmithandBaldur Karlsson c51e6f0e79 Update glslang to latest 2018-08-10 12:45:31 +02:00
baldurk 197a279e31 Add missing override specifier 2018-08-09 17:53:50 +01:00
baldurk adb02cbee4 Linux compile fixes 2018-08-09 17:26:47 +01:00
baldurk b1246c28ae Update docs reference to renamed SPIRVDisassembler class 2018-08-09 17:26:47 +01:00
baldurk 3c7b420e59 Expand SPIR-V disassemblers to general shader processing tools
* Instead of just configuring SPIR-V disassemblers and picking only the first
  one when we need to edit SPIR-V, we allow setting up any shader processor that
  goes between two shader encodings.
* When editing, the default will still be to use embedded source, and then after
  that the first tool that goes from the native shader format to a text format,
  but the drop-down allows you to pick any of them.
* Similarly in the shader viewer you can configure the compilation options and
  method, to choose the compiler you want to use. Embedded command line
  parameters in the shader are automatically appended.
2018-08-09 16:56:53 +01:00
baldurk a81e4a2b45 Pass through and allow different source shader encodings when editing
* This means e.g. the D3D11 back-end can accept DXBC directly if the UI can
  provide it, or compile from HLSL as before.
* More importantly, the Vulkan back-end can take SPIR-V compiled from any
  source, or compile from GLSL as before as a fall-back.
2018-08-09 16:56:52 +01:00
baldurk 24a5375133 Disable shader buttons when no shader is bound 2018-08-09 16:56:52 +01:00
baldurk a4dfad6e82 Add a backend query to check shader encodings BuildTargetShader allows
* This will allow the backend to specify both the native format (e.g. SPIR-V,
  DXBC) as well as a language it might be able to internally compile (GLSL or
  HLSL).
* The caller will then able to decide for itself whether it wants to compile to
  native format and pass that down, or pass the language down and let it be
  built internally.
* Currently BuildTargetShader still only accepts shader source.
2018-08-09 16:56:51 +01:00
baldurk 8249c9b218 Store shader tool command-line from compile flags
* For DXBC files, we decode the D3DCOMPILE flags back into fxc parameters, and
  vice-versa.
* For SPIR-V, glslang will embed command line parameters as OpModuleProcessed
  strings or opcodes.
* This is stored as a "@cmdline" shader compile flag.
2018-08-09 16:56:51 +01:00
baldurk 7de19f4c35 List an encoding for shader debuginfo source. Add HLSL/spvas to enum 2018-08-09 16:56:50 +01:00
baldurk 492a9bf828 Add QByteArray cast for bytebuf 2018-08-09 16:56:50 +01:00
baldurk 3ddeea088c Draw a divider in toolbuttons with menu dropdowns 2018-08-09 16:56:49 +01:00
baldurk de59556c3b Don't allow HTML pipeline export with no capture loaded 2018-08-09 16:56:49 +01:00
baldurk 74b71f538c Remove mistaken log print leftover from debugging 2018-08-09 16:56:48 +01:00
baldurk 2fc67467e2 Don't add empty API name to analytics - indicates failure to load 2018-08-09 16:56:47 +01:00
baldurk d7e4060698 Make sure we don't open a shader viewer with an unbound shader 2018-08-07 12:42:52 +01:00
baldurk 2c58f4092a Support typedefs in SPDB type decoding 2018-08-07 12:42:51 +01:00
baldurk 4e6c3ead41 Nudge users reporting bugs on old builds to update to the latest version 2018-08-07 12:42:51 +01:00
baldurk fee02414cb Don't resize to negative size if reading length fails for any reason 2018-08-07 12:42:50 +01:00
baldurk feee30c15e Set UI value of CaptureAllCmdLists from settings 2018-08-07 12:42:50 +01:00
baldurk 2326677955 Allow grouping auto-passes with multi-draw draws 2018-08-06 17:28:36 +01:00
baldurk fbec9c13aa If sphinx_rtd_theme_chm_friendly directory is missing, use normal theme 2018-08-06 17:28:35 +01:00
baldurk 8e2a2b13c1 Clean up handling of internal resources
* This reduces code complexity and divergence between the backends, as well as
  prevents internal resources in captures from being included when 'Ref All
  Resources' is enabled.
2018-08-06 16:48:04 +01:00
baldurk 98e4a5b613 Set gl_CurChunk for creating client-memory IB buffers 2018-08-06 16:23:04 +01:00
baldurk 9e3147d021 Save treeview expansion state while browsing. Closes #678, Closes #1034
* This is supported currently in the API inspector, constant buffer previewer, and resource inspector.
* The saved expansions are only saved while the capture is open, and will be reset each time.
2018-08-06 16:23:03 +01:00
baldurk 74528c4d15 Allow saving state internally by key as well as externally 2018-08-06 16:23:03 +01:00
baldurk edc5815463 Move expansion saving to RDTreeView so it can be used in more places. 2018-08-06 16:23:02 +01:00
baldurk 7d55ecbc48 Add 'capture frame immediately' button
* This should be more obvious especially on e.g. android where there's no
  overlay and key shortcut.
2018-08-06 16:23:02 +01:00
baldurk 889904e155 Make message about closing android studio even more explicit 2018-08-06 16:23:02 +01:00
baldurk 10029d4b1d Don't bypass wglDX functions used for interop 2018-08-06 11:22:00 +01:00
baldurk 03c2507a25 Linux compile fix 2018-08-03 17:35:57 +01:00
baldurk cbcfe85d97 Use natural human sort for resources in resource inspector. Refs #1034 2018-08-03 16:52:13 +01:00
baldurk f36701779c Display <empty> as custom name if an empty string is set.
* In cases where the API doesn't consider an empty string to be ignored.
2018-08-03 16:52:13 +01:00
baldurk 9f7304c780 Add sleep to posix library startup to avoid race. Closes #857
* On win32 we can get the target control port instantly and immediately connect
  before program startup, on posix systems we must wait until afterwards and
  poll for open sockets.
* This means there's a small window of opportunity where the program may have
  started running but we haven't connected yet to send any initial commands.
  Adding a sleep should give target control time to connect.
2018-08-03 16:52:13 +01:00
baldurk 104072debe Only mark resources as dirty if they are still alive
* We can have dangling references to resources due to descriptor binding
  references, so ignore any IDs that are no longer valid.
2018-08-03 14:47:16 +01:00
baldurk cbbce5b033 Do index buffer remapping in vulkan
* This allows vulkan to handle index buffers with huge differences between
  minimum and maximum indices without over-allocating.
* It does mean we can no longer use the original index buffer as-is without
  changes, but this is a fair trade-off.
2018-08-03 14:47:16 +01:00
baldurk d79ead308f Make a little more room in VTX/IDX columns in buffer viewer 2018-08-03 14:47:15 +01:00
baldurk 84a90bfdaf Update RenderDoc API version to 1.2.0, add new function. Closes #1037
* The new function SetCaptureFileComments allows users to add comments to a
  capture after creating it at any time.
* We also use anonymous union to remove the need to duplicate API structs for
  backwards compatibility.
2018-08-03 11:16:24 +01:00
baldurk 27de5beb76 Remove dos newline characters from comments edited in UI 2018-08-03 11:16:23 +01:00
baldurk 9774c9be9b Use remapped set of physical devices to create device. Closes #1062
* m_ReplayPhysicalDevices contains the physical devices enumerated on replay,
  which could be arbitrary and not matching etc.
* m_PhysicalDevices contains the physical devices remapped in order to produce
  the closets match to the capture's PD in each slot, using the PDs available.
2018-08-03 11:16:23 +01:00
baldurk 7061830f52 Mark resources as clean immediately when they are released 2018-08-03 11:16:22 +01:00
baldurk a1dca66f76 Add sleep to RGP worker thread loop 2018-08-03 11:16:22 +01:00
baldurk 04dc71ce32 Fix compilation of depth MSAA <-> Array shaders on Vulkan
* glslang doesn't like the GL_ARB_sample_shading extension
2018-08-02 18:44:31 +01:00
baldurk 1ab163d1d5 Add ignore of gdi32full.dll
* We don't want to hook gdi32full.dll for the same reason as gdi32.dll - we just
  catch function calls going in, not coming out at a 'system' level.
2018-08-02 18:44:30 +01:00
baldurk 948274189c Don't register live resources during capture
* Otherwise we try and delete these resources on shutdown, which we shouldn't.
2018-08-02 11:32:43 +01:00
baldurk e636b610f9 Get DataType from internal format if there's no hint
* dataType would never have been eGL_NONE previously, since it's either set to
  the hint or eGL_UNSIGNED_BYTE.
2018-08-02 11:32:43 +01:00
baldurk fa7fab9eb4 Speed up application of upload heaps on D3D12 captures
* If we keep the data in CPU memory since we're going to need to CPU upload
  anyway, the copy goes significantly faster.
2018-08-02 01:18:01 +01:00
baldurk 39258daff7 Ensure GetProcAddress is populated first
* This makes sure that we have glXGetProcAddress / eglGetProcAddress available
  first so that we can then bootstrap and fetch other functions.
2018-08-01 23:55:33 +01:00
baldurk 1443422cf7 Use libGL.so.1 instead of libGL.so for dynamic access 2018-08-01 23:55:30 +01:00