Struct shape_core::Triangle
source · [−]Fields
vertex: [Point<T>; 3]
Implementations
sourceimpl<T> Triangle<T> where
T: Clone + Real,
impl<T> Triangle<T> where
T: Clone + Real,
pub fn is_valid(&self) -> bool
pub fn is_congruent(&self) -> bool
pub fn is_isosceles(&self) -> bool
pub fn perimeter(&self) -> T
sourcepub fn inscribed_circle(&self) -> Circle<T>
pub fn inscribed_circle(&self) -> Circle<T>
Get the inscribed circle of the triangle
sourcepub fn circumscribed_circle(&self) -> Circle<T>
pub fn circumscribed_circle(&self) -> Circle<T>
Get the circumscribed circle of the triangle.
Trait Implementations
sourceimpl<T> Projective<T> for Triangle<T> where
T: Float,
impl<T> Projective<T> for Triangle<T> where
T: Float,
sourcefn translate_x(&mut self, x: &T)
fn translate_x(&mut self, x: &T)
Transform by length $\delta x$. Read more
sourcefn translate_y(&mut self, y: &T)
fn translate_y(&mut self, y: &T)
Transform by length $\delta y$. Read more
sourceimpl<T, P> TryFrom<(P, P, P)> for Triangle<T> where
Point<T>: From<P>,
T: Num + Clone + PartialOrd,
impl<T, P> TryFrom<(P, P, P)> for Triangle<T> where
Point<T>: From<P>,
T: Num + Clone + PartialOrd,
sourceimpl<T> ValidShape<T> for Triangle<T> where
T: Num + PartialOrd + Clone,
impl<T> ValidShape<T> for Triangle<T> where
T: Num + PartialOrd + Clone,
Auto Trait Implementations
impl<T> RefUnwindSafe for Triangle<T> where
T: RefUnwindSafe,
impl<T> Send for Triangle<T> where
T: Send,
impl<T> Sync for Triangle<T> where
T: Sync,
impl<T> Unpin for Triangle<T> where
T: Unpin,
impl<T> UnwindSafe for Triangle<T> where
T: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more