Skip to content

Instantly share code, notes, and snippets.

@tmcw
Created March 18, 2013 21:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tmcw/5191049 to your computer and use it in GitHub Desktop.
Save tmcw/5191049 to your computer and use it in GitHub Desktop.
var x = point.lon.toFixed(4) % 360;
var y = point.lat.toFixed(4);
var z = first ? center[2] : this.map.getZoom();
if (x < -180) x += 360; else if (x > 180) x -= 360;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment