openstreetmap

http://nominatim.openstreetmap.org api giving httpcode 403

懵懂的女人 提交于 2019-12-13 00:04:25
问题 api call to http://nominatim.openstreetmap.org/search?format=json started giving httpcode 403. We are using this api since last 2 years and never faced such issue. Suddenly today it started giving this error. Any kind of help is appreciated! 回答1: Added HTTP Referrer and it worked! As per their usage policy , valid HTTP Referrer is required. However not sure about how it used to work earlier. 来源: https://stackoverflow.com/questions/48700300/http-nominatim-openstreetmap-org-api-giving-httpcode

Overpass api to find the speed limit for a co-ordinate?

折月煮酒 提交于 2019-12-12 20:50:03
问题 I receive coordinate of a vehicle and I need to find out the speed limit of that road at which this vehicle is at?. I know you can find maxspeed for a certain bounded box like this www.overpass-api.de/api/xapi? [maxspeed= ][bbox=5.6283473,50.5348043,5.6285261,50.534884] but that is if this bounded box area has ONLY one speed limit. So say suppose there was an area which had two speed limit within the bounded box? My second concern is how should i make the bounded box since I am just getting

Enhance XML Parsing complexity - c# XML Looping

倖福魔咒の 提交于 2019-12-12 18:23:05
问题 I am writing my own c# custom map navigation program. I am using OpenStreetMaps for the map data. It's a large XML file that contains Nodes and ways. I wrote a convertor that strips the XML file from useless junk (like timestamp, user etc) so the file will become smaller. Now while I attempt to loop through the XML and convert the data to C# object Ways and Nodes I came across a problem. I need to do so much looping that the loading time is way too long. XML Example (w = way, n = node, rf =

Location change and put Marker on Click in openstreetmap

ぐ巨炮叔叔 提交于 2019-12-12 15:31:58
问题 I am new to Open Street Map map. I want to put the marker on map where i Tapped. I want to delete previous marker also. Please help me. Thanks in advance. Here is my code Overlay touchOverlay = new Overlay(this) { ItemizedIconOverlay<OverlayItem> anotherItemizedIconOverlay = null; @Override protected void draw(Canvas arg0, MapView arg1, boolean arg2) { } @Override public boolean onSingleTapConfirmed(final MotionEvent e, final MapView mapView) { Projection proj = mapView.getProjection();

How to handle long press on a map, using OSMDroid / OSMBonusPack in Android?

限于喜欢 提交于 2019-12-12 15:13:37
问题 I am trying to create a simple application with maps, on Android. I am using OSMDroid's MapView to render the basic OpenStreet Map mapview. I have a custom MapActivity that implements the MapEventsReceiver interface (from OSMBonusPack). In my activity's onCreate() , I create a MapEventsOverlay , I add it to the mapView . The problem is, longPressHelper() and singleTapUpHelper() are never called. See my code below. public abstract class CustomMap extends BaseActivity implements

Using map.osm and osmarender.xml from Android project in web project

北城以北 提交于 2019-12-12 13:38:52
问题 I edited an .osm file and a style file (osmarender.xml) some time ago and included it in an Android project (using osmosis and the Mapsforge library). Works fine and looks good. Now I would like to reuse these files in a web project using OpenLayers (or Leaflet?). Using this example (https://wiki.openstreetmap.org/wiki/OpenLayers_osm_file_example) I was able to display my (very local, but still 23 MB) map, however, it was all in yellow (no styles applied, of course) and it was rendered on top

OpenLayers: Does not work in internet explorer

痞子三分冷 提交于 2019-12-12 12:36:01
问题 I have this simple code: <HTML> <head> <title>Vector Icon Example</title> <script src="https://code.jquery.com/jquery-1.11.2.min.js"></script> <link rel="stylesheet" href="../apidoc/styles/bootstrap.min.css"> <script src="../apidoc/scripts/bootstrap.min.js"></script> <link rel="stylesheet" href="../css/ol.css" type="text/css"> <script src="../build/ol.js"></script> </head> <BODY> <div id="map" style="width: 100%, height: 400px">ggg</div> <script> new ol.Map({ layers: [ new ol.layer.Tile(

Cached/offline maps for iPhone?

旧巷老猫 提交于 2019-12-12 12:02:01
问题 I'd like to use use maps in my application, so that there will be as less as possible traffic. Perfect solution would be caching of map slices. I know it's not possible with google maps (license). I took a look on OpenStreetMaps and it seems as good solution. The next: SDK. The only one I've found is from CloudMade. The problem is, I found no related API methods for caching/offline calls. Are there any alternative solutions? 回答1: You might find more information on the Route-Me project Wiki.

How to get point of interest near my point using overpass-api?

安稳与你 提交于 2019-12-12 10:56:52
问题 I am using Overpass API. I have an issue to find some points of interest (cafes, hospitals, schools) near (around in 100-200 miles) my point. I have only latitude and longitude. Overpass API gives opportunity to get POIs using your place name. But I don't have it. I have only coordinates. How can I do that ? 回答1: Use the around statement! <query type="node"> <around lat="..." lon="..." radius="..."/> <has-kv k="amenity" v="cafe" /> </query> <print /> Try this example on overpass turbo! 来源:

Calculating shortest path on maps (Google Maps, Openstreetmaps, etc)

喜欢而已 提交于 2019-12-12 09:19:57
问题 I want to calculate shortest paths on some kind of already existing map API routes and then draw them. That being said, I need to be able to extract/get as more more data as possible (i.e. routes' coordinates) in order to be able to manipulate with it. My first thought was using Google Maps but as far as I understand, Google Maps API provides very little necessary data for my problem thus I won't be able to make any kind of accurate calculations. Also, existing Google Maps API's algorithms