Metadata-Version: 2.4
Name: renderdoc-mcp
Version: 0.2.3
Summary: MCP server for RenderDoc graphics debugger - enables AI-assisted frame capture analysis
Requires-Python: ==3.13.*
Description-Content-Type: text/markdown
Requires-Dist: mcp[cli]>=1.0.0

# renderdoc-mcp

MCP server for [RenderDoc](https://renderdoc.org/) — let AI assistants analyze GPU frame captures (`.rdc` files) for graphics debugging and performance analysis.

> **Platform**: Windows x64 only.
>
> **Python**: Requires Python 3.13 exactly. The bundled `renderdoc.pyd` is compiled for Python 3.13, and the compile-time and runtime Python versions must match exactly.

## Prerequisites

- **Python 3.13** — [python.org/downloads](https://www.python.org/downloads/)
- **uv** — [docs.astral.sh/uv/getting-started/installation](https://docs.astral.sh/uv/getting-started/installation/)

```bash
# verify
python --version   # Python 3.13.12
uv --version       # uv 0.10.9
```

## Configuration

No manual installation needed. Add to your MCP client configuration and `uvx` will handle the rest:

**Kiro** (`~/.kiro/settings/mcp.json`):
```json
{
  "mcpServers": {
    "renderdoc": {
      "command": "uvx",
      "args": ["--python", "3.13", "renderdoc-mcp"]
    }
  }
}
```

**Claude Desktop** (`claude_desktop_config.json`):
```json
{
  "mcpServers": {
    "renderdoc": {
      "command": "uvx",
      "args": ["--python", "3.13", "renderdoc-mcp"]
    }
  }
}
```

`--python 3.13` is required — the bundled `renderdoc.pyd` is compiled for Python 3.13 and the compile-time and runtime versions must match exactly.

## Usage

Just talk to your AI assistant:

> "简单介绍下 renderdoc-mcp 所有的工具及作用"

> "打开 frame.rdc 看看这一帧在做什么"

> "找到渲染角色模型的 draw call，检查它的管线状态"

> "为什么我的阴影贴图是黑的？检查深度 pass"

> "分析性能，有没有冗余的 draw call？"

## Tools (42)

**Session** — open/close captures, frame overview, GPU quirk detection

**Event Navigation** — list/search/navigate draw calls and actions

**Pipeline Inspection** — full pipeline state, shader bindings, vertex inputs, one-call draw analysis

**Resource Analysis** — enumerate textures, buffers, resources and their usage

**Data Extraction** — export textures/meshes/render targets, read pixels, buffer data

**Shader Analysis** — disassembly, reflection, constant buffer contents

**Advanced** — pixel history, draw call diff, render pass analysis, pixel region scan, per-pixel shader debug

**Performance** — pass timing, overdraw, bandwidth, state change analysis

**Diagnostics** — negative/NaN/Inf detection, precision issues, reflection mismatch, mobile GPU risks

## Prompts

| Prompt | Description |
|--------|-------------|
| `debug_draw_call` | Deep-dive a single draw call |
| `find_rendering_issue` | Systematic diagnosis from a problem description |
| `analyze_performance` | Frame-wide performance analysis |

## How It Works

```
AI Assistant <--MCP--> renderdoc-mcp <--Python API--> renderdoc.pyd <-> GPU replay
```

All required RenderDoc DLLs and `renderdoc.pyd` are bundled — no separate RenderDoc installation needed.

## Troubleshooting

**`ImportError: DLL load failed`** — verify Python 3.13 is being used; check antivirus is not blocking bundled DLLs.

**Server won't start** — check MCP client logs; confirm `python --version` is 3.13.

## License

MIT
