remove all but specific highways in osmosis

المشرف العام

Administrator
طاقم الإدارة
I want to display entire country OSM data in my application.
The problem my application dont know how to deal large maps.
Instead of chunking the map into 5-10 small chunks, I wish to display only the following items:

highway=trunk, highway=trunk_link, highway=primary,highway=primary_link, highway=secondary, highway=secondary_link,highway=tertiary,highway=tertiary_link ,highway=motorway, highway=motorway_linkAll roads but residentials. I dont want to show rails, polygon shapes (area, landuse, parks.. etc..) Only roads!

But after running this command:

osmosis.bat --read-xml "C:\belgium-latest.osm" --tag-filter accept-nodes highway=trunk, highway=trunk_link, highway=primary,highway=primary_link, highway=secondary, highway=secondary_link,highway=tertiary,highway=tertiary_link ,highway=motorway, highway=motorway_link --write-xml "C:\belgium-latest-highwayOnly.osm"I still have the other shapes (not only highways) and the osm file is too big.. it shrunks only 25%~.. i hoped it to be smaller.

I am doing something wrong ? should i add objects to reject-nodes attriute ?



أكثر...
 
أعلى