blender-mcp

GitHub

驱动运行中Blender实例的MCP技能,通过bpy脚本创建或修改网格、材质、动画等。需安装MCP服务器及插件,连接后利用工具获取场景信息并执行Python代码,支持可视化验证与资产服务集成。

optional-skills/creative/blender-mcp/SKILL.md NousResearch/hermes-agent

Trigger Scenarios

用户希望在Blender中创建或修改3D内容 需要自动化操作Blender场景中的对象、材质或灯光 请求生成或调整Blender动画和渲染设置

Install

npx skills add NousResearch/hermes-agent --skill blender-mcp -g -y
More Options

Non-standard path

npx skills add https://github.com/NousResearch/hermes-agent/tree/main/optional-skills/creative/blender-mcp -g -y

Use without installing

npx skills use NousResearch/hermes-agent@blender-mcp

指定 Agent (Claude Code)

npx skills add NousResearch/hermes-agent --skill blender-mcp -a claude-code -g -y

安装 repo 全部 skill

npx skills add NousResearch/hermes-agent --all -g -y

预览 repo 内 skill

npx skills add NousResearch/hermes-agent --list

SKILL.md

Frontmatter
{
    "name": "blender-mcp",
    "tags": [
        "blender",
        "3d",
        "animation",
        "modeling",
        "bpy",
        "mcp"
    ],
    "author": "alireza78a + kshitijk4poor + Hermes Agent",
    "version": "2.1.0",
    "requires": "Blender 3.0+ desktop instance (headless via xvfb-run)",
    "platforms": [
        "linux",
        "macos",
        "windows"
    ],
    "description": "Drive Blender via the catalog blender MCP, with bpy recipes."
}

Blender MCP Skill

Companion skill for the blender entry in the Hermes MCP catalog. The MCP server provides the connection to Blender; this skill teaches the bpy idioms and pitfalls for driving it well. It does not cover Blender UI workflows — everything here goes through the MCP tools against a live Blender session.

When to Use

Use when the user wants to create or modify anything in a running Blender instance: meshes, materials, animations, lighting, renders. Requires the blender MCP server installed and a Blender desktop session with the addon connected.

