pub fn bnd2_union_pnt2(b: &Bounds2f, p: Point2f) -> Bounds2f {
    let p_min: Point2f = Point2f {
        x: b.p_min.x.min(p.x),
        y: b.p_min.y.min(p.y),
    };
    let p_max: Point2f = Point2f {
        x: b.p_max.x.max(p.x),
        y: b.p_max.y.max(p.y),
    };
    Bounds2f { p_min, p_max }
}
/// Given a bounding box and a point, the **bnd2_union_pnt2()**
/// function returns a new bounding box that encompasses that point as
/// well as the original box.
Given a bounding box and a point, the **bnd2_union_pnt2()
function returns a new bounding box that encompasses that point as
well as the original box.
Given a bounding box and a point the ** bnd2_union_pnt2 () function returns a new bounding box that encompasses that point as well as the original box .
pub fn bnd2_union_pnt2(b: &Bounds2f, p: Point2f) -> Bounds2f {
    let p_min: Point2f = Point2f {
        x: b.p_min.x.min(p.x),
        y: b.p_min.y.min(p.y),
    };
    let p_max: Point2f = Point2f {
        x: b.p_max.x.max(p.x),
        y: b.p_max.y.max(p.y),
    };
    Bounds2f { p_min, p_max }
}
pub fn bnd2_union_pnt2 ( b : & Bounds2f , p : Point2f ) -> Bounds2f { let p_min : Point2f = Point2f { x : b . p_min . x . min ( p . x ) , y : b . p_min . y . min ( p . y ) , } ; let p_max : Point2f = Point2f { x : b . p_max . x . max ( p . x ) , y : b . p_max . y . max ( p . y ) , } ; Bounds2f { p_min , p_max } }
Given a bounding box and a point, the **bnd2_union_pnt2()
function returns a new bounding box that encompasses that point as
well as the original box.
Given a bounding box and a point the ** bnd2_union_pnt2 () function returns a new bounding box that encompasses that point as well as the original box .
b
&Bounds2f
p
Point2f