diff --git a/src/ComputeSharp.Core/Primitives/Double/DoubleMxN.g.cs b/src/ComputeSharp.Core/Primitives/Double/DoubleMxN.g.cs index bbbdbc4e..6b41e7b1 100644 --- a/src/ComputeSharp.Core/Primitives/Double/DoubleMxN.g.cs +++ b/src/ComputeSharp.Core/Primitives/Double/DoubleMxN.g.cs @@ -90,6 +90,27 @@ public unsafe partial struct Double1x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float1x1(Double1x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x1(Double1x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x1(Double1x1 matrix) => default; + /// /// Negates a value. /// @@ -294,6 +315,27 @@ public unsafe partial struct Double1x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float1x2(Double1x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x2(Double1x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x2(Double1x2 matrix) => default; + /// /// Negates a value. /// @@ -516,6 +558,27 @@ public unsafe partial struct Double1x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float1x3(Double1x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x3(Double1x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x3(Double1x3 matrix) => default; + /// /// Negates a value. /// @@ -750,6 +813,27 @@ public unsafe partial struct Double1x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float1x4(Double1x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x4(Double1x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x4(Double1x4 matrix) => default; + /// /// Negates a value. /// @@ -960,6 +1044,27 @@ public unsafe partial struct Double2x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float2x1(Double2x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x1(Double2x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x1(Double2x1 matrix) => default; + /// /// Negates a value. /// @@ -1207,6 +1312,27 @@ public unsafe partial struct Double2x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float2x2(Double2x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x2(Double2x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x2(Double2x2 matrix) => default; + /// /// Negates a value. /// @@ -1474,6 +1600,27 @@ public unsafe partial struct Double2x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float2x3(Double2x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x3(Double2x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x3(Double2x3 matrix) => default; + /// /// Negates a value. /// @@ -1767,6 +1914,27 @@ public unsafe partial struct Double2x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float2x4(Double2x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x4(Double2x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x4(Double2x4 matrix) => default; + /// /// Negates a value. /// @@ -1983,6 +2151,27 @@ public unsafe partial struct Double3x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float3x1(Double3x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x1(Double3x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x1(Double3x1 matrix) => default; + /// /// Negates a value. /// @@ -2257,6 +2446,27 @@ public unsafe partial struct Double3x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float3x2(Double3x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x2(Double3x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x2(Double3x2 matrix) => default; + /// /// Negates a value. /// @@ -2564,6 +2774,27 @@ public unsafe partial struct Double3x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float3x3(Double3x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x3(Double3x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x3(Double3x3 matrix) => default; + /// /// Negates a value. /// @@ -2910,6 +3141,27 @@ public unsafe partial struct Double3x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float3x4(Double3x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x4(Double3x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x4(Double3x4 matrix) => default; + /// /// Negates a value. /// @@ -3138,6 +3390,27 @@ public unsafe partial struct Double4x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float4x1(Double4x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x1(Double4x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x1(Double4x1 matrix) => default; + /// /// Negates a value. /// @@ -3439,6 +3712,27 @@ public unsafe partial struct Double4x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float4x2(Double4x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x2(Double4x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x2(Double4x2 matrix) => default; + /// /// Negates a value. /// @@ -3786,6 +4080,27 @@ public unsafe partial struct Double4x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float4x3(Double4x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x3(Double4x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x3(Double4x3 matrix) => default; + /// /// Negates a value. /// @@ -4185,6 +4500,27 @@ public unsafe partial struct Double4x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Float4x4(Double4x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x4(Double4x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x4(Double4x4 matrix) => default; + /// /// Negates a value. /// diff --git a/src/ComputeSharp.Core/Primitives/Float/FloatMxN.g.cs b/src/ComputeSharp.Core/Primitives/Float/FloatMxN.g.cs index b0d4095b..982f252a 100644 --- a/src/ComputeSharp.Core/Primitives/Float/FloatMxN.g.cs +++ b/src/ComputeSharp.Core/Primitives/Float/FloatMxN.g.cs @@ -91,6 +91,27 @@ public unsafe partial struct Float1x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x1(Float1x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x1(Float1x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x1(Float1x1 matrix) => default; + /// /// Negates a value. /// @@ -313,6 +334,27 @@ public unsafe partial struct Float1x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x2(Float1x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x2(Float1x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x2(Float1x2 matrix) => default; + /// /// Negates a value. /// @@ -637,6 +679,27 @@ public unsafe partial struct Float1x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x3(Float1x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x3(Float1x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x3(Float1x3 matrix) => default; + /// /// Negates a value. /// @@ -973,6 +1036,27 @@ public unsafe partial struct Float1x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x4(Float1x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x4(Float1x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x4(Float1x4 matrix) => default; + /// /// Negates a value. /// @@ -1285,6 +1369,27 @@ public unsafe partial struct Float2x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x1(Float2x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x1(Float2x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x1(Float2x1 matrix) => default; + /// /// Negates a value. /// @@ -1620,6 +1725,27 @@ public unsafe partial struct Float2x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x2(Float2x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x2(Float2x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x2(Float2x2 matrix) => default; + /// /// Negates a value. /// @@ -1905,6 +2031,27 @@ public unsafe partial struct Float2x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x3(Float2x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x3(Float2x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x3(Float2x3 matrix) => default; + /// /// Negates a value. /// @@ -2300,6 +2447,27 @@ public unsafe partial struct Float2x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x4(Float2x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x4(Float2x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x4(Float2x4 matrix) => default; + /// /// Negates a value. /// @@ -2618,6 +2786,27 @@ public unsafe partial struct Float3x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x1(Float3x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x1(Float3x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x1(Float3x1 matrix) => default; + /// /// Negates a value. /// @@ -2980,6 +3169,27 @@ public unsafe partial struct Float3x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x2(Float3x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x2(Float3x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x2(Float3x2 matrix) => default; + /// /// Negates a value. /// @@ -3389,6 +3599,27 @@ public unsafe partial struct Float3x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x3(Float3x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x3(Float3x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x3(Float3x3 matrix) => default; + /// /// Negates a value. /// @@ -3753,6 +3984,27 @@ public unsafe partial struct Float3x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x4(Float3x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x4(Float3x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x4(Float3x4 matrix) => default; + /// /// Negates a value. /// @@ -4083,6 +4335,27 @@ public unsafe partial struct Float4x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x1(Float4x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x1(Float4x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x1(Float4x1 matrix) => default; + /// /// Negates a value. /// @@ -4472,6 +4745,27 @@ public unsafe partial struct Float4x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x2(Float4x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x2(Float4x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x2(Float4x2 matrix) => default; + /// /// Negates a value. /// @@ -4921,6 +5215,27 @@ public unsafe partial struct Float4x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x3(Float4x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x3(Float4x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x3(Float4x3 matrix) => default; + /// /// Negates a value. /// @@ -5422,6 +5737,27 @@ public unsafe partial struct Float4x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x4(Float4x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x4(Float4x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x4(Float4x4 matrix) => default; + /// /// Negates a value. /// diff --git a/src/ComputeSharp.Core/Primitives/Int/IntMxN.g.cs b/src/ComputeSharp.Core/Primitives/Int/IntMxN.g.cs index 3748c882..b2bfe7ef 100644 --- a/src/ComputeSharp.Core/Primitives/Int/IntMxN.g.cs +++ b/src/ComputeSharp.Core/Primitives/Int/IntMxN.g.cs @@ -91,6 +91,27 @@ public unsafe partial struct Int1x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float1x1(Int1x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x1(Int1x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x1(Int1x1 matrix) => default; + /// /// Negates a value. /// @@ -411,6 +432,27 @@ public unsafe partial struct Int1x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float1x2(Int1x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x2(Int1x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x2(Int1x2 matrix) => default; + /// /// Negates a value. /// @@ -833,6 +875,27 @@ public unsafe partial struct Int1x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float1x3(Int1x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x3(Int1x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x3(Int1x3 matrix) => default; + /// /// Negates a value. /// @@ -1267,6 +1330,27 @@ public unsafe partial struct Int1x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float1x4(Int1x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x4(Int1x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt1x4(Int1x4 matrix) => default; + /// /// Negates a value. /// @@ -1677,6 +1761,27 @@ public unsafe partial struct Int2x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float2x1(Int2x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x1(Int2x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x1(Int2x1 matrix) => default; + /// /// Negates a value. /// @@ -2110,6 +2215,27 @@ public unsafe partial struct Int2x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float2x2(Int2x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x2(Int2x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x2(Int2x2 matrix) => default; + /// /// Negates a value. /// @@ -2493,6 +2619,27 @@ public unsafe partial struct Int2x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float2x3(Int2x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x3(Int2x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x3(Int2x3 matrix) => default; + /// /// Negates a value. /// @@ -2986,6 +3133,27 @@ public unsafe partial struct Int2x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float2x4(Int2x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x4(Int2x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt2x4(Int2x4 matrix) => default; + /// /// Negates a value. /// @@ -3402,6 +3570,27 @@ public unsafe partial struct Int3x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float3x1(Int3x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x1(Int3x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x1(Int3x1 matrix) => default; + /// /// Negates a value. /// @@ -3862,6 +4051,27 @@ public unsafe partial struct Int3x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float3x2(Int3x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x2(Int3x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x2(Int3x2 matrix) => default; + /// /// Negates a value. /// @@ -4369,6 +4579,27 @@ public unsafe partial struct Int3x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float3x3(Int3x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x3(Int3x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x3(Int3x3 matrix) => default; + /// /// Negates a value. /// @@ -4831,6 +5062,27 @@ public unsafe partial struct Int3x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float3x4(Int3x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x4(Int3x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt3x4(Int3x4 matrix) => default; + /// /// Negates a value. /// @@ -5259,6 +5511,27 @@ public unsafe partial struct Int4x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float4x1(Int4x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x1(Int4x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x1(Int4x1 matrix) => default; + /// /// Negates a value. /// @@ -5746,6 +6019,27 @@ public unsafe partial struct Int4x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float4x2(Int4x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x2(Int4x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x2(Int4x2 matrix) => default; + /// /// Negates a value. /// @@ -6293,6 +6587,27 @@ public unsafe partial struct Int4x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float4x3(Int4x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x3(Int4x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x3(Int4x3 matrix) => default; + /// /// Negates a value. /// @@ -6892,6 +7207,27 @@ public unsafe partial struct Int4x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float4x4(Int4x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x4(Int4x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator UInt4x4(Int4x4 matrix) => default; + /// /// Negates a value. /// diff --git a/src/ComputeSharp.Core/Primitives/MatrixType.ttinclude b/src/ComputeSharp.Core/Primitives/MatrixType.ttinclude index 01ae50f5..089843f6 100644 --- a/src/ComputeSharp.Core/Primitives/MatrixType.ttinclude +++ b/src/ComputeSharp.Core/Primitives/MatrixType.ttinclude @@ -255,6 +255,30 @@ public unsafe partial struct <#=fullTypeName#> WriteLine("}"); PopIndent(); + // Generate the cast operators, when applicable + foreach (string targetType in new[] { "Float", "Double", "Int", "UInt" }) + { + if (typeName != "Bool" && typeName != targetType) + { + WriteLine(""); + + bool isImplicit = + (typeName == "Float" && targetType == "Double") || + (typeName == "Int" && targetType == "Float") || + (typeName == "Int" && targetType == "Double") || + (typeName == "UInt" && targetType == "Float") || + (typeName == "UInt" && targetType == "Double"); +#> + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static <#=isImplicit ? "implicit" : "explicit"#> operator <#=targetType#><#=rows#>x<#=columns#>(<#=fullTypeName#> matrix) => default; +<# + } + } + // Generate the negation operator if (typeName != "UInt") { diff --git a/src/ComputeSharp.Core/Primitives/UInt/UIntMxN.g.cs b/src/ComputeSharp.Core/Primitives/UInt/UIntMxN.g.cs index e1b1bed9..2411e3fc 100644 --- a/src/ComputeSharp.Core/Primitives/UInt/UIntMxN.g.cs +++ b/src/ComputeSharp.Core/Primitives/UInt/UIntMxN.g.cs @@ -90,6 +90,27 @@ public unsafe partial struct UInt1x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float1x1(UInt1x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x1(UInt1x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x1(UInt1x1 matrix) => default; + /// /// Sums two values. /// @@ -385,6 +406,27 @@ public unsafe partial struct UInt1x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float1x2(UInt1x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x2(UInt1x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x2(UInt1x2 matrix) => default; + /// /// Sums two values. /// @@ -698,6 +740,27 @@ public unsafe partial struct UInt1x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float1x3(UInt1x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x3(UInt1x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x3(UInt1x3 matrix) => default; + /// /// Sums two values. /// @@ -1023,6 +1086,27 @@ public unsafe partial struct UInt1x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float1x4(UInt1x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double1x4(UInt1x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int1x4(UInt1x4 matrix) => default; + /// /// Sums two values. /// @@ -1324,6 +1408,27 @@ public unsafe partial struct UInt2x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float2x1(UInt2x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x1(UInt2x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x1(UInt2x1 matrix) => default; + /// /// Sums two values. /// @@ -1662,6 +1767,27 @@ public unsafe partial struct UInt2x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float2x2(UInt2x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x2(UInt2x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x2(UInt2x2 matrix) => default; + /// /// Sums two values. /// @@ -2020,6 +2146,27 @@ public unsafe partial struct UInt2x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float2x3(UInt2x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x3(UInt2x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x3(UInt2x3 matrix) => default; + /// /// Sums two values. /// @@ -2404,6 +2551,27 @@ public unsafe partial struct UInt2x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float2x4(UInt2x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double2x4(UInt2x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int2x4(UInt2x4 matrix) => default; + /// /// Sums two values. /// @@ -2711,6 +2879,27 @@ public unsafe partial struct UInt3x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float3x1(UInt3x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x1(UInt3x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x1(UInt3x1 matrix) => default; + /// /// Sums two values. /// @@ -3076,6 +3265,27 @@ public unsafe partial struct UInt3x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float3x2(UInt3x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x2(UInt3x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x2(UInt3x2 matrix) => default; + /// /// Sums two values. /// @@ -3474,6 +3684,27 @@ public unsafe partial struct UInt3x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float3x3(UInt3x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x3(UInt3x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x3(UInt3x3 matrix) => default; + /// /// Sums two values. /// @@ -3911,6 +4142,27 @@ public unsafe partial struct UInt3x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float3x4(UInt3x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double3x4(UInt3x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int3x4(UInt3x4 matrix) => default; + /// /// Sums two values. /// @@ -4230,6 +4482,27 @@ public unsafe partial struct UInt4x1 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float4x1(UInt4x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x1(UInt4x1 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x1(UInt4x1 matrix) => default; + /// /// Sums two values. /// @@ -4622,6 +4895,27 @@ public unsafe partial struct UInt4x2 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float4x2(UInt4x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x2(UInt4x2 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x2(UInt4x2 matrix) => default; + /// /// Sums two values. /// @@ -5060,6 +5354,27 @@ public unsafe partial struct UInt4x3 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float4x3(UInt4x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x3(UInt4x3 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x3(UInt4x3 matrix) => default; + /// /// Sums two values. /// @@ -5550,6 +5865,27 @@ public unsafe partial struct UInt4x4 return matrix; } + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Float4x4(UInt4x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static implicit operator Double4x4(UInt4x4 matrix) => default; + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + /// This method is an intrinsic and can only be used within a shader on the GPU. Using it on the CPU is undefined behavior. + public static explicit operator Int4x4(UInt4x4 matrix) => default; + /// /// Sums two values. ///