fn ring_type_from_points_ordering(points: &[Coord]) -> RingType {
    let area = points
        .windows(2)
        .map(|pts| (pts[1].x - pts[0].x) * (pts[1].y + pts[0].y))
        .sum::<f64>()
        / 2.0f64;

    if area < 0.0 {
        RingType::InnerRing
    } else {
        RingType::OuterRing
    }
}
/// Given the points, check if they represent an outer ring of a polygon
///
/// As per ESRI's Shapefile 1998 whitepaper:
/// `
/// The order of vertices or orientation for a ring indicates which side of the ring
/// is the interior of the polygon.
/// The neighborhood to the right of an observer walking along
/// the ring in vertex order is the neighborhood inside the polygon.
/// Vertices of rings defining holes in polygons are in a counterclockwise direction.
/// Vertices for a single, ringed polygon are, therefore, always in clockwise order.
/// `
///
/// Inner Rings defines holes -> points are in counterclockwise order
/// Outer Rings's points are un clockwise order
///
/// https://stackoverflow.com/questions/1165647/how-to-determine-if-a-list-of-polygon-points-are-in-clockwise-order/1180256#1180256
Given the points, check if they represent an outer ring of a polygon
As per ESRI's Shapefile 1998 whitepaper:
`
The order of vertices or orientation for a ring indicates which side of the ring
is the interior of the polygon.
The neighborhood to the right of an observer walking along
the ring in vertex order is the neighborhood inside the polygon.
Vertices of rings defining holes in polygons are in a counterclockwise direction.
Vertices for a single, ringed polygon are, therefore, always in clockwise order.

Inner Rings defines holes -> points are in counterclockwise order
Outer Rings's points are un clockwise order


Given the points check if they represent an outer ring of a polygon As per ESRI ' s Shapefile 1998 whitepaper : ` The order of vertices or orientation for a ring indicates which side of the ring is the interior of the polygon . The neighborhood to the right of an observer walking along the ring in vertex order is the neighborhood inside the polygon . Vertices of rings defining holes in polygons are in a counterclockwise direction . Vertices for a single ringed polygon are therefore always in clockwise order . Inner Rings defines holes - > points are in counterclockwise order Outer Rings ' s points are un clockwise order
fn ring_type_from_points_ordering(points: &[Coord]) -> RingType {
    let area = points
        .windows(2)
        .map(|pts| (pts[1].x - pts[0].x) * (pts[1].y + pts[0].y))
        .sum::<f64>()
        / 2.0f64;
    if area < 0.0 {
        RingType::InnerRing
    } else {
        RingType::OuterRing
    }
}
fn ring_type_from_points_ordering ( points : & [ Coord ] ) -> RingType { let area = points . windows ( 2 ) . map ( | pts | ( pts [ 1 ] . x - pts [ 0 ] . x ) * ( pts [ 1 ] . y + pts [ 0 ] . y ) ) . sum :: < f64 > ( ) / 2.0f64 ; if area < 0.0 { RingType :: InnerRing } else { RingType :: OuterRing } }
Given the points, check if they represent an outer ring of a polygon
As per ESRI's Shapefile 1998 whitepaper:
`
The order of vertices or orientation for a ring indicates which side of the ring
is the interior of the polygon.
Given the points check if they represent an outer ring of a polygon As per ESRI ' s Shapefile 1998 whitepaper : ` The order of vertices or orientation for a ring indicates which side of the ring is the interior of the polygon .
points
&[Coord]
points
&[Coord]