SupervisionT / Leaflet.PolylineMeasure

Measure the distance by Great Circle or Rhumb Line --> DEMO -->

Home Page:http://goo.gl/1Q3k75

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Leaflet.PolylineMeasure

I have been inspired by PPete work and his original work https://github.com/ppete2/Leaflet.PolylineMeasure

In this plugin we provide two different mesurement methods to measure the distance between two points. Those methodes are:

  • Great Circle Distance Wiki
  • Rhumb Line Distance Wiki

As a user you'll have the ability to toggle between the two methodes and each time the distance measurement will be rendered based on your selection, One path .. render twice!!

Demo

  • Please take a look at the following Demo

Screenshot

Usage

Add 2 lines within your HTML-code to load the .css and .js files of the plugin:

<link rel="stylesheet" href="https://ppete2.github.io/Leaflet.PolylineMeasure/Leaflet.PolylineMeasure.css" />
<script src="https://ppete2.github.io/Leaflet.PolylineMeasure/Leaflet.PolylineMeasure.js"></script>

Add 1 line within your Javascript-code to add the plugin's control into your Leaflet map.

L.control.polylineMeasure(options).addTo(map);

About

Measure the distance by Great Circle or Rhumb Line --> DEMO -->

http://goo.gl/1Q3k75

License:BSD 2-Clause "Simplified" License


Languages

Language:JavaScript 90.9%Language:HTML 6.8%Language:CSS 2.2%