Hi, if I have longitude and latitude I want to get information of building on that point.

I want dimensions of that building and orientation.

Is it possible?

Thank You.

asked 22 Feb '18, 15:51

zelenooq's gravatar image

zelenooq
21224
accept rate: 0%

edited 24 Feb '18, 11:54

aseerel4c26's gravatar image

aseerel4c26 ♦
31.9k16236548

Are you asking "is there a website that already shows this information" or something else?

(22 Feb '18, 16:05) SomeoneElse ♦

Idea is to get information which building it is so I can get dimensions of that building. But that add on information are interesting too. What do You mean by "web sit hat already shows this information"?

(23 Feb '18, 08:28) zelenooq

I think you have two steps here: first, identify which buildings is at that location. Second, get the building's dimensions.

For the first part, Overpass API may help you. I do not much of it, but the "query features tool" (number 11 at https://wiki.openstreetmap.org/wiki/Browsing ) lists enclosing features if you click the map at a location. Look at your browser's network console (e.g. ctrl+shift+E in Firefox) to see the issued request to Overpass API. There are many other questions on Overpass API.

For the second part, you can use Overpass API, too. It can return the building's edge nodes (which themselves contain coordinates). See the other question where-do-i-get-geographic-coordinates-for-osm-building-corners for more info on OSM building objects.

permanent link

answered 24 Feb '18, 01:16

aseerel4c26's gravatar image

aseerel4c26 ♦
31.9k16236548
accept rate: 18%

With overpass api, i only have edges, and only one height. For example, here is building with one base shape and with 3 heights. With overpass api you get only one height. For example, here is buidling with one base shape and 3 heights: https://osmbuildings.org/?lat=45.79836&lon=15.96269&zoom=18

(24 Feb '18, 11:55) zelenooq

And here I get only one height OverpassQL: [out:json] ; ( node ["building"] (45.798071354879,15.962183922529,45.798639834183,15.96318975091); way ["building"] (45.798071354879,15.962183922529,45.798639834183,15.96318975091); relation ["building"] (45.798071354879,15.962183922529,45.798639834183,15.96318975091); ); out;

; out skel;

(24 Feb '18, 11:56) zelenooq

{ "type": "FeatureCollection", "generator": "overpass-ide", "copyright": "The data included in this document is from www.openstreetmap.org. The data is made available under ODbL.", "timestamp": "2018-02-24T11:45:02Z", "features": [ { "type": "Feature", "properties": { "@id": "way/230237107", "building": "yes", "height": "94.6", "name": "Zagrepčanka" }, "geometry": {

(24 Feb '18, 11:57) zelenooq
1

your example building is mapped with building parts. See e.g. https://www.openstreetmap.org/way/230236690 . If osmbuildings shows different heights then you also can get the with overpass API because both act on the same data.

(24 Feb '18, 20:24) aseerel4c26 ♦

How can I know that there is more than one building parts? Above is my OverpassQL with only one height. How to get parts and height (and shape) of each shape? For this example. Thnx.

(26 Feb '18, 09:39) zelenooq

You need to understand

simply making random overpass api queries is a waste of (everybody's) time.

permanent link

answered 26 Feb '18, 09:22

SimonPoole's gravatar image

SimonPoole ♦
37.6k13282597
accept rate: 19%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×203
×100
×31
×2

question asked: 22 Feb '18, 15:51

question was seen: 1,185 times

last updated: 26 Feb '18, 09:39

powered by OSQA