Last active
October 26, 2019 08:50
-
-
Save hamin/1d3f45623b38504d72c8 to your computer and use it in GitHub Desktop.
Arcade Fire's 'The Suburbs' in Sonic PI ;) Download http://sonic-pi.net and copy paste this Grammy Winning gem ;)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
in_thread do | |
loop do | |
sample :drum_bass_hard, amp: 2 | |
sleep 2 | |
end | |
end | |
in_thread do | |
loop do | |
sleep 1 | |
sample :drum_snare_hard, amp: 2 | |
sleep 1 | |
end | |
end | |
in_thread do | |
loop do | |
sample :drum_cymbal_pedal, amp: 1 | |
sleep 0.5 | |
end | |
end | |
in_thread do | |
loop do | |
cue :tick | |
#synth = [:pulse, :fm, :tb303].sample | |
use_synth :fm | |
4.times do | |
play chord(:D4, :major) | |
sleep 0.5 | |
end | |
4.times do | |
play chord(:B4, :minor) | |
sleep 0.5 | |
end | |
4.times do | |
play chord(:Gb4, :major) | |
sleep 0.5 | |
end | |
4.times do | |
play chord(:A4, :major) | |
sleep 0.5 | |
end | |
end | |
end | |
in_thread do | |
loop do | |
sync :tick | |
play_pattern_timed chord(:D4, :major), [0.25, 4], pan: -1 | |
play_pattern_timed chord(:B4, :minor), [0.25, 4], pan: 1 | |
play_pattern_timed chord(:Gb4, :major), [0.25, 4], pan: -1 | |
play_pattern_timed chord(:A4, :major), [0.25, 4], pan: 1 | |
end | |
end | |
riff1 = lambda do | |
sleep 0.5 | |
play :Gb6 | |
sleep 0.25 | |
play :Gb6 | |
sleep 0.25 | |
play :A6 | |
sleep 0.35 | |
play :B6 | |
sleep 0.5 | |
play :Gb6 | |
end | |
riff2 = lambda do | |
sleep 2.65 | |
play :Gb6 | |
sleep 0.5 | |
play :E6 | |
sleep 0.5 | |
play :Db6 | |
sleep 0.25 | |
play :E6 | |
end | |
riff3 = lambda do | |
sleep 1.75 | |
play :Db6 | |
sleep 0.35 | |
play :Db6 | |
sleep 0.5 | |
play :Db6 | |
sleep 0.25 | |
play :B5 | |
sleep 0.5 | |
play :A5 | |
sleep 0.25 | |
play :B5 | |
sleep 0.25 | |
play :Db6 | |
sleep 0.25 | |
play :Db6 | |
end | |
verse = lambda do | |
[riff1, riff2, riff3, riff2, riff3, riff2].map(&:call) | |
end | |
chorus_riff1 = lambda do | |
sleep 0.5 | |
play :Db7 | |
sleep 0.5 | |
play :B6 | |
sleep 0.5 | |
play :A6 | |
sleep 0.5 | |
play :Ab6 | |
sleep 0.85 | |
play :Db6 | |
sleep 0.15 | |
play :E6 | |
sleep 0.35 | |
play :Gb6 | |
end | |
chorus_riff2 = lambda do | |
sleep 1.1 | |
play :Gb6 | |
sleep 0.5 | |
play :E6 | |
sleep 0.5 | |
play :D6 | |
sleep 0.5 | |
play :Db6 | |
sleep 0.85 | |
play :D6 | |
sleep 0.15 | |
play :Db6 | |
sleep 0.35 | |
play :A5 | |
end | |
chorus = lambda do | |
sample :drum_splash_soft, amp: 2 | |
[chorus_riff1, chorus_riff2].map(&:call) | |
sample :drum_splash_soft, amp: 2 | |
end | |
verse.call | |
sleep 2.25 | |
in_thread do | |
loop do | |
sample :drum_cymbal_soft, amp: 2 | |
sleep 0.5 | |
end | |
end | |
chorus.call | |
sleep 0.7 | |
chorus.call |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Wicked! One quick tip - you'll definitely benefit from reading the help sections on
live_loop
and live coding in general :)