diff options
author | wm4 <wm4@nowhere> | 2015-02-20 21:56:55 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2015-02-20 21:56:55 +0100 |
commit | 1cac7d1a659faffd1514a3269edf9fcae4d357c1 (patch) | |
tree | feaa280fa28a416691f2fe2e0cd56f588746dcd1 /demux/demux.h | |
parent | 6aa6778ac46672dd237acc86856353d133917f06 (diff) | |
download | mpv-1cac7d1a659faffd1514a3269edf9fcae4d357c1.tar.bz2 mpv-1cac7d1a659faffd1514a3269edf9fcae4d357c1.tar.xz |
demux: add a demux_open_url() function
Often stream and a demuxer are opened at the same time. Provide a
function for this and replace most of its uses.
Diffstat (limited to 'demux/demux.h')
-rw-r--r-- | demux/demux.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/demux/demux.h b/demux/demux.h index b76fb8fedc..b6aa4af517 100644 --- a/demux/demux.h +++ b/demux/demux.h @@ -172,6 +172,7 @@ struct demuxer_params { int matroska_wanted_segment; bool *matroska_was_valid; bool expect_subtitle; + bool disable_cache; // demux_open_url() only }; typedef struct demuxer { @@ -259,6 +260,12 @@ struct sh_stream *new_sh_stream(struct demuxer *demuxer, enum stream_type type); struct demuxer *demux_open(struct stream *stream, struct demuxer_params *params, struct mpv_global *global); +struct mp_cancel; +struct demuxer *demux_open_url(const char *url, + struct demuxer_params *params, + struct mp_cancel *cancel, + struct mpv_global *global); + void demux_start_thread(struct demuxer *demuxer); void demux_stop_thread(struct demuxer *demuxer); void demux_set_wakeup_cb(struct demuxer *demuxer, void (*cb)(void *ctx), void *ctx); |