diff options
author | Rainer Hochecker <[email protected]> | 2017-01-05 16:58:56 +0100 |
---|---|---|
committer | Ben Widawsky <[email protected]> | 2017-01-23 08:47:15 -0800 |
commit | 09b140abb532dede5de6b03b1cc3c03852c1c9e9 (patch) | |
tree | 8c0aa7210fba34a1a3a07581364dd8ef54df6dd0 /src/mesa/drivers/dri/common | |
parent | 1338d912f52b69f76ef75d1ad313893db77d4da8 (diff) |
dri: allow 16bit R/GR images to be exported via drm buffers
This allows eglCreateImageKHR to access P010 surfaces created by vaapi
Signed-off-by: Rainer Hochecker <[email protected]>
Acked-by: Ben Widawky <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/common')
-rw-r--r-- | src/mesa/drivers/dri/common/dri_util.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c index 209a42ab243..f92eee9081d 100644 --- a/src/mesa/drivers/dri/common/dri_util.c +++ b/src/mesa/drivers/dri/common/dri_util.c @@ -881,8 +881,12 @@ driImageFormatToGLFormat(uint32_t image_format) return MESA_FORMAT_R8G8B8X8_UNORM; case __DRI_IMAGE_FORMAT_R8: return MESA_FORMAT_R_UNORM8; + case __DRI_IMAGE_FORMAT_R16: + return MESA_FORMAT_R_UNORM16; case __DRI_IMAGE_FORMAT_GR88: return MESA_FORMAT_R8G8_UNORM; + case __DRI_IMAGE_FORMAT_GR1616: + return MESA_FORMAT_R16G16_UNORM; case __DRI_IMAGE_FORMAT_SARGB8: return MESA_FORMAT_B8G8R8A8_SRGB; case __DRI_IMAGE_FORMAT_NONE: |