Video SDK v3.7.1 API Reference for Unity
Video SDK v3.7.1 API Reference for Unity Documentation

Agora provides ensured quality of experience (QoE) for worldwide Internet-based voice and video communications through a virtual global network optimized for real-time web and mobile-to-mobile applications.

During API calls, the SDK may returns error codes and warning codes. See Error Codes and Warning Codes.

  • The IRtcEngine class is the entry point of the Agora RTC SDK providing API methods for applications to quickly start a voice/video communication or interactive broadcast.
  • The AgoraCallback reports runtime events to the applications.
  • The AgoraChannel class provides methods that enable real-time communications in a specified channel. By creating multiple AgoraChannel instances, users can join multiple channels.
  • The AudioEffectManagerImpl class provides APIs that set the audio effects.
  • The AudioPlaybackDeviceManager class provides APIs that set the audio playback device, and retrieves the information of the audio playback device.
  • The AudioRecordingDeviceManager class provides APIs that set the audio capturing device, and retrieves the information of the audio capturing device.
  • The VideoDeviceManager class provides APIs that set the video capturing device, and retrieves the information of the video capturing device.
  • The MetadataObserver class provides APIs that register the MetadataObserver and report the status of the metadata.
  • The PacketObserver class provides APIs that register the PacketObserver and report the status of the audio packet.
  • The AudioRawDataManager class provides APIs that register the audio raw data observer and report the status of the audio raw data.
  • The VideoRawDataManager class provides APIs that register the video raw data observer and report the status of the video raw data.
  • The VideoSurface class provides APIs that set the video renderer type and the local/remote video.
  • The MediaRecorder class provides APIs for recording the audio and video on the client.

Core Methods

Method Description
GetEngine1 Initializes the IRtcEngine.
GetEngine2 Initializes the IRtcEngine and specifies the connection area.
Destroy Destroys all IRtcEngine resources.
SetChannelProfile Sets the channel profile of the Agora IRtcEngine.
SetClientRole1 Sets the role of the user in interactive live streaming.
SetClientRole2 Sets the role and level of the user in interactive live streaming.
JoinChannelByKey Allows a user to join a channel with token.
JoinChannel Joins a channel with the user ID, and configures whether to publish or automatically subscribe to the audio or video streams.
SwitchChannel Switches to a different channel in interactive live streaming.
SwitchChannel2 Switches to a different channel and sets the subscribing state in the interactive live streaming.
LeaveChannel Allows a user to leave a channel.
RenewToken Renews the Token.
GetConnectionState Gets the current connection state of the SDK.

Core Events

Event Description
OnConnectionStateChangedHandler Occurs when the connection state between the SDK and the server changes.
OnJoinChannelSuccessHandler Occurs when a user joins a channel.
OnReJoinChannelSuccessHandler Occurs when a user rejoins the channel.
OnLeaveChannelHandler Occurs when a user leaves the channel.
OnClientRoleChangedHandler Occurs when the user role switches in interactive live streaming.
OnClientRoleChangeFailedHandler Occurs when the user role switch fails in the interactive live streaming.
OnUserJoinedHandler Occurs when a remote user (COMMUNICATION)/ host (LIVE_BROADCASTING) joins the channel.
OnUserOfflineHandler Occurs when a remote user (COMMUNICATION)/ host (LIVE_BROADCASTING) leaves the channel.
OnNetworkTypeChangedHandler Occurs when the local network type changes.
OnConnectionLostHandler Occurs when the SDK cannot reconnect to Agora's edge server 10 seconds after its connection to the server is interrupted.
OnTokenPrivilegeWillExpireHandler Occurs when the token expires in 30 seconds.
OnRequestTokenHandler Occurs when the token expires.

Audio Management

