osmbuildings | OSM Buildings Classic | Map library
kandi X-RAY | osmbuildings Summary
kandi X-RAY | osmbuildings Summary
OSM Buildings is a JavaScript library for showing building geometry on interactive maps. There is also documentation of OSM Buildings Server side: It's safe use the master branch for production. For further information visit follow @osmbuildings on Twitter or report issues here on Github.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Returns the Julian position of the sun .
- Align props to an item and normalize it .
- fade out .
- Calculate the length of the Eometry .
- Converts a date value to days .
- Calculates the jian date of the given date .
- Returns the separation of a given b
- Calculate the arim of a point .
- get the offset from a point
- Calculate the separation of a day .
osmbuildings Key Features
osmbuildings Examples and Code Snippets
Community Discussions
Trending Discussions on osmbuildings
QUESTION
I am trying to retrieve building data from osmbuildings.org
The osmbuildings documentation (https://osmbuildings.org/documentation/data/) features an example URL (https://data.osmbuildings.org/0.2/anonymous/tile/15/17605/10743.json) that returns the JSON file for buildings that are located in Berlin at roughly 52°32'30.6"N 13°25'23.2"E coordinates.
Can I use this same site to get a JSON file for buildings in a different location? For example, I believe the X,Y coordinates using XYZ tile coordinates would be 25835 and 5221 for a location in Singapore for a zoom of 15 and the corresponding url would be https://data.osmbuildings.org/0.2/anonymous/tile/15/25835/5221.json. However, when I put this into the web browser, I don't get the json file like in the Berlin case. Can someone please explain?
I also tried different zoom values at the same location: https://data.osmbuildings.org/0.2/anonymous/tile/16/51672/8779.json
And at a slightly different location with fewer buildings: https://data.osmbuildings.org/0.2/anonymous/tile/16/51666/9459.json
...ANSWER
Answered 2020-Oct-25 at 23:05If you do not get the JSON file, you are probably getting an empty reply. This is likely because your specified tile does not contain any building data.
This can have various reasons, e.g. there are regions where no building data is available. In your case however, it seems to me that your conversion into X,Y coordinates is not correct for Singapore.
In my following example, I use the coordinates for the Singapore Marina Bay (https://www.openstreetmap.org/#map=15/1.2742/103.8617).
I converted the lon/lat to tile numbers using the formula from the OSM wiki (https://wiki.openstreetmap.org/wiki/Slippy_map_tilenames). In pseudo code:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install osmbuildings
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page