2
* Copyright (C) 2001-2003 the xine project
4
* This program is free software; you can redistribute it and/or modify
5
* it under the terms of the GNU General Public License as published by
6
* the Free Software Foundation; either version 2 of the License, or
7
* (at your option) any later version.
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
14
* You should have received a copy of the GNU General Public License
15
* along with this program; if not, write to the Free Software
16
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18
* $Id: gtkxine.h,v 1.26 2003/03/08 23:27:27 guenter Exp $
20
* the xine engine in a widget - header
23
#ifndef HAVE_GTK_XINE_H
24
#define HAVE_GTK_XINE_H
28
#include <X11/extensions/XShm.h>
33
#endif /* __cplusplus */
36
#define GTK_XINE(obj) (GTK_CHECK_CAST ((obj), gtk_xine_get_type (), GtkXine))
37
#define GTK_XINE_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), gtk_xine_get_type (), GtkXineClass))
38
#define GTK_IS_XINE(obj) (GTK_CHECK_TYPE (obj, gtk_xine_get_type ()))
39
#define GTK_IS_XINE_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), gtk_xine_get_type ()))
41
typedef struct _GtkXine GtkXine;
42
typedef struct _GtkXineClass GtkXineClass;
49
xine_stream_t *stream;
53
char *video_driver_id;
54
char *audio_driver_id;
56
xine_video_port_t *video_port;
57
xine_audio_port_t *audio_port;
70
int oldwidth, oldheight;
72
/* fullscreen stuff */
75
int fullscreen_width, fullscreen_height;
76
Window fullscreen_window, toplevel;
79
gboolean cursor_visible;
81
GdkVisibilityState visibility;
87
xine_post_t *vis_plugin;
94
GtkWidgetClass parent_class;
97
GtkType gtk_xine_get_type (void);
98
GtkWidget* gtk_xine_new (const gchar *video_driver_id,
99
const gchar *audio_driver_id);
100
void gtk_xine_set_visibility (GtkXine *gtx,
101
GdkVisibilityState state);
102
void gtk_xine_resize (GtkXine *gtx,
106
gint gtk_xine_open (GtkXine *gtx,
108
gint gtk_xine_play (GtkXine *gtx,
111
gint gtk_xine_trick_mode (GtkXine *gtx,
114
gint gtk_xine_get_stream_info (GtkXine *gtx,
116
const gchar*gtk_xine_get_meta_info (GtkXine *gtx,
118
gint gtk_xine_get_pos_length (GtkXine *gtx,
119
gint *pos_stream, /* 0..65535 */
120
gint *pos_time, /* milliseconds */
121
gint *length_time);/* milliseconds */
122
void gtk_xine_stop (GtkXine *gtx);
124
gint gtk_xine_get_error (GtkXine *gtx);
125
gint gtk_xine_get_status (GtkXine *gtx);
127
void gtk_xine_set_param (GtkXine *gtx,
130
gint gtk_xine_get_param (GtkXine *gtx,
133
gint gtk_xine_get_audio_lang (GtkXine *gtx,
136
gint gtk_xine_get_spu_lang (GtkXine *gtx,
140
void gtk_xine_set_fullscreen (GtkXine *gtx,
143
gint gtk_xine_is_fullscreen (GtkXine *gtx);
145
void gtk_xine_set_resize_factor (GtkXine *gtx,
146
double factor /* 0.0 => don't resize */);
148
gint gtk_xine_get_current_frame (GtkXine *gtx,
154
gint gtk_xine_get_log_section_count(GtkXine *gtx);
155
gchar **gtk_xine_get_log_names (GtkXine *gtx);
156
gchar **gtk_xine_get_log (GtkXine *gtx,
158
void gtk_xine_register_log_cb (GtkXine *gtx,
162
gchar **gtk_xine_get_browsable_input_plugin_ids (GtkXine *gtx) ;
163
xine_mrl_t **gtk_xine_get_browse_mrls (GtkXine *gtx,
164
const gchar *plugin_id,
165
const gchar *start_mrl,
167
gchar **gtk_xine_get_autoplay_input_plugin_ids (GtkXine *gtx);
168
gchar **gtk_xine_get_autoplay_mrls (GtkXine *gtx,
169
const gchar *plugin_id,
171
gchar *gtk_xine_get_file_extensions (GtkXine *gtx);
172
gchar *gtk_xine_get_mime_types (GtkXine *gtx);
174
const char *gtk_xine_config_register_string (GtkXine *gtx,
176
const char *def_value,
177
const char *description,
180
xine_config_cb_t changed_cb,
183
int gtk_xine_config_register_range (GtkXine *gtx,
187
const char *description,
190
xine_config_cb_t changed_cb,
193
int gtk_xine_config_register_enum (GtkXine *gtx,
197
const char *description,
200
xine_config_cb_t changed_cb,
203
int gtk_xine_config_register_num (GtkXine *gtx,
206
const char *description,
209
xine_config_cb_t changed_cb,
212
int gtk_xine_config_register_bool (GtkXine *gtx,
215
const char *description,
218
xine_config_cb_t changed_cb,
221
int gtk_xine_config_get_first_entry (GtkXine *gtx, xine_cfg_entry_t *entry);
222
int gtk_xine_config_get_next_entry (GtkXine *gtx, xine_cfg_entry_t *entry);
223
int gtk_xine_config_lookup_entry (GtkXine *gtx,
224
const gchar *key, xine_cfg_entry_t *entry);
225
void gtk_xine_config_update_entry (GtkXine *gtx,
226
xine_cfg_entry_t *entry);
227
void gtk_xine_config_load (GtkXine *gtx,
228
const gchar *cfg_filename);
229
void gtk_xine_config_save (GtkXine *gtx,
230
const gchar *cfg_filename);
231
void gtk_xine_config_reset (GtkXine *gtx);
233
xine_event_queue_t *gtk_xine_event_new_queue (GtkXine *gtx);
235
void gtk_xine_event_send (GtkXine *gtx,
236
const xine_event_t *event);
238
const char *const *gtk_xine_list_post_plugins_typed (GtkXine *gtx, int type);
239
void gtk_xine_set_vis (GtkXine *gtx,
240
char *id); /* NULL to disable */
242
/* FIXME: OSD missing */
247
#endif /* __cplusplus */
251
#endif /* HAVE_GTK_XINE_H */