Function aabb3::expand_point[][src]

pub fn expand_point<'out, T>(
    out: &'out mut AABB3<T>,
    aabb3: &AABB3<T>,
    p: &[T; 3]
) -> &'out mut AABB3<T> where
    T: Clone + PartialOrd

Examples

use aabb3::{self, AABB3};
let mut a = aabb3::new_identity();
let b = aabb3::new([-1.0, -1.0, -1.0], [1.0, 1.0, 1.0]);
assert_eq!(
    aabb3::expand_point(&mut a, &b, &[2.0, 2.0, 2.0]),
    &AABB3{ min: [-1.0, -1.0, -1.0], max: [2.0, 2.0, 2.0] }
);