three-mesh-bvh
Advanced tools
Changelog
[0.4.2] - 2021-08-04
intersectsRangeFunc
could be passed the incorrect node id in shapecast.distanceToGeometry
and closestPointToGeometry
which would likely result in some closest points being missed. This fix greatly degrades performance in the case where the passed geometry does not have a BVH. It is recommended that the passed in geometry include a computed bounds tree.closestPointToGeometry
.MeshBVHVisualizer
render and update performance.distanceToGeometry
and closestPointToGeometry
fast path when the passed in geometry has a bounds tree.Changelog
[0.4.1] - 2021-06-21
Changelog
[0.4.0] - 2021-06-11
MeshBVH.refit
function to refit the bounds to modified vertices.setBoundingBox
MeshBVH construction option.MeshBVH.getBoundingBox
function.intersectsRange
callback option to MeshBVH.shapecast
.src/worker/generateAsync.js
function. Use GenerateMeshBVHWorker
instead.type: module
in package.json to enable use of es6 modules in node.sideEffects: false
to package.json.MeshBVH.shapecast
to take an object of callback functions instead of a list of function arguments and the triangle intersection callback has been changed to take a single triangle index. See README for new API. Calls using the old function will log a warning.MeshBVHVisualizer
not using the new geometry BVH if one was generated.MeshBVHVisualizer
not using the new mesh if it was set.intersectsTriangleFunc
to MeshBVH.shapecast
could throw an error.Changelog
[0.3.7] - 2021-03-06
Changelog
[0.3.6] - 2021-03-03
Changelog
[0.3.5] - 2021-02-28
raycastFirst
failed to return a valid result.Changelog
[0.3.4] - 2021-02-25
Changelog
[0.3.3] - 2021-01-24
depth
argument to intersectsBoundsFunc
and intersectsTriangleFunc
of shapecast
.closestPointToSegment
function to the triangle object used during shapecast which can be used for capsule intersection detection.Changelog
[0.3.2] - 2020-12-23
Shapecast
intersectsBoundsFunc
to return one of the NOT_INTERSECTED
, INTERSECTED
, or CONTAINED
constants. Returning true
and false
currently retains the old functionality.Changelog
[0.3.1] - 2020-12-14
shapecast
to the docs.MeshBVHVisualizer
to exports.