diff --git a/src/ComputeSharp.Core/Primitives/Float/FloatMxN.cs.cs b/src/ComputeSharp.Core/Primitives/Float/FloatMxN.cs.cs new file mode 100644 index 00000000..996e5e11 --- /dev/null +++ b/src/ComputeSharp.Core/Primitives/Float/FloatMxN.cs.cs @@ -0,0 +1,37 @@ +using System.Numerics; + +#pragma warning disable CS0660, CS0661 + +namespace ComputeSharp; + +/// +partial struct Float3x2 +{ + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static unsafe implicit operator Matrix3x2(Float3x2 xy) => *(Matrix3x2*)&xy; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static unsafe implicit operator Float3x2(Matrix3x2 xy) => *(Float3x2*)&xy; +} + +/// +partial struct Float4x4 +{ + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static unsafe implicit operator Matrix4x4(Float4x4 xy) => *(Matrix4x4*)&xy; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static unsafe implicit operator Float4x4(Matrix4x4 xy) => *(Float4x4*)&xy; +} \ No newline at end of file