diff --git a/Cargo.toml b/Cargo.toml index b73677e..041b19a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -5,7 +5,6 @@ edition = "2021" [lib] name = "xenobalanus" -crate-type = ["cdylib"] [dependencies] delaunator = "1.0.2" diff --git a/src/lib.rs b/src/lib.rs index 8b5b7e3..558b2a9 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -126,7 +126,7 @@ pub fn delaunay(points: &Vec>) -> Vec { result.triangles } -fn preprocess(points: &[Point], triangles: &[usize], types: usize) -> GeometryData { +pub fn preprocess(points: &[Point], triangles: &[usize], types: usize) -> GeometryData { let geometry_data = Arc::new(Mutex::new(GeometryData::new())); triangles.par_chunks(3).enumerate().for_each(|(index, tri_idx)| { @@ -138,7 +138,7 @@ fn preprocess(points: &[Point], triangles: &[usize], types: usize) -> Geome Arc::try_unwrap(geometry_data).unwrap().into_inner().unwrap() } -fn delfin( +pub fn delfin( geometry_data: &GeometryData, min_area: f32, min_distance: f32, @@ -236,7 +236,7 @@ fn delfin( } -fn dtscan( +pub fn dtscan( geometry_data: &GeometryData, min_pts: usize, max_closeness: f32,