Method Description
EnableAudio Enables the audio module.
DisableAudio Disables the audio module.
SetAudioProfile Sets the audio parameters and application scenarios.
AdjustRecordingSignalVolume Adjusts adjust the capturing signal volume.
AdjustUserPlaybackSignalVolume Adjusts the playback signal volume of a specified remote user.
AdjustPlaybackSignalVolume Adjusts the playback signal volume of all remote users.
EnableLocalAudio Enables/Disables the local audio sampling.
MuteLocalAudioStream Stops or resumes publishing the local audio stream.
MuteRemoteAudioStream Stops or resumes subscribing to the audio stream of a specified user.
MuteAllRemoteAudioStreams Stops or resumes subscribing to the audio streams of all remote users.
SetExternalAudioSourceVolume Sets the volume of the external audio frame in the specified position.

Audio Volume Indication

Method Description
EnableAudioVolumeIndication Enables the OnVolumeIndicationHandler callback at a set time interval to report on which users are speaking and the speakers' volume.
Event Description
OnVolumeIndicationHandler Reports which users are speaking, the speakers' volumes, and whether the local user is speaking.
OnActiveSpeakerHandler Reports which user is the loudest speaker.

Face detection

Method Description
EnableFaceDetection Enables/Disables face detection for the local user.
Event Description
OnFacePositionChangedHandler Reports the face detection result of the local user.

Video Management

Method Description
EnableVideo Enables the video module.
EnableVideoObserver Enables the video observer.
DisableVideo Disables the video module.
DisableVideoObserver Disables the video observer.
SetVideoEncoderConfiguration Sets the video encoder configuration.
SetForUser Sets the local/remote video.
StartPreview Starts the local video preview before joining the channel.
StopPreview Stops the local video preview and disables video.
EnableLocalVideo Enables/Disables the local video capture.
MuteLocalVideoStream Stops or resumes publishing the local video stream.
MuteRemoteVideoStream Stops or resumes subscribing to the video stream of a specified user.
MuteAllRemoteVideoStreams Stops or resumes subscribing to the video streams of all remote users.

Audio Effect Playback

Method Description
GetEffectsVolume Gets the volume of the audio effects.
SetEffectsVolume Sets the volume of the audio effects.
SetVolumeOfEffect Sets the volume of a specified audio effect.
PlayEffect Plays a specified audio effect.
StopEffect Stops playing a specified audio effect.
StopAllEffects Stops playing all audio effects.
PreloadEffect Preloads a specified audio effect file into the memory.
UnloadEffect Releases a specified audio effect from the memory.
PauseEffect Pauses a specified audio effect.
PauseAllEffects Pauses all audio effects.
ResumeEffect Resumes playing a specified audio effect.
ResumeAllEffects Resumes playing all audio effects.
SetVoiceOnlyMode Sets the voice-only mode.
Event Description
OnAudioEffectFinishedHandler Occurs when the local audio effect playback finishes.

Audio file information

Method Description
GetAudioFileInfo Gets the information of a specified audio file.
Event Description
OnRequestAudioFileInfoHandler Reports the information of an audio file.

Voice Effect

Method Description
SetVoiceBeautifierPreset Sets an SDK preset voice beautifier effect.
SetVoiceBeautifierParameters Sets parameters for SDK preset voice beautifier effects.
SetAudioEffectPreset Sets an SDK preset audio effect.
SetAudioEffectParameters Sets parameters for SDK preset audio effects.
SetVoiceConversionPreset Sets an SDK preset voice conversion effect.
SetLocalVoicePitch Changes the voice pitch of the local speaker.
SetLocalVoiceEqualization Sets the local voice equalization effect.
SetLocalVoiceReverb Sets the local voice reverberation.
EnableLocalVoicePitchCallback Enables reporting the voice pitch of the local user.
Event Description
OnLocalVoicePitchInHzHandler Reports the voice pitch of the local user.

Sound Position Indication

Method Description
EnableSoundPositionIndication Enables/Disables stereo panning for remote users.
SetRemoteVoicePosition Sets the sound position and gain of a remote user.

Audio Routing Control

Method Description
SetDefaultAudioRouteToSpeakerphone Sets the default audio playback route. (For Android and iOS only)
SetEnableSpeakerphone Enables/Disables the audio playback route to the speakerphone. (For Android and iOS only)
IsSpeakerphoneEnabled Checks whether the speakerphone is enabled. (For Android and iOS only)
Event Description
OnAudioRouteChangedHandler Occurs when the local audio route changes.

