Strudelify

One Toke Over the Line

Brewer And Shipley

KeyC majorTempo157 bpm
0:00/0:00
// One Toke Over the Line — Brewer And Shipley
// 157 bpm, 4/4, key C major. Source: midi.
// Generated by strudelify. One cycle = one bar.
// note: duplicate parts dropped: ch 5 string ensemble 2 (copy of ch 4 "strings" string ensemble 2, 0.083 beats late); ch 2 clavinet (copy of ch 3 "piano2" clavinet, 0.083 beats late)
// note: Full arrangement: all 84 bars on a 16-step grid, each part at one level. Source detail keeps the original performance.
setcpm(157/4)

// Notation: c3@3 lasts 3 steps · ~ is a rest · [c3,e3] is a chord · [...]/2 spreads a riff over 2 bars.
// A part's distinct bars are riffs (A, B, C...) played in order: edit a riff to change every repeat.

// bass · electric bass pick · "base2"
const bass = note(`<
  A B C D E F G H I J K L M N G H I O K P M Q G H I R S T U V W X Y R Z T U AA AB AC AD J K L M N G H I O K P M Q G H I
  R S T U V W X Y R Z T U AA AB AC AD J K L M N G H AE AF@2 ~
>`.pickRestart({
  A: "~ g1 a1 b1", B: "c2 g1", C: "c2!2 d2 e2", D: "f2@3 c2 f2!2 g2@2", E: "c2@3 c2 g1@2 a1@2", F: "c2 e2", G: "a2 d2",
  H: "f2 g2", I: "c2 g1 a1 b1", J: "c2@3 c2 g1@3 a1", K: "c2@2 c2@2 d2!2 e2 c2", L: "f2@3 e2 f2!2 g2!2",
  M: "c2@3 c2 g1!2 a1 g1", N: "c2@3 c2 e2@3 e2", O: "c2@4 g1@3 a1", P: "f2@3 e2 f2!2 g2@2", Q: "c2@4 e2@3 e2",
  R: "c2 g2", S: "c2@2 c2 g2", T: "f2@2 f2 g2", U: "c2@2 g1 a1", V: "c2!2", W: "d2@2 d2 e2", X: "f2@2 f2 f#2",
  Y: "g2@2 g1 a1", Z: "c3@2 c2 g2", AA: "c2 a1", AB: "d2 f2", AC: "g2@2 g2!2 g2@2 g2!2", AD: "g2@2 g2!2 g2@2 g2@2",
  AE: "c2@2 f2@3 d2@3", AF: "[f2@4 g2@3 c2@9]/2",
})).s("gm_electric_bass_pick").gain(0.72)

