Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setup tags and icons for Travel Routes #1158

Open
wants to merge 21 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion icons/tools/sortfiles.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3656,4 +3656,17 @@ icon activities_surfing
icon activities_running
icon activities_horse_riding
icon activities_diving
icon activities_canoe
icon activities_canoe

#Routes
icon_alias routes_kayak activities_kayak
icon_alias routes_horse activities_horse
icon_alias routes_skiing activities_skiing
icon_alias routes_bicycle activities_bicycle
icon_alias routes_trekking activities_trekking
icon_alias routes_pedestrian activities_pedestrian
icon_alias routes_snowmobile activities_snowmobile
icon_alias routes_mountain_bike activities_mountain_bike
icon_alias routes_inline_skates activities_inline_skates
icon_alias routes_running activities_running
icon_alias routes_fitness sport_fitness_station
27 changes: 19 additions & 8 deletions obf_creation/rendering_types.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@
<type
tag="" value="" - necessary
minzoom="" - indexed for map section (min zoom)

?additional="true/text" - attach tag/value to another map object
Note: additional="true" is supposed to use with tags that have a limited range of values (to avoid dictionary overflow)
Use additional="true" for: POI type, icon names, category names, text-colors (red,green,blue), etc.
Use additional="text" for: ids, latlon, hex-colors, elevation values, ref, name, description, etc.
?poi - register only for poi (deprecated)
?map - register only for map (deprecated)
?relation - propogate tag from relation objects to
Expand Down Expand Up @@ -1158,16 +1162,23 @@
<type tag="route" value="point" minzoom="3" nameTags="shield_text,ref,name"/>
<type tag="category" additional="true" minzoom="3"/>
<type tag="route_activity_type" additional="true" minzoom="3"/>
<type tag="diff_ele_up" additional="true" minzoom="3"/>
<type tag="diff_ele_down" additional="true" minzoom="3"/>

<type tag="min_ele__start" additional="true" minzoom="3"/>
<type tag="max_ele__start" additional="true" minzoom="3"/>
<type tag="avg_ele__start" additional="true" minzoom="3"/>
<type tag="end_ele__start" additional="true" minzoom="3"/>
<type tag="min_ele" additional="text" minzoom="3"/>
<type tag="avg_ele" additional="text" minzoom="3"/>
<type tag="max_ele" additional="text" minzoom="3"/>

<type tag="start_ele" additional="text" minzoom="3"/>
<type tag="ele_graph" additional="text" minzoom="3"/>

<type tag="diff_ele_up" additional="text" minzoom="3"/>
<type tag="diff_ele_down" additional="text" minzoom="3"/>

<!-- Unknown and actually unused tags: -->
<!-- <type tag="min_ele__start" additional="text" minzoom="3"/> -->
<!-- <type tag="max_ele__start" additional="text" minzoom="3"/> -->
<!-- <type tag="avg_ele__start" additional="text" minzoom="3"/> -->
<!-- <type tag="end_ele__start" additional="text" minzoom="3"/> -->

<type tag="shield_bg" additional="true" minzoom="3"/>
<type tag="shield_fg" additional="true" minzoom="3"/>
<type tag="shield_fg_2" additional="true" minzoom="3"/>
Expand All @@ -1176,10 +1187,10 @@

<type tag="gpx_bg" additional="true" minzoom="3"/>
<type tag="gpx_icon" additional="true" minzoom="3"/>
<type tag="gpx_icon_2" additional="true" minzoom="3"/>
<type tag="gpx_width" additional="true" minzoom="3"/>

<type tag="relation_gpx" additional="true" minzoom="3"/>
<type tag="flexible_line_width" additional="true" minzoom="3"/>
<type tag="translucent_line_colors" additional="true" minzoom="3"/>