Local Media Events

Event Description
OnLocalAudioStateChangedHandler Occurs when the local audio state changes.
OnLocalVideoStateChangedHandler Occurs when the local video state changes.
OnFirstLocalAudioFramePublishedHandler Occurs when the first audio frame is published.
OnFirstLocalVideoFramePublishedHandler Occurs when the first video frame is published.
OnFirstLocalVideoFrameHandler Occurs when the first local video frame is rendered.
OnAudioPublishStateChangedHandler Occurs when the audio publishing state changes.
OnVideoPublishStateChangedHandler Occurs when the video publishing state changes.

Remote Media Events

Event Description
OnRemoteAudioStateChangedHandler Occurs when the remote audio state changes.
OnRemoteVideoStateChangedHandler Occurs when the remote video state changes.
OnFirstRemoteVideoFrameHandler Occurs when the first remote video frame is rendered.
OnFirstRemoteVideoDecodedHandler Occurs when the first remote video frame is received and decoded.
OnAudioSubscribeStateChangedHandler Occurs when the audio subscribing state changes.
OnVideoSubscribeStateChangedHandler Occurs when the video subscribing state changes.

Statistics Events

After joining a channel, SDK triggers this group of callbacks once every two seconds.

Event Description
OnRtcStatsHandler Reports the statistics of the current call session.
OnNetworkQualityHandler Reports the network quality of each user.
OnLocalAudioStatsHandler Reports the statistics of the local audio stream.
OnLocalVideoStatsHandler Reports the statistics of the local video stream.
OnRemoteAudioStatsHandler Reports the statistics of the audio stream from each remote user/host.
OnRemoteVideoStatsHandler Reports the statistics of the video stream from each remote user/host.

Video Pre-process and Post-process

Method Description
SetBeautyEffectOptions Sets the image enhancement options. (This method applies to Android and iOS only.)
EnableVirtualBackground Enables/Disables the virtual background.
EnableRemoteSuperResolution Enables/Disables the super resolution feature for a remote user's video.
SetVideoDenoiserOptions Sets video noise reduction.
SetLowlightEnhanceOptions Sets low-light enhancement.
SetColorEnhanceOptions Sets color enhancement.
Event Description
OnVirtualBackgroundSourceEnabledHandler Reports whether the virtual background is successfully enabled.
OnUserSuperResolutionEnabledHandler Reports whether the super resolution feature is successfully enabled.

Multi-channel management

We provide an advanced guide on the applicable scenarios, implementation and considerations for this group of methods. For details, see Join multiple channels.

Method Description
CreateChannel Creates and gets an AgoraChannel object. To join multiple channels, create multiple AgoraChannel objects.
SetMultiChannelWant Sets whether to enable the multi-channel mode.
SetForMultiChannelUser Sets the local or remote video of users in multiple channels.
AgoraChannel Provides methods that enable real-time communications in a specified channel.

Screen Capture

This group of methods applies to Windows or macOS only.

Method Description
CreateScreenCaptureManager Creates a ScreenCaptureManager class.
CreateScreenCaptureManager Gets the number of the shareable screens or windows.
GetScreenCaptureSourceType Gets the type of the shared target.
GetScreenCaptureSourceName Gets the name of the window or screen.
GetScreenCaptureSourceProcessPath Gets the process to which the window or screen belongs.
GetScreenCaptureSourceTitle Gets the title of the window or screen.
GetScreenCaptureSourceId Gets the source ID of the window or screen.
GetScreenCaptureIsPrimaryMonitor Checks whether the screen is the primary display.
GetScreenCaptureThumbImage Gets the image content of the thumbnail.
GetScreenCaptureIconImage Gets the image content of the icon.
StartScreenCaptureByDisplayId Shares the whole or part of a screen by specifying the display ID.
StartScreenCaptureByScreenRect Shares the whole or part of a screen by specifying the screen rect.
StartScreenCaptureByWindowId Shares the whole or part of a window by specifying the window ID.
SetScreenCaptureContentHint Sets the content hint for screen sharing.
SetScreenCaptureScenario Sets the screen sharing scenario.
UpdateScreenCaptureParameters Updates the screen sharing parameters.
UpdateScreenCaptureRegion Updates the screen sharing region.
StopScreenCapture Stops screen sharing.
Event Description
OnScreenCaptureInfoUpdatedHandler Occurs when the screen sharing information is updated.

