Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Adds a containsLatLng() method to Polygon class for Google Maps API v3
branch: master

This branch is 16 commits behind tparkin:master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
README
maps.google.polygon.containsLatLng.js

README

This is a Javascript Google Maps v3 extension for the Polygon class to detect whether or not a point resides within it.

Simplest Usage:

var coordinate = new google.maps.LatLng(40, -90);                                                                                                                                                                                                       
var polygon = new google.maps.Polygon([], "#000000", 1, 1, "#336699", 0.3);
var isWithinPolygon = polygon.containsLatLng(coordinate);
Something went wrong with that request. Please try again.