borrow bucket map from cam slicer to allow negative z indices
This commit is contained in:
parent
6812644a3a
commit
5a56453390
2 changed files with 16 additions and 6 deletions
|
|
@ -22,6 +22,14 @@ THREE.computeFaceNormal = function(vA,vB,vC) {
|
|||
return cb;
|
||||
};
|
||||
|
||||
// https://www.npmjs.com/package/three-mesh-bvh
|
||||
THREE.addBVH = function() {
|
||||
const { computeBoundsTree, disposeBoundsTree, acceleratedRaycast } = MeshBVHLib;
|
||||
THREE.BufferGeometry.prototype.computeBoundsTree = computeBoundsTree;
|
||||
THREE.BufferGeometry.prototype.disposeBoundsTree = disposeBoundsTree;
|
||||
THREE.Mesh.prototype.raycast = acceleratedRaycast;
|
||||
};
|
||||
|
||||
THREE.dispose = function(obj) {
|
||||
if (!obj) {
|
||||
return;
|
||||
|
|
|
|||
Loading…
Reference in a new issue