Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>you have to add them to an instance of your effect, like so (copy to your editor and search for <em>LOOK HERE</em>):</p> <pre><code>class myPlugin : public AudioEffectX { public: myPlugin (audioMasterCallback audioMaster); ~myPlugin (); // Processing virtual void processReplacing (float** inputs, float** outputs, VstInt32 sampleFrames); virtual void processDoubleReplacing (double** inputs, double** outputs, VstInt32 sampleFrames); virtual void midiOutNoteOn (int iKey, int iVel); virtual void midiOutNoteOff (int iKey, int iVel); // Program virtual void setProgramName (char* name); virtual void getProgramName (char* name); // Parameters virtual void setParameter (VstInt32 index, float value); virtual float getParameter (VstInt32 index); virtual void getParameterLabel (VstInt32 index, char* label); virtual void getParameterDisplay (VstInt32 index, char* text); virtual void getParameterName (VstInt32 index, char* text); virtual bool getEffectName (char* name); virtual bool getVendorString (char* text); virtual bool getProductString (char* text); virtual VstInt32 getVendorVersion (); virtual VstInt32 canDo (char* text); class aFilterL { friend class myPlugin; public: aFilterL (); ~aFilterL (); float fOut1_l; float filterOut1_l; float Out_1_l; float Out_2_l; float* buffer_Out_1_l; float* buffer_Out_2_l; virtual float aFilterMethodL (float a0, float a1, float a2, float b1, float b2, float inputL, float prevInput1L, float prevInput2L) { Out_1_l = buffer_Out_1_l[0]; Out_2_l = buffer_Out_2_l[0]; filterOut1_l = (a0 * inputL) + (a1 * prevInput1L) + (a2 * prevInput2L) - (b1 * Out_1_l) - (b2 * Out_2_l) + 1.0E-25; fOut1_l = filterOut1_l; buffer_Out_2_l[0] = buffer_Out_1_l[0]; buffer_Out_1_l[0] = fOut1_l; return fOut1_l; } }; class aFilterR { friend class myPlugin; public: aFilterR (); ~aFilterR (); float fOut1_r; float filterOut1_r; float Out_1_r; float Out_2_r; float* buffer_Out_1_r; float* buffer_Out_2_r; virtual float aFilterMethodR (float a0, float a1, float a2, float b1, float b2, float inputR, float prevInput1R, float prevInput2R) { Out_1_r = buffer_Out_1_r[0]; Out_2_r = buffer_Out_2_r[0]; filterOut1_r = (a0 * inputR) + (a1 * prevInput1R) + (a2 * prevInput2R) - (b1 * Out_1_r) - (b2 * Out_2_r) + 1.0E-25; fOut1_r = filterOut1_r; buffer_Out_2_r[0] = buffer_Out_1_r[0]; buffer_Out_1_r[0] = fOut1_r; return fOut1_r; } }; /* LOOK HERE */ private: aFilterL filterL; aFilterR filterR; }; myPlugin::myPlugin (audioMasterCallback audioMaster) : AudioEffectX (audioMaster, 1, 1), filterL(), /* LOOK HERE */ filterR() /* LOOK HERE */ { setNumInputs (2); // stereo in setNumOutputs (2); // stereo out setUniqueID ('Gain'); // identify canProcessReplacing (); // supports replacing output canDoubleReplacing (); // supports double precision processing /* LOOK HERE */ //myPlugin *my_aFilter1L = new aFilterL(); //myPlugin *my_aFilter1R = new aFilterR(); } </code></pre> <p>the nested class is only a declaration (sort of like a namespace, but you have a few additional options regarding visibility). declaring a class in this scope does not automatically add filters to the effect, you'll still have to declare them exactly as any static or instance variable of the class.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload