1 /* 2 * Copyright (C) 2021 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 #pragma once 18 19 // clang-format off 20 #define FOR_EACH_EGL_FUNCTION(X) \ 21 X(void*, eglGetProcAddress, (const char* procname)) \ 22 X(const char*, eglQueryString, (EGLDisplay dpy, EGLint id)) \ 23 X(EGLDisplay, eglGetPlatformDisplay, (EGLenum platform, void *native_display, const EGLAttrib *attrib_list)) \ 24 X(EGLDisplay, eglGetPlatformDisplayEXT, (EGLenum platform, void *native_display, const EGLint *attrib_list)) \ 25 X(EGLBoolean, eglBindAPI, (EGLenum api)) \ 26 X(EGLBoolean, eglChooseConfig, (EGLDisplay display, EGLint const* attrib_list, EGLConfig* configs, EGLint config_size, EGLint* num_config)) \ 27 X(EGLContext, eglCreateContext, (EGLDisplay display, EGLConfig config, EGLContext share_context, EGLint const* attrib_list)) \ 28 X(EGLSurface, eglCreatePbufferSurface, (EGLDisplay display, EGLConfig config, EGLint const* attrib_list)) \ 29 X(EGLBoolean, eglDestroyContext, (EGLDisplay display, EGLContext context)) \ 30 X(EGLBoolean, eglDestroySurface, (EGLDisplay display, EGLSurface surface)) \ 31 X(EGLBoolean, eglGetConfigAttrib, (EGLDisplay display, EGLConfig config, EGLint attribute, EGLint * value)) \ 32 X(EGLDisplay, eglGetDisplay, (NativeDisplayType native_display)) \ 33 X(EGLint, eglGetError, (void)) \ 34 X(EGLBoolean, eglInitialize, (EGLDisplay display, EGLint * major, EGLint * minor)) \ 35 X(EGLBoolean, eglTerminate, (EGLDisplay display)) \ 36 X(EGLBoolean, eglMakeCurrent, (EGLDisplay display, EGLSurface draw, EGLSurface read, EGLContext context)) \ 37 X(EGLBoolean, eglSwapBuffers, (EGLDisplay display, EGLSurface surface)) \ 38 X(EGLSurface, eglCreateWindowSurface, (EGLDisplay display, EGLConfig config, EGLNativeWindowType native_window, EGLint const* attrib_list)) \ 39 X(EGLBoolean, eglSwapInterval, (EGLDisplay display, EGLint interval)) \ 40 X(void, eglSetBlobCacheFuncsANDROID, (EGLDisplay display, EGLSetBlobFuncANDROID set, EGLGetBlobFuncANDROID get)) \ 41 X(EGLImage, eglCreateImageKHR, (EGLDisplay dpy, EGLContext ctx, EGLenum target, EGLClientBuffer buffer, const EGLint *attrib_list)) \ 42 X(EGLBoolean, eglDestroyImageKHR, (EGLDisplay dpy, EGLImage image)) \ 43 X(EGLImage, eglCreateImage, (EGLDisplay dpy, EGLContext ctx, EGLenum target, EGLClientBuffer buffer, const EGLint *attrib_list)) \ 44 X(EGLBoolean, eglDestroyImage, (EGLDisplay dpy, EGLImage image)) 45 46 // clang-format on