paint_mesh_regions
Assigns colors to named or ID-based mesh regions and exports a painted 3MF, opening an interactive 3D preview for visual verification.
Instructions
Paint mesh regions by name or id and write a painted 3MF. Opens Kiln's interactive inline 3D stage on the result (orbit/zoom panel in MCP Apps hosts; hosted sessions add a browser stage link).
INLINE 3D STAGE: on success this tool opens Kiln's interactive 3D stage — an inline viewer panel the user can orbit, zoom, and turn over — in hosts that render MCP Apps panels (Kiln's hosted connection attaches a browser stage link for hosts that don't). Oversized meshes are decimated automatically for the stage; the PNG preview is the floor, not the whole experience.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"input_path": "<input_path>",
"assignments": "<assignments>"
},
"name": "paint_mesh_regions"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| design_id | No | Land the painted result in this design's version lineage, so a paint is a version you can branch, diff, release and roll back like any other change. Default: "". | |
| crease_deg | No | Crease angle in degrees: pass the value ``segmentation_params`` returned, so the regions painted are the ones shown. Omitted, Kiln's shared crease angle is used. | |
| input_path | Yes | The mesh that was segmented. | |
| printer_id | No | Check the requested colours against what this printer actually has loaded, and say so when it has fewer. Advice only — it never blocks a paint. It also names the bed the painted 3MF is placed on, so a model sitting off the plate is centred on the machine's real bed. Default: "". | |
| assignments | Yes | ``{surface: "#rrggbb"}`` — surface by id, by name, or by a plain word (above). Unassigned regions stay unpainted (the body colour). At most 16 distinct colours — a painted 3MF carries no more. | |
| branch_name | No | Branch to put that version on. Default: "painted". | |
| preview_only | No | Render the candidate, write nothing. Default: false. | |
| partition_hash | No | From ``segmentation_params``. Checked against the partition this call derives, so approving one set of regions and painting another is a refusal rather than a wrong answer. Omitting it skips the check. Default: "". | |
| min_region_area_frac | No | Smallest region kept, as a fraction of the mesh's surface area: pass the value ``segmentation_params`` returned. Omitted, the default is used. |