[FFmpeg-cvslog] avfilter/af_afftdn: request new frames only when needed
Paul B Mahol
git at videolan.org
Mon May 9 23:21:18 EEST 2022
ffmpeg | branch: master | Paul B Mahol <onemda at gmail.com> | Sun May 1 14:13:29 2022 +0200| [fe57904a71fde486237595c47ba8fee072c4aa5c] | committer: Paul B Mahol
avfilter/af_afftdn: request new frames only when needed
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=fe57904a71fde486237595c47ba8fee072c4aa5c
---
libavfilter/af_afftdn.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/libavfilter/af_afftdn.c b/libavfilter/af_afftdn.c
index 1b6487a102..cdb256fa10 100644
--- a/libavfilter/af_afftdn.c
+++ b/libavfilter/af_afftdn.c
@@ -1154,6 +1154,11 @@ static int activate(AVFilterContext *ctx)
if (ret > 0)
return output_frame(inlink, in);
+ if (ff_inlink_queued_samples(inlink) >= s->sample_advance) {
+ ff_filter_set_ready(ctx, 10);
+ return 0;
+ }
+
FF_FILTER_FORWARD_STATUS(inlink, outlink);
FF_FILTER_FORWARD_WANTED(outlink, inlink);
More information about the ffmpeg-cvslog
mailing list