Version v1.9
This version comes with two useful features for Vulkan users, pixel history and shader debugging, as well as a number of other feature improvements and bugfixes. More details on all of those are listed below.
Please ensure you have the latest graphics drivers installed for your system, as a number of bugs have been fixed recently that are relevant to these new features.
Binary releases are available on renderdoc.org with zip and installer for Windows and binary tarball for linux.
PLEASE NOTE: I've added a new flag to the existing analytics system to track how many people use DXIL shaders on D3D12. This flag works the same as other analytic flags, in that it only stores a single bit of whether or not (per month) you have ever loaded a capture that uses DXIL shaders. It doesn't track anything to do with the shader contents, their version, shader stage, or anything like that.
If you are already opted out of the analytics this will not change anything for you. If you would like to opt out of the analytics after this change you can do so in the main settings page, under 'Anonymous Analytics'.
Main Highlights
-
Vulkan supports shader debugging of SPIR-V shaders at vertex, fragment and compute stages.
To debug a vertex, use the mesh viewer to select the vertex and instance you want and then right click to debug that particular vertex. Fragment shaders can be debugged either from pixel history (see below) or else with the 'debug' button under the texture viewer, when you have the desired drawcall and pixel selected. Note that if the current draw overdraws the pixel then it's not defined which instance of the pixel shader will be debugged, so you can use the pixel history to select a particular fragment. To debug a compute shader there are new controls on the pipeline state viewer to select the group and thread you wish to debug.
Currently the shader debugging is at the SPIR-V level. No special setup is required, however if the shader is built with debug information such as embedded source code and OpLine mapping that can be used to switch between source and SPIR-V, and where possible real names will be used for variables.
Please ensure you have the latest graphics drivers installed for your system, as a number of bugs have been fixed recently that are relevant to these new features.
At the moment there is limited support for extended types such as float16 and int16, as well as extensions and features added after vulkan 1.0. Currently subgroups and subgroup operations are not supported, so only one thread of any given shader will be debugged at a time. A tracking issue exists to follow the status of those limitations.
-
Vulkan now also supports fetching pixel history thanks to contributions from Aliya Pazylbekova at Google.
Within the texture viewer you can select a pixel in a given texture and click the 'history' button below the zoomed in context view to fetch a list of all modifications to that pixel up to that point in the capture. In particular for drawcalls this will show which drawcall and where possible which primitive covers the pixel, as well as showing if a drawcall fails a given rasterization test before modifying the pixel.
There are a few known limitations such as surrounding the use of secondary command buffers and render passes with multiple subpasses, as well as if command buffers are submitted multiple times in a frame. A tracking issue exists to follow the status of those limitations.
-
When a resource is discarded it will now be filled with a recognisable pattern, both to make it clear what has happened as well as to debug any cases where that data is then read inadvertently. This feature is disabled when captures are opened with the 'Fastest' replay optimisation level, which can either be done as a one-off with
File
→Open Capture with Options
or changed in the settings menu as a default.Buffers are filled with a repeating
0xD15CAD3D
pattern. Textures are filled with a pattern depending on how they were discarded:This happens explicitly on OpenGL when calling
glInvalidate*
.
On D3D11/D3D12 this happens explicitly too with
Discard*
calls.
On Vulkan this can happen implicitly when transitioning an image from
UNDEFINED
to any layout.
Also when using a render-pass attachment with
LOAD_DONT_CARE
orSTORE_DONT_CARE
.
-
Programs using DXIL (SM6.x) bytecode can now be captured and replayed. All existing features except for shader debugging are supported. NOTE: As mentioned above, I've added a simple flag to the existing analytics system to track how many people use DXIL shaders. See above for more information.
Python breaking changes
byteStride
has been moved fromVKVertexBinding
toVKVertexBuffer
.CompType.Double
has been removed. Double are now represented the same way as other non-32-bit values, withCompType.Float
as the base component type and the associated byte width set to 8. Everywhere that already usedCompType.Double
already has a byte width that can be examined.
Features/Improvements
- UI: Add a configurable set of folders to search for custom visualisation shaders for the texture viewer.
- UI: Add support for navigating within buffers that are larger than 2GB.
- UI: Improve the copy-paste behaviour for tree views.
- UI: Add expand/collapse all to all tree views in the UI (previously it was inconsistently available).
- UI: Disable rasterizer-based shader stages from pipeline flowchart if rasterizer discard is enabled.
- UI: When an application crashes or otherwise disconnects mid-capture, hide the capture progress bar.
- UI: Show error dialog when vulkan layer registration as root fails.
- UI: Fix display of actions within a package on android when packages contain many actions.
- UI: Fix deadlock when running run command for remote server.
- UI: Show the image view in vulkan pipeline state viewer when the view is non-trivial.
- UI: Show slices in opengl pipeline state viewer when only some slices of an image are bound.
- UI: Resource inspector now shows an entry for discard uses of a resource.
- UI: Alpha-only textures default to showing the alpha channel instead of RGB like other textures.
- All: Made texture overlays behave more consistent with interaction with viewport and scissor, and added a pass/fail red/green drawcall overlay for showing scissor test failure.
- D3D: Add support for new MS way for separate debug info in shaders.
- Vulkan: Defer preparing initial states of resources that are not modified in several seconds to reduce memory overhead.
- Vulkan: Entirely omit initial contents for images that are always fully initialised within any command buffer that uses them, to reduce memory overhead.
- Vulkan: Include the draw count for indirect draws.
- Vulkan: Improve the handling of unknown pNext structures, and allow linux builds to support windows-only pNext structs such as those from
VK_EXT_full_screen_exclusive
. - Vulkan: When negative viewport height is in use, account for that when unprojecting mesh data for display in mesh viewer.
- Vulkan: Add support for extensions:
VK_EXT_inline_uniform_block
VK_EXT_custom_border_color
VK_EXT_robustness2
VK_EXT_pipeline_creation_cache_control
VK_EXT_private_data
VK_EXT_extended_dynamic_state
- OpenGL: Removed some spurious serialised buffer binding calls when client side arrays are potentially in use on GL.
- OpenGL: Don't emit redundant warnings about unbound vertex buffers.
- OpenGL: Clear calls consistently show in the event browser as drawcall type events.
- GLES: Support added for ARM counters on OpenGL ES.
- Linux: Implement proper support for capturing child processes, and populate them immediately in the capture connection panel. This fixes capture of apitrace as well as e.g. launching a program through a wrapper script.
- Linux: Implement 'debugger delay' option to wait for the debugger after launching a child process.
- Android: Added support for upcoming Android 11 breakage of storage locations.
Bugfixes
- All: Handle buffer truncation and zero-sized buffers correctly.
- UI: Fix generation of padding bytes between struct members in raw buffer viewer.
- UI: Fix handling of nested structs in raw buffer viewer.
- UI: Fix paging buttons in raw buffer viewer.
- UI: Fix combined image/sampler descriptors not displaying properly.
- UI: Fix an off-by-one error that would display too many or duplicated thumbnails for D3D12 resources.
- UI: Fix an issue that could cause device crashes with a particular race between an HWND resizing and creating a swapchain.
- UI: Fix a bug generating HLSL edit stubs.
- UI: Fix handling of matrix padding in raw buffer viewer.
- UI: Fix calculation of index buffer offset.
- UI: Fix a crash when opening a constant buffer which is not buffer backed (e.g. push/root constants) and is not used by the current pipeline.
- D3D11: Fix a crash with invalid cross-thread access when capturing from deferred contexts.
- D3D11: Fix a crash with multithreaded access to buffer data when discarding buffers on multiple deferred contexts at once.
- D3D11: Fix a problem where incorrect results would be returned from rasterizer queries while shader debugging due to state pollution.
- D3D11: Show post-modification depth on a per-fragment basis in pixel history.
- D3D11: Show each fragment's depth test pass/fail status.
- D3D: Fix crash calling
DXGIGetDebugInterface*
when the output pointer is NULL. - D3D: Fix potential truncation in arrays with less than a full float4 per element, when debugging HLSL shaders with source information.
- D3D: Fix a potential out-of-bounds read if the contents of a file in an PDB are exactly a multiple of 512 bytes.
- D3D: Fix swizzle on resource not being properly applied for byte address buffer loads.
- Vulkan: Fix a crash when editing shaders with a different entry point name.
- Vulkan: When capturing buffers or memory that are bound with
VK_*_buffer_device_address
ensure those buffers aren't prematurely deleted. This could cause the device address to be re-used which we cannot support properly. - Vulkan: Fix a crash fetching bindless feedback for a shader that doesn't use the GLSL.std.450 extended instruction set.
- Vulkan/GL: Fix display of overlays and array textures when using multiview.
- Vulkan: Fix a problem where subpass self-dependencies were incorrectly removed when partially replaying a renderpass.
- Vulkan: Don't display KHR performance counters that are not command scope.
- Vulkan: Support KHR performance counters on begin renderpass/next subpass/end renderpass commands.
- Vulkan: Fix a crash that could happen with captures that use multiple subpasses as well as multivew.
- Vulkan: Allow replaying a capture that used validation-related extensions.
- Vulkan: Fix a crash when an application sets stageFlags to 0 for a binding.
- OpenGL: Fix a bug where tracking state would get out of sync when capturing a program that uses multisampled depth.
- OpenGL: Improve support for GLES readback of image formats.
- OpenGL: Fix fetching of mesh output in captures that themselves use transform feedback.
- OpenGL: Fix readback of buffers larger than 2GB.
- OpenGL: Fix a crash if glBindBuffersBase is called with a NULL buffers array.
- OpenGL: Ensure
GetLastError
return value is set to 0 when successfully returning a GL hook, as some buggy programs may incorrectly look for it even on success. - OpenGL: Don't fetch the mip level or layer for renderbuffer framebuffer attachments.
- OpenGL: Work around possible driver bug with texture queries breaking when active texture is non-0.
- OpenGL: Fix extra NULL bytes being included in Intel performance counter names and descriptions.
- OpenGL: Fix error when a framebuffer has a layer of a 3D texture bound as an attachment.
- OpenGL: Show Intel GPU counters that belong to multiple queries in each place they appear.
- OpenGL: When serialising calls to
glUniformBlockBinding
orglShaderStorageBlockBinding
store the name as well as the index, to account for if the index changes. - OpenGL ES: Handle reading the right amount of data from instanced vertex attributes that use client memory.
- D3D12: Fix failure to replay when opening a capture that uses
OpenExistingHeapFromAddress
due to invalid heap flags from that function. - D3D12: Workaround device hang on nvidia when capturing programs that use multisampled depth.
- D3D12: Fix shader debugging co-ordinate indexing with a texture UAV.
- Linux: Fix parsing of command lines that contain nested quotes and empty parameters.
- Android: Handle capturing packages that do not have a native ABI.