valhalla

Crates.iovalhalla
lib.rsvalhalla
version0.6.6
created_at2025-06-26 15:48:54.250702+00
updated_at2025-08-17 21:46:30.560101+00
descriptionRust bindings for Valhalla routing engine
homepage
repositoryhttps://github.com/kinkard/valhalla-rs
max_upload_size
id1727510
size13,886,712
Stefan Kizim (kinkard)

documentation

README

About

C++-to-Rust bindings for Valhalla Routing Engine, powered by cxx.

valhalla-rs provides drop-in infrastructure (cargo add valhalla and you're ready) for utility projects that need to access Valhalla's road graph data, expose additional Valhalla functionality, or benefit from calling Valhalla's routing engine in-process.

valhalla-debug demonstrates this use case.

Features:

  • Tile access: Read Valhalla tiles and access road graph edges (DirectedEdge, EdgeInfo) and nodes (NodeInfo) - see tiles_tests for examples
  • Actor API: Route building and routing operations similar to Valhalla's Python bindings - see actor_tests for examples
  • Live traffic: Write traffic information directly to memory-mapped traffic.tar

Usage

Run cargo add valhalla or add this to your Cargo.toml:

[dependencies]
valhalla = "0.6"

Dependencies

Since Valhalla heavily relies on system libraries, you need to install the following dependencies to build this project:

sudo apt-get update && sudo apt-get install -y --no-install-recommends clang pkg-config build-essential cmake libboost-dev liblz4-dev libprotobuf-dev protobuf-compiler zlib1g-dev

See the Dockerfile for a complete reference setup, or the Valhalla documentation for other platforms.

License

This project provides Rust bindings for the Valhalla routing engine and distributes (via crates.io) the Valhalla source code. The entire project is licensed under the MIT License.

The original Valhalla license is available at valhalla/COPYING.

Commit count: 0

cargo fmt