From a77a171b7ff436cb63b13321427a259a2a8c8fc7 Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 30 Oct 2014 22:46:25 +0100 Subject: demux_lavf: mark as seekable if protocol supports seeking by time Basically, this will mark the demuxer as seekable with rtmp* and mmsh protocols. These protocols have network-level time seeking, and whether you can seek on the byte level does not matter. Until now, seeking was typically only enabled because of the cache, and a (nonsensical) warning was shown accordingly. It still could happen that the server doesn't actually support thse requests (or simply rejects them), so this is somewhat imperfect. --- stream/stream_lavf.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'stream/stream_lavf.c') diff --git a/stream/stream_lavf.c b/stream/stream_lavf.c index 02f23284b3..76f2c8ee4e 100644 --- a/stream/stream_lavf.c +++ b/stream/stream_lavf.c @@ -117,6 +117,10 @@ static int control(stream_t *s, int cmd, void *arg) return 1; break; } + case STREAM_CTRL_HAS_AVSEEK: + if (avio->read_seek) + return 1; + break; case STREAM_CTRL_GET_METADATA: { *(struct mp_tags **)arg = read_icy(s); if (!*(struct mp_tags **)arg) -- cgit v1.2.3