Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/thibauts/merge-meshes
Merges multiple meshes into one
https://github.com/thibauts/merge-meshes
Last synced: 2 months ago
JSON representation
Merges multiple meshes into one
- Host: GitHub
- URL: https://github.com/thibauts/merge-meshes
- Owner: thibauts
- License: mit
- Created: 2015-03-01T12:43:12.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2015-03-01T12:45:15.000Z (almost 10 years ago)
- Last Synced: 2024-08-09T15:17:40.283Z (5 months ago)
- Language: JavaScript
- Size: 117 KB
- Stars: 5
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
merge-meshes
============
### Merges multiple meshes into oneInstall
-------```bash
$ npm install merge-meshes
```Usage
-----```javascript
var mergeMeshes = require('merge-meshes');var meshA = {
cells: [
[0, 1, 2]
],
positions: [
[ 0, 0, 0],
[ 1, 0, 0],
[ 0, 1, 0],
]
}var meshB = {
cells: [
[0, 1, 2],
],
positions: [
[ 0, 0, 0],
[-1, 0, 0],
[ 0, 1, 0]
]
}var mesh = mergeMeshes([meshA, meshB]);
console.log(mesh);
/*
{
cells: [
[0, 1, 2],
[3, 4, 5]
],
positions: [
[ 0, 0, 0],
[ 1, 0, 0],
[ 0, 1, 0],
[ 0, 0, 0],
[-1, 0, 0],
[ 0, 1, 0]
]
}
*/
```