// // Generated by StgSharp.GenerateGL on 2026-08-25 09:22:55Z // Version: 4.4 // using System; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using StgSharp.Graphics.OpenGL; namespace StgSharp.Graphics.OpenGL { public unsafe partial class OpenGLFunction { [MethodImpl(MethodImplOptions.AggressiveInlining)] public void BindBuffersBase(uint target, uint first, ReadOnlySpan buffers) { fixed (uint* buffersPtr = buffers) { Context.glBindBuffersBase(target, first, checked((int)buffers.Length), buffersPtr); } } [MethodImpl(MethodImplOptions.AggressiveInlining)] public void BindBuffersRange(uint target, uint first, ReadOnlySpan buffers, ReadOnlySpan offsets, ReadOnlySpan sizes) { if (offsets.Length != buffers.Length) { throw new ArgumentException("Span lengths controlled by count must match.", nameof(offsets)); } if (sizes.Length != buffers.Length) { throw new ArgumentException("Span lengths controlled by count must match.", nameof(sizes)); } fixed (uint* buffersPtr = buffers) { fixed (nint* offsetsPtr = offsets) { fixed (nint* sizesPtr = sizes) { Context.glBindBuffersRange(target, first, checked((int)buffers.Length), buffersPtr, offsetsPtr, sizesPtr); } } } } [MethodImpl(MethodImplOptions.AggressiveInlining)] public void BindImageTextures(uint first, ReadOnlySpan textures) { fixed (uint* texturesPtr = textures) { Context.glBindImageTextures(first, checked((int)textures.Length), texturesPtr); } } [MethodImpl(MethodImplOptions.AggressiveInlining)] public void BindSamplers(uint first, ReadOnlySpan samplers) { fixed (uint* samplersPtr = samplers) { Context.glBindSamplers(first, checked((int)samplers.Length), samplersPtr); } } [MethodImpl(MethodImplOptions.AggressiveInlining)] public void BindTextures(uint first, ReadOnlySpan textures) { fixed (uint* texturesPtr = textures) { Context.glBindTextures(first, checked((int)textures.Length), texturesPtr); } } [MethodImpl(MethodImplOptions.AggressiveInlining)] public void BindVertexBuffers(uint first, ReadOnlySpan buffers, ReadOnlySpan offsets, ReadOnlySpan strides) { if (offsets.Length != buffers.Length) { throw new ArgumentException("Span lengths controlled by count must match.", nameof(offsets)); } if (strides.Length != buffers.Length) { throw new ArgumentException("Span lengths controlled by count must match.", nameof(strides)); } fixed (uint* buffersPtr = buffers) { fixed (nint* offsetsPtr = offsets) { fixed (int* stridesPtr = strides) { Context.glBindVertexBuffers(first, checked((int)buffers.Length), buffersPtr, offsetsPtr, stridesPtr); } } } } [MethodImpl(MethodImplOptions.AggressiveInlining)] public void BufferStorage(uint target, nint size, void* data, uint flags) { Context.glBufferStorage(target, size, data, flags); } [MethodImpl(MethodImplOptions.AggressiveInlining)] public void ClearTexImage(GlHandle texture, int level, uint format, uint type, void* data) { Context.glClearTexImage(texture.Value, level, format, type, data); } [MethodImpl(MethodImplOptions.AggressiveInlining)] public void ClearTexSubImage(GlHandle texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, uint format, uint type, void* data) { Context.glClearTexSubImage(texture.Value, level, xoffset, yoffset, zoffset, width, height, depth, format, type, data); } } }