mpv/options
wm4 1301a90761 demux: add a demuxer thread
This adds a thread to the demuxer which reads packets asynchronously.
It will do so until a configurable minimum packet queue size is
reached. (See options.rst additions.)

For now, the thread is disabled by default. There are some corner cases
that have to be fixed, such as fixing cache behavior with webradios.

Note that most interaction with the demuxer is still blocking, so if
e.g. network dies, the player will still freeze. But this change will
make it possible to remove most causes for freezing.

Most of the new code in demux.c actually consists of weird caches to
compensate for thread-safety issues (with the previously single-threaded
design), or to avoid blocking by having to wait on the demuxer thread.

Most of the changes in the player are due to the fact that we must not
access the source stream directly. the demuxer thread already accesses
it, and the stream stuff is not thread-safe.

For timeline stuff (like ordered chapters), we enable the thread for the
current segment only. We also clear its packet queue on seek, so that
the remaining (unconsumed) readahead buffer doesn't waste memory.

Keep in mind that insane subtitles (such as ASS typesetting muxed into
mkv files) will practically disable the readahead, because the total
queue size is considered when checking whether the minimum queue size
was reached.
2014-07-16 23:25:56 +02:00
..
m_config.c build: include <strings.h> for strcasecmp() 2014-07-10 08:29:32 +02:00
m_config.h options: remove a global variable 2014-06-11 00:39:14 +02:00
m_option.c Audit and replace all ctype.h uses 2014-07-01 23:11:08 +02:00
m_option.h options: support setting start time relative to start PTS 2014-06-29 20:39:49 +02:00
m_property.c command: redo the property type 2014-06-13 02:11:39 +02:00
m_property.h command: redo the property type 2014-06-13 02:11:39 +02:00
options.c demux: add a demuxer thread 2014-07-16 23:25:56 +02:00
options.h demux: add a demuxer thread 2014-07-16 23:25:56 +02:00
parse_commandline.c options: fix "-" (stdin) input 2014-05-06 01:06:07 +02:00
parse_commandline.h
parse_configfile.c config: adjust config parser messages 2014-07-13 20:11:46 +02:00
parse_configfile.h encode: don't apply default config options 2014-04-19 22:05:17 +02:00
path.c config: use the same signature for win32/OSX specific path functions 2014-06-26 19:56:45 +02:00
path.h Basic xdg directory implementation 2014-06-26 19:37:25 +02:00