Skip to content

Instantly share code, notes, and snippets.

@kniknoo
Created March 17, 2018 04:31
Show Gist options
  • Save kniknoo/fcb19480d43357297434477bb7d2df22 to your computer and use it in GitHub Desktop.
Save kniknoo/fcb19480d43357297434477bb7d2df22 to your computer and use it in GitHub Desktop.
use_bpm 95
with_fx :compressor, slope_above: 0.6, threshold: 0.4, amp: 1.5 do
live_loop :amen_break do
with_fx :bitcrusher, sample_rate: rrand_i(100, 40000), bits: [2, 4, 8, 8, 8, 16, 16, 16, 16, 16, 16, 16, 16].choose do
use_sample_defaults beat_stretch: 8, num_slices: 32, release: 0.5, sustain: 0#, rate: [-1, 1].choose
r = [1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27, 29, 31]
#sample :loop_amen_full, slice: [0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28, 30].ring.tick
sleep 0.25
(line, 2, 6).choose.times do
#sample :loop_amen_full, slice: r.choose, beat_stretch: rrand(8.05, 8.1) #unless one_in(11)
sleep 0.25
end
end
end
end
live_loop :bass do
use_synth :fm
use_synth_defaults amp: 0.5, release: 3
sync :amen_break
#control amp: 0
play (scale, :b2, :blues_minor, num_octaves: 2).choose, amp: 0.6, cutoff: rrand(80, 120), depth: rrand(0.5, 8), divisor: rrand(0.99, 1.01) unless one_in(5)
play (scale, :b4, :blues_minor, num_octaves: 2).choose, cutoff: rrand(80, 120), depth: rrand(0.5, 8), divisor: rrand(0.99, 1.01) unless one_in(3)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment