diff options
author | Jamie Gennis <jgennis@google.com> | 2011-07-11 15:47:20 -0700 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2011-07-11 15:47:20 -0700 |
commit | 0d0c5a6d6b434d3d7890f4bd9eca90084ba4e780 (patch) | |
tree | 416aca922fdb9538362db4d73b43d7b4b046da7f /opengl | |
parent | ed8a338c0bfd8f8d4b3f42110d6775c02eafa210 (diff) | |
parent | bee205fd58a27c10a0895de5339e76025d429d2b (diff) | |
download | frameworks_native-0d0c5a6d6b434d3d7890f4bd9eca90084ba4e780.zip frameworks_native-0d0c5a6d6b434d3d7890f4bd9eca90084ba4e780.tar.gz frameworks_native-0d0c5a6d6b434d3d7890f4bd9eca90084ba4e780.tar.bz2 |
Merge "EGL: fix the ANativeWindow size/fmt override"
Diffstat (limited to 'opengl')
-rw-r--r-- | opengl/libs/EGL/eglApi.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/opengl/libs/EGL/eglApi.cpp b/opengl/libs/EGL/eglApi.cpp index 7d5d010..ba5d29a 100644 --- a/opengl/libs/EGL/eglApi.cpp +++ b/opengl/libs/EGL/eglApi.cpp @@ -367,7 +367,12 @@ EGLSurface eglCreateWindowSurface( EGLDisplay dpy, EGLConfig config, if (cnx->egl.eglGetConfigAttrib(iDpy, iConfig, EGL_NATIVE_VISUAL_ID, &format)) { if (format != 0) { - native_window_set_buffers_geometry(window, 0, 0, format); + int err = native_window_set_buffers_format(window, format); + if (err != 0) { + LOGE("error setting native window pixel format: %s (%d)", + strerror(-err), err); + return setError(EGL_BAD_NATIVE_WINDOW, EGL_NO_SURFACE); + } } } |