summaryrefslogtreecommitdiff
path: root/src/xine-engine/xine.c
diff options
context:
space:
mode:
authorDarren Salt <linux@youmustbejoking.demon.co.uk>2008-06-20 13:18:17 +0100
committerDarren Salt <linux@youmustbejoking.demon.co.uk>2008-06-20 13:18:17 +0100
commit17c9a01cbafd5ff0e6645f96f8ac084fbf239e4d (patch)
treef8bbe29f4b5b0464bdf83ed6cab05497a55955ec /src/xine-engine/xine.c
parenta78cd0f86f650fd566337d9abb86eedc51e3e699 (diff)
parente8d0ebf629763d195cdc6675f952f479bcedb6c7 (diff)
downloadxine-lib-17c9a01cbafd5ff0e6645f96f8ac084fbf239e4d.tar.gz
xine-lib-17c9a01cbafd5ff0e6645f96f8ac084fbf239e4d.tar.bz2
Merge from 1.1.
--HG-- rename : src/input/input_plugin.h => include/xine/input_plugin.h
Diffstat (limited to 'src/xine-engine/xine.c')
-rw-r--r--src/xine-engine/xine.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/xine-engine/xine.c b/src/xine-engine/xine.c
index 39bef61d8..1e7c5c2c7 100644
--- a/src/xine-engine/xine.c
+++ b/src/xine-engine/xine.c
@@ -1228,6 +1228,27 @@ static int open_internal (xine_stream_t *stream, const char *mrl) {
/* enable buffered input plugin (request optimizer) */
stream->input_plugin = _x_cache_plugin_get_instance(stream);
+ /* Let the plugin request a specific demuxer (if the user hasn't).
+ * This overrides find-by-content & find-by-extension.
+ */
+ if (!stream->demux_plugin)
+ {
+ char *default_demux = NULL;
+ stream->input_plugin->get_optional_data (stream->input_plugin, &default_demux, INPUT_OPTIONAL_DATA_DEMUXER);
+ if (default_demux)
+ {
+ stream->demux_plugin = _x_find_demux_plugin_by_name (stream, default_demux, stream->input_plugin);
+ if (stream->demux_plugin)
+ {
+ lprintf ("demux and input plugin found\n");
+ _x_meta_info_set_utf8 (stream, XINE_META_INFO_SYSTEMLAYER,
+ stream->demux_plugin->demux_class->identifier);
+ }
+ else
+ xine_log (stream->xine, XINE_LOG_MSG, _("xine: couldn't load plugin-specified demux %s for >%s<\n"), default_demux, mrl);
+ }
+ }
+
if (!stream->demux_plugin) {
/*