From 2cbd4409786393458180cdce115cf8780fb2f083 Mon Sep 17 00:00:00 2001 From: pengquan1 Date: Tue, 18 Jan 2022 11:10:43 +0800 Subject: [PATCH] enable OH_Platform Signed-off-by: pengquan1 --- BUILD.gn | 2 +- api/EGL/eglplatform.h | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/BUILD.gn b/BUILD.gn index 8fe7d31..90808a8 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 99362a2..578791b 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 -- Gitee