Following on from our discussion of compression and limiting last month, let's look at how you can use the related processes of gating and expansion within your DAW.
It's a sad fact that unwanted hiss and hum didn't vanish with the passing of analogue tape, because these noises are often part of the source being recorded. In a properly set up studio these noises should be very low in level, but if they aren't then you'll probably have to deal with them using processing.
There are some digital denoising systems which can significantly reduce the level of audible noise without introducing unacceptable side-effects, and I'll be covering such plug-ins in a later article, but first I'd like to explore the more basic techniques of gating and expansion. The main point to keep in mind about gates and expanders is that they only reduce the level of noise during pauses in the wanted material, but in many cases this is adequate, because when the wanted audio is playing it masks the noise. Only if the noise contamination is fairly severe will the audio fail to mask it, except perhaps during very quiet passages. Because such processing only works for pauses, gating and expansion are of limited use on finished mixes, but if you examine the individual tracks of a typical recording, you'll invariably find that there are lots of pauses where the processing can bring about benefits.
For example, a vocal track usually includes gaps between phrases, kick drum tracks have gaps between beats, and even electric guitars and basses stop playing from time to time! While it is easy enough to trim an audio file to remove background noise, silencing all the shorter pauses by hand is extremely tedious, and even those sequencers that offer an automatic silence-stripping facility are not always foolproof. In fact the simplest way to automatically silence pauses is to use a gate.
Gates are based on gain-control devices similar to those used in compressors, but, instead of processing only those signals that exceed the threshold as a compressor does, a gate processes only those signals that fall below the threshold. When a signal falls below the threshold, it is turned down in level or even silenced altogether. It follows then that, if the threshold is set just above the noise floor of the recording, the gate will close during pauses in the wanted audio, thus keeping the pauses nice and quiet.
Figure 1 shows how a gate threshold system operates. However, a basic gate functioning as a simple switch that can only be on or off isn't ideal for this application, as there will be an abrupt change in the noise level as the gate opens and closes, so slowly decaying sounds can be cut off prematurely. To get around this, gates usually have attack and release controls similar to those on compressors.
The attack control determines how quickly the gate opens once the input signal exceeds the threshold. If the attack time is set too short, low-frequency sounds or those with a naturally slow attack may be distorted due to the gate opening abruptly part of the way through a cycle. In most cases, the waveform distortion caused by a gate opening too quickly will be audible as a click. By setting a longer attack time, this problem can be overcome, though instruments with a naturally fast attack, such as drums, are best treated with a fast attack time, otherwise some of their initial transient may be cut off.
A similar problem occurs at the end of the wanted sound — if the sound has a gradual decay, we don't want the gate to suddenly silence the sound before it has had a chance to fully decay naturally. By fitting a release time control, it's possible to adjust how quickly the gate closes when the audio falls below the threshold, so slowly decaying sounds can be treated using a longer release time to make the decay fade away more naturally. Conversely, if a sound stops abruptly, too long a gate release time will mean that any background noise will remain audible until the gate has closed, so we don't want the release time to be too long either. As a rule, the attack time should be set as fast as possible without causing a click, while the release should be set long enough to allow the sound to decay naturally, but not so long as to allow the noise to remain audible after the sound has ended.
Like a compressor, a gate can only deal with a signal once that signal has been received and analysed by the side-chain, so there's always a risk that the leading edge of a sharp transient sound, such as a drum hit, will be lost due to the gate's inability to respond instantly. To be fair, modern gates are very fast, but plug-ins have the advantage that they can be designed so that the side-chain 'looks' at the signal a millisecond or two before it arrives at the gate's main input allowing the gate to start opening just before the transient arrives. This look-ahead facility is only an advantage when dealing with sounds that have a very fast attack, so it is usually switchable or variable where it is provided. Paul White
More Advanced Gating Controls
Although a basic gate can function reasonably well using only the controls mentioned so far, adding a hold control can be useful. The purpose of hold is to delay the gate from entering its release phase until after a short time has elapsed once the input signal has fallen back below the threshold. The main reason for doing this is to avoid an effect known as 'chatter' that occurs when a gate switches on and off very rapidly in the presence of a signal that has an undulating level, such as a decaying guitar chord played through an amplifier with the tremolo switched on. Chatter is only usually a problem with fast attack and release settings, and it is necessary only to increase the hold time until the chattering stops. Chattering can also occur on low-pitched bass sounds, although here it usually sounds like distortion, because the gate may try to switch on and off for each cycle of the waveform. Again, increasing the hold time will cure this problem. Figure 2 shows how the attack, release and hold times work together. In gates with no hold control, a fixed hold time of several milliseconds is usually built in to prevent chatter distortion on low-frequency sounds.
Another more advanced control is hysteresis, which isn't often presented to the user as a control on hardware gates, though it is becoming more common on software plug-ins where extra knobs don't increase manufacturing cost! Hysteresis is yet another means of preventing chattering, and it works by setting two different thresholds a few decibels apart — one for turning the gate on and another for turning it off. The user still has only one threshold to set — the one that opens that gate — but, because of the effect of hysteresis, the signal must fall a few decibels below that value before the gate will start to close again. Virtually all gates have some hysteresis built in to make them behave more smoothly in real-life situations.
A basic gate needs only threshold, attack and release controls, but in some situations, the output sounds more natural if, instead of completely muting the signal during pauses, the gate merely reduces the level. This requires a range control, which in most instances sets by how many decibels the signal will be attenuated when the gate is closed. Applications for the range control include reducing the level of breath noises without silencing them altogether, or treating sounds where there is a significant amount of spill from other instruments. In the latter case, reducing the amount of spill during pauses often sounds more acceptable than muting it altogether.
Gate Or Expander?
Expanders are similar to gates except in one very important detail. Whereas a gate (with its range control set to maximum) will completely silence any signal that falls below the threshold, the expander works like a compressor in reverse and applies gain reduction to below-threshold signals, the amount of gain reduction depending on the expander's ratio setting. A 1:2 expander ratio would mean that for every decibel the input fell below the threshold, the output would fall by 2dB. The main benefit of an expander is that it sounds less heavy-handed than a gate, but when longer release times are being used the difference is less obvious than at short release times. Maintaining the compressor analogy for a moment, a gate can be thought of as an expander with an infinitely high ratio in just the same way as a limiter is a compressor with an infinitely high ratio. Note that, while it is traditional to express the expander ratio as '1:integer', it may also be expressed as a 'fraction:1', for example 0.5:1 instead of 1:2. Paul White
Like the compressor, a gate has a side-chain circuit that measures the level of the incoming audio signal and then compares it with the threshold value set by the user. Different gates use different ways of averaging the incoming signal within the side-chain, but it's becoming increasingly popular in plug-ins to allow the user to choose between peak and RMS side-chain sensing, as is already commonplace in many compressors. Essentially RMS sensing has more of an averaging effect, and closely approximates the way our ears perceive sound levels, whereas peak sensing tracks even the shortest transient peaks. As a rule, peak sensing is best for percussive sounds, while RMS works well for more consistent sounds, such as vocals.
When the signal measured at the side-chain exceeds the threshold, the circuit (or software) generates a control signal to open the gate at a rate set by the attack control. When the signal falls below the threshold, the gate closes according to the setting of the hold and release controls. Where a stereo signal is being gated, both channels need to be controlled in exactly the same way to prevent the signal from appearing to move from side to side in situations where one gate opens or closes before the other. This tends to be automatically handled for plug-ins, whereas a hardware compressor will probably have a stereo link switch on the front panel. If the side-chain input is stereo, this will usually be summed to mono to ensure both channels receive exactly the same control signals.
On some hardware gates and plug-ins the side-chain can be accessed by a signal other than the main input, so that one signal can, in effect, be gated by another. In the case of a plug-in, the usual system is to designate another audio track as the side-chain or keying input. The most commonly discussed example of external gate keying is the kick drum that gates the bass guitar track to tighten up the sound. If the bass guitar is played early, it won't be allowed to pass through the gate until the kick drum causes the gate to open — the earlier it is, the more of its start will be chopped off by the gate action. The bass guitar then decays at a rate set by the hold and release controls, which means it can be made shorter than originally played if required. A similar technique may be used to control the timing of backing vocals by keying them from the lead vocal line or from the backing singer with the best timing.
Keying In Practice
Some gates include a dedicated ducking mode, where the range control sets the amount by which the signal level is ducked. By ducking, we simply mean that the level of one signal drops in the presence of another. The signal to be ducked is fed via the main audio input and the controlling signal is once again sent to the side-chain key input. The gate's attack and release times set the rate at which the levels change in response to the side-chain signal and, in most ducking applications, we want the level to drop fairly quickly then recover a little more gently. Though ducking is most often associated with a DJ's voice controlling the level of the music being played (allowing him to be heard when speaking over the music), it may also be used more subtly to drop some instruments by a few decibels in the mix when the vocals or a solo instrument are present.
Another trick for making use of a gate's side-chain input is if an equaliser is inserted into the side-chain signal path. That way the gate can be made more sensitive to some frequencies than to others, a feature that can help avoid false triggering. For example, if you are gating a snare drum, there may be enough spill from the kick drum to open the gate occasionally. By filtering low frequencies out of the side-chain, the gate can be made less sensitive to the kick, making it easier to set a threshold value that allows only the snare drum through.
Gates with side-chain EQ invariably include a 'listen' mode that lets you hear the signal feeding the side-chain via the gate's output, enabling you to set the filter controls by ear. All you have to do is adjust the EQ controls (normally variable frequency high-pass and low-pass filters) to pass as much of the wanted sound as possible while rejecting frequencies above or below the range you're interested in. Such filters do not directly affect the sound of the gated signal — they only affect the way in which the gate's triggering circuit responds, though using excessive high-cut can slow the rate at which the gate opens.
Gating & Expansion In MOTU Digital Performer
For simple gating duties Digital Performer's Dynamics plug-in fits the bill nicely. It offers only three controls, Threshold, Attack and Release, along with input and output gain stages, but it has great metering, with separate displays for input and output level, gain reduction and side-chain level — a dedicated pop-up menu allows audio on any of DP's busses to feed the side-chain signal. With threshold level displayed as a transparent slider on the side-chain meter, Dynamics makes it simple to set up more creative gating effects. If you need to EQ this side-chain input, it can be done at source, in other words on the channel that is carrying the control signal.
The Dynamics plug-in is also home to DP's only expander, so this too benefits from fine metering and intuitive controls. Ratio is displayed sensibly as '1:integer' — the opposite of the Dynamics compressor mode. Again, a side-chain input is available, and both Attack and Release offer useful time ranges.
Almost at the other end of the complexity spectrum is Masterworks Gate, which is one of DP's best-kept secrets. It's a plug-in that you find more uses for each time you try it, and can be used as a surgical noise-removal tool, a transient modifier or a brutal sound-shaping device. To begin with, Masterworks Gate has a Range control, so gating doesn't have to be absolute — you could treat a snare hit, for example, so that when its level falls below the threshold Masterworks Gate attenuates it just a little bit, allowing the sound to ring on but at a level where it doesn't obscure other elements of the mix. Then there's the Hold control, which is excellent for helping to avoid chattering, but again can be used to modify the decay portion of percussive sounds and other strong transient signals. The Hold control even has a little 'traffic light' display to indicate when the gate is open, closed, or in its hold phase.
There's still more, though, including a look-ahead facility, configurable key sources (including stereo sources, even if you're only using a mono gate), key listen, and built-in low-pass and high-pass side-chain filters. It can even accept MIDI keying — just make sure you have Inter-application MIDI switched on in your FreeMIDI preferences (under Mac OS 9) and then select Masterworks Gate as an output in one of DP's MIDI tracks. For serious weirdness, a stereo Masterworks Gate can be set up so that each channel is set up differently, but for those times when you need more conventional control over a stereo signal just hold down the Mac's Option key whilst adjusting a control on either channel to have it apply to both channels. Robin Bigwood
Applications & Connections
While many recording channels include gating, it's often not a great idea to use gating at the recording stage, as there's no way to recover an otherwise good recording if the gate is set incorrectly and removes some wanted audio. In most instances it's safer to gate the track after recording, something that's easily achieved using a gate plug-in. The usual way to set up a gate is to solo the track being processed, then set the gate threshold as low as possible, without allowing false triggering from noise. Once this is as good as you can get it (using the side-chain filters if necessary), adjust the release time so that the natural decay of the sound being gated is not affected, but not setting it so long that you still hear noise after the wanted sound has died away. For most applications, the attack time should be as fast as possible without causing clicks, though you can use a longer attack time as a special effect to give each note or phrase a soft start. Where there is a lot of spill or noise, using the range control to reduce rather than eliminate the unwanted sounds may produce a more listenable result.
Gates are processors and so are invariably used via insert points or otherwise placed in series with the signal being treated. You don't use them via the aux send or return loop, so one gate is required for each channel being treated. Plug-ins may be inserted in individual mixer channels or groups, after which you should listen through to the soloed track to ensure that the gate isn't harming the wanted audio in any way. If the background noise isn't consistent in level, it may be possible to manually silence or reduce the level of problematic sections using your sequencer's editing tools, leaving the gate to look after passages where the noise level is reasonably constant. You may also want to try the automatic silence stripping facility of your sequencer, though this is only suitable if you want the pauses to be completely silenced.
Note that gating should always be carried out before the addition of reverb or delay, as the natural decay of such sounds is likely to suffer. Furthermore, delay and reverb help to camouflage abrupt gate actions that might sound slightly unnatural in isolation. Where gating and compression are being used together, it's usually best to place the gate before the compressor, where the variation between loud and quieter sounds is at its greatest. This will produce more reliable triggering that attempting to gate the compressor's output where the dynamic range will have been reduced by the compressor action.
Gating & Expansion In Cakewalk Sonar
As mentioned in last month's Using Your DAW's Compressors & Limiters masterclass, Sonar includes four dynamics plug-ins that include various expansion and gating functions. The Expander/Gate plug-in features Attack, Release, Threshold and Ratio controls, a choice of hard- or soft-knee turnover, plus a choice of Peak, RMS, or longer-term Average detection algorithms. An 'LED' shows when the expander is working. The Compressor/Gate and the comprehensive Dynamics plug-in both include a similar selection of controls, although their Attack, Release, and Knee controls are shared with the compressor section.
With stereo signals you also have the option of controlling both channels based on the current maximum level of the two, or switching to side-chain operation to apply the effect to the right channel based on the level of the left. This latter option sounds enticing, but would require creating a special stereo file containing the two mono tracks — not very easy in practice. Martin Walker
Gating & Expansion In Emagic Logic Audio
Logic Audio v5's most sophisticated gate, Noise Gate, includes all the features covered in this introduction, including side-chain keying and filters, user-variable hysteresis, look-ahead mode and peak/RMS side-chain sensing. However, there is no visual indicator to show when the gate is open. That said, you only have to set the range to maximum and the gating action becomes quite obvious from listening to the results. I tend to set the gate up with the attenuation at maximum, then reduce it if necessary after all the other controls have been set.
The Silver Gate looks a lot simpler, with its small, sliders-only control panel, but it is still a very capable gate offering all the essentials. It has no side-chain filters, but comes with fully variable attack, release and hold times as well as a look-ahead mode. Both Noise Gate and Silver Gate can be triggered from a separate audio track selected via a drop-down menu.
Logic's Expander is actually quite sophisticated and, in addition to the expected Threshold, Attack, Release and Ratio controls, it also offers variable knee adjustment and a choice of peak and RMS sensing. There's an Auto Gain button, to help compensate for any level changes caused by the expander, and a graphic display of the expansion curve. Furthermore, the expander may also be triggered from a separate audio track via its side-chain to achieve a similar effect to externally keying a gate.
Gating & Expansion In Digidesign Pro Tools
The Dynamics II suite supplied with current versions of Pro Tools includes two plug-ins that are relevant here: Gate II and Expander/Gate II. As with the Compressor II plug-in discussed last month, these are available in TDM and host-based RTAS versions, which are functionally identical, and can also be used for off-line destructive audio processing in the unlikely event that you don't want to do gating in real time.
The more complex of the two plug-ins is the expander/gate, although most of its features should be familiar to anyone who's used a hardware expander or gate. As on all the Dynamics II plug-ins, the first control is simply a switch that allows you to invert the polarity of the input signal. This is followed by conventional Threshold, Ratio, Attack, Hold, Decay and Range controls. All of these work as you'd expect: the Threshold sets the level below which expansion takes place and the Ratio controls how severe the expansion is. If you want Expander/Gate II to behave as a gate, turn the Ratio right up towards its 1:100 maximum; if you require more gentle expansion, leave it at a lower setting. The Range control sets the maximum amount of attenuation, up to a limit of 80dB.
Like the other Dynamics II plug-ins, Expander/Gate II supports side-chaining. To trigger the expander/gate from another mixer channel, you need to send from that channel to a mixer buss within Pro Tools, select that buss as the key input in Expander/Gate II and hit the External Input button. Where it differs from the other Dynamics II plug-ins is in offering built-in filtering. Since the side-chain signal is used purely as a control signal, and won't be heard in the mix, it's often useful to drastically EQ or filter it to isolate the parts of the sound that you want to trigger the gate reliably. The Key HPF and Key LPF sliders allow you to eliminate any frequencies below or above the instrument you want to use as your trigger: if, for instance, you want to gate a bass guitar using the kick drum as a key, but only have access to a fully mixed drum track, you may be able to isolate the kick by filtering out everything above 100Hz or so. The Key Listen button allows you to hear the side-chain signal, which is useful when setting up these filters.
If your side-chain signal needs more radical sonic surgery in order to trigger the gate reliably, you can insert EQs and other plug-ins between the source send and the key input. Create an aux track and set its inputs and outputs to separate busses (say buss one and two respectively), then insert the necessary plug-ins on this track. Send from your source track to the aux track's input buss, and select its output buss as the key input within Expander/Gate II. Gate II is simply a more basic version of Expander/Gate II which has the expansion ratio fixed at 1:100, and lacks the built-in filtering facilities on the key input. Sam Inglis
Gating & Expansion In Steinberg Cubase SX
Steinberg offer an Autogate module as part of the comprehensive five-stage VST Dynamics plug-in. As explained in last month's software dynamics masterclass, earlier versions of Cubase have this functionality built into each channel, which means that it isn't available for Groups, Rewire, or VST Instrument channels. To remedy this, Cubase VST v5 introduced exactly the same module as part of the simpler three-stage Dynamics plug-in, which Cubase SX also offers.
VST Dynamics always places the Autogate module first in the signal chain, since gating out unwanted noise is best done before any subsequent compression, and this is also the safest option with the Dynamics version using the default '2-1-3' routing option, although the others may prove useful in some cases. Unlike Logic's Noise Gate, Autogate does feature a visual indication of when the gate is open or closed, and has Threshold, Attack, Hold, and Release controls, along with some useful extras. Release has an optional Auto button that finds its own optimal setting depending on the type of incoming signal, while the Attack time can be switched to Predict Mode, which looks ahead in the waveform to ensure the gate will be open by the time any signal above the threshold level is received. The Threshold can also be set automatically — just find a section of your track where the unwanted background noise is the only component, and then while playing this back (loop it if the snippet is too short) click on the Calibrate button.
Autogate works very well when removing unwanted background noises, particularly since it also has a Trigger Frequency Range so you can make sure that only the desired sounds trigger the gate. You set the lower and upper frequencies using a pair of sliders, while a handy 'Listen' mode helps you tune it. I've used this in the past to open the gate only for the kick drums in a loop.
The MIDI Gate was introduced in Cubase VST 5.1, and also deserves a mention here. Once you place it in an audio insert slot you can use an external MIDI note message from another track to gate your audio, by routing its MIDI output to the new option that appears, while the plug-in's Attack and Release controls let you create your choice of audio level envelope. Its default Note On hold mode only reacts to the start of each note, with the setting of the manual Hold control determining the duration of the trigger. This is fine if you want each gate duration to be the same, but the Note Off hold mode is more flexible, since it uses the note's length instead, so you can alter the envelope hold time from note to note. Further refinements are available from the Note To Attack and Note To Release controls, where higher notes extend the respective durations, while Velocity To VCA lets you add envelope dynamics. MIDI Gate is often a more effective option than an audio gate when extracting individual drum sounds from a loop track, since there's no possibility of incorrect triggering, and it's also extremely useful for more extreme chopping effects such as applying MIDI percussion parts to sustained pad sounds.
Finally, Cubase also contains another gate in a more unlikely place — Apogee's UV22 and UV22HR dithering plug-ins. When you select the Autoblack option this automatically disables the dither noise whenever digital silence is detected, such as between album tracks. Martin Walker