sinek/include gtkxine.h,1.1,1.2

[email protected] Sun, 05 Jan 2003 03:37:14 -0800
Newsgroups gmane.comp.video.sinek.cvs
Message-ID <[email protected]>
Update of /cvsroot/sinek/sinek/include
In directory sc8-pr-cvs1:/tmp/cvs-serv19844/include

Modified Files:
	gtkxine.h 
Log Message:
compiles.. untested


Index: gtkxine.h
===================================================================
RCS file: /cvsroot/sinek/sinek/include/gtkxine.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- gtkxine.h	5 Jan 2003 09:08:49 -0000	1.1
+++ gtkxine.h	5 Jan 2003 11:37:12 -0000	1.2
@@ -12,7 +12,7 @@
 #define GTK_XINE_H
 
 #include <gtk/gtk.h>
-#include <stdlib.h>
+#include <xine.h>
 
 #ifdef __cplusplus
 extern "C" {
@@ -42,12 +42,12 @@
 
 enum _GtkXinePlaybackSpeed
 {
-	GTK_XINE_PLAYBACK_SPEED_PAUSE,
-	GTK_XINE_PLAYBACK_SPEED_QUARTER_SLOW,
-	GTK_XINE_PLAYBACK_SPEED_HALF_SLOW,
-	GTK_XINE_PLAYBACK_SPEED_NORMAL,
-	GTK_XINE_PLAYBACK_SPEED_TWICE_FAST,
-	GTK_XINE_PLAYBACK_SPEED_FOUR_FAST,
+	GTK_XINE_PLAYBACK_SPEED_PAUSE          = XINE_SPEED_PAUSE,
+	GTK_XINE_PLAYBACK_SPEED_QUARTER_SLOW   = XINE_SPEED_SLOW_4,
+	GTK_XINE_PLAYBACK_SPEED_HALF_SLOW      = XINE_SPEED_SLOW_2,
+	GTK_XINE_PLAYBACK_SPEED_NORMAL         = XINE_SPEED_NORMAL,
+	GTK_XINE_PLAYBACK_SPEED_TWICE_FAST     = XINE_SPEED_FAST_2,
+	GTK_XINE_PLAYBACK_SPEED_FOUR_FAST      = XINE_SPEED_FAST_4,
 };
 
 #if 0
@@ -64,17 +64,40 @@
 };
 #endif
 
+
+
+/**
+ ** The default behavior for the warning handler is to print to stderr.
+ ** The default behavior for the error handler is to print to stderr, and
+ ** then exit.
+ ** Audio and video drivers default to "auto".  A value of "null" will cause
+ ** them to not load.
+ */
+typedef void (*message_handler_cb) (const char *msg);
+
 GtkType     gtk_xine_get_type             (void);
 GtkWidget*  gtk_xine_new                  (void);
-GtkWidget*  gtk_xine_new_with_values      (const char *fname, const char *audio_driver, const char *video_driver, const char *display_name);
 
-/* config file defaults to ~/.xine/config */
-void        gtk_xine_select_config_file   (GtkXine *xine, const char *fname);
-/* audio/video drivers default to "auto" ("null" if unable to load) */
-void        gtk_xine_select_audio_driver  (GtkXine *xine, const char *name);
-void        gtk_xine_select_video_driver  (GtkXine *xine, const char *name);
-//void        gtk_xine_select_video_driver  (GtkXine *xine, const char *name, GtkXineVisualType v);
-void        gtk_xine_select_display       (GtkXine *xine, const char *display_name);
+int         gtk_xine_set_warning_handler  (GtkXine *xine, message_handler_cb cb);
+int         gtk_xine_set_error_handler    (GtkXine *xine, message_handler_cb cb);
+const char *gtk_xine_set_audio_driver     (GtkXine *xine, const char *name);
+const char *gtk_xine_set_video_driver     (GtkXine *xine, const char *name);
+
+/* config file */
+
+int         gtk_xine_config_load          (GtkXine *xine, const char *conffile);
+int         gtk_xine_config_save          (GtkXine *xine, const char *conffile);
+
+const char *gtk_xine_config_register_string (GtkXine *xine, const char *key, const char *default_value);
+int         gtk_xine_config_register_range (GtkXine *xine, const char *key, int default_value, int min, int max);
+int         gtk_xine_config_register_enum (GtkXine *xine, const char *key, int default_value, char **values);
+int         gtk_xine_config_register_num  (GtkXine *xine, const char *key, int default_value);
+int         gtk_xine_config_register_bool (GtkXine *xine, const char *key, int default_value);
+
+int         gtk_xine_config_set           (GtkXine *xine, const char *key, void *value);
+int         gtk_xine_config_get           (GtkXine *xine, const char *key, void **value);
+
+
 
 void        gtk_xine_load                 (GtkXine *xine, const char *mrl);
 void        gtk_xine_play                 (GtkXine *xine);
@@ -82,15 +105,24 @@
 void        gtk_xine_play_from_time       (GtkXine *xine, time_t start);
 void        gtk_xine_stop                 (GtkXine *xine);
 
-void        gtk_xine_select_audio_channel (GtkXine *xine, int channel);
-void        gtk_xine_select_spu_channel   (GtkXine *xine, int channel);
+/* stream parameters */
 
-void        gtk_xine_set_volume           (GtkXine *xine, int volume);
+GtkXinePlaybackSpeed gtk_xine_set_speed   (GtkXine *xine, GtkXinePlaybackSpeed speed);
+GtkXinePlaybackSpeed gtk_xine_get_speed   (GtkXine *xine);
+
+int         gtk_xine_set_audio_channel    (GtkXine *xine, int channel);
+int         gtk_xine_get_audio_channel    (GtkXine *xine);
+int         gtk_xine_set_spu_channel      (GtkXine *xine, int channel);
+int         gtk_xine_get_spu_channel      (GtkXine *xine);
+int         gtk_xine_set_video_channel    (GtkXine *xine, int channel);
+int         gtk_xine_get_video_channel    (GtkXine *xine);
+
+int         gtk_xine_set_volume           (GtkXine *xine, int volume);
 int         gtk_xine_get_volume           (GtkXine *xine);
-void        gtk_xine_set_mute             (GtkXine *xine, int mute);
+int         gtk_xine_set_mute             (GtkXine *xine, int muted);
+int         gtk_xine_get_mute             (GtkXine *xine);
+
 
-void        gtk_xine_set_speed            (GtkXine *xine, GtkXinePlaybackSpeed speed);
-GtkXinePlaybackSpeed gtk_xine_get_speed   (GtkXine *xine);
 
 int         gtk_xine_get_current_position (GtkXine *xine);
 time_t      gtk_xine_get_current_time     (GtkXine *xine);




-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf