diff --git a/.silktouch/0afb5dc84012c2fa.stout b/.silktouch/0afb5dc84012c2fa.stout
new file mode 100644
index 0000000000..60fd812b22
Binary files /dev/null and b/.silktouch/0afb5dc84012c2fa.stout differ
diff --git a/.silktouch/c8c046b328b09d23.stout b/.silktouch/c8c046b328b09d23.stout
index 35b4d2a73b..2f5d1a8ee3 100644
Binary files a/.silktouch/c8c046b328b09d23.stout and b/.silktouch/c8c046b328b09d23.stout differ
diff --git a/.silktouch/f634eee0bf239a81.stout b/.silktouch/f634eee0bf239a81.stout
deleted file mode 100644
index 046c5cc172..0000000000
Binary files a/.silktouch/f634eee0bf239a81.stout and /dev/null differ
diff --git a/eng/silktouch/sdl/SDL3/generate.rsp b/eng/silktouch/sdl/SDL3/generate.rsp
index 264138a3bb..1503cdd39c 100644
--- a/eng/silktouch/sdl/SDL3/generate.rsp
+++ b/eng/silktouch/sdl/SDL3/generate.rsp
@@ -7,6 +7,8 @@ SDL_SIZE_MAX
SDL_memcpy
SDL_memmove
SDL_memset
+SDL_BeginThreadFunction
+SDL_EndThreadFunction
--file
sdl-SDL.h
--methodClassName
diff --git a/eng/submodules/sdl b/eng/submodules/sdl
index d95f5bad24..78cc5c1734 160000
--- a/eng/submodules/sdl
+++ b/eng/submodules/sdl
@@ -1 +1 @@
-Subproject commit d95f5bad2459608816cbf24f14dcab618a4a9ab7
+Subproject commit 78cc5c173404488d80751af226d1eaf67033bcc4
diff --git a/generator.json b/generator.json
index ed43803f4e..6921658b9a 100644
--- a/generator.json
+++ b/generator.json
@@ -43,6 +43,7 @@
"ExtractNestedTyping",
"TransformHandles",
"TransformFunctions",
+ "TransformProperties",
"PrettifyNames",
"AddVTables"
],
@@ -71,6 +72,7 @@
"AddIncludes",
"ClangScraper",
"AddApiProfiles",
+ "BakeSourceSets",
"MixKhronosData",
"AddOpaqueStructs",
"TransformFunctions",
@@ -88,29 +90,33 @@
"Profiles": [
{
"Profile": "gl",
- "SourceSubdirectory": "glcompat",
- "BakedOutputSubdirectory": "gl"
+ "SourceSubdirectory": "glcompat"
},
{
"Profile": "glcore",
"SourceSubdirectory": "glcore",
- "BakedOutputSubdirectory": "gl",
"MinVersion": "3.2"
},
{
"Profile": "gles1",
"SourceSubdirectory": "gles1",
- "BakedOutputSubdirectory": "gl",
"MaxVersion": "2.0"
},
{
"Profile": "gles2",
"SourceSubdirectory": "gles2",
- "BakedOutputSubdirectory": "gl",
"MinVersion": "2.0"
}
]
},
+ "BakeSourceSets": {
+ "SourceSets": {
+ "glcompat": "gl",
+ "glcore": "gl",
+ "gles1": "gl",
+ "gles2": "gl"
+ }
+ },
"AddOpaqueStructs": {
"Names": [
"GLsync"
diff --git a/sources/Core/Core/Abstractions/Utf8String.cs b/sources/Core/Core/Abstractions/Utf8String.cs
new file mode 100644
index 0000000000..9b04eff88e
--- /dev/null
+++ b/sources/Core/Core/Abstractions/Utf8String.cs
@@ -0,0 +1,81 @@
+// Licensed to the .NET Foundation under one or more agreements.
+// The .NET Foundation licenses this file to you under the MIT license.
+
+using System.Runtime.InteropServices;
+
+namespace Silk.NET.Core;
+
+///
+/// Represents a target type for UTF-8 string literals.
+///
+/// The UTF-8 bytes.
+public readonly ref struct Utf8String(ReadOnlySpan bytes)
+{
+ ///
+ /// Gets the UTF-8 byte representation of this string.
+ ///
+ public ReadOnlySpan Bytes { get; } = bytes;
+
+ ///
+ /// Converts this string to a .
+ ///
+ /// The string.
+ /// The ref.
+ public static implicit operator Ref(Utf8String str) => str.Bytes;
+
+ ///
+ /// Converts this string to a .
+ ///
+ /// The string.
+ /// The ref.
+ public static implicit operator Ref(Utf8String str) => (ReadOnlySpan)str;
+
+ ///
+ /// Converts this string to a .
+ ///
+ /// The string.
+ /// The span.
+ public static implicit operator ReadOnlySpan(Utf8String str) => str.Bytes;
+
+ ///
+ /// Converts this string to a .
+ ///
+ /// The string.
+ /// The span.
+ public static implicit operator ReadOnlySpan(Utf8String str) =>
+ MemoryMarshal.Cast(str);
+
+ // TODO add ptr casts once we have an analyzer for e.g. [KnownImmovable]
+
+ ///
+ /// Converts this string to a .
+ ///
+ /// The string.
+ /// The ref.
+ public static implicit operator Ref(Utf8String str) => (Ref)str.Bytes;
+
+ ///
+ /// Converts this string to a .
+ ///
+ /// The string.
+ /// The string.
+ public static implicit operator string(Utf8String str) => str.ToString();
+
+ ///
+ /// Converts the given UTF-8 bytes to a .
+ ///
+ /// The bytes.
+ /// The string.
+ public static implicit operator Utf8String(ReadOnlySpan bytes) => new(bytes);
+
+ ///
+ /// Converts the given UTF-8 bytes to a .
+ ///
+ /// The bytes.
+ /// The string.
+ public static implicit operator Utf8String(ReadOnlySpan bytes) =>
+ MemoryMarshal.Cast(bytes);
+
+ ///
+ public override string ToString() => (string)(Ref)this;
+}
diff --git a/sources/Core/Core/Pointers/Ref.generic.cs b/sources/Core/Core/Pointers/Ref.generic.cs
index 1f295d30b1..c94bc40361 100644
--- a/sources/Core/Core/Pointers/Ref.generic.cs
+++ b/sources/Core/Core/Pointers/Ref.generic.cs
@@ -132,12 +132,21 @@ public ref T this[nuint index]
public static bool operator !=(NullPtr lh, Ref rh) => (Ref)lh != rh;
///
- /// Creates a from a span
+ /// Creates a from a span.
///
- ///
+ /// The span to create the ref from.
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
public static implicit operator Ref(Span span) => new(ref span.GetPinnableReference());
+ ///
+ /// Creates a from a readonly span.
+ ///
+ /// The span to create the ref from.
+ [MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
+ // TODO const correctness analyzers
+ public static implicit operator Ref(ReadOnlySpan span) =>
+ new(ref Unsafe.AsRef(in span.GetPinnableReference()));
+
///
/// Creates a from a byte reference
///
diff --git a/sources/Core/Core/SilkMarshal.cs b/sources/Core/Core/SilkMarshal.cs
index 442a976b01..b2680eb01a 100644
--- a/sources/Core/Core/SilkMarshal.cs
+++ b/sources/Core/Core/SilkMarshal.cs
@@ -215,6 +215,7 @@ public static ref byte StringArrayToNative(ReadOnlySpan strs, nint charS
/// The character size of the marshalled strings.
/// The reference.
/// A GC exception occurred.
+ // TODO analyzer to clarify that this only works if the inner array is const.
public static ref byte StringArrayToNative(ReadOnlySpan strs, nint charSize = 1)
{
var ret = new byte[strs.Length * sizeof(nint)];
@@ -235,6 +236,7 @@ public static ref byte StringArrayToNative(ReadOnlySpan strs, nint cha
/// The character size of the marshalled strings.
/// The reference.
/// A GC exception occurred.
+ // TODO analyzer to clarify that this only works if the inner array is const.
public static ref byte StringArrayToNative(ReadOnlySpan strs, nint charSize = 1)
{
var ret = new byte[strs.Length * sizeof(nint)];
@@ -255,6 +257,7 @@ public static ref byte StringArrayToNative(ReadOnlySpan strs, nint c
/// The pointee type.
/// The created array.
/// A GC exception occurred.
+ // TODO analyzer to clarify that this only works if the inner array is const.
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static T*[] JaggedArrayToPointerArray(ReadOnlySpan array)
where T : unmanaged
@@ -286,6 +289,7 @@ public static ref byte StringArrayToNative(ReadOnlySpan strs, nint c
/// The pointee type.
/// The created array.
/// A GC exception occurred.
+ // TODO analyzer to clarify that this only works if the inner array is const.
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static T**[] JaggedArrayToPointerArray(ReadOnlySpan array)
where T : unmanaged
@@ -319,6 +323,7 @@ public static ref byte StringArrayToNative(ReadOnlySpan strs, nint c
/// The pointee type.
/// The created array.
/// A GC exception occurred.
+ // TODO analyzer to clarify that this only works if the inner array is const.
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static T***[] JaggedArrayToPointerArray(ReadOnlySpan array)
where T : unmanaged
@@ -508,6 +513,15 @@ public static Ref AsRef(ref this T @ref)
public static Ref AsRef(this Span @ref)
where T : unmanaged => new(ref @ref.GetPinnableReference());
+ ///
+ /// Creates a reference from a readonly span.
+ ///
+ /// A span of .
+ /// The pointee type.
+ /// The pointer to the given span's elements.
+ public static Ref AsRef(this ReadOnlySpan @ref)
+ where T : unmanaged => @ref;
+
///
/// Creates a 2D Ref from a reference.
///
@@ -537,6 +551,26 @@ public static Ref2D AsRef2D(ref this Span @ref)
throw IL.Unreachable();
}
+ ///
+ /// Creates a 2D Ref from a reference to a readonly span.
+ ///
+ /// A reference to a .
+ /// The pointee type.
+ /// The pointer to the given reference.
+ public static Ref2D AsRef2D(ref this ReadOnlySpan @ref)
+ where T : unmanaged
+ {
+ IL.Emit.Ldarg_0();
+ IL.Emit.Newobj(
+ MethodRef.Constructor(
+ TypeRef.Type(typeof(Ref2D<>).MakeGenericType(typeof(T))),
+ TypeRef.Type(typeof(Ref<>).MakeGenericType(typeof(T)).MakeByRefType())
+ )
+ );
+ IL.Emit.Ret();
+ throw IL.Unreachable();
+ }
+
///
/// Converts a span of ptrs to a 2D jagged array
///
@@ -685,51 +719,32 @@ static TTo UnsignedFallback(TFrom value)
MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization
)]
static TTo UnsignedCast(TFrom value) =>
- sizeof(TTo) == sizeof(TFrom)
- ? Unsafe.BitCast(value)
- : sizeof(TTo) == 1 && sizeof(TFrom) == 2
- ? Unsafe.BitCast((byte)Unsafe.BitCast(value))
- : sizeof(TTo) == 1 && sizeof(TFrom) == 4
- ? Unsafe.BitCast((byte)Unsafe.BitCast(value))
- : sizeof(TTo) == 1 && sizeof(TFrom) == 8
- ? Unsafe.BitCast((byte)Unsafe.BitCast(value))
- : sizeof(TTo) == 2 && sizeof(TFrom) == 1
- ? Unsafe.BitCast(Unsafe.BitCast(value))
- : sizeof(TTo) == 2 && sizeof(TFrom) == 4
- ? Unsafe.BitCast(
- (ushort)Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 2 && sizeof(TFrom) == 8
- ? Unsafe.BitCast(
- (ushort)Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 4 && sizeof(TFrom) == 1
- ? Unsafe.BitCast(
- Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 4 && sizeof(TFrom) == 2
- ? Unsafe.BitCast(
- Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 4 && sizeof(TFrom) == 8
- ? Unsafe.BitCast(
- (uint)Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 8 && sizeof(TFrom) == 1
- ? Unsafe.BitCast(
- Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 8 && sizeof(TFrom) == 2
- ? Unsafe.BitCast(
- Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 8 && sizeof(TFrom) == 4
- ? Unsafe.BitCast(
- Unsafe.BitCast(
- value
- )
- )
- : UnsignedFallback(value);
+ sizeof(TTo) == sizeof(TFrom) ? Unsafe.BitCast(value)
+ : sizeof(TTo) == 1 && sizeof(TFrom) == 2
+ ? Unsafe.BitCast((byte)Unsafe.BitCast(value))
+ : sizeof(TTo) == 1 && sizeof(TFrom) == 4
+ ? Unsafe.BitCast((byte)Unsafe.BitCast(value))
+ : sizeof(TTo) == 1 && sizeof(TFrom) == 8
+ ? Unsafe.BitCast((byte)Unsafe.BitCast(value))
+ : sizeof(TTo) == 2 && sizeof(TFrom) == 1
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : sizeof(TTo) == 2 && sizeof(TFrom) == 4
+ ? Unsafe.BitCast((ushort)Unsafe.BitCast(value))
+ : sizeof(TTo) == 2 && sizeof(TFrom) == 8
+ ? Unsafe.BitCast((ushort)Unsafe.BitCast(value))
+ : sizeof(TTo) == 4 && sizeof(TFrom) == 1
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : sizeof(TTo) == 4 && sizeof(TFrom) == 2
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : sizeof(TTo) == 4 && sizeof(TFrom) == 8
+ ? Unsafe.BitCast((uint)Unsafe.BitCast(value))
+ : sizeof(TTo) == 8 && sizeof(TFrom) == 1
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : sizeof(TTo) == 8 && sizeof(TFrom) == 2
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : sizeof(TTo) == 8 && sizeof(TFrom) == 4
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : UnsignedFallback(value);
[MethodImpl(MethodImplOptions.NoInlining | MethodImplOptions.AggressiveOptimization)]
static TTo SignedFallback(TFrom _) =>
@@ -741,57 +756,39 @@ static TTo SignedFallback(TFrom _) =>
MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization
)]
static TTo SignedCast(TFrom value) =>
- sizeof(TTo) == sizeof(TFrom)
- ? Unsafe.BitCast(value)
- : sizeof(TTo) == 1 && sizeof(TFrom) == 2
- ? Unsafe.BitCast((sbyte)Unsafe.BitCast(value))
- : sizeof(TTo) == 1 && sizeof(TFrom) == 4
- ? Unsafe.BitCast((sbyte)Unsafe.BitCast(value))
- : sizeof(TTo) == 1 && sizeof(TFrom) == 8
- ? Unsafe.BitCast((sbyte)Unsafe.BitCast(value))
- : sizeof(TTo) == 2 && sizeof(TFrom) == 1
- ? Unsafe.BitCast(Unsafe.BitCast(value))
- : sizeof(TTo) == 2 && sizeof(TFrom) == 4
- ? Unsafe.BitCast(
- (short)Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 2 && sizeof(TFrom) == 8
- ? Unsafe.BitCast(
- (short)Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 4 && sizeof(TFrom) == 1
- ? Unsafe.BitCast(
- Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 4 && sizeof(TFrom) == 2
- ? Unsafe.BitCast(
- Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 4 && sizeof(TFrom) == 8
- ? Unsafe.BitCast(
- (int)Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 8 && sizeof(TFrom) == 1
- ? Unsafe.BitCast(
- Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 8 && sizeof(TFrom) == 2
- ? Unsafe.BitCast(
- Unsafe.BitCast(value)
- )
- : sizeof(TTo) == 8 && sizeof(TFrom) == 4
- ? Unsafe.BitCast(
- Unsafe.BitCast(
- value
- )
- )
- : SignedFallback(value);
+ sizeof(TTo) == sizeof(TFrom) ? Unsafe.BitCast(value)
+ : sizeof(TTo) == 1 && sizeof(TFrom) == 2
+ ? Unsafe.BitCast((sbyte)Unsafe.BitCast(value))
+ : sizeof(TTo) == 1 && sizeof(TFrom) == 4
+ ? Unsafe.BitCast((sbyte)Unsafe.BitCast(value))
+ : sizeof(TTo) == 1 && sizeof(TFrom) == 8
+ ? Unsafe.BitCast((sbyte)Unsafe.BitCast(value))
+ : sizeof(TTo) == 2 && sizeof(TFrom) == 1
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : sizeof(TTo) == 2 && sizeof(TFrom) == 4
+ ? Unsafe.BitCast((short)Unsafe.BitCast(value))
+ : sizeof(TTo) == 2 && sizeof(TFrom) == 8
+ ? Unsafe.BitCast((short)Unsafe.BitCast(value))
+ : sizeof(TTo) == 4 && sizeof(TFrom) == 1
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : sizeof(TTo) == 4 && sizeof(TFrom) == 2
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : sizeof(TTo) == 4 && sizeof(TFrom) == 8
+ ? Unsafe.BitCast((int)Unsafe.BitCast(value))
+ : sizeof(TTo) == 8 && sizeof(TFrom) == 1
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : sizeof(TTo) == 8 && sizeof(TFrom) == 2
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : sizeof(TTo) == 8 && sizeof(TFrom) == 4
+ ? Unsafe.BitCast(Unsafe.BitCast(value))
+ : SignedFallback(value);
return typeof(TTo).IsAssignableTo(typeof(IFloatingPoint<>))
- ? throw new NotImplementedException("Floating points are not supported at this time.")
- : typeof(TTo).IsAssignableTo(typeof(ISignedNumber<>))
- ? SignedCast(value)
- : UnsignedCast(value);
+ ? throw new NotImplementedException(
+ "Floating points are not supported at this time."
+ )
+ : typeof(TTo).IsAssignableTo(typeof(ISignedNumber<>)) ? SignedCast(value)
+ : UnsignedCast(value);
}
///
diff --git a/sources/OpenGL/OpenGL/Enums/GLEnum.gen.cs b/sources/OpenGL/OpenGL/Enums/GLEnum.gen.cs
index af6137ad5e..b57750cb91 100644
--- a/sources/OpenGL/OpenGL/Enums/GLEnum.gen.cs
+++ b/sources/OpenGL/OpenGL/Enums/GLEnum.gen.cs
@@ -3194,7 +3194,7 @@ public enum GLEnum : uint
LayoutDepthAttachmentStencilReadOnlyEXT = unchecked((uint)0x9531),
HandleTypeD3D12FenceEXT = unchecked((uint)0x9594),
D3D12FenceValueEXT = unchecked((uint)0x9595),
- ActiveProgramEXT = unchecked((uint)0x8B8D),
+ ActiveProgramEXT = unchecked((uint)0x8259),
LightModelColorControlEXT = unchecked((uint)0x81F8),
SingleColorEXT = unchecked((uint)0x81F9),
SeparateSpecularColorEXT = unchecked((uint)0x81FA),
diff --git a/sources/OpenGL/OpenGL/GL.gen.cs b/sources/OpenGL/OpenGL/GL.gen.cs
index fb816c59ce..2945dd9f3b 100644
--- a/sources/OpenGL/OpenGL/GL.gen.cs
+++ b/sources/OpenGL/OpenGL/GL.gen.cs
@@ -23,6 +23,8 @@ public partial class ThisThread : IGL.Static
public static partial void MakeCurrent(IGL ctx);
}
+ private readonly unsafe void*[] _slots = new void*[3291];
+
public static IGL Create(INativeContext ctx) => new GL(ctx);
///
diff --git a/sources/OpenGL/OpenGL/gl/GL.gen.cs b/sources/OpenGL/OpenGL/gl/GL.gen.cs
index f581b93235..a5c8c03a33 100644
--- a/sources/OpenGL/OpenGL/gl/GL.gen.cs
+++ b/sources/OpenGL/OpenGL/gl/GL.gen.cs
@@ -7,10 +7,10 @@
namespace Silk.NET.OpenGL;
-[SupportedApiProfile("gles1", MaxVersion = "2.0")]
-[SupportedApiProfile("gles2", MinVersion = "2.0")]
-[SupportedApiProfile("glcore", MinVersion = "3.2")]
[SupportedApiProfile("gl")]
+[SupportedApiProfile("glcore", MinVersion = "3.2")]
+[SupportedApiProfile("gles2", MinVersion = "2.0")]
+[SupportedApiProfile("gles1", MaxVersion = "2.0")]
public unsafe partial class GL : IGL, IGL.Static
{
public partial class DllImport : IGL.Static
@@ -415005,10 +415005,13 @@ public static void WriteMaskEXT(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.Accum([NativeTypeName("GLenum")] uint op, [NativeTypeName("GLfloat")] float value) =>
- ((delegate* unmanaged)nativeContext.LoadFunction("glAccum", "opengl"))(
- op,
- value
- );
+ (
+ (delegate* unmanaged)(
+ _slots[0] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[0] = nativeContext.LoadFunction("glAccum", "opengl")
+ )
+ )(op, value);
[SupportedApiProfile(
"gl",
@@ -415083,10 +415086,13 @@ public static void Accum(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.AccumxOES([NativeTypeName("GLenum")] uint op, [NativeTypeName("GLfixed")] int value) =>
- ((delegate* unmanaged)nativeContext.LoadFunction("glAccumxOES", "opengl"))(
- op,
- value
- );
+ (
+ (delegate* unmanaged)(
+ _slots[1] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[1] = nativeContext.LoadFunction("glAccumxOES", "opengl")
+ )
+ )(op, value);
[SupportedApiProfile("gl", ["GL_OES_fixed_point"])]
[NativeFunction("opengl", EntryPoint = "glAccumxOES")]
@@ -415122,8 +415128,14 @@ uint IGL.AcquireKeyedMutexWin32EXTRaw(
[NativeTypeName("GLuint")] uint timeout
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAcquireKeyedMutexWin32EXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[2] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[2] = nativeContext.LoadFunction(
+ "glAcquireKeyedMutexWin32EXT",
+ "opengl"
+ )
+ )
)(memory, key, timeout);
[return: NativeTypeName("GLboolean")]
@@ -415140,8 +415152,11 @@ public static uint AcquireKeyedMutexWin32EXTRaw(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.ActiveProgramEXT([NativeTypeName("GLuint")] uint program) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glActiveProgramEXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[3] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[3] = nativeContext.LoadFunction("glActiveProgramEXT", "opengl")
+ )
)(program);
[SupportedApiProfile("gl", ["GL_EXT_separate_shader_objects"])]
@@ -415157,8 +415172,11 @@ void IGL.ActiveShaderProgram(
[NativeTypeName("GLuint")] uint program
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glActiveShaderProgram", "opengl")
+ (delegate* unmanaged)(
+ _slots[4] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[4] = nativeContext.LoadFunction("glActiveShaderProgram", "opengl")
+ )
)(pipeline, program);
[SupportedApiProfile(
@@ -415200,8 +415218,11 @@ void IGL.ActiveShaderProgramEXT(
[NativeTypeName("GLuint")] uint program
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glActiveShaderProgramEXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[5] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[5] = nativeContext.LoadFunction("glActiveShaderProgramEXT", "opengl")
+ )
)(pipeline, program);
[SupportedApiProfile("gles2", ["GL_EXT_separate_shader_objects"])]
@@ -415215,8 +415236,11 @@ public static void ActiveShaderProgramEXT(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.ActiveStencilFaceEXT([NativeTypeName("GLenum")] uint face) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glActiveStencilFaceEXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[6] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[6] = nativeContext.LoadFunction("glActiveStencilFaceEXT", "opengl")
+ )
)(face);
[SupportedApiProfile("gl", ["GL_EXT_stencil_two_side"])]
@@ -415240,9 +415264,13 @@ public static void ActiveStencilFaceEXT(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.ActiveTexture([NativeTypeName("GLenum")] uint texture) =>
- ((delegate* unmanaged)nativeContext.LoadFunction("glActiveTexture", "opengl"))(
- texture
- );
+ (
+ (delegate* unmanaged)(
+ _slots[7] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[7] = nativeContext.LoadFunction("glActiveTexture", "opengl")
+ )
+ )(texture);
[SupportedApiProfile(
"gl",
@@ -415364,8 +415392,11 @@ public static void ActiveTexture(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.ActiveTextureARB([NativeTypeName("GLenum")] uint texture) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glActiveTextureARB", "opengl")
+ (delegate* unmanaged)(
+ _slots[8] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[8] = nativeContext.LoadFunction("glActiveTextureARB", "opengl")
+ )
)(texture);
[SupportedApiProfile("gl", ["GL_ARB_multitexture"])]
@@ -415393,8 +415424,11 @@ void IGL.ActiveVaryingNV(
[NativeTypeName("const GLchar *")] sbyte* name
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glActiveVaryingNV", "opengl")
+ (delegate* unmanaged)(
+ _slots[9] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[9] = nativeContext.LoadFunction("glActiveVaryingNV", "opengl")
+ )
)(program, name);
[SupportedApiProfile("gl", ["GL_NV_transform_feedback"])]
@@ -415436,8 +415470,11 @@ void IGL.AlphaFragmentOp1ATI(
[NativeTypeName("GLuint")] uint arg1Mod
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAlphaFragmentOp1ATI", "opengl")
+ (delegate* unmanaged)(
+ _slots[10] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[10] = nativeContext.LoadFunction("glAlphaFragmentOp1ATI", "opengl")
+ )
)(op, dst, dstMod, arg1, arg1Rep, arg1Mod);
[SupportedApiProfile("gl", ["GL_ATI_fragment_shader"])]
@@ -415496,8 +415533,11 @@ void IGL.AlphaFragmentOp2ATI(
[NativeTypeName("GLuint")] uint arg2Mod
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAlphaFragmentOp2ATI", "opengl")
+ (delegate* unmanaged)(
+ _slots[11] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[11] = nativeContext.LoadFunction("glAlphaFragmentOp2ATI", "opengl")
+ )
)(op, dst, dstMod, arg1, arg1Rep, arg1Mod, arg2, arg2Rep, arg2Mod);
[SupportedApiProfile("gl", ["GL_ATI_fragment_shader"])]
@@ -415606,8 +415646,11 @@ void IGL.AlphaFragmentOp3ATI(
uint,
uint,
uint,
- void>)
- nativeContext.LoadFunction("glAlphaFragmentOp3ATI", "opengl")
+ void>)(
+ _slots[12] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[12] = nativeContext.LoadFunction("glAlphaFragmentOp3ATI", "opengl")
+ )
)(op, dst, dstMod, arg1, arg1Rep, arg1Mod, arg2, arg2Rep, arg2Mod, arg3, arg3Rep, arg3Mod);
[SupportedApiProfile("gl", ["GL_ATI_fragment_shader"])]
@@ -415711,8 +415754,11 @@ void IGL.AlphaFunc(
[NativeTypeName("GLfloat")] float @ref
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAlphaFunc", "opengl")
+ (delegate* unmanaged)(
+ _slots[13] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[13] = nativeContext.LoadFunction("glAlphaFunc", "opengl")
+ )
)(func, @ref);
[SupportedApiProfile(
@@ -415794,8 +415840,11 @@ void IGL.AlphaFuncQCOM(
[NativeTypeName("GLclampf")] float @ref
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAlphaFuncQCOM", "opengl")
+ (delegate* unmanaged)(
+ _slots[14] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[14] = nativeContext.LoadFunction("glAlphaFuncQCOM", "opengl")
+ )
)(func, @ref);
[SupportedApiProfile("gles2", ["GL_QCOM_alpha_test"])]
@@ -415812,8 +415861,11 @@ void IGL.AlphaFuncx(
[NativeTypeName("GLfixed")] int @ref
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAlphaFuncx", "opengl")
+ (delegate* unmanaged)(
+ _slots[15] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[15] = nativeContext.LoadFunction("glAlphaFuncx", "opengl")
+ )
)(func, @ref);
[SupportedApiProfile("gles1", ["GL_VERSION_ES_CM_1_0"], MinVersion = "1.0")]
@@ -415845,8 +415897,11 @@ void IGL.AlphaFuncxOES(
[NativeTypeName("GLfixed")] int @ref
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAlphaFuncxOES", "opengl")
+ (delegate* unmanaged)(
+ _slots[16] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[16] = nativeContext.LoadFunction("glAlphaFuncxOES", "opengl")
+ )
)(func, @ref);
[SupportedApiProfile("gl", ["GL_OES_fixed_point"])]
@@ -415877,8 +415932,14 @@ public static void AlphaFuncxOES(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.AlphaToCoverageDitherControlNV([NativeTypeName("GLenum")] uint mode) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAlphaToCoverageDitherControlNV", "opengl")
+ (delegate* unmanaged)(
+ _slots[17] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[17] = nativeContext.LoadFunction(
+ "glAlphaToCoverageDitherControlNV",
+ "opengl"
+ )
+ )
)(mode);
[SupportedApiProfile("gl", ["GL_NV_alpha_to_coverage_dither_control"])]
@@ -415890,8 +415951,14 @@ public static void AlphaToCoverageDitherControlNV([NativeTypeName("GLenum")] uin
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.ApplyFramebufferAttachmentCMAAIntel() =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glApplyFramebufferAttachmentCMAAINTEL", "opengl")
+ (delegate* unmanaged)(
+ _slots[18] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[18] = nativeContext.LoadFunction(
+ "glApplyFramebufferAttachmentCMAAINTEL",
+ "opengl"
+ )
+ )
)();
[SupportedApiProfile("gl", ["GL_INTEL_framebuffer_CMAA"])]
@@ -415905,8 +415972,11 @@ public static void ApplyFramebufferAttachmentCMAAIntel() =>
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.ApplyTextureEXT([NativeTypeName("GLenum")] uint mode) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glApplyTextureEXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[19] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[19] = nativeContext.LoadFunction("glApplyTextureEXT", "opengl")
+ )
)(mode);
[SupportedApiProfile("gl", ["GL_EXT_light_texture"])]
@@ -415935,8 +416005,11 @@ uint IGL.AreProgramsResidentNV(
[NativeTypeName("GLboolean *")] uint* residences
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAreProgramsResidentNV", "opengl")
+ (delegate* unmanaged)(
+ _slots[20] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[20] = nativeContext.LoadFunction("glAreProgramsResidentNV", "opengl")
+ )
)(n, programs, residences);
[return: NativeTypeName("GLboolean")]
@@ -415982,8 +416055,11 @@ uint IGL.AreTexturesResident(
[NativeTypeName("GLboolean *")] uint* residences
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAreTexturesResident", "opengl")
+ (delegate* unmanaged)(
+ _slots[21] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[21] = nativeContext.LoadFunction("glAreTexturesResident", "opengl")
+ )
)(n, textures, residences);
[return: NativeTypeName("GLboolean")]
@@ -416075,8 +416151,11 @@ uint IGL.AreTexturesResidentEXT(
[NativeTypeName("GLboolean *")] uint* residences
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAreTexturesResidentEXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[22] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[22] = nativeContext.LoadFunction("glAreTexturesResidentEXT", "opengl")
+ )
)(n, textures, residences);
[return: NativeTypeName("GLboolean")]
@@ -416117,7 +416196,13 @@ public static MaybeBool AreTexturesResidentEXT(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.ArrayElement([NativeTypeName("GLint")] int i) =>
- ((delegate* unmanaged)nativeContext.LoadFunction("glArrayElement", "opengl"))(i);
+ (
+ (delegate* unmanaged)(
+ _slots[23] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[23] = nativeContext.LoadFunction("glArrayElement", "opengl")
+ )
+ )(i);
[SupportedApiProfile(
"gl",
@@ -416149,9 +416234,13 @@ void IGL.ArrayElement([NativeTypeName("GLint")] int i) =>
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.ArrayElementEXT([NativeTypeName("GLint")] int i) =>
- ((delegate* unmanaged)nativeContext.LoadFunction("glArrayElementEXT", "opengl"))(
- i
- );
+ (
+ (delegate* unmanaged)(
+ _slots[24] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[24] = nativeContext.LoadFunction("glArrayElementEXT", "opengl")
+ )
+ )(i);
[SupportedApiProfile("gl", ["GL_EXT_vertex_array"])]
[NativeFunction("opengl", EntryPoint = "glArrayElementEXT")]
@@ -416169,8 +416258,11 @@ void IGL.ArrayObjectATI(
[NativeTypeName("GLuint")] uint offset
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glArrayObjectATI", "opengl")
+ (delegate* unmanaged)(
+ _slots[25] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[25] = nativeContext.LoadFunction("glArrayObjectATI", "opengl")
+ )
)(array, size, type, stride, buffer, offset);
[SupportedApiProfile("gl", ["GL_ATI_vertex_array_object"])]
@@ -416239,8 +416331,14 @@ uint IGL.AsyncCopyBufferSubDataNVX(
uint,
uint*,
ulong*,
- uint>)
- nativeContext.LoadFunction("glAsyncCopyBufferSubDataNVX", "opengl")
+ uint>)(
+ _slots[26] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[26] = nativeContext.LoadFunction(
+ "glAsyncCopyBufferSubDataNVX",
+ "opengl"
+ )
+ )
)(
waitSemaphoreCount,
waitSemaphoreArray,
@@ -416420,8 +416518,14 @@ uint IGL.AsyncCopyImageSubDataNVX(
uint,
uint*,
ulong*,
- uint>)
- nativeContext.LoadFunction("glAsyncCopyImageSubDataNVX", "opengl")
+ uint>)(
+ _slots[27] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[27] = nativeContext.LoadFunction(
+ "glAsyncCopyImageSubDataNVX",
+ "opengl"
+ )
+ )
)(
waitSemaphoreCount,
waitSemaphoreArray,
@@ -416623,8 +416727,11 @@ public static uint AsyncCopyImageSubDataNVX(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.AsyncMarkerSGIX([NativeTypeName("GLuint")] uint marker) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAsyncMarkerSGIX", "opengl")
+ (delegate* unmanaged)(
+ _slots[28] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[28] = nativeContext.LoadFunction("glAsyncMarkerSGIX", "opengl")
+ )
)(marker);
[SupportedApiProfile("gl", ["GL_SGIX_async"])]
@@ -416639,8 +416746,11 @@ void IGL.AttachObjectARB(
[NativeTypeName("GLhandleARB")] uint obj
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAttachObjectARB", "opengl")
+ (delegate* unmanaged)(
+ _slots[29] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[29] = nativeContext.LoadFunction("glAttachObjectARB", "opengl")
+ )
)(containerObj, obj);
[SupportedApiProfile("gl", ["GL_ARB_shader_objects"])]
@@ -416657,8 +416767,11 @@ void IGL.AttachShader(
[NativeTypeName("GLuint")] uint shader
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glAttachShader", "opengl")
+ (delegate* unmanaged)(
+ _slots[30] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[30] = nativeContext.LoadFunction("glAttachShader", "opengl")
+ )
)(program, shader);
[SupportedApiProfile(
@@ -416713,7 +416826,13 @@ public static void AttachShader(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.Begin([NativeTypeName("GLenum")] uint mode) =>
- ((delegate* unmanaged)nativeContext.LoadFunction("glBegin", "opengl"))(mode);
+ (
+ (delegate* unmanaged)(
+ _slots[31] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[31] = nativeContext.LoadFunction("glBegin", "opengl")
+ )
+ )(mode);
[SupportedApiProfile(
"gl",
@@ -416786,8 +416905,11 @@ void IGL.BeginConditionalRender(
[NativeTypeName("GLenum")] uint mode
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginConditionalRender", "opengl")
+ (delegate* unmanaged)(
+ _slots[32] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[32] = nativeContext.LoadFunction("glBeginConditionalRender", "opengl")
+ )
)(id, mode);
[SupportedApiProfile(
@@ -416885,8 +417007,14 @@ void IGL.BeginConditionalRenderNV(
[NativeTypeName("GLenum")] uint mode
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginConditionalRenderNV", "opengl")
+ (delegate* unmanaged)(
+ _slots[33] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[33] = nativeContext.LoadFunction(
+ "glBeginConditionalRenderNV",
+ "opengl"
+ )
+ )
)(id, mode);
[SupportedApiProfile("gl", ["GL_NV_conditional_render"])]
@@ -416919,8 +417047,14 @@ public static void BeginConditionalRenderNV(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.BeginConditionalRenderNVX([NativeTypeName("GLuint")] uint id) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginConditionalRenderNVX", "opengl")
+ (delegate* unmanaged)(
+ _slots[34] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[34] = nativeContext.LoadFunction(
+ "glBeginConditionalRenderNVX",
+ "opengl"
+ )
+ )
)(id);
[SupportedApiProfile("gl", ["GL_NVX_conditional_render"])]
@@ -416932,8 +417066,11 @@ public static void BeginConditionalRenderNVX([NativeTypeName("GLuint")] uint id)
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.BeginFragmentShaderATI() =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginFragmentShaderATI", "opengl")
+ (delegate* unmanaged)(
+ _slots[35] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[35] = nativeContext.LoadFunction("glBeginFragmentShaderATI", "opengl")
+ )
)();
[SupportedApiProfile("gl", ["GL_ATI_fragment_shader"])]
@@ -416944,8 +417081,11 @@ void IGL.BeginFragmentShaderATI() =>
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.BeginOcclusionQueryNV([NativeTypeName("GLuint")] uint id) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginOcclusionQueryNV", "opengl")
+ (delegate* unmanaged)(
+ _slots[36] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[36] = nativeContext.LoadFunction("glBeginOcclusionQueryNV", "opengl")
+ )
)(id);
[SupportedApiProfile("gl", ["GL_NV_occlusion_query"])]
@@ -416957,8 +417097,11 @@ public static void BeginOcclusionQueryNV([NativeTypeName("GLuint")] uint id) =>
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.BeginPerfMonitorAMD([NativeTypeName("GLuint")] uint monitor) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginPerfMonitorAMD", "opengl")
+ (delegate* unmanaged)(
+ _slots[37] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[37] = nativeContext.LoadFunction("glBeginPerfMonitorAMD", "opengl")
+ )
)(monitor);
[SupportedApiProfile("gl", ["GL_AMD_performance_monitor"])]
@@ -416972,8 +417115,11 @@ public static void BeginPerfMonitorAMD([NativeTypeName("GLuint")] uint monitor)
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.BeginPerfQueryIntel([NativeTypeName("GLuint")] uint queryHandle) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginPerfQueryINTEL", "opengl")
+ (delegate* unmanaged)(
+ _slots[38] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[38] = nativeContext.LoadFunction("glBeginPerfQueryINTEL", "opengl")
+ )
)(queryHandle);
[SupportedApiProfile("gl", ["GL_INTEL_performance_query"])]
@@ -416990,8 +417136,11 @@ void IGL.BeginQuery(
[NativeTypeName("GLuint")] uint id
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginQuery", "opengl")
+ (delegate* unmanaged)(
+ _slots[39] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[39] = nativeContext.LoadFunction("glBeginQuery", "opengl")
+ )
)(target, id);
[SupportedApiProfile(
@@ -417101,8 +417250,11 @@ void IGL.BeginQueryARB(
[NativeTypeName("GLuint")] uint id
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginQueryARB", "opengl")
+ (delegate* unmanaged)(
+ _slots[40] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[40] = nativeContext.LoadFunction("glBeginQueryARB", "opengl")
+ )
)(target, id);
[SupportedApiProfile("gl", ["GL_ARB_occlusion_query"])]
@@ -417134,8 +417286,11 @@ void IGL.BeginQueryEXT(
[NativeTypeName("GLuint")] uint id
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginQueryEXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[41] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[41] = nativeContext.LoadFunction("glBeginQueryEXT", "opengl")
+ )
)(target, id);
[SupportedApiProfile(
@@ -417174,8 +417329,11 @@ void IGL.BeginQueryIndexed(
[NativeTypeName("GLuint")] uint id
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginQueryIndexed", "opengl")
+ (delegate* unmanaged)(
+ _slots[42] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[42] = nativeContext.LoadFunction("glBeginQueryIndexed", "opengl")
+ )
)(target, index, id);
[SupportedApiProfile(
@@ -417261,8 +417419,11 @@ public static void BeginQueryIndexed(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.BeginTransformFeedback([NativeTypeName("GLenum")] uint primitiveMode) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginTransformFeedback", "opengl")
+ (delegate* unmanaged)(
+ _slots[43] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[43] = nativeContext.LoadFunction("glBeginTransformFeedback", "opengl")
+ )
)(primitiveMode);
[SupportedApiProfile(
@@ -417353,8 +417514,14 @@ public static void BeginTransformFeedback(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.BeginTransformFeedbackEXT([NativeTypeName("GLenum")] uint primitiveMode) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginTransformFeedbackEXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[44] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[44] = nativeContext.LoadFunction(
+ "glBeginTransformFeedbackEXT",
+ "opengl"
+ )
+ )
)(primitiveMode);
[SupportedApiProfile("gl", ["GL_EXT_transform_feedback"])]
@@ -417379,8 +417546,14 @@ public static void BeginTransformFeedbackEXT(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.BeginTransformFeedbackNV([NativeTypeName("GLenum")] uint primitiveMode) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginTransformFeedbackNV", "opengl")
+ (delegate* unmanaged)(
+ _slots[45] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[45] = nativeContext.LoadFunction(
+ "glBeginTransformFeedbackNV",
+ "opengl"
+ )
+ )
)(primitiveMode);
[SupportedApiProfile("gl", ["GL_NV_transform_feedback"])]
@@ -417405,8 +417578,11 @@ public static void BeginTransformFeedbackNV(
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.BeginVertexShaderEXT() =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginVertexShaderEXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[46] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[46] = nativeContext.LoadFunction("glBeginVertexShaderEXT", "opengl")
+ )
)();
[SupportedApiProfile("gl", ["GL_EXT_vertex_shader"])]
@@ -417417,8 +417593,11 @@ void IGL.BeginVertexShaderEXT() =>
[MethodImpl(MethodImplOptions.AggressiveInlining | MethodImplOptions.AggressiveOptimization)]
void IGL.BeginVideoCaptureNV([NativeTypeName("GLuint")] uint video_capture_slot) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBeginVideoCaptureNV", "opengl")
+ (delegate* unmanaged)(
+ _slots[47] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[47] = nativeContext.LoadFunction("glBeginVideoCaptureNV", "opengl")
+ )
)(video_capture_slot);
[SupportedApiProfile("gl", ["GL_NV_video_capture"])]
@@ -417434,8 +417613,11 @@ void IGL.BindAttribLocation(
[NativeTypeName("const GLchar *")] sbyte* name
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBindAttribLocation", "opengl")
+ (delegate* unmanaged)(
+ _slots[48] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[48] = nativeContext.LoadFunction("glBindAttribLocation", "opengl")
+ )
)(program, index, name);
[SupportedApiProfile(
@@ -417561,8 +417743,11 @@ void IGL.BindAttribLocationARB(
[NativeTypeName("const GLcharARB *")] sbyte* name
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBindAttribLocationARB", "opengl")
+ (delegate* unmanaged)(
+ _slots[49] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[49] = nativeContext.LoadFunction("glBindAttribLocationARB", "opengl")
+ )
)(programObj, index, name);
[SupportedApiProfile("gl", ["GL_ARB_vertex_shader"])]
@@ -417603,8 +417788,11 @@ void IGL.BindBuffer(
[NativeTypeName("GLuint")] uint buffer
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBindBuffer", "opengl")
+ (delegate* unmanaged)(
+ _slots[50] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[50] = nativeContext.LoadFunction("glBindBuffer", "opengl")
+ )
)(target, buffer);
[SupportedApiProfile(
@@ -417726,8 +417914,11 @@ void IGL.BindBufferARB(
[NativeTypeName("GLuint")] uint buffer
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBindBufferARB", "opengl")
+ (delegate* unmanaged)(
+ _slots[51] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[51] = nativeContext.LoadFunction("glBindBufferARB", "opengl")
+ )
)(target, buffer);
[SupportedApiProfile("gl", ["GL_ARB_vertex_buffer_object"])]
@@ -417760,8 +417951,11 @@ void IGL.BindBufferBase(
[NativeTypeName("GLuint")] uint buffer
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBindBufferBase", "opengl")
+ (delegate* unmanaged)(
+ _slots[52] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[52] = nativeContext.LoadFunction("glBindBufferBase", "opengl")
+ )
)(target, index, buffer);
[SupportedApiProfile(
@@ -417867,8 +418061,11 @@ void IGL.BindBufferBaseEXT(
[NativeTypeName("GLuint")] uint buffer
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBindBufferBaseEXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[53] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[53] = nativeContext.LoadFunction("glBindBufferBaseEXT", "opengl")
+ )
)(target, index, buffer);
[SupportedApiProfile("gl", ["GL_EXT_transform_feedback"])]
@@ -417904,8 +418101,11 @@ void IGL.BindBufferBaseNV(
[NativeTypeName("GLuint")] uint buffer
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBindBufferBaseNV", "opengl")
+ (delegate* unmanaged)(
+ _slots[54] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[54] = nativeContext.LoadFunction("glBindBufferBaseNV", "opengl")
+ )
)(target, index, buffer);
[SupportedApiProfile("gl", ["GL_NV_transform_feedback"])]
@@ -417942,8 +418142,11 @@ void IGL.BindBufferOffsetEXT(
[NativeTypeName("GLintptr")] nint offset
) =>
(
- (delegate* unmanaged)
- nativeContext.LoadFunction("glBindBufferOffsetEXT", "opengl")
+ (delegate* unmanaged)(
+ _slots[55] is not null and var loadedFnPtr
+ ? loadedFnPtr
+ : _slots[55] = nativeContext.LoadFunction("glBindBufferOffsetEXT", "opengl")
+ )
)(target, index, buffer, offset);
[SupportedApiProfile("gl", ["GL_EXT_transform_feedback"])]
@@ -417983,8 +418186,11 @@ void IGL.BindBufferOffsetNV(
[NativeTypeName("GLintptr")] nint offset
) =>
(
- (delegate* unmanaged