Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mikolalysenko/convex-boundary-3d
Finds the boundary of a convex polytope formed by the intersection of halfspaces
https://github.com/mikolalysenko/convex-boundary-3d
Last synced: about 2 months ago
JSON representation
Finds the boundary of a convex polytope formed by the intersection of halfspaces
- Host: GitHub
- URL: https://github.com/mikolalysenko/convex-boundary-3d
- Owner: mikolalysenko
- License: mit
- Created: 2013-10-10T06:52:43.000Z (about 11 years ago)
- Default Branch: master
- Last Pushed: 2014-06-19T17:44:40.000Z (over 10 years ago)
- Last Synced: 2024-10-10T21:40:15.808Z (3 months ago)
- Language: JavaScript
- Size: 132 KB
- Stars: 4
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
convex-boundary-3d
==================
Given a collection of 3D planes constructs the set of polygons representing their boundary.## Install
npm install convex-boundary-3d
## Example
```javascript
var extractBoundary = require("convex-boundary-3d")//Make a cube
var cube = extractBoundary([
[ 1, 0, 0, 1],
[-1, 0, 0, 1],
[ 0, 1, 0, 1],
[ 0,-1, 0, 1],
[ 0, 0, 1, 1],
[ 0, 0,-1, 1]
])
```## API
### `require("convex-boundary-3d")(planes)`
Computes the boundary formed by the intersection of some number of halfspaces in 3D* `planes` is a list of planes
**Returns** A list of polygons encoding the boundary of the planes
## Credits
(c) 2013 Mikola Lysenko. MIT License