Picks a 3d object from a view or scene by 3D raycast calculations. Performs an initial coarse boundary calculation to return a subset of entities whose bounding volumes intersect with the specified ray, then triggers an optional picking collider on individual entity objects to further determine the precise values of the picking ray collision.

Constructor

new(findClosestCollision:Bool)

Creates a new RaycastPicker object.

Parameters:

findClosestCollision

Determines whether the picker searches for the closest bounds collision along the ray, or simply returns the first collision encountered Defaults to false.

Variables

Methods

dispose():Void

getEntityCollision(position:Vector3D, direction:Vector3D, entities:Array<Entity>):PickingCollisionVO

getSceneCollision(position:Vector3D, direction:Vector3D, scene:Scene3D):PickingCollisionVO

@inheritDoc

getViewCollision(x:Float, y:Float, view:View3D):PickingCollisionVO

@inheritDoc

setIgnoreList(entities:Array<Entity>):Void