We've talked a lot about samples, meaning individual values in a stream of audio. Now, we arrive at sampling, meaning recording audio, playing back of audio, and sample, which means a piece of audio. Sadly, the word sample has an ambiguous meaning in this context.
To be able to record and play something, we'll need to reference memory somehow. We have two options for this: RAM and hard disk. Playing from the hard disk and recording to it can be done using
[sfrecord~] respectively. The
[sfinfo~] object can be used to get additional info about the audio file such as sample rate, length, and so on. Playing from the disk is particularly useful if we need to play very long files since they would of course ...