[vlc-devel] [PATCH 03/14] lib: add libvlc_media_discoverer_browse

Thomas Guillem thomas at gllm.fr
Mon Dec 8 11:21:29 CET 2014



On Sun, Dec 7, 2014, at 17:31, Rémi Denis-Courmont wrote:
> Le vendredi 05 décembre 2014, 14:42:54 Thomas Guillem a écrit :
> > Discover media on a specified uri.
> > ---
> >  include/vlc/libvlc_media_discoverer.h | 10 ++++++++++
> >  lib/libvlc.sym                        |  1 +
> >  lib/media_discoverer.c                | 28 ++++++++++++++++++++++++++++
> >  3 files changed, 39 insertions(+)
> > 
> > diff --git a/include/vlc/libvlc_media_discoverer.h
> > b/include/vlc/libvlc_media_discoverer.h index 0f3b379..bc0d9e9 100644
> > --- a/include/vlc/libvlc_media_discoverer.h
> > +++ b/include/vlc/libvlc_media_discoverer.h
> > @@ -126,6 +126,16 @@ LIBVLC_API libvlc_event_manager_t *
> >  LIBVLC_API int
> >          libvlc_media_discoverer_is_running( libvlc_media_discoverer_t *
> > p_mdis );
> > 
> > +/**
> > + * Discover media on a specified uri.
> > + *
> > + * \param p_mdis media service discover object
> > + * \param psz_uri uri
> > + * \return -1 in case of error, 0 otherwise
> > + */
> > +LIBVLC_API int
> > +        libvlc_media_discoverer_browse( libvlc_media_discoverer_t * p_mdis,
> > const char * psz_uri ); +
> 
> That is a bad idea. The URI parameter is completely undocumented. The 
> threading ruels are completely undocumented, and well, the meaning of the 
> function is somewhere between obscure and undocumented.

Ok, I'll pass a input_item_t * at SD_CMD_BROWSE, and a libvlc_media_t *
at libvlc_media_discoverer_browse().
I'll lock what need to be locked, and do a better documentation.

Do you have a better name for libvlc_media_discoverer_browse ?
libvlc_media_discoverer_discover_at(libvlc_media_discoverer_t *,
libvlc_media_t *) ?

> 
> -- 
> Rémi Denis-Courmont
> http://www.remlab.net/
> 
> _______________________________________________
> 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