#include "MRMeshFwd.h"
#include "MRId.h"
#include "MRMeshPart.h"
#include "MRVector.h"
Go to the source code of this file.
|
MRMESHC_API MRFaceBitSet * | mrMeshComponentsGetComponent (const MRMeshPart *mp, MRFaceId id, MRFaceIncidence incidence, bool(*isCompBd)(MRUndirectedEdgeId)) |
|
MRMESHC_API MRFaceBitSet * | mrMeshComponentsGetLargestComponent (const MRMeshPart *mp, MRFaceIncidence incidence, bool(*isCompBd)(MRUndirectedEdgeId), float minArea, int *numSmallerComponents) |
| returns the largest by surface area component or empty set if its area is smaller than
|
|
MRMESHC_API MRFaceBitSet * | mrMeshComponentsGetLargeByAreaComponents (const MRMeshPart *mp, float minArea, bool(*isCompBd)(MRUndirectedEdgeId)) |
| returns the union of connected components, each having at least given area
|
|
MRMESHC_API MRMeshComponentsMap | mrMeshComponentsGetAllComponentsMap (const MRMeshPart *mp, MRFaceIncidence incidence) |
|
MRMESHC_API MRMeshRegions | mrMeshComponentsGetLargeByAreaRegions (const MRMeshPart *mp, const MRFace2RegionMap *face2RegionMap, int numRegions, float minArea) |
|
MRMESHC_API void | mrMeshComponentsAllComponentsMapFree (const MRMeshComponentsMap *map) |
| deletes allocated map
|
|
◆ MRFaceIncidence
◆ MRMeshComponentsMap
stores reference on Face2RegionMap ( key: face id, value: region id ) and number of components
◆ MRMeshRegions
typedef struct MRMeshRegions MRMeshRegions |
stores reference on bitset of faces and number of regions
◆ MRFaceIncidence
Enumerator |
---|
MRFaceIncidencePerEdge | face can have neighbor only via edge
|
MRFaceIncidencePerVertex | face can have neighbor via vertex
|
◆ mrMeshComponentsAllComponentsMapFree()
◆ mrMeshComponentsGetAllComponentsMap()
gets all connected components of mesh part as
- the mapping: FaceId -> Component ID in [0, 1, 2, ...)
- the total number of components
◆ mrMeshComponentsGetComponent()
returns one connected component containing given face, not effective to call more than once, if several components are needed use getAllComponents
◆ mrMeshComponentsGetLargeByAreaComponents()
returns the union of connected components, each having at least given area
◆ mrMeshComponentsGetLargeByAreaRegions()
returns
- the union of all regions with area >= minArea
- the number of such regions
◆ mrMeshComponentsGetLargestComponent()
returns the largest by surface area component or empty set if its area is smaller than
- Parameters
-