avfilter/vf_pullup: do not ignore frame field order
authorPaul B Mahol <onemda@gmail.com>
Wed, 2 Oct 2013 21:13:54 +0000 (21:13 +0000)
committerPaul B Mahol <onemda@gmail.com>
Thu, 3 Oct 2013 02:43:20 +0000 (02:43 +0000)
Signed-off-by: Paul B Mahol <onemda@gmail.com>
libavfilter/vf_pullup.c

index a47f339..4ad441f 100644 (file)
@@ -657,7 +657,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in)
                   (const uint8_t**)in->data, in->linesize,
                   inlink->format, inlink->w, inlink->h);
 
-    p = !!in->interlaced_frame;
+    p = in->interlaced_frame ? !in->top_field_first : 0;
     pullup_submit_field(s, b, p  );
     pullup_submit_field(s, b, p^1);