1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 // This file is auto-generated from
6 // ui/gl/generate_bindings.py
7 // It's formatted by clang-format using chromium coding style:
8 // clang-format -i -style=chromium filename
11 #ifndef UI_GFX_GL_GL_BINDINGS_AUTOGEN_EGL_H_
12 #define UI_GFX_GL_GL_BINDINGS_AUTOGEN_EGL_H_
18 typedef EGLBoolean(GL_BINDING_CALL
* eglBindAPIProc
)(EGLenum api
);
19 typedef EGLBoolean(GL_BINDING_CALL
* eglBindTexImageProc
)(EGLDisplay dpy
,
22 typedef EGLBoolean(GL_BINDING_CALL
* eglChooseConfigProc
)(
24 const EGLint
* attrib_list
,
28 typedef EGLint(GL_BINDING_CALL
* eglClientWaitSyncKHRProc
)(EGLDisplay dpy
,
32 typedef EGLBoolean(GL_BINDING_CALL
* eglCopyBuffersProc
)(
35 EGLNativePixmapType target
);
36 typedef EGLContext(GL_BINDING_CALL
* eglCreateContextProc
)(
39 EGLContext share_context
,
40 const EGLint
* attrib_list
);
41 typedef EGLImageKHR(GL_BINDING_CALL
* eglCreateImageKHRProc
)(
45 EGLClientBuffer buffer
,
46 const EGLint
* attrib_list
);
47 typedef EGLSurface(GL_BINDING_CALL
* eglCreatePbufferFromClientBufferProc
)(
52 const EGLint
* attrib_list
);
53 typedef EGLSurface(GL_BINDING_CALL
* eglCreatePbufferSurfaceProc
)(
56 const EGLint
* attrib_list
);
57 typedef EGLSurface(GL_BINDING_CALL
* eglCreatePixmapSurfaceProc
)(
60 EGLNativePixmapType pixmap
,
61 const EGLint
* attrib_list
);
62 typedef EGLSyncKHR(GL_BINDING_CALL
* eglCreateSyncKHRProc
)(
65 const EGLint
* attrib_list
);
66 typedef EGLSurface(GL_BINDING_CALL
* eglCreateWindowSurfaceProc
)(
69 EGLNativeWindowType win
,
70 const EGLint
* attrib_list
);
71 typedef EGLBoolean(GL_BINDING_CALL
* eglDestroyContextProc
)(EGLDisplay dpy
,
73 typedef EGLBoolean(GL_BINDING_CALL
* eglDestroyImageKHRProc
)(EGLDisplay dpy
,
75 typedef EGLBoolean(GL_BINDING_CALL
* eglDestroySurfaceProc
)(EGLDisplay dpy
,
77 typedef EGLBoolean(GL_BINDING_CALL
* eglDestroySyncKHRProc
)(EGLDisplay dpy
,
79 typedef EGLBoolean(GL_BINDING_CALL
* eglGetConfigAttribProc
)(EGLDisplay dpy
,
83 typedef EGLBoolean(GL_BINDING_CALL
* eglGetConfigsProc
)(EGLDisplay dpy
,
87 typedef EGLContext(GL_BINDING_CALL
* eglGetCurrentContextProc
)(void);
88 typedef EGLDisplay(GL_BINDING_CALL
* eglGetCurrentDisplayProc
)(void);
89 typedef EGLSurface(GL_BINDING_CALL
* eglGetCurrentSurfaceProc
)(EGLint readdraw
);
90 typedef EGLDisplay(GL_BINDING_CALL
* eglGetDisplayProc
)(
91 EGLNativeDisplayType display_id
);
92 typedef EGLint(GL_BINDING_CALL
* eglGetErrorProc
)(void);
93 typedef EGLDisplay(GL_BINDING_CALL
* eglGetPlatformDisplayEXTProc
)(
96 const EGLint
* attrib_list
);
97 typedef __eglMustCastToProperFunctionPointerType(
98 GL_BINDING_CALL
* eglGetProcAddressProc
)(const char* procname
);
99 typedef EGLBoolean(GL_BINDING_CALL
* eglGetSyncAttribKHRProc
)(EGLDisplay dpy
,
103 typedef EGLBoolean(GL_BINDING_CALL
* eglGetSyncValuesCHROMIUMProc
)(
106 EGLuint64CHROMIUM
* ust
,
107 EGLuint64CHROMIUM
* msc
,
108 EGLuint64CHROMIUM
* sbc
);
109 typedef EGLBoolean(GL_BINDING_CALL
* eglInitializeProc
)(EGLDisplay dpy
,
112 typedef EGLBoolean(GL_BINDING_CALL
* eglMakeCurrentProc
)(EGLDisplay dpy
,
116 typedef EGLBoolean(GL_BINDING_CALL
* eglPostSubBufferNVProc
)(EGLDisplay dpy
,
122 typedef EGLenum(GL_BINDING_CALL
* eglQueryAPIProc
)(void);
123 typedef EGLBoolean(GL_BINDING_CALL
* eglQueryContextProc
)(EGLDisplay dpy
,
127 typedef const char*(GL_BINDING_CALL
* eglQueryStringProc
)(EGLDisplay dpy
,
129 typedef EGLBoolean(GL_BINDING_CALL
* eglQuerySurfaceProc
)(EGLDisplay dpy
,
133 typedef EGLBoolean(GL_BINDING_CALL
* eglQuerySurfacePointerANGLEProc
)(
138 typedef EGLBoolean(GL_BINDING_CALL
* eglReleaseTexImageProc
)(EGLDisplay dpy
,
141 typedef EGLBoolean(GL_BINDING_CALL
* eglReleaseThreadProc
)(void);
142 typedef EGLBoolean(GL_BINDING_CALL
* eglSurfaceAttribProc
)(EGLDisplay dpy
,
146 typedef EGLBoolean(GL_BINDING_CALL
* eglSwapBuffersProc
)(EGLDisplay dpy
,
148 typedef EGLBoolean(GL_BINDING_CALL
* eglSwapIntervalProc
)(EGLDisplay dpy
,
150 typedef EGLBoolean(GL_BINDING_CALL
* eglTerminateProc
)(EGLDisplay dpy
);
151 typedef EGLBoolean(GL_BINDING_CALL
* eglWaitClientProc
)(void);
152 typedef EGLBoolean(GL_BINDING_CALL
* eglWaitGLProc
)(void);
153 typedef EGLBoolean(GL_BINDING_CALL
* eglWaitNativeProc
)(EGLint engine
);
154 typedef EGLint(GL_BINDING_CALL
* eglWaitSyncKHRProc
)(EGLDisplay dpy
,
158 struct ExtensionsEGL
{
159 bool b_EGL_ANGLE_d3d_share_handle_client_buffer
;
160 bool b_EGL_ANGLE_platform_angle
;
161 bool b_EGL_ANGLE_query_surface_pointer
;
162 bool b_EGL_ANGLE_surface_d3d_texture_2d_share_handle
;
163 bool b_EGL_CHROMIUM_sync_control
;
164 bool b_EGL_KHR_fence_sync
;
165 bool b_EGL_KHR_gl_texture_2D_image
;
166 bool b_EGL_KHR_image
;
167 bool b_EGL_KHR_image_base
;
168 bool b_EGL_KHR_reusable_sync
;
169 bool b_EGL_KHR_wait_sync
;
170 bool b_EGL_NV_post_sub_buffer
;
174 eglBindAPIProc eglBindAPIFn
;
175 eglBindTexImageProc eglBindTexImageFn
;
176 eglChooseConfigProc eglChooseConfigFn
;
177 eglClientWaitSyncKHRProc eglClientWaitSyncKHRFn
;
178 eglCopyBuffersProc eglCopyBuffersFn
;
179 eglCreateContextProc eglCreateContextFn
;
180 eglCreateImageKHRProc eglCreateImageKHRFn
;
181 eglCreatePbufferFromClientBufferProc eglCreatePbufferFromClientBufferFn
;
182 eglCreatePbufferSurfaceProc eglCreatePbufferSurfaceFn
;
183 eglCreatePixmapSurfaceProc eglCreatePixmapSurfaceFn
;
184 eglCreateSyncKHRProc eglCreateSyncKHRFn
;
185 eglCreateWindowSurfaceProc eglCreateWindowSurfaceFn
;
186 eglDestroyContextProc eglDestroyContextFn
;
187 eglDestroyImageKHRProc eglDestroyImageKHRFn
;
188 eglDestroySurfaceProc eglDestroySurfaceFn
;
189 eglDestroySyncKHRProc eglDestroySyncKHRFn
;
190 eglGetConfigAttribProc eglGetConfigAttribFn
;
191 eglGetConfigsProc eglGetConfigsFn
;
192 eglGetCurrentContextProc eglGetCurrentContextFn
;
193 eglGetCurrentDisplayProc eglGetCurrentDisplayFn
;
194 eglGetCurrentSurfaceProc eglGetCurrentSurfaceFn
;
195 eglGetDisplayProc eglGetDisplayFn
;
196 eglGetErrorProc eglGetErrorFn
;
197 eglGetPlatformDisplayEXTProc eglGetPlatformDisplayEXTFn
;
198 eglGetProcAddressProc eglGetProcAddressFn
;
199 eglGetSyncAttribKHRProc eglGetSyncAttribKHRFn
;
200 eglGetSyncValuesCHROMIUMProc eglGetSyncValuesCHROMIUMFn
;
201 eglInitializeProc eglInitializeFn
;
202 eglMakeCurrentProc eglMakeCurrentFn
;
203 eglPostSubBufferNVProc eglPostSubBufferNVFn
;
204 eglQueryAPIProc eglQueryAPIFn
;
205 eglQueryContextProc eglQueryContextFn
;
206 eglQueryStringProc eglQueryStringFn
;
207 eglQuerySurfaceProc eglQuerySurfaceFn
;
208 eglQuerySurfacePointerANGLEProc eglQuerySurfacePointerANGLEFn
;
209 eglReleaseTexImageProc eglReleaseTexImageFn
;
210 eglReleaseThreadProc eglReleaseThreadFn
;
211 eglSurfaceAttribProc eglSurfaceAttribFn
;
212 eglSwapBuffersProc eglSwapBuffersFn
;
213 eglSwapIntervalProc eglSwapIntervalFn
;
214 eglTerminateProc eglTerminateFn
;
215 eglWaitClientProc eglWaitClientFn
;
216 eglWaitGLProc eglWaitGLFn
;
217 eglWaitNativeProc eglWaitNativeFn
;
218 eglWaitSyncKHRProc eglWaitSyncKHRFn
;
221 class GL_EXPORT EGLApi
{
226 virtual EGLBoolean
eglBindAPIFn(EGLenum api
) = 0;
227 virtual EGLBoolean
eglBindTexImageFn(EGLDisplay dpy
,
230 virtual EGLBoolean
eglChooseConfigFn(EGLDisplay dpy
,
231 const EGLint
* attrib_list
,
234 EGLint
* num_config
) = 0;
235 virtual EGLint
eglClientWaitSyncKHRFn(EGLDisplay dpy
,
238 EGLTimeKHR timeout
) = 0;
239 virtual EGLBoolean
eglCopyBuffersFn(EGLDisplay dpy
,
241 EGLNativePixmapType target
) = 0;
242 virtual EGLContext
eglCreateContextFn(EGLDisplay dpy
,
244 EGLContext share_context
,
245 const EGLint
* attrib_list
) = 0;
246 virtual EGLImageKHR
eglCreateImageKHRFn(EGLDisplay dpy
,
249 EGLClientBuffer buffer
,
250 const EGLint
* attrib_list
) = 0;
251 virtual EGLSurface
eglCreatePbufferFromClientBufferFn(
256 const EGLint
* attrib_list
) = 0;
257 virtual EGLSurface
eglCreatePbufferSurfaceFn(EGLDisplay dpy
,
259 const EGLint
* attrib_list
) = 0;
260 virtual EGLSurface
eglCreatePixmapSurfaceFn(EGLDisplay dpy
,
262 EGLNativePixmapType pixmap
,
263 const EGLint
* attrib_list
) = 0;
264 virtual EGLSyncKHR
eglCreateSyncKHRFn(EGLDisplay dpy
,
266 const EGLint
* attrib_list
) = 0;
267 virtual EGLSurface
eglCreateWindowSurfaceFn(EGLDisplay dpy
,
269 EGLNativeWindowType win
,
270 const EGLint
* attrib_list
) = 0;
271 virtual EGLBoolean
eglDestroyContextFn(EGLDisplay dpy
, EGLContext ctx
) = 0;
272 virtual EGLBoolean
eglDestroyImageKHRFn(EGLDisplay dpy
,
273 EGLImageKHR image
) = 0;
274 virtual EGLBoolean
eglDestroySurfaceFn(EGLDisplay dpy
,
275 EGLSurface surface
) = 0;
276 virtual EGLBoolean
eglDestroySyncKHRFn(EGLDisplay dpy
, EGLSyncKHR sync
) = 0;
277 virtual EGLBoolean
eglGetConfigAttribFn(EGLDisplay dpy
,
281 virtual EGLBoolean
eglGetConfigsFn(EGLDisplay dpy
,
284 EGLint
* num_config
) = 0;
285 virtual EGLContext
eglGetCurrentContextFn(void) = 0;
286 virtual EGLDisplay
eglGetCurrentDisplayFn(void) = 0;
287 virtual EGLSurface
eglGetCurrentSurfaceFn(EGLint readdraw
) = 0;
288 virtual EGLDisplay
eglGetDisplayFn(EGLNativeDisplayType display_id
) = 0;
289 virtual EGLint
eglGetErrorFn(void) = 0;
290 virtual EGLDisplay
eglGetPlatformDisplayEXTFn(EGLenum platform
,
291 void* native_display
,
292 const EGLint
* attrib_list
) = 0;
293 virtual __eglMustCastToProperFunctionPointerType
eglGetProcAddressFn(
294 const char* procname
) = 0;
295 virtual EGLBoolean
eglGetSyncAttribKHRFn(EGLDisplay dpy
,
299 virtual EGLBoolean
eglGetSyncValuesCHROMIUMFn(EGLDisplay dpy
,
301 EGLuint64CHROMIUM
* ust
,
302 EGLuint64CHROMIUM
* msc
,
303 EGLuint64CHROMIUM
* sbc
) = 0;
304 virtual EGLBoolean
eglInitializeFn(EGLDisplay dpy
,
307 virtual EGLBoolean
eglMakeCurrentFn(EGLDisplay dpy
,
311 virtual EGLBoolean
eglPostSubBufferNVFn(EGLDisplay dpy
,
317 virtual EGLenum
eglQueryAPIFn(void) = 0;
318 virtual EGLBoolean
eglQueryContextFn(EGLDisplay dpy
,
322 virtual const char* eglQueryStringFn(EGLDisplay dpy
, EGLint name
) = 0;
323 virtual EGLBoolean
eglQuerySurfaceFn(EGLDisplay dpy
,
327 virtual EGLBoolean
eglQuerySurfacePointerANGLEFn(EGLDisplay dpy
,
331 virtual EGLBoolean
eglReleaseTexImageFn(EGLDisplay dpy
,
334 virtual EGLBoolean
eglReleaseThreadFn(void) = 0;
335 virtual EGLBoolean
eglSurfaceAttribFn(EGLDisplay dpy
,
339 virtual EGLBoolean
eglSwapBuffersFn(EGLDisplay dpy
, EGLSurface surface
) = 0;
340 virtual EGLBoolean
eglSwapIntervalFn(EGLDisplay dpy
, EGLint interval
) = 0;
341 virtual EGLBoolean
eglTerminateFn(EGLDisplay dpy
) = 0;
342 virtual EGLBoolean
eglWaitClientFn(void) = 0;
343 virtual EGLBoolean
eglWaitGLFn(void) = 0;
344 virtual EGLBoolean
eglWaitNativeFn(EGLint engine
) = 0;
345 virtual EGLint
eglWaitSyncKHRFn(EGLDisplay dpy
,
352 #define eglBindAPI ::gfx::g_current_egl_context->eglBindAPIFn
353 #define eglBindTexImage ::gfx::g_current_egl_context->eglBindTexImageFn
354 #define eglChooseConfig ::gfx::g_current_egl_context->eglChooseConfigFn
355 #define eglClientWaitSyncKHR \
356 ::gfx::g_current_egl_context->eglClientWaitSyncKHRFn
357 #define eglCopyBuffers ::gfx::g_current_egl_context->eglCopyBuffersFn
358 #define eglCreateContext ::gfx::g_current_egl_context->eglCreateContextFn
359 #define eglCreateImageKHR ::gfx::g_current_egl_context->eglCreateImageKHRFn
360 #define eglCreatePbufferFromClientBuffer \
361 ::gfx::g_current_egl_context->eglCreatePbufferFromClientBufferFn
362 #define eglCreatePbufferSurface \
363 ::gfx::g_current_egl_context->eglCreatePbufferSurfaceFn
364 #define eglCreatePixmapSurface \
365 ::gfx::g_current_egl_context->eglCreatePixmapSurfaceFn
366 #define eglCreateSyncKHR ::gfx::g_current_egl_context->eglCreateSyncKHRFn
367 #define eglCreateWindowSurface \
368 ::gfx::g_current_egl_context->eglCreateWindowSurfaceFn
369 #define eglDestroyContext ::gfx::g_current_egl_context->eglDestroyContextFn
370 #define eglDestroyImageKHR ::gfx::g_current_egl_context->eglDestroyImageKHRFn
371 #define eglDestroySurface ::gfx::g_current_egl_context->eglDestroySurfaceFn
372 #define eglDestroySyncKHR ::gfx::g_current_egl_context->eglDestroySyncKHRFn
373 #define eglGetConfigAttrib ::gfx::g_current_egl_context->eglGetConfigAttribFn
374 #define eglGetConfigs ::gfx::g_current_egl_context->eglGetConfigsFn
375 #define eglGetCurrentContext \
376 ::gfx::g_current_egl_context->eglGetCurrentContextFn
377 #define eglGetCurrentDisplay \
378 ::gfx::g_current_egl_context->eglGetCurrentDisplayFn
379 #define eglGetCurrentSurface \
380 ::gfx::g_current_egl_context->eglGetCurrentSurfaceFn
381 #define eglGetDisplay ::gfx::g_current_egl_context->eglGetDisplayFn
382 #define eglGetError ::gfx::g_current_egl_context->eglGetErrorFn
383 #define eglGetPlatformDisplayEXT \
384 ::gfx::g_current_egl_context->eglGetPlatformDisplayEXTFn
385 #define eglGetProcAddress ::gfx::g_current_egl_context->eglGetProcAddressFn
386 #define eglGetSyncAttribKHR ::gfx::g_current_egl_context->eglGetSyncAttribKHRFn
387 #define eglGetSyncValuesCHROMIUM \
388 ::gfx::g_current_egl_context->eglGetSyncValuesCHROMIUMFn
389 #define eglInitialize ::gfx::g_current_egl_context->eglInitializeFn
390 #define eglMakeCurrent ::gfx::g_current_egl_context->eglMakeCurrentFn
391 #define eglPostSubBufferNV ::gfx::g_current_egl_context->eglPostSubBufferNVFn
392 #define eglQueryAPI ::gfx::g_current_egl_context->eglQueryAPIFn
393 #define eglQueryContext ::gfx::g_current_egl_context->eglQueryContextFn
394 #define eglQueryString ::gfx::g_current_egl_context->eglQueryStringFn
395 #define eglQuerySurface ::gfx::g_current_egl_context->eglQuerySurfaceFn
396 #define eglQuerySurfacePointerANGLE \
397 ::gfx::g_current_egl_context->eglQuerySurfacePointerANGLEFn
398 #define eglReleaseTexImage ::gfx::g_current_egl_context->eglReleaseTexImageFn
399 #define eglReleaseThread ::gfx::g_current_egl_context->eglReleaseThreadFn
400 #define eglSurfaceAttrib ::gfx::g_current_egl_context->eglSurfaceAttribFn
401 #define eglSwapBuffers ::gfx::g_current_egl_context->eglSwapBuffersFn
402 #define eglSwapInterval ::gfx::g_current_egl_context->eglSwapIntervalFn
403 #define eglTerminate ::gfx::g_current_egl_context->eglTerminateFn
404 #define eglWaitClient ::gfx::g_current_egl_context->eglWaitClientFn
405 #define eglWaitGL ::gfx::g_current_egl_context->eglWaitGLFn
406 #define eglWaitNative ::gfx::g_current_egl_context->eglWaitNativeFn
407 #define eglWaitSyncKHR ::gfx::g_current_egl_context->eglWaitSyncKHRFn
409 #endif // UI_GFX_GL_GL_BINDINGS_AUTOGEN_EGL_H_