has anyone here implemented a vst synth before?
if so- can you give me a basic overview of the different processing blocks / the abstract architecture of how to code a synth. say a simple monophonic subtractive synth with say a sawtooth wav for the oscillator...
feel free to elaborate or take this topic and make a straw to drink margarita's out of.
if so- can you give me a basic overview of the different processing blocks / the abstract architecture of how to code a synth. say a simple monophonic subtractive synth with say a sawtooth wav for the oscillator...
feel free to elaborate or take this topic and make a straw to drink margarita's out of.
-
Re: basic vst synth overview?
Sat, April 3, 2004 - 1:19 PMI haven't programmed a VST synth yet, but I'm working on it (actually probably an AudioUnit first). I have programmed synth blocks in PD.
The basic elements:
MIDI input processor -> oscillator -> filter -> amplifier
mod stuff: MIDI input -> LFOs + Envelope Generators -> Osc, Filter and Amplifier
That's about as blocky and abstract as you can get. Maybe I misunderstood your question?
You can find lots of VST source code of you google for it.... -
-
Re: basic vst synth overview?
Tue, May 8, 2007 - 5:22 PMI have used PD to make a vst effect using Joseph Sarlo's externals, This works on Windows only so far. I think Max/MSP can also output patchs to VST and other pluggin flavours.
-
-
Re: basic vst synth overview?
Mon, April 9, 2007 - 5:47 PMhe VSTSDK actually comes with (simple/crude) example source code that does just what you ask (called VSTXSynth).
If you don't want to look at the SDK examples, here is a crude summary:
First you need a table which contains a ratio for every MIDI note (so you aren't calculating these on every note event), and you have a lookup 'wave' table which contains the desired waveform (though not really needed for a 'clinical' sawtooth as your phase accumulator for the lookup is a sawtooth itself). The lookup table should be at the very least 4096 samples long, or else you'll have a lot of aliasing/artifacts to deal with. Every sample you are accumulating the phase (table position) for the current note (voice), based around the host sample rate / note frequency, and then you access the wavetable to get the resultant "sample" which becomes the signal output.
The tricky part is making it sound good, yet CPU-friendly (as VSTXSynth is intentionally simple/crude) which requires bandlimiting/oversampling on the wavetable.