Skip to content

Add configurable max_collapse_distance property to Lua profiles for p…#7344

Merged
TheMarex merged 5 commits intoProject-OSRM:masterfrom
afarber:6171-configurable-max-collapse-distance
Jan 27, 2026
Merged

Add configurable max_collapse_distance property to Lua profiles for p…#7344
TheMarex merged 5 commits intoProject-OSRM:masterfrom
afarber:6171-configurable-max-collapse-distance

Conversation

@afarber
Copy link
Copy Markdown
Contributor

@afarber afarber commented Jan 27, 2026

Issue

Fixes #6171

  • Add max_collapse_distance property to ProfileProperties (default: 30.0m)
  • Expose property to Lua profiles via sol2
  • Add GetMaxCollapseDistance() to DataFacade interface
  • Pass parameter through collapse detection functions
  • Set foot profile to 10m to preserve short crossings for pedestrian safety

Tasklist

Requirements / Relations

Supersedes #7252

@kaligrafy
Copy link
Copy Markdown

Nice! Looks good!

Copy link
Copy Markdown
Member

@TheMarex TheMarex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for salvaging the previous PR! I've added a few recommendations and you may have missed one of the constants?

Comment thread include/engine/guidance/collapse_turns.hpp Outdated
Comment thread include/extractor/profile_properties.hpp Outdated
Comment thread src/engine/guidance/collapse_turns.cpp Outdated
@afarber afarber force-pushed the 6171-configurable-max-collapse-distance branch from b8fe669 to 46769e1 Compare January 27, 2026 22:04
@TheMarex TheMarex merged commit a5a3ba6 into Project-OSRM:master Jan 27, 2026
19 checks passed
@kaligrafy
Copy link
Copy Markdown

super great thanks!

@afarber afarber deleted the 6171-configurable-max-collapse-distance branch January 28, 2026 07:30
MarcelloPerathoner pushed a commit to MarcelloPerathoner/osrm-backend that referenced this pull request Feb 24, 2026
Project-OSRM#7344)

* Add configurable max_collapse_distance property to Lua profiles for pedestrian routing

* Add log entry

* Fix format

* Remove defaults, move init to constructor, pass max_collapse_distance

* Add missing GetMaxCollapseDistance
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

MAX_COLLAPSE_DISTANCE and precise pedestrian steps

3 participants