About program World Walk Web. March 27, 2021, 10:01 a.m., by Lem

Almost functional altitude fetching system

After a few months, the IRL Fog of War comes back with some satisfying improvements.


Status


For memory, the Fog currently relies mostly on altitude around positions to define the visible area. A strong altitude database access was then mandatory (via API or local raster file analysis). The opentopodata API seems comprehensive and mature enough for this work. The main downside, which is also probably the reason they are still alive, is that there are limitations on requests per second and per day (for free access). For Europe, the Eu-Dem database gives a good precision for our use case: 25m. Enough to have a decent rendering of hiking sessions.


Even with the request limitation, it was enough to set up an advanced system for altitude management (with local storage for already asked informations), allowing the drawing of a more relevant Fog (even if the system is not designed for urban areas with occulting buildings).


Details





The capture above is an explanatory rendering of the Fog of War for a little running session. Red dots are the GPS samples from the running app. Dark blue area is the "absolute" fog of war, only based on distance to position. Transluscent blue area is the difference between absolute fog and altitude biased fog : we consider that all what is in this blue area is hidden by the landscape.





The second capture shows the same result for a single point. We cas see here that the area is suspiciously rectangular. This is due to altitude requests limitations, giving the same altitude to several points. A better precision setting would give a sharpest shape.





This last capture displays construction dots in dark red corresponding to the altitude requests around a given position in light red. The algorithm splits the "visibility" circle into N rays (here N=16), and each ray is splitted into M subsegments (here M=20).

For each ray, the maximum visibility is set to the last point where the altitude is not above the initial point nor below the previous maximum altitude. (which ignores the further visible spots, algorithm to be corrected in a next version)


Coming next


With this basis, a lot of progress can be made on visibility, altitude gathering strategy algorithms and parameters adjustments to balance between precision and API availability.


The main effort will be on usability, since a lot of operations are done manually for the moment.


About fog aspect, a difficult but interesting point would be to direct the vision field, since humans have no eyes behind the head. This would request a lot of preprocessing to know the walking direction, and I'm not sure the difference would be so significant.




Draft for oriented vision field around a looping track (with excessively narrow vision)

> More Updates articles

Add a comment

| RSS feed for all notifications | for dev news only