Point export to gpx and then reimport as point is broken

elmuSSo shared this problem 8 years ago
Solved

Yo.


I started to play with Locus API and I wanted to import some nice gpx file ( which will be dynamically created by ma app ). So I wanted to recreate the points in their original form. I took a few different points and exported them to gpx file. Then when I reimported them as a points, all are broken. Descriptions are broken, photos are broken, links, formating and so on.


Here is the worst example:


The rest is in this link: https://dl.dropbox.com/u/4747589/PoiG...


I also discovered that the images are not being loaded inside the points descriptions, like on the screenshot 7.jpg


Could you please look into it? And btw, is there any documentation how to create gpx files to be nicely represented as points in Locus? maybe Im doing something wrong?

Comments (20)

photo
0

Hi,


I don`t know if I can simply help with pack of images you packed into rar file. Anyway how description works:


It`s quite simple, let`s take first image in rar file. First three lines that are on screenshot is HTML web page! That is in desc tag in GPX file. Rest, so since coordinates is also HTML page, but it`s generated always by Locus itself, so repeating of some informations may happen in case you export GPX from Locus and then you import same points into Locus


if you`ll need some help, let me know, but if you`ll not be sure why something happen, I need some GPX file to test

photo
0

I can see whats going on inside the files. Of course I will send you some GPX examples to import. But this is not the thing. Im dissapointed that You didn`t standardise the GPX import/export format. Do the tests yourself. Make some points in Locus. Make them complicated, with icon, with address, or even take the point from track recording, or take the point with photo ( all natively created in Locus). And then expot them. The thing is, when these points ( exported to GPX) will be reimported, there should have exactly the same appearance as before export, shouldn`t they? And that`s not the case, they are different, changed, misunderstood by Locus import functions. Let`s imagine second scenario. You have a beautiful collection of points, and you want to share them with your friend. So You are exporting them to GPX, sending him, he is importing them into Locus, and... shit, they are not the same. Geocaches are perfectly made, you can import, export, import and the process will not change their appearance, desciption, and so on. Every other points should be also so persistent. Am I right?

photo
0

Ok. I made some tests. All these are Points created in Locus, exported to some format and then reimported into Locus and analysed.


https://dl.dropbox.com/u/4747589/POIr...


Test points will be:


1. Normal Point


2. Normal Point with address found


3. Point added from analysing already existing track


4. Point found with Google Places


5. Point with photo made during track record


6. Point with photo


7. Geocache


Export to GPX -> reimport to Locus:


1. Unformatted description: all fields not separated and in one line


2. Unformatted description. all fields not separated and in one line


3. Unformatted description. all fields not separated and in one line. Only Distance from/to start are fine in Desciption area.


4. Unformatted description: all fields not separated and in one line. NO URL! It dissapeared after import.


5. Unformatted description: all fields not separated and in one line. NO PHOTO - only question mark icon.


6. Unformatted description: all fields not separated and in one line. NO PHOTO - only question mark icon.


7. All is perfectly fine. Photos, URLs, hints and so on.


Export to GPX (Garmin format) -> reimport to Locus:


1. Unformatted description: all fields not separated and in one line


2. Unformatted description. all fields not separated and in one line


3. Unformatted description. all fields not separated and in one line. Only Distance from/to start are fine in Desciption area.


4. Unformatted description: all fields not separated and in one line. NO URL! It dissapeared after import.


5. Unformatted description: all fields not separated and in one line. NO PHOTO - only question mark icon.


6. Unformatted description: all fields not separated and in one line. NO PHOTO - only question mark icon.


7. All is perfectly fine. Photos, URLs, hints and so on.


Export to KML -> reimport to Locus:


ALL ICONS ARE LOST


1. No errors


2. No errors


3. No errors


4. No errors


5. NO PHOTO - only question mark icon


6. NO PHOTO - only question mark icon


