resumeSendTransportAudio

Resumes the send transport for audio and updates the UI and audio producer state accordingly.

This function supports both a primary and a local audio producer, delegating local handling to a separate function.

Workflow:

  1. Resume Primary Audio Producer: If an active primary audio producer exists, it is resumed.

  2. Update UI: Based on conditions (videoAlreadyOn, islevel, lockScreen, shared), updates the main window state and prepopulates user media if needed.

  3. Update Audio Producer State: Updates the audio producer state to reflect the resumed producer.

  4. Handle Local Audio Transport Resumption: Invokes resumeLocalSendTransportAudio to handle the local audio transport resumption.

Parameters

options

The options containing parameters for resuming audio send transport

Example:

val options = ResumeSendTransportAudioOptions(
parameters = object : ResumeSendTransportAudioParameters {
override val audioProducer = myAudioProducer
override val localAudioProducer = myLocalAudioProducer
override val islevel = "2"
override val hostLabel = "Host123"
override val lockScreen = false
override val shared = false
override val videoAlreadyOn = false
override val updateAudioProducer = { producer -> setAudioProducer(producer) }
override val updateLocalAudioProducer = { producer -> setLocalAudioProducer(producer) }
override val updateUpdateMainWindow = { state -> setMainWindowState(state) }
override val prepopulateUserMedia = { opts -> /* prepopulate */}
override fun getUpdatedAllParams() = this
}
)

resumeSendTransportAudio(options)