# HG changeset patch # User Andrew O. Shadoura # Date 1218101654 -10800 # Node ID 8de129d0823898ed1adb69e1c226278c087a1798 # Parent bb0638143fc8a9eae0a61f54f14fdaa4b955db90# Parent f084f639e9626de9579999714c2b301372d8d9a7 merge diff -r bb0638143fc8 -r 8de129d08238 src/audacious/output.c --- a/src/audacious/output.c Thu Aug 07 12:29:24 2008 +0300 +++ b/src/audacious/output.c Thu Aug 07 12:34:14 2008 +0300 @@ -682,3 +682,16 @@ SAD_dither_apply_replaygain(sad_state_from_float, &info, &mode); } + +void output_plugin_cleanup(void) +{ + OutputPlugin *op = get_current_output_plugin(); + op->init(); + output_close_audio(); + printf("output plugin cleanupn\n"); +} +void output_plugin_reinit(void) +{ + + printf("output plugin reinit \n"); +} diff -r bb0638143fc8 -r 8de129d08238 src/audacious/output.h --- a/src/audacious/output.h Thu Aug 07 12:29:24 2008 +0300 +++ b/src/audacious/output.h Thu Aug 07 12:34:14 2008 +0300 @@ -70,5 +70,6 @@ extern OutputPlugin psuedo_output_plugin; extern OutputPluginData op_data; - +void output_plugin_cleanup(void); +void output_plugin_reinit(void); #endif /* AUDACIOUS_OUTPUT_H */ diff -r bb0638143fc8 -r 8de129d08238 src/audacious/plugin.h --- a/src/audacious/plugin.h Thu Aug 07 12:29:24 2008 +0300 +++ b/src/audacious/plugin.h Thu Aug 07 12:34:14 2008 +0300 @@ -656,6 +656,8 @@ gboolean (*vfs_fget_be16)(guint16 *value, VFSFile *stream); gboolean (*vfs_fget_be32)(guint32 *value, VFSFile *stream); gboolean (*vfs_fget_be64)(guint64 *value, VFSFile *stream); + void (*output_plugin_cleanup)(void); + void (*output_plugin_reinit)(void); }; /* Convenience macros for accessing the public API. */ @@ -1016,6 +1018,8 @@ #define aud_save_preset_file _audvt->save_preset_file #define aud_equalizer_read_aud_preset _audvt->equalizer_read_aud_preset #define aud_load_preset_file _audvt->load_preset_file +#define aud_output_plugin_cleanup _audvt->output_plugin_cleanup +#define aud_output_plugin_reinit _audvt->output_plugin_reinit #include "audacious/auddrct.h" diff -r bb0638143fc8 -r 8de129d08238 src/audacious/pluginenum.c --- a/src/audacious/pluginenum.c Thu Aug 07 12:29:24 2008 +0300 +++ b/src/audacious/pluginenum.c Thu Aug 07 12:34:14 2008 +0300 @@ -399,6 +399,8 @@ .save_preset_file = save_preset_file, .equalizer_read_aud_preset = equalizer_read_aud_preset, .load_preset_file = load_preset_file, + .output_plugin_cleanup = output_plugin_cleanup, + .output_plugin_reinit = output_plugin_reinit, }; /*****************************************************************/