mpv/audio
wm4 9c2858f37f ad_lavc: deal with arbitrary decoder delay
Normally, audio decoder don't have a decoder delay, so the code was
fine. But FFmpeg supports multithreaded decoding for some audio codecs,
which introduces such a delay.

The delay means that we won't get decoded audio for the first few
packets, and that we need to do something to get the trailing audio
still buffered in the decoder when reaching EOF.

Two changes are needed to deal with the delay:
- If EOF is reached, pass a "flush" packet to the decoder to return the
  buffered audio. Such a flush packet is automatically setup when
  calling mp_set_av_packet() with a NULL packet.
- Use the PTS returned by the decoder, instead of the packet's. This is
  important to get correct timestamps for decoded audio. Ignoring this
  would result into offsetting the audio playback time by the decoder
  delay. Note that we can still use the timestamp of the first packet
  to get the timestamp for the start of the audio.
2013-12-04 23:12:51 +01:00
..
decode ad_lavc: deal with arbitrary decoder delay 2013-12-04 23:12:51 +01:00
filter options: add options that set defaults for af/vf/ao/vo 2013-12-01 00:12:10 +01:00
out ao_oss: when falling back from unknown prefer larger format 2013-12-04 00:07:40 +01:00
audio.c audio: better rejection of invalid formats 2013-11-27 00:16:05 +01:00
audio.h audio: better rejection of invalid formats 2013-11-27 00:16:05 +01:00
audio_buffer.c audio: add mp_audio_buffer 2013-11-12 23:28:21 +01:00
audio_buffer.h audio: add mp_audio_buffer 2013-11-12 23:28:21 +01:00
chmap.c core: move contents to mpvcore (2/2) 2013-08-06 22:52:31 +02:00
chmap.h core: move contents to mpvcore (2/2) 2013-08-06 22:52:31 +02:00
chmap_sel.c ao_jack: allow more control about channel layouts 2013-07-07 18:37:55 +02:00
chmap_sel.h audio: add channel map selection function 2013-05-12 21:24:57 +02:00
fmt-conversion.c audio: drop "_NE"/"ne" suffix from audio formats 2013-11-15 21:25:05 +01:00
fmt-conversion.h ad_lavc: use fmt-conversion to map sample formats 2013-04-13 04:21:27 +02:00
format.c audio/format: add heuristic to estimate loss on format conversion 2013-11-16 21:46:17 +01:00
format.h audio/format: add heuristic to estimate loss on format conversion 2013-11-16 21:46:17 +01:00
mixer.c audio/filter: remove unneeded AF_CONTROLs, convert to enum 2013-11-18 14:21:01 +01:00
mixer.h command: don't allow changing volume if no audio initialized 2013-10-12 18:57:02 +02:00
reorder_ch.c ao_lavc: support non-interleaved audio 2013-11-13 20:10:17 +01:00
reorder_ch.h ao_lavc: support non-interleaved audio 2013-11-13 20:10:17 +01:00