Set heading_penalty in GHRequest

I’m creating a extended documentation on heading:
graphhopper/heading.md

At the end I focus on setting the heading_penalty parameter, which works perfectly fine with a get request.

My question is:

Is setting the heading_penalty supported in GHRequest?

I want to include it in HeadingExample.java (Java) and HeadingExamples.java (API). I need something like setHeadingPenalty.

If it’s not supported I can try implement it but I wanted to doublecheck with you.

You can set it via the hints field: graphhopper/GraphHopperTest.java at 9f442cb7db22f027610f03ef0b6cbe2e372d3dc0 · graphhopper/graphhopper · GitHub

        req.putHint("heading_penalty", 400); // ... or
        req.putHint(Routing.HEADING_PENALTY, "400");
1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.