// chords · clavinet · "piano2"
const clavinet = note(`<
  A B C D C E F G@2 H@2 I@2 J K L@2 M N O P J K Q@2 R S T@2 U V W@2 X Y Z@2 AA AB AC@2 H@2 I@2 J K L@2 M N O P J K Q@2 R
  S T@2 AD V AE@2 AF Y Z@2 AG AB AC@2 H@2 I@2 J K AH@2 AI@2 ~
>`.pickRestart({
  A: "~@6 g2 a2", B: "[g2,c3] [g2,c3]@3", C: "d#3 e3@3 g3@4 d#3@2 d#3@2 c3@2 a2@2", D: "[c3,g3]@2 [c3,g3]@4 [d3,g3] c3",
  E: "[g3,c4,e4]@3 [g3,c4,e4] [g3,b3,d4]@4", F: "[e3,a3,c4]@3 [e3,a3,c4] [d3,f#3,c4]@4",
  G: "[[f3,a3,c4]@2 [f3,a3,c4]@2 [g3,e4] [f#3,d#4] [f3,d4] [d#3,c4]@3 [e3,c4]@2 a3 g3 e3 d3]/2", // F C D#m Dm Cm C
  H: "[[g3,c4,e4]@2 [c4,e4,g4]@2 [c4,e4,g4]!3 [a#3,e4,g4]@3 [a#3,e4,g4]@2 [g3,e4]@2 [e3,c4]@2]/2", // C Edim C
  I: "[[c3,f3,a3]@2 [f3,a3,c4]@2 [f3,a3,c4]!3 [e3,g3,c4]@2 a3 [c3,e3,g3]@6]/2", // F C
  J: "[g3,c4,e4]!2 [c4,e4,g4]@2 [b3,e4,g4]@2 e4 g4", K: "[c4,e4,a4]@2 [c4,e4,a4]@2 [f#3,e4] d4 c4@2",
  L: "[[c3,f3,a3]@2 [f3,a3,c4]@2 [g3,e4] d4 c4 [e3,g3,c4]@2 a3 [c3,e3,g3]@6]/2", // F C
  M: "[g3,c4,e4] e4 g4 e4 [c4,e4,g4]!2 [c4,e4,g4]@2", N: "[a#3,e4,g4]!2 [g3,e4] [e3,c4]",
  O: "[c3,f3,a3] a3 c4 a3 [f3,a3,c4] a3 e4@2", P: "[e3,g3,d4] c4@7",
  Q: "[[c3,f3,a3]@2 [f3,a3,c4]@2 [g3,e4] d4 c4 [e3,g3,c4]@9]/2", R: "[e3,g3,c4]@5 a3 c4!2", S: "[a#2,e3,a3] g3@7",
  T: "[[a2,c3,f3]@3 e3 f3 g3 [c3,e3]@10]/2", U: "[g2,c3,e3]@4 [c3,e3,g3] [c3,e3,g3]@3", V: "[d3,f#3,a3] [f#3,a3,c4]@3",
  W: "[[f3,a3] c4 e4 c4 e4@2 c4 [g3,b3,d4]@9]/2", X: "[e3,g3] c4 e4 c4 e4@2 d4 c4", Y: "[g3,a#3,e4] d4 e4!2 d4 c4@3",
  Z: "[[c3,f3,a3]@2 a3 g3 a3 g3 [c3,e3,g3]@10]/2", AA: "~ e3 g3!2 [c3,e3,a3] a3 c4 a3",
  AB: "[f#3,a3,e4] e4@2 [a3,c4,f4]@2 e4 c4@2", AC: "[~ c4 d4 c4 [b3,d4,g4]@2 f4 [g3,b3,e4]@3 g3@2 a3@2 c4@2]/2",
  AD: "[g2,c3,e3]@3 g2 a2 c3@2 c3", AE: "[[f3,a3]@2 e4 c4 e4@2 c4 [g3,b3,d4]@8 c4]/2",
  AF: "[e3,g3,c4] c4@2 c4 e4@2 d4 c4", AG: "~ e3 g3!2 [c3,e3,a3] a3@2 a3",
  AH: "[[c3,f3,a3]@2 [f3,a3,c4]@2 [g3,e4] d4 c4 [e3,g3,c4]@3 [c3,f3,a3]@3 [d3,f#3,b3]@3]/2", // F C F Bm
  AI: "[[c3,f3,a3]@2 [f3,a3,c4]@2 [g3,b3,e4] d4 e4 [g3,c4,e4]@9]/2", // F Em C
})).s("gm_clavinet").gain(0.47).pan(1)

// drums · kick
const kick = s("bd").struct("<~ A@24 B A C A@29 B A C A@22 ~@2>".pickRestart({
  A: "x ~@2 x ~@3 x", B: "x", C: "x ~@2 x ~@2 x!2",
})).gain(0.47)

// drums · snare
const snare = s("sd").struct("<~ [~ x]!24 ~ [~ x]!31 ~ [~ x]!24 ~@2>").gain(0.47)

// drums · hihat
const hihat = s("hh").struct("<A@9 B@2 A C A@12 D A@14 E B@2 A C A@12 D A@14 E B@2 A C A@5 ~@2>".pickRestart({
  A: "x!4", B: "x ~ x ~ x ~ x!2", C: "x ~@3 x ~@3 x ~ x!3 ~ x ~", D: "x ~@3 x ~@3 x ~@3 x ~ x!2", E: "x",
})).gain(0.47)

// drums · open hat
const open_hat = s("oh").struct(`<
  ~ A ~ A B ~ C ~ B A@2 ~ C B ~@2 B@9 ~ B@14 ~ A@2 ~ C B ~@2 B@9 ~ B@14 ~ A@2 ~ C B ~@2 B@2 ~@2
>`.pickRestart({
  A: "~@3 x ~@4", B: "~@3 x ~@3 x", C: "~@7 x",
})).gain(0.47)

// drums · crash
const crash = s("cr").struct(`<
  A@2 ~@5 A ~ A ~@7 A ~@7 A@3 ~@3 B ~ A ~@6 C A ~@7 A ~@7 A@3 ~@3 B ~ A ~@6 C A ~@6 C D ~@2
>`.pickRestart({
  A: "x", B: "~@7 x", C: "~ x ~@2", D: "x ~@6 x",
})).gain(0.47)

// drums · ride
const ride = s("rd").struct("<~@81 [~@7 x] ~@2>").gain(0.47)

stack(bass, clavinet, kick, snare, hihat, open_hat, crash, ride)