Gate

Gate operator properties for Script Engine. Silences (or attenuates) the audio when its level falls below a chosen threshold. Useful for muting microphones during pauses, suppressing room tone or background hum between speech phrases, and cleaning up multi-mic mixes where every open mic adds noise. Built on FFmpeg's compander filter, with broadcast-style controls (threshold, ratio, attack/release, knee, gain reduction, makeup gain) plus advanced detector settings.

Property Type Access Description
InputGainDb float get/set Pre-gate gain applied to the input, in decibels. [min=-24, max=24, default=0]. 0 leaves the signal unchanged. Negative values reduce the input level; positive values boost it before the gate processes it.
GainReductionDb float get/set How much the gate attenuates the signal when closed, in decibels. [min=-36, max=0, default=-36]. −36 dB silences the audio completely (full gate); less negative values leave a quiet "duck" of the original through (often preferable on speech to avoid sudden cut-outs). 0 dB effectively disables the gate.
ThresholdDb float get/set Level below which the gate closes, in decibels relative to full scale. [min=-48, max=0, default=-24]. Audio quieter than this triggers the gate; audio louder is allowed through. Set this just above the noise floor — too low and the gate barely engages, too high and it chops off legitimate quiet content.
Ratio float get/set How aggressively the gate closes below the threshold. [min=1, max=20, default=4]. 1:1 effectively disables the gate. Higher values produce a more decisive close — useful for hard gating noisy mics, while lower values give a softer "ducking" effect.
Attack float get/set How quickly the gate opens when the signal exceeds the threshold, in milliseconds. [min=1, max=200, default=20]. Short values catch the start of words and percussive sounds; longer values can clip fast onsets.
Release float get/set How quickly the gate closes after the signal drops below the threshold, in milliseconds. [min=5, max=5000, default=250]. Short values close abruptly between words (more obvious gating); long values let the natural tail of words fade out before muting.
Knee float get/set Soft-knee width around the threshold. [min=1, max=8, default=2.8]. Low values give a hard, decisive open/close; high values give a gentle, gradual engagement around the threshold.
MakeupGainDb float get/set Extra gain applied after the gate to raise the overall level. [min=0, max=24, default=0].
OperationMode CompressorMode get/set CompressorMode — operating mode / gating direction. Reuses the underlying compressor's mode setting. The standard mode for a gate is the one that pulls down quiet parts (i.e. cuts when the signal is below the threshold), which is what most users want.
Link CompressorLink get/set How left and right channels are linked when the gate decides whether to open or close. Linked detection keeps the stereo image stable; independent detection gates each channel separately.
CompressorDetection CompressorDetection get/set How the gate measures the input level — peak vs. RMS. Peak detection reacts to instantaneous peaks (more aggressive on transients). RMS reacts to the smoothed loudness over time (more transparent on speech and music).
ResetCommand Command get Reset all settings to their defaults.
SamplesRendered int get Total number of audio samples processed by the gate (read-only, debug).

Inherits from: AbstractAudioOperator, AbstractOperator, AbstractAudioMetering.

See also: Gate in Operators — user-facing introduction, screenshots, and section summaries.