diff options
author | Anton Khirnov <[email protected]> | 2022-10-11 10:47:42 +0200 |
---|---|---|
committer | Anton Khirnov <[email protected]> | 2022-10-13 10:19:13 +0200 |
commit | d1526f4dacca42a5065b140d2e0058017e0e0049 (patch) | |
tree | 098cece5f6559835158dad52af8b657cc1b2a0c2 | |
parent | 4b2f380e0a3b3abc30e41ecf87d6270b616a8f7c (diff) |
lavfi/vf_deinterlace_qsv: set output frame durations
-rw-r--r-- | libavfilter/vf_deinterlace_qsv.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libavfilter/vf_deinterlace_qsv.c b/libavfilter/vf_deinterlace_qsv.c index 3065d6ac95..98ed7283ad 100644 --- a/libavfilter/vf_deinterlace_qsv.c +++ b/libavfilter/vf_deinterlace_qsv.c @@ -516,6 +516,11 @@ static int process_frame(AVFilterContext *ctx, const AVFrame *in, out->pts++; s->last_pts = out->pts; + if (outlink->frame_rate.num && outlink->frame_rate.den) + out->duration = av_rescale_q(1, av_inv_q(outlink->frame_rate), outlink->time_base); + else + out->duration = 0; + ret = ff_filter_frame(outlink, out); if (ret < 0) return ret; |