使用说明
Blender MCP服务器
-
文件管理 加载Blender文件
load_file(filepath: str) -> str将.blend文件加载到Blender中。保存当前Blender文件
save_file(filepath: str) -> str将当前场景保存到指定路径。 -
对象创建 创建多维数据集
create_cube(name: str) -> str创建球体
create_sphere(name: str) -> str列出所有对象
list_objects() -> list[str]返回场景中所有对象的名称。 -
对象操纵 移动对象
move_object(object_id: str, x: float, y: float, z: float) -> str旋转对象
rotate_object(object_id: str, rx: float, ry: float, rz: float) -> str按Euler角度(弧度)旋转对象。计算两个物体之间的距离
distance_between(obj1_id: str, obj2_id: str) -> float -
出口 导出到glTF
export_gltf(filepath: str, objects: list[str] = None) -> str将选定或所有对象导出到.glb/.gltf文件。导出到点云
gltf_to_pointcloud(gltf_path: str, ply_path: str, num_points: int = 10000, include_interior: bool = False) -> str将GLTF/GLB网格转换为PLY点云。 include_intery=网格体积内的真实采样点。 num_points控制采样点的数量。设置相机焦距。调整相机的焦距
set_camera_focal_length(focal_length_mm: float):将图像渲染为png格式
def render_image(output_path: str):
