Open Cycle Map

2,011 views
Skip to first unread message

freddyben

unread,
Jun 9, 2013, 5:57:15 AM6/9/13
to osm...@googlegroups.com
Hello everyone,

I have a project : make a bicycle trip trough Belgium, the netherlands and up to Danemark. OsmAnd seem to me to be the only App on android that allows you to download full map of country so you have everything you need stored in your telephone before you hit the road. Great ! Unfortunately, OsmAnd don't support Open CYCLE Map, which gives the route for bicycle users. Am I wrong or is there a solution to implement Open Cycle Map with the same kind of system (download full maps) ? Thanks a lot for your help !

Hardy

unread,
Jun 9, 2013, 6:45:49 AM6/9/13
to osm...@googlegroups.com
No, you cannot download the opencyclemaps in osmand for offline use.
 
- You could creat a tile-map copy of opencyclemaps (via 3rd party tools) for a certain reagion and store it as sqlite on your sdcard to use in OsmAnd (access/select via "Online maps" plugin, although it is a cached map then),
- or you can chose the "Touring view" for OsmAnd offline maps, and check out the cycle-related options which then appear under "Define View"/"Configure screen".  We have started adding some cycle-network related functionality, but still not as complete/bug-free as the "Alpine Hiking" and "Hiking symbol" functionality we alreay added to Toruing view earlier.
 
Go play with it!

joepd...@gmail.com

unread,
Jun 9, 2013, 8:05:49 AM6/9/13
to osm...@googlegroups.com


- or you can chose the "Touring view" for OsmAnd offline maps, and check out the cycle-related options which then appear under "Define View"/"Configure screen".  We have started adding some cycle-network related functionality, but still not as complete/bug-free as the "Alpine Hiking" and "Hiking symbol" functionality we alreay added to Toruing view earlier.
 

I've been playing with this and it works fine for me. Now the next question is: how to make Osmand to route along the bicycle routes. I've been messing around with the routing.xml and added a line like

<road tag="ncn_network" value="ncn" speed="18" priority="1.5" dynamicPriority="1.5"/>

but this doesn't seem to work. If I change existing lines I see Osmand respond to that, so the file I'm editing is being used by Osmand. Am I doing something wrong, or doesn't this just work (yet)?


Harry van der Wolf

unread,
Jun 9, 2013, 9:45:01 AM6/9/13
to osm...@googlegroups.com
Hi,

2013/6/9 Hardy <hm.gg...@gmail.com>

- or you can chose the "Touring view" for OsmAnd offline maps, and check out the cycle-related options which then appear under "Define View"/"Configure screen".  We have started adding some cycle-network related functionality, but still not as complete/bug-free as the "Alpine Hiking" and "Hiking symbol" functionality we alreay added to Toruing view earlier.
 

 I made a separate cycle_map render. I (proudly) stole the cycleroute settings from the touring view render and modified some settings a little.
 I modified:
- the settings itself so that it is no longer a rendering poperty but an integral part of the map. So when you select the (bi)cycle view and select the cycle_map render,  cycle routes are automatically displayed and not via a configure setting in the configure screen options.
- the map colors so that it mimics the opencyclemap colors as close as possible
- the cycle route fonts and increased their size a little.

Note that this is a (really) quick and dirty "implementation".

Please see attached render. Simply store it into your osmand/rendering folder on your SDcard.

Harry

cycle_map.render.xml

Nick Allen

unread,
Jun 9, 2013, 12:12:03 PM6/9/13
to osm...@googlegroups.com
Harry,

Brilliant, that's certainly exactly what I was looking for, thanks,

Slight amendment though. At the moment your file does not render lcn & rcn routes - looking through I've spotted that near the end your colour codes for these two route types have a double # instead of one. I've corrected it in the attached file.

Thanks again for your work on this.

Nick
cycle_map.render.xml

Harry van der Wolf

unread,
Jun 9, 2013, 12:55:11 PM6/9/13
to osm...@googlegroups.com


2013/6/9 Nick Allen <nick.a...@gmail.com>


Slight amendment though. At the moment your file does not render lcn & rcn routes - looking through I've spotted that near the end your colour codes for these two route types have a double # instead of one. I've corrected it in the attached file.

