Windows

Main Window

class qrenderdoc.MainWindow

The main parent window of the application.

ShortcutCallback(QWidget focusWidget)

Not a member function - the signature for any ShortcutCallback callbacks.

Parameters

focusWidget (QWidget) – The widget with focus at the time this shortcut was detected. May be None.

RegisterShortcut(shortcut, widget, callback)

Register a callback for a particular key shortcut.

This creates a managed shortcut. Qt’s shortcut system doesn’t allow specialisation/duplication, so you can’t use Ctrl+S for a shortcut in a window to update some changes if there’s also a global Ctrl+S shortcut on the window. In the end, neither shortcut will be called.

Instead this function allows the main window to manage shortcuts internally, and it will pick the closest shortcut to a given action. The search goes from the widget with the focus currently up the chain of parents, with the first match being used. If no matches are found, then a ‘global’ default will be invoked, if it exists.

Parameters
  • shortcut# (str) – The text string representing the shortcut, e.g. ‘Ctrl+S’.

  • widget# (QWidget) – A handle to the widget to use as the context for this shortcut, or None for a global shortcut. Note that if an existing global shortcut exists the new one will not be registered.

  • callback# (ShortcutCallback) – The function to callback when the shortcut is hit.

UnregisterShortcut(shortcut, widget)

Unregister a callback for a particular key shortcut, made in a previous call to RegisterShortcut().

See the documentation for RegisterShortcut() for what these shortcuts are for.

Parameters
  • shortcut# (str) – The text string representing the shortcut, e.g. ‘Ctrl+S’. To unregister all shortcuts for a particular widget, you can pass an empty string here. In this case, UnregisterShortcut.widget must not be None.

  • widget# (QWidget) – A handle to the widget used as the context for the shortcut, or None if referring to a global shortcut.

Widget()

Retrieves the PySide2 QWidget for this MainWindow if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Event Browser

class qrenderdoc.EventBrowser

The event browser window.

UpdateDurationColumn()

Updates the duration column if the selected time unit changes.

Widget()

Retrieves the PySide2 QWidget for this EventBrowser if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

API Inspector

class qrenderdoc.APIInspector

The API inspector window.

Refresh()

Refresh the current API view - useful if callstacks are now available.

RevealParameter(param)

Expand the API view to reveal a given parameter and select it.

Parameters

param# (renderdoc.SDObject) – The parameter to reveal and select.

Widget()

Retrieves the PySide2 QWidget for this APIInspector if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Pipeline State

class qrenderdoc.PipelineStage(value)

Specifies a pipeline stage for the PipelineStateViewer.

VertexInput

The fixed function vertex input stage.

VertexShader

The vertex shader.

HullShader

The vertex shader.

TessControlShader

The tessellation control shader.

DomainShader

The domain shader.

TessEvalShader

The tessellation evaluation shader.

GeometryShader

The geometry shader, including stream-out/transform feedback.

Rasterizer

The fixed function rasterizer stage.

ViewportsScissors

The viewports and scissors. Helper alias for Rasterizer.

PixelShader

The pixel shader.

FragmentShader

The fragment shader.

ColorDepthOutput

The fixed function color and depth output stage, including color blending and depth/stencil testing state.

Blending

The color blending state. Helper alias for ColorDepthOutput.

DepthTest

The depth test state. Helper alias for ColorDepthOutput.

StencilTest

The stencil test state. Helper alias for ColorDepthOutput.

ComputeShader

The compute shader.

SampleMask

The sample mask.

class qrenderdoc.PipelineStateViewer

The pipeline state viewer window.

SaveShaderFile(shader)

Prompt the user to save the binary form of the given shader to disk.

Parameters

shader# (renderdoc.ShaderReflection) – The shader reflection data to save.

Returns

True if the shader was saved successfully, False if an error occurred.

Return type

bool

SelectPipelineStage(stage)

Select a given pipeline stage in the viewer.

Parameters

stage# (PipelineStage) – The stage to select.

Widget()

Retrieves the PySide2 QWidget for this PipelineStateViewer if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Texture Viewer

class qrenderdoc.FollowType(value)

Specifies a type of followed resource for the TextureViewer.

OutputColor

