0
0
mirror of https://github.com/mpv-player/mpv.git synced 2024-09-20 12:02:23 +02:00
mpv/audio/decode
wm4 84cfe0d8b2 audio: flush remaining data from the filter chain on EOF
This can be reproduced with:

   mpv short.wav -af 'lavfi="aecho=0.8:0.9:5000|6800:0.3|0.25"'

An audio file that is just 1-2 seconds long should play for 8-9 seconds,
which audible echo towards the end.

The code assumes that when playing with AF_FILTER_FLAG_EOF, the filter
will either produce output, or has all remaining data flushed. I'm not
really sure whether this really works if there are multiple filters with
EOF handling in the chain. To handle it correctly, af_lavfi should retry
filtering if 1. EOF flag is set, 2. there were input samples, and 3. no
output samples were produced. But currently it seems to work well enough
anyway.
2013-12-05 00:31:55 +01:00
..
ad_lavc.c ad_lavc: handle decoder EAGAIN only if there was an input packet 2013-12-04 23:30:01 +01:00
ad_mpg123.c cosmetics: rename video/audio reset functions 2013-11-27 21:14:39 +01:00
ad_spdif.c av_common: add timebase parameter to mp_set_av_packet() 2013-12-04 23:12:51 +01:00
ad.h cosmetics: rename video/audio reset functions 2013-11-27 21:14:39 +01:00
dec_audio.c audio: flush remaining data from the filter chain on EOF 2013-12-05 00:31:55 +01:00
dec_audio.h cosmetics: rename video/audio reset functions 2013-11-27 21:14:39 +01:00