Readonlyintersects(shape?, boxMin: vec3, boxMax: vec3) -> float: a world box's score; negative skips it, the lower of two siblings is entered first.
Readonlyintersects(shape?, a: vec3, b: vec3, c: vec3, instance: uint, triangle: uint, material: uint, normal: vec3) -> bool, or any leading part of those
arguments (only what it declares is computed): a triangle in world space,
its instance (BvhHit.instance), original triangle, material and the
world normal of its authored front side. True stops the cast.
Optional Readonlykeep(shape?, score: float) -> bool: asked when a pushed box comes off the stack with the score it was pushed with; false skips it. Default: keep every box.
Optional ReadonlynameThe WGSL name of the function (its walk, private state and adapters are <name>_bvh*; a hook may not use those names). Default bvhThreeShapecast<n>, numbered in creation order.
Optional ReadonlyshapeThe TSL type of the value the cast is called with and every hook gets
first ('vec4', 'mat4', a StructTypeNode, ...): the query's shape.
Default none: the hooks get no shape and the call takes none.
Options of BvhTraceNodes.getShapecastFn: three-mesh-bvh's
getShapecastFnhooks as three function nodes, compiled into one shapecast walk (shapecastWalkWgsl, the walktraceModuleWgsl({ shapecast })stamps for WGSL hooks). Each hook takesshapefirst when ashapetype is given, then its own arguments.