summaryrefslogtreecommitdiffstats
path: root/arts/modules/effects/freeverb/allpass.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'arts/modules/effects/freeverb/allpass.cpp')
-rw-r--r--arts/modules/effects/freeverb/allpass.cpp36
1 files changed, 36 insertions, 0 deletions
diff --git a/arts/modules/effects/freeverb/allpass.cpp b/arts/modules/effects/freeverb/allpass.cpp
new file mode 100644
index 00000000..ca4d8bc5
--- /dev/null
+++ b/arts/modules/effects/freeverb/allpass.cpp
@@ -0,0 +1,36 @@
+// Allpass filter implementation
+//
+// Written by Jezar at Dreampoint, June 2000
+// http://www.dreampoint.co.uk
+// This code is public domain
+
+#include "allpass.hpp"
+
+allpass::allpass()
+{
+ bufidx = 0;
+}
+
+void allpass::setbuffer(float *buf, int size)
+{
+ buffer = buf;
+ bufsize = size;
+}
+
+void allpass::mute()
+{
+ for (int i=0; i<bufsize; i++)
+ buffer[i]=0;
+}
+
+void allpass::setfeedback(float val)
+{
+ feedback = val;
+}
+
+float allpass::getfeedback()
+{
+ return feedback;
+}
+
+//ends