Jump to content

Can I convert a bunch of .txt files to a single .kmz?


darwinmay

Recommended Posts

Someone on the local forums needed the page files for the Kansas DeLorme Challenge, so I thought I would take up the challenge of putting together the files myself. Going along fine, however I'd like to also have a .kmz with the page definitions (such as http://www.switchbacks.com/files/Geocaching/WDC/WDC-GE.kmz). Is this possible with gpsbabel (I'm using version 1.2.7 from the Ubuntu apt repositories)?

 

The .txt files are located at blueninja.homelinux.org/caching/KSDCPages.zip.

Edited by BlueNinja
Link to comment

GPSBabel isn't where I'd start with that. This is a plain ole text conversion problem. Looking at the kmz file and the indifvidual Pages files (each appears to be five points to get a closed polygon) I'd just write a little shell or perl (or awk or python or whatever...) ditty that looped over them and then wrote out the appropriate Placemark/linearRing sections.

 

(Hint kmz is gzipped kml....)

Link to comment
any reason why I couldn't convert them to a kml, then gzip into a kmz?
Well, if you have a KML there's no reason to make a kmz - Google Earth can read either.

 

To make the KML files yourself, you wouldn't need MUCH scripting. I don't think GPSBabel would handle the text files in the form you have them, so that would be even MORE work. So either bite the bullet and learn SOME kind of scripting/programming language - or find someone else to do it for you....

 

No, I'm not volunteering :blink: But that's about the only reason I ever write a line of code anymore: Some odd little chore for which no other tool exists? Write one!

Edited by lee_rimar
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...