Matrix Extensions

The Matrix Extensions provide methods to transform a Matrix (Rotate, Scale, Translate, etc...). These are a similar subset of methods originally provided in the System.Windows.Media.Matrix class.

Methods

Methods Return Type Description
HasInverse bool Returns true if the matrix has an inverse.
Multiply(Matrix) Matrix Multiply this matrix to the given matrix and return the result.
Rotate(Matrix, double) Matrix Applies a rotation of the specified angle about the origin of this Matrix structure and returns the result.
RotateAt(Matrix, double, double, double) Matrix Rotates this matrix about the specified point and returns the new result.
Scale(double, double) Matrix Appends the specified scale vector to this Matrix structure and returns the result.
ScaleAt(double, double, double, double) Matrix Scales this Matrix by the specified amount about the specified point and returns the result.
Skew(double, double) Matrix Appends a skew of the specified degrees in the x and y dimensions to this Matrix structure and returns the result.
Translate(double, double) Matrix Translates the matrix by the given amount and returns the result.

Requirements (Windows 10 Device Family)

Device family Universal, 10.0.15063.0 or higher
Namespace Microsoft.Toolkit.Uwp.UI
NuGet package Microsoft.Toolkit.Uwp.UI

API Source Code