pub struct Region {
pub from: Pos,
pub to: Pos,
}Expand description
A region in global space
Fields§
§from: PosThe starting position of the region
to: PosThe end position of the region
Implementations§
Source§impl Region
impl Region
Sourcepub const fn intersects(&self, other: &Region) -> bool
pub const fn intersects(&self, other: &Region) -> bool
Check if another region is intersecting with this region
Sourcepub fn intersect_with(self, other: &Region) -> Self
pub fn intersect_with(self, other: &Region) -> Self
Create a new region by intersecting two regions
Trait Implementations§
impl Copy for Region
impl StructuralPartialEq for Region
Auto Trait Implementations§
impl Freeze for Region
impl RefUnwindSafe for Region
impl Send for Region
impl Sync for Region
impl Unpin for Region
impl UnsafeUnpin for Region
impl UnwindSafe for Region
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more