7. It`s no longer recognised as Geochache! Description is fine, URL is there, but no geocache icon


So. Hmm. This is crazy. It would be nice to have KML format, but with persistent icons, repaired geocache recognition and encapsulated in KMZ together with photos.


So now Im confused. I don`t know what format should I use to write the plugin. Both are unreliable:(


I also discovered that there is no obvious way to export only certain Points. I can see only option to exporth the whole category. There should be an option to export only checked points.


I didn`t get deep into that, but I presume that GPX/KML files with their own icons are also not supported? It would be cool to have KMZ file with points+icons in it. So the icons would be auto-imported into Locus, after loading this KMZ file.

photo
0

there is no place for discussion. Thanks for complete report, I`ll for sure improve it. Unfortunately I`m going on a small five days trip, so I`ll work on it in the end of next week, same with https://getsatisfaction.com/locus/top...

photo
0

Thank You.

photo
0

as I wrote, I`ll look on it next weekend but just for your info


1. export only visible points is under "data manager > export > points >" and at bottom "Export only visible"


2. support for geocaches in KML will not be! Also no support for geocache icons in KML because they`re dynamicaly added when cache is displayed. Geocaches have generally no place in KML format, that`s why they export as normal points

photo
0

hmm and second part, there is generally one main problem. Let`s talk mainly about GPX because as you discovered, KML ignores almost everything except name and coordinates (as I see also styles for tracks etc. which should be fixed)


GPX do not have own tags for address and many more, so that`s why Locus include into this GPX own part "extensions" that contain these data and which see again only Locus when you import this file back. Anyway because expect Locus no other software know about this, I also incluse these information as a text into description tag. So when you import this file into any program, there will be description filled with such info. If you import this file into Locus, there will be description but also a regular part with identical info. So only way I see, is to ignore this description if it`s generated in Locus during import. This should fix all your "Unformatted description" texts. But question for me remain how to simply do it ...

photo
0

hi ... I really don`t expect that, but together with some refractoring and some tweaking, it took almost two days to make it working on first sight correctly!


So please check new test version 2.5.6.1


For export there is new settings (in export screen) - "Export generated descriptions". So disable this if you want later import points back to Locus. There is also export together with icons if you check for KML - "Pack as KMZ"

photo
0

Great! I will take a look in the nearest future. In the meantime, think about creating some small documentation about the imported points, to give a chance to programmers to use these specification.

photo
0

yes I was already thinking about it. Import/export is going to have quite a lot of settings and hidden features so some documentation on wiki is more then needed

photo
0

Very nice to hear that! I think POI functionality in Locus is turning into really powerful set of features. With connection to API it is even better.

photo
0

hmm with API it`s little bit complicated. It was created with ... let`s say "hot needle". I never ever imagine that Locus became such monster :) so whole API is not perfect from my current point of view.


I`m slowly creating completely independent new API (few classes already completed, but I expect public BETA release after around half an year :) ).


Peter (my new co-worker) is slowly learning some server side java stuff and I hope this should ends with some nice synchronization and sharing stuffs. Hmm, don`t know why I tell you this, it`s just sound of future ...


Anyway if you`ll have time, test improved export please. I`ll gladly fix some errors if there will be any (and it`s quite possible because I rewrote quite a lot of code)

photo
0

Ok, if I will have some time, I will test it for sure. Now i`m on holidays, and intensively testing other introduced features:) Offlinizer is perfect:)

photo
0

Menion, can You please check this kmz file to find out why, the areas which are perfectly visible in Google Earth are not visible in Locus?


https://dl.dropbox.com/u/4747589/Mapy...


And I can see, that colour of an icon is not supported in Locus.

photo
0

hi,


this is already fixed (in test version). I checked your file and it works correctly


and color - yes, it`s one of not yet implemented KML features

photo
0

may you please test this version? https://dl.dropbox.com/u/8015949/Locu... You can also check on it "blend mode". I had one similar problem as you had, so I was changing a lot way how Locus handle styles for icons. Now are supported also colors etc. Anyway I had to change all computations for tapping and drawing. So just be careful if icons are drawn on correct places and if they also react correctly. Thanks ;)

photo
0

Ok. I will test this as soon as I can.

photo
0

Was probably a bad idea to add this to an already solved topic. I`m creating a new one.


Hi


I`ve noticed that as of today (v2.14.1), URL are not exported to GPX while they are correctly imported.


Am I doing something wrong ?


(Should I open a new topic?)


Thanks


Barbudor

photo
0

I`m also very interested in that, see Make GPX export+import use element "link" for POI website - did you open a new topic? Then please add a link :)