libvlc_vlm.h

Go to the documentation of this file.
00001 /*****************************************************************************
00002  * libvlc_vlm.h:  libvlc_* new external API
00003  *****************************************************************************
00004  * Copyright (C) 1998-2005 the VideoLAN team
00005  * $Id$
00006  *
00007  * Authors: Clément Stenac <zorglub@videolan.org>
00008  *          Jean-Paul Saman <jpsaman _at_ m2x _dot_ nl>
00009  *
00010  * This program is free software; you can redistribute it and/or modify
00011  * it under the terms of the GNU General Public License as published by
00012  * the Free Software Foundation; either version 2 of the License, or
00013  * (at your option) any later version.
00014  *
00015  * This program is distributed in the hope that it will be useful,
00016  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00017  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00018  * GNU General Public License for more details.
00019  *
00020  * You should have received a copy of the GNU General Public License
00021  * along with this program; if not, write to the Free Software
00022  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
00023  *****************************************************************************/
00024 
00025 #ifndef LIBVLC_VLM_H
00026 #define LIBVLC_VLM_H 1
00027 
00028 # ifdef __cplusplus
00029 extern "C" {
00030 # endif
00031 
00032 /*****************************************************************************
00033  * VLM
00034  *****************************************************************************/
00035 /** \defgroup libvlc_vlm libvlc_vlm
00036  * \ingroup libvlc
00037  * LibVLC VLM
00038  * @{
00039  */
00040 
00041 
00042 /**
00043  * Release the vlm instance related to the given libvlc_instance_t
00044  *
00045  * \param p_instance the instance
00046  * \param p_e an initialized exception pointer
00047  */
00048 VLC_PUBLIC_API void libvlc_vlm_release( libvlc_instance_t *, libvlc_exception_t * );
00049 
00050 /**
00051  * Add a broadcast, with one input.
00052  *
00053  * \param p_instance the instance
00054  * \param psz_name the name of the new broadcast
00055  * \param psz_input the input MRL
00056  * \param psz_output the output MRL (the parameter to the "sout" variable)
00057  * \param i_options number of additional options
00058  * \param ppsz_options additional options
00059  * \param b_enabled boolean for enabling the new broadcast
00060  * \param b_loop Should this broadcast be played in loop ?
00061  * \param p_e an initialized exception pointer
00062  */
00063 VLC_PUBLIC_API void libvlc_vlm_add_broadcast( libvlc_instance_t *, char *, char *, char* ,
00064                                               int, char **, int, int, libvlc_exception_t * );
00065 
00066 /**
00067  * Add a vod, with one input.
00068  *
00069  * \param p_instance the instance
00070  * \param psz_name the name of the new vod media
00071  * \param psz_input the input MRL
00072  * \param i_options number of additional options
00073  * \param ppsz_options additional options
00074  * \param b_enabled boolean for enabling the new vod
00075  * \param psz_mux the muxer of the vod media
00076  * \param p_e an initialized exception pointer
00077  */
00078 VLC_PUBLIC_API void libvlc_vlm_add_vod( libvlc_instance_t *, char *, char *, int, char **,
00079                                         int, char *, libvlc_exception_t * );
00080 
00081 /**
00082  * Delete a media (VOD or broadcast).
00083  *
00084  * \param p_instance the instance
00085  * \param psz_name the media to delete
00086  * \param p_e an initialized exception pointer
00087  */
00088 VLC_PUBLIC_API void libvlc_vlm_del_media( libvlc_instance_t *, char *, libvlc_exception_t * );
00089 
00090 /**
00091  * Enable or disable a media (VOD or broadcast).
00092  *
00093  * \param p_instance the instance
00094  * \param psz_name the media to work on
00095  * \param b_enabled the new status
00096  * \param p_e an initialized exception pointer
00097  */
00098 VLC_PUBLIC_API void libvlc_vlm_set_enabled( libvlc_instance_t *, char *, int,
00099                                             libvlc_exception_t *);
00100 
00101 /**
00102  * Set the output for a media.
00103  *
00104  * \param p_instance the instance
00105  * \param psz_name the media to work on
00106  * \param psz_output the output MRL (the parameter to the "sout" variable)
00107  * \param p_e an initialized exception pointer
00108  */
00109 VLC_PUBLIC_API void libvlc_vlm_set_output( libvlc_instance_t *, char *, char*,
00110                                            libvlc_exception_t *);
00111 
00112 /**
00113  * Set a media's input MRL. This will delete all existing inputs and
00114  * add the specified one.
00115  *
00116  * \param p_instance the instance
00117  * \param psz_name the media to work on
00118  * \param psz_input the input MRL
00119  * \param p_e an initialized exception pointer
00120  */
00121 VLC_PUBLIC_API void libvlc_vlm_set_input( libvlc_instance_t *, char *, char*,
00122                                           libvlc_exception_t *);
00123 
00124 /**
00125  * Add a media's input MRL. This will add the specified one.
00126  *
00127  * \param p_instance the instance
00128  * \param psz_name the media to work on
00129  * \param psz_input the input MRL
00130  * \param p_e an initialized exception pointer
00131  */
00132 VLC_PUBLIC_API void libvlc_vlm_add_input( libvlc_instance_t *, char *, char *,
00133                                           libvlc_exception_t *p_exception );
00134 /**
00135  * Set a media's loop status.
00136  *
00137  * \param p_instance the instance
00138  * \param psz_name the media to work on
00139  * \param b_loop the new status
00140  * \param p_e an initialized exception pointer
00141  */
00142 VLC_PUBLIC_API void libvlc_vlm_set_loop( libvlc_instance_t *, char *, int,
00143                                          libvlc_exception_t *);
00144 
00145 /**
00146  * Set a media's vod muxer.
00147  *
00148  * \param p_instance the instance
00149  * \param psz_name the media to work on
00150  * \param psz_mux the new muxer
00151  * \param p_e an initialized exception pointer
00152  */
00153 VLC_PUBLIC_API void libvlc_vlm_set_mux( libvlc_instance_t *p_instance, char *psz_name,
00154                                         char *psz_mux, libvlc_exception_t *p_exception );
00155 
00156 /**
00157  * Edit the parameters of a media. This will delete all existing inputs and
00158  * add the specified one.
00159  *
00160  * \param p_instance the instance
00161  * \param psz_name the name of the new broadcast
00162  * \param psz_input the input MRL
00163  * \param psz_output the output MRL (the parameter to the "sout" variable)
00164  * \param i_options number of additional options
00165  * \param ppsz_options additional options
00166  * \param b_enabled boolean for enabling the new broadcast
00167  * \param b_loop Should this broadcast be played in loop ?
00168  * \param p_e an initialized exception pointer
00169  */
00170 VLC_PUBLIC_API void libvlc_vlm_change_media( libvlc_instance_t *, char *, char *, char* ,
00171                                              int, char **, int, int, libvlc_exception_t * );
00172 
00173 /**
00174  * Play the named broadcast.
00175  *
00176  * \param p_instance the instance
00177  * \param psz_name the name of the broadcast
00178  * \param p_e an initialized exception pointer
00179  */
00180 VLC_PUBLIC_API void libvlc_vlm_play_media ( libvlc_instance_t *, char *, libvlc_exception_t * );
00181 
00182 /**
00183  * Stop the named broadcast.
00184  *
00185  * \param p_instance the instance
00186  * \param psz_name the name of the broadcast
00187  * \param p_e an initialized exception pointer
00188  */
00189 VLC_PUBLIC_API void libvlc_vlm_stop_media ( libvlc_instance_t *, char *, libvlc_exception_t * );
00190 
00191 /**
00192  * Pause the named broadcast.
00193  *
00194  * \param p_instance the instance
00195  * \param psz_name the name of the broadcast
00196  * \param p_e an initialized exception pointer
00197  */
00198 VLC_PUBLIC_API void libvlc_vlm_pause_media( libvlc_instance_t *, char *, libvlc_exception_t * );
00199 
00200 /**
00201  * Seek in the named broadcast.
00202  *
00203  * \param p_instance the instance
00204  * \param psz_name the name of the broadcast
00205  * \param f_percentage the percentage to seek to
00206  * \param p_e an initialized exception pointer
00207  */
00208 VLC_PUBLIC_API void libvlc_vlm_seek_media( libvlc_instance_t *, char *,
00209                                            float, libvlc_exception_t * );
00210 
00211 /**
00212  * Return information about the named broadcast.
00213  *
00214  * \param p_instance the instance
00215  * \param psz_name the name of the broadcast
00216  * \param p_e an initialized exception pointer
00217  * \return string with information about named media
00218  */
00219 VLC_PUBLIC_API char* libvlc_vlm_show_media( libvlc_instance_t *, char *, libvlc_exception_t * );
00220 
00221 /**
00222  * Get information about media attribute from vlm.
00223  *
00224  * \param libvlc instance
00225  * \param type of information
00226  * \param default value
00227  * \return value of media attribute
00228  */
00229 #define LIBVLC_VLM_GET_MEDIA_ATTRIBUTE( attr, returnType, getType, default)\
00230 returnType libvlc_vlm_get_media_instance_## attr( libvlc_instance_t *, \
00231                         char *, int , libvlc_exception_t * );
00232 
00233 VLC_PUBLIC_API LIBVLC_VLM_GET_MEDIA_ATTRIBUTE( position, float, Float, -1);
00234 VLC_PUBLIC_API LIBVLC_VLM_GET_MEDIA_ATTRIBUTE( time, int, Integer, -1);
00235 VLC_PUBLIC_API LIBVLC_VLM_GET_MEDIA_ATTRIBUTE( length, int, Integer, -1);
00236 VLC_PUBLIC_API LIBVLC_VLM_GET_MEDIA_ATTRIBUTE( rate, int, Integer, -1);
00237 VLC_PUBLIC_API LIBVLC_VLM_GET_MEDIA_ATTRIBUTE( title, int, Integer, 0);
00238 VLC_PUBLIC_API LIBVLC_VLM_GET_MEDIA_ATTRIBUTE( chapter, int, Integer, 0);
00239 VLC_PUBLIC_API LIBVLC_VLM_GET_MEDIA_ATTRIBUTE( seekable, int, Bool, 0);
00240 
00241 #undef LIBVLC_VLM_GET_MEDIA_ATTRIBUTE
00242 
00243 /** @} */
00244 
00245 # ifdef __cplusplus
00246 }
00247 # endif
00248 
00249 #endif /* <vlc/libvlc_vlm.h> */

Generated on Wed Aug 13 08:02:37 2008 for VLC by  doxygen 1.5.1