From 549d8f50ad6a4cf695d5ae39ce353276f16f4122 Mon Sep 17 00:00:00 2001 From: GlennWSo Date: Thu, 23 Feb 2023 15:38:42 +0100 Subject: [PATCH 1/9] return inds used from second mesh. To enable blaming in mesh --- src/transformation/mesh_intersection/mesh_intersection.rs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/transformation/mesh_intersection/mesh_intersection.rs b/src/transformation/mesh_intersection/mesh_intersection.rs index 3a030654..d7379ead 100644 --- a/src/transformation/mesh_intersection/mesh_intersection.rs +++ b/src/transformation/mesh_intersection/mesh_intersection.rs @@ -18,7 +18,7 @@ pub fn intersect_meshes( pos2: &Isometry, mesh2: &TriMesh, flip2: bool, -) -> Result, MeshIntersectionError> { +) -> Result)>, MeshIntersectionError> { if mesh1.topology().is_none() || mesh2.topology().is_none() { return Err(MeshIntersectionError::MissingTopology); } @@ -151,7 +151,10 @@ pub fn intersect_meshes( new_indices1.append(&mut new_indices12); if !new_indices1.is_empty() { - Ok(Some(TriMesh::new(new_vertices, new_indices1))) + Ok(Some(( + TriMesh::new(new_vertices, new_indices1), + new_indices2, + ))) } else { Ok(None) } From 1bf57f0294b3cd5d2cfa12a24c2627e2b0c99c18 Mon Sep 17 00:00:00 2001 From: GlennWSo Date: Thu, 23 Feb 2023 16:49:24 +0100 Subject: [PATCH 2/9] moved intersect_meshes with tracking to new func --- .../mesh_intersection/mesh_intersection.rs | 146 ++++++++++++++++++ src/transformation/mesh_intersection/mod.rs | 2 +- src/transformation/mod.rs | 2 +- 3 files changed, 148 insertions(+), 2 deletions(-) diff --git a/src/transformation/mesh_intersection/mesh_intersection.rs b/src/transformation/mesh_intersection/mesh_intersection.rs index d7379ead..f9a6cfc1 100644 --- a/src/transformation/mesh_intersection/mesh_intersection.rs +++ b/src/transformation/mesh_intersection/mesh_intersection.rs @@ -18,6 +18,152 @@ pub fn intersect_meshes( pos2: &Isometry, mesh2: &TriMesh, flip2: bool, +) -> Result, MeshIntersectionError> { + if mesh1.topology().is_none() || mesh2.topology().is_none() { + return Err(MeshIntersectionError::MissingTopology); + } + + if mesh1.pseudo_normals().is_none() || mesh2.pseudo_normals().is_none() { + return Err(MeshIntersectionError::MissingPseudoNormals); + } + + // NOTE: remove this, used for debugging only. + mesh1.assert_half_edge_topology_is_valid(); + mesh2.assert_half_edge_topology_is_valid(); + + let pos12 = pos1.inv_mul(pos2); + + // 1: collect all the potential triangle-triangle intersections. + let mut intersections = vec![]; + let mut visitor = BoundingVolumeIntersectionsSimultaneousVisitor::with_relative_pos( + pos12, + |tri1: &u32, tri2: &u32| { + intersections.push((*tri1, *tri2)); + true + }, + ); + + mesh1.qbvh().traverse_bvtt(mesh2.qbvh(), &mut visitor); + + let mut deleted_faces1: HashSet = HashSet::default(); + let mut deleted_faces2: HashSet = HashSet::default(); + let mut new_indices1 = vec![]; + let mut new_indices2 = vec![]; + + for (fid1, fid2) in &intersections { + let tri1 = mesh1.triangle(*fid1); + let tri2 = mesh2.triangle(*fid2).transformed(&pos12); + + if super::triangle_triangle_intersection(&tri1, &tri2).is_some() { + let _ = deleted_faces1.insert(*fid1); + let _ = deleted_faces2.insert(*fid2); + } + } + + extract_connected_components( + &pos12, + &mesh1, + &mesh2, + flip2, + &deleted_faces1, + &mut new_indices1, + ); + extract_connected_components( + &pos12.inverse(), + &mesh2, + &mesh1, + flip1, + &deleted_faces2, + &mut new_indices2, + ); + + let mut new_vertices12 = vec![]; + let mut new_indices12 = vec![]; + + cut_and_triangulate_intersections( + &pos12, + &mesh1, + flip1, + &mesh2, + flip2, + &mut new_vertices12, + &mut new_indices12, + &mut intersections, + ); + + let old_vertices1 = mesh1.vertices(); + let old_vertices2 = mesh2.vertices(); + + // At this point, we know what triangles we want from the first mesh, + // and the ones we want from the second mesh. Now we need to build the + // vertex buffer and adjust the indices accordingly. + let mut new_vertices = vec![]; + + // Maps from unified index to the final vertex index. + let mut index_map = HashMap::new(); + let base_id2 = mesh1.vertices().len() as u32; + + // Grab all the triangles from the connected component extracted from the first mesh. + for idx1 in &mut new_indices1 { + for k in 0..3 { + let new_id = *index_map.entry(idx1[k]).or_insert_with(|| { + let vtx = old_vertices1[idx1[k] as usize]; + new_vertices.push(vtx); + new_vertices.len() - 1 + }); + idx1[k] = new_id as u32; + } + } + + // Grab all the triangles from the connected component extracted from the second mesh. + for idx2 in &mut new_indices2 { + for k in 0..3 { + let new_id = *index_map.entry(base_id2 + idx2[k]).or_insert_with(|| { + let vtx = pos12 * old_vertices2[idx2[k] as usize]; + new_vertices.push(vtx); + new_vertices.len() - 1 + }); + idx2[k] = new_id as u32; + } + } + + // Grab all the trinangles from the intersections. + for idx12 in &mut new_indices12 { + for k in 0..3 { + let new_id = *index_map.entry(idx12[k]).or_insert_with(|| { + let vtx = unified_vertex(mesh1, mesh2, &new_vertices12, &pos12, idx12[k]); + new_vertices.push(vtx); + new_vertices.len() - 1 + }); + idx12[k] = new_id as u32; + } + } + + if flip1 { + new_indices1.iter_mut().for_each(|idx| idx.swap(1, 2)); + } + + if flip2 { + new_indices2.iter_mut().for_each(|idx| idx.swap(1, 2)); + } + + new_indices1.append(&mut new_indices2); + new_indices1.append(&mut new_indices12); + + if !new_indices1.is_empty() { + Ok(Some(TriMesh::new(new_vertices, new_indices1))) + } else { + Ok(None) + } +} + +pub fn intersect_meshes_track( + pos1: &Isometry, + mesh1: &TriMesh, + flip1: bool, + pos2: &Isometry, + mesh2: &TriMesh, + flip2: bool, ) -> Result)>, MeshIntersectionError> { if mesh1.topology().is_none() || mesh2.topology().is_none() { return Err(MeshIntersectionError::MissingTopology); diff --git a/src/transformation/mesh_intersection/mod.rs b/src/transformation/mesh_intersection/mod.rs index e9b0d6b9..bed605ff 100644 --- a/src/transformation/mesh_intersection/mod.rs +++ b/src/transformation/mesh_intersection/mod.rs @@ -1,4 +1,4 @@ -pub use self::mesh_intersection::intersect_meshes; +pub use self::mesh_intersection::{intersect_meshes, intersect_meshes_track}; pub use self::mesh_intersection_error::MeshIntersectionError; pub(self) use triangle_triangle_intersection::*; diff --git a/src/transformation/mod.rs b/src/transformation/mod.rs index 93fd346e..15de1369 100644 --- a/src/transformation/mod.rs +++ b/src/transformation/mod.rs @@ -7,7 +7,7 @@ pub use self::convex_hull2::{convex_hull2 as convex_hull, convex_hull2_idx as co #[cfg(feature = "dim3")] pub use self::convex_hull3::{check_convex_hull, convex_hull, try_convex_hull, ConvexHullError}; #[cfg(feature = "dim3")] -pub use self::mesh_intersection::intersect_meshes; +pub use self::mesh_intersection::{intersect_meshes, intersect_meshes_track}; pub use self::polygon_intersection::{ convex_polygons_intersection, convex_polygons_intersection_points, }; From 93518e99917d0aaf9982039f96d8a93c1622d1c1 Mon Sep 17 00:00:00 2001 From: GlennWSo Date: Fri, 24 Feb 2023 17:01:04 +0100 Subject: [PATCH 3/9] clone inds so that can be used as tracks --- src/transformation/mesh_intersection/mesh_intersection.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/transformation/mesh_intersection/mesh_intersection.rs b/src/transformation/mesh_intersection/mesh_intersection.rs index f9a6cfc1..f85f3466 100644 --- a/src/transformation/mesh_intersection/mesh_intersection.rs +++ b/src/transformation/mesh_intersection/mesh_intersection.rs @@ -293,7 +293,7 @@ pub fn intersect_meshes_track( new_indices2.iter_mut().for_each(|idx| idx.swap(1, 2)); } - new_indices1.append(&mut new_indices2); + new_indices1.append(&mut new_indices2.clone()); new_indices1.append(&mut new_indices12); if !new_indices1.is_empty() { From 1459c83f4e8c4e5c17a6c0b04862fbaaa894df43 Mon Sep 17 00:00:00 2001 From: GlennWSo Date: Mon, 27 Feb 2023 13:14:21 +0100 Subject: [PATCH 4/9] pass tracking as index posistions --- .../mesh_intersection/mesh_intersection.rs | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/transformation/mesh_intersection/mesh_intersection.rs b/src/transformation/mesh_intersection/mesh_intersection.rs index f85f3466..7de05ba1 100644 --- a/src/transformation/mesh_intersection/mesh_intersection.rs +++ b/src/transformation/mesh_intersection/mesh_intersection.rs @@ -164,7 +164,7 @@ pub fn intersect_meshes_track( pos2: &Isometry, mesh2: &TriMesh, flip2: bool, -) -> Result)>, MeshIntersectionError> { +) -> Result)>, MeshIntersectionError> { if mesh1.topology().is_none() || mesh2.topology().is_none() { return Err(MeshIntersectionError::MissingTopology); } @@ -293,14 +293,13 @@ pub fn intersect_meshes_track( new_indices2.iter_mut().for_each(|idx| idx.swap(1, 2)); } - new_indices1.append(&mut new_indices2.clone()); + // TODO track new_indices12 and indices21 separatly + let tracks = vec![new_indices1.len(), new_indices2.len(), new_indices12.len()]; + new_indices1.append(&mut new_indices2); new_indices1.append(&mut new_indices12); if !new_indices1.is_empty() { - Ok(Some(( - TriMesh::new(new_vertices, new_indices1), - new_indices2, - ))) + Ok(Some((TriMesh::new(new_vertices, new_indices1), tracks))) } else { Ok(None) } From 9cbedc02663f26863fc272229ce6606198a296d6 Mon Sep 17 00:00:00 2001 From: GlennWSo Date: Tue, 28 Feb 2023 11:38:54 +0100 Subject: [PATCH 5/9] split new_inds form intersection into group for better tracking --- .../mesh_intersection/mesh_intersection.rs | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/src/transformation/mesh_intersection/mesh_intersection.rs b/src/transformation/mesh_intersection/mesh_intersection.rs index 7de05ba1..f74bb88f 100644 --- a/src/transformation/mesh_intersection/mesh_intersection.rs +++ b/src/transformation/mesh_intersection/mesh_intersection.rs @@ -79,6 +79,7 @@ pub fn intersect_meshes( let mut new_vertices12 = vec![]; let mut new_indices12 = vec![]; + let mut new_indices21 = vec![]; cut_and_triangulate_intersections( &pos12, @@ -88,6 +89,7 @@ pub fn intersect_meshes( flip2, &mut new_vertices12, &mut new_indices12, + &mut new_indices21, &mut intersections, ); @@ -157,6 +159,8 @@ pub fn intersect_meshes( } } + +/// Computes the intersection of two meshes, returns tracking meta pub fn intersect_meshes_track( pos1: &Isometry, mesh1: &TriMesh, @@ -225,6 +229,7 @@ pub fn intersect_meshes_track( let mut new_vertices12 = vec![]; let mut new_indices12 = vec![]; + let mut new_indices21 = vec![]; cut_and_triangulate_intersections( &pos12, @@ -234,6 +239,7 @@ pub fn intersect_meshes_track( flip2, &mut new_vertices12, &mut new_indices12, + &mut new_indices21, &mut intersections, ); @@ -294,9 +300,10 @@ pub fn intersect_meshes_track( } // TODO track new_indices12 and indices21 separatly - let tracks = vec![new_indices1.len(), new_indices2.len(), new_indices12.len()]; + let tracks = vec![new_indices1.len(), new_indices2.len(), new_indices12.len(), new_indices21.len()]; new_indices1.append(&mut new_indices2); new_indices1.append(&mut new_indices12); + new_indices1.append(&mut new_indices21); if !new_indices1.is_empty() { Ok(Some((TriMesh::new(new_vertices, new_indices1), tracks))) @@ -504,6 +511,7 @@ fn cut_and_triangulate_intersections( flip2: bool, new_vertices12: &mut Vec>, new_indices12: &mut Vec<[u32; 3]>, + new_indices21: &mut Vec<[u32; 3]>, intersections: &mut Vec<(u32, u32)>, ) { let mut triangulations1 = HashMap::new(); @@ -634,6 +642,7 @@ fn cut_and_triangulate_intersections( &triangulations2, new_vertices12, new_indices12, + new_indices21, ); } @@ -684,6 +693,7 @@ fn extract_result( triangulations2: &HashMap, new_vertices12: &mut Vec>, new_indices12: &mut Vec<[u32; 3]>, + new_indices21: &mut Vec<[u32; 3]>, ) { // Base ids for indexing in the first mesh vertices, second mesh vertices, and new vertices, as if they // are part of a single big array. @@ -780,7 +790,7 @@ fn extract_result( if flip2 { idx.swap(1, 2); } - new_indices12.push(idx); + new_indices21.push(idx); } } } From 171a9c501440c9ac884885a47fa54dbed1c0b360 Mon Sep 17 00:00:00 2001 From: GlennWSo Date: Tue, 28 Feb 2023 11:45:09 +0100 Subject: [PATCH 6/9] append second part of intersected triangles --- src/transformation/mesh_intersection/mesh_intersection.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/transformation/mesh_intersection/mesh_intersection.rs b/src/transformation/mesh_intersection/mesh_intersection.rs index f74bb88f..9d09cfc2 100644 --- a/src/transformation/mesh_intersection/mesh_intersection.rs +++ b/src/transformation/mesh_intersection/mesh_intersection.rs @@ -151,6 +151,7 @@ pub fn intersect_meshes( new_indices1.append(&mut new_indices2); new_indices1.append(&mut new_indices12); + new_indices1.append(&mut new_indices21); if !new_indices1.is_empty() { Ok(Some(TriMesh::new(new_vertices, new_indices1))) From 6a6b3776ca960a98f7d22f26aceb3bc52778ace4 Mon Sep 17 00:00:00 2001 From: GlennWSo Date: Tue, 28 Feb 2023 11:58:07 +0100 Subject: [PATCH 7/9] grab triangles from intersection2 --- .../mesh_intersection/mesh_intersection.rs | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/src/transformation/mesh_intersection/mesh_intersection.rs b/src/transformation/mesh_intersection/mesh_intersection.rs index 9d09cfc2..1084d112 100644 --- a/src/transformation/mesh_intersection/mesh_intersection.rs +++ b/src/transformation/mesh_intersection/mesh_intersection.rs @@ -280,7 +280,7 @@ pub fn intersect_meshes_track( } } - // Grab all the trinangles from the intersections. + // Grab all the trinangles from intersection1. for idx12 in &mut new_indices12 { for k in 0..3 { let new_id = *index_map.entry(idx12[k]).or_insert_with(|| { @@ -292,6 +292,18 @@ pub fn intersect_meshes_track( } } + // Grab all the trinangles from intersection2. + for idx21 in &mut new_indices21 { + for k in 0..3 { + let new_id = *index_map.entry(idx21[k]).or_insert_with(|| { + let vtx = unified_vertex(mesh1, mesh2, &new_vertices12, &pos12, idx21[k]); + new_vertices.push(vtx); + new_vertices.len() - 1 + }); + idx21[k] = new_id as u32; + } + } + if flip1 { new_indices1.iter_mut().for_each(|idx| idx.swap(1, 2)); } @@ -300,7 +312,6 @@ pub fn intersect_meshes_track( new_indices2.iter_mut().for_each(|idx| idx.swap(1, 2)); } - // TODO track new_indices12 and indices21 separatly let tracks = vec![new_indices1.len(), new_indices2.len(), new_indices12.len(), new_indices21.len()]; new_indices1.append(&mut new_indices2); new_indices1.append(&mut new_indices12); From 8cd7ff499e4eec2c6bcb6da3f3f4d47c0c05a17f Mon Sep 17 00:00:00 2001 From: GlennWSo Date: Tue, 28 Feb 2023 12:46:37 +0100 Subject: [PATCH 8/9] removed code duplication --- .../mesh_intersection/mesh_intersection.rs | 148 ++---------------- 1 file changed, 9 insertions(+), 139 deletions(-) diff --git a/src/transformation/mesh_intersection/mesh_intersection.rs b/src/transformation/mesh_intersection/mesh_intersection.rs index 1084d112..d9a2df01 100644 --- a/src/transformation/mesh_intersection/mesh_intersection.rs +++ b/src/transformation/mesh_intersection/mesh_intersection.rs @@ -19,149 +19,19 @@ pub fn intersect_meshes( mesh2: &TriMesh, flip2: bool, ) -> Result, MeshIntersectionError> { - if mesh1.topology().is_none() || mesh2.topology().is_none() { - return Err(MeshIntersectionError::MissingTopology); - } - - if mesh1.pseudo_normals().is_none() || mesh2.pseudo_normals().is_none() { - return Err(MeshIntersectionError::MissingPseudoNormals); - } - - // NOTE: remove this, used for debugging only. - mesh1.assert_half_edge_topology_is_valid(); - mesh2.assert_half_edge_topology_is_valid(); - - let pos12 = pos1.inv_mul(pos2); - - // 1: collect all the potential triangle-triangle intersections. - let mut intersections = vec![]; - let mut visitor = BoundingVolumeIntersectionsSimultaneousVisitor::with_relative_pos( - pos12, - |tri1: &u32, tri2: &u32| { - intersections.push((*tri1, *tri2)); - true - }, - ); - - mesh1.qbvh().traverse_bvtt(mesh2.qbvh(), &mut visitor); - - let mut deleted_faces1: HashSet = HashSet::default(); - let mut deleted_faces2: HashSet = HashSet::default(); - let mut new_indices1 = vec![]; - let mut new_indices2 = vec![]; - - for (fid1, fid2) in &intersections { - let tri1 = mesh1.triangle(*fid1); - let tri2 = mesh2.triangle(*fid2).transformed(&pos12); - - if super::triangle_triangle_intersection(&tri1, &tri2).is_some() { - let _ = deleted_faces1.insert(*fid1); - let _ = deleted_faces2.insert(*fid2); - } - } - - extract_connected_components( - &pos12, - &mesh1, - &mesh2, - flip2, - &deleted_faces1, - &mut new_indices1, - ); - extract_connected_components( - &pos12.inverse(), - &mesh2, - &mesh1, - flip1, - &deleted_faces2, - &mut new_indices2, - ); - - let mut new_vertices12 = vec![]; - let mut new_indices12 = vec![]; - let mut new_indices21 = vec![]; - - cut_and_triangulate_intersections( - &pos12, - &mesh1, - flip1, - &mesh2, - flip2, - &mut new_vertices12, - &mut new_indices12, - &mut new_indices21, - &mut intersections, - ); - - let old_vertices1 = mesh1.vertices(); - let old_vertices2 = mesh2.vertices(); - - // At this point, we know what triangles we want from the first mesh, - // and the ones we want from the second mesh. Now we need to build the - // vertex buffer and adjust the indices accordingly. - let mut new_vertices = vec![]; - - // Maps from unified index to the final vertex index. - let mut index_map = HashMap::new(); - let base_id2 = mesh1.vertices().len() as u32; - - // Grab all the triangles from the connected component extracted from the first mesh. - for idx1 in &mut new_indices1 { - for k in 0..3 { - let new_id = *index_map.entry(idx1[k]).or_insert_with(|| { - let vtx = old_vertices1[idx1[k] as usize]; - new_vertices.push(vtx); - new_vertices.len() - 1 - }); - idx1[k] = new_id as u32; - } - } - - // Grab all the triangles from the connected component extracted from the second mesh. - for idx2 in &mut new_indices2 { - for k in 0..3 { - let new_id = *index_map.entry(base_id2 + idx2[k]).or_insert_with(|| { - let vtx = pos12 * old_vertices2[idx2[k] as usize]; - new_vertices.push(vtx); - new_vertices.len() - 1 - }); - idx2[k] = new_id as u32; - } - } - - // Grab all the trinangles from the intersections. - for idx12 in &mut new_indices12 { - for k in 0..3 { - let new_id = *index_map.entry(idx12[k]).or_insert_with(|| { - let vtx = unified_vertex(mesh1, mesh2, &new_vertices12, &pos12, idx12[k]); - new_vertices.push(vtx); - new_vertices.len() - 1 - }); - idx12[k] = new_id as u32; - } - } - - if flip1 { - new_indices1.iter_mut().for_each(|idx| idx.swap(1, 2)); - } - - if flip2 { - new_indices2.iter_mut().for_each(|idx| idx.swap(1, 2)); - } - - new_indices1.append(&mut new_indices2); - new_indices1.append(&mut new_indices12); - new_indices1.append(&mut new_indices21); - - if !new_indices1.is_empty() { - Ok(Some(TriMesh::new(new_vertices, new_indices1))) - } else { - Ok(None) + let res = intersect_meshes_track(pos1, mesh1, flip1, pos2, mesh2, flip2); + match res { + Ok(Some((mesh, _tracks))) => Ok(Some(mesh)), + Ok(None) => Ok(None), + Err(e) => Err(e), } } -/// Computes the intersection of two meshes, returns tracking meta +/// Computes the intersection of two meshes, returns additional tracking meta +/// +/// The meshes must be oriented, have their half-edge topology computed, and must not be self-intersecting. +/// The result mesh vertex coordinates are given in the local-space of `mesh1`. pub fn intersect_meshes_track( pos1: &Isometry, mesh1: &TriMesh, From 7dfd147860107afd6482f436b99aab22cf33463c Mon Sep 17 00:00:00 2001 From: GlennWSo Date: Tue, 28 Feb 2023 12:49:03 +0100 Subject: [PATCH 9/9] renamed instersect_meshes_track to tracked_intersection --- src/transformation/mesh_intersection/mesh_intersection.rs | 4 ++-- src/transformation/mesh_intersection/mod.rs | 2 +- src/transformation/mod.rs | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/transformation/mesh_intersection/mesh_intersection.rs b/src/transformation/mesh_intersection/mesh_intersection.rs index d9a2df01..e27acace 100644 --- a/src/transformation/mesh_intersection/mesh_intersection.rs +++ b/src/transformation/mesh_intersection/mesh_intersection.rs @@ -19,7 +19,7 @@ pub fn intersect_meshes( mesh2: &TriMesh, flip2: bool, ) -> Result, MeshIntersectionError> { - let res = intersect_meshes_track(pos1, mesh1, flip1, pos2, mesh2, flip2); + let res = tracked_intersection(pos1, mesh1, flip1, pos2, mesh2, flip2); match res { Ok(Some((mesh, _tracks))) => Ok(Some(mesh)), Ok(None) => Ok(None), @@ -32,7 +32,7 @@ pub fn intersect_meshes( /// /// The meshes must be oriented, have their half-edge topology computed, and must not be self-intersecting. /// The result mesh vertex coordinates are given in the local-space of `mesh1`. -pub fn intersect_meshes_track( +pub fn tracked_intersection( pos1: &Isometry, mesh1: &TriMesh, flip1: bool, diff --git a/src/transformation/mesh_intersection/mod.rs b/src/transformation/mesh_intersection/mod.rs index bed605ff..3ec9e8af 100644 --- a/src/transformation/mesh_intersection/mod.rs +++ b/src/transformation/mesh_intersection/mod.rs @@ -1,4 +1,4 @@ -pub use self::mesh_intersection::{intersect_meshes, intersect_meshes_track}; +pub use self::mesh_intersection::{intersect_meshes, tracked_intersection}; pub use self::mesh_intersection_error::MeshIntersectionError; pub(self) use triangle_triangle_intersection::*; diff --git a/src/transformation/mod.rs b/src/transformation/mod.rs index 15de1369..008b939d 100644 --- a/src/transformation/mod.rs +++ b/src/transformation/mod.rs @@ -7,7 +7,7 @@ pub use self::convex_hull2::{convex_hull2 as convex_hull, convex_hull2_idx as co #[cfg(feature = "dim3")] pub use self::convex_hull3::{check_convex_hull, convex_hull, try_convex_hull, ConvexHullError}; #[cfg(feature = "dim3")] -pub use self::mesh_intersection::{intersect_meshes, intersect_meshes_track}; +pub use self::mesh_intersection::{intersect_meshes, tracked_intersection}; pub use self::polygon_intersection::{ convex_polygons_intersection, convex_polygons_intersection_points, };