Trait geo::algorithm::extremes::Extremes [−][src]
Find the extreme coordinates and indices of a geometry.
Examples
use geo::extremes::Extremes; use geo::polygon; // a diamond shape let polygon = polygon![ (x: 1.0, y: 0.0), (x: 2.0, y: 1.0), (x: 1.0, y: 2.0), (x: 0.0, y: 1.0), (x: 1.0, y: 0.0), ]; let extremes = polygon.extremes().unwrap(); assert_eq!(extremes.y_max.index, 2); assert_eq!(extremes.y_max.coord.x, 1.); assert_eq!(extremes.y_max.coord.y, 2.);
Required methods
Loading content...Implementors
impl<'a, T, G> Extremes<'a, T> for G where
G: CoordsIter<'a, Scalar = T>,
T: CoordNum,
[src]
G: CoordsIter<'a, Scalar = T>,
T: CoordNum,