Show Menu
Cheatography

CamillaDSP Cheat Sheet (DRAFT) by

This cheat sheet summarizes the YAML specification for the CamillaDSP configuration file.

This is a draft cheat sheet. It is a work in progress and is not finished yet.

top level

Config­uration name.
Config­uration descri­ption.
Defines devices for "­cap­tur­e" and "­pla­yba­ck" (input and output devices).
Mixers define channels, route audio, and change the number of channels in the pipeline.
Define and configure filters used in the pipeline.
Special "­fil­ter­s" that work on several channels at once..
The processing steps to be followed.

devices:

sample­rate:
The samplerate setting decides the sample rate that everything will run at. This rate must be supported by both the capture and playback device.
chunksize:
All processing is done in chunks of data. The chunksize is the number of samples each chunk will have per channel.

Suggested starting points for different sample rates:
44.1 or 48 kHz: 1024
88.2 or 96 kHz: 2048
176.4 or 192 kHz: 4096

The duration in seconds of a chunk is chunks­ize­/sa­mpl­erate, so the suggested values corres­ponds to about 22 ms per chunk. This is a reasonable value.
queuel­imit:*
[defaults to 4] The field queuelimit should normally be left out to use the default of 4. It sets the limit for the length of the queues between the capture device and the processing thread, as well as between the processing thread and the playback device. The total queue size limit will be 2 * chunksize * queuelimit samples per channel.
enable­_ra­te_­adj­ust:*
[default false] This enables the playback device to control the rate of the capture device, in order to avoid buffer underruns or a slowly increasing latency. This is currently supported when using an Alsa, Wasapi or CoreAudio playback device (and any capture device).
target­_le­vel:*
[default chunksize] The value is the number of samples that should be left in the buffer of the playback device when the next chunk arrives. Only applies when enable­_ra­te_­adjust is set to true.
adjust­_pe­riod:*
[defaults 10] Set the interval between correc­tions, in seconds. Only applies when enable­_ra­te_­adjust is set to true
silence_threshold:*
silence_timeout:*
Pause processing if the input is silent. The threshold is the threshold level in dB.
captur­e_s­amp­ler­ate:*
The capture sample­rate. Setting it to null sets the capture samplerate to the same value as sample­rate.
stop_on_rate_change:*
rate_measure_interval:*
Setting stop_o­n_r­ate­_change to true makes CamillaDSP stop the processing if the measured capture sample rate changes.
volume­_ra­mp_­time:*
[default 400 ms] Set the duration of the ramp when changing volume of the default volume control.
multithreaded:*
worker_threads:*
[defaults to false and automa­tic)] Setting true enables multit­hreaded proces­sing. When this is enabled, CamillaDSP creates several filtering tasks by grouping the filters for each channel.
capture:
playback:
Defines input and output devices respec­tively. See the dedicated section.
resamp­ler:*
Defines the resampler. Setting it to null or leaving it out disables resamp­ling. See the dedicated section below.

(devices:) capture: and playback:

type:
Type type of device. See Note1 below.
channels:
Number of channels.
device:
Device name (for Alsa, Pulse, Wasapi, CoreAu­dio). For CoreAudio and Wasapi, null will give the default device
filename:
Path to the file (for File, RawFile and WavFile).
format:
Sample format (for all except Jack).
Note1 - List of device types for the type: node.
All devices: Jack, Wasapi, CoreAudio, Alsa, Pulse
Capture devices only: Bluez, RawFile, WavFile, Signal­Gen­erator, and Stdin
Playback devices only: File and Stdout.
Note2 - capture: device types have an optional labels: property. This accepts a list of strings, and is meant to be used by a GUI to display meaningful channel names. CamillaDSP itself does not use these labels.

(devices:) resampler:

type:
One of AsyncSinc, AsyncPoly, or Synchr­onous.
Asynch­ronous resampling with anti-a­lia­sing.
profile: (Async­Sinc)
One of Balanced, Fast, VeryFast, or Accurate
more AsyncSinc parameters
See the CamillaDSP resampling docume­ntation or the Rubato docume­nta­tion.
Asynch­ronous resampling without anti-a­lia­sing.
interp­ola­tion: (Async­Poly)
One of Linear, Cubic, Quintic, or Septic.
Synchr­onous resampling with anti-a­lia­sing.
The Synchr­onous resampler has no additional nodes.

mixer:

Each child node of the mixer: node is a user-d­efined mixer name that will be referenced in the ____ node(s). Each mixer has the following nodes. See the CamillaDSP docume­ntation for more info.
descri­ption:*
   
Mixer descri­­ption.
labels:*
   
Labels for GUI display..
channels:
 
in:
 
Number of input channels.
 
out:
 
Number of output channels.
mapping:
   
A list containing one dest entry for each output channel. Channel numbers are 0-based.
 
dest:
 
An output channel.
 
mute:*
 
Should the output channel be muted? Boolean.
 
sources:
 
A list of sources contri­buting to the output channel.
   
channel:
Input source channel number. 0-based.
   
gain:*
Gain to apply to the input channel. Units are in scale.
   
scale:*
Units for gain. Must be one of dB or linear.
   
inverted:*
Should the channel be inverted? Boolean.

proces­sors:

Each node under the proces­sors: node is a user-d­efined name for a configured processor.
type:
A processor type, one of Compressor or NoiseGate.
parame­ters:
Compressor
A standard dynamic range compressor configured with the most common parame­ters.
NoiseGate
Simple noise gate that estimates current loudness using the compre­ssor's algorithm.

pipeline:

The pipeline consists of a list of processing steps between input and output. Each step has a type , affected channels, and the name(s) of each filter, mixer, or processor.
type:
One of Mixer, Filter, or Processor.
descri­ption*:
[blank] The pipeline descri­ption.
name:
For Mixer or Processor steps only. User-d­efined name for a mixer or processor to use..
names:
For Filter steps only. List of user-d­efined names of filters to use.
channels:
For Filter steps only. List of channels to filter.
bypassed*:
[false] Bypasses the processing step if true.
If the name of a mixer, processor or filter includes the tokens $sampl­erate$ or $chann­els$, these will be replaced by the corres­ponding values from the config. For example, if the samplerate is 44100, the filter name fir_$s­amp­lerate$ will be updated to fir_44100.
 

filters: Utility filters

Gain
 
Gain to apply.
 
gain:
Range is +/-150 dB or +/- 10 (linear scale).
 
scale*:
[dB] dB or linear.
 
mute*:
[false] Mute the signal.
 
inverted*:
[false] Invert the signal.
Volume
 
Volume control that reacts to a websocket request to change the volume of a fader. All Volume filters responding to the fader in the request will change their volume.
 
fader:
Which fader (
Aux1
to
Aux4
) that this filter responds to.
 
limit*:
[+50 dB] Maximum value allowed for the filter.
 
ramp_t­ime*:
[400 ms] Time interval (in millis­econds) over which the volume changes to a new value. Must be positive.
Loudness
 
Apply loudness compen­sation using the RME ADI-2 DAC FS method. Reacts to changes in volume for any of the five faders. Can be used with an external volume control if changes to that control are also sent to Camill­aDSP's websocket.
 
refere­nce­_level:
If the fader is above this level, no compen­sation is applied. Below 20 dB below the refere­nce­_level, the full amount of each boost is applied. Otherwise, the boosts are scaled linearly. Range is +20/-100.
 
fader*:
[Main] The fader whose volume is monitored to determine the amount of compen­sation to apply.
 
high_b­oost*:
[10 dB] Maximum HF boost in dB. Range is 0-20.
 
low_bo­ost*:
[10 dB] Maximum LF boost in dB. Range is 0-20.
 
attenu­ate­_mid*:
[false] Attenuates mids instead of boosting HF and LF to avoid clipping when used with external volume controls and web API.
Delay
 
Delays the signal. If unit: is mm, the speed of sound of 343 m/sec is used to calculate the delay.
 
delay:
Amount of delay. Must be zero or positive.
 
unit*:
[ms] delay: units, one of ms, mm, or samples.
 
subsample:
When true, an IIR filter is used to achieve subsample delay precision. When false, will round to the nearest number of full samples. This is faster.
 
Intended to add shaped noise to 16-bit output. Several types are supported
 
type:
Type of dither. See docume­ntation.
 
bits:
Target bit depth. Should match bitdepth of oversa­mpling delta-­sigma DACs. For true NOS DACs, should match the number of bits where the DAC is linear.
 
Limits output signal to a given level.
 
clip_l­imit:
Clipping level in dB.
 
soft_c­lip*:
[false] Enable soft clipping, introd­ucing some harmonic distor­tion..
 
Implements a generic difference equation. See docume­ntation.
 
a:
[1.0] Coeffi­cients a0, a1, ..., an.
 
b:
[1.0] Coeffi­cients b0, b1, ..., bn.

filters: Biquad filters (IIR)

Many standard filters are implem­ented as Biquad IIR filters. These are specified using another type: node beneath the biquad's parame­ters: node. Values for this second type: node follow. Type-s­pecific nodes define each parameter for that type and are shown below.
Note: bandwidth is given in octaves.
Free
a1: a2: b0: b1: b2:
Normalized coeffi­cients.
Highpass
Lowpass
freq: q:
Second order high/l­owpass filters (12dB/­oct).
HighpassFO
LowpassFO
freq:
First order high/l­owpass filters (6dB/oct)
Highshelf
Lowshelf
freq: gain:
q: or slope:
freq: is the center frequency, where the gain is half of grain:. slope: is in dB/octave.
HighshelfFO
LowshelfFO
freq: gain:
freq: is the center frequency, where the gain is half of grain:.
Peaking
freq: gain:
q: or bandwidth:
Notch
freq:
q: or bandwidth:
Has a large negative gain.
Genera­lNotch
freq_z:
freq_p:
q_p:
normalize_at_dc:*
A notch filter where the pole and zero can be placed at different frequencies.
q_p is the pole Q.
Bandpass
freq:
q: or bandwidth:
Second order bandpass filter.
Allpass
freq:
q: or bandwidth:
Second order allpass filter.
AllpassFO
freq:
First order allpass filter.
Linkwi­tzT­ran­sform
freq_act:
q_act:
freq_target:
q_target:
Modifies a given actual speaker HP response (frequency and q) with a new target.

filters: Biquad­Combo filters (IIR)

These filters are composed of several Biquad IIR filters. These are specified using another type: node beneath the biquad's parame­ters: node. Values for this second type: node follow. Type-s­pecific nodes define each parameter for that type and are shown below.
Note1: bandwidth is given in octaves.
Note2: See also Higher order biquads
ButterworthHighpass
ButterworthLowpass
freq: order:
LinkwitzRileyHighpass
LinkwitzRileyLowpass
freq: order:
order: must be even.
Tilt
gain:
Tilts across entire spectrum. Positive values increase the high freque­ncies. Half the gain is applied to the highs and negative half is applied to the lows. Gain limited to +/-100dB
FivePo­intPeq
 
Five band PEQ with a low shelf, three peaking filters, and a high shelf. All 15 values are required.
fls: gls: qls:
fp1: gp1: qp1:
fp2: gp2: qp2:
fp3: gp3: qp3:
fhs: ghs: qhs:
Graphi­cEq­ualizer
freq_min:
freq_max:
gains:
Min/max freque­ncies default to 20Hz and 20kHz. gains: is an array of gains for each band. The number of bands is set by the length of the array.

filters: Convol­ution filters (FIR)

Conv (FIR)

Volume control faders

There are five volume control "­cha­nne­ls" called "­fad­ers­", named "­Mai­n" and "­Aux­1" to "­Aux­4". See volume control.

Supported sample formats

S16LE
Signed 16-bit int, stored as two bytes
S24LE
Signed 24-bit int, stored as four bytes (three bytes of data, one padding byte)
S24LE3
Signed 24-bit int, stored as three bytes (with no padding)
S32LE
Signed 32-bit int, stored as four bytes
FLOAT32LE
32-bit float, stored as four bytes
FLOAT64LE
64-bit float, stored as eight bytes

Supported sample formats by device type

 
Alsa
Pulse
Wasapi
CoreAudio
Jack
Other
S16LE
Yes
Yes
Yes
Yes
No
Yes
S24LE
Yes
Yes
Yes
Yes
No
Yes
S24LE3
Yes
Yes
Yes
Yes
No
Yes
S32LE
Yes
Yes
Yes
Yes
No
Yes
FLOAT32LE
Yes
Yes
Yes
Yes
Yes
Yes
FLOAT64LE
Yes
No
No
No
No
Yes
Other = File/S­tdi­n/S­tdout

Equivalent sample formats by API

CamillaDSP
Alsa
Pulse
S16LE
S16_LE
S16LE
S24LE
S24_LE
S24_32LE
S24LE3
S24_3LE
S24LE
S32LE
S32_LE
S32LE
FLOAT32LE
FLOAT_LE
FLOAT32LE
FLOAT64LE
FLOAT64_LE
-