Reaktor Primary - 2. Building a Synth: Adding More Elements

The last tutorial saw us build a basic polyphonic synth where you could switch the oscillator types. This one follows on from the same design so either follow the steps in that tutorial first, or use this image as a reference. We are going to add more elements to the design to allow us to shape the volume, as well as use two different oscillators at once. Below is what we are aiming to achieve:




So, starting off where we last ended, we have our very basic synth, with four oscillators, each selectable via the switch. I will remind you of the Audio Voice Combiners needed to allow the outputs of the polyphonic modules to combine so they are received by the monophonic outputs. 

Step one in this tutorial is to right click and select New Macro. A macro is a container where you can add modules, it is a way to keep everything tidy. Normally for each section of the instrument/effect, you would have a dedicated macro.


Next, we select all the oscillators, the switch, and the audio voice combiner, and cut the selection via a right click menu.


Select the macro and enter it by double clicking, you are now inside the macro.


You can tell what level you are in by the bar under the instrument panel, here, it says Panel > New > Macro. Right click and paste the cut items so that they are now in the macro itself.


We need a way for the MIDI data to get in, as well as the Audio signal to get out, this can be done by creating input and output ports, as are seen in the main folder view. These are found by right clicking, selecting Built in Module, then are found in the Terminal Sub-Menu.


You can duplicate the In Port because we want an Input for Both Pitch and Amplitude/Gate to control the P, and A inputs of the Oscillators. There should now be two input ports, and one output.


Rename the input ports to "P" and "G", then connect them up as done in the previous tutorial so it looks like the image below.


Make sure the MIDI inputs are connected to the input ports of the Macro (double click on the window to leave the Macro back into the main window) so they are correctly sent to the oscillators inside. You will notice that there is no real difference aside from all of the clutter is tidy now. Ensure the outputs are also connected. This stage should be able to work if a key is pressed. Make sure to rename the macro to Oscillator because more macros will be made as the synth becomes more complex.


Now, we are going to make the sound more interesting. Let's first add a volume envelope so that the note isn't just off/on, but reacts naturally to a note press. We do this by adding a volume envelope. From this point onwards, almost every new feature created will be made in its own macro, so create a new macro, and name it ADSR. 

ADSR stands for Attack, Decay, Sustain, and Release. I wrote a fairly detailed guide on what these are last year, so please do check it out if you need a refresher. This is one of the most important parts of a synth .


Double click on the ADSR Macro to enter it and right click to open up the menu. Select LFO, Envelope in the Built in Modules folder, and look down to find the ADSR module. Add it to the macro. We also want to add an input which detects when a note is hit, and an output to send the envelope signal to the A input of the oscillators. Name the Input "G", and the output "A".


Once we have the macro set up, with the ADSR module inside, we can connect the Macro's G input to the G input of the module. You will then notice there are four other input slots for the module, and one output. This is the part where we start adding proper controls to our synth.

Right click on one of the inputs (let's start with the A input) and select Create Control this will create a knob which is visible in the panel view above. Make a control for each of the four inputs A, D, S, and R.


You will notice that each control knob loads on top of each other in the panel view, to start editing what the panel/faceplate of the synth looks like, click on the padlock button to unlock it. You are now able to arrange the knobs and controls to how you see fit. Pretty much every synth follows the convention of having the ADSR knobs in a row, following the order in the name.


Below shows the result of rearranging the panel view to make a nice, clear row of knobs next to the oscillator selection switches. Connect the output of the ADSR module to the output of the macro and then exit the macro by double clicking on the empty space in the window.


Now we just need to hook up the ADSR to the oscillators. Make sure the ADSR macro is receiving the MIDI gate input and connect the A output of the ADSR macro to the G input of the Oscillator macro (this will replace the wire already in place as only one connection can be received).


Now we have a polyphonic, single-switchable-oscillator, synth, with a volume envelope. Sounds smart but this is more primitive than pretty much any synth you will encounter. Since this article is titled "Adding More Elements", let's continue doing just that! If you haven't considered it yet, one of the main advantages of a macro is you can easily duplicate everything inside it by right clicking on the macro itself. It allows quickly replicable structures which save a large amount of time, once set up.

You are able to save your macros as you make them, so it is often worth watching what macros you make regularly and just save them as a template. ADSR macros in particular are worth saving, as you can guarantee that every synth you build will need at least one.

For the second part of this tutorial, we are going to bulk out the synth by doubling the oscillators. This means that there are going to be two oscillator macros, with independently switchable waveforms. Select the oscillator macro and hit duplicate. Rename them to "Oscillator 1" and "Oscillator 2", then make sure that the MIDI Note In, and Envelope is connected to each.

We need to combine these two signals so let's use a Math function called Add (found in the menu). This will add the two signals together. 


The add module adds the two polyphonic signals together, but for it to be received by the output, we need to combine the voices into a single signal using an Audio Voice Combiner. This is quite a confusing concept, so I recommend you don't give up here, it begins to make sense over time. To try and clear things up, I made this image explanation

Below, you will see how the synth structure should look at this stage. Make sure to unlock the Panel view again and arrange the extra oscillator's switch controls so they are not overlapping.


The final element which we are going to add to the synth today, is a second ADSR. This will mean there are two ADSRs, each controlling one of the oscillators. Duplicate the ADSR macro and name them "ADSR 1", and "ADSR 2". Select the output of ADSR 2 to go to the G input of Oscillator 2. Rearrange the panel view so that the oscillators and ADSRs are in line with their correct counterparts. 

Finally save your work so far so we can continue onwards in our journey through Reaktor's Primary environment.