Skip to content

Commit

Permalink
Approximate with DistancePlaneProjection
Browse files Browse the repository at this point in the history
  • Loading branch information
otbutz committed Apr 22, 2024
1 parent 1c2f22e commit 1fa6172
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
import com.graphhopper.routing.weighting.WeightApproximator;
import com.graphhopper.routing.weighting.Weighting;
import com.graphhopper.storage.Graph;
import com.graphhopper.util.DistancePlaneProjection;

import java.util.Arrays;

Expand Down Expand Up @@ -78,8 +79,10 @@ public LMApproximator(Graph graph, Weighting lmWeighting, Weighting routingWeigh
this.graph = graph;
this.lmWeighting = lmWeighting;
this.routingWeighting = routingWeighting;
this.fallBackApproximation = new BeelineWeightApproximator(graph.getNodeAccess(), lmWeighting);
this.beelineApproximation = new BeelineWeightApproximator(graph.getNodeAccess(), routingWeighting);
this.fallBackApproximation = new BeelineWeightApproximator(graph.getNodeAccess(), lmWeighting)
.setDistanceCalc(DistancePlaneProjection.DIST_PLANE);
this.beelineApproximation = new BeelineWeightApproximator(graph.getNodeAccess(), routingWeighting)
.setDistanceCalc(DistancePlaneProjection.DIST_PLANE);
this.maxBaseNodes = maxBaseNodes;
}

Expand Down

0 comments on commit 1fa6172

Please sign in to comment.