ReadOnly

class ReadOnly(aqRef: AudioQueueRef, asbd: AudioStreamBasicDescription, stateRef: StableRef<MacosAudioQueue.ReadOnly.State>) : MacosAudioQueue<MacosAudioQueue.ReadOnly.State>

Constructors

Link copied to clipboard
constructor(aqRef: AudioQueueRef, asbd: AudioStreamBasicDescription, stateRef: StableRef<MacosAudioQueue.ReadOnly.State>)

Types

Link copied to clipboard
class State(val running: Boolean, val channel: Channel<ByteArray>)

Functions

Link copied to clipboard
fun dispose(inImmediate: Boolean = true)

Disposes the aqRef.

Link copied to clipboard
fun flush()

Resets the aqRef's decoder state.

Link copied to clipboard
fun pause()

Pauses playing or recording audio.

Link copied to clipboard
fun reset()

Resets the aqRef.

Link copied to clipboard
fun start()

Begins playing or recordings audio.

Link copied to clipboard
fun stop(inImmediate: Boolean = true)

Stops playing or recording audio.

Link copied to clipboard
suspend fun streamTo(dst: SendChannel<ByteArray>)