1 /*
2  * Copyright (c) 2024 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 #ifndef EGL_FUNCTIONS_H
16 #define EGL_FUNCTIONS_H
17 #if RENDER_HAS_GLES_BACKEND
18 #ifndef declare
19 // clang-format off
20 #include <EGL/egl.h>
21 #include <EGL/eglext.h>
22 // clang-format on
23 #define declare(a, b) extern a b;
24 #endif
25 
26 #ifdef EGL_ANDROID_get_native_client_buffer
27 declare(PFNEGLGETNATIVECLIENTBUFFERANDROIDPROC, eglGetNativeClientBufferANDROID);
28 #endif
29 
30 #ifdef EGL_KHR_image_base
31 declare(PFNEGLCREATEIMAGEKHRPROC, eglCreateImageKHR);
32 declare(PFNEGLDESTROYIMAGEKHRPROC, eglDestroyImageKHR);
33 #endif
34 
35 #endif // RENDER_HAS_GLES_BACKEND
36 #undef declare
37 #endif  // EGL_FUNCTIONS_H