Posts: 7
Threads: 2
Joined: Jun 2011
Hi, Second post.
Why do KML files converted from GPX have no timestamps?
This means they cannot use GE's Time Slider.
--
Terry, East Grinstead, UK
Posts: 7,532
Threads: 230
Joined: Aug 2007
(02.06.2011, 22:30)terrypin Wrote: Why do KML files converted from GPX have no timestamps?
I guess that the Source file contains no timestamps either? Can you post an example?
--
Christian
Posts: 1,296
Threads: 45
Joined: Oct 2007
@Christian: Attached is a part of a motorbike-tour. Recorded at a TomTom with logpos.
Time and speed are recorded and shown very well in original *.itn format.
Time and speed are lost when saving the data via RC as *.kml.
No hidden options are set for *.kml at my system.
110604.zip (Size: 3.31 KB / Downloads: 1,071)
--
Matthias
Posts: 7,532
Threads: 230
Joined: Aug 2007
(04.06.2011, 11:06)kumo Wrote: Time and speed are recorded and shown very well in original *.itn format.
Time and speed are lost when saving the data via RC as *.kml.
Now, I understand the problem. You might call it a bug or a feature. The reason for this behaviour is, that RouteConverter stores a Track or Route in KML as a LineString where there is no possibility to store a timestamp:
Quote: <LineString>
<coordinates>10.07341,53.76129,24.1 10.07162,53.76708,23.0 10.07011,53.77909,35.2 10.0541,53.76915,22.4 10.04943,53.77269,21.7 10.039,53.79359,61.9 10.03064,53.79567,45.2 10.01436,53.80204,47.5 10.01281,53.80697,54.5 </coordinates>
</LineString>
If you're using Waypoint List, a Placemark is used and the timestamp is preserved:
Code: <Placemark>
<name>Wakendorf II; K79 Wilstedter Straße</name>
<visibility>false</visibility>
<TimeStamp>
<when>2011-06-04T07:09:11Z</when>
</TimeStamp>
<Point>
<coordinates>10.07162,53.76708,23.0</coordinates>
</Point>
</Placemark>
So the workaround to keep timestamps is: change the type of the position list to "Waypoint List" before saving as KML.
Does this help? Any ideas how to improve this?
--
Christian
Posts: 7
Threads: 2
Joined: Jun 2011
06.06.2011, 10:40
(This post was last modified: 06.06.2011, 10:42 by terrypin.)
I'm confused. When I drag a GPX (with timestamps) into Google Earth, the default pop-up dialog looks like this:
http://dl.dropbox.com/u/4019461/GE-GPX-Tracks-1.jpg
I have to enable the option 'Create KML linestrings' if I want to use the time data in GE (e.g. the Time Slider). That seems hard to square with "RouteConverter stores a Track or Route in KML as a LineString where there is no possibility to store a timestamp."
To answer your last question, changing my tracks to waypoints would definitely not be an acceptable solution for me!
--
Terry, East Grinstead, UK
Posts: 7,532
Threads: 230
Joined: Aug 2007
(06.06.2011, 10:40)terrypin Wrote: I'm confused. When I drag a GPX (with timestamps) into Google Earth, the default pop-up dialog looks like this:
http://dl.dropbox.com/u/4019461/GE-GPX-Tracks-1.jpg
Now, I'm confused. I thought we were talking about opening KML files in Google Earth, since that is the native format of Google Earth?
So you open GPX in Google Earth?
--
Christian
Posts: 7
Threads: 2
Joined: Jun 2011
07.06.2011, 23:01
(This post was last modified: 07.06.2011, 23:02 by terrypin.)
"So you open GPX in Google Earth?"
Yes, of course, if I want to view the track in GE.
But maybe we should return to my original question! I'll re-phrase it.
Let's say I want to use RC to convert xyz.GPX (with timestamps) to KML. I open the GPX in RC then use File > Save As, and specify Google Earth. But the resultant file xyz.KML does not contain any time data.
Why not?
Did you try to reproduce that?
--
Terry, East Grinstead, UK
Posts: 7,532
Threads: 230
Joined: Aug 2007
08.06.2011, 07:39
(This post was last modified: 08.06.2011, 07:39 by routeconverter.)
(07.06.2011, 23:01)terrypin Wrote: "So you open GPX in Google Earth?"
Yes, of course, if I want to view the track in GE.
That is not self-evident. KML is the natural format of Google Earth and it makes a difference whether the format is GPX or KML for the answer of your question.
(07.06.2011, 23:01)terrypin Wrote: But maybe we should return to my original question! I'll re-phrase it.
Let's say I want to use RC to convert xyz.GPX (with timestamps) to KML. I open the GPX in RC then use File > Save As, and specify Google Earth. But the resultant file xyz.KML does not contain any time data.
Why not?
Now it's clearer, what you're doing. And I've already answered this question in my first post. In short: if you don't use "Waypoint list" as a type there is no way to representation timestamps in KML as the format does not allow it. If you find a different way to represent timestamps, please provide test files.
--
Christian
Posts: 7
Threads: 2
Joined: Jun 2011
Eh? Of course KML files support timestamps! Here's an example.
http://dl.dropbox.com/u/4019461/KMLwithTimeStamps.kml
--
Terry, East Grinstead, UK
Posts: 7,532
Threads: 230
Joined: Aug 2007
08.06.2011, 17:24
(This post was last modified: 08.06.2011, 17:25 by routeconverter.)
(08.06.2011, 16:40)terrypin Wrote: Eh? Of course KML files support timestamps! Here's an example.
[..]
We're getting closer and closer. The example uses <Placemark> and a new KML Extension introduced with Google Earth 5:
Quote: <gx:Track>
<when>2010-05-30T08:10:40Z</when>
<when>2010-05-30T08:42:58Z</when>
<when>2010-05-30T08:43:37Z</when>
[...]
<gx:coord>-1.514117 50.669709 11</gx:coord>
<gx:coord>-1.513529 50.66998499999999 9.000000000000002</gx:coord>
<gx:coord>-1.513229 50.67039199999999 11</gx:coord>
Note, that this is a Google-specific extension to KML 2.2 and currently RouteConverter only reads this structure and displays it as a Track. Feel free to extend the code and submit a merge request.
--
Christian
|