[−][src]Enum rlifesrc_lib::Transform
Transformations (rotations and reflections) after the last generation.
After the last generation, the pattern will return to
the first generation, applying this transformation first,
and then the translation defined by dx
and dy
.
8 different values corresponds to 8 elements of the dihedral group D8.
Id
is the identity transformation.
R
means rotations around the center of the world.
The number after it is the counterclockwise rotation angle in degrees.
F
means reflections (flips).
The symbol after it is the axis of reflection.
Some of the transformations are only valid when the world is square.
Variants
Id
.
Identity transformation.
R90
.
90° rotation counterclockwise.
R180
.
180° rotation counterclockwise.
R270
.
270° rotation counterclockwise.
F-
.
Reflection across the middle row.
F|
.
Reflection across the middle column.
F\
.
Reflection across the diagonal.
F/
.
Reflection across the antidiagonal.
Methods
impl Transform
[src]
pub fn square_world(self) -> bool
[src]
Whether the transformation requires the world to be square.
Returns true
for R90
, R270
, F\
and F/
.
Trait Implementations
impl Clone for Transform
[src]
impl Copy for Transform
[src]
impl Default for Transform
[src]
impl Eq for Transform
[src]
impl PartialEq<Transform> for Transform
[src]
impl Debug for Transform
[src]
impl FromStr for Transform
[src]
type Err = String
The associated error which can be returned from parsing.
fn from_str(s: &str) -> Result<Self, Self::Err>
[src]
impl StructuralPartialEq for Transform
[src]
impl StructuralEq for Transform
[src]
Auto Trait Implementations
impl Send for Transform
impl Sync for Transform
impl Unpin for Transform
impl UnwindSafe for Transform
impl RefUnwindSafe for Transform
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,