diff options
author | wm4 <wm4@nowhere> | 2016-06-08 11:49:56 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2016-06-08 12:02:06 +0200 |
commit | aeb3df0e2c7f8e86f7b550f876dc24ae1c4686f6 (patch) | |
tree | d75bbdc1ad1b3e2c406710af3cfe6e65c78187d8 /demux | |
parent | 9c286d747287eba71c194e7cb063fdc314d488a1 (diff) | |
download | mpv-aeb3df0e2c7f8e86f7b550f876dc24ae1c4686f6.tar.bz2 mpv-aeb3df0e2c7f8e86f7b550f876dc24ae1c4686f6.tar.xz |
demux_lavf: assume fully read files (subtitles) are always seekable
Since the libavformat API is crap, we have to apply tons of heuristics
to check whether seeking will work. (No, checking it at seek time isn't
going to work either, because if a seek fails, the demuxer will be in an
undefined state. Because the libavformat API is crap.)
Diffstat (limited to 'demux')
-rw-r--r-- | demux/demux_lavf.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/demux/demux_lavf.c b/demux/demux_lavf.c index ea0c15ec6a..a6f51dc5f3 100644 --- a/demux/demux_lavf.c +++ b/demux/demux_lavf.c @@ -795,6 +795,7 @@ static int demux_open_lavf(demuxer_t *demuxer, enum demux_check check) avfc->pb = priv->pb; if (stream_control(priv->stream, STREAM_CTRL_HAS_AVSEEK, NULL) > 0) demuxer->seekable = true; + demuxer->seekable |= priv->format_hack.fully_read; } if (matches_avinputformat_name(priv, "rtsp")) { |