setTransmissionMode(_:channelUUID:completionHandler:)
Sets the audio transmission mode for the channel you specify.
Declaration
func setTransmissionMode(_ transmissionMode: PTTransmissionMode, channelUUID: UUID, completionHandler: (@Sendable ((any Error)?) -> Void)? = nil)func setTransmissionMode(_ transmissionMode: PTTransmissionMode, channelUUID: UUID) async throwsParameters
- transmissionMode:
The transmission mode.
- channelUUID:
The channel identifier the participant becomes active in.
- completionHandler:
The completion handler that contains an optional error.
errorAn error, if any, that indicates the reason why the system couldn’t set the transmission mode.
Discussion
By default, a channel’s transmission mode is PTTransmissionMode.halfDuplex — indicating that only one participant can send or receive audio at a time. Use PTTransmissionMode.fullDuplex to allow a person to transmit and receive audio simultaneously.
Set the transmission mode to PTTransmissionMode.listenOnly to prevent a participant from transmitting any audio.