Index: ChangeLog
===================================================================
RCS file: /cvs/gnome/beast/plugins/ChangeLog,v
retrieving revision 1.178
diff -u -p -r1.178 ChangeLog
--- ChangeLog	10 May 2006 13:13:59 -0000	1.178
+++ ChangeLog	15 May 2006 20:13:18 -0000
@@ -1,3 +1,11 @@
+Mon May 15 22:09:53 2006  Stefan Westerfeld  <stefan@space.twc.de>
+
+	* davsyndrum.c (dav_syn_drum_update_modules): It is important to
+	update sample rate dependant parameters in the "params" struct within
+	the object, because the "params" struct within the object will be used
+	by dav_syn_drum_context_create to initialize the state for the
+	modules. This fixes #337703.
+
 Wed May 10 15:12:26 2006  Stefan Westerfeld  <stefan@space.twc.de>
 
 	* bseblockutils.cc: Minor optimizations, introduced a few LIKELY()
Index: davsyndrum.c
===================================================================
RCS file: /cvs/gnome/beast/plugins/davsyndrum.c,v
retrieving revision 1.28
diff -u -p -r1.28 davsyndrum.c
--- davsyndrum.c	8 May 2006 01:37:22 -0000	1.28
+++ davsyndrum.c	15 May 2006 20:13:18 -0000
@@ -357,7 +357,6 @@ dav_syn_drum_update_modules (DavSynDrum 
 {
   if (BSE_SOURCE_PREPARED (self))
     {
-      DavSynDrumParams params = self->params;
       /* Calculate the half life rate given:
        *  half - the length of the half life
        *  rate - time divisor (usually the # calcs per second)
@@ -366,7 +365,9 @@ dav_syn_drum_update_modules (DavSynDrum 
        *
        * ln(1/2) = -ln(2) = -BSE_LN2 = -0.693147...
        */
-      params.res = exp (-BSE_LN2 / (self->half * bse_engine_sample_freq()));
+      self->params.res = exp (-BSE_LN2 / (self->half * bse_engine_sample_freq()));
+
+      DavSynDrumParams params = self->params;
       /* update all DavSynDrumModules. take a look at davxtalstrings.c
        * if you don't understand what this code does.
        */
