[Libva] [PATCH Libva-itnel-driver 4/4] Add the csc conversion from YV16 to NV12

Yuan, Feng feng.yuan at intel.com
Mon Mar 17 00:49:50 PDT 2014


Reviewed-by: Wind Yuan <feng.yuan at intel.com>
Tested-by: Wind Yuan <feng.yuan at intel.com>

>-----Original Message-----
>From: libva-bounces at lists.freedesktop.org
>[mailto:libva-bounces at lists.freedesktop.org] On Behalf Of Zhao Yakui
>Sent: Friday, March 14, 2014 3:21 PM
>To: libva at lists.freedesktop.org
>Subject: [Libva] [PATCH Libva-itnel-driver 4/4] Add the csc conversion from
>YV16 to NV12
>
>Signed-off-by: Zhao Yakui <yakui.zhao at intel.com>
>---
> src/gen8_post_processing.c |  2 ++
> src/i965_post_processing.c | 11 +++++++++--
> 2 files changed, 11 insertions(+), 2 deletions(-)
>
>diff --git a/src/gen8_post_processing.c b/src/gen8_post_processing.c index
>f34392c..8207e02 100644
>--- a/src/gen8_post_processing.c
>+++ b/src/gen8_post_processing.c
>@@ -496,8 +496,10 @@
>gen8_pp_set_media_rw_message_surface(VADriverContextP ctx, struct
>i965_post_proc
>     dri_bo *bo;
>     int fourcc = pp_get_surface_fourcc(ctx, surface);
>     const int U = (fourcc == VA_FOURCC('Y', 'V', '1', '2') ||
>+                   fourcc == VA_FOURCC('Y', 'V', '1', '6') ||
>                    fourcc == VA_FOURCC('I', 'M', 'C', '1')) ? 2 : 1;
>     const int V = (fourcc == VA_FOURCC('Y', 'V', '1', '2') ||
>+                   fourcc == VA_FOURCC('Y', 'V', '1', '6') ||
>                    fourcc == VA_FOURCC('I', 'M', 'C', '1')) ? 1 : 2;
>     int interleaved_uv = fourcc == VA_FOURCC('N', 'V', '1', '2');
>     int packed_yuv = (fourcc == VA_FOURCC('Y', 'U', 'Y', '2') || fourcc ==
>VA_FOURCC('U', 'Y', 'V', 'Y')); diff --git a/src/i965_post_processing.c
>b/src/i965_post_processing.c index 936c1a6..0f92f38 100755
>--- a/src/i965_post_processing.c
>+++ b/src/i965_post_processing.c
>@@ -1764,8 +1764,12 @@
>pp_set_media_rw_message_surface(VADriverContextP ctx, struct
>i965_post_processin
>     dri_bo *bo;
>     int fourcc = pp_get_surface_fourcc(ctx, surface);
>     const int Y = 0;
>-    const int U = fourcc == VA_FOURCC('Y', 'V', '1', '2') ? 2 : 1;
>-    const int V = fourcc == VA_FOURCC('Y', 'V', '1', '2') ? 1 : 2;
>+    const int U = ((fourcc == VA_FOURCC('Y', 'V', '1', '2')) ||
>+                   (fourcc == VA_FOURCC('Y', 'V', '1', '6')))
>+                   ? 2 : 1;
>+    const int V = ((fourcc == VA_FOURCC('Y', 'V', '1', '2')) ||
>+                   (fourcc == VA_FOURCC('Y', 'V', '1', '6')))
>+                   ? 1 : 2;
>     const int UV = 1;
>     int interleaved_uv = fourcc == VA_FOURCC('N', 'V', '1', '2');
>     int packed_yuv = (fourcc == VA_FOURCC('Y', 'U', 'Y', '2') || fourcc ==
>VA_FOURCC('U', 'Y', 'V', 'Y')); @@ -1875,8 +1879,10 @@
>gen7_pp_set_media_rw_message_surface(VADriverContextP ctx, struct
>i965_post_proc
>     dri_bo *bo;
>     int fourcc = pp_get_surface_fourcc(ctx, surface);
>     const int U = (fourcc == VA_FOURCC('Y', 'V', '1', '2') ||
>+                   fourcc == VA_FOURCC('V', 'V', '1', '6') ||
>                    fourcc == VA_FOURCC('I', 'M', 'C', '1')) ? 2 : 1;
>     const int V = (fourcc == VA_FOURCC('Y', 'V', '1', '2') ||
>+                   fourcc == VA_FOURCC('V', 'V', '1', '6') ||
>                    fourcc == VA_FOURCC('I', 'M', 'C', '1')) ? 1 : 2;
>     int interleaved_uv = fourcc == VA_FOURCC('N', 'V', '1', '2');
>     int packed_yuv = (fourcc == VA_FOURCC('Y', 'U', 'Y', '2') || fourcc ==
>VA_FOURCC('U', 'Y', 'V', 'Y')); @@ -5230,6 +5236,7 @@
>i965_image_processing(VADriverContextP ctx,
>         case VA_FOURCC('4', '2', '2', 'V'):
>         case VA_FOURCC('4', '1', '1', 'P'):
>         case VA_FOURCC('4', '4', '4', 'P'):
>+        case VA_FOURCC('Y', 'V', '1', '6'):
>             status = i965_image_pl3_processing(ctx,
>                                                src_surface,
>                                                src_rect,
>--
>1.8.2-rc2
>
>_______________________________________________
>Libva mailing list
>Libva at lists.freedesktop.org
>http://lists.freedesktop.org/mailman/listinfo/libva


More information about the Libva mailing list