[vlc-devel] [PATCH 2/7] Add services-advertisement configuration option

Roland Bewick roland.bewick at gmail.com
Thu Jul 25 17:08:06 CEST 2019


On Thu, 25 Jul 2019 at 4:44 PM, Alexandre Janniaux <ajanni at videolabs.io>
wrote:

> Hi,
>
> Actually I was a bit to fast in answering, it currently displays nothing in
> vlc -H but could in the future (only add_module does that currently) and
> could also be presented just like control interfaces in the Qt interfaces.
>
> It also provides better insight when reading the code because you'll know
> the capability supported for this variable.
>
> You shouldn't have to introduce this kind of documentation yourself, as the
> module system is dynamic and you never know when compiling which modules
> will
> be available at runtime.
>
> Thank you for your changes :)


Ok, sounds good to me :-)

Thanks for the explanation.


>
> Regards,
>
> --
> Alexandre Janniaux
> VideoLabs
>
> On Thu, Jul 25, 2019 at 01:32:54PM +0700, Roland Bewick wrote:
> >
> > On 24/07/2019 11:29 PM, Alexandre Janniaux wrote:
> > > The default value should probably be NULL like "keystore",
> "clock-source",
> > > pidfile,... btw, to stay consistent. :)
> > Sounds good.
> > >
> > > --
> > > Alexandre Janniaux
> > > VideoLabs
> > >
> > > On Wed, Jul 24, 2019 at 06:11:16PM +0200, Alexandre Janniaux wrote:
> > > > Hi,
> > > >
> > > > This would probably be a good idea to use add_module_list instead of
> > > > add_string, as `vlc -H` will provide the available module that you
> can
> > > > put there and you probably want to be capable of running multiple
> > > > service advertisement like the variable name states.
> > > > If so, you'll need to use config_ChainParse to extract the different
> > > > module and their configurations.
> >
> > I've updated to use add_module_list and I just get the
> > SERVICE_ADVERTISEMENT_TEXT and SERVICE_ADVERTISEMENT_LONGTEXT:
> >
> >       --services-advertisement=<string>
> >                                  Services advertisement modules
> >           Specifies the services advertisement modules to preload,
> separated
> > by colons. Typical value is "mdns".
> >
> >
> > Do you mean it should show something like the below?
> >
> > --services-advertisement={mdns}
> >
> > > >
> > > > Besides, other defines aren't using abbreviations so maybe SA_TEXT
> could
> > > > be a more explicit name ?
> > Renamed SERVICE_ADVERTISEMENT_*
> > > >
> > > > Regards,
> > > >
> > > > --
> > > > Alexandre Janniaux
> > > > VideoLabs
> > > >
> > > > On Wed, Jul 24, 2019 at 10:43:45PM +0700, Roland Bewick wrote:
> > > > > ---
> > > > >   src/libvlc-module.c | 6 ++++++
> > > > >   1 file changed, 6 insertions(+)
> > > > >
> > > > > diff --git a/src/libvlc-module.c b/src/libvlc-module.c
> > > > > index f5de78bcae..97075cbab6 100644
> > > > > --- a/src/libvlc-module.c
> > > > > +++ b/src/libvlc-module.c
> > > > > @@ -1232,6 +1232,11 @@ static const char *const
> psz_recursive_list_text[] = {
> > > > >        "Specifies the services discovery modules to preload,
> separated by " \
> > > > >        "colons. Typical value is \"sap\"." )
> > > > >
> > > > > +#define SA_TEXT N_( "Services advertisement modules")
> > > > > +#define SA_LONGTEXT N_( \
> > > > > +     "Specifies the services advertisement modules to preload,
> separated by " \
> > > > > +     "colons. Typical value is \"mdns\"." )
> > > > > +
> > > > >   #define RANDOM_TEXT N_("Play files randomly forever")
> > > > >   #define RANDOM_LONGTEXT N_( \
> > > > >       "VLC will randomly play files in the playlist until
> interrupted.")
> > > > > @@ -2125,6 +2130,7 @@ vlc_module_begin ()
> > > > >       add_category_hint(N_("Miscellaneous"), MISC_CAT_LONGTEXT)
> > > > >       add_module("vod-server", "vod server", NULL,
> > > > >                  VOD_SERVER_TEXT, VOD_SERVER_LONGTEXT)
> > > > > +    add_string( "services-advertisement", "", SA_TEXT,
> SA_LONGTEXT, true )
> > > > >
> > > > >       set_section( N_("Plugins" ), NULL )
> > > > >   #ifdef HAVE_DYNAMIC_PLUGINS
> > > > > --
> > > > > 2.11.0
> > > > >
> > > > > _______________________________________________
> > > > > vlc-devel mailing list
> > > > > To unsubscribe or modify your subscription options:
> > > > > https://mailman.videolan.org/listinfo/vlc-devel
> > > > _______________________________________________
> > > > vlc-devel mailing list
> > > > To unsubscribe or modify your subscription options:
> > > > https://mailman.videolan.org/listinfo/vlc-devel
> > > _______________________________________________
> > > vlc-devel mailing list
> > > To unsubscribe or modify your subscription options:
> > > https://mailman.videolan.org/listinfo/vlc-devel
> > _______________________________________________
> > vlc-devel mailing list
> > To unsubscribe or modify your subscription options:
> > https://mailman.videolan.org/listinfo/vlc-devel
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20190725/6ef81f1e/attachment-0001.html>


More information about the vlc-devel mailing list