Video SDK for iOS API Reference
Loading...
Searching...
No Matches
ZoomVideoSDKAudioHelper Class Reference

A class to operate the audio action. More...

#include <ZoomVideoSDKAudioHelper.h>

Inherits NSObject.

Instance Methods

(ZoomVideoSDKError- startAudio
 Start audio.
 
(ZoomVideoSDKError- stopAudio
 Stop audio.
 
(ZoomVideoSDKError- muteAudio:
 Mute user's audio.
 
(ZoomVideoSDKError- unmuteAudio:
 Ask unmute user's audio.
 
(ZoomVideoSDKError- muteAllAudio:
 Mute all user's VOIP audio except my self.
 
(ZoomVideoSDKError- allowAudioUnmutedBySelf:
 Allow the others to unmute themselves or not.
 
(ZoomVideoSDKError- unmuteAllAudio
 Ask unmute all user's VOIP audio.
 
(ZoomVideoSDKError- subscribe
 Call the function to subscribe audio rawdata.
 
(ZoomVideoSDKError- unSubscribe
 Call the function to unSubscribe audio rawdata.
 
(BOOL) - resetAudioSession
 Reset Audio Session including Category and Mode for ZoomVideoSDK Audio Session Environment When developer change audio session in session.
 
(BOOL) - setSDKAudioSessionEnv
 Set the AVAudio Session Environment for Zoom Video SDK Session.
 
(void) - cleanAudioSession
 Clean Audio Session including Category and Mode.
 
(ZoomVideoSDKAudioDevice *_Nullable) - getCurrentAudioOutputRoute
 Get current audio output port description,AVAudioSessionPortDescription}.
 
(BOOL) - setAudioOutputRoute:
 Set audio output device. SeeZoomVideoSDKAudioDevice}.
 
(NSArray< ZoomVideoSDKAudioDevice * > *_Nullable) - getAvailableAudioOutputRoute
 Gets the available audio output port description,AVAudioSessionPortDescription}..
 
(BOOL) - showAudioOutputDeviceAirPlayPicker:
 Displays the system AirPlay picker.
 
(ZoomVideoSDKAudioDevice *_Nullable) - getCurrentAudioInputDevice
 Gets the current audio input device. SeeAVAudioSessionPortDescription}.
 
(NSArray< ZoomVideoSDKAudioDevice * > *_Nullable) - getAvailableAudioInputsDevice
 Gets the list of available audio input devices. SeeAVAudioSessionPortDescription}.
 
(BOOL) - setAudioInputDevice:
 Sets the audio input device..
 

Detailed Description

A class to operate the audio action.

Definition at line 32 of file ZoomVideoSDKAudioHelper.h.

Method Documentation

◆ allowAudioUnmutedBySelf:

- (ZoomVideoSDKError) allowAudioUnmutedBySelf: (BOOL) allowUnmute

Allow the others to unmute themselves or not.

Parameters
allowUnmuteYes means allow the user to unmute themself, otherwise NO.
Returns
The result of it.
Warning
Only host or manager can change this property.

◆ cleanAudioSession

- (void) cleanAudioSession

Clean Audio Session including Category and Mode.

Warning
SDK will restore audio session status after session end. if developer call overrideOutputAudioPort interface wtth AVAudioSessionPortBuiltInSpeaker in AVAudioSessionCategoryPlayAndRecord Category before join session, then sdk can not restore audio session BuiltInSpeaker output when session end,.
Deprecated
No longer maintain anymore!

◆ getAvailableAudioInputsDevice

- (NSArray< ZoomVideoSDKAudioDevice * > *_Nullable) getAvailableAudioInputsDevice

Gets the list of available audio input devices. SeeAVAudioSessionPortDescription}.

Returns
An array of available audio input devices.

◆ getAvailableAudioOutputRoute

- (NSArray< ZoomVideoSDKAudioDevice * > *_Nullable) getAvailableAudioOutputRoute

Gets the available audio output port description,AVAudioSessionPortDescription}..

Returns
A list of the vailable audio output pott descriptions.

◆ getCurrentAudioInputDevice

- (ZoomVideoSDKAudioDevice *_Nullable) getCurrentAudioInputDevice

Gets the current audio input device. SeeAVAudioSessionPortDescription}.

Returns
The current audio input device.

◆ getCurrentAudioOutputRoute

- (ZoomVideoSDKAudioDevice *_Nullable) getCurrentAudioOutputRoute

Get current audio output port description,AVAudioSessionPortDescription}.