Audio File Playback and Mixing

Method Description
StartAudioMixing Starts playing and mixing the music file.
StopAudioMixing Stops playing and mixing the music file.
PauseAudioMixing Pauses playing and mixing the music file.
ResumeAudioMixing Resumes playing and mixing the music file.
AdjustAudioMixingVolume Adjusts the volume during audio mixing.
AdjustAudioMixingPlayoutVolume Adjusts the volume of audio mixing for local playback.
AdjustAudioMixingPublishVolume Adjusts the volume of audio mixing for remote playback.
SetAudioMixingPitch Sets the pitch of the local music file.
GetAudioMixingPlayoutVolume Gets the audio mixing volume for local playback.
GetAudioMixingPublishVolume Gets the audio mixing volume for publishing.
GetAudioMixingCurrentPosition Gets the playback position (ms) of the music file.
SetAudioMixingPosition Sets the playback position of the music file.
GetAudioTrackCount Gets the audio track index of the current music file (for Android, iOS, and Windows only).
SetAudioMixingPlaybackSpeed Sets the playback speed of the current music file.
SetAudioMixingDualMonoMode Sets the channel mode of the current music file.
SelectAudioTrack Specifies the playback track of the current music file (for Android, iOS, and Windows only).
Event Description
OnAudioMixingStateChangedHandler Occurs when the state of the local user's audio mixing file changes.
OnRemoteAudioMixingBeginHandler Occurs when a remote user starts audio mixing.
OnRemoteAudioMixingEndHandler Occurs when a remote user finishes audio mixing.

CDN Publisher

This group of methods apply to interactive live streaming only.

Method Description
StartRtmpStreamWithoutTranscoding Starts pushing media streams to a CDN without transcoding.
StartRtmpStreamWithTranscoding Starts pushing media streams to a CDN and sets the transcoding configuration.
UpdateRtmpTranscoding Updates the transcoding configuration.
StopRtmpStream Stops pushing media streams to a CDN.
Event Description
OnRtmpStreamingStateChangedHandler Occurs when the state of the RTMP or RTMPS streaming changes.
OnRtmpStreamingEventHandler Reports events during the RTMP or RTMPS streaming.
OnTranscodingUpdatedHandler Occurs when the publisher's transcoding settings are updated.

Media Stream Relay Across Channels

This group of methods apply to interactive live streaming only.

Method Description
StartChannelMediaRelay Starts to relay media streams across channels.
UpdateChannelMediaRelay Updates the channels for media stream relay.
StopChannelMediaRelay Stops the media stream relay.
PauseAllChannelMediaRelay Pauses the media stream relay to all destination channels.
ResumeAllChannelMediaRelay Resumes the media stream relay to all destination channels.
Event Description
OnChannelMediaRelayStateChangedHandler Occurs when the state of the media stream relay changes.
OnChannelMediaRelayEventHandler Reports events during the media stream relay.

In-ear Monitoring

This group of methods applies to Android and iOS only.

Method Description
EnableInEarMonitoring Enables in-ear monitoring.
SetInEarMonitoringVolume Sets the volume of the in-ear monitor.

Dual Video Stream Mode

Method Description
EnableDualStreamMode Enables/disables dual video stream mode.
SetRemoteVideoStreamType Sets the remote user’s video stream type received by the local user when the remote user sends dual streams.
SetRemoteDefaultVideoStreamType Sets the default video-stream type for the video received by the local user when the remote user sends dual streams.

Stream Fallback

