I was trying to figure out raycasting with MeshLine and found that the early exit optimization never gets called when you don't intersect the sphere.
if (raycaster.ray.intersectSphere(sphere, interRay) === false) { return }
Should be:
if (raycaster.ray.intersectSphere(sphere, interRay) === null) { return }
Not really a factor for most cases but for mouseover with a lot of geometry might make a difference.
I was trying to figure out raycasting with MeshLine and found that the early exit optimization never gets called when you don't intersect the sphere.
if (raycaster.ray.intersectSphere(sphere, interRay) === false) { return }
Should be:if (raycaster.ray.intersectSphere(sphere, interRay) === null) { return }
Not really a factor for most cases but for mouseover with a lot of geometry might make a difference.