changeset 4851:8ebd8358de04

On second thought, apply equalizer settings on (re)opening audio
author John Lindgren <john.lindgren@tds.net>
date Mon, 13 Apr 2009 01:18:06 -0400
parents 47b72fc78e92
children c4698861e8fb
files src/audlegacy/equalizer.c src/audlegacy/output.c
diffstat 2 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/audlegacy/equalizer.c	Mon Apr 13 00:53:26 2009 -0400
+++ b/src/audlegacy/equalizer.c	Mon Apr 13 01:18:06 2009 -0400
@@ -30,7 +30,6 @@
 }
 
 void init_equalizer (void) {
-   change_equalizer ();
    hook_register ("equalizer changed");
    if (hook_associate ("equalizer changed", (HookFunction) change_equalizer, 0))
       abort ();
--- a/src/audlegacy/output.c	Mon Apr 13 00:53:26 2009 -0400
+++ b/src/audlegacy/output.c	Mon Apr 13 01:18:06 2009 -0400
@@ -29,6 +29,8 @@
 #  include "config.h"
 #endif
 
+#include "audconfig.h"
+#include "equalizer.h"
 #include "output.h"
 #include "main.h"
 #include "input.h"
@@ -302,6 +304,8 @@
         op_state.rate = rate;
         op_state.nch = nch;
 
+        output_set_eq (cfg.equalizer_active, cfg.equalizer_preamp,
+         cfg.equalizer_bands);
         return TRUE;
     } else {
         return FALSE;