diff options
author | Chia-I Wu <olv@lunarg.com> | 2010-10-11 16:09:52 +0800 |
---|---|---|
committer | Chia-I Wu <olvaffe@gmail.com> | 2010-12-09 20:01:35 -0500 |
commit | 13375514519e00fc6598b30055d7320553f8b676 (patch) | |
tree | 66eb4d7b02a8923a6052d26647b465aa2cdf11f6 | |
parent | 6719d59a85958712425ade241606a8d632f4357d (diff) |
android: Add _EGL_PLATFORM_ANDROID.
-rw-r--r-- | include/EGL/eglplatform.h | 9 | ||||
-rw-r--r-- | src/egl/main/egldisplay.c | 3 | ||||
-rw-r--r-- | src/egl/main/egldisplay.h | 1 |
3 files changed, 12 insertions, 1 deletions
diff --git a/include/EGL/eglplatform.h b/include/EGL/eglplatform.h index 33a3e5f889..22a263f522 100644 --- a/include/EGL/eglplatform.h +++ b/include/EGL/eglplatform.h @@ -78,6 +78,15 @@ typedef int EGLNativeDisplayType; typedef void *EGLNativeWindowType; typedef void *EGLNativePixmapType; +#elif defined(ANDROID) /* Android */ + +struct android_native_window_t; +struct egl_native_pixmap_t; + +typedef struct android_native_window_t* EGLNativeWindowType; +typedef struct egl_native_pixmap_t* EGLNativePixmapType; +typedef void* EGLNativeDisplayType; + #elif defined(__unix__) || defined(__unix) #ifdef MESA_EGL_NO_X11_HEADERS diff --git a/src/egl/main/egldisplay.c b/src/egl/main/egldisplay.c index 565e44d2d2..cabf1d40fe 100644 --- a/src/egl/main/egldisplay.c +++ b/src/egl/main/egldisplay.c @@ -28,7 +28,8 @@ _eglGetNativePlatformFromEnv(void) { _EGL_PLATFORM_WINDOWS, "gdi" }, { _EGL_PLATFORM_X11, "x11" }, { _EGL_PLATFORM_DRM, "drm" }, - { _EGL_PLATFORM_FBDEV, "fbdev" } + { _EGL_PLATFORM_FBDEV, "fbdev" }, + { _EGL_PLATFORM_ANDROID, "android" } }; _EGLPlatformType plat = _EGL_INVALID_PLATFORM; const char *plat_name; diff --git a/src/egl/main/egldisplay.h b/src/egl/main/egldisplay.h index bcba05480a..054c138c9e 100644 --- a/src/egl/main/egldisplay.h +++ b/src/egl/main/egldisplay.h @@ -13,6 +13,7 @@ enum _egl_platform_type { _EGL_PLATFORM_X11, _EGL_PLATFORM_DRM, _EGL_PLATFORM_FBDEV, + _EGL_PLATFORM_ANDROID, _EGL_NUM_PLATFORMS, _EGL_INVALID_PLATFORM = -1 |