I'm trying to use the boundary of London as a bounding polygon for an osmembrane pipeline. How do I convert http://www.openstreetmap.org/browse/relation/175342 into something more like http://wiki.openstreetmap.org/wiki/Osmosis/Polygon_Filter_File_Format so I can use it as the boundary polygon? asked 24 Aug '12, 14:49 PeterGribble |
I don't know if there is an easier way, but that is how I was doing: With JOSM
answered 24 Aug '12, 15:22 NicolasDumoulin Pieren Thanks, that seems to have worked. It's cooking away now, so I'll have to see how it comes out!
(24 Aug '12, 16:33)
PeterGribble
It seems to have come out in 60 different polygons, and when I ran my query it only found two results, whereas with a box covering the same rough area I got over 6000... Is that because the relation is made of 60 different ways? I've combined them in JOSM, and I'm about to try it again.
(28 Aug '12, 09:39)
PeterGribble
1
I don't understand which query you're talking. Ensure that you're merging all the ways in JOSM, and remove all the tags. Then, you can check the resulting .poly file by opening it in a text editor. You should have only one polygon section in the file.
(28 Aug '12, 10:11)
NicolasDumoulin
1
Have you seen the text at the top of osm2poly.pl? The bit about the "must have" tags is missing from Nicolas' description:
(28 Aug '12, 10:19)
cartinus
you're right cartinus, but I've never done that in my previous usage of this script … so I don't know, but you may try ;)
(28 Aug '12, 10:48)
NicolasDumoulin
1
Yeah, it seems the original data were split into different ways, and combining them in JOSM before converting has fixed the problem. It's all working fine! Thanks Nicolas :)
(04 Sep '12, 14:41)
PeterGribble
It seems that a JOSM plugin can be installed (name 'poly') and you can export the poly file directly from JOSM (http://josm.openstreetmap.de/wiki/Plugins)
(04 Sep '12, 16:40)
Pieren
showing 5 of 7
show 2 more comments
|
You can use: http://polygons.openstreetmap.fr/ It will convert your relation ID to a poly file and it has an API :
answered 06 Dec '18, 09:05 Potdeyaourt |