shithub: aubio

Download patch

ref: 5f0ad5072a4f6e05f22492a5a9b6a9ae12ed5e07
parent: 1239d230255db345d182047be6736c0c884343b8
author: Paul Brossier <piem@piem.org>
date: Sun Mar 26 11:39:27 EDT 2017

src/synth/wavetable.c: always clamp wavetable

--- a/examples/aubioonset.c
+++ b/examples/aubioonset.c
@@ -45,7 +45,6 @@
   }
   if (mix_input) {
     aubio_wavetable_do (wavetable, ibuf, obuf);
-    fvec_clamp(obuf, 1.);
   } else {
     aubio_wavetable_do (wavetable, obuf, obuf);
   }
--- a/examples/aubiotrack.c
+++ b/examples/aubiotrack.c
@@ -48,7 +48,6 @@
   }
   if (mix_input) {
     aubio_wavetable_do (wavetable, ibuf, obuf);
-    fvec_clamp(obuf, 1.);
   } else {
     aubio_wavetable_do (wavetable, obuf, obuf);
   }
--- a/src/synth/wavetable.c
+++ b/src/synth/wavetable.c
@@ -103,6 +103,7 @@
     for (i = 0; i < output->length; i++) {
       output->data[i] += input->data[i];
     }
+    fvec_clamp(obuf, 1.);
   }
 }