Struct nalgebra::Similarity2 [] [src]

pub struct Similarity2<N> {
    pub isometry: Isometry2<N>,
    // some fields omitted
}

A two-dimensional similarity transformation.

This is a composition of a uniform scale, followed by a rotation, followed by a translation. Vectors Vector2 are not affected by the translational component of this transformation while points Point2 are. Similarity transformations conserve angles. Distances are multiplied by some constant (the scale factor). The scale factor cannot be zero.

Fields

The isometry applicable by this similarity transformation.

Methods

impl<N: BaseFloat> Similarity2<N>
[src]

Creates a new similarity transformation from a vector, an axis-angle rotation, and a scale factor.

The scale factor may be negative but not zero.

Creates a new similarity transformation from a rotation matrix, a vector, and a scale factor.

The scale factor may be negative but not zero.

Creates a new similarity transformation from an isometry and a scale factor.

The scale factor may be negative but not zero.

The scale factor of this similarity transformation.

The inverse scale factor of this similarity transformation.

Appends in-place a scale to this similarity transformation.

Appends a scale to this similarity transformation.

Prepends in-place a scale to this similarity transformation.

Prepends a scale to this similarity transformation.

Sets the scale of this similarity transformation.

Trait Implementations

impl<N: Copy> Copy for Similarity2<N>
[src]

impl<N: Debug> Debug for Similarity2<N>
[src]

Formats the value using the given formatter.

impl<N: Clone> Clone for Similarity2<N>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<N: Decodable> Decodable for Similarity2<N>
[src]

impl<N: Encodable> Encodable for Similarity2<N>
[src]

impl<N: PartialEq> PartialEq for Similarity2<N>
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

impl<N: Eq> Eq for Similarity2<N>
[src]

impl<N: BaseFloat> One for Similarity2<N>
[src]

Returns the multiplicative identity element of Self, 1. Read more

impl<N: BaseFloat> Transformation<Similarity2<N>> for Similarity2<N>
[src]

Gets the transformation of self.

Gets the inverse transformation of self.

Appends a transformation to this object.

Appends the transformation amount to a copy of t.

Prepends a transformation to this object.

Prepends the transformation amount to a copy of t.

Sets the transformation of self.

impl<N: BaseFloat> Mul<Similarity2<N>> for Similarity2<N>
[src]

The resulting type after applying the * operator

The method for the * operator

impl<N: BaseFloat> MulAssign<Similarity2<N>> for Similarity2<N>
[src]

The method for the *= operator

impl<N: BaseFloat> Mul<Isometry2<N>> for Similarity2<N>
[src]

The resulting type after applying the * operator

The method for the * operator

impl<N: BaseFloat> MulAssign<Isometry2<N>> for Similarity2<N>
[src]

The method for the *= operator

impl<N: BaseFloat> Mul<Rotation2<N>> for Similarity2<N>
[src]

The resulting type after applying the * operator

The method for the * operator

impl<N: BaseFloat> MulAssign<Rotation2<N>> for Similarity2<N>
[src]

The method for the *= operator

impl<N: BaseNum> Mul<Vector2<N>> for Similarity2<N>
[src]

The resulting type after applying the * operator

The method for the * operator

impl<N: BaseNum> Mul<Point2<N>> for Similarity2<N>
[src]

The resulting type after applying the * operator

The method for the * operator

impl<N: BaseNum> Transform<Point2<N>> for Similarity2<N>
[src]

Applies a transformation to v.

Applies an inverse transformation to v.

impl<N: BaseNum + Neg<Output=N>> Inverse for Similarity2<N>
[src]

In-place version of inverse.

Returns the inverse of m.

impl<N: BaseNum> ToHomogeneous<Matrix3<N>> for Similarity2<N>
[src]

Gets the homogeneous coordinates form of this object.

impl<N: ApproxEq<N>> ApproxEq<N> for Similarity2<N>
[src]

Default epsilon for approximation.

Default ULPs for approximation.

Tests approximate equality using a custom epsilon.

Tests approximate equality using units in the last place (ULPs)

Tests approximate equality.

impl<N: Rand + BaseFloat> Rand for Similarity2<N>
[src]

Generates a random instance of this type using the specified source of randomness. Read more

impl<N: Display + BaseFloat> Display for Similarity2<N>
[src]

Formats the value using the given formatter.

impl<N> Dimension for Similarity2<N>
[src]

The dimension of the object.