Deduplicate foward/reverse geometries

Changes the internal representation of compressed geometries to be a
single array shared between forward and reverse geometries that can be
read in either direction. Includes a change on
extractor::OriginalEdgeData to store via_geometry ids that indicate
which direction to read the geometry for that edge based edge.

Closes #2592
This commit is contained in:
Lauren Budorick
2016-07-22 18:23:54 +02:00
committed by Jake Pruitt
parent 73179641b1
commit a75e16e26b
24 changed files with 769 additions and 428 deletions
+1 -1
View File
@@ -125,7 +125,7 @@ getRepresentativeCoordinate(const NodeID from_node,
};
// Uncompressed roads are simple, return the coordinate at the end
if (!compressed_geometries.HasEntryForID(via_edge_id))
if (!compressed_geometries.HasZippedEntryForForwardID(via_edge_id) && !compressed_geometries.HasZippedEntryForReverseID(via_edge_id))
{
return extractCoordinateFromNode(traverse_in_reverse ? query_nodes[from_node]
: query_nodes[to_node]);