diff --git a/BUILD.gn b/BUILD.gn index 8fe7d319d6a311356c0514a48a9c9119514388a0..90808a840df5adf404ab7065954e9353522070b2 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -15,7 +15,7 @@ config("libEGL_public_config") { include_dirs = [ "api" ] defines = [ "ENABLE_EGL", - "EGL_NO_X11", + "OHOS_PLATFORM", ] } diff --git a/api/EGL/eglplatform.h b/api/EGL/eglplatform.h index 99362a23deeace9de3f9fb80f63995c175d4d472..578791b9aa1457cb402d080b96c409e13d1999e0 100644 --- a/api/EGL/eglplatform.h +++ b/api/EGL/eglplatform.h @@ -54,6 +54,14 @@ typedef void *EGLNativeDisplayType; typedef void *EGLNativePixmapType; typedef void *EGLNativeWindowType; +#elif defined(OHOS_PLATFORM) + +struct NativeWindow; + +typedef void* EGLNativeDisplayType; +typedef void* EGLNativePixmapType; +typedef struct NativeWindow* EGLNativeWindowType; + #elif defined(_WIN32) || defined(__VC32__) && !defined(__CYGWIN__) && !defined(__SCITECH_SNAP__) /* Win32 and WinCE */ #ifndef WIN32_LEAN_AND_MEAN #define WIN32_LEAN_AND_MEAN 1