Prerequisites

  1. Install the MCP server from the Nous catalog (one-time):

    hermes mcp install blender
    

    This configures the pinned blender-mcp stdio server with the curated tool set: get_scene_info, get_object_info, get_viewport_screenshot, execute_blender_code.

  2. Install the addon inside Blender (one-time — the catalog entry's post-install notes cover this too):

  3. Every session: start Blender FIRST, press N in the viewport, open the "BlenderMCP" tab, click "Connect to Claude" (starts the local bridge socket). Then start your Hermes session so the MCP tools are loaded.

    The addon refuses to start under blender -b (background mode). On a machine without a display, run Blender under a virtual one: xvfb-run blender. GPU rendering works fine under Xvfb.

Quick Reference

MCP tool Use for
get_scene_info List objects before touching the scene
get_object_info Inspect one object (transform, materials)
get_viewport_screenshot Visual check of what you built
execute_blender_code Everything else — arbitrary bpy Python

Deeper material lives in the reference files (load on demand):

Reference Contents
references/bpy-api.md Essential bpy operations: modeling, materials, modifiers, rendering
references/recipes.md Complete working scenes: low-poly terrain, glass sphere, HDRI lighting, turntable animation
references/pitfalls.md Hard-won lessons: empty code results in 5.x, ops-vs-data API, engine names by version

Optional asset-service tools (PolyHaven, Sketchfab, Hyper3D, Hunyuan3D) are disabled by default. If the user has enabled a service in the addon panel, opt into its tools with hermes mcp configure blender.

Procedure

  1. Call get_scene_info first — never assume the scene is empty.
  2. Build with execute_blender_code, in small focused calls (one logical step per call: add objects, then materials, then animation). Large monolithic scripts hit the bridge timeout.
  3. Verify visually with get_viewport_screenshot between major steps.
  4. Render to an absolute path and tell the user where the file is.

Common bpy Patterns

Clear scene:

bpy.ops.object.select_all(action='SELECT')
bpy.ops.object.delete()

Add mesh objects:

bpy.ops.mesh.primitive_uv_sphere_add(radius=1, location=(0, 0, 0))
bpy.ops.mesh.primitive_cube_add(size=2, location=(3, 0, 0))
bpy.ops.mesh.primitive_cylinder_add(radius=0.5, depth=2, location=(-3, 0, 0))

Create and assign material:

mat = bpy.data.materials.new(name="MyMat")
mat.use_nodes = True
bsdf = mat.node_tree.nodes.get("Principled BSDF")
bsdf.inputs["Base Color"].default_value = (R, G, B, 1.0)
bsdf.inputs["Roughness"].default_value = 0.3
bsdf.inputs["Metallic"].default_value = 0.0
obj.data.materials.append(mat)

Keyframe animation:

obj.location = (0, 0, 0)
obj.keyframe_insert(data_path="location", frame=1)
obj.location = (0, 0, 3)
obj.keyframe_insert(data_path="location", frame=60)

Render to file:

bpy.context.scene.render.filepath = "/tmp/render.png"
bpy.context.scene.render.engine = 'CYCLES'
bpy.ops.render.render(write_still=True)

Pitfalls

  • The blender MCP tools only exist if the server is installed and the session started after install. If they're missing, run hermes mcp install blender and start a new session.
  • The addon bridge must be (re)connected inside Blender each Blender session (N-panel > BlenderMCP > Connect). "Connection refused" from the tools means Blender isn't running or the addon isn't connected — fix that, don't retry.
  • Break complex scenes into multiple smaller execute_blender_code calls to avoid bridge timeouts.
  • Render output paths must be absolute (/tmp/render.png), not relative — they resolve on the BLENDER host's filesystem, which matters if Hermes and Blender run on different machines.
  • shade_smooth() requires the object to be selected and in object mode.
  • execute_blender_code runs arbitrary Python inside Blender with no sandbox — same trust level as the terminal tool. Don't paste untrusted code into it.
  • Do NOT hand-roll raw TCP JSON to port 9876 from execute_code — that was this skill's pre-MCP workaround. It bypasses the catalog's version pinning and tool curation. The MCP tools are the supported path.

Verification

  • get_scene_info returns the expected object list after each build step.
  • get_viewport_screenshot shows the scene you intended.
  • After a render, confirm the output file exists and report its absolute path to the user.

Version History

  • e0dfcf2 Current 2026-07-25 11:34

Same Skill Collection

optional-skills/autonomous-ai-agents/antigravity-cli/SKILL.md
optional-skills/autonomous-ai-agents/blackbox/SKILL.md
optional-skills/autonomous-ai-agents/grok/SKILL.md
optional-skills/autonomous-ai-agents/honcho/SKILL.md
optional-skills/autonomous-ai-agents/openhands/SKILL.md
optional-skills/blockchain/evm/SKILL.md
optional-skills/blockchain/hyperliquid/SKILL.md
optional-skills/blockchain/solana/SKILL.md
optional-skills/creative/audiocraft-audio-generation/SKILL.md
optional-skills/creative/baoyu-article-illustrator/SKILL.md
optional-skills/creative/baoyu-comic/SKILL.md
optional-skills/creative/concept-diagrams/SKILL.md
optional-skills/creative/creative-ideation/SKILL.md
optional-skills/creative/heartmula/SKILL.md
optional-skills/creative/kanban-video-orchestrator/SKILL.md
optional-skills/creative/meme-generation/SKILL.md
optional-skills/creative/pixel-art/SKILL.md
optional-skills/creative/tldraw-offline/SKILL.md
optional-skills/creative/unreal-mcp/SKILL.md
optional-skills/data-science/jupyter-notebook/SKILL.md
optional-skills/devops/cli/SKILL.md
optional-skills/devops/docker-management/SKILL.md
optional-skills/devops/hermes-s6-container-supervision/SKILL.md
optional-skills/devops/pinggy-tunnel/SKILL.md
optional-skills/devops/watchers/SKILL.md
optional-skills/dogfood/adversarial-ux-test/SKILL.md
optional-skills/finance/3-statement-model/SKILL.md
optional-skills/finance/comps-analysis/SKILL.md
optional-skills/finance/dcf-model/SKILL.md
optional-skills/finance/excel-author/SKILL.md
optional-skills/finance/lbo-model/SKILL.md
optional-skills/finance/stocks/SKILL.md
optional-skills/gaming/minecraft-modpack-server/SKILL.md
optional-skills/health/fitness-nutrition/SKILL.md
optional-skills/health/neuroskill-bci/SKILL.md
optional-skills/mcp/mcp-oauth-remote-gateway/SKILL.md
optional-skills/mcp/mcporter/SKILL.md
optional-skills/migration/openclaw-migration/SKILL.md
optional-skills/mlops/accelerate/SKILL.md
optional-skills/mlops/clip/SKILL.md
optional-skills/mlops/flash-attention/SKILL.md
optional-skills/mlops/guidance/SKILL.md
optional-skills/mlops/huggingface-tokenizers/SKILL.md
optional-skills/mlops/inference/outlines/SKILL.md
optional-skills/mlops/llava/SKILL.md
optional-skills/mlops/models/segment-anything-model/SKILL.md
optional-skills/mlops/nemo-curator/SKILL.md
optional-skills/mlops/obliteratus/SKILL.md
optional-skills/mlops/peft/SKILL.md

Metadata

Files
0
Version
e0dfcf2
Hash
bb7489b6
Indexed
2026-07-25 11:34

Главная - Вики-сайт
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-05 14:30
浙ICP备14020137号-1 $Гость$