Last active
February 24, 2016 08:57
-
-
Save jothirnadh/5dee4accfbee5d9c8fb6 to your computer and use it in GitHub Desktop.
Revisions
-
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 0 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -150,8 +150,6 @@ Before mapping turn lanes activate the following preferences in JOSM to visualiz ### [Role of turn:lane in a relation](https://github.com/mapbox/mapping/issues/153#issuecomment-185679507) ## Different scenarios we came across while mapping ### 1. Counting number of turn lanes: -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -12,6 +12,8 @@ A Way in OSM represents road as a complex feature. First of all, it is a line th ### What is a lane: To understand the complexity of a Way, the widht of the road in divided into absolute (meters) or in relative number of lanes units of measurement. Numbers of lanes on the road will help us to make our driving decisions. At least road has one lane for driving in both directions. This is a rough assumption. As a general rule, the road has two or more lanes for vehicular traffic.  Use the `lanes=*` key to tag how many full-width traffic lanes there are on a highway. #### Roads with more than two lanes -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 4 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -7,10 +7,12 @@ For now, most common approach for road mapping is to trace roads following their  ### What is a Way: A Way in OSM represents road as a complex feature. First of all, it is a line that represents an object (road), which covers a specific **area** on the ground. In order to show the shape and contours of the road we may to draw a polygon and mark it accordingly. (See [`area:highway`=`*`](http://wiki.openstreetmap.org/wiki/Key:area:highway), [description](http://wiki.openstreetmap.org/wiki/Proposed_features/Street_area) and [comprehensive mapping guide](http://wiki.openstreetmap.org/wiki/Proposed_features/area_highway/mapping_guidelines) in Wiki OSM) ### What is a lane: To understand the complexity of a Way, the widht of the road in divided into absolute (meters) or in relative number of lanes units of measurement. Numbers of lanes on the road will help us to make our driving decisions. At least road has one lane for driving in both directions. This is a rough assumption. As a general rule, the road has two or more lanes for vehicular traffic. Use the `lanes=*` key to tag how many full-width traffic lanes there are on a highway. #### Roads with more than two lanes -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 3 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,4 +1,4 @@ # Mapping roads for navigational purpose ## Roads: Roads are the main map features that we use for rendering navigational applications. Accurate roads representation leads not only to the well-looking map but also to a more precise navigation. @@ -7,9 +7,10 @@ For now, most common approach for road mapping is to trace roads following their  ### What is a Way: A Way in OSM represents road as a complex feature. First of all, it is a line that represents an object (road), which covers a specific **area** on the ground. To show this, we can specify the width of the road in absolute (meters) or in relative (number of **lanes**) units of measurement. Numbers of lanes on the road will help us to make our driving decision. At least road has 1 lane for driving in both directions. This is a rough assumption. As a general rule, the road has two or more lanes for vehicular traffic. In order to show the shape and contours of the road we may to draw a polygon and mark it accordingly. (See [`area:highway`=`*`](http://wiki.openstreetmap.org/wiki/Key:area:highway), [description](http://wiki.openstreetmap.org/wiki/Proposed_features/Street_area) and [comprehensive mapping guide](http://wiki.openstreetmap.org/wiki/Proposed_features/area_highway/mapping_guidelines) in Wiki OSM) ### What is a lane: To understand the complexity of the Way, the widht of the road in divided into A way is Use the lanes=* key to tag how many full-width traffic lanes there are on a highway. #### Roads with more than two lanes -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 3 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -131,7 +131,9 @@ Before mapping turn lanes activate the following preferences in JOSM to visualiz  * For each road segment tag the turn lanes based on the road markings in the direction of the way. Eg. `turn:lanes=left|left;through|through`. Check [OSM turn:lanes](http://wiki.openstreetmap.org/wiki/Key:turn:lanes) for reference.  * For bi-directional segments, use `turn:lanes:backward=` and `turn:lanes:forward=` to specify turn lanes in each direction. -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 5 additions and 5 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -123,21 +123,21 @@ Before mapping turn lanes activate the following preferences in JOSM to visualiz * Filter out non road features with inverse filter: `boundary: | leisure: | landuse: | waterway: | amenity: | natural: | building:` ### Mapping a turn lane * Check all roads in the imagery for turn lanes at junction points  * Split the road into segments based on the total number of lanes for the segment  * For each road segment tag the turn lanes based on the road markings in the direction of the way. Eg. `turn:lanes=left|through|right`. Check [OSM turn:lanes](http://wiki.openstreetmap.org/wiki/Key:turn:lanes) for reference. * For bi-directional segments, use `turn:lanes:backward=` and `turn:lanes:forward=` to specify turn lanes in each direction.  * Verify correct tagging using the `Lane attributes` style  -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 6 additions and 6 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -123,23 +123,23 @@ Before mapping turn lanes activate the following preferences in JOSM to visualiz * Filter out non road features with inverse filter: `boundary: | leisure: | landuse: | waterway: | amenity: | natural: | building:` ### Mapping a turn lane 1. Check all roads in the imagery for turn lanes at junction points  2. Split the road into segments based on the total number of lanes for the segment  3. For each road segment tag the turn lanes based on the road markings in the direction of the way. Eg. `turn:lanes=left|through|right`. Check [OSM turn:lanes](http://wiki.openstreetmap.org/wiki/Key:turn:lanes) for reference. 4. For bi-directional segments, use `turn:lanes:backward=` and `turn:lanes:forward=` to specify turn lanes in each direction.  5. Verify correct tagging using the `Lane attributes` style  ### [Role of turn:lane in a relation](https://github.com/mapbox/mapping/issues/153#issuecomment-185679507) -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 5 additions and 11 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -112,11 +112,11 @@ bothways |  * *`Tagging Presets > lane attributes`*  @@ -132,21 +132,15 @@ Before mapping turn lanes activate the following preferences in JOSM to visualiz  - For each road segment tag the turn lanes based on the road markings in the direction of the way. Eg. `turn:lanes=left|through|right`. Check [OSM turn:lanes](http://wiki.openstreetmap.org/wiki/Key:turn:lanes) for reference. - For bi-directional segments, use `turn:lanes:backward=` and `turn:lanes:forward=` to specify turn lanes in each direction.  - Verify correct tagging using the `Lane attributes` style  ### [Role of turn:lane in a relation](https://github.com/mapbox/mapping/issues/153#issuecomment-185679507) ### Difference between a turn:lane and a turn: restruction -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -112,7 +112,7 @@ bothways |  -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -112,11 +112,11 @@ bothways |  * `*Tagging Presets > lane attributes*`  -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 5 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -129,9 +129,13 @@ Before mapping turn lanes activate the following preferences in JOSM to visualiz - Split the road into segments based on the total number of lanes for the segment  - For each road segment tag the turn lanes based on the road markings in the direction of the way. Eg. `turn:lanes=left|through|right`. Check [OSM turn:lanes](http://wiki.openstreetmap.org/wiki/Key:turn:lanes) for reference. - For bi-directional segments, use `turn:lanes:backward=` and `turn:lanes:forward=` to specify turn lanes in each direction. - Verify correct tagging using the `Lane attributes` style  **There are generally two different scenarios in mapping turn lanes:** -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 4 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -117,14 +117,18 @@ Before mapping turn lanes activate the following preferences in JOSM to visualiz  * **Tagging Presets > lane attributes**  * Filter out non road features with inverse filter: `boundary: | leisure: | landuse: | waterway: | amenity: | natural: | building:` ### Mapping a turn lane - Check all roads in the imagery for turn lanes at junction points  - Split the road into segments based on the total number of lanes for the segment - For each road segment tag the turn lanes based on the road markings in the direction of the way. Eg. `turn:lanes=left|through|right`. See [OSM turn:lanes](http://wiki.openstreetmap.org/wiki/Key:turn:lanes) - For bi-directional segments, use `turn:lanes:backward=` and `turn:lanes:forward=` to specify turn lanes in each direction. - Verify correct tagging using the `Lane attributes` style -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 116 additions and 9 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,5 +1,5 @@ # Mapping roads for navigation ## Roads: Roads are the main map features that we use for rendering navigational applications. Accurate roads representation leads not only to the well-looking map but also to a more precise navigation. For now, most common approach for road mapping is to trace roads following their centroid. This way of tracing looks good for 2-lanes roads like unclassified and residential roads or for tracing over low-res imagery. @@ -9,13 +9,9 @@ For now, most common approach for road mapping is to trace roads following their ### What is a Way: A Way in OSM represents road as a complex feature. First of all, it is a line that represents an object (road), which covers a specific **area** on the ground. To show this, we can specify the width of the road in absolute (meters) or in relative (number of lanes) units of measurement. Numbers of lanes on the road will help us to make our driving decision. At least road has 1 lane for driving in both directions. This is a rough assumption. As a general rule, the road has two or more lanes for vehicular traffic. In order to show the shape and contours of the road we may to draw a polygon and mark it accordingly. (See [`area:highway`=`*`](http://wiki.openstreetmap.org/wiki/Key:area:highway), [description](http://wiki.openstreetmap.org/wiki/Proposed_features/Street_area) and [comprehensive mapping guide](http://wiki.openstreetmap.org/wiki/Proposed_features/area_highway/mapping_guidelines) in Wiki OSM) ### What is a lane: #### Roads with more than two lanes There are two cases: - Roads which carry traffic in both directions and @@ -80,7 +76,7 @@ turn:lanes:both_ways=left Case when number of lanes is even but numbers of lanes for each direction not equal.  ### Dual carriageway roads Trace ways for dual carriageways road for each direction as close as possible to their outermost edge. There is some reasons for such way of tracing: - In lower zoom levels we will be able to distinguish dual carriageways road from bidirectional one just glimpsing on the map - GPS devices will associate their position with right road segments even in bad signal reception conditions @@ -90,7 +86,7 @@ Trace ways for dual carriageways road for each direction as close as possible to Place nodes of the lines in each direction, opposite to each other, which will get a good view of the road on the map  ## What is a turn lane: A turn lane is an auxiliary lane demarcated on the road to specify directions to ongoing vehicles. Turn lanes serve two purposes: * Provide directional information to the ongoing vehicles and @@ -113,3 +109,114 @@ slight_right |  merge_to_right |  bothways |  ### Pre-requirements for mapping a turn lane in JOSM: Before mapping turn lanes activate the following preferences in JOSM to visualize the mapped turn lanes: `preferences > Map Settings` * **Map Paint Styles > Lanes and road attributes**  * **Tagging Presets > lane attributes**  * Filter out non road features with inverse filter: `boundary: | leisure: | landuse: | waterway: | amenity: | natural: | building:` ### Mapping a turn lane - Check all roads in the imagery for turn lanes at junction points  - Split the road into segments based on the total number of lanes for the segment - For each road segment tag the turn lanes based on the road markings in the direction of the way. Eg. `turn:lanes=left|through|right`. See [OSM turn:lanes](http://wiki.openstreetmap.org/wiki/Key:turn:lanes) - For bi-directional segments, use `turn:lanes:backward=` and `turn:lanes:forward=` to specify turn lanes in each direction. - Verify correct tagging using the `Lane attributes` style  **There are generally two different scenarios in mapping turn lanes:** * Mapping turn lanes(oneway): * Mapping turn lanes (bi-directional ways)  ### [Role of turn:lane in a relation](https://github.com/mapbox/mapping/issues/153#issuecomment-185679507) ### Difference between a turn:lane and a turn: restruction ## Different scenarios we came across while mapping ### 1. Counting number of turn lanes: If there are no clear cut demarcations on the road and yet cars are parked on either sides of the road, consider them as drive lanes. Case below:  ### 2. Parking lane issue: In the U.S., when parallel parking spaces are marked, they are marked in one of [three ways](http://mutcd.fhwa.dot.gov/htm/2009/part3/fig3b_21_longdesc.htm):  Here’s an example of the box marking style: [](https://commons.wikimedia.org/wiki/File:J.S._Shingler_Bldg_%28East_face%29,_McLendon_St,_Ashburn.JPG) ### 3. Starting a turn lane: Turn lanes should begin exactly as per the marking in the imagery, not before or after.  ### 4. Ending a turn lane: Turn lanes should terminate at the first highway junction after the start of the turn lane.  ### 5. Turn lane forward In case of bi-directional ways, the key [turn:lanes:forward=*](http://wiki.openstreetmap.org/wiki/Forward_%26_backward,_left_%26_right) describes only the turning indications on the lanes in the same direction as the osm-way; while adding this we must view the road in the direction to the osm-way(**on the direction where the osm-way arrow is pointing**).  ### 6. Turn lane backward In case of bi-directional ways, the key [turn:lanes:backward=*](http://wiki.openstreetmap.org/wiki/Forward_%26_backward,_left_%26_right) describes only the turning indications on the lanes in the opposite direction as the osm-way; while adding this we must view the road in the oppoiste direction to the osm-way(**opposite to direction where the osm-way arrow is pointing**).  *Adding a `turn:lanes:backward` tag ### 7. [How to add a HOV](http://wiki.openstreetmap.org/wiki/Key:hov) HOV is a symbol demorcated on major roads generally used to indicate vehicle occupancy requirements.  In the above cases tag given to the road are `hov:lanes=designated|yes|yes|yes` ### 8. Bicycle lanes and road shoulders: Road shoulders and bicycle lanes are ignored from the lane count. Both these roads are `lanes=2` <img width="489" alt="screenshot 2015-12-10 17 35 07" src="https://cloud.githubusercontent.com/assets/126868/11715007/628dd90a-9f64-11e5-9e22-58614d2afbf6.png">  *lanes=3 for the above example, ignoring the two cycle ways* * Ignore bicycle lanes even though they are in the middle;example below:  *The middle way is also a biclcle lane which is not counted while adding the `lanes` tag* * Additionally, `Strava global-heat cycle` layer can used to verify if a particular lane is a cycle-way. `tms[16]:http://globalheat.strava.com/tiles/cycling/color3/{zoom}/{x}/{y}.png` ### 9. Lane marked as a separate way Do not add turn lanes in these cases where the only turn lane is already a mapped as a separate way. <img width="348" alt="9e4a470a-9f62-11e5-83ac-920ac6181842" src="https://cloud.githubusercontent.com/assets/13744156/13173428/6694c468-d723-11e5-96be-b95502b9f58a.png"> ### 10. Bidirectional turn lanes: These are the lanes marked with symbol representing both directions at a time.  Tag used for such lanes are `turn:lanes:both_ways=*` ### 11. Mapillary Plugin to verify turn lanes: The imagery at some places is not very clear and at-times the turn-lanes are covered by cars. In situations like these `Mapillary plugin` can be used. If there is Mapillary imagery coverage in that area, they can used to verify the presence of turn-lanes. **Name of the plugin:** Mapillary  -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 25 additions and 23 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -13,29 +13,7 @@ General road tracing is easy - trace roads by its middle axis. In our everyday life we comeacross with different types of road designs. How we have to trace it? ### What is a lane: ## Roads with more than two lanes @@ -111,3 +89,27 @@ Trace ways for dual carriageways road for each direction as close as possible to Place nodes of the lines in each direction, opposite to each other, which will get a good view of the road on the map  ### What is a turn lane: A turn lane is an auxiliary lane demarcated on the road to specify directions to ongoing vehicles. Turn lanes serve two purposes: * Provide directional information to the ongoing vehicles and * Provide the lane information to be choosen for the vehicles changing their direction ### Types of turn lanes There are a total of 12 different turn lanes demarcated on the roads. They are: Turn Lane | Representation --- | --- left |  right |  through |  left_through |  right_through |  left_through_right |  left_right |  slight_left |  slight_right |  merge_to_left |  merge_to_right |  bothways |  -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -19,8 +19,8 @@ Turn lanes serve two purposes: * Provide directional information to the ongoing vehicles and * Provide the lane information to be choosen for the vehicles changing their direction ### Types of turn lanes There are a total of 12 different turn lanes demarcated on the roads. They are: Turn Lane | Representation --- | --- -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 30 additions and 6 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -13,6 +13,30 @@ General road tracing is easy - trace roads by its middle axis. In our everyday life we comeacross with different types of road designs. How we have to trace it? ### What is a turn lane: A turn lane is an auxiliary lane demarcated on the road to specify directions to ongoing vehicles. Turn lanes serve two purposes: * Provide directional information to the ongoing vehicles and * Provide the lane information to be choosen for the vehicles changing their direction ### Types of turn:lane There are a total of 12 different types of turn lanes demarcated on the roads. They are: Turn Lane | Representation --- | --- left |  right |  through |  left_through |  right_through |  left_through_right |  left_right |  slight_left |  slight_right |  merge_to_left |  merge_to_right |  bothways |  ## Roads with more than two lanes There are two cases: @@ -55,15 +79,15 @@ Our decision is to trace **main direction**! Before tracing (fix previous tracing), we need to inspect the strat and end points of the road segments. We need to identify the road direction, general numbers of lanes and the places where there are extra lanes. Based on this we choose our strategy. ### Bidirectional roads At the image below general number of lanes is two - `lanes=2`. Orange line is the center line of bidirectional way which represents main movement direction. We don't change its flow when extra lanes are appeared. Just set `lanes=3`+`lanes:forward=2`+`lanes:backward=1` tags for the segment at right low corner with extra lane for turn to right. Optionally we may specify [placement](https://wiki.openstreetmap.org/wiki/Proposed_features/placement) of the lanes relatively to the our OSM-way.   Look to the below image. There is we have two tagging variants: 1. `lanes=2` - 1 lane for each direction, or 2. `lanes=3` - denote middle lane for left turn as: point_left: _this is discussed_ ``` highway=residential @@ -80,10 +104,10 @@ turn:lanes:both_ways=left ### Dual carriageways roads Trace ways for dual carriageways road for each direction as close as possible to their outermost edge. There is some reasons for such way of tracing: - In lower zoom levels we will be able to distinguish dual carriageways road from bidirectional one just glimpsing on the map - GPS devices will associate their position with right road segments even in bad signal reception conditions - Link roads which join to or fork from main highway will look good and will be connected in right places - We are able to adjust position of the lanes on the road using `placement=right_of:3` tagging if needed. Place nodes of the lines in each direction, opposite to each other, which will get a good view of the road on the map  -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -40,7 +40,7 @@ Roads with an even number of lanes tend to have an equal number of lanes in each In opposite case, when numbers of lanes for each directions don't match, we have to explicitly denote their numbers with `lanes:forward=*`+`lanes:backward=*` along with overall numbers of `lanes=*`. We are not aable to draw a road on its center line, especially if roads join/fork or the number of lanes change. Imagine two roads which join: how would you draw the OSM-way around the point where the roads join?  @@ -52,7 +52,7 @@ We aren't be able always to draw a road on its center line, especially if roads Our decision is to trace **main direction**! Before tracing (fix previous tracing), we need to inspect the strat and end points of the road segments. We need to identify the road direction, general numbers of lanes and the places where there are extra lanes. Based on this we choose our strategy. ### Bidirectional roads At the image below general number of lanes is two - `lanes=2`. Orange line is the center line of bidirectional way which represents main movement direction. We don't change its flow when extra lanes are appeared. Just set `lanes=3`+`lanes:forward=2`+`lanes:backward=1` for the segment at right low corner with extra lane for turn to right. Optionally we may specify [placement](https://wiki.openstreetmap.org/wiki/Proposed_features/placement) of the lanes relatively to the our OSM-way. -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 5 additions and 5 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -29,11 +29,11 @@ To set number of lanes for roads which carry traffic in both directions use [`:b `Forward` means the direction in which the way is drawn in OpenStreetMap, while `backward` means the opposite direction. ``` xml Example: highway=tertiary lanes=5 lanes:forward=3 lanes:backward=2 ``` Roads with an even number of lanes tend to have an equal number of lanes in each direction by default and thus we may omit `:forward` and `:backward` tagging. -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 1 addition and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -29,6 +29,7 @@ To set number of lanes for roads which carry traffic in both directions use [`:b `Forward` means the direction in which the way is drawn in OpenStreetMap, while `backward` means the opposite direction. ``` xml *Example:* highway=tertiary lanes=5 lanes:forward=3 -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -16,11 +16,11 @@ In our everyday life we comeacross with different types of road designs. How we ## Roads with more than two lanes There are two cases: - Roads which carry traffic in both directions and  - Dual carriageway roads.  -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 2 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -25,7 +25,8 @@ There are two cases:  To set number of lanes for roads which carry traffic in both directions use [`:backward` and `:forward` suffixes](http://wiki.openstreetmap.org/wiki/Forward_%26_backward,_left_%26_right#Forward_and_backward) `Forward` means the direction in which the way is drawn in OpenStreetMap, while `backward` means the opposite direction. ``` xml highway=tertiary -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 4 additions and 4 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,7 +6,7 @@ For now, most common approach for road mapping is to trace roads following their  ### What is a Way: A Way in OSM represents road as a complex feature. First of all, it is a line that represents an object (road), which covers a specific **area** on the ground. To show this, we can specify the width of the road in absolute (meters) or in relative (number of lanes) units of measurement. Numbers of lanes on the road will help us to make our driving decision. At least road has 1 lane for driving in both directions. This is a rough assumption. As a general rule, the road has two or more lanes for vehicular traffic. In order to show the shape and contours of the road we may to draw a polygon and mark it accordingly. (See [`area:highway`=`*`](http://wiki.openstreetmap.org/wiki/Key:area:highway), [description](http://wiki.openstreetmap.org/wiki/Proposed_features/Street_area) and [comprehensive mapping guide](http://wiki.openstreetmap.org/wiki/Proposed_features/area_highway/mapping_guidelines) in Wiki OSM) General road tracing is easy - trace roads by its middle axis. @@ -15,16 +15,16 @@ In our everyday life we comeacross with different types of road designs. How we ## Roads with more than two lanes There are two cases: - Roads which carry traffic in both directions and  - Dual carriageway roads.  To set number of lanes for roads which carry traffic in both directions use [`:backward` and `:forward` suffixes](http://wiki.openstreetmap.org/wiki/Forward_%26_backward,_left_%26_right#Forward_and_backward) >`Forward` means the direction in which the way is drawn in OpenStreetMap, while `backward` means the opposite direction. ``` xml -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -26,7 +26,7 @@ There is two cases: To set number of lanes for roads which carry traffic in both directions use `:backward` and `:forward` suffixes - [http://wiki.openstreetmap.org/wiki/Forward_&_backward,_left_&_right#Forward_and_backward](http://wiki.openstreetmap.org/wiki/Forward_%26_backward,_left_%26_right#Forward_and_backward) >`Forward` means the direction in which the way is drawn in OpenStreetMap, while `backward` means the opposite direction. ``` xml highway=tertiary lanes=5 -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 4 additions and 5 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,18 +1,17 @@ # Mapping roads accurately ### Roads: Roads are the main map features that we use for rendering navigational applications. Accurate roads representation leads not only to the well-looking map but also to a more precise navigation. For now, most common approach for road mapping is to trace roads following their centroid. This way of tracing looks good for 2-lanes roads like unclassified and residential roads or for tracing over low-res imagery.  ## What is a Way: A Way in OSM represents road as a complex feature. First of all, it is a line that represents an object (road), which covers a specific **area** on the ground. To show this, we can specify the width of the road in absolute (meters) or in relative (number of lanes) units of measurement. Numbers of lanes on the road will help us to make our driving decision. At least road has 1 lane for driving in both directions. This is a rough assumption. As a general rule, the road has two or more lanes for vehicular traffic. In order to show the shape and contours of the road we may to draw a polygon and mark it accordingly. (See [`area:highway`=`*`](http://wiki.openstreetmap.org/wiki/Key:area:highway), [description](http://wiki.openstreetmap.org/wiki/Proposed_features/Street_area) and [comprehensive mapping guide](http://wiki.openstreetmap.org/wiki/Proposed_features/area_highway/mapping_guidelines) in Wiki OSM) General road tracing is easy - trace roads by its middle axis. In our everyday life we comeacross with different types of road designs. How we have to trace it? ## Roads with more than two lanes -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 2 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -9,7 +9,6 @@ For now, most common approach for road mapping is to trace roads following their ## What a way is A Way in OSM represents road as a complex feature. First of all, it is a line that represents an object(road), which covers a specific **area** on the ground. To show this, we can specify the width of the road in absolute(meters) or in relative(number of lanes) units of measurement. Numbers of lanes on the road will help us to make our driving decision. At least road has 1 lane for driving in both directions. This is a rough assumption. As a general rule, the road has two or more lanes for vehicular traffic. In order to show the shape and contours of the road we may to draw a polygon and mark it accordingly. (See [`area:highway`=`*`](http://wiki.openstreetmap.org/wiki/Key:area:highway), [description](http://wiki.openstreetmap.org/wiki/Proposed_features/Street_area) and [comprehensive mapping guide](http://wiki.openstreetmap.org/wiki/Proposed_features/area_highway/mapping_guidelines) in Wiki OSM) General road tracing is easy - trace roads by its middle axis. In our everyday life we faced with different cases of shape of roads. How we have to trace it? @@ -18,11 +17,11 @@ In our everyday life we faced with different cases of shape of roads. How we ha ## Roads with more than two lanes There is two cases: - Roads which carry traffic in both directions and  - Dual carriageways roads.  -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 3 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,12 +1,13 @@ # Mapping roads accurately ### Roads Roads are the main map features that we use for rendering navigational applications. Accurate roads representation leads not only to the well-looking map but also to a more precise navigation. For now, most common approach for road mapping is to trace roads following their centroid. This way of tracing looks good for 2-lanes roads like unclassified and residential roads or for tracing over low-res imagery.  ## What a way is A Way in OSM represents road as a complex feature. First of all, it is a line that represents an object(road), which covers a specific **area** on the ground. To show this, we can specify the width of the road in absolute(meters) or in relative(number of lanes) units of measurement. Numbers of lanes on the road will help us to make our driving decision. At least road has 1 lane for driving in both directions. This is a rough assumption. As a general rule, the road has two or more lanes for vehicular traffic. In order to show the shape and contours of the road we may to draw a polygon and mark it accordingly. (See [`area:highway`=`*`](http://wiki.openstreetmap.org/wiki/Key:area:highway), [description](http://wiki.openstreetmap.org/wiki/Proposed_features/Street_area) and [comprehensive mapping guide](http://wiki.openstreetmap.org/wiki/Proposed_features/area_highway/mapping_guidelines) in Wiki OSM) General road tracing is easy - trace roads by its middle axis. -
jothirnadh revised this gist
Feb 23, 2016 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,7 +6,7 @@ For now, most common approach for road mapping is to trace roads following their  ## What a way is A Way in OSM represents road as a complex feature. First of all, it is a line that represents an object(road), which covers a specific **area** on the ground. To show this, we can specify the width of the road in absolute(meters) or in relative(number of lanes) units of measurement. Numbers of lanes on the road will help us to make our driving decision. At least road has 1 lane for driving in both directions. This is a rough assumption. As a general rule, the road has two or more lanes for vehicular traffic. In order to show the shape and contours of the road we may to draw a polygon and mark it accordingly. (See [`area:highway`=`*`](http://wiki.openstreetmap.org/wiki/Key:area:highway), [description](http://wiki.openstreetmap.org/wiki/Proposed_features/Street_area) and [comprehensive mapping guide](http://wiki.openstreetmap.org/wiki/Proposed_features/area_highway/mapping_guidelines) in Wiki OSM) General road tracing is easy - trace roads by its middle axis. -
jothirnadh created this gist
Feb 23, 2016 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,88 @@ ### Roads Roads are the main map features that we use in rendering navigation. Accurate roads representation leads not only to the well-looking map but also a more precise navigation. For now, most common approach for road mapping is to trace roads following their centroid. This way of tracing looks good for 2-lanes roads like unclassified and residential roads or for tracing over low-res imagery.  ## What a way is A Way in OSM represents road as a complex feature. First of all, it is a line that represents the object (road) which covers a specific **area** on the ground. To show this, we can specify the width of the road in absolute(meters) or in relative(number of lanes) units of measurement. Numbers of lanes on the road will help us to make our driving decision. At least road has 1 lane for driving in both directions. This is a rough assumption. As a general rule, the road has two or more lanes for vehicular traffic. In order to show the shape and contours of the road we may to draw a polygon and mark it accordingly. (See [`area:highway`=`*`](http://wiki.openstreetmap.org/wiki/Key:area:highway), [description](http://wiki.openstreetmap.org/wiki/Proposed_features/Street_area) and [comprehensive mapping guide](http://wiki.openstreetmap.org/wiki/Proposed_features/area_highway/mapping_guidelines) in Wiki OSM) General road tracing is easy - trace roads by its middle axis. In our everyday life we faced with different cases of shape of roads. How we have to trace it? ## Roads with more than two lanes There is two cases: - roads which carry traffic in both directions and  - dual carriageways roads.  To set number of lanes for roads which carry traffic in both directions use `:backward` and `:forward` suffixes - [http://wiki.openstreetmap.org/wiki/Forward_&_backward,_left_&_right#Forward_and_backward](http://wiki.openstreetmap.org/wiki/Forward_%26_backward,_left_%26_right#Forward_and_backward) >`Forward` means the direction in which the way is drawn in OpenStreetMap, while `backward` means the opposite direction. > ``` xml highway=tertiary lanes=5 lanes:forward=3 lanes:backward=2 ``` Roads with an even number of lanes tend to have an equal number of lanes in each direction by default and thus we may omit `:forward` and `:backward` tagging. In opposite case, when numbers of lanes for each directions don't match, we have to explicitly denote their numbers with `lanes:forward=*`+`lanes:backward=*` along with overall numbers of `lanes=*`. We aren't be able always to draw a road on its center line, especially if roads join/fork or the number of lanes changes. Imagine two roads which join: how would you draw the OSM-way around the point where the roads join?  _center line tracing_  _tracing main direction_ Our decision is to trace **main direction**! Before tracing (fix previous tracing), we need to inspect segments of the road before and after in some distance from selected place. We need to decide how to flow main direction of the road, general numbers of lanes and the places where there are extra lanes. Based on this we choose our strategy. ### Bidirectional roads At the image below general number of lanes is two - `lanes=2`. Orange line is the center line of bidirectional way which represents main movement direction. We don't change its flow when extra lanes are appeared. Just set `lanes=3`+`lanes:forward=2`+`lanes:backward=1` for the segment at right low corner with extra lane for turn to right. Optionally we may specify [placement](https://wiki.openstreetmap.org/wiki/Proposed_features/placement) of the lanes relatively to the our OSM-way.   Look to the below image. There is we have two tagging variants: 1. `lanes=2` - 1 lane for each direction, or 2. `lanes=3` - denote middle lane for left turn as :point_left: _this is discussed_ ``` highway=residential lanes=3 lanes:forward=1 lanes:backward=1 lanes:both_ways=1 turn:lanes:both_ways=left ```  Case when number of lanes is even but numbers of lanes for each direction not equal.  ### Dual carriageways roads Trace ways for dual carriageways road for each direction as close as possible to their outermost edge. There is some reasons for such way of tracing: - in lower zoom levels we will be able to distinguish dual carriageways road from bidirectional one just glimpsing on the map - GPS devices will associate their position with right road segments even in bad signal reception conditions - link roads which join to or fork from main highway will look good and will be connected in right places - we are able to adjust position of the lanes on the road using `placement=right_of:3` tagging if needed. Place nodes of the lines in each direction opposite to each other, which will get a good view of the road on the map 