summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXiang, Haihao <haihao.xiang@intel.com>2013-09-22 13:03:42 +0800
committerXiang, Haihao <haihao.xiang@intel.com>2013-09-23 15:02:22 +0800
commit6eeca792ef619ea4f5175256d297c3ea343d78ba (patch)
treef586bee2c740a2ff5b3c9de6ec032c119f1407b1
parent53697bc0fad0a048999b28ea7c8c40a291f9ab2d (diff)
VPP: fix the check for DI filter flags on SNB/IVB
Signed-off-by: Xiang, Haihao <haihao.xiang@intel.com> (cherry picked from commit ea3c725a7f9fa66e7ef05e1c08af30c28f8c1aa0)
-rwxr-xr-xsrc/i965_post_processing.c20
1 files changed, 6 insertions, 14 deletions
diff --git a/src/i965_post_processing.c b/src/i965_post_processing.c
index e1b6032..536eb64 100755
--- a/src/i965_post_processing.c
+++ b/src/i965_post_processing.c
@@ -3215,14 +3215,10 @@ pp_nv12_dndi_initialize(VADriverContextP ctx, struct i965_post_processing_contex
int dndi_top_first = 1;
VAProcFilterParameterBufferDeinterlacing *di_filter_param = (VAProcFilterParameterBufferDeinterlacing *)filter_param;
- if (di_filter_param->flags == I965_SURFACE_FLAG_FRAME)
- return VA_STATUS_ERROR_FLAG_NOT_SUPPORTED;
-
- if (di_filter_param->flags == I965_SURFACE_FLAG_TOP_FIELD_FIRST) {
- dndi_top_first = 1;
- } else {
+ if (di_filter_param->flags & VA_DEINTERLACING_BOTTOM_FIELD_FIRST)
dndi_top_first = 0;
- }
+ else
+ dndi_top_first = 1;
/* surface */
obj_surface = (struct object_surface *)src_surface->base;
@@ -3621,14 +3617,10 @@ gen7_pp_nv12_dndi_initialize(VADriverContextP ctx, struct i965_post_processing_c
VAProcFilterParameterBufferDeinterlacing *di_filter_param = (VAProcFilterParameterBufferDeinterlacing *)filter_param;
int is_first_frame = (pp_dndi_context->frame_order == -1);
- if (di_filter_param->flags == I965_SURFACE_FLAG_FRAME)
- return VA_STATUS_ERROR_FLAG_NOT_SUPPORTED;
-
- if (di_filter_param->flags == I965_SURFACE_FLAG_TOP_FIELD_FIRST) {
- dndi_top_first = 1;
- } else {
+ if (di_filter_param->flags & VA_DEINTERLACING_BOTTOM_FIELD_FIRST)
dndi_top_first = 0;
- }
+ else
+ dndi_top_first = 1;
/* surface */
current_in_obj_surface = (struct object_surface *)src_surface->base;