1 /*****************************************************************************
2 * vlc.h: global header for vlc
3 *****************************************************************************
4 * Copyright (C) 1998, 1999, 2000 VideoLAN
5 * $Id: vlc.h,v 1.1 2002/06/01 12:31:58 sam Exp $
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
20 *****************************************************************************/
29 /*****************************************************************************
31 *****************************************************************************/
32 typedef signed int vlc_error_t;
34 #define VLC_SUCCESS -0 /* No error */
35 #define VLC_EGENERIC -1 /* Generic error */
36 #define VLC_ENOMEM -2 /* Not enough memory */
37 #define VLC_ESTATUS -3 /* Invalid status */
38 #define VLC_EEXIT -255 /* Program exited */
40 /*****************************************************************************
42 *****************************************************************************/
43 typedef int vlc_bool_t;
48 /*****************************************************************************
49 * Main structure status
50 *****************************************************************************/
51 typedef int vlc_status_t;
53 #define VLC_STATUS_NONE 0x00000000
54 #define VLC_STATUS_CREATED 0x02020202
55 #define VLC_STATUS_STOPPED 0x12121212
56 #define VLC_STATUS_RUNNING 0x42424242
58 /*****************************************************************************
60 *****************************************************************************/
61 #define VLC_DECLARE_STRUCT( name ) \
63 typedef struct name##_s name##_t;
64 VLC_DECLARE_STRUCT(vlc)
65 VLC_DECLARE_STRUCT(vlc_object)
67 /*****************************************************************************
68 * Required internal headers
69 *****************************************************************************/
70 #if defined( __VLC__ )
73 # include "modules_inner.h"
74 # include "vlc_common.h"
75 # include "vlc_messages.h"
79 # include "configuration.h"
80 # include "threads_funcs.h"
81 # include "vlc_objects.h"
84 /*****************************************************************************
85 * Exported libvlc base API
86 *****************************************************************************/
87 vlc_t * vlc_create ( void );
88 vlc_error_t vlc_init ( vlc_t *, int, char *[] );
89 vlc_error_t vlc_run ( vlc_t * );
90 vlc_error_t vlc_stop ( vlc_t * );
91 vlc_error_t vlc_end ( vlc_t * );
92 vlc_error_t vlc_destroy ( vlc_t * );
94 vlc_error_t vlc_add_intf ( vlc_t *, char *, vlc_bool_t );
95 vlc_error_t vlc_add_target ( vlc_t *, char * );
97 vlc_status_t vlc_status ( vlc_t * );
103 #endif /* <vlc/vlc.h> */