* vlm.c: libvlc new API VLM handling functions
*****************************************************************************
* Copyright (C) 2005 the VideoLAN team
- * $Id: playlist.c 14265 2006-02-12 17:31:39Z zorglub $
+ * $Id$
*
* Authors: Clément Stenac <zorglub@videolan.org>
*
*****************************************************************************/
#include "libvlc_internal.h"
+
#include <vlc/libvlc.h>
#include <vlc_es.h>
#include <vlc_input.h>
} while(0)
#define VLM(p) VLM_RET(p,)
+void libvlc_vlm_release( libvlc_instance_t *p_instance, libvlc_exception_t *p_exception)
+{
+ vlm_t *p_vlm;
+
+ VLM(p_vlm);
+
+ vlm_Delete( p_vlm );
+}
+
+
void libvlc_vlm_add_broadcast( libvlc_instance_t *p_instance, char *psz_name,
char *psz_input, char *psz_output,
int i_options, char **ppsz_options,
void libvlc_vlm_set_output( libvlc_instance_t *p_instance, char *psz_name,
char *psz_output, libvlc_exception_t *p_exception )
{
-#define VLM_CHANGE_CODE { if( p_media->psz_output ) free( p_media->psz_output ); \
+#define VLM_CHANGE_CODE { free( p_media->psz_output ); \
p_media->psz_output = strdup( psz_output ); }
VLM_CHANGE( "Unable to change %s output property", VLM_CHANGE_CODE );
#undef VLM_CHANGE_CODE
#undef VLM_CHANGE_CODE
}
-
void libvlc_vlm_change_media( libvlc_instance_t *p_instance, char *psz_name,
char *psz_input, char *psz_output, int i_options,
char **ppsz_options, int b_enabled, int b_loop,
free( p_media->ppsz_input[--p_media->i_input] ); \
if( psz_input ) \
TAB_APPEND( p_media->i_input, p_media->ppsz_input, strdup(psz_input) ); \
- if( p_media->psz_output ) \
- free( p_media->psz_output ); \
+ free( p_media->psz_output ); \
p_media->psz_output = psz_output ? strdup( psz_output ) : NULL; \
while( p_media->i_option > 0 ) \
free( p_media->ppsz_option[--p_media->i_option] ); \
void libvlc_vlm_play_media( libvlc_instance_t *p_instance, char *psz_name,
libvlc_exception_t *p_exception )
-
{
vlm_t *p_vlm;
int64_t id;
void libvlc_vlm_stop_media( libvlc_instance_t *p_instance, char *psz_name,
libvlc_exception_t *p_exception )
-
{
vlm_t *p_vlm;
int64_t id;
void libvlc_vlm_pause_media( libvlc_instance_t *p_instance, char *psz_name,
libvlc_exception_t *p_exception )
-
{
vlm_t *p_vlm;
int64_t id;
void libvlc_vlm_seek_media( libvlc_instance_t *p_instance, char *psz_name,
float f_percentage, libvlc_exception_t *p_exception )
-
{
vlm_t *p_vlm;
int64_t id;
libvlc_exception_raise( p_exception, "Unable to call show %s", psz_name );
return NULL;
}
-