LoMaps + MapsForge V4

Started by Menion, February 20, 2023, 22:04:30

0 Members and 1 Guest are viewing this topic.

john_percy

@voldapet
Near 3 words location https://w3w.co/rocker.iceberg.heavy two OSMC routes have their markers superimposed at one location (western point) and not superimposed at another (eastern point).
Judging by the OSMC colour lines on the map, LoMaps has given both no osmc_order on the western segment but separated them on the eastern one.

Sent from my moto g(6) plus using Tapatalk

Voluntary and Velocity themes - https://voluntary.nichesite.org
  •  

voldapet

@john_percy
QuoteI'm looking at osmc waymarking but I can't see any markings on some routes I am looking at, where OAM maps show osmc markings. For example, one location is N 51.61224°, E 007.57491° (from Locus).
I'm sorry but on given coordinates isn't any osm relation with the specified "osmc:symbol". Could I kindly ask you for some screenshot or a better explanation? Maybe I miss something

Superimposed symbols
Thank you for the report. The definition of "osmc_order" depends on the main color of the route. If multiple routes have the same color, then osmc_order can be the same for those routes. The "osmc_order" was initially used to set a different offset (dy) for parallel routes. But later I decided to use this attribute also for drawing the symbol along the route and it can cause the following problems. More interesting is the easter part where symbols do not overlap. But this is basically an error because 2 blue lines are rendered and it should not happen.
I'll check it and I'll consider consider a custom order tag for symbols...

@Invalid theme - I'll ask @Menion to check it because the theme contains the reported icon and it should be valid

@karlchick - No problem I'll add it.
  •  
    The following users thanked this post: karlchick

john_percy

@voldapet
Three words: gardens.scout.embers
The screenshots are LoMaps with internal theme, OAM with Voluntary beta theme, LoMaps with Voluntary beta.

Emscherparkweg XE
osmc: symbol red:black:black_rectangle:XE:white



Sent from my moto g(6) plus using Tapatalk

Voluntary and Velocity themes - https://voluntary.nichesite.org
  •  

voldapet

@john_percy
ahh thank you. I missed it.

The "osmc:symbol" for this way is extracted into these values:
  <tag k="osmc" v="yes"/>
  <tag k="osmc_color" v="red"/>
  <tag k="osmc_background" v="black"/>
  <tag k="osmc_foreground" v=""/>
  <tag k="osmc_text" v="XE"/>
  <tag k="osmc_text_length" v="2"/>
  <tag k="osmc_text_color" v="white"/>

Please note especially the "osmc_foreground" that's empty but it should be "black_rectangle". This is my ugly workaround when the color of the foreground symbol is the same as the color of the background. The pseudo-code should look like:
if osmc_foreground.hasTheSameColor(osmc_background):
  set_value_empty_for(osmc_foreground)

The reason for this hack is a problematic rendering of text symbols that are not rendered by LoMaps theme. In the theme is a rule that requires defined osmc_foreground - I mean symbols are rendered only when osmc_foreground is defined (to avoid empty black rectangles).

Anyway the text and text color values are available in the data and you can use them
  •  

john_percy

@voldapet
Thanks for the explanation.
However I can find no indication that osmc_text exists in the map as a variable. I know previous versions of Mapsforge only supported a few variables, such as ref, name, addr:housenumber. Is that changed?

Sent from my moto g(6) plus using Tapatalk

Voluntary and Velocity themes - https://voluntary.nichesite.org
  •  

voldapet

#65
@john_percy
Mapsforge now supports any "key" that can be used as a text value. So you can, for example, display the value of the key "highway"
<pathText k="highway" font-style="normal" font-size=....
Anyway, you are right - "osmc_text" and "osmc_text_length" are really missing in the latest LoMaps. The latest version of LoMaps was released in version 4 which doesn't contain variable "tag-values" (%s, %f)

