UBports Robot Logo UBports Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    How to import a gpx.track into pure maps/Unav?

    Scheduled Pinned Locked Moved Solved Support
    17 Posts 5 Posters 1.6k Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
      Reply
      • Reply as topic
      Log in to reply
      This topic has been deleted. Only users with topic management privileges can see it.
      • R Offline
        rinigus
        last edited by

        @hankschwie

        The way GPX smart works is that it is using Valhalla's map matching - demo at https://www.mapzen.com/products/mobility/map-matching/

        Which is it's strength and, as you have seen, weakness in some conditions. For it to work, you are expected to give correct mode of transportation (you can walk in the both directions along one-way street, but don't do it while driving).
        In this respect I think it works as expected.

        As for a use of older tracks where street direction has changed, not sure it is of such use for driving then either. I would say that there is no need to be tolerant in this respect and lead to the situation where you are driving and guided to do illegal turn...

        1 Reply Last reply Reply Quote 0
        • R Offline
          rinigus
          last edited by

          As an additional note: not sure what is the status of GPX viewers on UT. From one POV, I would like to keep Pure Maps focussed and as simple as possible. Maybe some other app can be used for general GPX viewing or do the users expect to have such functionality from maps app?

          hankschwieH magdesignM 2 Replies Last reply Reply Quote 0
          • hankschwieH Offline
            hankschwie @rinigus
            last edited by hankschwie

            @rinigus
            Please keep the gpx-features, its just great for hiking or bicycle trips. Right now I'm planing bicycle trips, which works ok, as long as the tracks don't include cross country parts on fields or similar.

            Correcting tracks is an option to use older tracks (as provided by my android ADFC bicycle map app, which is able to export the tracks).

            1 Reply Last reply Reply Quote 0
            • R Offline
              rinigus
              last edited by

              I will, sure as it is now. Let's see if there will be requests and use cases to extend it. But that would have to be discussed before implementing.

              1 Reply Last reply Reply Quote 0
              • magdesignM Offline
                magdesign @rinigus
                last edited by magdesign

                @rinigus: I would love to use it for offline navigation for mountain biking in the mountains.
                Have a lot of GPX tracks from friends and I am thinking of creating some kind of Supertrail maps where all the nice biketrails are visible in offline mode.
                Not sure if here is the right place to ask, but would it be possible to overlay all stored gpx files over a map with height lines (opentopomap.org) or should I render them somehow into a hi-res map and then load this custom map? Any hints are very welcome.

                Oneplus 6 (A6003)
                UBports 16.04 RC 2021-W32

                R 1 Reply Last reply Reply Quote 0
                • R Offline
                  rinigus @magdesign
                  last edited by

                  @magdesign That's a bit more sophisticated than usual.

                  In principle, it is possible, but you will have to get your hands dirty. Overall, you will have to

                  1. convert GPX tracks to something that the map widget can load natively (GeoJSON)
                  2. serve that GeoJSON via local HTTP server (python simplehttp?)
                  3. create new style that is using GeoJSON and serve it via the same server
                  4. add new map to Pure Maps as a custom map

                  As OSM Scout Server does not have height lines, you would have to either look how to add isolines data to these maps via your style or download tiles from opentopomap and serve via your server as well.

                  Not very trivial, but possible. All depends on how much time do you want to invest into it. As a nice side effect, you will learn how it works and could contribute to the map data import and style development.

                  1 Reply Last reply Reply Quote 0
                  • H Offline
                    herr-b
                    last edited by

                    This is somehow similar to the "autoload" of gpx tracks we discussed on github:

                    The program Cachebox for example has a folder called "Autoload". All gpx files that are in this folder are loaded at program start and shown on the map. It has no UI for the "Autoload" folder, only shows the tracks as an overlay over the map. Each track has a different colour to distinguish them from each other.

                    R 1 Reply Last reply Reply Quote 0
                    • R Offline
                      rinigus @herr-b
                      last edited by

                      @herr-b, that would solve the problem as described by @magdesign. Any developers around wishing to write it?

                      1 Reply Last reply Reply Quote 0
                      • magdesignM Offline
                        magdesign
                        last edited by

                        @rinigus :Thanks for the summary of steps.
                        Since I will never go back to android I think I must spend time for solving this problem.

                        @herr-b : this sounds like a great solution.

                        Oneplus 6 (A6003)
                        UBports 16.04 RC 2021-W32

                        R 1 Reply Last reply Reply Quote 0
                        • R Offline
                          rinigus @magdesign
                          last edited by

                          @magdesign If you are going to work on https://github.com/rinigus/pure-maps/issues/408, that would resolve most of your issue with only remaining part being isolines. But for isolines we could maybe find some better solution

                          1 Reply Last reply Reply Quote 0
                          • magdesignM magdesign referenced this topic on
                          • magdesignM magdesign referenced this topic on
                          • First post
                            Last post