<type tag="route_id" additional="text" minzoom="3"/>
<type tag="osm_id" additional="text" minzoom="3"/>
Expand Down
125 changes: 67 additions & 58 deletions poi/activities.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,16 +71,6 @@
{
"label": "Motorcycling",
"id": "motorcycling",
"tags": [
"motorcycle",
"motorbiking",
"motorrad",
"motorbike",
"motor bike",
"ling-moto",
"motorway",
"fvbike"
],
"activities": [
{
"label": "Adventure Motorcycling",
Expand Down Expand Up @@ -108,7 +98,17 @@
{
"label": "Road Motorcycling",
"id": "road_motorcycling",
"icon_name": "activities_motorcycle"
"icon_name": "activities_motorcycle",
"tags": [
"motorcycle",
"motorbiking",
"motorrad",
"motorbike",
"motor bike",
"ling-moto",
"motorway",
"fvbike"
]
},
{
"label": "Sport Motorcycling",
Expand All @@ -123,6 +123,9 @@
{
"label": "Track Racing",
"id": "track_racing",
"tags": [
"racing"
],
"icon_name": "ic_sample"
},
{
Expand Down Expand Up @@ -228,7 +231,7 @@
]
},
{
"label": "Winter sport",
"label": "Winter sports",
"id": "winter_sport",
"activities": [
{
Expand All @@ -254,11 +257,11 @@
"id": "skiing",
"icon_name": "activities_skiing",
"tags": [
"wintersports",
"winter",
"ski",
"skiing",
"skating",
"winter",
"wintersports",
"лыжи",
"лыжня",
"nordic",
Expand Down Expand Up @@ -295,33 +298,6 @@
{
"label": "Cycling",
"id": "cycling",
"tags": [
"bike",
"biking",
"bicycling",
"bicycle",
"cycling",
"cycle",
"cycleway",
"cykel",
"handcycle",
"route=bicycle",
"cyclotourism",
"fietsen",
"вело",
"велосипед",
"rower",
"trasa rowerem",
"vélo",
"velo",
"radtour",
"bici",
"fiets",
"fahrrad",
"ncn",
"icn",
"lcn"
],
"activities": [
{
"label": "E-Biking",
Expand All @@ -346,6 +322,7 @@
"mountainbiking",
"mtb",
"mountainbike",
"mountain_bike",
"mountain bike",
"mountain biking",
"mountbarker",
Expand All @@ -360,7 +337,34 @@
{
"label": "Road cycling",
"id": "road_cycling",
"icon_name": "activities_bicycle"
"icon_name": "activities_bicycle",
"tags": [
"bike",
"biking",
"bicycling",
"bicycle",
"cycling",
"cycle",
"cycleway",
"cykel",
"handcycle",
"route=bicycle",
"cyclotourism",
"fietsen",
"вело",
"велосипед",
"rower",
"trasa rowerem",
"vélo",
"velo",
"radtour",
"bici",
"fiets",
"fahrrad",
"ncn",
"icn",
"lcn"
]
},
{
"label": "Touring",
Expand Down Expand Up @@ -425,24 +429,16 @@
]
},
{
"label": "Water sport",
"label": "Water sports",
"id": "water_sport",
"tags": [
"boat",
"water",
"boating",
"river",
"lake",
"canal"
],
"activities": [
{
"label": "Canoe",
"id": "canoe",
"icon_name": "activities_canoe",
"tags": [
"canoe"
]
]
},
{
"label": "Diving",
Expand All @@ -460,7 +456,13 @@
"icon_name": "activities_kayak",
"tags": [
"kayak",
"kayaking"
"kayaking",
"boat",
"water",
"boating",
"river",
"lake",
"canal"
]
},
{
Expand Down Expand Up @@ -504,8 +506,9 @@
"id": "horse_riding",
"icon_name": "activities_horse_riding",
"tags": [
"horse"
]
"horse",
"riding"
]
},
{
"label": "Mushrooms picking",
Expand Down Expand Up @@ -533,7 +536,7 @@
"icon_name": "activities_train",
"tags": [
"train"
]
]
},
{
"label": "Golfing",
Expand All @@ -543,12 +546,18 @@
{
"label": "Fitness",
"id": "fitness",
"icon_name": "fitness_station"
"icon_name": "fitness_station",
"tags": [
"fitness"
]
},
{
"label": "Inline skates",
"id": "inline_skates",
"icon_name": "activities_inline_skates"
"icon_name": "activities_inline_skates",
"tags": [
"inline_skates"
]
}
]
}
Expand Down
44 changes: 29 additions & 15 deletions poi/poi_types.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5330,20 +5330,20 @@
<poi_type name="route_article" tag="route_type" value="article"/>

<!-- OBF-GPX relation route types (convertFromOsmGPXTag) -->
<!-- Name acts as icon not as activity (refers to the icon) -->
<poi_type tag="route_type" value="water" name="activities_kayak"/>
<poi_type tag="route_type" value="riding" name="activities_horse"/>
<poi_type tag="route_type" value="winter" name="activities_skiing"/>
<poi_type tag="route_type" value="cycling" name="activities_bicycle"/>
<poi_type tag="route_type" value="hiking" name="activities_trekking"/>
<poi_type tag="route_type" value="walking" name="activities_pedestrian"/>
<poi_type tag="route_type" value="snowmobile" name="activities_snowmobile"/>
<poi_type tag="route_type" value="mountainbike" name="activities_mountain_bike"/>
<poi_type tag="route_type" value="inline_skates" name="activities_inline_skates"/>
<poi_type tag="route_type" value="running" name="activities_running"/> <!-- TODO copy icon from running -->
<poi_type tag="route_type" value="fitness" name="activities_fitness"/> <!-- TODO copy icon from fitness_station -->

<poi_type name="route_track" tag="route_type" value="track">
<!-- most routes_ icons are aliased from activities_ icons -->
<poi_type tag="route_type" value="water" name="routes_kayak"/>
<poi_type tag="route_type" value="riding" name="routes_horse"/>
<poi_type tag="route_type" value="winter" name="routes_skiing"/>
<poi_type tag="route_type" value="cycling" name="routes_bicycle"/>
<poi_type tag="route_type" value="hiking" name="routes_trekking"/>
<poi_type tag="route_type" value="walking" name="routes_pedestrian"/>
<poi_type tag="route_type" value="snowmobile" name="routes_snowmobile"/>
<poi_type tag="route_type" value="mountainbike" name="routes_mountain_bike"/>
<poi_type tag="route_type" value="inline_skates" name="routes_inline_skates"/>
<poi_type tag="route_type" value="running" name="routes_running"/>
<poi_type tag="route_type" value="fitness" name="routes_fitness"/> <!-- aliased from fitness_station -->

<poi_type tag="route_type" name="route_track" value="track">
<!-- OBF-GPX track: basic tags -->
<poi_additional name="user" tag="user" type="text"/>
<poi_additional name="date" tag="date" type="text"/>
Expand Down Expand Up @@ -5377,7 +5377,7 @@
<poi_additional name="route_activity_type_motorbike" tag="route_activity_type" value="motorbike"/>
<poi_additional name="route_activity_type_car" tag="route_activity_type" value="car"/>
</poi_additional_category>
<!-- OBF-GPX track: extensions tags (prefixed with gpx_) -->
<!-- OBF-GPX track: appearance extension tags (prefixed with gpx_) -->
<poi_additional name="gpx_show_arrows" tag="gpx_show_arrows" type="text"/>
<poi_additional name="gpx_show_start_finish" tag="gpx_show_start_finish" type="text"/>
<poi_additional name="gpx_split_interval" tag="gpx_split_interval" type="text"/>
Expand All @@ -5391,11 +5391,23 @@
<poi_additional name="gpx_coloring_type" tag="gpx_coloring_type" type="text"/>
<poi_additional name="gpx_color" tag="gpx_color" type="text"/>
<poi_additional name="gpx_width" tag="gpx_width" type="text"/>
<!-- OBF-GPX track: special extension tags -->
<poi_additional name="gpx_osmand:activity" tag="gpx_osmand:activity" type="text"/> <!-- osmand:activity placed in the metadata -->
<poi_additional name="gpx_osm_ref_present" tag="gpx_osm_ref_present" type="text"/>
<poi_additional name="gpx_osm_name_present" tag="gpx_osm_name_present" type="text"/>
<poi_additional name="gpx_osm_description_present" tag="gpx_osm_description_present" type="text"/>
<!-- OBF-GPX track: osmand:points_groups list by tags -->
<poi_additional name="points_groups_names" tag="points_groups_names" type="text"/>
<poi_additional name="points_groups_icons" tag="points_groups_icons" type="text"/>
<poi_additional name="points_groups_colors" tag="points_groups_colors" type="text"/>
<poi_additional name="points_groups_backgrounds" tag="points_groups_backgrounds" type="text"/>
<!-- OBF-GPX track: shield_* tags for GPX reconstruction -->
<poi_additional name="shield_bg" tag="shield_bg" type="text"/>
<poi_additional name="shield_fg" tag="shield_fg" type="text"/>
<poi_additional name="shield_fg_2" tag="shield_fg_2" type="text"/>
<poi_additional name="shield_text" tag="shield_text" type="text"/>
<poi_additional name="shield_textcolor" tag="shield_textcolor" type="text"/>
<poi_additional name="shield_waycolor" tag="shield_waycolor" type="text"/> <!-- special to restore as color -->
</poi_type>
<poi_type name="route_track_point" tag="route_type" value="track_point">
<!-- OBF-GPX point: icon extensions -->
Expand All @@ -5406,6 +5418,8 @@
<poi_additional name="color" tag="colour" type="text"/> <!-- global for "routes" category -->
<!-- OBF-GPX track (relation id) / points (node id) -->
<poi_additional name="osm_id" tag="osm_id" type="text"/>
<poi_additional name="flexible_line_width" tag="flexible_line_width" type="text"/>
<poi_additional name="translucent_line_colors" tag="translucent_line_colors" type="text"/>
</poi_category>
<poi_category name="user_defined_other" default_tag="amenity" no_edit="true" excluded_poi_additional_category="fee,payment_type,wheelchair_accessibility,internet_access_type,opening_hours">
<!-- Add additional combination for UK postcode POI files-->
Expand Down
Loading