SampledSoundList
SampledSoundList[{sample1, sample2, ...}, sampleRate]represents a mono PCM buffer. Samples are real values, normally in the range from -1 to 1, and sampleRate is measured in samples per second.
Playback
Wrap SampledSoundList in Sound:
Sound[
SampledSoundList[
Table[Sin[2 Pi 440 n/8000], {n, 0, 7999}],
8000
]
]WLJS evaluates and pools the sample data when the output is rendered, but creates the browser audio buffer only when playback starts. This keeps large sampled sounds lightweight before they are used.
Because sampled data has no discrete pitches, its preview uses the sound icon rather than a piano roll. When it can be computed, the duration is still shown.
NumericArray and offloaded sample data are supported and avoid unnecessary list conversion for larger buffers.