aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Blechmann <timblech@users.sourceforge.net>2005-10-09 09:55:24 +0000
committerIOhannes m zmölnig <zmoelnig@iem.at>2015-10-14 15:12:00 +0200
commit94ab8a946255bda2bb28cb94c064e3b899774bc5 (patch)
tree18c47f0e1e9f45504967fc4c650dce69a8312730
parentd79c9f0eeaac84d67504c9b439d9248919f3325f (diff)
more flext-like dsp callbacks
svn path=/trunk/externals/tb/; revision=3686
-rw-r--r--chaos/src/chaos_dsp.hpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/chaos/src/chaos_dsp.hpp b/chaos/src/chaos_dsp.hpp
index 16e2820..821b544 100644
--- a/chaos/src/chaos_dsp.hpp
+++ b/chaos/src/chaos_dsp.hpp
@@ -39,15 +39,16 @@ public:
/* cubic interpolation */
void m_signal_c(int n, t_sample *const *insigs,t_sample *const *outsigs);
- virtual void m_signal(int n, t_sample *const *insigs,t_sample *const *outsigs)
+ virtual void CbSignal()
{
- (this->*m_routine)(n,insigs,outsigs);
+ (this->*m_routine)(Blocksize(),InSig(),OutSig());
}
- virtual void m_dsp(int n, t_sample *const *insigs,t_sample *const *outsigs)
+ virtual bool CbDsp()
{
m_sr = Samplerate();
set_freq(m_freq); /* maybe we have to change the interpolation mode */
+ return true;
}
void (thisType::*m_routine)(int n, t_sample *const *insigs,t_sample *const *outsigs);
@@ -130,14 +131,14 @@ public:
if (f < 0) /* we can't go back in time :-) */
f = -f;
- if( f <= m_sr * 0.5 )
+ if( f <= m_sr * 0.1 )
{
if (m_freq >= m_sr * 0.5)
set_imethod(m_imethod);
m_freq = f;
m_invfreq = 1.f / f;
}
- else if (f > m_sr * 0.5)
+ else if (f > m_sr * 0.1)
{
m_freq = f;
m_invfreq = 1.f / f;