summaryrefslogtreecommitdiffstats
path: root/src/egl/main/eglimage.c
diff options
context:
space:
mode:
authorChia-I Wu <[email protected]>2010-10-22 17:09:40 +0800
committerChia-I Wu <[email protected]>2010-10-22 18:35:09 +0800
commit5664a983867038de48e71b65df89e0e254085af2 (patch)
tree4c3fa8187bc199b83fe8485cfd33d86ee84a1675 /src/egl/main/eglimage.c
parent713c8734f45b51b3758ecc95b96cf7b5aecacec8 (diff)
egl: Parse image attributes with _eglParseImageAttribList.
Avoid code duplications.
Diffstat (limited to 'src/egl/main/eglimage.c')
-rw-r--r--src/egl/main/eglimage.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/egl/main/eglimage.c b/src/egl/main/eglimage.c
index e11a1836ff6..8244ef3b518 100644
--- a/src/egl/main/eglimage.c
+++ b/src/egl/main/eglimage.c
@@ -45,6 +45,24 @@ _eglParseImageAttribList(_EGLImageAttribs *attrs, _EGLDisplay *dpy,
case EGL_GL_TEXTURE_ZOFFSET_KHR:
attrs->GLTextureZOffset = val;
break;
+
+ /* EGL_MESA_drm_image */
+ case EGL_WIDTH:
+ attrs->Width = val;
+ break;
+ case EGL_HEIGHT:
+ attrs->Height = val;
+ break;
+ case EGL_DRM_BUFFER_FORMAT_MESA:
+ attrs->DRMBufferFormatMESA = val;
+ break;
+ case EGL_DRM_BUFFER_USE_MESA:
+ attrs->DRMBufferUseMESA = val;
+ break;
+ case EGL_DRM_BUFFER_STRIDE_MESA:
+ attrs->DRMBufferStrideMESA = val;
+ break;
+
default:
/* unknown attrs are ignored */
break;