diff options
author | wm4 <wm4@nowhere> | 2013-07-11 21:10:42 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2013-07-12 21:56:40 +0200 |
commit | 52c3eb69765a0d1070bf240353095c8ff546765b (patch) | |
tree | db654a9798f4941dbc3b57c8569fcdeb0b21d24a /stream/stream.h | |
parent | d17d2fdc7c536821b3fea8c4a37c0ad09fc487db (diff) | |
download | mpv-52c3eb69765a0d1070bf240353095c8ff546765b.tar.bz2 mpv-52c3eb69765a0d1070bf240353095c8ff546765b.tar.xz |
core: change open_stream and demux_open signature
This removes the dependency on DEMUXER_TYPE_* and the file_format
parameter from the stream open functions.
Remove some of the playlist handling code. It looks like this was
needed only for loading linked mov files with demux_mov (which was
removed long ago).
Delete a minor bit of dead network-related code from stream.c as well.
Diffstat (limited to 'stream/stream.h')
-rw-r--r-- | stream/stream.h | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/stream/stream.h b/stream/stream.h index 149618ccd6..0d7e02ed4d 100644 --- a/stream/stream.h +++ b/stream/stream.h @@ -70,7 +70,6 @@ #define MP_STREAM_SEEK_FW 4 #define MP_STREAM_SEEK (MP_STREAM_SEEK_BW | MP_STREAM_SEEK_FW) -#define STREAM_REDIRECTED -2 #define STREAM_UNSUPPORTED -1 #define STREAM_ERROR 0 #define STREAM_OK 1 @@ -121,7 +120,7 @@ typedef struct stream_info_st { const char *author; const char *comment; // opts is set from ->opts - int (*open)(struct stream *st, int mode, void *opts, int *file_format); + int (*open)(struct stream *st, int mode, void *opts); const char *protocols[MAX_STREAM_PROTOCOLS]; const void *opts; int opts_url; /* If this is 1 we will parse the url as an option string @@ -158,6 +157,7 @@ typedef struct stream { void *priv; // used for DVD, TV, RTSP etc char *url; // strdup() of filename/url char *mime_type; // when HTTP streaming is used + char *demuxer; // request demuxer to be used char *lavf_type; // name of expected demuxer type for lavf struct MPOpts *opts; @@ -278,8 +278,7 @@ struct bstr stream_read_complete(struct stream *s, void *talloc_ctx, int stream_control(stream_t *s, int cmd, void *arg); void stream_update_size(stream_t *s); void free_stream(stream_t *s); -stream_t *open_stream(const char *filename, struct MPOpts *options, - int *file_format); +struct stream *stream_open(const char *filename, struct MPOpts *options); stream_t *open_output_stream(const char *filename, struct MPOpts *options); stream_t *open_memory_stream(void *data, int len); struct demux_stream; |