[vlc-commits] demux: add DEMUX_SET_ES_LIST control
Roland Bewick
git at videolan.org
Tue Jun 25 20:55:16 CEST 2019
vlc | branch: master | Roland Bewick <roland.bewick at gmail.com> | Wed May 22 01:08:26 2019 +0700| [355577728288e81eb7e9b7c74523622f6a726046] | committer: Thomas Guillem
demux: add DEMUX_SET_ES_LIST control
Signed-off-by: Thomas Guillem <thomas at gllm.fr>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=355577728288e81eb7e9b7c74523622f6a726046
---
include/vlc_demux.h | 3 ++-
modules/access/bluray.c | 2 ++
modules/demux/asf/asf.c | 3 +++
modules/demux/mock.c | 2 ++
modules/demux/mpeg/ts.c | 10 ++++++++--
modules/stream_out/chromecast/chromecast_demux.cpp | 1 +
src/input/demux.c | 1 +
7 files changed, 19 insertions(+), 3 deletions(-)
diff --git a/include/vlc_demux.h b/include/vlc_demux.h
index 9930c0957d..ba06d9162e 100644
--- a/include/vlc_demux.h
+++ b/include/vlc_demux.h
@@ -197,7 +197,8 @@ enum demux_query_e
DEMUX_SET_GROUP_DEFAULT,
DEMUX_SET_GROUP_ALL,
DEMUX_SET_GROUP_LIST, /* arg1= size_t, arg2= const int *, can fail */
- DEMUX_SET_ES, /* arg1= int can fail */
+ DEMUX_SET_ES, /* arg1= int can fail */
+ DEMUX_SET_ES_LIST, /* arg1= size_t, arg2= const int * (can be NULL) can fail */
/* Ask the demux to demux until the given date at the next pf_demux call
* but not more (and not less, at the precision available of course).
diff --git a/modules/access/bluray.c b/modules/access/bluray.c
index 54746fc98f..95f1afe389 100644
--- a/modules/access/bluray.c
+++ b/modules/access/bluray.c
@@ -2414,6 +2414,8 @@ static int blurayControl(demux_t *p_demux, int query, va_list args)
blurayOnUserStreamSelection(p_demux, i_id);
break;
}
+ case DEMUX_SET_ES_LIST:
+ return VLC_EGENERIC; /* TODO */
case DEMUX_SET_TITLE:
{
int i_title = va_arg(args, int);
diff --git a/modules/demux/asf/asf.c b/modules/demux/asf/asf.c
index 776e3c9af1..523f0420e3 100644
--- a/modules/demux/asf/asf.c
+++ b/modules/demux/asf/asf.c
@@ -490,6 +490,9 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
return i_ret;
}
+ case DEMUX_SET_ES_LIST:
+ return VLC_EGENERIC; /* TODO */
+
case DEMUX_GET_POSITION:
if( p_sys->i_time == VLC_TICK_INVALID ) return VLC_EGENERIC;
if( p_sys->i_length != 0 )
diff --git a/modules/demux/mock.c b/modules/demux/mock.c
index 03d282606b..b01fb2c342 100644
--- a/modules/demux/mock.c
+++ b/modules/demux/mock.c
@@ -287,6 +287,8 @@ Control(demux_t *demux, int query, va_list args)
return VLC_EGENERIC;
case DEMUX_SET_ES:
return VLC_EGENERIC;
+ case DEMUX_SET_ES_LIST:
+ return VLC_EGENERIC;
case DEMUX_SET_NEXT_DEMUX_TIME:
return VLC_EGENERIC;
case DEMUX_GET_FPS:
diff --git a/modules/demux/mpeg/ts.c b/modules/demux/mpeg/ts.c
index 41926aad3e..ce70347774 100644
--- a/modules/demux/mpeg/ts.c
+++ b/modules/demux/mpeg/ts.c
@@ -1109,9 +1109,15 @@ static int Control( demux_t *p_demux, int i_query, va_list args )
}
case DEMUX_SET_ES:
+ case DEMUX_SET_ES_LIST:
{
- i_int = va_arg( args, int );
- msg_Dbg( p_demux, "DEMUX_SET_ES %d", i_int );
+ if( i_query == DEMUX_SET_ES )
+ {
+ i_int = va_arg( args, int );
+ msg_Dbg( p_demux, "DEMUX_SET_ES %d", i_int );
+ }
+ else
+ msg_Dbg( p_demux, "DEMUX_SET_ES_LIST" );
if( p_sys->seltype != PROGRAM_ALL ) /* Won't change anything */
UpdatePESFilters( p_demux, false );
diff --git a/modules/stream_out/chromecast/chromecast_demux.cpp b/modules/stream_out/chromecast/chromecast_demux.cpp
index 7a97b9cadc..6bfc4fa9b0 100644
--- a/modules/stream_out/chromecast/chromecast_demux.cpp
+++ b/modules/stream_out/chromecast/chromecast_demux.cpp
@@ -378,6 +378,7 @@ struct demux_cc
break;
}
case DEMUX_SET_ES:
+ case DEMUX_SET_ES_LIST:
/* Seek back to the last known pos when changing tracks. This will
* flush sout streams, make sout del/add called right away and
* clear CC buffers. */
diff --git a/src/input/demux.c b/src/input/demux.c
index 22952ae800..02365c847d 100644
--- a/src/input/demux.c
+++ b/src/input/demux.c
@@ -379,6 +379,7 @@ int demux_vaControlHelper( stream_t *s,
case DEMUX_SET_GROUP_ALL:
case DEMUX_SET_GROUP_LIST:
case DEMUX_SET_ES:
+ case DEMUX_SET_ES_LIST:
case DEMUX_GET_ATTACHMENTS:
case DEMUX_CAN_RECORD:
case DEMUX_TEST_AND_CLEAR_FLAGS:
More information about the vlc-commits
mailing list