Browse Source

libvlc media list player: add getter for player instance

pull/35/head
Felix Paul Kühne 11 years ago
parent
commit
688e3bcb4d
  1. 1
      NEWS
  2. 10
      include/vlc/libvlc_media_list_player.h
  3. 1
      lib/libvlc.sym
  4. 13
      lib/media_list_player.c

1
NEWS

@ -141,6 +141,7 @@ libVLC:
This allows to attach media events between create and start.
* Add libvlc_media_get_codec_description to get a human readable description of a codec
* Add libvlc_MediaListEndReached Event to get notified when a media list reached the end
* Add libvlc_media_list_player_get_media_player to get the media player instance of a list player
* Add libvlc_media_parse_with_options that uses a flag to specify parse options
* Add libvlc_audio_output_device_get to get the currently selected audio output device
identifier (if there is one available)

10
include/vlc/libvlc_media_list_player.h

@ -102,6 +102,16 @@ LIBVLC_API void
libvlc_media_list_player_t * p_mlp,
libvlc_media_player_t * p_mi );
/**
* Get media player of the media_list_player instance.
*
* \param p_mlp media list player instance
* \return media player instance
* \note the caller is responsible for releasing the returned instance
*/
LIBVLC_API libvlc_media_player_t *
libvlc_media_list_player_get_media_player(libvlc_media_list_player_t * p_mlp);
/**
* Set the media list associated with the player
*

1
lib/libvlc.sym

@ -109,6 +109,7 @@ libvlc_media_list_lock
libvlc_media_list_media
libvlc_media_list_new
libvlc_media_list_player_event_manager
libvlc_media_list_player_get_media_player
libvlc_media_list_player_get_state
libvlc_media_list_player_is_playing
libvlc_media_list_player_new

13
lib/media_list_player.c

@ -1,10 +1,12 @@
/*****************************************************************************
* media_list_player.c: libvlc new API media_list player functions
*****************************************************************************
* Copyright (C) 2007 VLC authors and VideoLAN
* Copyright (C) 2007-2015 VLC authors and VideoLAN
* $Id$
*
* Authors: Pierre d'Herbemont <pdherbemont # videolan.org>
* Niles Bindel <zaggal69 # gmail.com>
* Rémi Denis-Courmont
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
@ -600,6 +602,15 @@ void libvlc_media_list_player_set_media_player(libvlc_media_list_player_t * p_ml
libvlc_media_player_release(p_oldmi);
}
/**************************************************************************
* get_media_player (Public)
**************************************************************************/
libvlc_media_player_t * libvlc_media_list_player_get_media_player(libvlc_media_list_player_t * p_mlp)
{
libvlc_media_player_retain(p_mlp->p_mi);
return p_mlp->p_mi;
}
/**************************************************************************
* set_media_list (Public)
**************************************************************************/

Loading…
Cancel
Save