diff options
author | Thomas Grill <xovo@users.sourceforge.net> | 2002-12-06 05:34:40 +0000 |
---|---|---|
committer | Thomas Grill <xovo@users.sourceforge.net> | 2002-12-06 05:34:40 +0000 |
commit | af12d7d5cd541b0d02b31a00e6e3918ae209d8eb (patch) | |
tree | acf0f8d8341dc0583651a665c62a522585e7ec30 /externals/grill/flext/source | |
parent | 420a758195fea188311fdcd24bff4be2c2afebfb (diff) |
""
svn path=/trunk/; revision=280
Diffstat (limited to 'externals/grill/flext/source')
-rw-r--r-- | externals/grill/flext/source/fldefs.h | 4 | ||||
-rw-r--r-- | externals/grill/flext/source/flsndobj.cpp | 15 | ||||
-rw-r--r-- | externals/grill/flext/source/flsndobj.h | 8 | ||||
-rw-r--r-- | externals/grill/flext/source/flstdc.h | 2 |
4 files changed, 22 insertions, 7 deletions
diff --git a/externals/grill/flext/source/fldefs.h b/externals/grill/flext/source/fldefs.h index b670bf76..14f2e012 100644 --- a/externals/grill/flext/source/fldefs.h +++ b/externals/grill/flext/source/fldefs.h @@ -835,6 +835,8 @@ FLEXT_CALL_PRE(M_FUN)(this,ARG1,ARG2,ARG3,ARG4,ARG5) //! @} FLEXT_D_METHOD +#if defined(FLEXT_ATTRIBUTES) && FLEXT_ATTRIBUTES == 1 + /*! \defgroup FLEXT_D_ATTRIB Attribute definition \note These have to reside inside the class declaration @{ @@ -1141,6 +1143,8 @@ AddAttrib(NAME,(bool (*)(flext_base *,int &))(FLEXT_GET_PRE(FUN)),(bool (*)(flex //! @} FLEXT_D_ATTRIB +#endif // FLEXT_ATTRIBUTES + //! @} FLEXT_DEFS diff --git a/externals/grill/flext/source/flsndobj.cpp b/externals/grill/flext/source/flsndobj.cpp index e377b4a7..c3b54014 100644 --- a/externals/grill/flext/source/flsndobj.cpp +++ b/externals/grill/flext/source/flsndobj.cpp @@ -8,9 +8,18 @@ flext_sndobj::flext_sndobj(): smprt(0),blsz(0) {} -flext_sndobj::~flext_sndobj() +bool flext_sndobj::Init() +{ + bool ret = flext_dsp::Init(); + inobjs = CntInSig(); + outobjs = CntOutSig(); + return ret; +} + +void flext_sndobj::Exit() { ClearObjs(); + flext_dsp::Exit(); } void flext_sndobj::ClearObjs() @@ -43,13 +52,13 @@ void flext_sndobj::m_dsp(int n,t_sample *const *in,t_sample *const *out) smprt = Samplerate(); // set up sndobjs for inlets and outlets - inobj = new Inlet *[inobjs = CntInSig()]; + inobj = new Inlet *[inobjs]; tmpobj = new SndObj *[inobjs]; for(i = 0; i < inobjs; ++i) { inobj[i] = new Inlet(in[i],blsz,smprt); tmpobj[i] = new SndObj(NULL,blsz,smprt); } - outobj = new Outlet *[outobjs = CntInSig()]; + outobj = new Outlet *[outobjs]; for(i = 0; i < outobjs; ++i) outobj[i] = new Outlet(out[i],blsz,smprt); NewObjs(); diff --git a/externals/grill/flext/source/flsndobj.h b/externals/grill/flext/source/flsndobj.h index 30099404..c56ba07b 100644 --- a/externals/grill/flext/source/flsndobj.h +++ b/externals/grill/flext/source/flsndobj.h @@ -6,8 +6,8 @@ WARRANTIES, see the file, "license.txt," in this distribution. */ -#ifndef FLEXT_SNDOBJ -#define FLEXT_SNDOBJ +#ifndef __FLSNDOBJ_H +#define __FLSNDOBJ_H #include "flext.h" @@ -25,7 +25,6 @@ class flext_sndobj: public: flext_sndobj(); - virtual ~flext_sndobj(); // these have to be overridden in child classes virtual void NewObjs() {} @@ -37,6 +36,9 @@ public: SndIO &OutObj(int i) { return *outobj[i]; } protected: + virtual bool Init(); + virtual void Exit(); + virtual void m_dsp(int n,t_sample *const *in,t_sample *const *out); virtual void m_signal(int n,t_sample *const *in,t_sample *const *out); diff --git a/externals/grill/flext/source/flstdc.h b/externals/grill/flext/source/flstdc.h index bf0ddd23..adf28b0d 100644 --- a/externals/grill/flext/source/flstdc.h +++ b/externals/grill/flext/source/flstdc.h @@ -29,7 +29,7 @@ WARRANTIES, see the file, "license.txt," in this distribution. #pragma warning (disable:4091 4005) #endif -#if FLEXT_OS == FLEXT_OS_WIN +#if FLEXT_OS == FLEXT_OS_WIN && !defined(NT) #define NT #endif |