diff --git a/README.md b/README.md index c53c9b43..4e2dc0b4 100644 --- a/README.md +++ b/README.md @@ -11,6 +11,7 @@ - [Quick start](#quick-start) - [Capturing variables](#capturing-variables) - [GPU resource types](#gpu-resource-types) + - [HLSL vector and matrix types](#hlsl-vector-and-matrix-types) - [HLSL intrinsics](#hlsl-intrinsics) - [Working with images](#working-with-images) - [Shader metaprogramming](#shader-metaprogramming) @@ -83,6 +84,8 @@ Shaders can store either GPU resources or custom values in their fields, so that ✅ HLSL types: `Bool`, `Bool2`, `Bool3`, `Bool4`, `Float2`, `Float3`, `Float4`, `Int2`, `Int3`, `Int4`, `UInt2`, `Uint3`, etc. +✅ HLSL matrix types: `Float2x2`, `Float3x3`, `Float3x4`, `Float4x4`, `Float1x4`, `Float4x`, etc. + ✅ Custom `struct` types containing any of the types above, as well as other valid custom `struct` types ## GPU resource types @@ -102,6 +105,27 @@ There are a number of extension APIs for the `GraphicsDevice` class that can be > **NOTE:** although the various APIs to allocate buffers are simply generic methods with a `T : unmanaged` constrain, they should only be used with C# types that are supported (see notes above). Additionally, the `bool` type should not be used in buffers due to C#/HLSL differences: use the `Bool` type instead (or just an `int` buffer). +## HLSL vector and matrix types + +As mentioned in the [Capturing variables](#capturing-variables) paragraph, **ComputeSharp** also exposes matrix types that can be used in compute shaders. These values store individual component values in row-major order (for consistency with .NET arrays) and can be indexed in several ways just like with HLSL vector types. One noticeable difference compared to HLSL vector types though is the lack of explicit properties to extract swizzled vectors (eg. `Float4.XZY` returns a `Float3` value with the `X`, `Z` and `Y` components). Due to the number of possible combinations being simply too high in the case of matrix types (eg. `Float4x4` alone would have had over 160k properties), the ability to extract swizzled vectors ([see here](https://docs.microsoft.com/windows/win32/direct3dhlsl/dx-graphics-hlsl-per-component-math)) can be achieved through the use of a special indexer property and values from the `MatrixIndex` type. Here is how it can be used: + +```csharp +Float4x4 matrix = default; + +// Standard indexer for rows and individual items +Float4 row = matrix[0]; +float item = matrix[0][1]; + +// Swizzled indexers, which can be made less verbose to +// write by adding this using static directive to the file +using static ComputeSharp.MatrixIndex; + +Float4 diagonal = matrix[M11, M22, M33, M44]; +Float4 vertices = matrix[M11, M14, M44, M41]; +``` + +Matrix types also include a number of built-in operators to work with vector types, and the `Hlsl` class detailed below (see [HLSL intrinsics](#hlsl-intrinsics)) also includes several overloads for the available methods to work on both matrix and vector types at the same time (eg. for row/matrix multiplication). + ## HLSL intrinsics **ComputeSharp** offers support for all HLSL intrinsics that can be used from compute shaders. These are special functions (usually representing mathematical operations) that are optimized on the GPU and can execute very efficiently. Some of them can be mapped automatically from methods in the `System.Math` type (such as `Math.Sin` and `Math.Cos`), but if you want to have direct access to all of them you can just use the methods in the `Hlsl` class from a compute shader, and **ComputeSharp** will rewrite all those calls to use the native intrinsics in the compute shaders where those are used. diff --git a/global.json b/global.json index 2cb2ac9b..9685cb85 100644 --- a/global.json +++ b/global.json @@ -1,5 +1,5 @@ { "sdk": { - "version": "5.0.100" + "version": "5.0.x" } } \ No newline at end of file diff --git a/samples/ComputeSharp.SwapChain/Program.cs b/samples/ComputeSharp.SwapChain/Program.cs index 4fd79340..3e0d87df 100644 --- a/samples/ComputeSharp.SwapChain/Program.cs +++ b/samples/ComputeSharp.SwapChain/Program.cs @@ -14,7 +14,9 @@ namespace ComputeSharp.SwapChain new SwapChainApplication(static (texture, time) => new(texture, (float)time.TotalSeconds)), new SwapChainApplication(static (texture, time) => new(texture, (float)time.TotalSeconds)), new SwapChainApplication(static (texture, time) => new(texture, (float)time.TotalSeconds)), - new SwapChainApplication(static (texture, time) => new(texture, (float)time.TotalSeconds)) + new SwapChainApplication(static (texture, time) => new(texture, (float)time.TotalSeconds)), + new SwapChainApplication(static (texture, time) => new(texture, (float)time.TotalSeconds)), + new SwapChainApplication(static (texture, time) => new(texture, (float)time.TotalSeconds)) }; static void Main() diff --git a/samples/ComputeSharp.SwapChain/Shaders/Octagrams.cs b/samples/ComputeSharp.SwapChain/Shaders/Octagrams.cs new file mode 100644 index 00000000..dfd79d8b --- /dev/null +++ b/samples/ComputeSharp.SwapChain/Shaders/Octagrams.cs @@ -0,0 +1,129 @@ +namespace ComputeSharp.SwapChain.Shaders +{ + /// + /// A shader creating an octagram animation, inspired by arabesque. + /// Ported from . + /// Created by whisky_shusuky. + /// + [AutoConstructor] + internal readonly partial struct Octagrams : IComputeShader + { + /// + /// The target texture. + /// + public readonly IReadWriteTexture2D texture; + + /// + /// The current time since the start of the application. + /// + public readonly float time; + + private static Float2x2 Rotate(float a) + { + float c = Hlsl.Cos(a), s = Hlsl.Sin(a); + + return new(c, s, -s, c); + } + + private static float Box(Float3 pos, float scale) + { + static float SDBox(Float3 p, Float3 b) + { + Float3 q = Hlsl.Abs(p) - b; + + return Hlsl.Length(Hlsl.Max(q, 0.0f)) + + Hlsl.Min(Hlsl.Max(q.X, Hlsl.Max(q.Y, q.Z)), 0.0f); + } + + pos *= scale; + + float b = SDBox(pos, new(0.4f, 0.4f, 0.1f)) / 1.5f; + + pos.XY *= 5.0f; + pos.Y -= 3.5f; + pos.XY = Hlsl.Mul(pos.XY, Rotate(0.75f)); + + return -b; + } + + private static float BoxSet(Float3 pos, float gTime) + { + Float3 pos_origin = pos; + + pos = pos_origin; + pos.Y += Hlsl.Sin(gTime * 0.4f) * 2.5f; + pos.XY = Hlsl.Mul(pos.XY, Rotate(0.8f)); + + float box1 = Box(pos, 2.0f - Hlsl.Abs(Hlsl.Sin(gTime * 0.4f)) * 1.5f); + + pos = pos_origin; + pos.Y -= Hlsl.Sin(gTime * 0.4f) * 2.5f; + pos.XY = Hlsl.Mul(pos.XY, Rotate(0.8f)); + + float box2 = Box(pos, 2.0f - Hlsl.Abs(Hlsl.Sin(gTime * 0.4f)) * 1.5f); + + pos = pos_origin; + pos.X += Hlsl.Sin(gTime * 0.4f) * 2.5f; + pos.XY = Hlsl.Mul(pos.XY, Rotate(0.8f)); + + float box3 = Box(pos, 2.0f - Hlsl.Abs(Hlsl.Sin(gTime * 0.4f)) * 1.5f); + + pos = pos_origin; + pos.X -= Hlsl.Sin(gTime * 0.4f) * 2.5f; + pos.XY = Hlsl.Mul(pos.XY, Rotate(0.8f)); + + float box4 = Box(pos, 2.0f - Hlsl.Abs(Hlsl.Sin(gTime * 0.4f)) * 1.5f); + + pos = pos_origin; + pos.XY = Hlsl.Mul(pos.XY, Rotate(0.8f)); + + float box5 = Box(pos, 0.5f) * 6.0f; + + pos = pos_origin; + + float box6 = Box(pos, 0.5f) * 6.0f; + float result = Hlsl.Max(Hlsl.Max(Hlsl.Max(Hlsl.Max(Hlsl.Max(box1, box2), box3), box4), box5), box6); + + return result; + } + + /// + public void Execute() + { + Int2 resolution = new(texture.Width, texture.Height); + Float2 p = ((Float2)ThreadIds.XY * 2.0f - resolution) / Hlsl.Min(resolution.X, resolution.Y); + Float3 ro = new(0.0f, -0.2f, time * 4.0f); + Float3 ray = Hlsl.Normalize(new Float3(p, 1.5f)); + + ray.XY = Hlsl.Mul(ray.XY, Rotate(Hlsl.Sin(time * 0.03f) * 5.0f)); + ray.YZ = Hlsl.Mul(ray.YZ, Rotate(Hlsl.Sin(time * 0.05f) * 0.2f)); + + float t = 0.1f; + float ac = 0.0f; + + for (int i = 0; i < 99; i++) + { + static Float3 Mod(Float3 x, float y) + { + return x - y * Hlsl.Floor(x / y); + } + + Float3 pos = ro + ray * t; + + pos = Mod(pos - 2.0f, 4.0f) - 2.0f; + + float gTime = time - i * 0.01f; + float d = BoxSet(pos, gTime); + + d = Hlsl.Max(Hlsl.Abs(d), 0.01f); + ac += Hlsl.Exp(-d * 23.0f); + t += d * 0.55f; + } + + Float3 col = ac * 0.02f + new Float3(0.0f, 0.2f * Hlsl.Abs(Hlsl.Sin(time)), 0.5f + Hlsl.Sin(time) * 0.2f); + Float4 color = new(col, 1.0f - t * (0.02f + 0.02f * Hlsl.Sin(time))); + + texture[ThreadIds.XY] = color; + } + } +} diff --git a/samples/ComputeSharp.SwapChain/Shaders/ProteanClouds.cs b/samples/ComputeSharp.SwapChain/Shaders/ProteanClouds.cs new file mode 100644 index 00000000..1a197dce --- /dev/null +++ b/samples/ComputeSharp.SwapChain/Shaders/ProteanClouds.cs @@ -0,0 +1,174 @@ +namespace ComputeSharp.SwapChain.Shaders +{ + /// + /// Fully procedural 3D animated volume with three evaluations per step (for shading). + /// Ported from . + /// Created by nimitz (twitter: @stormoid). + /// License Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. + /// + [AutoConstructor] + internal readonly partial struct ProteanClouds : IComputeShader + { + /// + /// The target texture. + /// + public readonly IReadWriteTexture2D texture; + + /// + /// The current time Hlsl.Since the start of the application. + /// + public readonly float time; + + private static Float2x2 Rotate(in float a) + { + float c = Hlsl.Cos(a), s = Hlsl.Sin(a); + + return new(c, s, -s, c); + } + + private static float LinStep(in float mn, in float mx, in float x) + { + return Hlsl.Clamp((x - mn) / (mx - mn), 0.0f, 1.0f); + } + + private static Float2 Disp(float t) + { + return new Float2(Hlsl.Sin(t * 0.22f) * 1.0f, Hlsl.Cos(t * 0.175f) * 1.0f) * 2.0f; + } + + private Float2 Map(Float3 p, float prm1, Float2 bsMo) + { + Float3 p2 = p; + + p2.XY -= Disp(p.Z).XY; + p.XY = Hlsl.Mul(p.XY, Rotate(Hlsl.Sin(p.Z + time) * (0.1f + prm1 * 0.05f) + time * 0.09f)); + + float cl = Hlsl.Dot(p2.XY, p2.XY); + float d = 0.0f; + + p *= 0.61f; + + float z = 1.0f; + float trk = 1.0f; + float dspAmp = 0.1f + prm1 * 0.2f; + + for (int i = 0; i < 5; i++) + { + p += Hlsl.Sin(p.ZXY * 0.75f * trk + time * trk * 0.8f) * dspAmp; + d -= Hlsl.Abs(Hlsl.Dot(Hlsl.Cos(p), Hlsl.Sin(p.YZX)) * z); + z *= 0.57f; + trk *= 1.4f; + + Float3x3 m3 = new Float3x3(0.33338f, 0.56034f, -0.71817f, -0.87887f, 0.32651f, -0.15323f, 0.15162f, 0.69596f, 0.61339f) * 1.93f; + + p = Hlsl.Mul(p, m3); + } + + d = Hlsl.Abs(d + prm1 * 3.0f) + prm1 * 0.3f - 2.5f + bsMo.Y; + + return new Float2(d + cl * 0.2f + 0.25f, cl); + } + + private Float4 Render(Float3 ro, Float3 rd, float time, float prm1, Float2 bsMo) + { + Float4 rez = 0; + float t = 1.5f; + float fogT = 0; + + for (int i = 0; i < 130; i++) + { + if (rez.A > 0.99f) break; + + Float3 pos = ro + t * rd; + Float2 mpv = Map(pos, prm1, bsMo); + float den = Hlsl.Clamp(mpv.X - 0.3f, 0.0f, 1.0f) * 1.12f; + float dn = Hlsl.Clamp((mpv.X + 2.0f), 0.0f, 3.0f); + Float4 col = 0f; + + if (mpv.X > 0.6f) + { + + col = new Float4(Hlsl.Sin(new Float3(5.0f, 0.4f, 0.2f) + mpv.Y * 0.1f + Hlsl.Sin(pos.Z * 0.4f) * 0.5f + 1.8f) * 0.5f + 0.5f, 0.08f); + col *= den * den * den; + col.RGB *= LinStep(4.0f, -2.5f, mpv.X) * 2.3f; + + float dif = Hlsl.Clamp((den - Map(pos + 0.8f, prm1, bsMo).X) / 9.0f, 0.001f, 1.0f); + + dif += Hlsl.Clamp((den - Map(pos + 0.35f, prm1, bsMo).X) / 2.5f, 0.001f, 1.0f); + col.XYZ *= den * (new Float3(0.005f, 0.045f, 0.075f) + 1.5f * new Float3(0.033f, 0.07f, 0.03f) * dif); + } + + float fogC = Hlsl.Exp(t * 0.2f - 2.2f); + + col += new Float4(0.06f, 0.11f, 0.11f, 0.1f) * Hlsl.Clamp(fogC - fogT, 0.0f, 1.0f); + fogT = fogC; + rez += col * (1.0f - rez.A); + t += Hlsl.Clamp(0.5f - dn * dn * 0.05f, 0.09f, 0.3f); + } + + return Hlsl.Clamp(rez, 0.0f, 1.0f); + } + + private static float GetSaturation(Float3 c) + { + float mi = Hlsl.Min(Hlsl.Min(c.X, c.Y), c.Z); + float ma = Hlsl.Max(Hlsl.Max(c.X, c.Y), c.Z); + + return (ma - mi) / (ma + (float)1e-7); + } + + private static Float3 ILerp(in Float3 a, in Float3 b, in float x) + { + Float3 ic = Hlsl.Lerp(a, b, x) + new Float3((float)1e-6, 0.0f, 0.0f); + float sd = Hlsl.Abs(GetSaturation(ic) - Hlsl.Lerp(GetSaturation(a), GetSaturation(b), x)); + Float3 dir = Hlsl.Normalize(new Float3(2.0f * ic.X - ic.Y - ic.Z, 2.0f * ic.Y - ic.X - ic.Z, 2.0f * ic.Z - ic.Y - ic.X)); + float lgt = Hlsl.Dot(1.0f, ic); + float ff = Hlsl.Dot(dir, Hlsl.Normalize(ic)); + + ic += 1.5f * dir * sd * ff * lgt; + + return Hlsl.Clamp(ic, 0.0f, 1.0f); + } + + /// + public void Execute() + { + Int2 resolution = new(texture.Width, texture.Height); + Float2 q = (Float2)ThreadIds.XY / resolution; + Float2 p = (ThreadIds.XY - 0.5f * (Float2)resolution) / resolution.Y; + Float2 bsMo = -0.5f * (Float2)resolution / resolution.Y; + float scaledTime = time * 3.0f; + Float3 ro = new(0, 0, scaledTime); + + ro += new Float3(Hlsl.Sin(time) * 0.5f, Hlsl.Sin(time * 1.0f) * 0.0f, 0); + + float dspAmp = 0.85f; + + ro.XY += Disp(ro.Z) * dspAmp; + + float tgtDst = 3.5f; + Float3 target = Hlsl.Normalize(ro - new Float3(Disp(scaledTime + tgtDst) * dspAmp, scaledTime + tgtDst)); + + ro.X -= bsMo.X * 2.0f; + + Float3 rightdir = Hlsl.Normalize(Hlsl.Cross(target, new Float3(0, 1, 0))); + Float3 updir = Hlsl.Normalize(Hlsl.Cross(rightdir, target)); + + rightdir = Hlsl.Normalize(Hlsl.Cross(updir, target)); + + Float3 rd = Hlsl.Normalize((p.X * rightdir + p.Y * updir) * 1.0f - target); + + rd.XY = Hlsl.Mul(rd.XY, Rotate(-Disp(scaledTime + 3.5f).X * 0.2f + bsMo.X)); + + float prm1 = Hlsl.SmoothStep(-0.4f, 0.4f, Hlsl.Sin(time * 0.3f)); + Float4 scn = Render(ro, rd, scaledTime, prm1, bsMo); + Float3 col = scn.RGB; + + col = ILerp(col.BGR, col.RGB, Hlsl.Clamp(1.0f - prm1, 0.05f, 1.0f)); + col = Hlsl.Pow(col, new Float3(0.55f, 0.65f, 0.6f)) * new Float3(1.0f, 0.97f, 0.9f); + col *= Hlsl.Pow(16.0f * q.X * q.Y * (1.0f - q.X) * (1.0f - q.Y), 0.12f) * 0.7f + 0.3f; + + texture[ThreadIds.XY] = new Float4(col, 1.0f); + } + } +} diff --git a/src/ComputeSharp.SourceGenerators/AnalyzerReleases.Unshipped.md b/src/ComputeSharp.SourceGenerators/AnalyzerReleases.Unshipped.md index 64faf974..dad27523 100644 --- a/src/ComputeSharp.SourceGenerators/AnalyzerReleases.Unshipped.md +++ b/src/ComputeSharp.SourceGenerators/AnalyzerReleases.Unshipped.md @@ -45,4 +45,5 @@ CMPS0037 | ComputeSharp.SourceGenerators.AutoConstructorGenerator | Warning | Au CMPS0038 | ComputeSharp.SourceGenerators.IComputeShaderDataLoaderGenerator | Warning | IComputeShaderDataLoaderGenerator, [Documentation](https://github.com/Sergio0694/ComputeSharp) CMPS0039 | ComputeSharp.SourceGenerators.IComputeShaderHashCodeGenerator | Warning | IComputeShaderHashCodeGenerator, [Documentation](https://github.com/Sergio0694/ComputeSharp) CMPS0040 | ComputeSharp.SourceGenerators.IComputeShaderSourceGenerator | Warning | IComputeShaderSourceGenerator, [Documentation](https://github.com/Sergio0694/ComputeSharp) -CMPS0041 | ComputeSharp.SourceGenerators.ShaderMethodSourceGenerator | Warning | ShaderMethodSourceGenerator, [Documentation](https://github.com/Sergio0694/ComputeSharp) \ No newline at end of file +CMPS0041 | ComputeSharp.SourceGenerators.ShaderMethodSourceGenerator | Warning | ShaderMethodSourceGenerator, [Documentation](https://github.com/Sergio0694/ComputeSharp) +CMPS0042 | ComputeSharp.IComputeShader | Error | IComputeShaderSourceGenerator, [Documentation](https://github.com/Sergio0694/ComputeSharp) \ No newline at end of file diff --git a/src/ComputeSharp.SourceGenerators/ComputeSharp.SourceGenerators.csproj b/src/ComputeSharp.SourceGenerators/ComputeSharp.SourceGenerators.csproj index 15c7d1ee..1caa0d0e 100644 --- a/src/ComputeSharp.SourceGenerators/ComputeSharp.SourceGenerators.csproj +++ b/src/ComputeSharp.SourceGenerators/ComputeSharp.SourceGenerators.csproj @@ -26,8 +26,9 @@ - + + @@ -35,30 +36,36 @@ + + + + + + diff --git a/src/ComputeSharp.SourceGenerators/Diagnostics/DiagnosticDescriptors.cs b/src/ComputeSharp.SourceGenerators/Diagnostics/DiagnosticDescriptors.cs index 25dbe67e..e7e12598 100644 --- a/src/ComputeSharp.SourceGenerators/Diagnostics/DiagnosticDescriptors.cs +++ b/src/ComputeSharp.SourceGenerators/Diagnostics/DiagnosticDescriptors.cs @@ -587,5 +587,18 @@ namespace ComputeSharp.SourceGenerators.Diagnostics isEnabledByDefault: true, description: $"The {nameof(ShaderMethodSourceGenerator)} generator encountered an error while processing a method, and using it in a shader might result in a runtime crash. Please report this issue at https://github.com/Sergio0694/ComputeSharp/issues.", helpLinkUri: "https://github.com/Sergio0694/ComputeSharp"); + + /// + /// Gets a for an incorrect matrix swizzling property argument. + /// + public static readonly DiagnosticDescriptor NonConstantMatrixSwizzledIndex = new( + id: "CMPS0042", + title: "Non constant matrix swizzled property argument", + messageFormat: "The arguments in a swizzled indexer for a matrix type must be compile-time constants", + category: typeof(ShaderMethodSourceGenerator).FullName, + defaultSeverity: DiagnosticSeverity.Error, + isEnabledByDefault: true, + description: "The arguments in a swizzled indexer for a matrix type must be compile-time constants.", + helpLinkUri: "https://github.com/Sergio0694/ComputeSharp"); } } diff --git a/src/ComputeSharp.SourceGenerators/Extensions/ISymbolExtensions.cs b/src/ComputeSharp.SourceGenerators/Extensions/ISymbolExtensions.cs index e84e89ad..f89b5aa1 100644 --- a/src/ComputeSharp.SourceGenerators/Extensions/ISymbolExtensions.cs +++ b/src/ComputeSharp.SourceGenerators/Extensions/ISymbolExtensions.cs @@ -94,6 +94,17 @@ namespace ComputeSharp.SourceGenerators.Extensions return $"{declaringTypeName}.{symbol.Name}"; } + /// + /// Gets the full metadata name for a given instance. + /// + /// The input instance. + /// The full metadata name for . + [Pure] + public static string GetFullMetadataName(this IFieldSymbol symbol) + { + return $"{symbol.ContainingType.GetFullMetadataName()}.{symbol.Name}"; + } + /// /// Gets a valid filename for a target symbol and generator type. /// diff --git a/src/ComputeSharp.SourceGenerators/IComputeShaderDataLoaderGenerator.cs b/src/ComputeSharp.SourceGenerators/IComputeShaderDataLoaderGenerator.cs index 0f72f7b2..beaff28e 100644 --- a/src/ComputeSharp.SourceGenerators/IComputeShaderDataLoaderGenerator.cs +++ b/src/ComputeSharp.SourceGenerators/IComputeShaderDataLoaderGenerator.cs @@ -160,14 +160,14 @@ namespace ComputeSharp.SourceGenerators resourceOffset = 0, rawDataOffset = sizeof(int) * 3; - foreach (var fieldSymbol in structDeclarationSymbol.GetMembers().OfType()) + foreach ( + IFieldSymbol fieldSymbol in + from fieldSymbol in structDeclarationSymbol.GetMembers().OfType() + where fieldSymbol.Type is INamedTypeSymbol { IsStatic: false } && + !fieldSymbol.IsConst + select fieldSymbol) { - if (fieldSymbol.Type is not INamedTypeSymbol { IsStatic: false } typeSymbol) - { - continue; - } - - string typeName = typeSymbol.GetFullMetadataName(); + string typeName = fieldSymbol.Type.GetFullMetadataName(); if (HlslKnownTypes.IsTypedResourceType(typeName)) { @@ -177,25 +177,53 @@ namespace ComputeSharp.SourceGenerators ParseExpression($"Unsafe.Add(ref r0, {resourceOffset++})"), ParseExpression($"GraphicsResourceHelper.ValidateAndGetGpuDescriptorHandle(shader.{fieldSymbol.Name}, device)")))); } - else if (HlslKnownTypes.IsScalarOrVectorType(typeName)) + else if (HlslKnownTypes.IsKnownHlslType(typeName)) { - if (fieldSymbol.IsConst) continue; - + // For scalar, vector and linear matrix types, serialize the value normally. + // Only the initial alignment needs to be considered, while data is packed. var (fieldSize, fieldPack) = HlslKnownSizes.GetTypeInfo(typeName); - // Calculate the right offset with 16-bytes padding (HLSL constant buffer). - // Since we're in a constant buffer, we need to both pad the starting offset - // to be aligned to the packing size of the type, and also to align the initial - // offset to ensure that values do not cross 16 bytes boundaries either. - rawDataOffset = AlignmentHelper.AlignToBoundary( - AlignmentHelper.Pad(rawDataOffset, fieldPack), - fieldSize, - 16); + // Check if the current type is a matrix type with more than one row. In this + // case, each row is aligned as if it was a separate array, so the start of + // each row needs to be at a multiple of 16 bytes (a float4 register). + if (HlslKnownTypes.IsNonLinearMatrixType(typeName, out string? elementName, out int rows, out int columns)) + { + string + rowTypeName = $"ComputeSharp.{elementName}{columns}", + rowLocalName = $"__{fieldSymbol.Name}__row0"; - statements.Add(ExpressionStatement( - ParseExpression($"Unsafe.WriteUnaligned(ref Unsafe.Add(ref r1, {rawDataOffset}), shader.{fieldSymbol.Name})"))); + statements.Add(ParseStatement($"ref {rowTypeName} {rowLocalName} = ref Unsafe.As<{typeName}, {rowTypeName}>(ref Unsafe.AsRef(in shader.{fieldSymbol.Name}));")); - rawDataOffset += fieldSize; + // Generate the loading code for each individual row, with proper alignment. + // This will result in the following (assuming Float2x3 m): + // + // ref Float3 __m__row0 = ref Unsafe.As(ref Unsafe.AsRef(in shader.m)); + // Unsafe.WriteUnaligned(ref Unsafe.Add(ref r1, rawDataOffset), Unsafe.Add(ref __m__row0, 0)); + // Unsafe.WriteUnaligned(ref Unsafe.Add(ref r1, rawDataOffset + 16), Unsafe.Add(ref __m__row0, 1)); + for (int j = 0; j < rows; j++) + { + rawDataOffset = AlignmentHelper.Pad(rawDataOffset, 16); + + statements.Add(ParseStatement($"Unsafe.WriteUnaligned(ref Unsafe.Add(ref r1, {rawDataOffset}), Unsafe.Add(ref {rowLocalName}, {j}));")); + + rawDataOffset += fieldPack * columns; + } + } + else + { + // Calculate the right offset with 16-bytes padding (HLSL constant buffer). + // Since we're in a constant buffer, we need to both pad the starting offset + // to be aligned to the packing size of the type, and also to align the initial + // offset to ensure that values do not cross 16 bytes boundaries either. + rawDataOffset = AlignmentHelper.AlignToBoundary( + AlignmentHelper.Pad(rawDataOffset, fieldPack), + fieldSize, + 16); + + statements.Add(ParseStatement($"Unsafe.WriteUnaligned(ref Unsafe.Add(ref r1, {rawDataOffset}), shader.{fieldSymbol.Name});")); + + rawDataOffset += fieldSize; + } } } diff --git a/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownKeywords.cs b/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownKeywords.cs index c760404a..5aec5569 100644 --- a/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownKeywords.cs +++ b/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownKeywords.cs @@ -42,17 +42,11 @@ namespace ComputeSharp.SourceGenerators.Mappings knownKeywords.Add(nameof(WarpIds)); // HLSL intrinsics method names - foreach (var method in - from method in typeof(Hlsl).GetMethods(BindingFlags.Public | BindingFlags.Static) - group method by method.Name - into groups - select (Name: groups.Key, MethodInfo: groups.First())) + foreach (var method in typeof(Hlsl).GetMethods(BindingFlags.Public | BindingFlags.Static)) { - string hlslName = method.MethodInfo.GetCustomAttribute() != null - ? method.Name - : method.Name.ToLowerInvariant(); + string name = method.GetCustomAttribute()?.Name ?? method.Name; - knownKeywords.Add(hlslName); + knownKeywords.Add(name); } return knownKeywords; diff --git a/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownMembers.cs b/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownMembers.cs index 707abb64..24da01ea 100644 --- a/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownMembers.cs +++ b/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownMembers.cs @@ -1,9 +1,11 @@ using System; using System.Collections.Generic; +using System.Collections.Immutable; using System.Diagnostics.Contracts; using System.Linq; using System.Numerics; using System.Reflection; +using System.Text.RegularExpressions; namespace ComputeSharp.SourceGenerators.Mappings { @@ -13,9 +15,9 @@ namespace ComputeSharp.SourceGenerators.Mappings internal static class HlslKnownMembers { /// - /// The mapping of supported known indexers to HLSL vector type names. + /// The mapping of supported known indexers to HLSL resource type names. /// - private static readonly IReadOnlyDictionary KnownIndexers = new Dictionary + private static readonly IReadOnlyDictionary KnownResourceIndexers = new Dictionary { [$"ComputeSharp.ReadOnlyTexture2D`1.this[{typeof(int).FullName}, {typeof(int).FullName}]"] = "int2", [$"ComputeSharp.ReadOnlyTexture2D`2.this[{typeof(int).FullName}, {typeof(int).FullName}]"] = "int2", @@ -183,13 +185,27 @@ namespace ComputeSharp.SourceGenerators.Mappings // Programmatically load mappings for the instance members of the HLSL vector types foreach (var item in - from type in HlslKnownTypes.HlslMappedVectorTypes + from type in HlslKnownTypes.KnownVectorTypes from property in type.GetProperties(BindingFlags.Instance | BindingFlags.Public) select (Type: type, Property: property)) { knownMembers.Add($"{item.Type.FullName}{Type.Delimiter}{item.Property.Name}", $"{item.Property.Name.ToLower()}"); } + // Load mappings for the matrix properties as well + foreach (var item in + from type in HlslKnownTypes.KnownMatrixTypes + from property in type.GetProperties(BindingFlags.Instance | BindingFlags.Public) + where Regex.IsMatch(property.Name, "^M[1-4]{2}$") + select (Type: type, Property: property)) + { + char + row = (char)(item.Property.Name[1] - 1), + column = (char)(item.Property.Name[2] - 1); + + knownMembers.Add($"{item.Type.FullName}{Type.Delimiter}{item.Property.Name}", $"_m{row}{column}"); + } + // Store GroupIds.Index for a quicker comparison afterwards PropertyInfo groupindexProperty = typeof(GroupIds).GetProperty(nameof(GroupIds.Index), BindingFlags.Static | BindingFlags.Public); @@ -236,6 +252,66 @@ namespace ComputeSharp.SourceGenerators.Mappings return knownMembers; } + /// + /// The mapping of supported known members to HLSL names. + /// + private static readonly IReadOnlyCollection KnownMatrixIndexers = BuildKnownMatrixIndexers(); + + /// + /// Builds the mapping of swizzled matrix indexer properties. + /// + [Pure] + private static IReadOnlyCollection BuildKnownMatrixIndexers() + { + return ( + from type in Assembly.GetExecutingAssembly().ExportedTypes + where Regex.IsMatch(type.FullName, @"ComputeSharp\.(Bool|Double|Float|Int|UInt)[1-4]x[1-4]") + from property in type.GetProperties() + let indices = property.GetIndexParameters() + where indices.Length > 0 && + indices.All(static index => index.ParameterType == typeof(MatrixIndex)) + let metadataName = $"{type.FullName}.this[{string.Join(", ", indices.Select(index => index.ParameterType))}]" + select metadataName).ToImmutableHashSet(); + } + + /// + /// The mapping of supported known members to HLSL names. + /// + private static readonly IReadOnlyCollection KnownMatrixIndices = BuildKnownMatrixIndices(); + + /// + /// Builds the mapping of swizzled matrix indices. + /// + [Pure] + private static IReadOnlyCollection BuildKnownMatrixIndices() + { + return ( + from name in Enum.GetNames(typeof(MatrixIndex)) + select $"{typeof(MatrixIndex).FullName}.{name}").ToImmutableHashSet(); + } + + /// + /// Checks whether or not a given property fullname matches a matrix swizzled indexer. + /// + /// The input fully qualified member name. + /// Whether or not is a matrix swizzled indexer. + [Pure] + public static bool IsKnownMatrixIndexer(string name) + { + return KnownMatrixIndexers.Contains(name); + } + + /// + /// Checks whether or not a given property fullname matches a matrix swizzled index. + /// + /// The input fully qualified member name. + /// Whether or not is a matrix swizzled index. + [Pure] + public static bool IsKnownMatrixIndex(string name) + { + return KnownMatrixIndices.Contains(name); + } + /// /// Tries to get the mapped HLSL-compatible member name for the input member name. /// @@ -249,15 +325,15 @@ namespace ComputeSharp.SourceGenerators.Mappings } /// - /// Tries to get the mapped HLSL-compatible indexer vector type name for the input indexer name. + /// Tries to get the mapped HLSL-compatible indexer resource type name for the input indexer name. /// /// The input fully qualified indexer name. /// The mapped type name, if one is found. /// The HLSL-compatible type name that can be used in an HLSL shader for the given indexer. [Pure] - public static bool TryGetMappedIndexerTypeName(string name, out string? mapped) + public static bool TryGetMappedResourceIndexerTypeName(string name, out string? mapped) { - return KnownIndexers.TryGetValue(name, out mapped); + return KnownResourceIndexers.TryGetValue(name, out mapped); } /// diff --git a/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownMethods.cs b/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownMethods.cs index 26eadfb5..b33dd8b0 100644 --- a/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownMethods.cs +++ b/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownMethods.cs @@ -107,14 +107,12 @@ namespace ComputeSharp.SourceGenerators.Mappings from method in typeof(Hlsl).GetMethods(BindingFlags.Public | BindingFlags.Static) group method by method.Name into groups - select (Name: groups.Key, MethodInfo: groups.First())) + select groups.First()) { // Check whether the current method should be translated with the original name // or with the lowercase version. This is needed because all C# methods are exposed // with the upper camel case format, while HLSL intrinsics use multiple different formats. - string hlslName = method.MethodInfo.GetCustomAttribute() != null - ? method.Name - : method.Name.ToLowerInvariant(); + string hlslName = method.GetCustomAttribute()?.Name ?? method.Name; knownMethods.Add($"{typeof(Hlsl).FullName}{Type.Delimiter}{method.Name}", hlslName); } diff --git a/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownSizes.cs b/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownSizes.cs index e05ff7a8..78d2aed8 100644 --- a/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownSizes.cs +++ b/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownSizes.cs @@ -1,6 +1,9 @@ using System.Collections.Generic; using System.Diagnostics.Contracts; +using System.Linq; using System.Numerics; +using System.Reflection; +using System.Text.RegularExpressions; namespace ComputeSharp.SourceGenerators.Mappings { @@ -12,38 +15,38 @@ namespace ComputeSharp.SourceGenerators.Mappings /// /// The mapping of supported known sizes to HLSL type names. /// - private static IReadOnlyDictionary KnownSizes = new Dictionary + private static IReadOnlyDictionary KnownSizes = BuildKnownSizesMap(); + + /// + /// Builds the mapping of known type sizes and alignments. + /// + [Pure] + private static IReadOnlyDictionary BuildKnownSizesMap() { - [typeof(bool).FullName] = (4, 4), - [typeof(int).FullName] = (4, 4), - [typeof(int).FullName] = (4, 4), - [typeof(float).FullName] = (4, 4), - [typeof(double).FullName] = (8, 8), + Dictionary knownSizes = new() + { + [typeof(bool).FullName] = (4, 4), + [typeof(int).FullName] = (4, 4), + [typeof(int).FullName] = (4, 4), + [typeof(float).FullName] = (4, 4), + [typeof(double).FullName] = (8, 8), - [typeof(Vector2).FullName] = (8, 4), - [typeof(Vector3).FullName] = (12, 4), - [typeof(Vector4).FullName] = (16, 4), + [typeof(Vector2).FullName] = (8, 4), + [typeof(Vector3).FullName] = (12, 4), + [typeof(Vector4).FullName] = (16, 4) + }; - [typeof(Bool2).FullName] = (8, 4), - [typeof(Bool3).FullName] = (12, 4), - [typeof(Bool4).FullName] = (16, 4), + foreach ( + var type in + from type in Assembly.GetExecutingAssembly().ExportedTypes + where Regex.IsMatch(type.FullName, @"^ComputeSharp\.(Bool|Double|Float|Int|UInt)") + select type) + { + knownSizes.Add(type.FullName, (type.StructLayoutAttribute.Size, type.StructLayoutAttribute.Pack)); + } - [typeof(Int2).FullName] = (8, 4), - [typeof(Int3).FullName] = (12, 4), - [typeof(Int4).FullName] = (16, 4), - - [typeof(UInt2).FullName] = (8, 4), - [typeof(UInt3).FullName] = (12, 4), - [typeof(UInt4).FullName] = (16, 4), - - [typeof(Float2).FullName] = (8, 4), - [typeof(Float3).FullName] = (12, 4), - [typeof(Float4).FullName] = (16, 4), - - [typeof(Double2).FullName] = (16, 8), - [typeof(Double3).FullName] = (24, 8), - [typeof(Double3).FullName] = (32, 8) - }; + return knownSizes; + } /// /// Gets the size and alignment info for a specified primitive type. diff --git a/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownTypes.cs b/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownTypes.cs index f9e79082..2f686b1c 100644 --- a/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownTypes.cs +++ b/src/ComputeSharp.SourceGenerators/Mappings/HlslKnownTypes.cs @@ -3,6 +3,7 @@ using System.Collections.Generic; using System.Diagnostics.Contracts; using System.Linq; using System.Numerics; +using System.Text.RegularExpressions; using ComputeSharp.SourceGenerators.Extensions; using Microsoft.CodeAnalysis; @@ -14,40 +15,19 @@ namespace ComputeSharp.SourceGenerators.Mappings internal static class HlslKnownTypes { /// - /// The mapping of supported known types to HLSL types. + /// Gets the known HLSL dispatch types. /// - private static readonly IReadOnlyDictionary KnownTypes = new Dictionary + public static IReadOnlyCollection HlslDispatchTypes { get; } = new[] { - [typeof(bool).FullName] = "bool", - [typeof(Bool).FullName] = "bool", - [typeof(Bool2).FullName] = "bool2", - [typeof(Bool3).FullName] = "bool3", - [typeof(Bool4).FullName] = "bool4", - [typeof(int).FullName] = "int", - [typeof(Int2).FullName] = "int2", - [typeof(Int3).FullName] = "int3", - [typeof(Int4).FullName] = "int4", - [typeof(uint).FullName] = "uint", - [typeof(UInt2).FullName] = "uint2", - [typeof(UInt3).FullName] = "uint3", - [typeof(UInt4).FullName] = "uint4", - [typeof(float).FullName] = "float", - [typeof(Float2).FullName] = "float2", - [typeof(Float3).FullName] = "float3", - [typeof(Float4).FullName] = "float4", - [typeof(Vector2).FullName] = "float2", - [typeof(Vector3).FullName] = "float3", - [typeof(Vector4).FullName] = "float4", - [typeof(double).FullName] = "double", - [typeof(Double2).FullName] = "double2", - [typeof(Double3).FullName] = "double3", - [typeof(Double4).FullName] = "double4" + typeof(ThreadIds), + typeof(GroupIds), + typeof(WarpIds) }; /// - /// Gets the known HLSL vector types available as mapped types. + /// Gets the set of HLSL vector types. /// - public static IReadOnlyCollection HlslMappedVectorTypes { get; } = new[] + public static IReadOnlyCollection KnownVectorTypes { get; } = new[] { typeof(Bool2), typeof(Bool3), typeof(Bool4), typeof(Int2), typeof(Int3), typeof(Int4), @@ -57,15 +37,70 @@ namespace ComputeSharp.SourceGenerators.Mappings }; /// - /// Gets the known HLSL dispatch types. + /// Gets the set of HLSL matrix types. /// - public static IReadOnlyCollection HlslDispatchTypes { get; } = new[] + public static IReadOnlyCollection KnownMatrixTypes { get; } = new[] { - typeof(ThreadIds), - typeof(GroupIds), - typeof(WarpIds) + typeof(Bool1x1), typeof(Bool1x2), typeof(Bool1x3), typeof(Bool1x4), + typeof(Bool2x1), typeof(Bool2x2), typeof(Bool2x3), typeof(Bool2x4), + typeof(Bool3x1), typeof(Bool3x2), typeof(Bool3x3), typeof(Bool3x4), + typeof(Bool4x1), typeof(Bool4x2), typeof(Bool4x3), typeof(Bool4x4), + typeof(Int1x1), typeof(Int1x2), typeof(Int1x3), typeof(Int1x4), + typeof(Int2x1), typeof(Int2x2), typeof(Int2x3), typeof(Int2x4), + typeof(Int3x1), typeof(Int3x2), typeof(Int3x3), typeof(Int3x4), + typeof(Int4x1), typeof(Int4x2), typeof(Int4x3), typeof(Int4x4), + typeof(UInt1x1), typeof(UInt1x2), typeof(UInt1x3), typeof(UInt1x4), + typeof(UInt2x1), typeof(UInt2x2), typeof(UInt2x3), typeof(UInt2x4), + typeof(UInt3x1), typeof(UInt3x2), typeof(UInt3x3), typeof(UInt3x4), + typeof(UInt4x1), typeof(UInt4x2), typeof(UInt4x3), typeof(UInt4x4), + typeof(Float1x1), typeof(Float1x2), typeof(Float1x3), typeof(Float1x4), + typeof(Float2x1), typeof(Float2x2), typeof(Float2x3), typeof(Float2x4), + typeof(Float3x1), typeof(Float3x2), typeof(Float3x3), typeof(Float3x4), + typeof(Float4x1), typeof(Float4x2), typeof(Float4x3), typeof(Float4x4), + typeof(Double1x1), typeof(Double1x2), typeof(Double1x3), typeof(Double1x4), + typeof(Double2x1), typeof(Double2x2), typeof(Double2x3), typeof(Double2x4), + typeof(Double3x1), typeof(Double3x2), typeof(Double3x3), typeof(Double3x4), + typeof(Double4x1), typeof(Double4x2), typeof(Double4x3), typeof(Double4x4) }; + /// + /// The mapping of supported known types to HLSL types. + /// + private static readonly IReadOnlyDictionary KnownHlslTypes = BuildKnownHlslTypes(); + + /// + /// Builds the mapping of known primitive types. + /// + [Pure] + private static IReadOnlyDictionary BuildKnownHlslTypes() + { + Dictionary knownTypes = new() + { + [typeof(bool).FullName] = "bool", + [typeof(int).FullName] = "int", + [typeof(uint).FullName] = "uint", + [typeof(float).FullName] = "float", + [typeof(Vector2).FullName] = "float2", + [typeof(Vector3).FullName] = "float3", + [typeof(Vector4).FullName] = "float4", + [typeof(double).FullName] = "double" + }; + + // Add all the vector types + foreach (var type in KnownVectorTypes) + { + knownTypes.Add(type.FullName, type.Name.ToLower()); + } + + // Add all the matrix types + foreach (var type in KnownMatrixTypes) + { + knownTypes.Add(type.FullName, type.Name.ToLower()); + } + + return knownTypes; + } + /// /// Checks whether or not a given type name matches a structured buffer type. /// @@ -113,13 +148,64 @@ namespace ComputeSharp.SourceGenerators.Mappings } /// - /// Checks whether or not a given type name matches a typed resource type. + /// Checks whether or not a given type name matches a known HLSL primitive type (scalar, vector or matrix). /// /// The input type name to check. - /// Whether or not represents a typed resource type. - public static bool IsScalarOrVectorType(string typeName) + /// Whether or not represents a scalar, vector or matrix type. + public static bool IsKnownHlslType(string typeName) { - return KnownTypes.ContainsKey(typeName); + return KnownHlslTypes.ContainsKey(typeName); + } + + /// + /// Checks whether or not a given type name matches a vector type. + /// + /// The input type name to check. + /// Whether or not represents a vector type. + public static bool IsVectorType(string typeName) + { + return KnownVectorTypes.Any(type => type.FullName == typeName); + } + + /// + /// Checks whether or not a given type name matches a matrix type. + /// + /// The input type name to check. + /// Whether or not represents a matrix type. + public static bool IsMatrixType(string typeName) + { + return KnownMatrixTypes.Any(type => type.FullName == typeName); + } + + /// + /// Checks whether or not a given type name is a non linear matrix type. + /// That is, a matrix type with more than a single row (which affects the constant buffer alignment). + /// + /// The input type name to check. + /// The element name of the matrix type. + /// The number of rows in the matrix type. + /// The number of columns in the matrix type. + /// Whether or not represents a non linear matrix type. + public static bool IsNonLinearMatrixType(string typeName, out string? elementName, out int rows, out int columns) + { + if (KnownMatrixTypes.Any(type => type.FullName == typeName)) + { + var match = Regex.Match(typeName, @"^ComputeSharp\.(Bool|Int|UInt|Float|Double)([2-4])x([1-4])$"); + + if (match.Success) + { + elementName = match.Groups[1].Value; + rows = int.Parse(match.Groups[2].Value); + columns = int.Parse(match.Groups[3].Value); + + return true; + } + } + + elementName = null; + rows = columns = 0; + + return false; } /// @@ -142,7 +228,7 @@ namespace ComputeSharp.SourceGenerators.Mappings string genericArgumentName = ((INamedTypeSymbol)typeSymbol.TypeArguments.Last()).GetFullMetadataName(); // If the current type is a custom type, format it as needed - if (!KnownTypes.TryGetValue(genericArgumentName, out string? mapped)) + if (!KnownHlslTypes.TryGetValue(genericArgumentName, out string? mapped)) { mapped = genericArgumentName.Replace(".", "__"); } @@ -169,7 +255,7 @@ namespace ComputeSharp.SourceGenerators.Mappings }; } - return KnownTypes[typeName]; + return KnownHlslTypes[typeName]; } /// @@ -182,7 +268,7 @@ namespace ComputeSharp.SourceGenerators.Mappings { string elementTypeName = ((INamedTypeSymbol)typeSymbol.ElementType).GetFullMetadataName(); - if (KnownTypes.TryGetValue(elementTypeName, out string? mapped)) + if (KnownHlslTypes.TryGetValue(elementTypeName, out string? mapped)) { return mapped; } @@ -197,7 +283,7 @@ namespace ComputeSharp.SourceGenerators.Mappings /// The HLSL-compatible type name that can be used in an HLSL shader. public static bool TryGetMappedName(string originalName, out string? mappedName) { - return KnownTypes.TryGetValue(originalName, out mappedName); + return KnownHlslTypes.TryGetValue(originalName, out mappedName); } /// @@ -210,7 +296,7 @@ namespace ComputeSharp.SourceGenerators.Mappings // Local function to recursively gather nested types static void ExploreTypes(INamedTypeSymbol type, HashSet customTypes) { - if (KnownTypes.ContainsKey(type.GetFullMetadataName())) return; + if (KnownHlslTypes.ContainsKey(type.GetFullMetadataName())) return; if (!customTypes.Add(type)) return; @@ -261,7 +347,7 @@ namespace ComputeSharp.SourceGenerators.Mappings INamedTypeSymbol fieldType = (INamedTypeSymbol)field.Type; - if (!KnownTypes.ContainsKey(fieldType.GetFullMetadataName())) + if (!KnownHlslTypes.ContainsKey(fieldType.GetFullMetadataName())) { _ = dependencies.Add(fieldType); } diff --git a/src/ComputeSharp.SourceGenerators/SyntaxRewriters/ShaderSourceRewriter.cs b/src/ComputeSharp.SourceGenerators/SyntaxRewriters/ShaderSourceRewriter.cs index 637d6c36..a36f9e92 100644 --- a/src/ComputeSharp.SourceGenerators/SyntaxRewriters/ShaderSourceRewriter.cs +++ b/src/ComputeSharp.SourceGenerators/SyntaxRewriters/ShaderSourceRewriter.cs @@ -240,7 +240,22 @@ namespace ComputeSharp.SourceGenerators.SyntaxRewriters return CastExpression(updatedNode.Type, LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(0))); } - return InvocationExpression(updatedNode.Type, updatedNode.ArgumentList); + // Add explicit casts for matrix constructors to help the overload resolution + if (this.semanticModel.GetTypeInfo(node).Type is ITypeSymbol matrixType && + HlslKnownTypes.IsMatrixType(matrixType.GetFullMetadataName())) + { + for (int i = 0; i < node.ArgumentList!.Arguments.Count; i++) + { + IArgumentOperation argumentOperation = (IArgumentOperation)this.semanticModel.GetOperation(node.ArgumentList.Arguments[i])!; + INamedTypeSymbol elementType = (INamedTypeSymbol)argumentOperation.Parameter.Type; + + updatedNode = updatedNode.ReplaceNode( + updatedNode.ArgumentList!.Arguments[i].Expression, + CastExpression(IdentifierName(HlslKnownTypes.GetMappedName(elementType)), updatedNode.ArgumentList.Arguments[i].Expression)); + } + } + + return InvocationExpression(updatedNode.Type, updatedNode.ArgumentList!); } /// @@ -271,6 +286,21 @@ namespace ComputeSharp.SourceGenerators.SyntaxRewriters return CastExpression(explicitType, LiteralExpression(SyntaxKind.NumericLiteralExpression, Literal(0))); } + // Add explicit casts like with the explicit object creation expressions above + if (this.semanticModel.GetTypeInfo(node).Type is ITypeSymbol matrixType && + HlslKnownTypes.IsMatrixType(matrixType.GetFullMetadataName())) + { + for (int i = 0; i < node.ArgumentList.Arguments.Count; i++) + { + IArgumentOperation argumentOperation = (IArgumentOperation)this.semanticModel.GetOperation(node.ArgumentList.Arguments[i])!; + INamedTypeSymbol elementType = (INamedTypeSymbol)argumentOperation.Parameter.Type; + + updatedNode = updatedNode.ReplaceNode( + updatedNode.ArgumentList.Arguments[i].Expression, + CastExpression(IdentifierName(HlslKnownTypes.GetMappedName(elementType)), updatedNode.ArgumentList.Arguments[i].Expression)); + } + } + return InvocationExpression(explicitType, updatedNode.ArgumentList); } @@ -392,7 +422,9 @@ namespace ComputeSharp.SourceGenerators.SyntaxRewriters this.semanticModel.GetOperation(node) is IMemberReferenceOperation operation) { // If the member access is a constant, track it and replace the tree with the processed constant name - if (operation is IFieldReferenceOperation fieldOperation && fieldOperation.Field.IsConst) + if (operation is IFieldReferenceOperation fieldOperation && + fieldOperation.Field.IsConst && + fieldOperation.Type.TypeKind != TypeKind.Enum) { this.constantDefinitions[fieldOperation.Field] = ((IFormattable)fieldOperation.Field.ConstantValue!).ToString(null, CultureInfo.InvariantCulture); @@ -557,12 +589,54 @@ namespace ComputeSharp.SourceGenerators.SyntaxRewriters { var updatedNode = (ElementAccessExpressionSyntax)base.VisitElementAccessExpression(node)!; - if (this.semanticModel.GetOperation(node) is IPropertyReferenceOperation operation && - HlslKnownMembers.TryGetMappedIndexerTypeName(operation.Property.GetFullMetadataName(), out string? mapping)) + if (this.semanticModel.GetOperation(node) is IPropertyReferenceOperation operation) { - var index = InvocationExpression(IdentifierName(mapping!), ArgumentList(updatedNode.ArgumentList.Arguments)); + string propertyName = operation.Property.GetFullMetadataName(); - return updatedNode.WithArgumentList(BracketedArgumentList(SingletonSeparatedList(Argument(index)))); + // Rewrite texture resource indices taking vectors into individual indices as per HLSL spec. + // For instance: texture[ThreadIds.XY] will be rewritten as texture[ThreadIds.X, ThreadIds.Y]. + if (HlslKnownMembers.TryGetMappedResourceIndexerTypeName(propertyName, out string? mapping)) + { + var index = InvocationExpression(IdentifierName(mapping!), ArgumentList(updatedNode.ArgumentList.Arguments)); + + return updatedNode.WithArgumentList(BracketedArgumentList(SingletonSeparatedList(Argument(index)))); + } + + // If the current property is a swizzled matrix indexer, ensure all the arguments are constants, and rewrite + // the property access to the corresponding HLSL syntax. For instance, m[M11, M12] will become m._m00_m01. + if (HlslKnownMembers.IsKnownMatrixIndexer(propertyName)) + { + bool isValid = true; + + // Validate the arguments + foreach (ArgumentSyntax argument in node.ArgumentList.Arguments) + { + if (this.semanticModel.GetOperation(argument.Expression) is not IFieldReferenceOperation fieldReference || + !HlslKnownMembers.IsKnownMatrixIndex(fieldReference.Field.GetFullMetadataName())) + { + this.context.ReportDiagnostic(NonConstantMatrixSwizzledIndex, argument); + + isValid = false; + } + } + + if (isValid) + { + // Rewrite the indexer as a property access + string hlslPropertyName = string.Join("", + from argument in node.ArgumentList.Arguments + let fieldReference = (IFieldReferenceOperation)this.semanticModel.GetOperation(argument.Expression)! + let fieldName = fieldReference.Field.Name + let row = (char)(fieldName[1] - 1) + let column = (char)(fieldName[2] - 1) + select $"_m{row}{column}"); + + return MemberAccessExpression( + SyntaxKind.SimpleMemberAccessExpression, + updatedNode.Expression, + IdentifierName(hlslPropertyName)); + } + } } return updatedNode; @@ -596,7 +670,9 @@ namespace ComputeSharp.SourceGenerators.SyntaxRewriters { var updatedNode = (IdentifierNameSyntax)base.VisitIdentifierName(node)!; - if (this.semanticModel.GetOperation(node) is IFieldReferenceOperation operation && operation.Field.IsConst) + if (this.semanticModel.GetOperation(node) is IFieldReferenceOperation operation && + operation.Field.IsConst && + operation.Type.TypeKind != TypeKind.Enum) { this.constantDefinitions[operation.Field] = ((IFormattable)operation.Field.ConstantValue!).ToString(null, CultureInfo.InvariantCulture); diff --git a/src/ComputeSharp/ComputeSharp.csproj b/src/ComputeSharp/ComputeSharp.csproj index ddedae12..c35b06c5 100644 --- a/src/ComputeSharp/ComputeSharp.csproj +++ b/src/ComputeSharp/ComputeSharp.csproj @@ -30,6 +30,11 @@ + + True + True + Hlsl.tt + True True @@ -45,6 +50,11 @@ True Bool4.tt + + True + True + BoolMxN.tt + True True @@ -60,6 +70,11 @@ True Double4.tt + + True + True + DoubleMxN.tt + True True @@ -75,6 +90,11 @@ True Float4.tt + + True + True + FloatMxN.tt + True True @@ -90,6 +110,11 @@ True Int4.tt + + True + True + IntMxN.tt + True True @@ -105,9 +130,18 @@ True UInt4.tt + + True + True + UIntMxN.tt + + + TextTemplatingFileGenerator + Hlsl.g.cs + TextTemplatingFileGenerator Bool2.g.cs @@ -120,6 +154,10 @@ TextTemplatingFileGenerator Bool4.g.cs + + TextTemplatingFileGenerator + BoolMxN.g.cs + TextTemplatingFileGenerator Double2.g.cs @@ -132,6 +170,10 @@ TextTemplatingFileGenerator Double4.g.cs + + TextTemplatingFileGenerator + DoubleMxN.g.cs + TextTemplatingFileGenerator Float2.g.cs @@ -144,6 +186,10 @@ TextTemplatingFileGenerator Float4.g.cs + + TextTemplatingFileGenerator + FloatMxN.g.cs + TextTemplatingFileGenerator Int2.g.cs @@ -156,6 +202,10 @@ TextTemplatingFileGenerator Int4.g.cs + + TextTemplatingFileGenerator + IntMxN.g.cs + TextTemplatingFileGenerator UInt2.g.cs @@ -168,6 +218,10 @@ TextTemplatingFileGenerator UInt4.g.cs + + TextTemplatingFileGenerator + UIntMxN.g.cs + diff --git a/src/ComputeSharp/Core/Intrinsics/Attributes/HlslIntrinsicNameAttribute.cs b/src/ComputeSharp/Core/Intrinsics/Attributes/HlslIntrinsicNameAttribute.cs new file mode 100644 index 00000000..80e133e2 --- /dev/null +++ b/src/ComputeSharp/Core/Intrinsics/Attributes/HlslIntrinsicNameAttribute.cs @@ -0,0 +1,24 @@ +using System; + +namespace ComputeSharp.Core.Intrinsics.Attributes +{ + /// + /// An attribute indicating the native member name of a given HLSL intrinsic. + /// + internal sealed class HlslIntrinsicNameAttribute : Attribute + { + /// + /// Creates a new instance with the specified parameters. + /// + /// The name of the HLSL intrinsic. + public HlslIntrinsicNameAttribute(string name) + { + Name = name; + } + + /// + /// Gets the name of the HLSL intrinsic. + /// + public string Name { get; } + } +} diff --git a/src/ComputeSharp/Core/Intrinsics/Attributes/PreserveMemberNameAttribute.cs b/src/ComputeSharp/Core/Intrinsics/Attributes/PreserveMemberNameAttribute.cs deleted file mode 100644 index 5f789ece..00000000 --- a/src/ComputeSharp/Core/Intrinsics/Attributes/PreserveMemberNameAttribute.cs +++ /dev/null @@ -1,11 +0,0 @@ -using System; - -namespace ComputeSharp.Core.Intrinsics.Attributes -{ - /// - /// An attribute to indicate that a given member has the same name when mapped to HLSL. - /// - internal sealed class PreserveMemberNameAttribute : Attribute - { - } -} diff --git a/src/ComputeSharp/Core/Intrinsics/Hlsl.cs b/src/ComputeSharp/Core/Intrinsics/Hlsl.cs index dc8e838c..868a6f2b 100644 --- a/src/ComputeSharp/Core/Intrinsics/Hlsl.cs +++ b/src/ComputeSharp/Core/Intrinsics/Hlsl.cs @@ -1,158 +1,12 @@ -using System.Diagnostics.Contracts; -using ComputeSharp.Core.Intrinsics.Attributes; -using ComputeSharp.Exceptions; +using ComputeSharp.Exceptions; namespace ComputeSharp { /// /// A that maps the supported HLSL intrinsic functions that can be used in compute shaders. /// - public static class Hlsl + public static partial class Hlsl { - /// - /// Returns the absolute value of the specified value. - /// - /// The specified value. - /// The absolute value of the parameter. - [Pure] - public static int Abs(int x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Abs)}(int)"); - - /// - /// Returns the absolute value of the specified value. - /// - /// The specified value. - /// The absolute value of the parameter. - [Pure] - public static Int2 Abs(Int2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Abs)}({nameof(Int2)})"); - - /// - /// Returns the absolute value of the specified value. - /// - /// The specified value. - /// The absolute value of the parameter. - [Pure] - public static Int3 Abs(Int3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Abs)}({nameof(Int3)})"); - - /// - /// Returns the absolute value of the specified value. - /// - /// The specified value. - /// The absolute value of the parameter. - [Pure] - public static Int4 Abs(Int4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Abs)}({nameof(Int4)})"); - - /// - /// Returns the absolute value of the specified value. - /// - /// The specified value. - /// The absolute value of the parameter. - [Pure] - public static float Abs(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Abs)}(float)"); - - /// - /// Returns the absolute value of the specified value. - /// - /// The specified value. - /// The absolute value of the parameter. - [Pure] - public static Float2 Abs(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Abs)}({nameof(Float2)})"); - - /// - /// Returns the absolute value of the specified value. - /// - /// The specified value. - /// The absolute value of the parameter. - [Pure] - public static Float3 Abs(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Abs)}({nameof(Float3)})"); - - /// - /// Returns the absolute value of the specified value. - /// - /// The specified value. - /// The absolute value of the parameter. - [Pure] - public static Float4 Abs(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Abs)}({nameof(Float4)})"); - - /// - /// Returns the arccosine of the specified value. - /// - /// The specified value, which should be within the range [-1 to 1] - /// The arccosine of the parameter. - [Pure] - public static float Acos(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Acos)}(float)"); - - /// - /// Returns the arccosine of the specified value. - /// - /// The specified value, where each component should be within the range [-1 to 1] - /// The arccosine of the parameter. - [Pure] - public static Float2 Acos(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Acos)}({nameof(Float2)})"); - - /// - /// Returns the arccosine of the specified value. - /// - /// The specified value, where each component should be within the range [-1 to 1] - /// The arccosine of the parameter. - [Pure] - public static Float3 Acos(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Acos)}({nameof(Float3)})"); - - /// - /// Returns the arccosine of the specified value. - /// - /// The specified value, where each component should be within the range [-1 to 1] - /// The arccosine of the parameter. - [Pure] - public static Float3 Acos(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Acos)}({nameof(Float4)})"); - - /// - /// Determines if all components of the specified value are non-zero. - /// - /// The specified value. - /// if all components of the parameter are non-zero; otherwise, . - [Pure] - public static bool All(Int2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(All)}({nameof(Int2)})"); - - /// - /// Determines if all components of the specified value are non-zero. - /// - /// The specified value. - /// if all components of the parameter are non-zero; otherwise, . - [Pure] - public static bool All(Int3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(All)}({nameof(Int3)})"); - - /// - /// Determines if all components of the specified value are non-zero. - /// - /// The specified value. - /// if all components of the parameter are non-zero; otherwise, . - [Pure] - public static bool All(Int4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(All)}({nameof(Int4)})"); - - /// - /// Determines if all components of the specified value are non-zero. - /// - /// The specified value. - /// if all components of the parameter are non-zero; otherwise, . - [Pure] - public static bool All(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(All)}({nameof(Float2)})"); - - /// - /// Determines if all components of the specified value are non-zero. - /// - /// The specified value. - /// if all components of the parameter are non-zero; otherwise, . - [Pure] - public static bool All(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(All)}({nameof(Float3)})"); - - /// - /// Determines if all components of the specified value are non-zero. - /// - /// The specified value. - /// if all components of the parameter are non-zero; otherwise, . - [Pure] - public static bool All(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(All)}({nameof(Float4)})"); - /// /// Blocks execution of all threads in a group until all memory accesses have been completed. /// @@ -161,8 +15,7 @@ namespace ComputeSharp /// Threads are synchronized at GroupSync barriers. /// This may stall a thread or threads if memory operations are in progress. /// - [PreserveMemberName] - public static void AllMemoryBarrier() => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AllMemoryBarrier)}()"); + public static void AllMemoryBarrier() => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AllMemoryBarrier)}()"); /// /// Blocks execution of all threads in a group until all memory accesses have been completed and all threads in the group have reached this call. @@ -172,765 +25,41 @@ namespace ComputeSharp /// Threads are synchronized at GroupSync barriers. /// This may stall a thread or threads if memory operations are in progress. /// - [PreserveMemberName] - public static void AllMemoryBarrierWithGroupSync() => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AllMemoryBarrierWithGroupSync)}()"); - - /// - /// Determines if any components of the specified value are non-zero. - /// - /// The specified value. - /// if any components of the parameter are non-zero; otherwise, . - [Pure] - public static bool Any(Int2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Any)}({nameof(Int2)})"); - - /// - /// Determines if any components of the specified value are non-zero. - /// - /// The specified value. - /// if any components of the parameter are non-zero; otherwise, . - [Pure] - public static bool Any(Int3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Any)}({nameof(Int3)})"); - - /// - /// Determines if any components of the specified value are non-zero. - /// - /// The specified value. - /// if any components of the parameter are non-zero; otherwise, . - [Pure] - public static bool Any(Int4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Any)}({nameof(Int4)})"); - - /// - /// Determines if any components of the specified value are non-zero. - /// - /// The specified value. - /// if any components of the parameter are non-zero; otherwise, . - [Pure] - public static bool Any(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Any)}({nameof(Float2)})"); - - /// - /// Determines if any components of the specified value are non-zero. - /// - /// The specified value. - /// if any components of the parameter are non-zero; otherwise, . - [Pure] - public static bool Any(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Any)}({nameof(Float3)})"); - - /// - /// Determines if any components of the specified value are non-zero. - /// - /// The specified value. - /// if any components of the parameter are non-zero; otherwise, . - [Pure] - public static bool Any(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Any)}({nameof(Float4)})"); - - /// - /// Reinterprets a cast value (two 32-bit values) into a . - /// - /// The low 32-bit pattern of the input value. - /// The high 32-bit pattern of the input value. - /// The input (two 32-bit values) recast as a . - [Pure] - public static double AsDouble(uint lowBits, uint highBits) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AsDouble)}(uint,uint)"); - - /// - /// Reinterprets a cast value (two 32-bit values) into a . - /// - /// The low 32-bit pattern of the input value. - /// The high 32-bit pattern of the input value. - /// The input (two 32-bit values) recast as a . - [Pure] - public static Double2 AsDouble(UInt2 lowBits, UInt2 highBits) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AsDouble)}({nameof(UInt2)},{nameof(UInt2)})"); - - /// - /// Interprets the bit pattern of as a floating-point number. - /// - /// The input value. - /// The input interpreted as a floating-point number. - [Pure] - public static float AsFloat(int x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AsFloat)}(int)"); - - /// - /// Interprets the bit pattern of as a floating-point number. - /// - /// The input value. - /// The input interpreted as a floating-point number. - [Pure] - public static Float2 AsFloat(Int2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AsFloat)}({nameof(Int2)})"); - - /// - /// Interprets the bit pattern of as a floating-point number. - /// - /// The input value. - /// The input interpreted as a floating-point number. - [Pure] - public static Float3 AsFloat(Int3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AsFloat)}({nameof(Int3)})"); - - /// - /// Interprets the bit pattern of as a floating-point number. - /// - /// The input value. - /// The input interpreted as a floating-point number. - [Pure] - public static Float4 AsFloat(Int4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AsFloat)}({nameof(Int4)})"); - - /// - /// Interprets the bit pattern of as a floating-point number. - /// - /// The input value. - /// The input interpreted as a floating-point number. - [Pure] - public static float AsFloat(uint x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AsFloat)}(uint)"); - - /// - /// Interprets the bit pattern of as a floating-point number. - /// - /// The input value. - /// The input interpreted as a floating-point number. - [Pure] - public static Float2 AsFloat(UInt2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AsFloat)}({nameof(UInt2)})"); - - /// - /// Interprets the bit pattern of as a floating-point number. - /// - /// The input value. - /// The input interpreted as a floating-point number. - [Pure] - public static Float3 AsFloat(UInt3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AsFloat)}({nameof(UInt3)})"); - - /// - /// Interprets the bit pattern of as a floating-point number. - /// - /// The input value. - /// The input interpreted as a floating-point number. - [Pure] - public static Float4 AsFloat(UInt4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(AsFloat)}({nameof(UInt4)})"); - - /// - /// Returns the arcsine of the specified value. - /// - /// The specified value, which should be within the range [-1 to 1] - /// The arcsine of the parameter. - [Pure] - public static float Asin(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Asin)}(float)"); - - /// - /// Returns the arcsine of the specified value. - /// - /// The specified value, where each component should be within the range [-1 to 1] - /// The arcsine of the parameter. - [Pure] - public static Float2 Asin(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Asin)}({nameof(Float2)})"); - - /// - /// Returns the arcsine of the specified value. - /// - /// The specified value, where each component should be within the range [-1 to 1] - /// The arcsine of the parameter. - [Pure] - public static Float3 Asin(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Asin)}({nameof(Float3)})"); - - /// - /// Returns the arcsine of the specified value. - /// - /// The specified value, where each component should be within the range [-1 to 1] - /// The arcsine of the parameter. - [Pure] - public static Float3 Asin(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Asin)}({nameof(Float4)})"); - - /// - /// Returns the arctangent of the specified value. - /// - /// The specified value. - /// The arctangent of the parameter. - [Pure] - public static float Atan(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Atan)}(float)"); - - /// - /// Returns the arctangent of the specified value. - /// - /// The specified value. - /// The arctangent of the parameter. - [Pure] - public static Float2 Atan(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Atan)}({nameof(Float2)})"); - - /// - /// Returns the arctangent of the specified value. - /// - /// The specified value. - /// The arctangent of the parameter. - [Pure] - public static Float3 Atan(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Atan)}({nameof(Float3)})"); - - /// - /// Returns the arctangent of the specified value. - /// - /// The specified value. - /// The arctangent of the parameter. - [Pure] - public static Float3 Atan(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Atan)}({nameof(Float4)})"); - - /// - /// Returns the arctangent of two values (,) - /// - /// The value. - /// The value. - /// The arctangent of (,) - [Pure] - public static float Atan2(float y, float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Atan2)}(float,float)"); - - /// - /// Returns the arctangent of two values (,) - /// - /// The value. - /// The value. - /// The arctangent of (,) - [Pure] - public static Float2 Atan2(Float2 y, Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Atan2)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Returns the arctangent of two values (,) - /// - /// The value. - /// The value. - /// The arctangent of (,) - [Pure] - public static Float3 Atan2(Float3 y, Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Atan2)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Returns the arctangent of two values (,) - /// - /// The value. - /// The value. - /// The arctangent of (,) - [Pure] - public static Float3 Atan2(Float4 y, Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Atan2)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Returns the smallest integer value that is greater than or equal to the specified value. - /// - /// The specified value. - /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. - [Pure] - public static float Ceil(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Ceil)}(float)"); - - /// - /// Returns the smallest integer value that is greater than or equal to the specified value. - /// - /// The specified value. - /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. - [Pure] - public static Float2 Ceil(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Ceil)}({nameof(Float2)})"); - - /// - /// Returns the smallest integer value that is greater than or equal to the specified value. - /// - /// The specified value. - /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. - [Pure] - public static Float3 Ceil(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Ceil)}({nameof(Float3)})"); - - /// - /// Returns the smallest integer value that is greater than or equal to the specified value. - /// - /// The specified value. - /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. - [Pure] - public static Float3 Ceil(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Ceil)}({nameof(Float4)})"); - - /// - /// Clamps the specified value to the specified minimum and maximum range. - /// - /// A value to clamp. - /// The specified minimum range. - /// The specified maximum range. - /// The clamped value for the x parameter. - /// For values of -INF or INF, clamp will behave as expected. However for values of NaN, the results are undefined. - [Pure] - public static int Clamp(int x, int min, int max) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Clamp)}(int,int,int)"); - - /// - /// Clamps the specified value to the specified minimum and maximum range. - /// - /// A value to clamp. - /// The specified minimum range. - /// The specified maximum range. - /// The clamped value for the x parameter. - /// For values of -INF or INF, clamp will behave as expected. However for values of NaN, the results are undefined. - [Pure] - public static Int2 Clamp(Int2 x, Int2 min, Int2 max) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Clamp)}({nameof(Int2)},{nameof(Int2)},{nameof(Int2)})"); - - /// - /// Clamps the specified value to the specified minimum and maximum range. - /// - /// A value to clamp. - /// The specified minimum range. - /// The specified maximum range. - /// The clamped value for the x parameter. - /// For values of -INF or INF, clamp will behave as expected. However for values of NaN, the results are undefined. - [Pure] - public static Int3 Clamp(Int3 x, Int3 min, Int3 max) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Clamp)}({nameof(Int3)},{nameof(Int3)},{nameof(Int3)})"); - - /// - /// Clamps the specified value to the specified minimum and maximum range. - /// - /// A value to clamp. - /// The specified minimum range. - /// The specified maximum range. - /// The clamped value for the x parameter. - /// For values of -INF or INF, clamp will behave as expected. However for values of NaN, the results are undefined. - [Pure] - public static Int4 Clamp(Int4 x, Int4 min, Int4 max) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Clamp)}({nameof(Int4)},{nameof(Int4)},{nameof(Int4)})"); - - /// - /// Clamps the specified value to the specified minimum and maximum range. - /// - /// A value to clamp. - /// The specified minimum range. - /// The specified maximum range. - /// The clamped value for the x parameter. - /// For values of -INF or INF, clamp will behave as expected. However for values of NaN, the results are undefined. - [Pure] - public static float Clamp(float x, float min, float max) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Clamp)}(float,float,float)"); - - /// - /// Clamps the specified value to the specified minimum and maximum range. - /// - /// A value to clamp. - /// The specified minimum range. - /// The specified maximum range. - /// The clamped value for the x parameter. - /// For values of -INF or INF, clamp will behave as expected. However for values of NaN, the results are undefined. - [Pure] - public static Float2 Clamp(Float2 x, Float2 min, Float2 max) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Clamp)}({nameof(Float2)},{nameof(Float2)},{nameof(Float2)})"); - - /// - /// Clamps the specified value to the specified minimum and maximum range. - /// - /// A value to clamp. - /// The specified minimum range. - /// The specified maximum range. - /// The clamped value for the x parameter. - /// For values of -INF or INF, clamp will behave as expected. However for values of NaN, the results are undefined. - [Pure] - public static Float3 Clamp(Float3 x, Float3 min, Float3 max) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Clamp)}({nameof(Float3)},{nameof(Float3)},{nameof(Float3)})"); - - /// - /// Clamps the specified value to the specified minimum and maximum range. - /// - /// A value to clamp. - /// The specified minimum range. - /// The specified maximum range. - /// The clamped value for the x parameter. - /// For values of -INF or INF, clamp will behave as expected. However for values of NaN, the results are undefined. - [Pure] - public static Float4 Clamp(Float4 x, Float4 min, Float4 max) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Clamp)}({nameof(Float4)},{nameof(Float4)},{nameof(Float4)})"); - - /// - /// Returns the cosine of the specified value. - /// - /// The specified value, radians. - /// The cosine of the parameter. - [Pure] - public static float Cos(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Cos)}(float)"); - - /// - /// Returns the cosine of the specified value. - /// - /// The specified value, radians. - /// The cosine of the parameter. - [Pure] - public static Float2 Cos(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Cos)}({nameof(Float2)})"); - - /// - /// Returns the cosine of the specified value. - /// - /// The specified value, radians. - /// The cosine of the parameter. - [Pure] - public static Float3 Cos(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Cos)}({nameof(Float3)})"); - - /// - /// Returns the cosine of the specified value. - /// - /// The specified value, radians. - /// The cosine of the parameter. - [Pure] - public static Float3 Cos(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Cos)}({nameof(Float4)})"); - - /// - /// Returns the hyperbolic cosine of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic cosine of the parameter. - [Pure] - public static float Cosh(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Cosh)}(float)"); - - /// - /// Returns the hyperbolic cosine of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic cosine of the parameter. - [Pure] - public static Float2 Cosh(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Cosh)}({nameof(Float2)})"); - - /// - /// Returns the hyperbolic cosine of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic cosine of the parameter. - [Pure] - public static Float3 Cosh(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Cosh)}({nameof(Float3)})"); - - /// - /// Returns the hyperbolic cosine of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic cosine of the parameter. - [Pure] - public static Float3 Cosh(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Cosh)}({nameof(Float4)})"); - - /// - /// Counts the number of bits in the input value. - /// - /// The input value. - /// The number of bits. - [Pure] - public static uint CountBits(uint x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(CountBits)}(uint)"); - - /// - /// Returns the cross product of two values. - /// - /// The first vector. - /// The second vector. - /// The cross product of the parameter and the parameter. - [Pure] - public static Float3 Cross(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Cross)}({nameof(Float3)})"); - - /// - /// Converts the specified value from radians to degrees. - /// - /// The specified value. - /// The result of converting the parameter from radians to degrees. - [Pure] - public static float Degrees(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Degrees)}(float)"); - - /// - /// Converts the specified value from radians to degrees. - /// - /// The specified value. - /// The result of converting the parameter from radians to degrees. - [Pure] - public static Float2 Degrees(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Degrees)}({nameof(Float2)})"); - - /// - /// Converts the specified value from radians to degrees. - /// - /// The specified value. - /// The result of converting the parameter from radians to degrees. - [Pure] - public static Float3 Degrees(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Degrees)}({nameof(Float3)})"); - - /// - /// Converts the specified value from radians to degrees. - /// - /// The specified value. - /// The result of converting the parameter from radians to degrees. - [Pure] - public static Float3 Degrees(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Degrees)}({nameof(Float4)})"); + public static void AllMemoryBarrierWithGroupSync() => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AllMemoryBarrierWithGroupSync)}()"); /// /// Blocks execution of all threads in a group until all device memory accesses have been completed. /// - [PreserveMemberName] - public static void DeviceMemoryBarrier() => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(DeviceMemoryBarrier)}()"); + public static void DeviceMemoryBarrier() => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(DeviceMemoryBarrier)}()"); /// /// Blocks execution of all threads in a group until all device memory accesses have been completed and all threads in the group have reached this call. /// - [PreserveMemberName] - public static void DeviceMemoryBarrierWithGroupSync() => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(DeviceMemoryBarrierWithGroupSync)}()"); - - /// - /// Returns a distance scalar between two values. - /// - /// The first value to compare. - /// The second value to compare. - /// A scalar value that represents the distance between the parameter and the parameter. - [Pure] - public static float Distance(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Distance)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Returns a distance scalar between two values. - /// - /// The first value to compare. - /// The second value to compare. - /// A scalar value that represents the distance between the parameter and the parameter. - [Pure] - public static float Distance(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Distance)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Returns a distance scalar between two values. - /// - /// The first value to compare. - /// The second value to compare. - /// A scalar value that represents the distance between the parameter and the parameter. - [Pure] - public static float Distance(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Distance)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Returns the dot product of two values. - /// - /// The first vector. - /// The second vector. - /// The dot product of the parameter and the parameter. - [Pure] - public static float Dot(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Dot)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Returns the dot product of two values. - /// - /// The first vector. - /// The second vector. - /// The dot product of the parameter and the parameter. - [Pure] - public static float Dot(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Dot)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Returns the dot product of two values. - /// - /// The first vector. - /// The second vector. - /// The dot product of the parameter and the parameter. - [Pure] - public static float Dot(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Dot)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Returns the base-e exponential of the specified value. - /// - /// The specified value. - /// The base-e exponential of the parameter. - [Pure] - public static float Exp(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Exp)}(float)"); - - /// - /// Returns the base-e exponential of the specified value. - /// - /// The specified value. - /// The base-e exponential of the parameter. - [Pure] - public static Float2 Exp(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Exp)}({nameof(Float2)})"); - - /// - /// Returns the base-e exponential of the specified value. - /// - /// The specified value. - /// The base-e exponential of the parameter. - [Pure] - public static Float3 Exp(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Exp)}({nameof(Float3)})"); - - /// - /// Returns the base-e exponential of the specified value. - /// - /// The specified value. - /// The base-e exponential of the parameter. - [Pure] - public static Float4 Exp(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Exp)}({nameof(Float4)})"); - - /// - /// Returns the base-2 exponential of the specified value. - /// - /// The specified value. - /// The base-2 exponential of the parameter. - [Pure] - public static float Exp2(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Exp2)}(float)"); - - /// - /// Returns the base-2 exponential of the specified value. - /// - /// The specified value. - /// The base-2 exponential of the parameter. - [Pure] - public static Float2 Exp2(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Exp2)}({nameof(Float2)})"); - - /// - /// Returns the base-2 exponential of the specified value. - /// - /// The specified value. - /// The base-2 exponential of the parameter. - [Pure] - public static Float3 Exp2(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Exp2)}({nameof(Float3)})"); - - /// - /// Returns the base-2 exponential of the specified value. - /// - /// The specified value. - /// The base-2 exponential of the parameter. - [Pure] - public static Float4 Exp2(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Exp2)}({nameof(Float4)})"); - - /// - /// Returns the largest integer that is less than or equal to the specified value. - /// - /// The specified value. - /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. - [Pure] - public static float Floor(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Floor)}(float)"); - - /// - /// Returns the largest integer that is less than or equal to the specified value. - /// - /// The specified value. - /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. - [Pure] - public static Float2 Floor(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Floor)}({nameof(Float2)})"); - - /// - /// Returns the largest integer that is less than or equal to the specified value. - /// - /// The specified value. - /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. - [Pure] - public static Float3 Floor(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Floor)}({nameof(Float3)})"); - - /// - /// Returns the largest integer that is less than or equal to the specified value. - /// - /// The specified value. - /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. - [Pure] - public static Float4 Floor(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Floor)}({nameof(Float4)})"); - - /// - /// Returns the floating-point remainder of /. - /// - /// The divident. - /// The divisor. - /// The floating-point remainder of the parameter divided by the parameter. - [Pure] - public static float Fmod(float x, float y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Fmod)}(float)"); - - /// - /// Returns the floating-point remainder of /. - /// - /// The divident. - /// The divisor. - /// The floating-point remainder of the parameter divided by the parameter. - [Pure] - public static Float2 Fmod(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Fmod)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Returns the floating-point remainder of /. - /// - /// The divident. - /// The divisor. - /// The floating-point remainder of the parameter divided by the parameter. - [Pure] - public static Float3 Fmod(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Fmod)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Returns the floating-point remainder of /. - /// - /// The divident. - /// The divisor. - /// The floating-point remainder of the parameter divided by the parameter. - [Pure] - public static Float4 Fmod(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Fmod)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Returns the fractional (or decimal) part of , which is greater than or equal to 0 and less than 1. - /// - /// The specified value. - /// The fractional part of the parameter. - [Pure] - public static float Frac(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Frac)}(float)"); - - /// - /// Returns the fractional (or decimal) part of , which is greater than or equal to 0 and less than 1. - /// - /// The specified value. - /// The fractional part of the parameter. - [Pure] - public static Float2 Frac(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Frac)}({nameof(Float2)})"); - - /// - /// Returns the fractional (or decimal) part of , which is greater than or equal to 0 and less than 1. - /// - /// The specified value. - /// The fractional part of the parameter. - [Pure] - public static Float3 Frac(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Frac)}({nameof(Float3)})"); - - /// - /// Returns the fractional (or decimal) part of , which is greater than or equal to 0 and less than 1. - /// - /// The specified value. - /// The fractional part of the parameter. - [Pure] - public static Float4 Frac(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Frac)}({nameof(Float4)})"); - - /// - /// Returns the mantissa and exponent of the specified floating-point value. - /// - /// The specified floating-point value (if the x parameter is 0, this function returns 0 for both the mantissa and the exponent) - /// The returned exponent of the parameter. - /// The fractional part of the parameter. - [Pure] - public static float Frexp(float x, out float exp) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Frexp)}(float,float)"); - - /// - /// Returns the mantissa and exponent of the specified floating-point value. - /// - /// The specified floating-point value (if the x parameter is 0, this function returns 0 for both the mantissa and the exponent) - /// The returned exponent of the parameter. - /// The fractional part of the parameter. - [Pure] - public static Float2 Frexp(Float2 x, out Float2 exp) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Frexp)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Returns the mantissa and exponent of the specified floating-point value. - /// - /// The specified floating-point value (if the x parameter is 0, this function returns 0 for both the mantissa and the exponent) - /// The returned exponent of the parameter. - /// The fractional part of the parameter. - [Pure] - public static Float3 Frexp(Float3 x, out Float3 exp) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Frac)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Returns the mantissa and exponent of the specified floating-point value. - /// - /// The specified floating-point value (if the x parameter is 0, this function returns 0 for both the mantissa and the exponent) - /// The returned exponent of the parameter. - /// The fractional part of the parameter. - [Pure] - public static Float4 Frexp(Float4 x, out Float4 exp) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Frexp)}({nameof(Float4)},{nameof(Float4)})"); + public static void DeviceMemoryBarrierWithGroupSync() => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(DeviceMemoryBarrierWithGroupSync)}()"); /// /// Blocks execution of all threads in a group until all group shared accesses have been completed. /// - [PreserveMemberName] - public static void GroupMemoryBarrier() => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(GroupMemoryBarrier)}()"); + public static void GroupMemoryBarrier() => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(GroupMemoryBarrier)}()"); /// /// Blocks execution of all threads in a group until all group shared accesses have been completed and all threads in the group have reached this call. /// - [PreserveMemberName] - public static void GroupMemoryBarrierWithGroupSync() => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(GroupMemoryBarrierWithGroupSync)}()"); + public static void GroupMemoryBarrierWithGroupSync() => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(GroupMemoryBarrierWithGroupSync)}()"); /// /// Performs a guaranteed atomic add of a value to a destination. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedAdd(int destination, int value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedAdd)}(int,int)"); + public static void InterlockedAdd(int destination, int value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedAdd)}({typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic add of a value to a destination. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedAdd(uint destination, uint value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedAdd)}(uint,uint)"); + public static void InterlockedAdd(uint destination, uint value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedAdd)}({typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic add of a value to a destination. @@ -938,8 +67,7 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original input value. - [PreserveMemberName] - public static void InterlockedAdd(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedAdd)}(int,int,int)"); + public static void InterlockedAdd(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedAdd)}({typeof(int)}, {typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic add of a value to a destination. @@ -947,24 +75,21 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original input value. - [PreserveMemberName] - public static void InterlockedAdd(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedAdd)}(uint,uint,uint)"); + public static void InterlockedAdd(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedAdd)}({typeof(uint)}, {typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic and of a value to a destination. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedAnd(int destination, int value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedAnd)}(int,int)"); + public static void InterlockedAnd(int destination, int value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedAnd)}({typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic and of a value to a destination. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedAnd(uint destination, uint value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedAnd)}(uint,uint)"); + public static void InterlockedAnd(uint destination, uint value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedAnd)}({typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic and of a value to a destination. @@ -972,8 +97,7 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original input value. - [PreserveMemberName] - public static void InterlockedAnd(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedAnd)}(int,int,int)"); + public static void InterlockedAnd(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedAnd)}({typeof(int)}, {typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic and of a value to a destination. @@ -981,8 +105,7 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original input value. - [PreserveMemberName] - public static void InterlockedAnd(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedAnd)}(uint,uint,uint)"); + public static void InterlockedAnd(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedAnd)}({typeof(uint)}, {typeof(uint)}, {typeof(uint)})"); /// /// Atomically compares the destination with the comparison value. If they are identical, the destination @@ -992,8 +115,7 @@ namespace ComputeSharp /// The comparison value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedCompareExchange(int destination, int comparison, int value, out int original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedCompareExchange)}(int,int,int,int)"); + public static void InterlockedCompareExchange(int destination, int comparison, int value, out int original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedCompareExchange)}({typeof(int)}, {typeof(int)}, {typeof(int)}, {typeof(int)})"); /// /// Atomically compares the destination with the comparison value. If they are identical, the destination @@ -1003,8 +125,7 @@ namespace ComputeSharp /// The comparison value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedCompareExchange(uint destination, uint comparison, uint value, out uint original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedCompareExchange)}(uint,uint,uint,uint)"); + public static void InterlockedCompareExchange(uint destination, uint comparison, uint value, out uint original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedCompareExchange)}({typeof(uint)}, {typeof(uint)}, {typeof(uint)}, {typeof(uint)})"); /// /// Atomically compares the destination to the comparison value. If they @@ -1013,8 +134,7 @@ namespace ComputeSharp /// The destination value. /// The comparison value. /// The input value. - [PreserveMemberName] - public static void InterlockedCompareStore(int destination, int comparison, int value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedCompareStore)}(int,int,int)"); + public static void InterlockedCompareStore(int destination, int comparison, int value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedCompareStore)}({typeof(int)}, {typeof(int)}, {typeof(int)})"); /// /// Atomically compares the destination to the comparison value. If they @@ -1023,8 +143,7 @@ namespace ComputeSharp /// The destination value. /// The comparison value. /// The input value. - [PreserveMemberName] - public static void InterlockedCompareStore(uint destination, uint comparison, uint value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedCompareStore)}(uint,uint,uint)"); + public static void InterlockedCompareStore(uint destination, uint comparison, uint value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedCompareStore)}({typeof(uint)}, {typeof(uint)}, {typeof(uint)})"); /// /// Assigns value to dest and returns the original value. @@ -1032,8 +151,7 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedExchange(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedExchange)}(int,int,int)"); + public static void InterlockedExchange(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedExchange)}({typeof(int)}, {typeof(int)}, {typeof(int)})"); /// /// Assigns value to dest and returns the original value. @@ -1041,24 +159,21 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedExchange(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedExchange)}(uint,uint,uint)"); + public static void InterlockedExchange(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedExchange)}({typeof(uint)}, {typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic max. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedMax(int destination, int value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedMax)}(int,int)"); + public static void InterlockedMax(int destination, int value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedMax)}({typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic max. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedMax(uint destination, uint value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedMax)}(uint,uint)"); + public static void InterlockedMax(uint destination, uint value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedMax)}({typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic max. @@ -1066,8 +181,7 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedMax(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedMax)}(int,int,int)"); + public static void InterlockedMax(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedMax)}({typeof(int)}, {typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic max. @@ -1075,24 +189,21 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedMax(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedMax)}(uint,uint,uint)"); + public static void InterlockedMax(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedMax)}({typeof(uint)}, {typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic min. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedMin(int destination, int value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedMin)}(int,int)"); + public static void InterlockedMin(int destination, int value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedMin)}({typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic min. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedMin(uint destination, uint value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedMin)}(uint,uint)"); + public static void InterlockedMin(uint destination, uint value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedMin)}({typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic min. @@ -1100,8 +211,7 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedMin(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedMin)}(int,int,int)"); + public static void InterlockedMin(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedMin)}({typeof(int)}, {typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic min. @@ -1109,24 +219,21 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedMin(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedMin)}(uint,uint,uint)"); + public static void InterlockedMin(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedMin)}({typeof(uint)}, {typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic or. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedOr(int destination, int value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedOr)}(int,int)"); + public static void InterlockedOr(int destination, int value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedOr)}({typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic or. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedOr(uint destination, uint value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedOr)}(uint,uint)"); + public static void InterlockedOr(uint destination, uint value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedOr)}({typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic or. @@ -1134,8 +241,7 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedOr(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedOr)}(int,int,int)"); + public static void InterlockedOr(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedOr)}({typeof(int)}, {typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic or. @@ -1143,24 +249,21 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedOr(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedOr)}(uint,uint,uint)"); + public static void InterlockedOr(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedOr)}({typeof(uint)}, {typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic xor. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedXor(int destination, int value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedXor)}(int,int)"); + public static void InterlockedXor(int destination, int value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedXor)}({typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic xor. /// /// The destination value. /// The input value. - [PreserveMemberName] - public static void InterlockedXor(uint destination, uint value) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedXor)}(uint,uint)"); + public static void InterlockedXor(uint destination, uint value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedXor)}({typeof(uint)}, {typeof(uint)})"); /// /// Performs a guaranteed atomic xor. @@ -1168,8 +271,7 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedXor(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedXor)}(int,int,int)"); + public static void InterlockedXor(int destination, int value, out int original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedXor)}({typeof(int)}, {typeof(int)}, {typeof(int)})"); /// /// Performs a guaranteed atomic xor. @@ -1177,1044 +279,6 @@ namespace ComputeSharp /// The destination value. /// The input value. /// The original value. - [PreserveMemberName] - public static void InterlockedXor(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(InterlockedXor)}(uint,uint,uint)"); - - /// - /// Determines if the specified floating-point value is finite. - /// - /// The specified value. - /// Returns if the parameter is finite, otherwise . - [Pure] - public static bool IsFinite(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(IsFinite)}(float)"); - - /// - /// Determines if the specified floating-point value is infinite. - /// - /// The specified value. - /// Returns if the parameter is infinite, otherwise . - [Pure] - public static bool IsInfinite(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(IsInfinite)}(float)"); - - /// - /// Determines if the specified floating-point value is . - /// - /// The specified value. - /// Returns if the parameter is , otherwise . - [Pure] - public static bool IsNaN(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(IsNaN)}(float)"); - - /// - /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. - /// - /// The specified value. - /// The specified exponent. - /// The result of multiplying the parameter by two, raised to the power of the parameter. - [Pure] - public static float Ldexp(float x, float exp) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Ldexp)}(float)"); - - /// - /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. - /// - /// The specified value. - /// The specified exponent. - /// The result of multiplying the parameter by two, raised to the power of the parameter. - [Pure] - public static Float2 Ldexp(Float2 x, Float2 exp) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Ldexp)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. - /// - /// The specified value. - /// The specified exponent. - /// The result of multiplying the parameter by two, raised to the power of the parameter. - [Pure] - public static Float3 Ldexp(Float3 x, Float3 exp) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Ldexp)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. - /// - /// The specified value. - /// The specified exponent. - /// The result of multiplying the parameter by two, raised to the power of the parameter. - [Pure] - public static Float4 Ldexp(Float4 x, Float4 exp) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Ldexp)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Returns the length of the specified floating-point vector. - /// - /// The specified floating-point vector. - /// A floating-point scalar that represents the length of the x parameter. - [Pure] - public static float Length(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Length)}({nameof(Float2)})"); - - /// - /// Returns the length of the specified floating-point vector. - /// - /// The specified floating-point vector. - /// A floating-point scalar that represents the length of the x parameter. - [Pure] - public static float Length(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Length)}({nameof(Float3)})"); - - /// - /// Returns the length of the specified floating-point vector. - /// - /// The specified floating-point vector. - /// A floating-point scalar that represents the length of the x parameter. - [Pure] - public static float Length(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Length)}({nameof(Float4)})"); - - /// - /// Performs a linear interpolation. - /// - /// The first value. - /// The second value. - /// A value that linearly interpolates between the parameter and the parameter. - /// The result of the linear interpolation. - [Pure] - public static float Lerp(float x, float y, float s) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Lerp)}(float,float,float)"); - - /// - /// Performs a linear interpolation. - /// - /// The first value. - /// The second value. - /// A value that linearly interpolates between the parameter and the parameter. - /// The result of the linear interpolation. - [Pure] - public static Float2 Lerp(Float2 x, Float2 y, Float2 s) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Lerp)}({nameof(Float2)},{nameof(Float2)},{nameof(Float2)})"); - - /// - /// Performs a linear interpolation. - /// - /// The first value. - /// The second value. - /// A value that linearly interpolates between the parameter and the parameter. - /// The result of the linear interpolation. - [Pure] - public static Float3 Lerp(Float3 x, Float3 y, Float3 s) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Lerp)}({nameof(Float3)},{nameof(Float3)},{nameof(Float3)})"); - - /// - /// Performs a linear interpolation. - /// - /// The first value. - /// The second value. - /// A value that linearly interpolates between the parameter and the parameter. - /// The result of the linear interpolation. - [Pure] - public static Float2 Lerp(Float4 x, Float4 y, Float4 s) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Lerp)}({nameof(Float4)},{nameof(Float4)},{nameof(Float4)})"); - - /// - /// Returns the base-e logarithm of the specified value. - /// - /// The specified value. - /// The base-e logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static float Log(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log)}(float)"); - - /// - /// Returns the base-e logarithm of the specified value. - /// - /// The specified value. - /// The base-e logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static Float2 Log(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log)}({nameof(Float2)})"); - - /// - /// Returns the base-e logarithm of the specified value. - /// - /// The specified value. - /// The base-e logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static Float3 Log(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log)}({nameof(Float3)})"); - - /// - /// Returns the base-e logarithm of the specified value. - /// - /// The specified value. - /// The base-e logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static Float4 Log(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log)}({nameof(Float4)})"); - - /// - /// Returns the base-10 logarithm of the specified value. - /// - /// The specified value. - /// The base-10 logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static float Log10(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log10)}(float)"); - - /// - /// Returns the base-10 logarithm of the specified value. - /// - /// The specified value. - /// The base-10 logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static Float2 Log10(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log10)}({nameof(Float2)})"); - - /// - /// Returns the base-10 logarithm of the specified value. - /// - /// The specified value. - /// The base-10 logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static Float3 Log10(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log10)}({nameof(Float3)})"); - - /// - /// Returns the base-10 logarithm of the specified value. - /// - /// The specified value. - /// The base-10 logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static Float4 Log10(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log10)}({nameof(Float4)})"); - - /// - /// Returns the base-2 logarithm of the specified value. - /// - /// The specified value. - /// The base-2 logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static float Log2(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log2)}(float)"); - - /// - /// Returns the base-2 logarithm of the specified value. - /// - /// The specified value. - /// The base-2 logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static Float2 Log2(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log2)}({nameof(Float2)})"); - - /// - /// Returns the base-2 logarithm of the specified value. - /// - /// The specified value. - /// The base-2 logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static Float3 Log2(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log2)}({nameof(Float3)})"); - - /// - /// Returns the base-2 logarithm of the specified value. - /// - /// The specified value. - /// The base-2 logarithm of the parameter (if parameter is negative this function returns indefinite, and if is 0, this function returns -INF) - [Pure] - public static Float4 Log2(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Log2)}({nameof(Float4)})"); - - /// - /// Selects the greater of and . - /// - /// The first specified value. - /// The second specified exponent. - /// The or parameter, whichever is the largest value. - /// For values of -INF or INF, will behave as expected. - [Pure] - public static int Max(int x, int y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Max)}(int,int)"); - - /// - /// Selects the greater of and . - /// - /// The first specified value. - /// The second specified exponent. - /// The or parameter, whichever is the largest value. - /// For values of -INF or INF, will behave as expected, but for for values of , the results are undefined. - [Pure] - public static float Max(float x, float y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Max)}(float,float)"); - - /// - /// Selects the greater of and . - /// - /// The first specified value. - /// The second specified exponent. - /// The or parameter, whichever is the largest value. - /// For values of -INF or INF, will behave as expected, but for for values of , the results are undefined. - [Pure] - public static Float2 Max(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Max)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Selects the greater of and . - /// - /// The first specified value. - /// The second specified exponent. - /// The or parameter, whichever is the largest value. - /// For values of -INF or INF, will behave as expected, but for for values of , the results are undefined. - [Pure] - public static Float3 Max(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Max)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Selects the greater of and . - /// - /// The first specified value. - /// The second specified exponent. - /// The or parameter, whichever is the largest value. - /// For values of -INF or INF, will behave as expected, but for for values of , the results are undefined. - [Pure] - public static Float4 Max(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Max)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Selects the lesser of and . - /// - /// The first specified value. - /// The second specified exponent. - /// The or parameter, whichever is the smallest value. - /// For values of -INF or INF, will behave as expected. - [Pure] - public static int Min(int x, int y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Min)}(int,int)"); - - /// - /// Selects the lesser of and . - /// - /// The first specified value. - /// The second specified exponent. - /// The or parameter, whichever is the smallest value. - /// For values of -INF or INF, will behave as expected, but for for values of , the results are undefined. - [Pure] - public static float Min(float x, float y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Min)}(float,float)"); - - /// - /// Selects the lesser of and . - /// - /// The first specified value. - /// The second specified exponent. - /// The or parameter, whichever is the smallest value. - /// For values of -INF or INF, will behave as expected, but for for values of , the results are undefined. - [Pure] - public static Float2 Min(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Min)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Selects the lesser of and . - /// - /// The first specified value. - /// The second specified exponent. - /// The or parameter, whichever is the smallest value. - /// For values of -INF or INF, will behave as expected, but for for values of , the results are undefined. - [Pure] - public static Float3 Min(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Min)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Selects the lesser of and . - /// - /// The first specified value. - /// The second specified exponent. - /// The or parameter, whichever is the smallest value. - /// For values of -INF or INF, will behave as expected, but for for values of , the results are undefined. - [Pure] - public static Float4 Min(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Min)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Splits the value into fractional and integer parts, each of which has the same sign as . - /// - /// The input value. - /// The integer portion of . - /// The signed-fractional portion of . - [Pure] - public static int Modf(int x, out int ip) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Modf)}(int,int)"); - - /// - /// Splits the value into fractional and integer parts, each of which has the same sign as . - /// - /// The input value. - /// The integer portion of . - /// The signed-fractional portion of . - [Pure] - public static Int2 Modf(Int2 x, out Int2 ip) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Modf)}({nameof(Int2)},{nameof(Int2)})"); - - /// - /// Splits the value into fractional and integer parts, each of which has the same sign as . - /// - /// The input value. - /// The integer portion of . - /// The signed-fractional portion of . - [Pure] - public static Int3 Modf(Int3 x, out Int3 ip) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Modf)}({nameof(Int3)},{nameof(Int3)})"); - - /// - /// Splits the value into fractional and integer parts, each of which has the same sign as . - /// - /// The input value. - /// The integer portion of . - /// The signed-fractional portion of . - [Pure] - public static Int4 Modf(Int4 x, out Int4 ip) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Modf)}({nameof(Int4)},{nameof(Int4)})"); - - /// - /// Splits the value into fractional and integer parts, each of which has the same sign as . - /// - /// The input value. - /// The integer portion of . - /// The signed-fractional portion of . - [Pure] - public static float Modf(float x, out float ip) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Modf)}(float,float)"); - - /// - /// Splits the value into fractional and integer parts, each of which has the same sign as . - /// - /// The input value. - /// The integer portion of . - /// The signed-fractional portion of . - [Pure] - public static Float2 Modf(Float2 x, out Float2 ip) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Modf)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Splits the value into fractional and integer parts, each of which has the same sign as . - /// - /// The input value. - /// The integer portion of . - /// The signed-fractional portion of . - [Pure] - public static Float3 Modf(Float3 x, out Float3 ip) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Modf)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Splits the value into fractional and integer parts, each of which has the same sign as . - /// - /// The input value. - /// The integer portion of . - /// The signed-fractional portion of . - [Pure] - public static Float4 Modf(Float4 x, out Float4 ip) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Modf)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Multiplies and using matrix math. - /// - /// The first input value (if is a vector, it treated as a row vector) - /// The second input value (if is a vector, it treated as a column vector) - /// The result of times . - [Pure] - public static Float2 Mul(float x, Float2 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Mul)}(float,{nameof(Float2)})"); - - /// - /// Multiplies and using matrix math. - /// - /// The first input value (if is a vector, it treated as a row vector) - /// The second input value (if is a vector, it treated as a column vector) - /// The result of times . - [Pure] - public static Float3 Mul(float x, Float3 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Mul)}(float,{nameof(Float3)})"); - - /// - /// Multiplies and using matrix math. - /// - /// The first input value (if is a vector, it treated as a row vector) - /// The second input value (if is a vector, it treated as a column vector) - /// The result of times . - [Pure] - public static Float3 Mul(float x, Float4 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Mul)}(float,{nameof(Float4)})"); - - /// - /// Multiplies and using matrix math. - /// - /// The first input value (if is a vector, it treated as a row vector) - /// The second input value (if is a vector, it treated as a column vector) - /// The result of times . - [Pure] - public static Float2 Mul(Float2 x, float y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Mul)}({nameof(Float2)},float)"); - - /// - /// Multiplies and using matrix math. - /// - /// The first input value (if is a vector, it treated as a row vector) - /// The second input value (if is a vector, it treated as a column vector) - /// The result of times . - [Pure] - public static Float3 Mul(Float3 x, float y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Mul)}({nameof(Float3)},float)"); - - /// - /// Multiplies and using matrix math. - /// - /// The first input value (if is a vector, it treated as a row vector) - /// The second input value (if is a vector, it treated as a column vector) - /// The result of times . - [Pure] - public static Float4 Mul(Float4 x, float y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Mul)}({nameof(Float4)},float)"); - - /// - /// Multiplies and using matrix math. - /// - /// The first input value (if is a vector, it treated as a row vector) - /// The second input value (if is a vector, it treated as a column vector) - /// The result of times . - [Pure] - public static float Mul(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Mul)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Multiplies and using matrix math. - /// - /// The first input value (if is a vector, it treated as a row vector) - /// The second input value (if is a vector, it treated as a column vector) - /// The result of times . - [Pure] - public static float Mul(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Mul)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Multiplies and using matrix math. - /// - /// The first input value (if is a vector, it treated as a row vector) - /// The second input value (if is a vector, it treated as a column vector) - /// The result of times . - [Pure] - public static float Mul(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Mul)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Normalizes the specified floating-point vector according to / length() - /// - /// The specified value. - /// The normalized parameter. - [Pure] - public static Float2 Normalize(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Normalize)}({nameof(Float2)})"); - - /// - /// Normalizes the specified floating-point vector according to / length() - /// - /// The specified value. - /// The normalized parameter. - [Pure] - public static Float3 Normalize(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Normalize)}({nameof(Float3)})"); - - /// - /// Normalizes the specified floating-point vector according to / length() - /// - /// The specified value. - /// The normalized parameter. - [Pure] - public static Float4 Normalize(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Normalize)}({nameof(Float4)})"); - - /// - /// Returns the specified value raised to the specified power. - /// - /// The specified value. - /// The specified power. - /// The parameter raised to the power of the parameter. - /// See for details on special cases. - [Pure] - public static float Pow(float x, float y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Pow)}(float,float)"); - - /// - /// Returns the specified value raised to the specified power. - /// - /// The specified value. - /// The specified power. - /// The parameter raised to the power of the parameter. - /// See for details on special cases. - [Pure] - public static Float2 Pow(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Pow)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Returns the specified value raised to the specified power. - /// - /// The specified value. - /// The specified power. - /// The parameter raised to the power of the parameter. - /// See for details on special cases. - [Pure] - public static Float3 Pow(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Pow)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Returns the specified value raised to the specified power. - /// - /// The specified value. - /// The specified power. - /// The parameter raised to the power of the parameter. - /// See for details on special cases. - [Pure] - public static Float4 Pow(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Pow)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Converts the specified value from degrees to radians. - /// - /// The specified value. - /// The parameter converted from degrees to radians. - [Pure] - public static float Radians(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Radians)}(float)"); - - /// - /// Converts the specified value from degrees to radians. - /// - /// The specified value. - /// The parameter converted from degrees to radians. - [Pure] - public static Float2 Radians(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Radians)}({nameof(Float2)})"); - - /// - /// Converts the specified value from degrees to radians. - /// - /// The specified value. - /// The parameter converted from degrees to radians. - [Pure] - public static Float3 Radians(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Radians)}({nameof(Float3)})"); - - /// - /// Converts the specified value from degrees to radians. - /// - /// The specified value. - /// The parameter converted from degrees to radians. - [Pure] - public static Float4 Radians(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Radians)}({nameof(Float4)})"); - - /// - /// Calculates a fast, approximate reciprocal of a given value. - /// - /// The specified value. - /// The reciprocal of the parameter. - [Pure] - public static float Rcp(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Rcp)}(float)"); - - /// - /// Calculates a fast, approximate, per-component reciprocal. - /// - /// The specified value. - /// The reciprocal of the parameter. - [Pure] - public static Float2 Rcp(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Rcp)}({nameof(Float2)})"); - - /// - /// Calculates a fast, approximate, per-component reciprocal. - /// - /// The specified value. - /// The reciprocal of the parameter. - [Pure] - public static Float3 Rcp(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Rcp)}({nameof(Float3)})"); - - /// - /// Calculates a fast, approximate, per-component reciprocal. - /// - /// The specified value. - /// The reciprocal of the parameter. - [Pure] - public static Float4 Rcp(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Rcp)}({nameof(Float4)})"); - - /// - /// Rounds the specified value to the nearest integer. - /// - /// The specified value. - /// The parameter, rounded to the nearest integer within a floating-point type. - [Pure] - public static float Round(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Round)}(float)"); - - /// - /// Rounds the specified value to the nearest integer. - /// - /// The specified value. - /// The parameter, rounded to the nearest integer within a floating-point type. - [Pure] - public static Float2 Round(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Round)}({nameof(Float2)})"); - - /// - /// Rounds the specified value to the nearest integer. - /// - /// The specified value. - /// The parameter, rounded to the nearest integer within a floating-point type. - [Pure] - public static Float3 Round(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Round)}({nameof(Float3)})"); - - /// - /// Rounds the specified value to the nearest integer. - /// - /// The specified value. - /// The parameter, rounded to the nearest integer within a floating-point type. - [Pure] - public static Float4 Round(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Round)}({nameof(Float4)})"); - - /// - /// Returns the reciprocal of the square root of the specified value. - /// - /// The specified value. - /// The reciprocal of the square root of the parameter. - /// This function uses the following formula: 1 / sqrt() - [Pure] - public static float Rsqrt(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Rsqrt)}(float)"); - - /// - /// Returns the reciprocal of the square root of the specified value. - /// - /// The specified value. - /// The reciprocal of the square root of the parameter. - /// This function uses the following formula: 1 / sqrt() - [Pure] - public static Float2 Rsqrt(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Rsqrt)}({nameof(Float2)})"); - - /// - /// Returns the reciprocal of the square root of the specified value. - /// - /// The specified value. - /// The reciprocal of the square root of the parameter. - /// This function uses the following formula: 1 / sqrt() - [Pure] - public static Float3 Rsqrt(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Rsqrt)}({nameof(Float3)})"); - - /// - /// Returns the reciprocal of the square root of the specified value. - /// - /// The specified value. - /// The reciprocal of the square root of the parameter. - /// This function uses the following formula: 1 / sqrt() - [Pure] - public static Float4 Rsqrt(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Rsqrt)}({nameof(Float4)})"); - - /// - /// Clamps the specified value within the range [0,1] - /// - /// The specified value. - /// The parameter, clamped within the range [0,1] - [Pure] - public static float Saturate(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Saturate)}(float)"); - - /// - /// Clamps the specified value within the range [0,1] - /// - /// The specified value. - /// The parameter, clamped within the range [0,1] - [Pure] - public static Float2 Saturate(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Saturate)}({nameof(Float2)})"); - - /// - /// Clamps the specified value within the range [0,1] - /// - /// The specified value. - /// The parameter, clamped within the range [0,1] - [Pure] - public static Float3 Saturate(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Saturate)}({nameof(Float3)})"); - - /// - /// Clamps the specified value within the range [0,1] - /// - /// The specified value. - /// The parameter, clamped within the range [0,1] - [Pure] - public static Float4 Saturate(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Saturate)}({nameof(Float4)})"); - - /// - /// Returns the sign of . - /// - /// The input value. - /// Returns -1 if is less than zero, 0 if equals zero and 1 if is greater than zero. - [Pure] - public static float Sign(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sign)}(float)"); - - /// - /// Returns the sign of . - /// - /// The input value. - /// Returns -1 if is less than zero, 0 if equals zero and 1 if is greater than zero. - [Pure] - public static Float2 Sign(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sign)}({nameof(Float2)})"); - - /// - /// Returns the sign of . - /// - /// The input value. - /// Returns -1 if is less than zero, 0 if equals zero and 1 if is greater than zero. - [Pure] - public static Float3 Sign(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sign)}({nameof(Float3)})"); - - /// - /// Returns the sign of . - /// - /// The input value. - /// Returns -1 if is less than zero, 0 if equals zero and 1 if is greater than zero. - [Pure] - public static Float4 Sign(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sign)}({nameof(Float4)})"); - - /// - /// Returns the sine of the specified value. - /// - /// The specified value, radians. - /// The sine of the parameter. - [Pure] - public static float Sin(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sin)}(float)"); - - /// - /// Returns the sine of the specified value. - /// - /// The specified value, radians. - /// The sine of the parameter. - [Pure] - public static Float2 Sin(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sin)}({nameof(Float2)})"); - - /// - /// Returns the sine of the specified value. - /// - /// The specified value, radians. - /// The sine of the parameter. - [Pure] - public static Float3 Sin(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sin)}({nameof(Float3)})"); - - /// - /// Returns the sine of the specified value. - /// - /// The specified value, radians. - /// The sine of the parameter. - [Pure] - public static Float4 Sin(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sin)}({nameof(Float4)})"); - - /// - /// Returns the sine and cosine of . - /// - /// The specified value, radians. - /// Returns the sine of . - /// Returns the cosine of . - public static void SinCos(float x, out float s, out float c) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(SinCos)}(float,float,float)"); - - /// - /// Returns the sine and cosine of . - /// - /// The specified value, radians. - /// Returns the sine of . - /// Returns the cosine of . - public static void SinCos(Float2 x, out Float2 s, out Float2 c) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(SinCos)}({nameof(Float2)},{nameof(Float2)},{nameof(Float2)})"); - - /// - /// Returns the sine and cosine of . - /// - /// The specified value, radians. - /// Returns the sine of . - /// Returns the cosine of . - public static void SinCos(Float3 x, out Float3 s, out Float3 c) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(SinCos)}({nameof(Float3)},{nameof(Float3)},{nameof(Float3)})"); - - /// - /// Returns the sine and cosine of . - /// - /// The specified value, radians. - /// Returns the sine of . - /// Returns the cosine of . - public static void SinCos(Float4 x, out Float4 s, out Float4 c) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(SinCos)}({nameof(Float4)},{nameof(Float4)},{nameof(Float4)})"); - - /// - /// Returns the hyperbolic sine of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic sine of the parameter. - [Pure] - public static float Sinh(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sinh)}(float)"); - - /// - /// Returns the hyperbolic sine of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic sine of the parameter. - [Pure] - public static Float2 Sinh(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sinh)}({nameof(Float2)})"); - - /// - /// Returns the hyperbolic sine of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic sine of the parameter. - [Pure] - public static Float3 Sinh(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sinh)}({nameof(Float3)})"); - - /// - /// Returns the hyperbolic sine of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic sine of the parameter. - [Pure] - public static Float4 Sinh(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sinh)}({nameof(Float4)})"); - - /// - /// Returns a smooth Hermite interpolation between 0 and 1, if is in the range [, ] - /// - /// The minimum range of the parameter. - /// The maximum range of the parameter. - /// The specified value to be interpolated. - /// 0 if is less than , 1 if is greater than , otherwise a value between 0 and 1 if is in the range [, ] - [Pure] - public static float SmoothStep(float min, float max, float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(SmoothStep)}(float,float,float)"); - - /// - /// Returns a smooth Hermite interpolation between 0 and 1, if is in the range [, ] - /// - /// The minimum range of the parameter. - /// The maximum range of the parameter. - /// The specified value to be interpolated. - /// 0 if is less than , 1 if is greater than , otherwise a value between 0 and 1 if is in the range [, ] - [Pure] - public static Float2 SmoothStep(Float2 min, Float2 max, Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(SmoothStep)}({nameof(Float2)},{nameof(Float2)},{nameof(Float2)})"); - - /// - /// Returns a smooth Hermite interpolation between 0 and 1, if is in the range [, ] - /// - /// The minimum range of the parameter. - /// The maximum range of the parameter. - /// The specified value to be interpolated. - /// 0 if is less than , 1 if is greater than , otherwise a value between 0 and 1 if is in the range [, ] - [Pure] - public static Float3 SmoothStep(Float3 min, Float3 max, Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(SmoothStep)}({nameof(Float3)},{nameof(Float3)},{nameof(Float3)})"); - - /// - /// Returns a smooth Hermite interpolation between 0 and 1, if is in the range [, ] - /// - /// The minimum range of the parameter. - /// The maximum range of the parameter. - /// The specified value to be interpolated. - /// 0 if is less than , 1 if is greater than , otherwise a value between 0 and 1 if is in the range [, ] - [Pure] - public static Float4 SmoothStep(Float4 min, Float4 max, Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(SmoothStep)}({nameof(Float4)},{nameof(Float4)},{nameof(Float4)})"); - - /// - /// Returns the square root of the specified floating-point value. - /// - /// The specified value. - /// The square root of the parameter. - [Pure] - public static float Sqrt(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sqrt)}(float)"); - - /// - /// Returns the square root of the specified floating-point value, per component. - /// - /// The specified value. - /// The square root of the parameter, per component. - [Pure] - public static Float2 Sqrt(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sqrt)}({nameof(Float2)})"); - - /// - /// Returns the square root of the specified floating-point value, per component. - /// - /// The specified value. - /// The square root of the parameter, per component. - [Pure] - public static Float3 Sqrt(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sqrt)}({nameof(Float3)})"); - - /// - /// Returns the square root of the specified floating-point value, per component. - /// - /// The specified value. - /// The square root of the parameter, per component. - [Pure] - public static Float4 Sqrt(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Sqrt)}({nameof(Float4)})"); - - /// - /// Compares two values, returning 0 or 1 based on which value is greater. - /// - /// The first specified value to compare. - /// The second specified value to compare. - /// 1 if the parameter is greater than or equal to the parameter, otherwise, 0. - /// This function uses the following formula: (x >= y) ? 1 : 0. - [Pure] - public static float Step(float x, float y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Step)}(float,float)"); - - /// - /// Compares two values, returning 0 or 1 based on which value is greater. - /// - /// The first specified value to compare. - /// The second specified value to compare. - /// 1 if the parameter is greater than or equal to the parameter, otherwise, 0. - /// This function uses the following formula: (x >= y) ? 1 : 0. - [Pure] - public static Float2 Step(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Step)}({nameof(Float2)},{nameof(Float2)})"); - - /// - /// Compares two values, returning 0 or 1 based on which value is greater. - /// - /// The first specified value to compare. - /// The second specified value to compare. - /// 1 if the parameter is greater than or equal to the parameter, otherwise, 0. - /// This function uses the following formula: (x >= y) ? 1 : 0. - [Pure] - public static Float3 Step(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Step)}({nameof(Float3)},{nameof(Float3)})"); - - /// - /// Compares two values, returning 0 or 1 based on which value is greater. - /// - /// The first specified value to compare. - /// The second specified value to compare. - /// 1 if the parameter is greater than or equal to the parameter, otherwise, 0. - /// This function uses the following formula: (x >= y) ? 1 : 0. - [Pure] - public static Float4 Step(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Step)}({nameof(Float4)},{nameof(Float4)})"); - - /// - /// Returns the tangent of the specified value. - /// - /// The specified value, radians. - /// The tangent of the parameter. - [Pure] - public static float Tan(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Tan)}(float)"); - - /// - /// Returns the tangent of the specified value. - /// - /// The specified value, radians. - /// The tangent of the parameter. - [Pure] - public static Float2 Tan(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Tan)}({nameof(Float2)})"); - - /// - /// Returns the tangent of the specified value. - /// - /// The specified value, radians. - /// The tangent of the parameter. - [Pure] - public static Float3 Tan(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Tan)}({nameof(Float3)})"); - - /// - /// Returns the tangent of the specified value. - /// - /// The specified value, radians. - /// The tangent of the parameter. - [Pure] - public static Float4 Tan(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Tan)}({nameof(Float4)})"); - - /// - /// Returns the hyperbolic tangent of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic tangent of the parameter. - [Pure] - public static float Tanh(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Tanh)}(float)"); - - /// - /// Returns the hyperbolic tangent of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic tangent of the parameter. - [Pure] - public static Float2 Tanh(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Tanh)}({nameof(Float2)})"); - - /// - /// Returns the hyperbolic tangent of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic tangent of the parameter. - [Pure] - public static Float3 Tanh(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Tanh)}({nameof(Float3)})"); - - /// - /// Returns the hyperbolic tangent of the specified value. - /// - /// The specified value, radians. - /// The hyperbolic tangent of the parameter. - [Pure] - public static Float4 Tanh(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Tanh)}({nameof(Float4)})"); - - /// - /// Truncates a floating-point value to the integer component. - /// - /// The specified value, radians. - /// The parameter truncated to an integer component. - [Pure] - public static float Trunc(float x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Trunc)}(float)"); - - /// - /// Truncates a floating-point value to the integer component. - /// - /// The specified value, radians. - /// The parameter truncated to an integer component. - [Pure] - public static Float2 Trunc(Float2 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Trunc)}({nameof(Float2)})"); - - /// - /// Truncates a floating-point value to the integer component. - /// - /// The specified value, radians. - /// The parameter truncated to an integer component. - [Pure] - public static Float3 Trunc(Float3 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Trunc)}({nameof(Float3)})"); - - /// - /// Truncates a floating-point value to the integer component. - /// - /// The specified value, radians. - /// The parameter truncated to an integer component. - [Pure] - public static Float4 Trunc(Float4 x) => throw new InvalidExecutionContextException($"{nameof(Hlsl)}.{nameof(Trunc)}({nameof(Float4)})"); + public static void InterlockedXor(uint destination, uint value, out uint original) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(InterlockedXor)}({typeof(uint)}, {typeof(uint)}, {typeof(uint)})"); } } diff --git a/src/ComputeSharp/Core/Intrinsics/Hlsl.g.cs b/src/ComputeSharp/Core/Intrinsics/Hlsl.g.cs new file mode 100644 index 00000000..e029ee85 --- /dev/null +++ b/src/ComputeSharp/Core/Intrinsics/Hlsl.g.cs @@ -0,0 +1,15167 @@ +using System.Diagnostics.Contracts; +using ComputeSharp.Core.Intrinsics.Attributes; +using ComputeSharp.Exceptions; + +namespace ComputeSharp +{ + /// + public static partial class Hlsl + { + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static int Abs(int x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(int)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int2 Abs(Int2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int2)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int3 Abs(Int3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int3)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int4 Abs(Int4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int4)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int1x1 Abs(Int1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int1x1)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int1x2 Abs(Int1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int1x2)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int1x3 Abs(Int1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int1x3)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int1x4 Abs(Int1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int1x4)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int2x1 Abs(Int2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int2x1)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int2x2 Abs(Int2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int2x2)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int2x3 Abs(Int2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int2x3)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int2x4 Abs(Int2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int2x4)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int3x1 Abs(Int3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int3x1)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int3x2 Abs(Int3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int3x2)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int3x3 Abs(Int3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int3x3)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int3x4 Abs(Int3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int3x4)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int4x1 Abs(Int4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int4x1)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int4x2 Abs(Int4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int4x2)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int4x3 Abs(Int4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int4x3)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Int4x4 Abs(Int4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Int4x4)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static float Abs(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(float)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float2 Abs(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float2)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float3 Abs(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float3)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float4 Abs(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float4)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float1x1 Abs(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float1x1)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float1x2 Abs(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float1x2)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float1x3 Abs(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float1x3)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float1x4 Abs(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float1x4)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float2x1 Abs(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float2x1)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float2x2 Abs(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float2x2)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float2x3 Abs(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float2x3)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float2x4 Abs(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float2x4)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float3x1 Abs(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float3x1)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float3x2 Abs(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float3x2)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float3x3 Abs(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float3x3)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float3x4 Abs(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float3x4)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float4x1 Abs(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float4x1)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float4x2 Abs(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float4x2)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float4x3 Abs(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float4x3)})"); + + /// + /// Returns the absolute value of the specified value. + /// + /// The specified value. + /// The absolute value of the parameter. + [Pure] + [HlslIntrinsicName("abs")] + public static Float4x4 Abs(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Abs)}({typeof(Float4x4)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static float Acos(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(float)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float2 Acos(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float2)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float3 Acos(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float3)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float4 Acos(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float4)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float1x1 Acos(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float1x1)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float1x2 Acos(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float1x2)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float1x3 Acos(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float1x3)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float1x4 Acos(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float1x4)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float2x1 Acos(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float2x1)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float2x2 Acos(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float2x2)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float2x3 Acos(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float2x3)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float2x4 Acos(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float2x4)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float3x1 Acos(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float3x1)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float3x2 Acos(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float3x2)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float3x3 Acos(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float3x3)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float3x4 Acos(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float3x4)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float4x1 Acos(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float4x1)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float4x2 Acos(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float4x2)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float4x3 Acos(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float4x3)})"); + + /// + /// Returns the arccosine of the specified value. + /// + /// The specified value. Each component should be a floating-point within the range [-1, 1]. + /// The arccosine of the parameter. + [Pure] + [HlslIntrinsicName("acos")] + public static Float4x4 Acos(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Acos)}({typeof(Float4x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(int x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(int)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int1x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int1x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int1x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int1x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int2x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int2x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int2x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int2x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int3x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int3x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int3x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int3x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int4x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int4x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int4x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Int4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Int4x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(float)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float1x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float1x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float1x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float1x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float2x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float2x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float2x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float2x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float3x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float3x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float3x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float3x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float4x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float4x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float4x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Float4x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(bool x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(bool)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool1x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool1x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool1x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool1x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool2x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool2x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool2x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool2x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool3x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool3x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool3x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool3x4)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool4x1)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool4x2)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool4x3)})"); + + /// + /// Determines if all components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not all components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("all")] + public static bool All(Bool4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(All)}({typeof(Bool4x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(int x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(int)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int1x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int1x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int1x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int1x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int2x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int2x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int2x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int2x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int3x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int3x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int3x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int3x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int4x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int4x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int4x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Int4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Int4x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(float)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float1x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float1x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float1x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float1x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float2x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float2x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float2x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float2x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float3x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float3x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float3x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float3x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float4x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float4x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float4x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Float4x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(bool x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(bool)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool1x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool1x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool1x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool1x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool2x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool2x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool2x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool2x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool3x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool3x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool3x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool3x4)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool4x1)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool4x2)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool4x3)})"); + + /// + /// Determines if any components of the specified value are non-zero. + /// + /// The specified value. + /// Whether or not any components of the parameter are non-zero. + [Pure] + [HlslIntrinsicName("any")] + public static bool Any(Bool4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Any)}({typeof(Bool4x4)})"); + + /// + /// Reinterprets a cast value (two 32-bit values) into a double precision floating-point value. + /// + /// The low 32-bit pattern of the input value. + /// The high 32-bit pattern of the input value. + /// The input (two 32-bit values) recast as a double precision floating-point number. + [Pure] + [HlslIntrinsicName("asdouble")] + public static double AsDouble(uint lowbits, uint highbits) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsDouble)}({typeof(uint)}, {typeof(uint)})"); + + /// + /// Reinterprets a cast value (two 32-bit values) into a double precision floating-point value. + /// + /// The low 32-bit pattern of the input value. + /// The high 32-bit pattern of the input value. + /// The input (two 32-bit values) recast as a double precision floating-point number. + [Pure] + [HlslIntrinsicName("asdouble")] + public static Double2 AsDouble(UInt2 lowbits, UInt2 highbits) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsDouble)}({typeof(UInt2)}, {typeof(UInt2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static float AsFloat(int x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(int)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float2 AsFloat(Int2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float3 AsFloat(Int3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int3)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float4 AsFloat(Int4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int4)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float1x1 AsFloat(Int1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int1x1)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float1x2 AsFloat(Int1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int1x2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float1x3 AsFloat(Int1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int1x3)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float1x4 AsFloat(Int1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int1x4)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float2x1 AsFloat(Int2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int2x1)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float2x2 AsFloat(Int2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int2x2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float2x3 AsFloat(Int2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int2x3)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float2x4 AsFloat(Int2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int2x4)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float3x1 AsFloat(Int3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int3x1)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float3x2 AsFloat(Int3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int3x2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float3x3 AsFloat(Int3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int3x3)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float3x4 AsFloat(Int3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int3x4)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float4x1 AsFloat(Int4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int4x1)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float4x2 AsFloat(Int4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int4x2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float4x3 AsFloat(Int4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int4x3)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float4x4 AsFloat(Int4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(Int4x4)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static float AsFloat(uint x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(uint)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float2 AsFloat(UInt2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float3 AsFloat(UInt3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt3)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float4 AsFloat(UInt4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt4)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float1x1 AsFloat(UInt1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt1x1)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float1x2 AsFloat(UInt1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt1x2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float1x3 AsFloat(UInt1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt1x3)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float1x4 AsFloat(UInt1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt1x4)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float2x1 AsFloat(UInt2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt2x1)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float2x2 AsFloat(UInt2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt2x2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float2x3 AsFloat(UInt2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt2x3)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float2x4 AsFloat(UInt2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt2x4)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float3x1 AsFloat(UInt3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt3x1)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float3x2 AsFloat(UInt3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt3x2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float3x3 AsFloat(UInt3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt3x3)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float3x4 AsFloat(UInt3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt3x4)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float4x1 AsFloat(UInt4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt4x1)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float4x2 AsFloat(UInt4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt4x2)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float4x3 AsFloat(UInt4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt4x3)})"); + + /// + /// Interprets the bit pattern of an input value as a floating-point number. + /// + /// The input value. + /// The input interpreted as a floating-point number. + [Pure] + [HlslIntrinsicName("asfloat")] + public static Float4x4 AsFloat(UInt4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsFloat)}({typeof(UInt4x4)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static float Asin(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(float)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float2 Asin(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float2)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float3 Asin(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float3)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float4 Asin(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float4)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float1x1 Asin(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float1x1)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float1x2 Asin(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float1x2)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float1x3 Asin(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float1x3)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float1x4 Asin(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float1x4)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float2x1 Asin(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float2x1)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float2x2 Asin(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float2x2)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float2x3 Asin(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float2x3)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float2x4 Asin(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float2x4)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float3x1 Asin(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float3x1)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float3x2 Asin(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float3x2)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float3x3 Asin(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float3x3)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float3x4 Asin(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float3x4)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float4x1 Asin(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float4x1)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float4x2 Asin(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float4x2)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float4x3 Asin(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float4x3)})"); + + /// + /// Returns the arcsine of the specified value. + /// + /// The specified value. + /// The arcsine of the parameter. + [Pure] + [HlslIntrinsicName("asin")] + public static Float4x4 Asin(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Asin)}({typeof(Float4x4)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static int AsInt(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(float)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int2 AsInt(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float2)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int3 AsInt(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float3)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int4 AsInt(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float4)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int1x1 AsInt(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float1x1)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int1x2 AsInt(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float1x2)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int1x3 AsInt(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float1x3)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int1x4 AsInt(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float1x4)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int2x1 AsInt(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float2x1)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int2x2 AsInt(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float2x2)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int2x3 AsInt(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float2x3)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int2x4 AsInt(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float2x4)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int3x1 AsInt(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float3x1)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int3x2 AsInt(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float3x2)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int3x3 AsInt(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float3x3)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int3x4 AsInt(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float3x4)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int4x1 AsInt(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float4x1)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int4x2 AsInt(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float4x2)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int4x3 AsInt(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float4x3)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int4x4 AsInt(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(Float4x4)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static int AsInt(uint x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(uint)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int2 AsInt(UInt2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt2)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int3 AsInt(UInt3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt3)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int4 AsInt(UInt4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt4)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int1x1 AsInt(UInt1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt1x1)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int1x2 AsInt(UInt1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt1x2)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int1x3 AsInt(UInt1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt1x3)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int1x4 AsInt(UInt1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt1x4)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int2x1 AsInt(UInt2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt2x1)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int2x2 AsInt(UInt2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt2x2)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int2x3 AsInt(UInt2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt2x3)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int2x4 AsInt(UInt2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt2x4)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int3x1 AsInt(UInt3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt3x1)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int3x2 AsInt(UInt3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt3x2)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int3x3 AsInt(UInt3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt3x3)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int3x4 AsInt(UInt3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt3x4)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int4x1 AsInt(UInt4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt4x1)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int4x2 AsInt(UInt4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt4x2)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int4x3 AsInt(UInt4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt4x3)})"); + + /// + /// Interprets the bit pattern of an input value as an integer number. + /// + /// The input value. + /// The input interpreted as an integer number. + [Pure] + [HlslIntrinsicName("asint")] + public static Int4x4 AsInt(UInt4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsInt)}({typeof(UInt4x4)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static uint AsUInt(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(float)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt2 AsUInt(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float2)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt3 AsUInt(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float3)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt4 AsUInt(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float4)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt1x1 AsUInt(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float1x1)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt1x2 AsUInt(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float1x2)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt1x3 AsUInt(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float1x3)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt1x4 AsUInt(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float1x4)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt2x1 AsUInt(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float2x1)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt2x2 AsUInt(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float2x2)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt2x3 AsUInt(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float2x3)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt2x4 AsUInt(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float2x4)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt3x1 AsUInt(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float3x1)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt3x2 AsUInt(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float3x2)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt3x3 AsUInt(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float3x3)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt3x4 AsUInt(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float3x4)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt4x1 AsUInt(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float4x1)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt4x2 AsUInt(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float4x2)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt4x3 AsUInt(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float4x3)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt4x4 AsUInt(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Float4x4)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static uint AsUInt(int x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(int)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt2 AsUInt(Int2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int2)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt3 AsUInt(Int3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int3)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt4 AsUInt(Int4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int4)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt1x1 AsUInt(Int1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int1x1)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt1x2 AsUInt(Int1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int1x2)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt1x3 AsUInt(Int1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int1x3)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt1x4 AsUInt(Int1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int1x4)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt2x1 AsUInt(Int2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int2x1)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt2x2 AsUInt(Int2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int2x2)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt2x3 AsUInt(Int2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int2x3)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt2x4 AsUInt(Int2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int2x4)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt3x1 AsUInt(Int3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int3x1)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt3x2 AsUInt(Int3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int3x2)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt3x3 AsUInt(Int3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int3x3)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt3x4 AsUInt(Int3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int3x4)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt4x1 AsUInt(Int4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int4x1)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt4x2 AsUInt(Int4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int4x2)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt4x3 AsUInt(Int4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int4x3)})"); + + /// + /// Interprets the bit pattern of an input value as an unsigned integer number. + /// + /// The input value. + /// The input interpreted as an unsigned integer number. + [Pure] + [HlslIntrinsicName("asuint")] + public static UInt4x4 AsUInt(Int4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(AsUInt)}({typeof(Int4x4)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static float Atan(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(float)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float2 Atan(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float2)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float3 Atan(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float3)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float4 Atan(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float4)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float1x1 Atan(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float1x1)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float1x2 Atan(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float1x2)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float1x3 Atan(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float1x3)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float1x4 Atan(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float1x4)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float2x1 Atan(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float2x1)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float2x2 Atan(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float2x2)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float2x3 Atan(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float2x3)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float2x4 Atan(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float2x4)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float3x1 Atan(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float3x1)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float3x2 Atan(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float3x2)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float3x3 Atan(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float3x3)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float3x4 Atan(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float3x4)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float4x1 Atan(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float4x1)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float4x2 Atan(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float4x2)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float4x3 Atan(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float4x3)})"); + + /// + /// Returns the arctangent of the specified value. + /// + /// The specified value. + /// The arctangent of the parameter. This value is within the range [-π/2, π/2]. + [Pure] + [HlslIntrinsicName("atan")] + public static Float4x4 Atan(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan)}({typeof(Float4x4)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static float Atan2(float y, float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(float)}, {typeof(float)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float2 Atan2(Float2 y, Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float3 Atan2(Float3 y, Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float4 Atan2(Float4 y, Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float1x1 Atan2(Float1x1 y, Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float1x2 Atan2(Float1x2 y, Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float1x3 Atan2(Float1x3 y, Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float1x4 Atan2(Float1x4 y, Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float2x1 Atan2(Float2x1 y, Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float2x2 Atan2(Float2x2 y, Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float2x3 Atan2(Float2x3 y, Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float2x4 Atan2(Float2x4 y, Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float3x1 Atan2(Float3x1 y, Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float3x2 Atan2(Float3x2 y, Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float3x3 Atan2(Float3x3 y, Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float3x4 Atan2(Float3x4 y, Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float4x1 Atan2(Float4x1 y, Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float4x2 Atan2(Float4x2 y, Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float4x3 Atan2(Float4x3 y, Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Returns the arctangent of two values (y, x). + /// + /// The y value. + /// The x value. + /// The arctangent of (, ). + [Pure] + [HlslIntrinsicName("atan2")] + public static Float4x4 Atan2(Float4x4 y, Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Atan2)}({typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static float Ceil(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(float)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float2 Ceil(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float2)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float3 Ceil(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float3)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float4 Ceil(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float4)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float1x1 Ceil(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float1x1)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float1x2 Ceil(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float1x2)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float1x3 Ceil(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float1x3)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float1x4 Ceil(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float1x4)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float2x1 Ceil(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float2x1)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float2x2 Ceil(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float2x2)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float2x3 Ceil(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float2x3)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float2x4 Ceil(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float2x4)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float3x1 Ceil(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float3x1)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float3x2 Ceil(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float3x2)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float3x3 Ceil(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float3x3)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float3x4 Ceil(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float3x4)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float4x1 Ceil(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float4x1)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float4x2 Ceil(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float4x2)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float4x3 Ceil(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float4x3)})"); + + /// + /// Returns the smallest integer value that is greater than or equal to the specified value. + /// + /// The specified value. + /// The smallest integer value (returned as a floating-point type) that is greater than or equal to the parameter. + [Pure] + [HlslIntrinsicName("ceil")] + public static Float4x4 Ceil(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ceil)}({typeof(Float4x4)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static float Clamp(float x, float min, float max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(float)}, {typeof(float)}, {typeof(float)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float2 Clamp(Float2 x, Float2 min, Float2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float2)}, {typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float3 Clamp(Float3 x, Float3 min, Float3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float3)}, {typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float4 Clamp(Float4 x, Float4 min, Float4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float4)}, {typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float1x1 Clamp(Float1x1 x, Float1x1 min, Float1x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float1x1)}, {typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float1x2 Clamp(Float1x2 x, Float1x2 min, Float1x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float1x2)}, {typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float1x3 Clamp(Float1x3 x, Float1x3 min, Float1x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float1x3)}, {typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float1x4 Clamp(Float1x4 x, Float1x4 min, Float1x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float1x4)}, {typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float2x1 Clamp(Float2x1 x, Float2x1 min, Float2x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float2x1)}, {typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float2x2 Clamp(Float2x2 x, Float2x2 min, Float2x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float2x2)}, {typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float2x3 Clamp(Float2x3 x, Float2x3 min, Float2x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float2x3)}, {typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float2x4 Clamp(Float2x4 x, Float2x4 min, Float2x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float2x4)}, {typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float3x1 Clamp(Float3x1 x, Float3x1 min, Float3x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float3x1)}, {typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float3x2 Clamp(Float3x2 x, Float3x2 min, Float3x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float3x2)}, {typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float3x3 Clamp(Float3x3 x, Float3x3 min, Float3x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float3x3)}, {typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float3x4 Clamp(Float3x4 x, Float3x4 min, Float3x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float3x4)}, {typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float4x1 Clamp(Float4x1 x, Float4x1 min, Float4x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float4x1)}, {typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float4x2 Clamp(Float4x2 x, Float4x2 min, Float4x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float4x2)}, {typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float4x3 Clamp(Float4x3 x, Float4x3 min, Float4x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float4x3)}, {typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Float4x4 Clamp(Float4x4 x, Float4x4 min, Float4x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Float4x4)}, {typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static int Clamp(int x, int min, int max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(int)}, {typeof(int)}, {typeof(int)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int2 Clamp(Int2 x, Int2 min, Int2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int2)}, {typeof(Int2)}, {typeof(Int2)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int3 Clamp(Int3 x, Int3 min, Int3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int3)}, {typeof(Int3)}, {typeof(Int3)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int4 Clamp(Int4 x, Int4 min, Int4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int4)}, {typeof(Int4)}, {typeof(Int4)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int1x1 Clamp(Int1x1 x, Int1x1 min, Int1x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int1x1)}, {typeof(Int1x1)}, {typeof(Int1x1)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int1x2 Clamp(Int1x2 x, Int1x2 min, Int1x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int1x2)}, {typeof(Int1x2)}, {typeof(Int1x2)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int1x3 Clamp(Int1x3 x, Int1x3 min, Int1x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int1x3)}, {typeof(Int1x3)}, {typeof(Int1x3)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int1x4 Clamp(Int1x4 x, Int1x4 min, Int1x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int1x4)}, {typeof(Int1x4)}, {typeof(Int1x4)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int2x1 Clamp(Int2x1 x, Int2x1 min, Int2x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int2x1)}, {typeof(Int2x1)}, {typeof(Int2x1)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int2x2 Clamp(Int2x2 x, Int2x2 min, Int2x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int2x2)}, {typeof(Int2x2)}, {typeof(Int2x2)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int2x3 Clamp(Int2x3 x, Int2x3 min, Int2x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int2x3)}, {typeof(Int2x3)}, {typeof(Int2x3)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int2x4 Clamp(Int2x4 x, Int2x4 min, Int2x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int2x4)}, {typeof(Int2x4)}, {typeof(Int2x4)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int3x1 Clamp(Int3x1 x, Int3x1 min, Int3x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int3x1)}, {typeof(Int3x1)}, {typeof(Int3x1)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int3x2 Clamp(Int3x2 x, Int3x2 min, Int3x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int3x2)}, {typeof(Int3x2)}, {typeof(Int3x2)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int3x3 Clamp(Int3x3 x, Int3x3 min, Int3x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int3x3)}, {typeof(Int3x3)}, {typeof(Int3x3)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int3x4 Clamp(Int3x4 x, Int3x4 min, Int3x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int3x4)}, {typeof(Int3x4)}, {typeof(Int3x4)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int4x1 Clamp(Int4x1 x, Int4x1 min, Int4x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int4x1)}, {typeof(Int4x1)}, {typeof(Int4x1)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int4x2 Clamp(Int4x2 x, Int4x2 min, Int4x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int4x2)}, {typeof(Int4x2)}, {typeof(Int4x2)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int4x3 Clamp(Int4x3 x, Int4x3 min, Int4x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int4x3)}, {typeof(Int4x3)}, {typeof(Int4x3)})"); + + /// + /// Clamps the specified value to the specified minimum and maximum range. + /// + /// The value to clamp. + /// The specified minimum range. + /// The specified maximum range. + /// The clamped value for the parameter. + [Pure] + [HlslIntrinsicName("clamp")] + public static Int4x4 Clamp(Int4x4 x, Int4x4 min, Int4x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Clamp)}({typeof(Int4x4)}, {typeof(Int4x4)}, {typeof(Int4x4)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static float Cos(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(float)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float2 Cos(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float2)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float3 Cos(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float3)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float4 Cos(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float4)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float1x1 Cos(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float1x1)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float1x2 Cos(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float1x2)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float1x3 Cos(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float1x3)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float1x4 Cos(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float1x4)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float2x1 Cos(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float2x1)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float2x2 Cos(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float2x2)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float2x3 Cos(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float2x3)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float2x4 Cos(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float2x4)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float3x1 Cos(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float3x1)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float3x2 Cos(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float3x2)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float3x3 Cos(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float3x3)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float3x4 Cos(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float3x4)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float4x1 Cos(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float4x1)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float4x2 Cos(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float4x2)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float4x3 Cos(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float4x3)})"); + + /// + /// Returns the cosine of the specified value. + /// + /// The specified value, in radians. + /// The cosine of the parameter. + [Pure] + [HlslIntrinsicName("cos")] + public static Float4x4 Cos(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cos)}({typeof(Float4x4)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static float Cosh(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(float)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float2 Cosh(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float2)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float3 Cosh(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float3)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float4 Cosh(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float4)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float1x1 Cosh(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float1x1)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float1x2 Cosh(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float1x2)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float1x3 Cosh(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float1x3)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float1x4 Cosh(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float1x4)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float2x1 Cosh(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float2x1)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float2x2 Cosh(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float2x2)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float2x3 Cosh(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float2x3)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float2x4 Cosh(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float2x4)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float3x1 Cosh(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float3x1)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float3x2 Cosh(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float3x2)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float3x3 Cosh(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float3x3)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float3x4 Cosh(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float3x4)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float4x1 Cosh(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float4x1)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float4x2 Cosh(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float4x2)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float4x3 Cosh(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float4x3)})"); + + /// + /// Returns the hyperbolic cosine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic cosine of the parameter. + [Pure] + [HlslIntrinsicName("cosh")] + public static Float4x4 Cosh(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cosh)}({typeof(Float4x4)})"); + + /// + /// Counts the number of bits (per component) in the input integer. + /// + /// The input value. + /// The number of bits. + [Pure] + [HlslIntrinsicName("countbits")] + public static uint CountBits(uint x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(CountBits)}({typeof(uint)})"); + + /// + /// Counts the number of bits (per component) in the input integer. + /// + /// The input value. + /// The number of bits. + [Pure] + [HlslIntrinsicName("countbits")] + public static UInt2 CountBits(UInt2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(CountBits)}({typeof(UInt2)})"); + + /// + /// Counts the number of bits (per component) in the input integer. + /// + /// The input value. + /// The number of bits. + [Pure] + [HlslIntrinsicName("countbits")] + public static UInt3 CountBits(UInt3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(CountBits)}({typeof(UInt3)})"); + + /// + /// Counts the number of bits (per component) in the input integer. + /// + /// The input value. + /// The number of bits. + [Pure] + [HlslIntrinsicName("countbits")] + public static UInt4 CountBits(UInt4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(CountBits)}({typeof(UInt4)})"); + + /// + /// Returns the cross product of two floating-point, 3D vectors. + /// + /// The first floating-point, 3D vector. + /// The second floating-point, 3D vector. + /// The number of bits. + [Pure] + [HlslIntrinsicName("cross")] + public static Float3 Cross(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Cross)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static float Degrees(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(float)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float2 Degrees(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float2)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float3 Degrees(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float3)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float4 Degrees(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float4)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float1x1 Degrees(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float1x1)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float1x2 Degrees(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float1x2)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float1x3 Degrees(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float1x3)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float1x4 Degrees(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float1x4)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float2x1 Degrees(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float2x1)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float2x2 Degrees(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float2x2)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float2x3 Degrees(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float2x3)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float2x4 Degrees(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float2x4)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float3x1 Degrees(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float3x1)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float3x2 Degrees(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float3x2)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float3x3 Degrees(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float3x3)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float3x4 Degrees(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float3x4)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float4x1 Degrees(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float4x1)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float4x2 Degrees(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float4x2)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float4x3 Degrees(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float4x3)})"); + + /// + /// Converts the specified value from radians to degrees. + /// + /// The specified value. + /// The result of converting the parameter from radians to degrees. + [Pure] + [HlslIntrinsicName("degrees")] + public static Float4x4 Degrees(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Degrees)}({typeof(Float4x4)})"); + + /// + /// Returns the determinant of the specified floating-point, square matrix. + /// + /// The specified value. + /// The floating-point, scalar value that represents the determinant of the parameter. + [Pure] + [HlslIntrinsicName("determinant")] + public static float Determinant(Float1x1 m) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Determinant)}({typeof(Float1x1)})"); + + /// + /// Returns the determinant of the specified floating-point, square matrix. + /// + /// The specified value. + /// The floating-point, scalar value that represents the determinant of the parameter. + [Pure] + [HlslIntrinsicName("determinant")] + public static float Determinant(Float2x2 m) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Determinant)}({typeof(Float2x2)})"); + + /// + /// Returns the determinant of the specified floating-point, square matrix. + /// + /// The specified value. + /// The floating-point, scalar value that represents the determinant of the parameter. + [Pure] + [HlslIntrinsicName("determinant")] + public static float Determinant(Float3x3 m) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Determinant)}({typeof(Float3x3)})"); + + /// + /// Returns the determinant of the specified floating-point, square matrix. + /// + /// The specified value. + /// The floating-point, scalar value that represents the determinant of the parameter. + [Pure] + [HlslIntrinsicName("determinant")] + public static float Determinant(Float4x4 m) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Determinant)}({typeof(Float4x4)})"); + + /// + /// Returns a distance scalar between two vectors. + /// + /// The first floating-point vector to compare. + /// The second floating-point vector to compare. + /// A floating-point, scalar value that represents the distance between the parameter and the parameter. + [Pure] + [HlslIntrinsicName("distance")] + public static Float2 Distance(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Distance)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Returns a distance scalar between two vectors. + /// + /// The first floating-point vector to compare. + /// The second floating-point vector to compare. + /// A floating-point, scalar value that represents the distance between the parameter and the parameter. + [Pure] + [HlslIntrinsicName("distance")] + public static Float3 Distance(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Distance)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Returns a distance scalar between two vectors. + /// + /// The first floating-point vector to compare. + /// The second floating-point vector to compare. + /// A floating-point, scalar value that represents the distance between the parameter and the parameter. + [Pure] + [HlslIntrinsicName("distance")] + public static Float4 Distance(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Distance)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Returns the dot product of two vectors. + /// + /// The first vector. + /// The second vector. + /// The dot product of the parameter and the parameter. + [Pure] + [HlslIntrinsicName("dot")] + public static float Dot(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Dot)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Returns the dot product of two vectors. + /// + /// The first vector. + /// The second vector. + /// The dot product of the parameter and the parameter. + [Pure] + [HlslIntrinsicName("dot")] + public static float Dot(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Dot)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Returns the dot product of two vectors. + /// + /// The first vector. + /// The second vector. + /// The dot product of the parameter and the parameter. + [Pure] + [HlslIntrinsicName("dot")] + public static float Dot(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Dot)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Returns the dot product of two vectors. + /// + /// The first vector. + /// The second vector. + /// The dot product of the parameter and the parameter. + [Pure] + [HlslIntrinsicName("dot")] + public static float Dot(Int2 x, Int2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Dot)}({typeof(Int2)}, {typeof(Int2)})"); + + /// + /// Returns the dot product of two vectors. + /// + /// The first vector. + /// The second vector. + /// The dot product of the parameter and the parameter. + [Pure] + [HlslIntrinsicName("dot")] + public static float Dot(Int3 x, Int3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Dot)}({typeof(Int3)}, {typeof(Int3)})"); + + /// + /// Returns the dot product of two vectors. + /// + /// The first vector. + /// The second vector. + /// The dot product of the parameter and the parameter. + [Pure] + [HlslIntrinsicName("dot")] + public static float Dot(Int4 x, Int4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Dot)}({typeof(Int4)}, {typeof(Int4)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static float Exp(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(float)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float2 Exp(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float2)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float3 Exp(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float3)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float4 Exp(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float4)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float1x1 Exp(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float1x1)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float1x2 Exp(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float1x2)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float1x3 Exp(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float1x3)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float1x4 Exp(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float1x4)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float2x1 Exp(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float2x1)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float2x2 Exp(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float2x2)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float2x3 Exp(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float2x3)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float2x4 Exp(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float2x4)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float3x1 Exp(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float3x1)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float3x2 Exp(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float3x2)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float3x3 Exp(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float3x3)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float3x4 Exp(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float3x4)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float4x1 Exp(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float4x1)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float4x2 Exp(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float4x2)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float4x3 Exp(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float4x3)})"); + + /// + /// Returns the base-e exponential of the specified value. + /// + /// The specified value. + /// The base-e exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp")] + public static Float4x4 Exp(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp)}({typeof(Float4x4)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static float Exp2(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(float)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float2 Exp2(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float2)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float3 Exp2(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float3)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float4 Exp2(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float4)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float1x1 Exp2(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float1x1)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float1x2 Exp2(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float1x2)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float1x3 Exp2(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float1x3)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float1x4 Exp2(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float1x4)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float2x1 Exp2(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float2x1)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float2x2 Exp2(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float2x2)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float2x3 Exp2(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float2x3)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float2x4 Exp2(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float2x4)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float3x1 Exp2(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float3x1)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float3x2 Exp2(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float3x2)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float3x3 Exp2(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float3x3)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float3x4 Exp2(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float3x4)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float4x1 Exp2(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float4x1)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float4x2 Exp2(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float4x2)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float4x3 Exp2(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float4x3)})"); + + /// + /// Returns the base-2 exponential of the specified value. + /// + /// The specified value. + /// The base-2 exponential of the parameter. + [Pure] + [HlslIntrinsicName("exp2")] + public static Float4x4 Exp2(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Exp2)}({typeof(Float4x4)})"); + + /// + /// Gets the location of the first set bit starting from the highest order bit and working downward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbithigh")] + public static int FirstBitHigh(int value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitHigh)}({typeof(int)})"); + + /// + /// Gets the location of the first set bit starting from the highest order bit and working downward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbithigh")] + public static Int2 FirstBitHigh(Int2 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitHigh)}({typeof(Int2)})"); + + /// + /// Gets the location of the first set bit starting from the highest order bit and working downward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbithigh")] + public static Int3 FirstBitHigh(Int3 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitHigh)}({typeof(Int3)})"); + + /// + /// Gets the location of the first set bit starting from the highest order bit and working downward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbithigh")] + public static Int4 FirstBitHigh(Int4 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitHigh)}({typeof(Int4)})"); + + /// + /// Gets the location of the first set bit starting from the highest order bit and working downward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbithigh")] + public static uint FirstBitHigh(uint value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitHigh)}({typeof(uint)})"); + + /// + /// Gets the location of the first set bit starting from the highest order bit and working downward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbithigh")] + public static UInt2 FirstBitHigh(UInt2 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitHigh)}({typeof(UInt2)})"); + + /// + /// Gets the location of the first set bit starting from the highest order bit and working downward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbithigh")] + public static UInt3 FirstBitHigh(UInt3 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitHigh)}({typeof(UInt3)})"); + + /// + /// Gets the location of the first set bit starting from the highest order bit and working downward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbithigh")] + public static UInt4 FirstBitHigh(UInt4 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitHigh)}({typeof(UInt4)})"); + + /// + /// Returns the location of the first set bit starting from the lowest order bit and working upward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbitlow")] + public static int FirstBitLow(int value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitLow)}({typeof(int)})"); + + /// + /// Returns the location of the first set bit starting from the lowest order bit and working upward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbitlow")] + public static Int2 FirstBitLow(Int2 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitLow)}({typeof(Int2)})"); + + /// + /// Returns the location of the first set bit starting from the lowest order bit and working upward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbitlow")] + public static Int3 FirstBitLow(Int3 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitLow)}({typeof(Int3)})"); + + /// + /// Returns the location of the first set bit starting from the lowest order bit and working upward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbitlow")] + public static Int4 FirstBitLow(Int4 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitLow)}({typeof(Int4)})"); + + /// + /// Returns the location of the first set bit starting from the lowest order bit and working upward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbitlow")] + public static uint FirstBitLow(uint value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitLow)}({typeof(uint)})"); + + /// + /// Returns the location of the first set bit starting from the lowest order bit and working upward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbitlow")] + public static UInt2 FirstBitLow(UInt2 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitLow)}({typeof(UInt2)})"); + + /// + /// Returns the location of the first set bit starting from the lowest order bit and working upward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbitlow")] + public static UInt3 FirstBitLow(UInt3 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitLow)}({typeof(UInt3)})"); + + /// + /// Returns the location of the first set bit starting from the lowest order bit and working upward, per component. + /// + /// The input value. + /// The location of the first set bit. + [Pure] + [HlslIntrinsicName("firstbitlow")] + public static UInt4 FirstBitLow(UInt4 value) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FirstBitLow)}({typeof(UInt4)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static float Floor(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(float)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float2 Floor(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float2)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float3 Floor(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float3)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float4 Floor(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float4)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float1x1 Floor(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float1x1)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float1x2 Floor(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float1x2)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float1x3 Floor(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float1x3)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float1x4 Floor(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float1x4)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float2x1 Floor(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float2x1)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float2x2 Floor(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float2x2)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float2x3 Floor(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float2x3)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float2x4 Floor(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float2x4)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float3x1 Floor(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float3x1)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float3x2 Floor(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float3x2)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float3x3 Floor(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float3x3)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float3x4 Floor(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float3x4)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float4x1 Floor(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float4x1)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float4x2 Floor(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float4x2)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float4x3 Floor(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float4x3)})"); + + /// + /// Returns the largest integer that is less than or equal to the specified value. + /// + /// The specified value. + /// The largest integer value (returned as a floating-point type) that is less than or equal to the parameter. + [Pure] + [HlslIntrinsicName("floor")] + public static Float4x4 Floor(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Floor)}({typeof(Float4x4)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static double FusedMultiplyAccumulate(double a, double b, double c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(double)}, {typeof(double)}, {typeof(double)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double2 FusedMultiplyAccumulate(Double2 a, Double2 b, Double2 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double2)}, {typeof(Double2)}, {typeof(Double2)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double3 FusedMultiplyAccumulate(Double3 a, Double3 b, Double3 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double3)}, {typeof(Double3)}, {typeof(Double3)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double4 FusedMultiplyAccumulate(Double4 a, Double4 b, Double4 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double4)}, {typeof(Double4)}, {typeof(Double4)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double1x1 FusedMultiplyAccumulate(Double1x1 a, Double1x1 b, Double1x1 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double1x1)}, {typeof(Double1x1)}, {typeof(Double1x1)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double1x2 FusedMultiplyAccumulate(Double1x2 a, Double1x2 b, Double1x2 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double1x2)}, {typeof(Double1x2)}, {typeof(Double1x2)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double1x3 FusedMultiplyAccumulate(Double1x3 a, Double1x3 b, Double1x3 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double1x3)}, {typeof(Double1x3)}, {typeof(Double1x3)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double1x4 FusedMultiplyAccumulate(Double1x4 a, Double1x4 b, Double1x4 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double1x4)}, {typeof(Double1x4)}, {typeof(Double1x4)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double2x1 FusedMultiplyAccumulate(Double2x1 a, Double2x1 b, Double2x1 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double2x1)}, {typeof(Double2x1)}, {typeof(Double2x1)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double2x2 FusedMultiplyAccumulate(Double2x2 a, Double2x2 b, Double2x2 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double2x2)}, {typeof(Double2x2)}, {typeof(Double2x2)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double2x3 FusedMultiplyAccumulate(Double2x3 a, Double2x3 b, Double2x3 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double2x3)}, {typeof(Double2x3)}, {typeof(Double2x3)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double2x4 FusedMultiplyAccumulate(Double2x4 a, Double2x4 b, Double2x4 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double2x4)}, {typeof(Double2x4)}, {typeof(Double2x4)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double3x1 FusedMultiplyAccumulate(Double3x1 a, Double3x1 b, Double3x1 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double3x1)}, {typeof(Double3x1)}, {typeof(Double3x1)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double3x2 FusedMultiplyAccumulate(Double3x2 a, Double3x2 b, Double3x2 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double3x2)}, {typeof(Double3x2)}, {typeof(Double3x2)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double3x3 FusedMultiplyAccumulate(Double3x3 a, Double3x3 b, Double3x3 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double3x3)}, {typeof(Double3x3)}, {typeof(Double3x3)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double3x4 FusedMultiplyAccumulate(Double3x4 a, Double3x4 b, Double3x4 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double3x4)}, {typeof(Double3x4)}, {typeof(Double3x4)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double4x1 FusedMultiplyAccumulate(Double4x1 a, Double4x1 b, Double4x1 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double4x1)}, {typeof(Double4x1)}, {typeof(Double4x1)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double4x2 FusedMultiplyAccumulate(Double4x2 a, Double4x2 b, Double4x2 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double4x2)}, {typeof(Double4x2)}, {typeof(Double4x2)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double4x3 FusedMultiplyAccumulate(Double4x3 a, Double4x3 b, Double4x3 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double4x3)}, {typeof(Double4x3)}, {typeof(Double4x3)})"); + + /// + /// Returns the double-precision fused multiply-addition of a * b + c. + /// + /// The first value in the fused multiply-addition. + /// The second value in the fused multiply-addition. + /// The third value in the fused multiply-addition. + /// The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP). + [Pure] + [HlslIntrinsicName("fma")] + public static Double4x4 FusedMultiplyAccumulate(Double4x4 a, Double4x4 b, Double4x4 c) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(FusedMultiplyAccumulate)}({typeof(Double4x4)}, {typeof(Double4x4)}, {typeof(Double4x4)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static float Fmod(float x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(float)}, {typeof(float)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float2 Fmod(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float3 Fmod(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float4 Fmod(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float1x1 Fmod(Float1x1 x, Float1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float1x2 Fmod(Float1x2 x, Float1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float1x3 Fmod(Float1x3 x, Float1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float1x4 Fmod(Float1x4 x, Float1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float2x1 Fmod(Float2x1 x, Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float2x2 Fmod(Float2x2 x, Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float2x3 Fmod(Float2x3 x, Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float2x4 Fmod(Float2x4 x, Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float3x1 Fmod(Float3x1 x, Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float3x2 Fmod(Float3x2 x, Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float3x3 Fmod(Float3x3 x, Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float3x4 Fmod(Float3x4 x, Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float4x1 Fmod(Float4x1 x, Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float4x2 Fmod(Float4x2 x, Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float4x3 Fmod(Float4x3 x, Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Returns the floating-point remainder of x / y. + /// + /// The floating-point dividend. + /// The floating-point divisor. + /// The floating-point remainder of the x parameter divided by the y parameter. + [Pure] + [HlslIntrinsicName("fmod")] + public static Float4x4 Fmod(Float4x4 x, Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Fmod)}({typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static float Frac(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(float)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float2 Frac(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float2)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float3 Frac(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float3)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float4 Frac(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float4)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float1x1 Frac(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float1x1)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float1x2 Frac(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float1x2)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float1x3 Frac(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float1x3)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float1x4 Frac(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float1x4)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float2x1 Frac(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float2x1)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float2x2 Frac(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float2x2)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float2x3 Frac(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float2x3)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float2x4 Frac(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float2x4)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float3x1 Frac(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float3x1)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float3x2 Frac(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float3x2)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float3x3 Frac(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float3x3)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float3x4 Frac(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float3x4)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float4x1 Frac(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float4x1)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float4x2 Frac(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float4x2)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float4x3 Frac(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float4x3)})"); + + /// + /// Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1. + /// + /// The specified value. + /// The fractional part of the parameter. + [Pure] + [HlslIntrinsicName("frac")] + public static Float4x4 Frac(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frac)}({typeof(Float4x4)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static float Frexp(float x, out float exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(float)}, {typeof(float)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float2 Frexp(Float2 x, out Float2 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float3 Frexp(Float3 x, out Float3 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float4 Frexp(Float4 x, out Float4 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float1x1 Frexp(Float1x1 x, out Float1x1 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float1x2 Frexp(Float1x2 x, out Float1x2 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float1x3 Frexp(Float1x3 x, out Float1x3 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float1x4 Frexp(Float1x4 x, out Float1x4 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float2x1 Frexp(Float2x1 x, out Float2x1 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float2x2 Frexp(Float2x2 x, out Float2x2 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float2x3 Frexp(Float2x3 x, out Float2x3 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float2x4 Frexp(Float2x4 x, out Float2x4 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float3x1 Frexp(Float3x1 x, out Float3x1 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float3x2 Frexp(Float3x2 x, out Float3x2 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float3x3 Frexp(Float3x3 x, out Float3x3 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float3x4 Frexp(Float3x4 x, out Float3x4 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float4x1 Frexp(Float4x1 x, out Float4x1 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float4x2 Frexp(Float4x2 x, out Float4x2 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float4x3 Frexp(Float4x3 x, out Float4x3 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Returns the mantissa and exponent of the specified floating-point value. + /// + /// The specified floating-point value. + /// The returned exponent of the input parameter. + /// The mantissa of the parameter. + [HlslIntrinsicName("frexp")] + public static Float4x4 Frexp(Float4x4 x, out Float4x4 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Frexp)}({typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static bool IsFinite(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(float)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool2 IsFinite(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float2)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool3 IsFinite(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float3)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool4 IsFinite(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float4)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool1x1 IsFinite(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float1x1)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool1x2 IsFinite(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float1x2)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool1x3 IsFinite(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float1x3)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool1x4 IsFinite(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float1x4)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool2x1 IsFinite(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float2x1)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool2x2 IsFinite(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float2x2)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool2x3 IsFinite(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float2x3)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool2x4 IsFinite(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float2x4)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool3x1 IsFinite(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float3x1)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool3x2 IsFinite(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float3x2)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool3x3 IsFinite(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float3x3)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool3x4 IsFinite(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float3x4)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool4x1 IsFinite(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float4x1)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool4x2 IsFinite(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float4x2)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool4x3 IsFinite(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float4x3)})"); + + /// + /// Determines if the specified floating-point value is finite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is finite. + [Pure] + [HlslIntrinsicName("isfinite")] + public static Bool4x4 IsFinite(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsFinite)}({typeof(Float4x4)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static bool IsInfinite(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(float)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool2 IsInfinite(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float2)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool3 IsInfinite(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float3)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool4 IsInfinite(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float4)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool1x1 IsInfinite(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float1x1)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool1x2 IsInfinite(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float1x2)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool1x3 IsInfinite(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float1x3)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool1x4 IsInfinite(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float1x4)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool2x1 IsInfinite(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float2x1)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool2x2 IsInfinite(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float2x2)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool2x3 IsInfinite(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float2x3)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool2x4 IsInfinite(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float2x4)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool3x1 IsInfinite(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float3x1)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool3x2 IsInfinite(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float3x2)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool3x3 IsInfinite(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float3x3)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool3x4 IsInfinite(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float3x4)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool4x1 IsInfinite(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float4x1)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool4x2 IsInfinite(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float4x2)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool4x3 IsInfinite(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float4x3)})"); + + /// + /// Determines if the specified value is infinite. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is infinite. + [Pure] + [HlslIntrinsicName("isinf")] + public static Bool4x4 IsInfinite(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsInfinite)}({typeof(Float4x4)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static bool IsNaN(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(float)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool2 IsNaN(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float2)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool3 IsNaN(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float3)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool4 IsNaN(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float4)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool1x1 IsNaN(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float1x1)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool1x2 IsNaN(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float1x2)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool1x3 IsNaN(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float1x3)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool1x4 IsNaN(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float1x4)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool2x1 IsNaN(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float2x1)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool2x2 IsNaN(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float2x2)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool2x3 IsNaN(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float2x3)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool2x4 IsNaN(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float2x4)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool3x1 IsNaN(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float3x1)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool3x2 IsNaN(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float3x2)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool3x3 IsNaN(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float3x3)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool3x4 IsNaN(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float3x4)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool4x1 IsNaN(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float4x1)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool4x2 IsNaN(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float4x2)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool4x3 IsNaN(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float4x3)})"); + + /// + /// Determines if the specified value is NAN or QNAN. + /// + /// The specified value. + /// Returns a value of the same size as , indicaating whether each component is NAN or QNAN. + [Pure] + [HlslIntrinsicName("isnan")] + public static Bool4x4 IsNaN(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(IsNaN)}({typeof(Float4x4)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static float Ldexp(float x, float exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(float)}, {typeof(float)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float2 Ldexp(Float2 x, Float2 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float3 Ldexp(Float3 x, Float3 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float4 Ldexp(Float4 x, Float4 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float1x1 Ldexp(Float1x1 x, Float1x1 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float1x2 Ldexp(Float1x2 x, Float1x2 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float1x3 Ldexp(Float1x3 x, Float1x3 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float1x4 Ldexp(Float1x4 x, Float1x4 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float2x1 Ldexp(Float2x1 x, Float2x1 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float2x2 Ldexp(Float2x2 x, Float2x2 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float2x3 Ldexp(Float2x3 x, Float2x3 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float2x4 Ldexp(Float2x4 x, Float2x4 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float3x1 Ldexp(Float3x1 x, Float3x1 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float3x2 Ldexp(Float3x2 x, Float3x2 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float3x3 Ldexp(Float3x3 x, Float3x3 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float3x4 Ldexp(Float3x4 x, Float3x4 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float4x1 Ldexp(Float4x1 x, Float4x1 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float4x2 Ldexp(Float4x2 x, Float4x2 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float4x3 Ldexp(Float4x3 x, Float4x3 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Returns the result of multiplying the specified value by two, raised to the power of the specified exponent. + /// + /// The specified value. + /// The specified exponent. + /// The result of multiplying the parameter by two, raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("ldexp")] + public static Float4x4 Ldexp(Float4x4 x, Float4x4 exp) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Ldexp)}({typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Returns the length of the specified floating-point vector. + /// + /// The specified floating-point vector. + /// A floating-point scalar that represents the length of the parameter. + [Pure] + [HlslIntrinsicName("length")] + public static float Length(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Length)}({typeof(Float2)})"); + + /// + /// Returns the length of the specified floating-point vector. + /// + /// The specified floating-point vector. + /// A floating-point scalar that represents the length of the parameter. + [Pure] + [HlslIntrinsicName("length")] + public static float Length(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Length)}({typeof(Float3)})"); + + /// + /// Returns the length of the specified floating-point vector. + /// + /// The specified floating-point vector. + /// A floating-point scalar that represents the length of the parameter. + [Pure] + [HlslIntrinsicName("length")] + public static float Length(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Length)}({typeof(Float4)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static float Lerp(float x, float min, float max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(float)}, {typeof(float)}, {typeof(float)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float2 Lerp(Float2 x, Float2 min, Float2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float2)}, {typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float3 Lerp(Float3 x, Float3 min, Float3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float3)}, {typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float4 Lerp(Float4 x, Float4 min, Float4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float4)}, {typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float1x1 Lerp(Float1x1 x, Float1x1 min, Float1x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float1x1)}, {typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float1x2 Lerp(Float1x2 x, Float1x2 min, Float1x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float1x2)}, {typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float1x3 Lerp(Float1x3 x, Float1x3 min, Float1x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float1x3)}, {typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float1x4 Lerp(Float1x4 x, Float1x4 min, Float1x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float1x4)}, {typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float2x1 Lerp(Float2x1 x, Float2x1 min, Float2x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float2x1)}, {typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float2x2 Lerp(Float2x2 x, Float2x2 min, Float2x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float2x2)}, {typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float2x3 Lerp(Float2x3 x, Float2x3 min, Float2x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float2x3)}, {typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float2x4 Lerp(Float2x4 x, Float2x4 min, Float2x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float2x4)}, {typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float3x1 Lerp(Float3x1 x, Float3x1 min, Float3x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float3x1)}, {typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float3x2 Lerp(Float3x2 x, Float3x2 min, Float3x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float3x2)}, {typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float3x3 Lerp(Float3x3 x, Float3x3 min, Float3x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float3x3)}, {typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float3x4 Lerp(Float3x4 x, Float3x4 min, Float3x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float3x4)}, {typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float4x1 Lerp(Float4x1 x, Float4x1 min, Float4x1 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float4x1)}, {typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float4x2 Lerp(Float4x2 x, Float4x2 min, Float4x2 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float4x2)}, {typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float4x3 Lerp(Float4x3 x, Float4x3 min, Float4x3 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float4x3)}, {typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Performs a linear interpolation. + /// + /// The first-floating point value. + /// The second-floating point value. + /// A value that linearly interpolates between the two inputs. + /// The result of the linear interpolation. + [Pure] + [HlslIntrinsicName("lerp")] + public static Float4x4 Lerp(Float4x4 x, Float4x4 min, Float4x4 max) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Lerp)}({typeof(Float4x4)}, {typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static float Log(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(float)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float2 Log(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float2)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float3 Log(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float3)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float4 Log(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float4)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float1x1 Log(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float1x1)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float1x2 Log(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float1x2)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float1x3 Log(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float1x3)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float1x4 Log(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float1x4)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float2x1 Log(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float2x1)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float2x2 Log(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float2x2)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float2x3 Log(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float2x3)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float2x4 Log(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float2x4)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float3x1 Log(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float3x1)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float3x2 Log(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float3x2)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float3x3 Log(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float3x3)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float3x4 Log(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float3x4)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float4x1 Log(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float4x1)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float4x2 Log(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float4x2)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float4x3 Log(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float4x3)})"); + + /// + /// Returns the base-e logarithm of the specified value. + /// + /// The specified value. + /// The base-e logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log")] + public static Float4x4 Log(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log)}({typeof(Float4x4)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static float Log10(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(float)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float2 Log10(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float2)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float3 Log10(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float3)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float4 Log10(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float4)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float1x1 Log10(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float1x1)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float1x2 Log10(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float1x2)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float1x3 Log10(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float1x3)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float1x4 Log10(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float1x4)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float2x1 Log10(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float2x1)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float2x2 Log10(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float2x2)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float2x3 Log10(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float2x3)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float2x4 Log10(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float2x4)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float3x1 Log10(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float3x1)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float3x2 Log10(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float3x2)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float3x3 Log10(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float3x3)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float3x4 Log10(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float3x4)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float4x1 Log10(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float4x1)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float4x2 Log10(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float4x2)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float4x3 Log10(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float4x3)})"); + + /// + /// Returns the base-10 logarithm of the specified value. + /// + /// The specified value. + /// The base-10 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log10")] + public static Float4x4 Log10(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log10)}({typeof(Float4x4)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static float Log2(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(float)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float2 Log2(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float2)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float3 Log2(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float3)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float4 Log2(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float4)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float1x1 Log2(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float1x1)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float1x2 Log2(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float1x2)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float1x3 Log2(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float1x3)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float1x4 Log2(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float1x4)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float2x1 Log2(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float2x1)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float2x2 Log2(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float2x2)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float2x3 Log2(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float2x3)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float2x4 Log2(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float2x4)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float3x1 Log2(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float3x1)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float3x2 Log2(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float3x2)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float3x3 Log2(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float3x3)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float3x4 Log2(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float3x4)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float4x1 Log2(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float4x1)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float4x2 Log2(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float4x2)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float4x3 Log2(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float4x3)})"); + + /// + /// Returns the base-2 logarithm of the specified value. + /// + /// The specified value. + /// The base-2 logarithm of the parameter. If the parameter is negative, this function returns indefinite. If the parameter is 0, this function returns negative infinity. + [Pure] + [HlslIntrinsicName("log2")] + public static Float4x4 Log2(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Log2)}({typeof(Float4x4)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static float Max(float x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(float)}, {typeof(float)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float2 Max(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float3 Max(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float4 Max(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float1x1 Max(Float1x1 x, Float1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float1x2 Max(Float1x2 x, Float1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float1x3 Max(Float1x3 x, Float1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float1x4 Max(Float1x4 x, Float1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float2x1 Max(Float2x1 x, Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float2x2 Max(Float2x2 x, Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float2x3 Max(Float2x3 x, Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float2x4 Max(Float2x4 x, Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float3x1 Max(Float3x1 x, Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float3x2 Max(Float3x2 x, Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float3x3 Max(Float3x3 x, Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float3x4 Max(Float3x4 x, Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float4x1 Max(Float4x1 x, Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float4x2 Max(Float4x2 x, Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float4x3 Max(Float4x3 x, Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Float4x4 Max(Float4x4 x, Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static int Max(int x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(int)}, {typeof(int)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int2 Max(Int2 x, Int2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int2)}, {typeof(Int2)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int3 Max(Int3 x, Int3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int3)}, {typeof(Int3)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int4 Max(Int4 x, Int4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int4)}, {typeof(Int4)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int1x1 Max(Int1x1 x, Int1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int1x1)}, {typeof(Int1x1)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int1x2 Max(Int1x2 x, Int1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int1x2)}, {typeof(Int1x2)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int1x3 Max(Int1x3 x, Int1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int1x3)}, {typeof(Int1x3)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int1x4 Max(Int1x4 x, Int1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int1x4)}, {typeof(Int1x4)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int2x1 Max(Int2x1 x, Int2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int2x1)}, {typeof(Int2x1)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int2x2 Max(Int2x2 x, Int2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int2x2)}, {typeof(Int2x2)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int2x3 Max(Int2x3 x, Int2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int2x3)}, {typeof(Int2x3)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int2x4 Max(Int2x4 x, Int2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int2x4)}, {typeof(Int2x4)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int3x1 Max(Int3x1 x, Int3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int3x1)}, {typeof(Int3x1)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int3x2 Max(Int3x2 x, Int3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int3x2)}, {typeof(Int3x2)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int3x3 Max(Int3x3 x, Int3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int3x3)}, {typeof(Int3x3)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int3x4 Max(Int3x4 x, Int3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int3x4)}, {typeof(Int3x4)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int4x1 Max(Int4x1 x, Int4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int4x1)}, {typeof(Int4x1)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int4x2 Max(Int4x2 x, Int4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int4x2)}, {typeof(Int4x2)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int4x3 Max(Int4x3 x, Int4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int4x3)}, {typeof(Int4x3)})"); + + /// + /// Selects the greater between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the largest value. + [Pure] + [HlslIntrinsicName("max")] + public static Int4x4 Max(Int4x4 x, Int4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Max)}({typeof(Int4x4)}, {typeof(Int4x4)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static float Min(float x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(float)}, {typeof(float)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float2 Min(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float3 Min(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float4 Min(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float1x1 Min(Float1x1 x, Float1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float1x2 Min(Float1x2 x, Float1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float1x3 Min(Float1x3 x, Float1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float1x4 Min(Float1x4 x, Float1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float2x1 Min(Float2x1 x, Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float2x2 Min(Float2x2 x, Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float2x3 Min(Float2x3 x, Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float2x4 Min(Float2x4 x, Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float3x1 Min(Float3x1 x, Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float3x2 Min(Float3x2 x, Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float3x3 Min(Float3x3 x, Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float3x4 Min(Float3x4 x, Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float4x1 Min(Float4x1 x, Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float4x2 Min(Float4x2 x, Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float4x3 Min(Float4x3 x, Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Float4x4 Min(Float4x4 x, Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static int Min(int x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(int)}, {typeof(int)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int2 Min(Int2 x, Int2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int2)}, {typeof(Int2)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int3 Min(Int3 x, Int3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int3)}, {typeof(Int3)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int4 Min(Int4 x, Int4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int4)}, {typeof(Int4)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int1x1 Min(Int1x1 x, Int1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int1x1)}, {typeof(Int1x1)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int1x2 Min(Int1x2 x, Int1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int1x2)}, {typeof(Int1x2)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int1x3 Min(Int1x3 x, Int1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int1x3)}, {typeof(Int1x3)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int1x4 Min(Int1x4 x, Int1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int1x4)}, {typeof(Int1x4)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int2x1 Min(Int2x1 x, Int2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int2x1)}, {typeof(Int2x1)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int2x2 Min(Int2x2 x, Int2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int2x2)}, {typeof(Int2x2)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int2x3 Min(Int2x3 x, Int2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int2x3)}, {typeof(Int2x3)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int2x4 Min(Int2x4 x, Int2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int2x4)}, {typeof(Int2x4)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int3x1 Min(Int3x1 x, Int3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int3x1)}, {typeof(Int3x1)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int3x2 Min(Int3x2 x, Int3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int3x2)}, {typeof(Int3x2)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int3x3 Min(Int3x3 x, Int3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int3x3)}, {typeof(Int3x3)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int3x4 Min(Int3x4 x, Int3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int3x4)}, {typeof(Int3x4)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int4x1 Min(Int4x1 x, Int4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int4x1)}, {typeof(Int4x1)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int4x2 Min(Int4x2 x, Int4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int4x2)}, {typeof(Int4x2)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int4x3 Min(Int4x3 x, Int4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int4x3)}, {typeof(Int4x3)})"); + + /// + /// Selects the lesser between two inputs. + /// + /// The first input value. + /// The second input value. + /// The or parameter, whichever is the smallest value. + [Pure] + [HlslIntrinsicName("min")] + public static Int4x4 Min(Int4x4 x, Int4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Min)}({typeof(Int4x4)}, {typeof(Int4x4)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static float Modf(float x, out float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(float)}, {typeof(float)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float2 Modf(Float2 x, out Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float3 Modf(Float3 x, out Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float4 Modf(Float4 x, out Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float1x1 Modf(Float1x1 x, out Float1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float1x2 Modf(Float1x2 x, out Float1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float1x3 Modf(Float1x3 x, out Float1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float1x4 Modf(Float1x4 x, out Float1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float2x1 Modf(Float2x1 x, out Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float2x2 Modf(Float2x2 x, out Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float2x3 Modf(Float2x3 x, out Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float2x4 Modf(Float2x4 x, out Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float3x1 Modf(Float3x1 x, out Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float3x2 Modf(Float3x2 x, out Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float3x3 Modf(Float3x3 x, out Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float3x4 Modf(Float3x4 x, out Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float4x1 Modf(Float4x1 x, out Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float4x2 Modf(Float4x2 x, out Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float4x3 Modf(Float4x3 x, out Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Float4x4 Modf(Float4x4 x, out Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static int Modf(int x, out int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(int)}, {typeof(int)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int2 Modf(Int2 x, out Int2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int2)}, {typeof(Int2)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int3 Modf(Int3 x, out Int3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int3)}, {typeof(Int3)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int4 Modf(Int4 x, out Int4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int4)}, {typeof(Int4)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int1x1 Modf(Int1x1 x, out Int1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int1x1)}, {typeof(Int1x1)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int1x2 Modf(Int1x2 x, out Int1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int1x2)}, {typeof(Int1x2)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int1x3 Modf(Int1x3 x, out Int1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int1x3)}, {typeof(Int1x3)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int1x4 Modf(Int1x4 x, out Int1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int1x4)}, {typeof(Int1x4)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int2x1 Modf(Int2x1 x, out Int2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int2x1)}, {typeof(Int2x1)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int2x2 Modf(Int2x2 x, out Int2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int2x2)}, {typeof(Int2x2)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int2x3 Modf(Int2x3 x, out Int2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int2x3)}, {typeof(Int2x3)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int2x4 Modf(Int2x4 x, out Int2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int2x4)}, {typeof(Int2x4)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int3x1 Modf(Int3x1 x, out Int3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int3x1)}, {typeof(Int3x1)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int3x2 Modf(Int3x2 x, out Int3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int3x2)}, {typeof(Int3x2)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int3x3 Modf(Int3x3 x, out Int3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int3x3)}, {typeof(Int3x3)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int3x4 Modf(Int3x4 x, out Int3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int3x4)}, {typeof(Int3x4)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int4x1 Modf(Int4x1 x, out Int4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int4x1)}, {typeof(Int4x1)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int4x2 Modf(Int4x2 x, out Int4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int4x2)}, {typeof(Int4x2)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int4x3 Modf(Int4x3 x, out Int4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int4x3)}, {typeof(Int4x3)})"); + + /// + /// Splits a value into fractional and integer parts, each with the same sign as the input value. + /// + /// The input value. + /// The resulting integer portion. + /// The signed-fractional portion of . + [Pure] + [HlslIntrinsicName("modf")] + public static Int4x4 Modf(Int4x4 x, out Int4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Modf)}({typeof(Int4x4)}, {typeof(Int4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static float Mul(float x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static int Mul(int x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2 Mul(float x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3 Mul(float x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4 Mul(float x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2 Mul(int x, Int2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3 Mul(int x, Int3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4 Mul(int x, Int4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x1 Mul(float x, Float1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float1x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x2 Mul(float x, Float1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float1x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x3 Mul(float x, Float1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float1x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x4 Mul(float x, Float1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float1x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x1 Mul(float x, Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x2 Mul(float x, Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x3 Mul(float x, Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x4 Mul(float x, Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x1 Mul(float x, Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x2 Mul(float x, Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x3 Mul(float x, Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x4 Mul(float x, Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x1 Mul(float x, Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x2 Mul(float x, Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x3 Mul(float x, Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x4 Mul(float x, Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(float)}, {typeof(Float4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x1 Mul(int x, Int1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int1x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x2 Mul(int x, Int1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int1x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x3 Mul(int x, Int1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int1x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x4 Mul(int x, Int1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int1x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x1 Mul(int x, Int2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x2 Mul(int x, Int2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x3 Mul(int x, Int2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x4 Mul(int x, Int2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x1 Mul(int x, Int3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x2 Mul(int x, Int3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x3 Mul(int x, Int3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x4 Mul(int x, Int3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x1 Mul(int x, Int4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x2 Mul(int x, Int4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x3 Mul(int x, Int4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x4 Mul(int x, Int4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(int)}, {typeof(Int4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2 Mul(Float2 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3 Mul(Float3 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4 Mul(Float4 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2 Mul(Int2 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3 Mul(Int3 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4 Mul(Int4 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static float Mul(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static float Mul(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static float Mul(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static int Mul(Int2 x, Int2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2)}, {typeof(Int2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static int Mul(Int3 x, Int3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3)}, {typeof(Int3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static int Mul(Int4 x, Int4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4)}, {typeof(Int4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static float Mul(Float2 x, Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2)}, {typeof(Float2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2 Mul(Float2 x, Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2)}, {typeof(Float2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3 Mul(Float2 x, Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2)}, {typeof(Float2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4 Mul(Float2 x, Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2)}, {typeof(Float2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static float Mul(Float3 x, Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3)}, {typeof(Float3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2 Mul(Float3 x, Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3)}, {typeof(Float3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3 Mul(Float3 x, Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3)}, {typeof(Float3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4 Mul(Float3 x, Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3)}, {typeof(Float3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static float Mul(Float4 x, Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4)}, {typeof(Float4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2 Mul(Float4 x, Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4)}, {typeof(Float4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3 Mul(Float4 x, Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4)}, {typeof(Float4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4 Mul(Float4 x, Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4)}, {typeof(Float4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static int Mul(Int2 x, Int2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2)}, {typeof(Int2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2 Mul(Int2 x, Int2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2)}, {typeof(Int2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3 Mul(Int2 x, Int2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2)}, {typeof(Int2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4 Mul(Int2 x, Int2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2)}, {typeof(Int2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static int Mul(Int3 x, Int3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3)}, {typeof(Int3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2 Mul(Int3 x, Int3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3)}, {typeof(Int3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3 Mul(Int3 x, Int3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3)}, {typeof(Int3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4 Mul(Int3 x, Int3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3)}, {typeof(Int3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static int Mul(Int4 x, Int4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4)}, {typeof(Int4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2 Mul(Int4 x, Int4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4)}, {typeof(Int4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3 Mul(Int4 x, Int4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4)}, {typeof(Int4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4 Mul(Int4 x, Int4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4)}, {typeof(Int4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x1 Mul(Float1x1 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x1)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x2 Mul(Float1x2 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x2)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x3 Mul(Float1x3 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x3)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x4 Mul(Float1x4 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x4)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x1 Mul(Float2x1 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x1)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x2 Mul(Float2x2 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x2)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x3 Mul(Float2x3 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x3)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x4 Mul(Float2x4 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x4)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x1 Mul(Float3x1 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x1)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x2 Mul(Float3x2 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x2)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x3 Mul(Float3x3 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x3)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x4 Mul(Float3x4 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x4)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x1 Mul(Float4x1 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x1)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x2 Mul(Float4x2 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x2)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x3 Mul(Float4x3 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x3)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x4 Mul(Float4x4 x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x4)}, {typeof(float)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x1 Mul(Int1x1 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x1)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x2 Mul(Int1x2 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x2)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x3 Mul(Int1x3 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x3)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x4 Mul(Int1x4 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x4)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x1 Mul(Int2x1 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x1)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x2 Mul(Int2x2 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x2)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x3 Mul(Int2x3 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x3)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x4 Mul(Int2x4 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x4)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x1 Mul(Int3x1 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x1)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x2 Mul(Int3x2 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x2)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x3 Mul(Int3x3 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x3)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x4 Mul(Int3x4 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x4)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x1 Mul(Int4x1 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x1)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x2 Mul(Int4x2 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x2)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x3 Mul(Int4x3 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x3)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x4 Mul(Int4x4 x, int y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x4)}, {typeof(int)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static float Mul(Float1x2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x2)}, {typeof(Float2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static float Mul(Float1x3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x3)}, {typeof(Float3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static float Mul(Float1x4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x4)}, {typeof(Float4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2 Mul(Float2x2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x2)}, {typeof(Float2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2 Mul(Float2x3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x3)}, {typeof(Float3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2 Mul(Float2x4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x4)}, {typeof(Float4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3 Mul(Float3x2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x2)}, {typeof(Float2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3 Mul(Float3x3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x3)}, {typeof(Float3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3 Mul(Float3x4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x4)}, {typeof(Float4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4 Mul(Float4x2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x2)}, {typeof(Float2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4 Mul(Float4x3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x3)}, {typeof(Float3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4 Mul(Float4x4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x4)}, {typeof(Float4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static int Mul(Int1x2 x, Int2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x2)}, {typeof(Int2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static int Mul(Int1x3 x, Int3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x3)}, {typeof(Int3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static int Mul(Int1x4 x, Int4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x4)}, {typeof(Int4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2 Mul(Int2x2 x, Int2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x2)}, {typeof(Int2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2 Mul(Int2x3 x, Int3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x3)}, {typeof(Int3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2 Mul(Int2x4 x, Int4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x4)}, {typeof(Int4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3 Mul(Int3x2 x, Int2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x2)}, {typeof(Int2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3 Mul(Int3x3 x, Int3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x3)}, {typeof(Int3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3 Mul(Int3x4 x, Int4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x4)}, {typeof(Int4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4 Mul(Int4x2 x, Int2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x2)}, {typeof(Int2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4 Mul(Int4x3 x, Int3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x3)}, {typeof(Int3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4 Mul(Int4x4 x, Int4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x4)}, {typeof(Int4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x1 Mul(Float1x1 x, Float1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x2 Mul(Float1x1 x, Float1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x1)}, {typeof(Float1x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x3 Mul(Float1x1 x, Float1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x1)}, {typeof(Float1x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x4 Mul(Float1x1 x, Float1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x1)}, {typeof(Float1x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x1 Mul(Float1x2 x, Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x2)}, {typeof(Float2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x2 Mul(Float1x2 x, Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x2)}, {typeof(Float2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x3 Mul(Float1x2 x, Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x2)}, {typeof(Float2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x4 Mul(Float1x2 x, Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x2)}, {typeof(Float2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x1 Mul(Float1x3 x, Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x3)}, {typeof(Float3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x2 Mul(Float1x3 x, Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x3)}, {typeof(Float3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x3 Mul(Float1x3 x, Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x3)}, {typeof(Float3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x4 Mul(Float1x3 x, Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x3)}, {typeof(Float3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x1 Mul(Float1x4 x, Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x4)}, {typeof(Float4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x2 Mul(Float1x4 x, Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x4)}, {typeof(Float4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x3 Mul(Float1x4 x, Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x4)}, {typeof(Float4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float1x4 Mul(Float1x4 x, Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float1x4)}, {typeof(Float4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x1 Mul(Float2x1 x, Float1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x1)}, {typeof(Float1x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x2 Mul(Float2x1 x, Float1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x1)}, {typeof(Float1x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x3 Mul(Float2x1 x, Float1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x1)}, {typeof(Float1x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x4 Mul(Float2x1 x, Float1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x1)}, {typeof(Float1x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x1 Mul(Float2x2 x, Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x2)}, {typeof(Float2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x2 Mul(Float2x2 x, Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x3 Mul(Float2x2 x, Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x2)}, {typeof(Float2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x4 Mul(Float2x2 x, Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x2)}, {typeof(Float2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x1 Mul(Float2x3 x, Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x3)}, {typeof(Float3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x2 Mul(Float2x3 x, Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x3)}, {typeof(Float3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x3 Mul(Float2x3 x, Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x3)}, {typeof(Float3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x4 Mul(Float2x3 x, Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x3)}, {typeof(Float3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x1 Mul(Float2x4 x, Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x4)}, {typeof(Float4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x2 Mul(Float2x4 x, Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x4)}, {typeof(Float4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x3 Mul(Float2x4 x, Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x4)}, {typeof(Float4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float2x4 Mul(Float2x4 x, Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float2x4)}, {typeof(Float4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x1 Mul(Float3x1 x, Float1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x1)}, {typeof(Float1x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x2 Mul(Float3x1 x, Float1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x1)}, {typeof(Float1x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x3 Mul(Float3x1 x, Float1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x1)}, {typeof(Float1x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x4 Mul(Float3x1 x, Float1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x1)}, {typeof(Float1x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x1 Mul(Float3x2 x, Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x2)}, {typeof(Float2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x2 Mul(Float3x2 x, Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x2)}, {typeof(Float2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x3 Mul(Float3x2 x, Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x2)}, {typeof(Float2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x4 Mul(Float3x2 x, Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x2)}, {typeof(Float2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x1 Mul(Float3x3 x, Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x3)}, {typeof(Float3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x2 Mul(Float3x3 x, Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x3)}, {typeof(Float3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x3 Mul(Float3x3 x, Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x4 Mul(Float3x3 x, Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x3)}, {typeof(Float3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x1 Mul(Float3x4 x, Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x4)}, {typeof(Float4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x2 Mul(Float3x4 x, Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x4)}, {typeof(Float4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x3 Mul(Float3x4 x, Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x4)}, {typeof(Float4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float3x4 Mul(Float3x4 x, Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float3x4)}, {typeof(Float4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x1 Mul(Float4x1 x, Float1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x1)}, {typeof(Float1x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x2 Mul(Float4x1 x, Float1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x1)}, {typeof(Float1x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x3 Mul(Float4x1 x, Float1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x1)}, {typeof(Float1x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x4 Mul(Float4x1 x, Float1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x1)}, {typeof(Float1x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x1 Mul(Float4x2 x, Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x2)}, {typeof(Float2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x2 Mul(Float4x2 x, Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x2)}, {typeof(Float2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x3 Mul(Float4x2 x, Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x2)}, {typeof(Float2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x4 Mul(Float4x2 x, Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x2)}, {typeof(Float2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x1 Mul(Float4x3 x, Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x3)}, {typeof(Float3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x2 Mul(Float4x3 x, Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x3)}, {typeof(Float3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x3 Mul(Float4x3 x, Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x3)}, {typeof(Float3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x4 Mul(Float4x3 x, Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x3)}, {typeof(Float3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x1 Mul(Float4x4 x, Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x4)}, {typeof(Float4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x2 Mul(Float4x4 x, Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x4)}, {typeof(Float4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x3 Mul(Float4x4 x, Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x4)}, {typeof(Float4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Float4x4 Mul(Float4x4 x, Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x1 Mul(Int1x1 x, Int1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x1)}, {typeof(Int1x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x2 Mul(Int1x1 x, Int1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x1)}, {typeof(Int1x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x3 Mul(Int1x1 x, Int1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x1)}, {typeof(Int1x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x4 Mul(Int1x1 x, Int1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x1)}, {typeof(Int1x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x1 Mul(Int1x2 x, Int2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x2)}, {typeof(Int2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x2 Mul(Int1x2 x, Int2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x2)}, {typeof(Int2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x3 Mul(Int1x2 x, Int2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x2)}, {typeof(Int2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x4 Mul(Int1x2 x, Int2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x2)}, {typeof(Int2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x1 Mul(Int1x3 x, Int3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x3)}, {typeof(Int3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x2 Mul(Int1x3 x, Int3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x3)}, {typeof(Int3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x3 Mul(Int1x3 x, Int3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x3)}, {typeof(Int3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x4 Mul(Int1x3 x, Int3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x3)}, {typeof(Int3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x1 Mul(Int1x4 x, Int4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x4)}, {typeof(Int4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x2 Mul(Int1x4 x, Int4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x4)}, {typeof(Int4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x3 Mul(Int1x4 x, Int4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x4)}, {typeof(Int4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int1x4 Mul(Int1x4 x, Int4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int1x4)}, {typeof(Int4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x1 Mul(Int2x1 x, Int1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x1)}, {typeof(Int1x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x2 Mul(Int2x1 x, Int1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x1)}, {typeof(Int1x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x3 Mul(Int2x1 x, Int1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x1)}, {typeof(Int1x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x4 Mul(Int2x1 x, Int1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x1)}, {typeof(Int1x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x1 Mul(Int2x2 x, Int2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x2)}, {typeof(Int2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x2 Mul(Int2x2 x, Int2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x2)}, {typeof(Int2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x3 Mul(Int2x2 x, Int2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x2)}, {typeof(Int2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x4 Mul(Int2x2 x, Int2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x2)}, {typeof(Int2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x1 Mul(Int2x3 x, Int3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x3)}, {typeof(Int3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x2 Mul(Int2x3 x, Int3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x3)}, {typeof(Int3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x3 Mul(Int2x3 x, Int3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x3)}, {typeof(Int3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x4 Mul(Int2x3 x, Int3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x3)}, {typeof(Int3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x1 Mul(Int2x4 x, Int4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x4)}, {typeof(Int4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x2 Mul(Int2x4 x, Int4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x4)}, {typeof(Int4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x3 Mul(Int2x4 x, Int4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x4)}, {typeof(Int4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int2x4 Mul(Int2x4 x, Int4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int2x4)}, {typeof(Int4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x1 Mul(Int3x1 x, Int1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x1)}, {typeof(Int1x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x2 Mul(Int3x1 x, Int1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x1)}, {typeof(Int1x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x3 Mul(Int3x1 x, Int1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x1)}, {typeof(Int1x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x4 Mul(Int3x1 x, Int1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x1)}, {typeof(Int1x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x1 Mul(Int3x2 x, Int2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x2)}, {typeof(Int2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x2 Mul(Int3x2 x, Int2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x2)}, {typeof(Int2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x3 Mul(Int3x2 x, Int2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x2)}, {typeof(Int2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x4 Mul(Int3x2 x, Int2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x2)}, {typeof(Int2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x1 Mul(Int3x3 x, Int3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x3)}, {typeof(Int3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x2 Mul(Int3x3 x, Int3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x3)}, {typeof(Int3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x3 Mul(Int3x3 x, Int3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x3)}, {typeof(Int3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x4 Mul(Int3x3 x, Int3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x3)}, {typeof(Int3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x1 Mul(Int3x4 x, Int4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x4)}, {typeof(Int4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x2 Mul(Int3x4 x, Int4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x4)}, {typeof(Int4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x3 Mul(Int3x4 x, Int4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x4)}, {typeof(Int4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int3x4 Mul(Int3x4 x, Int4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int3x4)}, {typeof(Int4x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x1 Mul(Int4x1 x, Int1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x1)}, {typeof(Int1x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x2 Mul(Int4x1 x, Int1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x1)}, {typeof(Int1x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x3 Mul(Int4x1 x, Int1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x1)}, {typeof(Int1x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x4 Mul(Int4x1 x, Int1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x1)}, {typeof(Int1x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x1 Mul(Int4x2 x, Int2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x2)}, {typeof(Int2x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x2 Mul(Int4x2 x, Int2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x2)}, {typeof(Int2x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x3 Mul(Int4x2 x, Int2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x2)}, {typeof(Int2x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x4 Mul(Int4x2 x, Int2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x2)}, {typeof(Int2x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x1 Mul(Int4x3 x, Int3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x3)}, {typeof(Int3x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x2 Mul(Int4x3 x, Int3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x3)}, {typeof(Int3x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x3 Mul(Int4x3 x, Int3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x3)}, {typeof(Int3x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x4 Mul(Int4x3 x, Int3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x3)}, {typeof(Int3x4)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x1 Mul(Int4x4 x, Int4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x4)}, {typeof(Int4x1)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x2 Mul(Int4x4 x, Int4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x4)}, {typeof(Int4x2)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x3 Mul(Int4x4 x, Int4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x4)}, {typeof(Int4x3)})"); + + /// + /// Multiplies two values using matrix math. + /// + /// The first input value. + /// The second input value. + /// The result of times . The result has the dimension -rows by -columns. + [Pure] + [HlslIntrinsicName("mul")] + public static Int4x4 Mul(Int4x4 x, Int4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Mul)}({typeof(Int4x4)}, {typeof(Int4x4)})"); + + /// + /// Generates a random value using the Perlin-noise algorithm. + /// + /// A floating-point vector from which to generate Perlin noise. + /// The Perlin noise value within a range between -1 and 1. + [Pure] + [HlslIntrinsicName("noise")] + public static float Noise(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Noise)}({typeof(Float2)})"); + + /// + /// Generates a random value using the Perlin-noise algorithm. + /// + /// A floating-point vector from which to generate Perlin noise. + /// The Perlin noise value within a range between -1 and 1. + [Pure] + [HlslIntrinsicName("noise")] + public static float Noise(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Noise)}({typeof(Float3)})"); + + /// + /// Generates a random value using the Perlin-noise algorithm. + /// + /// A floating-point vector from which to generate Perlin noise. + /// The Perlin noise value within a range between -1 and 1. + [Pure] + [HlslIntrinsicName("noise")] + public static float Noise(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Noise)}({typeof(Float4)})"); + + /// + /// Normalizes the specified floating-point vector according to x / length(x). + /// + /// The specified floating-point vector. + /// The normalized parameter. If the length of the parameter is 0, the result is indefinite. + [Pure] + [HlslIntrinsicName("normalize")] + public static float Normalize(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Normalize)}({typeof(Float2)})"); + + /// + /// Normalizes the specified floating-point vector according to x / length(x). + /// + /// The specified floating-point vector. + /// The normalized parameter. If the length of the parameter is 0, the result is indefinite. + [Pure] + [HlslIntrinsicName("normalize")] + public static float Normalize(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Normalize)}({typeof(Float3)})"); + + /// + /// Normalizes the specified floating-point vector according to x / length(x). + /// + /// The specified floating-point vector. + /// The normalized parameter. If the length of the parameter is 0, the result is indefinite. + [Pure] + [HlslIntrinsicName("normalize")] + public static float Normalize(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Normalize)}({typeof(Float4)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static float Pow(float x, float y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(float)}, {typeof(float)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float2 Pow(Float2 x, Float2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float3 Pow(Float3 x, Float3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float4 Pow(Float4 x, Float4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float1x1 Pow(Float1x1 x, Float1x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float1x2 Pow(Float1x2 x, Float1x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float1x3 Pow(Float1x3 x, Float1x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float1x4 Pow(Float1x4 x, Float1x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float2x1 Pow(Float2x1 x, Float2x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float2x2 Pow(Float2x2 x, Float2x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float2x3 Pow(Float2x3 x, Float2x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float2x4 Pow(Float2x4 x, Float2x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float3x1 Pow(Float3x1 x, Float3x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float3x2 Pow(Float3x2 x, Float3x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float3x3 Pow(Float3x3 x, Float3x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float3x4 Pow(Float3x4 x, Float3x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float4x1 Pow(Float4x1 x, Float4x1 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float4x2 Pow(Float4x2 x, Float4x2 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float4x3 Pow(Float4x3 x, Float4x3 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Returns the specified value raised to the specified power. + /// + /// The specified value. + /// The specified power. + /// The parameter raised to the power of the parameter. + [Pure] + [HlslIntrinsicName("pow")] + public static Float4x4 Pow(Float4x4 x, Float4x4 y) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Pow)}({typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static float Radians(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(float)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float2 Radians(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float2)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float3 Radians(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float3)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float4 Radians(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float4)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float1x1 Radians(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float1x1)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float1x2 Radians(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float1x2)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float1x3 Radians(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float1x3)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float1x4 Radians(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float1x4)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float2x1 Radians(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float2x1)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float2x2 Radians(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float2x2)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float2x3 Radians(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float2x3)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float2x4 Radians(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float2x4)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float3x1 Radians(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float3x1)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float3x2 Radians(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float3x2)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float3x3 Radians(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float3x3)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float3x4 Radians(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float3x4)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float4x1 Radians(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float4x1)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float4x2 Radians(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float4x2)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float4x3 Radians(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float4x3)})"); + + /// + /// Converts the specified value from degrees to radians. + /// + /// The specified value. + /// The parameter converted from degrees to radians. + [Pure] + [HlslIntrinsicName("radians")] + public static Float4x4 Radians(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Radians)}({typeof(Float4x4)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static float Rcp(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(float)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float2 Rcp(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float2)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float3 Rcp(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float3)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float4 Rcp(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float4)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float1x1 Rcp(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float1x1)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float1x2 Rcp(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float1x2)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float1x3 Rcp(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float1x3)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float1x4 Rcp(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float1x4)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float2x1 Rcp(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float2x1)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float2x2 Rcp(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float2x2)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float2x3 Rcp(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float2x3)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float2x4 Rcp(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float2x4)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float3x1 Rcp(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float3x1)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float3x2 Rcp(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float3x2)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float3x3 Rcp(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float3x3)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float3x4 Rcp(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float3x4)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float4x1 Rcp(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float4x1)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float4x2 Rcp(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float4x2)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float4x3 Rcp(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float4x3)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Float4x4 Rcp(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Float4x4)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static double Rcp(double x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(double)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double2 Rcp(Double2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double2)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double3 Rcp(Double3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double3)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double4 Rcp(Double4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double4)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double1x1 Rcp(Double1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double1x1)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double1x2 Rcp(Double1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double1x2)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double1x3 Rcp(Double1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double1x3)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double1x4 Rcp(Double1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double1x4)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double2x1 Rcp(Double2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double2x1)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double2x2 Rcp(Double2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double2x2)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double2x3 Rcp(Double2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double2x3)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double2x4 Rcp(Double2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double2x4)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double3x1 Rcp(Double3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double3x1)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double3x2 Rcp(Double3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double3x2)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double3x3 Rcp(Double3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double3x3)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double3x4 Rcp(Double3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double3x4)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double4x1 Rcp(Double4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double4x1)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double4x2 Rcp(Double4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double4x2)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double4x3 Rcp(Double4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double4x3)})"); + + /// + /// Calculates a fast, approximate, per-component reciprocal. + /// + /// The input value. + /// The reciprocal of the parameter. + [Pure] + [HlslIntrinsicName("rcp")] + public static Double4x4 Rcp(Double4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rcp)}({typeof(Double4x4)})"); + + /// + /// Reverses the order of the bits, per component. + /// + /// The input value. + /// The input value, with the bit order reversed. + [Pure] + [HlslIntrinsicName("reversebits")] + public static uint ReverseBits(uint x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(ReverseBits)}({typeof(uint)})"); + + /// + /// Reverses the order of the bits, per component. + /// + /// The input value. + /// The input value, with the bit order reversed. + [Pure] + [HlslIntrinsicName("reversebits")] + public static UInt2 ReverseBits(UInt2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(ReverseBits)}({typeof(UInt2)})"); + + /// + /// Reverses the order of the bits, per component. + /// + /// The input value. + /// The input value, with the bit order reversed. + [Pure] + [HlslIntrinsicName("reversebits")] + public static UInt3 ReverseBits(UInt3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(ReverseBits)}({typeof(UInt3)})"); + + /// + /// Reverses the order of the bits, per component. + /// + /// The input value. + /// The input value, with the bit order reversed. + [Pure] + [HlslIntrinsicName("reversebits")] + public static UInt4 ReverseBits(UInt4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(ReverseBits)}({typeof(UInt4)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static float Round(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(float)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float2 Round(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float2)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float3 Round(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float3)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float4 Round(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float4)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float1x1 Round(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float1x1)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float1x2 Round(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float1x2)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float1x3 Round(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float1x3)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float1x4 Round(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float1x4)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float2x1 Round(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float2x1)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float2x2 Round(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float2x2)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float2x3 Round(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float2x3)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float2x4 Round(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float2x4)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float3x1 Round(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float3x1)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float3x2 Round(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float3x2)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float3x3 Round(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float3x3)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float3x4 Round(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float3x4)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float4x1 Round(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float4x1)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float4x2 Round(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float4x2)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float4x3 Round(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float4x3)})"); + + /// + /// Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even. + /// + /// The specified value. + /// The parameter, rounded to the nearest integer within a floating-point type. + [Pure] + [HlslIntrinsicName("round")] + public static Float4x4 Round(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Round)}({typeof(Float4x4)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static float Rsqrt(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(float)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float2 Rsqrt(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float2)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float3 Rsqrt(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float3)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float4 Rsqrt(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float4)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float1x1 Rsqrt(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float1x1)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float1x2 Rsqrt(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float1x2)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float1x3 Rsqrt(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float1x3)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float1x4 Rsqrt(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float1x4)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float2x1 Rsqrt(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float2x1)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float2x2 Rsqrt(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float2x2)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float2x3 Rsqrt(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float2x3)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float2x4 Rsqrt(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float2x4)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float3x1 Rsqrt(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float3x1)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float3x2 Rsqrt(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float3x2)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float3x3 Rsqrt(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float3x3)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float3x4 Rsqrt(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float3x4)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float4x1 Rsqrt(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float4x1)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float4x2 Rsqrt(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float4x2)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float4x3 Rsqrt(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float4x3)})"); + + /// + /// Returns the reciprocal of the square root of the specified value. + /// + /// The specified value. + /// The reciprocal of the square root of the parameter. + [Pure] + [HlslIntrinsicName("rsqrt")] + public static Float4x4 Rsqrt(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Rsqrt)}({typeof(Float4x4)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static float Saturate(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(float)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float2 Saturate(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float2)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float3 Saturate(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float3)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float4 Saturate(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float4)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float1x1 Saturate(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float1x1)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float1x2 Saturate(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float1x2)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float1x3 Saturate(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float1x3)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float1x4 Saturate(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float1x4)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float2x1 Saturate(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float2x1)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float2x2 Saturate(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float2x2)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float2x3 Saturate(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float2x3)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float2x4 Saturate(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float2x4)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float3x1 Saturate(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float3x1)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float3x2 Saturate(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float3x2)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float3x3 Saturate(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float3x3)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float3x4 Saturate(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float3x4)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float4x1 Saturate(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float4x1)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float4x2 Saturate(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float4x2)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float4x3 Saturate(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float4x3)})"); + + /// + /// Clamps the specified value within the range of 0 to 1. + /// + /// The specified value. + /// The parameter, clamped within the range of 0 to 1. + [Pure] + [HlslIntrinsicName("saturate")] + public static Float4x4 Saturate(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Saturate)}({typeof(Float4x4)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static int Sign(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(float)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int2 Sign(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float2)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int3 Sign(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float3)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int4 Sign(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float4)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int1x1 Sign(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float1x1)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int1x2 Sign(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float1x2)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int1x3 Sign(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float1x3)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int1x4 Sign(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float1x4)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int2x1 Sign(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float2x1)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int2x2 Sign(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float2x2)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int2x3 Sign(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float2x3)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int2x4 Sign(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float2x4)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int3x1 Sign(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float3x1)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int3x2 Sign(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float3x2)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int3x3 Sign(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float3x3)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int3x4 Sign(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float3x4)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int4x1 Sign(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float4x1)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int4x2 Sign(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float4x2)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int4x3 Sign(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float4x3)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int4x4 Sign(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Float4x4)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static int Sign(int x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(int)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int2 Sign(Int2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int2)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int3 Sign(Int3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int3)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int4 Sign(Int4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int4)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int1x1 Sign(Int1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int1x1)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int1x2 Sign(Int1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int1x2)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int1x3 Sign(Int1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int1x3)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int1x4 Sign(Int1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int1x4)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int2x1 Sign(Int2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int2x1)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int2x2 Sign(Int2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int2x2)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int2x3 Sign(Int2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int2x3)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int2x4 Sign(Int2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int2x4)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int3x1 Sign(Int3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int3x1)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int3x2 Sign(Int3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int3x2)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int3x3 Sign(Int3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int3x3)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int3x4 Sign(Int3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int3x4)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int4x1 Sign(Int4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int4x1)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int4x2 Sign(Int4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int4x2)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int4x3 Sign(Int4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int4x3)})"); + + /// + /// Returns the sign of the input value. + /// + /// The specified value. + /// Returns -1 if is less than zero; 0 if equals zero; and 1 if is greater than zero. + [Pure] + [HlslIntrinsicName("sign")] + public static Int4x4 Sign(Int4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sign)}({typeof(Int4x4)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static float Sin(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(float)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float2 Sin(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float2)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float3 Sin(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float3)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float4 Sin(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float4)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float1x1 Sin(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float1x1)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float1x2 Sin(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float1x2)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float1x3 Sin(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float1x3)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float1x4 Sin(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float1x4)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float2x1 Sin(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float2x1)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float2x2 Sin(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float2x2)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float2x3 Sin(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float2x3)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float2x4 Sin(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float2x4)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float3x1 Sin(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float3x1)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float3x2 Sin(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float3x2)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float3x3 Sin(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float3x3)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float3x4 Sin(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float3x4)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float4x1 Sin(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float4x1)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float4x2 Sin(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float4x2)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float4x3 Sin(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float4x3)})"); + + /// + /// Returns the sine of the specified value. + /// + /// The specified value, in radians. + /// The sine of the parameter. + [Pure] + [HlslIntrinsicName("sin")] + public static Float4x4 Sin(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sin)}({typeof(Float4x4)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(float x, out float sin, out float cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(float)}, {typeof(float)}, {typeof(float)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float2 x, out Float2 sin, out Float2 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float2)}, {typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float3 x, out Float3 sin, out Float3 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float3)}, {typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float4 x, out Float4 sin, out Float4 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float4)}, {typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float1x1 x, out Float1x1 sin, out Float1x1 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float1x1)}, {typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float1x2 x, out Float1x2 sin, out Float1x2 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float1x2)}, {typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float1x3 x, out Float1x3 sin, out Float1x3 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float1x3)}, {typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float1x4 x, out Float1x4 sin, out Float1x4 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float1x4)}, {typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float2x1 x, out Float2x1 sin, out Float2x1 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float2x1)}, {typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float2x2 x, out Float2x2 sin, out Float2x2 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float2x2)}, {typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float2x3 x, out Float2x3 sin, out Float2x3 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float2x3)}, {typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float2x4 x, out Float2x4 sin, out Float2x4 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float2x4)}, {typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float3x1 x, out Float3x1 sin, out Float3x1 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float3x1)}, {typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float3x2 x, out Float3x2 sin, out Float3x2 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float3x2)}, {typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float3x3 x, out Float3x3 sin, out Float3x3 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float3x3)}, {typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float3x4 x, out Float3x4 sin, out Float3x4 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float3x4)}, {typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float4x1 x, out Float4x1 sin, out Float4x1 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float4x1)}, {typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float4x2 x, out Float4x2 sin, out Float4x2 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float4x2)}, {typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float4x3 x, out Float4x3 sin, out Float4x3 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float4x3)}, {typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Returns the sine and cosine of a specified value. + /// + /// The specified value, in radians. + /// The resulting sine. + /// The resulting cosine. + [Pure] + [HlslIntrinsicName("sincos")] + public static void SinCos(Float4x4 x, out Float4x4 sin, out Float4x4 cos) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SinCos)}({typeof(Float4x4)}, {typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static float Sinh(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(float)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float2 Sinh(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float2)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float3 Sinh(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float3)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float4 Sinh(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float4)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float1x1 Sinh(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float1x1)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float1x2 Sinh(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float1x2)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float1x3 Sinh(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float1x3)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float1x4 Sinh(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float1x4)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float2x1 Sinh(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float2x1)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float2x2 Sinh(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float2x2)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float2x3 Sinh(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float2x3)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float2x4 Sinh(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float2x4)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float3x1 Sinh(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float3x1)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float3x2 Sinh(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float3x2)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float3x3 Sinh(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float3x3)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float3x4 Sinh(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float3x4)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float4x1 Sinh(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float4x1)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float4x2 Sinh(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float4x2)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float4x3 Sinh(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float4x3)})"); + + /// + /// Returns the hyperbolic sine of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic sine of the parameter. + [Pure] + [HlslIntrinsicName("sinh")] + public static Float4x4 Sinh(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sinh)}({typeof(Float4x4)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static float SmoothStep(float min, float max, float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(float)}, {typeof(float)}, {typeof(float)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float2 SmoothStep(Float2 min, Float2 max, Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float2)}, {typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float3 SmoothStep(Float3 min, Float3 max, Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float3)}, {typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float4 SmoothStep(Float4 min, Float4 max, Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float4)}, {typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float1x1 SmoothStep(Float1x1 min, Float1x1 max, Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float1x1)}, {typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float1x2 SmoothStep(Float1x2 min, Float1x2 max, Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float1x2)}, {typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float1x3 SmoothStep(Float1x3 min, Float1x3 max, Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float1x3)}, {typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float1x4 SmoothStep(Float1x4 min, Float1x4 max, Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float1x4)}, {typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float2x1 SmoothStep(Float2x1 min, Float2x1 max, Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float2x1)}, {typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float2x2 SmoothStep(Float2x2 min, Float2x2 max, Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float2x2)}, {typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float2x3 SmoothStep(Float2x3 min, Float2x3 max, Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float2x3)}, {typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float2x4 SmoothStep(Float2x4 min, Float2x4 max, Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float2x4)}, {typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float3x1 SmoothStep(Float3x1 min, Float3x1 max, Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float3x1)}, {typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float3x2 SmoothStep(Float3x2 min, Float3x2 max, Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float3x2)}, {typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float3x3 SmoothStep(Float3x3 min, Float3x3 max, Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float3x3)}, {typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float3x4 SmoothStep(Float3x4 min, Float3x4 max, Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float3x4)}, {typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float4x1 SmoothStep(Float4x1 min, Float4x1 max, Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float4x1)}, {typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float4x2 SmoothStep(Float4x2 min, Float4x2 max, Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float4x2)}, {typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float4x3 SmoothStep(Float4x3 min, Float4x3 max, Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float4x3)}, {typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range. + /// + /// The specified minimum range. + /// The specified maximum range. + /// The specified value to be interpolated. + /// Returns 0 if is less than ; 1 if is greater than ; otherwise, a value between 0 and 1 if is in the range [, ]. + [Pure] + [HlslIntrinsicName("smoothstep")] + public static Float4x4 SmoothStep(Float4x4 min, Float4x4 max, Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(SmoothStep)}({typeof(Float4x4)}, {typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static float Sqrt(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(float)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float2 Sqrt(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float2)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float3 Sqrt(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float3)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float4 Sqrt(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float4)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float1x1 Sqrt(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float1x1)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float1x2 Sqrt(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float1x2)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float1x3 Sqrt(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float1x3)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float1x4 Sqrt(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float1x4)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float2x1 Sqrt(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float2x1)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float2x2 Sqrt(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float2x2)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float2x3 Sqrt(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float2x3)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float2x4 Sqrt(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float2x4)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float3x1 Sqrt(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float3x1)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float3x2 Sqrt(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float3x2)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float3x3 Sqrt(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float3x3)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float3x4 Sqrt(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float3x4)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float4x1 Sqrt(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float4x1)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float4x2 Sqrt(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float4x2)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float4x3 Sqrt(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float4x3)})"); + + /// + /// Returns the square root of the specified floating-point value, per component. + /// + /// The specified floating-point value. + /// The square root of the parameter, per component. + [Pure] + [HlslIntrinsicName("sqrt")] + public static Float4x4 Sqrt(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Sqrt)}({typeof(Float4x4)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static float Step(float y, float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(float)}, {typeof(float)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float2 Step(Float2 y, Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float2)}, {typeof(Float2)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float3 Step(Float3 y, Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float3)}, {typeof(Float3)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float4 Step(Float4 y, Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float4)}, {typeof(Float4)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float1x1 Step(Float1x1 y, Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float1x1)}, {typeof(Float1x1)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float1x2 Step(Float1x2 y, Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float1x2)}, {typeof(Float1x2)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float1x3 Step(Float1x3 y, Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float1x3)}, {typeof(Float1x3)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float1x4 Step(Float1x4 y, Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float1x4)}, {typeof(Float1x4)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float2x1 Step(Float2x1 y, Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float2x1)}, {typeof(Float2x1)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float2x2 Step(Float2x2 y, Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float2x2)}, {typeof(Float2x2)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float2x3 Step(Float2x3 y, Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float2x3)}, {typeof(Float2x3)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float2x4 Step(Float2x4 y, Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float2x4)}, {typeof(Float2x4)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float3x1 Step(Float3x1 y, Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float3x1)}, {typeof(Float3x1)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float3x2 Step(Float3x2 y, Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float3x2)}, {typeof(Float3x2)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float3x3 Step(Float3x3 y, Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float3x3)}, {typeof(Float3x3)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float3x4 Step(Float3x4 y, Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float3x4)}, {typeof(Float3x4)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float4x1 Step(Float4x1 y, Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float4x1)}, {typeof(Float4x1)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float4x2 Step(Float4x2 y, Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float4x2)}, {typeof(Float4x2)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float4x3 Step(Float4x3 y, Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float4x3)}, {typeof(Float4x3)})"); + + /// + /// Compares two values, returning 0 or 1 based on which value is greater. + /// + /// The first specified floating-point value. + /// The second specified floating-point value. + /// 1 if the parameter is greater than or equal to the parameter; otherwise, 0. + [Pure] + [HlslIntrinsicName("step")] + public static Float4x4 Step(Float4x4 y, Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Step)}({typeof(Float4x4)}, {typeof(Float4x4)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static float Tan(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(float)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float2 Tan(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float2)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float3 Tan(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float3)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float4 Tan(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float4)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float1x1 Tan(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float1x1)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float1x2 Tan(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float1x2)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float1x3 Tan(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float1x3)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float1x4 Tan(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float1x4)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float2x1 Tan(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float2x1)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float2x2 Tan(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float2x2)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float2x3 Tan(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float2x3)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float2x4 Tan(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float2x4)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float3x1 Tan(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float3x1)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float3x2 Tan(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float3x2)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float3x3 Tan(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float3x3)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float3x4 Tan(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float3x4)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float4x1 Tan(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float4x1)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float4x2 Tan(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float4x2)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float4x3 Tan(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float4x3)})"); + + /// + /// Returns the tangent of the specified value. + /// + /// The specified value, in radians. + /// The tangent of the parameter. + [Pure] + [HlslIntrinsicName("tan")] + public static Float4x4 Tan(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tan)}({typeof(Float4x4)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static float Tanh(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(float)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float2 Tanh(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float2)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float3 Tanh(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float3)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float4 Tanh(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float4)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float1x1 Tanh(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float1x1)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float1x2 Tanh(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float1x2)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float1x3 Tanh(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float1x3)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float1x4 Tanh(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float1x4)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float2x1 Tanh(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float2x1)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float2x2 Tanh(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float2x2)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float2x3 Tanh(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float2x3)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float2x4 Tanh(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float2x4)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float3x1 Tanh(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float3x1)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float3x2 Tanh(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float3x2)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float3x3 Tanh(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float3x3)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float3x4 Tanh(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float3x4)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float4x1 Tanh(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float4x1)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float4x2 Tanh(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float4x2)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float4x3 Tanh(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float4x3)})"); + + /// + /// Returns the hyperbolic tangent of the specified value. + /// + /// The specified value, in radians. + /// The hyperbolic tangent of the parameter. + [Pure] + [HlslIntrinsicName("tanh")] + public static Float4x4 Tanh(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Tanh)}({typeof(Float4x4)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float2x1 Transpose(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float1x2)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float3x1 Transpose(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float1x3)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float4x1 Transpose(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float1x4)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float1x2 Transpose(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float2x1)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float3x2 Transpose(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float2x3)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float4x2 Transpose(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float2x4)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float1x3 Transpose(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float3x1)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float2x3 Transpose(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float3x2)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float4x3 Transpose(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float3x4)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float1x4 Transpose(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float4x1)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float2x4 Transpose(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float4x2)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Float3x4 Transpose(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Float4x3)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int2x1 Transpose(Int1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int1x2)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int3x1 Transpose(Int1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int1x3)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int4x1 Transpose(Int1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int1x4)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int1x2 Transpose(Int2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int2x1)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int3x2 Transpose(Int2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int2x3)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int4x2 Transpose(Int2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int2x4)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int1x3 Transpose(Int3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int3x1)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int2x3 Transpose(Int3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int3x2)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int4x3 Transpose(Int3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int3x4)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int1x4 Transpose(Int4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int4x1)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int2x4 Transpose(Int4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int4x2)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Int3x4 Transpose(Int4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Int4x3)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool2x1 Transpose(Bool1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool1x2)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool3x1 Transpose(Bool1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool1x3)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool4x1 Transpose(Bool1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool1x4)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool1x2 Transpose(Bool2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool2x1)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool3x2 Transpose(Bool2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool2x3)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool4x2 Transpose(Bool2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool2x4)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool1x3 Transpose(Bool3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool3x1)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool2x3 Transpose(Bool3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool3x2)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool4x3 Transpose(Bool3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool3x4)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool1x4 Transpose(Bool4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool4x1)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool2x4 Transpose(Bool4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool4x2)})"); + + /// + /// Transposes the specified input matrix. + /// + /// The specified matrix. + /// The transposed value of the parameter. + [Pure] + [HlslIntrinsicName("transpose")] + public static Bool3x4 Transpose(Bool4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Transpose)}({typeof(Bool4x3)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static float Trunc(float x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(float)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float2 Trunc(Float2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float2)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float3 Trunc(Float3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float3)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float4 Trunc(Float4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float4)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float1x1 Trunc(Float1x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float1x1)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float1x2 Trunc(Float1x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float1x2)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float1x3 Trunc(Float1x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float1x3)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float1x4 Trunc(Float1x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float1x4)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float2x1 Trunc(Float2x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float2x1)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float2x2 Trunc(Float2x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float2x2)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float2x3 Trunc(Float2x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float2x3)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float2x4 Trunc(Float2x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float2x4)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float3x1 Trunc(Float3x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float3x1)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float3x2 Trunc(Float3x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float3x2)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float3x3 Trunc(Float3x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float3x3)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float3x4 Trunc(Float3x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float3x4)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float4x1 Trunc(Float4x1 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float4x1)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float4x2 Trunc(Float4x2 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float4x2)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float4x3 Trunc(Float4x3 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float4x3)})"); + + /// + /// Truncates a floating-point value to the integer component. + /// + /// The specified input. + /// The input value truncated to an integer component. + [Pure] + [HlslIntrinsicName("trunc")] + public static Float4x4 Trunc(Float4x4 x) => throw new InvalidExecutionContextException($"{typeof(Hlsl)}.{nameof(Trunc)}({typeof(Float4x4)})"); + } +} diff --git a/src/ComputeSharp/Core/Intrinsics/Hlsl.tt b/src/ComputeSharp/Core/Intrinsics/Hlsl.tt new file mode 100644 index 00000000..f8d4292f --- /dev/null +++ b/src/ComputeSharp/Core/Intrinsics/Hlsl.tt @@ -0,0 +1,57 @@ +<#@include file="Hlsl.ttinclude" #> +using System.Diagnostics.Contracts; +using ComputeSharp.Core.Intrinsics.Attributes; +using ComputeSharp.Exceptions; + +namespace ComputeSharp +{ + /// + public static partial class Hlsl + { +<# +PushIndent(" "); +PushIndent(" "); + +bool isFirst = true; + +foreach (var intrinsic in Intrinsics) +{ + foreach (var overload in intrinsic.Overloads) + { + if (isFirst) isFirst = false; + else WriteLine(""); + + WriteLine("/// "); + WriteLine($"/// {intrinsic.Summary}"); + WriteLine("/// "); + + foreach (var param in intrinsic.Parameters) + { + WriteLine($"/// {param.Info}"); + } + + if (intrinsic.Returns.Length > 0) + { + var returns = Regex.Replace(intrinsic.Returns, @"{(\w+)}", m => $""); + + WriteLine($"/// {returns}"); + } + + if (intrinsic.IsPure) WriteLine("[Pure]"); + WriteLine($"[HlslIntrinsicName(\"{intrinsic.HlslName}\")]"); + + Write($"public static {overload.Return} {intrinsic.Name}("); + Write(string.Join(", ", intrinsic.Parameters.Zip(overload.Params, (a, b) => $"{(a.IsOut ? "out " : "")}{b} {a.Name}"))); + Write(") => throw new InvalidExecutionContextException("); + + var parameters = string.Join(", ", overload.Params.Select(t => $"{{typeof({t})}}")); + + WriteLine($"$\"{{typeof(Hlsl)}}.{{nameof({intrinsic.Name})}}({parameters})\");"); + } +} + +PopIndent(); +PopIndent(); +#> + } +} diff --git a/src/ComputeSharp/Core/Intrinsics/Hlsl.ttinclude b/src/ComputeSharp/Core/Intrinsics/Hlsl.ttinclude new file mode 100644 index 00000000..18195278 --- /dev/null +++ b/src/ComputeSharp/Core/Intrinsics/Hlsl.ttinclude @@ -0,0 +1,2603 @@ +<#@ template debug="false" hostspecific="false" language="C#" #> +<#@ assembly name="System.Core" #> +<#@ import namespace="System.Linq" #> +<#@ import namespace="System.Text" #> +<#@ import namespace="System.Text.RegularExpressions" #> +<#@ import namespace="System.Collections.Generic" #> +<#@ output extension=".g.cs"#> +<# +var Intrinsics = new[] +{ + new + { + Name = "Abs", + HlslName = "abs", + Summary = "Returns the absolute value of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The absolute value of the {x} parameter.", + Overloads = new[] + { + new { Return = "int", Params = new[] { "int" } }, + new { Return = "Int2", Params = new[] { "Int2" } }, + new { Return = "Int3", Params = new[] { "Int3" } }, + new { Return = "Int4", Params = new[] { "Int4" } }, + new { Return = "Int1x1", Params = new[] { "Int1x1" } }, + new { Return = "Int1x2", Params = new[] { "Int1x2" } }, + new { Return = "Int1x3", Params = new[] { "Int1x3" } }, + new { Return = "Int1x4", Params = new[] { "Int1x4" } }, + new { Return = "Int2x1", Params = new[] { "Int2x1" } }, + new { Return = "Int2x2", Params = new[] { "Int2x2" } }, + new { Return = "Int2x3", Params = new[] { "Int2x3" } }, + new { Return = "Int2x4", Params = new[] { "Int2x4" } }, + new { Return = "Int3x1", Params = new[] { "Int3x1" } }, + new { Return = "Int3x2", Params = new[] { "Int3x2" } }, + new { Return = "Int3x3", Params = new[] { "Int3x3" } }, + new { Return = "Int3x4", Params = new[] { "Int3x4" } }, + new { Return = "Int4x1", Params = new[] { "Int4x1" } }, + new { Return = "Int4x2", Params = new[] { "Int4x2" } }, + new { Return = "Int4x3", Params = new[] { "Int4x3" } }, + new { Return = "Int4x4", Params = new[] { "Int4x4" } }, + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Acos", + HlslName = "acos", + Summary = "Returns the arccosine of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value. Each component should be a floating-point within the range [-1, 1]." } + }, + Returns = "The arccosine of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "All", + HlslName = "all", + Summary = "Determines if all components of the specified value are non-zero.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "Whether or not all components of the {x} parameter are non-zero.", + Overloads = new[] + { + new { Return = "bool", Params = new[] { "int" } }, + new { Return = "bool", Params = new[] { "Int2" } }, + new { Return = "bool", Params = new[] { "Int3" } }, + new { Return = "bool", Params = new[] { "Int4" } }, + new { Return = "bool", Params = new[] { "Int1x1" } }, + new { Return = "bool", Params = new[] { "Int1x2" } }, + new { Return = "bool", Params = new[] { "Int1x3" } }, + new { Return = "bool", Params = new[] { "Int1x4" } }, + new { Return = "bool", Params = new[] { "Int2x1" } }, + new { Return = "bool", Params = new[] { "Int2x2" } }, + new { Return = "bool", Params = new[] { "Int2x3" } }, + new { Return = "bool", Params = new[] { "Int2x4" } }, + new { Return = "bool", Params = new[] { "Int3x1" } }, + new { Return = "bool", Params = new[] { "Int3x2" } }, + new { Return = "bool", Params = new[] { "Int3x3" } }, + new { Return = "bool", Params = new[] { "Int3x4" } }, + new { Return = "bool", Params = new[] { "Int4x1" } }, + new { Return = "bool", Params = new[] { "Int4x2" } }, + new { Return = "bool", Params = new[] { "Int4x3" } }, + new { Return = "bool", Params = new[] { "Int4x4" } }, + new { Return = "bool", Params = new[] { "float" } }, + new { Return = "bool", Params = new[] { "Float2" } }, + new { Return = "bool", Params = new[] { "Float3" } }, + new { Return = "bool", Params = new[] { "Float4" } }, + new { Return = "bool", Params = new[] { "Float1x1" } }, + new { Return = "bool", Params = new[] { "Float1x2" } }, + new { Return = "bool", Params = new[] { "Float1x3" } }, + new { Return = "bool", Params = new[] { "Float1x4" } }, + new { Return = "bool", Params = new[] { "Float2x1" } }, + new { Return = "bool", Params = new[] { "Float2x2" } }, + new { Return = "bool", Params = new[] { "Float2x3" } }, + new { Return = "bool", Params = new[] { "Float2x4" } }, + new { Return = "bool", Params = new[] { "Float3x1" } }, + new { Return = "bool", Params = new[] { "Float3x2" } }, + new { Return = "bool", Params = new[] { "Float3x3" } }, + new { Return = "bool", Params = new[] { "Float3x4" } }, + new { Return = "bool", Params = new[] { "Float4x1" } }, + new { Return = "bool", Params = new[] { "Float4x2" } }, + new { Return = "bool", Params = new[] { "Float4x3" } }, + new { Return = "bool", Params = new[] { "Float4x4" } }, + new { Return = "bool", Params = new[] { "bool" } }, + new { Return = "bool", Params = new[] { "Bool2" } }, + new { Return = "bool", Params = new[] { "Bool3" } }, + new { Return = "bool", Params = new[] { "Bool4" } }, + new { Return = "bool", Params = new[] { "Bool1x1" } }, + new { Return = "bool", Params = new[] { "Bool1x2" } }, + new { Return = "bool", Params = new[] { "Bool1x3" } }, + new { Return = "bool", Params = new[] { "Bool1x4" } }, + new { Return = "bool", Params = new[] { "Bool2x1" } }, + new { Return = "bool", Params = new[] { "Bool2x2" } }, + new { Return = "bool", Params = new[] { "Bool2x3" } }, + new { Return = "bool", Params = new[] { "Bool2x4" } }, + new { Return = "bool", Params = new[] { "Bool3x1" } }, + new { Return = "bool", Params = new[] { "Bool3x2" } }, + new { Return = "bool", Params = new[] { "Bool3x3" } }, + new { Return = "bool", Params = new[] { "Bool3x4" } }, + new { Return = "bool", Params = new[] { "Bool4x1" } }, + new { Return = "bool", Params = new[] { "Bool4x2" } }, + new { Return = "bool", Params = new[] { "Bool4x3" } }, + new { Return = "bool", Params = new[] { "Bool4x4" } } + }, + IsPure = true + }, + new + { + Name = "Any", + HlslName = "any", + Summary = "Determines if any components of the specified value are non-zero.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "Whether or not any components of the {x} parameter are non-zero.", + Overloads = new[] + { + new { Return = "bool", Params = new[] { "int" } }, + new { Return = "bool", Params = new[] { "Int2" } }, + new { Return = "bool", Params = new[] { "Int3" } }, + new { Return = "bool", Params = new[] { "Int4" } }, + new { Return = "bool", Params = new[] { "Int1x1" } }, + new { Return = "bool", Params = new[] { "Int1x2" } }, + new { Return = "bool", Params = new[] { "Int1x3" } }, + new { Return = "bool", Params = new[] { "Int1x4" } }, + new { Return = "bool", Params = new[] { "Int2x1" } }, + new { Return = "bool", Params = new[] { "Int2x2" } }, + new { Return = "bool", Params = new[] { "Int2x3" } }, + new { Return = "bool", Params = new[] { "Int2x4" } }, + new { Return = "bool", Params = new[] { "Int3x1" } }, + new { Return = "bool", Params = new[] { "Int3x2" } }, + new { Return = "bool", Params = new[] { "Int3x3" } }, + new { Return = "bool", Params = new[] { "Int3x4" } }, + new { Return = "bool", Params = new[] { "Int4x1" } }, + new { Return = "bool", Params = new[] { "Int4x2" } }, + new { Return = "bool", Params = new[] { "Int4x3" } }, + new { Return = "bool", Params = new[] { "Int4x4" } }, + new { Return = "bool", Params = new[] { "float" } }, + new { Return = "bool", Params = new[] { "Float2" } }, + new { Return = "bool", Params = new[] { "Float3" } }, + new { Return = "bool", Params = new[] { "Float4" } }, + new { Return = "bool", Params = new[] { "Float1x1" } }, + new { Return = "bool", Params = new[] { "Float1x2" } }, + new { Return = "bool", Params = new[] { "Float1x3" } }, + new { Return = "bool", Params = new[] { "Float1x4" } }, + new { Return = "bool", Params = new[] { "Float2x1" } }, + new { Return = "bool", Params = new[] { "Float2x2" } }, + new { Return = "bool", Params = new[] { "Float2x3" } }, + new { Return = "bool", Params = new[] { "Float2x4" } }, + new { Return = "bool", Params = new[] { "Float3x1" } }, + new { Return = "bool", Params = new[] { "Float3x2" } }, + new { Return = "bool", Params = new[] { "Float3x3" } }, + new { Return = "bool", Params = new[] { "Float3x4" } }, + new { Return = "bool", Params = new[] { "Float4x1" } }, + new { Return = "bool", Params = new[] { "Float4x2" } }, + new { Return = "bool", Params = new[] { "Float4x3" } }, + new { Return = "bool", Params = new[] { "Float4x4" } }, + new { Return = "bool", Params = new[] { "bool" } }, + new { Return = "bool", Params = new[] { "Bool2" } }, + new { Return = "bool", Params = new[] { "Bool3" } }, + new { Return = "bool", Params = new[] { "Bool4" } }, + new { Return = "bool", Params = new[] { "Bool1x1" } }, + new { Return = "bool", Params = new[] { "Bool1x2" } }, + new { Return = "bool", Params = new[] { "Bool1x3" } }, + new { Return = "bool", Params = new[] { "Bool1x4" } }, + new { Return = "bool", Params = new[] { "Bool2x1" } }, + new { Return = "bool", Params = new[] { "Bool2x2" } }, + new { Return = "bool", Params = new[] { "Bool2x3" } }, + new { Return = "bool", Params = new[] { "Bool2x4" } }, + new { Return = "bool", Params = new[] { "Bool3x1" } }, + new { Return = "bool", Params = new[] { "Bool3x2" } }, + new { Return = "bool", Params = new[] { "Bool3x3" } }, + new { Return = "bool", Params = new[] { "Bool3x4" } }, + new { Return = "bool", Params = new[] { "Bool4x1" } }, + new { Return = "bool", Params = new[] { "Bool4x2" } }, + new { Return = "bool", Params = new[] { "Bool4x3" } }, + new { Return = "bool", Params = new[] { "Bool4x4" } } + }, + IsPure = true + }, + new + { + Name = "AsDouble", + HlslName = "asdouble", + Summary = "Reinterprets a cast value (two 32-bit values) into a double precision floating-point value.", + Parameters = new[] + { + new { IsOut = false, Name = "lowbits", Info = "The low 32-bit pattern of the input value." }, + new { IsOut = false, Name = "highbits", Info = "The high 32-bit pattern of the input value." } + }, + Returns = "The input (two 32-bit values) recast as a double precision floating-point number.", + Overloads = new[] + { + new { Return = "double", Params = new[] { "uint", "uint" } }, + new { Return = "Double2", Params = new[] { "UInt2", "UInt2" } } + }, + IsPure = true + }, + new + { + Name = "AsFloat", + HlslName = "asfloat", + Summary = "Interprets the bit pattern of an input value as a floating-point number.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The input value." } + }, + Returns = "The input interpreted as a floating-point number.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "int" } }, + new { Return = "Float2", Params = new[] { "Int2" } }, + new { Return = "Float3", Params = new[] { "Int3" } }, + new { Return = "Float4", Params = new[] { "Int4" } }, + new { Return = "Float1x1", Params = new[] { "Int1x1" } }, + new { Return = "Float1x2", Params = new[] { "Int1x2" } }, + new { Return = "Float1x3", Params = new[] { "Int1x3" } }, + new { Return = "Float1x4", Params = new[] { "Int1x4" } }, + new { Return = "Float2x1", Params = new[] { "Int2x1" } }, + new { Return = "Float2x2", Params = new[] { "Int2x2" } }, + new { Return = "Float2x3", Params = new[] { "Int2x3" } }, + new { Return = "Float2x4", Params = new[] { "Int2x4" } }, + new { Return = "Float3x1", Params = new[] { "Int3x1" } }, + new { Return = "Float3x2", Params = new[] { "Int3x2" } }, + new { Return = "Float3x3", Params = new[] { "Int3x3" } }, + new { Return = "Float3x4", Params = new[] { "Int3x4" } }, + new { Return = "Float4x1", Params = new[] { "Int4x1" } }, + new { Return = "Float4x2", Params = new[] { "Int4x2" } }, + new { Return = "Float4x3", Params = new[] { "Int4x3" } }, + new { Return = "Float4x4", Params = new[] { "Int4x4" } }, + new { Return = "float", Params = new[] { "uint" } }, + new { Return = "Float2", Params = new[] { "UInt2" } }, + new { Return = "Float3", Params = new[] { "UInt3" } }, + new { Return = "Float4", Params = new[] { "UInt4" } }, + new { Return = "Float1x1", Params = new[] { "UInt1x1" } }, + new { Return = "Float1x2", Params = new[] { "UInt1x2" } }, + new { Return = "Float1x3", Params = new[] { "UInt1x3" } }, + new { Return = "Float1x4", Params = new[] { "UInt1x4" } }, + new { Return = "Float2x1", Params = new[] { "UInt2x1" } }, + new { Return = "Float2x2", Params = new[] { "UInt2x2" } }, + new { Return = "Float2x3", Params = new[] { "UInt2x3" } }, + new { Return = "Float2x4", Params = new[] { "UInt2x4" } }, + new { Return = "Float3x1", Params = new[] { "UInt3x1" } }, + new { Return = "Float3x2", Params = new[] { "UInt3x2" } }, + new { Return = "Float3x3", Params = new[] { "UInt3x3" } }, + new { Return = "Float3x4", Params = new[] { "UInt3x4" } }, + new { Return = "Float4x1", Params = new[] { "UInt4x1" } }, + new { Return = "Float4x2", Params = new[] { "UInt4x2" } }, + new { Return = "Float4x3", Params = new[] { "UInt4x3" } }, + new { Return = "Float4x4", Params = new[] { "UInt4x4" } } + }, + IsPure = true + }, + new + { + Name = "Asin", + HlslName = "asin", + Summary = "Returns the arcsine of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The arcsine of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "AsInt", + HlslName = "asint", + Summary = "Interprets the bit pattern of an input value as an integer number.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The input value." } + }, + Returns = "The input interpreted as an integer number.", + Overloads = new[] + { + new { Return = "int", Params = new[] { "float" } }, + new { Return = "Int2", Params = new[] { "Float2" } }, + new { Return = "Int3", Params = new[] { "Float3" } }, + new { Return = "Int4", Params = new[] { "Float4" } }, + new { Return = "Int1x1", Params = new[] { "Float1x1" } }, + new { Return = "Int1x2", Params = new[] { "Float1x2" } }, + new { Return = "Int1x3", Params = new[] { "Float1x3" } }, + new { Return = "Int1x4", Params = new[] { "Float1x4" } }, + new { Return = "Int2x1", Params = new[] { "Float2x1" } }, + new { Return = "Int2x2", Params = new[] { "Float2x2" } }, + new { Return = "Int2x3", Params = new[] { "Float2x3" } }, + new { Return = "Int2x4", Params = new[] { "Float2x4" } }, + new { Return = "Int3x1", Params = new[] { "Float3x1" } }, + new { Return = "Int3x2", Params = new[] { "Float3x2" } }, + new { Return = "Int3x3", Params = new[] { "Float3x3" } }, + new { Return = "Int3x4", Params = new[] { "Float3x4" } }, + new { Return = "Int4x1", Params = new[] { "Float4x1" } }, + new { Return = "Int4x2", Params = new[] { "Float4x2" } }, + new { Return = "Int4x3", Params = new[] { "Float4x3" } }, + new { Return = "Int4x4", Params = new[] { "Float4x4" } }, + new { Return = "int", Params = new[] { "uint" } }, + new { Return = "Int2", Params = new[] { "UInt2" } }, + new { Return = "Int3", Params = new[] { "UInt3" } }, + new { Return = "Int4", Params = new[] { "UInt4" } }, + new { Return = "Int1x1", Params = new[] { "UInt1x1" } }, + new { Return = "Int1x2", Params = new[] { "UInt1x2" } }, + new { Return = "Int1x3", Params = new[] { "UInt1x3" } }, + new { Return = "Int1x4", Params = new[] { "UInt1x4" } }, + new { Return = "Int2x1", Params = new[] { "UInt2x1" } }, + new { Return = "Int2x2", Params = new[] { "UInt2x2" } }, + new { Return = "Int2x3", Params = new[] { "UInt2x3" } }, + new { Return = "Int2x4", Params = new[] { "UInt2x4" } }, + new { Return = "Int3x1", Params = new[] { "UInt3x1" } }, + new { Return = "Int3x2", Params = new[] { "UInt3x2" } }, + new { Return = "Int3x3", Params = new[] { "UInt3x3" } }, + new { Return = "Int3x4", Params = new[] { "UInt3x4" } }, + new { Return = "Int4x1", Params = new[] { "UInt4x1" } }, + new { Return = "Int4x2", Params = new[] { "UInt4x2" } }, + new { Return = "Int4x3", Params = new[] { "UInt4x3" } }, + new { Return = "Int4x4", Params = new[] { "UInt4x4" } } + }, + IsPure = true + }, + new + { + Name = "AsUInt", + HlslName = "asuint", + Summary = "Interprets the bit pattern of an input value as an unsigned integer number.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The input value." } + }, + Returns = "The input interpreted as an unsigned integer number.", + Overloads = new[] + { + new { Return = "uint", Params = new[] { "float" } }, + new { Return = "UInt2", Params = new[] { "Float2" } }, + new { Return = "UInt3", Params = new[] { "Float3" } }, + new { Return = "UInt4", Params = new[] { "Float4" } }, + new { Return = "UInt1x1", Params = new[] { "Float1x1" } }, + new { Return = "UInt1x2", Params = new[] { "Float1x2" } }, + new { Return = "UInt1x3", Params = new[] { "Float1x3" } }, + new { Return = "UInt1x4", Params = new[] { "Float1x4" } }, + new { Return = "UInt2x1", Params = new[] { "Float2x1" } }, + new { Return = "UInt2x2", Params = new[] { "Float2x2" } }, + new { Return = "UInt2x3", Params = new[] { "Float2x3" } }, + new { Return = "UInt2x4", Params = new[] { "Float2x4" } }, + new { Return = "UInt3x1", Params = new[] { "Float3x1" } }, + new { Return = "UInt3x2", Params = new[] { "Float3x2" } }, + new { Return = "UInt3x3", Params = new[] { "Float3x3" } }, + new { Return = "UInt3x4", Params = new[] { "Float3x4" } }, + new { Return = "UInt4x1", Params = new[] { "Float4x1" } }, + new { Return = "UInt4x2", Params = new[] { "Float4x2" } }, + new { Return = "UInt4x3", Params = new[] { "Float4x3" } }, + new { Return = "UInt4x4", Params = new[] { "Float4x4" } }, + new { Return = "uint", Params = new[] { "int" } }, + new { Return = "UInt2", Params = new[] { "Int2" } }, + new { Return = "UInt3", Params = new[] { "Int3" } }, + new { Return = "UInt4", Params = new[] { "Int4" } }, + new { Return = "UInt1x1", Params = new[] { "Int1x1" } }, + new { Return = "UInt1x2", Params = new[] { "Int1x2" } }, + new { Return = "UInt1x3", Params = new[] { "Int1x3" } }, + new { Return = "UInt1x4", Params = new[] { "Int1x4" } }, + new { Return = "UInt2x1", Params = new[] { "Int2x1" } }, + new { Return = "UInt2x2", Params = new[] { "Int2x2" } }, + new { Return = "UInt2x3", Params = new[] { "Int2x3" } }, + new { Return = "UInt2x4", Params = new[] { "Int2x4" } }, + new { Return = "UInt3x1", Params = new[] { "Int3x1" } }, + new { Return = "UInt3x2", Params = new[] { "Int3x2" } }, + new { Return = "UInt3x3", Params = new[] { "Int3x3" } }, + new { Return = "UInt3x4", Params = new[] { "Int3x4" } }, + new { Return = "UInt4x1", Params = new[] { "Int4x1" } }, + new { Return = "UInt4x2", Params = new[] { "Int4x2" } }, + new { Return = "UInt4x3", Params = new[] { "Int4x3" } }, + new { Return = "UInt4x4", Params = new[] { "Int4x4" } } + }, + IsPure = true + }, + new + { + Name = "Atan", + HlslName = "atan", + Summary = "Returns the arctangent of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The arctangent of the {x} parameter. This value is within the range [-π/2, π/2].", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Atan2", + HlslName = "atan2", + Summary = "Returns the arctangent of two values (y, x).", + Parameters = new[] + { + new { IsOut = false, Name = "y", Info = "The y value." }, + new { IsOut = false, Name = "x", Info = "The x value." } + }, + Returns = "The arctangent of ({y}, {x}).", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Ceil", + HlslName = "ceil", + Summary = "Returns the smallest integer value that is greater than or equal to the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The smallest integer value (returned as a floating-point type) that is greater than or equal to the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Clamp", + HlslName = "clamp", + Summary = "Clamps the specified value to the specified minimum and maximum range.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The value to clamp." }, + new { IsOut = false, Name = "min", Info = "The specified minimum range." }, + new { IsOut = false, Name = "max", Info = "The specified maximum range." } + }, + Returns = "The clamped value for the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4", "Float4x4" } }, + new { Return = "int", Params = new[] { "int", "int", "int" } }, + new { Return = "Int2", Params = new[] { "Int2", "Int2", "Int2" } }, + new { Return = "Int3", Params = new[] { "Int3", "Int3", "Int3" } }, + new { Return = "Int4", Params = new[] { "Int4", "Int4", "Int4" } }, + new { Return = "Int1x1", Params = new[] { "Int1x1", "Int1x1", "Int1x1" } }, + new { Return = "Int1x2", Params = new[] { "Int1x2", "Int1x2", "Int1x2" } }, + new { Return = "Int1x3", Params = new[] { "Int1x3", "Int1x3", "Int1x3" } }, + new { Return = "Int1x4", Params = new[] { "Int1x4", "Int1x4", "Int1x4" } }, + new { Return = "Int2x1", Params = new[] { "Int2x1", "Int2x1", "Int2x1" } }, + new { Return = "Int2x2", Params = new[] { "Int2x2", "Int2x2", "Int2x2" } }, + new { Return = "Int2x3", Params = new[] { "Int2x3", "Int2x3", "Int2x3" } }, + new { Return = "Int2x4", Params = new[] { "Int2x4", "Int2x4", "Int2x4" } }, + new { Return = "Int3x1", Params = new[] { "Int3x1", "Int3x1", "Int3x1" } }, + new { Return = "Int3x2", Params = new[] { "Int3x2", "Int3x2", "Int3x2" } }, + new { Return = "Int3x3", Params = new[] { "Int3x3", "Int3x3", "Int3x3" } }, + new { Return = "Int3x4", Params = new[] { "Int3x4", "Int3x4", "Int3x4" } }, + new { Return = "Int4x1", Params = new[] { "Int4x1", "Int4x1", "Int4x1" } }, + new { Return = "Int4x2", Params = new[] { "Int4x2", "Int4x2", "Int4x2" } }, + new { Return = "Int4x3", Params = new[] { "Int4x3", "Int4x3", "Int4x3" } }, + new { Return = "Int4x4", Params = new[] { "Int4x4", "Int4x4", "Int4x4" } } + }, + IsPure = true + }, + new + { + Name = "Cos", + HlslName = "cos", + Summary = "Returns the cosine of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value, in radians." } + }, + Returns = "The cosine of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Cosh", + HlslName = "cosh", + Summary = "Returns the hyperbolic cosine of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value, in radians." } + }, + Returns = "The hyperbolic cosine of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "CountBits", + HlslName = "countbits", + Summary = "Counts the number of bits (per component) in the input integer.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The input value." } + }, + Returns = "The number of bits.", + Overloads = new[] + { + new { Return = "uint", Params = new[] { "uint" } }, + new { Return = "UInt2", Params = new[] { "UInt2" } }, + new { Return = "UInt3", Params = new[] { "UInt3" } }, + new { Return = "UInt4", Params = new[] { "UInt4" } } + }, + IsPure = true + }, + new + { + Name = "Cross", + HlslName = "cross", + Summary = "Returns the cross product of two floating-point, 3D vectors.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The first floating-point, 3D vector." }, + new { IsOut = false, Name = "y", Info = "The second floating-point, 3D vector." } + }, + Returns = "The number of bits.", + Overloads = new[] + { + new { Return = "Float3", Params = new[] { "Float3", "Float3" } } + }, + IsPure = true + }, + new + { + Name = "Degrees", + HlslName = "degrees", + Summary = "Converts the specified value from radians to degrees.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The result of converting the {x} parameter from radians to degrees.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Determinant", + HlslName = "determinant", + Summary = "Returns the determinant of the specified floating-point, square matrix.", + Parameters = new[] + { + new { IsOut = false, Name = "m", Info = "The specified value." } + }, + Returns = "The floating-point, scalar value that represents the determinant of the {m} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "Float1x1" } }, + new { Return = "float", Params = new[] { "Float2x2" } }, + new { Return = "float", Params = new[] { "Float3x3" } }, + new { Return = "float", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Distance", + HlslName = "distance", + Summary = "Returns a distance scalar between two vectors.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The first floating-point vector to compare." }, + new { IsOut = false, Name = "y", Info = "The second floating-point vector to compare." } + }, + Returns = "A floating-point, scalar value that represents the distance between the {x} parameter and the {y} parameter.", + Overloads = new[] + { + new { Return = "Float2", Params = new[] { "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4" } } + }, + IsPure = true + }, + new + { + Name = "Dot", + HlslName = "dot", + Summary = "Returns the dot product of two vectors.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The first vector." }, + new { IsOut = false, Name = "y", Info = "The second vector." } + }, + Returns = "The dot product of the {x} parameter and the {y} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "Float2", "Float2" } }, + new { Return = "float", Params = new[] { "Float3", "Float3" } }, + new { Return = "float", Params = new[] { "Float4", "Float4" } }, + new { Return = "float", Params = new[] { "Int2", "Int2" } }, + new { Return = "float", Params = new[] { "Int3", "Int3" } }, + new { Return = "float", Params = new[] { "Int4", "Int4" } } + }, + IsPure = true + }, + new + { + Name = "Exp", + HlslName = "exp", + Summary = "Returns the base-e exponential of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The base-e exponential of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Exp2", + HlslName = "exp2", + Summary = "Returns the base-2 exponential of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The base-2 exponential of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "FirstBitHigh", + HlslName = "firstbithigh", + Summary = "Gets the location of the first set bit starting from the highest order bit and working downward, per component.", + Parameters = new[] + { + new { IsOut = false, Name = "value", Info = "The input value." } + }, + Returns = "The location of the first set bit.", + Overloads = new[] + { + new { Return = "int", Params = new[] { "int" } }, + new { Return = "Int2", Params = new[] { "Int2" } }, + new { Return = "Int3", Params = new[] { "Int3" } }, + new { Return = "Int4", Params = new[] { "Int4" } }, + new { Return = "uint", Params = new[] { "uint" } }, + new { Return = "UInt2", Params = new[] { "UInt2" } }, + new { Return = "UInt3", Params = new[] { "UInt3" } }, + new { Return = "UInt4", Params = new[] { "UInt4" } } + }, + IsPure = true + }, + new + { + Name = "FirstBitLow", + HlslName = "firstbitlow", + Summary = "Returns the location of the first set bit starting from the lowest order bit and working upward, per component.", + Parameters = new[] + { + new { IsOut = false, Name = "value", Info = "The input value." } + }, + Returns = "The location of the first set bit.", + Overloads = new[] + { + new { Return = "int", Params = new[] { "int" } }, + new { Return = "Int2", Params = new[] { "Int2" } }, + new { Return = "Int3", Params = new[] { "Int3" } }, + new { Return = "Int4", Params = new[] { "Int4" } }, + new { Return = "uint", Params = new[] { "uint" } }, + new { Return = "UInt2", Params = new[] { "UInt2" } }, + new { Return = "UInt3", Params = new[] { "UInt3" } }, + new { Return = "UInt4", Params = new[] { "UInt4" } } + }, + IsPure = true + }, + new + { + Name = "Floor", + HlslName = "floor", + Summary = "Returns the largest integer that is less than or equal to the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The largest integer value (returned as a floating-point type) that is less than or equal to the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "FusedMultiplyAccumulate", + HlslName = "fma", + Summary = "Returns the double-precision fused multiply-addition of a * b + c.", + Parameters = new[] + { + new { IsOut = false, Name = "a", Info = "The first value in the fused multiply-addition." }, + new { IsOut = false, Name = "b", Info = "The second value in the fused multiply-addition." }, + new { IsOut = false, Name = "c", Info = "The third value in the fused multiply-addition." } + }, + Returns = "The double-precision fused multiply-addition of parameters a * b + c. The returned value must be accurate to 0.5 units of least precision (ULP).", + Overloads = new[] + { + new { Return = "double", Params = new[] { "double", "double", "double" } }, + new { Return = "Double2", Params = new[] { "Double2", "Double2", "Double2" } }, + new { Return = "Double3", Params = new[] { "Double3", "Double3", "Double3" } }, + new { Return = "Double4", Params = new[] { "Double4", "Double4", "Double4" } }, + new { Return = "Double1x1", Params = new[] { "Double1x1", "Double1x1", "Double1x1" } }, + new { Return = "Double1x2", Params = new[] { "Double1x2", "Double1x2", "Double1x2" } }, + new { Return = "Double1x3", Params = new[] { "Double1x3", "Double1x3", "Double1x3" } }, + new { Return = "Double1x4", Params = new[] { "Double1x4", "Double1x4", "Double1x4" } }, + new { Return = "Double2x1", Params = new[] { "Double2x1", "Double2x1", "Double2x1" } }, + new { Return = "Double2x2", Params = new[] { "Double2x2", "Double2x2", "Double2x2" } }, + new { Return = "Double2x3", Params = new[] { "Double2x3", "Double2x3", "Double2x3" } }, + new { Return = "Double2x4", Params = new[] { "Double2x4", "Double2x4", "Double2x4" } }, + new { Return = "Double3x1", Params = new[] { "Double3x1", "Double3x1", "Double3x1" } }, + new { Return = "Double3x2", Params = new[] { "Double3x2", "Double3x2", "Double3x2" } }, + new { Return = "Double3x3", Params = new[] { "Double3x3", "Double3x3", "Double3x3" } }, + new { Return = "Double3x4", Params = new[] { "Double3x4", "Double3x4", "Double3x4" } }, + new { Return = "Double4x1", Params = new[] { "Double4x1", "Double4x1", "Double4x1" } }, + new { Return = "Double4x2", Params = new[] { "Double4x2", "Double4x2", "Double4x2" } }, + new { Return = "Double4x3", Params = new[] { "Double4x3", "Double4x3", "Double4x3" } }, + new { Return = "Double4x4", Params = new[] { "Double4x4", "Double4x4", "Double4x4" } } + }, + IsPure = true + }, + new + { + Name = "Fmod", + HlslName = "fmod", + Summary = "Returns the floating-point remainder of x / y.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The floating-point dividend." }, + new { IsOut = false, Name = "y", Info = "The floating-point divisor." } + }, + Returns = "The floating-point remainder of the x parameter divided by the y parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Frac", + HlslName = "frac", + Summary = "Returns the fractional (or decimal) part of the input which is greater than or equal to 0 and less than 1.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The fractional part of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Frexp", + HlslName = "frexp", + Summary = "Returns the mantissa and exponent of the specified floating-point value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified floating-point value." }, + new { IsOut = true, Name = "exp", Info = "The returned exponent of the input parameter." } + }, + Returns = "The mantissa of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4" } } + }, + IsPure = false + }, + new + { + Name = "IsFinite", + HlslName = "isfinite", + Summary = "Determines if the specified floating-point value is finite.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "Returns a value of the same size as {x}, indicaating whether each component is finite.", + Overloads = new[] + { + new { Return = "bool", Params = new[] { "float" } }, + new { Return = "Bool2", Params = new[] { "Float2" } }, + new { Return = "Bool3", Params = new[] { "Float3" } }, + new { Return = "Bool4", Params = new[] { "Float4" } }, + new { Return = "Bool1x1", Params = new[] { "Float1x1" } }, + new { Return = "Bool1x2", Params = new[] { "Float1x2" } }, + new { Return = "Bool1x3", Params = new[] { "Float1x3" } }, + new { Return = "Bool1x4", Params = new[] { "Float1x4" } }, + new { Return = "Bool2x1", Params = new[] { "Float2x1" } }, + new { Return = "Bool2x2", Params = new[] { "Float2x2" } }, + new { Return = "Bool2x3", Params = new[] { "Float2x3" } }, + new { Return = "Bool2x4", Params = new[] { "Float2x4" } }, + new { Return = "Bool3x1", Params = new[] { "Float3x1" } }, + new { Return = "Bool3x2", Params = new[] { "Float3x2" } }, + new { Return = "Bool3x3", Params = new[] { "Float3x3" } }, + new { Return = "Bool3x4", Params = new[] { "Float3x4" } }, + new { Return = "Bool4x1", Params = new[] { "Float4x1" } }, + new { Return = "Bool4x2", Params = new[] { "Float4x2" } }, + new { Return = "Bool4x3", Params = new[] { "Float4x3" } }, + new { Return = "Bool4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "IsInfinite", + HlslName = "isinf", + Summary = "Determines if the specified value is infinite.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "Returns a value of the same size as {x}, indicaating whether each component is infinite.", + Overloads = new[] + { + new { Return = "bool", Params = new[] { "float" } }, + new { Return = "Bool2", Params = new[] { "Float2" } }, + new { Return = "Bool3", Params = new[] { "Float3" } }, + new { Return = "Bool4", Params = new[] { "Float4" } }, + new { Return = "Bool1x1", Params = new[] { "Float1x1" } }, + new { Return = "Bool1x2", Params = new[] { "Float1x2" } }, + new { Return = "Bool1x3", Params = new[] { "Float1x3" } }, + new { Return = "Bool1x4", Params = new[] { "Float1x4" } }, + new { Return = "Bool2x1", Params = new[] { "Float2x1" } }, + new { Return = "Bool2x2", Params = new[] { "Float2x2" } }, + new { Return = "Bool2x3", Params = new[] { "Float2x3" } }, + new { Return = "Bool2x4", Params = new[] { "Float2x4" } }, + new { Return = "Bool3x1", Params = new[] { "Float3x1" } }, + new { Return = "Bool3x2", Params = new[] { "Float3x2" } }, + new { Return = "Bool3x3", Params = new[] { "Float3x3" } }, + new { Return = "Bool3x4", Params = new[] { "Float3x4" } }, + new { Return = "Bool4x1", Params = new[] { "Float4x1" } }, + new { Return = "Bool4x2", Params = new[] { "Float4x2" } }, + new { Return = "Bool4x3", Params = new[] { "Float4x3" } }, + new { Return = "Bool4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "IsNaN", + HlslName = "isnan", + Summary = "Determines if the specified value is NAN or QNAN.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "Returns a value of the same size as {x}, indicaating whether each component is NAN or QNAN.", + Overloads = new[] + { + new { Return = "bool", Params = new[] { "float" } }, + new { Return = "Bool2", Params = new[] { "Float2" } }, + new { Return = "Bool3", Params = new[] { "Float3" } }, + new { Return = "Bool4", Params = new[] { "Float4" } }, + new { Return = "Bool1x1", Params = new[] { "Float1x1" } }, + new { Return = "Bool1x2", Params = new[] { "Float1x2" } }, + new { Return = "Bool1x3", Params = new[] { "Float1x3" } }, + new { Return = "Bool1x4", Params = new[] { "Float1x4" } }, + new { Return = "Bool2x1", Params = new[] { "Float2x1" } }, + new { Return = "Bool2x2", Params = new[] { "Float2x2" } }, + new { Return = "Bool2x3", Params = new[] { "Float2x3" } }, + new { Return = "Bool2x4", Params = new[] { "Float2x4" } }, + new { Return = "Bool3x1", Params = new[] { "Float3x1" } }, + new { Return = "Bool3x2", Params = new[] { "Float3x2" } }, + new { Return = "Bool3x3", Params = new[] { "Float3x3" } }, + new { Return = "Bool3x4", Params = new[] { "Float3x4" } }, + new { Return = "Bool4x1", Params = new[] { "Float4x1" } }, + new { Return = "Bool4x2", Params = new[] { "Float4x2" } }, + new { Return = "Bool4x3", Params = new[] { "Float4x3" } }, + new { Return = "Bool4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Ldexp", + HlslName = "ldexp", + Summary = "Returns the result of multiplying the specified value by two, raised to the power of the specified exponent.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." }, + new { IsOut = false, Name = "exp", Info = "The specified exponent." } + }, + Returns = "The result of multiplying the {x} parameter by two, raised to the power of the {exp} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Length", + HlslName = "length", + Summary = "Returns the length of the specified floating-point vector.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified floating-point vector." } + }, + Returns = "A floating-point scalar that represents the length of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "Float2" } }, + new { Return = "float", Params = new[] { "Float3" } }, + new { Return = "float", Params = new[] { "Float4" } } + }, + IsPure = true + }, + new + { + Name = "Lerp", + HlslName = "lerp", + Summary = "Performs a linear interpolation.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The first-floating point value." }, + new { IsOut = false, Name = "min", Info = "The second-floating point value." }, + new { IsOut = false, Name = "max", Info = "A value that linearly interpolates between the two inputs." } + }, + Returns = "The result of the linear interpolation.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4", "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Log", + HlslName = "log", + Summary = "Returns the base-e logarithm of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The base-e logarithm of the {x} parameter. If the {x} parameter is negative, this function returns indefinite. If the {x} parameter is 0, this function returns negative infinity.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Log10", + HlslName = "log10", + Summary = "Returns the base-10 logarithm of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The base-10 logarithm of the {x} parameter. If the {x} parameter is negative, this function returns indefinite. If the {x} parameter is 0, this function returns negative infinity.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Log2", + HlslName = "log2", + Summary = "Returns the base-2 logarithm of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The base-2 logarithm of the {x} parameter. If the {x} parameter is negative, this function returns indefinite. If the {x} parameter is 0, this function returns negative infinity.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Max", + HlslName = "max", + Summary = "Selects the greater between two inputs.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The first input value." }, + new { IsOut = false, Name = "y", Info = "The second input value." } + }, + Returns = "The {x} or {y} parameter, whichever is the largest value.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4" } }, + new { Return = "int", Params = new[] { "int", "int" } }, + new { Return = "Int2", Params = new[] { "Int2", "Int2" } }, + new { Return = "Int3", Params = new[] { "Int3", "Int3" } }, + new { Return = "Int4", Params = new[] { "Int4", "Int4" } }, + new { Return = "Int1x1", Params = new[] { "Int1x1", "Int1x1" } }, + new { Return = "Int1x2", Params = new[] { "Int1x2", "Int1x2" } }, + new { Return = "Int1x3", Params = new[] { "Int1x3", "Int1x3" } }, + new { Return = "Int1x4", Params = new[] { "Int1x4", "Int1x4" } }, + new { Return = "Int2x1", Params = new[] { "Int2x1", "Int2x1" } }, + new { Return = "Int2x2", Params = new[] { "Int2x2", "Int2x2" } }, + new { Return = "Int2x3", Params = new[] { "Int2x3", "Int2x3" } }, + new { Return = "Int2x4", Params = new[] { "Int2x4", "Int2x4" } }, + new { Return = "Int3x1", Params = new[] { "Int3x1", "Int3x1" } }, + new { Return = "Int3x2", Params = new[] { "Int3x2", "Int3x2" } }, + new { Return = "Int3x3", Params = new[] { "Int3x3", "Int3x3" } }, + new { Return = "Int3x4", Params = new[] { "Int3x4", "Int3x4" } }, + new { Return = "Int4x1", Params = new[] { "Int4x1", "Int4x1" } }, + new { Return = "Int4x2", Params = new[] { "Int4x2", "Int4x2" } }, + new { Return = "Int4x3", Params = new[] { "Int4x3", "Int4x3" } }, + new { Return = "Int4x4", Params = new[] { "Int4x4", "Int4x4" } } + }, + IsPure = true + }, + new + { + Name = "Min", + HlslName = "min", + Summary = "Selects the lesser between two inputs.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The first input value." }, + new { IsOut = false, Name = "y", Info = "The second input value." } + }, + Returns = "The {x} or {y} parameter, whichever is the smallest value.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4" } }, + new { Return = "int", Params = new[] { "int", "int" } }, + new { Return = "Int2", Params = new[] { "Int2", "Int2" } }, + new { Return = "Int3", Params = new[] { "Int3", "Int3" } }, + new { Return = "Int4", Params = new[] { "Int4", "Int4" } }, + new { Return = "Int1x1", Params = new[] { "Int1x1", "Int1x1" } }, + new { Return = "Int1x2", Params = new[] { "Int1x2", "Int1x2" } }, + new { Return = "Int1x3", Params = new[] { "Int1x3", "Int1x3" } }, + new { Return = "Int1x4", Params = new[] { "Int1x4", "Int1x4" } }, + new { Return = "Int2x1", Params = new[] { "Int2x1", "Int2x1" } }, + new { Return = "Int2x2", Params = new[] { "Int2x2", "Int2x2" } }, + new { Return = "Int2x3", Params = new[] { "Int2x3", "Int2x3" } }, + new { Return = "Int2x4", Params = new[] { "Int2x4", "Int2x4" } }, + new { Return = "Int3x1", Params = new[] { "Int3x1", "Int3x1" } }, + new { Return = "Int3x2", Params = new[] { "Int3x2", "Int3x2" } }, + new { Return = "Int3x3", Params = new[] { "Int3x3", "Int3x3" } }, + new { Return = "Int3x4", Params = new[] { "Int3x4", "Int3x4" } }, + new { Return = "Int4x1", Params = new[] { "Int4x1", "Int4x1" } }, + new { Return = "Int4x2", Params = new[] { "Int4x2", "Int4x2" } }, + new { Return = "Int4x3", Params = new[] { "Int4x3", "Int4x3" } }, + new { Return = "Int4x4", Params = new[] { "Int4x4", "Int4x4" } } + }, + IsPure = true + }, + new + { + Name = "Modf", + HlslName = "modf", + Summary = "Splits a value into fractional and integer parts, each with the same sign as the input value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The input value." }, + new { IsOut = true, Name = "y", Info = "The resulting integer portion." } + }, + Returns = "The signed-fractional portion of {x}.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4" } }, + new { Return = "int", Params = new[] { "int", "int" } }, + new { Return = "Int2", Params = new[] { "Int2", "Int2" } }, + new { Return = "Int3", Params = new[] { "Int3", "Int3" } }, + new { Return = "Int4", Params = new[] { "Int4", "Int4" } }, + new { Return = "Int1x1", Params = new[] { "Int1x1", "Int1x1" } }, + new { Return = "Int1x2", Params = new[] { "Int1x2", "Int1x2" } }, + new { Return = "Int1x3", Params = new[] { "Int1x3", "Int1x3" } }, + new { Return = "Int1x4", Params = new[] { "Int1x4", "Int1x4" } }, + new { Return = "Int2x1", Params = new[] { "Int2x1", "Int2x1" } }, + new { Return = "Int2x2", Params = new[] { "Int2x2", "Int2x2" } }, + new { Return = "Int2x3", Params = new[] { "Int2x3", "Int2x3" } }, + new { Return = "Int2x4", Params = new[] { "Int2x4", "Int2x4" } }, + new { Return = "Int3x1", Params = new[] { "Int3x1", "Int3x1" } }, + new { Return = "Int3x2", Params = new[] { "Int3x2", "Int3x2" } }, + new { Return = "Int3x3", Params = new[] { "Int3x3", "Int3x3" } }, + new { Return = "Int3x4", Params = new[] { "Int3x4", "Int3x4" } }, + new { Return = "Int4x1", Params = new[] { "Int4x1", "Int4x1" } }, + new { Return = "Int4x2", Params = new[] { "Int4x2", "Int4x2" } }, + new { Return = "Int4x3", Params = new[] { "Int4x3", "Int4x3" } }, + new { Return = "Int4x4", Params = new[] { "Int4x4", "Int4x4" } } + }, + IsPure = true + }, + new + { + Name = "Mul", + HlslName = "mul", + Summary = "Multiplies two values using matrix math.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The first input value." }, + new { IsOut = false, Name = "y", Info = "The second input value." } + }, + Returns = "The result of {x} times {y}. The result has the dimension {x}-rows by {y}-columns.", + Overloads = new[] + { + // 1 (scalars) + new { Return = "float", Params = new[] { "float", "float" } }, + new { Return = "int", Params = new[] { "int", "int" } }, + + // 2 (scalar by vector) + new { Return = "Float2", Params = new[] { "float", "Float2" } }, + new { Return = "Float3", Params = new[] { "float", "Float3" } }, + new { Return = "Float4", Params = new[] { "float", "Float4" } }, + new { Return = "Int2", Params = new[] { "int", "Int2" } }, + new { Return = "Int3", Params = new[] { "int", "Int3" } }, + new { Return = "Int4", Params = new[] { "int", "Int4" } }, + + // 3 (scalar by matrix) + new { Return = "Float1x1", Params = new[] { "float", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "float", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "float", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "float", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "float", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "float", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "float", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "float", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "float", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "float", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "float", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "float", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "float", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "float", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "float", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "float", "Float4x4" } }, + new { Return = "Int1x1", Params = new[] { "int", "Int1x1" } }, + new { Return = "Int1x2", Params = new[] { "int", "Int1x2" } }, + new { Return = "Int1x3", Params = new[] { "int", "Int1x3" } }, + new { Return = "Int1x4", Params = new[] { "int", "Int1x4" } }, + new { Return = "Int2x1", Params = new[] { "int", "Int2x1" } }, + new { Return = "Int2x2", Params = new[] { "int", "Int2x2" } }, + new { Return = "Int2x3", Params = new[] { "int", "Int2x3" } }, + new { Return = "Int2x4", Params = new[] { "int", "Int2x4" } }, + new { Return = "Int3x1", Params = new[] { "int", "Int3x1" } }, + new { Return = "Int3x2", Params = new[] { "int", "Int3x2" } }, + new { Return = "Int3x3", Params = new[] { "int", "Int3x3" } }, + new { Return = "Int3x4", Params = new[] { "int", "Int3x4" } }, + new { Return = "Int4x1", Params = new[] { "int", "Int4x1" } }, + new { Return = "Int4x2", Params = new[] { "int", "Int4x2" } }, + new { Return = "Int4x3", Params = new[] { "int", "Int4x3" } }, + new { Return = "Int4x4", Params = new[] { "int", "Int4x4" } }, + + // 4 (vector by scalar) + new { Return = "Float2", Params = new[] { "Float2", "float" } }, + new { Return = "Float3", Params = new[] { "Float3", "float" } }, + new { Return = "Float4", Params = new[] { "Float4", "float" } }, + new { Return = "Int2", Params = new[] { "Int2", "int" } }, + new { Return = "Int3", Params = new[] { "Int3", "int" } }, + new { Return = "Int4", Params = new[] { "Int4", "int" } }, + + // 5 (vector by vector) + new { Return = "float", Params = new[] { "Float2", "Float2" } }, + new { Return = "float", Params = new[] { "Float3", "Float3" } }, + new { Return = "float", Params = new[] { "Float4", "Float4" } }, + new { Return = "int", Params = new[] { "Int2", "Int2" } }, + new { Return = "int", Params = new[] { "Int3", "Int3" } }, + new { Return = "int", Params = new[] { "Int4", "Int4" } }, + + // 6 (vector by matrix) + new { Return = "float", Params = new[] { "Float2", "Float2x1" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2x2" } }, + new { Return = "Float3", Params = new[] { "Float2", "Float2x3" } }, + new { Return = "Float4", Params = new[] { "Float2", "Float2x4" } }, + new { Return = "float", Params = new[] { "Float3", "Float3x1" } }, + new { Return = "Float2", Params = new[] { "Float3", "Float3x2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3x3" } }, + new { Return = "Float4", Params = new[] { "Float3", "Float3x4" } }, + new { Return = "float", Params = new[] { "Float4", "Float4x1" } }, + new { Return = "Float2", Params = new[] { "Float4", "Float4x2" } }, + new { Return = "Float3", Params = new[] { "Float4", "Float4x3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4x4" } }, + new { Return = "int", Params = new[] { "Int2", "Int2x1" } }, + new { Return = "Int2", Params = new[] { "Int2", "Int2x2" } }, + new { Return = "Int3", Params = new[] { "Int2", "Int2x3" } }, + new { Return = "Int4", Params = new[] { "Int2", "Int2x4" } }, + new { Return = "int", Params = new[] { "Int3", "Int3x1" } }, + new { Return = "Int2", Params = new[] { "Int3", "Int3x2" } }, + new { Return = "Int3", Params = new[] { "Int3", "Int3x3" } }, + new { Return = "Int4", Params = new[] { "Int3", "Int3x4" } }, + new { Return = "int", Params = new[] { "Int4", "Int4x1" } }, + new { Return = "Int2", Params = new[] { "Int4", "Int4x2" } }, + new { Return = "Int3", Params = new[] { "Int4", "Int4x3" } }, + new { Return = "Int4", Params = new[] { "Int4", "Int4x4" } }, + + // 7 (matrix by scalar) + new { Return = "Float1x1", Params = new[] { "Float1x1", "float" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "float" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "float" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "float" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "float" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "float" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "float" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "float" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "float" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "float" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "float" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "float" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "float" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "float" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "float" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "float" } }, + new { Return = "Int1x1", Params = new[] { "Int1x1", "int" } }, + new { Return = "Int1x2", Params = new[] { "Int1x2", "int" } }, + new { Return = "Int1x3", Params = new[] { "Int1x3", "int" } }, + new { Return = "Int1x4", Params = new[] { "Int1x4", "int" } }, + new { Return = "Int2x1", Params = new[] { "Int2x1", "int" } }, + new { Return = "Int2x2", Params = new[] { "Int2x2", "int" } }, + new { Return = "Int2x3", Params = new[] { "Int2x3", "int" } }, + new { Return = "Int2x4", Params = new[] { "Int2x4", "int" } }, + new { Return = "Int3x1", Params = new[] { "Int3x1", "int" } }, + new { Return = "Int3x2", Params = new[] { "Int3x2", "int" } }, + new { Return = "Int3x3", Params = new[] { "Int3x3", "int" } }, + new { Return = "Int3x4", Params = new[] { "Int3x4", "int" } }, + new { Return = "Int4x1", Params = new[] { "Int4x1", "int" } }, + new { Return = "Int4x2", Params = new[] { "Int4x2", "int" } }, + new { Return = "Int4x3", Params = new[] { "Int4x3", "int" } }, + new { Return = "Int4x4", Params = new[] { "Int4x4", "int" } }, + + // 8 (matrix by vector) + new { Return = "float", Params = new[] { "Float1x2", "Float2" } }, + new { Return = "float", Params = new[] { "Float1x3", "Float3" } }, + new { Return = "float", Params = new[] { "Float1x4", "Float4" } }, + new { Return = "Float2", Params = new[] { "Float2x2", "Float2" } }, + new { Return = "Float2", Params = new[] { "Float2x3", "Float3" } }, + new { Return = "Float2", Params = new[] { "Float2x4", "Float4" } }, + new { Return = "Float3", Params = new[] { "Float3x2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3x3", "Float3" } }, + new { Return = "Float3", Params = new[] { "Float3x4", "Float4" } }, + new { Return = "Float4", Params = new[] { "Float4x2", "Float2" } }, + new { Return = "Float4", Params = new[] { "Float4x3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4x4", "Float4" } }, + new { Return = "int", Params = new[] { "Int1x2", "Int2" } }, + new { Return = "int", Params = new[] { "Int1x3", "Int3" } }, + new { Return = "int", Params = new[] { "Int1x4", "Int4" } }, + new { Return = "Int2", Params = new[] { "Int2x2", "Int2" } }, + new { Return = "Int2", Params = new[] { "Int2x3", "Int3" } }, + new { Return = "Int2", Params = new[] { "Int2x4", "Int4" } }, + new { Return = "Int3", Params = new[] { "Int3x2", "Int2" } }, + new { Return = "Int3", Params = new[] { "Int3x3", "Int3" } }, + new { Return = "Int3", Params = new[] { "Int3x4", "Int4" } }, + new { Return = "Int4", Params = new[] { "Int4x2", "Int2" } }, + new { Return = "Int4", Params = new[] { "Int4x3", "Int3" } }, + new { Return = "Int4", Params = new[] { "Int4x4", "Int4" } }, + + // 9 (matrix by matrix) + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x1", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x1", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x1", "Float1x4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x2", "Float2x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float2x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x2", "Float2x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x2", "Float2x4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x3", "Float3x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x3", "Float3x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float3x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x3", "Float3x4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x4", "Float4x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x4", "Float4x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x4", "Float4x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float4x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float1x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x1", "Float1x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x1", "Float1x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x1", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x2", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x2", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x2", "Float2x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x3", "Float3x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x3", "Float3x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float3x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x3", "Float3x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x4", "Float4x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x4", "Float4x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x4", "Float4x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float4x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float1x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x1", "Float1x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x1", "Float1x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x1", "Float1x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x2", "Float2x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float2x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x2", "Float2x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x2", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x3", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x3", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x3", "Float3x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x4", "Float4x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x4", "Float4x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x4", "Float4x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float4x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float1x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x1", "Float1x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x1", "Float1x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x1", "Float1x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x2", "Float2x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float2x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x2", "Float2x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x2", "Float2x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x3", "Float3x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x3", "Float3x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float3x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x3", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x4", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x4", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x4", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4" } }, + new { Return = "Int1x1", Params = new[] { "Int1x1", "Int1x1" } }, + new { Return = "Int1x2", Params = new[] { "Int1x1", "Int1x2" } }, + new { Return = "Int1x3", Params = new[] { "Int1x1", "Int1x3" } }, + new { Return = "Int1x4", Params = new[] { "Int1x1", "Int1x4" } }, + new { Return = "Int1x1", Params = new[] { "Int1x2", "Int2x1" } }, + new { Return = "Int1x2", Params = new[] { "Int1x2", "Int2x2" } }, + new { Return = "Int1x3", Params = new[] { "Int1x2", "Int2x3" } }, + new { Return = "Int1x4", Params = new[] { "Int1x2", "Int2x4" } }, + new { Return = "Int1x1", Params = new[] { "Int1x3", "Int3x1" } }, + new { Return = "Int1x2", Params = new[] { "Int1x3", "Int3x2" } }, + new { Return = "Int1x3", Params = new[] { "Int1x3", "Int3x3" } }, + new { Return = "Int1x4", Params = new[] { "Int1x3", "Int3x4" } }, + new { Return = "Int1x1", Params = new[] { "Int1x4", "Int4x1" } }, + new { Return = "Int1x2", Params = new[] { "Int1x4", "Int4x2" } }, + new { Return = "Int1x3", Params = new[] { "Int1x4", "Int4x3" } }, + new { Return = "Int1x4", Params = new[] { "Int1x4", "Int4x4" } }, + new { Return = "Int2x1", Params = new[] { "Int2x1", "Int1x1" } }, + new { Return = "Int2x2", Params = new[] { "Int2x1", "Int1x2" } }, + new { Return = "Int2x3", Params = new[] { "Int2x1", "Int1x3" } }, + new { Return = "Int2x4", Params = new[] { "Int2x1", "Int1x4" } }, + new { Return = "Int2x1", Params = new[] { "Int2x2", "Int2x1" } }, + new { Return = "Int2x2", Params = new[] { "Int2x2", "Int2x2" } }, + new { Return = "Int2x3", Params = new[] { "Int2x2", "Int2x3" } }, + new { Return = "Int2x4", Params = new[] { "Int2x2", "Int2x4" } }, + new { Return = "Int2x1", Params = new[] { "Int2x3", "Int3x1" } }, + new { Return = "Int2x2", Params = new[] { "Int2x3", "Int3x2" } }, + new { Return = "Int2x3", Params = new[] { "Int2x3", "Int3x3" } }, + new { Return = "Int2x4", Params = new[] { "Int2x3", "Int3x4" } }, + new { Return = "Int2x1", Params = new[] { "Int2x4", "Int4x1" } }, + new { Return = "Int2x2", Params = new[] { "Int2x4", "Int4x2" } }, + new { Return = "Int2x3", Params = new[] { "Int2x4", "Int4x3" } }, + new { Return = "Int2x4", Params = new[] { "Int2x4", "Int4x4" } }, + new { Return = "Int3x1", Params = new[] { "Int3x1", "Int1x1" } }, + new { Return = "Int3x2", Params = new[] { "Int3x1", "Int1x2" } }, + new { Return = "Int3x3", Params = new[] { "Int3x1", "Int1x3" } }, + new { Return = "Int3x4", Params = new[] { "Int3x1", "Int1x4" } }, + new { Return = "Int3x1", Params = new[] { "Int3x2", "Int2x1" } }, + new { Return = "Int3x2", Params = new[] { "Int3x2", "Int2x2" } }, + new { Return = "Int3x3", Params = new[] { "Int3x2", "Int2x3" } }, + new { Return = "Int3x4", Params = new[] { "Int3x2", "Int2x4" } }, + new { Return = "Int3x1", Params = new[] { "Int3x3", "Int3x1" } }, + new { Return = "Int3x2", Params = new[] { "Int3x3", "Int3x2" } }, + new { Return = "Int3x3", Params = new[] { "Int3x3", "Int3x3" } }, + new { Return = "Int3x4", Params = new[] { "Int3x3", "Int3x4" } }, + new { Return = "Int3x1", Params = new[] { "Int3x4", "Int4x1" } }, + new { Return = "Int3x2", Params = new[] { "Int3x4", "Int4x2" } }, + new { Return = "Int3x3", Params = new[] { "Int3x4", "Int4x3" } }, + new { Return = "Int3x4", Params = new[] { "Int3x4", "Int4x4" } }, + new { Return = "Int4x1", Params = new[] { "Int4x1", "Int1x1" } }, + new { Return = "Int4x2", Params = new[] { "Int4x1", "Int1x2" } }, + new { Return = "Int4x3", Params = new[] { "Int4x1", "Int1x3" } }, + new { Return = "Int4x4", Params = new[] { "Int4x1", "Int1x4" } }, + new { Return = "Int4x1", Params = new[] { "Int4x2", "Int2x1" } }, + new { Return = "Int4x2", Params = new[] { "Int4x2", "Int2x2" } }, + new { Return = "Int4x3", Params = new[] { "Int4x2", "Int2x3" } }, + new { Return = "Int4x4", Params = new[] { "Int4x2", "Int2x4" } }, + new { Return = "Int4x1", Params = new[] { "Int4x3", "Int3x1" } }, + new { Return = "Int4x2", Params = new[] { "Int4x3", "Int3x2" } }, + new { Return = "Int4x3", Params = new[] { "Int4x3", "Int3x3" } }, + new { Return = "Int4x4", Params = new[] { "Int4x3", "Int3x4" } }, + new { Return = "Int4x1", Params = new[] { "Int4x4", "Int4x1" } }, + new { Return = "Int4x2", Params = new[] { "Int4x4", "Int4x2" } }, + new { Return = "Int4x3", Params = new[] { "Int4x4", "Int4x3" } }, + new { Return = "Int4x4", Params = new[] { "Int4x4", "Int4x4" } }, + }, + IsPure = true + }, + new + { + Name = "Noise", + HlslName = "noise", + Summary = "Generates a random value using the Perlin-noise algorithm.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "A floating-point vector from which to generate Perlin noise." } + }, + Returns = "The Perlin noise value within a range between -1 and 1.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "Float2" } }, + new { Return = "float", Params = new[] { "Float3" } }, + new { Return = "float", Params = new[] { "Float4" } } + }, + IsPure = true + }, + new + { + Name = "Normalize", + HlslName = "normalize", + Summary = "Normalizes the specified floating-point vector according to x / length(x).", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified floating-point vector." } + }, + Returns = "The normalized {x} parameter. If the length of the {x} parameter is 0, the result is indefinite.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "Float2" } }, + new { Return = "float", Params = new[] { "Float3" } }, + new { Return = "float", Params = new[] { "Float4" } } + }, + IsPure = true + }, + new + { + Name = "Pow", + HlslName = "pow", + Summary = "Returns the specified value raised to the specified power.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." }, + new { IsOut = false, Name = "y", Info = "The specified power." } + }, + Returns = "The {x} parameter raised to the power of the {y} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Radians", + HlslName = "radians", + Summary = "Converts the specified value from degrees to radians.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The {x} parameter converted from degrees to radians.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Rcp", + HlslName = "rcp", + Summary = "Calculates a fast, approximate, per-component reciprocal.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The input value." } + }, + Returns = "The reciprocal of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } }, + new { Return = "double", Params = new[] { "double" } }, + new { Return = "Double2", Params = new[] { "Double2" } }, + new { Return = "Double3", Params = new[] { "Double3" } }, + new { Return = "Double4", Params = new[] { "Double4" } }, + new { Return = "Double1x1", Params = new[] { "Double1x1" } }, + new { Return = "Double1x2", Params = new[] { "Double1x2" } }, + new { Return = "Double1x3", Params = new[] { "Double1x3" } }, + new { Return = "Double1x4", Params = new[] { "Double1x4" } }, + new { Return = "Double2x1", Params = new[] { "Double2x1" } }, + new { Return = "Double2x2", Params = new[] { "Double2x2" } }, + new { Return = "Double2x3", Params = new[] { "Double2x3" } }, + new { Return = "Double2x4", Params = new[] { "Double2x4" } }, + new { Return = "Double3x1", Params = new[] { "Double3x1" } }, + new { Return = "Double3x2", Params = new[] { "Double3x2" } }, + new { Return = "Double3x3", Params = new[] { "Double3x3" } }, + new { Return = "Double3x4", Params = new[] { "Double3x4" } }, + new { Return = "Double4x1", Params = new[] { "Double4x1" } }, + new { Return = "Double4x2", Params = new[] { "Double4x2" } }, + new { Return = "Double4x3", Params = new[] { "Double4x3" } }, + new { Return = "Double4x4", Params = new[] { "Double4x4" } } + }, + IsPure = true + }, + new + { + Name = "ReverseBits", + HlslName = "reversebits", + Summary = "Reverses the order of the bits, per component.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The input value." } + }, + Returns = "The input value, with the bit order reversed.", + Overloads = new[] + { + new { Return = "uint", Params = new[] { "uint" } }, + new { Return = "UInt2", Params = new[] { "UInt2" } }, + new { Return = "UInt3", Params = new[] { "UInt3" } }, + new { Return = "UInt4", Params = new[] { "UInt4" } } + }, + IsPure = true + }, + new + { + Name = "Round", + HlslName = "round", + Summary = "Rounds the specified value to the nearest integer. Halfway cases are rounded to the nearest even.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The {x} parameter, rounded to the nearest integer within a floating-point type.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Rsqrt", + HlslName = "rsqrt", + Summary = "Returns the reciprocal of the square root of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The reciprocal of the square root of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Saturate", + HlslName = "saturate", + Summary = "Clamps the specified value within the range of 0 to 1.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "The {x} parameter, clamped within the range of 0 to 1.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Sign", + HlslName = "sign", + Summary = "Returns the sign of the input value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value." } + }, + Returns = "Returns -1 if {x} is less than zero; 0 if {x} equals zero; and 1 if {x} is greater than zero.", + Overloads = new[] + { + new { Return = "int", Params = new[] { "float" } }, + new { Return = "Int2", Params = new[] { "Float2" } }, + new { Return = "Int3", Params = new[] { "Float3" } }, + new { Return = "Int4", Params = new[] { "Float4" } }, + new { Return = "Int1x1", Params = new[] { "Float1x1" } }, + new { Return = "Int1x2", Params = new[] { "Float1x2" } }, + new { Return = "Int1x3", Params = new[] { "Float1x3" } }, + new { Return = "Int1x4", Params = new[] { "Float1x4" } }, + new { Return = "Int2x1", Params = new[] { "Float2x1" } }, + new { Return = "Int2x2", Params = new[] { "Float2x2" } }, + new { Return = "Int2x3", Params = new[] { "Float2x3" } }, + new { Return = "Int2x4", Params = new[] { "Float2x4" } }, + new { Return = "Int3x1", Params = new[] { "Float3x1" } }, + new { Return = "Int3x2", Params = new[] { "Float3x2" } }, + new { Return = "Int3x3", Params = new[] { "Float3x3" } }, + new { Return = "Int3x4", Params = new[] { "Float3x4" } }, + new { Return = "Int4x1", Params = new[] { "Float4x1" } }, + new { Return = "Int4x2", Params = new[] { "Float4x2" } }, + new { Return = "Int4x3", Params = new[] { "Float4x3" } }, + new { Return = "Int4x4", Params = new[] { "Float4x4" } }, + new { Return = "int", Params = new[] { "int" } }, + new { Return = "Int2", Params = new[] { "Int2" } }, + new { Return = "Int3", Params = new[] { "Int3" } }, + new { Return = "Int4", Params = new[] { "Int4" } }, + new { Return = "Int1x1", Params = new[] { "Int1x1" } }, + new { Return = "Int1x2", Params = new[] { "Int1x2" } }, + new { Return = "Int1x3", Params = new[] { "Int1x3" } }, + new { Return = "Int1x4", Params = new[] { "Int1x4" } }, + new { Return = "Int2x1", Params = new[] { "Int2x1" } }, + new { Return = "Int2x2", Params = new[] { "Int2x2" } }, + new { Return = "Int2x3", Params = new[] { "Int2x3" } }, + new { Return = "Int2x4", Params = new[] { "Int2x4" } }, + new { Return = "Int3x1", Params = new[] { "Int3x1" } }, + new { Return = "Int3x2", Params = new[] { "Int3x2" } }, + new { Return = "Int3x3", Params = new[] { "Int3x3" } }, + new { Return = "Int3x4", Params = new[] { "Int3x4" } }, + new { Return = "Int4x1", Params = new[] { "Int4x1" } }, + new { Return = "Int4x2", Params = new[] { "Int4x2" } }, + new { Return = "Int4x3", Params = new[] { "Int4x3" } }, + new { Return = "Int4x4", Params = new[] { "Int4x4" } } + }, + IsPure = true + }, + new + { + Name = "Sin", + HlslName = "sin", + Summary = "Returns the sine of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value, in radians." } + }, + Returns = "The sine of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "SinCos", + HlslName = "sincos", + Summary = "Returns the sine and cosine of a specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value, in radians." }, + new { IsOut = true, Name = "sin", Info = "The resulting sine." }, + new { IsOut = true, Name = "cos", Info = "The resulting cosine." } + }, + Returns = string.Empty, + Overloads = new[] + { + new { Return = "void", Params = new[] { "float", "float", "float" } }, + new { Return = "void", Params = new[] { "Float2", "Float2", "Float2" } }, + new { Return = "void", Params = new[] { "Float3", "Float3", "Float3" } }, + new { Return = "void", Params = new[] { "Float4", "Float4", "Float4" } }, + new { Return = "void", Params = new[] { "Float1x1", "Float1x1", "Float1x1" } }, + new { Return = "void", Params = new[] { "Float1x2", "Float1x2", "Float1x2" } }, + new { Return = "void", Params = new[] { "Float1x3", "Float1x3", "Float1x3" } }, + new { Return = "void", Params = new[] { "Float1x4", "Float1x4", "Float1x4" } }, + new { Return = "void", Params = new[] { "Float2x1", "Float2x1", "Float2x1" } }, + new { Return = "void", Params = new[] { "Float2x2", "Float2x2", "Float2x2" } }, + new { Return = "void", Params = new[] { "Float2x3", "Float2x3", "Float2x3" } }, + new { Return = "void", Params = new[] { "Float2x4", "Float2x4", "Float2x4" } }, + new { Return = "void", Params = new[] { "Float3x1", "Float3x1", "Float3x1" } }, + new { Return = "void", Params = new[] { "Float3x2", "Float3x2", "Float3x2" } }, + new { Return = "void", Params = new[] { "Float3x3", "Float3x3", "Float3x3" } }, + new { Return = "void", Params = new[] { "Float3x4", "Float3x4", "Float3x4" } }, + new { Return = "void", Params = new[] { "Float4x1", "Float4x1", "Float4x1" } }, + new { Return = "void", Params = new[] { "Float4x2", "Float4x2", "Float4x2" } }, + new { Return = "void", Params = new[] { "Float4x3", "Float4x3", "Float4x3" } }, + new { Return = "void", Params = new[] { "Float4x4", "Float4x4", "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Sinh", + HlslName = "sinh", + Summary = "Returns the hyperbolic sine of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value, in radians." } + }, + Returns = "The hyperbolic sine of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "SmoothStep", + HlslName = "smoothstep", + Summary = "Returns a smooth Hermite interpolation between 0 and 1 if the specified value is in the input range.", + Parameters = new[] + { + new { IsOut = false, Name = "min", Info = "The specified minimum range." }, + new { IsOut = false, Name = "max", Info = "The specified maximum range." }, + new { IsOut = false, Name = "x", Info = "The specified value to be interpolated." } + }, + Returns = "Returns 0 if {x} is less than {min}; 1 if {x} is greater than {max}; otherwise, a value between 0 and 1 if {x} is in the range [{min}, {max}].", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4", "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Sqrt", + HlslName = "sqrt", + Summary = "Returns the square root of the specified floating-point value, per component.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified floating-point value." } + }, + Returns = "The square root of the {x} parameter, per component.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Step", + HlslName = "step", + Summary = "Compares two values, returning 0 or 1 based on which value is greater.", + Parameters = new[] + { + new { IsOut = false, Name = "y", Info = "The first specified floating-point value." }, + new { IsOut = false, Name = "x", Info = "The second specified floating-point value." } + }, + Returns = "1 if the {x} parameter is greater than or equal to the {y} parameter; otherwise, 0.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float", "float" } }, + new { Return = "Float2", Params = new[] { "Float2", "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3", "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4", "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1", "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2", "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3", "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4", "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1", "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2", "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3", "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4", "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1", "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2", "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3", "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4", "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1", "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2", "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3", "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4", "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Tan", + HlslName = "tan", + Summary = "Returns the tangent of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value, in radians." } + }, + Returns = "The tangent of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Tanh", + HlslName = "tanh", + Summary = "Returns the hyperbolic tangent of the specified value.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified value, in radians." } + }, + Returns = "The hyperbolic tangent of the {x} parameter.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + }, + new + { + Name = "Transpose", + HlslName = "transpose", + Summary = "Transposes the specified input matrix.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified matrix." } + }, + Returns = "The transposed value of the {x} parameter.", + Overloads = new[] + { + new { Return = "Float2x1", Params = new[] { "Float1x2" } }, + new { Return = "Float3x1", Params = new[] { "Float1x3" } }, + new { Return = "Float4x1", Params = new[] { "Float1x4" } }, + new { Return = "Float1x2", Params = new[] { "Float2x1" } }, + new { Return = "Float3x2", Params = new[] { "Float2x3" } }, + new { Return = "Float4x2", Params = new[] { "Float2x4" } }, + new { Return = "Float1x3", Params = new[] { "Float3x1" } }, + new { Return = "Float2x3", Params = new[] { "Float3x2" } }, + new { Return = "Float4x3", Params = new[] { "Float3x4" } }, + new { Return = "Float1x4", Params = new[] { "Float4x1" } }, + new { Return = "Float2x4", Params = new[] { "Float4x2" } }, + new { Return = "Float3x4", Params = new[] { "Float4x3" } }, + new { Return = "Int2x1", Params = new[] { "Int1x2" } }, + new { Return = "Int3x1", Params = new[] { "Int1x3" } }, + new { Return = "Int4x1", Params = new[] { "Int1x4" } }, + new { Return = "Int1x2", Params = new[] { "Int2x1" } }, + new { Return = "Int3x2", Params = new[] { "Int2x3" } }, + new { Return = "Int4x2", Params = new[] { "Int2x4" } }, + new { Return = "Int1x3", Params = new[] { "Int3x1" } }, + new { Return = "Int2x3", Params = new[] { "Int3x2" } }, + new { Return = "Int4x3", Params = new[] { "Int3x4" } }, + new { Return = "Int1x4", Params = new[] { "Int4x1" } }, + new { Return = "Int2x4", Params = new[] { "Int4x2" } }, + new { Return = "Int3x4", Params = new[] { "Int4x3" } }, + new { Return = "Bool2x1", Params = new[] { "Bool1x2" } }, + new { Return = "Bool3x1", Params = new[] { "Bool1x3" } }, + new { Return = "Bool4x1", Params = new[] { "Bool1x4" } }, + new { Return = "Bool1x2", Params = new[] { "Bool2x1" } }, + new { Return = "Bool3x2", Params = new[] { "Bool2x3" } }, + new { Return = "Bool4x2", Params = new[] { "Bool2x4" } }, + new { Return = "Bool1x3", Params = new[] { "Bool3x1" } }, + new { Return = "Bool2x3", Params = new[] { "Bool3x2" } }, + new { Return = "Bool4x3", Params = new[] { "Bool3x4" } }, + new { Return = "Bool1x4", Params = new[] { "Bool4x1" } }, + new { Return = "Bool2x4", Params = new[] { "Bool4x2" } }, + new { Return = "Bool3x4", Params = new[] { "Bool4x3" } }, + }, + IsPure = true + }, + new + { + Name = "Trunc", + HlslName = "trunc", + Summary = "Truncates a floating-point value to the integer component.", + Parameters = new[] + { + new { IsOut = false, Name = "x", Info = "The specified input." } + }, + Returns = "The input value truncated to an integer component.", + Overloads = new[] + { + new { Return = "float", Params = new[] { "float" } }, + new { Return = "Float2", Params = new[] { "Float2" } }, + new { Return = "Float3", Params = new[] { "Float3" } }, + new { Return = "Float4", Params = new[] { "Float4" } }, + new { Return = "Float1x1", Params = new[] { "Float1x1" } }, + new { Return = "Float1x2", Params = new[] { "Float1x2" } }, + new { Return = "Float1x3", Params = new[] { "Float1x3" } }, + new { Return = "Float1x4", Params = new[] { "Float1x4" } }, + new { Return = "Float2x1", Params = new[] { "Float2x1" } }, + new { Return = "Float2x2", Params = new[] { "Float2x2" } }, + new { Return = "Float2x3", Params = new[] { "Float2x3" } }, + new { Return = "Float2x4", Params = new[] { "Float2x4" } }, + new { Return = "Float3x1", Params = new[] { "Float3x1" } }, + new { Return = "Float3x2", Params = new[] { "Float3x2" } }, + new { Return = "Float3x3", Params = new[] { "Float3x3" } }, + new { Return = "Float3x4", Params = new[] { "Float3x4" } }, + new { Return = "Float4x1", Params = new[] { "Float4x1" } }, + new { Return = "Float4x2", Params = new[] { "Float4x2" } }, + new { Return = "Float4x3", Params = new[] { "Float4x3" } }, + new { Return = "Float4x4", Params = new[] { "Float4x4" } } + }, + IsPure = true + } +}; +#> \ No newline at end of file diff --git a/src/ComputeSharp/Core/Primitives/Bool/Bool.cs b/src/ComputeSharp/Core/Primitives/Bool/Bool.cs index b1fe373a..8af16442 100644 --- a/src/ComputeSharp/Core/Primitives/Bool/Bool.cs +++ b/src/ComputeSharp/Core/Primitives/Bool/Bool.cs @@ -7,7 +7,7 @@ namespace ComputeSharp /// A that can be used in place of the type in HLSL shaders. /// [DebuggerDisplay("{Value}")] - [StructLayout(LayoutKind.Explicit, Size = sizeof(int))] + [StructLayout(LayoutKind.Explicit, Size = sizeof(int), Pack = 4)] public readonly struct Bool { /// diff --git a/src/ComputeSharp/Core/Primitives/Bool/Bool2.g.cs b/src/ComputeSharp/Core/Primitives/Bool/Bool2.g.cs index 085edf57..89c9426c 100644 --- a/src/ComputeSharp/Core/Primitives/Bool/Bool2.g.cs +++ b/src/ComputeSharp/Core/Primitives/Bool/Bool2.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 8)] + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] public partial struct Bool2 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Bool/Bool3.g.cs b/src/ComputeSharp/Core/Primitives/Bool/Bool3.g.cs index 72c49824..de0e57e9 100644 --- a/src/ComputeSharp/Core/Primitives/Bool/Bool3.g.cs +++ b/src/ComputeSharp/Core/Primitives/Bool/Bool3.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 12)] + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] public partial struct Bool3 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Bool/Bool4.g.cs b/src/ComputeSharp/Core/Primitives/Bool/Bool4.g.cs index 0139055f..fbd9fc50 100644 --- a/src/ComputeSharp/Core/Primitives/Bool/Bool4.g.cs +++ b/src/ComputeSharp/Core/Primitives/Bool/Bool4.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 16)] + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] public partial struct Bool4 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Bool/BoolMxN.g.cs b/src/ComputeSharp/Core/Primitives/Bool/BoolMxN.g.cs new file mode 100644 index 00000000..35fa4cd2 --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/Bool/BoolMxN.g.cs @@ -0,0 +1,2720 @@ +using System.Runtime.InteropServices; +using ComputeSharp.Exceptions; + +namespace ComputeSharp +{ + /// + [StructLayout(LayoutKind.Explicit, Size = 4, Pack = 4)] + public partial struct Bool1x1 + { + [FieldOffset(0)] + private bool m11; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + public Bool1x1(bool m11) + { + this.m11 = m11; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref bool this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool1x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool1x1)}.M11"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool1x1(bool x) + { + Bool1x1 matrix; + + matrix.m11 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool1x1 operator -(Bool1x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool1x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool1x1 operator +(Bool1x1 left, Bool1x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool1x1 operator /(Bool1x1 left, Bool1x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool1x1 operator *(Bool1x1 left, Bool1x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool1x1 operator -(Bool1x1 left, Bool1x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x1)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] + public partial struct Bool1x2 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + public Bool1x2(bool m11, bool m12) + { + this.m11 = m11; + this.m12 = m12; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool1x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool1x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool1x2)}.M12"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool1x2(bool x) + { + Bool1x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool1x2 operator -(Bool1x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool1x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool1x2 operator +(Bool1x2 left, Bool1x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool1x2 operator /(Bool1x2 left, Bool1x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool1x2 operator *(Bool1x2 left, Bool1x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool1x2 operator -(Bool1x2 left, Bool1x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x2)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Bool1x2(Bool2 vector) => throw new InvalidExecutionContextException($"{typeof(Bool1x2)}.{nameof(Bool1x2)}({nameof(Bool2)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] + public partial struct Bool1x3 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m13; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + public Bool1x3(bool m11, bool m12, bool m13) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool1x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool1x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool1x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref bool M13 => throw new InvalidExecutionContextException($"{typeof(Bool1x3)}.M13"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool1x3(bool x) + { + Bool1x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool1x3 operator -(Bool1x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool1x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool1x3 operator +(Bool1x3 left, Bool1x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool1x3 operator /(Bool1x3 left, Bool1x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool1x3 operator *(Bool1x3 left, Bool1x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool1x3 operator -(Bool1x3 left, Bool1x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x3)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Bool1x3(Bool3 vector) => throw new InvalidExecutionContextException($"{typeof(Bool1x3)}.{nameof(Bool1x3)}({nameof(Bool3)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct Bool1x4 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m13; + + [FieldOffset(12)] + private bool m14; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + public Bool1x4(bool m11, bool m12, bool m13, bool m14) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool1x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool1x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool1x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref bool M13 => throw new InvalidExecutionContextException($"{typeof(Bool1x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref bool M14 => throw new InvalidExecutionContextException($"{typeof(Bool1x4)}.M14"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool1x4(bool x) + { + Bool1x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool1x4 operator -(Bool1x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool1x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool1x4 operator +(Bool1x4 left, Bool1x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool1x4 operator /(Bool1x4 left, Bool1x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool1x4 operator *(Bool1x4 left, Bool1x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool1x4 operator -(Bool1x4 left, Bool1x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool1x4)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Bool1x4(Bool4 vector) => throw new InvalidExecutionContextException($"{typeof(Bool1x4)}.{nameof(Bool1x4)}({nameof(Bool4)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] + public partial struct Bool2x1 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m21; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + public Bool2x1(bool m11, bool m21) + { + this.m11 = m11; + this.m21 = m21; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref bool this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool2x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool2x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool2x1)}.M21"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool2x1(bool x) + { + Bool2x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool2x1 operator -(Bool2x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool2x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool2x1 operator +(Bool2x1 left, Bool2x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool2x1 operator /(Bool2x1 left, Bool2x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool2x1 operator *(Bool2x1 left, Bool2x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool2x1 operator -(Bool2x1 left, Bool2x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Bool2(Bool2x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Bool2x1)}.{nameof(Bool2)}({nameof(Bool2x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct Bool2x2 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m21; + + [FieldOffset(12)] + private bool m22; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + public Bool2x2(bool m11, bool m12, bool m21, bool m22) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Bool2x2(Bool2 row1, Bool2 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool2x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool2x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool2x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool2x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref bool M22 => throw new InvalidExecutionContextException($"{typeof(Bool2x2)}.M22"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool2x2(bool x) + { + Bool2x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool2x2 operator -(Bool2x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool2x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool2x2 operator +(Bool2x2 left, Bool2x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool2x2 operator /(Bool2x2 left, Bool2x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool2x2 operator *(Bool2x2 left, Bool2x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool2x2 operator -(Bool2x2 left, Bool2x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 4)] + public partial struct Bool2x3 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m13; + + [FieldOffset(12)] + private bool m21; + + [FieldOffset(16)] + private bool m22; + + [FieldOffset(20)] + private bool m23; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + public Bool2x3(bool m11, bool m12, bool m13, bool m21, bool m22, bool m23) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Bool2x3(Bool3 row1, Bool3 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool2x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool2x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool2x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref bool M13 => throw new InvalidExecutionContextException($"{typeof(Bool2x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool2x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref bool M22 => throw new InvalidExecutionContextException($"{typeof(Bool2x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref bool M23 => throw new InvalidExecutionContextException($"{typeof(Bool2x3)}.M23"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool2x3(bool x) + { + Bool2x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool2x3 operator -(Bool2x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool2x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool2x3 operator +(Bool2x3 left, Bool2x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool2x3 operator /(Bool2x3 left, Bool2x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool2x3 operator *(Bool2x3 left, Bool2x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool2x3 operator -(Bool2x3 left, Bool2x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 4)] + public partial struct Bool2x4 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m13; + + [FieldOffset(12)] + private bool m14; + + [FieldOffset(16)] + private bool m21; + + [FieldOffset(20)] + private bool m22; + + [FieldOffset(24)] + private bool m23; + + [FieldOffset(28)] + private bool m24; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + public Bool2x4(bool m11, bool m12, bool m13, bool m14, bool m21, bool m22, bool m23, bool m24) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Bool2x4(Bool4 row1, Bool4 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool2x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool2x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool2x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref bool M13 => throw new InvalidExecutionContextException($"{typeof(Bool2x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref bool M14 => throw new InvalidExecutionContextException($"{typeof(Bool2x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool2x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref bool M22 => throw new InvalidExecutionContextException($"{typeof(Bool2x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref bool M23 => throw new InvalidExecutionContextException($"{typeof(Bool2x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref bool M24 => throw new InvalidExecutionContextException($"{typeof(Bool2x4)}.M24"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool2x4(bool x) + { + Bool2x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool2x4 operator -(Bool2x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool2x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool2x4 operator +(Bool2x4 left, Bool2x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool2x4 operator /(Bool2x4 left, Bool2x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool2x4 operator *(Bool2x4 left, Bool2x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool2x4 operator -(Bool2x4 left, Bool2x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool2x4)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] + public partial struct Bool3x1 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m21; + + [FieldOffset(8)] + private bool m31; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [3, 1]. + public Bool3x1(bool m11, bool m21, bool m31) + { + this.m11 = m11; + this.m21 = m21; + this.m31 = m31; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref bool this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool3x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool3x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool3x1)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref bool M31 => throw new InvalidExecutionContextException($"{typeof(Bool3x1)}.M31"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool3x1(bool x) + { + Bool3x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + matrix.m31 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool3x1 operator -(Bool3x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool3x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool3x1 operator +(Bool3x1 left, Bool3x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool3x1 operator /(Bool3x1 left, Bool3x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool3x1 operator *(Bool3x1 left, Bool3x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool3x1 operator -(Bool3x1 left, Bool3x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Bool3(Bool3x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Bool3x1)}.{nameof(Bool3)}({nameof(Bool3x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 4)] + public partial struct Bool3x2 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m21; + + [FieldOffset(12)] + private bool m22; + + [FieldOffset(16)] + private bool m31; + + [FieldOffset(20)] + private bool m32; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + public Bool3x2(bool m11, bool m12, bool m21, bool m22, bool m31, bool m32) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + this.m31 = m31; + this.m32 = m32; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Bool3x2(Bool2 row1, Bool2 row2, Bool2 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m31 = row3.X; + this.m32 = row3.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool3x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool3x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool3x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool3x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref bool M22 => throw new InvalidExecutionContextException($"{typeof(Bool3x2)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref bool M31 => throw new InvalidExecutionContextException($"{typeof(Bool3x2)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref bool M32 => throw new InvalidExecutionContextException($"{typeof(Bool3x2)}.M32"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool3x2(bool x) + { + Bool3x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m31 = x; + matrix.m32 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool3x2 operator -(Bool3x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool3x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool3x2 operator +(Bool3x2 left, Bool3x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool3x2 operator /(Bool3x2 left, Bool3x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool3x2 operator *(Bool3x2 left, Bool3x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool3x2 operator -(Bool3x2 left, Bool3x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 36, Pack = 4)] + public partial struct Bool3x3 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m13; + + [FieldOffset(12)] + private bool m21; + + [FieldOffset(16)] + private bool m22; + + [FieldOffset(20)] + private bool m23; + + [FieldOffset(24)] + private bool m31; + + [FieldOffset(28)] + private bool m32; + + [FieldOffset(32)] + private bool m33; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + public Bool3x3(bool m11, bool m12, bool m13, bool m21, bool m22, bool m23, bool m31, bool m32, bool m33) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Bool3x3(Bool3 row1, Bool3 row2, Bool3 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool3x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool3x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool3x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref bool M13 => throw new InvalidExecutionContextException($"{typeof(Bool3x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool3x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref bool M22 => throw new InvalidExecutionContextException($"{typeof(Bool3x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref bool M23 => throw new InvalidExecutionContextException($"{typeof(Bool3x3)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref bool M31 => throw new InvalidExecutionContextException($"{typeof(Bool3x3)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref bool M32 => throw new InvalidExecutionContextException($"{typeof(Bool3x3)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref bool M33 => throw new InvalidExecutionContextException($"{typeof(Bool3x3)}.M33"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool3x3(bool x) + { + Bool3x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool3x3 operator -(Bool3x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool3x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool3x3 operator +(Bool3x3 left, Bool3x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool3x3 operator /(Bool3x3 left, Bool3x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool3x3 operator *(Bool3x3 left, Bool3x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool3x3 operator -(Bool3x3 left, Bool3x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 48, Pack = 4)] + public partial struct Bool3x4 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m13; + + [FieldOffset(12)] + private bool m14; + + [FieldOffset(16)] + private bool m21; + + [FieldOffset(20)] + private bool m22; + + [FieldOffset(24)] + private bool m23; + + [FieldOffset(28)] + private bool m24; + + [FieldOffset(32)] + private bool m31; + + [FieldOffset(36)] + private bool m32; + + [FieldOffset(40)] + private bool m33; + + [FieldOffset(44)] + private bool m34; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [3, 4]. + public Bool3x4(bool m11, bool m12, bool m13, bool m14, bool m21, bool m22, bool m23, bool m24, bool m31, bool m32, bool m33, bool m34) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m34 = m34; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Bool3x4(Bool4 row1, Bool4 row2, Bool4 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m34 = row3.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool3x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref bool M13 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref bool M14 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref bool M22 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref bool M23 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref bool M24 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M24"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref bool M31 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref bool M32 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref bool M33 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [3, 4]. + /// + public ref bool M34 => throw new InvalidExecutionContextException($"{typeof(Bool3x4)}.M34"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool3x4(bool x) + { + Bool3x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m34 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool3x4 operator -(Bool3x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool3x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool3x4 operator +(Bool3x4 left, Bool3x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool3x4 operator /(Bool3x4 left, Bool3x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool3x4 operator *(Bool3x4 left, Bool3x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool3x4 operator -(Bool3x4 left, Bool3x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool3x4)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct Bool4x1 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m21; + + [FieldOffset(8)] + private bool m31; + + [FieldOffset(12)] + private bool m41; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [4, 1]. + public Bool4x1(bool m11, bool m21, bool m31, bool m41) + { + this.m11 = m11; + this.m21 = m21; + this.m31 = m31; + this.m41 = m41; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref bool this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool4x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool4x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool4x1)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref bool M31 => throw new InvalidExecutionContextException($"{typeof(Bool4x1)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref bool M41 => throw new InvalidExecutionContextException($"{typeof(Bool4x1)}.M41"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool4x1(bool x) + { + Bool4x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + matrix.m31 = x; + matrix.m41 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool4x1 operator -(Bool4x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool4x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool4x1 operator +(Bool4x1 left, Bool4x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool4x1 operator /(Bool4x1 left, Bool4x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool4x1 operator *(Bool4x1 left, Bool4x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool4x1 operator -(Bool4x1 left, Bool4x1 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Bool4(Bool4x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Bool4x1)}.{nameof(Bool4)}({nameof(Bool4x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 4)] + public partial struct Bool4x2 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m21; + + [FieldOffset(12)] + private bool m22; + + [FieldOffset(16)] + private bool m31; + + [FieldOffset(20)] + private bool m32; + + [FieldOffset(24)] + private bool m41; + + [FieldOffset(28)] + private bool m42; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + public Bool4x2(bool m11, bool m12, bool m21, bool m22, bool m31, bool m32, bool m41, bool m42) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + this.m31 = m31; + this.m32 = m32; + this.m41 = m41; + this.m42 = m42; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Bool4x2(Bool2 row1, Bool2 row2, Bool2 row3, Bool2 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m41 = row4.X; + this.m42 = row4.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool4x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool4x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool4x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool4x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref bool M22 => throw new InvalidExecutionContextException($"{typeof(Bool4x2)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref bool M31 => throw new InvalidExecutionContextException($"{typeof(Bool4x2)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref bool M32 => throw new InvalidExecutionContextException($"{typeof(Bool4x2)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref bool M41 => throw new InvalidExecutionContextException($"{typeof(Bool4x2)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref bool M42 => throw new InvalidExecutionContextException($"{typeof(Bool4x2)}.M42"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool4x2(bool x) + { + Bool4x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m41 = x; + matrix.m42 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool4x2 operator -(Bool4x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool4x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool4x2 operator +(Bool4x2 left, Bool4x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool4x2 operator /(Bool4x2 left, Bool4x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool4x2 operator *(Bool4x2 left, Bool4x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool4x2 operator -(Bool4x2 left, Bool4x2 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 48, Pack = 4)] + public partial struct Bool4x3 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m13; + + [FieldOffset(12)] + private bool m21; + + [FieldOffset(16)] + private bool m22; + + [FieldOffset(20)] + private bool m23; + + [FieldOffset(24)] + private bool m31; + + [FieldOffset(28)] + private bool m32; + + [FieldOffset(32)] + private bool m33; + + [FieldOffset(36)] + private bool m41; + + [FieldOffset(40)] + private bool m42; + + [FieldOffset(44)] + private bool m43; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + /// The value to assign to the component at position [4, 3]. + public Bool4x3(bool m11, bool m12, bool m13, bool m21, bool m22, bool m23, bool m31, bool m32, bool m33, bool m41, bool m42, bool m43) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m41 = m41; + this.m42 = m42; + this.m43 = m43; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Bool4x3(Bool3 row1, Bool3 row2, Bool3 row3, Bool3 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m41 = row4.X; + this.m42 = row4.Y; + this.m43 = row4.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool4x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref bool M13 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref bool M22 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref bool M23 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref bool M31 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref bool M32 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref bool M33 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref bool M41 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref bool M42 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M42"); + + /// + /// Gets a reference to the value representing the component at position [4, 3]. + /// + public ref bool M43 => throw new InvalidExecutionContextException($"{typeof(Bool4x3)}.M43"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool4x3(bool x) + { + Bool4x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m41 = x; + matrix.m42 = x; + matrix.m43 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool4x3 operator -(Bool4x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool4x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool4x3 operator +(Bool4x3 left, Bool4x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool4x3 operator /(Bool4x3 left, Bool4x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool4x3 operator *(Bool4x3 left, Bool4x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool4x3 operator -(Bool4x3 left, Bool4x3 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 64, Pack = 4)] + public partial struct Bool4x4 + { + [FieldOffset(0)] + private bool m11; + + [FieldOffset(4)] + private bool m12; + + [FieldOffset(8)] + private bool m13; + + [FieldOffset(12)] + private bool m14; + + [FieldOffset(16)] + private bool m21; + + [FieldOffset(20)] + private bool m22; + + [FieldOffset(24)] + private bool m23; + + [FieldOffset(28)] + private bool m24; + + [FieldOffset(32)] + private bool m31; + + [FieldOffset(36)] + private bool m32; + + [FieldOffset(40)] + private bool m33; + + [FieldOffset(44)] + private bool m34; + + [FieldOffset(48)] + private bool m41; + + [FieldOffset(52)] + private bool m42; + + [FieldOffset(56)] + private bool m43; + + [FieldOffset(60)] + private bool m44; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [3, 4]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + /// The value to assign to the component at position [4, 3]. + /// The value to assign to the component at position [4, 4]. + public Bool4x4(bool m11, bool m12, bool m13, bool m14, bool m21, bool m22, bool m23, bool m24, bool m31, bool m32, bool m33, bool m34, bool m41, bool m42, bool m43, bool m44) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m34 = m34; + this.m41 = m41; + this.m42 = m42; + this.m43 = m43; + this.m44 = m44; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Bool4x4(Bool4 row1, Bool4 row2, Bool4 row3, Bool4 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m34 = row3.W; + this.m41 = row4.X; + this.m42 = row4.Y; + this.m43 = row4.Z; + this.m44 = row4.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Bool4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Bool4x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Bool2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Bool4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Bool3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Bool4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Bool4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Bool4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref bool M11 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref bool M12 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref bool M13 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref bool M14 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref bool M21 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref bool M22 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref bool M23 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref bool M24 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M24"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref bool M31 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref bool M32 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref bool M33 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [3, 4]. + /// + public ref bool M34 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M34"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref bool M41 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref bool M42 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M42"); + + /// + /// Gets a reference to the value representing the component at position [4, 3]. + /// + public ref bool M43 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M43"); + + /// + /// Gets a reference to the value representing the component at position [4, 4]. + /// + public ref bool M44 => throw new InvalidExecutionContextException($"{typeof(Bool4x4)}.M44"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Bool4x4(bool x) + { + Bool4x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m34 = x; + matrix.m41 = x; + matrix.m42 = x; + matrix.m43 = x; + matrix.m44 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Bool4x4 operator -(Bool4x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Bool4x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Bool4x4 operator +(Bool4x4 left, Bool4x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Bool4x4 operator /(Bool4x4 left, Bool4x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Bool4x4 operator *(Bool4x4 left, Bool4x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Bool4x4 operator -(Bool4x4 left, Bool4x4 right) => throw new InvalidExecutionContextException($"{nameof(Bool4x4)}.-"); + } +} diff --git a/src/ComputeSharp/Core/Primitives/Bool/BoolMxN.tt b/src/ComputeSharp/Core/Primitives/Bool/BoolMxN.tt new file mode 100644 index 00000000..76a0d8bc --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/Bool/BoolMxN.tt @@ -0,0 +1,4 @@ +<#@include file="..\MatrixType.ttinclude" #> +<# +GenerateAllMatrixProperties("Bool", sizeof(int)); +#> \ No newline at end of file diff --git a/src/ComputeSharp/Core/Primitives/Double/Double2.g.cs b/src/ComputeSharp/Core/Primitives/Double/Double2.g.cs index 1613c8ce..2476990a 100644 --- a/src/ComputeSharp/Core/Primitives/Double/Double2.g.cs +++ b/src/ComputeSharp/Core/Primitives/Double/Double2.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 16)] + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 8)] public partial struct Double2 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Double/Double3.g.cs b/src/ComputeSharp/Core/Primitives/Double/Double3.g.cs index 66ed53fe..b0715bc5 100644 --- a/src/ComputeSharp/Core/Primitives/Double/Double3.g.cs +++ b/src/ComputeSharp/Core/Primitives/Double/Double3.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 24)] + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 8)] public partial struct Double3 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Double/Double4.g.cs b/src/ComputeSharp/Core/Primitives/Double/Double4.g.cs index d0f3b2b2..7b1fc1ca 100644 --- a/src/ComputeSharp/Core/Primitives/Double/Double4.g.cs +++ b/src/ComputeSharp/Core/Primitives/Double/Double4.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 32)] + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 8)] public partial struct Double4 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Double/DoubleMxN.g.cs b/src/ComputeSharp/Core/Primitives/Double/DoubleMxN.g.cs new file mode 100644 index 00000000..2e7f926e --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/Double/DoubleMxN.g.cs @@ -0,0 +1,2720 @@ +using System.Runtime.InteropServices; +using ComputeSharp.Exceptions; + +namespace ComputeSharp +{ + /// + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 8)] + public partial struct Double1x1 + { + [FieldOffset(0)] + private double m11; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + public Double1x1(double m11) + { + this.m11 = m11; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref double this[int row] => throw new InvalidExecutionContextException($"{nameof(Double1x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double1x1)}.M11"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double1x1(double x) + { + Double1x1 matrix; + + matrix.m11 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double1x1 operator -(Double1x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Double1x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double1x1 operator +(Double1x1 left, Double1x1 right) => throw new InvalidExecutionContextException($"{nameof(Double1x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double1x1 operator /(Double1x1 left, Double1x1 right) => throw new InvalidExecutionContextException($"{nameof(Double1x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double1x1 operator *(Double1x1 left, Double1x1 right) => throw new InvalidExecutionContextException($"{nameof(Double1x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double1x1 operator -(Double1x1 left, Double1x1 right) => throw new InvalidExecutionContextException($"{nameof(Double1x1)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 8)] + public partial struct Double1x2 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + public Double1x2(double m11, double m12) + { + this.m11 = m11; + this.m12 = m12; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double1x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double1x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double1x2)}.M12"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double1x2(double x) + { + Double1x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double1x2 operator -(Double1x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Double1x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double1x2 operator +(Double1x2 left, Double1x2 right) => throw new InvalidExecutionContextException($"{nameof(Double1x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double1x2 operator /(Double1x2 left, Double1x2 right) => throw new InvalidExecutionContextException($"{nameof(Double1x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double1x2 operator *(Double1x2 left, Double1x2 right) => throw new InvalidExecutionContextException($"{nameof(Double1x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double1x2 operator -(Double1x2 left, Double1x2 right) => throw new InvalidExecutionContextException($"{nameof(Double1x2)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Double1x2(Double2 vector) => throw new InvalidExecutionContextException($"{typeof(Double1x2)}.{nameof(Double1x2)}({nameof(Double2)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 8)] + public partial struct Double1x3 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m13; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + public Double1x3(double m11, double m12, double m13) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double1x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double1x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double1x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref double M13 => throw new InvalidExecutionContextException($"{typeof(Double1x3)}.M13"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double1x3(double x) + { + Double1x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double1x3 operator -(Double1x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Double1x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double1x3 operator +(Double1x3 left, Double1x3 right) => throw new InvalidExecutionContextException($"{nameof(Double1x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double1x3 operator /(Double1x3 left, Double1x3 right) => throw new InvalidExecutionContextException($"{nameof(Double1x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double1x3 operator *(Double1x3 left, Double1x3 right) => throw new InvalidExecutionContextException($"{nameof(Double1x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double1x3 operator -(Double1x3 left, Double1x3 right) => throw new InvalidExecutionContextException($"{nameof(Double1x3)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Double1x3(Double3 vector) => throw new InvalidExecutionContextException($"{typeof(Double1x3)}.{nameof(Double1x3)}({nameof(Double3)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 8)] + public partial struct Double1x4 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m13; + + [FieldOffset(24)] + private double m14; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + public Double1x4(double m11, double m12, double m13, double m14) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double1x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double1x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double1x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref double M13 => throw new InvalidExecutionContextException($"{typeof(Double1x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref double M14 => throw new InvalidExecutionContextException($"{typeof(Double1x4)}.M14"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double1x4(double x) + { + Double1x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double1x4 operator -(Double1x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Double1x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double1x4 operator +(Double1x4 left, Double1x4 right) => throw new InvalidExecutionContextException($"{nameof(Double1x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double1x4 operator /(Double1x4 left, Double1x4 right) => throw new InvalidExecutionContextException($"{nameof(Double1x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double1x4 operator *(Double1x4 left, Double1x4 right) => throw new InvalidExecutionContextException($"{nameof(Double1x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double1x4 operator -(Double1x4 left, Double1x4 right) => throw new InvalidExecutionContextException($"{nameof(Double1x4)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Double1x4(Double4 vector) => throw new InvalidExecutionContextException($"{typeof(Double1x4)}.{nameof(Double1x4)}({nameof(Double4)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 8)] + public partial struct Double2x1 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m21; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + public Double2x1(double m11, double m21) + { + this.m11 = m11; + this.m21 = m21; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref double this[int row] => throw new InvalidExecutionContextException($"{nameof(Double2x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double2x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double2x1)}.M21"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double2x1(double x) + { + Double2x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double2x1 operator -(Double2x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Double2x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double2x1 operator +(Double2x1 left, Double2x1 right) => throw new InvalidExecutionContextException($"{nameof(Double2x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double2x1 operator /(Double2x1 left, Double2x1 right) => throw new InvalidExecutionContextException($"{nameof(Double2x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double2x1 operator *(Double2x1 left, Double2x1 right) => throw new InvalidExecutionContextException($"{nameof(Double2x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double2x1 operator -(Double2x1 left, Double2x1 right) => throw new InvalidExecutionContextException($"{nameof(Double2x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Double2(Double2x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Double2x1)}.{nameof(Double2)}({nameof(Double2x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 8)] + public partial struct Double2x2 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m21; + + [FieldOffset(24)] + private double m22; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + public Double2x2(double m11, double m12, double m21, double m22) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Double2x2(Double2 row1, Double2 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double2x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double2x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double2x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double2x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref double M22 => throw new InvalidExecutionContextException($"{typeof(Double2x2)}.M22"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double2x2(double x) + { + Double2x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double2x2 operator -(Double2x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Double2x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double2x2 operator +(Double2x2 left, Double2x2 right) => throw new InvalidExecutionContextException($"{nameof(Double2x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double2x2 operator /(Double2x2 left, Double2x2 right) => throw new InvalidExecutionContextException($"{nameof(Double2x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double2x2 operator *(Double2x2 left, Double2x2 right) => throw new InvalidExecutionContextException($"{nameof(Double2x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double2x2 operator -(Double2x2 left, Double2x2 right) => throw new InvalidExecutionContextException($"{nameof(Double2x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 48, Pack = 8)] + public partial struct Double2x3 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m13; + + [FieldOffset(24)] + private double m21; + + [FieldOffset(32)] + private double m22; + + [FieldOffset(40)] + private double m23; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + public Double2x3(double m11, double m12, double m13, double m21, double m22, double m23) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Double2x3(Double3 row1, Double3 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double2x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double2x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double2x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref double M13 => throw new InvalidExecutionContextException($"{typeof(Double2x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double2x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref double M22 => throw new InvalidExecutionContextException($"{typeof(Double2x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref double M23 => throw new InvalidExecutionContextException($"{typeof(Double2x3)}.M23"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double2x3(double x) + { + Double2x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double2x3 operator -(Double2x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Double2x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double2x3 operator +(Double2x3 left, Double2x3 right) => throw new InvalidExecutionContextException($"{nameof(Double2x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double2x3 operator /(Double2x3 left, Double2x3 right) => throw new InvalidExecutionContextException($"{nameof(Double2x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double2x3 operator *(Double2x3 left, Double2x3 right) => throw new InvalidExecutionContextException($"{nameof(Double2x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double2x3 operator -(Double2x3 left, Double2x3 right) => throw new InvalidExecutionContextException($"{nameof(Double2x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 64, Pack = 8)] + public partial struct Double2x4 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m13; + + [FieldOffset(24)] + private double m14; + + [FieldOffset(32)] + private double m21; + + [FieldOffset(40)] + private double m22; + + [FieldOffset(48)] + private double m23; + + [FieldOffset(56)] + private double m24; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + public Double2x4(double m11, double m12, double m13, double m14, double m21, double m22, double m23, double m24) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Double2x4(Double4 row1, Double4 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double2x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double2x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double2x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref double M13 => throw new InvalidExecutionContextException($"{typeof(Double2x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref double M14 => throw new InvalidExecutionContextException($"{typeof(Double2x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double2x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref double M22 => throw new InvalidExecutionContextException($"{typeof(Double2x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref double M23 => throw new InvalidExecutionContextException($"{typeof(Double2x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref double M24 => throw new InvalidExecutionContextException($"{typeof(Double2x4)}.M24"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double2x4(double x) + { + Double2x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double2x4 operator -(Double2x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Double2x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double2x4 operator +(Double2x4 left, Double2x4 right) => throw new InvalidExecutionContextException($"{nameof(Double2x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double2x4 operator /(Double2x4 left, Double2x4 right) => throw new InvalidExecutionContextException($"{nameof(Double2x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double2x4 operator *(Double2x4 left, Double2x4 right) => throw new InvalidExecutionContextException($"{nameof(Double2x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double2x4 operator -(Double2x4 left, Double2x4 right) => throw new InvalidExecutionContextException($"{nameof(Double2x4)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 8)] + public partial struct Double3x1 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m21; + + [FieldOffset(16)] + private double m31; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [3, 1]. + public Double3x1(double m11, double m21, double m31) + { + this.m11 = m11; + this.m21 = m21; + this.m31 = m31; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref double this[int row] => throw new InvalidExecutionContextException($"{nameof(Double3x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double3x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double3x1)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref double M31 => throw new InvalidExecutionContextException($"{typeof(Double3x1)}.M31"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double3x1(double x) + { + Double3x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + matrix.m31 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double3x1 operator -(Double3x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Double3x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double3x1 operator +(Double3x1 left, Double3x1 right) => throw new InvalidExecutionContextException($"{nameof(Double3x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double3x1 operator /(Double3x1 left, Double3x1 right) => throw new InvalidExecutionContextException($"{nameof(Double3x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double3x1 operator *(Double3x1 left, Double3x1 right) => throw new InvalidExecutionContextException($"{nameof(Double3x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double3x1 operator -(Double3x1 left, Double3x1 right) => throw new InvalidExecutionContextException($"{nameof(Double3x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Double3(Double3x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Double3x1)}.{nameof(Double3)}({nameof(Double3x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 48, Pack = 8)] + public partial struct Double3x2 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m21; + + [FieldOffset(24)] + private double m22; + + [FieldOffset(32)] + private double m31; + + [FieldOffset(40)] + private double m32; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + public Double3x2(double m11, double m12, double m21, double m22, double m31, double m32) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + this.m31 = m31; + this.m32 = m32; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Double3x2(Double2 row1, Double2 row2, Double2 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m31 = row3.X; + this.m32 = row3.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double3x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double3x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double3x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double3x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref double M22 => throw new InvalidExecutionContextException($"{typeof(Double3x2)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref double M31 => throw new InvalidExecutionContextException($"{typeof(Double3x2)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref double M32 => throw new InvalidExecutionContextException($"{typeof(Double3x2)}.M32"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double3x2(double x) + { + Double3x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m31 = x; + matrix.m32 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double3x2 operator -(Double3x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Double3x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double3x2 operator +(Double3x2 left, Double3x2 right) => throw new InvalidExecutionContextException($"{nameof(Double3x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double3x2 operator /(Double3x2 left, Double3x2 right) => throw new InvalidExecutionContextException($"{nameof(Double3x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double3x2 operator *(Double3x2 left, Double3x2 right) => throw new InvalidExecutionContextException($"{nameof(Double3x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double3x2 operator -(Double3x2 left, Double3x2 right) => throw new InvalidExecutionContextException($"{nameof(Double3x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 72, Pack = 8)] + public partial struct Double3x3 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m13; + + [FieldOffset(24)] + private double m21; + + [FieldOffset(32)] + private double m22; + + [FieldOffset(40)] + private double m23; + + [FieldOffset(48)] + private double m31; + + [FieldOffset(56)] + private double m32; + + [FieldOffset(64)] + private double m33; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + public Double3x3(double m11, double m12, double m13, double m21, double m22, double m23, double m31, double m32, double m33) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Double3x3(Double3 row1, Double3 row2, Double3 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double3x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double3x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double3x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref double M13 => throw new InvalidExecutionContextException($"{typeof(Double3x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double3x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref double M22 => throw new InvalidExecutionContextException($"{typeof(Double3x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref double M23 => throw new InvalidExecutionContextException($"{typeof(Double3x3)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref double M31 => throw new InvalidExecutionContextException($"{typeof(Double3x3)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref double M32 => throw new InvalidExecutionContextException($"{typeof(Double3x3)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref double M33 => throw new InvalidExecutionContextException($"{typeof(Double3x3)}.M33"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double3x3(double x) + { + Double3x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double3x3 operator -(Double3x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Double3x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double3x3 operator +(Double3x3 left, Double3x3 right) => throw new InvalidExecutionContextException($"{nameof(Double3x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double3x3 operator /(Double3x3 left, Double3x3 right) => throw new InvalidExecutionContextException($"{nameof(Double3x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double3x3 operator *(Double3x3 left, Double3x3 right) => throw new InvalidExecutionContextException($"{nameof(Double3x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double3x3 operator -(Double3x3 left, Double3x3 right) => throw new InvalidExecutionContextException($"{nameof(Double3x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 96, Pack = 8)] + public partial struct Double3x4 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m13; + + [FieldOffset(24)] + private double m14; + + [FieldOffset(32)] + private double m21; + + [FieldOffset(40)] + private double m22; + + [FieldOffset(48)] + private double m23; + + [FieldOffset(56)] + private double m24; + + [FieldOffset(64)] + private double m31; + + [FieldOffset(72)] + private double m32; + + [FieldOffset(80)] + private double m33; + + [FieldOffset(88)] + private double m34; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [3, 4]. + public Double3x4(double m11, double m12, double m13, double m14, double m21, double m22, double m23, double m24, double m31, double m32, double m33, double m34) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m34 = m34; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Double3x4(Double4 row1, Double4 row2, Double4 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m34 = row3.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double3x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref double M13 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref double M14 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref double M22 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref double M23 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref double M24 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M24"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref double M31 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref double M32 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref double M33 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [3, 4]. + /// + public ref double M34 => throw new InvalidExecutionContextException($"{typeof(Double3x4)}.M34"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double3x4(double x) + { + Double3x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m34 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double3x4 operator -(Double3x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Double3x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double3x4 operator +(Double3x4 left, Double3x4 right) => throw new InvalidExecutionContextException($"{nameof(Double3x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double3x4 operator /(Double3x4 left, Double3x4 right) => throw new InvalidExecutionContextException($"{nameof(Double3x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double3x4 operator *(Double3x4 left, Double3x4 right) => throw new InvalidExecutionContextException($"{nameof(Double3x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double3x4 operator -(Double3x4 left, Double3x4 right) => throw new InvalidExecutionContextException($"{nameof(Double3x4)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 8)] + public partial struct Double4x1 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m21; + + [FieldOffset(16)] + private double m31; + + [FieldOffset(24)] + private double m41; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [4, 1]. + public Double4x1(double m11, double m21, double m31, double m41) + { + this.m11 = m11; + this.m21 = m21; + this.m31 = m31; + this.m41 = m41; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref double this[int row] => throw new InvalidExecutionContextException($"{nameof(Double4x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double4x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double4x1)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref double M31 => throw new InvalidExecutionContextException($"{typeof(Double4x1)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref double M41 => throw new InvalidExecutionContextException($"{typeof(Double4x1)}.M41"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double4x1(double x) + { + Double4x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + matrix.m31 = x; + matrix.m41 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double4x1 operator -(Double4x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Double4x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double4x1 operator +(Double4x1 left, Double4x1 right) => throw new InvalidExecutionContextException($"{nameof(Double4x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double4x1 operator /(Double4x1 left, Double4x1 right) => throw new InvalidExecutionContextException($"{nameof(Double4x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double4x1 operator *(Double4x1 left, Double4x1 right) => throw new InvalidExecutionContextException($"{nameof(Double4x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double4x1 operator -(Double4x1 left, Double4x1 right) => throw new InvalidExecutionContextException($"{nameof(Double4x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Double4(Double4x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Double4x1)}.{nameof(Double4)}({nameof(Double4x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 64, Pack = 8)] + public partial struct Double4x2 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m21; + + [FieldOffset(24)] + private double m22; + + [FieldOffset(32)] + private double m31; + + [FieldOffset(40)] + private double m32; + + [FieldOffset(48)] + private double m41; + + [FieldOffset(56)] + private double m42; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + public Double4x2(double m11, double m12, double m21, double m22, double m31, double m32, double m41, double m42) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + this.m31 = m31; + this.m32 = m32; + this.m41 = m41; + this.m42 = m42; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Double4x2(Double2 row1, Double2 row2, Double2 row3, Double2 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m41 = row4.X; + this.m42 = row4.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double4x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double4x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double4x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double4x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref double M22 => throw new InvalidExecutionContextException($"{typeof(Double4x2)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref double M31 => throw new InvalidExecutionContextException($"{typeof(Double4x2)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref double M32 => throw new InvalidExecutionContextException($"{typeof(Double4x2)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref double M41 => throw new InvalidExecutionContextException($"{typeof(Double4x2)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref double M42 => throw new InvalidExecutionContextException($"{typeof(Double4x2)}.M42"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double4x2(double x) + { + Double4x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m41 = x; + matrix.m42 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double4x2 operator -(Double4x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Double4x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double4x2 operator +(Double4x2 left, Double4x2 right) => throw new InvalidExecutionContextException($"{nameof(Double4x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double4x2 operator /(Double4x2 left, Double4x2 right) => throw new InvalidExecutionContextException($"{nameof(Double4x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double4x2 operator *(Double4x2 left, Double4x2 right) => throw new InvalidExecutionContextException($"{nameof(Double4x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double4x2 operator -(Double4x2 left, Double4x2 right) => throw new InvalidExecutionContextException($"{nameof(Double4x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 96, Pack = 8)] + public partial struct Double4x3 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m13; + + [FieldOffset(24)] + private double m21; + + [FieldOffset(32)] + private double m22; + + [FieldOffset(40)] + private double m23; + + [FieldOffset(48)] + private double m31; + + [FieldOffset(56)] + private double m32; + + [FieldOffset(64)] + private double m33; + + [FieldOffset(72)] + private double m41; + + [FieldOffset(80)] + private double m42; + + [FieldOffset(88)] + private double m43; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + /// The value to assign to the component at position [4, 3]. + public Double4x3(double m11, double m12, double m13, double m21, double m22, double m23, double m31, double m32, double m33, double m41, double m42, double m43) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m41 = m41; + this.m42 = m42; + this.m43 = m43; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Double4x3(Double3 row1, Double3 row2, Double3 row3, Double3 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m41 = row4.X; + this.m42 = row4.Y; + this.m43 = row4.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double4x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref double M13 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref double M22 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref double M23 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref double M31 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref double M32 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref double M33 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref double M41 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref double M42 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M42"); + + /// + /// Gets a reference to the value representing the component at position [4, 3]. + /// + public ref double M43 => throw new InvalidExecutionContextException($"{typeof(Double4x3)}.M43"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double4x3(double x) + { + Double4x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m41 = x; + matrix.m42 = x; + matrix.m43 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double4x3 operator -(Double4x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Double4x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double4x3 operator +(Double4x3 left, Double4x3 right) => throw new InvalidExecutionContextException($"{nameof(Double4x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double4x3 operator /(Double4x3 left, Double4x3 right) => throw new InvalidExecutionContextException($"{nameof(Double4x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double4x3 operator *(Double4x3 left, Double4x3 right) => throw new InvalidExecutionContextException($"{nameof(Double4x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double4x3 operator -(Double4x3 left, Double4x3 right) => throw new InvalidExecutionContextException($"{nameof(Double4x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 128, Pack = 8)] + public partial struct Double4x4 + { + [FieldOffset(0)] + private double m11; + + [FieldOffset(8)] + private double m12; + + [FieldOffset(16)] + private double m13; + + [FieldOffset(24)] + private double m14; + + [FieldOffset(32)] + private double m21; + + [FieldOffset(40)] + private double m22; + + [FieldOffset(48)] + private double m23; + + [FieldOffset(56)] + private double m24; + + [FieldOffset(64)] + private double m31; + + [FieldOffset(72)] + private double m32; + + [FieldOffset(80)] + private double m33; + + [FieldOffset(88)] + private double m34; + + [FieldOffset(96)] + private double m41; + + [FieldOffset(104)] + private double m42; + + [FieldOffset(112)] + private double m43; + + [FieldOffset(120)] + private double m44; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [3, 4]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + /// The value to assign to the component at position [4, 3]. + /// The value to assign to the component at position [4, 4]. + public Double4x4(double m11, double m12, double m13, double m14, double m21, double m22, double m23, double m24, double m31, double m32, double m33, double m34, double m41, double m42, double m43, double m44) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m34 = m34; + this.m41 = m41; + this.m42 = m42; + this.m43 = m43; + this.m44 = m44; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Double4x4(Double4 row1, Double4 row2, Double4 row3, Double4 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m34 = row3.W; + this.m41 = row4.X; + this.m42 = row4.Y; + this.m43 = row4.Z; + this.m44 = row4.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Double4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Double4x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Double2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Double4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Double3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Double4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Double4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Double4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref double M11 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref double M12 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref double M13 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref double M14 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref double M21 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref double M22 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref double M23 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref double M24 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M24"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref double M31 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref double M32 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref double M33 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [3, 4]. + /// + public ref double M34 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M34"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref double M41 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref double M42 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M42"); + + /// + /// Gets a reference to the value representing the component at position [4, 3]. + /// + public ref double M43 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M43"); + + /// + /// Gets a reference to the value representing the component at position [4, 4]. + /// + public ref double M44 => throw new InvalidExecutionContextException($"{typeof(Double4x4)}.M44"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Double4x4(double x) + { + Double4x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m34 = x; + matrix.m41 = x; + matrix.m42 = x; + matrix.m43 = x; + matrix.m44 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Double4x4 operator -(Double4x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Double4x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Double4x4 operator +(Double4x4 left, Double4x4 right) => throw new InvalidExecutionContextException($"{nameof(Double4x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Double4x4 operator /(Double4x4 left, Double4x4 right) => throw new InvalidExecutionContextException($"{nameof(Double4x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Double4x4 operator *(Double4x4 left, Double4x4 right) => throw new InvalidExecutionContextException($"{nameof(Double4x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Double4x4 operator -(Double4x4 left, Double4x4 right) => throw new InvalidExecutionContextException($"{nameof(Double4x4)}.-"); + } +} diff --git a/src/ComputeSharp/Core/Primitives/Double/DoubleMxN.tt b/src/ComputeSharp/Core/Primitives/Double/DoubleMxN.tt new file mode 100644 index 00000000..6ecc4f82 --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/Double/DoubleMxN.tt @@ -0,0 +1,4 @@ +<#@include file="..\MatrixType.ttinclude" #> +<# +GenerateAllMatrixProperties("Double", sizeof(double)); +#> \ No newline at end of file diff --git a/src/ComputeSharp/Core/Primitives/Float/Float2.g.cs b/src/ComputeSharp/Core/Primitives/Float/Float2.g.cs index 16b5b8a3..c291ece6 100644 --- a/src/ComputeSharp/Core/Primitives/Float/Float2.g.cs +++ b/src/ComputeSharp/Core/Primitives/Float/Float2.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 8)] + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] public partial struct Float2 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Float/Float3.g.cs b/src/ComputeSharp/Core/Primitives/Float/Float3.g.cs index ba71cb65..aee2eb71 100644 --- a/src/ComputeSharp/Core/Primitives/Float/Float3.g.cs +++ b/src/ComputeSharp/Core/Primitives/Float/Float3.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 12)] + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] public partial struct Float3 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Float/Float4.g.cs b/src/ComputeSharp/Core/Primitives/Float/Float4.g.cs index 495a9154..c1aefc70 100644 --- a/src/ComputeSharp/Core/Primitives/Float/Float4.g.cs +++ b/src/ComputeSharp/Core/Primitives/Float/Float4.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 16)] + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] public partial struct Float4 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Float/FloatMxN.g.cs b/src/ComputeSharp/Core/Primitives/Float/FloatMxN.g.cs new file mode 100644 index 00000000..889e0435 --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/Float/FloatMxN.g.cs @@ -0,0 +1,2720 @@ +using System.Runtime.InteropServices; +using ComputeSharp.Exceptions; + +namespace ComputeSharp +{ + /// + [StructLayout(LayoutKind.Explicit, Size = 4, Pack = 4)] + public partial struct Float1x1 + { + [FieldOffset(0)] + private float m11; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + public Float1x1(float m11) + { + this.m11 = m11; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref float this[int row] => throw new InvalidExecutionContextException($"{nameof(Float1x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float1x1)}.M11"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float1x1(float x) + { + Float1x1 matrix; + + matrix.m11 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float1x1 operator -(Float1x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Float1x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float1x1 operator +(Float1x1 left, Float1x1 right) => throw new InvalidExecutionContextException($"{nameof(Float1x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float1x1 operator /(Float1x1 left, Float1x1 right) => throw new InvalidExecutionContextException($"{nameof(Float1x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float1x1 operator *(Float1x1 left, Float1x1 right) => throw new InvalidExecutionContextException($"{nameof(Float1x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float1x1 operator -(Float1x1 left, Float1x1 right) => throw new InvalidExecutionContextException($"{nameof(Float1x1)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] + public partial struct Float1x2 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + public Float1x2(float m11, float m12) + { + this.m11 = m11; + this.m12 = m12; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float1x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float1x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float1x2)}.M12"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float1x2(float x) + { + Float1x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float1x2 operator -(Float1x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Float1x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float1x2 operator +(Float1x2 left, Float1x2 right) => throw new InvalidExecutionContextException($"{nameof(Float1x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float1x2 operator /(Float1x2 left, Float1x2 right) => throw new InvalidExecutionContextException($"{nameof(Float1x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float1x2 operator *(Float1x2 left, Float1x2 right) => throw new InvalidExecutionContextException($"{nameof(Float1x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float1x2 operator -(Float1x2 left, Float1x2 right) => throw new InvalidExecutionContextException($"{nameof(Float1x2)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Float1x2(Float2 vector) => throw new InvalidExecutionContextException($"{typeof(Float1x2)}.{nameof(Float1x2)}({nameof(Float2)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] + public partial struct Float1x3 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m13; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + public Float1x3(float m11, float m12, float m13) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float1x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float1x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float1x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref float M13 => throw new InvalidExecutionContextException($"{typeof(Float1x3)}.M13"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float1x3(float x) + { + Float1x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float1x3 operator -(Float1x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Float1x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float1x3 operator +(Float1x3 left, Float1x3 right) => throw new InvalidExecutionContextException($"{nameof(Float1x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float1x3 operator /(Float1x3 left, Float1x3 right) => throw new InvalidExecutionContextException($"{nameof(Float1x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float1x3 operator *(Float1x3 left, Float1x3 right) => throw new InvalidExecutionContextException($"{nameof(Float1x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float1x3 operator -(Float1x3 left, Float1x3 right) => throw new InvalidExecutionContextException($"{nameof(Float1x3)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Float1x3(Float3 vector) => throw new InvalidExecutionContextException($"{typeof(Float1x3)}.{nameof(Float1x3)}({nameof(Float3)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct Float1x4 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m13; + + [FieldOffset(12)] + private float m14; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + public Float1x4(float m11, float m12, float m13, float m14) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float1x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float1x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float1x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref float M13 => throw new InvalidExecutionContextException($"{typeof(Float1x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref float M14 => throw new InvalidExecutionContextException($"{typeof(Float1x4)}.M14"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float1x4(float x) + { + Float1x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float1x4 operator -(Float1x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Float1x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float1x4 operator +(Float1x4 left, Float1x4 right) => throw new InvalidExecutionContextException($"{nameof(Float1x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float1x4 operator /(Float1x4 left, Float1x4 right) => throw new InvalidExecutionContextException($"{nameof(Float1x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float1x4 operator *(Float1x4 left, Float1x4 right) => throw new InvalidExecutionContextException($"{nameof(Float1x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float1x4 operator -(Float1x4 left, Float1x4 right) => throw new InvalidExecutionContextException($"{nameof(Float1x4)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Float1x4(Float4 vector) => throw new InvalidExecutionContextException($"{typeof(Float1x4)}.{nameof(Float1x4)}({nameof(Float4)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] + public partial struct Float2x1 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m21; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + public Float2x1(float m11, float m21) + { + this.m11 = m11; + this.m21 = m21; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref float this[int row] => throw new InvalidExecutionContextException($"{nameof(Float2x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float2x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float2x1)}.M21"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float2x1(float x) + { + Float2x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float2x1 operator -(Float2x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Float2x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float2x1 operator +(Float2x1 left, Float2x1 right) => throw new InvalidExecutionContextException($"{nameof(Float2x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float2x1 operator /(Float2x1 left, Float2x1 right) => throw new InvalidExecutionContextException($"{nameof(Float2x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float2x1 operator *(Float2x1 left, Float2x1 right) => throw new InvalidExecutionContextException($"{nameof(Float2x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float2x1 operator -(Float2x1 left, Float2x1 right) => throw new InvalidExecutionContextException($"{nameof(Float2x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Float2(Float2x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Float2x1)}.{nameof(Float2)}({nameof(Float2x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct Float2x2 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m21; + + [FieldOffset(12)] + private float m22; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + public Float2x2(float m11, float m12, float m21, float m22) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Float2x2(Float2 row1, Float2 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float2x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float2x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float2x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float2x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref float M22 => throw new InvalidExecutionContextException($"{typeof(Float2x2)}.M22"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float2x2(float x) + { + Float2x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float2x2 operator -(Float2x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Float2x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float2x2 operator +(Float2x2 left, Float2x2 right) => throw new InvalidExecutionContextException($"{nameof(Float2x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float2x2 operator /(Float2x2 left, Float2x2 right) => throw new InvalidExecutionContextException($"{nameof(Float2x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float2x2 operator *(Float2x2 left, Float2x2 right) => throw new InvalidExecutionContextException($"{nameof(Float2x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float2x2 operator -(Float2x2 left, Float2x2 right) => throw new InvalidExecutionContextException($"{nameof(Float2x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 4)] + public partial struct Float2x3 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m13; + + [FieldOffset(12)] + private float m21; + + [FieldOffset(16)] + private float m22; + + [FieldOffset(20)] + private float m23; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + public Float2x3(float m11, float m12, float m13, float m21, float m22, float m23) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Float2x3(Float3 row1, Float3 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float2x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float2x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float2x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref float M13 => throw new InvalidExecutionContextException($"{typeof(Float2x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float2x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref float M22 => throw new InvalidExecutionContextException($"{typeof(Float2x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref float M23 => throw new InvalidExecutionContextException($"{typeof(Float2x3)}.M23"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float2x3(float x) + { + Float2x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float2x3 operator -(Float2x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Float2x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float2x3 operator +(Float2x3 left, Float2x3 right) => throw new InvalidExecutionContextException($"{nameof(Float2x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float2x3 operator /(Float2x3 left, Float2x3 right) => throw new InvalidExecutionContextException($"{nameof(Float2x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float2x3 operator *(Float2x3 left, Float2x3 right) => throw new InvalidExecutionContextException($"{nameof(Float2x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float2x3 operator -(Float2x3 left, Float2x3 right) => throw new InvalidExecutionContextException($"{nameof(Float2x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 4)] + public partial struct Float2x4 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m13; + + [FieldOffset(12)] + private float m14; + + [FieldOffset(16)] + private float m21; + + [FieldOffset(20)] + private float m22; + + [FieldOffset(24)] + private float m23; + + [FieldOffset(28)] + private float m24; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + public Float2x4(float m11, float m12, float m13, float m14, float m21, float m22, float m23, float m24) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Float2x4(Float4 row1, Float4 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float2x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float2x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float2x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref float M13 => throw new InvalidExecutionContextException($"{typeof(Float2x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref float M14 => throw new InvalidExecutionContextException($"{typeof(Float2x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float2x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref float M22 => throw new InvalidExecutionContextException($"{typeof(Float2x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref float M23 => throw new InvalidExecutionContextException($"{typeof(Float2x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref float M24 => throw new InvalidExecutionContextException($"{typeof(Float2x4)}.M24"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float2x4(float x) + { + Float2x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float2x4 operator -(Float2x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Float2x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float2x4 operator +(Float2x4 left, Float2x4 right) => throw new InvalidExecutionContextException($"{nameof(Float2x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float2x4 operator /(Float2x4 left, Float2x4 right) => throw new InvalidExecutionContextException($"{nameof(Float2x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float2x4 operator *(Float2x4 left, Float2x4 right) => throw new InvalidExecutionContextException($"{nameof(Float2x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float2x4 operator -(Float2x4 left, Float2x4 right) => throw new InvalidExecutionContextException($"{nameof(Float2x4)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] + public partial struct Float3x1 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m21; + + [FieldOffset(8)] + private float m31; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [3, 1]. + public Float3x1(float m11, float m21, float m31) + { + this.m11 = m11; + this.m21 = m21; + this.m31 = m31; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref float this[int row] => throw new InvalidExecutionContextException($"{nameof(Float3x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float3x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float3x1)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref float M31 => throw new InvalidExecutionContextException($"{typeof(Float3x1)}.M31"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float3x1(float x) + { + Float3x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + matrix.m31 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float3x1 operator -(Float3x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Float3x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float3x1 operator +(Float3x1 left, Float3x1 right) => throw new InvalidExecutionContextException($"{nameof(Float3x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float3x1 operator /(Float3x1 left, Float3x1 right) => throw new InvalidExecutionContextException($"{nameof(Float3x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float3x1 operator *(Float3x1 left, Float3x1 right) => throw new InvalidExecutionContextException($"{nameof(Float3x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float3x1 operator -(Float3x1 left, Float3x1 right) => throw new InvalidExecutionContextException($"{nameof(Float3x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Float3(Float3x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Float3x1)}.{nameof(Float3)}({nameof(Float3x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 4)] + public partial struct Float3x2 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m21; + + [FieldOffset(12)] + private float m22; + + [FieldOffset(16)] + private float m31; + + [FieldOffset(20)] + private float m32; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + public Float3x2(float m11, float m12, float m21, float m22, float m31, float m32) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + this.m31 = m31; + this.m32 = m32; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Float3x2(Float2 row1, Float2 row2, Float2 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m31 = row3.X; + this.m32 = row3.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float3x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float3x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float3x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float3x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref float M22 => throw new InvalidExecutionContextException($"{typeof(Float3x2)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref float M31 => throw new InvalidExecutionContextException($"{typeof(Float3x2)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref float M32 => throw new InvalidExecutionContextException($"{typeof(Float3x2)}.M32"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float3x2(float x) + { + Float3x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m31 = x; + matrix.m32 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float3x2 operator -(Float3x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Float3x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float3x2 operator +(Float3x2 left, Float3x2 right) => throw new InvalidExecutionContextException($"{nameof(Float3x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float3x2 operator /(Float3x2 left, Float3x2 right) => throw new InvalidExecutionContextException($"{nameof(Float3x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float3x2 operator *(Float3x2 left, Float3x2 right) => throw new InvalidExecutionContextException($"{nameof(Float3x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float3x2 operator -(Float3x2 left, Float3x2 right) => throw new InvalidExecutionContextException($"{nameof(Float3x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 36, Pack = 4)] + public partial struct Float3x3 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m13; + + [FieldOffset(12)] + private float m21; + + [FieldOffset(16)] + private float m22; + + [FieldOffset(20)] + private float m23; + + [FieldOffset(24)] + private float m31; + + [FieldOffset(28)] + private float m32; + + [FieldOffset(32)] + private float m33; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + public Float3x3(float m11, float m12, float m13, float m21, float m22, float m23, float m31, float m32, float m33) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Float3x3(Float3 row1, Float3 row2, Float3 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float3x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float3x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float3x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref float M13 => throw new InvalidExecutionContextException($"{typeof(Float3x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float3x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref float M22 => throw new InvalidExecutionContextException($"{typeof(Float3x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref float M23 => throw new InvalidExecutionContextException($"{typeof(Float3x3)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref float M31 => throw new InvalidExecutionContextException($"{typeof(Float3x3)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref float M32 => throw new InvalidExecutionContextException($"{typeof(Float3x3)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref float M33 => throw new InvalidExecutionContextException($"{typeof(Float3x3)}.M33"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float3x3(float x) + { + Float3x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float3x3 operator -(Float3x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Float3x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float3x3 operator +(Float3x3 left, Float3x3 right) => throw new InvalidExecutionContextException($"{nameof(Float3x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float3x3 operator /(Float3x3 left, Float3x3 right) => throw new InvalidExecutionContextException($"{nameof(Float3x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float3x3 operator *(Float3x3 left, Float3x3 right) => throw new InvalidExecutionContextException($"{nameof(Float3x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float3x3 operator -(Float3x3 left, Float3x3 right) => throw new InvalidExecutionContextException($"{nameof(Float3x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 48, Pack = 4)] + public partial struct Float3x4 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m13; + + [FieldOffset(12)] + private float m14; + + [FieldOffset(16)] + private float m21; + + [FieldOffset(20)] + private float m22; + + [FieldOffset(24)] + private float m23; + + [FieldOffset(28)] + private float m24; + + [FieldOffset(32)] + private float m31; + + [FieldOffset(36)] + private float m32; + + [FieldOffset(40)] + private float m33; + + [FieldOffset(44)] + private float m34; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [3, 4]. + public Float3x4(float m11, float m12, float m13, float m14, float m21, float m22, float m23, float m24, float m31, float m32, float m33, float m34) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m34 = m34; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Float3x4(Float4 row1, Float4 row2, Float4 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m34 = row3.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float3x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref float M13 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref float M14 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref float M22 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref float M23 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref float M24 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M24"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref float M31 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref float M32 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref float M33 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [3, 4]. + /// + public ref float M34 => throw new InvalidExecutionContextException($"{typeof(Float3x4)}.M34"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float3x4(float x) + { + Float3x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m34 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float3x4 operator -(Float3x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Float3x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float3x4 operator +(Float3x4 left, Float3x4 right) => throw new InvalidExecutionContextException($"{nameof(Float3x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float3x4 operator /(Float3x4 left, Float3x4 right) => throw new InvalidExecutionContextException($"{nameof(Float3x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float3x4 operator *(Float3x4 left, Float3x4 right) => throw new InvalidExecutionContextException($"{nameof(Float3x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float3x4 operator -(Float3x4 left, Float3x4 right) => throw new InvalidExecutionContextException($"{nameof(Float3x4)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct Float4x1 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m21; + + [FieldOffset(8)] + private float m31; + + [FieldOffset(12)] + private float m41; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [4, 1]. + public Float4x1(float m11, float m21, float m31, float m41) + { + this.m11 = m11; + this.m21 = m21; + this.m31 = m31; + this.m41 = m41; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref float this[int row] => throw new InvalidExecutionContextException($"{nameof(Float4x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float4x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float4x1)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref float M31 => throw new InvalidExecutionContextException($"{typeof(Float4x1)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref float M41 => throw new InvalidExecutionContextException($"{typeof(Float4x1)}.M41"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float4x1(float x) + { + Float4x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + matrix.m31 = x; + matrix.m41 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float4x1 operator -(Float4x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Float4x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float4x1 operator +(Float4x1 left, Float4x1 right) => throw new InvalidExecutionContextException($"{nameof(Float4x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float4x1 operator /(Float4x1 left, Float4x1 right) => throw new InvalidExecutionContextException($"{nameof(Float4x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float4x1 operator *(Float4x1 left, Float4x1 right) => throw new InvalidExecutionContextException($"{nameof(Float4x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float4x1 operator -(Float4x1 left, Float4x1 right) => throw new InvalidExecutionContextException($"{nameof(Float4x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Float4(Float4x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Float4x1)}.{nameof(Float4)}({nameof(Float4x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 4)] + public partial struct Float4x2 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m21; + + [FieldOffset(12)] + private float m22; + + [FieldOffset(16)] + private float m31; + + [FieldOffset(20)] + private float m32; + + [FieldOffset(24)] + private float m41; + + [FieldOffset(28)] + private float m42; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + public Float4x2(float m11, float m12, float m21, float m22, float m31, float m32, float m41, float m42) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + this.m31 = m31; + this.m32 = m32; + this.m41 = m41; + this.m42 = m42; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Float4x2(Float2 row1, Float2 row2, Float2 row3, Float2 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m41 = row4.X; + this.m42 = row4.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float4x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float4x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float4x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float4x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref float M22 => throw new InvalidExecutionContextException($"{typeof(Float4x2)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref float M31 => throw new InvalidExecutionContextException($"{typeof(Float4x2)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref float M32 => throw new InvalidExecutionContextException($"{typeof(Float4x2)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref float M41 => throw new InvalidExecutionContextException($"{typeof(Float4x2)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref float M42 => throw new InvalidExecutionContextException($"{typeof(Float4x2)}.M42"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float4x2(float x) + { + Float4x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m41 = x; + matrix.m42 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float4x2 operator -(Float4x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Float4x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float4x2 operator +(Float4x2 left, Float4x2 right) => throw new InvalidExecutionContextException($"{nameof(Float4x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float4x2 operator /(Float4x2 left, Float4x2 right) => throw new InvalidExecutionContextException($"{nameof(Float4x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float4x2 operator *(Float4x2 left, Float4x2 right) => throw new InvalidExecutionContextException($"{nameof(Float4x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float4x2 operator -(Float4x2 left, Float4x2 right) => throw new InvalidExecutionContextException($"{nameof(Float4x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 48, Pack = 4)] + public partial struct Float4x3 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m13; + + [FieldOffset(12)] + private float m21; + + [FieldOffset(16)] + private float m22; + + [FieldOffset(20)] + private float m23; + + [FieldOffset(24)] + private float m31; + + [FieldOffset(28)] + private float m32; + + [FieldOffset(32)] + private float m33; + + [FieldOffset(36)] + private float m41; + + [FieldOffset(40)] + private float m42; + + [FieldOffset(44)] + private float m43; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + /// The value to assign to the component at position [4, 3]. + public Float4x3(float m11, float m12, float m13, float m21, float m22, float m23, float m31, float m32, float m33, float m41, float m42, float m43) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m41 = m41; + this.m42 = m42; + this.m43 = m43; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Float4x3(Float3 row1, Float3 row2, Float3 row3, Float3 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m41 = row4.X; + this.m42 = row4.Y; + this.m43 = row4.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float4x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref float M13 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref float M22 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref float M23 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref float M31 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref float M32 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref float M33 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref float M41 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref float M42 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M42"); + + /// + /// Gets a reference to the value representing the component at position [4, 3]. + /// + public ref float M43 => throw new InvalidExecutionContextException($"{typeof(Float4x3)}.M43"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float4x3(float x) + { + Float4x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m41 = x; + matrix.m42 = x; + matrix.m43 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float4x3 operator -(Float4x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Float4x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float4x3 operator +(Float4x3 left, Float4x3 right) => throw new InvalidExecutionContextException($"{nameof(Float4x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float4x3 operator /(Float4x3 left, Float4x3 right) => throw new InvalidExecutionContextException($"{nameof(Float4x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float4x3 operator *(Float4x3 left, Float4x3 right) => throw new InvalidExecutionContextException($"{nameof(Float4x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float4x3 operator -(Float4x3 left, Float4x3 right) => throw new InvalidExecutionContextException($"{nameof(Float4x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 64, Pack = 4)] + public partial struct Float4x4 + { + [FieldOffset(0)] + private float m11; + + [FieldOffset(4)] + private float m12; + + [FieldOffset(8)] + private float m13; + + [FieldOffset(12)] + private float m14; + + [FieldOffset(16)] + private float m21; + + [FieldOffset(20)] + private float m22; + + [FieldOffset(24)] + private float m23; + + [FieldOffset(28)] + private float m24; + + [FieldOffset(32)] + private float m31; + + [FieldOffset(36)] + private float m32; + + [FieldOffset(40)] + private float m33; + + [FieldOffset(44)] + private float m34; + + [FieldOffset(48)] + private float m41; + + [FieldOffset(52)] + private float m42; + + [FieldOffset(56)] + private float m43; + + [FieldOffset(60)] + private float m44; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [3, 4]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + /// The value to assign to the component at position [4, 3]. + /// The value to assign to the component at position [4, 4]. + public Float4x4(float m11, float m12, float m13, float m14, float m21, float m22, float m23, float m24, float m31, float m32, float m33, float m34, float m41, float m42, float m43, float m44) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m34 = m34; + this.m41 = m41; + this.m42 = m42; + this.m43 = m43; + this.m44 = m44; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Float4x4(Float4 row1, Float4 row2, Float4 row3, Float4 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m34 = row3.W; + this.m41 = row4.X; + this.m42 = row4.Y; + this.m43 = row4.Z; + this.m44 = row4.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Float4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Float4x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Float2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Float4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Float3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Float4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Float4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Float4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref float M11 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref float M12 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref float M13 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref float M14 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref float M21 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref float M22 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref float M23 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref float M24 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M24"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref float M31 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref float M32 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref float M33 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [3, 4]. + /// + public ref float M34 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M34"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref float M41 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref float M42 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M42"); + + /// + /// Gets a reference to the value representing the component at position [4, 3]. + /// + public ref float M43 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M43"); + + /// + /// Gets a reference to the value representing the component at position [4, 4]. + /// + public ref float M44 => throw new InvalidExecutionContextException($"{typeof(Float4x4)}.M44"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Float4x4(float x) + { + Float4x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m34 = x; + matrix.m41 = x; + matrix.m42 = x; + matrix.m43 = x; + matrix.m44 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Float4x4 operator -(Float4x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Float4x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Float4x4 operator +(Float4x4 left, Float4x4 right) => throw new InvalidExecutionContextException($"{nameof(Float4x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Float4x4 operator /(Float4x4 left, Float4x4 right) => throw new InvalidExecutionContextException($"{nameof(Float4x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Float4x4 operator *(Float4x4 left, Float4x4 right) => throw new InvalidExecutionContextException($"{nameof(Float4x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Float4x4 operator -(Float4x4 left, Float4x4 right) => throw new InvalidExecutionContextException($"{nameof(Float4x4)}.-"); + } +} diff --git a/src/ComputeSharp/Core/Primitives/Float/FloatMxN.tt b/src/ComputeSharp/Core/Primitives/Float/FloatMxN.tt new file mode 100644 index 00000000..97755751 --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/Float/FloatMxN.tt @@ -0,0 +1,4 @@ +<#@include file="..\MatrixType.ttinclude" #> +<# +GenerateAllMatrixProperties("Float", sizeof(float)); +#> \ No newline at end of file diff --git a/src/ComputeSharp/Core/Primitives/Int/Int2.g.cs b/src/ComputeSharp/Core/Primitives/Int/Int2.g.cs index 30fce220..a2c58948 100644 --- a/src/ComputeSharp/Core/Primitives/Int/Int2.g.cs +++ b/src/ComputeSharp/Core/Primitives/Int/Int2.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 8)] + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] public partial struct Int2 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Int/Int3.g.cs b/src/ComputeSharp/Core/Primitives/Int/Int3.g.cs index e8d79566..9378ed8b 100644 --- a/src/ComputeSharp/Core/Primitives/Int/Int3.g.cs +++ b/src/ComputeSharp/Core/Primitives/Int/Int3.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 12)] + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] public partial struct Int3 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Int/Int4.g.cs b/src/ComputeSharp/Core/Primitives/Int/Int4.g.cs index 3040778b..c4a2f3fc 100644 --- a/src/ComputeSharp/Core/Primitives/Int/Int4.g.cs +++ b/src/ComputeSharp/Core/Primitives/Int/Int4.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 16)] + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] public partial struct Int4 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/Int/IntMxN.g.cs b/src/ComputeSharp/Core/Primitives/Int/IntMxN.g.cs new file mode 100644 index 00000000..48156d86 --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/Int/IntMxN.g.cs @@ -0,0 +1,2720 @@ +using System.Runtime.InteropServices; +using ComputeSharp.Exceptions; + +namespace ComputeSharp +{ + /// + [StructLayout(LayoutKind.Explicit, Size = 4, Pack = 4)] + public partial struct Int1x1 + { + [FieldOffset(0)] + private int m11; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + public Int1x1(int m11) + { + this.m11 = m11; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref int this[int row] => throw new InvalidExecutionContextException($"{nameof(Int1x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int1x1)}.M11"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int1x1(int x) + { + Int1x1 matrix; + + matrix.m11 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int1x1 operator -(Int1x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Int1x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int1x1 operator +(Int1x1 left, Int1x1 right) => throw new InvalidExecutionContextException($"{nameof(Int1x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int1x1 operator /(Int1x1 left, Int1x1 right) => throw new InvalidExecutionContextException($"{nameof(Int1x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int1x1 operator *(Int1x1 left, Int1x1 right) => throw new InvalidExecutionContextException($"{nameof(Int1x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int1x1 operator -(Int1x1 left, Int1x1 right) => throw new InvalidExecutionContextException($"{nameof(Int1x1)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] + public partial struct Int1x2 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + public Int1x2(int m11, int m12) + { + this.m11 = m11; + this.m12 = m12; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int1x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int1x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int1x2)}.M12"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int1x2(int x) + { + Int1x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int1x2 operator -(Int1x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Int1x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int1x2 operator +(Int1x2 left, Int1x2 right) => throw new InvalidExecutionContextException($"{nameof(Int1x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int1x2 operator /(Int1x2 left, Int1x2 right) => throw new InvalidExecutionContextException($"{nameof(Int1x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int1x2 operator *(Int1x2 left, Int1x2 right) => throw new InvalidExecutionContextException($"{nameof(Int1x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int1x2 operator -(Int1x2 left, Int1x2 right) => throw new InvalidExecutionContextException($"{nameof(Int1x2)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Int1x2(Int2 vector) => throw new InvalidExecutionContextException($"{typeof(Int1x2)}.{nameof(Int1x2)}({nameof(Int2)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] + public partial struct Int1x3 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m13; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + public Int1x3(int m11, int m12, int m13) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int1x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int1x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int1x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref int M13 => throw new InvalidExecutionContextException($"{typeof(Int1x3)}.M13"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int1x3(int x) + { + Int1x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int1x3 operator -(Int1x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Int1x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int1x3 operator +(Int1x3 left, Int1x3 right) => throw new InvalidExecutionContextException($"{nameof(Int1x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int1x3 operator /(Int1x3 left, Int1x3 right) => throw new InvalidExecutionContextException($"{nameof(Int1x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int1x3 operator *(Int1x3 left, Int1x3 right) => throw new InvalidExecutionContextException($"{nameof(Int1x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int1x3 operator -(Int1x3 left, Int1x3 right) => throw new InvalidExecutionContextException($"{nameof(Int1x3)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Int1x3(Int3 vector) => throw new InvalidExecutionContextException($"{typeof(Int1x3)}.{nameof(Int1x3)}({nameof(Int3)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct Int1x4 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m13; + + [FieldOffset(12)] + private int m14; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + public Int1x4(int m11, int m12, int m13, int m14) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int1x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int1x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int1x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref int M13 => throw new InvalidExecutionContextException($"{typeof(Int1x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref int M14 => throw new InvalidExecutionContextException($"{typeof(Int1x4)}.M14"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int1x4(int x) + { + Int1x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int1x4 operator -(Int1x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Int1x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int1x4 operator +(Int1x4 left, Int1x4 right) => throw new InvalidExecutionContextException($"{nameof(Int1x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int1x4 operator /(Int1x4 left, Int1x4 right) => throw new InvalidExecutionContextException($"{nameof(Int1x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int1x4 operator *(Int1x4 left, Int1x4 right) => throw new InvalidExecutionContextException($"{nameof(Int1x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int1x4 operator -(Int1x4 left, Int1x4 right) => throw new InvalidExecutionContextException($"{nameof(Int1x4)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Int1x4(Int4 vector) => throw new InvalidExecutionContextException($"{typeof(Int1x4)}.{nameof(Int1x4)}({nameof(Int4)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] + public partial struct Int2x1 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m21; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + public Int2x1(int m11, int m21) + { + this.m11 = m11; + this.m21 = m21; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref int this[int row] => throw new InvalidExecutionContextException($"{nameof(Int2x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int2x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int2x1)}.M21"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int2x1(int x) + { + Int2x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int2x1 operator -(Int2x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Int2x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int2x1 operator +(Int2x1 left, Int2x1 right) => throw new InvalidExecutionContextException($"{nameof(Int2x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int2x1 operator /(Int2x1 left, Int2x1 right) => throw new InvalidExecutionContextException($"{nameof(Int2x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int2x1 operator *(Int2x1 left, Int2x1 right) => throw new InvalidExecutionContextException($"{nameof(Int2x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int2x1 operator -(Int2x1 left, Int2x1 right) => throw new InvalidExecutionContextException($"{nameof(Int2x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Int2(Int2x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Int2x1)}.{nameof(Int2)}({nameof(Int2x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct Int2x2 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m21; + + [FieldOffset(12)] + private int m22; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + public Int2x2(int m11, int m12, int m21, int m22) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Int2x2(Int2 row1, Int2 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int2x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int2x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int2x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int2x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref int M22 => throw new InvalidExecutionContextException($"{typeof(Int2x2)}.M22"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int2x2(int x) + { + Int2x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int2x2 operator -(Int2x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Int2x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int2x2 operator +(Int2x2 left, Int2x2 right) => throw new InvalidExecutionContextException($"{nameof(Int2x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int2x2 operator /(Int2x2 left, Int2x2 right) => throw new InvalidExecutionContextException($"{nameof(Int2x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int2x2 operator *(Int2x2 left, Int2x2 right) => throw new InvalidExecutionContextException($"{nameof(Int2x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int2x2 operator -(Int2x2 left, Int2x2 right) => throw new InvalidExecutionContextException($"{nameof(Int2x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 4)] + public partial struct Int2x3 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m13; + + [FieldOffset(12)] + private int m21; + + [FieldOffset(16)] + private int m22; + + [FieldOffset(20)] + private int m23; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + public Int2x3(int m11, int m12, int m13, int m21, int m22, int m23) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Int2x3(Int3 row1, Int3 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int2x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int2x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int2x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref int M13 => throw new InvalidExecutionContextException($"{typeof(Int2x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int2x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref int M22 => throw new InvalidExecutionContextException($"{typeof(Int2x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref int M23 => throw new InvalidExecutionContextException($"{typeof(Int2x3)}.M23"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int2x3(int x) + { + Int2x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int2x3 operator -(Int2x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Int2x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int2x3 operator +(Int2x3 left, Int2x3 right) => throw new InvalidExecutionContextException($"{nameof(Int2x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int2x3 operator /(Int2x3 left, Int2x3 right) => throw new InvalidExecutionContextException($"{nameof(Int2x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int2x3 operator *(Int2x3 left, Int2x3 right) => throw new InvalidExecutionContextException($"{nameof(Int2x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int2x3 operator -(Int2x3 left, Int2x3 right) => throw new InvalidExecutionContextException($"{nameof(Int2x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 4)] + public partial struct Int2x4 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m13; + + [FieldOffset(12)] + private int m14; + + [FieldOffset(16)] + private int m21; + + [FieldOffset(20)] + private int m22; + + [FieldOffset(24)] + private int m23; + + [FieldOffset(28)] + private int m24; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + public Int2x4(int m11, int m12, int m13, int m14, int m21, int m22, int m23, int m24) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public Int2x4(Int4 row1, Int4 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int2x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int2x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int2x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref int M13 => throw new InvalidExecutionContextException($"{typeof(Int2x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref int M14 => throw new InvalidExecutionContextException($"{typeof(Int2x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int2x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref int M22 => throw new InvalidExecutionContextException($"{typeof(Int2x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref int M23 => throw new InvalidExecutionContextException($"{typeof(Int2x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref int M24 => throw new InvalidExecutionContextException($"{typeof(Int2x4)}.M24"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int2x4(int x) + { + Int2x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int2x4 operator -(Int2x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Int2x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int2x4 operator +(Int2x4 left, Int2x4 right) => throw new InvalidExecutionContextException($"{nameof(Int2x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int2x4 operator /(Int2x4 left, Int2x4 right) => throw new InvalidExecutionContextException($"{nameof(Int2x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int2x4 operator *(Int2x4 left, Int2x4 right) => throw new InvalidExecutionContextException($"{nameof(Int2x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int2x4 operator -(Int2x4 left, Int2x4 right) => throw new InvalidExecutionContextException($"{nameof(Int2x4)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] + public partial struct Int3x1 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m21; + + [FieldOffset(8)] + private int m31; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [3, 1]. + public Int3x1(int m11, int m21, int m31) + { + this.m11 = m11; + this.m21 = m21; + this.m31 = m31; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref int this[int row] => throw new InvalidExecutionContextException($"{nameof(Int3x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int3x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int3x1)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref int M31 => throw new InvalidExecutionContextException($"{typeof(Int3x1)}.M31"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int3x1(int x) + { + Int3x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + matrix.m31 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int3x1 operator -(Int3x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Int3x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int3x1 operator +(Int3x1 left, Int3x1 right) => throw new InvalidExecutionContextException($"{nameof(Int3x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int3x1 operator /(Int3x1 left, Int3x1 right) => throw new InvalidExecutionContextException($"{nameof(Int3x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int3x1 operator *(Int3x1 left, Int3x1 right) => throw new InvalidExecutionContextException($"{nameof(Int3x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int3x1 operator -(Int3x1 left, Int3x1 right) => throw new InvalidExecutionContextException($"{nameof(Int3x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Int3(Int3x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Int3x1)}.{nameof(Int3)}({nameof(Int3x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 4)] + public partial struct Int3x2 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m21; + + [FieldOffset(12)] + private int m22; + + [FieldOffset(16)] + private int m31; + + [FieldOffset(20)] + private int m32; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + public Int3x2(int m11, int m12, int m21, int m22, int m31, int m32) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + this.m31 = m31; + this.m32 = m32; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Int3x2(Int2 row1, Int2 row2, Int2 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m31 = row3.X; + this.m32 = row3.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int3x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int3x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int3x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int3x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref int M22 => throw new InvalidExecutionContextException($"{typeof(Int3x2)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref int M31 => throw new InvalidExecutionContextException($"{typeof(Int3x2)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref int M32 => throw new InvalidExecutionContextException($"{typeof(Int3x2)}.M32"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int3x2(int x) + { + Int3x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m31 = x; + matrix.m32 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int3x2 operator -(Int3x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Int3x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int3x2 operator +(Int3x2 left, Int3x2 right) => throw new InvalidExecutionContextException($"{nameof(Int3x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int3x2 operator /(Int3x2 left, Int3x2 right) => throw new InvalidExecutionContextException($"{nameof(Int3x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int3x2 operator *(Int3x2 left, Int3x2 right) => throw new InvalidExecutionContextException($"{nameof(Int3x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int3x2 operator -(Int3x2 left, Int3x2 right) => throw new InvalidExecutionContextException($"{nameof(Int3x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 36, Pack = 4)] + public partial struct Int3x3 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m13; + + [FieldOffset(12)] + private int m21; + + [FieldOffset(16)] + private int m22; + + [FieldOffset(20)] + private int m23; + + [FieldOffset(24)] + private int m31; + + [FieldOffset(28)] + private int m32; + + [FieldOffset(32)] + private int m33; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + public Int3x3(int m11, int m12, int m13, int m21, int m22, int m23, int m31, int m32, int m33) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Int3x3(Int3 row1, Int3 row2, Int3 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int3x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int3x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int3x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref int M13 => throw new InvalidExecutionContextException($"{typeof(Int3x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int3x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref int M22 => throw new InvalidExecutionContextException($"{typeof(Int3x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref int M23 => throw new InvalidExecutionContextException($"{typeof(Int3x3)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref int M31 => throw new InvalidExecutionContextException($"{typeof(Int3x3)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref int M32 => throw new InvalidExecutionContextException($"{typeof(Int3x3)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref int M33 => throw new InvalidExecutionContextException($"{typeof(Int3x3)}.M33"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int3x3(int x) + { + Int3x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int3x3 operator -(Int3x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Int3x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int3x3 operator +(Int3x3 left, Int3x3 right) => throw new InvalidExecutionContextException($"{nameof(Int3x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int3x3 operator /(Int3x3 left, Int3x3 right) => throw new InvalidExecutionContextException($"{nameof(Int3x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int3x3 operator *(Int3x3 left, Int3x3 right) => throw new InvalidExecutionContextException($"{nameof(Int3x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int3x3 operator -(Int3x3 left, Int3x3 right) => throw new InvalidExecutionContextException($"{nameof(Int3x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 48, Pack = 4)] + public partial struct Int3x4 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m13; + + [FieldOffset(12)] + private int m14; + + [FieldOffset(16)] + private int m21; + + [FieldOffset(20)] + private int m22; + + [FieldOffset(24)] + private int m23; + + [FieldOffset(28)] + private int m24; + + [FieldOffset(32)] + private int m31; + + [FieldOffset(36)] + private int m32; + + [FieldOffset(40)] + private int m33; + + [FieldOffset(44)] + private int m34; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [3, 4]. + public Int3x4(int m11, int m12, int m13, int m14, int m21, int m22, int m23, int m24, int m31, int m32, int m33, int m34) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m34 = m34; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public Int3x4(Int4 row1, Int4 row2, Int4 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m34 = row3.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int3x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref int M13 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref int M14 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref int M22 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref int M23 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref int M24 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M24"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref int M31 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref int M32 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref int M33 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [3, 4]. + /// + public ref int M34 => throw new InvalidExecutionContextException($"{typeof(Int3x4)}.M34"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int3x4(int x) + { + Int3x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m34 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int3x4 operator -(Int3x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Int3x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int3x4 operator +(Int3x4 left, Int3x4 right) => throw new InvalidExecutionContextException($"{nameof(Int3x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int3x4 operator /(Int3x4 left, Int3x4 right) => throw new InvalidExecutionContextException($"{nameof(Int3x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int3x4 operator *(Int3x4 left, Int3x4 right) => throw new InvalidExecutionContextException($"{nameof(Int3x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int3x4 operator -(Int3x4 left, Int3x4 right) => throw new InvalidExecutionContextException($"{nameof(Int3x4)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct Int4x1 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m21; + + [FieldOffset(8)] + private int m31; + + [FieldOffset(12)] + private int m41; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [4, 1]. + public Int4x1(int m11, int m21, int m31, int m41) + { + this.m11 = m11; + this.m21 = m21; + this.m31 = m31; + this.m41 = m41; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref int this[int row] => throw new InvalidExecutionContextException($"{nameof(Int4x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int4x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int4x1)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref int M31 => throw new InvalidExecutionContextException($"{typeof(Int4x1)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref int M41 => throw new InvalidExecutionContextException($"{typeof(Int4x1)}.M41"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int4x1(int x) + { + Int4x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + matrix.m31 = x; + matrix.m41 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int4x1 operator -(Int4x1 matrix) => throw new InvalidExecutionContextException($"{nameof(Int4x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int4x1 operator +(Int4x1 left, Int4x1 right) => throw new InvalidExecutionContextException($"{nameof(Int4x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int4x1 operator /(Int4x1 left, Int4x1 right) => throw new InvalidExecutionContextException($"{nameof(Int4x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int4x1 operator *(Int4x1 left, Int4x1 right) => throw new InvalidExecutionContextException($"{nameof(Int4x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int4x1 operator -(Int4x1 left, Int4x1 right) => throw new InvalidExecutionContextException($"{nameof(Int4x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator Int4(Int4x1 matrix) => throw new InvalidExecutionContextException($"{typeof(Int4x1)}.{nameof(Int4)}({nameof(Int4x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 4)] + public partial struct Int4x2 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m21; + + [FieldOffset(12)] + private int m22; + + [FieldOffset(16)] + private int m31; + + [FieldOffset(20)] + private int m32; + + [FieldOffset(24)] + private int m41; + + [FieldOffset(28)] + private int m42; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + public Int4x2(int m11, int m12, int m21, int m22, int m31, int m32, int m41, int m42) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + this.m31 = m31; + this.m32 = m32; + this.m41 = m41; + this.m42 = m42; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Int4x2(Int2 row1, Int2 row2, Int2 row3, Int2 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m41 = row4.X; + this.m42 = row4.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int2 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int4x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int4x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int4x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int4x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref int M22 => throw new InvalidExecutionContextException($"{typeof(Int4x2)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref int M31 => throw new InvalidExecutionContextException($"{typeof(Int4x2)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref int M32 => throw new InvalidExecutionContextException($"{typeof(Int4x2)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref int M41 => throw new InvalidExecutionContextException($"{typeof(Int4x2)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref int M42 => throw new InvalidExecutionContextException($"{typeof(Int4x2)}.M42"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int4x2(int x) + { + Int4x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m41 = x; + matrix.m42 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int4x2 operator -(Int4x2 matrix) => throw new InvalidExecutionContextException($"{nameof(Int4x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int4x2 operator +(Int4x2 left, Int4x2 right) => throw new InvalidExecutionContextException($"{nameof(Int4x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int4x2 operator /(Int4x2 left, Int4x2 right) => throw new InvalidExecutionContextException($"{nameof(Int4x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int4x2 operator *(Int4x2 left, Int4x2 right) => throw new InvalidExecutionContextException($"{nameof(Int4x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int4x2 operator -(Int4x2 left, Int4x2 right) => throw new InvalidExecutionContextException($"{nameof(Int4x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 48, Pack = 4)] + public partial struct Int4x3 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m13; + + [FieldOffset(12)] + private int m21; + + [FieldOffset(16)] + private int m22; + + [FieldOffset(20)] + private int m23; + + [FieldOffset(24)] + private int m31; + + [FieldOffset(28)] + private int m32; + + [FieldOffset(32)] + private int m33; + + [FieldOffset(36)] + private int m41; + + [FieldOffset(40)] + private int m42; + + [FieldOffset(44)] + private int m43; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + /// The value to assign to the component at position [4, 3]. + public Int4x3(int m11, int m12, int m13, int m21, int m22, int m23, int m31, int m32, int m33, int m41, int m42, int m43) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m41 = m41; + this.m42 = m42; + this.m43 = m43; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Int4x3(Int3 row1, Int3 row2, Int3 row3, Int3 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m41 = row4.X; + this.m42 = row4.Y; + this.m43 = row4.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int3 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int4x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref int M13 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref int M22 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref int M23 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref int M31 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref int M32 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref int M33 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref int M41 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref int M42 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M42"); + + /// + /// Gets a reference to the value representing the component at position [4, 3]. + /// + public ref int M43 => throw new InvalidExecutionContextException($"{typeof(Int4x3)}.M43"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int4x3(int x) + { + Int4x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m41 = x; + matrix.m42 = x; + matrix.m43 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int4x3 operator -(Int4x3 matrix) => throw new InvalidExecutionContextException($"{nameof(Int4x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int4x3 operator +(Int4x3 left, Int4x3 right) => throw new InvalidExecutionContextException($"{nameof(Int4x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int4x3 operator /(Int4x3 left, Int4x3 right) => throw new InvalidExecutionContextException($"{nameof(Int4x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int4x3 operator *(Int4x3 left, Int4x3 right) => throw new InvalidExecutionContextException($"{nameof(Int4x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int4x3 operator -(Int4x3 left, Int4x3 right) => throw new InvalidExecutionContextException($"{nameof(Int4x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 64, Pack = 4)] + public partial struct Int4x4 + { + [FieldOffset(0)] + private int m11; + + [FieldOffset(4)] + private int m12; + + [FieldOffset(8)] + private int m13; + + [FieldOffset(12)] + private int m14; + + [FieldOffset(16)] + private int m21; + + [FieldOffset(20)] + private int m22; + + [FieldOffset(24)] + private int m23; + + [FieldOffset(28)] + private int m24; + + [FieldOffset(32)] + private int m31; + + [FieldOffset(36)] + private int m32; + + [FieldOffset(40)] + private int m33; + + [FieldOffset(44)] + private int m34; + + [FieldOffset(48)] + private int m41; + + [FieldOffset(52)] + private int m42; + + [FieldOffset(56)] + private int m43; + + [FieldOffset(60)] + private int m44; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [3, 4]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + /// The value to assign to the component at position [4, 3]. + /// The value to assign to the component at position [4, 4]. + public Int4x4(int m11, int m12, int m13, int m14, int m21, int m22, int m23, int m24, int m31, int m32, int m33, int m34, int m41, int m42, int m43, int m44) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m34 = m34; + this.m41 = m41; + this.m42 = m42; + this.m43 = m43; + this.m44 = m44; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public Int4x4(Int4 row1, Int4 row2, Int4 row3, Int4 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m34 = row3.W; + this.m41 = row4.X; + this.m42 = row4.Y; + this.m43 = row4.Z; + this.m44 = row4.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref Int4 this[int row] => throw new InvalidExecutionContextException($"{nameof(Int4x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref Int2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(Int4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref Int3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(Int4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref Int4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(Int4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref int M11 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref int M12 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref int M13 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref int M14 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref int M21 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref int M22 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref int M23 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref int M24 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M24"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref int M31 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref int M32 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref int M33 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [3, 4]. + /// + public ref int M34 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M34"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref int M41 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref int M42 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M42"); + + /// + /// Gets a reference to the value representing the component at position [4, 3]. + /// + public ref int M43 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M43"); + + /// + /// Gets a reference to the value representing the component at position [4, 4]. + /// + public ref int M44 => throw new InvalidExecutionContextException($"{typeof(Int4x4)}.M44"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator Int4x4(int x) + { + Int4x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m34 = x; + matrix.m41 = x; + matrix.m42 = x; + matrix.m43 = x; + matrix.m44 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static Int4x4 operator -(Int4x4 matrix) => throw new InvalidExecutionContextException($"{nameof(Int4x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static Int4x4 operator +(Int4x4 left, Int4x4 right) => throw new InvalidExecutionContextException($"{nameof(Int4x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static Int4x4 operator /(Int4x4 left, Int4x4 right) => throw new InvalidExecutionContextException($"{nameof(Int4x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static Int4x4 operator *(Int4x4 left, Int4x4 right) => throw new InvalidExecutionContextException($"{nameof(Int4x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static Int4x4 operator -(Int4x4 left, Int4x4 right) => throw new InvalidExecutionContextException($"{nameof(Int4x4)}.-"); + } +} diff --git a/src/ComputeSharp/Core/Primitives/Int/IntMxN.tt b/src/ComputeSharp/Core/Primitives/Int/IntMxN.tt new file mode 100644 index 00000000..bf70cf4d --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/Int/IntMxN.tt @@ -0,0 +1,4 @@ +<#@include file="..\MatrixType.ttinclude" #> +<# +GenerateAllMatrixProperties("Int", sizeof(int)); +#> \ No newline at end of file diff --git a/src/ComputeSharp/Core/Primitives/MatrixIndex.cs b/src/ComputeSharp/Core/Primitives/MatrixIndex.cs new file mode 100644 index 00000000..5b330472 --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/MatrixIndex.cs @@ -0,0 +1,97 @@ +namespace ComputeSharp +{ + /// + /// A type indicating a base-1 index into a matrix type. This can be used to extract references to swizzled vectors within a given matrix value. + /// For more info, see . + /// This type is meant to be used within a directive to simplify the code: + /// + /// + /// using static ComputeSharp.MatrixIndex; + /// Float2x2 matrix = 0; + /// Float2 row = matrix[M11, M12]; + /// + /// + /// + public enum MatrixIndex + { + /// + /// The first item in the first row. + /// + M11, + + /// + /// The second item in the first row. + /// + M12, + + /// + /// The third item in the first row. + /// + M13, + + /// + /// The fourth item in the first row. + /// + M14, + + /// + /// The first item in the second row. + /// + M21, + + /// + /// The second item in the second row. + /// + M22, + + /// + /// The third item in the second row. + /// + M23, + + /// + /// The fourth item in the second row. + /// + M24, + + /// + /// The first item in the third row. + /// + M31, + + /// + /// The second item in the third row. + /// + M32, + + /// + /// The third item in the third row. + /// + M33, + + /// + /// The fourth item in the third row. + /// + M34, + + /// + /// The first item in the fourth row. + /// + M41, + + /// + /// The second item in the fourth row. + /// + M42, + + /// + /// The third item in the fourth row. + /// + M43, + + /// + /// The fourth item in the fourth row. + /// + M44 + } +} diff --git a/src/ComputeSharp/Core/Primitives/MatrixType.ttinclude b/src/ComputeSharp/Core/Primitives/MatrixType.ttinclude new file mode 100644 index 00000000..9ef58902 --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/MatrixType.ttinclude @@ -0,0 +1,268 @@ +<#@ template debug="false" hostspecific="false" language="C#" #> +<#@ assembly name="System.Core" #> +<#@ import namespace="System.Linq" #> +<#@ import namespace="System.Text" #> +<#@ import namespace="System.Text.RegularExpressions" #> +<#@ import namespace="System.Collections.Generic" #> +<#@ output extension=".g.cs"#> +<# +// Generates all matrix members and types for a given HLSL type +void GenerateAllMatrixProperties(string typeName, int elementSize) +{ +#> +using System.Runtime.InteropServices; +using ComputeSharp.Exceptions; + +namespace ComputeSharp +{ +<# + for (int rows = 1; rows <= 4; rows++) + for (int columns = 1; columns <= 4; columns++) + { + if (rows > 1 || columns > 1) WriteLine(""); + + GenerateMatrixProperties(typeName, rows, columns, elementSize); + } +#> +} +<# +} + +// Generates all vector access properties for a specified type +void GenerateMatrixProperties(string typeName, int rows, int columns, int elementSize) +{ + string elementTypeName = typeName.ToLower(); + string fullTypeName = $"{typeName}{rows}x{columns}"; + string rowTypeName = columns > 1 ? $"{typeName}{columns}" : elementTypeName; + List fieldNames = new List(); +#> + /// + [StructLayout(LayoutKind.Explicit, Size = <#=(elementSize * rows * columns)#>, Pack = <#=elementSize#>)] + public partial struct <#=fullTypeName#> + { +<# + PushIndent(" "); + PushIndent(" "); + + // Generate the private fields + for (int i = 1; i <= rows; i++) + for (int j = 1; j <= columns; j++) + { + WriteLine($"[FieldOffset({((i - 1) * columns + j - 1) * elementSize})]"); + WriteLine($"private {elementTypeName} m{i}{j};"); + WriteLine(""); + + fieldNames.Add($"m{i}{j}"); + } + + // Generate the elementwise constructor + WriteLine("/// "); + WriteLine($"/// Creates a new instance with the specified parameters."); + WriteLine("/// "); + + for (int i = 1; i <= rows; i++) + for (int j = 1; j <= columns; j++) + { + WriteLine($"/// The value to assign to the component at position [{i}, {j}]."); + } + + WriteLine($"public {fullTypeName}({string.Join(", ", fieldNames.Select(n => $"{elementTypeName} {n}"))})"); + WriteLine("{"); + PushIndent(" "); + + foreach (string fieldName in fieldNames) + { + WriteLine($"this.{fieldName} = {fieldName};"); + } + + PopIndent(); + WriteLine("}"); + WriteLine(""); + + // Generate the row-wise constructor, if needed + if (rows > 1 && columns > 1) + { + WriteLine("/// "); + WriteLine($"/// Creates a new instance with the specified parameters."); + WriteLine("/// "); + + for (int i = 1; i <= rows; i++) + { + WriteLine($"/// The value to assign to the row at position [{i}]."); + } + + Write($"public {fullTypeName}("); + + for (int i = 1; i <= rows; i++) + { + if (i > 1) Write(", "); + Write($"{rowTypeName} row{i}"); + } + + WriteLine(")"); + WriteLine("{"); + PushIndent(" "); + + for (int i = 1; i <= rows; i++) + for (int j = 1; j <= columns; j++) + { + WriteLine($"this.m{i}{j} = row{i}.{"XYZW"[j - 1]};"); + } + + PopIndent(); + WriteLine("}"); + WriteLine(""); + } + + PopIndent(); + PopIndent(); +#> + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref <#=rowTypeName#> this[int row] => throw new InvalidExecutionContextException($"{nameof(<#=fullTypeName#>)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref <#=typeName#>2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(<#=fullTypeName#>)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref <#=typeName#>3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(<#=fullTypeName#>)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref <#=typeName#>4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(<#=fullTypeName#>)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); +<# + for (int i = 1; i <= rows; i++) + for (int j = 1; j <= columns; j++) + { + WriteLine(""); +#> + /// + /// Gets a reference to the value representing the component at position [<#=i#>, <#=j#>]. + /// + public ref <#=elementTypeName#> M<#=i#><#=j#> => throw new InvalidExecutionContextException($"{typeof(<#=fullTypeName#>)}.M<#=i#><#=j#>"); +<# + } + + WriteLine(""); +#> + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator <#=fullTypeName#>(<#=elementTypeName#> x) +<# + // Complete the conversion operator above + PushIndent(" "); + PushIndent(" "); + WriteLine("{"); + PushIndent(" "); + WriteLine($"{fullTypeName} matrix;"); + WriteLine(""); + + for (int i = 1; i <= rows; i++) + for (int j = 1; j <= columns; j++) + { + WriteLine($"matrix.m{i}{j} = x;"); + } + + WriteLine(""); + WriteLine("return matrix;"); + + PopIndent(); + WriteLine("}"); + PopIndent(); + PopIndent(); + + // Generate the negation operator + if (elementTypeName != "Bool" && elementTypeName != "UInt") + { + WriteLine(""); +#> + /// + /// Negates a value. + /// + /// The value to negate. + public static <#=fullTypeName#> operator -(<#=fullTypeName#> matrix) => throw new InvalidExecutionContextException($"{nameof(<#=fullTypeName#>)}.-"); +<# + } + + // Generate the numerical operators + if (elementTypeName != "Bool") + { + WriteLine(""); +#> + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static <#=fullTypeName#> operator +(<#=fullTypeName#> left, <#=fullTypeName#> right) => throw new InvalidExecutionContextException($"{nameof(<#=fullTypeName#>)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static <#=fullTypeName#> operator /(<#=fullTypeName#> left, <#=fullTypeName#> right) => throw new InvalidExecutionContextException($"{nameof(<#=fullTypeName#>)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static <#=fullTypeName#> operator *(<#=fullTypeName#> left, <#=fullTypeName#> right) => throw new InvalidExecutionContextException($"{nameof(<#=fullTypeName#>)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static <#=fullTypeName#> operator -(<#=fullTypeName#> left, <#=fullTypeName#> right) => throw new InvalidExecutionContextException($"{nameof(<#=fullTypeName#>)}.-"); +<# + } + + // Generate the casting operators for row/column vectors + if (rows == 1 && columns > 1) + { + WriteLine(""); +#> + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator <#=fullTypeName#>(<#=typeName#><#=columns#> vector) => throw new InvalidExecutionContextException($"{typeof(<#=fullTypeName#>)}.{nameof(<#=fullTypeName#>)}({nameof(<#=typeName#><#=columns#>)})"); +<# + } + + if (columns == 1 && rows > 1) + { + WriteLine(""); +#> + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator <#=typeName#><#=rows#>(<#=fullTypeName#> matrix) => throw new InvalidExecutionContextException($"{typeof(<#=fullTypeName#>)}.{nameof(<#=typeName#><#=rows#>)}({nameof(<#=fullTypeName#>)})"); +<# + } +#> + } +<# +} +#> \ No newline at end of file diff --git a/src/ComputeSharp/Core/Primitives/UInt/UInt2.g.cs b/src/ComputeSharp/Core/Primitives/UInt/UInt2.g.cs index 122daae7..8c539699 100644 --- a/src/ComputeSharp/Core/Primitives/UInt/UInt2.g.cs +++ b/src/ComputeSharp/Core/Primitives/UInt/UInt2.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 8)] + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] public partial struct UInt2 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/UInt/UInt3.g.cs b/src/ComputeSharp/Core/Primitives/UInt/UInt3.g.cs index fa24d40d..51d07dd9 100644 --- a/src/ComputeSharp/Core/Primitives/UInt/UInt3.g.cs +++ b/src/ComputeSharp/Core/Primitives/UInt/UInt3.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 12)] + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] public partial struct UInt3 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/UInt/UInt4.g.cs b/src/ComputeSharp/Core/Primitives/UInt/UInt4.g.cs index 41f20da0..4404bb94 100644 --- a/src/ComputeSharp/Core/Primitives/UInt/UInt4.g.cs +++ b/src/ComputeSharp/Core/Primitives/UInt/UInt4.g.cs @@ -4,7 +4,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = 16)] + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] public partial struct UInt4 { [FieldOffset(0)] diff --git a/src/ComputeSharp/Core/Primitives/UInt/UIntMxN.g.cs b/src/ComputeSharp/Core/Primitives/UInt/UIntMxN.g.cs new file mode 100644 index 00000000..c2bb30a2 --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/UInt/UIntMxN.g.cs @@ -0,0 +1,2720 @@ +using System.Runtime.InteropServices; +using ComputeSharp.Exceptions; + +namespace ComputeSharp +{ + /// + [StructLayout(LayoutKind.Explicit, Size = 4, Pack = 4)] + public partial struct UInt1x1 + { + [FieldOffset(0)] + private uint m11; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + public UInt1x1(uint m11) + { + this.m11 = m11; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref uint this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt1x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt1x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt1x1)}.M11"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt1x1(uint x) + { + UInt1x1 matrix; + + matrix.m11 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt1x1 operator -(UInt1x1 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt1x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt1x1 operator +(UInt1x1 left, UInt1x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt1x1 operator /(UInt1x1 left, UInt1x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt1x1 operator *(UInt1x1 left, UInt1x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt1x1 operator -(UInt1x1 left, UInt1x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x1)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] + public partial struct UInt1x2 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + public UInt1x2(uint m11, uint m12) + { + this.m11 = m11; + this.m12 = m12; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt2 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt1x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt1x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt1x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt1x2)}.M12"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt1x2(uint x) + { + UInt1x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt1x2 operator -(UInt1x2 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt1x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt1x2 operator +(UInt1x2 left, UInt1x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt1x2 operator /(UInt1x2 left, UInt1x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt1x2 operator *(UInt1x2 left, UInt1x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt1x2 operator -(UInt1x2 left, UInt1x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x2)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator UInt1x2(UInt2 vector) => throw new InvalidExecutionContextException($"{typeof(UInt1x2)}.{nameof(UInt1x2)}({nameof(UInt2)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] + public partial struct UInt1x3 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m13; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + public UInt1x3(uint m11, uint m12, uint m13) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt3 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt1x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt1x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt1x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt1x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref uint M13 => throw new InvalidExecutionContextException($"{typeof(UInt1x3)}.M13"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt1x3(uint x) + { + UInt1x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt1x3 operator -(UInt1x3 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt1x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt1x3 operator +(UInt1x3 left, UInt1x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt1x3 operator /(UInt1x3 left, UInt1x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt1x3 operator *(UInt1x3 left, UInt1x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt1x3 operator -(UInt1x3 left, UInt1x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x3)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator UInt1x3(UInt3 vector) => throw new InvalidExecutionContextException($"{typeof(UInt1x3)}.{nameof(UInt1x3)}({nameof(UInt3)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct UInt1x4 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m13; + + [FieldOffset(12)] + private uint m14; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + public UInt1x4(uint m11, uint m12, uint m13, uint m14) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt4 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt1x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt1x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt1x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt1x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref uint M13 => throw new InvalidExecutionContextException($"{typeof(UInt1x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref uint M14 => throw new InvalidExecutionContextException($"{typeof(UInt1x4)}.M14"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt1x4(uint x) + { + UInt1x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt1x4 operator -(UInt1x4 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt1x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt1x4 operator +(UInt1x4 left, UInt1x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt1x4 operator /(UInt1x4 left, UInt1x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt1x4 operator *(UInt1x4 left, UInt1x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt1x4 operator -(UInt1x4 left, UInt1x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt1x4)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator UInt1x4(UInt4 vector) => throw new InvalidExecutionContextException($"{typeof(UInt1x4)}.{nameof(UInt1x4)}({nameof(UInt4)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 8, Pack = 4)] + public partial struct UInt2x1 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m21; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + public UInt2x1(uint m11, uint m21) + { + this.m11 = m11; + this.m21 = m21; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref uint this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt2x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt2x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt2x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt2x1)}.M21"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt2x1(uint x) + { + UInt2x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt2x1 operator -(UInt2x1 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt2x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt2x1 operator +(UInt2x1 left, UInt2x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt2x1 operator /(UInt2x1 left, UInt2x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt2x1 operator *(UInt2x1 left, UInt2x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt2x1 operator -(UInt2x1 left, UInt2x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator UInt2(UInt2x1 matrix) => throw new InvalidExecutionContextException($"{typeof(UInt2x1)}.{nameof(UInt2)}({nameof(UInt2x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct UInt2x2 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m21; + + [FieldOffset(12)] + private uint m22; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + public UInt2x2(uint m11, uint m12, uint m21, uint m22) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public UInt2x2(UInt2 row1, UInt2 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt2 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt2x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt2x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt2x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt2x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt2x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref uint M22 => throw new InvalidExecutionContextException($"{typeof(UInt2x2)}.M22"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt2x2(uint x) + { + UInt2x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt2x2 operator -(UInt2x2 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt2x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt2x2 operator +(UInt2x2 left, UInt2x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt2x2 operator /(UInt2x2 left, UInt2x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt2x2 operator *(UInt2x2 left, UInt2x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt2x2 operator -(UInt2x2 left, UInt2x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 4)] + public partial struct UInt2x3 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m13; + + [FieldOffset(12)] + private uint m21; + + [FieldOffset(16)] + private uint m22; + + [FieldOffset(20)] + private uint m23; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + public UInt2x3(uint m11, uint m12, uint m13, uint m21, uint m22, uint m23) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public UInt2x3(UInt3 row1, UInt3 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt3 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt2x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt2x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt2x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt2x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref uint M13 => throw new InvalidExecutionContextException($"{typeof(UInt2x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt2x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref uint M22 => throw new InvalidExecutionContextException($"{typeof(UInt2x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref uint M23 => throw new InvalidExecutionContextException($"{typeof(UInt2x3)}.M23"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt2x3(uint x) + { + UInt2x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt2x3 operator -(UInt2x3 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt2x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt2x3 operator +(UInt2x3 left, UInt2x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt2x3 operator /(UInt2x3 left, UInt2x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt2x3 operator *(UInt2x3 left, UInt2x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt2x3 operator -(UInt2x3 left, UInt2x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 4)] + public partial struct UInt2x4 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m13; + + [FieldOffset(12)] + private uint m14; + + [FieldOffset(16)] + private uint m21; + + [FieldOffset(20)] + private uint m22; + + [FieldOffset(24)] + private uint m23; + + [FieldOffset(28)] + private uint m24; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + public UInt2x4(uint m11, uint m12, uint m13, uint m14, uint m21, uint m22, uint m23, uint m24) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + public UInt2x4(UInt4 row1, UInt4 row2) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt4 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt2x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt2x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt2x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt2x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref uint M13 => throw new InvalidExecutionContextException($"{typeof(UInt2x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref uint M14 => throw new InvalidExecutionContextException($"{typeof(UInt2x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt2x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref uint M22 => throw new InvalidExecutionContextException($"{typeof(UInt2x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref uint M23 => throw new InvalidExecutionContextException($"{typeof(UInt2x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref uint M24 => throw new InvalidExecutionContextException($"{typeof(UInt2x4)}.M24"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt2x4(uint x) + { + UInt2x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt2x4 operator -(UInt2x4 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt2x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt2x4 operator +(UInt2x4 left, UInt2x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt2x4 operator /(UInt2x4 left, UInt2x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt2x4 operator *(UInt2x4 left, UInt2x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt2x4 operator -(UInt2x4 left, UInt2x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt2x4)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 12, Pack = 4)] + public partial struct UInt3x1 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m21; + + [FieldOffset(8)] + private uint m31; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [3, 1]. + public UInt3x1(uint m11, uint m21, uint m31) + { + this.m11 = m11; + this.m21 = m21; + this.m31 = m31; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref uint this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt3x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt3x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt3x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt3x1)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref uint M31 => throw new InvalidExecutionContextException($"{typeof(UInt3x1)}.M31"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt3x1(uint x) + { + UInt3x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + matrix.m31 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt3x1 operator -(UInt3x1 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt3x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt3x1 operator +(UInt3x1 left, UInt3x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt3x1 operator /(UInt3x1 left, UInt3x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt3x1 operator *(UInt3x1 left, UInt3x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt3x1 operator -(UInt3x1 left, UInt3x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator UInt3(UInt3x1 matrix) => throw new InvalidExecutionContextException($"{typeof(UInt3x1)}.{nameof(UInt3)}({nameof(UInt3x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 24, Pack = 4)] + public partial struct UInt3x2 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m21; + + [FieldOffset(12)] + private uint m22; + + [FieldOffset(16)] + private uint m31; + + [FieldOffset(20)] + private uint m32; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + public UInt3x2(uint m11, uint m12, uint m21, uint m22, uint m31, uint m32) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + this.m31 = m31; + this.m32 = m32; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public UInt3x2(UInt2 row1, UInt2 row2, UInt2 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m31 = row3.X; + this.m32 = row3.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt2 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt3x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt3x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt3x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt3x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt3x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref uint M22 => throw new InvalidExecutionContextException($"{typeof(UInt3x2)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref uint M31 => throw new InvalidExecutionContextException($"{typeof(UInt3x2)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref uint M32 => throw new InvalidExecutionContextException($"{typeof(UInt3x2)}.M32"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt3x2(uint x) + { + UInt3x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m31 = x; + matrix.m32 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt3x2 operator -(UInt3x2 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt3x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt3x2 operator +(UInt3x2 left, UInt3x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt3x2 operator /(UInt3x2 left, UInt3x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt3x2 operator *(UInt3x2 left, UInt3x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt3x2 operator -(UInt3x2 left, UInt3x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 36, Pack = 4)] + public partial struct UInt3x3 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m13; + + [FieldOffset(12)] + private uint m21; + + [FieldOffset(16)] + private uint m22; + + [FieldOffset(20)] + private uint m23; + + [FieldOffset(24)] + private uint m31; + + [FieldOffset(28)] + private uint m32; + + [FieldOffset(32)] + private uint m33; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + public UInt3x3(uint m11, uint m12, uint m13, uint m21, uint m22, uint m23, uint m31, uint m32, uint m33) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public UInt3x3(UInt3 row1, UInt3 row2, UInt3 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt3 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt3x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt3x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt3x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt3x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref uint M13 => throw new InvalidExecutionContextException($"{typeof(UInt3x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt3x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref uint M22 => throw new InvalidExecutionContextException($"{typeof(UInt3x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref uint M23 => throw new InvalidExecutionContextException($"{typeof(UInt3x3)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref uint M31 => throw new InvalidExecutionContextException($"{typeof(UInt3x3)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref uint M32 => throw new InvalidExecutionContextException($"{typeof(UInt3x3)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref uint M33 => throw new InvalidExecutionContextException($"{typeof(UInt3x3)}.M33"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt3x3(uint x) + { + UInt3x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt3x3 operator -(UInt3x3 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt3x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt3x3 operator +(UInt3x3 left, UInt3x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt3x3 operator /(UInt3x3 left, UInt3x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt3x3 operator *(UInt3x3 left, UInt3x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt3x3 operator -(UInt3x3 left, UInt3x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 48, Pack = 4)] + public partial struct UInt3x4 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m13; + + [FieldOffset(12)] + private uint m14; + + [FieldOffset(16)] + private uint m21; + + [FieldOffset(20)] + private uint m22; + + [FieldOffset(24)] + private uint m23; + + [FieldOffset(28)] + private uint m24; + + [FieldOffset(32)] + private uint m31; + + [FieldOffset(36)] + private uint m32; + + [FieldOffset(40)] + private uint m33; + + [FieldOffset(44)] + private uint m34; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [3, 4]. + public UInt3x4(uint m11, uint m12, uint m13, uint m14, uint m21, uint m22, uint m23, uint m24, uint m31, uint m32, uint m33, uint m34) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m34 = m34; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + public UInt3x4(UInt4 row1, UInt4 row2, UInt4 row3) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m34 = row3.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt4 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt3x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt3x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref uint M13 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref uint M14 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref uint M22 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref uint M23 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref uint M24 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M24"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref uint M31 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref uint M32 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref uint M33 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [3, 4]. + /// + public ref uint M34 => throw new InvalidExecutionContextException($"{typeof(UInt3x4)}.M34"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt3x4(uint x) + { + UInt3x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m34 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt3x4 operator -(UInt3x4 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt3x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt3x4 operator +(UInt3x4 left, UInt3x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt3x4 operator /(UInt3x4 left, UInt3x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt3x4 operator *(UInt3x4 left, UInt3x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt3x4 operator -(UInt3x4 left, UInt3x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt3x4)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 16, Pack = 4)] + public partial struct UInt4x1 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m21; + + [FieldOffset(8)] + private uint m31; + + [FieldOffset(12)] + private uint m41; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [4, 1]. + public UInt4x1(uint m11, uint m21, uint m31, uint m41) + { + this.m11 = m11; + this.m21 = m21; + this.m31 = m31; + this.m41 = m41; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref uint this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt4x1)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt4x1)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt4x1)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt4x1)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref uint M31 => throw new InvalidExecutionContextException($"{typeof(UInt4x1)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref uint M41 => throw new InvalidExecutionContextException($"{typeof(UInt4x1)}.M41"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt4x1(uint x) + { + UInt4x1 matrix; + + matrix.m11 = x; + matrix.m21 = x; + matrix.m31 = x; + matrix.m41 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt4x1 operator -(UInt4x1 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt4x1)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt4x1 operator +(UInt4x1 left, UInt4x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x1)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt4x1 operator /(UInt4x1 left, UInt4x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x1)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt4x1 operator *(UInt4x1 left, UInt4x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x1)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt4x1 operator -(UInt4x1 left, UInt4x1 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x1)}.-"); + + /// + /// Casts a value to a one. + /// + /// The input value to cast. + public static implicit operator UInt4(UInt4x1 matrix) => throw new InvalidExecutionContextException($"{typeof(UInt4x1)}.{nameof(UInt4)}({nameof(UInt4x1)})"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 32, Pack = 4)] + public partial struct UInt4x2 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m21; + + [FieldOffset(12)] + private uint m22; + + [FieldOffset(16)] + private uint m31; + + [FieldOffset(20)] + private uint m32; + + [FieldOffset(24)] + private uint m41; + + [FieldOffset(28)] + private uint m42; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + public UInt4x2(uint m11, uint m12, uint m21, uint m22, uint m31, uint m32, uint m41, uint m42) + { + this.m11 = m11; + this.m12 = m12; + this.m21 = m21; + this.m22 = m22; + this.m31 = m31; + this.m32 = m32; + this.m41 = m41; + this.m42 = m42; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public UInt4x2(UInt2 row1, UInt2 row2, UInt2 row3, UInt2 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m41 = row4.X; + this.m42 = row4.Y; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt2 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt4x2)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt4x2)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt4x2)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt4x2)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt4x2)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref uint M22 => throw new InvalidExecutionContextException($"{typeof(UInt4x2)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref uint M31 => throw new InvalidExecutionContextException($"{typeof(UInt4x2)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref uint M32 => throw new InvalidExecutionContextException($"{typeof(UInt4x2)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref uint M41 => throw new InvalidExecutionContextException($"{typeof(UInt4x2)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref uint M42 => throw new InvalidExecutionContextException($"{typeof(UInt4x2)}.M42"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt4x2(uint x) + { + UInt4x2 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m41 = x; + matrix.m42 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt4x2 operator -(UInt4x2 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt4x2)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt4x2 operator +(UInt4x2 left, UInt4x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x2)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt4x2 operator /(UInt4x2 left, UInt4x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x2)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt4x2 operator *(UInt4x2 left, UInt4x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x2)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt4x2 operator -(UInt4x2 left, UInt4x2 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x2)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 48, Pack = 4)] + public partial struct UInt4x3 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m13; + + [FieldOffset(12)] + private uint m21; + + [FieldOffset(16)] + private uint m22; + + [FieldOffset(20)] + private uint m23; + + [FieldOffset(24)] + private uint m31; + + [FieldOffset(28)] + private uint m32; + + [FieldOffset(32)] + private uint m33; + + [FieldOffset(36)] + private uint m41; + + [FieldOffset(40)] + private uint m42; + + [FieldOffset(44)] + private uint m43; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + /// The value to assign to the component at position [4, 3]. + public UInt4x3(uint m11, uint m12, uint m13, uint m21, uint m22, uint m23, uint m31, uint m32, uint m33, uint m41, uint m42, uint m43) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m41 = m41; + this.m42 = m42; + this.m43 = m43; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public UInt4x3(UInt3 row1, UInt3 row2, UInt3 row3, UInt3 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m41 = row4.X; + this.m42 = row4.Y; + this.m43 = row4.Z; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt3 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt4x3)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt4x3)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref uint M13 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref uint M22 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref uint M23 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref uint M31 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref uint M32 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref uint M33 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref uint M41 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref uint M42 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M42"); + + /// + /// Gets a reference to the value representing the component at position [4, 3]. + /// + public ref uint M43 => throw new InvalidExecutionContextException($"{typeof(UInt4x3)}.M43"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt4x3(uint x) + { + UInt4x3 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m41 = x; + matrix.m42 = x; + matrix.m43 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt4x3 operator -(UInt4x3 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt4x3)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt4x3 operator +(UInt4x3 left, UInt4x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x3)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt4x3 operator /(UInt4x3 left, UInt4x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x3)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt4x3 operator *(UInt4x3 left, UInt4x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x3)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt4x3 operator -(UInt4x3 left, UInt4x3 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x3)}.-"); + } + + /// + [StructLayout(LayoutKind.Explicit, Size = 64, Pack = 4)] + public partial struct UInt4x4 + { + [FieldOffset(0)] + private uint m11; + + [FieldOffset(4)] + private uint m12; + + [FieldOffset(8)] + private uint m13; + + [FieldOffset(12)] + private uint m14; + + [FieldOffset(16)] + private uint m21; + + [FieldOffset(20)] + private uint m22; + + [FieldOffset(24)] + private uint m23; + + [FieldOffset(28)] + private uint m24; + + [FieldOffset(32)] + private uint m31; + + [FieldOffset(36)] + private uint m32; + + [FieldOffset(40)] + private uint m33; + + [FieldOffset(44)] + private uint m34; + + [FieldOffset(48)] + private uint m41; + + [FieldOffset(52)] + private uint m42; + + [FieldOffset(56)] + private uint m43; + + [FieldOffset(60)] + private uint m44; + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the component at position [1, 1]. + /// The value to assign to the component at position [1, 2]. + /// The value to assign to the component at position [1, 3]. + /// The value to assign to the component at position [1, 4]. + /// The value to assign to the component at position [2, 1]. + /// The value to assign to the component at position [2, 2]. + /// The value to assign to the component at position [2, 3]. + /// The value to assign to the component at position [2, 4]. + /// The value to assign to the component at position [3, 1]. + /// The value to assign to the component at position [3, 2]. + /// The value to assign to the component at position [3, 3]. + /// The value to assign to the component at position [3, 4]. + /// The value to assign to the component at position [4, 1]. + /// The value to assign to the component at position [4, 2]. + /// The value to assign to the component at position [4, 3]. + /// The value to assign to the component at position [4, 4]. + public UInt4x4(uint m11, uint m12, uint m13, uint m14, uint m21, uint m22, uint m23, uint m24, uint m31, uint m32, uint m33, uint m34, uint m41, uint m42, uint m43, uint m44) + { + this.m11 = m11; + this.m12 = m12; + this.m13 = m13; + this.m14 = m14; + this.m21 = m21; + this.m22 = m22; + this.m23 = m23; + this.m24 = m24; + this.m31 = m31; + this.m32 = m32; + this.m33 = m33; + this.m34 = m34; + this.m41 = m41; + this.m42 = m42; + this.m43 = m43; + this.m44 = m44; + } + + /// + /// Creates a new instance with the specified parameters. + /// + /// The value to assign to the row at position [1]. + /// The value to assign to the row at position [2]. + /// The value to assign to the row at position [3]. + /// The value to assign to the row at position [4]. + public UInt4x4(UInt4 row1, UInt4 row2, UInt4 row3, UInt4 row4) + { + this.m11 = row1.X; + this.m12 = row1.Y; + this.m13 = row1.Z; + this.m14 = row1.W; + this.m21 = row2.X; + this.m22 = row2.Y; + this.m23 = row2.Z; + this.m24 = row2.W; + this.m31 = row3.X; + this.m32 = row3.Y; + this.m33 = row3.Z; + this.m34 = row3.W; + this.m41 = row4.X; + this.m42 = row4.Y; + this.m43 = row4.Z; + this.m44 = row4.W; + } + + /// + /// Gets a reference to a specific row in the current instance. + /// + /// The row to access. + public ref UInt4 this[int row] => throw new InvalidExecutionContextException($"{nameof(UInt4x4)}[int]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + public ref UInt2 this[MatrixIndex xy0, MatrixIndex xy1] => throw new InvalidExecutionContextException($"{nameof(UInt4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + public ref UInt3 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2] => throw new InvalidExecutionContextException($"{nameof(UInt4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a swizzled reference to a specific sequence of items in the current instance. + /// + /// The identifier of the first item to index. + /// The identifier of the second item to index. + /// The identifier of the third item to index. + /// The identifier of the fourth item to index. + public ref UInt4 this[MatrixIndex xy0, MatrixIndex xy1, MatrixIndex xy2, MatrixIndex xy3] => throw new InvalidExecutionContextException($"{nameof(UInt4x4)}[{nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}, {nameof(MatrixIndex)}]"); + + /// + /// Gets a reference to the value representing the component at position [1, 1]. + /// + public ref uint M11 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M11"); + + /// + /// Gets a reference to the value representing the component at position [1, 2]. + /// + public ref uint M12 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M12"); + + /// + /// Gets a reference to the value representing the component at position [1, 3]. + /// + public ref uint M13 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M13"); + + /// + /// Gets a reference to the value representing the component at position [1, 4]. + /// + public ref uint M14 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M14"); + + /// + /// Gets a reference to the value representing the component at position [2, 1]. + /// + public ref uint M21 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M21"); + + /// + /// Gets a reference to the value representing the component at position [2, 2]. + /// + public ref uint M22 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M22"); + + /// + /// Gets a reference to the value representing the component at position [2, 3]. + /// + public ref uint M23 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M23"); + + /// + /// Gets a reference to the value representing the component at position [2, 4]. + /// + public ref uint M24 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M24"); + + /// + /// Gets a reference to the value representing the component at position [3, 1]. + /// + public ref uint M31 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M31"); + + /// + /// Gets a reference to the value representing the component at position [3, 2]. + /// + public ref uint M32 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M32"); + + /// + /// Gets a reference to the value representing the component at position [3, 3]. + /// + public ref uint M33 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M33"); + + /// + /// Gets a reference to the value representing the component at position [3, 4]. + /// + public ref uint M34 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M34"); + + /// + /// Gets a reference to the value representing the component at position [4, 1]. + /// + public ref uint M41 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M41"); + + /// + /// Gets a reference to the value representing the component at position [4, 2]. + /// + public ref uint M42 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M42"); + + /// + /// Gets a reference to the value representing the component at position [4, 3]. + /// + public ref uint M43 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M43"); + + /// + /// Gets a reference to the value representing the component at position [4, 4]. + /// + public ref uint M44 => throw new InvalidExecutionContextException($"{typeof(UInt4x4)}.M44"); + + /// + /// Creates a new value with the same value for all its components. + /// + /// The value to use for the components of the new instance. + public static implicit operator UInt4x4(uint x) + { + UInt4x4 matrix; + + matrix.m11 = x; + matrix.m12 = x; + matrix.m13 = x; + matrix.m14 = x; + matrix.m21 = x; + matrix.m22 = x; + matrix.m23 = x; + matrix.m24 = x; + matrix.m31 = x; + matrix.m32 = x; + matrix.m33 = x; + matrix.m34 = x; + matrix.m41 = x; + matrix.m42 = x; + matrix.m43 = x; + matrix.m44 = x; + + return matrix; + } + + /// + /// Negates a value. + /// + /// The value to negate. + public static UInt4x4 operator -(UInt4x4 matrix) => throw new InvalidExecutionContextException($"{nameof(UInt4x4)}.-"); + + /// + /// Sums two values. + /// + /// The first value to sum. + /// The second value to sum. + public static UInt4x4 operator +(UInt4x4 left, UInt4x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x4)}.+"); + + /// + /// Divides two values (elementwise division). + /// + /// The first value to divide. + /// The second value to divide. + public static UInt4x4 operator /(UInt4x4 left, UInt4x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x4)}./"); + + /// + /// Multiplies two values (elementwise product). + /// + /// The first value to multiply. + /// The second value to multiply. + public static UInt4x4 operator *(UInt4x4 left, UInt4x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x4)}.*"); + + /// + /// Subtracts two values. + /// + /// The first value to subtract. + /// The second value to subtract. + public static UInt4x4 operator -(UInt4x4 left, UInt4x4 right) => throw new InvalidExecutionContextException($"{nameof(UInt4x4)}.-"); + } +} diff --git a/src/ComputeSharp/Core/Primitives/UInt/UIntMxN.tt b/src/ComputeSharp/Core/Primitives/UInt/UIntMxN.tt new file mode 100644 index 00000000..59d27cd9 --- /dev/null +++ b/src/ComputeSharp/Core/Primitives/UInt/UIntMxN.tt @@ -0,0 +1,4 @@ +<#@include file="..\MatrixType.ttinclude" #> +<# +GenerateAllMatrixProperties("UInt", sizeof(uint)); +#> \ No newline at end of file diff --git a/src/ComputeSharp/Core/Primitives/VectorType.ttinclude b/src/ComputeSharp/Core/Primitives/VectorType.ttinclude index 538a24f6..5ab90379 100644 --- a/src/ComputeSharp/Core/Primitives/VectorType.ttinclude +++ b/src/ComputeSharp/Core/Primitives/VectorType.ttinclude @@ -72,7 +72,7 @@ using ComputeSharp.Exceptions; namespace ComputeSharp { /// - [StructLayout(LayoutKind.Explicit, Size = <#=(elementSize * i)#>)] + [StructLayout(LayoutKind.Explicit, Size = <#=(elementSize * i)#>, Pack = <#=elementSize#>)] public partial struct <#=typeName#> { <# diff --git a/src/ComputeSharp/Graphics/Extensions/Interop/ID3D12DeviceExtensions.cs b/src/ComputeSharp/Graphics/Extensions/Interop/ID3D12DeviceExtensions.cs index bf11e1db..c9ae84e9 100644 --- a/src/ComputeSharp/Graphics/Extensions/Interop/ID3D12DeviceExtensions.cs +++ b/src/ComputeSharp/Graphics/Extensions/Interop/ID3D12DeviceExtensions.cs @@ -558,7 +558,7 @@ namespace ComputeSharp.Graphics.Extensions public static unsafe TFeature CheckFeatureSupport(this ref ID3D12Device d3D12Device, D3D12_FEATURE d3D12Feature) where TFeature : unmanaged { - TFeature feature; + TFeature feature = default; d3D12Device.CheckFeatureSupport(d3D12Feature, &feature, (uint)sizeof(TFeature)).Assert(); diff --git a/src/ComputeSharp/Properties/AssemblyInfo.cs b/src/ComputeSharp/Properties/AssemblyInfo.cs index 55ae2dcc..0d511608 100644 --- a/src/ComputeSharp/Properties/AssemblyInfo.cs +++ b/src/ComputeSharp/Properties/AssemblyInfo.cs @@ -1,4 +1,5 @@ using System.Runtime.CompilerServices; -[assembly: InternalsVisibleTo("ComputeSharp.SourceGenerators")] +[module: SkipLocalsInit] + [assembly: InternalsVisibleTo("ComputeSharp.Tests.Internals")] diff --git a/src/ComputeSharp/Shaders/Translation/Mappings/HlslKnownTypes.cs b/src/ComputeSharp/Shaders/Translation/Mappings/HlslKnownTypes.cs index 5776c971..90aae996 100644 --- a/src/ComputeSharp/Shaders/Translation/Mappings/HlslKnownTypes.cs +++ b/src/ComputeSharp/Shaders/Translation/Mappings/HlslKnownTypes.cs @@ -10,7 +10,10 @@ namespace ComputeSharp.Shaders.Mappings /// internal static class HlslKnownTypes { - private static HashSet _HlslMappedVectorTypes { get; } = new HashSet(new[] + /// + /// The set of HLSL vector types. + /// + private static HashSet HlslMappedVectorTypes { get; } = new(new[] { typeof(Bool2), typeof(Bool3), typeof(Bool4), typeof(Int2), typeof(Int3), typeof(Int4), @@ -19,6 +22,33 @@ namespace ComputeSharp.Shaders.Mappings typeof(Double2), typeof(Double3), typeof(Double4) }); + /// + /// The set of HLSL matrix types. + /// + private static HashSet HlslMappedMatrixTypes { get; } = new(new[] + { + typeof(Bool1x1), typeof(Bool1x2), typeof(Bool1x3), typeof(Bool1x4), + typeof(Bool2x1), typeof(Bool2x2), typeof(Bool2x3), typeof(Bool2x4), + typeof(Bool3x1), typeof(Bool3x2), typeof(Bool3x3), typeof(Bool3x4), + typeof(Bool4x1), typeof(Bool4x2), typeof(Bool4x3), typeof(Bool4x4), + typeof(Int1x1), typeof(Int1x2), typeof(Int1x3), typeof(Int1x4), + typeof(Int2x1), typeof(Int2x2), typeof(Int2x3), typeof(Int2x4), + typeof(Int3x1), typeof(Int3x2), typeof(Int3x3), typeof(Int3x4), + typeof(Int4x1), typeof(Int4x2), typeof(Int4x3), typeof(Int4x4), + typeof(UInt1x1), typeof(UInt1x2), typeof(UInt1x3), typeof(UInt1x4), + typeof(UInt2x1), typeof(UInt2x2), typeof(UInt2x3), typeof(UInt2x4), + typeof(UInt3x1), typeof(UInt3x2), typeof(UInt3x3), typeof(UInt3x4), + typeof(UInt4x1), typeof(UInt4x2), typeof(UInt4x3), typeof(UInt4x4), + typeof(Float1x1), typeof(Float1x2), typeof(Float1x3), typeof(Float1x4), + typeof(Float2x1), typeof(Float2x2), typeof(Float2x3), typeof(Float2x4), + typeof(Float3x1), typeof(Float3x2), typeof(Float3x3), typeof(Float3x4), + typeof(Float4x1), typeof(Float4x2), typeof(Float4x3), typeof(Float4x4), + typeof(Double1x1), typeof(Double1x2), typeof(Double1x3), typeof(Double1x4), + typeof(Double2x1), typeof(Double2x2), typeof(Double2x3), typeof(Double2x4), + typeof(Double3x1), typeof(Double3x2), typeof(Double3x3), typeof(Double3x4), + typeof(Double4x1), typeof(Double4x2), typeof(Double4x3), typeof(Double4x4) + }); + /// /// Checks whether or not the input type is a known scalar type. /// @@ -38,11 +68,19 @@ namespace ComputeSharp.Shaders.Mappings /// The input instance to check. /// A indicating whether the input is in fact a known HLSL vector type. [Pure] - public static bool IsKnownVectorType(Type type) => _HlslMappedVectorTypes.Contains(type) || + public static bool IsKnownVectorType(Type type) => HlslMappedVectorTypes.Contains(type) || type == typeof(Vector2) || type == typeof(Vector3) || type == typeof(Vector4); + /// + /// Checks whether or not the input type is a known matrix type. + /// + /// The input instance to check. + /// A indicating whether the input is in fact a known HLSL matrix type. + [Pure] + public static bool IsKnownMatrixType(Type type) => HlslMappedMatrixTypes.Contains(type); + /// /// Checks whether or not the input type is a known buffer type. /// diff --git a/src/ComputeSharp/Shaders/Translation/ShaderCompiler.cs b/src/ComputeSharp/Shaders/Translation/ShaderCompiler.cs index cbc6e6b6..96332b55 100644 --- a/src/ComputeSharp/Shaders/Translation/ShaderCompiler.cs +++ b/src/ComputeSharp/Shaders/Translation/ShaderCompiler.cs @@ -104,14 +104,17 @@ namespace ComputeSharp.Shaders.Translation fixed (char* entryPoint = nameof(IComputeShader.Execute)) fixed (char* shaderProfile = "cs_6_0") fixed (char* optimization = "-O3") + fixed (char* rowMajor = "-Zpr") { + char** arguments = stackalloc char*[2] { optimization, rowMajor }; + DxcCompiler.Get()->Compile( (IDxcBlob*)dxcBlobEncoding.Get(), (ushort*)shaderName, (ushort*)entryPoint, (ushort*)shaderProfile, - (ushort**)&optimization, - 1, + (ushort**)arguments, + 2, null, 0, DxcIncludeHandler.Get(), diff --git a/src/ComputeSharp/Shaders/Translation/ShaderLoader{T}.cs b/src/ComputeSharp/Shaders/Translation/ShaderLoader{T}.cs index a04b9b61..de9cfcef 100644 --- a/src/ComputeSharp/Shaders/Translation/ShaderLoader{T}.cs +++ b/src/ComputeSharp/Shaders/Translation/ShaderLoader{T}.cs @@ -217,7 +217,7 @@ namespace ComputeSharp.Shaders.Translation this.hlslResourceInfo.Add(new HlslResourceInfo.ReadWrite(hlslType, hlslName, (int)this.readWriteBuffersCount++)); this.totalResourceCount++; } - else if (HlslKnownTypes.IsKnownScalarType(fieldType) || HlslKnownTypes.IsKnownVectorType(fieldType)) + else if (HlslKnownTypes.IsKnownScalarType(fieldType) || HlslKnownTypes.IsKnownVectorType(fieldType) || HlslKnownTypes.IsKnownMatrixType(fieldType)) { this.capturedFields.Add(fieldInfo); this.fieldsInfo.Add(new CapturedFieldInfo(hlslType, hlslName)); diff --git a/tests/ComputeSharp.Tests.Internals.SourceGenerators/DiagnosticsTests.cs b/tests/ComputeSharp.Tests.Internals.SourceGenerators/DiagnosticsTests.cs index 81336d41..40ea4c4a 100644 --- a/tests/ComputeSharp.Tests.Internals.SourceGenerators/DiagnosticsTests.cs +++ b/tests/ComputeSharp.Tests.Internals.SourceGenerators/DiagnosticsTests.cs @@ -1097,6 +1097,47 @@ namespace ComputeSharp.Tests.Internals VerifyGeneratedDiagnostics(source, "CMPS0036"); } + [TestMethod] + public void NonConstantMatrixSwizzledIndex() + { + string source = @" + using ComputeSharp; + using static ComputeSharp.MatrixIndex; + + namespace ComputeSharp + { + public class ReadWriteBuffer { } + public enum MatrixIndex + { + M11, + M12, + M13 + }, + public struct Float4 { } + public struct Float4x4 + { + public Float4 this[MatrixIndex m0, MatrixIndex m1, MatrixIndex m2, MatrixIndex m3] => default; + } + } + + namespace MyFancyApp.Sample + { + public struct MyShader : IComputeShader + { + public ReadWriteBuffer buffer; + + public void Execute() + { + Float4x4 m = default; + MatrixIndex index = M12; + Float4 = m[M11, index, M13, M11]; + } + } + }"; + + VerifyGeneratedDiagnostics(source, "CMPS0042"); + } + /// /// Verifies the output of a source generator. /// diff --git a/tests/ComputeSharp.Tests.Internals/ShaderDataLoaderTests.cs b/tests/ComputeSharp.Tests.Internals/ShaderDataLoaderTests.cs new file mode 100644 index 00000000..fb729401 --- /dev/null +++ b/tests/ComputeSharp.Tests.Internals/ShaderDataLoaderTests.cs @@ -0,0 +1,180 @@ +using ComputeSharp.__Internals; +using Microsoft.VisualStudio.TestTools.UnitTesting; + +#pragma warning disable CS0618 + +namespace ComputeSharp.Tests.Internals +{ + [TestClass] + [TestCategory("ShaderDataLoader")] + public partial class ShaderDataLoaderTests + { + [AutoConstructor] + public partial struct Shader1 : IComputeShader + { + public ReadWriteBuffer _; + + public void Execute() + { + } + } + + [TestMethod] + public unsafe void LoadShader1() + { + ulong* p0 = stackalloc ulong[128]; + byte* p1 = stackalloc byte[256]; + + using ReadWriteBuffer buffer = Gpu.Default.AllocateReadWriteBuffer(16); + + int size = DispatchDataLoader.LoadDispatchData(Gpu.Default, new Shader1(buffer), ref *p0, ref *p1); + + Assert.AreEqual(12, size); + + Assert.AreEqual(p0[0], buffer.D3D12GpuDescriptorHandle.ptr); + } + + [AutoConstructor] + public partial struct Shader2 : IComputeShader + { + public ReadWriteBuffer _0; + public ReadWriteBuffer _1; + public int a; + public int b; + public int c; + + public void Execute() + { + } + } + + [TestMethod] + public unsafe void LoadShader2() + { + ulong* p0 = stackalloc ulong[128]; + byte* p1 = stackalloc byte[256]; + + using ReadWriteBuffer buffer0 = Gpu.Default.AllocateReadWriteBuffer(16); + using ReadWriteBuffer buffer1 = Gpu.Default.AllocateReadWriteBuffer(16); + + int size = DispatchDataLoader.LoadDispatchData(Gpu.Default, new Shader2(buffer0, buffer1, 1, 22, 77), ref *p0, ref *p1); + + Assert.AreEqual(24, size); + + Assert.AreEqual(p0[0], buffer0.D3D12GpuDescriptorHandle.ptr); + Assert.AreEqual(p0[1], buffer1.D3D12GpuDescriptorHandle.ptr); + + Assert.AreEqual(1, *(int*)&p1[12]); + Assert.AreEqual(22, *(int*)&p1[16]); + Assert.AreEqual(77, *(int*)&p1[20]); + } + + [AutoConstructor] + public partial struct Shader3 : IComputeShader + { + public ReadWriteBuffer _; + public Float3 f3; + public int a; + public int b; + public Double2 d2; + public int c; + public int d; + + public void Execute() + { + } + } + + [TestMethod] + public unsafe void LoadShader3() + { + ulong* p0 = stackalloc ulong[128]; + byte* p1 = stackalloc byte[256]; + + using ReadWriteBuffer buffer = Gpu.Default.AllocateReadWriteBuffer(16); + + Shader3 shader = new(buffer, new(55, 44, 888), 22, 77, new(3.14, 6.28), 42, 9999); + + int size = DispatchDataLoader.LoadDispatchData(Gpu.Default, in shader, ref *p0, ref *p1); + + Assert.AreEqual(72, size); + + Assert.AreEqual(p0[0], buffer.D3D12GpuDescriptorHandle.ptr); + + Assert.AreEqual(55, *(float*)&p1[16]); + Assert.AreEqual(44, *(float*)&p1[20]); + Assert.AreEqual(888, *(float*)&p1[24]); + Assert.AreEqual(22, *(int*)&p1[28]); + Assert.AreEqual(77, *(int*)&p1[32]); + Assert.AreEqual(3.14, *(double*)&p1[48]); + Assert.AreEqual(6.28, *(double*)&p1[56]); + Assert.AreEqual(42, *(int*)&p1[64]); + Assert.AreEqual(9999, *(int*)&p1[68]); + } + + [AutoConstructor] + public partial struct Shader4 : IComputeShader + { + public ReadWriteBuffer _; + public Float2x3 f2x3; + public int a; + public Int1x3 i1x3; + public Double2 d2; + public int c; + public Int1x2 i1x2; + public Int2x2 i2x2; + public int d; + + public void Execute() + { + } + } + + [TestMethod] + public unsafe void LoadShader4() + { + ulong* p0 = stackalloc ulong[128]; + byte* p1 = stackalloc byte[256]; + + using ReadWriteBuffer buffer = Gpu.Default.AllocateReadWriteBuffer(16); + + Shader4 shader = new( + buffer, + f2x3: new(55, 44, 888, 111, 222, 333), + a: 22, + i1x3: new(1, 2, 3), + d2: new(3.14, 6.28), + c: 42, + i1x2: new(111, 222), + i2x2: new(11, 22, 33, 44), + d: 9999); + + int size = DispatchDataLoader.LoadDispatchData(Gpu.Default, in shader, ref *p0, ref *p1); + + Assert.AreEqual(124, size); + + Assert.AreEqual(p0[0], buffer.D3D12GpuDescriptorHandle.ptr); + + Assert.AreEqual(55, *(float*)&p1[16]); + Assert.AreEqual(44, *(float*)&p1[20]); + Assert.AreEqual(888, *(float*)&p1[24]); + Assert.AreEqual(111, *(float*)&p1[32]); + Assert.AreEqual(222, *(float*)&p1[36]); + Assert.AreEqual(333, *(float*)&p1[40]); + Assert.AreEqual(22, *(int*)&p1[44]); + Assert.AreEqual(1, *(int*)&p1[48]); + Assert.AreEqual(2, *(int*)&p1[52]); + Assert.AreEqual(3, *(int*)&p1[56]); + Assert.AreEqual(3.14, *(double*)&p1[64]); + Assert.AreEqual(6.28, *(double*)&p1[72]); + Assert.AreEqual(42, *(int*)&p1[80]); + Assert.AreEqual(111, *(int*)&p1[84]); + Assert.AreEqual(222, *(int*)&p1[88]); + Assert.AreEqual(11, *(int*)&p1[96]); + Assert.AreEqual(22, *(int*)&p1[100]); + Assert.AreEqual(33, *(int*)&p1[112]); + Assert.AreEqual(44, *(int*)&p1[116]); + Assert.AreEqual(9999, *(int*)&p1[120]); + } + } +} diff --git a/tests/ComputeSharp.Tests.Internals/ShaderHashCodeTests.cs b/tests/ComputeSharp.Tests.Internals/ShaderHashCodeTests.cs index dfe219e2..241ce61b 100644 --- a/tests/ComputeSharp.Tests.Internals/ShaderHashCodeTests.cs +++ b/tests/ComputeSharp.Tests.Internals/ShaderHashCodeTests.cs @@ -5,7 +5,7 @@ using Microsoft.VisualStudio.TestTools.UnitTesting; namespace ComputeSharp.Tests.Internals { [TestClass] - [TestCategory("ShaderHashCodes")] + [TestCategory("ShaderHashCode")] public class ShaderHashCodeTests { public struct Shader1 : IComputeShader diff --git a/tests/ComputeSharp.Tests/Assets/Octagrams.jpg b/tests/ComputeSharp.Tests/Assets/Octagrams.jpg new file mode 100644 index 00000000..bef5e971 Binary files /dev/null and b/tests/ComputeSharp.Tests/Assets/Octagrams.jpg differ diff --git a/tests/ComputeSharp.Tests/Assets/ProteanClouds.jpg b/tests/ComputeSharp.Tests/Assets/ProteanClouds.jpg new file mode 100644 index 00000000..9a0d508e Binary files /dev/null and b/tests/ComputeSharp.Tests/Assets/ProteanClouds.jpg differ diff --git a/tests/ComputeSharp.Tests/ComputeSharp.Tests.csproj b/tests/ComputeSharp.Tests/ComputeSharp.Tests.csproj index 8b157cb4..65816af5 100644 --- a/tests/ComputeSharp.Tests/ComputeSharp.Tests.csproj +++ b/tests/ComputeSharp.Tests/ComputeSharp.Tests.csproj @@ -31,6 +31,8 @@ + + @@ -47,9 +49,18 @@ PreserveNewest + + PreserveNewest + PreserveNewest + + PreserveNewest + + + PreserveNewest + TextTemplatingFileGenerator Texture2DTests.Pixels.g.cs diff --git a/tests/ComputeSharp.Tests/ShadersTests.cs b/tests/ComputeSharp.Tests/ShadersTests.cs index f16e267c..703aba93 100644 --- a/tests/ComputeSharp.Tests/ShadersTests.cs +++ b/tests/ComputeSharp.Tests/ShadersTests.cs @@ -43,6 +43,20 @@ namespace ComputeSharp.Tests RunAndCompareShader(device, static texture => new TwoTiledTruchet(texture, 0), 0.00033f); } + [CombinatorialTestMethod] + [AllDevices] + public void Octagrams(Device device) + { + RunAndCompareShader(device, static texture => new Octagrams(texture, 0), 0.00000586f); + } + + [CombinatorialTestMethod] + [AllDevices] + public void ProteanClouds(Device device) + { + RunAndCompareShader(device, static texture => new ProteanClouds(texture, 0), 0.00000107f); + } + /// /// Executes a given test for a specified shader. ///