Play audio samples
## S4 method for signature 'PTSample' playSample(x, silence = 0, wait = T, note = "C-3", loop = 1, ...) ## S4 method for signature 'PTModule' playSample(x, silence = 0, wait = T, note = "C-3", loop = 1, ...)
x |
Either a |
silence |
Especially for short samples, the |
wait |
A |
note |
A |
loop |
A positive |
... |
Further arguments passed on to |
Returns nothing but plays the sample(s) as audio.
Pepijn de Vries
Other sample.operations:
PTSample-class
,
PTSample-method
,
fineTune()
,
loopLength()
,
loopSample()
,
loopStart()
,
loopState()
,
name
,
read.sample()
,
sampleLength()
,
volume()
,
waveform()
,
write.sample()
Other sample.rate.operations:
sampleRate
## Not run: data("mod.intro") ## play all samples in mod.intro: playSample(mod.intro, 0.2, loop = 0.5) ## play a chromatic scale using sample number 3: for (note in c("A-2", "A#2", "B-2", "C-3", "C#3", "D-3", "D#3", "E-3", "F-3", "F#3", "G-3", "G#3")) { playSample(PTSample(mod.intro, 3), note = note, silence = 0.05, loop = 0.4) } ## play the sample at a rate based on a specific ## video mode and finetune: playSample(PTSample(mod.intro, 3), video = "NTSC", finetune = -5) ## End(Not run)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.