Struct iron_shapes::transform::Rot90Transform
source · pub struct Rot90Transform {
angle: Angle,
}Expand description
Transformation that consists only of a rotation by a multiple of 90 degrees
around the origin (0, 0).
Fields§
§angle: AngleImplementations§
source§impl Rot90Transform
impl Rot90Transform
sourcepub fn is_unitary(&self) -> bool
pub fn is_unitary(&self) -> bool
This transformation is always unitary. Returns always true.
sourcepub fn transform_point<T: CoordinateType>(&self, p: Point<T>) -> Point<T>
pub fn transform_point<T: CoordinateType>(&self, p: Point<T>) -> Point<T>
Apply the transformation to a single point.
sourcepub fn magnification<T: CoordinateType>(&self) -> T
pub fn magnification<T: CoordinateType>(&self) -> T
Get the magnification of this transformation. Always 1.
sourcepub fn try_magnification<T: CoordinateType>(&self) -> Option<T>
pub fn try_magnification<T: CoordinateType>(&self) -> Option<T>
Get the magnification of this transformation. Always Some(1).
Trait Implementations§
source§impl Clone for Rot90Transform
impl Clone for Rot90Transform
source§fn clone(&self) -> Rot90Transform
fn clone(&self) -> Rot90Transform
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for Rot90Transform
impl Debug for Rot90Transform
source§impl<'de> Deserialize<'de> for Rot90Transform
impl<'de> Deserialize<'de> for Rot90Transform
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Hash for Rot90Transform
impl Hash for Rot90Transform
source§impl PartialEq<Rot90Transform> for Rot90Transform
impl PartialEq<Rot90Transform> for Rot90Transform
source§fn eq(&self, other: &Rot90Transform) -> bool
fn eq(&self, other: &Rot90Transform) -> bool
This method tests for
self and other values to be equal, and is used
by ==.