Nez.Portable/Utils/Extensions/Vector2Ext.cs
/// <summary>
/// Creates a new <see cref="Vector2"/> that contains a transformation of 2d-vector by the specified <see cref="Matrix"/>.
/// </summary>
/// <param name="position">Source <see cref="Vector2"/>.</param>
/// <param name="matrix">The transformation <see cref="Matrix"/>.</param>
/// <returns>Transformed <see cref="Vector2"/>.</returns>
Creates a new  that contains a transformation of 2d-vector by the specified .
Creates a new that contains a transformation of 2d - vector by the specified .
[MethodImpl(MethodImplOptions.AggressiveInlining)]
        public static Vector2 transform(Vector2 position, Matrix2D matrix)
        {
            return new Vector2(
                (position.X * matrix.M11) + (position.Y * matrix.M21) + matrix.M31,
                (position.X * matrix.M12) + (position.Y * matrix.M22) + matrix.M32);
        }
[ MethodImpl ( MethodImplOptions . AggressiveInlining ) ] public static Vector2 transform ( Vector2 position , Matrix2D matrix ) { return new Vector2 ( ( position . X * matrix . M11 ) + ( position . Y * matrix . M21 ) + matrix . M31 , ( position . X * matrix . M12 ) + ( position . Y * matrix . M22 ) + matrix . M32 ) ; }
Creates a new  that contains a transformation of 2d-vector by the specified .
Creates a new that contains a transformation of 2d - vector by the specified .
None
position
Vector2
None
matrix
Matrix2D
The transformation .
The transformation .