Skip to main content

Bounds3

Macro Bounds3 

Source
macro_rules! Bounds3 {
    ($x_min:expr, $y_min:expr, $z_min:expr, $x_max:expr, $y_max:expr, $z_max:expr $(,)?) => { ... };
    ($mins:expr, $maxs:expr $(,)?) => { ... };
    () => { ... };
}
Expand description

Bounds3 constructor.

use cvmath::{Bounds3, Point3};

let explicit = cvmath::Bounds3!(1, 2, 3, 4, 5, 6);
let splat = cvmath::Bounds3!(7, 8);
let zero: Bounds3<i32> = cvmath::Bounds3!();

assert_eq!(explicit, Bounds3(Point3(1, 2, 3), Point3(4, 5, 6)));
assert_eq!(splat, Bounds3(Point3(7, 7, 7), Point3(8, 8, 8)));
assert_eq!(zero, Bounds3::ZERO);