Skip to main content
Glama

ブレンダーオープンMCP

blender-open-mcp Model Context Protocol (MCP) を用いて Blender とローカル AI モデル ( Ollama経由) を統合するオープンソース プロジェクトです。これにより、自然言語プロンプトで Blender を操作し、AI の力を活用して 3D モデリング作業を支援することができます。

特徴

  • **自然言語で Blender を制御する:**ローカルで実行されている Ollama モデルにプロンプトを送信して、Blender でアクションを実行します。

  • MCP 統合: AI モデルと Blender 間の構造化された通信にモデル コンテキスト プロトコルを使用します。

  • Ollama サポート: Ollama と連携してローカル モデルの管理を容易にするように設計されています。

  • **Blender アドオン:**ユーザー インターフェイスを提供し、サーバーとの通信を処理する Blender アドオンが含まれています。

  • PolyHaven 統合 (オプション): AI プロンプトを介して、 PolyHavenから Blender 内で直接アセット (HDRI、テクスチャ、モデル) をダウンロードして使用します。

  • 基本的な3D操作:

    • シーンとオブジェクトの情報を取得する

    • プリミティブを作成する

    • オブジェクトの変更と削除

    • 材料を適用する

  • **レンダリング サポート:**ツールを使用して画像をレンダリングし、出力に基づいて情報を取得します。

Related MCP server: SupaUI MCP Server

インストール

前提条件

  1. Blender: Blender 3.0以降。blender.orgからダウンロードしてください

  2. Ollama: OS 固有の指示に従って、 ollama.comからインストールします。

  3. Python: Python 3.10 以降。

  4. uv: pip install uvを使用してインストールします。

  5. **Git:**リポジトリのクローンを作成するために必要です。

インストール手順

  1. リポジトリをクローンします。

    git clone https://github.com/dhakalnirajan/blender-open-mcp.git cd blender-open-mcp
  2. 仮想環境を作成してアクティブ化する(推奨):

    uv venv source .venv/bin/activate # On Linux/macOS .venv\Scripts\activate # On Windows
  3. 依存関係をインストールします:

    uv pip install -e .
  4. Blenderアドオンをインストールします。

    • Blender を開きます。

    • Edit -> Preferences -> Add-onsに移動します。

    • Install...をクリックします。

    • blender-open-mcpディレクトリからaddon.pyファイルを選択します。

    • 「Blender MCP」アドオンを有効にします。

  5. Ollama モデルをダウンロードします (まだインストールされていない場合)。

    ollama run llama3.2

    *( **Gemma3*などの他のモデルも使用可能です。)

設定

  1. Ollama サーバーを起動します。Ollamaがバックグラウンドで実行されていることを確認します。

  2. MCP サーバーを起動します。

    blender-mcp

    または、

    python src/blender_open_mcp/server.py

    デフォルトではhttp://0.0.0.0:8000をリッスンしますが、設定を変更できます。

    blender-mcp --host 127.0.0.1 --port 8001 --ollama-url http://localhost:11434 --ollama-model llama3.2
  3. Blender アドオン サーバーを起動します。

    • Blender と 3D ビューポートを開きます。

    • サイドバーを開くにはNを押します。

    • 「Blender MCP」パネルを見つけます。

    • 「MCP サーバーを起動」をクリックします。

使用法

mcpコマンドライン ツールを使用してblender-open-mcpを操作します。

コマンド例

  • 基本プロンプト:

    mcp prompt "Hello BlenderMCP!" --host http://localhost:8000
  • シーン情報を取得:

    mcp tool get_scene_info --host http://localhost:8000
  • キューブを作成する:

    mcp prompt "Create a cube named 'my_cube'." --host http://localhost:8000
  • イメージをレンダリングする:

    mcp prompt "Render the image." --host http://localhost:8000
  • PolyHaven の使用 (有効な場合):

    mcp prompt "Download a texture from PolyHaven." --host http://localhost:8000

利用可能なツール

ツール名

説明

パラメータ

get_scene_info

シーンの詳細を取得します。

なし

get_object_info

オブジェクトに関する情報を取得します。

object_name

(文字列)

create_object

3D オブジェクトを作成します。

type

name

location

rotation

scale

modify_object

オブジェクトのプロパティを変更します。

name

location

rotation

scale

visible

delete_object

オブジェクトを削除します。

name

(文字列)

set_material

オブジェクトにマテリアルを割り当てます。

object_name

material_name

color

render_image

画像をレンダリングします。

file_path

(文字列)

execute_blender_code

Blender で Python コードを実行します。

code

(文字列)

get_polyhaven_categories

PolyHaven 資産カテゴリを一覧表示します。

asset_type

(文字列)

search_polyhaven_assets

PolyHaven アセットを検索します。

asset_type

categories

download_polyhaven_asset

PolyHaven アセットをダウンロードします。

asset_id

asset_type

resolution

file_format

set_texture

ダウンロードしたテクスチャを適用します。

object_name

texture_id

set_ollama_model

Ollama モデルを設定します。

model_name

(文字列)

set_ollama_url

Ollama サーバーの URL を設定します。

url

(文字列)

get_ollama_models

利用可能な Ollama モデルを一覧表示します。

なし

トラブルシューティング

問題が発生した場合:

  • Ollama とblender-open-mcpサーバーが実行されていることを確認します。

  • Blenderのアドオン設定を確認してください。

  • コマンドライン引数を確認します。

  • エラーの詳細についてはログを参照してください。

さらにサポートが必要な場合は、 GitHub の問題ページをご覧ください。


AIとのブレンディングを楽しみましょう!🚀

-
security - not tested
F
license - not found
-
quality - not tested

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/dhakalnirajan/blender-open-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server