[vlc-devel] [PATCH] libvlc: player: inherit VLC variables

Thomas Guillem thomas at gllm.fr
Wed Jun 3 08:21:34 CEST 2020


"sout" and "demux-filter" are not currently used by LibVLC. So, you can't do anything with it, and the variable creation without inherit prevent all use of sout from command line (passed to libvlc_new).

I'm OK to remove the inherit when we have a proper sout API, but we don't have any for now.

On Tue, Jun 2, 2020, at 19:52, Alexandre Janniaux wrote:
> Hi,
> 
> On Tue, Jun 02, 2020 at 07:47:06PM +0300, Rémi Denis-Courmont wrote:
> > Le tiistaina 2. kesäkuuta 2020, 19.16.07 EEST Romain Vimont a écrit :
> > > This allows to correctly handle --sout and --demux-filters parameters
> > > passed to libvlc.
> > > ---
> > >  lib/media_player.c | 4 ++--
> > >  1 file changed, 2 insertions(+), 2 deletions(-)
> > >
> > > diff --git a/lib/media_player.c b/lib/media_player.c
> > > index 68e6e62b1a2a..5238b7b1b7fa 100644
> > > --- a/lib/media_player.c
> > > +++ b/lib/media_player.c
> > > @@ -597,8 +597,8 @@ libvlc_media_player_new( libvlc_instance_t *instance )
> > >
> > >      /* Input */
> > >      var_Create (mp, "rate", VLC_VAR_FLOAT|VLC_VAR_DOINHERIT);
> > > -    var_Create (mp, "sout", VLC_VAR_STRING);
> > > -    var_Create (mp, "demux-filter", VLC_VAR_STRING);
> > > +    var_Create (mp, "sout", VLC_VAR_STRING | VLC_VAR_DOINHERIT);
> > > +    var_Create (mp, "demux-filter", VLC_VAR_STRING | VLC_VAR_DOINHERIT);
> >
> > -1
> >
> > These variables are controlled by LibVLC internally. Overriding them in its
> > back is guaranteed to cause problems eventually.
> 
> I agree, it doesn't look like a good idea since libVLC makes
> use of these variables for renderers. I don't see any use
> case in which it would be needed for libVLC.
> 
> Regards,
> --
> Alexandre Janniaux
> Videolabs
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel


More information about the vlc-devel mailing list