Giter Site home page Giter Site logo

giraldeau / osrm-frontend-v2 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from project-osrm/osrm-frontend

0.0 2.0 2.0 17.62 MB

Modular rewrite of the OSRM frontend using LRM

License: BSD 2-Clause "Simplified" License

Makefile 0.01% JavaScript 95.61% CSS 0.88% HTML 3.51%

osrm-frontend-v2's Introduction

This is the frontend served at https://map.project-osrm.org.

This frontend is builds heavily ontop of Leaflet Routing Machine. If you need a simple OSRM integration in your webpage, you should start from there.

Development

Local development

Install dependencies via:

npm install

Then compile the assets and start a server with:

npm start

This will start an auto-reloading webserver at http://localhost:9966

Local OSRM instance

The most common modifcation is to add your own OSRM endpoint. For this open src/leaflet_options.js:

  services: [{
    label: 'Car (fastest)',
    path: 'http://myserver.example.com/route/v1'
  }],

Replace the path with whatever your endpoint looks like.

Debug Interface

There is a debug interface for osrm-backend, accessible at http://127.0.0.1:9966/debug . It shows the edges of the graph, with the speed, and in pink the "small components", areas of the road network that are isolated from the rest for some reason (invalid turn restrictions, barriers, disconnected, incorrect oneways, etc) and are discarded in the routing machine.

Warning : If you want to debug your own osrm-backend, you have to edit debug/index.html and change http://router.project-osrm.org/tile/v1/car/tile to your own endpoint.

osrm-frontend-v2's People

Contributors

amyleew avatar themarex avatar freenerd avatar danpat avatar daniel-j-h avatar marcows avatar danyeaw avatar jjshoe avatar ymoisan avatar perliedman avatar desdroid avatar frederickjansen avatar jcoupey avatar 1ec5 avatar geohacker avatar lonvia avatar stevage avatar julienfr112 avatar

Watchers

Francis Giraldeau avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.