avfilter/af_surround: request new frames only when needed
ffmpeg | branch: master | Paul B Mahol <onemda@gmail.com> | Sat Apr 30 15:36:39 2022 +0200| [a9e9020ff6eb92fb36b35a53c27719aeedfc6a8a] | committer: Paul B Mahol avfilter/af_surround: request new frames only when needed
http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=a9e9020ff6eb92fb36...
libavfilter/af_surround.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/libavfilter/af_surround.c b/libavfilter/af_surround.c index 4599dd1601..858fed609a 100644 --- a/libavfilter/af_surround.c +++ b/libavfilter/af_surround.c @@ -1633,6 +1633,11 @@ static int activate(AVFilterContext *ctx) if (ret < 0) return ret; + if (ff_inlink_queued_samples(inlink) >= s->hop_size) { + ff_filter_set_ready(ctx, 10); + return 0; + } + if (ff_inlink_acknowledge_status(inlink, &status, &pts)) { ff_outlink_set_status(outlink, status, pts); return 0;
participants (1)
-
Paul B Mahol