1.0.7 • Published 8 years ago

convexhull v1.0.7

Weekly downloads
3
License
MIT
Repository
github
Last release
8 years ago

convexhull

npm version Build Status

convex hull 2D algorithm using monotone chain algorithm

usage

const convexhull = require('convexhull')(/*options*/{x: 'lng', y: 'lat'});

const points = [
  {
    lng: 121.409058,
    lat: 31.191149
  },
  ...
];

let hull = convexhull(points);

// for unsorted points
hull = convexhull(points, true);

Options

optiondescdefault
xproperty key x'longitude'
yproperty key y'latitude'

Reference

MonotoneChain

1.0.7

8 years ago

1.0.6

8 years ago

1.0.5

8 years ago

1.0.4

8 years ago

1.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago