ExplodeConnectedMeshes
Separate each connected component into a separate occurrence
Read time 1 minuteLast updated 8 months ago
API function: algo.explodeConnectedMeshes.
Each occurrence is subdivided in one occurrence per surfacic connected subset () + one for the non-surfacic elements ( and ).
polygonslinespointsOutcome
A list of N (+1 if there are non-surfacic elements, ie, lines or points) occurrences, where N is the number of surfacic connected subsets in the parent occurrence.
The following images visualize one color per connected component in the PixyzUI before (first image) and after (second image) a call to algo.explodeConnectedMeshes:


The scene treeview on the left also shows that a component has been subdivided into 10 new ones.
Parameters
bool explodeNonManifoldEdges
There's a single parameter to this algorithm. It determines how non-manifold edges (i.e., edges with more than two adjacent polygons) should be handled.
When , then non-manifold edges are considered to be a border of a connected component. In that case, each polygon adjacent to the non-manifold edge is considered to reside in a different connected components (unless they are connected via a sequence of manifold edges and polygons elsewhere).
explodeNonManifoldEdges==TrueWhen , then the polygons connecting at the non-manifold edge are considered to belong to the same connected component.
explodeNonManifoldEdges==False