Expand description
§geo-core
Format-agnostic geospatial domain types, geometry helpers, and transforms for video-analysis.
This crate owns stable internal concepts such as coordinates, bounding boxes, geometry, features, collections, and geometry simplification. It intentionally does not depend on GeoJSON or expose wire-format crate types.
§Install
[dependencies]
geo-core = { package = "moritzbrantner-geo-core", version = "0.1.0" }use geo_core::{Coordinate, Geometry};Modules§
- surface
- Library-owned runtime surface for
geo-core.
Structs§
- BBox
- Data type for a 2D bounding box.
- Coordinate
- Data type for a 2D geographic coordinate.
- GeoFeature
- GeoJSON-compatible feature data.
- GeoFeature
Collection - GeoJSON-compatible feature collection data.
Enums§
- Geometry
- GeoJSON-shaped geometry data.
Functions§
- assemble_
multipolygon - Assembles polygon or multipolygon geometry from outer and inner ring segments.
- geometry_
intersects_ bbox - Returns true when a geometry intersects a bbox.
- is_
valid_ closed_ ring - Returns true when a ring has at least four positions and matching first/last points.
- line_
string - Creates linestring geometry from coordinates.
- map_
feature_ coordinates - Applies a coordinate transform to every coordinate in a feature.
- map_
geometry_ coordinates - Applies a coordinate transform to every coordinate in a geometry.
- normalize_
ring_ orientation - Reverses a ring when needed to match the requested orientation.
- point
- Creates point geometry.
- point_
in_ ring - Returns true when a point lies inside a closed ring.
- polygon_
or_ multipolygon - Creates polygon or multipolygon geometry from polygon rings.
- ring_
area - Returns signed planar area for a closed ring.
- simplify_
geometry - Simplifies lines and rings in a geometry using Douglas-Peucker simplification.
- simplify_
line - Simplifies an open line using Douglas-Peucker simplification.
- simplify_
ring - Simplifies a closed ring and preserves ring closure.
- stitch_
rings - Stitches line segments into closed rings.
- translate_
geometry - Translates every coordinate in a geometry by a longitude/x and latitude/y delta.
Type Aliases§
- Position
- Two-dimensional coordinate position in
[longitude, latitude]order. - Properties
- JSON object used for feature properties.