libvlc_media_list_player.h
上传用户:kjfoods
上传日期:2020-07-06
资源大小:29949k
文件大小:6k
源码类别:

midi

开发平台:

Unix_Linux

  1. /*****************************************************************************
  2.  * libvlc_media_list.h:  libvlc_media_list API
  3.  *****************************************************************************
  4.  * Copyright (C) 1998-2008 the VideoLAN team
  5.  * $Id: d2f21515cd2cce6f46075c396cf16bef35a66374 $
  6.  *
  7.  * Authors: Pierre d'Herbemont
  8.  *
  9.  * This program is free software; you can redistribute it and/or modify
  10.  * it under the terms of the GNU General Public License as published by
  11.  * the Free Software Foundation; either version 2 of the License, or
  12.  * (at your option) any later version.
  13.  *
  14.  * This program is distributed in the hope that it will be useful,
  15.  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  16.  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  17.  * GNU General Public License for more details.
  18.  *
  19.  * You should have received a copy of the GNU General Public License
  20.  * along with this program; if not, write to the Free Software
  21.  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  22.  *****************************************************************************/
  23. #ifndef LIBVLC_MEDIA_LIST_PLAYER_H
  24. #define LIBVLC_MEDIA_LIST_PLAYER_H 1
  25. /**
  26.  * file
  27.  * This file defines libvlc_media_list_player API
  28.  */
  29. # ifdef __cplusplus
  30. extern "C" {
  31. # endif
  32. /*****************************************************************************
  33.  * Media List Player
  34.  *****************************************************************************/
  35. /** defgroup libvlc_media_list_player libvlc_media_list_player
  36.  * ingroup libvlc
  37.  * LibVLC Media List Player, play a media_list. You can see that as a media
  38.  * instance subclass
  39.  * @{
  40.  */
  41. typedef struct libvlc_media_list_player_t libvlc_media_list_player_t;
  42. /**
  43.  * Create new media_list_player.
  44.  *
  45.  * param p_instance libvlc instance
  46.  * param p_e initialized exception instance
  47.  * return media list player instance
  48.  */
  49. VLC_PUBLIC_API libvlc_media_list_player_t *
  50.     libvlc_media_list_player_new( libvlc_instance_t * p_instance,
  51.                                   libvlc_exception_t * p_e );
  52. /**
  53.  * Release media_list_player.
  54.  *
  55.  * param p_mlp media list player instance
  56.  */
  57. VLC_PUBLIC_API void
  58.     libvlc_media_list_player_release( libvlc_media_list_player_t * p_mlp );
  59. /**
  60.  * Replace media player in media_list_player with this instance.
  61.  *
  62.  * param p_mlp media list player instance
  63.  * param p_mi media player instance
  64.  * param p_e initialized exception instance
  65.  */
  66. VLC_PUBLIC_API void
  67.     libvlc_media_list_player_set_media_player(
  68.                                      libvlc_media_list_player_t * p_mlp,
  69.                                      libvlc_media_player_t * p_mi,
  70.                                      libvlc_exception_t * p_e );
  71. VLC_PUBLIC_API void
  72.     libvlc_media_list_player_set_media_list(
  73.                                      libvlc_media_list_player_t * p_mlp,
  74.                                      libvlc_media_list_t * p_mlist,
  75.                                      libvlc_exception_t * p_e );
  76. /**
  77.  * Play media list
  78.  *
  79.  * param p_mlp media list player instance
  80.  * param p_e initialized exception instance
  81.  */
  82. VLC_PUBLIC_API void
  83.     libvlc_media_list_player_play( libvlc_media_list_player_t * p_mlp,
  84.                                    libvlc_exception_t * p_e );
  85. /**
  86.  * Pause media list
  87.  *
  88.  * param p_mlp media list player instance
  89.  * param p_e initialized exception instance
  90.  */
  91. VLC_PUBLIC_API void
  92.     libvlc_media_list_player_pause( libvlc_media_list_player_t * p_mlp,
  93.                                    libvlc_exception_t * p_e );
  94. /**
  95.  * Is media list playing?
  96.  *
  97.  * param p_mlp media list player instance
  98.  * param p_e initialized exception instance
  99.  * return true for playing and false for not playing
  100.  */
  101. VLC_PUBLIC_API int
  102.     libvlc_media_list_player_is_playing( libvlc_media_list_player_t * p_mlp,
  103.                                          libvlc_exception_t * p_e );
  104. /**
  105.  * Get current libvlc_state of media list player
  106.  *
  107.  * param p_mlp media list player instance
  108.  * param p_e initialized exception instance
  109.  * return libvlc_state_t for media list player
  110.  */
  111. VLC_PUBLIC_API libvlc_state_t
  112.     libvlc_media_list_player_get_state( libvlc_media_list_player_t * p_mlp,
  113.                                         libvlc_exception_t * p_e );
  114. /**
  115.  * Play media list item at position index
  116.  *
  117.  * param p_mlp media list player instance
  118.  * param i_index index in media list to play
  119.  * param p_e initialized exception instance
  120.  */
  121. VLC_PUBLIC_API void
  122.     libvlc_media_list_player_play_item_at_index(
  123.                                    libvlc_media_list_player_t * p_mlp,
  124.                                    int i_index,
  125.                                    libvlc_exception_t * p_e );
  126. VLC_PUBLIC_API void
  127.     libvlc_media_list_player_play_item(
  128.                                    libvlc_media_list_player_t * p_mlp,
  129.                                    libvlc_media_t * p_md,
  130.                                    libvlc_exception_t * p_e );
  131. /**
  132.  * Stop playing media list
  133.  *
  134.  * param p_mlp media list player instance
  135.  * param p_e initialized exception instance
  136.  */
  137. VLC_PUBLIC_API void
  138.     libvlc_media_list_player_stop( libvlc_media_list_player_t * p_mlp,
  139.                                    libvlc_exception_t * p_e );
  140. /**
  141.  * Play next item from media list
  142.  *
  143.  * param p_mlp media list player instance
  144.  * param p_e initialized exception instance
  145.  */
  146. VLC_PUBLIC_API void
  147.     libvlc_media_list_player_next( libvlc_media_list_player_t * p_mlp,
  148.                                    libvlc_exception_t * p_e );
  149. /* NOTE: shouldn't there also be a libvlc_media_list_player_prev() */
  150. /** @} media_list_player */
  151. # ifdef __cplusplus
  152. }
  153. # endif
  154. #endif /* LIBVLC_MEDIA_LIST_PLAYER_H */