Anyway, I generated a new version of LoMaps (see attached map of Monaco) as version 5. The mentioned "osmc_text" and "osmc_text_length" tags should be available in the data. But I think I found some bug in the Mapsforge generator, where the tag-value variable is not included in the data if there is another tag with the same value. The value of "osmc_text" is often the same as the value of "ref", and it seems that in such a situation the "osmc_text" is not added to the data. I need to test this with @Menion in more detail and debug the data in the map tiles.


For this reason, I edited one tourist way with "osmc_text" value and set value "03 testtest" (avaialable in attached monaco map). You can test it with your theme...

PathText to display the text "03 testtest"
<pathText k="osmc_text" dy="2" font-style="bold" font-size="16" fill="#e67400" stroke="#ffffff" stroke-width="2.5" priority="1000"/>
  •  
    The following users thanked this post: john_percy

karlchick

@voldapet

Point 13
Would it be possible to include service tag values for highways? Seems only service values for railways are included.

This would allow lesser important service roads to be drawn thinner and less distracting, attached is a comparison of lomap vs oam. On lomap the car parks are very prominent as the parking aisles are drawn as service roads.
User id: 62b600722
Author of the OS Map Theme:
DiscussDownload
  •  

voldapet

@karlchick
Point 13
I see. I added:

<osm-tag key="service" value="alley" zoom-appear="13" />
<osm-tag key="service" value="driveway" zoom-appear="13" />
<osm-tag key="service" value="emergency_access " zoom-appear="13" />
<osm-tag key="service" value="parking_aisle" zoom-appear="13" />
<osm-tag key="service" value="slipway" zoom-appear="13" />

john_percy

#68
@voldapet
Does highway=construction flow through to lm_highway=construction? I suspect not.
I don't think it affects the internal theme adversely but it does affect my Voluntary theme in terms of route marking offset and width etc.

Voluntary and Velocity themes - https://voluntary.nichesite.org
  •  

john_percy

@voldapet
Also Höhlenweg X4, N 51.37576°, E 007.63249° is a route of type=disused_route but shows on the map.


Sent from my moto g(6) plus using Tapatalk

Voluntary and Velocity themes - https://voluntary.nichesite.org
  •  

john_percy

#70
Also Blue Pedalway ought not really to appear on the map as its state is only "proposed". https://www.openstreetmap.org/?mlat=52.6043&mlon=0.9077#map=10/52.6043/0.9077

geo:52.6043,0.9077?z=10

state=proposed
lcn=proposed
Voluntary and Velocity themes - https://voluntary.nichesite.org
  •  

voldapet

@john_percy Thank you for your report/feedback
You're right we ignore mentioned proposed or disused tags. I'll improve it.
Anyway, do you know more about tag type=disused_route ? I can't find any official documentation for this tags. I'm also wonder if there are more disused combinations...

- lm_highway=construction is really missing and will be improved in the next version of LoMaps

john_percy

#72
@voldapet
I think this particular example of a disused route ought to fail on a check on the relation for type=route, which I am sure you need to do in any case when preparing the map. I don't think this usage is documented but there are a whole host of ways of tagging lifecycle stages:
https://wiki.openstreetmap.org/wiki/Comparison_of_life_cycle_concepts
Edit: I could imagine type=disused:route as a possible interpretation of the wiki but that may not be allowed syntax.

Voluntary and Velocity themes - https://voluntary.nichesite.org
  •  

john_percy

#73
@voldapet
I'm attempting to follow the instructions for a custom poi theme. I've just downloaded the latest beta.
I have a theme file "Voluntary V5 LE.xml"
I'm attempting a poi theme file "Voluntary V5 LE_vol-multi.poi.xml" for a style "Multi" with a layer id "vol-multi".
a) the poi theme shows up in the list of selectable themes. I'm sure that's not desirable.
b) it doesn't seem to have any effect




Sent from my moto g(6) plus using Tapatalk
Voluntary and Velocity themes - https://voluntary.nichesite.org
  •  

Tapio

Quote from: john_percy on June 01, 2023, 00:19:34I'm attempting to follow the instructions for a custom poi theme.
What's that about, URL please?
Tapiola MFV4+ theme for OAM Maps:
Discuss - Releases - DL latest - Install latest
  •