diff options
author | Kasireddy, Vivek <[email protected]> | 2019-02-12 17:03:52 -0800 |
---|---|---|
committer | Lionel Landwerlin <[email protected]> | 2019-02-26 13:08:52 +0000 |
commit | 7cab8d3661f243c47874fa7e6ad30af7bd4a53d8 (patch) | |
tree | 2ec6bd221a13c2f8f35af3884974bb3331c80611 /src/mesa/drivers | |
parent | 65600d0946193b786c3fa780c7e72c9dc0a49186 (diff) |
i965: Add support for sampling from XYUV images
Add support to the i965 DRI driver to sample from XYUV8888 buffers.
Signed-off-by: Vivek Kasireddy <[email protected]>
Reviewed-by: Lionel Landwerlin <[email protected]>
Reviewed-by: Tapani Pälli <[email protected]>
Reviewed-by: Eric Engestrom <[email protected]>
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_wm.c | 6 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/intel_screen.c | 3 |
2 files changed, 9 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_wm.c b/src/mesa/drivers/dri/i965/brw_wm.c index 3cd8f18e794..47905ca5549 100644 --- a/src/mesa/drivers/dri/i965/brw_wm.c +++ b/src/mesa/drivers/dri/i965/brw_wm.c @@ -270,6 +270,9 @@ brw_debug_recompile_sampler_key(struct brw_context *brw, found |= key_debug(brw, "ayuv image bound", old_key->ayuv_image_mask, key->ayuv_image_mask); + found |= key_debug(brw, "xyuv image bound", + old_key->xyuv_image_mask, + key->xyuv_image_mask); for (unsigned int i = 0; i < MAX_SAMPLERS; i++) { found |= key_debug(brw, "textureGather workarounds", @@ -432,6 +435,9 @@ brw_populate_sampler_prog_key_data(struct gl_context *ctx, case __DRI_IMAGE_COMPONENTS_AYUV: key->ayuv_image_mask |= 1 << s; break; + case __DRI_IMAGE_COMPONENTS_XYUV: + key->xyuv_image_mask |= 1 << s; + break; default: break; } diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri/i965/intel_screen.c index 5041acd9a71..d34b161f41e 100644 --- a/src/mesa/drivers/dri/i965/intel_screen.c +++ b/src/mesa/drivers/dri/i965/intel_screen.c @@ -302,6 +302,9 @@ static const struct intel_image_format intel_image_formats[] = { { __DRI_IMAGE_FOURCC_AYUV, __DRI_IMAGE_COMPONENTS_AYUV, 1, { { 0, 0, 0, __DRI_IMAGE_FORMAT_ABGR8888, 4 } } }, + { __DRI_IMAGE_FOURCC_XYUV8888, __DRI_IMAGE_COMPONENTS_XYUV, 1, + { { 0, 0, 0, __DRI_IMAGE_FORMAT_XBGR8888, 4 } } }, + /* For YUYV and UYVY buffers, we set up two overlapping DRI images * and treat them as planar buffers in the compositors. * Plane 0 is GR88 and samples YU or YV pairs and places Y into |