Prepare for follow-on change

This commit is contained in:
Hanno Braun 2025-04-03 12:52:36 +02:00
parent 0df0d129b2
commit 27f3dc5b51

View File

@ -41,9 +41,7 @@ pub fn triangulate(face: &Face) -> TriMesh {
}
fn points(face: &Face) -> Vec<TriangulationPoint> {
face.half_edges
.iter()
.map(|half_edge| {
let points_from_half_edges = face.half_edges.iter().map(|half_edge| {
// Here, we project a 3D point (from the vertex) into the face's
// surface, creating a 2D point. Through the surface, this 2D
// point has a position in 3D space.
@ -68,8 +66,9 @@ fn points(face: &Face) -> Vec<TriangulationPoint> {
point_surface,
point_vertex: half_edge.start.point,
}
})
.collect()
});
points_from_half_edges.collect()
}
fn triangles(points: &[TriangulationPoint]) -> Vec<[TriangulationPoint; 3]> {