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
Nautical rendering style: 1. Add display of light characteristics in the nautical map 2. Add display of sectorial lights #16894
Comments
Let me cross-link to #16341. It's a frequent request from the boating community, so really quite a bit more than "nice to have" for the practical usability, is my understanding. |
Yes, I can underline that the seamark light characteristics are essential for nautical chart usability as aids to navigation at night. The flashing time, duration and multiple repetitions are unique and characteristic to clearly identify a seamark and its position in an area with certainty. Currently only the colour is indicated in the OSMAND nautical rendering style. This is insufficient, if you have e.g. three white cardinal lights around a point of danger. Only the flashing characteristic will tell, whether you need to go south or north of a specific light (seamark). So it is essential, and without light characteristics, it's of very limited use for navigation really. Thus request part 1. is most important, which is just representing light characteristics by INT-1 standardised text display and likely much simpler to implement in the natical rendering. |
A starting point would be a strategy for the rendering_types.xml (see OsmAnd-resources obf_creation folder) and its seamark section in lines 6742 to 7107: preprocess rules |
osmandapp/OsmAnd-resources#965 |
I came here from #16342 (comment) Sector lights can be displayed by adding dedicated lines to the OBFs for the sector limits and arcs. I wrote a script that does this and adjusted the render style accordingly. Grab the OBF and style from https://github.com/quantenschaum/mapping/releases/ Using these files it can look like this (with depth contours) |
I would like to propose a change of the light characteristics string. Currently the string does not follow the usual convention, it is similar but not the same. The light characteristics string should look like as described in the INT1 section P, page 82. Main things to change
|
|
Mostly for simple text processing we use rendering_types.xml and only complex we hard code in java (less flexible and not transparent) |
Line breaks in a label are not possible? |
It seems to be like this: The text in |
Yes you are right |
I can confirm that "nameTag (nameTag2)" is what we could achieve June 2023, when I tried to imitate and allow display of light characteristics in the nameTag2 as far as possible, also by selection of different lightDetail to modify in the app the nameTag2 and allow even some basic light sector text info. Nevertheless, this is still far from replicating IHO Int-1, which should be the aim for next steps regarding both:
My hint for a development in Java required for this certainly is: The OpenSeaMap and its rendering in OpenNavigationalCharts (ONC) is already able to provide text labels very close to Int-1 and draw arcs according to this standard. A lot of this rendering code is on Github and Sourceforge. I have had direct contact to the person achieving the Int-1 like display from OSM seamark tags in the ONC rendering. The code behind is very likely also based on java. I am not the right person to continue work in java. But I could forward an e-mail address, if you are interested to get in touch directly for next steps in OsmAnd. Please let me know. Regards Jo |
@josail What is "OpenNavigationalCharts"? Is there a link to the project/code? It can be achieved as described in #16894 (comment). Either these extra lines and labels are generated during the creation of the OBFs or this data is generated separately and can be downloaded as extra OBFs by uses who need these features like it is the case with the depth data. |
Sorry, ONC means OpenNauticalCharts: |
Regarding the two options: Several month delay of seamark changes would be a big disadvantage for OsmAnd. The OpenSeaMap and ONC do the rendering of seamark changes within few hours, sometimes even minutes. If a new download could lead to such up-to-date seamark light information then OsmAnd becomes a very valuable Offline source of most recent seamark and light information in the hands of sailors, more up-to-date than paper charts in many and perhaps some very relevant cases. E.g. when lit seamarks are discontinued/removed or newly installed, marking new dangers for navigation, protected areas, etc. |
Yes, if this would happen in the app, this would be the best solution IMHO. But this is currently not possible, whereas generated extra lines in the OBFs are doable, as I have demonstrated. Concerning updates, OsmAnd does not make OSM data accessible directly (You could use OSM raster tiles, though). It relies on the OBFs that are generated from the OSM data and which are updated monthly. So, generated light sectors in the OBFs could be updated monthly as well. I do not see a problem here. BTW: The ONC tiles are currently not updated! And generally OSM data is not suitable for navigation anyways without comparing it thoroughly to other sources. I think it can be used for navigation, but you really have to know about the state of the data and data sources. |
I adjusted my script such that a light characteristics string is generated and displayed in favor of the standard string. The characteristics of each individual sector are given in the sector arc. This is actually quite usable. |
I perfectly agree. Good to learn that ONC is not up to date currently. Then something went out of work. Can you confirm at your example check that the OpenSeaMap is updated better, or the same update problem applies? I would then inform the group managing this accordingly, at best based on your OSM seamark data example. |
Thanks for the Schleimünde example from your updated script. This is a big improvement! I like to motivate you to implement this for use of all in the OsmAnd. I would love to use this and prefer it much over my "symplistic" approach of June. The intuitive understandability of your Int-1 like display will be very helpful. |
I am not part of the OsmAnd team, but they are free to use the code from my repository. Would be nice to see this to become part of the OsmAnd nautical charts plugin. But you can already use it. Does not belong here, but because you asked: AFAIK the services
are essentially the same. Both show map tiles from |
Is there a keyword in the |
To my knowledge there are two folders
The processing from 1. to 2. involves a batch processing of icons, with the Osmand-resources/ which was difficult for me to find out two years ago. I hope I took some notes on it and if i find them, I post them here. |
Thanks. But there icons are inside the APK. Is there a location outside the APK, like in the osmand dir on the device, where I can place additional icons (w/o need to recompile)? |
Could anyone make use of the light sectors in #16894 (comment) ? |
@vshcherb and others As demonstrated step by step manually, all elements described by quantenschaum work perfectly. However, I would not know, how to implement that professionally (not manually, and sufficient in the OsmAnd world, i.e. independent of updating and downloading from a file provided on a server by quantenschaum), so that it becomes available to the whole community. More correct seamark light display would certainly enhance the usability of the OsmAnd Nautical render map for boaters significantly! a) I think the basis would be to enhance the creation of the .obf data taking the path provided in the tools of quantenschaum. b) When it comes to integrating quantenschaums marine rendering style with OsmAnd's nautical rendering style:
Who can support this? |
Hi @josail we certainly need to take ownership of it. I do appreciate the work you have done and I see that we need to integrate marine style replace our default boat rendering style. Also we need to integrate the data and schedule it on our side to produce monthly with World_seamarks.obf I have 1 question and 1 concern:
We're certainly willing to take leadership and automate it further. We don't know how to approach it yet (transfer maintenance is not easy unfortunately)
|
Hi Vshcherb, thanks for your engaging reply. The additional work proposed for the 2nd step of improving seamark lights originates from @quantenschaum. Thus I like to forward your question and concern to him/her?
Should the solution proposed above in this issue by quantenshaum really be related to a lot of manual effort, then I can suggest to also consult with @malcolmh, who has implemented java solutions for highly automate, global and "within minutes" OSM data seamark rendering with very similiar result, i.e. including light arcs and INT-1 standard text display next to lights, both for the opennauticalchart and openseamap here: https://github.com/OpenNauticalChart/renderer, see also some more description at https://wiki.opennauticalchart.org/, see the map rendering results corresponding to the three examples illustrated above in this issue: |
Yes, please use my work and integrate it into OsmAnd if you like. data created via cronjob is available at http://waddenzee.duckdns.org/download/ OsmAnd with light sectors vs OSM online |
Hi, is there any progress on this topic? It would be nice get my marine rendering style merged (could replace the nautical style) It contains many changes/enhancement to make the chart much more usable as a nautical chart, but is not that easy to merge and it get's worse the more they diverge. I also integrated the nautical depth style into it, because nautical depth are an integral part of a nautical chart (and currently the depth style gets overwritten with every update of OsmAnd). There also needs to be some additional data (i.e. light sectors, depth contours and areas, depth expositions, etc.) in the OBFs themselves, so the rendering types have to be updated as well. marine vs nautical |
@quantenschaum progress was interrupted by complicate 4.7 release. Just yesterday discussed that we need to do it this / next week at least start. |
Ok, nice. What do you mean by?
The marine style contains the styling for the light sectors but also contains other modifications, this could be merged now. The creation of the OBFs containing the light sector primitives is a separate task. One could start with a single set of light sectors as in the |
Using my script one can create lightsectors of different size using the I just implement this for 3 levels. It looks like this. screen-20240508-141642.h264.mp4 |
|
What exactly do you mean? Is there a possibility to give the sector arc radius in pixels? That would require the arc to be generated by the renderer, in a geometry shader. That would be nice solution. Are geometry shaders available on all current mobile devices? Alternative the arcs have to generate in demand in software (not opengl). |
I just updated the lightsectors file with now 4 different levels with different arc radii and thresholds to include lights based on their range. Try it, I think, this is quite usable. |
🚀 feature request
Nautical rendering style: 1. Add display of light characteristics in the nautical map 2. Add display of sctorial lights
Description
The display of the nautical rendering style lacks the important information on the light characteristics, which is essential for navigation by the light information. It is readily available in a well structured list of seamark tags as described in :
https://wiki.openstreetmap.org/wiki/Seamarks/Lights
which can be evaluated in a appropriate text as in the openseamap.
A special display with lines and coloured arcs is required for sectorial lights, as e.g. displayed here:
https://wiki.openstreetmap.org/wiki/Seamarks/Sectored_and_Directional_Lights
For 1. and 2. I'm willing to support with limited/beginners experience in the rendering style syntax. Thus the success will require engagement of a second person with more experience on the rendering style programming. I'm much willing to support by feedback on the openseamk syntax (https://wiki.openstreetmap.org/wiki/Seamarks/Light) and intended style (similar to openseamap and international standard INT-1 for nautical charts, https://wiki.openstreetmap.org/wiki/Seamarks/INT-1_Section_P). And by repeated testing of adjustments to the nautical rendering style on an iOS iphone.
Describe the solution you'd like
Text display right of or below the navigational light in the nautical rendering style reflecting INT-1 nomenclature of the light characteristics (e.g. https://wiki.openstreetmap.org/wiki/Seamarks/INT-1_Section_P, www.openseamap.org)
lines, dashed lines and coloured arcs of sectorial lights around the navigational light like in https://wiki.openstreetmap.org/wiki/Seamarks/Sectored_and_Directional_Lights
set up a composed string for text display in the nautical rendering style, some depence on zoom level according to major, minor and other navigational lights rating of importance
draw lines and arcs, graphical features to be implemented, I don't know how to do this
regarding 2.: alternatively as a first step to allow for the information of sectorial navigational lights as a workaround: Option for the display of a short 2nd text indicating the light sectors definitions
The text was updated successfully, but these errors were encountered: