AudioData
final class AudioDataStores input audio samples in a circular buffer.
-
Creates a zero-initialized buffer with capacity for
sampleCountframes per channel.Declaration
Swift
init(format: AudioDataFormat, sampleCount: Int) -
Snapshot of all internal buffer elements in chronological order (most recent at the end).
Declaration
Swift
final var buffer: FloatBuffer { get } -
Capacity in number of multi-channel sample frames.
Declaration
Swift
final var bufferLength: Int { get } -
Declaration
Swift
final let format: AudioDataFormat -
Loads the latest samples from
audioRecord.Declaration
Swift
final func load(audioRecord: AudioRecord) throws -
Loads a slice of interleaved audio samples from
bufferinto the internal ring buffer.Declaration
Swift
final func load(buffer: FloatBuffer, offset: Int, length: Int) throws