Quick question on VST audio buffers, I've used this in audio effects without any issue. However, not been able to get working with Synth projects works ok in RACKAFX but not in DAW just makes no sound (Ableton & Reaper). Compiled as VST and tried using the RACKAFX DLL that rackafx produces.
Have m_bWantVSTBuffers = true; set in DXSYNTH.CPP. Commented out the process audio frame code as well.
Below is a quick example code for testing, for the DX synth works ok in Rackafx but not in DAW.
Also unrelated but do you know how I get a VST code from steinberg or AU code from Apple ?
bool __stdcall CDXSynth::processVSTAudioBuffer(float** inBuffer, float** outBuffer, UINT uNumChannels, int inFramesToProcess)
float* pOutputL = outBuffer;
float* pOutputR= outBuffer;
while (--inFramesToProcess >= 0)
double dLeftAccum = 0.0;
double dRightAccum = 0.0;
float fMix = 0.25;
double dLeft = 0.0;
double dRight = 0.0;
// --- loop and accumulate voices
for (int i = 0; i<MAX_VOICES; i++)
// --- render synth
// --- accumulate and scale
dLeftAccum += fMix*dLeft;
dRightAccum += fMix*dRight;
// Left channel processing
*pOutputL = dLeftAccum;
// If there is a right channel
*pOutputR = dRightAccum;
// advance pointers
// all OK
Ok, you need to do a manual update of your project to add new features that were added in RackAFX v6.8 - one of those is sample accurate MIDI with VST and specifically involving the processVSTBuffers( ) function. The other feature involves sample accurate parameter handling for VST3 plugins only (they are the only ones that support this). I've added a new Forum and topic that has the link for the document to do the updating. Fortunately, it's pretty simple and involves cutting and pasting a few bits of code. I tested it with your DX Synth code and it worked fine. I did notice that you have the smoothParameters( ) function in the wrong place - it should be inside the frame loop rather than outside.
Newly created projects do not require any updates as they have the code in place. So, another way to see an example of the new code is to just create a new project and use the Technical Note on the link provided to understand what's going on.
If you have any questions or other issues, please address them in the newly created Forum at the above link.
Most Users Ever Online: 152
Currently Browsing this Page:
Guest Posters: 1
Newest Members:Jas, Rowan, sojourn, fabhenr, rg1, Niklas, Wutru, Tim Campbell, Danny Jonel, Valentin
Moderators: W Pirkle: 573
Administrators: Tom: 74, JD Young: 80, Will Pirkle: 0, W Pirkle: 573, VariableCook: 3