diff options
Diffstat (limited to 'stream')
-rw-r--r-- | stream/cache.c | 6 | ||||
-rw-r--r-- | stream/stream.c | 5 | ||||
-rw-r--r-- | stream/stream.h | 5 | ||||
-rw-r--r-- | stream/stream_bluray.c | 3 | ||||
-rw-r--r-- | stream/stream_cdda.c | 3 | ||||
-rw-r--r-- | stream/stream_dvd.c | 4 | ||||
-rw-r--r-- | stream/stream_dvdnav.c | 4 | ||||
-rw-r--r-- | stream/tv.c | 1 |
8 files changed, 7 insertions, 24 deletions
diff --git a/stream/cache.c b/stream/cache.c index 3523f04704..f96cdef0e7 100644 --- a/stream/cache.c +++ b/stream/cache.c @@ -112,7 +112,6 @@ struct priv { double stream_time_length; double stream_start_time; int64_t stream_size; - bool stream_manages_timeline; unsigned int stream_num_chapters; int stream_cache_idle; int stream_cache_fill; @@ -381,9 +380,6 @@ static void update_cached_controls(struct priv *s) s->stream_start_time = MP_NOPTS_VALUE; if (stream_control(s->stream, STREAM_CTRL_GET_START_TIME, &d) == STREAM_OK) s->stream_start_time = d; - s->stream_manages_timeline = false; - if (stream_control(s->stream, STREAM_CTRL_MANAGES_TIMELINE, NULL) == STREAM_OK) - s->stream_manages_timeline = true; s->stream_num_chapters = 0; if (stream_control(s->stream, STREAM_CTRL_GET_NUM_CHAPTERS, &ui) == STREAM_OK) s->stream_num_chapters = ui; @@ -428,8 +424,6 @@ static int cache_get_cached_control(stream_t *cache, int cmd, void *arg) return STREAM_UNSUPPORTED; *(int64_t *)arg = s->stream_size; return STREAM_OK; - case STREAM_CTRL_MANAGES_TIMELINE: - return s->stream_manages_timeline ? STREAM_OK : STREAM_UNSUPPORTED; case STREAM_CTRL_GET_NUM_CHAPTERS: *(unsigned int *)arg = s->stream_num_chapters; return STREAM_OK; diff --git a/stream/stream.c b/stream/stream.c index 31d15fbf97..d2ab3d640a 100644 --- a/stream/stream.c +++ b/stream/stream.c @@ -968,11 +968,6 @@ struct bstr stream_read_complete(struct stream *s, void *talloc_ctx, return (struct bstr){buf, total_read}; } -bool stream_manages_timeline(struct stream *s) -{ - return stream_control(s, STREAM_CTRL_MANAGES_TIMELINE, NULL) == STREAM_OK; -} - void stream_print_proto_list(struct mp_log *log) { int count = 0; diff --git a/stream/stream.h b/stream/stream.h index 389a0a56e8..f2663f3435 100644 --- a/stream/stream.h +++ b/stream/stream.h @@ -39,6 +39,7 @@ enum streamtype { STREAMTYPE_MF, STREAMTYPE_EDL, STREAMTYPE_AVDEVICE, + STREAMTYPE_CDDA, }; #define STREAM_BUFFER_SIZE 2048 @@ -80,8 +81,6 @@ enum stream_ctrl { STREAM_CTRL_GET_CACHE_IDLE, STREAM_CTRL_RESUME_CACHE, STREAM_CTRL_RECONNECT, - // DVD/Bluray, signal general support for GET_CURRENT_TIME etc. - STREAM_CTRL_MANAGES_TIMELINE, STREAM_CTRL_GET_START_TIME, STREAM_CTRL_GET_CHAPTER_TIME, STREAM_CTRL_GET_DVD_INFO, @@ -243,8 +242,6 @@ stream_t *open_memory_stream(void *data, int len); bool stream_check_interrupt(struct stream *s); -bool stream_manages_timeline(stream_t *s); - void mp_url_unescape_inplace(char *buf); char *mp_url_escape(void *talloc_ctx, const char *s, const char *ok); diff --git a/stream/stream_bluray.c b/stream/stream_bluray.c index fb3c6d749a..ee6d4b9664 100644 --- a/stream/stream_bluray.c +++ b/stream/stream_bluray.c @@ -584,8 +584,6 @@ static int bluray_stream_control(stream_t *s, int cmd, void *arg) *((double *)arg) = 0; return STREAM_OK; } - case STREAM_CTRL_MANAGES_TIMELINE: - return STREAM_OK; case STREAM_CTRL_GET_DISC_NAME: { const struct meta_dl *meta = bd_get_meta(b->bd); if (!meta || !meta->di_name || !meta->di_name[0]) @@ -801,6 +799,7 @@ static int bluray_stream_open(stream_t *s) s->end_pos = bd_get_title_size(bd); s->sector_size = BLURAY_SECTOR_SIZE; s->priv = b; + s->demuxer = "+disc"; MP_VERBOSE(s, "Blu-ray successfully opened.\n"); diff --git a/stream/stream_cdda.c b/stream/stream_cdda.c index 8ad7608604..953cc812f6 100644 --- a/stream/stream_cdda.c +++ b/stream/stream_cdda.c @@ -396,7 +396,8 @@ static int open_cdda(stream_t *st) st->control = control; st->close = close_cdda; - st->demuxer = "rawaudio"; + st->type = STREAMTYPE_CDDA; + st->demuxer = "+disc"; print_cdtext(st, 0); diff --git a/stream/stream_dvd.c b/stream/stream_dvd.c index 9773e14fa1..7576dc879b 100644 --- a/stream/stream_dvd.c +++ b/stream/stream_dvd.c @@ -619,8 +619,6 @@ static int control(stream_t *stream,int cmd,void* arg) snprintf(req->name, sizeof(req->name), "%c%c", lang >> 8, lang); return STREAM_OK; } - case STREAM_CTRL_MANAGES_TIMELINE: - return STREAM_OK; case STREAM_CTRL_GET_DVD_INFO: { struct stream_dvd_info_req *req = arg; @@ -899,6 +897,8 @@ static int open_s(stream_t *stream) // ... (unimplemented) // return NULL; stream->type = STREAMTYPE_DVD; + stream->demuxer = "+disc"; + stream->lavf_type = "mpeg"; stream->sector_size = 2048; stream->fill_buffer = fill_buffer; stream->control = control; diff --git a/stream/stream_dvdnav.c b/stream/stream_dvdnav.c index 9be03c6914..c366831aca 100644 --- a/stream/stream_dvdnav.c +++ b/stream/stream_dvdnav.c @@ -597,8 +597,6 @@ static int control(stream_t *stream, int cmd, void *arg) snprintf(req->name, sizeof(req->name), "%c%c", lang >> 8, lang); return STREAM_OK; } - case STREAM_CTRL_MANAGES_TIMELINE: - return STREAM_OK; case STREAM_CTRL_GET_DVD_INFO: { struct stream_dvd_info_req *req = arg; memset(req, 0, sizeof(*req)); @@ -733,7 +731,7 @@ static int open_s(stream_t *stream) stream->control = control; stream->close = stream_dvdnav_close; stream->type = STREAMTYPE_DVD; - stream->demuxer = "lavf"; + stream->demuxer = "+disc"; stream->lavf_type = "mpeg"; stream->allow_caching = false; diff --git a/stream/tv.c b/stream/tv.c index 726b7d0880..291e20240e 100644 --- a/stream/tv.c +++ b/stream/tv.c @@ -1228,7 +1228,6 @@ static int demux_tv_control(demuxer_t *demuxer, int cmd, void *arg) const demuxer_desc_t demuxer_desc_tv = { .name = "tv", .desc = "TV card demuxer", - .type = DEMUXER_TYPE_TV, .fill_buffer = demux_tv_fill_buffer, .control = demux_tv_control, .open = demux_open_tv, |