7.24.2007

APP: Google Earth™ Path Measurer

I use Google Earth frequently to plan out bike rides and hikes. One frustration I have faced in Google Earth is with using the built in path measuring tool. While you can trace your path with this tool and get the overall distance, it does not allow you to save the measured path. To save paths you need to upgrade to a Google Earth Plus account, which costs 20$ per year. I figured I would bite the bullet and upgrade my account, to be able to save paths that I create. So 20$ later I was the proud owner of a Plus account.

One small problem.. While the plus account allows you to create and save paths, it DOES NOT allow you to measure them! In order to measure the paths you create, you need to retrace them using the built in measuring tool. Whoops.

Frustrated with this problem, I decided to create a custom application to allow me to measure the paths I create in Google Earth without having to retrace them with the measuring tool.

I have decided to post my application for free download, in case anyone else is facing similar challenges. You can download the app here. An overview and details of its use follow below.

The KML Path Measurer

KML Path Measurer application screenshot

Overview

This application will measure paths in Google Earth, either saved in KML Files, or copied from the clipboard. The application uses the haversine formula to measure distances between points on a spherical object. These distances are approximate, but some test calculations I have made, show that they are in line with Google Earth's built in measuring tool calculations. The application handles files or clipboard KML containing multiple paths.

The application will also give you the option to automatically update the path's description with the calculated distance. The path can then be imported back into Google Earth.

Features

  • Measures Google Earth Paths either saved as KML files or copied from clipboard.
  • Option to automatically update path descriptions with calculated distance
  • Results in-line with Google Earth internal measuring tool

System Requirements

  • Microsoft Windows™ (Tested on XP and Vista)
  • Microsoft .NET Framework 2.0(Already installed on most Win Machines)
  • Google Earth™ (Plus account required to save paths)

Download

The application can be downloaded from here. This is a self installing msi file. The msi file is large (400K) but the actual application is only about 150K including the help file.

Installation

To install simply execute the downloaded msi file, and follow the on-screen prompts.

Application Use

Working with Paths exported as KML

First, you need to create a new path file in Google Earth. Clicking the create path button should pop up a window like this.

Creating a new path in Google Earth

Next trace out your path, name it, and click the OK button.

Here is an example path I created.

Sample Google Earth Path

Now save the path file as a KML file by right clicking the path in Places and choosing "Save as..".

Path Save As

When the dialog box appears, choose "Kml" in the save as type box, and click "Save".

Save KML Dialog Box

Now start the KML Path Measurer application. Click the "Calculate Distance from KML Path File" button. This will open a window to select a KML file. Select the file you just saved from Google Earth.

Update KML Dialog

The measurer application will ask you if you want to update the path description with the calculated distance. Choose yes if you want to have this automatically updated.

The application now displays the distances of any paths it finds in the files.

KML Path Measurer with calculated distance

If you chose to update the KML, the path can now be reopened in Google Earth. This will display the updated distance in its description field. To reimport the path, click File > Open in Google Earth and select the KML file. The path's distance is now displayed.Updated Path with distance in Google Earth

Working With Paths Copied to the Clipboard

Copy PathPaths can also be measured after being copied to the clipboard from Google Earth. Simply right click on the path or folder of paths in Google Earth, and select copy.

Now simply click the "Calculate Distance from Clipboard" button in the KML Path Measurer application, and it will calculate the distances for any paths you copied. It will also ask if you would like to update the paths with the calculated distances. If you choose to do this the updated KML will be copied back to the clipboard, ready to be pasted back into Google Earth.

To update the path in Google Earth, just right click your places folder and choose "Paste". The updated path is pasted back into Google Earth.

Contact

If you have any questions, or find any bugs, please feel free to contact me at whaleyadmin@gmail.com. I will make every effort to answer your queries as quickly as possible.

Legal

The KML Path Measurer application is Copyright 2007 by C. Donato. This application may be used free of charge for non-commercial purposes. The software may be distributed as long as the original author is credited properly, and no fee is transacted. The author assumes no liability for any damages related to the use or misuse of the KML Path Measurer Application. This product is not endorsed by Google.
*Google Earth is a trademark of Google Inc.