Permalink
Browse files

whirl: register control functions first -> remember initial state

  • Loading branch information...
1 parent 6b10197 commit a3466c6a6eb2700d229b8d642cf5a21931d9bb93 @x42 x42 committed Mar 23, 2013
Showing with 3 additions and 3 deletions.
  1. +3 −3 b_whirl/whirl.c
View
@@ -783,9 +783,6 @@ void initWhirl (struct b_whirl *w, void *m, double rate) {
w->SampleRateD = rate;
w->midi_cfg_ptr = m; // used for notify -- translate "rotary.speed-*"
- initTables (w);
- computeRotationSpeeds(w);
-
memset(w->HLbuf, 0, BUF_SIZE_SAMPLES);
memset(w->HRbuf, 0, BUF_SIZE_SAMPLES);
memset(w->DLbuf, 0, BUF_SIZE_SAMPLES);
@@ -813,6 +810,9 @@ void initWhirl (struct b_whirl *w, void *m, double rate) {
useMIDIControlFunction (m, "whirl.horn.deceleration", setHornDeceleration, (void*)w);
useMIDIControlFunction (m, "whirl.drum.acceleration", setDrumAcceleration, (void*)w);
useMIDIControlFunction (m, "whirl.drum.deceleration", setDrumDeceleration, (void*)w);
+
+ initTables (w);
+ computeRotationSpeeds(w);
}
/*

0 comments on commit a3466c6

Please sign in to comment.