Is it possible to use the Raycaster with a selection box?

I have a GLTF scene where I’ve experimented with the example selection box to select multiple meshes.
However, the results are inaccurate because it picks based on the centroid of each mesh and also gets meshes that are not visible by the camera (viewing one side of a house model selects all the walls in the direction of the box).
I’ve also experimented using the Raycaster, and it works great for picking with the mouse/pointer.
Is there any way to use a selection box or two Vector3 (starting and ending point of the box) with the Raycaster?


Pixel-perfect selection support for SelectionBox was discussed GitHub some time ago. The conclusion was to not add support to it considering the related complexity. Please read the following issue for more details:


Thank you for your prompt response! :slight_smile: