GitHub link
The Polygon Mesh Processing Library
SurfaceFeatures Class Reference

Detect and mark feature edges based on boundary or dihedral angle.

#include <pmp/algorithms/SurfaceFeatures.h>

Public Member Functions

 SurfaceFeatures (SurfaceMesh &mesh)
 Construct with mesh to be analyzed. More...
void clear ()
 Clear feature and boundary edges. More...
size_t detect_boundary ()
 Mark all boundary edges as features. More...
size_t detect_angle (Scalar angle)
 Mark edges with dihedral angle larger than angle as feature. More...

Constructor & Destructor Documentation

◆ SurfaceFeatures()

Adds two bool properties to the mesh if they are not already existing:

  • "e:feature" to mark feature edges
  • "v:feature" to mark feature vertices.
The class never removes the marker properties so that other algorithms can re-use this information. Cleaning up the properties when they are no longer needed is the responsibility of the caller.

Member Function Documentation

◆ clear()

void clear ( )

Sets all "e:feature" and "v:feature" properties to false.

This does not remove the corresponding property arrays.

◆ detect_angle()

size_t detect_angle ( Scalar  angle)
The number of feature edges detected.

◆ detect_boundary()

size_t detect_boundary ( )
The number of boudary edges detected.