polyxios.transforms#

Functions

extract_surface(poly)

Return the boundary surface of a volumetric PolyData.

filter_element_type(poly, *, keep)

Return a new PolyData containing only elements of the specified type(s).

merge(*polys)

Merge multiple PolyData into one by concatenating vertices and elements.

pipeline(*fns)

Left-to-right function composition for PolyData transforms.

reindex(poly)

Return a new PolyData with compact vertex indices (removes orphans).

remove_orphan_vertices(poly)

Return a new PolyData with unreferenced vertices removed and indices remapped.

triangulate(poly)

Return a new PolyData with all surface elements converted to triangles.

vertex_colors(poly)

Extract per-vertex RGB colors from the first eligible vertex attribute.