blender-mcp-bridge

blender-mcp-bridge

Enables natural language control of Blender via Claude by converting MCP JSON-RPC calls to Blender's custom TCP protocol for scene manipulation, object creation, and Python execution.

Category
Visit Server

README

blender-mcp-bridge

Blender 公式 MCP アドオン(TCP port 9876)と Claude Desktop(stdio MCP)を繋ぐブリッジ。

なぜこのアプリが必要か

Blender の公式アドオンは「MCP アドオン」と呼ばれていますが、現時点では標準 MCP プロトコル(JSON-RPC 2.0)を実装していないようです。内部は独自の TCP プロトコルで、{"type": "execute", "code": "..."} という形式で Python コードを受け取って実行するものです。

Claude Desktop は標準 MCP(JSON-RPC 2.0)でしか動かないため、そのままでは Blender に接続できません。

blender-mcp-bridge はその間に入り、標準 MCP のツール呼び出しを Blender の独自プロトコルに変換して転送します。

Claude Desktop
    │ stdio (MCP JSON-RPC 2.0)  ← Claude が話せる形式
    ▼
blender-mcp-bridge              ← このアプリ(変換・転送)
    │ TCP socket (port 9876)    ← Blender アドオンが受け付ける形式
    ▼
Blender アドオン

前提条件

Python 3.10 以上が必要です。Mac のデフォルト(python3)は 3.9 のことがあるため、事前に確認してください。

python3 --version

3.9 以下の場合は先に Python をインストールしてください:

  • 方法1(推奨): python.org から .pkg をダウンロードしてインストール
  • 方法2: Homebrew がある場合は brew install python@3.12
  • 方法3: pyenv がある場合は pyenv install 3.12

インストール後は python3.12 --version で確認し、以降のコマンドで python3 の代わりに python3.12 を使ってください。

セットアップ

Claude Code を使う場合(推奨)

このリポジトリを Claude Code で開き、スラッシュコマンドを実行するだけで完了します:

/setup

これにより以下が自動で行われます:

  • mcp ライブラリのインストール
  • Claude Code CLI(~/.claude.json)への blender サーバー登録
  • Claude Desktop(claude_desktop_config.json)への blender サーバー登録

手動でセットアップする場合

# 1. セットアップスクリプトを実行
python3 scripts/setup.py

# Python 3.9 以下の場合はバージョン指定で実行
python3.12 scripts/setup.py

スクリプトは以下を自動で行います:

  • mcp ライブラリのインストール
  • claude mcp add で Claude Code CLI に登録
  • claude_desktop_config.json を書き換えて Claude Desktop に登録

完了後は Claude Desktop を再起動してください。

JSON を直接書く場合

claude_desktop_config.json を開き、以下を追加します。

Mac (~/Library/Application Support/Claude/claude_desktop_config.json):

{
  "mcpServers": {
    "blender": {
      "command": "python3",
      "args": ["/path/to/blender-mcp-bridge/bridge.py"]
    }
  }
}

Windows (%APPDATA%\Claude\claude_desktop_config.json):

{
  "mcpServers": {
    "blender": {
      "command": "python",
      "args": ["C:\\path\\to\\blender-mcp-bridge\\bridge.py"]
    }
  }
}

使い方

  1. Blender MCP アドオンを Blender にインストール・有効化する
  2. Blender を起動する(アドオンが port 9876 でリッスン開始)
  3. Claude Desktop または Claude Code を再起動する
  4. Claude から「Blender のシーン情報を教えて」などと話しかける

仕組み:接続先の指定

bridge は起動時に環境変数 BLENDER_HOST / BLENDER_PORT を読み取り、接続先の Blender アドオンを決定します。

bridge 起動
  ↓ 環境変数を読む
  BLENDER_HOST=localhost  (デフォルト)
  BLENDER_PORT=9876       (デフォルト)
  ↓ TCP 接続
Blender アドオン (localhost:9876)

この環境変数は OS に設定するのではなく、MCP の設定ファイル(または claude mcp add コマンド)でブリッジ起動時に渡します。デフォルトの localhost:9876 で通常は変更不要です。

claude mcp add(Claude Code CLI)で変更する場合:

claude mcp add blender \
  --env BLENDER_HOST=localhost \
  --env BLENDER_PORT=9876 \
  -- python3 /path/to/bridge.py

ツール一覧

ツール名 説明
blender/get_scene_info アクティブシーンの名前・オブジェクト数・フレーム情報を返す
blender/list_objects シーン内オブジェクト一覧を返す(type でフィルタ可)
blender/get_object 指定オブジェクトの位置・回転・スケール・マテリアルを返す
blender/create_object メッシュ・ライト・カメラ等を作成する
blender/delete_object 指定オブジェクトを削除する
blender/transform_object 位置・回転・スケールを変更する(部分更新可)
blender/set_material Principled BSDF マテリアルをオブジェクトに設定する
blender/execute_python 任意の Python コードを Blender 内で実行する

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured