Skip to main content

Module repair

Module repair 

Source
Expand description

Stability: unstable — repair API may change before 1.0. 网格修复与洞填充模块。

提供洞填充、孤立元素清理、非流形检测和法线一致化等操作, 组合为高层修复 pipeline。

§核心 API

函数功能
fill_hole填充单个洞(指定边界半边)
fill_all_holes填充所有洞
remove_isolated_vertices删除无关联半边的顶点
remove_face删除面,将邻居半边转为边界
remove_degenerate_faces删除退化面
detect_nonmanifold_edges检测非流形边
detect_nonmanifold_vertices检测非流形顶点
repair_mesh一键修复 pipeline

Structs§

RepairStats
网格修复统计信息。

Functions§

detect_nonmanifold_edges
检测非流形边:被 3 个或更多面共享的边。
detect_nonmanifold_vertices
检测非流形顶点:outgoing 环不闭合且非边界的内部顶点。
fill_all_holes
填充所有洞。返回每个洞的填充面列表。
fill_hole
填充单个洞。返回填充面的 ID 列表。
remove_degenerate_faces
删除所有退化面(面积为零或三顶点共线的三角面)。
remove_face
删除面,在洞边界上创建新的边界半边环。
remove_isolated_vertices
删除所有孤立顶点(无 outgoing 半边的顶点)。返回被删除的顶点数量。
repair_mesh
一键修复 pipeline。