SDL_egl.h 72 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677
  1. /*
  2. Simple DirectMedia Layer
  3. Copyright (C) 1997-2020 Sam Lantinga <slouken@libsdl.org>
  4. This software is provided 'as-is', without any express or implied
  5. warranty. In no event will the authors be held liable for any damages
  6. arising from the use of this software.
  7. Permission is granted to anyone to use this software for any purpose,
  8. including commercial applications, and to alter it and redistribute it
  9. freely, subject to the following restrictions:
  10. 1. The origin of this software must not be misrepresented; you must not
  11. claim that you wrote the original software. If you use this software
  12. in a product, an acknowledgment in the product documentation would be
  13. appreciated but is not required.
  14. 2. Altered source versions must be plainly marked as such, and must not be
  15. misrepresented as being the original software.
  16. 3. This notice may not be removed or altered from any source distribution.
  17. */
  18. /**
  19. * \file SDL_egl.h
  20. *
  21. * This is a simple file to encapsulate the EGL API headers.
  22. */
  23. #if !defined(_MSC_VER) && !defined(__ANDROID__)
  24. #include <EGL/egl.h>
  25. #include <EGL/eglext.h>
  26. #else /* _MSC_VER */
  27. /* EGL headers for Visual Studio */
  28. #ifndef __khrplatform_h_
  29. #define __khrplatform_h_
  30. /*
  31. ** Copyright (c) 2008-2009 The Khronos Group Inc.
  32. **
  33. ** Permission is hereby granted, free of charge, to any person obtaining a
  34. ** copy of this software and/or associated documentation files (the
  35. ** "Materials"), to deal in the Materials without restriction, including
  36. ** without limitation the rights to use, copy, modify, merge, publish,
  37. ** distribute, sublicense, and/or sell copies of the Materials, and to
  38. ** permit persons to whom the Materials are furnished to do so, subject to
  39. ** the following conditions:
  40. **
  41. ** The above copyright notice and this permission notice shall be included
  42. ** in all copies or substantial portions of the Materials.
  43. **
  44. ** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  45. ** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  46. ** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
  47. ** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
  48. ** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
  49. ** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
  50. ** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
  51. */
  52. /* Khronos platform-specific types and definitions.
  53. *
  54. * $Revision: 23298 $ on $Date: 2013-09-30 17:07:13 -0700 (Mon, 30 Sep 2013) $
  55. *
  56. * Adopters may modify this file to suit their platform. Adopters are
  57. * encouraged to submit platform specific modifications to the Khronos
  58. * group so that they can be included in future versions of this file.
  59. * Please submit changes by sending them to the public Khronos Bugzilla
  60. * (http://khronos.org/bugzilla) by filing a bug against product
  61. * "Khronos (general)" component "Registry".
  62. *
  63. * A predefined template which fills in some of the bug fields can be
  64. * reached using http://tinyurl.com/khrplatform-h-bugreport, but you
  65. * must create a Bugzilla login first.
  66. *
  67. *
  68. * See the Implementer's Guidelines for information about where this file
  69. * should be located on your system and for more details of its use:
  70. * http://www.khronos.org/registry/implementers_guide.pdf
  71. *
  72. * This file should be included as
  73. * #include <KHR/khrplatform.h>
  74. * by Khronos client API header files that use its types and defines.
  75. *
  76. * The types in khrplatform.h should only be used to define API-specific types.
  77. *
  78. * Types defined in khrplatform.h:
  79. * khronos_int8_t signed 8 bit
  80. * khronos_uint8_t unsigned 8 bit
  81. * khronos_int16_t signed 16 bit
  82. * khronos_uint16_t unsigned 16 bit
  83. * khronos_int32_t signed 32 bit
  84. * khronos_uint32_t unsigned 32 bit
  85. * khronos_int64_t signed 64 bit
  86. * khronos_uint64_t unsigned 64 bit
  87. * khronos_intptr_t signed same number of bits as a pointer
  88. * khronos_uintptr_t unsigned same number of bits as a pointer
  89. * khronos_ssize_t signed size
  90. * khronos_usize_t unsigned size
  91. * khronos_float_t signed 32 bit floating point
  92. * khronos_time_ns_t unsigned 64 bit time in nanoseconds
  93. * khronos_utime_nanoseconds_t unsigned time interval or absolute time in
  94. * nanoseconds
  95. * khronos_stime_nanoseconds_t signed time interval in nanoseconds
  96. * khronos_boolean_enum_t enumerated boolean type. This should
  97. * only be used as a base type when a client API's boolean type is
  98. * an enum. Client APIs which use an integer or other type for
  99. * booleans cannot use this as the base type for their boolean.
  100. *
  101. * Tokens defined in khrplatform.h:
  102. *
  103. * KHRONOS_FALSE, KHRONOS_TRUE Enumerated boolean false/true values.
  104. *
  105. * KHRONOS_SUPPORT_INT64 is 1 if 64 bit integers are supported; otherwise 0.
  106. * KHRONOS_SUPPORT_FLOAT is 1 if floats are supported; otherwise 0.
  107. *
  108. * Calling convention macros defined in this file:
  109. * KHRONOS_APICALL
  110. * KHRONOS_APIENTRY
  111. * KHRONOS_APIATTRIBUTES
  112. *
  113. * These may be used in function prototypes as:
  114. *
  115. * KHRONOS_APICALL void KHRONOS_APIENTRY funcname(
  116. * int arg1,
  117. * int arg2) KHRONOS_APIATTRIBUTES;
  118. */
  119. /*-------------------------------------------------------------------------
  120. * Definition of KHRONOS_APICALL
  121. *-------------------------------------------------------------------------
  122. * This precedes the return type of the function in the function prototype.
  123. */
  124. #if defined(_WIN32) && !defined(__SCITECH_SNAP__) && !defined(SDL_VIDEO_STATIC_ANGLE)
  125. # define KHRONOS_APICALL __declspec(dllimport)
  126. #elif defined (__SYMBIAN32__)
  127. # define KHRONOS_APICALL IMPORT_C
  128. #else
  129. # define KHRONOS_APICALL
  130. #endif
  131. /*-------------------------------------------------------------------------
  132. * Definition of KHRONOS_APIENTRY
  133. *-------------------------------------------------------------------------
  134. * This follows the return type of the function and precedes the function
  135. * name in the function prototype.
  136. */
  137. #if defined(_WIN32) && !defined(_WIN32_WCE) && !defined(__SCITECH_SNAP__)
  138. /* Win32 but not WinCE */
  139. # define KHRONOS_APIENTRY __stdcall
  140. #else
  141. # define KHRONOS_APIENTRY
  142. #endif
  143. /*-------------------------------------------------------------------------
  144. * Definition of KHRONOS_APIATTRIBUTES
  145. *-------------------------------------------------------------------------
  146. * This follows the closing parenthesis of the function prototype arguments.
  147. */
  148. #if defined (__ARMCC_2__)
  149. #define KHRONOS_APIATTRIBUTES __softfp
  150. #else
  151. #define KHRONOS_APIATTRIBUTES
  152. #endif
  153. /*-------------------------------------------------------------------------
  154. * basic type definitions
  155. *-----------------------------------------------------------------------*/
  156. #if (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L) || defined(__GNUC__) || defined(__SCO__) || defined(__USLC__)
  157. /*
  158. * Using <stdint.h>
  159. */
  160. #include <stdint.h>
  161. typedef int32_t khronos_int32_t;
  162. typedef uint32_t khronos_uint32_t;
  163. typedef int64_t khronos_int64_t;
  164. typedef uint64_t khronos_uint64_t;
  165. #define KHRONOS_SUPPORT_INT64 1
  166. #define KHRONOS_SUPPORT_FLOAT 1
  167. #elif defined(__VMS ) || defined(__sgi)
  168. /*
  169. * Using <inttypes.h>
  170. */
  171. #include <inttypes.h>
  172. typedef int32_t khronos_int32_t;
  173. typedef uint32_t khronos_uint32_t;
  174. typedef int64_t khronos_int64_t;
  175. typedef uint64_t khronos_uint64_t;
  176. #define KHRONOS_SUPPORT_INT64 1
  177. #define KHRONOS_SUPPORT_FLOAT 1
  178. #elif defined(_WIN32) && !defined(__SCITECH_SNAP__)
  179. /*
  180. * Win32
  181. */
  182. typedef __int32 khronos_int32_t;
  183. typedef unsigned __int32 khronos_uint32_t;
  184. typedef __int64 khronos_int64_t;
  185. typedef unsigned __int64 khronos_uint64_t;
  186. #define KHRONOS_SUPPORT_INT64 1
  187. #define KHRONOS_SUPPORT_FLOAT 1
  188. #elif defined(__sun__) || defined(__digital__)
  189. /*
  190. * Sun or Digital
  191. */
  192. typedef int khronos_int32_t;
  193. typedef unsigned int khronos_uint32_t;
  194. #if defined(__arch64__) || defined(_LP64)
  195. typedef long int khronos_int64_t;
  196. typedef unsigned long int khronos_uint64_t;
  197. #else
  198. typedef long long int khronos_int64_t;
  199. typedef unsigned long long int khronos_uint64_t;
  200. #endif /* __arch64__ */
  201. #define KHRONOS_SUPPORT_INT64 1
  202. #define KHRONOS_SUPPORT_FLOAT 1
  203. #elif 0
  204. /*
  205. * Hypothetical platform with no float or int64 support
  206. */
  207. typedef int khronos_int32_t;
  208. typedef unsigned int khronos_uint32_t;
  209. #define KHRONOS_SUPPORT_INT64 0
  210. #define KHRONOS_SUPPORT_FLOAT 0
  211. #else
  212. /*
  213. * Generic fallback
  214. */
  215. #include <stdint.h>
  216. typedef int32_t khronos_int32_t;
  217. typedef uint32_t khronos_uint32_t;
  218. typedef int64_t khronos_int64_t;
  219. typedef uint64_t khronos_uint64_t;
  220. #define KHRONOS_SUPPORT_INT64 1
  221. #define KHRONOS_SUPPORT_FLOAT 1
  222. #endif
  223. /*
  224. * Types that are (so far) the same on all platforms
  225. */
  226. typedef signed char khronos_int8_t;
  227. typedef unsigned char khronos_uint8_t;
  228. typedef signed short int khronos_int16_t;
  229. typedef unsigned short int khronos_uint16_t;
  230. /*
  231. * Types that differ between LLP64 and LP64 architectures - in LLP64,
  232. * pointers are 64 bits, but 'long' is still 32 bits. Win64 appears
  233. * to be the only LLP64 architecture in current use.
  234. */
  235. #ifdef _WIN64
  236. typedef signed long long int khronos_intptr_t;
  237. typedef unsigned long long int khronos_uintptr_t;
  238. typedef signed long long int khronos_ssize_t;
  239. typedef unsigned long long int khronos_usize_t;
  240. #else
  241. typedef signed long int khronos_intptr_t;
  242. typedef unsigned long int khronos_uintptr_t;
  243. typedef signed long int khronos_ssize_t;
  244. typedef unsigned long int khronos_usize_t;
  245. #endif
  246. #if KHRONOS_SUPPORT_FLOAT
  247. /*
  248. * Float type
  249. */
  250. typedef float khronos_float_t;
  251. #endif
  252. #if KHRONOS_SUPPORT_INT64
  253. /* Time types
  254. *
  255. * These types can be used to represent a time interval in nanoseconds or
  256. * an absolute Unadjusted System Time. Unadjusted System Time is the number
  257. * of nanoseconds since some arbitrary system event (e.g. since the last
  258. * time the system booted). The Unadjusted System Time is an unsigned
  259. * 64 bit value that wraps back to 0 every 584 years. Time intervals
  260. * may be either signed or unsigned.
  261. */
  262. typedef khronos_uint64_t khronos_utime_nanoseconds_t;
  263. typedef khronos_int64_t khronos_stime_nanoseconds_t;
  264. #endif
  265. /*
  266. * Dummy value used to pad enum types to 32 bits.
  267. */
  268. #ifndef KHRONOS_MAX_ENUM
  269. #define KHRONOS_MAX_ENUM 0x7FFFFFFF
  270. #endif
  271. /*
  272. * Enumerated boolean type
  273. *
  274. * Values other than zero should be considered to be true. Therefore
  275. * comparisons should not be made against KHRONOS_TRUE.
  276. */
  277. typedef enum {
  278. KHRONOS_FALSE = 0,
  279. KHRONOS_TRUE = 1,
  280. KHRONOS_BOOLEAN_ENUM_FORCE_SIZE = KHRONOS_MAX_ENUM
  281. } khronos_boolean_enum_t;
  282. #endif /* __khrplatform_h_ */
  283. #ifndef __eglplatform_h_
  284. #define __eglplatform_h_
  285. /*
  286. ** Copyright (c) 2007-2009 The Khronos Group Inc.
  287. **
  288. ** Permission is hereby granted, free of charge, to any person obtaining a
  289. ** copy of this software and/or associated documentation files (the
  290. ** "Materials"), to deal in the Materials without restriction, including
  291. ** without limitation the rights to use, copy, modify, merge, publish,
  292. ** distribute, sublicense, and/or sell copies of the Materials, and to
  293. ** permit persons to whom the Materials are furnished to do so, subject to
  294. ** the following conditions:
  295. **
  296. ** The above copyright notice and this permission notice shall be included
  297. ** in all copies or substantial portions of the Materials.
  298. **
  299. ** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  300. ** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  301. ** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
  302. ** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
  303. ** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
  304. ** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
  305. ** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
  306. */
  307. /* Platform-specific types and definitions for egl.h
  308. * $Revision: 12306 $ on $Date: 2010-08-25 09:51:28 -0700 (Wed, 25 Aug 2010) $
  309. *
  310. * Adopters may modify khrplatform.h and this file to suit their platform.
  311. * You are encouraged to submit all modifications to the Khronos group so that
  312. * they can be included in future versions of this file. Please submit changes
  313. * by sending them to the public Khronos Bugzilla (http://khronos.org/bugzilla)
  314. * by filing a bug against product "EGL" component "Registry".
  315. */
  316. /*#include <KHR/khrplatform.h>*/
  317. /* Macros used in EGL function prototype declarations.
  318. *
  319. * EGL functions should be prototyped as:
  320. *
  321. * EGLAPI return-type EGLAPIENTRY eglFunction(arguments);
  322. * typedef return-type (EXPAPIENTRYP PFNEGLFUNCTIONPROC) (arguments);
  323. *
  324. * KHRONOS_APICALL and KHRONOS_APIENTRY are defined in KHR/khrplatform.h
  325. */
  326. #ifndef EGLAPI
  327. #define EGLAPI KHRONOS_APICALL
  328. #endif
  329. #ifndef EGLAPIENTRY
  330. #define EGLAPIENTRY KHRONOS_APIENTRY
  331. #endif
  332. #define EGLAPIENTRYP EGLAPIENTRY*
  333. /* The types NativeDisplayType, NativeWindowType, and NativePixmapType
  334. * are aliases of window-system-dependent types, such as X Display * or
  335. * Windows Device Context. They must be defined in platform-specific
  336. * code below. The EGL-prefixed versions of Native*Type are the same
  337. * types, renamed in EGL 1.3 so all types in the API start with "EGL".
  338. *
  339. * Khronos STRONGLY RECOMMENDS that you use the default definitions
  340. * provided below, since these changes affect both binary and source
  341. * portability of applications using EGL running on different EGL
  342. * implementations.
  343. */
  344. #if defined(_WIN32) || defined(__VC32__) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__) /* Win32 and WinCE */
  345. #ifndef WIN32_LEAN_AND_MEAN
  346. #define WIN32_LEAN_AND_MEAN 1
  347. #endif
  348. #ifndef NOMINMAX /* don't define min() and max(). */
  349. #define NOMINMAX
  350. #endif
  351. #include <windows.h>
  352. #if __WINRT__
  353. #include <Unknwn.h>
  354. typedef IUnknown * EGLNativeWindowType;
  355. typedef IUnknown * EGLNativePixmapType;
  356. typedef IUnknown * EGLNativeDisplayType;
  357. #else
  358. typedef HDC EGLNativeDisplayType;
  359. typedef HBITMAP EGLNativePixmapType;
  360. typedef HWND EGLNativeWindowType;
  361. #endif
  362. #elif defined(__WINSCW__) || defined(__SYMBIAN32__) /* Symbian */
  363. typedef int EGLNativeDisplayType;
  364. typedef void *EGLNativeWindowType;
  365. typedef void *EGLNativePixmapType;
  366. #elif defined(WL_EGL_PLATFORM)
  367. typedef struct wl_display *EGLNativeDisplayType;
  368. typedef struct wl_egl_pixmap *EGLNativePixmapType;
  369. typedef struct wl_egl_window *EGLNativeWindowType;
  370. #elif defined(__GBM__)
  371. typedef struct gbm_device *EGLNativeDisplayType;
  372. typedef struct gbm_bo *EGLNativePixmapType;
  373. typedef void *EGLNativeWindowType;
  374. #elif defined(__ANDROID__) /* Android */
  375. struct ANativeWindow;
  376. struct egl_native_pixmap_t;
  377. typedef struct ANativeWindow *EGLNativeWindowType;
  378. typedef struct egl_native_pixmap_t *EGLNativePixmapType;
  379. typedef void *EGLNativeDisplayType;
  380. #elif defined(MIR_EGL_PLATFORM)
  381. #include <mir_toolkit/mir_client_library.h>
  382. typedef MirEGLNativeDisplayType EGLNativeDisplayType;
  383. typedef void *EGLNativePixmapType;
  384. typedef MirEGLNativeWindowType EGLNativeWindowType;
  385. #elif defined(__unix__)
  386. #ifdef MESA_EGL_NO_X11_HEADERS
  387. typedef void *EGLNativeDisplayType;
  388. typedef khronos_uintptr_t EGLNativePixmapType;
  389. typedef khronos_uintptr_t EGLNativeWindowType;
  390. #else
  391. /* X11 (tentative) */
  392. #include <X11/Xlib.h>
  393. #include <X11/Xutil.h>
  394. typedef Display *EGLNativeDisplayType;
  395. typedef Pixmap EGLNativePixmapType;
  396. typedef Window EGLNativeWindowType;
  397. #endif /* MESA_EGL_NO_X11_HEADERS */
  398. #else
  399. #error "Platform not recognized"
  400. #endif
  401. /* EGL 1.2 types, renamed for consistency in EGL 1.3 */
  402. typedef EGLNativeDisplayType NativeDisplayType;
  403. typedef EGLNativePixmapType NativePixmapType;
  404. typedef EGLNativeWindowType NativeWindowType;
  405. /* Define EGLint. This must be a signed integral type large enough to contain
  406. * all legal attribute names and values passed into and out of EGL, whether
  407. * their type is boolean, bitmask, enumerant (symbolic constant), integer,
  408. * handle, or other. While in general a 32-bit integer will suffice, if
  409. * handles are 64 bit types, then EGLint should be defined as a signed 64-bit
  410. * integer type.
  411. */
  412. typedef khronos_int32_t EGLint;
  413. #endif /* __eglplatform_h */
  414. #ifndef __egl_h_
  415. #define __egl_h_ 1
  416. #ifdef __cplusplus
  417. extern "C" {
  418. #endif
  419. /*
  420. ** Copyright (c) 2013-2015 The Khronos Group Inc.
  421. **
  422. ** Permission is hereby granted, free of charge, to any person obtaining a
  423. ** copy of this software and/or associated documentation files (the
  424. ** "Materials"), to deal in the Materials without restriction, including
  425. ** without limitation the rights to use, copy, modify, merge, publish,
  426. ** distribute, sublicense, and/or sell copies of the Materials, and to
  427. ** permit persons to whom the Materials are furnished to do so, subject to
  428. ** the following conditions:
  429. **
  430. ** The above copyright notice and this permission notice shall be included
  431. ** in all copies or substantial portions of the Materials.
  432. **
  433. ** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  434. ** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  435. ** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
  436. ** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
  437. ** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
  438. ** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
  439. ** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
  440. */
  441. /*
  442. ** This header is generated from the Khronos OpenGL / OpenGL ES XML
  443. ** API Registry. The current version of the Registry, generator scripts
  444. ** used to make the header, and the header can be found at
  445. ** http://www.opengl.org/registry/
  446. **
  447. ** Khronos $Revision: 31566 $ on $Date: 2015-06-23 08:48:48 -0700 (Tue, 23 Jun 2015) $
  448. */
  449. /*#include <EGL/eglplatform.h>*/
  450. /* Generated on date 20150623 */
  451. /* Generated C header for:
  452. * API: egl
  453. * Versions considered: .*
  454. * Versions emitted: .*
  455. * Default extensions included: None
  456. * Additional extensions included: _nomatch_^
  457. * Extensions removed: _nomatch_^
  458. */
  459. #ifndef EGL_VERSION_1_0
  460. #define EGL_VERSION_1_0 1
  461. typedef unsigned int EGLBoolean;
  462. typedef void *EGLDisplay;
  463. typedef void *EGLConfig;
  464. typedef void *EGLSurface;
  465. typedef void *EGLContext;
  466. typedef void (*__eglMustCastToProperFunctionPointerType)(void);
  467. #define EGL_ALPHA_SIZE 0x3021
  468. #define EGL_BAD_ACCESS 0x3002
  469. #define EGL_BAD_ALLOC 0x3003
  470. #define EGL_BAD_ATTRIBUTE 0x3004
  471. #define EGL_BAD_CONFIG 0x3005
  472. #define EGL_BAD_CONTEXT 0x3006
  473. #define EGL_BAD_CURRENT_SURFACE 0x3007
  474. #define EGL_BAD_DISPLAY 0x3008
  475. #define EGL_BAD_MATCH 0x3009
  476. #define EGL_BAD_NATIVE_PIXMAP 0x300A
  477. #define EGL_BAD_NATIVE_WINDOW 0x300B
  478. #define EGL_BAD_PARAMETER 0x300C
  479. #define EGL_BAD_SURFACE 0x300D
  480. #define EGL_BLUE_SIZE 0x3022
  481. #define EGL_BUFFER_SIZE 0x3020
  482. #define EGL_CONFIG_CAVEAT 0x3027
  483. #define EGL_CONFIG_ID 0x3028
  484. #define EGL_CORE_NATIVE_ENGINE 0x305B
  485. #define EGL_DEPTH_SIZE 0x3025
  486. #define EGL_DONT_CARE ((EGLint)-1)
  487. #define EGL_DRAW 0x3059
  488. #define EGL_EXTENSIONS 0x3055
  489. #define EGL_FALSE 0
  490. #define EGL_GREEN_SIZE 0x3023
  491. #define EGL_HEIGHT 0x3056
  492. #define EGL_LARGEST_PBUFFER 0x3058
  493. #define EGL_LEVEL 0x3029
  494. #define EGL_MAX_PBUFFER_HEIGHT 0x302A
  495. #define EGL_MAX_PBUFFER_PIXELS 0x302B
  496. #define EGL_MAX_PBUFFER_WIDTH 0x302C
  497. #define EGL_NATIVE_RENDERABLE 0x302D
  498. #define EGL_NATIVE_VISUAL_ID 0x302E
  499. #define EGL_NATIVE_VISUAL_TYPE 0x302F
  500. #define EGL_NONE 0x3038
  501. #define EGL_NON_CONFORMANT_CONFIG 0x3051
  502. #define EGL_NOT_INITIALIZED 0x3001
  503. #define EGL_NO_CONTEXT ((EGLContext)0)
  504. #define EGL_NO_DISPLAY ((EGLDisplay)0)
  505. #define EGL_NO_SURFACE ((EGLSurface)0)
  506. #define EGL_PBUFFER_BIT 0x0001
  507. #define EGL_PIXMAP_BIT 0x0002
  508. #define EGL_READ 0x305A
  509. #define EGL_RED_SIZE 0x3024
  510. #define EGL_SAMPLES 0x3031
  511. #define EGL_SAMPLE_BUFFERS 0x3032
  512. #define EGL_SLOW_CONFIG 0x3050
  513. #define EGL_STENCIL_SIZE 0x3026
  514. #define EGL_SUCCESS 0x3000
  515. #define EGL_SURFACE_TYPE 0x3033
  516. #define EGL_TRANSPARENT_BLUE_VALUE 0x3035
  517. #define EGL_TRANSPARENT_GREEN_VALUE 0x3036
  518. #define EGL_TRANSPARENT_RED_VALUE 0x3037
  519. #define EGL_TRANSPARENT_RGB 0x3052
  520. #define EGL_TRANSPARENT_TYPE 0x3034
  521. #define EGL_TRUE 1
  522. #define EGL_VENDOR 0x3053
  523. #define EGL_VERSION 0x3054
  524. #define EGL_WIDTH 0x3057
  525. #define EGL_WINDOW_BIT 0x0004
  526. EGLAPI EGLBoolean EGLAPIENTRY eglChooseConfig (EGLDisplay dpy, const EGLint *attrib_list, EGLConfig *configs, EGLint config_size, EGLint *num_config);
  527. EGLAPI EGLBoolean EGLAPIENTRY eglCopyBuffers (EGLDisplay dpy, EGLSurface surface, EGLNativePixmapType target);
  528. EGLAPI EGLContext EGLAPIENTRY eglCreateContext (EGLDisplay dpy, EGLConfig config, EGLContext share_context, const EGLint *attrib_list);
  529. EGLAPI EGLSurface EGLAPIENTRY eglCreatePbufferSurface (EGLDisplay dpy, EGLConfig config, const EGLint *attrib_list);
  530. EGLAPI EGLSurface EGLAPIENTRY eglCreatePixmapSurface (EGLDisplay dpy, EGLConfig config, EGLNativePixmapType pixmap, const EGLint *attrib_list);
  531. EGLAPI EGLSurface EGLAPIENTRY eglCreateWindowSurface (EGLDisplay dpy, EGLConfig config, EGLNativeWindowType win, const EGLint *attrib_list);
  532. EGLAPI EGLBoolean EGLAPIENTRY eglDestroyContext (EGLDisplay dpy, EGLContext ctx);
  533. EGLAPI EGLBoolean EGLAPIENTRY eglDestroySurface (EGLDisplay dpy, EGLSurface surface);
  534. EGLAPI EGLBoolean EGLAPIENTRY eglGetConfigAttrib (EGLDisplay dpy, EGLConfig config, EGLint attribute, EGLint *value);
  535. EGLAPI EGLBoolean EGLAPIENTRY eglGetConfigs (EGLDisplay dpy, EGLConfig *configs, EGLint config_size, EGLint *num_config);
  536. EGLAPI EGLDisplay EGLAPIENTRY eglGetCurrentDisplay (void);
  537. EGLAPI EGLSurface EGLAPIENTRY eglGetCurrentSurface (EGLint readdraw);
  538. EGLAPI EGLDisplay EGLAPIENTRY eglGetDisplay (EGLNativeDisplayType display_id);
  539. EGLAPI EGLint EGLAPIENTRY eglGetError (void);
  540. EGLAPI __eglMustCastToProperFunctionPointerType EGLAPIENTRY eglGetProcAddress (const char *procname);
  541. EGLAPI EGLBoolean EGLAPIENTRY eglInitialize (EGLDisplay dpy, EGLint *major, EGLint *minor);
  542. EGLAPI EGLBoolean EGLAPIENTRY eglMakeCurrent (EGLDisplay dpy, EGLSurface draw, EGLSurface read, EGLContext ctx);
  543. EGLAPI EGLBoolean EGLAPIENTRY eglQueryContext (EGLDisplay dpy, EGLContext ctx, EGLint attribute, EGLint *value);
  544. EGLAPI const char *EGLAPIENTRY eglQueryString (EGLDisplay dpy, EGLint name);
  545. EGLAPI EGLBoolean EGLAPIENTRY eglQuerySurface (EGLDisplay dpy, EGLSurface surface, EGLint attribute, EGLint *value);
  546. EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers (EGLDisplay dpy, EGLSurface surface);
  547. EGLAPI EGLBoolean EGLAPIENTRY eglTerminate (EGLDisplay dpy);
  548. EGLAPI EGLBoolean EGLAPIENTRY eglWaitGL (void);
  549. EGLAPI EGLBoolean EGLAPIENTRY eglWaitNative (EGLint engine);
  550. #endif /* EGL_VERSION_1_0 */
  551. #ifndef EGL_VERSION_1_1
  552. #define EGL_VERSION_1_1 1
  553. #define EGL_BACK_BUFFER 0x3084
  554. #define EGL_BIND_TO_TEXTURE_RGB 0x3039
  555. #define EGL_BIND_TO_TEXTURE_RGBA 0x303A
  556. #define EGL_CONTEXT_LOST 0x300E
  557. #define EGL_MIN_SWAP_INTERVAL 0x303B
  558. #define EGL_MAX_SWAP_INTERVAL 0x303C
  559. #define EGL_MIPMAP_TEXTURE 0x3082
  560. #define EGL_MIPMAP_LEVEL 0x3083
  561. #define EGL_NO_TEXTURE 0x305C
  562. #define EGL_TEXTURE_2D 0x305F
  563. #define EGL_TEXTURE_FORMAT 0x3080
  564. #define EGL_TEXTURE_RGB 0x305D
  565. #define EGL_TEXTURE_RGBA 0x305E
  566. #define EGL_TEXTURE_TARGET 0x3081
  567. EGLAPI EGLBoolean EGLAPIENTRY eglBindTexImage (EGLDisplay dpy, EGLSurface surface, EGLint buffer);
  568. EGLAPI EGLBoolean EGLAPIENTRY eglReleaseTexImage (EGLDisplay dpy, EGLSurface surface, EGLint buffer);
  569. EGLAPI EGLBoolean EGLAPIENTRY eglSurfaceAttrib (EGLDisplay dpy, EGLSurface surface, EGLint attribute, EGLint value);
  570. EGLAPI EGLBoolean EGLAPIENTRY eglSwapInterval (EGLDisplay dpy, EGLint interval);
  571. #endif /* EGL_VERSION_1_1 */
  572. #ifndef EGL_VERSION_1_2
  573. #define EGL_VERSION_1_2 1
  574. typedef unsigned int EGLenum;
  575. typedef void *EGLClientBuffer;
  576. #define EGL_ALPHA_FORMAT 0x3088
  577. #define EGL_ALPHA_FORMAT_NONPRE 0x308B
  578. #define EGL_ALPHA_FORMAT_PRE 0x308C
  579. #define EGL_ALPHA_MASK_SIZE 0x303E
  580. #define EGL_BUFFER_PRESERVED 0x3094
  581. #define EGL_BUFFER_DESTROYED 0x3095
  582. #define EGL_CLIENT_APIS 0x308D
  583. #define EGL_COLORSPACE 0x3087
  584. #define EGL_COLORSPACE_sRGB 0x3089
  585. #define EGL_COLORSPACE_LINEAR 0x308A
  586. #define EGL_COLOR_BUFFER_TYPE 0x303F
  587. #define EGL_CONTEXT_CLIENT_TYPE 0x3097
  588. #define EGL_DISPLAY_SCALING 10000
  589. #define EGL_HORIZONTAL_RESOLUTION 0x3090
  590. #define EGL_LUMINANCE_BUFFER 0x308F
  591. #define EGL_LUMINANCE_SIZE 0x303D
  592. #define EGL_OPENGL_ES_BIT 0x0001
  593. #define EGL_OPENVG_BIT 0x0002
  594. #define EGL_OPENGL_ES_API 0x30A0
  595. #define EGL_OPENVG_API 0x30A1
  596. #define EGL_OPENVG_IMAGE 0x3096
  597. #define EGL_PIXEL_ASPECT_RATIO 0x3092
  598. #define EGL_RENDERABLE_TYPE 0x3040
  599. #define EGL_RENDER_BUFFER 0x3086
  600. #define EGL_RGB_BUFFER 0x308E
  601. #define EGL_SINGLE_BUFFER 0x3085
  602. #define EGL_SWAP_BEHAVIOR 0x3093
  603. #define EGL_UNKNOWN ((EGLint)-1)
  604. #define EGL_VERTICAL_RESOLUTION 0x3091
  605. EGLAPI EGLBoolean EGLAPIENTRY eglBindAPI (EGLenum api);
  606. EGLAPI EGLenum EGLAPIENTRY eglQueryAPI (void);
  607. EGLAPI EGLSurface EGLAPIENTRY eglCreatePbufferFromClientBuffer (EGLDisplay dpy, EGLenum buftype, EGLClientBuffer buffer, EGLConfig config, const EGLint *attrib_list);
  608. EGLAPI EGLBoolean EGLAPIENTRY eglReleaseThread (void);
  609. EGLAPI EGLBoolean EGLAPIENTRY eglWaitClient (void);
  610. #endif /* EGL_VERSION_1_2 */
  611. #ifndef EGL_VERSION_1_3
  612. #define EGL_VERSION_1_3 1
  613. #define EGL_CONFORMANT 0x3042
  614. #define EGL_CONTEXT_CLIENT_VERSION 0x3098
  615. #define EGL_MATCH_NATIVE_PIXMAP 0x3041
  616. #define EGL_OPENGL_ES2_BIT 0x0004
  617. #define EGL_VG_ALPHA_FORMAT 0x3088
  618. #define EGL_VG_ALPHA_FORMAT_NONPRE 0x308B
  619. #define EGL_VG_ALPHA_FORMAT_PRE 0x308C
  620. #define EGL_VG_ALPHA_FORMAT_PRE_BIT 0x0040
  621. #define EGL_VG_COLORSPACE 0x3087
  622. #define EGL_VG_COLORSPACE_sRGB 0x3089
  623. #define EGL_VG_COLORSPACE_LINEAR 0x308A
  624. #define EGL_VG_COLORSPACE_LINEAR_BIT 0x0020
  625. #endif /* EGL_VERSION_1_3 */
  626. #ifndef EGL_VERSION_1_4
  627. #define EGL_VERSION_1_4 1
  628. #define EGL_DEFAULT_DISPLAY ((EGLNativeDisplayType)0)
  629. #define EGL_MULTISAMPLE_RESOLVE_BOX_BIT 0x0200
  630. #define EGL_MULTISAMPLE_RESOLVE 0x3099
  631. #define EGL_MULTISAMPLE_RESOLVE_DEFAULT 0x309A
  632. #define EGL_MULTISAMPLE_RESOLVE_BOX 0x309B
  633. #define EGL_OPENGL_API 0x30A2
  634. #define EGL_OPENGL_BIT 0x0008
  635. #define EGL_SWAP_BEHAVIOR_PRESERVED_BIT 0x0400
  636. EGLAPI EGLContext EGLAPIENTRY eglGetCurrentContext (void);
  637. #endif /* EGL_VERSION_1_4 */
  638. #ifndef EGL_VERSION_1_5
  639. #define EGL_VERSION_1_5 1
  640. typedef void *EGLSync;
  641. typedef intptr_t EGLAttrib;
  642. typedef khronos_utime_nanoseconds_t EGLTime;
  643. typedef void *EGLImage;
  644. #define EGL_CONTEXT_MAJOR_VERSION 0x3098
  645. #define EGL_CONTEXT_MINOR_VERSION 0x30FB
  646. #define EGL_CONTEXT_OPENGL_PROFILE_MASK 0x30FD
  647. #define EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY 0x31BD
  648. #define EGL_NO_RESET_NOTIFICATION 0x31BE
  649. #define EGL_LOSE_CONTEXT_ON_RESET 0x31BF
  650. #define EGL_CONTEXT_OPENGL_CORE_PROFILE_BIT 0x00000001
  651. #define EGL_CONTEXT_OPENGL_COMPATIBILITY_PROFILE_BIT 0x00000002
  652. #define EGL_CONTEXT_OPENGL_DEBUG 0x31B0
  653. #define EGL_CONTEXT_OPENGL_FORWARD_COMPATIBLE 0x31B1
  654. #define EGL_CONTEXT_OPENGL_ROBUST_ACCESS 0x31B2
  655. #define EGL_OPENGL_ES3_BIT 0x00000040
  656. #define EGL_CL_EVENT_HANDLE 0x309C
  657. #define EGL_SYNC_CL_EVENT 0x30FE
  658. #define EGL_SYNC_CL_EVENT_COMPLETE 0x30FF
  659. #define EGL_SYNC_PRIOR_COMMANDS_COMPLETE 0x30F0
  660. #define EGL_SYNC_TYPE 0x30F7
  661. #define EGL_SYNC_STATUS 0x30F1
  662. #define EGL_SYNC_CONDITION 0x30F8
  663. #define EGL_SIGNALED 0x30F2
  664. #define EGL_UNSIGNALED 0x30F3
  665. #define EGL_SYNC_FLUSH_COMMANDS_BIT 0x0001
  666. #define EGL_FOREVER 0xFFFFFFFFFFFFFFFFull
  667. #define EGL_TIMEOUT_EXPIRED 0x30F5
  668. #define EGL_CONDITION_SATISFIED 0x30F6
  669. #define EGL_NO_SYNC ((EGLSync)0)
  670. #define EGL_SYNC_FENCE 0x30F9
  671. #define EGL_GL_COLORSPACE 0x309D
  672. #define EGL_GL_COLORSPACE_SRGB 0x3089
  673. #define EGL_GL_COLORSPACE_LINEAR 0x308A
  674. #define EGL_GL_RENDERBUFFER 0x30B9
  675. #define EGL_GL_TEXTURE_2D 0x30B1
  676. #define EGL_GL_TEXTURE_LEVEL 0x30BC
  677. #define EGL_GL_TEXTURE_3D 0x30B2
  678. #define EGL_GL_TEXTURE_ZOFFSET 0x30BD
  679. #define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_X 0x30B3
  680. #define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_X 0x30B4
  681. #define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Y 0x30B5
  682. #define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Y 0x30B6
  683. #define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Z 0x30B7
  684. #define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Z 0x30B8
  685. #define EGL_IMAGE_PRESERVED 0x30D2
  686. #define EGL_NO_IMAGE ((EGLImage)0)
  687. EGLAPI EGLSync EGLAPIENTRY eglCreateSync (EGLDisplay dpy, EGLenum type, const EGLAttrib *attrib_list);
  688. EGLAPI EGLBoolean EGLAPIENTRY eglDestroySync (EGLDisplay dpy, EGLSync sync);
  689. EGLAPI EGLint EGLAPIENTRY eglClientWaitSync (EGLDisplay dpy, EGLSync sync, EGLint flags, EGLTime timeout);
  690. EGLAPI EGLBoolean EGLAPIENTRY eglGetSyncAttrib (EGLDisplay dpy, EGLSync sync, EGLint attribute, EGLAttrib *value);
  691. EGLAPI EGLImage EGLAPIENTRY eglCreateImage (EGLDisplay dpy, EGLContext ctx, EGLenum target, EGLClientBuffer buffer, const EGLAttrib *attrib_list);
  692. EGLAPI EGLBoolean EGLAPIENTRY eglDestroyImage (EGLDisplay dpy, EGLImage image);
  693. EGLAPI EGLDisplay EGLAPIENTRY eglGetPlatformDisplay (EGLenum platform, void *native_display, const EGLAttrib *attrib_list);
  694. EGLAPI EGLSurface EGLAPIENTRY eglCreatePlatformWindowSurface (EGLDisplay dpy, EGLConfig config, void *native_window, const EGLAttrib *attrib_list);
  695. EGLAPI EGLSurface EGLAPIENTRY eglCreatePlatformPixmapSurface (EGLDisplay dpy, EGLConfig config, void *native_pixmap, const EGLAttrib *attrib_list);
  696. EGLAPI EGLBoolean EGLAPIENTRY eglWaitSync (EGLDisplay dpy, EGLSync sync, EGLint flags);
  697. #endif /* EGL_VERSION_1_5 */
  698. #ifdef __cplusplus
  699. }
  700. #endif
  701. #endif /* __egl_h_ */
  702. #ifndef __eglext_h_
  703. #define __eglext_h_ 1
  704. #ifdef __cplusplus
  705. extern "C" {
  706. #endif
  707. /*
  708. ** Copyright (c) 2013-2015 The Khronos Group Inc.
  709. **
  710. ** Permission is hereby granted, free of charge, to any person obtaining a
  711. ** copy of this software and/or associated documentation files (the
  712. ** "Materials"), to deal in the Materials without restriction, including
  713. ** without limitation the rights to use, copy, modify, merge, publish,
  714. ** distribute, sublicense, and/or sell copies of the Materials, and to
  715. ** permit persons to whom the Materials are furnished to do so, subject to
  716. ** the following conditions:
  717. **
  718. ** The above copyright notice and this permission notice shall be included
  719. ** in all copies or substantial portions of the Materials.
  720. **
  721. ** THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
  722. ** EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  723. ** MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
  724. ** IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
  725. ** CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
  726. ** TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
  727. ** MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
  728. */
  729. /*
  730. ** This header is generated from the Khronos OpenGL / OpenGL ES XML
  731. ** API Registry. The current version of the Registry, generator scripts
  732. ** used to make the header, and the header can be found at
  733. ** http://www.opengl.org/registry/
  734. **
  735. ** Khronos $Revision: 31566 $ on $Date: 2015-06-23 08:48:48 -0700 (Tue, 23 Jun 2015) $
  736. */
  737. /*#include <EGL/eglplatform.h>*/
  738. #define EGL_EGLEXT_VERSION 20150623
  739. /* Generated C header for:
  740. * API: egl
  741. * Versions considered: .*
  742. * Versions emitted: _nomatch_^
  743. * Default extensions included: egl
  744. * Additional extensions included: _nomatch_^
  745. * Extensions removed: _nomatch_^
  746. */
  747. #ifndef EGL_KHR_cl_event
  748. #define EGL_KHR_cl_event 1
  749. #define EGL_CL_EVENT_HANDLE_KHR 0x309C
  750. #define EGL_SYNC_CL_EVENT_KHR 0x30FE
  751. #define EGL_SYNC_CL_EVENT_COMPLETE_KHR 0x30FF
  752. #endif /* EGL_KHR_cl_event */
  753. #ifndef EGL_KHR_cl_event2
  754. #define EGL_KHR_cl_event2 1
  755. typedef void *EGLSyncKHR;
  756. typedef intptr_t EGLAttribKHR;
  757. typedef EGLSyncKHR (EGLAPIENTRYP PFNEGLCREATESYNC64KHRPROC) (EGLDisplay dpy, EGLenum type, const EGLAttribKHR *attrib_list);
  758. #ifdef EGL_EGLEXT_PROTOTYPES
  759. EGLAPI EGLSyncKHR EGLAPIENTRY eglCreateSync64KHR (EGLDisplay dpy, EGLenum type, const EGLAttribKHR *attrib_list);
  760. #endif
  761. #endif /* EGL_KHR_cl_event2 */
  762. #ifndef EGL_KHR_client_get_all_proc_addresses
  763. #define EGL_KHR_client_get_all_proc_addresses 1
  764. #endif /* EGL_KHR_client_get_all_proc_addresses */
  765. #ifndef EGL_KHR_config_attribs
  766. #define EGL_KHR_config_attribs 1
  767. #define EGL_CONFORMANT_KHR 0x3042
  768. #define EGL_VG_COLORSPACE_LINEAR_BIT_KHR 0x0020
  769. #define EGL_VG_ALPHA_FORMAT_PRE_BIT_KHR 0x0040
  770. #endif /* EGL_KHR_config_attribs */
  771. #ifndef EGL_KHR_create_context
  772. #define EGL_KHR_create_context 1
  773. #define EGL_CONTEXT_MAJOR_VERSION_KHR 0x3098
  774. #define EGL_CONTEXT_MINOR_VERSION_KHR 0x30FB
  775. #define EGL_CONTEXT_FLAGS_KHR 0x30FC
  776. #define EGL_CONTEXT_OPENGL_PROFILE_MASK_KHR 0x30FD
  777. #define EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY_KHR 0x31BD
  778. #define EGL_NO_RESET_NOTIFICATION_KHR 0x31BE
  779. #define EGL_LOSE_CONTEXT_ON_RESET_KHR 0x31BF
  780. #define EGL_CONTEXT_OPENGL_DEBUG_BIT_KHR 0x00000001
  781. #define EGL_CONTEXT_OPENGL_FORWARD_COMPATIBLE_BIT_KHR 0x00000002
  782. #define EGL_CONTEXT_OPENGL_ROBUST_ACCESS_BIT_KHR 0x00000004
  783. #define EGL_CONTEXT_OPENGL_CORE_PROFILE_BIT_KHR 0x00000001
  784. #define EGL_CONTEXT_OPENGL_COMPATIBILITY_PROFILE_BIT_KHR 0x00000002
  785. #define EGL_OPENGL_ES3_BIT_KHR 0x00000040
  786. #endif /* EGL_KHR_create_context */
  787. #ifndef EGL_KHR_create_context_no_error
  788. #define EGL_KHR_create_context_no_error 1
  789. #define EGL_CONTEXT_OPENGL_NO_ERROR_KHR 0x31B3
  790. #endif /* EGL_KHR_create_context_no_error */
  791. #ifndef EGL_KHR_fence_sync
  792. #define EGL_KHR_fence_sync 1
  793. typedef khronos_utime_nanoseconds_t EGLTimeKHR;
  794. #ifdef KHRONOS_SUPPORT_INT64
  795. #define EGL_SYNC_PRIOR_COMMANDS_COMPLETE_KHR 0x30F0
  796. #define EGL_SYNC_CONDITION_KHR 0x30F8
  797. #define EGL_SYNC_FENCE_KHR 0x30F9
  798. typedef EGLSyncKHR (EGLAPIENTRYP PFNEGLCREATESYNCKHRPROC) (EGLDisplay dpy, EGLenum type, const EGLint *attrib_list);
  799. typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYSYNCKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync);
  800. typedef EGLint (EGLAPIENTRYP PFNEGLCLIENTWAITSYNCKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync, EGLint flags, EGLTimeKHR timeout);
  801. typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETSYNCATTRIBKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync, EGLint attribute, EGLint *value);
  802. #ifdef EGL_EGLEXT_PROTOTYPES
  803. EGLAPI EGLSyncKHR EGLAPIENTRY eglCreateSyncKHR (EGLDisplay dpy, EGLenum type, const EGLint *attrib_list);
  804. EGLAPI EGLBoolean EGLAPIENTRY eglDestroySyncKHR (EGLDisplay dpy, EGLSyncKHR sync);
  805. EGLAPI EGLint EGLAPIENTRY eglClientWaitSyncKHR (EGLDisplay dpy, EGLSyncKHR sync, EGLint flags, EGLTimeKHR timeout);
  806. EGLAPI EGLBoolean EGLAPIENTRY eglGetSyncAttribKHR (EGLDisplay dpy, EGLSyncKHR sync, EGLint attribute, EGLint *value);
  807. #endif
  808. #endif /* KHRONOS_SUPPORT_INT64 */
  809. #endif /* EGL_KHR_fence_sync */
  810. #ifndef EGL_KHR_get_all_proc_addresses
  811. #define EGL_KHR_get_all_proc_addresses 1
  812. #endif /* EGL_KHR_get_all_proc_addresses */
  813. #ifndef EGL_KHR_gl_colorspace
  814. #define EGL_KHR_gl_colorspace 1
  815. #define EGL_GL_COLORSPACE_KHR 0x309D
  816. #define EGL_GL_COLORSPACE_SRGB_KHR 0x3089
  817. #define EGL_GL_COLORSPACE_LINEAR_KHR 0x308A
  818. #endif /* EGL_KHR_gl_colorspace */
  819. #ifndef EGL_KHR_gl_renderbuffer_image
  820. #define EGL_KHR_gl_renderbuffer_image 1
  821. #define EGL_GL_RENDERBUFFER_KHR 0x30B9
  822. #endif /* EGL_KHR_gl_renderbuffer_image */
  823. #ifndef EGL_KHR_gl_texture_2D_image
  824. #define EGL_KHR_gl_texture_2D_image 1
  825. #define EGL_GL_TEXTURE_2D_KHR 0x30B1
  826. #define EGL_GL_TEXTURE_LEVEL_KHR 0x30BC
  827. #endif /* EGL_KHR_gl_texture_2D_image */
  828. #ifndef EGL_KHR_gl_texture_3D_image
  829. #define EGL_KHR_gl_texture_3D_image 1
  830. #define EGL_GL_TEXTURE_3D_KHR 0x30B2
  831. #define EGL_GL_TEXTURE_ZOFFSET_KHR 0x30BD
  832. #endif /* EGL_KHR_gl_texture_3D_image */
  833. #ifndef EGL_KHR_gl_texture_cubemap_image
  834. #define EGL_KHR_gl_texture_cubemap_image 1
  835. #define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_X_KHR 0x30B3
  836. #define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_X_KHR 0x30B4
  837. #define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Y_KHR 0x30B5
  838. #define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_KHR 0x30B6
  839. #define EGL_GL_TEXTURE_CUBE_MAP_POSITIVE_Z_KHR 0x30B7
  840. #define EGL_GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_KHR 0x30B8
  841. #endif /* EGL_KHR_gl_texture_cubemap_image */
  842. #ifndef EGL_KHR_image
  843. #define EGL_KHR_image 1
  844. typedef void *EGLImageKHR;
  845. #define EGL_NATIVE_PIXMAP_KHR 0x30B0
  846. #define EGL_NO_IMAGE_KHR ((EGLImageKHR)0)
  847. typedef EGLImageKHR (EGLAPIENTRYP PFNEGLCREATEIMAGEKHRPROC) (EGLDisplay dpy, EGLContext ctx, EGLenum target, EGLClientBuffer buffer, const EGLint *attrib_list);
  848. typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYIMAGEKHRPROC) (EGLDisplay dpy, EGLImageKHR image);
  849. #ifdef EGL_EGLEXT_PROTOTYPES
  850. EGLAPI EGLImageKHR EGLAPIENTRY eglCreateImageKHR (EGLDisplay dpy, EGLContext ctx, EGLenum target, EGLClientBuffer buffer, const EGLint *attrib_list);
  851. EGLAPI EGLBoolean EGLAPIENTRY eglDestroyImageKHR (EGLDisplay dpy, EGLImageKHR image);
  852. #endif
  853. #endif /* EGL_KHR_image */
  854. #ifndef EGL_KHR_image_base
  855. #define EGL_KHR_image_base 1
  856. #define EGL_IMAGE_PRESERVED_KHR 0x30D2
  857. #endif /* EGL_KHR_image_base */
  858. #ifndef EGL_KHR_image_pixmap
  859. #define EGL_KHR_image_pixmap 1
  860. #endif /* EGL_KHR_image_pixmap */
  861. #ifndef EGL_KHR_lock_surface
  862. #define EGL_KHR_lock_surface 1
  863. #define EGL_READ_SURFACE_BIT_KHR 0x0001
  864. #define EGL_WRITE_SURFACE_BIT_KHR 0x0002
  865. #define EGL_LOCK_SURFACE_BIT_KHR 0x0080
  866. #define EGL_OPTIMAL_FORMAT_BIT_KHR 0x0100
  867. #define EGL_MATCH_FORMAT_KHR 0x3043
  868. #define EGL_FORMAT_RGB_565_EXACT_KHR 0x30C0
  869. #define EGL_FORMAT_RGB_565_KHR 0x30C1
  870. #define EGL_FORMAT_RGBA_8888_EXACT_KHR 0x30C2
  871. #define EGL_FORMAT_RGBA_8888_KHR 0x30C3
  872. #define EGL_MAP_PRESERVE_PIXELS_KHR 0x30C4
  873. #define EGL_LOCK_USAGE_HINT_KHR 0x30C5
  874. #define EGL_BITMAP_POINTER_KHR 0x30C6
  875. #define EGL_BITMAP_PITCH_KHR 0x30C7
  876. #define EGL_BITMAP_ORIGIN_KHR 0x30C8
  877. #define EGL_BITMAP_PIXEL_RED_OFFSET_KHR 0x30C9
  878. #define EGL_BITMAP_PIXEL_GREEN_OFFSET_KHR 0x30CA
  879. #define EGL_BITMAP_PIXEL_BLUE_OFFSET_KHR 0x30CB
  880. #define EGL_BITMAP_PIXEL_ALPHA_OFFSET_KHR 0x30CC
  881. #define EGL_BITMAP_PIXEL_LUMINANCE_OFFSET_KHR 0x30CD
  882. #define EGL_LOWER_LEFT_KHR 0x30CE
  883. #define EGL_UPPER_LEFT_KHR 0x30CF
  884. typedef EGLBoolean (EGLAPIENTRYP PFNEGLLOCKSURFACEKHRPROC) (EGLDisplay dpy, EGLSurface surface, const EGLint *attrib_list);
  885. typedef EGLBoolean (EGLAPIENTRYP PFNEGLUNLOCKSURFACEKHRPROC) (EGLDisplay dpy, EGLSurface surface);
  886. #ifdef EGL_EGLEXT_PROTOTYPES
  887. EGLAPI EGLBoolean EGLAPIENTRY eglLockSurfaceKHR (EGLDisplay dpy, EGLSurface surface, const EGLint *attrib_list);
  888. EGLAPI EGLBoolean EGLAPIENTRY eglUnlockSurfaceKHR (EGLDisplay dpy, EGLSurface surface);
  889. #endif
  890. #endif /* EGL_KHR_lock_surface */
  891. #ifndef EGL_KHR_lock_surface2
  892. #define EGL_KHR_lock_surface2 1
  893. #define EGL_BITMAP_PIXEL_SIZE_KHR 0x3110
  894. #endif /* EGL_KHR_lock_surface2 */
  895. #ifndef EGL_KHR_lock_surface3
  896. #define EGL_KHR_lock_surface3 1
  897. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSURFACE64KHRPROC) (EGLDisplay dpy, EGLSurface surface, EGLint attribute, EGLAttribKHR *value);
  898. #ifdef EGL_EGLEXT_PROTOTYPES
  899. EGLAPI EGLBoolean EGLAPIENTRY eglQuerySurface64KHR (EGLDisplay dpy, EGLSurface surface, EGLint attribute, EGLAttribKHR *value);
  900. #endif
  901. #endif /* EGL_KHR_lock_surface3 */
  902. #ifndef EGL_KHR_partial_update
  903. #define EGL_KHR_partial_update 1
  904. #define EGL_BUFFER_AGE_KHR 0x313D
  905. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSETDAMAGEREGIONKHRPROC) (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects);
  906. #ifdef EGL_EGLEXT_PROTOTYPES
  907. EGLAPI EGLBoolean EGLAPIENTRY eglSetDamageRegionKHR (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects);
  908. #endif
  909. #endif /* EGL_KHR_partial_update */
  910. #ifndef EGL_KHR_platform_android
  911. #define EGL_KHR_platform_android 1
  912. #define EGL_PLATFORM_ANDROID_KHR 0x3141
  913. #endif /* EGL_KHR_platform_android */
  914. #ifndef EGL_KHR_platform_gbm
  915. #define EGL_KHR_platform_gbm 1
  916. #define EGL_PLATFORM_GBM_KHR 0x31D7
  917. #endif /* EGL_KHR_platform_gbm */
  918. #ifndef EGL_KHR_platform_wayland
  919. #define EGL_KHR_platform_wayland 1
  920. #define EGL_PLATFORM_WAYLAND_KHR 0x31D8
  921. #endif /* EGL_KHR_platform_wayland */
  922. #ifndef EGL_KHR_platform_x11
  923. #define EGL_KHR_platform_x11 1
  924. #define EGL_PLATFORM_X11_KHR 0x31D5
  925. #define EGL_PLATFORM_X11_SCREEN_KHR 0x31D6
  926. #endif /* EGL_KHR_platform_x11 */
  927. #ifndef EGL_KHR_reusable_sync
  928. #define EGL_KHR_reusable_sync 1
  929. #ifdef KHRONOS_SUPPORT_INT64
  930. #define EGL_SYNC_STATUS_KHR 0x30F1
  931. #define EGL_SIGNALED_KHR 0x30F2
  932. #define EGL_UNSIGNALED_KHR 0x30F3
  933. #define EGL_TIMEOUT_EXPIRED_KHR 0x30F5
  934. #define EGL_CONDITION_SATISFIED_KHR 0x30F6
  935. #define EGL_SYNC_TYPE_KHR 0x30F7
  936. #define EGL_SYNC_REUSABLE_KHR 0x30FA
  937. #define EGL_SYNC_FLUSH_COMMANDS_BIT_KHR 0x0001
  938. #define EGL_FOREVER_KHR 0xFFFFFFFFFFFFFFFFull
  939. #define EGL_NO_SYNC_KHR ((EGLSyncKHR)0)
  940. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSIGNALSYNCKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync, EGLenum mode);
  941. #ifdef EGL_EGLEXT_PROTOTYPES
  942. EGLAPI EGLBoolean EGLAPIENTRY eglSignalSyncKHR (EGLDisplay dpy, EGLSyncKHR sync, EGLenum mode);
  943. #endif
  944. #endif /* KHRONOS_SUPPORT_INT64 */
  945. #endif /* EGL_KHR_reusable_sync */
  946. #ifndef EGL_KHR_stream
  947. #define EGL_KHR_stream 1
  948. typedef void *EGLStreamKHR;
  949. typedef khronos_uint64_t EGLuint64KHR;
  950. #ifdef KHRONOS_SUPPORT_INT64
  951. #define EGL_NO_STREAM_KHR ((EGLStreamKHR)0)
  952. #define EGL_CONSUMER_LATENCY_USEC_KHR 0x3210
  953. #define EGL_PRODUCER_FRAME_KHR 0x3212
  954. #define EGL_CONSUMER_FRAME_KHR 0x3213
  955. #define EGL_STREAM_STATE_KHR 0x3214
  956. #define EGL_STREAM_STATE_CREATED_KHR 0x3215
  957. #define EGL_STREAM_STATE_CONNECTING_KHR 0x3216
  958. #define EGL_STREAM_STATE_EMPTY_KHR 0x3217
  959. #define EGL_STREAM_STATE_NEW_FRAME_AVAILABLE_KHR 0x3218
  960. #define EGL_STREAM_STATE_OLD_FRAME_AVAILABLE_KHR 0x3219
  961. #define EGL_STREAM_STATE_DISCONNECTED_KHR 0x321A
  962. #define EGL_BAD_STREAM_KHR 0x321B
  963. #define EGL_BAD_STATE_KHR 0x321C
  964. typedef EGLStreamKHR (EGLAPIENTRYP PFNEGLCREATESTREAMKHRPROC) (EGLDisplay dpy, const EGLint *attrib_list);
  965. typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYSTREAMKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream);
  966. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMATTRIBKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint value);
  967. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint *value);
  968. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMU64KHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLuint64KHR *value);
  969. #ifdef EGL_EGLEXT_PROTOTYPES
  970. EGLAPI EGLStreamKHR EGLAPIENTRY eglCreateStreamKHR (EGLDisplay dpy, const EGLint *attrib_list);
  971. EGLAPI EGLBoolean EGLAPIENTRY eglDestroyStreamKHR (EGLDisplay dpy, EGLStreamKHR stream);
  972. EGLAPI EGLBoolean EGLAPIENTRY eglStreamAttribKHR (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint value);
  973. EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamKHR (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLint *value);
  974. EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamu64KHR (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLuint64KHR *value);
  975. #endif
  976. #endif /* KHRONOS_SUPPORT_INT64 */
  977. #endif /* EGL_KHR_stream */
  978. #ifndef EGL_KHR_stream_consumer_gltexture
  979. #define EGL_KHR_stream_consumer_gltexture 1
  980. #ifdef EGL_KHR_stream
  981. #define EGL_CONSUMER_ACQUIRE_TIMEOUT_USEC_KHR 0x321E
  982. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMERGLTEXTUREEXTERNALKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream);
  983. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMERACQUIREKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream);
  984. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMERRELEASEKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream);
  985. #ifdef EGL_EGLEXT_PROTOTYPES
  986. EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerGLTextureExternalKHR (EGLDisplay dpy, EGLStreamKHR stream);
  987. EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerAcquireKHR (EGLDisplay dpy, EGLStreamKHR stream);
  988. EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerReleaseKHR (EGLDisplay dpy, EGLStreamKHR stream);
  989. #endif
  990. #endif /* EGL_KHR_stream */
  991. #endif /* EGL_KHR_stream_consumer_gltexture */
  992. #ifndef EGL_KHR_stream_cross_process_fd
  993. #define EGL_KHR_stream_cross_process_fd 1
  994. typedef int EGLNativeFileDescriptorKHR;
  995. #ifdef EGL_KHR_stream
  996. #define EGL_NO_FILE_DESCRIPTOR_KHR ((EGLNativeFileDescriptorKHR)(-1))
  997. typedef EGLNativeFileDescriptorKHR (EGLAPIENTRYP PFNEGLGETSTREAMFILEDESCRIPTORKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream);
  998. typedef EGLStreamKHR (EGLAPIENTRYP PFNEGLCREATESTREAMFROMFILEDESCRIPTORKHRPROC) (EGLDisplay dpy, EGLNativeFileDescriptorKHR file_descriptor);
  999. #ifdef EGL_EGLEXT_PROTOTYPES
  1000. EGLAPI EGLNativeFileDescriptorKHR EGLAPIENTRY eglGetStreamFileDescriptorKHR (EGLDisplay dpy, EGLStreamKHR stream);
  1001. EGLAPI EGLStreamKHR EGLAPIENTRY eglCreateStreamFromFileDescriptorKHR (EGLDisplay dpy, EGLNativeFileDescriptorKHR file_descriptor);
  1002. #endif
  1003. #endif /* EGL_KHR_stream */
  1004. #endif /* EGL_KHR_stream_cross_process_fd */
  1005. #ifndef EGL_KHR_stream_fifo
  1006. #define EGL_KHR_stream_fifo 1
  1007. #ifdef EGL_KHR_stream
  1008. #define EGL_STREAM_FIFO_LENGTH_KHR 0x31FC
  1009. #define EGL_STREAM_TIME_NOW_KHR 0x31FD
  1010. #define EGL_STREAM_TIME_CONSUMER_KHR 0x31FE
  1011. #define EGL_STREAM_TIME_PRODUCER_KHR 0x31FF
  1012. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSTREAMTIMEKHRPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLTimeKHR *value);
  1013. #ifdef EGL_EGLEXT_PROTOTYPES
  1014. EGLAPI EGLBoolean EGLAPIENTRY eglQueryStreamTimeKHR (EGLDisplay dpy, EGLStreamKHR stream, EGLenum attribute, EGLTimeKHR *value);
  1015. #endif
  1016. #endif /* EGL_KHR_stream */
  1017. #endif /* EGL_KHR_stream_fifo */
  1018. #ifndef EGL_KHR_stream_producer_aldatalocator
  1019. #define EGL_KHR_stream_producer_aldatalocator 1
  1020. #ifdef EGL_KHR_stream
  1021. #endif /* EGL_KHR_stream */
  1022. #endif /* EGL_KHR_stream_producer_aldatalocator */
  1023. #ifndef EGL_KHR_stream_producer_eglsurface
  1024. #define EGL_KHR_stream_producer_eglsurface 1
  1025. #ifdef EGL_KHR_stream
  1026. #define EGL_STREAM_BIT_KHR 0x0800
  1027. typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATESTREAMPRODUCERSURFACEKHRPROC) (EGLDisplay dpy, EGLConfig config, EGLStreamKHR stream, const EGLint *attrib_list);
  1028. #ifdef EGL_EGLEXT_PROTOTYPES
  1029. EGLAPI EGLSurface EGLAPIENTRY eglCreateStreamProducerSurfaceKHR (EGLDisplay dpy, EGLConfig config, EGLStreamKHR stream, const EGLint *attrib_list);
  1030. #endif
  1031. #endif /* EGL_KHR_stream */
  1032. #endif /* EGL_KHR_stream_producer_eglsurface */
  1033. #ifndef EGL_KHR_surfaceless_context
  1034. #define EGL_KHR_surfaceless_context 1
  1035. #endif /* EGL_KHR_surfaceless_context */
  1036. #ifndef EGL_KHR_swap_buffers_with_damage
  1037. #define EGL_KHR_swap_buffers_with_damage 1
  1038. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSWITHDAMAGEKHRPROC) (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects);
  1039. #ifdef EGL_EGLEXT_PROTOTYPES
  1040. EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersWithDamageKHR (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects);
  1041. #endif
  1042. #endif /* EGL_KHR_swap_buffers_with_damage */
  1043. #ifndef EGL_KHR_vg_parent_image
  1044. #define EGL_KHR_vg_parent_image 1
  1045. #define EGL_VG_PARENT_IMAGE_KHR 0x30BA
  1046. #endif /* EGL_KHR_vg_parent_image */
  1047. #ifndef EGL_KHR_wait_sync
  1048. #define EGL_KHR_wait_sync 1
  1049. typedef EGLint (EGLAPIENTRYP PFNEGLWAITSYNCKHRPROC) (EGLDisplay dpy, EGLSyncKHR sync, EGLint flags);
  1050. #ifdef EGL_EGLEXT_PROTOTYPES
  1051. EGLAPI EGLint EGLAPIENTRY eglWaitSyncKHR (EGLDisplay dpy, EGLSyncKHR sync, EGLint flags);
  1052. #endif
  1053. #endif /* EGL_KHR_wait_sync */
  1054. #ifndef EGL_ANDROID_blob_cache
  1055. #define EGL_ANDROID_blob_cache 1
  1056. typedef khronos_ssize_t EGLsizeiANDROID;
  1057. typedef void (*EGLSetBlobFuncANDROID) (const void *key, EGLsizeiANDROID keySize, const void *value, EGLsizeiANDROID valueSize);
  1058. typedef EGLsizeiANDROID (*EGLGetBlobFuncANDROID) (const void *key, EGLsizeiANDROID keySize, void *value, EGLsizeiANDROID valueSize);
  1059. typedef void (EGLAPIENTRYP PFNEGLSETBLOBCACHEFUNCSANDROIDPROC) (EGLDisplay dpy, EGLSetBlobFuncANDROID set, EGLGetBlobFuncANDROID get);
  1060. #ifdef EGL_EGLEXT_PROTOTYPES
  1061. EGLAPI void EGLAPIENTRY eglSetBlobCacheFuncsANDROID (EGLDisplay dpy, EGLSetBlobFuncANDROID set, EGLGetBlobFuncANDROID get);
  1062. #endif
  1063. #endif /* EGL_ANDROID_blob_cache */
  1064. #ifndef EGL_ANDROID_framebuffer_target
  1065. #define EGL_ANDROID_framebuffer_target 1
  1066. #define EGL_FRAMEBUFFER_TARGET_ANDROID 0x3147
  1067. #endif /* EGL_ANDROID_framebuffer_target */
  1068. #ifndef EGL_ANDROID_image_native_buffer
  1069. #define EGL_ANDROID_image_native_buffer 1
  1070. #define EGL_NATIVE_BUFFER_ANDROID 0x3140
  1071. #endif /* EGL_ANDROID_image_native_buffer */
  1072. #ifndef EGL_ANDROID_native_fence_sync
  1073. #define EGL_ANDROID_native_fence_sync 1
  1074. #define EGL_SYNC_NATIVE_FENCE_ANDROID 0x3144
  1075. #define EGL_SYNC_NATIVE_FENCE_FD_ANDROID 0x3145
  1076. #define EGL_SYNC_NATIVE_FENCE_SIGNALED_ANDROID 0x3146
  1077. #define EGL_NO_NATIVE_FENCE_FD_ANDROID -1
  1078. typedef EGLint (EGLAPIENTRYP PFNEGLDUPNATIVEFENCEFDANDROIDPROC) (EGLDisplay dpy, EGLSyncKHR sync);
  1079. #ifdef EGL_EGLEXT_PROTOTYPES
  1080. EGLAPI EGLint EGLAPIENTRY eglDupNativeFenceFDANDROID (EGLDisplay dpy, EGLSyncKHR sync);
  1081. #endif
  1082. #endif /* EGL_ANDROID_native_fence_sync */
  1083. #ifndef EGL_ANDROID_recordable
  1084. #define EGL_ANDROID_recordable 1
  1085. #define EGL_RECORDABLE_ANDROID 0x3142
  1086. #endif /* EGL_ANDROID_recordable */
  1087. #ifndef EGL_ANGLE_d3d_share_handle_client_buffer
  1088. #define EGL_ANGLE_d3d_share_handle_client_buffer 1
  1089. #define EGL_D3D_TEXTURE_2D_SHARE_HANDLE_ANGLE 0x3200
  1090. #endif /* EGL_ANGLE_d3d_share_handle_client_buffer */
  1091. #ifndef EGL_ANGLE_device_d3d
  1092. #define EGL_ANGLE_device_d3d 1
  1093. #define EGL_D3D9_DEVICE_ANGLE 0x33A0
  1094. #define EGL_D3D11_DEVICE_ANGLE 0x33A1
  1095. #endif /* EGL_ANGLE_device_d3d */
  1096. #ifndef EGL_ANGLE_query_surface_pointer
  1097. #define EGL_ANGLE_query_surface_pointer 1
  1098. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYSURFACEPOINTERANGLEPROC) (EGLDisplay dpy, EGLSurface surface, EGLint attribute, void **value);
  1099. #ifdef EGL_EGLEXT_PROTOTYPES
  1100. EGLAPI EGLBoolean EGLAPIENTRY eglQuerySurfacePointerANGLE (EGLDisplay dpy, EGLSurface surface, EGLint attribute, void **value);
  1101. #endif
  1102. #endif /* EGL_ANGLE_query_surface_pointer */
  1103. #ifndef EGL_ANGLE_surface_d3d_texture_2d_share_handle
  1104. #define EGL_ANGLE_surface_d3d_texture_2d_share_handle 1
  1105. #endif /* EGL_ANGLE_surface_d3d_texture_2d_share_handle */
  1106. #ifndef EGL_ANGLE_window_fixed_size
  1107. #define EGL_ANGLE_window_fixed_size 1
  1108. #define EGL_FIXED_SIZE_ANGLE 0x3201
  1109. #endif /* EGL_ANGLE_window_fixed_size */
  1110. #ifndef EGL_ARM_pixmap_multisample_discard
  1111. #define EGL_ARM_pixmap_multisample_discard 1
  1112. #define EGL_DISCARD_SAMPLES_ARM 0x3286
  1113. #endif /* EGL_ARM_pixmap_multisample_discard */
  1114. #ifndef EGL_EXT_buffer_age
  1115. #define EGL_EXT_buffer_age 1
  1116. #define EGL_BUFFER_AGE_EXT 0x313D
  1117. #endif /* EGL_EXT_buffer_age */
  1118. #ifndef EGL_EXT_client_extensions
  1119. #define EGL_EXT_client_extensions 1
  1120. #endif /* EGL_EXT_client_extensions */
  1121. #ifndef EGL_EXT_create_context_robustness
  1122. #define EGL_EXT_create_context_robustness 1
  1123. #define EGL_CONTEXT_OPENGL_ROBUST_ACCESS_EXT 0x30BF
  1124. #define EGL_CONTEXT_OPENGL_RESET_NOTIFICATION_STRATEGY_EXT 0x3138
  1125. #define EGL_NO_RESET_NOTIFICATION_EXT 0x31BE
  1126. #define EGL_LOSE_CONTEXT_ON_RESET_EXT 0x31BF
  1127. #endif /* EGL_EXT_create_context_robustness */
  1128. #ifndef EGL_EXT_device_base
  1129. #define EGL_EXT_device_base 1
  1130. typedef void *EGLDeviceEXT;
  1131. #define EGL_NO_DEVICE_EXT ((EGLDeviceEXT)(0))
  1132. #define EGL_BAD_DEVICE_EXT 0x322B
  1133. #define EGL_DEVICE_EXT 0x322C
  1134. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDEVICEATTRIBEXTPROC) (EGLDeviceEXT device, EGLint attribute, EGLAttrib *value);
  1135. typedef const char *(EGLAPIENTRYP PFNEGLQUERYDEVICESTRINGEXTPROC) (EGLDeviceEXT device, EGLint name);
  1136. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDEVICESEXTPROC) (EGLint max_devices, EGLDeviceEXT *devices, EGLint *num_devices);
  1137. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYDISPLAYATTRIBEXTPROC) (EGLDisplay dpy, EGLint attribute, EGLAttrib *value);
  1138. #ifdef EGL_EGLEXT_PROTOTYPES
  1139. EGLAPI EGLBoolean EGLAPIENTRY eglQueryDeviceAttribEXT (EGLDeviceEXT device, EGLint attribute, EGLAttrib *value);
  1140. EGLAPI const char *EGLAPIENTRY eglQueryDeviceStringEXT (EGLDeviceEXT device, EGLint name);
  1141. EGLAPI EGLBoolean EGLAPIENTRY eglQueryDevicesEXT (EGLint max_devices, EGLDeviceEXT *devices, EGLint *num_devices);
  1142. EGLAPI EGLBoolean EGLAPIENTRY eglQueryDisplayAttribEXT (EGLDisplay dpy, EGLint attribute, EGLAttrib *value);
  1143. #endif
  1144. #endif /* EGL_EXT_device_base */
  1145. #ifndef EGL_EXT_device_drm
  1146. #define EGL_EXT_device_drm 1
  1147. #define EGL_DRM_DEVICE_FILE_EXT 0x3233
  1148. #endif /* EGL_EXT_device_drm */
  1149. #ifndef EGL_EXT_device_enumeration
  1150. #define EGL_EXT_device_enumeration 1
  1151. #endif /* EGL_EXT_device_enumeration */
  1152. #ifndef EGL_EXT_device_openwf
  1153. #define EGL_EXT_device_openwf 1
  1154. #define EGL_OPENWF_DEVICE_ID_EXT 0x3237
  1155. #endif /* EGL_EXT_device_openwf */
  1156. #ifndef EGL_EXT_device_query
  1157. #define EGL_EXT_device_query 1
  1158. #endif /* EGL_EXT_device_query */
  1159. #ifndef EGL_EXT_image_dma_buf_import
  1160. #define EGL_EXT_image_dma_buf_import 1
  1161. #define EGL_LINUX_DMA_BUF_EXT 0x3270
  1162. #define EGL_LINUX_DRM_FOURCC_EXT 0x3271
  1163. #define EGL_DMA_BUF_PLANE0_FD_EXT 0x3272
  1164. #define EGL_DMA_BUF_PLANE0_OFFSET_EXT 0x3273
  1165. #define EGL_DMA_BUF_PLANE0_PITCH_EXT 0x3274
  1166. #define EGL_DMA_BUF_PLANE1_FD_EXT 0x3275
  1167. #define EGL_DMA_BUF_PLANE1_OFFSET_EXT 0x3276
  1168. #define EGL_DMA_BUF_PLANE1_PITCH_EXT 0x3277
  1169. #define EGL_DMA_BUF_PLANE2_FD_EXT 0x3278
  1170. #define EGL_DMA_BUF_PLANE2_OFFSET_EXT 0x3279
  1171. #define EGL_DMA_BUF_PLANE2_PITCH_EXT 0x327A
  1172. #define EGL_YUV_COLOR_SPACE_HINT_EXT 0x327B
  1173. #define EGL_SAMPLE_RANGE_HINT_EXT 0x327C
  1174. #define EGL_YUV_CHROMA_HORIZONTAL_SITING_HINT_EXT 0x327D
  1175. #define EGL_YUV_CHROMA_VERTICAL_SITING_HINT_EXT 0x327E
  1176. #define EGL_ITU_REC601_EXT 0x327F
  1177. #define EGL_ITU_REC709_EXT 0x3280
  1178. #define EGL_ITU_REC2020_EXT 0x3281
  1179. #define EGL_YUV_FULL_RANGE_EXT 0x3282
  1180. #define EGL_YUV_NARROW_RANGE_EXT 0x3283
  1181. #define EGL_YUV_CHROMA_SITING_0_EXT 0x3284
  1182. #define EGL_YUV_CHROMA_SITING_0_5_EXT 0x3285
  1183. #endif /* EGL_EXT_image_dma_buf_import */
  1184. #ifndef EGL_EXT_multiview_window
  1185. #define EGL_EXT_multiview_window 1
  1186. #define EGL_MULTIVIEW_VIEW_COUNT_EXT 0x3134
  1187. #endif /* EGL_EXT_multiview_window */
  1188. #ifndef EGL_EXT_output_base
  1189. #define EGL_EXT_output_base 1
  1190. typedef void *EGLOutputLayerEXT;
  1191. typedef void *EGLOutputPortEXT;
  1192. #define EGL_NO_OUTPUT_LAYER_EXT ((EGLOutputLayerEXT)0)
  1193. #define EGL_NO_OUTPUT_PORT_EXT ((EGLOutputPortEXT)0)
  1194. #define EGL_BAD_OUTPUT_LAYER_EXT 0x322D
  1195. #define EGL_BAD_OUTPUT_PORT_EXT 0x322E
  1196. #define EGL_SWAP_INTERVAL_EXT 0x322F
  1197. typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETOUTPUTLAYERSEXTPROC) (EGLDisplay dpy, const EGLAttrib *attrib_list, EGLOutputLayerEXT *layers, EGLint max_layers, EGLint *num_layers);
  1198. typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETOUTPUTPORTSEXTPROC) (EGLDisplay dpy, const EGLAttrib *attrib_list, EGLOutputPortEXT *ports, EGLint max_ports, EGLint *num_ports);
  1199. typedef EGLBoolean (EGLAPIENTRYP PFNEGLOUTPUTLAYERATTRIBEXTPROC) (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint attribute, EGLAttrib value);
  1200. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYOUTPUTLAYERATTRIBEXTPROC) (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint attribute, EGLAttrib *value);
  1201. typedef const char *(EGLAPIENTRYP PFNEGLQUERYOUTPUTLAYERSTRINGEXTPROC) (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint name);
  1202. typedef EGLBoolean (EGLAPIENTRYP PFNEGLOUTPUTPORTATTRIBEXTPROC) (EGLDisplay dpy, EGLOutputPortEXT port, EGLint attribute, EGLAttrib value);
  1203. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYOUTPUTPORTATTRIBEXTPROC) (EGLDisplay dpy, EGLOutputPortEXT port, EGLint attribute, EGLAttrib *value);
  1204. typedef const char *(EGLAPIENTRYP PFNEGLQUERYOUTPUTPORTSTRINGEXTPROC) (EGLDisplay dpy, EGLOutputPortEXT port, EGLint name);
  1205. #ifdef EGL_EGLEXT_PROTOTYPES
  1206. EGLAPI EGLBoolean EGLAPIENTRY eglGetOutputLayersEXT (EGLDisplay dpy, const EGLAttrib *attrib_list, EGLOutputLayerEXT *layers, EGLint max_layers, EGLint *num_layers);
  1207. EGLAPI EGLBoolean EGLAPIENTRY eglGetOutputPortsEXT (EGLDisplay dpy, const EGLAttrib *attrib_list, EGLOutputPortEXT *ports, EGLint max_ports, EGLint *num_ports);
  1208. EGLAPI EGLBoolean EGLAPIENTRY eglOutputLayerAttribEXT (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint attribute, EGLAttrib value);
  1209. EGLAPI EGLBoolean EGLAPIENTRY eglQueryOutputLayerAttribEXT (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint attribute, EGLAttrib *value);
  1210. EGLAPI const char *EGLAPIENTRY eglQueryOutputLayerStringEXT (EGLDisplay dpy, EGLOutputLayerEXT layer, EGLint name);
  1211. EGLAPI EGLBoolean EGLAPIENTRY eglOutputPortAttribEXT (EGLDisplay dpy, EGLOutputPortEXT port, EGLint attribute, EGLAttrib value);
  1212. EGLAPI EGLBoolean EGLAPIENTRY eglQueryOutputPortAttribEXT (EGLDisplay dpy, EGLOutputPortEXT port, EGLint attribute, EGLAttrib *value);
  1213. EGLAPI const char *EGLAPIENTRY eglQueryOutputPortStringEXT (EGLDisplay dpy, EGLOutputPortEXT port, EGLint name);
  1214. #endif
  1215. #endif /* EGL_EXT_output_base */
  1216. #ifndef EGL_EXT_output_drm
  1217. #define EGL_EXT_output_drm 1
  1218. #define EGL_DRM_CRTC_EXT 0x3234
  1219. #define EGL_DRM_PLANE_EXT 0x3235
  1220. #define EGL_DRM_CONNECTOR_EXT 0x3236
  1221. #endif /* EGL_EXT_output_drm */
  1222. #ifndef EGL_EXT_output_openwf
  1223. #define EGL_EXT_output_openwf 1
  1224. #define EGL_OPENWF_PIPELINE_ID_EXT 0x3238
  1225. #define EGL_OPENWF_PORT_ID_EXT 0x3239
  1226. #endif /* EGL_EXT_output_openwf */
  1227. #ifndef EGL_EXT_platform_base
  1228. #define EGL_EXT_platform_base 1
  1229. typedef EGLDisplay (EGLAPIENTRYP PFNEGLGETPLATFORMDISPLAYEXTPROC) (EGLenum platform, void *native_display, const EGLint *attrib_list);
  1230. typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPLATFORMWINDOWSURFACEEXTPROC) (EGLDisplay dpy, EGLConfig config, void *native_window, const EGLint *attrib_list);
  1231. typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPLATFORMPIXMAPSURFACEEXTPROC) (EGLDisplay dpy, EGLConfig config, void *native_pixmap, const EGLint *attrib_list);
  1232. #ifdef EGL_EGLEXT_PROTOTYPES
  1233. EGLAPI EGLDisplay EGLAPIENTRY eglGetPlatformDisplayEXT (EGLenum platform, void *native_display, const EGLint *attrib_list);
  1234. EGLAPI EGLSurface EGLAPIENTRY eglCreatePlatformWindowSurfaceEXT (EGLDisplay dpy, EGLConfig config, void *native_window, const EGLint *attrib_list);
  1235. EGLAPI EGLSurface EGLAPIENTRY eglCreatePlatformPixmapSurfaceEXT (EGLDisplay dpy, EGLConfig config, void *native_pixmap, const EGLint *attrib_list);
  1236. #endif
  1237. #endif /* EGL_EXT_platform_base */
  1238. #ifndef EGL_EXT_platform_device
  1239. #define EGL_EXT_platform_device 1
  1240. #define EGL_PLATFORM_DEVICE_EXT 0x313F
  1241. #endif /* EGL_EXT_platform_device */
  1242. #ifndef EGL_EXT_platform_wayland
  1243. #define EGL_EXT_platform_wayland 1
  1244. #define EGL_PLATFORM_WAYLAND_EXT 0x31D8
  1245. #endif /* EGL_EXT_platform_wayland */
  1246. #ifndef EGL_EXT_platform_x11
  1247. #define EGL_EXT_platform_x11 1
  1248. #define EGL_PLATFORM_X11_EXT 0x31D5
  1249. #define EGL_PLATFORM_X11_SCREEN_EXT 0x31D6
  1250. #endif /* EGL_EXT_platform_x11 */
  1251. #ifndef EGL_EXT_protected_surface
  1252. #define EGL_EXT_protected_surface 1
  1253. #define EGL_PROTECTED_CONTENT_EXT 0x32C0
  1254. #endif /* EGL_EXT_protected_surface */
  1255. #ifndef EGL_EXT_stream_consumer_egloutput
  1256. #define EGL_EXT_stream_consumer_egloutput 1
  1257. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSTREAMCONSUMEROUTPUTEXTPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLOutputLayerEXT layer);
  1258. #ifdef EGL_EGLEXT_PROTOTYPES
  1259. EGLAPI EGLBoolean EGLAPIENTRY eglStreamConsumerOutputEXT (EGLDisplay dpy, EGLStreamKHR stream, EGLOutputLayerEXT layer);
  1260. #endif
  1261. #endif /* EGL_EXT_stream_consumer_egloutput */
  1262. #ifndef EGL_EXT_swap_buffers_with_damage
  1263. #define EGL_EXT_swap_buffers_with_damage 1
  1264. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSWITHDAMAGEEXTPROC) (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects);
  1265. #ifdef EGL_EGLEXT_PROTOTYPES
  1266. EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersWithDamageEXT (EGLDisplay dpy, EGLSurface surface, EGLint *rects, EGLint n_rects);
  1267. #endif
  1268. #endif /* EGL_EXT_swap_buffers_with_damage */
  1269. #ifndef EGL_EXT_yuv_surface
  1270. #define EGL_EXT_yuv_surface 1
  1271. #define EGL_YUV_ORDER_EXT 0x3301
  1272. #define EGL_YUV_NUMBER_OF_PLANES_EXT 0x3311
  1273. #define EGL_YUV_SUBSAMPLE_EXT 0x3312
  1274. #define EGL_YUV_DEPTH_RANGE_EXT 0x3317
  1275. #define EGL_YUV_CSC_STANDARD_EXT 0x330A
  1276. #define EGL_YUV_PLANE_BPP_EXT 0x331A
  1277. #define EGL_YUV_BUFFER_EXT 0x3300
  1278. #define EGL_YUV_ORDER_YUV_EXT 0x3302
  1279. #define EGL_YUV_ORDER_YVU_EXT 0x3303
  1280. #define EGL_YUV_ORDER_YUYV_EXT 0x3304
  1281. #define EGL_YUV_ORDER_UYVY_EXT 0x3305
  1282. #define EGL_YUV_ORDER_YVYU_EXT 0x3306
  1283. #define EGL_YUV_ORDER_VYUY_EXT 0x3307
  1284. #define EGL_YUV_ORDER_AYUV_EXT 0x3308
  1285. #define EGL_YUV_SUBSAMPLE_4_2_0_EXT 0x3313
  1286. #define EGL_YUV_SUBSAMPLE_4_2_2_EXT 0x3314
  1287. #define EGL_YUV_SUBSAMPLE_4_4_4_EXT 0x3315
  1288. #define EGL_YUV_DEPTH_RANGE_LIMITED_EXT 0x3318
  1289. #define EGL_YUV_DEPTH_RANGE_FULL_EXT 0x3319
  1290. #define EGL_YUV_CSC_STANDARD_601_EXT 0x330B
  1291. #define EGL_YUV_CSC_STANDARD_709_EXT 0x330C
  1292. #define EGL_YUV_CSC_STANDARD_2020_EXT 0x330D
  1293. #define EGL_YUV_PLANE_BPP_0_EXT 0x331B
  1294. #define EGL_YUV_PLANE_BPP_8_EXT 0x331C
  1295. #define EGL_YUV_PLANE_BPP_10_EXT 0x331D
  1296. #endif /* EGL_EXT_yuv_surface */
  1297. #ifndef EGL_HI_clientpixmap
  1298. #define EGL_HI_clientpixmap 1
  1299. struct EGLClientPixmapHI {
  1300. void *pData;
  1301. EGLint iWidth;
  1302. EGLint iHeight;
  1303. EGLint iStride;
  1304. };
  1305. #define EGL_CLIENT_PIXMAP_POINTER_HI 0x8F74
  1306. typedef EGLSurface (EGLAPIENTRYP PFNEGLCREATEPIXMAPSURFACEHIPROC) (EGLDisplay dpy, EGLConfig config, struct EGLClientPixmapHI *pixmap);
  1307. #ifdef EGL_EGLEXT_PROTOTYPES
  1308. EGLAPI EGLSurface EGLAPIENTRY eglCreatePixmapSurfaceHI (EGLDisplay dpy, EGLConfig config, struct EGLClientPixmapHI *pixmap);
  1309. #endif
  1310. #endif /* EGL_HI_clientpixmap */
  1311. #ifndef EGL_HI_colorformats
  1312. #define EGL_HI_colorformats 1
  1313. #define EGL_COLOR_FORMAT_HI 0x8F70
  1314. #define EGL_COLOR_RGB_HI 0x8F71
  1315. #define EGL_COLOR_RGBA_HI 0x8F72
  1316. #define EGL_COLOR_ARGB_HI 0x8F73
  1317. #endif /* EGL_HI_colorformats */
  1318. #ifndef EGL_IMG_context_priority
  1319. #define EGL_IMG_context_priority 1
  1320. #define EGL_CONTEXT_PRIORITY_LEVEL_IMG 0x3100
  1321. #define EGL_CONTEXT_PRIORITY_HIGH_IMG 0x3101
  1322. #define EGL_CONTEXT_PRIORITY_MEDIUM_IMG 0x3102
  1323. #define EGL_CONTEXT_PRIORITY_LOW_IMG 0x3103
  1324. #endif /* EGL_IMG_context_priority */
  1325. #ifndef EGL_MESA_drm_image
  1326. #define EGL_MESA_drm_image 1
  1327. #define EGL_DRM_BUFFER_FORMAT_MESA 0x31D0
  1328. #define EGL_DRM_BUFFER_USE_MESA 0x31D1
  1329. #define EGL_DRM_BUFFER_FORMAT_ARGB32_MESA 0x31D2
  1330. #define EGL_DRM_BUFFER_MESA 0x31D3
  1331. #define EGL_DRM_BUFFER_STRIDE_MESA 0x31D4
  1332. #define EGL_DRM_BUFFER_USE_SCANOUT_MESA 0x00000001
  1333. #define EGL_DRM_BUFFER_USE_SHARE_MESA 0x00000002
  1334. typedef EGLImageKHR (EGLAPIENTRYP PFNEGLCREATEDRMIMAGEMESAPROC) (EGLDisplay dpy, const EGLint *attrib_list);
  1335. typedef EGLBoolean (EGLAPIENTRYP PFNEGLEXPORTDRMIMAGEMESAPROC) (EGLDisplay dpy, EGLImageKHR image, EGLint *name, EGLint *handle, EGLint *stride);
  1336. #ifdef EGL_EGLEXT_PROTOTYPES
  1337. EGLAPI EGLImageKHR EGLAPIENTRY eglCreateDRMImageMESA (EGLDisplay dpy, const EGLint *attrib_list);
  1338. EGLAPI EGLBoolean EGLAPIENTRY eglExportDRMImageMESA (EGLDisplay dpy, EGLImageKHR image, EGLint *name, EGLint *handle, EGLint *stride);
  1339. #endif
  1340. #endif /* EGL_MESA_drm_image */
  1341. #ifndef EGL_MESA_image_dma_buf_export
  1342. #define EGL_MESA_image_dma_buf_export 1
  1343. typedef EGLBoolean (EGLAPIENTRYP PFNEGLEXPORTDMABUFIMAGEQUERYMESAPROC) (EGLDisplay dpy, EGLImageKHR image, int *fourcc, int *num_planes, EGLuint64KHR *modifiers);
  1344. typedef EGLBoolean (EGLAPIENTRYP PFNEGLEXPORTDMABUFIMAGEMESAPROC) (EGLDisplay dpy, EGLImageKHR image, int *fds, EGLint *strides, EGLint *offsets);
  1345. #ifdef EGL_EGLEXT_PROTOTYPES
  1346. EGLAPI EGLBoolean EGLAPIENTRY eglExportDMABUFImageQueryMESA (EGLDisplay dpy, EGLImageKHR image, int *fourcc, int *num_planes, EGLuint64KHR *modifiers);
  1347. EGLAPI EGLBoolean EGLAPIENTRY eglExportDMABUFImageMESA (EGLDisplay dpy, EGLImageKHR image, int *fds, EGLint *strides, EGLint *offsets);
  1348. #endif
  1349. #endif /* EGL_MESA_image_dma_buf_export */
  1350. #ifndef EGL_MESA_platform_gbm
  1351. #define EGL_MESA_platform_gbm 1
  1352. #define EGL_PLATFORM_GBM_MESA 0x31D7
  1353. #endif /* EGL_MESA_platform_gbm */
  1354. #ifndef EGL_NOK_swap_region
  1355. #define EGL_NOK_swap_region 1
  1356. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSREGIONNOKPROC) (EGLDisplay dpy, EGLSurface surface, EGLint numRects, const EGLint *rects);
  1357. #ifdef EGL_EGLEXT_PROTOTYPES
  1358. EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersRegionNOK (EGLDisplay dpy, EGLSurface surface, EGLint numRects, const EGLint *rects);
  1359. #endif
  1360. #endif /* EGL_NOK_swap_region */
  1361. #ifndef EGL_NOK_swap_region2
  1362. #define EGL_NOK_swap_region2 1
  1363. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSWAPBUFFERSREGION2NOKPROC) (EGLDisplay dpy, EGLSurface surface, EGLint numRects, const EGLint *rects);
  1364. #ifdef EGL_EGLEXT_PROTOTYPES
  1365. EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffersRegion2NOK (EGLDisplay dpy, EGLSurface surface, EGLint numRects, const EGLint *rects);
  1366. #endif
  1367. #endif /* EGL_NOK_swap_region2 */
  1368. #ifndef EGL_NOK_texture_from_pixmap
  1369. #define EGL_NOK_texture_from_pixmap 1
  1370. #define EGL_Y_INVERTED_NOK 0x307F
  1371. #endif /* EGL_NOK_texture_from_pixmap */
  1372. #ifndef EGL_NV_3dvision_surface
  1373. #define EGL_NV_3dvision_surface 1
  1374. #define EGL_AUTO_STEREO_NV 0x3136
  1375. #endif /* EGL_NV_3dvision_surface */
  1376. #ifndef EGL_NV_coverage_sample
  1377. #define EGL_NV_coverage_sample 1
  1378. #define EGL_COVERAGE_BUFFERS_NV 0x30E0
  1379. #define EGL_COVERAGE_SAMPLES_NV 0x30E1
  1380. #endif /* EGL_NV_coverage_sample */
  1381. #ifndef EGL_NV_coverage_sample_resolve
  1382. #define EGL_NV_coverage_sample_resolve 1
  1383. #define EGL_COVERAGE_SAMPLE_RESOLVE_NV 0x3131
  1384. #define EGL_COVERAGE_SAMPLE_RESOLVE_DEFAULT_NV 0x3132
  1385. #define EGL_COVERAGE_SAMPLE_RESOLVE_NONE_NV 0x3133
  1386. #endif /* EGL_NV_coverage_sample_resolve */
  1387. #ifndef EGL_NV_cuda_event
  1388. #define EGL_NV_cuda_event 1
  1389. #define EGL_CUDA_EVENT_HANDLE_NV 0x323B
  1390. #define EGL_SYNC_CUDA_EVENT_NV 0x323C
  1391. #define EGL_SYNC_CUDA_EVENT_COMPLETE_NV 0x323D
  1392. #endif /* EGL_NV_cuda_event */
  1393. #ifndef EGL_NV_depth_nonlinear
  1394. #define EGL_NV_depth_nonlinear 1
  1395. #define EGL_DEPTH_ENCODING_NV 0x30E2
  1396. #define EGL_DEPTH_ENCODING_NONE_NV 0
  1397. #define EGL_DEPTH_ENCODING_NONLINEAR_NV 0x30E3
  1398. #endif /* EGL_NV_depth_nonlinear */
  1399. #ifndef EGL_NV_device_cuda
  1400. #define EGL_NV_device_cuda 1
  1401. #define EGL_CUDA_DEVICE_NV 0x323A
  1402. #endif /* EGL_NV_device_cuda */
  1403. #ifndef EGL_NV_native_query
  1404. #define EGL_NV_native_query 1
  1405. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYNATIVEDISPLAYNVPROC) (EGLDisplay dpy, EGLNativeDisplayType *display_id);
  1406. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYNATIVEWINDOWNVPROC) (EGLDisplay dpy, EGLSurface surf, EGLNativeWindowType *window);
  1407. typedef EGLBoolean (EGLAPIENTRYP PFNEGLQUERYNATIVEPIXMAPNVPROC) (EGLDisplay dpy, EGLSurface surf, EGLNativePixmapType *pixmap);
  1408. #ifdef EGL_EGLEXT_PROTOTYPES
  1409. EGLAPI EGLBoolean EGLAPIENTRY eglQueryNativeDisplayNV (EGLDisplay dpy, EGLNativeDisplayType *display_id);
  1410. EGLAPI EGLBoolean EGLAPIENTRY eglQueryNativeWindowNV (EGLDisplay dpy, EGLSurface surf, EGLNativeWindowType *window);
  1411. EGLAPI EGLBoolean EGLAPIENTRY eglQueryNativePixmapNV (EGLDisplay dpy, EGLSurface surf, EGLNativePixmapType *pixmap);
  1412. #endif
  1413. #endif /* EGL_NV_native_query */
  1414. #ifndef EGL_NV_post_convert_rounding
  1415. #define EGL_NV_post_convert_rounding 1
  1416. #endif /* EGL_NV_post_convert_rounding */
  1417. #ifndef EGL_NV_post_sub_buffer
  1418. #define EGL_NV_post_sub_buffer 1
  1419. #define EGL_POST_SUB_BUFFER_SUPPORTED_NV 0x30BE
  1420. typedef EGLBoolean (EGLAPIENTRYP PFNEGLPOSTSUBBUFFERNVPROC) (EGLDisplay dpy, EGLSurface surface, EGLint x, EGLint y, EGLint width, EGLint height);
  1421. #ifdef EGL_EGLEXT_PROTOTYPES
  1422. EGLAPI EGLBoolean EGLAPIENTRY eglPostSubBufferNV (EGLDisplay dpy, EGLSurface surface, EGLint x, EGLint y, EGLint width, EGLint height);
  1423. #endif
  1424. #endif /* EGL_NV_post_sub_buffer */
  1425. #ifndef EGL_NV_stream_sync
  1426. #define EGL_NV_stream_sync 1
  1427. #define EGL_SYNC_NEW_FRAME_NV 0x321F
  1428. typedef EGLSyncKHR (EGLAPIENTRYP PFNEGLCREATESTREAMSYNCNVPROC) (EGLDisplay dpy, EGLStreamKHR stream, EGLenum type, const EGLint *attrib_list);
  1429. #ifdef EGL_EGLEXT_PROTOTYPES
  1430. EGLAPI EGLSyncKHR EGLAPIENTRY eglCreateStreamSyncNV (EGLDisplay dpy, EGLStreamKHR stream, EGLenum type, const EGLint *attrib_list);
  1431. #endif
  1432. #endif /* EGL_NV_stream_sync */
  1433. #ifndef EGL_NV_sync
  1434. #define EGL_NV_sync 1
  1435. typedef void *EGLSyncNV;
  1436. typedef khronos_utime_nanoseconds_t EGLTimeNV;
  1437. #ifdef KHRONOS_SUPPORT_INT64
  1438. #define EGL_SYNC_PRIOR_COMMANDS_COMPLETE_NV 0x30E6
  1439. #define EGL_SYNC_STATUS_NV 0x30E7
  1440. #define EGL_SIGNALED_NV 0x30E8
  1441. #define EGL_UNSIGNALED_NV 0x30E9
  1442. #define EGL_SYNC_FLUSH_COMMANDS_BIT_NV 0x0001
  1443. #define EGL_FOREVER_NV 0xFFFFFFFFFFFFFFFFull
  1444. #define EGL_ALREADY_SIGNALED_NV 0x30EA
  1445. #define EGL_TIMEOUT_EXPIRED_NV 0x30EB
  1446. #define EGL_CONDITION_SATISFIED_NV 0x30EC
  1447. #define EGL_SYNC_TYPE_NV 0x30ED
  1448. #define EGL_SYNC_CONDITION_NV 0x30EE
  1449. #define EGL_SYNC_FENCE_NV 0x30EF
  1450. #define EGL_NO_SYNC_NV ((EGLSyncNV)0)
  1451. typedef EGLSyncNV (EGLAPIENTRYP PFNEGLCREATEFENCESYNCNVPROC) (EGLDisplay dpy, EGLenum condition, const EGLint *attrib_list);
  1452. typedef EGLBoolean (EGLAPIENTRYP PFNEGLDESTROYSYNCNVPROC) (EGLSyncNV sync);
  1453. typedef EGLBoolean (EGLAPIENTRYP PFNEGLFENCENVPROC) (EGLSyncNV sync);
  1454. typedef EGLint (EGLAPIENTRYP PFNEGLCLIENTWAITSYNCNVPROC) (EGLSyncNV sync, EGLint flags, EGLTimeNV timeout);
  1455. typedef EGLBoolean (EGLAPIENTRYP PFNEGLSIGNALSYNCNVPROC) (EGLSyncNV sync, EGLenum mode);
  1456. typedef EGLBoolean (EGLAPIENTRYP PFNEGLGETSYNCATTRIBNVPROC) (EGLSyncNV sync, EGLint attribute, EGLint *value);
  1457. #ifdef EGL_EGLEXT_PROTOTYPES
  1458. EGLAPI EGLSyncNV EGLAPIENTRY eglCreateFenceSyncNV (EGLDisplay dpy, EGLenum condition, const EGLint *attrib_list);
  1459. EGLAPI EGLBoolean EGLAPIENTRY eglDestroySyncNV (EGLSyncNV sync);
  1460. EGLAPI EGLBoolean EGLAPIENTRY eglFenceNV (EGLSyncNV sync);
  1461. EGLAPI EGLint EGLAPIENTRY eglClientWaitSyncNV (EGLSyncNV sync, EGLint flags, EGLTimeNV timeout);
  1462. EGLAPI EGLBoolean EGLAPIENTRY eglSignalSyncNV (EGLSyncNV sync, EGLenum mode);
  1463. EGLAPI EGLBoolean EGLAPIENTRY eglGetSyncAttribNV (EGLSyncNV sync, EGLint attribute, EGLint *value);
  1464. #endif
  1465. #endif /* KHRONOS_SUPPORT_INT64 */
  1466. #endif /* EGL_NV_sync */
  1467. #ifndef EGL_NV_system_time
  1468. #define EGL_NV_system_time 1
  1469. typedef khronos_utime_nanoseconds_t EGLuint64NV;
  1470. #ifdef KHRONOS_SUPPORT_INT64
  1471. typedef EGLuint64NV (EGLAPIENTRYP PFNEGLGETSYSTEMTIMEFREQUENCYNVPROC) (void);
  1472. typedef EGLuint64NV (EGLAPIENTRYP PFNEGLGETSYSTEMTIMENVPROC) (void);
  1473. #ifdef EGL_EGLEXT_PROTOTYPES
  1474. EGLAPI EGLuint64NV EGLAPIENTRY eglGetSystemTimeFrequencyNV (void);
  1475. EGLAPI EGLuint64NV EGLAPIENTRY eglGetSystemTimeNV (void);
  1476. #endif
  1477. #endif /* KHRONOS_SUPPORT_INT64 */
  1478. #endif /* EGL_NV_system_time */
  1479. #ifndef EGL_TIZEN_image_native_buffer
  1480. #define EGL_TIZEN_image_native_buffer 1
  1481. #define EGL_NATIVE_BUFFER_TIZEN 0x32A0
  1482. #endif /* EGL_TIZEN_image_native_buffer */
  1483. #ifndef EGL_TIZEN_image_native_surface
  1484. #define EGL_TIZEN_image_native_surface 1
  1485. #define EGL_NATIVE_SURFACE_TIZEN 0x32A1
  1486. #endif /* EGL_TIZEN_image_native_surface */
  1487. #ifdef __cplusplus
  1488. }
  1489. #endif
  1490. #endif /* __eglext_h_ */
  1491. #endif /* _MSC_VER */