Giter Site home page Giter Site logo

API suggestion about node-osrm HOT 9 CLOSED

jfirebaugh avatar jfirebaugh commented on July 17, 2024
API suggestion

from node-osrm.

Comments (9)

DennisOSRM avatar DennisOSRM commented on July 17, 2024

Is this for NodeJS or browser?

The shared memory stuff is backend only, ie. the browser shouldn't know about it

from node-osrm.

jfirebaugh avatar jfirebaugh commented on July 17, 2024

This is for the node-OSRM API.

from node-osrm.

DennisOSRM avatar DennisOSRM commented on July 17, 2024

Ok, cool. We shouldn't use any ini file as thats purely optional and deprecated now. The C++ way to do it now is to populate an unordered map with the paths and pass it to the OSRM c'tor:

https://github.com/DennisOSRM/Project-OSRM/blob/develop/Util/ServerPaths.h

So passing the filenames directly sounds better to me.

from node-osrm.

jfirebaugh avatar jfirebaugh commented on July 17, 2024

👍

from node-osrm.

DennisOSRM avatar DennisOSRM commented on July 17, 2024

A convenient feature would be just to give the base name, i.e '/path/to/file.osrm' and the 'new.Engine(...)' call adds the appropriate suffixes assuming that all files are in the same directory.

from node-osrm.

jfirebaugh avatar jfirebaugh commented on July 17, 2024

@DennisOSRM Seems like that should built into the C++ API and then just naturally be supported by the Node bindings.

from node-osrm.

DennisOSRM avatar DennisOSRM commented on July 17, 2024

@jfirebaugh Ok, is on the todo-list. If the user supplies an .osrm file instead of an .ini it will do it's magic automatically. For now, let's continue with an .ini file. This can then be added in due time. Does that make sense?

from node-osrm.

springmeyer avatar springmeyer commented on July 17, 2024

I'm starting to take a look at this.

from node-osrm.

jfirebaugh avatar jfirebaugh commented on July 17, 2024

Config part of this is done. Engine should still have dedicated route, locate, and nearest functions to replace Query.

from node-osrm.

Related Issues (20)

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.