zynaddsubfx

ZynAddSubFX open source synthesizer
Log | Files | Refs | Submodules | LICENSE

commit 639a06b0cb18c44aad408fc68c1c032bba1b31fd
parent 6bc0b69cc5cfc61f63f88f077b546a01c0729eb6
Author: Mark McCurry <mark.d.mccurry@gmail.com>
Date:   Mon,  1 Jun 2009 10:20:13 -0400

Misc/Stereo   Added Stereo(const T &val) constructor

Diffstat:
Msrc/Misc/Stereo.C | 5+++++
Msrc/Misc/Stereo.h | 4++++
2 files changed, 9 insertions(+), 0 deletions(-)

diff --git a/src/Misc/Stereo.C b/src/Misc/Stereo.C @@ -5,6 +5,11 @@ Stereo<T>::Stereo(const T &left, const T &right) {} template <class T> +Stereo<T>::Stereo(const T &val) + :leftChannel(val),rightChannel(val) +{} + +template <class T> void Stereo<T>::operator=(const Stereo<T> & nstr) { leftChannel=nstr.leftChannel; diff --git a/src/Misc/Stereo.h b/src/Misc/Stereo.h @@ -23,6 +23,10 @@ template <class T> class Stereo{ public: Stereo(const T &left,const T &right); + + /**Initializes Stereo with left and right set to val + * @param val the value for both channels*/ + Stereo(const T &val); ~Stereo(){}; void operator=(const Stereo<T> &smp);