-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdglOpenGL.pas
17862 lines (16489 loc) · 929 KB
/
dglOpenGL.pas
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
{==============================================================================}
{ }
{ OpenGL 4.1 - Headertranslation }
{ Version 4.1a }
{ Date : 14.03.2011 }
{ }
{ Works with : }
{ - Delphi 3 and up }
{ - FreePascal (1.9.3 and up) }
{ }
{==============================================================================}
{ }
{ Containts the translations of glext.h, gl_1_1.h, glu.h and weglext.h. }
{ It also contains some helperfunctions that were inspired by those }
{ found in Mike Lischke's OpenGL12.pas. }
{ }
{ Copyright (C) DGL-OpenGL2-Portteam }
{ All Rights Reserved }
{ }
{ Obtained through: }
{ Delphi OpenGL Community(DGL) - www.delphigl.com }
{ }
{ Converted and maintained by DGL's GL2.0-Team : }
{ - Sascha Willems - http://www.delphigl.de }
{ - Steffen Xonna (Lossy eX) - http://www.dev-center.de }
{ - Lars Middendorf - http://www.3d-seite.de }
{ Additional input : }
{ - Martin Waldegger (Mars) - http://www.basegraph.com }
{ - Benjamin Rosseaux (BeRo) - http://www.0ok.de }
{ Additional thanks: }
{ sigsegv (libdl.so) }
{ }
{ }
{==============================================================================}
{ You may retrieve the latest version of this file at the Delphi OpenGL }
{ Community home page, located at http://www.delphigl.com/ }
{ }
{ The contents of this file are used with permission, subject to }
{ the Mozilla Public License Version 1.1 (the "License"); you may }
{ not use this file except in compliance with the License. You may }
{ obtain a copy of the License at }
{ http://www.mozilla.org/MPL/MPL-1.1.html }
{ }
{ Software distributed under the License is distributed on an }
{ "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or }
{ implied. See the License for the specific language governing }
{ rights and limitations under the License. }
{ }
{==============================================================================}
{ History : }
{ Version 1.0 Initial Release }
{ Version 1.1 Added PPointer in Tpyessection for compatiblity with Delphi }
{ versions lower than 7 (SW) }
{ Added a function named RaiseLastOSError including a comment }
{ on how to make it run under Delphi versions lower than 7 (SW) }
{ Added some data types according to the GL-Syntax (SW) }
{ Version 1.2 Fixed some problems with getting the addresses of some }
{ Extensions (e.g. glTexImage3D) where the EXT/ARB did work }
{ but not the core-functions (SW) }
{ Version 1.3 A second call to ReadimplementationProperties won't }
{ revert to the default libs anymore (MW) }
{ Libraries now will be released if necessary (MW) }
{ Version 1.3a Small fixes for glSlang-functions (SW) }
{ Version 1.3b Fixed a small bug with GL_ARB_shader_objects, that lead }
{ lead to that extension not loaded correctly (SW) }
{ Version 1.3c more GL 1.5 compliance by FOG_COORD_xx and }
{ ARB less VBO and occlusion query routines (MW) }
{ Version 1.3d Fixed linebreaks (should now be corrected under D5) (SW) }
{ Version 1.4 Changed header to correspond to the OpenGL-Shading }
{ Language specification 1.10 : }
{ - Added new GL_SAMPLER_*-Constants }
{ - Added Constant GL_SHADING_LANGUAGE_VERSION_ARB }
{ - Added Constant GL_FRAGMENT_SHADER_DERIVATIVE_HINT_ARB }
{ - Added Constant GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB (SW) }
{ Version 1.4a Fixed a missing stdcall for glBindAttribLocationARB (SW) }
{ Version 1.4b Fixed declaration for glUniform*(f/i)vARB (added count) (MW) }
{ glCompileShaderARB changed from function to procedure (MW) }
{ Version 1.5 Added support for FreePascal (BR) }
{ Added type TGLVectorf3/TGLVector3f (SW) }
{ Version 1.6 Added Extension GL_EXT_framebuffer_object (SX) }
{ Version 1.7 Added Extension GL_ARB_fragment_program_shadow (SX) }
{ Added Extension GL_ARB_draw_buffers (SX) }
{ Added Extension GL_ARB_texture_rectangle (SX) }
{ Added Extension GL_ARB_color_buffer_float (SX) }
{ Added Extension GL_ARB_half_float_pixel (SX) }
{ Added Extension GL_ARB_texture_float (SX) }
{ Added Extension GL_ARB_pixel_buffer_object (SX) }
{ Added Extension GL_EXT_depth_bounds_test (SX) }
{ Added Extension GL_EXT_texture_mirror_clamp (SX) }
{ Added Extension GL_EXT_blend_equation_separate (SX) }
{ Added Extension GL_EXT_pixel_buffer_object (SX) }
{ Added Extension GL_EXT_texture_compression_dxt1 (SX) }
{ Added Extension GL_NV_fragment_program_option (SX) }
{ Added Extension GL_NV_fragment_program2 (SX) }
{ Added Extension GL_NV_vertex_program2_option (SX) }
{ Added Extension GL_NV_vertex_program3 (SX) }
{ Version 1.8 Added explicit delegate type definitions (LM) }
{ Added .Net 1.1 Support (LM) }
{ Added .Net overloaded functions (LM) }
{ Added delayed extension loading and stubs (LM) }
{ Added automatic InitOpenGL call in CreateRenderingContext(LM) }
{ Added extra Read_* function (LM) }
{ Version 2.0 fixed some Problem with version string and damn drivers. }
{ String 1.15 identified as OpenGL 1.5 not as OpenGL 1.1 (SX) }
{ Removed unexisting extension GL_ARB_texture_mirror_repeat(SX) }
{ Added Extension WGL_ARB_pixel_format_float (SX) }
{ Added Extension GL_EXT_stencil_clear_tag (SX) }
{ Added Extension GL_EXT_texture_rectangle (SX) }
{ Added Extension GL_EXT_texture_edge_clamp (SX) }
{ Some 1.5 Core Consts added (now completed) (SX) }
{ gluProject need pointer for not .net (SX) }
{ gluUnProject need pointer for not .net (SX) }
{ wglUseFontOutlines* need pointer for not .net (SX) }
{ wglSwapMultipleBuffers need pointer for not .net (SX) }
{ Bug with wglGetExtensionsStringEXT removed }
{ different type for .net (SX) }
{ Added OpenGL 2.0 Core (SX) }
{ Version 2.0.1 fixed some problems with glGetActiveAttrib in 2.0 Core (SX) }
{ fixes some problems with gluProject (SX) }
{ fixes some problems with gluUnProject (SX) }
{ fixes some problems with gluTessVertex (SX) }
{ fixes some problems with gluLoadSamplingMatrices (SX) }
{ Version 2.1 Removed .NET Support (SX) }
{ Better support for Linux (SX) }
{ Better Codeformation (SX) }
{ Added some more Vector/Matrix types (SX) }
{ Added OpenGL 2.1 Core (SX) }
{ Added Extension GL_EXT_packed_depth_stencil (SX) }
{ Added Extension GL_EXT_texture_sRGB (SX) }
{ Added Extension GL_EXT_framebuffer_blit (SX) }
{ Added Extension GL_EXT_framebuffer_multisample (SX) }
{ Added Extension GL_EXT_timer_query (SX) }
{ Added Extension GL_EXT_gpu_program_parameters (SX) }
{ Added Extension GL_EXT_bindable_uniform (SX) }
{ Added Extension GL_EXT_draw_buffers2 (SX) }
{ Added Extension GL_EXT_draw_instanced (SX) }
{ Added Extension GL_EXT_framebuffer_sRGB (SX) }
{ Added Extension GL_EXT_geometry_shader4 (SX) }
{ Added Extension GL_EXT_gpu_shader4 (SX) }
{ Added Extension GL_EXT_packed_float (SX) }
{ Added Extension GL_EXT_texture_array (SX) }
{ Added Extension GL_EXT_texture_buffer_object (SX) }
{ Added Extension GL_EXT_texture_compression_latc (SX) }
{ Added Extension GL_EXT_texture_compression_rgtc (SX) }
{ Added Extension GL_EXT_texture_integer (SX) }
{ Added Extension GL_EXT_texture_shared_exponent (SX) }
{ Added Extension GL_NV_depth_buffer_float (SX) }
{ Added Extension GL_NV_fragment_program4 (SX) }
{ Added Extension GL_NV_framebuffer_multisample_coverage (SX) }
{ Added Extension GL_NV_geometry_program4 (SX) }
{ Added Extension GL_NV_gpu_program4 (SX) }
{ Added Extension GL_NV_parameter_buffer_object (SX) }
{ Added Extension GL_NV_transform_feedback (SX) }
{ Added Extension GL_NV_vertex_program4 (SX) }
{ Version 3.0 fixed some const of GL_EXT_texture_shared_exponent (SX) }
{ possible better support for mac (SX) }
{ Added OpenGL 3.0 Core (SX) }
{ Added Extension GL_ARB_depth_buffer_float (SX) }
{ Added Extension GL_ARB_draw_instanced (SX) }
{ Added Extension GL_ARB_framebuffer_object (SX) }
{ Added Extension GL_ARB_framebuffer_sRGB (SX) }
{ Added Extension GL_ARB_geometry_shader4 (SX) }
{ Added Extension GL_ARB_half_float_vertex (SX) }
{ Added Extension GL_ARB_instanced_arrays (SX) }
{ Added Extension GL_ARB_map_buffer_range (SX) }
{ Added Extension GL_ARB_texture_buffer_object (SX) }
{ Added Extension GL_ARB_texture_compression_rgtc (SX) }
{ Added Extension GL_ARB_texture_rg (SX) }
{ Added Extension GL_ARB_vertex_array_object (SX) }
{ Added Extension GL_NV_conditional_render (SX) }
{ Added Extension GL_NV_present_video (SX) }
{ Added Extension GL_EXT_transform_feedback (SX) }
{ Added Extension GL_EXT_direct_state_access (SX) }
{ Added Extension GL_EXT_vertex_array_bgra (SX) }
{ Added Extension GL_EXT_texture_swizzle (SX) }
{ Added Extension GL_NV_explicit_multisample (SX) }
{ Added Extension GL_NV_transform_feedback2 (SX) }
{ Added Extension WGL_ARB_create_context (SX) }
{ Added Extension WGL_NV_present_video (SX) }
{ Added Extension WGL_NV_video_out (SX) }
{ Added Extension WGL_NV_swap_group (SX) }
{ Added Extension WGL_NV_gpu_affinity (SX) }
{ Added define DGL_TINY_HEADER to suppress automatic }
{ function loading (SX) }
{ glProcedure renamed to dglGetProcAddress and now it's }
{ visible from outside the unit to custom load functions (SX) }
{ dglCheckExtension added to check if an extension exists (SX) }
{ Read_GL_ARB_buffer_object renamed to }
{ Read_GL_ARB_vertex_buffer_object (SX) }
{ Version 3.0.1 fixed an problem with fpc (SX) }
{ Version 3.0.2 fixed an problem with WGL_ARB_create_context (SX) }
{ Version 3.2 Functions from GL_VERSION_3_0 where updated (SX) }
{ Functions from GL_ARB_map_buffer_range where updated (SX) }
{ Functions from GL_NV_present_video where added (SX) }
{ Added consts of GL_ARB_instanced_arrays (SX) }
{ Defines to identify Delphi was changed (prevent for }
{ feature maintenance) (SX) }
{ Added Extension GL_ATI_meminfo (SX) }
{ Added Extension GL_AMD_performance_monitor (SX) }
{ Added Extension GL_AMD_texture_texture4 (SX) }
{ Added Extension GL_AMD_vertex_shader_tesselator (SX) }
{ Added Extension GL_EXT_provoking_vertex (SX) }
{ Added Extension WGL_AMD_gpu_association (SX) }
{ Added OpenGL 3.1 Core (SX) }
{ All deprecated stuff can be disabled if you undef the }
{ define DGL_DEPRECATED (SX) }
{ Added Extension GL_ARB_uniform_buffer_object (SX) }
{ Added Extension GL_ARB_compatibility (SX) }
{ Added Extension GL_ARB_copy_buffer (SX) }
{ Added Extension GL_ARB_shader_texture_lod (SX) }
{ Remove function from GL_NV_present_video (SX) }
{ Added Extension WGL_3DL_stereo_control (SX) }
{ Added Extension GL_EXT_texture_snorm (SX) }
{ Added Extension GL_AMD_draw_buffers_blend (SX) }
{ Added Extension GL_APPLE_texture_range (SX) }
{ Added Extension GL_APPLE_float_pixels (SX) }
{ Added Extension GL_APPLE_vertex_program_evaluators (SX) }
{ Added Extension GL_APPLE_aux_depth_stencil (SX) }
{ Added Extension GL_APPLE_object_purgeable (SX) }
{ Added Extension GL_APPLE_row_bytes (SX) }
{ Added OpenGL 3.2 Core (SX) }
{ Added Extension GL_ARB_depth_clamp (SX) }
{ Added Extension GL_ARB_draw_elements_base_vertex (SX) }
{ Added Extension GL_ARB_fragment_coord_conventions (SX) }
{ Added Extension GL_ARB_provoking_vertex (SX) }
{ Added Extension GL_ARB_seamless_cube_map (SX) }
{ Added Extension GL_ARB_sync (SX) }
{ Added Extension GL_ARB_texture_multisample (SX) }
{ Added Extension GL_ARB_vertex_array_bgra (SX) }
{ Added Extension GL_ARB_draw_buffers_blend (SX) }
{ Added Extension GL_ARB_sample_shading (SX) }
{ Added Extension GL_ARB_texture_cube_map_array (SX) }
{ Added Extension GL_ARB_texture_gather (SX) }
{ Added Extension GL_ARB_texture_query_lod (SX) }
{ Added Extension WGL_ARB_create_context_profile (SX) }
{ Added GLX Core up to Version 1.4 (SX) }
{ Added Extension GLX_ARB_multisample (SX) }
{ Added Extension GLX_ARB_fbconfig_float (SX) }
{ Added Extension GLX_ARB_get_proc_address (SX) }
{ Added Extension GLX_ARB_create_context (SX) }
{ Added Extension GLX_ARB_create_context_profile (SX) }
{ Added Extension GLX_EXT_visual_info (SX) }
{ Added Extension GLX_EXT_visual_rating (SX) }
{ Added Extension GLX_EXT_import_context (SX) }
{ Added Extension GLX_EXT_fbconfig_packed_float (SX) }
{ Added Extension GLX_EXT_framebuffer_sRGB (SX) }
{ Added Extension GLX_EXT_texture_from_pixmap (SX) }
{ Version 3.2.1 Fixed some problems with Delphi < 6 (SX) }
{ Version 3.2.2 Added Extension GL_APPLE_rgb_422 (SX) }
{ Added Extension GL_EXT_separate_shader_objects (SX) }
{ Added Extension GL_NV_video_capture (SX) }
{ Added Extension GL_NV_copy_image (SX) }
{ Added Extension GL_NV_parameter_buffer_object2 (SX) }
{ Added Extension GL_NV_shader_buffer_load (SX) }
{ Added Extension GL_NV_vertex_buffer_unified_memory (SX) }
{ Added Extension GL_NV_texture_barrier (SX) }
{ Variable GL_EXT_texture_snorm will be filled (SX) }
{ Variable GL_APPLE_row_bytes will be filled (SX) }
{ Added Extension WGL_NV_video_capture (SX) }
{ Added Extension WGL_NV_copy_image (SX) }
{ WGL_NV_video_out now named WGL_NV_video_output (SX) }
{ Added Extension GLX_EXT_swap_control (SX) }
{ Version 3.2.3 Fixed an Problem with glGetAttribLocation (SX) }
{ Added const GL_UNIFORM_BUFFER_EXT (SX) }
{ Functions of GL_NV_texture_barrier now will be loaded (SX) }
{ Version 4.0 Changes on Extension GL_ARB_texture_gather (SX) }
{ Changes on Extension GL_NV_shader_buffer_load (SX) }
{ Added OpenGL 3.3 Core (SX) }
{ Added OpenGL 4.0 Core (SX) }
{ Added Extension GL_AMD_shader_stencil_export (SX) }
{ Added Extension GL_AMD_seamless_cubemap_per_texture (SX) }
{ Added Extension GL_ARB_shading_language_include (SX) }
{ Added Extension GL_ARB_texture_compression_bptc (SX) }
{ Added Extension GL_ARB_blend_func_extended (SX) }
{ Added Extension GL_ARB_explicit_attrib_location (SX) }
{ Added Extension GL_ARB_occlusion_query2 (SX) }
{ Added Extension GL_ARB_sampler_objects (SX) }
{ Added Extension GL_ARB_shader_bit_encoding (SX) }
{ Added Extension GL_ARB_texture_rgb10_a2ui (SX) }
{ Added Extension GL_ARB_texture_swizzle (SX) }
{ Added Extension GL_ARB_timer_query (SX) }
{ Added Extension GL_ARB_vertex_type_2_10_10_10_rev (SX) }
{ Added Extension GL_ARB_draw_indirect (SX) }
{ Added Extension GL_ARB_gpu_shader5 (SX) }
{ Added Extension GL_ARB_gpu_shader_fp64 (SX) }
{ Added Extension GL_ARB_shader_subroutine (SX) }
{ Added Extension GL_ARB_tessellation_shader (SX) }
{ Added Extension GL_ARB_texture_buffer_object_rgb32 (SX) }
{ Added Extension GL_ARB_transform_feedback2 (SX) }
{ Added Extension GL_ARB_transform_feedback3 (SX) }
{ Version 4.1 Possible fix some strange linux behavior (SX) }
{ All function uses GL instead of TGL types (SX) }
{ GL_AMD_vertex_shader_tesselator will be read now (SX) }
{ GL_AMD_draw_buffers_blend will be read now (SX) }
{ Changes on glStencilFuncSeparate (GL_2_0) (SX) }
{ Changes on GL_VERSION_3_2 (SX) }
{ Changes on GL_VERSION_3_3 (SX) }
{ Changes on GL_VERSION_4_0 (SX) }
{ Changes on GL_ARB_sample_shading (SX) }
{ Changes on GL_ARB_texture_cube_map_array (SX) }
{ Changes on GL_ARB_gpu_shader5 (SX) }
{ Changes on GL_ARB_transform_feedback3 (SX) }
{ Changes on GL_ARB_sampler_objects (SX) }
{ Changes on GL_ARB_gpu_shader_fp64 (SX) }
{ Changes on GL_APPLE_element_array (SX) }
{ Changes on GL_APPLE_vertex_array_range (SX) }
{ Changes on GL_NV_transform_feedback (SX) }
{ Changes on GL_NV_vertex_buffer_unified_memory (SX) }
{ Changes on GL_EXT_multi_draw_arrays (SX) }
{ Changes on GL_EXT_direct_state_access (SX) }
{ Changes on GL_AMD_performance_monitor (SX) }
{ Changes on GL_AMD_seamless_cubemap_per_texture (SX) }
{ Changes on GL_EXT_geometry_shader4 (SX) }
{ Added OpenGL 4.1 Core (SX) }
{ Added Extension GL_ARB_ES2_compatibility (SX) }
{ Added Extension GL_ARB_get_program_binary (SX) }
{ Added Extension GL_ARB_separate_shader_objects (SX) }
{ Added Extension GL_ARB_shader_precision (SX) }
{ Added Extension GL_ARB_vertex_attrib_64bit (SX) }
{ Added Extension GL_ARB_viewport_array (SX) }
{ Added Extension GL_ARB_cl_event (SX) }
{ Added Extension GL_ARB_debug_output (SX) }
{ Added Extension GL_ARB_robustness (SX) }
{ Added Extension GL_ARB_shader_stencil_export (SX) }
{ Added Extension GL_AMD_conservative_depth (SX) }
{ Added Extension GL_EXT_shader_image_load_store (SX) }
{ Added Extension GL_EXT_vertex_attrib_64bit (SX) }
{ Added Extension GL_NV_gpu_program5 (SX) }
{ Added Extension GL_NV_gpu_shader5 (SX) }
{ Added Extension GL_NV_shader_buffer_store (SX) }
{ Added Extension GL_NV_tessellation_program5 (SX) }
{ Added Extension GL_NV_vertex_attrib_integer_64bit (SX) }
{ Added Extension GL_NV_multisample_coverage (SX) }
{ Added Extension GL_AMD_name_gen_delete (SX) }
{ Added Extension GL_AMD_debug_output (SX) }
{ Added Extension GL_NV_vdpau_interop (SX) }
{ Added Extension GL_AMD_transform_feedback3_lines_triangles (SX) }
{ Added Extension GL_AMD_depth_clamp_separate (SX) }
{ Added Extension GL_EXT_texture_sRGB_decode (SX) }
{ Added Extension WGL_ARB_framebuffer_sRGB (SX) }
{ Added Extension WGL_ARB_create_context_robustness (SX) }
{ Added Extension WGL_EXT_create_context_es2_profile (SX) }
{ Added Extension WGL_NV_multisample_coverage (SX) }
{ Added Extension GLX_ARB_vertex_buffer_object (SX) }
{ Added Extension GLX_ARB_framebuffer_sRGB (SX) }
{ Added Extension GLX_ARB_create_context_robustness (SX) }
{ Added Extension GLX_EXT_create_context_es2_profile (SX) }
{ Version 4.1a Fix for dglGetProcAddress with FPC and linux (def param) (SW) }
{==============================================================================}
{ Header based on glext.h rev 67 (2010/12/09) }
{ Header based on wglext.h rev 22 (2010/08/06) }
{ Header based on glxext.h rev 32 (2010/08/06) (only Core/ARB/EXT) }
{ }
{ This is an important notice for maintaining. Dont remove it. And make sure }
{ to keep it up to date }
{==============================================================================}
{$define DGL_DEPRECATED}
{
This define defines if the header should use deprecated ARB stuff or not.
per Default the Header use deprecated Stuff.
}
{.$define DGL_TINY_HEADER}
{
If you enable the define DGL_TINY_HEADER no function automatically will be loaded if you
call ActivateRenderingContext. This may some bit faster and the smart linker can delete
all non used functions. This will reduce the filesize of your binary file. But in this
case you have to load the functions by yourself. There are two ways to do this.
1. You can load whole extension by calling the func Read_Extensionname. But if you do
this it's possible to load functions you dont use. So you have the same "problem"
like before. But it's only an bit smaler.
> Read_GL_ARB_multitexture;
2. You are able to load only the functions you exactly need. In this case you are able
to use the variables of the dglOpenGL.pas. So you only need to load the functions
and you can use the header like before.
To do this you have to created and activated an opengl context and than you can load
the needed functions.
> ActivateRenderingContext(fDC, fRC);
> glActiveTextureARB := dglGetProcAddress('glActiveTextureARB');
> glMultiTexCoord2fARB := dglGetProcAddress('glMultiTexCoord2fARB');
So only the function "glActiveTextureARB" and "glMultiTexCoord2fARB" will be loaded.
Please notice that the extension variables won't be loaded if this define is active. But
you can call dglCheckExtension to check if any extension exists. You can assign them to
the variables of the dglOpenGL.pas so all code they use this will find them.
> GL_ARB_shading_language_100 := dglCheckExtension('GL_ARB_shading_language_100');
}
unit dglOpenGL;
interface
// defines to configure freepascal
{$IFDEF FPC}
{$MODE Delphi}
{$IFNDEF WINDOWS}
{$LINKLIB c}
{$ENDIF}
{$ENDIF}
// known delphi versions
{$IFNDEF FPC} // if freepascal isnt defined
{$IFDEF VER140} // Delphi 6
{$DEFINE DELPHI6_AND_DOWN}
{$ENDIF}
{$IFDEF VER130} // Delphi 5
{$DEFINE DELPHI6_AND_DOWN}
{$ENDIF}
{$IFDEF VER120} // Delphi 4
{$DEFINE DELPHI6_AND_DOWN}
{$ENDIF}
{$IFDEF VER110} // C++ Builder 3
{$DEFINE DELPHI6_AND_DOWN}
{$ENDIF}
{$IFDEF VER100} // Delphi 3
{$DEFINE DELPHI6_AND_DOWN}
{$ENDIF}
{$ENDIF}
// Options for Delphi < 5
{$IFDEF DELPHI6_AND_DOWN}
{$A+}
{$ELSE}
{$A4}
{$ENDIF}
// generell options
{$H+,O+,X+}
// detecting Windows
{$IFDEF Win32} // Delphi and fpc of 32 Bit Windows
{$DEFINE DGL_WIN}
{$ENDIF}
{$IFDEF Win64} // Delphi and fpc of 32 Bit Windows
{$DEFINE DGL_WIN}
{$ENDIF}
// detecting Linux
{$IFDEF linux} // Linux
{$DEFINE DGL_LINUX}
{$ENDIF}
// detecting 64 Bit CPU
{$IFDEF CPU64} // fpc on 64 bit cpus
{$DEFINE DGL_64BIT} // dgl define for 64 bit
{$ENDIF}
uses
SysUtils
{$IFDEF DGL_WIN}, Windows{$ENDIF}
{$IFDEF DGL_LINUX}, X, XLib, XUtil{$ENDIF}
;
type
// Needed for Delphi 6 and less (defined in system.pas for Delphi 7)
PPointer = ^Pointer;
PCardinal = ^Cardinal;
GLenum = Cardinal;
GLboolean = BYTEBOOL;
GLbitfield = Cardinal;
GLbyte = Shortint;
GLshort = SmallInt;
GLint = Integer;
GLsizei = Integer;
GLubyte = Byte;
GLushort = Word;
GLuint = Cardinal;
GLfloat = Single;
GLclampf = Single;
GLdouble = Double;
GLclampd = Double;
GLvoid = Pointer;
GLint64 = Int64;
GLuint64 = {$IFDEF DELPHI6_AND_DOWN} Int64 {$ELSE} UInt64 {$ENDIF};
TGLenum = GLenum;
TGLboolean = GLboolean;
TGLbitfield = GLbitfield;
TGLbyte = GLbyte;
TGLshort = GLshort;
TGLint = GLint;
TGLsizei = GLsizei;
TGLubyte = GLubyte;
TGLushort = GLushort;
TGLuint = GLuint;
TGLfloat = GLfloat;
TGLclampf = GLclampf;
TGLdouble = GLdouble;
TGLclampd = GLclampd;
TGLvoid = GLvoid;
TGLint64 = GLint64;
TGLuint64 = GLuint64;
PGLboolean = ^GLboolean;
PGLbyte = ^GLbyte;
PGLshort = ^GLshort;
PGLint = ^GLint;
PGLsizei = ^GLsizei;
PGLubyte = ^GLubyte;
PGLushort = ^GLushort;
PGLuint = ^GLuint;
PGLclampf = ^GLclampf;
PGLfloat = ^GLfloat;
PGLdouble = ^GLdouble;
PGLclampd = ^GLclampd;
PGLenum = ^GLenum;
PGLvoid = Pointer;
PPGLvoid = ^PGLvoid;
PGLint64 = ^GLint64;
PGLuint64 = ^GLuint64;
// GL_NV_half_float
GLhalfNV = WORD;
TGLhalfNV = GLhalfNV;
PGLhalfNV = ^GLhalfNV;
// GL_ARB_shader_objects
PGLHandleARB = ^GLHandleARB;
GLHandleARB = Integer;
GLcharARB = AnsiChar;
PGLcharARB = PAnsiChar;
PPGLcharARB = ^PGLcharARB;
// GL_VERSION_1_5
GLintptr = GLint;
GLsizeiptr = GLsizei;
// GL_ARB_vertex_buffer_object
GLintptrARB = GLint;
GLsizeiptrARB = GLsizei;
// GL_VERSION_2_0
GLHandle = Integer;
PGLchar = PAnsiChar;
PPGLchar = ^PGLChar;
// GL_EXT_timer_query
GLint64EXT = Int64;
TGLint64EXT = GLint64EXT;
PGLint64EXT = ^GLint64EXT;
GLuint64EXT = GLuint64;
TGLuint64EXT = GLuint64EXT;
PGLuint64EXT = ^GLuint64EXT;
// WGL_ARB_pbuffer
HPBUFFERARB = THandle;
// WGL_EXT_pbuffer
HPBUFFEREXT = THandle;
// WGL_NV_present_video
PHVIDEOOUTPUTDEVICENV = ^HVIDEOOUTPUTDEVICENV;
HVIDEOOUTPUTDEVICENV = THandle;
// WGL_NV_video_output
PHPVIDEODEV = ^HPVIDEODEV;
HPVIDEODEV = THandle;
// WGL_NV_gpu_affinity
PHPGPUNV = ^HPGPUNV;
PHGPUNV = ^HGPUNV;
// WGL_NV_video_capture
HVIDEOINPUTDEVICENV = THandle;
PHVIDEOINPUTDEVICENV = ^HVIDEOINPUTDEVICENV;
HPGPUNV = THandle;
HGPUNV = THandle;
// GL_ARB_sync
GLsync = Pointer;
// GL_ARB_cl_event
{ These incomplete types let us declare types compatible with OpenCL's cl_context and cl_event }
_cl_context = record end;
_cl_event = record end;
p_cl_context = ^_cl_context;
p_cl_event = ^_cl_event;
// GL_ARB_debug_output
TglDebugProcARB = procedure (source: GLenum; type_: GLenum; id: GLuint; severity: GLenum; length: GLsizei; const message_: PGLchar; userParam: PGLvoid); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
// GL_AMD_debug_output
TglDebugProcAMD = procedure (id: GLuint; category: GLenum; severity: GLenum; length: GLsizei; const message_: PGLchar; userParam: PGLvoid); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
// GL_NV_vdpau_interop
GLvdpauSurfaceNV = GLintptr;
PGLvdpauSurfaceNV = ^GLvdpauSurfaceNV;
// GLX
{$IFDEF DGL_LINUX}
GLXContext = Pointer;
GLXContextID = TXID;
GLXDrawable = TXID;
GLXFBConfig = Pointer;
GLXPbuffer = TXID;
GLXPixmap = TXID;
GLXWindow = TXID;
Window = TXID;
Colormap = TXID;
Pixmap = TXID;
Font = TXID;
{$ENDIF}
// Datatypes corresponding to GL's types TGL(name)(type)(count)
TGLVectorub2 = array[0..1] of GLubyte;
TGLVectori2 = array[0..1] of GLint;
TGLVectorf2 = array[0..1] of GLfloat;
TGLVectord2 = array[0..1] of GLdouble;
TGLVectorp2 = array[0..1] of Pointer;
TGLVectorub3 = array[0..2] of GLubyte;
TGLVectori3 = array[0..2] of GLint;
TGLVectorf3 = array[0..2] of GLfloat;
TGLVectord3 = array[0..2] of GLdouble;
TGLVectorp3 = array[0..2] of Pointer;
TGLVectorub4 = array[0..3] of GLubyte;
TGLVectori4 = array[0..3] of GLint;
TGLVectorf4 = array[0..3] of GLfloat;
TGLVectord4 = array[0..3] of GLdouble;
TGLVectorp4 = array[0..3] of Pointer;
TGLArrayf4 = TGLVectorf4;
TGLArrayf3 = TGLVectorf3;
TGLArrayd3 = TGLVectord3;
TGLArrayi4 = TGLVectori4;
TGLArrayp4 = TGLVectorp4;
TGlMatrixub3 = array[0..2, 0..2] of GLubyte;
TGlMatrixi3 = array[0..2, 0..2] of GLint;
TGLMatrixf3 = array[0..2, 0..2] of GLfloat;
TGLMatrixd3 = array[0..2, 0..2] of GLdouble;
TGlMatrixub4 = array[0..3, 0..3] of GLubyte;
TGlMatrixi4 = array[0..3, 0..3] of GLint;
TGLMatrixf4 = array[0..3, 0..3] of GLfloat;
TGLMatrixd4 = array[0..3, 0..3] of GLdouble;
TGLVector3f = TGLVectorf3;
// Datatypes corresponding to OpenGL12.pas for easy porting
TVector3d = TGLVectord3;
TVector4i = TGLVectori4;
TVector4f = TGLVectorf4;
TVector4p = TGLVectorp4;
TMatrix4f = TGLMatrixf4;
TMatrix4d = TGLMatrixd4;
PGLMatrixd4 = ^TGLMatrixd4;
PVector4i = ^TVector4i;
{$IFDEF FPC}
TRect = packed record
Left, Top, Right, Bottom: Longint;
end;
{$ENDIF}
PGPU_DEVICE = ^GPU_DEVICE;
GPU_DEVICE = record
cb: DWORD;
DeviceName: array [0..31] of AnsiChar;
DeviceString: array [0..127] of AnsiChar;
Flags: DWORD;
rcVirtualScreen: TRect;
end;
type
{$IFDEF FPC}
{$IFDEF DGL_WIN}
PWGLSwap = ^TWGLSwap;
{$EXTERNALSYM _WGLSWAP}
_WGLSWAP = packed record
hdc: HDC;
uiFlags: UINT;
end;
TWGLSwap = _WGLSWAP;
{$EXTERNALSYM WGLSWAP}
WGLSWAP = _WGLSWAP;
{$ENDIF}
{$ENDIF}
// GLU types
TGLUNurbs = record
end;
TGLUQuadric = record
end;
TGLUTesselator = record
end;
PGLUNurbs = ^TGLUNurbs;
PGLUQuadric = ^TGLUQuadric;
PGLUTesselator = ^TGLUTesselator;
// backwards compatibility
TGLUNurbsObj = TGLUNurbs;
TGLUQuadricObj = TGLUQuadric;
TGLUTesselatorObj = TGLUTesselator;
TGLUTriangulatorObj = TGLUTesselator;
PGLUNurbsObj = PGLUNurbs;
PGLUQuadricObj = PGLUQuadric;
PGLUTesselatorObj = PGLUTesselator;
PGLUTriangulatorObj = PGLUTesselator;
// GLUQuadricCallback
TGLUQuadricErrorProc = procedure(errorCode: GLenum); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
// GLUTessCallback
TGLUTessBeginProc = procedure(AType: GLenum); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessEdgeFlagProc = procedure(Flag: GLboolean); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessVertexProc = procedure(VertexData: Pointer); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessEndProc = procedure; {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessErrorProc = procedure(ErrNo: GLenum); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessCombineProc = procedure(Coords: TGLArrayd3; VertexData: TGLArrayp4; Weight: TGLArrayf4; OutData: PPointer); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessBeginDataProc = procedure(AType: GLenum; UserData: Pointer); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessEdgeFlagDataProc = procedure(Flag: GLboolean; UserData: Pointer); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessVertexDataProc = procedure(VertexData: Pointer; UserData: Pointer); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessEndDataProc = procedure(UserData: Pointer); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessErrorDataProc = procedure(ErrNo: GLenum; UserData: Pointer); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
TGLUTessCombineDataProc = procedure(Coords: TGLArrayd3; VertexData: TGLArrayp4; Weight: TGLArrayf4; OutData: PPointer; UserData: Pointer); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
// GLUNurbsCallback
TGLUNurbsErrorProc = procedure(ErrorCode: GLEnum); {$IFDEF DGL_WIN}stdcall; {$ELSE}cdecl; {$ENDIF}
var
GL_VERSION_1_0,
GL_VERSION_1_1,
GL_VERSION_1_2,
GL_VERSION_1_3,
GL_VERSION_1_4,
GL_VERSION_1_5,
GL_VERSION_2_0,
GL_VERSION_2_1,
GL_VERSION_3_0,
GL_VERSION_3_1,
GL_VERSION_3_2,
GL_VERSION_3_3,
GL_VERSION_4_0,
GL_VERSION_4_1,
GLU_VERSION_1_1,
GLU_VERSION_1_2,
GLU_VERSION_1_3,
GL_3DFX_multisample,
GL_3DFX_tbuffer,
GL_3DFX_texture_compression_FXT1,
GL_APPLE_client_storage,
GL_APPLE_element_array,
GL_APPLE_fence,
GL_APPLE_specular_vector,
GL_APPLE_transform_hint,
GL_APPLE_vertex_array_object,
GL_APPLE_vertex_array_range,
GL_APPLE_ycbcr_422,
GL_APPLE_texture_range,
GL_APPLE_float_pixels,
GL_APPLE_vertex_program_evaluators,
GL_APPLE_aux_depth_stencil,
GL_APPLE_object_purgeable,
GL_APPLE_row_bytes,
GL_APPLE_rgb_422,
GL_ARB_depth_texture,
GL_ARB_fragment_program,
GL_ARB_imaging,
GL_ARB_matrix_palette,
GL_ARB_multisample,
GL_ARB_multitexture,
GL_ARB_point_parameters,
GL_ARB_shadow,
GL_ARB_shadow_ambient,
GL_ARB_texture_border_clamp,
GL_ARB_texture_compression,
GL_ARB_texture_cube_map,
GL_ARB_texture_env_add,
GL_ARB_texture_env_combine,
GL_ARB_texture_env_crossbar,
GL_ARB_texture_env_dot3,
GL_ARB_texture_mirrored_repeat,
GL_ARB_transpose_matrix,
GL_ARB_vertex_blend,
GL_ARB_vertex_buffer_object,
GL_ARB_vertex_program,
GL_ARB_window_pos,
GL_ARB_shader_objects,
GL_ARB_vertex_shader,
GL_ARB_fragment_shader,
GL_ARB_shading_language_100,
GL_ARB_occlusion_query,
GL_ARB_texture_non_power_of_two,
GL_ARB_point_sprite,
GL_ARB_fragment_program_shadow,
GL_ARB_draw_buffers,
GL_ARB_texture_rectangle,
GL_ARB_color_buffer_float,
GL_ARB_half_float_pixel,
GL_ARB_texture_float,
GL_ARB_pixel_buffer_object,
GL_ARB_depth_buffer_float,
GL_ARB_draw_instanced,
GL_ARB_framebuffer_object,
GL_ARB_framebuffer_sRGB,
GL_ARB_geometry_shader4,
GL_ARB_half_float_vertex,
GL_ARB_instanced_arrays,
GL_ARB_map_buffer_range,
GL_ARB_texture_buffer_object,
GL_ARB_texture_compression_rgtc,
GL_ARB_texture_rg,
GL_ARB_vertex_array_object,
GL_ARB_uniform_buffer_object,
GL_ARB_compatibility,
GL_ARB_copy_buffer,
GL_ARB_shader_texture_lod,
GL_ARB_depth_clamp,
GL_ARB_draw_elements_base_vertex,
GL_ARB_fragment_coord_conventions,
GL_ARB_provoking_vertex,
GL_ARB_seamless_cube_map,
GL_ARB_sync,
GL_ARB_texture_multisample,
GL_ARB_vertex_array_bgra,
GL_ARB_draw_buffers_blend,
GL_ARB_sample_shading,
GL_ARB_texture_cube_map_array,
GL_ARB_texture_gather,
GL_ARB_texture_query_lod,
GL_ARB_shading_language_include,
GL_ARB_texture_compression_bptc,
GL_ARB_blend_func_extended,
GL_ARB_explicit_attrib_location,
GL_ARB_occlusion_query2,
GL_ARB_sampler_objects,
GL_ARB_shader_bit_encoding,
GL_ARB_texture_rgb10_a2ui,
GL_ARB_texture_swizzle,
GL_ARB_timer_query,
GL_ARB_vertex_type_2_10_10_10_rev,
GL_ARB_draw_indirect,
GL_ARB_gpu_shader5,
GL_ARB_gpu_shader_fp64,
GL_ARB_shader_subroutine,
GL_ARB_tessellation_shader,
GL_ARB_texture_buffer_object_rgb32,
GL_ARB_transform_feedback2,
GL_ARB_transform_feedback3,
GL_ARB_ES2_compatibility,
GL_ARB_get_program_binary,
GL_ARB_separate_shader_objects,
GL_ARB_shader_precision,
GL_ARB_vertex_attrib_64bit,
GL_ARB_viewport_array,
GL_ARB_cl_event,
GL_ARB_debug_output,
GL_ARB_robustness,
GL_ARB_shader_stencil_export,
GL_ATI_draw_buffers,
GL_ATI_element_array,
GL_ATI_envmap_bumpmap,
GL_ATI_fragment_shader,
GL_ATI_map_object_buffer,
GL_ATI_pn_triangles,
GL_ATI_separate_stencil,
GL_ATI_text_fragment_shader,
GL_ATI_texture_env_combine3,
GL_ATI_texture_float,
GL_ATI_texture_mirror_once,
GL_ATI_vertex_array_object,
GL_ATI_vertex_attrib_array_object,
GL_ATI_vertex_streams,
GL_ATI_meminfo,
GL_AMD_performance_monitor,
GL_AMD_texture_texture4,
GL_AMD_vertex_shader_tesselator,
GL_AMD_draw_buffers_blend,
GL_AMD_shader_stencil_export,
GL_AMD_seamless_cubemap_per_texture,
GL_AMD_conservative_depth,
GL_AMD_name_gen_delete,
GL_AMD_debug_output,
GL_AMD_transform_feedback3_lines_triangles,
GL_AMD_depth_clamp_separate,
GL_EXT_422_pixels,
GL_EXT_abgr,
GL_EXT_bgra,
GL_EXT_blend_color,
GL_EXT_blend_func_separate,
GL_EXT_blend_logic_op,
GL_EXT_blend_minmax,
GL_EXT_blend_subtract,
GL_EXT_clip_volume_hint,
GL_EXT_cmyka,
GL_EXT_color_matrix,
GL_EXT_color_subtable,
GL_EXT_compiled_vertex_array,
GL_EXT_convolution,
GL_EXT_coordinate_frame,
GL_EXT_copy_texture,
GL_EXT_cull_vertex,
GL_EXT_draw_range_elements,
GL_EXT_fog_coord,
GL_EXT_framebuffer_object,
GL_EXT_histogram,
GL_EXT_index_array_formats,
GL_EXT_index_func,
GL_EXT_index_material,
GL_EXT_index_texture,
GL_EXT_light_texture,
GL_EXT_misc_attribute,
GL_EXT_multi_draw_arrays,
GL_EXT_multisample,
GL_EXT_packed_pixels,
GL_EXT_paletted_texture,
GL_EXT_pixel_transform,
GL_EXT_pixel_transform_color_table,
GL_EXT_point_parameters,
GL_EXT_polygon_offset,
GL_EXT_rescale_normal,
GL_EXT_secondary_color,
GL_EXT_separate_specular_color,
GL_EXT_shadow_funcs,
GL_EXT_shared_texture_palette,
GL_EXT_stencil_two_side,
GL_EXT_stencil_wrap,
GL_EXT_subtexture,
GL_EXT_texture,
GL_EXT_texture3D,
GL_EXT_texture_compression_s3tc,
GL_EXT_texture_cube_map,
GL_EXT_texture_edge_clamp,
GL_EXT_texture_env_add,
GL_EXT_texture_env_combine,
GL_EXT_texture_env_dot3,
GL_EXT_texture_filter_anisotropic,
GL_EXT_texture_lod_bias,
GL_EXT_texture_object,
GL_EXT_texture_perturb_normal,
GL_EXT_texture_rectangle,
GL_EXT_vertex_array,
GL_EXT_vertex_shader,
GL_EXT_vertex_weighting,
GL_EXT_depth_bounds_test,
GL_EXT_texture_mirror_clamp,
GL_EXT_blend_equation_separate,
GL_EXT_pixel_buffer_object,
GL_EXT_texture_compression_dxt1,
GL_EXT_stencil_clear_tag,
GL_EXT_packed_depth_stencil,
GL_EXT_texture_sRGB,
GL_EXT_framebuffer_blit,
GL_EXT_framebuffer_multisample,
GL_EXT_timer_query,
GL_EXT_gpu_program_parameters,
GL_EXT_bindable_uniform,
GL_EXT_draw_buffers2,
GL_EXT_draw_instanced,
GL_EXT_framebuffer_sRGB,
GL_EXT_geometry_shader4,
GL_EXT_gpu_shader4,
GL_EXT_packed_float,
GL_EXT_texture_array,
GL_EXT_texture_buffer_object,
GL_EXT_texture_compression_latc,
GL_EXT_texture_compression_rgtc,
GL_EXT_texture_integer,
GL_EXT_texture_shared_exponent,
GL_EXT_transform_feedback,
GL_EXT_direct_state_access,
GL_EXT_vertex_array_bgra,
GL_EXT_texture_swizzle,
GL_EXT_provoking_vertex,
GL_EXT_texture_snorm,
GL_EXT_separate_shader_objects,
GL_EXT_shader_image_load_store,
GL_EXT_vertex_attrib_64bit,