2

I have a osm file,i convert it to pbf file by osmosis.but it not convert to .map file.i use this in cmd:

osmosis --rb
file=city.osm.pbf -mw file=map.map bbox=34.3635451292,30.0247495993,57.513131979
3,53.2954765066

get it ERROR:

SEVERE: Execution aborted.
org.openstreetmap.osmosis.core.OsmosisRuntimeException: Argument bbox for task 1
-rb was not recognised.

what is this?!

My Osm File Bound Tag:

<bounds minlat="30.0247495993" minlon="53.2954765066" maxlat="34.3635451292" maxlon="57.5131319793"/>

1 Answer 1

1

The bbox for osmosis should have the order left - right - top - bottom. Note that West of Greenwich has to be negative.

Alternatively, you can write something like

--bb left=30. right=34. bottom=53. top=57. 

to avoid any misunderstanding.

See http://wiki.openstreetmap.org/wiki/Osmosis/Detailed_Usage_0.44#--bounding-box_.28--bb.29


EDIT

The Map-Writer plugin has its own definition of a bounding box:

https://code.google.com/p/mapsforge/wiki/GettingStartedMapWriter

minLat, minLon, maxLat, maxLon in exactly this order

invoked with bbox= instead of --bb

So you have to decided wether you use a bounding box on reading or on writing.

3
  • --mw is true.worked for osm files from osm site.
    – Ali
    Apr 13, 2014 at 9:56
  • i used: osmosis --rb city.osm.pbf -mw file=ddd.map --bb 34.,30.,57.,53. ERROR: Only one default (un-named) argument can exist per task. Arguments 3 and 2 have no name.
    – Ali
    Apr 13, 2014 at 10:13
  • the --bb belongs to the osmosis parameters, while bbox belongs to the mapwriter plugin.
    – AndreJ
    Apr 13, 2014 at 11:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.