[talk-au] GPX editor

spammed at aanet.com.au spammed at aanet.com.au
Thu Sep 20 11:28:07 BST 2007


On Thu, 2007-09-20 at 11:44 +1000, Stephen Hope wrote:
> Can anybody recommend an editor for use on GPX files?  Not tracks,
> just waypoints.
> 
> However, the GPS was left on while sitting still for quite some time
> at a few places, so I'd like to remove some excess points 
Just open it up in a text editor and delete entire trackpoint entry from
the xml.

Here's one of my trackpoints that I don't need:

   <trkpt lat="-37.772000" lon="145.024740">
    <ele>111.781</ele>
    <time>2007-09-15T23:47:07Z</time>
   </trkpt>
Here are your rough steps:

1) Open the track log
$ java -jar josm-latest.jar 20070915.gpx

2) put your mouse over the cloud of points to be deleted, and write down
the co-ordinates

3) Open the track log in your favourite text editor
$ vi 20070915.gpx
(or emacs, or Microsoft WordPad, or whatever)

4) Search for the co-ordinates you wrote down, leaving off the last part
for precision.

5) Delete all points either side, by looking at the time.  You should be
able to work out when you stopped moving and roughly when you started
again.

6) Not sure what happens if you cross over a <trkseg>.  Anyone else have
a clue?

If this actually works, please add it to a Wiki somewhere.

Have fun.

Neil.





More information about the Talk-au mailing list