Am So., 5. Apr. 2020 um 01:02 Uhr schrieb Carl Eugen Hoyos <ceffm...@gmail.com>: > > Am Sa., 4. Apr. 2020 um 00:44 Uhr schrieb Carl Eugen Hoyos > <ceffm...@gmail.com>: > > > > Am Sa., 4. Apr. 2020 um 00:40 Uhr schrieb James Almer <jamr...@gmail.com>: > > > > > > On 4/3/2020 6:37 PM, Carl Eugen Hoyos wrote: > > > > Am Fr., 3. Apr. 2020 um 23:19 Uhr schrieb Carl Eugen Hoyos > > > > <ceffm...@gmail.com>: > > > > > > > >> Attached patch marks actually telecined frames as interlaced, > > > >> other frames as progressive. > > > > > > > > New patch with changes to fate attached. > > > > > > > > Please comment, Carl Eugen > > > > > > Those yadif tests look wrong. The patch shouldn't affect them. > > > > Clearly, thank you! > > > > New patch attached, it should now only change the telecined > > frames and leave the other frames as they are, the setfield > > filter can be used to force a progressive setting for them. > > New patch attached that also sets top_field_first
Which had the effect that fate is correct again, new patch attached. Please comment, Carl Eugen
From cd2f7b4336c1d0b786ba613d525830ff152788a3 Mon Sep 17 00:00:00 2001 From: Carl Eugen Hoyos <ceffm...@gmail.com> Date: Sun, 5 Apr 2020 01:00:44 +0200 Subject: [PATCH] lavfi/telecine: Mark telecined frames as interlaced. --- libavfilter/vf_telecine.c | 8 ++++++++ tests/ref/fate/filter-pixfmts-fieldmatch | 10 +++++----- tests/ref/fate/filter-pixfmts-pullup | 24 ++++++++++++------------ 3 files changed, 25 insertions(+), 17 deletions(-) diff --git a/libavfilter/vf_telecine.c b/libavfilter/vf_telecine.c index 62599a7a3a..ff8151dfc9 100644 --- a/libavfilter/vf_telecine.c +++ b/libavfilter/vf_telecine.c @@ -207,6 +207,8 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *inpicref) s->stride[i], (s->planeheight[i] - !s->first_field + 1) / 2); } + s->frame[nout]->interlaced_frame = 1; + s->frame[nout]->top_field_first = !s->first_field; nout++; len--; s->occupied = 0; @@ -220,6 +222,8 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *inpicref) inpicref->data[i], inpicref->linesize[i], s->stride[i], s->planeheight[i]); + s->frame[nout]->interlaced_frame = inpicref->interlaced_frame; + s->frame[nout]->top_field_first = inpicref->top_field_first; nout++; len -= 2; } @@ -236,6 +240,8 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *inpicref) for (i = 0; i < nout; i++) { AVFrame *frame = av_frame_clone(s->frame[i]); + int interlaced = frame->interlaced_frame; + int tff = frame->top_field_first; if (!frame) { av_frame_free(&inpicref); @@ -243,6 +249,8 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *inpicref) } av_frame_copy_props(frame, inpicref); + frame->interlaced_frame = interlaced; + frame->top_field_first = tff; frame->pts = ((s->start_time == AV_NOPTS_VALUE) ? 0 : s->start_time) + av_rescale(outlink->frame_count_in, s->ts_unit.num, s->ts_unit.den); -- 2.24.1
_______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".