Method Description
SetLocalPublishFallbackOption Sets the fallback option for the published video stream under unreliable network conditions.
SetRemoteSubscribeFallbackOption Sets the fallback option for the remote stream under unreliable network conditions.
SetRemoteUserPriority Prioritizes a remote user's stream.
Event Description
OnLocalPublishFallbackToAudioOnlyHandler

Occurs:

  • When the published media stream falls back to an audio-only stream due to poor network conditions.
  • When the published media stream switches back to the video after the network conditions improve.

OnRemoteSubscribeFallbackToAudioOnlyHandler

Occurs:

  • When the remote media stream falls back to audio-only due to poor network conditions.
  • When the remote media stream switches back to the video after the network conditions improve.

Pre-call Network Test

Method Description
StartEchoTest Starts an audio call test.
StartEchoTest Starts an audio and video call loop test.
StopEchoTest Stops the audio call test.
EnableLastmileTest Enables the network connection quality test.
DisableLastmileTest Disables the network connection quality test.
StartLastmileProbeTest Starts the last-mile network probe test.
StopLastmileProbeTest Stops the last-mile network probe test.
Event Description
OnLastmileQualityHandler Reports the last mile network quality of the local user before the user joins the channel.
OnLastmileProbeResultHandler Reports the last-mile network probe result.

External Video Data (Push-mode only)

Method Description
SetExternalVideoSource Configures the external video source.
PushVideoFrame Pushes the external video frame.

External Audio Data (Push-mode only)

Method Description
SetExternalAudioSource Configures the external audio source.
PushAudioFrame Pushes the external audio frame.

External Audio Sink (Pull-mode only)

This group of methods applies to Windows only.

Method Description
SetExternalAudioSink Sets the external audio sink.
PullAudioFrame Pulls the external audio frame.

Raw Audio Data

Method Description
RegisterAudioRawDataObserver Registers an audio frame observer object.
UnRegisterAudioRawDataObserver UnRegisters the audio raw data observer.
SetOnRecordAudioFrameCallback Listens for the OnRecordAudioFrameHandler delegate.
SetOnPlaybackAudioFrameCallback Listens for the OnPlaybackAudioFrameHandler delegate.
SetOnPlaybackAudioFrameBeforeMixingCallback Listens for the OnPlaybackAudioFrameBeforeMixingHandler delegate.
SetOnMixedAudioFrameCallback Listens for the OnMixedAudioFrameHandler delegate.
Event Description
OnRecordAudioFrameHandler Retrieves the recorded audio frame.
OnPlaybackAudioFrameHandler Retrieves the audio playback frame.
OnPlaybackAudioFrameBeforeMixingHandler Retrieves the audio frame of a specified user before mixing.
OnMixedAudioFrameHandler Retrieves the mixed recorded and playback audio frame.

<a name="rawvideo"></a >Raw Video Data

Method Description
RegisterVideoRawDataObserver Registers a video frame observer object.
UnRegisterVideoRawDataObserver UnRegisters the video raw data observer.
SetOnCaptureVideoFrameCallback Listens for the OnCaptureVideoFrameHandler delegate.
SetOnRenderVideoFrameCallback Listens for the OnRenderVideoFrameHandler delegate.
Event Description
OnCaptureVideoFrameHandler Occurs when the camera captured image is received.
OnRenderVideoFrameHandler Processes the received image of the specified user (post-processing).

Media Metadata

This group of methods apply to interactive live streaming only.

Method Description
RegisterMediaMetadataObserver Registers a metadata observer.
UnRegisterMediaMetadataObserver Unregisters a metadata observer.
Event Description
OnGetMaxMetadataSizeHandler Occurs when the SDK requests the maximum size of the metadata.
OnReadyToSendMetadataHandler Occurs when the SDK is ready to receive and send metadata.
OnMediaMetaDataReceivedHandler Occurs when the local user receives the metadata.

Watermark

This group of methods apply to interactive live streaming only.

Method Description
AddVideoWatermark Adds a watermark image to the local video stream.
ClearVideoWatermarks Removes the added watermark image from the video stream.

