STL to BREP: A FreeCAD Tool for AI Agents
说明与用途
FreeCAD MCP中的convert_mesh_to_brep工具将STL网格转换为具有解析面(平面和圆柱)的有效BREP实体,将平面数量从808减少到31,并保持体积误差低于0.04%。
问题
Automatic stitching of STL into BREP solids is missing for AI agents working with CAD.
结果
The tool converts STL meshes to valid BREP solids with analytic planes and cylinders, reducing faceting from 808 to 31 faces and maintaining volume within 0.04%.
工作流
- Load STL into FreeCAD MCP
- Run convert_mesh_to_brep with repair=true and default tolerances
- Obtain BREP solid and JSON report
- Verify closed solid, volume change, and residual faceting
证据
Automatic stitching of STL into BREP solids.
808 faces, every one of them a plane. The solid is valid, but the holes and the lug are made of narrow flat strips, not cylindrical surfaces.
31 faces: 21 Plane and 10 Cylinder. The surface types are read from the BREP itself; the orange color is applied for the figure only.
All six results are closed, valid solids, and they survived a save-and-reopen test.
The volume change on every part is under 0.04%.
I would like to find STL files that break this tool: cylinders left faceted, wrongly recognized surfaces, distorted holes, extra geometry, or a mesh it cannot process at all.
- 记录日期: 2026-11-02T05:59:14.913Z