waxmorph.data

waxmorph.data#

Normalize meshes and sample their volumes for rollout point clouds.

For mesh volume V and requested count N, r = (3V / 4 pi N)^(1/3) and the Poisson exclusion distance is d_min = 1.2 r. This permits equal-radius overlap; contact and graph connectivity remain sample-dependent. N=2000 is a public default, and callers may choose another count. Exact-count wrappers may reduce r and d_min together; returned radius fields report that effective value. Source and target use independent samples, so row order carries independent draws.

Functions

load_mesh(path)

Load one mesh, reorient its normals, and fill small holes in place.

normalize_mesh(mesh[, target_extent])

Center and isotropically scale a mesh in place, preserving aspect ratio.

sample_mesh_pair(source_path, target_path[, ...])

Sample independent, equal-count source and target clouds.

sample_mesh_sequence(source_path, target_specs)

Sample a source cloud and frame-tagged target clouds at exact equal counts.

sample_volume(mesh, n_points[, pitch, ...])

Sample at most n_points centers from a normalized mesh interior.