[GIS] How to convert a GPX to SHP with extended properties

gpxshapefile

I have a GPX file containing trackpoints, similiar to the following:

<trkpt lat="12.34567890" lon="-12.34567890">
        <ele>250.100000</ele>
        <time>2016-06-03T13:09:47Z</time>
        <course>140.300003</course>
        <speed>15.639112</speed>
        <geoidheight>-34.6</geoidheight>
        <fix>3d</fix>
        <sat>5</sat>
        <hdop>2.800000</hdop>
        <vdop>1.600000</vdop>
        <pdop>4.600000</pdop>
</trkpt>

How do I convert the GPX file to a SHP file and include all the extended fields, like hdop, vdop, pdop, etc.? This will eventually be imported into GIS software like QGIS or ArcMap but I prefer SHP over a database for portability.

I tried using OGR2OGR with -dsco GPX_USE_EXTENSIONS=YES but that doesn't bring the extended properties along to the SHP file.

I prefer a command line approach to doing this. I will be trying to automate the process.

Best Answer

GPSBabel is my go-to for this (unless you have access to FME).

DNRGPS is another option. I prefer GPSBabel just because I've been using it for longer.

If you have ArcMap, see this other post for ArcMap specific answers: What is the simplest method to add GPX files into Arcmap?

Related Question