1 /*****************************************************************************
2 * vlc_vod.h: interface for VoD server modules
3 *****************************************************************************
4 * Copyright (C) 2000, 2001 the VideoLAN team
7 * Author: Gildas Bazin <gbazin@videolan.org>
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.
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.
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., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
22 *****************************************************************************/
31 /* Module properties */
35 vod_media_t * (*pf_media_new) ( vod_t *, char *, input_item_t * );
36 void (*pf_media_del) ( vod_t *, vod_media_t * );
37 int (*pf_media_add_es)( vod_t *, vod_media_t *, es_format_t * );
38 void (*pf_media_del_es)( vod_t *, vod_media_t *, es_format_t * );
40 /* Owner properties */
41 int (*pf_media_control) ( void *, vod_media_t *, char *, int, va_list );
45 static inline int vod_MediaControl( vod_t *p_vod, vod_media_t *p_media,
46 char *psz_id, int i_query, ... )
51 if( !p_vod->pf_media_control ) return VLC_EGENERIC;
53 va_start( args, i_query );
54 i_result = p_vod->pf_media_control( p_vod->p_data, p_media, psz_id,
62 VOD_MEDIA_PLAY, /* arg1= double * res= */
63 VOD_MEDIA_PAUSE, /* arg1= double * res= */
64 VOD_MEDIA_STOP, /* arg1= double res=can fail */
65 VOD_MEDIA_SEEK, /* arg1= double * res= */