Questions tagged [gpx]

GPX (the GPS Exchange Format) is a light-weight XML data format for the interchange of GPS data. Source: http://www.topografix.com/gpx.asp

GPX (the GPS Exchange Format) is a light-weight XML data format for the interchange of GPS data (waypoints, routes, and tracks) between applications and Web services on the Internet.

It was devised by Topographix.

Current Status

The GPX 1.1 schema was released on August 9, 2004.

Gpx example:

<?xml version="1.0" encoding="UTF-8"?>
<gpx version="1.1" creator="GeoWgs84 Harness">
  <metadata>
    <bounds minlat="-22.92166941" minlon="44.37930616" maxlat="-20.11240872" maxlon="45.58278193" />
  </metadata>
  <wpt lat="-22.85100527" lon="45.57800895">
    <name>Ox</name>
    <sym>Dot</sym>
  </wpt>
  <rte>
    <name>Spiral</name>
    <rtept lat="-22.85100527" lon="45.57800895">
      <name>Ox</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85091497" lon="45.57800895">
      <name>A00</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85083842" lon="45.57808352">
      <name>A01</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85100527" lon="45.57800895">
      <name>Ox</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85074986" lon="45.57828453">
      <name>A02</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85072882" lon="45.57872908">
      <name>A03</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85100527" lon="45.57800895">
      <name>Ox</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85100526" lon="45.57956788">
      <name>A04</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85211105" lon="45.58088949">
      <name>A05</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85100527" lon="45.57800895">
      <name>Ox</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85509172" lon="45.58241839">
      <name>A06</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.86168376" lon="45.58278193">
      <name>A07</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85100527" lon="45.57800895">
      <name>Ox</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.87412204" lon="45.57800895">
      <name>A08</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.89371830" lon="45.55891257">
      <name>A09</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85100527" lon="45.57800895">
      <name>Ox</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.91637356" lon="45.50742620">
      <name>A10</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.92166941" lon="45.39356015">
      <name>A11</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85100527" lon="45.57800895">
      <name>Ox</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85050504" lon="45.17892468">
      <name>A12</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.56621709" lon="44.84211913">
      <name>A13</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85100527" lon="45.57800895">
      <name>Ox</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-21.80087521" lon="44.45769348">
      <name>A14</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-20.11240872" lon="44.37930616">
      <name>A15</name>
      <sym>Dot</sym>
    </rtept>
    <rtept lat="-22.85100527" lon="45.57800895">
      <name>Ox</name>
      <sym>Dot</sym>
    </rtept>
  </rte>
  <extensions />
</gpx>

Resources

376 questions
5
votes
6 answers

Plotting GPS info with Ruby

I'm looking for ways to programmatically convert my GPS logs to images and would like to do this in Ruby... if that's an acceptable tool. I have no GIS background whatsoever but as a programmer i think it's an interesting problem to look at. Here is…
Cimm
  • 4,653
  • 8
  • 40
  • 66
5
votes
1 answer

How to reference an exception class in Python?

I want to catch a GPSException thrown by the gpxpy library. try: gpx = gpxpy.parse(open(filepath)) except GPXException: print "GPXException for %s." % filepath Since I am new to Python I do not understand how one would reference the…
JJD
  • 50,076
  • 60
  • 203
  • 339
4
votes
2 answers

How to comment a GPX file?

How I can make a comment in a GPX files? I checked on Google and here with no luck. Thank you !
Jonas
  • 41
  • 1
  • 2
4
votes
0 answers

How to draw a polyline in google maps using Android GPX Parse

I'm trying to draw a polyline on a google maps using the Android GPX Parser library, I have little experience in programming, the code I'm using reads the .gpx file and provides the result in the android studio logcat but does not draw the polyline…
Naldo
  • 41
  • 2
4
votes
2 answers

Wrong locations order after loading a GPX file in the Android Emulator

I have a problem with the Android emulator. I am creating an app which uses location in order to register tracks etc. The problem is: when I load a GPX file in Extended controls of the emulator, locations are not sorted correctly thus the man on the…
Fajeczny
  • 41
  • 1
  • 4
4
votes
2 answers

Swift - How to read coordinates from a gpx file

so in my other question I asked, I found out that I can create easily gpx files, but now I need to display the content of the gpx file as a MKPolygon. Before, I had created the list with all the coordinates in a plist file, this was easy to read…
J.Paravicini
  • 882
  • 12
  • 39
4
votes
2 answers

Trying to define GPX document type in Xcode 6.4

I'm trying to define a GPX document type so that I can open gpx file types from other applications. I've followed Apple's Technical Q&A on this topic. I've also tried solutions that I found that edited the plist file directly. None of them have…
flightsimmer668
  • 41
  • 1
  • 10
4
votes
2 answers

Using GPXPY to parse gpx file results in not well-formed invalid token error

I have a few gpx files which I want to parse and then feed into a GIS format. I've downloaded gpxpy because I need some of its functions rather than just wanting to extract the lat and lon from the files. But when I make a parser import gpxpy p =…
Menno
  • 241
  • 2
  • 8
4
votes
1 answer

File upload in PHP: Validating that a file is gpx

I am currently working on a project where the users can upload images and GPX files. No problem in validating the images but I simply can't find a secure way to make sure that the gpx files are not some malicious file instead. Any hints are very…
user1204121
  • 385
  • 1
  • 3
  • 15
4
votes
1 answer

Simulate Low and Hight Gps Accuracy

I did a .gpx file to simulate a route on IOS simulator, now i wanna simulate the horizontal accuracy how I can do this? as follow is an excerpt of my .gpx file: //how add…
ademar111190
  • 14,215
  • 14
  • 85
  • 114
3
votes
3 answers

How do I use XmlSerializer to handle different namespace versions?

I am using the .NET XmlSerializer class to deserialize GPX files. There are two versions of the GPX standard: ... ... Also, some GPX…
MetaMapper
  • 968
  • 8
  • 22
3
votes
3 answers

Parsing GPX files with SAX parser or XmlPullParser

I have a number of gpx files that my app creates and will need to parse at a later stage in the app. I'm having trouble parsing them in general. I've seen alot of examples of parsers on this site and others but they all use objects like Tracksand…
Droid_Interceptor
  • 613
  • 3
  • 14
  • 37
3
votes
4 answers

How to append a child element to a large XML file using Java?

I am trying to create a XML file, using Java, that is a collection of GPS coordinates (GPX). Every time I receive a coordinate from my android device (approximately 1 every second) I need to append the results to an existing XML file. The output…
Ferrari692
  • 101
  • 5
3
votes
1 answer

Is it possible to add your own tags to a GPX file like in XML?

I know GPX is a light-weight XML data format but what I want to know is it possible to add my own tag like Some Town here which will hold the nearest town that the GPS data was done near or would I have to save this in a seperate XML…
Droid_Interceptor
  • 613
  • 3
  • 14
  • 37
3
votes
1 answer

Where does this precision loss happen and how to prevent it?

I'm writing a simple tool in Qt which reads data from two GPX (XML) files and combines them in a certain way. I tested my tool with track logs that contain waypoints having 6 decimal digits precision. When I read them from the GPX file, the…
teukkam
  • 4,267
  • 1
  • 26
  • 35
1 2
3
24 25