diff options
author | Thomas Grill <xovo@users.sourceforge.net> | 2005-10-07 12:58:48 +0000 |
---|---|---|
committer | Thomas Grill <xovo@users.sourceforge.net> | 2005-10-07 12:58:48 +0000 |
commit | 2aefe91f615726931d9e99d5009e1f6e57f623c9 (patch) | |
tree | b0719d79b466aa0558c5ebf52a31222d56bad923 /externals/grill/flext/source/fldsp.h | |
parent | 78768816e2a6450c60ad7aac8e2df0abf40f5c8d (diff) |
bugfixes and optimizations, especially for DSP under Max/MSP
fixed dsp vector offset bug
preprocessed class names now also reflect debug mode (to avoid name clashes)
svn path=/trunk/; revision=3676
Diffstat (limited to 'externals/grill/flext/source/fldsp.h')
-rw-r--r-- | externals/grill/flext/source/fldsp.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/externals/grill/flext/source/fldsp.h b/externals/grill/flext/source/fldsp.h index 91cbccb0..b85bbe07 100644 --- a/externals/grill/flext/source/fldsp.h +++ b/externals/grill/flext/source/fldsp.h @@ -55,13 +55,19 @@ public: t_sample *const *InSig() const { return vecs; } //! returns input vector - t_sample *InSig(int i) const { return vecs[i]; } + t_sample *InSig(int i) const { return InSig()[i]; } //! returns array of output vectors (CntOutSig() vectors) - t_sample *const *OutSig() const { return vecs+CntInSig(); } + // \todo cache that returned pointer + t_sample *const *OutSig() const + { + int i = CntInSig(); + // we have at least one actual dsp in vector + return vecs+(i?i:1); + } //! returns output vector - t_sample *OutSig(int i) const { return vecs[CntInSig()+i]; } + t_sample *OutSig(int i) const { return OutSig()[i]; } //! typedef describing a signal vector typedef t_sample *t_signalvec; |