Mesh Segmentation for CAD Conversion

Mesh segmentation for CAD groups mesh faces into regions that each belong to one analytic surface (plane, cylinder, cone, sphere). Paramesh AI uses region-growing with adaptive normal thresholds, curvature-based splitting, and post-processing to handle mixed regions. The result feeds into primitive fitting and feature recognition.

Why segmentation matters

A mesh is just triangles — thousands of small flat faces. Before you can recognize that something is a "hole" or a "chamfer," you need to know which triangles belong to which surface. That's what segmentation does.

Paramesh AI's segmentation algorithm

  1. Adjacency graph — build face-to-face connections from shared edges
  2. Region growing — flood-fill from seed faces using normal angle thresholds (15 degrees for planes, 30 degrees for curves)
  3. Small region merging — absorb tiny regions into their most similar neighbor
  4. Flat/curved splitting — detect mixed regions and separate planar faces from curved ones
  5. Curvature splitting — use k-means on (normal, curvature) features to split remaining complex regions
  6. Surface classification — label each region as PLANE, CYLINDER, CONE, SPHERE, or UNKNOWN using SVD analysis