Google Maps API Polygon with “Hole” In Center

It really is a matter of direction of indices in your polygons, while one is clockwise other should be counter-clockwise.
Change your second array to:

var circleOverlay = [
   new google.maps.LatLng(25.774252, -80.190262),
   new google.maps.LatLng(32.321384, -64.75737),  //second and third coordinates
   new google.maps.LatLng(18.466465, -66.118292), //are swapped compared to your original
   new google.maps.LatLng(25.774252, -80.190262)
 ];

and it will display a nice hole in your triangle

Leave a Comment