Modules
Conversions between this crate and geo
. Long-term, we should think about directly using geo
or wrapping it, but in the meantime…
Structs
An angle, stored in radians.
Represents a rectangular boundary of Pt2D
points.
A circle, defined by a center and radius.
A distance, in meters. Can be negative.
A duration, in seconds. Can be negative.
A quad-tree to quickly find the closest points to some polylines.
Represents a rectangular boundary of LonLat
points. After building one of these, LonLat
s
can be transformed into Pt2D
s, treating the top-left of the boundary as (0, 0), and growing
to the right and down (screen-drawing order, not Cartesian) in meters.
This represents world space, NOT LonLat.
A line segment.
Represents a (longitude, latitude) point.
Most of the time, [0, 1]. But some callers may go outside this range.
This represents world-space in meters.
Maybe a misnomer, but like a PolyLine, but closed.
In meters per second. Can be negative.
In seconds since midnight. Can’t be negative.
Specifies how to stringify different geom objects.
Enums
Constants
Traits
Functions
Deserializes a trimmed f64
from an i32
.
Serializes a trimmed f64
as an i32
to save space.
Reduce the precision of an f64. This helps ensure serialization is idempotent (everything is exacly the same before and after saving/loading). Ideally we’d use some kind of proper fixed-precision type instead of f64.