Version 0.2.0 (2025-03-13)
Fixes
- fix: In CDT, update internal function
remove_crossed_edges
to be faillible, to avoid a possible infinite loop.
Changes
-
changed: defaults to using
f64
instead off32
inside the algorithm for more stable results (benchmarks were already usingf64
).f32
can still be enabled via thef32
cargo feature. -
changed:
tracing
dependency is now optional. Error messages (andDebugContext
when thedebug_context
feature is enabled) are returned within aTriangulationError
. -
changed:
glam
dependency now accepts version of glam up to 0.29 -
changed: now accept slices as inputs instead of
Vec
in most functions -
vertices format:
- added:
Vertex2d
andVertex3d
traits defining the algorithm vertex input format. - changed:
constrained_triangulation_from_3d_planar_vertices
,constrained_triangulation_from_2d_vertices
,triangulation_from_3d_planar_vertices
,triangulation_from_2d_vertices
andtransform_to_2d_planar_coordinate_system
to be generic over the input vertex format. This does not affect the vertex format used during the algorithm. This allows to decouple the vertex format used in the algorithm (f32
orf64
) from the vertex input format.- As an example: it is now possible to give vertices with f32 coordinates as an input, but compute the triangulation using f64.
- removed:
Vector3A
type. It was not used except for theplane_normal
input format, and it was already being converted immediately to aVector3
. - removed: the
Vector3
type now superseded by theVertex3d
trait.
- added:
Optimizations
- improved: find_vertex_placement hot path for edge side tests, and move the vertex merging to the end
- improved: some triangles neigbor checks
Examples, benchmarks & profiling
- changed: the visual debugger in the examples now always uses
glam::f32::Vec3
for vertices storage. - updated: profiling & benchmarks