Video snapshot

Method Description
TakeSnapshot Takes a snapshot of a video stream.
Event Description
OnSnapshotTakenHandler Reports the result of taking a video snapshot.

Encryption

Method Description
EnableEncryption Enables/Disables the built-in encryption.
RegisterPacketObserver Registers a packet observer.
UnRegisterPacketObserver UnRegisters the packet observer.

Audio Recorder

Method Description
StartAudioRecording Starts an audio recording on the client.
StopAudioRecording Stops an audio recording on the client.

Media Recorder

Method Description
GetMediaRecorder Gets the MediaRecorder object.
StartRecording Starts recording the local audio and video.
StopRecording Stops recording the local audio and video.
InitMediaRecorderObserver Registers the MediaRecorder observer.
Events Description
OnRecorderStateChangedHandler Occurs when the recording state changes.
OnRecorderInfoUpdatedHandler Occurs when the recording information is updated.

Camera Control

Method Description
SwitchCamera Switches between front and rear cameras (for Android and iOS only).
IsCameraZoomSupported Checks whether the camera zoom function is supported (for Android and iOS only).
IsCameraTorchSupported Checks whether the device supports enabling the flash (for Android and iOS only).
IsCameraFocusSupported Checks whether the camera manual focus function is supported (for Android and iOS only).
IsCameraExposurePositionSupported Checks whether the camera exposure function is supported (for Android and iOS only).
IsCameraAutoFocusFaceModeSupported Checks whether the camera face auto-focus function is supported (for Android and iOS only).
SetCameraZoomFactor Sets the camera zoom ratio (for Android and iOS only).
GetCameraMaxZoomFactor Gets the maximum zoom ratio of the camera (for Android and iOS only).
SetCameraFocusPositionInPreview Sets the camera manual focus position (for Android and iOS only).
SetCameraExposurePosition Sets the camera exposure position (for Android and iOS only).
SetCameraTorchOn Sets whether to enable the flash (for Android and iOS only).
SetCameraAutoFocusFaceModeEnabled Enables the camera auto-face focus function (for Android and iOS only).
Events Description
OnCameraFocusAreaChangedHandler Occurs when the camera focus area changes.
OnCameraExposureAreaChangedHandler Occurs when the camera exposure area changes.

Audio Device Manager

This group of methods applies to Windows and macOS only.

Method Description
CreateAAudioPlaybackDeviceManager Creates an IAudioPlaybackDeviceManager instance.
ReleaseAAudioPlaybackDeviceManager Releases an IAudioPlaybackDeviceManager instance.
CreateAAudioRecordingDeviceManager Creates an IAudioRecordingDeviceManager instance.
ReleaseAAudioRecordingDeviceManager Releases an IAudioRecordingDeviceManager instance.
GetAudioPlaybackDeviceCount Retrieves the total number of the indexed audio playback devices in the system.
GetAudioRecordingDeviceCount Retrieves the total number of the indexed audio capturing devices in the system.
GetAudioPlaybackDevice Retrieves the audio playback device associated with the index.
GetAudioRecordingDevice Retrieves the audio capturing device associated with the index.
SetAudioPlaybackDevice Sets the audio playback device using the device ID.
GetAudioPlaybackDefaultDevice Gets the default audio playback device of the system.
SetAudioRecordingDevice Sets the audio capturing device using the device ID.
GetAudioRecordingDefaultDevice Gets the default audio recording device of the system.
StartAudioPlaybackDeviceTest Starts the test of the current audio playback device.
StopAudioPlaybackDeviceTest Stops the test of the current audio playback device.
StartAudioRecordingDeviceTest Starts the test of the current audio capturing device.
StopAudioRecordingDeviceTest Stops the test of the current audio capturing device.
SetAudioPlaybackDeviceVolume Sets the volume of the current audio playback device.
GetAudioPlaybackDeviceVolume Retrieves the volume of the current audio playback device.
SetAudioRecordingDeviceVolume Sets the volume of the current audio capturing device.
GetAudioRecordingDeviceVolume Retrieves the volume of the current audio capturing device.
SetAudioPlaybackDeviceMute Sets whether to stop audio playback.
IsAudioPlaybackDeviceMute Retrieves the status of the current audio playback device.
SetAudioRecordingDeviceMute Sets whether to stop audio capturing.
IsAudioRecordingDeviceMute Gets the status of the current audio capturing device.
GetCurrentPlaybackDevice Retrieves the device ID of the current audio playback device.
GetCurrentRecordingDevice Retrieves the device ID of the current audio capturing device.
GetCurrentPlaybackDeviceInfo Retrieves the device information of the current audio playback device.
GetCurrentRecordingDeviceInfo Retrieves the device information of the current audio capturing device.
FollowSystemPlaybackDevice Sets the audio playback device used by the SDK to follow the system default audio playback device.
FollowSystemRecordingDevice Sets the audio recording device used by the SDK to follow the system default audio recording device.
StartAudioDeviceLoopbackTest Starts the audio device loopback test (for macOS and Windows only).
StopAudioDeviceLoopbackTest Stops the audio device loopback test (for macOS and Windows only).
Event Description
OnAudioDeviceStateChangedHandler Occurs when the audio device state changes (for macOS and Winddows only).
OnAudioDeviceVolumeChangedHandler Occurs when the volume of the playback, microphone, or application changes.
OnAudioDeviceTestVolumeIndicationHandler Reports the result of an audio device test.

