Mercurial > audlegacy-plugins
diff src/amidi-plug/backend-fluidsynth/b-fluidsynth.c @ 1414:5f892afeb8e1 audacious-plugins-1.4.0-dr2
- amidi-plug 0.8 beta1; support for gthread and v3 plugin system; needs testing and refinements
author | Giacomo Lozito <james@develia.org> |
---|---|
date | Mon, 06 Aug 2007 14:01:24 +0200 |
parents | d2e508857ded |
children |
line wrap: on
line diff
--- a/src/amidi-plug/backend-fluidsynth/b-fluidsynth.c Mon Aug 06 03:20:01 2007 +0200 +++ b/src/amidi-plug/backend-fluidsynth/b-fluidsynth.c Mon Aug 06 14:01:24 2007 +0200 @@ -163,12 +163,21 @@ gint sequencer_queue_start( void ) { + sc.last_sample_time = 0; g_timer_start( sc.timer_seq ); /* reset the sequencer timer */ g_timer_start( sc.timer_sample ); /* reset the sampler timer */ return 1; } +gint sequencer_queue_stop( void ) +{ + g_timer_stop( sc.timer_seq ); + g_timer_stop( sc.timer_sample ); + return 1; +} + + gint sequencer_event_init( void ) { /* common settings for all our events */ @@ -274,6 +283,17 @@ } +gint sequencer_event_allnoteoff( gint unused ) +{ + gint c = 0; + for ( c = 0 ; c < 16 ; c++ ) + { + fluid_synth_all_notes_off( sc.synth , c ); + } + return 1; +} + + gint sequencer_output( gpointer * buffer , gint * len ) { gdouble current_time = g_timer_elapsed( sc.timer_sample , NULL );