The index specifies which output color target to select. Shader stage and array index are ignored.

OutputDepth

The resource followed is the depth/stencil output target. All other parameters are ignored.

ReadWrite

The index specifies a resource within the given shader’s read-write resources. The array element then specifies the index within that resource’s array, if applicable.

ReadOnly

The index specifies a resource within the given shader’s read-only resources. The array element then specifies the index within that resource’s array, if applicable.

class qrenderdoc.TextureViewer

The texture viewer window.

GetChannelVisibilityBits()

Return which channels are currently displayed, as a bitmask.

If red is visible 0x1 will be set in the returned value, if blue is visible 0x2 will be set, etc.

Returns

The current bitmask showing channel visibility.

Return type

int

GetCurrentResource()

Return which resource is currently being displayed in the active tab.

Returns

The ID of the resource being displayed.

Return type

renderdoc.ResourceId

GetHistogramRange()

Return the current histogram blackpoint to whitepoint range.

Returns

The current histogram range.

Return type

Tuple[float,float]

GetSelectedSubresource()

Return which subresource is currently selected for viewing.

Returns

The subresource currently selected.

Return type

renderdoc.Subresource

GetTextureOverlay()

Return the currently selected texture overlay.

Returns

The currently selected texture overlay.

Return type

renderdoc.DebugOverlay

GetZoomLevel()

Return the current zoom level, whether manually set or auto-calculated.

Returns

The current zoom level, with 100% being represented as 1.0.

Return type

float

GotoLocation(x, y)

Highlights the given pixel location in the current texture.

Parameters
  • x# (int) – The X co-ordinate.

  • y# (int) – The Y co-ordinate.

IsZoomAutoFit()

Return whether or not the texture viewer is currently auto-fitting the zoom level.

Returns

True if the zoom level is currently auto-fitting.

Return type

bool

SetChannelVisibility(red, green, blue, alpha)

Set the visibility of each channel.

Parameters
  • red# (bool) – Whether the red channel should be visible.

  • green# (bool) – Whether the green channel should be visible.

  • blue# (bool) – Whether the blue channel should be visible.

  • alpha# (bool) – Whether the alpha channel should be visible.

SetHistogramRange(blackpoint, whitepoint)

Set the current histogram blackpoint to whitepoint range.

Parameters
  • blackpoint# (float) – The value that should be mapped to black, component-wise.

  • whitepoint# (float) – The value that should be mapped to white, component-wise.

SetSelectedSubresource(sub)

Select a particular subresource within the currently selected texture. Any out of bounds parameters will be clamped to the available subresources.

Parameters

sub# (renderdoc.Subresource) – The subresource to select.

SetTextureOverlay(overlay)

Changes the currently selected overlay the given pixel location in the current texture.

Parameters

overlay# (renderdoc.DebugOverlay) – The overlay to enable.

SetZoomLevel(autofit, zoom)

Set the zoom level for displaying textures.

Parameters
  • autofit# (bool) – True if the zoom level should be auto-calculated continuously to automatically fit the texture completely in view.

  • zoom# (float) – The zoom level as a percentage, with 100% being 1.0. Ignored if autofit is True.

ViewFollowedResource(followType, stage, index, arrayElement)

Select the ‘following’ view and choose which resource slot to follow.

Parameters
  • followType# (FollowType) – The type of followed resource.

  • stage# (renderdoc.ShaderStage) – The shader stage of the shader reflection data to look up.

  • index# (int) – The index within the given resource list (if applicable) to follow.

  • arrayElement# (int) – The index within the given resource array (if applicable) to follow.

ViewTexture(resourceId, typeCast, focus)

Open a texture view, optionally raising this window to the foreground.

Parameters
  • resourceId# (renderdoc.ResourceId) – The ID of the texture to view.

  • typeCast# (renderdoc.CompType) – If possible interpret the texture with this type instead of its normal type. If set to Typeless then no cast is applied, otherwise where allowed the texture data will be reinterpreted - e.g. from unsigned integers to floats, or to unsigned normalised values.

  • focus# (bool) – True if the TextureViewer should be raised.

Widget()

Retrieves the PySide2 QWidget for this TextureViewer if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Buffer Viewer

class qrenderdoc.BufferViewer

