Constructors
constructor
- batchObjects: The group of BatchObjects that will make up this top level acceleration structure
Properties
accelerationStructure
The top-level acceleration structure does not have it’s own transformation space. It’s identical to the world space. Unlike the bottom-level acceleration structure which is always centered around the world origin.
Methods
closestPointToPoint
- point: Vector3 The point in space we want to find the closest point in the BVH to
getBoundingBox
- optional target: Box3
raycast
- ray: Ray to intersect with
- materialOrSide: Side | Material | Material[]
raycastFirst
raycast
but stops at first intersection found. Queries the top-level BVH first, then if it finds intersections, it goes down to the bottom-level BVHs and raycasts against them.
Parameters
- ray: Ray to intersect with
- materialOrSide: Side | Material | Material[]
raycastFirst
refit
is called automatically whenever any of the comprising BatchObjects update their transformation.shapecast
- callbacks: ExtendedShapeCastCallbacks