AudioDataCaptured

An event indicating that a buffer of audio data has been captured.

The buffer contains frameCount frames in the format set by the AudioCaptureOptions of the session. Samples are 32-bit floating-point values, stored separately for each channel.

Since

9.6.0

Functions

Link copied to clipboard
open fun channelCount(): Int
Returns the number of channels in this buffer.
Link copied to clipboard
open fun channelData(channel: Int): Array<Float>
Returns a new array with the samples of the given channel.
Link copied to clipboard
open fun frameCount(): Int
Returns the number of frames in this buffer.
Link copied to clipboard
Returns the capture session that initiated this event.
Link copied to clipboard
open fun timestamp(): Duration
Returns the time from the first captured frame of the session to the first frame of this buffer.