Video Device Manager

This group of methods applies to Windows and macOS only.

Method Description
CreateAVideoDeviceManager Creates an VideoDeviceManager instance.
ReleaseAVideoDeviceManager Releases an VideoDeviceManager instance.
GetVideoDeviceCount Retrieves the total number of the indexed video capturing devices in the system.
GetVideoDevice Retrieves the video capturing device associated with the index.
SetVideoDevice Sets the video capturing device using the device ID.
StartVideoDeviceTest Starts the video capturing device test.
StopVideoDeviceTest Stops the video capturing device test.
GetCurrentVideoDevice Retrieves the device ID of the current video capturing device.
Event Description
OnVideoDeviceStateChangedHandler Occurs when the video device state changes.

Stream Message

Method Description
CreateDataStream Creates a data stream.
SendStreamMessage Sends data stream messages to all users in a channel.
Event Description
OnStreamMessageHandler Occurs when the local user receives the data stream from the remote user within five seconds.
OnStreamMessageErrorHandler Occurs when the local user does not receive the data stream from the remote user within five seconds.

Miscellaneous Audio Control

Method Description
EnableLoopbackRecording Enables loopback capturing (for macOS and Windows only).
AdjustLoopbackRecordingSignalVolume Enables loopback capturing (for macOS and Windows only).
SetAudioSessionOperationRestriction Sets the audio session’s operational restriction (for iOS only).

Miscellaneous Video Control

Method Description
SetCameraCapturerConfiguration Sets the camera capturer configuration.

Miscellaneous Methods

Method Description
SetGameFps Sets the video rendering frame rate.
EnableFilpTextureApply Enables/Disables the mirror mode when renders the Texture.
SetVideoSurfaceType Set the video renderer type.
SetEnable Starts/Stops the video rendering.
SetCloudProxy Sets the Agora cloud proxy service.
EnableDeepLearningDenoise Enables/Disables deep-learning noise reduction.
SendCustomReportMessage Reports customized messages.
GetCallId Retrieves the current call ID.
Rate Allows the user to rate the call and is called after the call ends.
Complain Allows a user to complain about the call quality after a call ends.
GetSdkVersion Gets the SDK version number.
GetErrorDescription Retrieves the description of a warning or error code.

Miscellaneous Events

Event Description
OnSDKWarningHandler Reports a warning during SDK runtime.
OnSDKErrorHandler Reports an error during SDK runtime.
OnApiExecutedHandler Occurs when a method is executed by the SDK.
OnProxyConnectedHandler Reports the proxy connection state.