Greetings all OSM mappers!<br><br>Ever wanted to take a look at all the tracks you've ever done in a particular area... but your editor couldn't handle that many gpx files without getting too slow?<br><br>Ever go through a street that's not on your GPS and go "Hey wait, I <b>KNOW</b> I've been here before!"?<br>
<br>Ever try to remember which day or gpx file that one track is in?<br><br>Want to find trackpoints based on elevation or in a specific bounding box?<br><br>Grep a GPX file and then handmake a new file to put those points in?<br>
<br>I wanted to do those things... and I couldn't couldn't find a utility for it.    Maybe my googling skills aren't up to snuff and I missed it but... oh well, now you have gpxgrep.<br><br>How is it better than grep?  Well it creates a gpx file and puts all the trackpoints and waypoint you want inside it.  A valid GPX file you can drop in JOSM or whatever to play around with... but you probably shouldn't upload them to OSM.  :-)<br>
<br>Here's an example:<br>./gpxgrep 4.3432 -54.343 4.4003 -54.405 ~/Tracks/*.gpx > mybox.gpx<br><br>There's also an elevation option that takes two numbers and returns all points or waypoints within that elevation range. <br>
./gpxgrep 4 -5 4.1 -5.1 -e -99 0 ~/Tracks/*.gpx > belowsea.gpx<br><br>Perhaps useful to hikers?<br><br>----------<br>This is alpha level stuff, it works most of the time but sometimes doesn't create a new track segment when points go past the bounding box, so you get some lines around the edges.  I also need to add comment searching.  So fool around with it, let me know what you think and send suggestions.<br>
<br><a href="http://sourceforge.net/projects/gpxgrep/">http://sourceforge.net/projects/gpxgrep/</a><br><br>I'll be refactoring when I get a chance, the code is ugly but I've held onto it too long and need to release something so here it is.<br>
<br>-Don.<br>