optimized version ray/bbox intersection for BVH