summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/egl/common
diff options
context:
space:
mode:
authorChia-I Wu <[email protected]>2011-11-25 11:59:02 +0800
committerChia-I Wu <[email protected]>2011-11-25 12:34:33 +0800
commit75cc24c876059d6eb183e07ed802f997fb416864 (patch)
treed54eaf925a263684e7086a8671db540636e0660d /src/gallium/state_trackers/egl/common
parent42c2c371d6c4c82c3e9176e028281a91edfadafd (diff)
android: add support for ICS
With ICS (Android 4.0), several headers and structs are renamed. Define ANDROID_VERSION so that we can choose a different path depending on the platform version. I've tested only softpipe and llvmpipe. r600g is also reported to work.
Diffstat (limited to 'src/gallium/state_trackers/egl/common')
-rw-r--r--src/gallium/state_trackers/egl/common/egl_g3d_image.c4
-rw-r--r--src/gallium/state_trackers/egl/common/native_buffer.h4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/gallium/state_trackers/egl/common/egl_g3d_image.c b/src/gallium/state_trackers/egl/common/egl_g3d_image.c
index 4d90c400319..cf8ec98dbba 100644
--- a/src/gallium/state_trackers/egl/common/egl_g3d_image.c
+++ b/src/gallium/state_trackers/egl/common/egl_g3d_image.c
@@ -206,7 +206,7 @@ egl_g3d_reference_wl_buffer(_EGLDisplay *dpy, struct wl_buffer *buffer,
static struct pipe_resource *
egl_g3d_reference_android_native_buffer(_EGLDisplay *dpy,
- struct android_native_buffer_t *buf)
+ struct ANativeWindowBuffer *buf)
{
struct egl_g3d_display *gdpy = egl_g3d_display(dpy);
struct native_buffer nbuf;
@@ -260,7 +260,7 @@ egl_g3d_create_image(_EGLDriver *drv, _EGLDisplay *dpy, _EGLContext *ctx,
#ifdef EGL_ANDROID_image_native_buffer
case EGL_NATIVE_BUFFER_ANDROID:
ptex = egl_g3d_reference_android_native_buffer(dpy,
- (struct android_native_buffer_t *) buffer);
+ (struct ANativeWindowBuffer *) buffer);
break;
#endif
default:
diff --git a/src/gallium/state_trackers/egl/common/native_buffer.h b/src/gallium/state_trackers/egl/common/native_buffer.h
index 503ed580b05..eb161b11a3d 100644
--- a/src/gallium/state_trackers/egl/common/native_buffer.h
+++ b/src/gallium/state_trackers/egl/common/native_buffer.h
@@ -33,7 +33,7 @@
#include "pipe/p_state.h"
struct native_display;
-struct android_native_buffer_t;
+struct ANativeWindowBuffer;
enum native_buffer_type {
NATIVE_BUFFER_DRM,
@@ -53,7 +53,7 @@ struct native_buffer {
unsigned stride;
} drm;
- struct android_native_buffer_t *android; /**< opaque native buffer */
+ struct ANativeWindowBuffer *android; /**< opaque native buffer */
} u;
};