# HG changeset patch # User William Pitcock # Date 1190130434 18000 # Node ID fd4cd1945b91d529a393321beb964027ccc07dd1 # Parent 7a2b667bab4bb70f42ff6cb367d4a466f556ca35 Connect volumecontrol flow to the work pipeline. diff -r 7a2b667bab4b -r fd4cd1945b91 src/audacious/output.c --- a/src/audacious/output.c Tue Sep 18 10:41:40 2007 -0500 +++ b/src/audacious/output.c Tue Sep 18 10:47:14 2007 -0500 @@ -37,6 +37,7 @@ #include "configdb.h" #include "effect.h" +#include "volumecontrol.h" #include @@ -171,7 +172,10 @@ if (!op_data.current_output_plugin->get_volume) return; - op_data.current_output_plugin->get_volume(l, r); + if (cfg.software_volume_control) + volumecontrol_get_volume_state(l, r); + else + op_data.current_output_plugin->get_volume(l, r); } void @@ -183,7 +187,10 @@ if (!op_data.current_output_plugin->set_volume) return; - op_data.current_output_plugin->set_volume(l, r); + if (cfg.software_volume_control) + volumecontrol_set_volume_state(l, r); + else + op_data.current_output_plugin->set_volume(l, r); } void @@ -520,6 +527,9 @@ length = effect_do_mod_samples(&ptr, length, op_state.fmt, op_state.rate, op_state.nch); + if (cfg.software_volume_control) + volumecontrol_pad_audio(ptr, length, op_state.fmt, op_state.nch); + writeoffs = 0; while (writeoffs < length) {