The buffer viewer window, either a raw buffer or the geometry pipeline.

ScrollToColumn(column, stage)
ScrollToColumn(column)None

Scroll to the given column in the given stage’s data.

Parameters
  • column# (int) – the column to scroll to.

  • stage# (renderdoc.MeshDataStage) – The stage of the geometry pipeline to scroll within.

ScrollToRow(row, stage)
ScrollToRow(row)None

Scroll to the given row in the given stage’s data.

Parameters
  • row# (int) – the row to scroll to.

  • stage# (renderdoc.MeshDataStage) – The stage of the geometry pipeline to scroll within.

SetCurrentInstance(instance)

For a mesh view, set the current instance. This is ignored when called on a raw buffer view.

Parameters

instance# (int) – The instance to select, will be clamped to the range [0, numInstances-1]

SetCurrentView(view)

For a mesh view, set the current multiview view. This is ignored when called on a raw buffer view.

Parameters

view# (int) – The view to select, will be clamped to the range [0, numViews-1]

SetPreviewStage(stage)

For a mesh view, set the current preview stage. This is ignored when called on a raw buffer view.

Parameters

stage# (renderdoc.MeshDataStage) – The stage to show

Widget()

Retrieves the PySide2 QWidget for this BufferViewer if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Resource Inspector

class qrenderdoc.ResourceInspector

The Resource inspector window.

CurrentResource()

Return which resource is currently being inspected.

Returns

The ID of the resource being inspected.

Return type

renderdoc.ResourceId

Inspect(id)

Change the current resource being inspected.

Parameters

id# (renderdoc.ResourceId) – The ID of the resource to inspect.

RevealParameter(param)

Expand the resource initialisation chunks to reveal and select a given parameter.

Parameters

param# (renderdoc.SDObject) – The parameter to reveal and select.

Widget()

Retrieves the PySide2 QWidget for this ResourceInspector if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Capture Dialog

class qrenderdoc.CaptureDialog

The executable capture window.

IsInjectMode()

Determines if the window is in inject or launch mode.

Returns

True if the window is set up for injecting.

Return type

bool

LoadSettings(filename)

Loads settings from a file and applies them. See SetSettings().

Parameters

filename# (str) – The filename to load the settings from.

SaveSettings(filename)

Saves the current settings to a file. See Settings().

Parameters

filename# (str) – The filename to save the settings to.

SetCommandLine(cmd)

Sets the command line string to use when launching an executable.

Parameters

cmd# (str) – The command line to use.

SetEnvironmentModifications(modifications)

Sets the list of environment modifications to apply when launching.

Parameters

modifications# (List[renderdoc.EnvironmentModification]) – The list of modifications to apply.

SetExecutableFilename(filename)

Sets the executable filename to capture.

Parameters

filename# (str) – The filename to execute.

SetInjectMode(inject)

Switches the window to or from inject mode.

Parameters

inject# (bool) – True if the window should configure for injecting into processes.

SetSettings(settings)

Configures the window based on a bulk structure of settings.

Parameters

settings# (CaptureSettings) – The settings to apply.

SetWorkingDirectory(dir)

Sets the working directory for capture.

Parameters

dir# (str) – The directory to use.

Settings()

Retrieves the current state of the window as a structure of settings.

Returns

The settings describing the current window state.

Return type

CaptureSettings

TriggerCapture()

Launches a capture of the current executable.

UpdateGlobalHook()

Update the current state of the global hook, e.g. if it has been enabled.

UpdateRemoteHost()

Update the current state based on the current remote host, when that changes.

Widget()

Retrieves the PySide2 QWidget for this CaptureDialog if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Debug Messages

class qrenderdoc.DebugMessageView

The debug warnings and errors window.

Widget()

Retrieves the PySide2 QWidget for this DebugMessageView if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Diagnostic Log

class qrenderdoc.DiagnosticLogView

The diagnostic log viewing window.

Widget()

Retrieves the PySide2 QWidget for this DiagnosticLogView if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Comment View

class qrenderdoc.CommentView

The capture comments window.

GetComments()

Gets the current comments text.

Returns

The current comments text.

Return type

str

SetComments(text)

Sets the current comments text.

Parameters

text# (str) – The new comments text.

Widget()

Retrieves the PySide2 QWidget for this CommentView if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Statistics Viewer

class qrenderdoc.StatisticsViewer

The statistics window.

Widget()

Retrieves the PySide2 QWidget for this StatisticsViewer if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Timeline Bar

class qrenderdoc.TimelineBar

The timeline bar.

HighlightHistory(id, history)

Highlights the modifications in a frame of a given resource.

Parameters
HighlightResourceUsage(id)

Highlights the frame usage of the specified resource.

Parameters

id# (renderdoc.ResourceId) – The ID of the resource to highlight.

Widget()

Retrieves the PySide2 QWidget for this TimelineBar if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Performance Counter Viewer

class qrenderdoc.PerformanceCounterViewer

The performance counter view window.

Widget()

Retrieves the PySide2 QWidget for this PerformanceCounterViewer if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Python Shell

class qrenderdoc.PythonShell

The interactive python shell.

Widget()

Retrieves the PySide2 QWidget for this PythonShell if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Shader Viewer

class qrenderdoc.ShaderViewer

A shader window used for viewing, editing, or debugging.

SaveCallback(context, viewer, encoding, flags, entry, compiled)

Not a member function - the signature for any SaveCallback callbacks.

Called whenever a shader viewer that was open for editing triggers a save/update.

Parameters
CloseCallback(context)

Not a member function - the signature for any CloseCallback callbacks.

Called whenever a shader viewer that was open for editing is closed.

Parameters
AddWatch(expression)

Add an expression to the watch panel.

Parameters

expression# (str) – The name of the expression to watch.

CurrentStep()

Retrieves the current step in the debugging.

Returns

The current step.

Return type

int

GetCurrentFileContents()

Return the current text of source files within the viewer. Primarily useful for returning any edits applied when editing a shader.

Returns

The current file contents as a list of (filename, contents) pairs.

Return type

List[Tuple[str,str]]

RunForward()

Runs execution forward to the next breakpoint, or the end of the trace.

SetCurrentStep(step)

Sets the current step in the debugging.

Parameters

step# (int) – The current step to jump to.

ShowErrors(errors)

Show a list of shader compilation errors or warnings.

Parameters

errors# (str) – The string of errors or warnings to display.

ToggleBreakpointOnDisassemblyLine(disassemblyLine)

Toggles a breakpoint at a given disassembly line (starting from 1).

Parameters

disassemblyLine# (int) – The line of the disassembly to toggle a breakpoint on.

ToggleBreakpointOnInstruction(instruction=- 1)
ToggleBreakpointOnInstruction()None

Toggles a breakpoint at a given instruction.

Parameters

instruction# (int) – The instruction to toggle breakpoint at. If this is -1 the nearest instruction after the current caret position is used.

Widget()

Retrieves the PySide2 QWidget for this ShaderViewer if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Constant Buffer Previewer

class qrenderdoc.ConstantBufferPreviewer

A constant buffer preview window.

Widget()

Retrieves the PySide2 QWidget for this ConstantBufferPreviewer if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Pixel History

class qrenderdoc.PixelHistoryView

A pixel history window.

SetHistory(history)

Set the history displayed in this window.

Parameters

history# (List[renderdoc.PixelModification]) – A list of pixel events to display.

Widget()

Retrieves the PySide2 QWidget for this PixelHistoryView if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget

Shader Message Viewer

class qrenderdoc.ShaderMessageViewer

A shader message list window.

GetEvent()

Return the EID that this viewer is displaying messages from.

Returns

The EID.

Return type

int

GetShaderMessages()

Return the shader messages displayed in this viewer.

Returns

The shader messages.

Return type

List[renderdoc.ShaderMessage]

IsOutOfDate()

Returns whether or not this viewer is out of date - if the shaders have been edited since the messages were fetched.

Returns

True if the viewer is out of date.

Return type

bool

Widget()

Retrieves the PySide2 QWidget for this ShaderMessageViewer if PySide2 is available, or otherwise returns a unique opaque pointer that can be passed back to any RenderDoc functions expecting a QWidget.

Returns

Return the widget handle, either a PySide2 handle or an opaque handle.

Return type

QWidget