https://github.com/jamen/pos
turn coordinate positions (under 2^15) into a single index
https://github.com/jamen/pos
Last synced: 8 months ago
JSON representation
turn coordinate positions (under 2^15) into a single index
- Host: GitHub
- URL: https://github.com/jamen/pos
- Owner: jamen
- Created: 2017-01-17T22:41:05.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-01-17T22:56:26.000Z (over 9 years ago)
- Last Synced: 2025-04-02T11:24:30.505Z (about 1 year ago)
- Language: JavaScript
- Homepage:
- Size: 0 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
Awesome Lists containing this project
README
# pos
> Turn coordinate positions (under 2^15) into a single index
```js
var loc = toLoc(123, 456)
// 14942331
var pos = toPos(loc)
// [123, 456]
```