Click to expand library description
JavaScript library that builds concave hull by set of points.
Usage:
var points = [ [236, 126], [234, 115], [238, 109], [247, 102], ... ];
hull(points, 50); // returns points of the hull (in clockwise order)
Params:
- 1st param - array of coordinates in format:
[[x1, y1], [x2, y2], ..., [xn, yn]]
. - 2nd param - concavity.
1
- thin shape.Infinity
- convex hull. By default20
. - 3rd param - points format. For example:
['.lng', '.lat']
if you have{lng: x, lat: y}
points. By default you can use[x, y]
points.
It is still possible to fetch the latest version of the library by using GitHub URL as a dependency, but since the entire library is now deprecated, it is recommended to look for alternative solutions.
Publishing this library to the public NPM registry under a different name and encouraging other users using unmaintained package is not recommended.
Expand
Expand
- Prepare for archiving: remove helper files, examples, and most of documentation.
- Some cleanup and deprecation.
- Minor fixes in package.json.
- Fix vulnerability issue.
- Update NPM dependencies to address vulnerability issues.
- Deprecate library on npmjs registry.
Squash previous tiny releases into one bigger commit with the following minor changes:
- Fix issue with formatting when users pass less than 4 points as an input.
- Remove bower and travis files as they are deprecated.
- Clean up .gitignore.
- Add "debug" folder to .npmignore to reduce tarball size.
- Fix that avoids hitting stack size limit on large arrays.
- Change language level to ES6.
- Performance improvements.
- Minor changes: return the first point as the last point when fewer than 4 unique points are provided.
- Minor changes: fix missing "var" declaration.
- Fix modification of the initial array.
- Add filtration of the duplicates.
- Add edgeSkipList to increase performance of the highly accurate shapes (with the small
concavity
number) + some refactoring.
- Minor changes: fix bower.json.
- Minor changes: fix bower.json.
- Minor changes: Bower support.
- Minor changes: copyrights.
- Minor changes: readme, package.json.
- Configurable point format, now you can use points like
{x: 10, y: 10}
and{lat: 52, lng: 82}
.
- Minor changes: doc, package.json, etc.
- Second version with better performance inspired by this article.
- First version based on Delaunay triangulation.