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 the local logic to a separate function.
The options for resuming the send transport.
A promise that resolves when the send transport is resumed and the UI is updated.
await resumeSendTransportAudio({
parameters: {
audioProducer: producer,
localAudioProducer: localProducer,
islevel: '1',
hostLabel: 'Host',
lock_screen: false,
shared: false,
updateAudioProducer: updateProducerFunction,
updateLocalAudioProducer: updateLocalProducerFunction,
videoAlreadyOn: false,
updateUpdateMainWindow: updateWindowFunction,
prepopulateUserMedia: prepopulateFunction,
prepopulateLocalUserMedia: prepopulateLocalFunction,
},
});
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 the local logic to a separate function.
Param: options
The options for resuming the send transport.
Param: options.parameters
The parameters for resuming the send transport.
Param: options.parameters.audioProducer
The primary audio producer to resume.
Param: options.parameters.localAudioProducer
The local audio producer to resume.
Param: options.parameters.islevel
The level of the audio producer.
Param: options.parameters.hostLabel
The label for the host.
Param: options.parameters.lock_screen
Indicates if the screen is locked.
Param: options.parameters.shared
Indicates if the screen is shared.
Param: options.parameters.videoAlreadyOn
Indicates if the video is already on.
Param: options.parameters.updateAudioProducer
Function to update the audio producer state.
Param: options.parameters.updateLocalAudioProducer
Function to update the local audio producer state.
Param: options.parameters.updateUpdateMainWindow
Function to update the main window.
Param: options.parameters.prepopulateUserMedia
Function to prepopulate user media.
Returns
A promise that resolves when the send transport is resumed and the UI is updated.
Throws
Throws an error if there is an issue during the process of resuming the audio send transport.
Example