Skip to main content

ray_aabb

Function ray_aabb 

Source
pub fn ray_aabb(
    origin: [f64; 3],
    dir: [f64; 3],
    min: [f64; 3],
    max: [f64; 3],
) -> Option<(f64, f64)>
Expand description

Ray-box intersection by the slab method: (t_near, t_far) with t_far >= max(t_near, 0).