Function aabb3::union [] [src]

pub fn union<'out, 'a, 'b, T>(
    out: &'out mut AABB3<T>,
    a: &'a AABB3<T>,
    b: &'b AABB3<T>
) -> &'out mut AABB3<T> where
    T: Copy + Num

Examples

use aabb3::{self, AABB3};
let mut a = aabb3::new_identity();
let b = aabb3::new([-1, -1, -1], [0, 0, 0]);
let c = aabb3::new([0, 0, 0], [1, 1, 1]);
assert_eq!(
    aabb3::union(&mut a, &b, &c),
    &AABB3{ min: [-1, -1, -1], max: [1, 1, 1] }
);