axiolid-mesh
Triangle meshes: the discrete representation every backend consumes.
| Latest release | 0.3.6 (2026-11-04) |
| crates.io | axiolid-mesh |
| Facade | axiolid feature mesh |
| Layer | representations (representation.discrete) |
| API documentation | rustdoc · docs.rs |
| Source | crates/representations/discrete/mesh/ |
Overview
Triangle and polygon mesh values: TriMesh as the compact exchange type, PolygonMesh keeping n-gons and holes until explicit triangulation, u32 indices, named per-vertex and per-corner attribute channels, derived edge adjacency, connected components, and a deterministic structural audit that reports defects instead of rejecting dirty input, with an oriented-cycle audit for meshes closed up to shells that touch along an edge. HalfedgeMesh is the editable surface mesh for algorithms that rewrite connectivity in place: O(1) adjacency, vertex circulators, boundary loops, and edge flip, split and collapse (with the link condition) and face split that keep it a valid oriented 2-manifold; non-manifold input is refused by name. MeshView and TriangleMeshView let a foreign mesh be read without copying it. split_triangle_at_side_corners re-triangulates a triangle whose sides carry extra corners, on indices alone. Mesh operations such as booleans, sections and repair live in other crates.
The optional serde feature (off by default) derives Serialize and Deserialize for the mesh values the geometry graph's wire format carries (ADR 0085). The format, its version and its refusal rules belong to axiolid-model; this crate only supplies the derives.
Design notes
Rendering appearance (materials, shaders, colours as styling) is not part of a mesh value. Data that must follow the geometry, such as a material id per vertex, travels as an attribute channel.
Features
Default: none.
| Feature | Enables |
|---|---|
serde | serde, axiolid-core/serde |
Depends on
Changes
Latest release, 0.3.6 (2026-11-04):
Added
audit_mesh_cycleandtry_audit_mesh_cyclereturnMeshCycleHealth: theMeshHealthplus the number of unbalanced edges and the first one, so a mesh closed up to edge-touching shells can be told from an open one. A closed oriented cycle is weaker than a closed two-manifold (#416).The package now ships
LICENSEandLICENSE-COMMERCIAL(symlinks to the repository root), so the licence texts travel with the archive (#358).split_triangle_at_side_cornersre-triangulates a triangle whose sides carry extra corners into proper triangles of the same winding, by side bitmask ear clipping on indices alone.axiolid-mesh-compileandaxiolid-healshared it as two private copies before (#422).
Full history: crates/representations/discrete/mesh/CHANGELOG.md