Created
September 26, 2015 14:27
-
-
Save pepijn-devries/35ca5d9c12ef29409111 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
# play all samples in the module at note "C-3" | |
playSample(mod) | |
# play chromatic scales of octaves 2 and 3 using the 23rd sample | |
data(period_table) | |
for (i_note in as.vector(outer(names(period_table)[-1:-2], | |
c(2:3), function(x, y) paste(x, y, sep = "")))) | |
{ | |
print(i_note) | |
playSample(PTSample(mod, 23), 0.1, T, i_note, 0.5) | |
} | |
# play all finetunes of C-3 | |
for (ft in -8:7) | |
{ | |
print(ft) | |
playSample(PTSample(mod, 23), 0.1, T, "C-3", 0.5, finetune = ft) | |
} | |
# export one of the samples as *.wav file | |
writeWave(PTSample(mod, 25), "guitar slide.wav") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment