-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathgl.Version_4_5.cs
7474 lines (6948 loc) · 345 KB
/
gl.Version_4_5.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
#region Copyright and License
// Copyright (c) 2013-2014 The Khronos Group Inc.
// Copyright (c) of C# port 2014 by Shinta <shintadono@googlemail.com>
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and/or associated documentation files (the
// "Materials"), to deal in the Materials without restriction, including
// without limitation the rights to use, copy, modify, merge, publish,
// distribute, sublicense, and/or sell copies of the Materials, and to
// permit persons to whom the Materials are furnished to do so, subject to
// the following conditions:
//
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Materials.
//
// THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
// CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
// TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
// MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
#endregion
using System;
using System.Runtime.InteropServices;
namespace OpenGL.Core
{
using Delegates;
namespace Delegates
{
/// <summary>
/// Controls the clipping volume behavior and the clip coordinate to window coordinate transformation behavior.
/// </summary>
/// <param name="origin">A <see cref="glOrientationOrigin"/> specifying the clip control origin.</param>
/// <param name="depth">A <see cref="glClipDepthMode"/> specifying the clip control depth mode.</param>
public delegate void glClipControl(glOrientationOrigin origin, glClipDepthMode depth);
internal delegate void glCreateTransformFeedback(int one, out uint id);
internal delegate void glCreateTransformFeedbacks(int count, uint[] ids);
/// <summary>
/// Binds a buffer object to a transform feedback object.
/// </summary>
/// <param name="xfb">The name of the transform feedback object.</param>
/// <param name="index">The index of the binding point of the transform feedback buffer object.</param>
/// <param name="buffer">The name of the buffer object.</param>
public delegate void glTransformFeedbackBufferBase(uint xfb, uint index, uint buffer);
internal delegate void glTransformFeedbackBufferRange_32(uint xfb, uint index, uint buffer, int offset, int size);
internal delegate void glTransformFeedbackBufferRange_64(uint xfb, uint index, uint buffer, long offset, long size);
/// <summary>
/// Returns the parameters of transform feedback objects.
/// </summary>
/// <param name="xfb">The name of the transform feedback object.</param>
/// <param name="pname">A <see cref="glTransformFeedbackParameter"/> specifying the parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetTransformFeedbacki(uint xfb, glTransformFeedbackParameter pname, out int param);
/// <summary>
/// Returns the parameters of transform feedback objects.
/// </summary>
/// <param name="xfb">The name of the transform feedback object.</param>
/// <param name="pname">A <see cref="glTransformFeedbackParameter"/> specifying the parameter.</param>
/// <param name="param">Returns the requested valu(e).</param>
public delegate void glGetTransformFeedbackiv(uint xfb, glTransformFeedbackParameter pname, int[] param);
/// <summary>
/// Returns the parameters of transform feedback buffer buffer objects.
/// </summary>
/// <param name="xfb">The name of the transform feedback buffer object.</param>
/// <param name="pname">A <see cref="glTransformFeedbackParameter"/> specifying the parameter.</param>
/// <param name="index">The index of the buffer binding point.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetTransformFeedbacki_(uint xfb, glTransformFeedbackParameter pname, uint index, out int param);
/// <summary>
/// Returns the parameters of transform feedback buffer buffer objects.
/// </summary>
/// <param name="xfb">The name of the transform feedback buffer object.</param>
/// <param name="pname">A <see cref="glTransformFeedbackParameter"/> specifying the parameter.</param>
/// <param name="index">The index of the buffer binding point.</param>
/// <param name="param">Returns the requested value(s).</param>
public delegate void glGetTransformFeedbacki_v(uint xfb, glTransformFeedbackParameter pname, uint index, int[] param);
/// <summary>
/// Returns the parameters of transform feedback buffer buffer objects.
/// </summary>
/// <param name="xfb">The name of the transform feedback buffer object.</param>
/// <param name="pname">A <see cref="glTransformFeedbackParameter"/> specifying the parameter.</param>
/// <param name="index">The index of the buffer binding point.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetTransformFeedbacki64_(uint xfb, glTransformFeedbackParameter pname, uint index, out long param);
/// <summary>
/// Returns the parameters of transform feedback buffer buffer objects.
/// </summary>
/// <param name="xfb">The name of the transform feedback buffer object.</param>
/// <param name="pname">A <see cref="glTransformFeedbackParameter"/> specifying the parameter.</param>
/// <param name="index">The index of the buffer binding point.</param>
/// <param name="param">Returns the requested value(s).</param>
public delegate void glGetTransformFeedbacki64_v(uint xfb, glTransformFeedbackParameter pname, uint index, long[] param);
internal delegate void glCreateBuffer(int one, out uint buffer);
internal delegate void glCreateBuffers(int count, uint[] buffers);
internal delegate void glNamedBufferStorage_32(uint buffer, int size, IntPtr data, glBufferStorageFlag flags);
internal delegate void glNamedBufferStorage_64(uint buffer, long size, IntPtr data, glBufferStorageFlag flags);
internal delegate void glNamedBufferData_32(uint buffer, int size, IntPtr data, glBufferUsage usage);
internal delegate void glNamedBufferData_64(uint buffer, long size, IntPtr data, glBufferUsage usage);
internal delegate void glNamedBufferSubData_32(uint buffer, int offset, int size, IntPtr data);
internal delegate void glNamedBufferSubData_64(uint buffer, long offset, long size, IntPtr data);
internal delegate void glCopyNamedBufferSubData_32(uint readBuffer, uint writeBuffer, int readOffset, int writeOffset, int size);
internal delegate void glCopyNamedBufferSubData_64(uint readBuffer, uint writeBuffer, long readOffset, long writeOffset, long size);
internal delegate void glClearNamedBufferData(uint buffer, glInternalFormat internalformat, glPixelFormat format, glPixelDataType type, IntPtr data);
internal delegate void glClearNamedBufferSubData_32(uint buffer, glInternalFormat internalformat, int offset, int size, glPixelFormat format, glPixelDataType type, IntPtr data);
internal delegate void glClearNamedBufferSubData_64(uint buffer, glInternalFormat internalformat, long offset, long size, glPixelFormat format, glPixelDataType type, IntPtr data);
/// <summary>
/// Maps a data store into client memory.
/// </summary>
/// <param name="buffer">The name of buffer object.</param>
/// <param name="access">A <see cref="glAccess"/> specifying the access.</param>
/// <returns>The pointer to the data. Use result with Marshal.Copy(...); to access data.</returns>
public delegate IntPtr glMapNamedBuffer(uint buffer, glAccess access);
internal delegate IntPtr glMapNamedBufferRange_32(uint buffer, int offset, int length, glMapBufferRangeAccess access);
internal delegate IntPtr glMapNamedBufferRange_64(uint buffer, long offset, long length, glMapBufferRangeAccess access);
/// <summary>
/// Releases a mapped data store.
/// </summary>
/// <param name="buffer">The name of buffer object.</param>
/// <returns><b>true</b> unless the data store contents have become corrupt during the time the data store was mapped. If <b>false</b> is returned an application must reinitialize the data store.</returns>
[return: MarshalAs(UnmanagedType.I1)]
public delegate bool glUnmapNamedBuffer(uint buffer);
internal delegate void glFlushMappedNamedBufferRange_32(uint buffer, int offset, int length);
internal delegate void glFlushMappedNamedBufferRange_64(uint buffer, long offset, long length);
/// <summary>
/// Returns the parameters of buffer objects.
/// </summary>
/// <param name="buffer">The name of the buffer object.</param>
/// <param name="pname">A <see cref="glGetBufferParameter"/> specifying the parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetNamedBufferParameteri(uint buffer, glGetBufferParameter pname, out int param);
/// <summary>
/// Returns the parameters of buffer objects.
/// </summary>
/// <param name="buffer">The name of the buffer object.</param>
/// <param name="pname">A <see cref="glGetBufferParameter"/> specifying the parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetNamedBufferParameteriv(uint buffer, glGetBufferParameter pname, int[] @params);
/// <summary>
/// Returns the parameters of buffer objects.
/// </summary>
/// <param name="buffer">The name of the buffer object.</param>
/// <param name="pname">A <see cref="glGetBufferParameter"/> specifying the parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetNamedBufferParameteri64(uint buffer, glGetBufferParameter pname, out long param);
/// <summary>
/// Returns the parameters of buffer objects.
/// </summary>
/// <param name="buffer">The name of the buffer object.</param>
/// <param name="pname">A <see cref="glGetBufferParameter"/> specifying the parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetNamedBufferParameteri64v(uint buffer, glGetBufferParameter pname, long[] @params);
/// <summary>
/// Returns the pointer to a mapped data store of a buffer object.
/// </summary>
/// <param name="buffer">The name of the buffer object.</param>
/// <param name="pname">Must be <see cref="glGetBufferParameter.BUFFER_MAP_POINTER"/>.</param>
/// <param name="param">The pointer to the mapped data store.</param>
public delegate void glGetNamedBufferPointerv(uint buffer, glGetBufferParameter pname, out IntPtr param);
internal delegate void glGetNamedBufferSubData_32(uint buffer, int offset, int size, IntPtr data);
internal delegate void glGetNamedBufferSubData_64(uint buffer, long offset, long size, IntPtr data);
internal delegate void glCreateFramebuffer(int one, out uint framebuffer);
internal delegate void glCreateFramebuffers(int count, uint[] framebuffers);
/// <summary>
/// Attaches renderbuffers as a logical buffer of framebuffer objects.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="attachment">A <see cref="glBuffer"/> specifying the framebuffer attachment.</param>
/// <param name="renderbuffertarget">A <see cref="glRenderbufferTarget"/> specifying the renderbuffer target.</param>
/// <param name="renderbuffer">The name of the renderbuffer.</param>
public delegate void glNamedFramebufferRenderbuffer(uint framebuffer, glBuffer attachment, glRenderbufferTarget renderbuffertarget, uint renderbuffer);
/// <summary>
/// Sets parameters of framebuffer objects.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="pname">A <see cref="glFramebufferParameter"/> specifying the parameter.</param>
/// <param name="param">The new value.</param>
public delegate void glNamedFramebufferParameteri(uint framebuffer, glFramebufferParameter pname, int param);
/// <summary>
/// Attaches levels of texture objects as a logical buffer of framebuffer objects.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="attachment">A <see cref="glBuffer"/> specifying the framebuffer attachment.</param>
/// <param name="texture">The name of the texture object.</param>
/// <param name="level">The level-of-detail.</param>
public delegate void glNamedFramebufferTexture(uint framebuffer, glBuffer attachment, uint texture, int level);
/// <summary>
/// Attaches layers of texture objects as a logical buffer of framebuffer objects.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="attachment">A <see cref="glBuffer"/> specifying the framebuffer attachment.</param>
/// <param name="texture">The name of the texture object.</param>
/// <param name="level">The level-of-detail.</param>
/// <param name="layer">The layer number.</param>
public delegate void glNamedFramebufferTextureLayer(uint framebuffer, glBuffer attachment, uint texture, int level, int layer);
/// <summary>
/// Sets the color buffers to draw into.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object. (Zero for the default framebuffer.)</param>
/// <param name="buf">A <see cref="glBuffer"/> specifying the buffer.</param>
public delegate void glNamedFramebufferDrawBuffer(uint framebuffer, glBuffer buf);
/// <summary>
/// Sets the color buffers to draw into.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object. (Zero for the default framebuffer.)</param>
/// <param name="count">Number of buffers.</param>
/// <param name="bufs">A array of <see cref="glBuffer"/>s specifying the buffers.</param>
public delegate void glNamedFramebufferDrawBuffers(uint framebuffer, int count, params glBuffer[] bufs);
/// <summary>
/// Sets the color buffers to read from.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object. (Zero for the default framebuffer.)</param>
/// <param name="src">A <see cref="glBuffer"/> specifying the buffer.</param>
public delegate void glNamedFramebufferReadBuffer(uint framebuffer, glBuffer src);
/// <summary>
/// Invalidates the content of some or all of a framebuffer's attachments.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="numAttachments">The number of attachments in <paramref name="attachments"/>.</param>
/// <param name="attachments">An array of <see cref="glBuffer"/>s specifying the attachments.</param>
public delegate void glInvalidateNamedFramebufferData(uint framebuffer, int numAttachments, params glBuffer[] attachments);
/// <summary>
/// Invalidates the content of a region of some or all of a framebuffer's attachments.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="numAttachments">The number of attachments in <paramref name="attachments"/>.</param>
/// <param name="attachments">An array of <see cref="glBuffer"/>s specifying the attachments.</param>
/// <param name="x">The X offset of the region to be invalidated.</param>
/// <param name="y">The Y offset of the region to be invalidated.</param>
/// <param name="width">The width of the region to be invalidated.</param>
/// <param name="height">The height of the region to be invalidated.</param>
public delegate void glInvalidateNamedFramebufferSubData(uint framebuffer, int numAttachments, glBuffer[] attachments, int x, int y, int width, int height);
/// <summary>
/// Clears/Resets the values of a buffer to a specific value.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="buffer">A <see cref="glBuffer"/> specifying the buffer to be cleared.</param>
/// <param name="drawbuffer">The index of the color buffer if <paramref name="buffer"/> is <see cref="glBuffer.COLOR"/></param>
/// <param name="value">The value to be set.</param>
public delegate void glClearNamedFramebufferiv(uint framebuffer, glBuffer buffer, int drawbuffer, params int[] value);
/// <summary>
/// Clears/Resets the values of a buffer to a specific value.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="buffer">A <see cref="glBuffer"/> specifying the buffer to be cleared.</param>
/// <param name="drawbuffer">The index of the color buffer if <paramref name="buffer"/> is <see cref="glBuffer.COLOR"/></param>
/// <param name="value">The value to be set.</param>
public delegate void glClearNamedFramebufferuiv(uint framebuffer, glBuffer buffer, int drawbuffer, params uint[] value);
/// <summary>
/// Clears/Resets the values of a buffer to a specific value.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="buffer">A <see cref="glBuffer"/> specifying the buffer to be cleared.</param>
/// <param name="drawbuffer">The index of the color buffer if <paramref name="buffer"/> is <see cref="glBuffer.COLOR"/></param>
/// <param name="value">The value to be set.</param>
public delegate void glClearNamedFramebufferfv(uint framebuffer, glBuffer buffer, int drawbuffer, params float[] value);
/// <summary>
/// Clears/Resets the values of the depth-stencil-buffer to a specific value.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="buffer">Must be <see cref="glBuffer.DEPTH_STENCIL"/>.</param>
/// <param name="drawbuffer">Must be zero.</param>
/// <param name="depth">The depth value to set.</param>
/// <param name="stencil">The stencil value to set.</param>
public delegate void glClearNamedFramebufferfi(uint framebuffer, glBuffer buffer, int drawbuffer, float depth, int stencil);
/// <summary>
/// Copies a block of pixels between two framebuffer objects.
/// </summary>
/// <param name="readFramebuffer">The name of the framebuffer object to read from.</param>
/// <param name="drawFramebuffer">The name of the framebuffer object to write to.</param>
/// <param name="srcX0">The left bound of the region to copy.</param>
/// <param name="srcY0">The bottom bound of the region to copy.</param>
/// <param name="srcX1">The right bound of the region to copy.</param>
/// <param name="srcY1">The top bound of the region to copy.</param>
/// <param name="dstX0">The left bound of the region to be copied in.</param>
/// <param name="dstY0">The bottom bound of the region to be copied in.</param>
/// <param name="dstX1">The right bound of the region to be copied in.</param>
/// <param name="dstY1">The top bound of the region to be copied in.</param>
/// <param name="mask">A <see cref="glBufferMask"/> specifying the values to copy.</param>
/// <param name="filter">A <see cref="glFilter"/> specifying the interpolation methode to use when resizing.</param>
public delegate void glBlitNamedFramebuffer(uint readFramebuffer, uint drawFramebuffer, int srcX0, int srcY0, int srcX1, int srcY1, int dstX0, int dstY0, int dstX1, int dstY1, glBufferMask mask, glFilter filter);
/// <summary>
/// Checks and returns the state of a framebuffer target.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="target">A <see cref="glFramebufferTarget"/> specifying the target against which the framebuffer completeness ist checked.</param>
/// <returns>A <see cref="glFramebufferStatus"/> specifying the state of the framebuffer target</returns>
public delegate glFramebufferStatus glCheckNamedFramebufferStatus(uint framebuffer, glFramebufferTarget target);
/// <summary>
/// Returns the parameters of framebuffer objects.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="pname">A <see cref="glFramebufferParameter"/> specifying the parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetNamedFramebufferParameteri(uint framebuffer, glFramebufferParameter pname, out int param);
/// <summary>
/// Returns the parameters of framebuffer objects.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="pname">A <see cref="glFramebufferParameter"/> specifying the parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetNamedFramebufferParameteriv(uint framebuffer, glFramebufferParameter pname, int[] @params);
/// <summary>
/// Returns the parameters of framebuffer object attachments.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="attachment">A <see cref="glBuffer"/> specifying the attachment.</param>
/// <param name="pname">A <see cref="glFramebufferAttachmentParameter"/> specifying the parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetNamedFramebufferAttachmentParameteri(uint framebuffer, glBuffer attachment, glFramebufferAttachmentParameter pname, out int param);
/// <summary>
/// Returns the parameters of framebuffer object attachments.
/// </summary>
/// <param name="framebuffer">The name of the framebuffer object.</param>
/// <param name="attachment">A <see cref="glBuffer"/> specifying the attachment.</param>
/// <param name="pname">A <see cref="glFramebufferAttachmentParameter"/> specifying the parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetNamedFramebufferAttachmentParameteriv(uint framebuffer, glBuffer attachment, glFramebufferAttachmentParameter pname, int[] @params);
internal delegate void glCreateRenderbuffer(int one, out uint renderbuffer);
internal delegate void glCreateRenderbuffers(int count, uint[] renderbuffers);
/// <summary>
/// Creates renderbuffer storages for renderbuffer objects.
/// </summary>
/// <param name="renderbuffer">The name of the renderbuffer object.</param>
/// <param name="internalformat">A <see cref="glInternalFormat"/> specifying the internal format of the storage.</param>
/// <param name="width">The width of the storage in pixels.</param>
/// <param name="height">The height of the storage in pixels.</param>
public delegate void glNamedRenderbufferStorage(uint renderbuffer, glInternalFormat internalformat, int width, int height);
/// <summary>
/// Creates multisample renderbuffer storages for renderbuffer objects.
/// </summary>
/// <param name="renderbuffer">The name of the renderbuffer object.</param>
/// <param name="samples">The number of samples.</param>
/// <param name="internalformat">A <see cref="glInternalFormat"/> specifying the internal format of the storage.</param>
/// <param name="width">The width of the storage in pixels.</param>
/// <param name="height">The height of the storage in pixels.</param>
public delegate void glNamedRenderbufferStorageMultisample(uint renderbuffer, int samples, glInternalFormat internalformat, int width, int height);
/// <summary>
/// Returns parameters of renderbuffer objects.
/// </summary>
/// <param name="renderbuffer">The name of the renderbuffer object.</param>
/// <param name="pname">A <see cref="glRenderbufferParameter"/> specifying the parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetNamedRenderbufferParameteri(uint renderbuffer, glRenderbufferParameter pname, out int param);
/// <summary>
/// Returns parameters of renderbuffer objects.
/// </summary>
/// <param name="renderbuffer">The name of the renderbuffer object.</param>
/// <param name="pname">A <see cref="glRenderbufferParameter"/> specifying the parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetNamedRenderbufferParameteriv(uint renderbuffer, glRenderbufferParameter pname, int[] @params);
internal delegate void glCreateTexture(glTextureTarget target, int one, out uint texture);
internal delegate void glCreateTextures(glTextureTarget target, int count, uint[] textures);
/// <summary>
/// Attaches buffer objects to texture objects.
/// </summary>
/// <param name="texture">The name of the texture object.</param>
/// <param name="internalformat">A <see cref="glInternalFormat"/> specifying the internal format to be used.</param>
/// <param name="buffer">The name of the buffer object.</param>
public delegate void glTextureBuffer(uint texture, glInternalFormat internalformat, uint buffer);
internal delegate void glTextureBufferRange_32(uint texture, glInternalFormat internalformat, uint buffer, int offset, int size);
internal delegate void glTextureBufferRange_64(uint texture, glInternalFormat internalformat, uint buffer, long offset, long size);
/// <summary>
/// Creates a storage for all levels of a 1D texture.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="levels">Number of levels.</param>
/// <param name="internalformat">A <see cref="glInternalFormat"/> specifying the internal format.</param>
/// <param name="width">The width of the texture.</param>
public delegate void glTextureStorage1D(uint texture, int levels, glInternalFormat internalformat, int width);
/// <summary>
/// Creates a storage for all levels of a 2D texture.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="levels">Number of levels.</param>
/// <param name="internalformat">A <see cref="glInternalFormat"/> specifying the internal format.</param>
/// <param name="width">The width of the texture.</param>
/// <param name="height">The height of the texture.</param>
public delegate void glTextureStorage2D(uint texture, int levels, glInternalFormat internalformat, int width, int height);
/// <summary>
/// Creates a storage for all levels of a 3D texture.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="levels">Number of levels.</param>
/// <param name="internalformat">A <see cref="glInternalFormat"/> specifying the internal format.</param>
/// <param name="width">The width of the texture.</param>
/// <param name="height">The height of the texture.</param>
/// <param name="depth">The depth of the texture.</param>
public delegate void glTextureStorage3D(uint texture, int levels, glInternalFormat internalformat, int width, int height, int depth);
/// <summary>
/// Creates a storage for of a 2D multisample texture.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="samples">The number of samples in the texture.</param>
/// <param name="internalformat">A <see cref="glInternalFormat"/> specifying the internal format.</param>
/// <param name="width">The width of the texture.</param>
/// <param name="height">The height of the texture.</param>
/// <param name="fixedsamplelocations">Specifies whether the image will use identical sample locations and the same number of samples for all texels in the image, and the sample locations will not depend on the internal format or size of the image.</param>
public delegate void glTextureStorage2DMultisample(uint texture, int samples, glInternalFormat internalformat, int width, int height, [MarshalAs(UnmanagedType.I1)] bool fixedsamplelocations);
/// <summary>
/// Creates a storage for of a 3D multisample texture.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="samples">The number of samples in the texture.</param>
/// <param name="internalformat">A <see cref="glInternalFormat"/> specifying the internal format.</param>
/// <param name="width">The width of the texture.</param>
/// <param name="height">The height of the texture.</param>
/// <param name="depth">The depth of the texture.</param>
/// <param name="fixedsamplelocations">Specifies whether the image will use identical sample locations and the same number of samples for all texels in the image, and the sample locations will not depend on the internal format or size of the image.</param>
public delegate void glTextureStorage3DMultisample(uint texture, int samples, glInternalFormat internalformat, int width, int height, int depth, [MarshalAs(UnmanagedType.I1)] bool fixedsamplelocations);
internal delegate void glTextureSubImage1D(uint texture, int level, int xoffset, int width, glPixelFormat format, glPixelDataType type, IntPtr pixels);
internal delegate void glTextureSubImage2D(uint texture, int level, int xoffset, int yoffset, int width, int height, glPixelFormat format, glPixelDataType type, IntPtr pixels);
internal delegate void glTextureSubImage3D(uint texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, glPixelFormat format, glPixelDataType type, IntPtr pixels);
internal delegate void glCompressedTextureSubImage1D(uint texture, int level, int xoffset, int width, glInternalFormat format, int imageSize, IntPtr data);
internal delegate void glCompressedTextureSubImage2D(uint texture, int level, int xoffset, int yoffset, int width, int height, glInternalFormat format, int imageSize, IntPtr data);
internal delegate void glCompressedTextureSubImage3D(uint texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, glInternalFormat format, int imageSize, IntPtr data);
/// <summary>
/// Copies pixels inside a 1D texture.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="level">The level-of-detail to be filled.</param>
/// <param name="xoffset">The horizontal texel offset.</param>
/// <param name="x">Horizontal start position of the region to be copied, in window coordinates.</param>
/// <param name="y">Vertical start position of the region to be copied, in window coordinates.</param>
/// <param name="width">The width of the texture.</param>
public delegate void glCopyTextureSubImage1D(uint texture, int level, int xoffset, int x, int y, int width);
/// <summary>
/// Copies pixels inside a 2D texture.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="level">The level-of-detail to be filled.</param>
/// <param name="xoffset">The horizontal texel offset.</param>
/// <param name="yoffset">The vertical texel offset.</param>
/// <param name="x">Horizontal start position of the region to be copied, in window coordinates.</param>
/// <param name="y">Vertical start position of the region to be copied, in window coordinates.</param>
/// <param name="width">The width of the texture.</param>
/// <param name="height">The height of the texture.</param>
public delegate void glCopyTextureSubImage2D(uint texture, int level, int xoffset, int yoffset, int x, int y, int width, int height);
/// <summary>
/// Copies pixels inside a 3D texture.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="level">The level-of-detail to be filled.</param>
/// <param name="xoffset">The horizontal texel offset.</param>
/// <param name="yoffset">The vertical texel offset.</param>
/// <param name="zoffset">The texel offset in Z direction.</param>
/// <param name="x">Horizontal start position of the region to be copied, in window coordinates.</param>
/// <param name="y">Vertical start position of the region to be copied, in window coordinates.</param>
/// <param name="width">The width of the texture.</param>
/// <param name="height">The height of the texture.</param>
public delegate void glCopyTextureSubImage3D(uint texture, int level, int xoffset, int yoffset, int zoffset, int x, int y, int width, int height);
/// <summary>
/// Sets texture parameters of texture object.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> selecting the parameter to be set.</param>
/// <param name="param">The value the parameter is set to.</param>
public delegate void glTextureParameterf(uint texture, glTextureParameter pname, float param);
/// <summary>
/// Sets texture parameters of texture object.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> selecting the parameter to be set.</param>
/// <param name="params">The value the parameter is set to.</param>
public delegate void glTextureParameterfv(uint texture, glTextureParameter pname, params float[] @params);
internal delegate void glTextureParameteri(uint texture, glTextureParameter pname, int param);
/// <summary>
/// Sets texture parameters of texture object.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> selecting the parameter to be set.</param>
/// <param name="params">The value the parameter is set to.</param>
public delegate void glTextureParameteriv(uint texture, glTextureParameter pname, params int[] @params);
/// <summary>
/// Sets texture parameters of texture object.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> selecting the parameter to be set.</param>
/// <param name="params">The value the parameter is set to.</param>
public delegate void glTextureParameterIiv(uint texture, glTextureParameter pname, params int[] @params);
/// <summary>
/// Sets texture parameters of texture object.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> selecting the parameter to be set.</param>
/// <param name="params">The value the parameter is set to.</param>
public delegate void glTextureParameterIuiv(uint texture, glTextureParameter pname, params uint[] @params);
/// <summary>
/// Generates the mipmap of a texture object.
/// </summary>
/// <param name="texture">The name of the texture.</param>
public delegate void glGenerateTextureMipmap(uint texture);
/// <summary>
/// Bind a texture object to a texture unit.
/// </summary>
/// <param name="unit">The texture unit.</param>
/// <param name="texture">The name of the texture.</param>
public delegate void glBindTextureUnit(uint unit, uint texture);
internal delegate void glGetTextureImage(uint texture, int level, glPixelFormat format, glPixelDataType type, int bufSize, IntPtr pixels);
internal delegate void glGetCompressedTextureImage(uint texture, int level, int bufSize, IntPtr pixels);
/// <summary>
/// Returns the texture parameter of a texture level.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="level">The level-of-detail.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> specifying the texture parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetTextureLevelParameterf(uint texture, int level, glTexLevelParameter pname, out float param);
/// <summary>
/// Returns the texture parameter of a texture level.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="level">The level-of-detail.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> specifying the texture parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetTextureLevelParameterfv(uint texture, int level, glTexLevelParameter pname, float[] @params);
/// <summary>
/// Returns the texture parameter of a texture level.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="level">The level-of-detail.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> specifying the texture parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetTextureLevelParameteri(uint texture, int level, glTexLevelParameter pname, out int param);
/// <summary>
/// Returns the texture parameter of a texture level.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="level">The level-of-detail.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> specifying the texture parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetTextureLevelParameteriv(uint texture, int level, glTexLevelParameter pname, int[] @params);
/// <summary>
/// Returns the value of a texture parameter.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> specifying the texture parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetTextureParameterf(uint texture, glTextureParameter pname, out float param);
/// <summary>
/// Returns the value(s) of a texture parameter.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> specifying the texture parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetTextureParameterfv(uint texture, glTextureParameter pname, float[] @params);
internal delegate void glGetTextureParameteri(uint texture, glTextureParameter pname, out int param);
internal delegate void glGetTextureParameteriv(uint texture, glTextureParameter pname, int[] @params);
/// <summary>
/// Returns the value of a texture parameter.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> specifying the texture parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetTextureParameterIi(uint texture, glTextureParameter pname, out int param);
/// <summary>
/// Returns the value(s) of a texture parameter.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> specifying the texture parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetTextureParameterIiv(uint texture, glTextureParameter pname, int[] @params);
/// <summary>
/// Returns the value of a texture parameter.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> specifying the texture parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetTextureParameterIui(uint texture, glTextureParameter pname, out uint param);
/// <summary>
/// Returns the value(s) of a texture parameter.
/// </summary>
/// <param name="texture">The name of the texture.</param>
/// <param name="pname">A <see cref="glTextureParameter"/> specifying the texture parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetTextureParameterIuiv(uint texture, glTextureParameter pname, uint[] @params);
internal delegate void glCreateVertexArray(int one, out uint array);
internal delegate void glCreateVertexArrays(int count, uint[] arrays);
/// <summary>
/// Disables a vertex array attribute.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="index">The index of the vertex attribute.</param>
public delegate void glDisableVertexArrayAttrib(uint vaobj, uint index);
/// <summary>
/// Enables a vertex array attribute.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="index">The index of the vertex attribute.</param>
public delegate void glEnableVertexArrayAttrib(uint vaobj, uint index);
/// <summary>
/// Sets the element array buffer binding of a vertex array object.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="buffer">The name of the buffer object.</param>
public delegate void glVertexArrayElementBuffer(uint vaobj, uint buffer);
internal delegate void glVertexArrayVertexBuffer_32(uint vaobj, uint bindingindex, uint buffer, int offset, int stride);
internal delegate void glVertexArrayVertexBuffer_64(uint vaobj, uint bindingindex, uint buffer, long offset, int stride);
internal delegate void glVertexArrayVertexBuffers_32(uint vaobj, uint first, int count, uint[] buffers, int[] offsets, int[] strides);
internal delegate void glVertexArrayVertexBuffers_64(uint vaobj, uint first, int count, uint[] buffers, long[] offsets, int[] strides);
/// <summary>
/// Associate a vertex attribute and a vertex buffer binding for a vertex array object.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="attribindex">The index of the attribute.</param>
/// <param name="bindingindex">The index of the vertex buffer binding with which to associate the generic vertex attribute.</param>
public delegate void glVertexArrayAttribBinding(uint vaobj, uint attribindex, uint bindingindex);
/// <summary>
/// Sets the organization of vertex arrays.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="attribindex">The index of the vertex attribute.</param>
/// <param name="size">The number of values per vertex that are stored in the array.</param>
/// <param name="type">A <see cref="glVertexAttribType"/> specifying the type of the data stored in the array.</param>
/// <param name="normalized">Set <b>true</b> if data is normalized.</param>
/// <param name="relativeoffset">The distance between elements within the buffer.</param>
public delegate void glVertexArrayAttribFormat(uint vaobj, uint attribindex, int size, glVertexAttribType type, [MarshalAs(UnmanagedType.I1)] bool normalized, uint relativeoffset);
/// <summary>
/// Sets the organization of vertex arrays.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="attribindex">The index of the vertex attribute.</param>
/// <param name="size">The number of values per vertex that are stored in the array.</param>
/// <param name="type">A <see cref="glVertexAttribType"/> specifying the type of the data stored in the array.</param>
/// <param name="relativeoffset">The distance between elements within the buffer.</param>
public delegate void glVertexArrayAttribIFormat(uint vaobj, uint attribindex, int size, glVertexAttribType type, uint relativeoffset);
/// <summary>
/// Sets the organization of vertex arrays.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="attribindex">The index of the vertex attribute.</param>
/// <param name="size">The number of values per vertex that are stored in the array.</param>
/// <param name="type">A <see cref="glVertexAttribType"/> specifying the type of the data stored in the array.</param>
/// <param name="relativeoffset">The distance between elements within the buffer.</param>
public delegate void glVertexArrayAttribLFormat(uint vaobj, uint attribindex, int size, glVertexAttribType type, uint relativeoffset);
/// <summary>
/// Sets the rate at which vertex attributes advance.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="bindingindex">The index of the binding.</param>
/// <param name="divisor">The value for the instance step rate.</param>
public delegate void glVertexArrayBindingDivisor(uint vaobj, uint bindingindex, uint divisor);
/// <summary>
/// Returns the parameters of vertex array objects.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="pname">Must be <see cref="glVertexArrayParameter.ELEMENT_ARRAY_BUFFER_BINDING"/>.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetVertexArrayi(uint vaobj, glVertexArrayParameter pname, out int param);
/// <summary>
/// Returns the parameters of vertex array objects.
/// </summary>
/// <param name="vaobj">The name of the vertex attribute array object.</param>
/// <param name="pname">Must be <see cref="glVertexArrayParameter.ELEMENT_ARRAY_BUFFER_BINDING"/>.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetVertexArrayiv(uint vaobj, glVertexArrayParameter pname, int[] @params);
/// <summary>
/// Returns the parameters of vertex attributes.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="index">The index of the vertex attribute.</param>
/// <param name="pname">A <see cref="glVertexAttribParameter"/> specifying the parameter.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetVertexArrayIndexedi(uint vaobj, uint index, glVertexAttribParameter pname, out int param);
/// <summary>
/// Returns the parameters of vertex attributes.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="index">The index of the vertex attribute.</param>
/// <param name="pname">A <see cref="glVertexAttribParameter"/> specifying the parameter.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetVertexArrayIndexediv(uint vaobj, uint index, glVertexAttribParameter pname, int[] @params);
/// <summary>
/// Returns the parameters of vertex attributes.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="index">The index of the vertex attribute.</param>
/// <param name="pname">Must be <see cref="glVertexAttribParameter.VERTEX_BINDING_OFFSET"/>.</param>
/// <param name="param">Returns the requested value.</param>
public delegate void glGetVertexArrayIndexed64i(uint vaobj, uint index, glVertexAttribParameter pname, out long param);
/// <summary>
/// Returns the parameters of vertex attributes.
/// </summary>
/// <param name="vaobj">The name of the vertex array object.</param>
/// <param name="index">The index of the vertex attribute.</param>
/// <param name="pname">Must be <see cref="glVertexAttribParameter.VERTEX_BINDING_OFFSET"/>.</param>
/// <param name="params">Returns the requested value(s).</param>
public delegate void glGetVertexArrayIndexed64iv(uint vaobj, uint index, glVertexAttribParameter pname, long[] @params);
internal delegate void glCreateSampler(int one, out uint sampler);
internal delegate void glCreateSamplers(int count, uint[] samplers);
internal delegate void glCreateProgramPipeline(int one, out uint pipeline);
internal delegate void glCreateProgramPipelines(int count, uint[] pipelines);
internal delegate void glCreateQuery(glQueryTarget target, int one, out uint id);
internal delegate void glCreateQueries(glQueryTarget target, int count, uint[] ids);
internal delegate void glGetQueryBufferObjecti64v_32(uint id, uint buffer, glQueryObjectParameter pname, int offset);
internal delegate void glGetQueryBufferObjecti64v_64(uint id, uint buffer, glQueryObjectParameter pname, long offset);
internal delegate void glGetQueryBufferObjectiv_32(uint id, uint buffer, glQueryObjectParameter pname, int offset);
internal delegate void glGetQueryBufferObjectiv_64(uint id, uint buffer, glQueryObjectParameter pname, long offset);
internal delegate void glGetQueryBufferObjectui64v_32(uint id, uint buffer, glQueryObjectParameter pname, int offset);
internal delegate void glGetQueryBufferObjectui64v_64(uint id, uint buffer, glQueryObjectParameter pname, long offset);
internal delegate void glGetQueryBufferObjectuiv_32(uint id, uint buffer, glQueryObjectParameter pname, int offset);
internal delegate void glGetQueryBufferObjectuiv_64(uint id, uint buffer, glQueryObjectParameter pname, long offset);
/// <summary>
/// Orders memory transactions for regions issued prior to this command relative to those issued after this.
/// </summary>
/// <param name="barriers">A <see cref="glMemoryBarrierMask"/> specifying the kind of memory transactions to be ordered.</param>
public delegate void glMemoryBarrierByRegion(glMemoryBarrierMask barriers);
internal delegate void glGetTextureSubImage(uint texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, glPixelFormat format, glPixelDataType type, int bufSize, IntPtr pixels);
internal delegate void glGetCompressedTextureSubImage(uint texture, int level, int xoffset, int yoffset, int zoffset, int width, int height, int depth, int bufSize, IntPtr pixels);
/// <summary>
/// Returns if the rendering context has not been lost due to software or hardware issues.
/// </summary>
/// <returns><see cref="glGraphicsResetStatus.NO_ERROR"/> if the rendering context wasn't lost.</returns>
public delegate glGraphicsResetStatus glGetGraphicsResetStatus();
internal delegate void glGetnCompressedTexImage(glTextureProxyTarget target, int level, int bufSize, IntPtr pixels);
internal delegate void glGetnTexImage(glTextureProxyTarget target, int level, glPixelFormat format, glPixelDataType type, int bufSize, IntPtr pixels);
/// <summary>
/// Returns the value(s) of a uniform variable.
/// </summary>
/// <param name="program">The name of the program.</param>
/// <param name="location">The location of the uniform variable inside the program object.</param>
/// <param name="bufSize">The number of elements available in <paramref name="params"/>.</param>
/// <param name="params">The value(s) of the uniform variable.</param>
public delegate void glGetnUniformdv(uint program, int location, int bufSize, double[] @params);
/// <summary>
/// Returns the value(s) of a uniform variable.
/// </summary>
/// <param name="program">The name of the program.</param>
/// <param name="location">The location of the uniform variable inside the program object.</param>
/// <param name="bufSize">The number of elements available in <paramref name="params"/>.</param>
/// <param name="params">The value(s) of the uniform variable.</param>
public delegate void glGetnUniformfv(uint program, int location, int bufSize, float[] @params);
/// <summary>
/// Returns the value(s) of a uniform variable.
/// </summary>
/// <param name="program">The name of the program.</param>
/// <param name="location">The location of the uniform variable inside the program object.</param>
/// <param name="bufSize">The number of elements available in <paramref name="params"/>.</param>
/// <param name="params">The value(s) of the uniform variable.</param>
public delegate void glGetnUniformiv(uint program, int location, int bufSize, int[] @params);
/// <summary>
/// Returns the value(s) of a uniform variable.
/// </summary>
/// <param name="program">The name of the program.</param>
/// <param name="location">The location of the uniform variable inside the program object.</param>
/// <param name="bufSize">The number of elements available in <paramref name="params"/>.</param>
/// <param name="params">The value(s) of the uniform variable.</param>
public delegate void glGetnUniformuiv(uint program, int location, int bufSize, uint[] @params);
internal delegate void glReadnPixels(int x, int y, int width, int height, glPixelFormat format, glPixelDataType type, int bufSize, IntPtr pixels);
/// <summary>
/// Controls the ordering of reads and writes to rendered fragments across drawing commands.
/// </summary>
public delegate void glTextureBarrier();
}
public static partial class gl
{
/// <summary>
/// Indicates if OpenGL version 4.5 is available.
/// </summary>
public static bool VERSION_4_5;
#region Delegates
/// <summary>
/// Controls the clipping volume behavior and the clip coordinate to window coordinate transformation behavior.
/// </summary>
public static glClipControl ClipControl;
private static glCreateTransformFeedback _CreateTransformFeedback;
private static glCreateTransformFeedbacks _CreateTransformFeedbacks;
/// <summary>
/// Binds a buffer object to a transform feedback object.
/// </summary>
public static glTransformFeedbackBufferBase TransformFeedbackBufferBase;
private static glTransformFeedbackBufferRange_32 TransformFeedbackBufferRange_32;
private static glTransformFeedbackBufferRange_64 TransformFeedbackBufferRange_64;
/// <summary>
/// Returns the parameters of transform feedback objects.
/// </summary>
public static glGetTransformFeedbacki GetTransformFeedbacki;
/// <summary>
/// Returns the parameters of transform feedback objects.
/// </summary>
public static glGetTransformFeedbackiv GetTransformFeedbackiv;
/// <summary>
/// Returns the parameters of transform feedback buffer buffer objects.
/// </summary>
public static glGetTransformFeedbacki_ GetTransformFeedbacki_;
/// <summary>
/// Returns the parameters of transform feedback buffer buffer objects.
/// </summary>
public static glGetTransformFeedbacki_v GetTransformFeedbacki_v;
/// <summary>
/// Returns the parameters of transform feedback buffer buffer objects.
/// </summary>
public static glGetTransformFeedbacki64_ GetTransformFeedbacki64_;
/// <summary>
/// Returns the parameters of transform feedback buffer buffer objects.
/// </summary>
public static glGetTransformFeedbacki64_v GetTransformFeedbacki64_v;
private static glCreateBuffer _CreateBuffer;
private static glCreateBuffers _CreateBuffers;
private static glNamedBufferStorage_32 NamedBufferStorage_32;
private static glNamedBufferStorage_64 NamedBufferStorage_64;
private static glNamedBufferData_32 NamedBufferData_32;
private static glNamedBufferData_64 NamedBufferData_64;
private static glNamedBufferSubData_32 NamedBufferSubData_32;
private static glNamedBufferSubData_64 NamedBufferSubData_64;
private static glCopyNamedBufferSubData_32 CopyNamedBufferSubData_32;
private static glCopyNamedBufferSubData_64 CopyNamedBufferSubData_64;
private static glClearNamedBufferData _ClearNamedBufferData;
private static glClearNamedBufferSubData_32 ClearNamedBufferSubData_32;
private static glClearNamedBufferSubData_64 ClearNamedBufferSubData_64;
/// <summary>
/// Maps a data store into client memory.
/// </summary>
public static glMapNamedBuffer MapNamedBuffer;
private static glMapNamedBufferRange_32 MapNamedBufferRange_32;
private static glMapNamedBufferRange_64 MapNamedBufferRange_64;
/// <summary>
/// Releases a mapped data store.
/// </summary>
public static glUnmapNamedBuffer UnmapNamedBuffer;
private static glFlushMappedNamedBufferRange_32 FlushMappedNamedBufferRange_32;
private static glFlushMappedNamedBufferRange_64 FlushMappedNamedBufferRange_64;
/// <summary>
/// Returns the parameters of buffer objects.
/// </summary>
public static glGetNamedBufferParameteri GetNamedBufferParameteri;
/// <summary>
/// Returns the parameters of buffer objects.
/// </summary>
public static glGetNamedBufferParameteriv GetNamedBufferParameteriv;
/// <summary>
/// Returns the parameters of buffer objects.
/// </summary>
public static glGetNamedBufferParameteri64 GetNamedBufferParameteri64;
/// <summary>
/// Returns the parameters of buffer objects.
/// </summary>
public static glGetNamedBufferParameteri64v GetNamedBufferParameteri64v;
/// <summary>
/// Returns the pointer to a mapped data store of a buffer object.
/// </summary>
public static glGetNamedBufferPointerv GetNamedBufferPointerv;
private static glGetNamedBufferSubData_32 GetNamedBufferSubData_32;
private static glGetNamedBufferSubData_64 GetNamedBufferSubData_64;
private static glCreateFramebuffer _CreateFramebuffer;
private static glCreateFramebuffers _CreateFramebuffers;
/// <summary>
/// Attaches a renderbuffers as a logical buffer of a framebuffer objects.
/// </summary>
public static glNamedFramebufferRenderbuffer NamedFramebufferRenderbuffer;
/// <summary>
/// Sets parameters of framebuffer objects.
/// </summary>
public static glNamedFramebufferParameteri NamedFramebufferParameteri;
/// <summary>
/// Attaches levels of a texture objects as a logical buffer of framebuffer objects.
/// </summary>
public static glNamedFramebufferTexture NamedFramebufferTexture;
/// <summary>
/// Attaches layers of texture objects as a logical buffer of framebuffer objects.
/// </summary>
public static glNamedFramebufferTextureLayer NamedFramebufferTextureLayer;
/// <summary>
/// Sets the color buffers to draw into.
/// </summary>
public static glNamedFramebufferDrawBuffer NamedFramebufferDrawBuffer;