Returns
The current audio output port description.

◆ muteAllAudio:

- (ZoomVideoSDKError) muteAllAudio: (BOOL) allowUnmute

Mute all user's VOIP audio except my self.

Parameters
allowUnmuteYes means allow the user to unmute themself, otherwise NO.
Returns
The result of it.
Warning
Only host or manager can mute all user's audio.

◆ muteAudio:

- (ZoomVideoSDKError) muteAudio: (ZoomVideoSDKUser *_Nullable) user

Mute user's audio.

Returns
The result of it.
Warning
If mute self use userid=0.
Only host or manager can mute others audio.

◆ resetAudioSession

- (BOOL) resetAudioSession

Reset Audio Session including Category and Mode for ZoomVideoSDK Audio Session Environment When developer change audio session in session.

Returns
Yes means set auidio success, otherwise failed.
Deprecated
Use setSDKAudioSessionEnv instead.

◆ setAudioInputDevice:

- (BOOL) setAudioInputDevice: (ZoomVideoSDKAudioDevice *_Nullable) device

Sets the audio input device..

Parameters
deviceThe device to set as the audio input. SeeAVAudioSessionPortDescription}.
Returns
YES If the input device was set successfully, otherwise the method failed.

◆ setAudioOutputRoute:

- (BOOL) setAudioOutputRoute: (ZoomVideoSDKAudioDevice *_Nullable) device

Set audio output device. SeeZoomVideoSDKAudioDevice}.

Parameters
deviceThe device to set as the audio output.
Returns
YES if the output route was set successfully; otherwise, the method failed.

◆ setSDKAudioSessionEnv

- (BOOL) setSDKAudioSessionEnv

Set the AVAudio Session Environment for Zoom Video SDK Session.

Warning
Developer change AVAudio Session by self special needs in SDK session,will cause the audio output abnormal. Then developer can set SDK AVAudio Session environment.
Returns
Yes means set audio success, otherwise failed.

◆ showAudioOutputDeviceAirPlayPicker:

- (BOOL) showAudioOutputDeviceAirPlayPicker: (UIView *_Nullable) parentView

Displays the system AirPlay picker.

Parameters
parentViewThe parent view where the AirPlay picker will be shown.
Returns
YES If the picker was shown successfully, otherwise the method failed.

◆ startAudio

- (ZoomVideoSDKError) startAudio

Start audio.

Returns
The result of it.

◆ stopAudio

- (ZoomVideoSDKError) stopAudio

Stop audio.

Returns
the result of it.

◆ subscribe

- (ZoomVideoSDKError) subscribe

Call the function to subscribe audio rawdata.

Warning
Please check the callack "- (void)onMixedAudioRawDataReceived:(ZoomVideoSDKAudioRawData *)rawData".
" - (void)onOneWayAudioRawDataReceived:(ZoomVideoSDKAudioRawData *)rawData user:(ZoomVideoSDKUser *)user.

◆ unmuteAllAudio

- (ZoomVideoSDKError) unmuteAllAudio

Ask unmute all user's VOIP audio.

Returns
The result of it.
Warning
Only host or manager can ask unmute all user's audio.
This function will trigger the callback onHostAskUnmute.

◆ unmuteAudio:

- (ZoomVideoSDKError) unmuteAudio: (ZoomVideoSDKUser *_Nullable) user

Ask unmute user's audio.

Returns
The result of it.
Warning
If unmute self use userid=0.
Only host or manager can unmute others audio.
This function will trigger the callback onHostAskUnmute.

◆ unSubscribe

- (ZoomVideoSDKError) unSubscribe

Call the function to unSubscribe audio rawdata.

Warning
Please check the callack "- (void)onMixedAudioRawDataReceived:(ZoomVideoSDKAudioRawData *)rawData".
" - (void)onOneWayAudioRawDataReceived:(ZoomVideoSDKAudioRawData *)rawData user:(ZoomVideoSDKUser *)user.