fn is_edge_unique(tris: &[Tri], facing_tris: &[u32], ignore_tri: u32, edge: &Edge) -> bool {
    for &tri_idx in facing_tris {
        if ignore_tri == tri_idx {
            continue;
        }

        let tri = tris[tri_idx as usize];

        let edges = [
            Edge { a: tri.a, b: tri.b },
            Edge { a: tri.b, b: tri.c },
            Edge { a: tri.c, b: tri.a },
        ];

        for e in &edges {
            if *edge == *e {
                return false;
            }
        }
    }

    true
}
// This will compare the incoming edge with all the edges in the facing tris and then return true
// if it's unique.
This will compare the incoming edge with all the edges in the facing tris and then return true
if it's unique.
This will compare the incoming edge with all the edges in the facing tris and then return true if it ' s unique .
fn is_edge_unique(tris: &[Tri], facing_tris: &[u32], ignore_tri: u32, edge: &Edge) -> bool {
    for &tri_idx in facing_tris {
        if ignore_tri == tri_idx {
            continue;
        }
        let tri = tris[tri_idx as usize];
        let edges = [
            Edge { a: tri.a, b: tri.b },
            Edge { a: tri.b, b: tri.c },
            Edge { a: tri.c, b: tri.a },
        ];
        for e in &edges {
            if *edge == *e {
                return false;
            }
        }
    }
    true
}
fn is_edge_unique ( tris : & [ Tri ] , facing_tris : & [ u32 ] , ignore_tri : u32 , edge : & Edge ) -> bool { for & tri_idx in facing_tris { if ignore_tri == tri_idx { continue ; } let tri = tris [ tri_idx as usize ] ; let edges = [ Edge { a : tri . a , b : tri . b } , Edge { a : tri . b , b : tri . c } , Edge { a : tri . c , b : tri . a } , ] ; for e in & edges { if * edge == * e { return false ; } } } true }
This will compare the incoming edge with all the edges in the facing tris and then return true
if it's unique.
This will compare the incoming edge with all the edges in the facing tris and then return true if it ' s unique .
tris
&[Tri]
facing_tris
&[u32]
ignore_tri
u32
edge
&Edge
tris
&[Tri]
facing_tris
&[u32]
ignore_tri
u32
edge
&Edge