Usage Patterns
Basic Workflow
rdc open capture.rdc # start daemon, load capture
rdc info # show capture metadata
rdc draws # list draw calls (TSV)
rdc pipeline 142 # pipeline state at event 142
rdc shader 142 ps # pixel shader disassembly
rdc close # stop daemon Piping and Filtering
Default TSV output is designed for Unix pipes:
# Find draw calls with "Triangle" in the name
rdc draws | grep Triangle
# Get just event IDs
rdc draws | cut -f1
# Count draw calls
rdc draws | wc -l
# Sort resources by name
rdc resources --sort name JSON Mode
Add --json to any command for structured output:
# Pretty-print pipeline state
rdc pipeline 142 --json | jq .
# Extract shader entry point
rdc pipeline 142 vs --json | jq '.entryPoint'
# Filter draws by flag
rdc draws --json | jq '.[] | select(.flags | contains("Drawcall"))' CI / Automation
rdc-cli is designed for CI pipelines and agent-driven workflows:
# Assert a capture has expected draw count
test $(rdc draws | wc -l) -ge 5
# Export all textures for visual regression
for id in $(rdc resources --type texture | cut -f1); do
rdc texture "$id" -o "textures/$id.png"
done
# Structured output for downstream processing
rdc draws --json > draws.json
rdc pipeline 5 --json > pipeline.json VFS Browsing
Browse capture data like a filesystem:
# List top-level nodes
rdc ls /
# Browse a specific draw call
rdc ls /draws/142/
# Read shader source directly
rdc cat /draws/142/shader/ps/disasm
# Show full tree (limited depth)
rdc tree / --depth 2 Search
# Search shader disassembly for a pattern
rdc search "main"
# Filter by shader stage
rdc search "shadowMap" --stage ps
# With context lines
rdc search "textureSample" -C 3 GPU Counters
# List available hardware counters
rdc counters --list
# Fetch counter values for all events
rdc counters Resource Usage Tracking
# See where a resource is used across the frame
rdc usage 5
# Show all resource usage
rdc usage --all Pass Analysis
rdc passes shows 6 columns: NAME, DRAWS, DISPATCHES, TRIANGLES, BEGIN_EID, END_EID.
GL/GLES/D3D11 captures get synthetic pass inference automatically.
# Tabular pass summary
rdc passes
# Per-pass dependency graph (reads/writes/load/store)
rdc passes --deps --table
# Add RT_SWITCHES column for TBR/mobile bandwidth analysis
rdc passes --switches
# Inspect attachments, load/store ops, and dimensions for a pass
rdc pass GBuffer
# JSON output — includes load_ops/store_ops per pass
rdc passes --json | jq '.[] | { name: .name, load: .load_ops, store: .store_ops }' Dead Render Target Detection
# List render targets written but never sampled/read
rdc unused-targets
# JSON output for scripted analysis
rdc unused-targets --json | jq '.[].name'