Struct UVTransform
- Namespace
- HelixToolkit.SharpDX
- Assembly
- HelixToolkit.SharpDX.dll
2D UV Transform
public struct UVTransform
- Inherited Members
- Extension Methods
Constructors
UVTransform(Vector2)
Initializes a new instance of the UVTransform struct.
public UVTransform(Vector2 translation)
Parameters
translationVector2The translation.
UVTransform(float)
Initializes a new instance of the UVTransform struct.
public UVTransform(float rotation)
Parameters
rotationfloatThe rotation.
UVTransform(float, Vector2, Vector2)
Initializes a new instance of the UVTransform struct.
public UVTransform(float rotation, Vector2 scaling, Vector2 translation)
Parameters
UVTransform(float, float, float, float, float)
Initializes a new instance of the UVTransform struct.
public UVTransform(float rotation, float scalingX = 1, float scalingY = 1, float translationX = 0, float translationY = 0)
Parameters
rotationfloatThe rotation.
scalingXfloatThe scaling x.
scalingYfloatThe scaling y.
translationXfloatThe translation x.
translationYfloatThe translation y.
Fields
Identity
public static readonly UVTransform Identity
Field Value
Rotation
The rotation by radian
public float Rotation
Field Value
Scaling
The scaling
public Vector2 Scaling
Field Value
Translation
The translation
public Vector2 Translation
Field Value
Properties
HasUVTransform
Gets a value indicating whether this instance has uv transform.
public bool HasUVTransform { get; }
Property Value
- bool
trueif this instance has uv transform; otherwise,false.
Methods
ToArray()
public float[] ToArray()
Returns
- float[]
Operators
implicit operator Matrix4x4(UVTransform)
Performs an implicit conversion from UVTransform to Matrix4x4.
public static implicit operator Matrix4x4(UVTransform uvTransform)
Parameters
uvTransformUVTransformThe uv transform.
Returns
- Matrix4x4
The result of the conversion.
implicit operator UVTransform(Matrix4x4)
Performs an implicit conversion from Matrix4x4 to UVTransform.
public static implicit operator UVTransform(Matrix4x4 matrix)
Parameters
matrixMatrix4x4The matrix.
Returns
- UVTransform
The result of the conversion.