Skip to content

Instantly share code, notes, and snippets.

@abhisuri97
Created March 18, 2017 09:31
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 abhisuri97/178b41d96d2eaef446d2c71f54fc8419 to your computer and use it in GitHub Desktop.
Save abhisuri97/178b41d96d2eaef446d2c71f54fc8419 to your computer and use it in GitHub Desktop.
var lv = new PruneClusterForLeaflet(160);
mymap.addLayer(lv); // mymap is a leaflet map
/* google location history puts all lat and long pts in integers
* need to convert to regular coors
*/
var SCALAR_E7 = 0.0000001;
var os = oboe()
os.node('locations.*', function(location) {
var marker = new PruneCluster.Marker(location.latitudeE7 * SCALAR_E7,
location.longitudeE7 * SCALAR_E7);
lv.RegisterMarker(marker);
return oboe.drop;
}).done('done');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment