Edit

Share via


SKRotationScaleMatrix Struct

Definition

Represents a 2D rotation and uniform scale matrix.

public struct SKRotationScaleMatrix : IEquatable<SkiaSharp.SKRotationScaleMatrix>
Inheritance
SKRotationScaleMatrix
Implements

Remarks

This struct stores rotation as scaled cosine/sine values (SCos and SSin) and translation (TX and TY). Use ToMatrix() to convert to a full SKMatrix.

Constructors

Name Description
SKRotationScaleMatrix(Single, Single, Single, Single)

Creates a new SKRotationScaleMatrix with the specified components.

Fields

Name Description
Empty

Represents an empty matrix with all components set to zero.

Identity

Represents the identity matrix (scale of 1, no rotation, no translation).

Properties

Name Description
SCos

Gets or sets the scaled cosine component (scale * cos(angle)).

SSin

Gets or sets the scaled sine component (scale * sin(angle)).

TX

Gets or sets the x-axis translation component.

TY

Gets or sets the y-axis translation component.

Methods

Name Description
Create(Single, Single, Single, Single, Single, Single)

Creates a rotation-scale matrix with the specified scale, rotation (in radians), translation, and anchor point.

CreateDegrees(Single, Single, Single, Single, Single, Single)

Creates a rotation-scale matrix with the specified scale, rotation (in degrees), translation, and anchor point.

CreateIdentity()

Creates an identity matrix that represents no transformation.

CreateRotation(Single, Single, Single)

Creates a rotation matrix with the specified angle (in radians) around an anchor point.

CreateRotationDegrees(Single, Single, Single)

Creates a rotation matrix with the specified angle (in degrees) around an anchor point.

CreateScale(Single)

Creates a uniform scale matrix with no rotation or translation.

CreateTranslation(Single, Single)

Creates a translation matrix with no rotation or scale.

Equals(Object)

Determines whether the specified object is equal to the current instance.

Equals(SKRotationScaleMatrix)

Determines whether the specified SKRotationScaleMatrix is equal to the current instance.

GetHashCode()

Returns the hash code for this instance.

ToMatrix()

Converts this rotation-scale matrix to a full 3x3 transformation matrix.

Operators

Name Description
Equality(SKRotationScaleMatrix, SKRotationScaleMatrix)

Determines whether two SKRotationScaleMatrix instances are equal.

Inequality(SKRotationScaleMatrix, SKRotationScaleMatrix)

Determines whether two SKRotationScaleMatrix instances are not equal.

Applies to