Struct rin_math::Rect [−][src]
Represents a rectangle with operations over it
Fields
pos: Pnt2<T>
width: T
height: T
Implementations
impl<T: Float + BaseNum> Rect<T>
[src]
impl<T: Float + BaseNum> Rect<T>
[src]pub fn aspect_ratio(&self) -> T
[src]
pub fn min_x(&self) -> T
[src]
pub fn max_x(&self) -> T
[src]
pub fn min_y(&self) -> T
[src]
pub fn max_y(&self) -> T
[src]
pub fn max_pos(&self) -> Pnt2<T>
[src]
pub fn min_pos(&self) -> Pnt2<T>
[src]
pub fn overlaps(&self, other: &Rect<T>) -> bool
[src]
pub fn intersection(&self, other: &Rect<T>) -> Rect<T>
[src]
impl<T: BaseNum + Copy> Rect<T>
[src]
impl<T: BaseNum + Copy> Rect<T>
[src]impl<T: BaseNum> Rect<T>
[src]
impl<T: BaseNum> Rect<T>
[src]Trait Implementations
impl<'de, T: BaseNum> Deserialize<'de> for Rect<T> where
T: Deserialize<'de>,
[src]
impl<'de, T: BaseNum> Deserialize<'de> for Rect<T> where
T: Deserialize<'de>,
[src]fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl<T: Float + BaseNum> InsideRect<T> for Rect<T>
[src]
impl<T: Float + BaseNum> InsideRect<T> for Rect<T>
[src]impl<N1, N2> SubsetOf<Rect<N2>> for Rect<N1> where
Pnt2<N2>: SupersetOf<Pnt2<N1>>,
N1: BaseNum,
N2: BaseNum + SupersetOf<N1>,
[src]
impl<N1, N2> SubsetOf<Rect<N2>> for Rect<N1> where
Pnt2<N2>: SupersetOf<Pnt2<N1>>,
N1: BaseNum,
N2: BaseNum + SupersetOf<N1>,
[src]fn is_in_subset(t: &Rect<N2>) -> bool
[src]
fn from_superset_unchecked(t: &Rect<N2>) -> Rect<N1>
[src]
fn to_superset(&self) -> Rect<N2>
[src]
pub fn from_superset(element: &T) -> Option<Self>
[src]
impl<T: Copy + BaseNum> Copy for Rect<T>
[src]
impl<T: BaseNum> StructuralPartialEq for Rect<T>
[src]
Auto Trait Implementations
impl<T> RefUnwindSafe for Rect<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
impl<T> Send for Rect<T> where
T: Send,
T: Send,
impl<T> Sync for Rect<T> where
T: Sync,
T: Sync,
impl<T> Unpin for Rect<T> where
T: Unpin,
T: Unpin,
impl<T> UnwindSafe for Rect<T> where
T: UnwindSafe,
T: UnwindSafe,
Blanket Implementations
impl<T> AsUniform<dyn AsRef<[[f32; 4]; 4]> + 'static> for T where
T: AsRef<[[f32; 4]; 4]>,
[src]
impl<T> AsUniform<dyn AsRef<[[f32; 4]; 4]> + 'static> for T where
T: AsRef<[[f32; 4]; 4]>,
[src]pub fn as_uniform(&self) -> UniformValue
[src]
impl<T> AsUniform<dyn AsRef<[f32; 4]> + 'static> for T where
T: AsRef<[f32; 4]>,
[src]
impl<T> AsUniform<dyn AsRef<[f32; 4]> + 'static> for T where
T: AsRef<[f32; 4]>,
[src]pub fn as_uniform(&self) -> UniformValue
[src]
impl<T> AsUniform<dyn AsRef<[i32; 4]> + 'static> for T where
T: AsRef<[i32; 4]>,
[src]
impl<T> AsUniform<dyn AsRef<[i32; 4]> + 'static> for T where
T: AsRef<[i32; 4]>,
[src]pub fn as_uniform(&self) -> UniformValue
[src]
impl<T> AsUniform<dyn AsRef<[u32; 4]> + 'static> for T where
T: AsRef<[u32; 4]>,
[src]
impl<T> AsUniform<dyn AsRef<[u32; 4]> + 'static> for T where
T: AsRef<[u32; 4]>,
[src]pub fn as_uniform(&self) -> UniformValue
[src]
impl<T> CallHasher for T where
T: Hash,
[src]
impl<T> CallHasher for T where
T: Hash,
[src]impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]pub fn to_subset(&self) -> Option<SS>
[src]
pub fn is_in_subset(&self) -> bool
[src]
pub fn to_subset_unchecked(&self) -> SS
[src]
pub fn from_subset(element: &SS) -> SP
[src]
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]pub fn to_subset(&self) -> Option<SS>
[src]
pub fn is_in_subset(&self) -> bool
[src]
pub fn to_subset_unchecked(&self) -> SS
[src]
pub fn from_subset(element: &SS) -> SP
[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,