Hi .I’m going to use GVerb class in my own application , but it’s a little fuzzy for me to understand how to do that .
Anyone know where is the GVerb relative code in AudaCity source project ? and dose GVerb support mono and/or stereo ?
Thank you.
The source code for GVerb is available from http://plugin.org.uk/
GVerb is a LADSPA plug-in. http://www.ladspa.org/
Most of the support files are in the Audacity source: src/effects/ladspa
As GVerb and a couple of other LADSPA plug-ins have been ported to Windows, there is some additional Windows specific stuff in: win/LADSPA_plugins-win
GVerb is a mono effect but if you want a stereo effect you could run each channel through the effect separately and then pan and mix the processed signals with the dry signals as required.
Thank you , It works now,but not very well .
Here is primary code in my project:
gverb_new(16000.f, 300.0f, 50.0f, 7.0f, 0.5f, 15.0f, 0.5f, 0.5f, 0.5f);
AudioSampleType *samples = (AudioSampleType*)dataBuffer.mBuffers[0].mData;
float lval,rval;
//float dryc = DB_CO(0); //what is this?
for (int i = 0; i< fileLengthFrames; i++) {
float value = (float)samples[i] / 32768.f; //convert AudioSampleType(SInt16) to float
gverb_do(_verb, value, &lval, &rval);
samples[i] = (SInt16)(lval * 32767.f); //convert float to SInt16
}
Anything wrong with my code ? what’s the meaning of lval & rval ?