Python API¶
RenderDoc exposes a significant amount of functionality to custom python scripting. This documentation will walk you through how to get started, showing examples of one-off scripts and permanent UI extensions.
Scripting this way can help automate or simplify common patterns you use, and personalise RenderDoc for your specific needs or wants.
RenderDoc’s internal APIs are exposed directly to python, meaning any feature exposed in the UI will be accessible in some way to python as well. Many aspects of the UI itself are also accessible, and that can be extended in future by request.
It’s assumed that you have a basic familiarity with python or can learn the syntax.
- Tutorial: First Steps with Python
- Tutorial: UI extensions
- Python IDE integration
- Python FAQ
- What can I do if I hit a crash while running my python script?
- Is there a more useful object preview in the REPL/print?
- Why can’t I see the new UI panel I created?
- Can I run python scripts from the command line?
- What version compatibility guarantees does python API provide?
- Can I get more access to the UI for customisation?
- Can I get callbacks when captures are loaded/closed or events are selected?
- Can I access these APIs in C++?
- Can I freely modify and use data I obtain from the APIs?
- Can I use Python scripting together with Android?
- Why doesn’t VS Code apply breakpoints or catch exceptions properly?
- Why do the examples have a preamble for
pyrenderdoc?
- Python Examples
- Example: Show buffer with format
- Example: Show and save a texture
- Example: Iterating over Actions
- Example: Pipeline State
- Example: Shader Reflection
- Example: Resource Usage
- Example: Memory bindings
- Example: Pixel History & Shader Debug
- Example: Mesh Output
- Example: Advanced Buffers
- Example: Launching an application
- Example: Adding a custom event browser filter
- Further Reading on Python Scripting
- Using Python Module Manually
- API Reference:
renderdoc - API Reference:
qrenderdoc