Skip to content

Commit ffcf93d

Browse files
committed
cleanup before archiving
1 parent 8f7d2a9 commit ffcf93d

File tree

16 files changed

+188
-353
lines changed

16 files changed

+188
-353
lines changed

.npmignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
11
node_modules
2-
debug
3-
readme-imgs
2+
debug

README.md

Lines changed: 13 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,84 +1,48 @@
1-
# NOTE: This library is unmaintained and deprecated.
1+
## NOTE: This library is unmaintained and deprecated.
22

3-
Hull.js is a JavaScript library that builds concave hull by set of points.
4-
5-
## Examples
3+
<details>
4+
<summary>Click to expand library description</summary>
65

7-
See live examples <a target="_blank" href="http://andriiheonia.github.io/hull/">here</a>.
6+
JavaScript library that builds concave hull by set of points.
87

9-
## Usage
8+
Usage:
109

1110
var points = [ [236, 126], [234, 115], [238, 109], [247, 102], ... ];
1211
hull(points, 50); // returns points of the hull (in clockwise order)
1312

14-
## Params
13+
Params:
1514

1615
* 1st param - array of coordinates in format: `[[x1, y1], [x2, y2], ..., [xn, yn]]`.
1716
* 2nd param - concavity. `1` - thin shape. `Infinity` - convex hull. By default `20`.
1817
* 3rd param - points format. For example: `['.lng', '.lat']` if you have `{lng: x, lat: y}` points. By default you can use `[x, y]` points.
1918

20-
## How it works
21-
22-
<details>
23-
<summary>Expand</summary>
24-
25-
Let's see step by step what happens when you call `hull()` function:
26-
27-
<ol>
28-
<li>
29-
<div>Hull.js takes your source points of the shape:</div>
30-
<div><img src="https://raw.githubusercontent.com/andriiheonia/hull/master/readme-imgs/0.png" /></div>
31-
</li>
32-
<li>
33-
<div>Builds convex hull:</div>
34-
<div><img src="https://raw.githubusercontent.com/andriiheonia/hull/master/readme-imgs/1.png" /></div>
35-
</li>
36-
<li>
37-
<div>After that, the edges flex inward (according to the `concavity` param). For example:</div>
38-
<div>
39-
<img src="https://raw.githubusercontent.com/andriiheonia/hull/master/readme-imgs/2_1.png" />
40-
`concavity = 80`<br/>
41-
<img src="https://raw.githubusercontent.com/andriiheonia/hull/master/readme-imgs/2_2.png" />
42-
`concavity = 40`<br/>
43-
<img src="https://raw.githubusercontent.com/andriiheonia/hull/master/readme-imgs/2_3.png" />
44-
`concavity = 20`
45-
</div>
46-
</li>
47-
</ol>
48-
49-
</details>
50-
5119
## NPM package
5220

53-
Since version 1.0.7 this library is not hosted on npmjs.com. You can still use [GitHub URL](https://docs.npmjs.com/cli/v10/configuring-npm/package-json#github-urls) as a dependency to fetch the latest version, but keep in mind that the entire library is deprecated and there are no plans to maintain it.
21+
It is still possible to fetch the latest version of the library by using [GitHub URL](https://docs.npmjs.com/cli/v10/configuring-npm/package-json#github-urls) as a dependency, but **since the entire library is now deprecated, it is recommended to look for alternative solutions**.
5422

5523
Publishing this library to the public NPM registry under a different name and encouraging other users using unmaintained package is not recommended.
5624

57-
## Development
58-
59-
npm install # install dependencies
60-
npm run test # run tests and build file for debugging in browser
61-
npm run watch # watch ./src dir and automatically rebuild file for debugging
62-
63-
## TypeScript
64-
65-
You can install <a target="_blank" href="https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/hull.js">third-party TypeScript definitions</a> via `npm install --save @types/hull.js`.
66-
6725
## Related papers
6826

27+
<details>
28+
<summary>Expand</summary>
29+
6930
* <a target="_blank" href="http://www.it.uu.se/edu/course/homepage/projektTDB/ht13/project10/Project-10-report.pdf">Implementation of a fast and efficient concave hull algorithm</a>.
7031
* <a target="_blank" href="http://www.cs.jhu.edu/~misha/Fall05/09.13.05.pdf">Computational Geometry: Convex Hulls</a>.
7132
* <a target="_blank" href="https://en.wikibooks.org/wiki/Algorithm_Implementation/Geometry/Convex_hull/Monotone_chain">Andrew's monotone chain convex hull algorithm</a>.
7233
* <a target="_blank" href="http://bryceboe.com/2006/10/23/line-segment-intersection-algorithm/">Line Segment Intersection Algorithm</a>.
7334
* <a target="_blank" href="http://allenchou.net/2013/07/cross-product-of-2d-vectors/">Game Math: "Cross Product" of 2D Vectors</a>.
7435
* <a target="_blank" href="http://users.livejournal.com/_winnie/237714.html">Угол между двумя векторами</a>.
7536
* <a target="_blank" href="http://habrahabr.ru/post/105882/">Когда не нужна тригонометрия</a>.
37+
</details>
7638

7739
## Changelog
7840

7941
<details>
8042
<summary>Expand</summary>
8143

44+
### 1.0.13 - 08.02.2025
45+
- Prepare for archiving: remove helper files, examples, and most of documentation.
8246
### 1.0.12 - 26.01.2025
8347
- Some cleanup and deprecation.
8448
### 1.0.11 - 11.12.2024

debug/perf.js

Lines changed: 0 additions & 186 deletions
This file was deleted.

0 commit comments

Comments
 (0)