Thanks for correcting it. I already mentioned that it was quick&dirty.
I first copied the colors of the touring view, then decided to use the very soft purple of the opencyclemap routes, but they were so soft that they were hardly visible when being outside (and that's where you use them), so I copied the original touring view colours back but obviously not correct.

Harry


Harry van der Wolf

unread,
Jun 9, 2013, 1:18:27 PM6/9/13
to osm...@googlegroups.com
I made another change. After switching to the soft-purple colors of OpenCycleMap I also set the property textOnPath="true" (It puts the text really on and in the direction of the path, e.g. the road/cycleway.)
With the touring view colors set back this textOnPath="true" option makes the text hardly readable, so I removed that tag.

See attached.

Harry
cycle_map.render.xml

Harry van der Wolf

unread,
Jun 9, 2013, 4:58:15 PM6/9/13
to osm...@googlegroups.com
And a few more more minor changes and one correction.

Harry
cycle_map.render.xml

Nick A

unread,
Jun 9, 2013, 6:29:20 PM6/9/13
to osm...@googlegroups.com
Harry,

I've had a play with your latest version, and for me in the Uk it is very good. The only improvement would be if the cycle routes showed at even higher zooms - a days ride is  often 50 miles, so fitting that sort of distance on the screen would be of great assistance.

Thanks again

Nick


Harry van der Wolf

unread,
Jun 10, 2013, 3:13:39 AM6/10/13
to osm...@googlegroups.com


2013/6/10 Nick A <nick.a...@gmail.com>

Harry,

I've had a play with your latest version, and for me in the Uk it is very good. The only improvement would be if the cycle routes showed at even higher zooms - a days ride is  often 50 miles, so fitting that sort of distance on the screen would be of great assistance.

I assume you mean at lower zooms, being larger overviews.
I will take a look this afternoon. And if I interpret you incorrect then please let me know.

Harry

mircozorzo

unread,
Jun 10, 2013, 3:34:27 AM6/10/13
to osm...@googlegroups.com
Hi, good work!

Will be useful add this tag?

service:bicycle:rental
service:bicycle:repair
service:bicycle:retail
service:bicycle:second_hand

amenity:drinking_water
amenity:place_of_worship


Bye, Mirco

Harry van der Wolf

unread,
Jun 10, 2013, 4:08:15 AM6/10/13
to osm...@googlegroups.com
Hi,

2013/6/10 mircozorzo <mirco...@gmail.com>

Will be useful add this tag?

service:bicycle:rental
service:bicycle:repair
service:bicycle:retail
service:bicycle:second_hand

I don't know above tags and I can't find them either at <http://wiki.openstreetmap.org/wiki/Map_Features>. Do you have some description of them.
repair is only available for car_repair
second_hand only as shop and pawnbroker.

I do know amenity:bicycle_rental and that one is standard in the maps.

 
amenity:drinking_water
amenity:place_of_worship


These two are also standard in the maps.

Harry

Max

unread,
Jun 10, 2013, 6:19:31 AM6/10/13
to osm...@googlegroups.com

On Monday, June 10, 2013 10:08:15 AM UTC+2, Harry van der Wolf wrote:
Will be useful add this tag?

service:bicycle:rental
service:bicycle:repair
service:bicycle:retail
service:bicycle:second_hand

I don't know above tags and I can't find them either at <http://wiki.openstreetmap.org/wiki/Map_Features>. Do you have some description of them.

mircozorzo

unread,
Jun 10, 2013, 6:32:16 AM6/10/13
to osm...@googlegroups.com
Hi, thank you for the reply.

Il giorno lunedì 10 giugno 2013 10:08:15 UTC+2, Harry van der Wolf ha scritto:
Hi,


amenity:drinking_water
amenity:place_of_worship


These two are also standard in the maps.

Ok, but are displayed only from zoom 16 with a brown icon not so visible.   
I'll to modify the file to decrease the minimum zoom.
 

Bye, Mirco

Harry van der Wolf

unread,
Jun 10, 2013, 11:14:59 AM6/10/13
to osm...@googlegroups.com
Hi all,

2013/6/10 mircozorzo <mirco...@gmail.com>
I can't change the icon. The icon is programmed into OsmAnd. I can change the minimum zoom level but at zoom level 14 and below the POI icon is simply too small to be drawn on the map.
A much better option is to create a POI filter for the POIs you are interested in. Save it as Cycling_POIs (or whatever you want to call it).
Switch on the POIs and select your personal filter Cycling_POIs (or whatever you called it). Now your custom POIs are visible in an orange disk at least down to zoomlevel 10.
Please take a look at <http://code.google.com/p/osmand/wiki/HowToFilterPOIs> if necessary. I just updated it :)
By the way: I don't understand the "amenity:place_of_worship" though. What does that have to do with cycling? Is it just some personal favorite you want to have on a lower level? If so: That's an even better reason to create a completely personalized POI filter.




On Monday, June 10, 2013 10:08:15 AM UTC+2, Harry van der Wolf wrote:
Will be useful add this tag?

service:bicycle:rental
service:bicycle:repair
service:bicycle:retail
service:bicycle:second_hand

I don't know above tags and I can't find them either at <http://wiki.openstreetmap.org/wiki/Map_Features>. Do you have some description of them.

OK, now I understand what they are but I have no idea how to incorporate that.
Maybe Hardy, who is the real rendering expert, can help out here.

 

 

2013/6/10 Nick A <nick.a...@gmail.com>


I've had a play with your latest version, and for me in the Uk it is very good. The only improvement would be if the cycle routes showed at even higher zooms - a days ride is  often 50 miles, so fitting that sort of distance on the screen would be of great assistance.



That's a tough one. I did lower the zoom levels when it starts to visualize, but at levels below 12 you get to the limits of the original zoom settings from the default render. These zoom settings can be overriden as well, but the issue is that smaller roads are by definition not visible on lower zoom levels otherwise the rendering of the map would be too crowded and far too slow.
The  lcn, rcn and ncn networks make use of cycleways, minor roads, larger roads with separate parallel cyclepaths, tracks, etc, etc. Showing all these roads at these low zoomlevels might not even work on slower phones with lesser memory (but that's a personal guess).
zoomlevel 12 on my phone is about 15 by 25 km (Yes, I calculate in metric distances). At zoomlevel 11 you get gapps in your routes unless I lower the zoomlevel of a lot of roads, which is quite some work and might still not give the desired result.


Anyway: Please find attached the latest version.

Harry
cycle_map.render.xml

Harry van der Wolf

unread,
Jun 11, 2013, 1:14:32 PM6/11/13
to osm...@googlegroups.com
Some minor changes like smaller strokewidths on lower zoomlevels to make the cycle routes less coarse.

Anyone any idea how to implement the service tags?


service:bicycle:rental
service:bicycle:repair
service:bicycle:retail
service:bicycle:second_hand

If someone leads me on the right track I'm happy to implement it.

Harry
cycle_map.render.xml

Max

unread,
Jun 12, 2013, 7:14:34 AM6/12/13
to osm...@googlegroups.com

Anyone any idea how to implement the service tags?

service:bicycle:rental
service:bicycle:repair
service:bicycle:retail
service:bicycle:second_hand

If someone leads me on the right track I'm happy to implement it.

First, you need to get these tags into the data (obf file), have a look at:
https://github.com/osmandapp/Osmand/blob/r1.4/OsmAnd-java/src/net/osmand/osm/rendering_types.xml#L355

If these service tags are always part of shop=bicycle, I suggest to use additional="true" (if this is possible for POIs).

After that, you have to add the POIs to the rendering xml, maybe this is the right place:
https://github.com/osmandapp/Osmand/blob/r1.4/OsmAnd-java/src/net/osmand/render/Touring-view_%28more-contrast-and-details%29.render.xml

Maybe you will find examples in default.render.xml:
https://github.com/osmandapp/Osmand/blob/r1.4/OsmAnd-java/src/net/osmand/render/default.render.xml

You can use the built-in icons, if there are no suitable icons, you may provide some.

Regards,
Max

Harry van der Wolf

unread,
Jun 12, 2013, 9:15:39 AM6/12/13
to osm...@googlegroups.com
Hi Max,

Thanks for your reply and research.
In the mean time I have been working on it as well but without success.



Anyone any idea how to implement the service tags?

service:bicycle:rental
service:bicycle:repair
service:bicycle:retail
service:bicycle:second_hand

If someone leads me on the right track I'm happy to implement it.

First, you need to get these tags into the data (obf file), have a look at:
https://github.com/osmandapp/Osmand/blob/r1.4/OsmAnd-java/src/net/osmand/osm/rendering_types.xml#L355


I know the service key is part of  the shop tag and they are currently not part of the rendering types.
 
If these service tags are always part of shop=bicycle, I suggest to use additional="true" (if this is possible for POIs).

The true/false/test option is for renderingproperties. And for POIs as such these renderingproperties can be used and work as well. However, I don't know how to define the renderingproperty for the services as I simply don't know how to specify the services (see below)
If you mean something else please explain.
 

After that, you have to add the POIs to the rendering xml, maybe this is the right place:
https://github.com/osmandapp/Osmand/blob/r1.4/OsmAnd-java/src/net/osmand/render/Touring-view_%28more-contrast-and-details%29.render.xml

I used that one as a basis for my cycle_map.render.xml and used Gimp to extract the colors from the opencyclemap.org render colours..


What I tried so far:
I used the Netherlands, Belgium, GB_England and some France* obf maps, but I can't find the service tags in the obfs. They are simply not there.
Then I downloaded the the osm.pdf's from geofabrik.de, converted them to straight osm (huge!) and did a "grep -ia service". Then I do find tags like
        <tag k="service:bicycle:repair" v="yes"/>
        <tag k="service:bicycle:retail" v="yes"/>
So they are in the original OSM data files but OsmAndMapCreator does not take them into account.

 
You can use the built-in icons, if there are no suitable icons, you may provide some.

That's the least problem :). I already wanted to use the standard "icon="shop_bicycle" tag="shop" value="bicycle"" values for the services.

=
My current end conclusion is that we can't support these service tags as OsmAndMapCreator does not support them (yet).
=

Harry

silma...@gmail.com

unread,
Jun 13, 2013, 5:28:36 PM6/13/13
to osm...@googlegroups.com
Hi,

I played around with the XML files you posted to create my own Open-Cycle-Map-style. Thank you very much for sharing your ideas!

Currently I am stuck at one point that seems quite simple: The map renders just fine, but the name tags of the cycle ways are only shown in zoom level 15 and higher.
I cannot find a way to make them show up in lower zoom levels. I think it would be good to see those names starting from zoom level 11 or 12.

Here is the part dealing with those name tags from my current XML file:

    <text>
        <group>
            <filter appMode="bicycle" tag="lcn_network" value="lcn" nameTag="lcn_ref" textColor="#0000B2" textOrder="20"/>
            <filter appMode="bicycle" tag="rcn_network" value="rcn" nameTag="rcn_ref" textColor="#1C8FB2" textOrder="20"/>
            <filter appMode="bicycle" tag="ncn_network" value="ncn" nameTag="ncn_ref" textColor="#B20000" textOrder="20"/>
           
            <groupFilter appMode="bicycle" textHaloRadius="1" textBold="true" textOnPath="true">
                <filter minzoom="10" maxzoom="11" textSize="16" textDy= "-5"/>
                <filter minzoom="12" maxzoom="13" textSize="16" textDy= "-8"/>
                <filter minzoom="14" maxzoom="14" textSize="14" textDy="-10"/>
                <filter minzoom="15" maxzoom="15" textSize="15" textDy="-12"/>
                <filter minzoom="16" maxzoom="16" textSize="17" textDy="-15"/>
                <filter minzoom="17" maxzoom="17" textSize="20" textDy="-19"/>
                <filter minzoom="18"              textSize="23" textDy="-25"/>
            </groupFilter>
        </group>
    </text>



It seem that everything is there, but I must be missing something.
Is there some kind of attribute that says "do really draw this item now"? It looks to me as if there were some defaults that don't draw the name tags in lower zoom levels.

Max

unread,
Jun 13, 2013, 6:24:27 PM6/13/13
to osm...@googlegroups.com
Hello!


Currently I am stuck at one point that seems quite simple: The map renders just fine, but the name tags of the cycle ways are only shown in zoom level 15 and higher.
I cannot find a way to make them show up in lower zoom levels.

Strange, I had exactly the same problem, but didn't find a solution:
https://groups.google.com/d/msg/osmand/UltaD3u8e7U/zwrbn4ZafY4J

Regards,
Max

Evgeniy Kachalin

unread,
Aug 28, 2013, 3:08:52 AM8/28/13
to osm...@googlegroups.com
What is the latest variant? I'd like to try it please.

пятница, 14 июня 2013 г., 2:24:27 UTC+4 пользователь Max написал:

Harry van der Wolf

unread,
Aug 28, 2013, 5:00:59 AM8/28/13
to osmand
This is a general error in OsmAnd and has nothing to do with the cycle
map. It also occurs on "normal" roads and even for motorways/trunks.

See issue https://code.google.com/p/osmand/issues/detail?id=2144



2013/6/14 Max <openstre...@nurfuerspam.de>:
> --
> You received this message because you are subscribed to the Google Groups
> "Osmand" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to osmand+un...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

Hardy

unread,
Aug 28, 2013, 5:55:42 AM8/28/13
to osm...@googlegroups.com
Hello Harry, I just noticed we have had the cycle-map renderer in github for quite some time but had never published it as a built-in renderer. I have just done so, is this ok, is it already good enough for that? If not, please let me know so I "hide" it again ...  :-)
 
Thanks,
Hardy
 

Harry van der Wolf

unread,
Aug 28, 2013, 6:04:18 AM8/28/13
to osmand
I think it is good enough, but I made some changes after the commit to
the repository. I will check whether these changes are improvements,
"my personal preference", etc. I let you know asap.

Harry

2013/8/28 Hardy <hm.gg...@gmail.com>:

Hardy

unread,
Aug 28, 2013, 6:06:51 AM8/28/13
to osm...@googlegroups.com
Ok, thanks! I slightly renamed the file to be in line with our other internal renderers, direct link is https://github.com/osmandapp/OsmAnd-resources/blob/master/rendering_styles/Cycle-map.render.xml
Thanks,
Hardy

 

Harry van der Wolf

unread,
Aug 29, 2013, 1:34:45 PM8/29/13
to osmand
I created a pull request with the update.

Comments from the file:
- Add rendering property NumberInPath. Cycle network number
perpendicular on route or "textonpath". some like it one way, some the
other.
- minor changes in strokewidth and text size

Harry

2013/8/28 Hardy <hm.gg...@gmail.com>:

Hardy

unread,
Aug 29, 2013, 2:33:40 PM8/29/13
to osm...@googlegroups.com
Harry, thank you! Merged.
Best regards, Hardy

Pee Wee

unread,
Aug 31, 2013, 5:35:00 AM8/31/13
to osm...@googlegroups.com
Well done guys.

One question/request.

Is it possible to render cyclenode numbers (osm tag  rcn_ref)?

I've also noticed the checkbox "show network number inside cycleway" but I can't figure out what that does. Any hints.

I'm using latest nightly.apk (

Cheers PeeWee32

Harry van der Wolf

unread,
Aug 31, 2013, 5:53:45 AM8/31/13
to osmand
I will have a look at the cyclenode numbers. Somehow they disappeared.
Maybe it is a conflicting tag/ref combination. That sometimes happens.
Same for motorway-junction/exit name and reference number.

W.r.t. the "show network number inside cycleway". See attached (low
quality) images. some like it one way, some like it the other way.

I myself am not completely satisfied with the text color but it's the
official cycleway color. I like a more contrast-rich color. Maybe I
will change that.

Harry

2013/8/31 Pee Wee <piew...@gmail.com>:
normal.jpg
show_network_number_inside_cycleway.jpg

Pee Wee

unread,
Aug 31, 2013, 6:29:14 AM8/31/13
to osm...@googlegroups.com

Thanks Harry for the quick response. The images show the difference but it is so minor that I had not initially noticed when I checked/unchecked.  I would not mind if you just pick one and leave the checkbox option away. Osmand already has so many options that it could scare beginners away.

 I hope you can fix the cyclenode numbers. Thanks again.

Cheers PeeWee

Harry van der Wolf

unread,
Aug 31, 2013, 11:09:49 AM8/31/13
to osmand
>
> I hope you can fix the cyclenode numbers. Thanks again.
>

Currently not. they are only displayed at zoomlevel 14 and only a few
of them. At this moment I have no idea why that doesn't function on
other levels.

Harry

Hardy

unread,
Sep 2, 2013, 5:34:50 PM9/2/13
to osm...@googlegroups.com
Harry, I guess this may be related to issue 2144. I find no bug in the render.xml.
Best, Hardy

 

runb...@gmail.com

unread,
Jul 24, 2018, 5:24:39 PM7/24/18
to Osmand

Hi,
is there still hapening something? The cycle-map.render is quite good, but looks still different from the opencyclemap layer (https://www.openstreetmap.org/#map=12/54.1578/12.0633&layers=C).

However I found an older version of the cyclemap style here: https://github.com/openstreetmap/potlatch2/blob/master/resources/stylesheets/opencyclemap.css
The style definitions doesn't look that tricky. Is it possible to clone this style somehow?

Cheers Lukas

Gerhard Schröder Berlin

unread,
Jul 25, 2018, 9:41:14 AM7/25/18
to osm...@googlegroups.com

This style is also good: https://cycling.waymarkedtrails.org/#search?query=&map=14!50.8703!9.7262

gpsies.com also use these stile...how can I use these stile in osmand?


Thanks!

--
You received this message because you are subscribed to the Google Groups "Osmand" group.
To unsubscribe from this group and stop receiving emails from it, send an email to osmand+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages