Every sound, synth and setting
Every game sound, ready-made synth, setting and chord of synths.js and synths, with its range and where it starts. This page is written from the library's own table of names, so it is what the library has.
Where two spellings are shown, the first is JavaScript's and the second is Python's. A program may use either in both languages: lead.vibratoRate and lead.vibrato_rate are the same setting.
Game sounds
playSound(name) in JavaScript, play_sound(name) in Python. There are 14:
"coin", "jump", "laser", "explosion", "hit", "shoot", "powerup", "blip", "click", "zap", "bounce", "pop", "win", "lose".
Explained in Game sounds.
Ready-made synths
makeSynth(name) in JavaScript, make_synth(name) in Python. Each is settings of the one engine, not a recording, and the table shows the settings it is made of. Anything it does not set is as it starts in the tables below, with the filter open.
| Synth | What it is made of |
|---|---|
keys | wave "triangle", wave2 "sine", level2 0.35, pitch2 12, cutoff 3500, sweep 18, sweepDecay 0.3, sweepSustain 0.2, keytrack 0.5, attack 0.003, decay 0.45, sustain 0.3, release 0.35, reverb 0.12 |
bass | wave "saw", sub 0.6, cutoff 320, resonance 0.3, sweep 30, sweepDecay 0.18, sweepSustain 0.15, attack 0.003, decay 0.2, sustain 0.75, release 0.12 |
lead | wave "saw", wave2 "square", level2 0.6, detune2 9, cutoff 2800, resonance 0.25, keytrack 0.5, attack 0.01, decay 0.15, sustain 0.7, release 0.2, vibrato 0.15, vibratoDelay 0.25, vibratoRate 5.5, echo 0.2 |
pad | wave "saw", voices 4, detune 22, spread 0.8, cutoff 1600, attack 0.5, decay 0.5, sustain 0.8, release 1.2, chorus 0.4, reverb 0.4 |
pluck | wave "saw", cutoff 500, resonance 0.2, sweep 48, sweepDecay 0.12, sweepSustain 0, keytrack 0.5, attack 0.001, decay 0.3, sustain 0, release 0.25 |
organ | wave "sine", wave2 "sine", level2 0.6, pitch2 12, sub 0.5, attack 0.008, decay 0.01, sustain 1, release 0.06, chorus 0.3 |
strings | wave "saw", voices 3, detune 14, spread 0.6, cutoff 3200, attack 0.25, decay 0.3, sustain 0.85, release 0.6, vibrato 0.08, vibratoDelay 0.4, reverb 0.3 |
bell | wave "sine", wave2 "sine", level2 0.45, pitch2 19, detune2 2, attack 0.001, decay 1.4, sustain 0, release 1.2, reverb 0.3 |
flute | wave "triangle", noise 0.03, cutoff 3000, attack 0.06, decay 0.1, sustain 0.9, release 0.15, vibrato 0.1, vibratoDelay 0.3 |
chip | wave "square", filter "off", attack 0, decay 0, sustain 1, release 0.02 |
chipLead, chip_lead | wave "pulse", width 0.25, filter "off", attack 0, decay 0, sustain 1, release 0.02, vibrato 0.2, vibratoDelay 0.15, vibratoRate 6 |
chipBass, chip_bass | wave "pulse", filter "off", attack 0, decay 0, sustain 1, release 0.02, macroRate 4, macro 8 steps |
chipNoise, chip_noise | level1 0, noise 1, noise.type "lfsr", filter "off", attack 0, decay 0.12, sustain 0, release 0.05 |
chipKick, chip_kick | wave "triangle", filter "off", attack 0, decay 0.16, sustain 0, release 0.05, macro 6 steps |
chipSnare, chip_snare | wave "pulse", noise.type "lfsr", filter "off", attack 0, decay 0.16, sustain 0, release 0.05, macro 6 steps |
chipHat, chip_hat | wave "pulse", noise.type "lfsr", filter "off", attack 0, decay 0.05, sustain 0, release 0.02, macro 3 steps |
kick | wave "sine", filter "off", pitchSweep 30, pitchSweepDecay 0.06, pitchSweepAttack 0, attack 0, decay 0.3, sustain 0, release 0.1 |
snare | wave "triangle", level1 0.6, noise 1, filter "highpass", cutoff 500, resonance 0.05, pitchSweep 12, pitchSweepDecay 0.04, pitchSweepAttack 0, attack 0, decay 0.17, sustain 0, release 0.08 |
hat | level1 0, noise 1, filter "highpass", cutoff 7000, attack 0, decay 0.05, sustain 0, release 0.03 |
Explained in Synths and their settings.
Settings of a synth
Each is a property of a synth (lead.cutoff = 800), a name in makeSynth({ cutoff: 800 }) or make_synth(cutoff=800), and a setting a dial can be tied to (dial("cutoff", lead, "cutoff")). The last column is the sound engine's own name for it, which a synth also answers to.
| Setting | Values | Starts at | Measured in | The engine's name |
|---|---|---|---|---|
wave | "sine", "triangle", "saw", "pulse", "sample" | "triangle" | osc1.wave | |
level1 | 0 to 1 | 1 | 1 is as it comes | osc1.level |
width or pulseWidth, pulse_width | 0 to 1 | 0.5 | osc1.pulse_width | |
sample | 0 to 1023, whole numbers | 0 | a sample | osc1.sample |
octave | -4 to 4, whole numbers | 0 | octaves | transpose |
pitch | -48 to 48 | 0 | semitones | transpose |
voices | 1 to 8, whole numbers | 1 | voices | unison.voices |
detune | 0 to 100 | 20 | hundredths of a semitone | unison.detune |
spread | 0 to 1 | 0.5 | unison.spread | |
wave2 | "sine", "triangle", "saw", "pulse", "sample" | "saw" | osc2.wave | |
level2 | 0 to 1 | 0 | 1 is as it comes | osc2.level |
pitch2 | -48 to 48 | 0 | semitones | osc2.coarse |
detune2 | -100 to 100 | 0 | hundredths of a semitone | osc2.fine |
width2 | 0 to 1 | 0.5 | osc2.pulse_width | |
sync | true or false (True, False) | off | osc2.sync | |
ring | 0 to 1 | 0 | osc2.ring | |
sub | 0 to 1 | 0 | 1 is as it comes | sub.level |
noise | 0 to 1 | 0 | 1 is as it comes | noise.level |
macroRate, macro_rate | 1 to 1000 | 50 | Hz | macro.rate |
macroSync, macro_sync | true or false (True, False) | off | macro.sync | |
filter | "off", "lowpass", "highpass", "bandpass", "notch", "low_band", "band_high", "all" | "off" | filter.type | |
slope | "12db", "24db" | "12db" | filter.slope | |
cutoff | 20 to 20000 | 2000 | Hz | filter.cutoff |
resonance | 0 to 1 | 0.15 | filter.resonance | |
keytrack | 0 to 1 | 0 | filter.keytrack | |
sweep | -96 to 96 | 0 | semitones | filter.env |
sweepAttack, sweep_attack | 0 to 20 | 0.005 | seconds | filter_env.attack |
sweepDecay, sweep_decay | 0 to 20 | 0.2 | seconds | filter_env.decay |
sweepSustain, sweep_sustain | 0 to 1 | 0.3 | filter_env.sustain | |
sweepRelease, sweep_release | 0 to 20 | 0.2 | seconds | filter_env.release |
attack | 0 to 20 | 0.005 | seconds | amp.attack |
decay | 0 to 20 | 0.1 | seconds | amp.decay |
sustain | 0 to 1 | 0.8 | amp.sustain | |
release | 0 to 20 | 0.15 | seconds | amp.release |
curve | 0 to 1 | 0.5 | amp.curve | |
pitchSweep, pitch_sweep | -48 to 48 | 0 | semitones | mod_env.pitch |
pitchSweepAttack, pitch_sweep_attack | 0 to 20 | 0.005 | seconds | mod_env.attack |
pitchSweepDecay, pitch_sweep_decay | 0 to 20 | 0.2 | seconds | mod_env.decay |
vibrato | -48 to 48 | 0 | semitones | lfo1.pitch |
vibratoRate, vibrato_rate | 0.01 to 50 | 5 | Hz | lfo1.rate |
vibratoDelay, vibrato_delay | 0 to 10 | 0 | seconds | lfo1.delay |
tremolo | 0 to 1 | 0 | lfo1.amp | |
wobble | -96 to 96 | 0 | semitones | lfo2.cutoff |
wobbleRate, wobble_rate or pwmRate, pwm_rate | 0.01 to 50 | 0.5 | Hz | lfo2.rate |
autopan | 0 to 1 | 0 | lfo2.pan | |
pwm | -1 to 1 | 0 | lfo2.pulse_width | |
distortion or drive | 0 to 1 | 0 | fx.drive | |
crush or bits | 1 to 16 | 16 | bits | fx.bits |
downsample | 1 to 64, whole numbers | 1 | fx.downsample | |
pitchShift, pitch_shift | -12 to 12 | 0 | semitones | fx.pitch |
ringMod, ring_mod | 0 to 1 | 0 | fx.ring | |
ringSpeed, ring_speed | 1 to 5000 | 30 | Hz | fx.ring_freq |
ringWave, ring_wave | "sine", "noise" | "sine" | fx.ring_wave | |
comb | 0 to 1 | 0 | fx.comb | |
combTone, comb_tone | 50 to 5000 | 200 | Hz | fx.comb_freq |
combFeedback, comb_feedback | -0.97 to 0.97 | 0.7 | fx.comb_feedback | |
flanger | 0 to 1 | 0 | fx.comb_depth | |
flangerRate, flanger_rate | 0.01 to 10 | 0.3 | Hz | fx.comb_rate |
reverse | true or false (True, False) | off | osc1.reverse | |
echo or delay | 0 to 1 | 0 | 1 is as it comes | send.delay |
reverb | 0 to 1 | 0 | 1 is as it comes | send.reverb |
chorus | 0 to 1 | 0 | 1 is as it comes | send.chorus |
tranceGateDepth, trance_gate_depth | 0 to 1 | 0 | gate.depth | |
tranceGateRate, trance_gate_rate | 0.25 to 16 | 4 | steps | gate.rate |
tranceGateSmooth, trance_gate_smooth | 0.001 to 0.5 | 0.008 | seconds | gate.smooth |
tranceGateSwing, trance_gate_swing | 0 to 0.75 | 0 | gate.swing | |
tranceGateSends, trance_gate_sends | true or false (True, False) | on | gate.sends | |
tranceGateStereo, trance_gate_stereo | true or false (True, False) | off | gate.stereo |
Some values have other words that mean the same: "square" for "pulse", "sawtooth" for "saw", "tri" for "triangle", "sin" for "sine", "low" for "lowpass", "high" for "highpass", "band" for "bandpass", "none" for "off", "hiss" for "white", "chip" for "lfsr", "buzz" for "lfsr_short".
Settings shared by every synth
The echo, the reverb and the chorus are shared by all the synths, and so is the volume of everything. These are set with setEffects({ echoTime: 0.3 }) in JavaScript and set_effects(echo_time=0.3) in Python.
| Setting | Values | Starts at | Measured in | The engine's name |
|---|---|---|---|---|
maxVoices, max_voices | 1 to 64, whole numbers | 64 | voices | voices |
masterVolume, master_volume | 0 to 2 | 0.35 | 1 is as it comes | master.volume |
limiter | true or false (True, False) | on | master.limiter | |
echoTime, echo_time | 0.001 to 2 | 0.3 | seconds | delay.time |
echoFeedback, echo_feedback | 0 to 0.95 | 0.4 | delay.feedback | |
echoTone, echo_tone | 200 to 20000 | 6000 | Hz | delay.tone |
echoBounce, echo_bounce | true or false (True, False) | off | delay.pingpong | |
reverbSize, reverb_size | 0 to 1 | 0.5 | reverb.size | |
reverbDamping, reverb_damping | 0 to 1 | 0.4 | reverb.damping | |
reverbType, reverb_type | "room", "hall", "plate", "cathedral", "spring" | "room" | reverb.type | |
reverbDecay, reverb_decay | 0 to 30 | 0 | seconds | reverb.decay |
reverbPredelay, reverb_predelay | 0 to 0.2 | 0 | seconds | reverb.predelay |
reverbLowCut, reverb_low_cut | 20 to 1000 | 120 | Hz | reverb.low_cut |
reverbLevel, reverb_level | 0 to 2 | 1 | 1 is as it comes | reverb.level |
echoLevel, echo_level | 0 to 2 | 1 | 1 is as it comes | delay.level |
chorusRate, chorus_rate | 0.05 to 10 | 0.8 | Hz | chorus.rate |
chorusDepth, chorus_depth | 0 to 1 | 0.5 | chorus.depth | |
micGain, mic_gain | 0 to 8 | 1 | 1 is as it comes | input.gain |
micGate, mic_gate | -100 to 0 | -100 | db | input.gate |
micGateRelease, mic_gate_release | 0.005 to 2 | 0.15 | seconds | input.gate_release |
Explained in Effects.
The other settings
These are spelled as the sound engine spells them, and are set like any other: lead.volume = 0.5, lead.set("bend_range", 12). A dot in a name may be written as a capital or an underscore: lead.lfo1Wave, lead.lfo1_wave.
| Setting | Values | Starts at | Measured in |
|---|---|---|---|
volume | 0 to 2 | 1 | 1 is as it comes |
pan | -1 to 1 | 0 | -1 is left, 1 is right |
tune | -100 to 100 | 0 | hundredths of a semitone |
bend | -1 to 1 | 0 | |
bend_range | 0 to 48 | 2 | semitones |
glide | 0 to 10 | 0 | seconds |
mode | "poly", "mono", "legato" | "poly" | |
velocity | 0 to 1 | 1 | |
pan.law, pan_law | "equal_power", "square_root" | "equal_power" | |
osc1.coarse, osc1_coarse | -48 to 48 | 0 | semitones |
osc1.fine, osc1_fine | -100 to 100 | 0 | hundredths of a semitone |
osc1.start, osc1_start | 0 to 1 | 0 | |
osc1.keytrack, osc1_keytrack | true or false (True, False) | on | |
osc2.sample, osc2_sample | 0 to 1023, whole numbers | 0 | a sample |
osc2.start, osc2_start | 0 to 1 | 0 | |
osc2.keytrack, osc2_keytrack | true or false (True, False) | on | |
osc2.reverse, osc2_reverse | true or false (True, False) | off | |
sub.wave, sub_wave | "sine", "square", "triangle" | "sine" | |
sub.octave, sub_octave | -2 to -1, whole numbers | -1 | octaves |
sample.antialias, sample_antialias | true or false (True, False) | on | |
noise.type, noise_type | "white", "pink", "lfsr", "lfsr_short" | "white" | |
noise.pitch, noise_pitch | -48 to 48 | 0 | semitones |
filter.velocity, filter_velocity | -96 to 96 | 0 | semitones |
filter_env.curve, filter_env_curve | 0 to 1 | 0.5 | |
mod_env.sustain, mod_env_sustain | 0 to 1 | 0 | |
mod_env.release, mod_env_release | 0 to 20 | 0.2 | seconds |
mod_env.curve, mod_env_curve | 0 to 1 | 0.5 | |
mod_env.osc2_pitch, mod_env_osc2_pitch | -48 to 48 | 0 | semitones |
mod_env.pulse_width, mod_env_pulse_width | -1 to 1 | 0 | |
lfo1.wave, lfo1_wave | "sine", "triangle", "saw", "square", "random" | "sine" | |
lfo1.fade, lfo1_fade | 0 to 10 | 0 | seconds |
lfo1.sync, lfo1_sync | true or false (True, False) | on | |
lfo1.pulse_width, lfo1_pulse_width | -1 to 1 | 0 | |
lfo1.cutoff, lfo1_cutoff | -96 to 96 | 0 | semitones |
lfo1.pan, lfo1_pan | 0 to 1 | 0 | |
lfo2.wave, lfo2_wave | "sine", "triangle", "saw", "square", "random" | "triangle" | |
lfo2.delay, lfo2_delay | 0 to 10 | 0 | seconds |
lfo2.fade, lfo2_fade | 0 to 10 | 0 | seconds |
lfo2.sync, lfo2_sync | true or false (True, False) | off | |
lfo2.pitch, lfo2_pitch | -48 to 48 | 0 | semitones |
lfo2.amp, lfo2_amp | 0 to 1 | 0 | |
input.part, input_part | 0 to 63, whole numbers | 31 | part |
input.monitor, input_monitor | true or false (True, False) | on | |
tempo | 20 to 999 | 120 | bpm |
Chords
A chord is a note and a kind: "C" and "m7" make "Cm7". The numbers are each note of the chord in semitones above the first.
| Kind | Semitones |
|---|---|
5, power | 0 7 |
6 | 0 4 7 9 |
7, dom7 | 0 4 7 10 |
9 | 0 4 7 10 14 |
major, maj | 0 4 7 |
minor, min, m | 0 3 7 |
dim | 0 3 6 |
aug | 0 4 8 |
sus2 | 0 2 7 |
sus4, sus | 0 5 7 |
octave | 0 12 |
m6 | 0 3 7 9 |
maj7 | 0 4 7 11 |
m7, min7 | 0 3 7 10 |
dim7 | 0 3 6 9 |
m7b5 | 0 3 6 10 |
mmaj7 | 0 3 7 11 |
add9 | 0 4 7 14 |
maj9 | 0 4 7 11 14 |
m9 | 0 3 7 10 14 |
Explained in Notes, chords and tunes.
Note lengths
A length by name is measured in beats, against the tempo.
| Length | Beats |
|---|---|
"whole", "w" | 4 |
"half", "h" | 2 |
"quarter", "q" | 1 |
"eighth", "e" | 0.5 |
"sixteenth", "s" | 0.25 |
"thirtysecond", "t" | 0.125 |
Explained in Notes, chords and tunes.
Voices
A voice changes a microphone, a recording or a synth in one word: mic.voice = "robot". "none" takes it off, and voiceNames() gives the list to a program (voice_names()).
| Voice | What it is |
|---|---|
"robot" | A machine: the voice multiplied by a 50 Hz wave, ringing in a metal pipe. |
"chipmunk" | Small and squeaky: everything seven semitones higher. |
"monster" | Huge and deep: seven semitones lower, with a growl and a little room. |
"cave" | Far inside a cave: long echoes and an enormous, dark space. |
"telephone" | Down an old phone line: only the middle of the voice, coarse and a little crushed. |
"alien" | Not from here: higher, multiplied by a 180 Hz wave, with a slow metallic sweep. |
"whisper" | Hoarse and breathy: the voice's pitch blurred into noise, with its low end taken off. |
Explained in Your voice.
How many at once
A program can have 32 synths at once and 64 notes sounding at once. A song has 32 channels of its own.