Skip to content

Instantly share code, notes, and snippets.

View AlexandreRangel's full-sized avatar

Alexandre Rangel AlexandreRangel

View GitHub Profile
# the computer is singing and playing based on rules since the beggining of the night - v18
# Alexandre rANGEL www.quasecinema.org Sonic Pi 2.9 20-Apr-2016
myBPM = 72
use_bpm myBPM
c1 = c2 = q1 = q2 = k1 = k2 = 0
set_volume! 0.75
use_random_seed (Time.new.year / Time.new.month / Time.new.day * Time.new.hour * Time.new.min * Time.new.sec)
# http://www.freesound.org/people/digifishmusic/sounds/44928 and http://www.freesound.org/people/toiletrolltube/sounds/179881
# download samples, rename to vocal_la_c4, cello and hatMetal and put it in your path, defined here:
use_sample_pack_as '/Users/rangel/pisamples', :mySamples
# Alexandre rANGEL
# www.quasecinema.org
# my mothers were angels with fire veils and feather wings v14
# Sonic Pi 2.10
# 16-Apr-2016
use_bpm 140
set_volume! 0.777
t = Time.new
@AlexandreRangel
AlexandreRangel / enoch-v12.rb
Last active April 24, 2016 19:54
Sonic Pi music code
# Alexandre rANGEL
# www.quasecinema.org
# enoch v12
# 22 April 2016
# Sonic Pi 2.10
use_random_seed 3.14
x = 0
y = 0
d3= 0
# Alexandre rANGEL
# www.quasecinema.org
# Bast - v06
# 1 May 2016
# Sonic Pi 2.10
set_sched_ahead_time! 2
use_random_seed 3.14
y = 0
d3= 0
# Alexandre rANGEL
# www.quasecinema.org
# "mother gave me wings" v05
# 8 May 2016
# Sonic Pi 2.10
use_bpm 60
set_volume! 0.8
sample_birds = '/Users/rangel/pisamples/birds.flac'
# Alexandre rANGEL
# www.quasecinema.org
# "a new bark in town" v01
# 15 May 2016
# Sonic Pi 2.10
use_bpm 48
sample_drawer = '/Users/rangel/pisamples/drawer.wav'
#http://www.freesound.org/people/jesabat/sounds/119725/
@AlexandreRangel
AlexandreRangel / my-scales-v08.rb
Created May 22, 2016 21:17
Sonic Pi music code
# Alexandre rANGEL
# www.quasecinema.org
# "my-scales" v08
# 21 May 2016
# Sonic Pi 2.10
t = Time.new
use_random_seed Math::PI
puts Math::PI
set_volume! 1.0
# "i'm at home" v18 Alexandre rANGEL www.quasecinema.org
# 29 May 2016 Sonic Pi 2.10
use_bpm 96; use_random_seed Math::PI; set_sched_ahead_time! 4
set_volume! 0.66
sample_scratch = '/Users/rangel/pisamples/scratch.wav' #www.freesound.org/people/junggle/sounds/29940/
sample_train = '/Users/rangel/pisamples/train.wav' #www.freesound.org/people/lex1975/sounds/114468/
sample_barceloneta = '/Users/rangel/pisamples/barceloneta.wav' #www.freesound.org/people/barcelonetasonora/sounds/186337/
load_samples [sample_scratch,sample_train,sample_barceloneta,:bd_808,:bd_haus]
#################################################################################
puts "let's go!"
@AlexandreRangel
AlexandreRangel / please-play-this.rb
Created June 2, 2016 10:33
Sonic Pi music code
# Sonic Pi 2.10
use_synth :dsaw
live_loop :serra1 do
play chord(:d2, :m7).choose,
detune: rrand_i(-16,-8), detune_slide: [1,2,4,8].choose,
amp: 0.9, attack: 2, sustain: 2, release: [3.5].choose
sleep 4
end
live_loop :serra2 do
play chord([:d4,:d5].choose, :major).choose,
@AlexandreRangel
AlexandreRangel / now-play-this.rb
Created June 3, 2016 10:27
Sonic Pi 2.10 music code
use_synth :growl
64.times do
play rrand(30,90),
attack: rrand(4,16), sustain: rrand(2,4),
release: rrand(4,24), slide_shape: 3,
cutoff: rrand(62,112),
cutoff_slide: [2,4,8,12].choose,
res: rrand(0,0.99),
res_slide: [2,4,6].choose,
pan: rrand(-0.4,0.4),