# HG changeset patch # User nenolod # Date 1141829222 28800 # Node ID d51a251b542cdc16f4760737ccbc282e856a5cc5 # Parent b8b9d7f5d371014db1cbba4d7837969cecc1a5da [svn] - add get_written_time(), get_output_time(). diff -r b8b9d7f5d371 -r d51a251b542c audacious/output.c --- a/audacious/output.c Tue Mar 07 11:47:20 2006 -0800 +++ b/audacious/output.c Wed Mar 08 06:47:02 2006 -0800 @@ -173,6 +173,24 @@ *(guint16 *) it = GUINT16_SWAP_LE_BE(*(guint16 *) it); } +/* called by input plugin to peek at the output plugin's write progress */ +gint +get_written_time(void) +{ + OutputPlugin *op = get_current_output_plugin(); + + return op->written_time(); +} + +/* called by input plugin to peek at the output plugin's output progress */ +gint +get_output_time(void) +{ + OutputPlugin *op = get_current_output_plugin(); + + return op->output_time(); +} + /* called by input plugin when data is ready */ void produce_audio(gint time, /* position */ diff -r b8b9d7f5d371 -r d51a251b542c audacious/output.h --- a/audacious/output.h Tue Mar 07 11:47:20 2006 -0800 +++ b/audacious/output.h Wed Mar 08 06:47:02 2006 -0800 @@ -43,6 +43,9 @@ void output_set_eq(gboolean, gfloat, gfloat *); void produce_audio(gint, AFormat, gint, gint, gpointer, int *); +gint get_written_time(void); +gint get_output_time(void); + extern OutputPluginData op_data; #endif