Struct map_model::raw::RawMap [−][src]
pub struct RawMap { pub name: MapName, pub roads: BTreeMap<OriginalRoad, RawRoad>, pub intersections: BTreeMap<NodeID, RawIntersection>, pub buildings: BTreeMap<OsmID, RawBuilding>, pub bus_routes: Vec<RawBusRoute>, pub areas: Vec<RawArea>, pub parking_lots: Vec<RawParkingLot>, pub parking_aisles: Vec<(WayID, Vec<Pt2D>)>, pub boundary_polygon: Polygon, pub gps_bounds: GPSBounds, pub config: MapConfig, }
Fields
name: MapName
roads: BTreeMap<OriginalRoad, RawRoad>
intersections: BTreeMap<NodeID, RawIntersection>
buildings: BTreeMap<OsmID, RawBuilding>
bus_routes: Vec<RawBusRoute>
areas: Vec<RawArea>
parking_lots: Vec<RawParkingLot>
parking_aisles: Vec<(WayID, Vec<Pt2D>)>
boundary_polygon: Polygon
gps_bounds: GPSBounds
config: MapConfig
Implementations
(Intersection polygon, polygons for roads, list of labeled polygons to debug)
Generate the trimmed PolyLine
for a single RawRoad by calculating both intersections
pub fn merge_short_road(
&mut self,
short: OriginalRoad
) -> Result<(NodeID, NodeID, Vec<OriginalRoad>, Vec<OriginalRoad>)>
pub fn merge_short_road(
&mut self,
short: OriginalRoad
) -> Result<(NodeID, NodeID, Vec<OriginalRoad>, Vec<OriginalRoad>)>
(the surviving intersection, the deleted intersection, deleted roads, new roads)
Look for short roads that should be merged, and mark them as junction=intersection.
pub fn run_all_simplifications(
&mut self,
consolidate_all_intersections: bool,
timer: &mut Timer<'_>
)
pub fn run_all_simplifications(
&mut self,
consolidate_all_intersections: bool,
timer: &mut Timer<'_>
)
Run a sequence of transformations to the RawMap before converting it to a full Map.
We don’t want to run these during the OSM->RawMap import stage, because we want to use the map_editor tool to debug the RawMap.
Trait Implementations
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more