Bass

A bass is a low note with a shape: how bright it is, and whether it plucks and fades or holds. A sawtooth wave and a low-pass filter give you both.

  • Synthesized
  • Sawtooth + filter

The sound

A sawtooth has strong overtones above its note. The low-pass filter decides how many survive: turn Cutoff down and the bass gets rounder and deeper; up, and it buzzes.

react-strudel-kit
export const bassSound = (sound: BassSettings): PatternModifierCall[] => [
  fn('instrument', sample('sawtooth')), // Rich in overtones, so the filter has work to do.
  fn('lowPass', sound.cutoff), // Remove everything above this (Hz): lower is rounder.
  fn('attack', 0.005),
  fn('decay', sound.decay), // Seconds to fall from the peak to the sustain level.
  fn('sustain', sound.sustain), // Level held while the note lasts: 0 = pluck, 1 = organ.
  fn('release', 0.05),
  fn('gain', 0.3),
]

Playing it on its own takes a rhythm, here written next to the sound. Switch to Strudel output to see the values the sliders are playing now.

export const bassAlone = (settings: BassSettings) => chain(
  // Eight slots: root, rest, root, fifth, rest, root, octave, fifth.
  fn('note', sequence(
    pitch('c2'), rest(), pitch('c2'), pitch('g2'),
    rest(), pitch('c2'), pitch('c3'), pitch('g2'),
  )),
  ...bassSound(settings),
  fn('cpm', 25), // 100 BPM.
)

How it is built

PartUnitWhat it does
instrument(sawtooth)—The source: a bright wave with every overtone, so the filter has something to remove.
lowPassHzRemoves frequencies above the cutoff. The most important control for a bass.
decaysecondsTime to fall from the first peak to the sustain level.
sustainlevel 0–1How loud the note stays while it lasts. 0 plucks; 1 holds like an organ.

In a groove

Your bass with a kick on beats 1 and 3. They start the bar together; on beat 3 the bass rests and lets the kick through.

export const bassGroove = (settings: BassSettings) => chain(
  fn('stack',
    chain(fn('note', sequence(KICK, rest(), KICK, rest())), ...kickSound(KICK_DEFAULTS)),
    chain(fn('note', sequence(pitch('c2'), rest(), pitch('c2'), pitch('g2'), rest(), pitch('c2'), pitch('c3'), pitch('g2'))), ...bassSound(settings)),
  ),
  fn('cpm', 25),
)

Bass and kick

Ready

Used in: Bass line · Layer a song