1 /* 2 3 Boost Software License - Version 1.0 - August 17th, 2003 4 5 Permission is hereby granted, free of charge, to any person or organization 6 obtaining a copy of the software and accompanying documentation covered by 7 this license (the "Software") to use, reproduce, display, distribute, 8 execute, and transmit the Software, and to prepare derivative works of the 9 Software, and to permit third-parties to whom the Software is furnished to 10 do so, all subject to the following: 11 12 The copyright notices in the Software and this entire statement, including 13 the above license grant, this restriction and the following disclaimer, 14 must be included in all copies of the Software, in whole or in part, and 15 all derivative works of the Software, unless such copies or derivative 16 works are solely in the form of machine-executable object code generated by 17 a source language processor. 18 19 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 20 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 21 FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT 22 SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE 23 FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, 24 ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 25 DEALINGS IN THE SOFTWARE. 26 27 */ 28 module derelict.gles.eglext; 29 30 import derelict.gles.egltypes; 31 import derelict.gles.internal; 32 import core.stdc.stdint; 33 34 private __gshared bool _EGL_KHR_cl_event; 35 bool EGL_KHR_cl_event() @property { return _EGL_KHR_cl_event; } 36 enum : uint { 37 EGL_CL_EVENT_HANDLE_KHR = 0x309C, 38 EGL_SYNC_CL_EVENT_KHR = 0x30FE, 39 EGL_SYNC_CL_EVENT_COMPLETE_KHR = 0x30FF, 40 } 41 42 private __gshared bool _EGL_KHR_cl_event2; 43 bool EGL_KHR_cl_event2() @property { return _EGL_KHR_cl_event2; } 44 alias EGLSyncKHR = void*; 45 alias EGLAttribKHR = intptr_t; 46 extern( System ) nothrow { 47 alias EGLSyncKHR function( EGLDisplay, EGLenum, const EGLAttribKHR* ) da_eglCreateSync64KHR; 48 } 49 __gshared { 50 da_eglCreateSync64KHR eglCreateSync64KHR; 51 } 52 private void load_EGL_KHR_cl_event2() { 53 try { 54 bindGLFunc( cast( void** )&eglCreateSync64KHR, "eglCreateSync64KHR" ); 55 56 _EGL_KHR_cl_event2 = true; 57 } catch( Exception e ) { 58 _EGL_KHR_cl_event2 = false; 59 } 60 } 61 62 private __gshared bool _EGL_KHR_client_get_all_proc_addresses; 63 bool EGL_KHR_client_get_all_proc_addresses() @property { return _EGL_KHR_client_get_all_proc_addresses; } 64 65 private __gshared bool _EGL_KHR_config_attribs; 66 bool EGL_KHR_config_attribs() @property { return _EGL_KHR_config_attribs; } 67 enum : uint { 68 EGL_CONFORMANT_KHR = 0x3042, 69 EGL_VG_COLORSPACE_LINEAR_BIT_KHR = 0x0020, 70 EGL_VG_ALPHA_FORMAT_PRE_BIT_KHR = 0x0040, 71 } 72 73 private __gshared bool _EGL_KHR_create_context; 74 bool EGL_KHR_create_context() @property { return _EGL_KHR_create_context; } 75 enum : uint { 76 EGL_CONTEXT_MAJOR_VERSION_KHR = 0x3098, 77 EGL_CONTEXT_MINOR_VERSION_KHR = 0x30FB, 78 EGL_CONTEXT_FLAGS_KHR = 0x30FC, 79 EGL_CONTEXT_OPENGL_PROFILE_MASK_KHR = 0x30FD, 80 EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY_KHR = 0x31BD, 81 EGL_NO_RESET_NOTIFICATION_KHR = 0x31BE, 82 EGL_LOSE_CONTEXT_ON_RESET_KHR = 0x31BF, 83 EGL_CONTEXT_OPENGL_DEBUG_BIT_KHR = 0x00000001, 84 EGL_CONTEXT_OPENGL_FORWARD_COMPATIBLE_BIT_KHR = 0x00000002, 85 EGL_CONTEXT_OPENGL_ROBUST_ACCESS_BIT_KHR = 0x00000004, 86 EGL_CONTEXT_OPENGL_CORE_PROFILE_BIT_KHR = 0x00000001, 87 EGL_CONTEXT_OPENGL_COMPATIBILITY_PROFILE_BIT_KHR = 0x00000002, 88 EGL_OPENGL_ES3_BIT_KHR = 0x00000040, 89 } 90 91 private __gshared bool _EGL_KHR_fence_sync; 92 bool EGL_KHR_fence_sync() @property { return _EGL_KHR_fence_sync; } 93 enum : uint { 94 EGL_SYNC_PRIOR_COMMANDS_COMPLETE_KHR = 0x30F0, 95 EGL_SYNC_CONDITION_KHR = 0x30F8, 96 EGL_SYNC_FENCE_KHR = 0x30F9, 97 } 98 99 private __gshared bool _EGL_KHR_get_all_proc_addresses; 100 bool EGL_KHR_get_all_proc_addresses() @property { return _EGL_KHR_get_all_proc_addresses; } 101 102 private __gshared bool _EGL_KHR_gl_colorspace; 103 bool EGL_KHR_gl_colorspace() @property { return _EGL_KHR_gl_colorspace; } 104 enum : uint { 105 EGL_GL_COLORSPACE_KHR = 0x309D, 106 EGL_GL_COLORSPACE_SRGB_KHR = 0x3089, 107 EGL_GL_COLORSPACE_LINEAR_KHR = 0x308A, 108 } 109 110 private __gshared bool _EGL_KHR_gl_renderbuffer_image; 111 bool EGL_KHR_gl_renderbuffer_image() @property { return _EGL_KHR_gl_renderbuffer_image; } 112 enum : uint { 113 EGL_GL_RENDERBUFFER_KHR = 0x30B9, 114 } 115 116 private __gshared bool _EGL_KHR_gl_texture_2D_image; 117 bool EGL_KHR_gl_texture_2D_image() @property { return _EGL_KHR_gl_texture_2D_image; } 118 enum : uint { 119 EGL_GL_TEXTURE_2D_KHR = 0x30B1, 120 EGL_GL_TEXTURE_LEVEL_KHR = 0x30BC, 121 } 122 123 private __gshared bool _EGL_KHR_gl_texture_3D_image; 124 bool EGL_KHR_gl_texture_3D_image() @property { return _EGL_KHR_gl_texture_3D_image; } 125 enum : uint { 126 EGL_GL_TEXTURE_3D_KHR = 0x30B2, 127 EGL_GL_TEXTURE_ZOFFSET_KHR = 0x30BD, 128 } 129 130 private __gshared bool _EGL_KHR_gl_texture_cubemap_image; 131 bool EGL_KHR_gl_texture_cubemap_image() @property { return _EGL_KHR_gl_texture_cubemap_image; } 132 enum : uint { 133 EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_X_KHR = 0x30B3, 134 EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_X_KHR = 0x30B4, 135 EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Y_KHR = 0x30B5, 136 EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_KHR = 0x30B6, 137 EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Z_KHR = 0x30B7, 138 EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_KHR = 0x30B8, 139 } 140 141 private __gshared bool _EGL_KHR_image; 142 bool EGL_KHR_image() @property { return _EGL_KHR_image; } 143 alias EGLImageKHR = void*; 144 enum EGLImageKHR EGL_NO_IMAGE_KHR = null; 145 enum : uint { 146 EGL_NATIVE_PIXMAP_KHR = 0x30B0, 147 } 148 extern( System ) nothrow { 149 alias EGLImageKHR function( EGLDisplay, EGLContext, EGLenum, EGLClientBuffer, const EGLint* ) da_eglCreateImageKHR; 150 alias EGLBoolean function( EGLDisplay, EGLImageKHR ) da_eglDestroyImageKHR; 151 } 152 __gshared { 153 da_eglCreateImageKHR eglCreateImageKHR; 154 da_eglDestroyImageKHR eglDestroyImageKHR; 155 } 156 private void load_EGL_KHR_image() { 157 try { 158 bindGLFunc( cast( void** )&eglCreateImageKHR, "eglCreateImageKHR" ); 159 bindGLFunc( cast( void** )&eglDestroyImageKHR, "eglDestroyImageKHR" ); 160 161 _EGL_KHR_image = true; 162 } catch( Exception e ) { 163 _EGL_KHR_image = false; 164 } 165 } 166 167 private __gshared bool _EGL_KHR_image_base; 168 bool EGL_KHR_image_base() @property { return _EGL_KHR_image_base; } 169 enum : uint { 170 EGL_IMAGE_PRESERVED_KHR = 0x30D2, 171 } 172 173 private __gshared bool _EGL_KHR_image_pixmap; 174 bool EGL_KHR_image_pixmap() @property { return _EGL_KHR_image_pixmap; } 175 176 private __gshared bool _EGL_KHR_lock_surface; 177 bool EGL_KHR_lock_surface() @property { return _EGL_KHR_lock_surface; } 178 enum : uint { 179 EGL_READ_SURFACE_BIT_KHR = 0x0001, 180 EGL_WRITE_SURFACE_BIT_KHR = 0x0002, 181 EGL_LOCK_SURFACE_BIT_KHR = 0x0080, 182 EGL_OPTIMAL_FORMAT_BIT_KHR = 0x0100, 183 EGL_MATCH_FORMAT_KHR = 0x3043, 184 EGL_FORMAT_RGB_565_EXACT_KHR = 0x30C0, 185 EGL_FORMAT_RGB_565_KHR = 0x30C1, 186 EGL_FORMAT_RGBA_8888_EXACT_KHR = 0x30C2, 187 EGL_FORMAT_RGBA_8888_KHR = 0x30C3, 188 EGL_MAP_PRESERVE_PIXELS_KHR = 0x30C4, 189 EGL_LOCK_USAGE_HINT_KHR = 0x30C5, 190 EGL_BITMAP_POINTER_KHR = 0x30C6, 191 EGL_BITMAP_PITCH_KHR = 0x30C7, 192 EGL_BITMAP_ORIGIN_KHR = 0x30C8, 193 EGL_BITMAP_PIXEL_RED_OFFSET_KHR = 0x30C9, 194 EGL_BITMAP_PIXEL_GREEN_OFFSET_KHR = 0x30CA, 195 EGL_BITMAP_PIXEL_BLUE_OFFSET_KHR = 0x30CB, 196 EGL_BITMAP_PIXEL_ALPHA_OFFSET_KHR = 0x30CC, 197 EGL_BITMAP_PIXEL_LUMINANCE_OFFSET_KHR = 0x30CD, 198 EGL_LOWER_LEFT_KHR = 0x30CE, 199 EGL_UPPER_LEFT_KHR = 0x30CF, 200 } 201 extern( System ) nothrow { 202 alias EGLBoolean function( EGLDisplay, EGLSurface, const EGLint* ) da_eglLockSurfaceKHR; 203 alias EGLBoolean function( EGLDisplay, EGLSurface ) da_eglUnlockSurfaceKHR; 204 } 205 __gshared { 206 da_eglLockSurfaceKHR eglLockSurfaceKHR; 207 da_eglUnlockSurfaceKHR eglUnlockSurfaceKHR; 208 } 209 private void load_EGL_KHR_lock_surface() { 210 try { 211 bindGLFunc( cast( void** )&eglLockSurfaceKHR, "eglLockSurfaceKHR" ); 212 bindGLFunc( cast( void** )&eglUnlockSurfaceKHR, "eglUnlockSurfaceKHR" ); 213 214 _EGL_KHR_lock_surface = true; 215 } catch( Exception e ) { 216 _EGL_KHR_lock_surface = false; 217 } 218 } 219 220 private __gshared bool _EGL_KHR_lock_surface2; 221 bool EGL_KHR_lock_surface2() @property { return _EGL_KHR_lock_surface2; } 222 enum : uint { 223 EGL_BITMAP_PIXEL_SIZE_KHR = 0x3110, 224 } 225 226 private __gshared bool _EGL_KHR_lock_surface3; 227 bool EGL_KHR_lock_surface3() @property { return _EGL_KHR_lock_surface3; } 228 extern( System ) nothrow { 229 alias EGLBoolean function( EGLDisplay, EGLSurface, EGLint, EGLAttribKHR* ) da_eglQuerySurface64KHR; 230 } 231 __gshared { 232 da_eglQuerySurface64KHR eglQuerySurface64KHR; 233 } 234 private void load_EGL_KHR_lock_surface3() { 235 try { 236 bindGLFunc( cast( void** )&eglQuerySurface64KHR, "eglQuerySurface64KHR" ); 237 238 _EGL_KHR_lock_surface3 = true; 239 } catch( Exception e ) { 240 _EGL_KHR_lock_surface3 = false; 241 } 242 } 243 244 private __gshared bool _EGL_KHR_platform_android; 245 bool EGL_KHR_platform_android() @property { return _EGL_KHR_platform_android; } 246 enum : uint { 247 EGL_PLATFORM_ANDROID_KHR = 0x3141, 248 } 249 250 private __gshared bool _EGL_KHR_platform_gbm; 251 bool EGL_KHR_platform_gbm() @property { return _EGL_KHR_platform_gbm; } 252 enum : uint { 253 EGL_PLATFORM_GBM_KHR = 0x31D7, 254 } 255 256 private __gshared bool _EGL_KHR_platform_wayland; 257 bool EGL_KHR_platform_wayland() @property { return _EGL_KHR_platform_wayland; } 258 enum : uint { 259 EGL_PLATFORM_WAYLAND_KHR = 0x31D8, 260 } 261 262 private __gshared bool _EGL_KHR_platform_x11; 263 bool EGL_KHR_platform_x11() @property { return _EGL_KHR_platform_x11; } 264 enum : uint { 265 EGL_PLATFORM_X11_KHR = 0x31D5, 266 EGL_PLATFORM_X11_SCREEN_KHR = 0x31D6, 267 } 268 269 private __gshared bool _EGL_KHR_reusable_sync; 270 bool EGL_KHR_reusable_sync() @property { return _EGL_KHR_reusable_sync; } 271 alias EGLTimeKHR = ulong; 272 enum EGLTimeKHR EGL_FOREVER_KHR = 0xFFFFFFFFFFFFFFFFUL; 273 enum EGLSyncKHR EGL_NO_SYNC_KHR = null; 274 enum : uint { 275 EGL_SYNC_STATUS_KHR = 0x30F1, 276 EGL_SIGNALED_KHR = 0x30F2, 277 EGL_UNSIGNALED_KHR = 0x30F3, 278 EGL_TIMEOUT_EXPIRED_KHR = 0x30F5, 279 EGL_CONDITION_SATISFIED_KHR = 0x30F6, 280 EGL_SYNC_TYPE_KHR = 0x30F7, 281 EGL_SYNC_REUSABLE_KHR = 0x30FA, 282 EGL_SYNC_FLUSH_COMMANDS_BIT_KHR = 0x0001, 283 } 284 extern( System ) nothrow { 285 alias EGLSyncKHR function( EGLDisplay, EGLenum, const EGLint* ) da_eglCreateSyncKHR; 286 alias EGLBoolean function( EGLDisplay, EGLSyncKHR ) da_eglDestroySyncKHR; 287 alias EGLint function( EGLDisplay, EGLSyncKHR, EGLint, EGLTimeKHR ) da_eglClientWaitSyncKHR; 288 alias EGLBoolean function( EGLDisplay, EGLSyncKHR, EGLenum ) da_eglSignalSyncKHR; 289 alias EGLBoolean function( EGLDisplay, EGLSyncKHR, EGLint, EGLint* ) da_eglGetSyncAttribKHR; 290 } 291 __gshared { 292 da_eglCreateSyncKHR eglCreateSyncKHR; 293 da_eglDestroySyncKHR eglDestroySyncKHR; 294 da_eglClientWaitSyncKHR eglClientWaitSyncKHR; 295 da_eglSignalSyncKHR eglSignalSyncKHR; 296 da_eglGetSyncAttribKHR eglGetSyncAttribKHR; 297 } 298 private void load_EGL_KHR_reusable_sync() { 299 try { 300 bindGLFunc( cast( void** )&eglCreateSyncKHR, "eglCreateSyncKHR" ); 301 bindGLFunc( cast( void** )&eglDestroySyncKHR, "eglDestroySyncKHR" ); 302 bindGLFunc( cast( void** )&eglClientWaitSyncKHR, "eglClientWaitSyncKHR" ); 303 bindGLFunc( cast( void** )&eglSignalSyncKHR, "eglSignalSyncKHR" ); 304 bindGLFunc( cast( void** )&eglGetSyncAttribKHR, "eglGetSyncAttribKHR" ); 305 306 _EGL_KHR_reusable_sync = true; 307 } catch( Exception e ) { 308 _EGL_KHR_reusable_sync = false; 309 } 310 } 311 312 private __gshared bool _EGL_KHR_stream; 313 bool EGL_KHR_stream() @property { return _EGL_KHR_stream; } 314 alias EGLStreamKHR = void*; 315 alias EGLuint64KHR = ulong; 316 enum EGLStreamKHR EGL_NO_STREAM_KHR = null; 317 enum : uint { 318 EGL_CONSUMER_LATENCY_USEC_KHR = 0x3210, 319 EGL_PRODUCER_FRAME_KHR = 0x3212, 320 EGL_CONSUMER_FRAME_KHR = 0x3213, 321 EGL_STREAM_STATE_KHR = 0x3214, 322 EGL_STREAM_STATE_CREATED_KHR = 0x3215, 323 EGL_STREAM_STATE_CONNECTING_KHR = 0x3216, 324 EGL_STREAM_STATE_EMPTY_KHR = 0x3217, 325 EGL_STREAM_STATE_NEW_FRAME_AVAILABLE_KHR = 0x3218, 326 EGL_STREAM_STATE_OLD_FRAME_AVAILABLE_KHR = 0x3219, 327 EGL_STREAM_STATE_DISCONNECTED_KHR = 0x321A, 328 EGL_BAD_STREAM_KHR = 0x321B, 329 EGL_BAD_STATE_KHR = 0x321C, 330 } 331 extern( System ) nothrow { 332 alias EGLStreamKHR function( EGLDisplay, const EGLint* ) da_eglCreateStreamKHR; 333 alias EGLBoolean function( EGLDisplay, EGLStreamKHR ) da_eglDestroyStreamKHR; 334 alias EGLBoolean function( EGLDisplay, EGLStreamKHR, EGLenum, EGLint ) da_eglStreamAttribKHR; 335 alias EGLBoolean function( EGLDisplay, EGLStreamKHR, EGLenum, EGLint* ) da_eglQueryStreamKHR; 336 alias EGLBoolean function( EGLDisplay, EGLStreamKHR, EGLenum, EGLuint64KHR* ) da_eglQueryStreamu64KHR; 337 } 338 __gshared { 339 da_eglCreateStreamKHR eglCreateStreamKHR; 340 da_eglDestroyStreamKHR eglDestroyStreamKHR; 341 da_eglStreamAttribKHR eglStreamAttribKHR; 342 da_eglQueryStreamKHR eglQueryStreamKHR; 343 da_eglQueryStreamu64KHR eglQueryStreamu64KHR; 344 } 345 private void load_EGL_KHR_stream() { 346 try { 347 bindGLFunc( cast( void** )&eglCreateStreamKHR, "eglCreateStreamKHR" ); 348 bindGLFunc( cast( void** )&eglDestroyStreamKHR, "eglDestroyStreamKHR" ); 349 bindGLFunc( cast( void** )&eglStreamAttribKHR, "eglStreamAttribKHR" ); 350 bindGLFunc( cast( void** )&eglQueryStreamKHR, "eglQueryStreamKHR" ); 351 bindGLFunc( cast( void** )&eglQueryStreamu64KHR, "eglQueryStreamu64KHR" ); 352 353 _EGL_KHR_stream = true; 354 } catch( Exception e ) { 355 _EGL_KHR_stream = false; 356 } 357 } 358 359 private __gshared bool _EGL_KHR_stream_consumer_gltexture; 360 bool EGL_KHR_stream_consumer_gltexture() @property { return _EGL_KHR_stream_consumer_gltexture; } 361 enum : uint { 362 EGL_CONSUMER_ACQUIRE_TIMEOUT_USEC_KHR = 0x321E, 363 } 364 extern( System ) nothrow { 365 alias EGLBoolean function( EGLDisplay, EGLStreamKHR ) da_eglStreamConsumerGLTextureExternalKHR; 366 alias EGLBoolean function( EGLDisplay, EGLStreamKHR ) da_eglStreamConsumerAcquireKHR; 367 alias EGLBoolean function( EGLDisplay, EGLStreamKHR ) da_eglStreamConsumerReleaseKHR; 368 } 369 __gshared { 370 da_eglStreamConsumerGLTextureExternalKHR eglStreamConsumerGLTextureExternalKHR; 371 da_eglStreamConsumerAcquireKHR eglStreamConsumerAcquireKHR; 372 da_eglStreamConsumerReleaseKHR eglStreamConsumerReleaseKHR; 373 } 374 private void load_EGL_KHR_stream_consumer_gltexture() { 375 try { 376 bindGLFunc( cast( void** )&eglStreamConsumerGLTextureExternalKHR, "eglStreamConsumerGLTextureExternalKHR" ); 377 bindGLFunc( cast( void** )&eglStreamConsumerAcquireKHR, "eglStreamConsumerAcquireKHR" ); 378 bindGLFunc( cast( void** )&eglStreamConsumerReleaseKHR, "eglStreamConsumerReleaseKHR" ); 379 380 _EGL_KHR_stream_consumer_gltexture = true; 381 } catch( Exception e ) { 382 _EGL_KHR_stream_consumer_gltexture = false; 383 } 384 } 385 386 private __gshared bool _EGL_KHR_stream_cross_process_fd; 387 bool EGL_KHR_stream_cross_process_fd() @property { return _EGL_KHR_stream_cross_process_fd; } 388 alias EGLNativeFileDescriptorKHR = int; 389 enum EGLNativeFileDescriptorKHR EGL_NO_FILE_DESCRIPTOR_KHR = -1; 390 EGLNativeFileDescriptorKHR eglGetStreamFileDescriptorKHR( EGLDisplay, EGLStreamKHR ); 391 EGLStreamKHR eglCreateStreamFromFileDescriptorKHR( EGLDisplay, EGLNativeFileDescriptorKHR ); 392 393 private __gshared bool _EGL_KHR_stream_fifo; 394 bool EGL_KHR_stream_fifo() @property { return _EGL_KHR_stream_fifo; } 395 enum : uint { 396 EGL_STREAM_FIFO_LENGTH_KHR = 0x31FC, 397 EGL_STREAM_TIME_NOW_KHR = 0x31FD, 398 EGL_STREAM_TIME_CONSUMER_KHR = 0x31FE, 399 EGL_STREAM_TIME_PRODUCER_KHR = 0x31FF, 400 } 401 extern( System ) nothrow { 402 alias EGLBoolean function( EGLDisplay, EGLStreamKHR, EGLenum, EGLTimeKHR* ) da_eglQueryStreamTimeKHR; 403 } 404 __gshared { 405 da_eglQueryStreamTimeKHR eglQueryStreamTimeKHR; 406 } 407 private void load_EGL_KHR_stream_fifo() { 408 try { 409 bindGLFunc( cast( void** )&eglQueryStreamTimeKHR, "eglQueryStreamTimeKHR" ); 410 411 _EGL_KHR_stream_fifo = true; 412 } catch( Exception e ) { 413 _EGL_KHR_stream_fifo = false; 414 } 415 } 416 417 private __gshared bool _EGL_KHR_stream_producer_aldatalocator; 418 bool EGL_KHR_stream_producer_aldatalocator() @property { return _EGL_KHR_stream_producer_aldatalocator; } 419 420 private __gshared bool _EGL_KHR_stream_producer_eglsurface; 421 bool EGL_KHR_stream_producer_eglsurface() @property { return _EGL_KHR_stream_producer_eglsurface; } 422 enum : uint { 423 EGL_STREAM_BIT_KHR = 0x0800, 424 } 425 extern( System ) nothrow { 426 alias EGLSurface function( EGLDisplay, EGLConfig, EGLStreamKHR, const EGLint* ) da_eglCreateStreamProducerSurfaceKHR; 427 } 428 __gshared { 429 da_eglCreateStreamProducerSurfaceKHR eglCreateStreamProducerSurfaceKHR; 430 } 431 private void load_EGL_KHR_stream_producer_eglsurface() { 432 try { 433 bindGLFunc( cast( void** )&eglCreateStreamProducerSurfaceKHR, "eglCreateStreamProducerSurfaceKHR" ); 434 435 _EGL_KHR_stream_producer_eglsurface = true; 436 } catch( Exception e ) { 437 _EGL_KHR_stream_producer_eglsurface = false; 438 } 439 } 440 441 private __gshared bool _EGL_KHR_surfaceless_context; 442 bool EGL_KHR_surfaceless_context() @property { return _EGL_KHR_surfaceless_context; } 443 444 private __gshared bool _EGL_KHR_vg_parent_image; 445 bool EGL_KHR_vg_parent_image() @property { return _EGL_KHR_vg_parent_image; } 446 enum : uint { 447 EGL_VG_PARENT_IMAGE_KHR = 0x30BA, 448 } 449 450 private __gshared bool _EGL_KHR_wait_sync; 451 bool EGL_KHR_wait_sync() @property { return _EGL_KHR_wait_sync; } 452 extern( System ) nothrow { 453 alias EGLint function( EGLDisplay, EGLSyncKHR, EGLint ) da_eglWaitSyncKHR; 454 } 455 __gshared { 456 da_eglWaitSyncKHR eglWaitSyncKHR; 457 } 458 private void load_EGL_KHR_wait_sync() { 459 try { 460 bindGLFunc( cast( void** )&eglWaitSyncKHR, "eglWaitSyncKHR" ); 461 462 _EGL_KHR_wait_sync = true; 463 } catch( Exception e ) { 464 _EGL_KHR_wait_sync = false; 465 } 466 } 467 468 private __gshared bool _EGL_ANDROID_blob_cache; 469 bool EGL_ANDROID_blob_cache() @property { return _EGL_ANDROID_blob_cache; } 470 alias EGLsizeiANDROID = intptr_t; 471 alias void function( const void*, EGLsizeiANDROID, const void*, EGLsizeiANDROID ) EGLSetBlobFuncANDROID; 472 alias void function( const void*, EGLsizeiANDROID, const void*, EGLsizeiANDROID ) EGLGetBlobFuncANDROID; 473 extern( System ) nothrow { 474 alias void function( EGLDisplay, EGLSetBlobFuncANDROID, EGLGetBlobFuncANDROID ) da_eglSetBlobCacheFuncsANDROID; 475 } 476 __gshared { 477 da_eglSetBlobCacheFuncsANDROID eglSetBlobCacheFuncsANDROID; 478 } 479 private void load_EGL_ANDROID_blob_cache() { 480 try { 481 bindGLFunc( cast( void** )&eglSetBlobCacheFuncsANDROID, "eglSetBlobCacheFuncsANDROID" ); 482 483 _EGL_ANDROID_blob_cache = true; 484 } catch( Exception e ) { 485 _EGL_ANDROID_blob_cache = false; 486 } 487 } 488 489 private __gshared bool _EGL_ANDROID_framebuffer_target; 490 bool EGL_ANDROID_framebuffer_target() @property { return _EGL_ANDROID_framebuffer_target; } 491 enum : uint { 492 EGL_FRAMEBUFFER_TARGET_ANDROID = 0x3147, 493 } 494 495 private __gshared bool _EGL_ANDROID_image_native_buffer; 496 bool EGL_ANDROID_image_native_buffer() @property { return _EGL_ANDROID_image_native_buffer; } 497 enum : uint { 498 EGL_NATIVE_BUFFER_ANDROID = 0x3140, 499 } 500 501 private __gshared bool _EGL_ANDROID_native_fence_sync; 502 bool EGL_ANDROID_native_fence_sync() @property { return _EGL_ANDROID_native_fence_sync; } 503 enum int EGL_NO_NATIVE_FENCE_ANDROID = -1; 504 enum : uint { 505 EGL_SYNC_NATIVE_FENCE_ANDROID = 0x3144, 506 EGL_SYNC_NATIVE_FENCE_FD_ANDROID = 0x3145, 507 EGL_SYNC_NATIVE_FENCE_SIGNALED_ANDROID = 0x3146, 508 } 509 extern( System ) nothrow { 510 alias EGLint function( EGLDisplay, EGLSyncKHR ) da_eglDupNativeFenceFDANDROID; 511 } 512 __gshared { 513 da_eglDupNativeFenceFDANDROID eglDupNativeFenceFDANDROID; 514 } 515 private void load_EGL_ANDROID_native_fence_sync() { 516 try { 517 bindGLFunc( cast( void** )&eglDupNativeFenceFDANDROID, "eglDupNativeFenceFDANDROID" ); 518 519 _EGL_ANDROID_native_fence_sync = true; 520 } catch( Exception e ) { 521 _EGL_ANDROID_native_fence_sync = false; 522 } 523 } 524 525 private __gshared bool _EGL_ANDROID_recordable; 526 bool EGL_ANDROID_recordable() @property { return _EGL_ANDROID_recordable; } 527 enum : uint { 528 EGL_RECORDABLE_ANDROID = 0x3142, 529 } 530 531 private __gshared bool _EGL_ANGLE_d3d_share_handle_client_buffer; 532 bool EGL_ANGLE_d3d_share_handle_client_buffer() @property { return _EGL_ANGLE_d3d_share_handle_client_buffer; } 533 enum : uint { 534 EGL_D3D_TEXTURE_2D_SHARE_HANDLE_ANGLE = 0x3200, 535 } 536 537 private __gshared bool _EGL_ANGLE_query_surface_pointer; 538 bool EGL_ANGLE_query_surface_pointer() @property { return _EGL_ANGLE_query_surface_pointer; } 539 extern( System ) nothrow { 540 alias EGLBoolean function( EGLDisplay, EGLSurface, EGLint, void** ) da_eglQuerySurfacePointerANGLE; 541 } 542 __gshared { 543 da_eglQuerySurfacePointerANGLE eglQuerySurfacePointerANGLE; 544 } 545 private void load_EGL_ANGLE_query_surface_pointer() { 546 try { 547 bindGLFunc( cast( void** )&eglQuerySurfacePointerANGLE, "eglQuerySurfacePointerANGLE" ); 548 549 _EGL_ANGLE_query_surface_pointer = true; 550 } catch( Exception e ) { 551 _EGL_ANGLE_query_surface_pointer = false; 552 } 553 } 554 555 private __gshared bool _EGL_ANGLE_surface_d3d_texture_2d_share_handle; 556 bool EGL_ANGLE_surface_d3d_texture_2d_share_handle() @property { return _EGL_ANGLE_surface_d3d_texture_2d_share_handle; } 557 558 private __gshared bool _EGL_ARM_pixmap_multisample_discard; 559 bool EGL_ARM_pixmap_multisample_discard() @property { return _EGL_ARM_pixmap_multisample_discard; } 560 enum : uint { 561 EGL_DISCARD_SAMPLES_ARM = 0x3286, 562 } 563 564 private __gshared bool _EGL_EXT_buffer_age; 565 bool EGL_EXT_buffer_age() @property { return _EGL_EXT_buffer_age; } 566 enum : uint { 567 EGL_BUFFER_AGE_EXT = 0x313D, 568 } 569 570 private __gshared bool _EGL_EXT_client_extensions; 571 bool EGL_EXT_client_extensions() @property { return _EGL_EXT_client_extensions; } 572 573 private __gshared bool _EGL_EXT_create_context_robustness; 574 bool EGL_EXT_create_context_robustness() @property { return _EGL_EXT_create_context_robustness; } 575 enum : uint { 576 EGL_CONTEXT_OPENGL_ROBUST_ACCESS_EXT = 0x30BF, 577 EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY_EXT = 0x3138, 578 EGL_NO_RESET_NOTIFICATION_EXT = 0x31BE, 579 EGL_LOSE_CONTEXT_ON_RESET_EXT = 0x31BF, 580 } 581 582 private __gshared bool _EGL_EXT_device_base; 583 bool EGL_EXT_device_base() @property { return _EGL_EXT_device_base; } 584 alias EGLDeviceEXT = void*; 585 enum EGLDeviceEXT EGL_NO_DEVICE_EXT = null; 586 enum : uint { 587 EGL_BAD_DEVICE_EXT = 0x322B, 588 EGL_DEVICE_EXT = 0x322C, 589 } 590 extern( System ) nothrow { 591 alias EGLBoolean function( EGLDeviceEXT, EGLint, EGLAttrib* ) da_eglQueryDeviceAttribEXT; 592 alias const( char )* function( EGLDeviceEXT, EGLint ) da_eglQueryDeviceStringEXT; 593 alias EGLBoolean function( EGLint, EGLDeviceEXT*, EGLint* ) da_eglQueryDevicesEXT; 594 alias EGLBoolean function( EGLDisplay, EGLint, EGLAttrib* ) da_eglQueryDisplayAttribEXT; 595 } 596 __gshared { 597 da_eglQueryDeviceAttribEXT eglQueryDeviceAttribEXT; 598 da_eglQueryDeviceStringEXT eglQueryDeviceStringEXT; 599 da_eglQueryDevicesEXT eglQueryDevicesEXT; 600 da_eglQueryDisplayAttribEXT eglQueryDisplayAttribEXT; 601 } 602 private void load_EGL_EXT_device_base() { 603 try { 604 bindGLFunc( cast( void** )&eglQueryDeviceAttribEXT, "eglQueryDeviceAttribEXT" ); 605 bindGLFunc( cast( void** )&eglQueryDeviceStringEXT, "eglQueryDeviceStringEXT" ); 606 bindGLFunc( cast( void** )&eglQueryDevicesEXT, "eglQueryDevicesEXT" ); 607 bindGLFunc( cast( void** )&eglQueryDisplayAttribEXT, "eglQueryDisplayAttribEXT" ); 608 609 _EGL_EXT_device_base = true; 610 } catch( Exception e ) { 611 _EGL_EXT_device_base = false; 612 } 613 } 614 615 private __gshared bool _EGL_EXT_image_dma_buf_import; 616 bool EGL_EXT_image_dma_buf_import() @property { return _EGL_EXT_image_dma_buf_import; } 617 enum : uint { 618 EGL_LINUX_DMA_BUF_EXT = 0x3270, 619 EGL_LINUX_DRM_FOURCC_EXT = 0x3271, 620 EGL_DMA_BUF_PLANE0_FD_EXT = 0x3272, 621 EGL_DMA_BUF_PLANE0_OFFSET_EXT = 0x3273, 622 EGL_DMA_BUF_PLANE0_PITCH_EXT = 0x3274, 623 EGL_DMA_BUF_PLANE1_FD_EXT = 0x3275, 624 EGL_DMA_BUF_PLANE1_OFFSET_EXT = 0x3276, 625 EGL_DMA_BUF_PLANE1_PITCH_EXT = 0x3277, 626 EGL_DMA_BUF_PLANE2_FD_EXT = 0x3278, 627 EGL_DMA_BUF_PLANE2_OFFSET_EXT = 0x3279, 628 EGL_DMA_BUF_PLANE2_PITCH_EXT = 0x327A, 629 EGL_YUV_COLOR_SPACE_HINT_EXT = 0x327B, 630 EGL_SAMPLE_RANGE_HINT_EXT = 0x327C, 631 EGL_YUV_CHROMA_HORIZONTAL_SITING_HINT_EXT = 0x327D, 632 EGL_YUV_CHROMA_VERTICAL_SITING_HINT_EXT = 0x327E, 633 EGL_ITU_REC601_EXT = 0x327F, 634 EGL_ITU_REC709_EXT = 0x3280, 635 EGL_ITU_REC2020_EXT = 0x3281, 636 EGL_YUV_FULL_RANGE_EXT = 0x3282, 637 EGL_YUV_NARROW_RANGE_EXT = 0x3283, 638 EGL_YUV_CHROMA_SITING_0_EXT = 0x3284, 639 EGL_YUV_CHROMA_SITING_0_5_EXT = 0x3285, 640 } 641 642 private __gshared bool _EGL_EXT_multiview_window; 643 bool EGL_EXT_multiview_window() @property { return _EGL_EXT_multiview_window; } 644 enum : uint { 645 EGL_MULTIVIEW_VIEW_COUNT_EXT = 0x3134, 646 } 647 648 private __gshared bool _EGL_EXT_platform_base; 649 bool EGL_EXT_platform_base() @property { return _EGL_EXT_platform_base; } 650 extern( System ) nothrow { 651 alias EGLDisplay function( EGLenum, void*, const EGLint* ) da_eglGetPlatformDisplayEXT; 652 alias EGLSurface function( EGLDisplay, EGLConfig, void*, const EGLint* ) da_eglCreatePlatformWindowSurfaceEXT; 653 alias EGLSurface function( EGLDisplay, EGLConfig, void*, const EGLint* ) da_eglCreatePlatformPixmapSurfaceEXT; 654 } 655 __gshared { 656 da_eglGetPlatformDisplayEXT eglGetPlatformDisplayEXT; 657 da_eglCreatePlatformWindowSurfaceEXT eglCreatePlatformWindowSurfaceEXT; 658 da_eglCreatePlatformPixmapSurfaceEXT eglCreatePlatformPixmapSurfaceEXT; 659 } 660 private void load_EGL_EXT_platform_base() { 661 try { 662 bindGLFunc( cast( void** )&eglGetPlatformDisplayEXT, "eglGetPlatformDisplayEXT" ); 663 bindGLFunc( cast( void** )&eglCreatePlatformWindowSurfaceEXT, "eglCreatePlatformWindowSurfaceEXT" ); 664 bindGLFunc( cast( void** )&eglCreatePlatformPixmapSurfaceEXT, "eglCreatePlatformPixmapSurfaceEXT" ); 665 666 _EGL_EXT_platform_base = true; 667 } catch( Exception e ) { 668 _EGL_EXT_platform_base = false; 669 } 670 } 671 672 private __gshared bool _EGL_EXT_platform_device; 673 bool EGL_EXT_platform_device() @property { return _EGL_EXT_platform_device; } 674 enum : uint { 675 EGL_PLATFORM_DEVICE_EXT = 0x313F, 676 } 677 678 private __gshared bool _EGL_EXT_platform_wayland; 679 bool EGL_EXT_platform_wayland() @property { return _EGL_EXT_platform_wayland; } 680 enum : uint { 681 EGL_PLATFORM_WAYLAND_EXT = 0x31D8, 682 } 683 684 private __gshared bool _EGL_EXT_platform_x11; 685 bool EGL_EXT_platform_x11() @property { return _EGL_EXT_platform_x11; } 686 enum : uint { 687 EGL_PLATFORM_X11_EXT = 0x31D5, 688 EGL_PLATFORM_X11_SCREEN_EXT = 0x31D6, 689 } 690 691 private __gshared bool _EGL_EXT_protected_surface; 692 bool EGL_EXT_protected_surface() @property { return _EGL_EXT_protected_surface; } 693 enum : uint { 694 EGL_PROTECTED_CONTENT_EXT = 0x32C0, 695 } 696 697 private __gshared bool _EGL_EXT_swap_buffers_with_damage; 698 bool EGL_EXT_swap_buffers_with_damage() @property { return _EGL_EXT_swap_buffers_with_damage; } 699 extern( System ) nothrow { 700 alias EGLBoolean function( EGLDisplay, EGLSurface, EGLint*, EGLint ) da_eglSwapBuffersWithDamageEXT; 701 } 702 __gshared { 703 da_eglSwapBuffersWithDamageEXT eglSwapBuffersWithDamageEXT; 704 } 705 private void load_EGL_EXT_swap_buffers_with_damage() { 706 try { 707 bindGLFunc( cast( void** )&eglSwapBuffersWithDamageEXT, "eglSwapBuffersWithDamageEXT" ); 708 709 _EGL_EXT_swap_buffers_with_damage = true; 710 } catch( Exception e ) { 711 _EGL_EXT_swap_buffers_with_damage = false; 712 } 713 } 714 715 private __gshared bool _EGL_HI_clientpixmap; 716 bool EGL_HI_clientpixmap() @property { return _EGL_HI_clientpixmap; } 717 struct EGLClientPixmapHI { 718 void * pData; 719 EGLint iWidth; 720 EGLint iHeight; 721 EGLint iStride; 722 }; 723 enum : uint { 724 EGL_CLIENT_PIXMAP_POINTER_HI = 0x8F74, 725 } 726 extern( System ) nothrow { 727 alias EGLSurface function( EGLDisplay, EGLConfig, EGLClientPixmapHI* ) da_eglCreatePixmapSurfaceHI; 728 } 729 __gshared { 730 da_eglCreatePixmapSurfaceHI eglCreatePixmapSurfaceHI; 731 } 732 private void load_EGL_HI_clientpixmap() { 733 try { 734 bindGLFunc( cast( void** )&eglCreatePixmapSurfaceHI, "eglCreatePixmapSurfaceHI" ); 735 736 _EGL_HI_clientpixmap = true; 737 } catch( Exception e ) { 738 _EGL_HI_clientpixmap = false; 739 } 740 } 741 742 private __gshared bool _EGL_HI_colorformats; 743 bool EGL_HI_colorformats() @property { return _EGL_HI_colorformats; } 744 enum : uint { 745 EGL_COLOR_FORMAT_HI = 0x8F70, 746 EGL_COLOR_RGB_HI = 0x8F71, 747 EGL_COLOR_RGBA_HI = 0x8F72, 748 EGL_COLOR_ARGB_HI = 0x8F73, 749 } 750 751 private __gshared bool _EGL_IMG_context_priority; 752 bool EGL_IMG_context_priority() @property { return _EGL_IMG_context_priority; } 753 enum : uint { 754 EGL_CONTEXT_PRIORITY_LEVEL_IMG = 0x3100, 755 EGL_CONTEXT_PRIORITY_HIGH_IMG = 0x3101, 756 EGL_CONTEXT_PRIORITY_MEDIUM_IMG = 0x3102, 757 EGL_CONTEXT_PRIORITY_LOW_IMG = 0x3103, 758 } 759 760 private __gshared bool _EGL_MESA_drm_image; 761 bool EGL_MESA_drm_image() @property { return _EGL_MESA_drm_image; } 762 enum : uint { 763 EGL_DRM_BUFFER_FORMAT_MESA = 0x31D0, 764 EGL_DRM_BUFFER_USE_MESA = 0x31D1, 765 EGL_DRM_BUFFER_FORMAT_ARGB32_MESA = 0x31D2, 766 EGL_DRM_BUFFER_MESA = 0x31D3, 767 EGL_DRM_BUFFER_STRIDE_MESA = 0x31D4, 768 EGL_DRM_BUFFER_USE_SCANOUT_MESA = 0x00000001, 769 EGL_DRM_BUFFER_USE_SHARE_MESA = 0x00000002, 770 } 771 extern( System ) nothrow { 772 alias EGLImageKHR function( EGLDisplay, const EGLint* ) da_eglCreateDRMImageMESA; 773 alias EGLBoolean function( EGLDisplay, EGLImageKHR, EGLint*, EGLint*, EGLint* ) da_eglExportDRMImageMESA; 774 } 775 __gshared { 776 da_eglCreateDRMImageMESA eglCreateDRMImageMESA; 777 da_eglExportDRMImageMESA eglExportDRMImageMESA; 778 } 779 private void load_EGL_MESA_drm_image() { 780 try { 781 bindGLFunc( cast( void** )&eglCreateDRMImageMESA, "eglCreateDRMImageMESA" ); 782 bindGLFunc( cast( void** )&eglExportDRMImageMESA, "eglExportDRMImageMESA" ); 783 784 _EGL_MESA_drm_image = true; 785 } catch( Exception e ) { 786 _EGL_MESA_drm_image = false; 787 } 788 } 789 790 private __gshared bool _EGL_MESA_platform_gbm; 791 bool EGL_MESA_platform_gbm() @property { return _EGL_MESA_platform_gbm; } 792 enum : uint { 793 EGL_PLATFORM_GBM_MESA = 0x31D7, 794 } 795 796 private __gshared bool _EGL_NOK_swap_region; 797 bool EGL_NOK_swap_region() @property { return _EGL_NOK_swap_region; } 798 EGLBoolean eglSwapBuffersRegionNOK( EGLDisplay, EGLSurface, EGLint, const EGLint* ); 799 800 private __gshared bool _EGL_NOK_swap_region2; 801 bool EGL_NOK_swap_region2() @property { return _EGL_NOK_swap_region2; } 802 EGLBoolean eglSwapBuffersRegion2NOK( EGLDisplay, EGLSurface, EGLint, const EGLint* ); 803 804 private __gshared bool _EGL_NOK_texture_from_pixmap; 805 bool EGL_NOK_texture_from_pixmap() @property { return _EGL_NOK_texture_from_pixmap; } 806 enum : uint { 807 EGL_Y_INVERTED_NOK = 0x307F, 808 } 809 810 private __gshared bool _EGL_NV_3dvision_surface; 811 bool EGL_NV_3dvision_surface() @property { return _EGL_NV_3dvision_surface; } 812 enum : uint { 813 EGL_AUTO_STEREO_NV = 0x3136, 814 } 815 816 private __gshared bool _EGL_NV_coverage_sample; 817 bool EGL_NV_coverage_sample() @property { return _EGL_NV_coverage_sample; } 818 enum : uint { 819 EGL_COVERAGE_BUFFERS_NV = 0x30E0, 820 EGL_COVERAGE_SAMPLES_NV = 0x30E1, 821 } 822 823 private __gshared bool _EGL_NV_coverage_sample_resolve; 824 bool EGL_NV_coverage_sample_resolve() @property { return _EGL_NV_coverage_sample_resolve; } 825 enum : uint { 826 EGL_COVERAGE_SAMPLE_RESOLVE_NV = 0x3131, 827 EGL_COVERAGE_SAMPLE_RESOLVE_DEFAULT_NV = 0x3132, 828 EGL_COVERAGE_SAMPLE_RESOLVE_NONE_NV = 0x3133, 829 } 830 831 private __gshared bool _EGL_NV_depth_nonlinear; 832 bool EGL_NV_depth_nonlinear() @property { return _EGL_NV_depth_nonlinear; } 833 enum : uint { 834 EGL_DEPTH_ENCODING_NV = 0x30E2, 835 EGL_DEPTH_ENCODING_NONE_NV = 0, 836 EGL_DEPTH_ENCODING_NONLINEAR_NV = 0x30E3, 837 } 838 839 private __gshared bool _EGL_NV_native_query; 840 bool EGL_NV_native_query() @property { return _EGL_NV_native_query; } 841 extern( System ) nothrow { 842 alias EGLBoolean function( EGLDisplay, EGLNativeDisplayType* ) da_eglQueryNativeDisplayNV; 843 alias EGLBoolean function( EGLDisplay, EGLSurface, EGLNativeWindowType* ) da_eglQueryNativeWindowNV; 844 alias EGLBoolean function( EGLDisplay, EGLSurface, EGLNativePixmapType* ) da_eglQueryNativePixmapNV; 845 } 846 __gshared { 847 da_eglQueryNativeDisplayNV eglQueryNativeDisplayNV; 848 da_eglQueryNativeWindowNV eglQueryNativeWindowNV; 849 da_eglQueryNativePixmapNV eglQueryNativePixmapNV; 850 } 851 private void load_EGL_NV_native_query() { 852 try { 853 bindGLFunc( cast( void** )&eglQueryNativeDisplayNV, "eglQueryNativeDisplayNV" ); 854 bindGLFunc( cast( void** )&eglQueryNativeWindowNV, "eglQueryNativeWindowNV" ); 855 bindGLFunc( cast( void** )&eglQueryNativePixmapNV, "eglQueryNativePixmapNV" ); 856 857 _EGL_NV_native_query = true; 858 } catch( Exception e ) { 859 _EGL_NV_native_query = false; 860 } 861 } 862 863 private __gshared bool _EGL_NV_post_convert_rounding; 864 bool EGL_NV_post_convert_rounding() @property { return _EGL_NV_post_convert_rounding; } 865 866 private __gshared bool _EGL_NV_post_sub_buffer; 867 bool EGL_NV_post_sub_buffer() @property { return _EGL_NV_post_sub_buffer; } 868 enum : uint { 869 EGL_POST_SUB_BUFFER_SUPPORTED_NV = 0x30BE, 870 } 871 extern( System ) nothrow { 872 alias EGLBoolean function( EGLDisplay, EGLSurface, EGLint, EGLint, EGLint, EGLint ) da_eglPostSubBufferNV; 873 } 874 __gshared { 875 da_eglPostSubBufferNV eglPostSubBufferNV; 876 } 877 private void load_EGL_NV_post_sub_buffer() { 878 try { 879 bindGLFunc( cast( void** )&eglPostSubBufferNV, "eglPostSubBufferNV" ); 880 881 _EGL_NV_post_sub_buffer = true; 882 } catch( Exception e ) { 883 _EGL_NV_post_sub_buffer = false; 884 } 885 } 886 887 private __gshared bool _EGL_NV_stream_sync; 888 bool EGL_NV_stream_sync() @property { return _EGL_NV_stream_sync; } 889 enum : uint { 890 EGL_SYNC_NEW_FRAME_NV = 0x321F, 891 } 892 extern( System ) nothrow { 893 alias EGLSyncKHR function( EGLDisplay, EGLStreamKHR, EGLenum, const EGLint* ) da_eglCreateStreamSyncNV; 894 } 895 __gshared { 896 da_eglCreateStreamSyncNV eglCreateStreamSyncNV; 897 } 898 private void load_EGL_NV_stream_sync() { 899 try { 900 bindGLFunc( cast( void** )&eglCreateStreamSyncNV, "eglCreateStreamSyncNV" ); 901 902 _EGL_NV_stream_sync = true; 903 } catch( Exception e ) { 904 _EGL_NV_stream_sync = false; 905 } 906 } 907 908 private __gshared bool _EGL_NV_sync; 909 bool EGL_NV_sync() @property { return _EGL_NV_sync; } 910 alias EGLSyncNV = void*; 911 alias EGLTimeNV = ulong; 912 enum EGLSyncNV EGL_NO_SYNC_NV = null; 913 enum EGLTimeNV EGL_FOREVER_NV = 0xFFFFFFFFFFFFFFFFUL; 914 enum : uint { 915 EGL_SYNC_PRIOR_COMMANDS_COMPLETE_NV = 0x30E6, 916 EGL_SYNC_STATUS_NV = 0x30E7, 917 EGL_SIGNALED_NV = 0x30E8, 918 EGL_UNSIGNALED_NV = 0x30E9, 919 EGL_SYNC_FLUSH_COMMANDS_BIT_NV = 0x0001, 920 EGL_ALREADY_SIGNALED_NV = 0x30EA, 921 EGL_TIMEOUT_EXPIRED_NV = 0x30EB, 922 EGL_CONDITION_SATISFIED_NV = 0x30EC, 923 EGL_SYNC_TYPE_NV = 0x30ED, 924 EGL_SYNC_CONDITION_NV = 0x30EE, 925 EGL_SYNC_FENCE_NV = 0x30EF, 926 } 927 extern( System ) nothrow { 928 alias EGLSyncNV function( EGLDisplay, EGLenum, const EGLint* ) da_eglCreateFenceSyncNV; 929 alias EGLBoolean function( EGLSyncNV ) da_eglDestroySyncNV; 930 alias EGLBoolean function( EGLSyncNV ) da_eglFenceNV; 931 alias EGLint function( EGLSyncNV, EGLint, EGLTimeNV ) da_eglClientWaitSyncNV; 932 alias EGLBoolean function( EGLSyncNV, EGLenum ) da_eglSignalSyncNV; 933 alias EGLBoolean function( EGLSyncNV, EGLint, EGLint* ) da_eglGetSyncAttribNV; 934 } 935 __gshared { 936 da_eglCreateFenceSyncNV eglCreateFenceSyncNV; 937 da_eglDestroySyncNV eglDestroySyncNV; 938 da_eglFenceNV eglFenceNV; 939 da_eglClientWaitSyncNV eglClientWaitSyncNV; 940 da_eglSignalSyncNV eglSignalSyncNV; 941 da_eglGetSyncAttribNV eglGetSyncAttribNV; 942 } 943 private void load_EGL_NV_sync() { 944 try { 945 bindGLFunc( cast( void** )&eglCreateFenceSyncNV, "eglCreateFenceSyncNV" ); 946 bindGLFunc( cast( void** )&eglDestroySyncNV, "eglDestroySyncNV" ); 947 bindGLFunc( cast( void** )&eglFenceNV, "eglFenceNV" ); 948 bindGLFunc( cast( void** )&eglClientWaitSyncNV, "eglClientWaitSyncNV" ); 949 bindGLFunc( cast( void** )&eglSignalSyncNV, "eglSignalSyncNV" ); 950 bindGLFunc( cast( void** )&eglGetSyncAttribNV, "eglGetSyncAttribNV" ); 951 952 _EGL_NV_sync = true; 953 } catch( Exception e ) { 954 _EGL_NV_sync = false; 955 } 956 } 957 958 private __gshared bool _EGL_NV_system_time; 959 bool EGL_NV_system_time() @property { return _EGL_NV_system_time; } 960 alias EGLuint64NV = ulong; 961 extern( System ) nothrow { 962 alias EGLuint64NV function ( ) da_eglGetSystemTimeFrequencyNV; 963 alias EGLuint64NV function ( ) da_eglGetSystemTimeNV; 964 } 965 __gshared { 966 da_eglGetSystemTimeFrequencyNV eglGetSystemTimeFrequencyNV; 967 da_eglGetSystemTimeNV eglGetSystemTimeNV; 968 } 969 private void load_EGL_NV_system_time() { 970 try { 971 bindGLFunc( cast( void** )&eglGetSystemTimeFrequencyNV, "eglGetSystemTimeFrequencyNV" ); 972 bindGLFunc( cast( void** )&eglGetSystemTimeNV, "eglGetSystemTimeNV" ); 973 974 _EGL_NV_system_time = true; 975 } catch( Exception e ) { 976 _EGL_NV_system_time = false; 977 } 978 } 979 980 package void loadEXT( EGLDisplay disp ) { 981 _EGL_KHR_cl_event = isEGLExtSupported( disp, "EGL_KHR_cl_event" ); 982 _EGL_KHR_cl_event2 = isEGLExtSupported( disp, "EGL_KHR_cl_event2" ); 983 if( _EGL_KHR_cl_event2 ) load_EGL_KHR_cl_event2(); 984 _EGL_KHR_client_get_all_proc_addresses = isEGLExtSupported( disp, "EGL_KHR_client_get_all_proc_addresses" ); 985 _EGL_KHR_config_attribs = isEGLExtSupported( disp, "EGL_KHR_config_attribs" ); 986 _EGL_KHR_create_context = isEGLExtSupported( disp, "EGL_KHR_create_context" ); 987 _EGL_KHR_fence_sync = isEGLExtSupported( disp, "EGL_KHR_fence_sync" ); 988 _EGL_KHR_get_all_proc_addresses = isEGLExtSupported( disp, "EGL_KHR_get_all_proc_addresses" ); 989 _EGL_KHR_gl_colorspace = isEGLExtSupported( disp, "EGL_KHR_gl_colorspace" ); 990 _EGL_KHR_gl_renderbuffer_image = isEGLExtSupported( disp, "EGL_KHR_gl_renderbuffer_image" ); 991 _EGL_KHR_gl_texture_2D_image = isEGLExtSupported( disp, "EGL_KHR_gl_texture_2D_image" ); 992 _EGL_KHR_gl_texture_3D_image = isEGLExtSupported( disp, "EGL_KHR_gl_texture_3D_image" ); 993 _EGL_KHR_gl_texture_cubemap_image = isEGLExtSupported( disp, "EGL_KHR_gl_texture_cubemap_image" ); 994 _EGL_KHR_image = isEGLExtSupported( disp, "EGL_KHR_image" ); 995 if( _EGL_KHR_image ) load_EGL_KHR_image(); 996 _EGL_KHR_image_base = isEGLExtSupported( disp, "EGL_KHR_image_base" ); 997 _EGL_KHR_image_pixmap = isEGLExtSupported( disp, "EGL_KHR_image_pixmap" ); 998 _EGL_KHR_lock_surface = isEGLExtSupported( disp, "EGL_KHR_lock_surface" ); 999 if( _EGL_KHR_lock_surface ) load_EGL_KHR_lock_surface(); 1000 _EGL_KHR_lock_surface2 = isEGLExtSupported( disp, "EGL_KHR_lock_surface2" ); 1001 _EGL_KHR_lock_surface3 = isEGLExtSupported( disp, "EGL_KHR_lock_surface3" ); 1002 if( _EGL_KHR_lock_surface3 ) load_EGL_KHR_lock_surface3(); 1003 _EGL_KHR_platform_android = isEGLExtSupported( disp, "EGL_KHR_platform_android" ); 1004 _EGL_KHR_platform_gbm = isEGLExtSupported( disp, "EGL_KHR_platform_gbm" ); 1005 _EGL_KHR_platform_wayland = isEGLExtSupported( disp, "EGL_KHR_platform_wayland" ); 1006 _EGL_KHR_platform_x11 = isEGLExtSupported( disp, "EGL_KHR_platform_x11" ); 1007 _EGL_KHR_reusable_sync = isEGLExtSupported( disp, "EGL_KHR_reusable_sync" ); 1008 if( _EGL_KHR_reusable_sync ) load_EGL_KHR_reusable_sync(); 1009 _EGL_KHR_stream = isEGLExtSupported( disp, "EGL_KHR_stream" ); 1010 if( _EGL_KHR_stream ) load_EGL_KHR_stream(); 1011 _EGL_KHR_stream_consumer_gltexture = isEGLExtSupported( disp, "EGL_KHR_stream_consumer_gltexture" ); 1012 if( _EGL_KHR_stream_consumer_gltexture ) load_EGL_KHR_stream_consumer_gltexture(); 1013 _EGL_KHR_stream_cross_process_fd = isEGLExtSupported( disp, "EGL_KHR_stream_cross_process_fd" ); 1014 _EGL_KHR_stream_fifo = isEGLExtSupported( disp, "EGL_KHR_stream_fifo" ); 1015 if( _EGL_KHR_stream_fifo ) load_EGL_KHR_stream_fifo(); 1016 _EGL_KHR_stream_producer_aldatalocator = isEGLExtSupported( disp, "EGL_KHR_stream_producer_aldatalocator" ); 1017 _EGL_KHR_stream_producer_eglsurface = isEGLExtSupported( disp, "EGL_KHR_stream_producer_eglsurface" ); 1018 if( _EGL_KHR_stream_producer_eglsurface ) load_EGL_KHR_stream_producer_eglsurface(); 1019 _EGL_KHR_surfaceless_context = isEGLExtSupported( disp, "EGL_KHR_surfaceless_context" ); 1020 _EGL_KHR_vg_parent_image = isEGLExtSupported( disp, "EGL_KHR_vg_parent_image" ); 1021 _EGL_KHR_wait_sync = isEGLExtSupported( disp, "EGL_KHR_wait_sync" ); 1022 if( _EGL_KHR_wait_sync ) load_EGL_KHR_wait_sync(); 1023 _EGL_ANDROID_blob_cache = isEGLExtSupported( disp, "EGL_ANDROID_blob_cache" ); 1024 if( _EGL_ANDROID_blob_cache ) load_EGL_ANDROID_blob_cache(); 1025 _EGL_ANDROID_framebuffer_target = isEGLExtSupported( disp, "EGL_ANDROID_framebuffer_target" ); 1026 _EGL_ANDROID_image_native_buffer = isEGLExtSupported( disp, "EGL_ANDROID_image_native_buffer" ); 1027 _EGL_ANDROID_native_fence_sync = isEGLExtSupported( disp, "EGL_ANDROID_native_fence_sync" ); 1028 if( _EGL_ANDROID_native_fence_sync ) load_EGL_ANDROID_native_fence_sync(); 1029 _EGL_ANDROID_recordable = isEGLExtSupported( disp, "EGL_ANDROID_recordable" ); 1030 _EGL_ANGLE_d3d_share_handle_client_buffer = isEGLExtSupported( disp, "EGL_ANGLE_d3d_share_handle_client_buffer" ); 1031 _EGL_ANGLE_query_surface_pointer = isEGLExtSupported( disp, "EGL_ANGLE_query_surface_pointer" ); 1032 if( _EGL_ANGLE_query_surface_pointer ) load_EGL_ANGLE_query_surface_pointer(); 1033 _EGL_ANGLE_surface_d3d_texture_2d_share_handle = isEGLExtSupported( disp, "EGL_ANGLE_surface_d3d_texture_2d_share_handle" ); 1034 _EGL_ARM_pixmap_multisample_discard = isEGLExtSupported( disp, "EGL_ARM_pixmap_multisample_discard" ); 1035 _EGL_EXT_buffer_age = isEGLExtSupported( disp, "EGL_EXT_buffer_age" ); 1036 _EGL_EXT_client_extensions = isEGLExtSupported( disp, "EGL_EXT_client_extensions" ); 1037 _EGL_EXT_create_context_robustness = isEGLExtSupported( disp, "EGL_EXT_create_context_robustness" ); 1038 _EGL_EXT_device_base = isEGLExtSupported( disp, "EGL_EXT_device_base" ); 1039 if( _EGL_EXT_device_base ) load_EGL_EXT_device_base(); 1040 _EGL_EXT_image_dma_buf_import = isEGLExtSupported( disp, "EGL_EXT_image_dma_buf_import" ); 1041 _EGL_EXT_multiview_window = isEGLExtSupported( disp, "EGL_EXT_multiview_window" ); 1042 _EGL_EXT_platform_base = isEGLExtSupported( disp, "EGL_EXT_platform_base" ); 1043 if( _EGL_EXT_platform_base ) load_EGL_EXT_platform_base(); 1044 _EGL_EXT_platform_device = isEGLExtSupported( disp, "EGL_EXT_platform_device" ); 1045 _EGL_EXT_platform_wayland = isEGLExtSupported( disp, "EGL_EXT_platform_wayland" ); 1046 _EGL_EXT_platform_x11 = isEGLExtSupported( disp, "EGL_EXT_platform_x11" ); 1047 _EGL_EXT_protected_surface = isEGLExtSupported( disp, "EGL_EXT_protected_surface" ); 1048 _EGL_EXT_swap_buffers_with_damage = isEGLExtSupported( disp, "EGL_EXT_swap_buffers_with_damage" ); 1049 if( _EGL_EXT_swap_buffers_with_damage ) load_EGL_EXT_swap_buffers_with_damage(); 1050 _EGL_HI_clientpixmap = isEGLExtSupported( disp, "EGL_HI_clientpixmap" ); 1051 if( _EGL_HI_clientpixmap ) load_EGL_HI_clientpixmap(); 1052 _EGL_HI_colorformats = isEGLExtSupported( disp, "EGL_HI_colorformats" ); 1053 _EGL_IMG_context_priority = isEGLExtSupported( disp, "EGL_IMG_context_priority" ); 1054 _EGL_MESA_drm_image = isEGLExtSupported( disp, "EGL_MESA_drm_image" ); 1055 if( _EGL_MESA_drm_image ) load_EGL_MESA_drm_image(); 1056 _EGL_MESA_platform_gbm = isEGLExtSupported( disp, "EGL_MESA_platform_gbm" ); 1057 _EGL_NOK_swap_region = isEGLExtSupported( disp, "EGL_NOK_swap_region" ); 1058 _EGL_NOK_swap_region2 = isEGLExtSupported( disp, "EGL_NOK_swap_region2" ); 1059 _EGL_NOK_texture_from_pixmap = isEGLExtSupported( disp, "EGL_NOK_texture_from_pixmap" ); 1060 _EGL_NV_3dvision_surface = isEGLExtSupported( disp, "EGL_NV_3dvision_surface" ); 1061 _EGL_NV_coverage_sample = isEGLExtSupported( disp, "EGL_NV_coverage_sample" ); 1062 _EGL_NV_coverage_sample_resolve = isEGLExtSupported( disp, "EGL_NV_coverage_sample_resolve" ); 1063 _EGL_NV_depth_nonlinear = isEGLExtSupported( disp, "EGL_NV_depth_nonlinear" ); 1064 _EGL_NV_native_query = isEGLExtSupported( disp, "EGL_NV_native_query" ); 1065 if( _EGL_NV_native_query ) load_EGL_NV_native_query(); 1066 _EGL_NV_post_convert_rounding = isEGLExtSupported( disp, "EGL_NV_post_convert_rounding" ); 1067 _EGL_NV_post_sub_buffer = isEGLExtSupported( disp, "EGL_NV_post_sub_buffer" ); 1068 if( _EGL_NV_post_sub_buffer ) load_EGL_NV_post_sub_buffer(); 1069 _EGL_NV_stream_sync = isEGLExtSupported( disp, "EGL_NV_stream_sync" ); 1070 if( _EGL_NV_stream_sync ) load_EGL_NV_stream_sync(); 1071 _EGL_NV_sync = isEGLExtSupported( disp, "EGL_NV_sync" ); 1072 if( _EGL_NV_sync ) load_EGL_NV_sync(); 1073 _EGL_NV_system_time = isEGLExtSupported( disp, "EGL_NV_system_time" ); 1074 if( _EGL_NV_system_time ) load_EGL_NV_system_time(); 1075 }