Skip to content

axiolid-measure ​

Metric properties: area, volume, centroid, moments of inertia.

Latest release0.3.15 (2026-11-13)
crates.ioaxiolid-measure
Facadeaxiolid feature measure
Layeralgorithms (algorithm.query)
API documentationrustdoc · docs.rs
Sourcecrates/algorithms/query/measure/

Overview ​

Metric properties of geometry: surface area, signed volume, centroids and second moments of triangle meshes, closest points and distances between segments, triangles and meshes, certified Hausdorff distance between meshes, Frechet distance between polylines, winding numbers, and the area and extent of the faces selected by their normal (a floor, a wall side). Undefined quantities are refused: an open or non-manifold mesh gets an error, not a plausible volume. cycle_volume_properties also accepts meshes closed up to shells that touch along an edge, which are not two-manifold, and still refuses open surfaces. The optional exact feature adds mass properties, certified boundary distance and certified boundary Hausdorff distance for exact B-reps, single solids or bodies of several, without imposing them on mesh-only consumers.

Features ​

Default: none.

FeatureEnables
exactaxiolid-brep, axiolid-curve, axiolid-evaluate, axiolid-overlay, axiolid-surface, axiolid-topology

Depends on ​

Changes ​

Latest release, 0.3.15 (2026-11-13):

Changed ​

  • DistanceBounds::upper (all distance and clearance queries, plan and body variants) is at least the distance between the boundary points the witnesses stand for, not their computed distance: it adds their evaluation rounding, 16 ulps of each side's witness scale. A plan overlap still reports [0, 0] (#439).

Fixed ​

  • At georeferenced coordinates Clearance::Below could be claimed within about 1e-8 of a limit the distance does not go below (#439).
  • The exact Hausdorff lower bound takes off its witness's rounding (a face charted from far away but lying near the origin raised it up to about 1e-9 past the distance), and a point query's upper adds its nearest point's (#439).
  • B-spline witnesses are padded by the de Boor evaluation's rounding, a bound that counts the degrees and the weights' spread (#439). A B-spline face whose weight ratio exceeds 1 / (64 L eps) (L the sum of its degrees, about 3.5e13 for a bilinear patch) is refused with ExactMeasureError::NonPlanarFace, since that bound is first order.
  • The exact Hausdorff upper bound about a B-spline patch's witness adds the distance from the witness to the centre of the patch's enclosing sphere (the control net's box midpoint), which it left out and so could report an upper bound below the distance (#459).
  • The exact boundary distance and Hausdorff distance carry rounding margins derived from the magnitudes their numbers are computed from, in ulps of the coordinates, instead of 1e-12 of them. At georeferenced coordinates (450000, 5600000) the old margins left an interval about 1e-5 wide that never closed to the accuracy asked; a search now settles at a floor of 128 ulps of its scale, about 3.2e-7 there and 6e-14 at unit scale, and an accuracy below the floor is never reported as met (#318).
  • The distance search closes gaps along a planar face's normal on certified foot witnesses (the foot of a witness on a planar face, the closest points of two line edges) instead of waiting for patch centres to line up, and the point queries of the Hausdorff search pop equal bounds first in, first out (#318).
  • The margin for taking two boundary points as touching is 128 ulps of their magnitudes, not 1e-12 of them: items of one body apart by more than that are measured instead of refused as ItemsNearlyShareFace, and at unit scale a 1e-13 gap is now a gap (#318).
  • The sphere and torus branches of a projected range carried no rounding pad at all (#318).
  • The Hausdorff matched bound, a translate's re-charted surface and cone pole, and the displacement gate use the same derived margins, and a plane, cylinder or elliptical cylinder is Lipschitz by its axes rather than 1 + |v| times as steep, which had inflated the bound of patches charted in world coordinates (#318).

Full history: crates/algorithms/query/measure/CHANGELOG.md

Released under the Mozilla Public License 2.0.