Voice SDK v3.7.1 API Reference for Unity
Classes | Enumerations | Functions
agora_gaming_rtc Namespace Reference

Classes

struct   LogConfig
 
struct   RtcEngineConfig
 
struct   RtcStats
 
struct   AudioVolumeInfo
 
class   ChannelMediaOptions
 
struct   LocalVideoStats
 
struct   RemoteVideoStats
 
struct   UserInfo
 
struct   RemoteAudioStats
 
struct   WatermarkOptions
 
struct   LocalAudioStats
 
struct   VideoEncoderConfiguration
 
struct   VideoDimensions
 
struct   TranscodingUser
 
struct   RtcImage
 
struct   LiveTranscoding
 
struct   ExternalVideoFrame
 
struct   VideoFrame
 
struct   AudioFrame
 
struct   LastmileProbeOneWayResult
 
struct   LastmileProbeResult
 
struct   CameraCapturerConfiguration
 
struct   LastmileProbeConfig
 
struct   Packet
 
struct   BeautyOptions
 
struct   Rectangle
 
struct   ScreenCaptureParameters
 
struct   InjectStreamConfig
 
struct   ChannelMediaRelayConfiguration
 
struct   ChannelMediaInfo
 
struct   Metadata
 
struct   VideoCanvas
 
class   EncryptionConfig
 
struct   ClientRoleOptions
 
struct   DataStreamConfig
 
struct   AudioRecordingConfiguration
 
struct   VirtualBackgroundSource
 
struct   AudioFileInfo
 
struct   EchoTestConfiguration
 
struct   MediaRecorderConfiguration
 
struct   RecorderInfo
 
struct   LowLightEnhanceOptions
 
struct   VideoDenoiserOptions
 
struct   ColorEnhanceOptions
 
struct   WlAccStats
 
struct   ThumbImageBuffer
 
struct   ScreenCaptureInfo
 
class   AgoraChannel
 
class   IRtcEngine
 
class   AudioEffectManagerImpl
 
class   IAudioPlaybackDeviceManager
 
class   AudioPlaybackDeviceManager
 
class   IAudioRecordingDeviceManager
 
class   AudioRecordingDeviceManager
 
class   MediaRecorder
 
class   IScreenCaptureManager
 
class   ScreenCaptureManager
 
class   VideoDeviceManager
 
class   MetadataObserver
 
class   PacketObserver
 
class   AudioRawDataManager
 
class   VideoRawDataManager
 
class   VideoSurface
 

Enumerations

enum class   VIDEO_RENDER_MODE { RENDER_RAWDATA = 100 , REDNER_OPENGL_ES2 = 101 , RENDER_UNITY_LOW_LEVEL_INTERFACE = 102 }
 
enum class   ERROR_CODE { ERROR_NOT_INIT_ENGINE = -7 , ERROR_OK = 0 , ERROR_INVALID_ARGUMENT = -2 , ERROR_NO_DEVICE_PLUGIN = -100 }
 
enum class   REMOTE_VIDEO_STREAM_TYPE { REMOTE_VIDEO_STREAM_HIGH = 0 , REMOTE_VIDEO_STREAM_LOW = 1 }
 
enum class   REMOTE_VIDEO_STATE {
  REMOTE_VIDEO_STATE_STOPPED = 0 , REMOTE_VIDEO_STATE_STARTING = 1 , REMOTE_VIDEO_STATE_DECODING = 2 , REMOTE_VIDEO_STATE_FROZEN = 3 ,
  REMOTE_VIDEO_STATE_FAILED = 4
}
 
enum class   AUDIO_MIXING_REASON_TYPE {
  AUDIO_MIXING_REASON_CAN_NOT_OPEN = 701 , AUDIO_MIXING_REASON_TOO_FREQUENT_CALL = 702 , AUDIO_MIXING_REASON_INTERRUPTED_EOF = 703 , AUDIO_MIXING_REASON_STARTED_BY_USER = 720 ,
  AUDIO_MIXING_REASON_ONE_LOOP_COMPLETED = 721 , AUDIO_MIXING_REASON_START_NEW_LOOP = 722 , AUDIO_MIXING_REASON_ALL_LOOPS_COMPLETED = 723 , AUDIO_MIXING_REASON_STOPPED_BY_USER = 724 ,
  AUDIO_MIXING_REASON_PAUSED_BY_USER = 725 , AUDIO_MIXING_REASON_RESUMED_BY_USER = 726
}
 
enum class   USER_OFFLINE_REASON { QUIT = 0 , DROPPED = 1 , BECOME_AUDIENCE = 2 }
 
enum class   LOG_FILTER {
  OFF = 0 , DEBUG = 0x80f , INFO = 0x0f , WARNING = 0x0e ,
  ERROR = 0x0c , CRITICAL = 0x08
}
 
enum class   CHANNEL_PROFILE { CHANNEL_PROFILE_COMMUNICATION = 0 , CHANNEL_PROFILE_LIVE_BROADCASTING = 1 , CHANNEL_PROFILE_GAME = 2 }
 
enum class   CLIENT_ROLE_TYPE { CLIENT_ROLE_BROADCASTER = 1 , CLIENT_ROLE_AUDIENCE = 2 }
 
enum class   AUDIO_RECORDING_QUALITY_TYPE { AUDIO_RECORDING_QUALITY_LOW = 0 , AUDIO_RECORDING_QUALITY_MEDIUM = 1 , AUDIO_RECORDING_QUALITY_HIGH = 2 , AUDIO_RECORDING_QUALITY_ULTRA_HIGH = 3 }
 
enum class   AUDIO_ROUTE {
  AUDIO_ROUTE_DEFAULT = -1 , AUDIO_ROUTE_HEADSET = 0 , AUDIO_ROUTE_EARPIECE = 1 , AUDIO_ROUTE_HEADSET_NO_MIC = 2 ,
  AUDIO_ROUTE_SPEAKERPHONE = 3 , AUDIO_ROUTE_LOUDSPEAKER = 4 , AUDIO_ROUTE_BLUETOOTH = 5 , AUDIO_ROUTE_USB = 6 ,
  AUDIO_ROUTE_HDMI = 7 , AUDIO_ROUTE_DISPLAYPORT = 8 , AUDIO_ROUTE_AIRPLAY = 9
}
 
enum class   CONNECTION_STATE_TYPE {
  CONNECTION_STATE_DISCONNECTED = 1 , CONNECTION_STATE_CONNECTING = 2 , CONNECTION_STATE_CONNECTED = 3 , CONNECTION_STATE_RECONNECTING = 4 ,
  CONNECTION_STATE_FAILED = 5
}
 
enum class   CONNECTION_CHANGED_REASON_TYPE {
  CONNECTION_CHANGED_CONNECTING = 0 , CONNECTION_CHANGED_JOIN_SUCCESS = 1 , CONNECTION_CHANGED_INTERRUPTED = 2 , CONNECTION_CHANGED_BANNED_BY_SERVER = 3 ,
  CONNECTION_CHANGED_JOIN_FAILED = 4 , CONNECTION_CHANGED_LEAVE_CHANNEL = 5 , CONNECTION_CHANGED_INVALID_APP_ID = 6 , CONNECTION_CHANGED_INVALID_CHANNEL_NAME = 7 ,
  CONNECTION_CHANGED_INVALID_TOKEN = 8 , CONNECTION_CHANGED_TOKEN_EXPIRED = 9 , CONNECTION_CHANGED_REJECTED_BY_SERVER = 10 , CONNECTION_CHANGED_SETTING_PROXY_SERVER = 11 ,
  CONNECTION_CHANGED_RENEW_TOKEN = 12 , CONNECTION_CHANGED_CLIENT_IP_ADDRESS_CHANGED = 13 , CONNECTION_CHANGED_KEEP_ALIVE_TIMEOUT = 14 , CONNECTION_CHANGED_SAME_UID_LOGIN = 19 ,
  CONNECTION_CHANGED_TOO_MANY_BROADCASTERS = 20
}
 
enum class   STREAM_FALLBACK_OPTIONS { STREAM_FALLBACK_OPTION_DISABLED = 0 , STREAM_FALLBACK_OPTION_VIDEO_STREAM_LOW = 1 , STREAM_FALLBACK_OPTION_AUDIO_ONLY = 2 }
 
enum class   VideoContentHint { CONTENT_HINT_NONE = 0 , CONTENT_HINT_MOTION = 1 , CONTENT_HINT_DETAILS = 2 }
 
enum class   REMOTE_VIDEO_STATE_REASON {
  REMOTE_VIDEO_STATE_REASON_INTERNAL = 0 , REMOTE_VIDEO_STATE_REASON_NETWORK_CONGESTION = 1 , REMOTE_VIDEO_STATE_REASON_NETWORK_RECOVERY = 2 , REMOTE_VIDEO_STATE_REASON_LOCAL_MUTED = 3 ,
  REMOTE_VIDEO_STATE_REASON_LOCAL_UNMUTED = 4 , REMOTE_VIDEO_STATE_REASON_REMOTE_MUTED = 5 , REMOTE_VIDEO_STATE_REASON_REMOTE_UNMUTED = 6 , REMOTE_VIDEO_STATE_REASON_REMOTE_OFFLINE = 7 ,
  REMOTE_VIDEO_STATE_REASON_AUDIO_FALLBACK = 8 , REMOTE_VIDEO_STATE_REASON_AUDIO_FALLBACK_RECOVERY = 9 , REMOTE_VIDEO_STATE_REASON_SDK_IN_BACKGROUND = 10
}
 
enum class   LOCAL_VIDEO_STREAM_STATE { LOCAL_VIDEO_STREAM_STATE_STOPPED = 0 , LOCAL_VIDEO_STREAM_STATE_CAPTURING = 1 , LOCAL_VIDEO_STREAM_STATE_ENCODING = 2 , LOCAL_VIDEO_STREAM_STATE_FAILED = 3 }
 
enum class   LOCAL_VIDEO_STREAM_ERROR {
  LOCAL_VIDEO_STREAM_ERROR_OK = 0 , LOCAL_VIDEO_STREAM_ERROR_FAILURE = 1 , LOCAL_VIDEO_STREAM_ERROR_DEVICE_NO_PERMISSION = 2 , LOCAL_VIDEO_STREAM_ERROR_DEVICE_BUSY = 3 ,
  LOCAL_VIDEO_STREAM_ERROR_CAPTURE_FAILURE = 4 , LOCAL_VIDEO_STREAM_ERROR_ENCODE_FAILURE = 5 , LOCAL_VIDEO_STREAM_ERROR_CAPTURE_INBACKGROUND = 6 , LOCAL_VIDEO_STREAM_ERROR_CAPTURE_MULTIPLE_FOREGROUND_APPS = 7 ,
  LOCAL_VIDEO_STREAM_ERROR_DEVICE_NOT_FOUND = 8 , LOCAL_VIDEO_STREAM_ERROR_DEVICE_DISCONNECTED = 9 , LOCAL_VIDEO_STREAM_ERROR_DEVICE_INVALID_ID = 10 , LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_MINIMIZED = 11 ,
  LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_CLOSED = 12 , LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_OCCLUDED = 13 , LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_NOT_SUPPORTED = 20
}
 
enum class   AUDIO_RECORDING_POSITION { AUDIO_RECORDING_POSITION_MIXED_RECORDING_AND_PLAYBACK = 0 , AUDIO_RECORDING_POSITION_RECORDING = 1 , AUDIO_RECORDING_POSITION_MIXED_PLAYBACK = 2 }
 
enum class   MEDIA_DEVICE_TYPE {
  UNKNOWN_AUDIO_DEVICE = -1 , AUDIO_PLAYOUT_DEVICE = 0 , AUDIO_RECORDING_DEVICE = 1 , VIDEO_RENDER_DEVICE = 2 ,
  VIDEO_CAPTURE_DEVICE = 3 , AUDIO_APPLICATION_PLAYOUT_DEVICE = 4
}
 
enum class   RAW_AUDIO_FRAME_OP_MODE_TYPE { RAW_AUDIO_FRAME_OP_MODE_READ_ONLY = 0 , RAW_AUDIO_FRAME_OP_MODE_WRITE_ONLY = 1 , RAW_AUDIO_FRAME_OP_MODE_READ_WRITE = 2 }
 
enum class   AUDIO_PROFILE_TYPE {
  AUDIO_PROFILE_DEFAULT = 0 , AUDIO_PROFILE_SPEECH_STANDARD = 1 , AUDIO_PROFILE_MUSIC_STANDARD = 2 , AUDIO_PROFILE_MUSIC_STANDARD_STEREO = 3 ,
  AUDIO_PROFILE_MUSIC_HIGH_QUALITY = 4 , AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO = 5 , AUDIO_PROFILE_IOT = 6 , AUDIO_PROFILE_NUM = 7
}
 
enum class   AUDIO_SCENARIO_TYPE {
  AUDIO_SCENARIO_DEFAULT = 0 , AUDIO_SCENARIO_CHATROOM_ENTERTAINMENT = 1 , AUDIO_SCENARIO_EDUCATION = 2 , AUDIO_SCENARIO_GAME_STREAMING = 3 ,
  AUDIO_SCENARIO_SHOWROOM = 4 , AUDIO_SCENARIO_CHATROOM_GAMING = 5 , AUDIO_SCENARIO_IOT = 6 , AUDIO_SCENARIO_MEETING = 8 ,
  AUDIO_SCENARIO_NUM = 10
}
 
enum class   VIDEO_CODEC_PROFILE_TYPE { VIDEO_CODEC_PROFILE_BASELINE = 66 , VIDEO_CODEC_PROFILE_MAIN = 77 , VIDEO_CODEC_PROFILE_HIGH = 100 }
 
enum class   AUDIO_SAMPLE_RATE_TYPE { AUDIO_SAMPLE_RATE_32000 = 32000 , AUDIO_SAMPLE_RATE_44100 = 44100 , AUDIO_SAMPLE_RATE_48000 = 48000 }
 
enum class   AUDIO_MIXING_STATE_TYPE { AUDIO_MIXING_STATE_PLAYING = 710 , AUDIO_MIXING_STATE_PAUSED = 711 , AUDIO_MIXING_STATE_STOPPED = 713 , AUDIO_MIXING_STATE_FAILED = 714 }
 
enum class   AUDIO_MIXING_ERROR_TYPE { AUDIO_MIXING_ERROR_CAN_NOT_OPEN = 701 , AUDIO_MIXING_ERROR_TOO_FREQUENT_CALL = 702 , AUDIO_MIXING_ERROR_INTERRUPTED_EOF = 703 , AUDIO_MIXING_ERROR_OK = 0 }
 
enum class   RTMP_STREAM_PUBLISH_STATE {
  RTMP_STREAM_PUBLISH_STATE_IDLE = 0 , RTMP_STREAM_PUBLISH_STATE_CONNECTING = 1 , RTMP_STREAM_PUBLISH_STATE_RUNNING = 2 , RTMP_STREAM_PUBLISH_STATE_RECOVERING = 3 ,
  RTMP_STREAM_PUBLISH_STATE_FAILURE = 4 , RTMP_STREAM_PUBLISH_STATE_DISCONNECTING = 5
}
 
enum class   RTMP_STREAM_PUBLISH_ERROR_TYPE {
  RTMP_STREAM_PUBLISH_ERROR_OK = 0 , RTMP_STREAM_PUBLISH_ERROR_INVALID_ARGUMENT = 1 , RTMP_STREAM_PUBLISH_ERROR_ENCRYPTED_STREAM_NOT_ALLOWED = 2 , RTMP_STREAM_PUBLISH_ERROR_CONNECTION_TIMEOUT = 3 ,
  RTMP_STREAM_PUBLISH_ERROR_INTERNAL_SERVER_ERROR = 4 , RTMP_STREAM_PUBLISH_ERROR_RTMP_SERVER_ERROR = 5 , RTMP_STREAM_PUBLISH_ERROR_TOO_OFTEN = 6 , RTMP_STREAM_PUBLISH_ERROR_REACH_LIMIT = 7 ,
  RTMP_STREAM_PUBLISH_ERROR_NOT_AUTHORIZED = 8 , RTMP_STREAM_PUBLISH_ERROR_STREAM_NOT_FOUND = 9 , RTMP_STREAM_PUBLISH_ERROR_FORMAT_NOT_SUPPORTED = 10 , RTMP_STREAM_PUBLISH_ERROR_NOT_BROADCASTER = 11 ,
  RTMP_STREAM_PUBLISH_ERROR_TRANSCODING_NO_MIX_STREAM = 13 , RTMP_STREAM_PUBLISH_ERROR_NET_DOWN = 14 , RTMP_STREAM_PUBLISH_ERROR_INVALID_APPID = 15 , RTMP_STREAM_UNPUBLISH_ERROR_OK = 100
}
 
enum class   NETWORK_TYPE {
  NETWORK_TYPE_UNKNOWN = -1 , NETWORK_TYPE_DISCONNECTED = 0 , NETWORK_TYPE_LAN = 1 , NETWORK_TYPE_WIFI = 2 ,
  NETWORK_TYPE_MOBILE_2G = 3 , NETWORK_TYPE_MOBILE_3G = 4 , NETWORK_TYPE_MOBILE_4G = 5 , NETWORK_TYPE_MOBILE_5G = 6
}
 
enum class   VOICE_CHANGER_PRESET {
  VOICE_CHANGER_OFF = 0x00000000 , VOICE_CHANGER_OLDMAN = 0x00000001 , VOICE_CHANGER_BABYBOY = 0x00000002 , VOICE_CHANGER_BABYGIRL = 0x00000003 ,
  VOICE_CHANGER_ZHUBAJIE = 0x00000004 , VOICE_CHANGER_ETHEREAL = 0x00000005 , VOICE_CHANGER_HULK = 0x00000006 , VOICE_BEAUTY_VIGOROUS = 0x00100001 ,
  VOICE_BEAUTY_DEEP = 0x00100002 , VOICE_BEAUTY_MELLOW = 0x00100003 , VOICE_BEAUTY_FALSETTO = 0x00100004 , VOICE_BEAUTY_FULL = 0x00100005 ,
  VOICE_BEAUTY_CLEAR = 0x00100006 , VOICE_BEAUTY_RESOUNDING = 0x00100007 , VOICE_BEAUTY_RINGING = 0x00100008 , VOICE_BEAUTY_SPACIAL = 0x00100009 ,
  GENERAL_BEAUTY_VOICE_MALE_MAGNETIC = 0x00200001 , GENERAL_BEAUTY_VOICE_FEMALE_FRESH = 0x00200002 , GENERAL_BEAUTY_VOICE_FEMALE_VITALITY = 0x00200003
}
 
enum class   AUDIO_REVERB_PRESET {
  AUDIO_REVERB_OFF = 0x00000000 , AUDIO_REVERB_FX_KTV = 0x00100001 , AUDIO_REVERB_FX_VOCAL_CONCERT = 0x00100002 , AUDIO_REVERB_FX_UNCLE = 0x00100003 ,
  AUDIO_REVERB_FX_SISTER = 0x00100004 , AUDIO_REVERB_FX_STUDIO = 0x00100005 , AUDIO_REVERB_FX_POPULAR = 0x00100006 , AUDIO_REVERB_FX_RNB = 0x00100007 ,
  AUDIO_REVERB_FX_PHONOGRAPH = 0x00100008 , AUDIO_REVERB_POPULAR = 0x00000001 , AUDIO_REVERB_RNB = 0x00000002 , AUDIO_REVERB_ROCK = 0x00000003 ,
  AUDIO_REVERB_HIPHOP = 0x00000004 , AUDIO_REVERB_VOCAL_CONCERT = 0x00000005 , AUDIO_REVERB_KTV = 0x00000006 , AUDIO_REVERB_STUDIO = 0x00000007 ,
  AUDIO_VIRTUAL_STEREO = 0x00200001
}
 
enum class   AUDIO_EQUALIZATION_BAND_FREQUENCY {
  AUDIO_EQUALIZATION_BAND_31 = 0 , AUDIO_EQUALIZATION_BAND_62 = 1 , AUDIO_EQUALIZATION_BAND_125 = 2 , AUDIO_EQUALIZATION_BAND_250 = 3 ,
  AUDIO_EQUALIZATION_BAND_500 = 4 , AUDIO_EQUALIZATION_BAND_1K = 5 , AUDIO_EQUALIZATION_BAND_2K = 6 , AUDIO_EQUALIZATION_BAND_4K = 7 ,
  AUDIO_EQUALIZATION_BAND_8K = 8 , AUDIO_EQUALIZATION_BAND_16K = 9
}
 
enum class   QUALITY_ADAPT_INDICATION { ADAPT_NONE = 0 , ADAPT_UP_BANDWIDTH = 1 , ADAPT_DOWN_BANDWIDTH = 2 }
 
enum class   AUDIO_REVERB_TYPE {
  AUDIO_REVERB_DRY_LEVEL = 0 , AUDIO_REVERB_WET_LEVEL = 1 , AUDIO_REVERB_ROOM_SIZE = 2 , AUDIO_REVERB_WET_DELAY = 3 ,
  AUDIO_REVERB_STRENGTH = 4
}
 
enum class   AUDIO_CODEC_PROFILE_TYPE { AUDIO_CODEC_PROFILE_LC_AAC = 0 , AUDIO_CODEC_PROFILE_HE_AAC = 1 , AUDIO_CODEC_PROFILE_HE_AAC_V2 = 2 }
 
enum class   VIDEO_CODEC_TYPE { VIDEO_CODEC_VP8 = 1 , VIDEO_CODEC_H264 = 2 , VIDEO_CODEC_EVP = 3 , VIDEO_CODEC_E264 = 4 }
 
enum class   AREA_CODE : uint {
  AREA_CODE_CN = 0x00000001 , AREA_CODE_NA = 0x00000002 , AREA_CODE_EU = 0x00000004 , AREA_CODE_AS = 0x00000008 ,
  AREA_CODE_JP = 0x00000010 , AREA_CODE_IN = 0x00000020 , AREA_CODE_GLOB = 0xFFFFFFFF
}
 
enum class   LOG_LEVEL {
  LOG_LEVEL_NONE = 0x0000 , LOG_LEVEL_INFO = 0x0001 , LOG_LEVEL_WARN = 0x0002 , LOG_LEVEL_ERROR = 0x0004 ,
  LOG_LEVEL_FATAL = 0x0008
}
 
enum class   FRAME_RATE {
  FRAME_RATE_FPS_1 = 1 , FRAME_RATE_FPS_7 = 7 , FRAME_RATE_FPS_10 = 10 , FRAME_RATE_FPS_15 = 15 ,
  FRAME_RATE_FPS_24 = 24 , FRAME_RATE_FPS_30 = 30 , FRAME_RATE_FPS_60 = 60
}
 
enum class   ORIENTATION_MODE { ORIENTATION_MODE_ADAPTIVE = 0 , ORIENTATION_MODE_FIXED_LANDSCAPE = 1 , ORIENTATION_MODE_FIXED_PORTRAIT = 2 }
 
enum class   DEGRADATION_PREFERENCE { MAINTAIN_QUALITY = 0 , MAINTAIN_FRAMERATE = 1 , MAINTAIN_BALANCED = 2 }
 
enum class   VIDEO_FRAME_TYPE { FRAME_TYPE_YUV420 = 0 , FRAME_TYPE_RGBA = 1 }
 
enum class   VIDEO_MIRROR_MODE_TYPE { VIDEO_MIRROR_MODE_AUTO = 0 , VIDEO_MIRROR_MODE_ENABLED = 1 , VIDEO_MIRROR_MODE_DISABLED = 2 }
 
enum class   AUDIO_FRAME_TYPE { FRAME_TYPE_PCM16 = 0 }
 
enum class   MEDIA_SOURCE_TYPE { AUDIO_PLAYOUT_SOURCE = 0 , AUDIO_RECORDING_SOURCE = 1 }
 
enum class   LASTMILE_PROBE_RESULT_STATE { LASTMILE_PROBE_RESULT_COMPLETE = 1 , LASTMILE_PROBE_RESULT_INCOMPLETE_NO_BWE = 2 , LASTMILE_PROBE_RESULT_UNAVAILABLE = 3 }
 
enum class   CAMERA_DIRECTION { CAMERA_REAR = 0 , CAMERA_FRONT = 1 }
 
enum class   CAPTURER_OUTPUT_PREFERENCE { CAPTURER_OUTPUT_PREFERENCE_AUTO = 0 , CAPTURER_OUTPUT_PREFERENCE_PERFORMANCE = 1 , CAPTURER_OUTPUT_PREFERENCE_PREVIEW = 2 , CAPTURER_OUTPUT_PREFERENCE_MANUAL = 3 }
 
enum class   QUALITY_TYPE {
  QUALITY_UNKNOWN = 0 , QUALITY_EXCELLENT = 1 , QUALITY_GOOD = 2 , QUALITY_POOR = 3 ,
  QUALITY_BAD = 4 , QUALITY_VBAD = 5 , QUALITY_DOWN = 6 , QUALITY_UNSUPPORTED = 7 ,
  QUALITY_DETECTING = 8
}
 
enum class   MEDIA_DEVICE_STATE_TYPE {
  MEDIA_DEVICE_STATE_IDLE = 0 , MEDIA_DEVICE_STATE_ACTIVE = 1 , MEDIA_DEVICE_STATE_DISABLED = 2 , MEDIA_DEVICE_STATE_NOT_PRESENT = 4 ,
  MEDIA_DEVICE_STATE_UNPLUGGED = 8 , MEDIA_DEVICE_STATE_UNRECOMMENDED = 16
}
 
enum class   PRIORITY_TYPE { PRIORITY_HIGH = 50 , PRIORITY_NORMAL = 100 }
 
enum class   LOCAL_AUDIO_STREAM_STATE { LOCAL_AUDIO_STREAM_STATE_STOPPED = 0 , LOCAL_AUDIO_STREAM_STATE_RECORDING = 1 , LOCAL_AUDIO_STREAM_STATE_ENCODING = 2 , LOCAL_AUDIO_STREAM_STATE_FAILED = 3 }
 
enum class   LOCAL_AUDIO_STREAM_ERROR {
  LOCAL_AUDIO_STREAM_ERROR_OK = 0 , LOCAL_AUDIO_STREAM_ERROR_FAILURE = 1 , LOCAL_AUDIO_STREAM_ERROR_DEVICE_NO_PERMISSION = 2 , LOCAL_AUDIO_STREAM_ERROR_DEVICE_BUSY = 3 ,
  LOCAL_AUDIO_STREAM_ERROR_RECORD_FAILURE = 4 , LOCAL_AUDIO_STREAM_ERROR_ENCODE_FAILURE = 5 , LOCAL_AUDIO_STREAM_ERROR_NO_RECORDING_DEVICE = 6 , LOCAL_AUDIO_STREAM_ERROR_NO_PLAYOUT_DEVICE = 7 ,
  LOCAL_AUDIO_STREAM_ERROR_INTERRUPTED = 8 , LOCAL_AUDIO_STREAM_ERROR_RECORD_INVALID_ID = 9 , LOCAL_AUDIO_STREAM_ERROR_PLAYOUT_INVALID_ID = 10
}
 
enum class   REMOTE_AUDIO_STATE {
  REMOTE_AUDIO_STATE_STOPPED = 0 , REMOTE_AUDIO_STATE_STARTING = 1 , REMOTE_AUDIO_STATE_DECODING = 2 , REMOTE_AUDIO_STATE_FROZEN = 3 ,
  REMOTE_AUDIO_STATE_FAILED = 4
}
 
enum class   REMOTE_AUDIO_STATE_REASON {
  REMOTE_AUDIO_REASON_INTERNAL = 0 , REMOTE_AUDIO_REASON_NETWORK_CONGESTION = 1 , REMOTE_AUDIO_REASON_NETWORK_RECOVERY = 2 , REMOTE_AUDIO_REASON_LOCAL_MUTED = 3 ,
  REMOTE_AUDIO_REASON_LOCAL_UNMUTED = 4 , REMOTE_AUDIO_REASON_REMOTE_MUTED = 5 , REMOTE_AUDIO_REASON_REMOTE_UNMUTED = 6 , REMOTE_AUDIO_REASON_REMOTE_OFFLINE = 7
}
 
enum class   AUDIO_SESSION_OPERATION_RESTRICTION {
  AUDIO_SESSION_OPERATION_RESTRICTION_NONE = 0 , AUDIO_SESSION_OPERATION_RESTRICTION_SET_CATEGORY = 1 , AUDIO_SESSION_OPERATION_RESTRICTION_CONFIGURE_SESSION = 1 << 1 , AUDIO_SESSION_OPERATION_RESTRICTION_DEACTIVATE_SESSION = 1 << 2 ,
  AUDIO_SESSION_OPERATION_RESTRICTION_ALL = 1 << 7
}
 
enum class   CHANNEL_MEDIA_RELAY_EVENT {
  RELAY_EVENT_NETWORK_DISCONNECTED = 0 , RELAY_EVENT_NETWORK_CONNECTED = 1 , RELAY_EVENT_PACKET_JOINED_SRC_CHANNEL = 2 , RELAY_EVENT_PACKET_JOINED_DEST_CHANNEL = 3 ,
  RELAY_EVENT_PACKET_SENT_TO_DEST_CHANNEL = 4 , RELAY_EVENT_PACKET_RECEIVED_VIDEO_FROM_SRC = 5 , RELAY_EVENT_PACKET_RECEIVED_AUDIO_FROM_SRC = 6 , RELAY_EVENT_PACKET_UPDATE_DEST_CHANNEL = 7 ,
  RELAY_EVENT_PACKET_UPDATE_DEST_CHANNEL_REFUSED = 8 , RELAY_EVENT_PACKET_UPDATE_DEST_CHANNEL_NOT_CHANGE = 9 , RELAY_EVENT_PACKET_UPDATE_DEST_CHANNEL_IS_NULL = 10 , RELAY_EVENT_VIDEO_PROFILE_UPDATE = 11 ,
  RELAY_EVENT_PAUSE_SEND_PACKET_TO_DEST_CHANNEL_SUCCESS = 12 , RELAY_EVENT_PAUSE_SEND_PACKET_TO_DEST_CHANNEL_FAILED = 13 , RELAY_EVENT_RESUME_SEND_PACKET_TO_DEST_CHANNEL_SUCCESS = 14 , RELAY_EVENT_RESUME_SEND_PACKET_TO_DEST_CHANNEL_FAILED = 15
}
 
enum class   CHANNEL_MEDIA_RELAY_STATE { RELAY_STATE_IDLE = 0 , RELAY_STATE_CONNECTING = 1 , RELAY_STATE_RUNNING = 2 , RELAY_STATE_FAILURE = 3 }
 
enum class   VIDEO_PROFILE_TYPE {
  VIDEO_PROFILE_LANDSCAPE_120P = 0 , VIDEO_PROFILE_LANDSCAPE_120P_3 = 2 , VIDEO_PROFILE_LANDSCAPE_180P = 10 , VIDEO_PROFILE_LANDSCAPE_180P_3 = 12 ,
  VIDEO_PROFILE_LANDSCAPE_180P_4 = 13 , VIDEO_PROFILE_LANDSCAPE_240P = 20 , VIDEO_PROFILE_LANDSCAPE_240P_3 = 22 , VIDEO_PROFILE_LANDSCAPE_240P_4 = 23 ,
  VIDEO_PROFILE_LANDSCAPE_360P = 30 , VIDEO_PROFILE_LANDSCAPE_360P_3 = 32 , VIDEO_PROFILE_LANDSCAPE_360P_4 = 33 , VIDEO_PROFILE_LANDSCAPE_360P_6 = 35 ,
  VIDEO_PROFILE_LANDSCAPE_360P_7 = 36 , VIDEO_PROFILE_LANDSCAPE_360P_8 = 37 , VIDEO_PROFILE_LANDSCAPE_360P_9 = 38 , VIDEO_PROFILE_LANDSCAPE_360P_10 = 39 ,
  VIDEO_PROFILE_LANDSCAPE_360P_11 = 100 , VIDEO_PROFILE_LANDSCAPE_480P = 40 , VIDEO_PROFILE_LANDSCAPE_480P_3 = 42 , VIDEO_PROFILE_LANDSCAPE_480P_4 = 43 ,
  VIDEO_PROFILE_LANDSCAPE_480P_6 = 45 , VIDEO_PROFILE_LANDSCAPE_480P_8 = 47 , VIDEO_PROFILE_LANDSCAPE_480P_9 = 48 , VIDEO_PROFILE_LANDSCAPE_480P_10 = 49 ,
  VIDEO_PROFILE_LANDSCAPE_720P = 50 , VIDEO_PROFILE_LANDSCAPE_720P_3 = 52 , VIDEO_PROFILE_LANDSCAPE_720P_5 = 54 , VIDEO_PROFILE_LANDSCAPE_720P_6 = 55 ,
  VIDEO_PROFILE_LANDSCAPE_1080P = 60 , VIDEO_PROFILE_LANDSCAPE_1080P_3 = 62 , VIDEO_PROFILE_LANDSCAPE_1080P_5 = 64 , VIDEO_PROFILE_LANDSCAPE_1440P = 66 ,
  VIDEO_PROFILE_LANDSCAPE_1440P_2 = 67 , VIDEO_PROFILE_LANDSCAPE_4K = 70 , VIDEO_PROFILE_LANDSCAPE_4K_3 = 72 , VIDEO_PROFILE_PORTRAIT_120P = 1000 ,
  VIDEO_PROFILE_PORTRAIT_120P_3 = 1002 , VIDEO_PROFILE_PORTRAIT_180P = 1010 , VIDEO_PROFILE_PORTRAIT_180P_3 = 1012 , VIDEO_PROFILE_PORTRAIT_180P_4 = 1013 ,
  VIDEO_PROFILE_PORTRAIT_240P = 1020 , VIDEO_PROFILE_PORTRAIT_240P_3 = 1022 , VIDEO_PROFILE_PORTRAIT_240P_4 = 1023 , VIDEO_PROFILE_PORTRAIT_360P = 1030 ,
  VIDEO_PROFILE_PORTRAIT_360P_3 = 1032 , VIDEO_PROFILE_PORTRAIT_360P_4 = 1033 , VIDEO_PROFILE_PORTRAIT_360P_6 = 1035 , VIDEO_PROFILE_PORTRAIT_360P_7 = 1036 ,
  VIDEO_PROFILE_PORTRAIT_360P_8 = 1037 , VIDEO_PROFILE_PORTRAIT_360P_9 = 1038 , VIDEO_PROFILE_PORTRAIT_360P_10 = 1039 , VIDEO_PROFILE_PORTRAIT_360P_11 = 1100 ,
  VIDEO_PROFILE_PORTRAIT_480P = 1040 , VIDEO_PROFILE_PORTRAIT_480P_3 = 1042 , VIDEO_PROFILE_PORTRAIT_480P_4 = 1043 , VIDEO_PROFILE_PORTRAIT_480P_6 = 1045 ,
  VIDEO_PROFILE_PORTRAIT_480P_8 = 1047 , VIDEO_PROFILE_PORTRAIT_480P_9 = 1048 , VIDEO_PROFILE_PORTRAIT_480P_10 = 1049 , VIDEO_PROFILE_PORTRAIT_720P = 1050 ,
  VIDEO_PROFILE_PORTRAIT_720P_3 = 1052 , VIDEO_PROFILE_PORTRAIT_720P_5 = 1054 , VIDEO_PROFILE_PORTRAIT_720P_6 = 1055 , VIDEO_PROFILE_PORTRAIT_1080P = 1060 ,
  VIDEO_PROFILE_PORTRAIT_1080P_3 = 1062 , VIDEO_PROFILE_PORTRAIT_1080P_5 = 1064 , VIDEO_PROFILE_PORTRAIT_1440P = 1066 , VIDEO_PROFILE_PORTRAIT_1440P_2 = 1067 ,
  VIDEO_PROFILE_PORTRAIT_4K = 1070 , VIDEO_PROFILE_PORTRAIT_4K_3 = 1072 , VIDEO_PROFILE_DEFAULT = VIDEO_PROFILE_LANDSCAPE_360P
}
 
enum class   CHANNEL_MEDIA_RELAY_ERROR {
  RELAY_OK = 0 , RELAY_ERROR_SERVER_ERROR_RESPONSE = 1 , RELAY_ERROR_SERVER_NO_RESPONSE = 2 , RELAY_ERROR_NO_RESOURCE_AVAILABLE = 3 ,
  RELAY_ERROR_FAILED_JOIN_SRC = 4 , RELAY_ERROR_FAILED_JOIN_DEST = 5 , RELAY_ERROR_FAILED_PACKET_RECEIVED_FROM_SRC = 6 , RELAY_ERROR_FAILED_PACKET_SENT_TO_DEST = 7 ,
  RELAY_ERROR_SERVER_CONNECTION_LOST = 8 , RELAY_ERROR_INTERNAL_ERROR = 9 , RELAY_ERROR_SRC_TOKEN_EXPIRED = 10 , RELAY_ERROR_DEST_TOKEN_EXPIRED = 11
}
 
enum class   METADATA_TYPE { UNKNOWN_METADATA = -1 , VIDEO_METADATA = 0 }
 
enum class   RENDER_MODE_TYPE { RENDER_MODE_HIDDEN = 1 , RENDER_MODE_FIT = 2 , RENDER_MODE_ADAPTIVE = 3 }
 
enum class   ENCRYPTION_MODE {
  AES_128_XTS = 1 , AES_128_ECB = 2 , AES_256_XTS = 3 , SM4_128_ECB = 4 ,
  AES_128_GCM = 5 , AES_256_GCM = 6 , AES_128_GCM2 = 7 , AES_256_GCM2 = 8 ,
  MODE_END
}
 
enum class   RTMP_STREAMING_EVENT { RTMP_STREAMING_EVENT_FAILED_LOAD_IMAGE = 1 , RTMP_STREAMING_EVENT_URL_ALREADY_IN_USE = 2 , RTMP_STREAMING_EVENT_ADVANCED_FEATURE_NOT_SUPPORT = 3 , RTMP_STREAMING_EVENT_REQUEST_TOO_OFTEN = 4 }
 
enum class   STREAM_PUBLISH_STATE { PUB_STATE_IDLE = 0 , PUB_STATE_NO_PUBLISHED = 1 , PUB_STATE_PUBLISHING = 2 , PUB_STATE_PUBLISHED = 3 }
 
enum class   STREAM_SUBSCRIBE_STATE { SUB_STATE_IDLE = 0 , SUB_STATE_NO_SUBSCRIBED = 1 , SUB_STATE_SUBSCRIBING = 2 , SUB_STATE_SUBSCRIBED = 3 }
 
enum class   AUDIENCE_LATENCY_LEVEL_TYPE { AUDIENCE_LATENCY_LEVEL_LOW_LATENCY = 1 , AUDIENCE_LATENCY_LEVEL_ULTRA_LOW_LATENCY = 2 }
 
enum class   VOICE_BEAUTIFIER_PRESET {
  VOICE_BEAUTIFIER_OFF = 0x00000000 , CHAT_BEAUTIFIER_MAGNETIC = 0x01010100 , CHAT_BEAUTIFIER_FRESH = 0x01010200 , CHAT_BEAUTIFIER_VITALITY = 0x01010300 ,
  SINGING_BEAUTIFIER = 0x01020100 , TIMBRE_TRANSFORMATION_VIGOROUS = 0x01030100 , TIMBRE_TRANSFORMATION_DEEP = 0x01030200 , TIMBRE_TRANSFORMATION_MELLOW = 0x01030300 ,
  TIMBRE_TRANSFORMATION_FALSETTO = 0x01030400 , TIMBRE_TRANSFORMATION_FULL = 0x01030500 , TIMBRE_TRANSFORMATION_CLEAR = 0x01030600 , TIMBRE_TRANSFORMATION_RESOUNDING = 0x01030700 ,
  TIMBRE_TRANSFORMATION_RINGING = 0x01030800
}
 
enum class   AUDIO_EFFECT_PRESET {
  AUDIO_EFFECT_OFF = 0x00000000 , ROOM_ACOUSTICS_KTV = 0x02010100 , ROOM_ACOUSTICS_VOCAL_CONCERT = 0x02010200 , ROOM_ACOUSTICS_STUDIO = 0x02010300 ,
  ROOM_ACOUSTICS_PHONOGRAPH = 0x02010400 , ROOM_ACOUSTICS_VIRTUAL_STEREO = 0x02010500 , ROOM_ACOUSTICS_SPACIAL = 0x02010600 , ROOM_ACOUSTICS_ETHEREAL = 0x02010700 ,
  ROOM_ACOUSTICS_3D_VOICE = 0x02010800 , VOICE_CHANGER_EFFECT_UNCLE = 0x02020100 , VOICE_CHANGER_EFFECT_OLDMAN = 0x02020200 , VOICE_CHANGER_EFFECT_BOY = 0x02020300 ,
  VOICE_CHANGER_EFFECT_SISTER = 0x02020400 , VOICE_CHANGER_EFFECT_GIRL = 0x02020500 , VOICE_CHANGER_EFFECT_PIGKING = 0x02020600 , VOICE_CHANGER_EFFECT_HULK = 0x02020700 ,
  STYLE_TRANSFORMATION_RNB = 0x02030100 , STYLE_TRANSFORMATION_POPULAR = 0x02030200 , PITCH_CORRECTION = 0x02040100
}
 
enum class   SUPER_RESOLUTION_STATE_REASON { SR_STATE_REASON_SUCCESS = 0 , SR_STATE_REASON_STREAM_OVER_LIMITATION = 1 , SR_STATE_REASON_USER_COUNT_OVER_LIMITATION = 2 , SR_STATE_REASON_DEVICE_NOT_SUPPORTED = 3 }
 
enum class   CAPTURE_BRIGHTNESS_LEVEL_TYPE { CAPTURE_BRIGHTNESS_LEVEL_INVALID = -1 , CAPTURE_BRIGHTNESS_LEVEL_NORMAL = 0 , CAPTURE_BRIGHTNESS_LEVEL_BRIGHT = 1 , CAPTURE_BRIGHTNESS_LEVEL_DARK = 2 }
 
enum class   PROXY_TYPE {
  NONE_PROXY_TYPE = 0 , UDP_PROXY_TYPE = 1 , TCP_PROXY_TYPE = 2 , LOCAL_PROXY_TYPE = 3 ,
  TCP_PROXY_AUTO_FALLBACK_TYPE = 4
}
 
enum class   VOICE_CONVERSION_PRESET {
  VOICE_CONVERSION_OFF = 0x00000000 , VOICE_CHANGER_NEUTRAL = 0x03010100 , VOICE_CHANGER_SWEET = 0x03010200 , VOICE_CHANGER_SOLID = 0x03010300 ,
  VOICE_CHANGER_BASS = 0x03010400
}
 
enum class   EXPERIENCE_QUALITY_TYPE { EXPERIENCE_QUALITY_GOOD = 0 , EXPERIENCE_QUALITY_BAD = 1 }
 
enum class   EXPERIENCE_POOR_REASON {
  EXPERIENCE_REASON_NONE = 0 , REMOTE_NETWORK_QUALITY_POOR = 1 , LOCAL_NETWORK_QUALITY_POOR = 2 , WIRELESS_SIGNAL_POOR = 4 ,
  WIFI_BLUETOOTH_COEXIST = 8
}
 
enum class   BACKGROUND_SOURCE_TYPE { BACKGROUND_COLOR = 1 , BACKGROUND_IMG , BACKGROUND_BLUR }
 
enum class   BACKGROUND_BLUR_DEGREE { BLUR_DEGREE_LOW = 1 , BLUR_DEGREE_MEDIUM , BLUR_DEGREE_HIGH }
 
enum class   VIRTUAL_BACKGROUND_SOURCE_STATE_REASON { VIRTUAL_BACKGROUND_SOURCE_STATE_REASON_SUCCESS = 0 , VIRTUAL_BACKGROUND_SOURCE_STATE_REASON_IMAGE_NOT_EXIST = 1 , VIRTUAL_BACKGROUND_SOURCE_STATE_REASON_COLOR_FORMAT_NOT_SUPPORTED = 2 , VIRTUAL_BACKGROUND_SOURCE_STATE_REASON_DEVICE_NOT_SUPPORTED = 3 }
 
enum class   AUDIO_MIXING_DUAL_MONO_MODE { AUDIO_MIXING_DUAL_MONO_AUTO = 0 , AUDIO_MIXING_DUAL_MONO_L = 1 , AUDIO_MIXING_DUAL_MONO_R = 2 , AUDIO_MIXING_DUAL_MONO_MIX = 3 }
 
enum class   AUDIO_FILE_INFO_ERROR { AUDIO_FILE_INFO_ERROR_OK = 0 , AUDIO_FILE_INFO_ERROR_FAILURE = 1 }
 
enum class   MediaRecorderContainerFormat { FORMAT_MP4 = 1 , FORMAT_FLV = 2 }
 
enum class   MediaRecorderStreamType { STREAM_TYPE_AUDIO = 0x01 , STREAM_TYPE_VIDEO = 0x02 , STREAM_TYPE_BOTH = STREAM_TYPE_AUDIO | STREAM_TYPE_VIDEO }
 
enum class   RecorderState { RECORDER_STATE_ERROR = -1 , RECORDER_STATE_START = 2 , RECORDER_STATE_STOP = 3 }
 
enum class   RecorderErrorCode {
  RECORDER_ERROR_NONE = 0 , RECORDER_ERROR_WRITE_FAILED = 1 , RECORDER_ERROR_NO_STREAM = 2 , RECORDER_ERROR_OVER_MAX_DURATION = 3 ,
  RECORDER_ERROR_CONFIG_CHANGED = 4 , RECORDER_ERROR_CUSTOM_STREAM_DETECTED = 5
}
 
enum class   EXCLUDE_WINDOW_ERROR { EXCLUDE_WINDOW_FAIL = -1 , EXCLUDE_WINDOW_NONE = 0 }
 
enum class   AudioDeviceTestVolumeType { AudioTestRecordingVolume = 0 , AudioTestPlaybackVolume = 1 }
 
enum class   LOW_LIGHT_ENHANCE_MODE { LOW_LIGHT_ENHANCE_AUTO = 0 , LOW_LIGHT_ENHANCE_MANUAL }
 
enum class   LOW_LIGHT_ENHANCE_LEVEL { LOW_LIGHT_ENHANCE_LEVEL_HIGH_QUALITY = 0 , LOW_LIGHT_ENHANCE_LEVEL_FAST }
 
enum class   VIDEO_DENOISER_MODE { VIDEO_DENOISER_AUTO = 0 , VIDEO_DENOISER_MANUAL }
 
enum class   VIDEO_DENOISER_LEVEL { VIDEO_DENOISER_LEVEL_HIGH_QUALITY = 0 , VIDEO_DENOISER_LEVEL_FAST , VIDEO_DENOISER_LEVEL_STRENGTH }
 
enum class   CLIENT_ROLE_CHANGE_FAILED_REASON { CLIENT_ROLE_CHANGE_FAILED_BY_TOO_MANY_BROADCASTERS = 1 , CLIENT_ROLE_CHANGE_FAILED_BY_NOT_AUTHORIZED = 2 , CLIENT_ROLE_CHANGE_FAILED_BY_REQUEST_TIME_OUT = 3 , CLIENT_ROLE_CHANGE_FAILED_BY_CONNECTION_FAILED = 4 }
 
enum class   WLACC_MESSAGE_REASON { WLACC_MESSAGE_REASON_WEAK_SIGNAL = 0 , WLACC_MESSAGE_REASON_2G_CHANNEL_CONGESTION = 1 }
 
enum class   WLACC_SUGGEST_ACTION { WLACC_SUGGEST_ACTION_CLOSE_TO_WIFI = 0 , WLACC_SUGGEST_ACTION_CONNECT_5G = 1 , WLACC_SUGGEST_ACTION_CHECK_5G = 2 , WLACC_SUGGEST_ACTION_MODIFY_SSID = 3 }
 
enum class   CLOUD_PROXY_TYPE { NONE_PROXY = 0 , UDP_PROXY = 1 }
 
enum class   SCREEN_SCENARIO_TYPE { SCREEN_SCENARIO_DOCUMENT = 1 , SCREEN_SCENARIO_GAMING = 2 , SCREEN_SCENARIO_VIDEO = 3 , SCREEN_SCENARIO_RDC = 4 }
 
enum class   ScreenCaptureSourceType { ScreenCaptureSourceType_Unknown = -1 , ScreenCaptureSourceType_Window = 0 , ScreenCaptureSourceType_Screen = 1 , ScreenCaptureSourceType_Custom = 2 }
 
enum class   AgoraVideoSurfaceType { Renderer = 0 , RawImage = 1 }
 

Functions

delegate void  OnJoinChannelSuccessHandler (string channelName, uint uid, int elapsed)
 
delegate void  OnLeaveChannelHandler (RtcStats stats)
 
delegate void  OnReJoinChannelSuccessHandler (string channelName, uint uid, int elapsed)
 
delegate void  OnConnectionLostHandler ()
 
delegate void  OnConnectionInterruptedHandler ()
 
delegate void  OnRequestTokenHandler ()
 
delegate void  OnUserJoinedHandler (uint uid, int elapsed)
 
delegate void  OnUserOfflineHandler (uint uid, USER_OFFLINE_REASON reason)
 
delegate void  OnVolumeIndicationHandler (AudioVolumeInfo[] speakers, int speakerNumber, int totalVolume)
 
delegate void  OnLocalVoicePitchInHzHandler (int pitchInHz)
 
delegate void  OnUserMutedAudioHandler (uint uid, bool muted)
 
delegate void  OnSDKWarningHandler (int warn, string msg)
 
delegate void  OnSDKErrorHandler (int error, string msg)
 
delegate void  OnRtcStatsHandler (RtcStats stats)
 
delegate void  OnAudioMixingFinishedHandler ()
 
delegate void  OnAudioRouteChangedHandler (AUDIO_ROUTE route)
 
delegate void  OnFirstRemoteVideoDecodedHandler (uint uid, int width, int height, int elapsed)
 
delegate void  OnVideoSizeChangedHandler (uint uid, int width, int height, int rotation)
 
delegate void  OnClientRoleChangedHandler (CLIENT_ROLE_TYPE oldRole, CLIENT_ROLE_TYPE newRole)
 
delegate void  OnUserMuteVideoHandler (uint uid, bool muted)
 
delegate void  OnMicrophoneEnabledHandler (bool isEnabled)
 
delegate void  OnApiExecutedHandler (int err, string api, string result)
 
delegate void  OnLastmileQualityHandler (int quality)
 
delegate void  OnFirstLocalAudioFrameHandler (int elapsed)
 
delegate void  OnFirstRemoteAudioFrameHandler (uint userId, int elapsed)
 
delegate void  OnAudioQualityHandler (uint userId, int quality, ushort delay, ushort lost)
 
delegate void  OnStreamUnpublishedHandler (string url)
 
delegate void  OnStreamPublishedHandler (string url, int error)
 
delegate void  OnStreamMessageErrorHandler (uint userId, int streamId, int code, int missed, int cached)
 
delegate void  OnStreamMessageHandler (uint userId, int streamId, byte[] data, int length)
 
delegate void  OnConnectionBannedHandler ()
 
delegate void  OnConnectionStateChangedHandler (CONNECTION_STATE_TYPE state, CONNECTION_CHANGED_REASON_TYPE reason)
 
delegate void  OnTokenPrivilegeWillExpireHandler (string token)
 
delegate void  OnActiveSpeakerHandler (uint uid)
 
delegate void  OnVideoStoppedHandler ()
 
delegate void  OnFirstLocalVideoFrameHandler (int width, int height, int elapsed)
 
delegate void  OnFirstRemoteVideoFrameHandler (uint uid, int width, int height, int elapsed)
 
delegate void  OnUserEnableVideoHandler (uint uid, bool enabled)
 
delegate void  OnUserEnableLocalVideoHandler (uint uid, bool enabled)
 
delegate void  OnRemoteVideoStateChangedHandler (uint uid, REMOTE_VIDEO_STATE state, REMOTE_VIDEO_STATE_REASON reason, int elapsed)
 
delegate void  OnLocalPublishFallbackToAudioOnlyHandler (bool isFallbackOrRecover)
 
delegate void  OnRemoteSubscribeFallbackToAudioOnlyHandler (uint uid, bool isFallbackOrRecover)
 
delegate void  OnNetworkQualityHandler (uint uid, int txQuality, int rxQuality)
 
delegate void  OnLocalVideoStatsHandler (LocalVideoStats localVideoStats)
 
delegate void  OnRemoteVideoStatsHandler (RemoteVideoStats remoteVideoStats)
 
delegate void  OnRemoteAudioStatsHandler (RemoteAudioStats remoteAudioStats)
 
delegate void  OnAudioDeviceStateChangedHandler (string deviceId, int deviceType, int deviceState)
 
delegate void  OnCameraReadyHandler ()
 
delegate void  OnCameraFocusAreaChangedHandler (int x, int y, int width, int height)
 
delegate void  OnCameraExposureAreaChangedHandler (int x, int y, int width, int height)
 
delegate void  OnRemoteAudioMixingBeginHandler ()
 
delegate void  OnRemoteAudioMixingEndHandler ()
 
delegate void  OnAudioEffectFinishedHandler (int soundId)
 
delegate void  OnVideoDeviceStateChangedHandler (string deviceId, int deviceType, int deviceState)
 
delegate void  OnRemoteVideoTransportStatsHandler (uint uid, ushort delay, ushort lost, ushort rxKBitRate)
 
delegate void  OnRemoteAudioTransportStatsHandler (uint uid, ushort delay, ushort lost, ushort rxKBitRate)
 
delegate void  OnTranscodingUpdatedHandler ()
 
delegate void  OnAudioDeviceVolumeChangedHandler (MEDIA_DEVICE_TYPE deviceType, int volume, bool muted)
 
delegate void  OnMediaEngineStartCallSuccessHandler ()
 
delegate void  OnMediaEngineLoadSuccessHandler ()
 
delegate void  OnAudioMixingStateChangedHandler (AUDIO_MIXING_STATE_TYPE state, AUDIO_MIXING_REASON_TYPE reason)
 
delegate void  OnFirstRemoteAudioDecodedHandler (uint uid, int elapsed)
 
delegate void  OnLocalVideoStateChangedHandler (LOCAL_VIDEO_STREAM_STATE localVideoState, LOCAL_VIDEO_STREAM_ERROR error)
 
delegate void  OnRtmpStreamingStateChangedHandler (string url, RTMP_STREAM_PUBLISH_STATE state, RTMP_STREAM_PUBLISH_ERROR_TYPE errCode)
 
delegate void  OnNetworkTypeChangedHandler (NETWORK_TYPE type)
 
delegate void  OnLastmileProbeResultHandler (LastmileProbeResult result)
 
delegate void  OnLocalUserRegisteredHandler (uint uid, string userAccount)
 
delegate void  OnUserInfoUpdatedHandler (uint uid, UserInfo userInfo)
 
delegate void  OnLocalAudioStateChangedHandler (LOCAL_AUDIO_STREAM_STATE state, LOCAL_AUDIO_STREAM_ERROR error)
 
delegate void  OnRemoteAudioStateChangedHandler (uint uid, REMOTE_AUDIO_STATE state, REMOTE_AUDIO_STATE_REASON reason, int elapsed)
 
delegate void  OnLocalAudioStatsHandler (LocalAudioStats localAudioStats)
 
delegate void  OnChannelMediaRelayStateChangedHandler (CHANNEL_MEDIA_RELAY_STATE state, CHANNEL_MEDIA_RELAY_ERROR code)
 
delegate void  OnChannelMediaRelayEventHandler (CHANNEL_MEDIA_RELAY_EVENT events)
 
delegate void  OnFacePositionChangedHandler (int imageWidth, int imageHeight, Rectangle vecRectangle, int vecDistance, int numFaces)
 
delegate void  OnRtmpStreamingEventHandler (string url, RTMP_STREAMING_EVENT eventCode)
 
delegate void  OnAudioPublishStateChangedHandler (string channel, STREAM_PUBLISH_STATE oldState, STREAM_PUBLISH_STATE newState, int elapseSinceLastState)
 
delegate void  OnVideoPublishStateChangedHandler (string channel, STREAM_PUBLISH_STATE oldState, STREAM_PUBLISH_STATE newState, int elapseSinceLastState)
 
delegate void  OnAudioSubscribeStateChangedHandler (string channel, uint uid, STREAM_SUBSCRIBE_STATE oldState, STREAM_SUBSCRIBE_STATE newState, int elapseSinceLastState)
 
delegate void  OnVideoSubscribeStateChangedHandler (string channel, uint uid, STREAM_SUBSCRIBE_STATE oldState, STREAM_SUBSCRIBE_STATE newState, int elapseSinceLastState)
 
delegate void  OnFirstLocalAudioFramePublishedHandler (int elapsed)
 
delegate void  OnFirstLocalVideoFramePublishedHandler (int elapsed)
 
delegate void  OnUserSuperResolutionEnabledHandler (uint uid, bool enabled, SUPER_RESOLUTION_STATE_REASON reason)
 
delegate void  OnVirtualBackgroundSourceEnabledHandler (bool enabled, VIRTUAL_BACKGROUND_SOURCE_STATE_REASON reason)
 
delegate void  OnRequestAudioFileInfoHandler (AudioFileInfo info, AUDIO_FILE_INFO_ERROR error)
 
delegate void  OnSnapshotTakenHandler (string channel, uint uid, string filePath, int width, int height, int errCode)
 
delegate void  OnClientRoleChangeFailedHandler (CLIENT_ROLE_CHANGE_FAILED_REASON reason, CLIENT_ROLE_TYPE currentRole)
 
delegate void  OnAudioDeviceTestVolumeIndicationHandler (AudioDeviceTestVolumeType volumeType, int volume)
 
delegate void  OnProxyConnectedHandler (string channel, uint uid, PROXY_TYPE proxyType, string localProxyIp, int elapsed)
 
delegate void  OnScreenCaptureInfoUpdatedHandler (ScreenCaptureInfo info)
 
delegate void  ChannelOnWarningHandler (string channelId, int warn, string message)
 
delegate void  ChannelOnErrorHandler (string channelId, int err, string message)
 
delegate void  ChannelOnJoinChannelSuccessHandler (string channelId, uint uid, int elapsed)
 
delegate void  ChannelOnReJoinChannelSuccessHandler (string channelId, uint uid, int elapsed)
 
delegate void  ChannelOnLeaveChannelHandler (string channelId, RtcStats rtcStats)
 
delegate void  ChannelOnClientRoleChangedHandler (string channelId, CLIENT_ROLE_TYPE oldRole, CLIENT_ROLE_TYPE newRole)
 
delegate void  ChannelOnUserJoinedHandler (string channelId, uint uid, int elapsed)
 
delegate void  ChannelOnUserOffLineHandler (string channelId, uint uid, USER_OFFLINE_REASON reason)
 
delegate void  ChannelOnConnectionLostHandler (string channelId)
 
delegate void  ChannelOnRequestTokenHandler (string channelId)
 
delegate void  ChannelOnTokenPrivilegeWillExpireHandler (string channelId, string token)
 
delegate void  ChannelOnRtcStatsHandler (string channelId, RtcStats rtcStats)
 
delegate void  ChannelOnNetworkQualityHandler (string channelId, uint uid, int txQuality, int rxQuality)
 
delegate void  ChannelOnRemoteVideoStatsHandler (string channelId, RemoteVideoStats remoteVideoStats)
 
delegate void  ChannelOnRemoteAudioStatsHandler (string channelId, RemoteAudioStats remoteAudioStats)
 
delegate void  ChannelOnRemoteAudioStateChangedHandler (string channelId, uint uid, REMOTE_AUDIO_STATE state, REMOTE_AUDIO_STATE_REASON reason, int elapsed)
 
delegate void  ChannelOnActiveSpeakerHandler (string channelId, uint uid)
 
delegate void  ChannelOnVideoSizeChangedHandler (string channelId, uint uid, int width, int height, int rotation)
 
delegate void  ChannelOnRemoteVideoStateChangedHandler (string channelId, uint uid, REMOTE_VIDEO_STATE state, REMOTE_VIDEO_STATE_REASON reason, int elapsed)
 
delegate void  ChannelOnStreamMessageHandler (string channelId, uint uid, int streamId, string data, int length)
 
delegate void  ChannelOnStreamMessageErrorHandler (string channelId, uint uid, int streamId, int code, int missed, int cached)
 
delegate void  ChannelOnMediaRelayStateChangedHandler (string channelId, CHANNEL_MEDIA_RELAY_STATE state, CHANNEL_MEDIA_RELAY_ERROR code)
 
delegate void  ChannelOnMediaRelayEventHandler (string channelId, CHANNEL_MEDIA_RELAY_EVENT events)
 
delegate void  ChannelOnRtmpStreamingStateChangedHandler (string channelId, string url, RTMP_STREAM_PUBLISH_STATE state, RTMP_STREAM_PUBLISH_ERROR_TYPE errCode)
 
delegate void  ChannelOnTranscodingUpdatedHandler (string channelId)
 
delegate void  ChannelOnRemoteSubscribeFallbackToAudioOnlyHandler (string channelId, uint uid, bool isFallbackOrRecover)
 
delegate void  ChannelOnConnectionStateChangedHandler (string channelId, CONNECTION_STATE_TYPE state, CONNECTION_CHANGED_REASON_TYPE reason)
 
delegate void  ChannelOnLocalPublishFallbackToAudioOnlyHandler (string channelId, bool isFallbackOrRecover)
 
delegate void  ChannelOnRtmpStreamingEventHandler (string channelId, string url, RTMP_STREAMING_EVENT eventCode)
 
delegate void  ChannelOnAudioPublishStateChangedHandler (string channelId, STREAM_PUBLISH_STATE oldState, STREAM_PUBLISH_STATE newState, int elapseSinceLastState)
 
delegate void  ChannelOnVideoPublishStateChangedHandler (string channelId, STREAM_PUBLISH_STATE oldState, STREAM_PUBLISH_STATE newState, int elapseSinceLastState)
 
delegate void  ChannelOnAudioSubscribeStateChangedHandler (string channelId, uint uid, STREAM_SUBSCRIBE_STATE oldState, STREAM_SUBSCRIBE_STATE newState, int elapseSinceLastState)
 
delegate void  ChannelOnVideoSubscribeStateChangedHandler (string channelId, uint uid, STREAM_SUBSCRIBE_STATE oldState, STREAM_SUBSCRIBE_STATE newState, int elapseSinceLastState)
 
delegate void  ChannelOnUserSuperResolutionEnabledHandler (string channelId, uint uid, bool enabled, SUPER_RESOLUTION_STATE_REASON reason)
 
delegate void  ChannelOnClientRoleChangeFailedHandler (string channelId, CLIENT_ROLE_CHANGE_FAILED_REASON reason, CLIENT_ROLE_TYPE currentRole)
 
delegate void  ChannelOnFirstRemoteVideoFrameHandler (string channelId, uint uid, int width, int height, int elapsed)
 
delegate void  ChannelOnChannelProxyConnectedHandler (string channelId, uint uid, PROXY_TYPE proxyType, string localProxyIp, int elapsed)
 

Enumeration Type Documentation

◆ AgoraVideoSurfaceType

The definition of AgoraVideoSurfaceType.

Enumerator
Renderer 

0: (Default) The renderer for rendering 3D GameObject, such as Cube、Cylinder and Plane.

RawImage 

1: The renderer for rendering Raw Image of the UI components.

◆ AREA_CODE

enum agora_gaming_rtc.AREA_CODE : uint
strong

Regions for connetion.

Enumerator
AREA_CODE_CN 

Mainland China.

AREA_CODE_NA 

North America.

AREA_CODE_EU 

Europe.

AREA_CODE_AS 

Asia, excluding Mainland China.

AREA_CODE_JP 

Japan.

AREA_CODE_IN 

India.

AREA_CODE_GLOB 

(Default) Global.

◆ AUDIENCE_LATENCY_LEVEL_TYPE

The latency level of an audience member in interactive live streaming.

Note
Takes effect only when the user role is CLIENT_ROLE_AUDIENCE.
Enumerator
AUDIENCE_LATENCY_LEVEL_LOW_LATENCY 

1: Low latency.

AUDIENCE_LATENCY_LEVEL_ULTRA_LOW_LATENCY 

2: (Default) Ultra low latency.

◆ AUDIO_CODEC_PROFILE_TYPE

Audio codec profile types. The default value is LC_ACC.

Enumerator
AUDIO_CODEC_PROFILE_LC_AAC 

0: LC-AAC, which is the low-complexity audio codec type.

AUDIO_CODEC_PROFILE_HE_AAC 

1: HE-AAC, which is the high-efficiency audio codec type.

AUDIO_CODEC_PROFILE_HE_AAC_V2 

2: HE-AACv2, which is the high-efficiency audio codec type.

Since
v3.6.1.1

◆ AUDIO_EFFECT_PRESET

The options for SDK preset audio effects.

Enumerator
AUDIO_EFFECT_OFF 

Turn off audio effects and use the original voice.

ROOM_ACOUSTICS_KTV 

An audio effect typical of a KTV venue.

Note
To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
ROOM_ACOUSTICS_VOCAL_CONCERT 

An audio effect typical of a concert hall.

Note
To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
ROOM_ACOUSTICS_STUDIO 

An audio effect typical of a recording studio.

Note
To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
ROOM_ACOUSTICS_PHONOGRAPH 

An audio effect typical of a vintage phonograph.

Note
To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
ROOM_ACOUSTICS_VIRTUAL_STEREO 

A virtual stereo effect that renders monophonic audio as stereo audio.

Note
Call SetAudioProfile and set the profile parameter to AUDIO_PROFILE_MUSIC_STANDARD_STEREO(3) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator; otherwise, the enumerator setting does not take effect.
ROOM_ACOUSTICS_SPACIAL 

A more spatial audio effect.

Note
To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
ROOM_ACOUSTICS_ETHEREAL 

A more ethereal audio effect.

Note
To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
ROOM_ACOUSTICS_3D_VOICE 

A 3D voice effect that makes the voice appear to be moving around the user. The default cycle period of the 3D voice effect is 10 seconds. To change the cycle period, call SetAudioEffectParameters after this method.

Note
  • Call SetAudioProfile and set the profile parameter to AUDIO_PROFILE_MUSIC_STANDARD_STEREO(3) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator; otherwise, the enumerator setting does not take effect.
  • If the 3D voice effect is enabled, users need to use stereo audio playback devices to hear the anticipated voice effect.
VOICE_CHANGER_EFFECT_UNCLE 

The voice of an uncle.

Note
  • Agora recommends using this enumerator to process a male-sounding voice; otherwise, you may not hear the anticipated voice effect.
  • To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
VOICE_CHANGER_EFFECT_OLDMAN 

The voice of an old man.

Note
  • Agora recommends using this enumerator to process a male-sounding voice; otherwise, you may not hear the anticipated voice effect.
  • To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
VOICE_CHANGER_EFFECT_BOY 

The voice of a boy.

Note
  • Agora recommends using this enumerator to process a male-sounding voice; otherwise, you may not hear the anticipated voice effect.
  • To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
VOICE_CHANGER_EFFECT_SISTER 

The voice of a young woman.

Note
  • Agora recommends using this enumerator to process a female-sounding voice; otherwise, you may not hear the anticipated voice effect.
  • To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
VOICE_CHANGER_EFFECT_GIRL 

The voice of a girl.

Note
  • Agora recommends using this enumerator to process a female-sounding voice; otherwise, you may not hear the anticipated voice effect.
  • To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
VOICE_CHANGER_EFFECT_PIGKING 

The voice of Pig King, a character in Journey to the West who has a voice like a growling bear.

Note
To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
VOICE_CHANGER_EFFECT_HULK 

The voice of Hulk.

Note
To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.
STYLE_TRANSFORMATION_RNB 

An audio effect typical of R&B music.

Note
Call SetAudioProfile and set the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator; otherwise, the enumerator setting does not take effect.
STYLE_TRANSFORMATION_POPULAR 

An audio effect typical of popular music.

Note
Call SetAudioProfile and set the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator; otherwise, the enumerator setting does not take effect.
PITCH_CORRECTION 

A pitch correction effect that corrects the user's pitch based on the pitch of the natural C major scale. To change the basic mode and tonic pitch, call SetAudioEffectParameters after this method.

Note
To achieve better audio effect quality, Agora recommends calling SetAudioProfile and setting the profile parameter to AUDIO_PROFILE_MUSIC_HIGH_QUALITY(4) or AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5) before setting this enumerator.

◆ AUDIO_EQUALIZATION_BAND_FREQUENCY

Audio equalization band frequencies.

Enumerator
AUDIO_EQUALIZATION_BAND_31 

0: 31 Hz

AUDIO_EQUALIZATION_BAND_62 

1: 62 Hz

AUDIO_EQUALIZATION_BAND_125 

2: 125 Hz

AUDIO_EQUALIZATION_BAND_250 

3: 250 Hz

AUDIO_EQUALIZATION_BAND_500 

4: 500 Hz

AUDIO_EQUALIZATION_BAND_1K 

5: 1 kHz

AUDIO_EQUALIZATION_BAND_2K 

6: 2 kHz

AUDIO_EQUALIZATION_BAND_4K 

7: 4 kHz

AUDIO_EQUALIZATION_BAND_8K 

8: 8 kHz

AUDIO_EQUALIZATION_BAND_16K 

9: 16 kHz

◆ AUDIO_FILE_INFO_ERROR

The information acquisition state. This enum is reported in OnRequestAudioFileInfoHandler.

Since
v3.6.1.1
Enumerator
AUDIO_FILE_INFO_ERROR_OK 

0: Successfully get the information of an audio file.

AUDIO_FILE_INFO_ERROR_FAILURE 

1: Fail to get the information of an audio file.

◆ AUDIO_FRAME_TYPE

The audio frame type.

Enumerator
FRAME_TYPE_PCM16 

0: PCM16.

◆ AUDIO_MIXING_DUAL_MONO_MODE

The channel mode. Set in SetAudioMixingDualMonoMode.

Since
v3.6.1.1
Enumerator
AUDIO_MIXING_DUAL_MONO_AUTO 

0: Original mode.

AUDIO_MIXING_DUAL_MONO_L 

1: Left channel mode. This mode replaces the audio of the right channel with the audio of the left channel, which means the user can only hear the audio of the left channel.

AUDIO_MIXING_DUAL_MONO_R 

2: Right channel mode. This mode replaces the audio of the left channel with the audio of the right channel, which means the user can only hear the audio of the right channel.

AUDIO_MIXING_DUAL_MONO_MIX 

3: Mixed channel mode. This mode mixes the audio of the left channel and the right channel, which means the user can hear the audio of the left channel and the right channel at the same time.

◆ AUDIO_MIXING_ERROR_TYPE

The error codes of the local user's audio mixing file.

Deprecated:
Deprecated from v3.4.2, Use AUDIO_MIXING_REASON_TYPE instead.
Enumerator
AUDIO_MIXING_ERROR_CAN_NOT_OPEN 

701: The SDK cannot open the audio mixing file.

AUDIO_MIXING_ERROR_TOO_FREQUENT_CALL 

702: The SDK opens the audio mixing file too frequently.

AUDIO_MIXING_ERROR_INTERRUPTED_EOF 

703: The opening of the audio mixing file is interrupted.

AUDIO_MIXING_ERROR_OK 

0: The SDK can open the audio mixing file.

◆ AUDIO_MIXING_REASON_TYPE

The reason of audio mixing state change.

Enumerator
AUDIO_MIXING_REASON_CAN_NOT_OPEN 

701: The SDK cannot open the audio mixing file.

AUDIO_MIXING_REASON_TOO_FREQUENT_CALL 

702: The SDK opens the audio mixing file too frequently.

AUDIO_MIXING_REASON_INTERRUPTED_EOF 

703: The audio mixing file playback is interrupted.

AUDIO_MIXING_REASON_STARTED_BY_USER 

720: The audio mixing is started by user.

AUDIO_MIXING_REASON_ONE_LOOP_COMPLETED 

721: The audio mixing file is played once.

AUDIO_MIXING_REASON_START_NEW_LOOP 

722: The audio mixing file is playing in a new loop.

AUDIO_MIXING_REASON_ALL_LOOPS_COMPLETED 

723: The audio mixing file is all played out.

AUDIO_MIXING_REASON_STOPPED_BY_USER 

724: Playing of audio file is stopped by user.

AUDIO_MIXING_REASON_PAUSED_BY_USER 

725: Playing of audio file is paused by user.

AUDIO_MIXING_REASON_RESUMED_BY_USER 

726: Playing of audio file is resumed by user.

◆ AUDIO_MIXING_STATE_TYPE

The states of the local user's audio mixing file.

Enumerator
AUDIO_MIXING_STATE_PLAYING 

710: The audio mixing file is playing. This state indicates that the SDK is in the following stages:

AUDIO_MIXING_STATE_PAUSED 

711: The audio mixing file pauses playing. This state indicates that the SDK calls PauseAudioMixing successfully.

AUDIO_MIXING_STATE_STOPPED 

713: The audio mixing file stops playing. This state indicates that the SDK calls StopAudioMixing successfully.

AUDIO_MIXING_STATE_FAILED 

714: An exception occurs during the playback of the audio mixing file. See error types in the errorCode for details.

◆ AUDIO_PROFILE_TYPE

Audio profiles.

Sets the sample rate, bitrate, encoding mode, and the number of channels.

Enumerator
AUDIO_PROFILE_DEFAULT 

0: Default audio profile.

  • For the LIVE_BROADCASTING profile: A sample rate of 48 KHz, music encoding, mono, and a bitrate of up to 64 Kbps.
  • For the COMMUNICATION profile:
    • Windows: A sample rate of 16 KHz, music encoding, mono, and a bitrate of up to 16 Kbps.
    • Android/iOS/macOS: A sample rate of 32 KHz, music encoding, mono, and a bitrate of up to 18 Kbps.
AUDIO_PROFILE_SPEECH_STANDARD 

1: A sample rate of 32 KHz, audio encoding, mono, and a bitrate of up to 18 Kbps.

AUDIO_PROFILE_MUSIC_STANDARD 

2: A sample rate of 48 kHz, music encoding, mono, and a bitrate of up to 64 Kbps.

AUDIO_PROFILE_MUSIC_STANDARD_STEREO 

3: A sample rate of 48 kHz, music encoding, stereo, and a bitrate of up to 80 Kbps.

AUDIO_PROFILE_MUSIC_HIGH_QUALITY 

4: A sample rate of 48 kHz, music encoding, mono, and a bitrate of up to 96 Kbps.

AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO 

5: A sample rate of 48 kHz, music encoding, stereo, and a bitrate of up to 128 Kbps.

AUDIO_PROFILE_IOT 

6: A sample rate of 16 kHz, audio encoding, mono, and Acoustic Echo Cancellation (AES) enabled.

AUDIO_PROFILE_NUM 

The number of elements in the enumeration.

◆ AUDIO_RECORDING_POSITION

The reording content, set in StartAudioRecording.

Enumerator
AUDIO_RECORDING_POSITION_MIXED_RECORDING_AND_PLAYBACK 

0: (Default) Records the mixed audio of the local user and all remote users.

AUDIO_RECORDING_POSITION_RECORDING 

1: Records the audio of the local user only.

AUDIO_RECORDING_POSITION_MIXED_PLAYBACK 

2: Records the audio of all remote users only.

◆ AUDIO_RECORDING_QUALITY_TYPE

The audio recording quality, which is set in StartAudioRecording.

Enumerator
AUDIO_RECORDING_QUALITY_LOW 

0: Low quality. For example, the size of an AAC file with a sample rate of 32,000 Hz and a 10-minute recording is approximately 1.2 MB.

AUDIO_RECORDING_QUALITY_MEDIUM 

1: (Default) Medium quality. For example, the size of an AAC file with a sample rate of 32,000 Hz and a 10-minute recording is approximately 2 MB.

AUDIO_RECORDING_QUALITY_HIGH 

2: High quality. For example, the size of an AAC file with a sample rate of 32,000 Hz and a 10-minute recording is approximately 3.75 MB.

AUDIO_RECORDING_QUALITY_ULTRA_HIGH 

3: Ultra high quality. For example, the size of an AAC file with a sample rate of 32,000 Hz and a 10-minute recording is approximately 7.5 MB.

◆ AUDIO_REVERB_PRESET

Local voice reverberation presets.

Deprecated:
Deprecated as of v3.2.0. Use AUDIO_EFFECT_PRESET instead.
Enumerator
AUDIO_REVERB_OFF 

Turn off local voice reverberation, that is, to use the original voice.

AUDIO_REVERB_FX_KTV 

The reverberation style typical of a KTV venue (enhanced).

AUDIO_REVERB_FX_VOCAL_CONCERT 

The reverberation style typical of a concert hall (enhanced).

AUDIO_REVERB_FX_UNCLE 

The reverberation style typical of an uncle's voice.

AUDIO_REVERB_FX_SISTER 

The reverberation style typical of a sister's voice.

AUDIO_REVERB_FX_STUDIO 

The reverberation style typical of a recording studio (enhanced).

AUDIO_REVERB_FX_POPULAR 

The reverberation style typical of popular music (enhanced).

AUDIO_REVERB_FX_RNB 

The reverberation style typical of R&B music (enhanced).

AUDIO_REVERB_FX_PHONOGRAPH 

The reverberation style typical of the vintage phonograph.

AUDIO_REVERB_POPULAR 

The reverberation style typical of popular music.

AUDIO_REVERB_RNB 

The reverberation style typical of R&B music.

AUDIO_REVERB_ROCK 

The reverberation style typical of rock music.

AUDIO_REVERB_HIPHOP 

The reverberation style typical of hip-hop music.

AUDIO_REVERB_VOCAL_CONCERT 

The reverberation style typical of a concert hall.

AUDIO_REVERB_KTV 

The reverberation style typical of a KTV venue.

AUDIO_REVERB_STUDIO 

The reverberation style typical of a recording studio.

AUDIO_VIRTUAL_STEREO 

The reverberation of the virtual stereo. The virtual stereo is an effect that renders the monophonic audio as the stereo audio, so that all users in the channel can hear the stereo voice effect. To achieve better virtual stereo reverberation, Agora recommends setting profile in SetAudioProfile as AUDIO_PROFILE_MUSIC_HIGH_QUALITY_STEREO(5).

◆ AUDIO_REVERB_TYPE

Audio reverberation types.

Enumerator
AUDIO_REVERB_DRY_LEVEL 

0: The level of the dry signal (db). The value is between -20 and 10.

AUDIO_REVERB_WET_LEVEL 

1: The level of the early reflection signal (wet signal) (dB). The value is between -20 and 10.

AUDIO_REVERB_ROOM_SIZE 

2: The room size of the reflection. The value is between 0 and 100.

AUDIO_REVERB_WET_DELAY 

3: The length of the initial delay of the wet signal (ms). The value is between 0 and 200.

AUDIO_REVERB_STRENGTH 

4: The reverberation strength. The value is between 0 and 100.

◆ AUDIO_ROUTE

Audio output routing.

Enumerator
AUDIO_ROUTE_DEFAULT 

Default.

AUDIO_ROUTE_HEADSET 

Headset.

AUDIO_ROUTE_EARPIECE 

Earpiece.

AUDIO_ROUTE_HEADSET_NO_MIC 

Headset with no microphone.

AUDIO_ROUTE_SPEAKERPHONE 

Speakerphone.

AUDIO_ROUTE_LOUDSPEAKER 

Loudspeaker.

AUDIO_ROUTE_BLUETOOTH 

Bluetooth headset.

AUDIO_ROUTE_USB 

USB peripheral (macOS only).

AUDIO_ROUTE_HDMI 

HDMI peripheral (macOS only).

AUDIO_ROUTE_DISPLAYPORT 

DisplayPort peripheral (macOS only).

AUDIO_ROUTE_AIRPLAY 

Apple AirPlay (macOS only).

◆ AUDIO_SAMPLE_RATE_TYPE

Audio-sample rates.

Enumerator
AUDIO_SAMPLE_RATE_32000 

32000: 32 kHz

AUDIO_SAMPLE_RATE_44100 

44100: 44.1 kHz

AUDIO_SAMPLE_RATE_48000 

48000: 48 kHz

◆ AUDIO_SCENARIO_TYPE

Audio application scenarios.

Enumerator
AUDIO_SCENARIO_DEFAULT 

0: Default audio scenario.

AUDIO_SCENARIO_CHATROOM_ENTERTAINMENT 

1: Entertainment scenario, supporting voice during gameplay.

AUDIO_SCENARIO_EDUCATION 

2: Education scenario where users need to frequently switch the user role.

AUDIO_SCENARIO_GAME_STREAMING 

3: High-quality audio chatroom scenario where hosts mainly play music.

AUDIO_SCENARIO_SHOWROOM 

4: Showroom scenario where a single host wants high-quality audio.

AUDIO_SCENARIO_CHATROOM_GAMING 

5: Gaming scenario for group chat that only contains the human voice.

AUDIO_SCENARIO_IOT 

6: IoT (Internet of Things) scenario where users use IoT devices with low power consumption.

AUDIO_SCENARIO_MEETING 

8: Meeting scenario that mainly contains the human voice.

   @since v3.2.0
AUDIO_SCENARIO_NUM 

The number of elements in the enumeration.

◆ AUDIO_SESSION_OPERATION_RESTRICTION

Audio session restriction.

Enumerator
AUDIO_SESSION_OPERATION_RESTRICTION_NONE 

No restriction, the SDK has full control of the audio session operations.

AUDIO_SESSION_OPERATION_RESTRICTION_SET_CATEGORY 

The SDK does not change the audio session category.

AUDIO_SESSION_OPERATION_RESTRICTION_CONFIGURE_SESSION 

The SDK does not change any setting of the audio session (category, mode, categoryOptions).

AUDIO_SESSION_OPERATION_RESTRICTION_DEACTIVATE_SESSION 

The SDK keeps the audio session active when leaving a channel.

AUDIO_SESSION_OPERATION_RESTRICTION_ALL 

The SDK does not configure the audio session anymore.

◆ AudioDeviceTestVolumeType

The volume type.

Since
3.6.2
Enumerator
AudioTestRecordingVolume 

0: The volume of the audio capturing device.

AudioTestPlaybackVolume 

1: The volume of the audio playback device.

◆ AVDATA_TYPE

Enumerator
AVDATA_UNKNOWN 

0: the metadata type is unknown.

AVDATA_VIDEO 

1: the metadata type is video.

AVDATA_AUDIO 

2: the metadata type is video.

◆ BACKGROUND_BLUR_DEGREE

The degree of blurring applied to the custom background image.

Since
v3.6.1.1
Enumerator
BLUR_DEGREE_LOW 

1: The degree of blurring applied to the custom background image is low. The user can almost see the background clearly.

BLUR_DEGREE_MEDIUM 

The degree of blurring applied to the custom background image is medium. It is difficult for the user to recognize details in the background.

BLUR_DEGREE_HIGH 

(Default) The degree of blurring applied to the custom background image is high. The user can barely see any distinguishing features in the background.

◆ BACKGROUND_SOURCE_TYPE

The type of the custom background image.

Enumerator
BACKGROUND_COLOR 

1: (Default) The background image is a solid color.

BACKGROUND_IMG 

The background image is a file in PNG or JPG format.

BACKGROUND_BLUR 

The background image is blurred.

Since
v3.6.1.1

◆ CAMERA_DIRECTION

Sets the camera direction.

Enumerator
CAMERA_REAR 

0: Uses the rear camera.

CAMERA_FRONT 

1: Uses the front camera.

◆ CAPTURE_BRIGHTNESS_LEVEL_TYPE

The brightness level of the video image captured by the local camera.

Since
v3.3.1
Enumerator
CAPTURE_BRIGHTNESS_LEVEL_INVALID 

-1: The SDK does not detect the brightness level of the video image. Wait a few seconds to get the brightness level from CAPTURE_BRIGHTNESS_LEVEL_TYPE in the next callback.

CAPTURE_BRIGHTNESS_LEVEL_NORMAL 

0: The brightness level of the video image is normal.

CAPTURE_BRIGHTNESS_LEVEL_BRIGHT 

1: The brightness level of the video image is too bright.

CAPTURE_BRIGHTNESS_LEVEL_DARK 

2: The brightness level of the video image is too dark.

◆ CAPTURER_OUTPUT_PREFERENCE

Camera capturer configuration.

Enumerator
CAPTURER_OUTPUT_PREFERENCE_AUTO 

0: (Default) self-adapts the camera output parameters to the system performance and network conditions to balance CPU consumption and video preview quality.

CAPTURER_OUTPUT_PREFERENCE_PERFORMANCE 

1: Prioritizes the system performance. The SDK chooses the dimension and frame rate of the local camera capture closest to those set by SetVideoEncoderConfiguration.

CAPTURER_OUTPUT_PREFERENCE_PREVIEW 

2: Prioritizes the local preview quality. The SDK chooses higher camera output parameters to improve the local video preview quality. This option requires extra CPU and RAM usage for video pre-processing.

CAPTURER_OUTPUT_PREFERENCE_MANUAL 

3: Allows you to customize the width and height of the video image captured by the local camera.

   @since v3.3.1

◆ CHANNEL_MEDIA_RELAY_ERROR

The definition of CHANNEL_MEDIA_RELAY_ERROR.

Enumerator
RELAY_OK 

0: The state is normal.

RELAY_ERROR_SERVER_ERROR_RESPONSE 

1: An error occurs in the server response.

RELAY_ERROR_SERVER_NO_RESPONSE 

2: No server response. You can call the LeaveChannel method to leave the channel.

This error can also occur if your project has not enabled co-host token authentication. Contact suppo.nosp@m.rt@a.nosp@m.gora..nosp@m.io to enable the co-host token authentication service before starting a channel media relay.

RELAY_ERROR_NO_RESOURCE_AVAILABLE 

3: The SDK fails to access the service, probably due to limited resources of the server.

RELAY_ERROR_FAILED_JOIN_SRC 

4: Fails to send the relay request.

RELAY_ERROR_FAILED_JOIN_DEST 

5: Fails to accept the relay request.

RELAY_ERROR_FAILED_PACKET_RECEIVED_FROM_SRC 

6: The server fails to receive the media stream.

RELAY_ERROR_FAILED_PACKET_SENT_TO_DEST 

7: The server fails to send the media stream.

RELAY_ERROR_SERVER_CONNECTION_LOST 

8: The SDK disconnects from the server due to poor network connections. You can call the LeaveChannel method to leave the channel.

RELAY_ERROR_INTERNAL_ERROR 

9: An internal error occurs in the server.

RELAY_ERROR_SRC_TOKEN_EXPIRED 

10: The token of the source channel has expired.

RELAY_ERROR_DEST_TOKEN_EXPIRED 

11: The token of the destination channel has expired.

◆ CHANNEL_MEDIA_RELAY_EVENT

The event code in CHANNEL_MEDIA_RELAY_EVENT.

Enumerator
RELAY_EVENT_NETWORK_DISCONNECTED 

0: The user disconnects from the server due to poor network connections.

RELAY_EVENT_NETWORK_CONNECTED 

1: The network reconnects.

RELAY_EVENT_PACKET_JOINED_SRC_CHANNEL 

2: The user joins the source channel.

RELAY_EVENT_PACKET_JOINED_DEST_CHANNEL 

3: The user joins the destination channel.

RELAY_EVENT_PACKET_SENT_TO_DEST_CHANNEL 

4: The SDK starts relaying the media stream to the destination channel.

RELAY_EVENT_PACKET_RECEIVED_VIDEO_FROM_SRC 

5: The server receives the video stream from the source channel.

RELAY_EVENT_PACKET_RECEIVED_AUDIO_FROM_SRC 

6: The server receives the audio stream from the source channel.

RELAY_EVENT_PACKET_UPDATE_DEST_CHANNEL 

7: The destination channel is updated.

RELAY_EVENT_PACKET_UPDATE_DEST_CHANNEL_REFUSED 

8: The destination channel update fails due to internal reasons.

RELAY_EVENT_PACKET_UPDATE_DEST_CHANNEL_NOT_CHANGE 

9: The destination channel does not change, which means that the destination channel fails to be updated.

RELAY_EVENT_PACKET_UPDATE_DEST_CHANNEL_IS_NULL 

10: The destination channel name is null.

RELAY_EVENT_VIDEO_PROFILE_UPDATE 

11: The video profile is sent to the server.

RELAY_EVENT_PAUSE_SEND_PACKET_TO_DEST_CHANNEL_SUCCESS 

12: The SDK successfully pauses relaying the media stream to destination channels.

Since
v3.6.1.1
RELAY_EVENT_PAUSE_SEND_PACKET_TO_DEST_CHANNEL_FAILED 

13: The SDK fails to pause relaying the media stream to destination channels.

Since
v3.6.1.1
RELAY_EVENT_RESUME_SEND_PACKET_TO_DEST_CHANNEL_SUCCESS 

14: The SDK successfully resumes relaying the media stream to destination channels.

Since
v3.6.1.1
RELAY_EVENT_RESUME_SEND_PACKET_TO_DEST_CHANNEL_FAILED 

15: The SDK fails to resume relaying the media stream to destination channels.

Since
v3.6.1.1

◆ CHANNEL_MEDIA_RELAY_STATE

The state code in CHANNEL_MEDIA_RELAY_STATE.

Enumerator
RELAY_STATE_IDLE 

0: The initial state. After you successfully stop the channel media relay by calling StopChannelMediaRelay, the OnChannelMediaRelayStateChangedHandler callback returns this state.

RELAY_STATE_CONNECTING 

1: The SDK tries to relay the media stream to the destination channel.

RELAY_STATE_RUNNING 

2: The SDK successfully relays the media stream to the destination channel.

RELAY_STATE_FAILURE 

3: A failure occurs. See the details in code.

◆ CHANNEL_PROFILE

The channel profile.

Enumerator
CHANNEL_PROFILE_COMMUNICATION 

0: (Default) Communication. This profile applies to scenarios such as an audio call or video call, where all users can publish and subscribe to streams.

CHANNEL_PROFILE_LIVE_BROADCASTING 

1: Live streaming. In this profile, uses have roles, namely, host and audience (default). A host both publishes and subscribes to streams, while an audience subscribes to streams only. This profile applies to scenarios such as a chat room or interactive video streaming.

CHANNEL_PROFILE_GAME 

2: Gaming. This profile uses a codec with a lower bitrate and consumes less power. Applies to the gaming scenario, where all game players can talk freely.

  @note Agora does not recommend using this setting.

◆ CLIENT_ROLE_CHANGE_FAILED_REASON

Reasons for a user role switch failure, reported in OnClientRoleChangeFailedHandler.

Since
v3.7.0
Enumerator
CLIENT_ROLE_CHANGE_FAILED_BY_TOO_MANY_BROADCASTERS 

1: The number of hosts in the channel is already at the upper limit.

Note
This enumerator is reported only when the support for 128 users is enabled. The maximum number of hosts is based on the actual number of hosts configured when you enable the 128-user feature.
CLIENT_ROLE_CHANGE_FAILED_BY_NOT_AUTHORIZED 

2: The request is rejected by the Agora server. Agora recommends you prompt the user to try to switch their user role again.

CLIENT_ROLE_CHANGE_FAILED_BY_REQUEST_TIME_OUT 

3: The request is timed out. Agora recommends you prompt the user to check the network connection and try to switch their user role again.

CLIENT_ROLE_CHANGE_FAILED_BY_CONNECTION_FAILED 

4: The SDK connection fails. You can use reason reported in the onClientRoleChangeFailed callback to troubleshoot the failure.

◆ CLIENT_ROLE_TYPE

The role of a user in interactive live streaming.

Enumerator
CLIENT_ROLE_BROADCASTER 

1: Host. A host can both send and receive streams.

CLIENT_ROLE_AUDIENCE 

2: (Default) Audience, the default role. An audience member can only receive streams.

◆ CLOUD_PROXY_TYPE

The cloud proxy type.

Since
v3.3.0
Enumerator
NONE_PROXY 

0: Do not use the cloud proxy.

UDP_PROXY 

1: The cloud proxy for the UDP protocol.

◆ CODEC_AUDIO

Enumerator
CODEC_AUDIO_PCM 

0: PCM audio codec.

CODEC_AUDIO_AAC 

1: aac audio codec.

CODEC_AUDIO_G722 

2: G711 audio codec.

◆ CODEC_VIDEO

Enumerator
CODEC_VIDEO_AVC 

0: h264 avc codec.

CODEC_VIDEO_HEVC 

1: h265 hevc codec.

CODEC_VIDEO_VP8 

2: vp8 codec.

◆ CONNECTION_CHANGED_REASON_TYPE

Reasons for a connection state change.

Enumerator
CONNECTION_CHANGED_CONNECTING 

0: The SDK is connecting to Agora's edge server.

CONNECTION_CHANGED_JOIN_SUCCESS 

1: The SDK has joined the channel successfully.

CONNECTION_CHANGED_INTERRUPTED 

2: The connection between the SDK and Agora's edge server is interrupted.

CONNECTION_CHANGED_BANNED_BY_SERVER 

3: The user is banned by the server. This error occurs when the user is kicked out the channel from the server.

CONNECTION_CHANGED_JOIN_FAILED 

4: The SDK fails to join the channel for more than 20 minutes and stops reconnecting to the channel.

CONNECTION_CHANGED_LEAVE_CHANNEL 

5: The SDK has left the channel.

CONNECTION_CHANGED_INVALID_APP_ID 

6: The connection failed since Appid is not valid.

CONNECTION_CHANGED_INVALID_CHANNEL_NAME 

7: The connection failed since channel name is not valid.

CONNECTION_CHANGED_INVALID_TOKEN 

8: The connection failed since token is not valid, possibly because:

  • The App Certificate for the project is enabled in Dashboard, but you do not use Token when joining the channel. If you enable the App Certificate, you must use a token to join the channel.
  • The uid that you specify in the JoinChannelByKey method is different from the uid that you pass for generating the token.
CONNECTION_CHANGED_TOKEN_EXPIRED 

9: The connection failed since token is expired.

CONNECTION_CHANGED_REJECTED_BY_SERVER 

10: The connection is rejected by server. This error usually occurs in the following situations:

  • When the user is already in the channel, and still calls the method to join the channel, for example, JoinChannelByKey.
  • When the user tries to join a channel during StartEchoTest. Once you call StartEchoTest, you need to call StopEchoTest before joining a channel.
CONNECTION_CHANGED_SETTING_PROXY_SERVER 

11: The connection changed to reconnecting since SDK has set a proxy server.

CONNECTION_CHANGED_RENEW_TOKEN 

12: When SDK is in connection failed, the renew token operation will make it connecting.

CONNECTION_CHANGED_CLIENT_IP_ADDRESS_CHANGED 

13: The IP Address of SDK client has changed. i.e., Network type or IP/Port changed by network operator might change client IP address.

CONNECTION_CHANGED_KEEP_ALIVE_TIMEOUT 

14: Timeout for the keep-alive of the connection between the SDK and Agora's edge server. The connection state changes to CONNECTION_STATE_RECONNECTING(4).

CONNECTION_CHANGED_SAME_UID_LOGIN 

19: Join the same channel from different devices using the same user ID.

CONNECTION_CHANGED_TOO_MANY_BROADCASTERS 

20: The number of hosts in the channel is already at the upper limit.

Note
This enumerator is reported only when the support for 128 users is enabled. The maximum number of hosts is based on the actual number of hosts configured when you enable the 128-user feature.

◆ CONNECTION_STATE_TYPE

Connection states.

Enumerator
CONNECTION_STATE_DISCONNECTED 

1: The SDK is disconnected from Agora's edge server.

  • This is the initial state before calling the JoinChannelByKey method.
  • The SDK also enters this state when the application calls the LeaveChannel method.
CONNECTION_STATE_CONNECTING 

2: The SDK is connecting to Agora's edge server.

  • When the application calls the JoinChannelByKey method, the SDK starts to establish a connection to the specified channel, triggers the OnConnectionStateChangedHandler callback, and switches to the CONNECTION_STATE_CONNECTING(2) state.
  • When the SDK successfully joins the channel, it triggers the OnConnectionStateChangedHandler callback and switches to the CONNECTION_STATE_CONNECTED(3) state.
  • After the SDK joins the channel and when it finishes initializing the media engine, the SDK triggers the OnJoinChannelSuccessHandler callback.
CONNECTION_STATE_CONNECTED 

3: The SDK is connected to Agora's edge server and has joined a channel. You can now publish or subscribe to a media stream in the channel. If the connection to the channel is lost because, for example, if the network is down or switched, the SDK automatically tries to reconnect and triggers:

CONNECTION_STATE_RECONNECTING 

4: The SDK keeps rejoining the channel after being disconnected from a joined channel because of network issues.

  • If the SDK cannot rejoin the channel within 10 seconds after being disconnected from Agora's edge server, the SDK triggers the OnConnectionLostHandler callback, stays in the CONNECTION_STATE_RECONNECTING(4) state, and keeps rejoining the channel.
  • If the SDK fails to rejoin the channel 20 minutes after being disconnected from Agora's edge server, the SDK triggers the OnConnectionStateChangedHandler callback, switches to the CONNECTION_STATE_FAILED(5) state, and stops rejoining the channel.
CONNECTION_STATE_FAILED 

5: The SDK fails to connect to Agora's edge server or join the channel. You must call the LeaveChannel method to leave this state, and call the JoinChannelByKey method again to rejoin the channel. If the SDK is banned from joining the channel by Agora's edge server (through the RESTful API), the SDK triggers the OnConnectionBannedHandler (deprecated) and OnConnectionStateChangedHandler callbacks.

◆ DEGRADATION_PREFERENCE

Video degradation preferences when the bandwidth is a constraint.

Enumerator
MAINTAIN_QUALITY 

0: (Default) Degrade the frame rate in order to maintain the video quality.

MAINTAIN_FRAMERATE 

1: Degrade the video quality in order to maintain the frame rate.

MAINTAIN_BALANCED 

2: (For future use) Maintain a balance between the frame rate and video quality.

◆ ENCRYPTION_MODE

Encryption mode.

Enumerator
AES_128_XTS 

1: (Default) 128-bit AES encryption, XTS mode.

AES_128_ECB 

2: 128-bit AES encryption, ECB mode.

AES_256_XTS 

3: 256-bit AES encryption, XTS mode.

SM4_128_ECB 

4: 128-bit SM4 encryption, ECB mode.

AES_128_GCM 

5: 128-bit AES encryption, GCM mode.

   @since v3.3.1
AES_256_GCM 

6: 256-bit AES encryption, GCM mode.

   @since v3.3.1
AES_128_GCM2 

7: (Default) 128-bit AES encryption, GCM mode, with custom KDF salt.

  @since v3.4.5
AES_256_GCM2 

8: 256-bit AES encryption, GCM mode, with custom KDF salt.

  @since v3.4.5
MODE_END 

Enumerator boundary.

◆ ERROR_CODE

Error code, see more in Error Code.

Enumerator
ERROR_NOT_INIT_ENGINE 

-7: The SDK is not initialized before calling this method.

ERROR_OK 

0: No error occurs.

ERROR_INVALID_ARGUMENT 

-2: An invalid parameter is used. For example, the specific channel name includes illegal characters.

ERROR_NO_DEVICE_PLUGIN 

-100: No device is plugged.

◆ EXCLUDE_WINDOW_ERROR

The error code of the window blocking during screen sharing.

Since
v3.6.1.1
Enumerator
EXCLUDE_WINDOW_FAIL 

-1: Fails to block the window during screen sharing. The user's graphics card does not support window blocking.

EXCLUDE_WINDOW_NONE 

0: Reserved.

◆ EXPERIENCE_POOR_REASON

The reason for poor QoE of the local user when receiving a remote audio stream.

Since
v3.3.1
Enumerator
EXPERIENCE_REASON_NONE 

0: No reason, indicating good QoE of the local user.

REMOTE_NETWORK_QUALITY_POOR 

1: The remote user's network quality is poor.

LOCAL_NETWORK_QUALITY_POOR 

2: The local user's network quality is poor.

WIRELESS_SIGNAL_POOR 

4: The local user's Wi-Fi or mobile network signal is weak.

WIFI_BLUETOOTH_COEXIST 

8: The local user enables both Wi-Fi and bluetooth, and their signals interfere with each other. As a result, audio transmission quality is undermined.

◆ EXPERIENCE_QUALITY_TYPE

Quality of experience (QoE) of the local user when receiving a remote audio stream.

Since
v3.3.1
Enumerator
EXPERIENCE_QUALITY_GOOD 

0: QoE of the local user is good.

EXPERIENCE_QUALITY_BAD 

1: QoE of the local user is poor.

◆ FRAME_RATE

Video frame rates.

Enumerator
FRAME_RATE_FPS_1 

1: 1 fps

FRAME_RATE_FPS_7 

7: 7 fps

FRAME_RATE_FPS_10 

10: 10 fps

FRAME_RATE_FPS_15 

15: 15 fps

FRAME_RATE_FPS_24 

24: 24 fps

FRAME_RATE_FPS_30 

30: 30 fps

FRAME_RATE_FPS_60 

60: 60 fps (Windows and macOS only)

◆ LASTMILE_PROBE_RESULT_STATE

States of the last-mile network probe test.

Enumerator
LASTMILE_PROBE_RESULT_COMPLETE 

1: The last-mile network probe test is complete.

LASTMILE_PROBE_RESULT_INCOMPLETE_NO_BWE 

2: The last-mile network probe test is incomplete and the bandwidth estimation is not available, probably due to limited test resources.

LASTMILE_PROBE_RESULT_UNAVAILABLE 

3: The last-mile network probe test is not carried out, probably due to poor network conditions.

◆ LOCAL_AUDIO_STREAM_ERROR

Local audio state error codes.

Enumerator
LOCAL_AUDIO_STREAM_ERROR_OK 

0: The local audio is normal.

LOCAL_AUDIO_STREAM_ERROR_FAILURE 

1: No specified reason for the local audio failure.

LOCAL_AUDIO_STREAM_ERROR_DEVICE_NO_PERMISSION 

2: No permission to use the local audio device.

LOCAL_AUDIO_STREAM_ERROR_DEVICE_BUSY 

3: The microphone is in use.

LOCAL_AUDIO_STREAM_ERROR_RECORD_FAILURE 

4: The local audio capturing fails. Check whether the capturing device is working properly.

LOCAL_AUDIO_STREAM_ERROR_ENCODE_FAILURE 

5: The local audio encoding fails.

LOCAL_AUDIO_STREAM_ERROR_NO_RECORDING_DEVICE 

6: No recording audio device.

LOCAL_AUDIO_STREAM_ERROR_NO_PLAYOUT_DEVICE 

7: No playout audio device.

LOCAL_AUDIO_STREAM_ERROR_INTERRUPTED 

8: The local audio capturing is interrupted by the system call.

LOCAL_AUDIO_STREAM_ERROR_RECORD_INVALID_ID 

9: An invalid audio capture device ID.

Since
v3.6.1.1
LOCAL_AUDIO_STREAM_ERROR_PLAYOUT_INVALID_ID 

10: An invalid audio playback device ID.

Since
v3.6.1.1

◆ LOCAL_AUDIO_STREAM_STATE

Local audio state types.

Enumerator
LOCAL_AUDIO_STREAM_STATE_STOPPED 

0: The local audio is in the initial state.

LOCAL_AUDIO_STREAM_STATE_RECORDING 

1: The capturing device starts successfully.

LOCAL_AUDIO_STREAM_STATE_ENCODING 

2: The first audio frame encodes successfully.

LOCAL_AUDIO_STREAM_STATE_FAILED 

3: The local audio fails to start.

◆ LOCAL_VIDEO_STREAM_ERROR

Local video state error codes

Enumerator
LOCAL_VIDEO_STREAM_ERROR_OK 

0: The local video is normal.

LOCAL_VIDEO_STREAM_ERROR_FAILURE 

1: No specified reason for the local video failure.

LOCAL_VIDEO_STREAM_ERROR_DEVICE_NO_PERMISSION 

2: No permission to use the local video capturing device.

LOCAL_VIDEO_STREAM_ERROR_DEVICE_BUSY 

3: The local video capturing device is in use.

LOCAL_VIDEO_STREAM_ERROR_CAPTURE_FAILURE 

4: The local video capture fails. Check whether the capturing device is working properly.

LOCAL_VIDEO_STREAM_ERROR_ENCODE_FAILURE 

5: The local video encoding fails.

LOCAL_VIDEO_STREAM_ERROR_CAPTURE_INBACKGROUND 

6: (iOS only) The application is in the background.

  @since v3.3.0
LOCAL_VIDEO_STREAM_ERROR_CAPTURE_MULTIPLE_FOREGROUND_APPS 

7: (iOS only) The application is running in Slide Over, Split View, or Picture in Picture mode.

  @since v3.3.0
LOCAL_VIDEO_STREAM_ERROR_DEVICE_NOT_FOUND 

8:capture not found

LOCAL_VIDEO_STREAM_ERROR_DEVICE_DISCONNECTED 

9: (macOS only) The external camera currently in use is disconnected (such as being unplugged).

Since
v3.5.0
LOCAL_VIDEO_STREAM_ERROR_DEVICE_INVALID_ID 

10: (macOS and Windows only) The SDK cannot find the video device in the video device list. Check whether the ID of the video device is valid.

Since
v3.6.1.1
LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_MINIMIZED 

11: The shared window is minimized when you call StartScreenCaptureByWindowId to share a window.

LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_CLOSED 

12: The error code indicates that a window shared by the window ID has been closed, or a full-screen window shared by the window ID has exited full-screen mode. After exiting full-screen mode, remote users cannot see the shared window. To prevent remote users from seeing a black screen, Agora recommends that you immediately stop screen sharing.

Common scenarios for reporting this error code:

  • When the local user closes the shared window, the SDK reports this error code.
  • The local user shows some slides in full-screen mode first, and then shares the windows of the slides. After the user exits full-screen mode, the SDK reports this error code.
  • The local user watches web video or reads web document in full-screen mode first, and then shares the window of the web video or document. After the user exits full-screen mode, the SDK reports this error code.
LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_OCCLUDED 

13: (Windows only) The window being shared is overlapped by another window, so the overlapped area is blacked out by the SDK during window sharing.

Since
v3.6.1.1
LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_NOT_SUPPORTED 

20: (Windows only) The SDK does not support sharing this type of window.

Since
v3.6.1.1

◆ LOCAL_VIDEO_STREAM_STATE

Local video state types.

Enumerator
LOCAL_VIDEO_STREAM_STATE_STOPPED 

0: Initial state.

LOCAL_VIDEO_STREAM_STATE_CAPTURING 

1: The local video capturing device starts successfully. The SDK also reports this state when you share a maximized window by calling StartScreenCaptureByWindowId.

LOCAL_VIDEO_STREAM_STATE_ENCODING 

2: The first video frame is successfully encoded.

LOCAL_VIDEO_STREAM_STATE_FAILED 

3: The local video fails to start.

◆ LOG_FILTER

Output log filter level.

Enumerator
OFF 

0: Do not output any log information.

DEBUG 

0x80f: Output all log information. Set your log filter as debug if you want to get the most complete log file.

INFO 

0x0f: Output CRITICAL, ERROR, WARNING, and INFO level log information. We recommend setting your log filter as this level.

WARNING 

0x0e: Outputs CRITICAL, ERROR, and WARNING level log information.

ERROR 

0x0c: Outputs CRITICAL and ERROR level log information.

CRITICAL 

0x08: Outputs CRITICAL level log information.

◆ LOG_LEVEL

The output log level of the SDK.

Since
v3.3.1
Enumerator
LOG_LEVEL_NONE 

0: Do not output any log.

LOG_LEVEL_INFO 

0x0001: (Default) Output logs of the FATAL, ERROR, WARN and INFO level. We recommend setting your log filter as this level.

LOG_LEVEL_WARN 

0x0002: Output logs of the FATAL, ERROR and WARN level.

LOG_LEVEL_ERROR 

0x0004: Output logs of the FATAL and ERROR level.

LOG_LEVEL_FATAL 

0x0008: Output logs of the FATAL level.

◆ LOW_LIGHT_ENHANCE_LEVEL

The low-light enhancement level.

Enumerator
LOW_LIGHT_ENHANCE_LEVEL_HIGH_QUALITY 

0: (Default) Promotes video quality during low-light enhancement. It processes the brightness, details, and noise of the video image. The performance consumption is moderate, the processing speed is moderate, and the overall video quality is optimal.

LOW_LIGHT_ENHANCE_LEVEL_FAST 

Promotes performance during low-light enhancement. It processes the brightness and details of the video image. The processing speed is faster.

◆ LOW_LIGHT_ENHANCE_MODE

The low-light enhancement mode.

Enumerator
LOW_LIGHT_ENHANCE_AUTO 

0: (Default) Automatic mode. The SDK automatically enables or disables the low-light enhancement feature according to the ambient light to compensate for the lighting level or prevent overexposure, as necessary.

LOW_LIGHT_ENHANCE_MANUAL 

Manual mode. Users need to enable or disable the low-light enhancement feature manually.

◆ MEDIA_DEVICE_STATE_TYPE

Media device states.

Enumerator
MEDIA_DEVICE_STATE_IDLE 

0: The device is idle.

MEDIA_DEVICE_STATE_ACTIVE 

1: The device is active.

MEDIA_DEVICE_STATE_DISABLED 

2: The device is disabled.

MEDIA_DEVICE_STATE_NOT_PRESENT 

4: The device is not present.

MEDIA_DEVICE_STATE_UNPLUGGED 

8: The device is unplugged.

MEDIA_DEVICE_STATE_UNRECOMMENDED 

16: The device is not recommended.

◆ MEDIA_DEVICE_TYPE

Media device types.

Enumerator
UNKNOWN_AUDIO_DEVICE 

-1: Unknown device type.

AUDIO_PLAYOUT_DEVICE 

0: Audio playback device.

AUDIO_RECORDING_DEVICE 

1: Audio capturing device.

VIDEO_RENDER_DEVICE 

2: Video renderer.

VIDEO_CAPTURE_DEVICE 

3: Video capturer.

AUDIO_APPLICATION_PLAYOUT_DEVICE 

4: Application audio playback device.

◆ MEDIA_SOURCE_TYPE

Deprecated:
Type of audio device.
Enumerator
AUDIO_PLAYOUT_SOURCE 

0: Audio playback device.

AUDIO_RECORDING_SOURCE 

1: Microphone.

◆ MediaRecorderContainerFormat

The format of the recording file.

Since
v3.6.1.1
Enumerator
FORMAT_MP4 

(Default) MP4.

FORMAT_FLV 

Reserved parameter.

◆ MediaRecorderStreamType

The recording content.

Since
v3.6.1.1
Enumerator
STREAM_TYPE_AUDIO 

Only audio.

STREAM_TYPE_VIDEO 

Only video.

STREAM_TYPE_BOTH 

(Default) Audio and video.

◆ METADATA_TYPE

Metadata type of the observer.

Note
We only support video metadata for now.
Enumerator
UNKNOWN_METADATA 

-1: The metadata type is unknown.

VIDEO_METADATA 

0: The metadata type is video.

◆ NETWORK_TYPE

Network type.

Enumerator
NETWORK_TYPE_UNKNOWN 

-1: The network type is unknown.

NETWORK_TYPE_DISCONNECTED 

0: The SDK disconnects from the network.

NETWORK_TYPE_LAN 

1: The network type is LAN.

NETWORK_TYPE_WIFI 

2: The network type is Wi-Fi.

NETWORK_TYPE_MOBILE_2G 

3: The network type is mobile 2G.

NETWORK_TYPE_MOBILE_3G 

4: The network type is mobile 3G.

NETWORK_TYPE_MOBILE_4G 

5: The network type is mobile 4G.

NETWORK_TYPE_MOBILE_5G 

6: The network type is mobile 5G.

Since
v3.6.1.1

◆ ORIENTATION_MODE

Video output orientation modes.

Enumerator
ORIENTATION_MODE_ADAPTIVE 

0: (Default) Adaptive mode. The video encoder adapts to the orientation mode of the video input device.

  • If the width of the captured video from the SDK is greater than the height, the encoder sends the video in landscape mode. The encoder also sends the rotational information of the video, and the receiver uses the rotational information to rotate the received video.
  • When you use a custom video source, the output video from the encoder inherits the orientation of the original video. If the original video is in portrait mode, the output video from the encoder is also in portrait mode. The encoder also sends the rotational information of the video to the receiver.
ORIENTATION_MODE_FIXED_LANDSCAPE 

1: Landscape mode. The video encoder always sends the video in landscape mode. The video encoder rotates the original video before sending it and the rotational infomation is 0. This mode applies to scenarios involving CDN live streaming.

ORIENTATION_MODE_FIXED_PORTRAIT 

2: Portrait mode. The video encoder always sends the video in portrait mode. The video encoder rotates the original video before sending it and the rotational infomation is 0. This mode applies to scenarios involving CDN live streaming.

◆ PRIORITY_TYPE

The priority of the remote user.

Enumerator
PRIORITY_HIGH 

50: The user's priority is high.

PRIORITY_NORMAL 

100: (Default) The user's priority is normal.

◆ PROXY_TYPE

The proxy type.

Since
3.6.2
Enumerator
NONE_PROXY_TYPE 

0: Reserved for future use.

UDP_PROXY_TYPE 

1: The cloud proxy for the UDP protocol, that is, the Force UDP cloud proxy mode. In this mode, the SDK always transmits data over UDP.

TCP_PROXY_TYPE 

2: The cloud proxy for the TCP (encryption) protocol, that is, the Force TCP cloud proxy mode. In this mode, the SDK always transmits data over TLS 443.

LOCAL_PROXY_TYPE 

3: Reserved for future use.

TCP_PROXY_AUTO_FALLBACK_TYPE 

4: The automatic mode. In this mode, the SDK attempts a direct connection to SD-RTN™ and automatically switches to TLS 443 if the attempt fails.

◆ QUALITY_ADAPT_INDICATION

Quality change of the local video in terms of target frame rate and target bit rate since last count.

Enumerator
ADAPT_NONE 

The quality of the local video stays the same.

ADAPT_UP_BANDWIDTH 

The quality improves because the network bandwidth increases.

ADAPT_DOWN_BANDWIDTH 

The quality worsens because the network bandwidth decreases.

◆ QUALITY_TYPE

Network quality types.

Enumerator
QUALITY_UNKNOWN 

0: The network quality is unknown.

QUALITY_EXCELLENT 

1: The network quality is excellent.

QUALITY_GOOD 

2: The network quality is quite good, but the bitrate may be slightly lower than excellent.

QUALITY_POOR 

3: Users can feel the communication slightly impaired.

QUALITY_BAD 

4: Users cannot communicate smoothly.

QUALITY_VBAD 

5: The network is so bad that users can barely communicate.

QUALITY_DOWN 

6: The network is down and users cannot communicate at all.

QUALITY_UNSUPPORTED 

7: Users cannot detect the network quality. (Not in use.)

QUALITY_DETECTING 

8: Detecting the network quality.

◆ RAW_AUDIO_FRAME_OP_MODE_TYPE

Use modes of the OnRecordAudioFrameHandler and OnPlaybackAudioFrameHandler callbacks.

Enumerator
RAW_AUDIO_FRAME_OP_MODE_READ_ONLY 

0: Read-only mode: Users only read the AudioFrame data without modifying anything. For example, when users acquire the data with the Agora RTC SDK, then push the RTMP or RTMPS streams.

RAW_AUDIO_FRAME_OP_MODE_WRITE_ONLY 

1: Write-only mode: Users replace the AudioFrame data with their own data and pass the data to the SDK for encoding. For example, when users acquire the data.

RAW_AUDIO_FRAME_OP_MODE_READ_WRITE 

2: Read and write mode: Users read the data from AudioFrame, modify it, and then play it. For example, when users have their own sound-effect processing module and perform some voice pre-processing, such as a voice change.

◆ RecorderErrorCode

The reason for the state change.

Since
v3.6.1.1
Enumerator
RECORDER_ERROR_NONE 

No error occurs.

RECORDER_ERROR_WRITE_FAILED 

The SDK fails to write the recorded data to a file.

RECORDER_ERROR_NO_STREAM 

The SDK does not detect audio and video streams to be recorded, or audio and video streams are interrupted for more than five seconds during recording.

RECORDER_ERROR_OVER_MAX_DURATION 

The recording duration exceeds the upper limit.

RECORDER_ERROR_CONFIG_CHANGED 

The recording configuration changes.

RECORDER_ERROR_CUSTOM_STREAM_DETECTED 

The SDK detects audio and video streams from users using versions of the SDK earlier than v3.0.1 in the COMMUNICATION channel profile.

◆ RecorderState

The current recording state.

Since
v3.6.1.1
Enumerator
RECORDER_STATE_ERROR 

An error occurs during the recording. See RecorderErrorCode for the reason.

RECORDER_STATE_START 

The audio and video recording is started.

RECORDER_STATE_STOP 

The audio and video recording is stopped.

◆ REMOTE_AUDIO_STATE

Remote audio states.

Enumerator
REMOTE_AUDIO_STATE_STOPPED 

0: The remote audio is in the default state, probably due to REMOTE_AUDIO_REASON_LOCAL_MUTED(3), REMOTE_AUDIO_REASON_REMOTE_MUTED(5), or REMOTE_AUDIO_REASON_REMOTE_OFFLINE(7).

REMOTE_AUDIO_STATE_STARTING 

1: The first remote audio packet is received.

REMOTE_AUDIO_STATE_DECODING 

2: The remote audio stream is decoded and plays normally, probably due to REMOTE_AUDIO_REASON_NETWORK_RECOVERY(2), REMOTE_AUDIO_REASON_LOCAL_UNMUTED(4), or REMOTE_AUDIO_REASON_REMOTE_UNMUTED(6)`.

REMOTE_AUDIO_STATE_FROZEN 

3: The remote audio is frozen, probably due to REMOTE_AUDIO_REASON_NETWORK_CONGESTION(1).

REMOTE_AUDIO_STATE_FAILED 

4: The remote audio fails to start, probably due to REMOTE_AUDIO_REASON_INTERNAL(0).

◆ REMOTE_AUDIO_STATE_REASON

Remote audio state reasons.

Enumerator
REMOTE_AUDIO_REASON_INTERNAL 

0: The SDK reports this reason when the audio state changes.

REMOTE_AUDIO_REASON_NETWORK_CONGESTION 

1: Network congestion.

REMOTE_AUDIO_REASON_NETWORK_RECOVERY 

2: Network recovery.

REMOTE_AUDIO_REASON_LOCAL_MUTED 

3: The local user stops receiving the remote audio stream or disables the audio module.

REMOTE_AUDIO_REASON_LOCAL_UNMUTED 

4: The local user resumes receiving the remote audio stream or enables the audio module.

REMOTE_AUDIO_REASON_REMOTE_MUTED 

5: The remote user stops sending the audio stream or disables the audio module.

REMOTE_AUDIO_REASON_REMOTE_UNMUTED 

6: The remote user resumes sending the audio stream or enables the audio module.

REMOTE_AUDIO_REASON_REMOTE_OFFLINE 

7: The remote user leaves the channel.

◆ REMOTE_VIDEO_STATE

The state of the remote video.

Enumerator
REMOTE_VIDEO_STATE_STOPPED 

0: The remote video is in the default state, probably due to REMOTE_VIDEO_STATE_REASON_LOCAL_MUTED(3), REMOTE_VIDEO_STATE_REASON_REMOTE_MUTED(5), or REMOTE_VIDEO_STATE_REASON_REMOTE_OFFLINE(7).

REMOTE_VIDEO_STATE_STARTING 

1: The first remote video packet is received.

REMOTE_VIDEO_STATE_DECODING 

2: The remote video stream is decoded and plays normally, probably due to REMOTE_VIDEO_STATE_REASON_NETWORK_RECOVERY(2), REMOTE_VIDEO_STATE_REASON_LOCAL_UNMUTED(4), REMOTE_VIDEO_STATE_REASON_REMOTE_UNMUTED(6), or REMOTE_VIDEO_STATE_REASON_AUDIO_FALLBACK_RECOVERY(9).

REMOTE_VIDEO_STATE_FROZEN 

3: The remote video is frozen, probably due to REMOTE_VIDEO_STATE_REASON_NETWORK_CONGESTION(1) or REMOTE_VIDEO_STATE_REASON_AUDIO_FALLBACK(8).

REMOTE_VIDEO_STATE_FAILED 

4: The remote video fails to start, probably due to REMOTE_VIDEO_STATE_REASON_INTERNAL(0).

◆ REMOTE_VIDEO_STATE_REASON

The reason of the remote video state change.

Enumerator
REMOTE_VIDEO_STATE_REASON_INTERNAL 

0: The SDK reports this reason when the video state changes.

REMOTE_VIDEO_STATE_REASON_NETWORK_CONGESTION 

1: Network congestion.

REMOTE_VIDEO_STATE_REASON_NETWORK_RECOVERY 

2: Network recovery.

REMOTE_VIDEO_STATE_REASON_LOCAL_MUTED 

3: The local user stops receiving the remote video stream or disables the video module.

REMOTE_VIDEO_STATE_REASON_LOCAL_UNMUTED 

4: The local user resumes receiving the remote video stream or enables the video module.

REMOTE_VIDEO_STATE_REASON_REMOTE_MUTED 

5: The remote user stops sending the video stream or disables the video module.

REMOTE_VIDEO_STATE_REASON_REMOTE_UNMUTED 

6: The remote user resumes sending the video stream or enables the video module.

REMOTE_VIDEO_STATE_REASON_REMOTE_OFFLINE 

7: The remote user leaves the channel.

REMOTE_VIDEO_STATE_REASON_AUDIO_FALLBACK 

8: The remote audio-and-video stream falls back to the audio-only stream due to poor network conditions.

REMOTE_VIDEO_STATE_REASON_AUDIO_FALLBACK_RECOVERY 

9: The remote audio-only stream switches back to the video stream after the network conditions improve.

REMOTE_VIDEO_STATE_REASON_SDK_IN_BACKGROUND 

10: The remote user sdk(only for iOS) in background.

◆ REMOTE_VIDEO_STREAM_TYPE

Remote video stream types.

Enumerator
REMOTE_VIDEO_STREAM_HIGH 

0: High-stream video.

REMOTE_VIDEO_STREAM_LOW 

1: Low-stream video.

◆ RENDER_MODE_TYPE

Video display modes.

Enumerator
RENDER_MODE_HIDDEN 

1: Uniformly scale the video until it fills the visible boundaries (cropped). One dimension of the video may have clipped contents.

RENDER_MODE_FIT 

2: Uniformly scale the video until one of its dimension fits the boundary (zoomed to fit). Areas that are not filled due to disparity in the aspect ratio are filled with black.

RENDER_MODE_ADAPTIVE 
Deprecated:
3: This mode is deprecated.

◆ RTMP_STREAM_PUBLISH_ERROR_TYPE

Error codes of the RTMP or RTMPS streaming.

Enumerator
RTMP_STREAM_PUBLISH_ERROR_OK 

The RTMP or RTMPS streaming publishes successfully.

RTMP_STREAM_PUBLISH_ERROR_INVALID_ARGUMENT 

Invalid argument used. If, for example, you do not call the SetLiveTranscoding method to configure the LiveTranscoding parameters before calling the addPublishStreamUrl method, the SDK returns this error. Check whether you set the parameters in the setLiveTranscoding method properly.

RTMP_STREAM_PUBLISH_ERROR_ENCRYPTED_STREAM_NOT_ALLOWED 

The RTMP or RTMPS streaming is encrypted and cannot be published.

RTMP_STREAM_PUBLISH_ERROR_CONNECTION_TIMEOUT 

Timeout for the RTMP or RTMPS streaming. Call the AddPublishStreamUrl method to publish the streaming again.

RTMP_STREAM_PUBLISH_ERROR_INTERNAL_SERVER_ERROR 

An error occurs in Agora's streaming server. Call the AddPublishStreamUrl method to publish the streaming again.

RTMP_STREAM_PUBLISH_ERROR_RTMP_SERVER_ERROR 

An error occurs in the CDN server.

RTMP_STREAM_PUBLISH_ERROR_TOO_OFTEN 

The RTMP or RTMPS streaming publishes too frequently.

RTMP_STREAM_PUBLISH_ERROR_REACH_LIMIT 

The host publishes more than 10 URLs. Delete the unnecessary URLs before adding new ones.

RTMP_STREAM_PUBLISH_ERROR_NOT_AUTHORIZED 

The host manipulates other hosts' URLs. Check your app logic.

RTMP_STREAM_PUBLISH_ERROR_STREAM_NOT_FOUND 

Agora's server fails to find the RTMP or RTMPS streaming.

RTMP_STREAM_PUBLISH_ERROR_FORMAT_NOT_SUPPORTED 

The format of the RTMP or RTMPS streaming URL is not supported. Check whether the URL format is correct.

RTMP_STREAM_PUBLISH_ERROR_NOT_BROADCASTER 

11: The user role is not host, so the user cannot use the CDN live streaming function. Check your application code logic.

Since
v3.6.1.1
RTMP_STREAM_PUBLISH_ERROR_TRANSCODING_NO_MIX_STREAM 

13: UpdateRtmpTranscoding or SetLiveTranscoding method is called to update the transcoding configuration in a scenario where there is streaming without transcoding. Check your application code logic.

Since
v3.6.1.1
RTMP_STREAM_PUBLISH_ERROR_NET_DOWN 

14: Errors occurred in the host's network.

Since
v3.6.1.1
RTMP_STREAM_PUBLISH_ERROR_INVALID_APPID 

15: Your App ID does not have permission to use the CDN live streaming function. Refer to Prerequisites to enable the CDN live streaming permission.

Since
v3.6.1.1
RTMP_STREAM_UNPUBLISH_ERROR_OK 

100: The streaming has been stopped normally. After you call RemovePublishStreamUrl to stop streaming, the SDK returns this value.

Since
v3.4.5

◆ RTMP_STREAM_PUBLISH_STATE

States of the RTMP or RTMPS streaming.

Enumerator
RTMP_STREAM_PUBLISH_STATE_IDLE 

0: The RTMP or RTMPS streaming has not started or has ended.

RTMP_STREAM_PUBLISH_STATE_CONNECTING 

1: The SDK is connecting to Agora's streaming server and the RTMP server. This state is triggered after you call the AddPublishStreamUrl method.

RTMP_STREAM_PUBLISH_STATE_RUNNING 

2: The RTMP or RTMPS streaming publishes. The SDK successfully publishes the RTMP or RTMPS streaming and returns this state.

RTMP_STREAM_PUBLISH_STATE_RECOVERING 

3: The RTMP or RTMPS streaming is recovering. When exceptions occur to the CDN, or the streaming is interrupted, the SDK tries to resume RTMP or RTMPS streaming and returns this state.

  • If the SDK successfully resumes the streaming, RTMP_STREAM_PUBLISH_STATE_RUNNING(2) returns.
  • If the streaming does not resume within 60 seconds or server errors occur, RTMP_STREAM_PUBLISH_STATE_FAILURE(4) returns. You can also reconnect to the server by calling the RemovePublishStreamUrl and AddPublishStreamUrl methods.
RTMP_STREAM_PUBLISH_STATE_FAILURE 

4: The RTMP or RTMPS streaming fails. See the errCode parameter for the detailed error information. You can also call the AddPublishStreamUrl method to publish the RTMP or RTMPS streaming again.

RTMP_STREAM_PUBLISH_STATE_DISCONNECTING 

5: The SDK is disconnecting from the Agora streaming server and CDN. When you call Remove or Stop to stop the streaming normally, the SDK reports the streaming state as DISCONNECTING, IDLE in sequence.

Since
v3.6.1.1

◆ RTMP_STREAMING_EVENT

Events during the RTMP or RTMPS streaming.

Enumerator
RTMP_STREAMING_EVENT_FAILED_LOAD_IMAGE 

An error occurs when you add a background image or a watermark image to the RTMP or RTMPS stream.

RTMP_STREAMING_EVENT_URL_ALREADY_IN_USE 

The chosen URL address is already in use for CDN live streaming.

RTMP_STREAMING_EVENT_ADVANCED_FEATURE_NOT_SUPPORT 

3: The feature is not supported.

Since
v3.6.1.1
RTMP_STREAMING_EVENT_REQUEST_TOO_OFTEN 

4: Reserved.

Since
v3.6.1.1

◆ SCREEN_SCENARIO_TYPE

The screen sharing scenario, set in SetScreenCaptureScenario.

Since
3.7.0
Enumerator
SCREEN_SCENARIO_DOCUMENT 

1: (Default) Document. This scenario prioritizes the video quality of screen sharing and reduces the latency of the shared video for the receiver. If you share documents, slides, and tables, you can set this scenario.

SCREEN_SCENARIO_GAMING 

2: Game. This scenario prioritizes the smoothness of screen sharing. If you share games, you can set this scenario.

SCREEN_SCENARIO_VIDEO 

3: Video. This scenario prioritizes the smoothness of screen sharing. If you share movies or live videos, you can set this scenario.

SCREEN_SCENARIO_RDC 

4: Remote control. This scenario prioritizes the video quality of screen sharing and reduces the latency of the shared video for the receiver. If you share the device desktop being remotely controlled, you can set this scenario.

◆ ScreenCaptureSourceType

The type of the shared target.

Since
v3.5.2
Enumerator
ScreenCaptureSourceType_Unknown 

-1: Unknown type.

ScreenCaptureSourceType_Window 

0: The shared target is a window.

ScreenCaptureSourceType_Screen 

1: The shared target is a screen of a particular monitor.

ScreenCaptureSourceType_Custom 

2: Reserved parameter.

◆ STREAM_FALLBACK_OPTIONS

Stream fallback options.

Enumerator
STREAM_FALLBACK_OPTION_DISABLED 

0: No fallback behavior for the local/remote video stream when the uplink/downlink network conditions are poor. The quality of the stream is not guaranteed.

STREAM_FALLBACK_OPTION_VIDEO_STREAM_LOW 

1: Under poor downlink network conditions, the remote video stream, to which you subscribe, falls back to the low-stream (low resolution and low bitrate) video. You can set this option only in the SetRemoteSubscribeFallbackOption method. Nothing happens when you set this in the SetLocalPublishFallbackOption method.

STREAM_FALLBACK_OPTION_AUDIO_ONLY 

2: Under poor uplink network conditions, the locally published video stream falls back to audio only. Under poor downlink network conditions, the remote video stream, to which you subscribe, first falls back to the low-stream (low resolution and low bitrate) video; and then to an audio-only stream if the network conditions worsen.

◆ STREAM_PUBLISH_STATE

The publishing state.

Enumerator
PUB_STATE_IDLE 

0: The initial publishing state after joining the channel.

PUB_STATE_NO_PUBLISHED 

1: Fails to publish the local stream. Possible reasons:

PUB_STATE_PUBLISHING 

2: Publishing.

PUB_STATE_PUBLISHED 

3: Publishes successfully.

◆ STREAM_SUBSCRIBE_STATE

The subscribing state.

Enumerator
SUB_STATE_IDLE 

0: The initial subscribing state after joining the channel.

SUB_STATE_NO_SUBSCRIBED 

1: Fails to subscribe to the remote stream. Possible reasons:

SUB_STATE_SUBSCRIBING 

2: Subscribing.

SUB_STATE_SUBSCRIBED 

3: Subscribes to and receives the remote stream successfully.

◆ SUPER_RESOLUTION_STATE_REASON

The reason why super resolution is not successfully enabled or the message that confirms success.

Since
v3.6.1.1
Enumerator
SR_STATE_REASON_SUCCESS 

0: Super resolution is successfully enabled.

SR_STATE_REASON_STREAM_OVER_LIMITATION 

1: The original resolution of the remote video is beyond the range where super resolution can be applied.

SR_STATE_REASON_USER_COUNT_OVER_LIMITATION 

2: Super resolution is already being used to boost another remote user's video.

SR_STATE_REASON_DEVICE_NOT_SUPPORTED 

3: The device does not support using super resolution.

◆ USER_OFFLINE_REASON

Reasons for a user being offline.

Enumerator
QUIT 

0: The user quits the call.

DROPPED 

1: The SDK times out and the user drops offline because no data packet is received within a certain period of time. If the user quits the call and the message is not passed to the SDK (due to an unreliable channel), the SDK assumes the user dropped offline.

BECOME_AUDIENCE 

2: (Interactive live streaming only.) The client role switched from the host to the audience.

◆ VIDEO_CODEC_PROFILE_TYPE

Video codec profile types.

Enumerator
VIDEO_CODEC_PROFILE_BASELINE 

66: Baseline video codec profile. Generally used in video calls on mobile phones.

VIDEO_CODEC_PROFILE_MAIN 

77: Main video codec profile. Generally used in mainstream electronics such as MP4 players, portable video players, PSP, and iPads.

VIDEO_CODEC_PROFILE_HIGH 

100: (Default) High video codec profile. Generally used in high-resolution broadcasts or television.

◆ VIDEO_CODEC_TYPE

Video codec types

Enumerator
VIDEO_CODEC_VP8 

1: Standard VP8.

VIDEO_CODEC_H264 

2: Standard H264.

VIDEO_CODEC_EVP 

3: Enhanced VP8.

VIDEO_CODEC_E264 

4: Enhanced H264.

◆ VIDEO_DENOISER_LEVEL

The video noise reduction level.

Enumerator
VIDEO_DENOISER_LEVEL_HIGH_QUALITY 

0: (Default) Promotes video quality during video noise reduction. HIGH_QUALITY balances performance consumption and video noise reduction quality. The performance consumption is moderate, the video noise reduction speed is moderate, and the overall video quality is optimal.

VIDEO_DENOISER_LEVEL_FAST 

Promotes reducing performance consumption during video noise reduction. FAST prioritizes reducing performance consumption over video noise reduction quality. The performance consumption is lower, and the video noise reduction speed is faster. To avoid a noticeable shadowing effect (shadows trailing behind moving objects) in the processed video, Agora recommends that you use FAST when the camera is fixed.

VIDEO_DENOISER_LEVEL_STRENGTH 

Enhanced video noise reduction. STRENGTH prioritizes video noise reduction quality over reducing performance consumption. The performance consumption is higher, the video noise reduction speed is slower, and the video noise reduction quality is better. If HIGH_QUALITY is not enough for your video noise reduction needs, you can use STRENGTH.

◆ VIDEO_DENOISER_MODE

The video noise reduction mode.

Enumerator
VIDEO_DENOISER_AUTO 

0: (Default) Automatic mode. The SDK automatically enables or disables the video noise reduction feature according to the ambient light.

VIDEO_DENOISER_MANUAL 

Manual mode. Users need to enable or disable the video noise reduction feature manually.

◆ VIDEO_FRAME_TYPE

The video frame type.

Enumerator
FRAME_TYPE_YUV420 

0: YUV420.

FRAME_TYPE_RGBA 

1: RGBA.

◆ VIDEO_MIRROR_MODE_TYPE

Video mirror modes.

Enumerator
VIDEO_MIRROR_MODE_AUTO 

0: The default mirror mode is determined by the SDK.

VIDEO_MIRROR_MODE_ENABLED 

1: Enable mirror mode.

VIDEO_MIRROR_MODE_DISABLED 

2: Disable mirror mode.

◆ VIDEO_PROFILE_TYPE

Deprecated:
Video profiles.
Enumerator
VIDEO_PROFILE_LANDSCAPE_120P 

0: 160 × 120, frame rate 15 fps, bitrate 65 Kbps.

VIDEO_PROFILE_LANDSCAPE_120P_3 

2: 120 × 120, frame rate 15 fps, bitrate 50 Kbps.

VIDEO_PROFILE_LANDSCAPE_180P 

10: 320×180, frame rate 15 fps, bitrate 140 Kbps.

VIDEO_PROFILE_LANDSCAPE_180P_3 

12: 180 × 180, frame rate 15 fps, bitrate 100 Kbps.

VIDEO_PROFILE_LANDSCAPE_180P_4 

13: 240 × 180, frame rate 15 fps, bitrate 120 Kbps.

VIDEO_PROFILE_LANDSCAPE_240P 

20: 320 × 240, frame rate 15 fps, bitrate 200 Kbps.

VIDEO_PROFILE_LANDSCAPE_240P_3 

22: 240 × 240, frame rate 15 fps, bitrate 140 Kbps.

VIDEO_PROFILE_LANDSCAPE_240P_4 

23: 424 × 240, frame rate 15 fps, bitrate 220 Kbps.

VIDEO_PROFILE_LANDSCAPE_360P 

30: 640 × 360, frame rate 15 fps, bitrate 400 Kbps.

VIDEO_PROFILE_LANDSCAPE_360P_3 

32: 360 × 360, frame rate 15 fps, bitrate 260 Kbps.

VIDEO_PROFILE_LANDSCAPE_360P_4 

33: 640 × 360, frame rate 30 fps, bitrate 600 Kbps.

VIDEO_PROFILE_LANDSCAPE_360P_6 

35: 360 × 360, frame rate 30 fps, bitrate 400 Kbps.

VIDEO_PROFILE_LANDSCAPE_360P_7 

36: 480 × 360, frame rate 15 fps, bitrate 320 Kbps.

VIDEO_PROFILE_LANDSCAPE_360P_8 

37: 480 × 360, frame rate 30 fps, bitrate 490 Kbps.

VIDEO_PROFILE_LANDSCAPE_360P_9 

38: 640 × 360, frame rate 15 fps, bitrate 800 Kbps.

Note
Interactive live streaming profile only.
VIDEO_PROFILE_LANDSCAPE_360P_10 

39: 640 × 360, frame rate 24 fps, bitrate 800 Kbps.

Note
Interactive live streaming profile only.
VIDEO_PROFILE_LANDSCAPE_360P_11 

100: 640 × 360, frame rate 24 fps, bitrate 1000 Kbps.

Note
Interactive live streaming profile only.
VIDEO_PROFILE_LANDSCAPE_480P 

40: 640 × 480, frame rate 15 fps, bitrate 500 Kbps.

VIDEO_PROFILE_LANDSCAPE_480P_3 

42: 480 × 480, frame rate 15 fps, bitrate 400 Kbps.

VIDEO_PROFILE_LANDSCAPE_480P_4 

43: 640 × 480, frame rate 30 fps, bitrate 750 Kbps.

VIDEO_PROFILE_LANDSCAPE_480P_6 

45: 480 × 480, frame rate 30 fps, bitrate 600 Kbps.

VIDEO_PROFILE_LANDSCAPE_480P_8 

47: 848 × 480, frame rate 15 fps, bitrate 610 Kbps.

VIDEO_PROFILE_LANDSCAPE_480P_9 

48: 848 × 480, frame rate 30 fps, bitrate 930 Kbps.

VIDEO_PROFILE_LANDSCAPE_480P_10 

49: 640 × 480, frame rate 10 fps, bitrate 400 Kbps.

VIDEO_PROFILE_LANDSCAPE_720P 

50: 1280 × 720, frame rate 15 fps, bitrate 1130 Kbps.

VIDEO_PROFILE_LANDSCAPE_720P_3 

52: 1280 × 720, frame rate 30 fps, bitrate 1710 Kbps.

VIDEO_PROFILE_LANDSCAPE_720P_5 

54: 960 × 720, frame rate 15 fps, bitrate 910 Kbps.

VIDEO_PROFILE_LANDSCAPE_720P_6 

55: 960 × 720, frame rate 30 fps, bitrate 1380 Kbps.

VIDEO_PROFILE_LANDSCAPE_1080P 

60: 1920 × 1080, frame rate 15 fps, bitrate 2080 Kbps.

VIDEO_PROFILE_LANDSCAPE_1080P_3 

62: 1920 × 1080, frame rate 30 fps, bitrate 3150 Kbps.

VIDEO_PROFILE_LANDSCAPE_1080P_5 

64: 1920 × 1080, frame rate 60 fps, bitrate 4780 Kbps.

VIDEO_PROFILE_LANDSCAPE_1440P 

66: 2560 × 1440, frame rate 30 fps, bitrate 4850 Kbps.

VIDEO_PROFILE_LANDSCAPE_1440P_2 

67: 2560 × 1440, frame rate 60 fps, bitrate 6500 Kbps.

VIDEO_PROFILE_LANDSCAPE_4K 

70: 3840 × 2160, frame rate 30 fps, bitrate 6500 Kbps.

VIDEO_PROFILE_LANDSCAPE_4K_3 

72: 3840 × 2160, frame rate 60 fps, bitrate 6500 Kbps.

VIDEO_PROFILE_PORTRAIT_120P 

1000: 120 × 160, frame rate 15 fps, bitrate 65 Kbps.

VIDEO_PROFILE_PORTRAIT_120P_3 

1002: 120 × 120, frame rate 15 fps, bitrate 50 Kbps.

VIDEO_PROFILE_PORTRAIT_180P 

1010: 180 × 320, frame rate 15 fps, bitrate 140 Kbps.

VIDEO_PROFILE_PORTRAIT_180P_3 

1012: 180 × 180, frame rate 15 fps, bitrate 100 Kbps.

VIDEO_PROFILE_PORTRAIT_180P_4 

1013: 180 × 240, frame rate 15 fps, bitrate 120 Kbps.

VIDEO_PROFILE_PORTRAIT_240P 

1020: 240 × 320, frame rate 15 fps, bitrate 200 Kbps.

VIDEO_PROFILE_PORTRAIT_240P_3 

1022: 240 × 240, frame rate 15 fps, bitrate 140 Kbps.

VIDEO_PROFILE_PORTRAIT_240P_4 

1023: 240 × 424, frame rate 15 fps, bitrate 220 Kbps.

VIDEO_PROFILE_PORTRAIT_360P 

1030: 360 × 640, frame rate 15 fps, bitrate 400 Kbps.

VIDEO_PROFILE_PORTRAIT_360P_3 

1032: 360 × 360, frame rate 15 fps, bitrate 260 Kbps.

VIDEO_PROFILE_PORTRAIT_360P_4 

1033: 360 × 640, frame rate 30 fps, bitrate 600 Kbps.

VIDEO_PROFILE_PORTRAIT_360P_6 

1035: 360 × 360, frame rate 30 fps, bitrate 400 Kbps.

VIDEO_PROFILE_PORTRAIT_360P_7 

1036: 360 × 480, frame rate 15 fps, bitrate 320 Kbps.

VIDEO_PROFILE_PORTRAIT_360P_8 

1037: 360 × 480, frame rate 30 fps, bitrate 490 Kbps.

VIDEO_PROFILE_PORTRAIT_360P_9 

1038: 360 × 640, frame rate 15 fps, bitrate 800 Kbps.

Note
Interactive live streaming profile only.
VIDEO_PROFILE_PORTRAIT_360P_10 

1039: 360 × 640, frame rate 24 fps, bitrate 800 Kbps.

Note
Interactive live streaming profile only.
VIDEO_PROFILE_PORTRAIT_360P_11 

1100: 360 × 640, frame rate 24 fps, bitrate 1000 Kbps.

Note
Interactive live streaming profile only.
VIDEO_PROFILE_PORTRAIT_480P 

1040: 480 × 640, frame rate 15 fps, bitrate 500 Kbps.

VIDEO_PROFILE_PORTRAIT_480P_3 

1042: 480 × 480, frame rate 15 fps, bitrate 400 Kbps.

VIDEO_PROFILE_PORTRAIT_480P_4 

1043: 480 × 640, frame rate 30 fps, bitrate 750 Kbps.

VIDEO_PROFILE_PORTRAIT_480P_6 

1045: 480 × 480, frame rate 30 fps, bitrate 600 Kbps.

VIDEO_PROFILE_PORTRAIT_480P_8 

1047: 480 × 848, frame rate 15 fps, bitrate 610 Kbps.

VIDEO_PROFILE_PORTRAIT_480P_9 

1048: 480 × 848, frame rate 30 fps, bitrate 930 Kbps.

VIDEO_PROFILE_PORTRAIT_480P_10 

1049: 480 × 640, frame rate 10 fps, bitrate 400 Kbps.

VIDEO_PROFILE_PORTRAIT_720P 

1050: 720 × 1280, frame rate 15 fps, bitrate 1130 Kbps.

VIDEO_PROFILE_PORTRAIT_720P_3 

1052: 720 × 1280, frame rate 30 fps, bitrate 1710 Kbps.

VIDEO_PROFILE_PORTRAIT_720P_5 

1054: 720 × 960, frame rate 15 fps, bitrate 910 Kbps.

VIDEO_PROFILE_PORTRAIT_720P_6 

1055: 720 × 960, frame rate 30 fps, bitrate 1380 Kbps.

VIDEO_PROFILE_PORTRAIT_1080P 

1060: 1080 × 1920, frame rate 15 fps, bitrate 2080 Kbps.

VIDEO_PROFILE_PORTRAIT_1080P_3 

1062: 1080 × 1920, frame rate 30 fps, bitrate 3150 Kbps.

VIDEO_PROFILE_PORTRAIT_1080P_5 

1064: 1080 × 1920, frame rate 60 fps, bitrate 4780 Kbps.

VIDEO_PROFILE_PORTRAIT_1440P 

1066: 1440 × 2560, frame rate 30 fps, bitrate 4850 Kbps.

VIDEO_PROFILE_PORTRAIT_1440P_2 

1067: 1440 × 2560, frame rate 60 fps, bitrate 6500 Kbps.

VIDEO_PROFILE_PORTRAIT_4K 

1070: 2160 × 3840, frame rate 30 fps, bitrate 6500 Kbps.

VIDEO_PROFILE_PORTRAIT_4K_3 

1072: 2160 × 3840, frame rate 60 fps, bitrate 6500 Kbps.

VIDEO_PROFILE_DEFAULT 

Default 640 × 360, frame rate 15 fps, bitrate 400 Kbps.

◆ VIDEO_RENDER_MODE

Video rendering mode.

Enumerator
RENDER_RAWDATA 

100: (Default) RawData.

REDNER_OPENGL_ES2 

101: OpenGLES 2.

RENDER_UNITY_LOW_LEVEL_INTERFACE 

102: Unity low level interface.

◆ VideoContentHint

Content hints for screen sharing.

Enumerator
CONTENT_HINT_NONE 

0: (Default) No content hint.

CONTENT_HINT_MOTION 

1: Motion-intensive content. Choose this option if you prefer smoothness or when you are sharing a video clip, movie, or video game.

CONTENT_HINT_DETAILS 

2: Motionless content. Choose this option if you prefer sharpness or when you are sharing a picture, PowerPoint slide, or text.

◆ VIRTUAL_BACKGROUND_SOURCE_STATE_REASON

The reason why the virtual background is not successfully enabled or the message that confirms success.

Enumerator
VIRTUAL_BACKGROUND_SOURCE_STATE_REASON_SUCCESS 

0: The virtual background is successfully enabled.

VIRTUAL_BACKGROUND_SOURCE_STATE_REASON_IMAGE_NOT_EXIST 

1: The custom background image does not exist. Please check the value of source in VirtualBackgroundSource.

VIRTUAL_BACKGROUND_SOURCE_STATE_REASON_COLOR_FORMAT_NOT_SUPPORTED 

2: The color format of the custom background image is invalid. Please check the value of color in VirtualBackgroundSource.

VIRTUAL_BACKGROUND_SOURCE_STATE_REASON_DEVICE_NOT_SUPPORTED 

3: The device does not support using the virtual background.

◆ VOICE_BEAUTIFIER_PRESET

The options for SDK preset voice beautifier effects.

Enumerator
VOICE_BEAUTIFIER_OFF 

Turn off voice beautifier effects and use the original voice.

CHAT_BEAUTIFIER_MAGNETIC 

A more magnetic voice.

Note
Agora recommends using this enumerator to process a male-sounding voice; otherwise, you may experience vocal distortion.
CHAT_BEAUTIFIER_FRESH 

A fresher voice.

Note
Agora recommends using this enumerator to process a female-sounding voice; otherwise, you may experience vocal distortion.
CHAT_BEAUTIFIER_VITALITY 

A more vital voice.

Note
Agora recommends using this enumerator to process a female-sounding voice; otherwise, you may experience vocal distortion.
SINGING_BEAUTIFIER 
Since
v3.3.1

Singing beautifier effect.

TIMBRE_TRANSFORMATION_VIGOROUS 

A more vigorous voice.

TIMBRE_TRANSFORMATION_DEEP 

A deeper voice.

TIMBRE_TRANSFORMATION_MELLOW 

A mellower voice.

TIMBRE_TRANSFORMATION_FALSETTO 

A falsetto voice.

TIMBRE_TRANSFORMATION_FULL 

A fuller voice.

TIMBRE_TRANSFORMATION_CLEAR 

A clearer voice.

TIMBRE_TRANSFORMATION_RESOUNDING 

A more resounding voice.

TIMBRE_TRANSFORMATION_RINGING 

A more ringing voice.

◆ VOICE_CHANGER_PRESET

Local voice beautifier options.

Deprecated:
Deprecated as of v3.2.0. Use VOICE_BEAUTIFIER_PRESET instead.
Enumerator
VOICE_CHANGER_OFF 

The original voice (no local voice beautifier).

VOICE_CHANGER_OLDMAN 

The voice of an old man (for male-sounding voice only).

VOICE_CHANGER_BABYBOY 

The voice of a little boy (for male-sounding voice only).

VOICE_CHANGER_BABYGIRL 

The voice of a little girl (for female-sounding voice only).

VOICE_CHANGER_ZHUBAJIE 

The voice of Zhu Bajie, a character in Journey to the West who has a voice like that of a growling bear.

VOICE_CHANGER_ETHEREAL 

The ethereal voice.

VOICE_CHANGER_HULK 

The voice of Hulk.

VOICE_BEAUTY_VIGOROUS 

A more vigorous voice.

VOICE_BEAUTY_DEEP 

A deeper voice.

VOICE_BEAUTY_MELLOW 

A mellower voice.

VOICE_BEAUTY_FALSETTO 

Falsetto.

VOICE_BEAUTY_FULL 

A fuller voice.

VOICE_BEAUTY_CLEAR 

A clearer voice.

VOICE_BEAUTY_RESOUNDING 

A more resounding voice.

VOICE_BEAUTY_RINGING 

A more ringing voice.

VOICE_BEAUTY_SPACIAL 

A more spatially resonant voice.

GENERAL_BEAUTY_VOICE_MALE_MAGNETIC 

(For male only) A more magnetic voice. Do not use it when the speaker is a female; otherwise, voice distortion occurs.

GENERAL_BEAUTY_VOICE_FEMALE_FRESH 

(For female only) A fresher voice. Do not use it when the speaker is a male; otherwise, voice distortion occurs.

GENERAL_BEAUTY_VOICE_FEMALE_VITALITY 

(For female only) A more vital voice. Do not use it when the speaker is a male; otherwise, voice distortion occurs.

◆ VOICE_CONVERSION_PRESET

The options for SDK preset voice conversion effects.

Since
v3.3.1
Enumerator
VOICE_CONVERSION_OFF 

Turn off voice conversion effects and use the original voice.

VOICE_CHANGER_NEUTRAL 

A gender-neutral voice. To avoid audio distortion, ensure that you use this enumerator to process a female-sounding voice.

VOICE_CHANGER_SWEET 

A sweet voice. To avoid audio distortion, ensure that you use this enumerator to process a female-sounding voice.

VOICE_CHANGER_SOLID 

A steady voice. To avoid audio distortion, ensure that you use this enumerator to process a male-sounding voice.

VOICE_CHANGER_BASS 

A deep voice. To avoid audio distortion, ensure that you use this enumerator to process a male-sounding voice.

◆ WLACC_MESSAGE_REASON

The reason of notifying the user of a message.

Enumerator
WLACC_MESSAGE_REASON_WEAK_SIGNAL 

WIFI signal is weak.

WLACC_MESSAGE_REASON_2G_CHANNEL_CONGESTION 

2.4G band congestion.

◆ WLACC_SUGGEST_ACTION

Suggest an action for the user.

Enumerator
WLACC_SUGGEST_ACTION_CLOSE_TO_WIFI 

Please get close to AP.

WLACC_SUGGEST_ACTION_CONNECT_5G 

The user is advised to connect to the prompted SSID.

WLACC_SUGGEST_ACTION_CHECK_5G 

The user is advised to check whether the AP supports 5G band and enable 5G band (the aciton link is attached), or purchases an AP that supports 5G. AP does not support 5G band.

WLACC_SUGGEST_ACTION_MODIFY_SSID 

The user is advised to change the SSID of the 2.4G or 5G band (the aciton link is attached). The SSID of the 2.4G band AP is the same as that of the 5G band.

Function Documentation

◆ ChannelOnActiveSpeakerHandler()

delegate void agora_gaming_rtc.ChannelOnActiveSpeakerHandler ( string  channelId,
uint  uid 
)

Reports which user is the loudest speaker.

If the user enables the audio volume indication by calling the EnableAudioVolumeIndication method, this callback returns the uid of the active speaker detected by the audio volume detection module of the SDK.

Note
  • To receive this callback, you need to call the EnableAudioVolumeIndication method.
  • This callback returns the user ID of the user with the highest voice volume during a period of time, instead of at the moment.
Parameters
channelId The name of the channel that you join.
uid The user ID of the active speaker. A uid of 0 represents the local user.

◆ ChannelOnAudioPublishStateChangedHandler()

delegate void agora_gaming_rtc.ChannelOnAudioPublishStateChangedHandler ( string  channelId,
STREAM_PUBLISH_STATE  oldState,
STREAM_PUBLISH_STATE  newState,
int  elapseSinceLastState 
)

Occurs when the audio publishing state changes.

Since
v3.2.0

This callback indicates the publishing state change of the local audio stream.

Parameters
channelId The name of the channel that you join.
oldState The previous publishing state. For details, see STREAM_PUBLISH_STATE.
newState The current publishing state. For details, see STREAM_PUBLISH_STATE.
elapseSinceLastState The time elapsed (ms) from the previous state to the current state.

◆ ChannelOnAudioSubscribeStateChangedHandler()

delegate void agora_gaming_rtc.ChannelOnAudioSubscribeStateChangedHandler ( string  channelId,
uint  uid,
STREAM_SUBSCRIBE_STATE  oldState,
STREAM_SUBSCRIBE_STATE  newState,
int  elapseSinceLastState 
)

Occurs when the audio subscribing state changes.

Since
v3.2.0

This callback indicates the subscribing state change of a remote audio stream.

Parameters
channelId The name of the channel that you join.
uid The ID of the remote user.
oldState The previous subscribing state. For details, see STREAM_SUBSCRIBE_STATE.
newState The current subscribing state. For details, see STREAM_SUBSCRIBE_STATE.
elapseSinceLastState The time elapsed (ms) from the previous state to the current state.

◆ ChannelOnChannelProxyConnectedHandler()

delegate void agora_gaming_rtc.ChannelOnChannelProxyConnectedHandler ( string  channelId,
uint  uid,
PROXY_TYPE  proxyType,
string  localProxyIp,
int  elapsed 
)

Reports the proxy connection state.

Since
3.7.0

You can use this callback to listen for the state of the SDK connecting to a proxy. For example, when a user calls SetCloudProxy and joins a channel successfully, the SDK triggers this callback to report the user ID, the proxy type connected, and the time elapsed from the user calling joinChannel until this callback is triggered.

Parameters
channelId The channel name.
uid The user ID.
proxyType The proxy type. See PROXY_TYPE.
localProxyIp Reserved for future use.
elapsed The time elapsed (ms) from the user calling joinChannel until this callback is triggered.

◆ ChannelOnClientRoleChangedHandler()

delegate void agora_gaming_rtc.ChannelOnClientRoleChangedHandler ( string  channelId,
CLIENT_ROLE_TYPE  oldRole,
CLIENT_ROLE_TYPE  newRole 
)

Occurs when the user role switches in the interactive live streaming. For example, from a host to an audience or vice versa.

This callback notifies the application of a user role switch when the application calls the SetClientRole method.

The SDK triggers this callback when the local user switches the user role by calling the SetClientRole method after joining the channel.

Parameters
channelId The name of the channel that you join.
oldRole Role that the user switches from: CLIENT_ROLE_TYPE.
newRole Role that the user switches to: CLIENT_ROLE_TYPE.

◆ ChannelOnClientRoleChangeFailedHandler()

delegate void agora_gaming_rtc.ChannelOnClientRoleChangeFailedHandler ( string  channelId,
CLIENT_ROLE_CHANGE_FAILED_REASON  reason,
CLIENT_ROLE_TYPE  currentRole 
)

Occurs when the user role switch fails in the interactive live streaming.

Since
3.7.0

In the LIVE_BROADCASTING channel profile, when the local user calls SetClientRole to switch their user role after joining the channel but the switch fails, the SDK triggers this callback to report the reason for the failure and the current user role.

Parameters
channelId The channel name.
reason The reason for the user role switch failure. See CLIENT_ROLE_CHANGE_FAILED_REASON.
currentRole The current user role. See CLIENT_ROLE_TYPE.

◆ ChannelOnConnectionLostHandler()

delegate void agora_gaming_rtc.ChannelOnConnectionLostHandler ( string  channelId )

Occurs when the SDK cannot reconnect to Agora's edge server 10 seconds after its connection to the server is interrupted.

The SDK triggers this callback when it cannot connect to the server 10 seconds after calling the JoinChannel method, whether or not it is in the channel.

This callback is different from OnConnectionInterruptedHandler:

  • The SDK triggers the OnConnectionInterruptedHandler callback when it loses connection with the server for more than four seconds after it successfully joins the channel.
  • The SDK triggers the ChannelOnConnectionLostHandler callback when it loses connection with the server for more than 10 seconds, whether or not it joins the channel.

If the SDK fails to rejoin the channel 20 minutes after being disconnected from Agora's edge server, the SDK stops rejoining the channel.

Parameters
channelId The name of the channel that you join.

◆ ChannelOnConnectionStateChangedHandler()

delegate void agora_gaming_rtc.ChannelOnConnectionStateChangedHandler ( string  channelId,
CONNECTION_STATE_TYPE  state,
CONNECTION_CHANGED_REASON_TYPE  reason 
)

Occurs when the connection state between the SDK and the server changes.

Parameters
channelId The name of the channel that you join.
state See CONNECTION_STATE_TYPE.
reason See CONNECTION_CHANGED_REASON_TYPE.

◆ ChannelOnErrorHandler()

delegate void agora_gaming_rtc.ChannelOnErrorHandler ( string  channelId,
int  err,
string  message 
)

Reports an error code of AgoraChannel.

In most cases, the SDK cannot fix the issue and resume running. The SDK requires the application to take action or informs the user about the issue.

For example, the SDK reports an ERR_START_CALL(1002) error when failing to initialize a call. The application informs the user that the call initialization failed and invokes the LeaveChannel method to leave the channel.

Parameters
channelId The name of the channel that you join.
err The error code, see Error Code.
message The error message.

◆ ChannelOnFirstRemoteVideoFrameHandler()

delegate void agora_gaming_rtc.ChannelOnFirstRemoteVideoFrameHandler ( string  channelId,
uint  uid,
int  width,
int  height,
int  elapsed 
)

Occurs when the first remote video frame is rendered.

The SDK triggers this callback when the first frame of the remote video is displayed in the user's video window. The application can get the time elapsed from a user joining the channel until the first video frame is displayed.

Parameters
channelId The name of the current channel.
uid User ID of the remote user sending the video stream.
width Width (px) of the video frame.
height Height (px) of the video stream.
elapsed Time elapsed (ms) from the local user calling joinChannel until the SDK triggers this callback.

◆ ChannelOnJoinChannelSuccessHandler()

delegate void agora_gaming_rtc.ChannelOnJoinChannelSuccessHandler ( string  channelId,
uint  uid,
int  elapsed 
)

Occurs when a user joins a channel.

This callback notifies the application that a user joins a specified channel when the application calls the JoinChannel method.

The channel name assignment is based on channelId specified in the JoinChannel method.

If the uid is not specified in the JoinChannel method, the server automatically assigns a uid.

Parameters
channelId The name of the channel that you join.
uid The user ID of the user joining the channel.
elapsed Time elapsed (ms) from the user calling the JoinChannel method until the SDK triggers this callback.

◆ ChannelOnLeaveChannelHandler()

delegate void agora_gaming_rtc.ChannelOnLeaveChannelHandler ( string  channelId,
RtcStats  rtcStats 
)

Occurs when a user leaves the channel.

This callback notifies the application that a user leaves the channel when the application calls the LeaveChannel method.

The application retrieves information, such as the call duration and statistics.

Parameters
channelId The name of the channel that you join.
rtcStats The statistics of the call: RtcStats.

◆ ChannelOnLocalPublishFallbackToAudioOnlyHandler()

delegate void agora_gaming_rtc.ChannelOnLocalPublishFallbackToAudioOnlyHandler ( string  channelId,
bool  isFallbackOrRecover 
)

Occurs when the locally published media stream falls back to an audio-only stream due to poor network conditions or switches back to the video after the network conditions improve.

If you call SetLocalPublishFallbackOption and set option as STREAM_FALLBACK_OPTION_AUDIO_ONLY(2), the SDK triggers this callback when the locally published stream falls back to audio-only mode due to poor uplink conditions, or when the audio stream switches back to the video after the uplink network condition improves.

Parameters
channelId The name of the channel that you join.
isFallbackOrRecover Whether the locally published stream falls back to audio-only or switches back to the video:
  • true: The locally published stream falls back to audio-only due to poor network conditions.
  • false: The locally published stream switches back to the video after the network conditions improve.

◆ ChannelOnMediaRelayEventHandler()

delegate void agora_gaming_rtc.ChannelOnMediaRelayEventHandler ( string  channelId,
CHANNEL_MEDIA_RELAY_EVENT  events 
)

Reports events during the media stream relay.

Parameters
channelId The name of the channel that you join.
events The event code in CHANNEL_MEDIA_RELAY_EVENT.

◆ ChannelOnMediaRelayStateChangedHandler()

delegate void agora_gaming_rtc.ChannelOnMediaRelayStateChangedHandler ( string  channelId,
CHANNEL_MEDIA_RELAY_STATE  state,
CHANNEL_MEDIA_RELAY_ERROR  code 
)

Occurs when the state of the media stream relay changes.

The SDK returns the state of the current media relay with any error message.

Parameters
channelId The name of the channel that you join.
state The state code in CHANNEL_MEDIA_RELAY_STATE.
code The error code in CHANNEL_MEDIA_RELAY_ERROR.

◆ ChannelOnNetworkQualityHandler()

delegate void agora_gaming_rtc.ChannelOnNetworkQualityHandler ( string  channelId,
uint  uid,
int  txQuality,
int  rxQuality 
)

Reports the last mile network quality of each user in the channel once every two seconds.

Last mile refers to the connection between the local device and the Agora edge server. This callback reports once every two seconds the last mile network conditions of each user in the channel. If a channel includes multiple users, the SDK triggers this callback as many times.

Parameters
channelId The name of the channel that you join.
uid User ID. The network quality of the user with this uid is reported. If uid is 0, the local network quality is reported.
txQuality Uplink transmission quality rating of the user in terms of the transmission bitrate, packet loss rate, average RTT (Round-Trip Time), and jitter of the uplink network. txQuality is a quality rating helping you understand how well the current uplink network conditions can support the selected VideoEncoderConfiguration. For example, a 1000 Kbps uplink network may be adequate for video frames with a resolution of 640 × 480 and a frame rate of 15 fps in the Live-broadcast profile, but may be inadequate for resolutions higher than 1280 × 720. See QUALITY_TYPE.
rxQuality Downlink network quality rating of the user in terms of the packet loss rate, average RTT, and jitter of the downlink network. See QUALITY_TYPE.

◆ ChannelOnReJoinChannelSuccessHandler()

delegate void agora_gaming_rtc.ChannelOnReJoinChannelSuccessHandler ( string  channelId,
uint  uid,
int  elapsed 
)

Occurs when a user rejoins the channel after disconnection due to network problems.

When a user loses connection with the server because of network problems, the SDK automatically tries to reconnect and triggers this callback upon reconnection.

Parameters
channelId The name of the channel that you rejoin.
uid The user ID of the user rejoining the channel.
elapsed The time elapsed (ms) from starting to reconnect until the SDK triggers this callback.

◆ ChannelOnRemoteAudioStateChangedHandler()

delegate void agora_gaming_rtc.ChannelOnRemoteAudioStateChangedHandler ( string  channelId,
uint  uid,
REMOTE_AUDIO_STATE  state,
REMOTE_AUDIO_STATE_REASON  reason,
int  elapsed 
)

Occurs when the remote audio state changes.

This callback indicates the state change of the remote audio stream.

Note
This callback does not work properly when the number of users (in the COMMUNICATION profile) or hosts (in the LIVE_BROADCASTING profile) in the channel exceeds 17.
Parameters
channelId The name of the channel that you join.
uid The ID of the remote user whose audio state changes.
state The state of the remote audio. See REMOTE_AUDIO_STATE.
reason The reason of the remote audio state change. See REMOTE_AUDIO_STATE_REASON.
elapsed Time elapsed (ms) from the local user calling the JoinChannel method until the SDK triggers this callback.

◆ ChannelOnRemoteAudioStatsHandler()

delegate void agora_gaming_rtc.ChannelOnRemoteAudioStatsHandler ( string  channelId,
RemoteAudioStats  remoteAudioStats 
)

Reports the statistics of the audio stream from each remote user or host.

This callback replaces the OnAudioQualityHandler callback.

The SDK triggers this callback once every two seconds for each remote user or host. If a channel includes multiple remote users, the SDK triggers this callback as many times.

Parameters
channelId The name of the channel that you join.
remoteAudioStats The statistics of the received remote audio streams. See RemoteAudioStats.

◆ ChannelOnRemoteSubscribeFallbackToAudioOnlyHandler()

delegate void agora_gaming_rtc.ChannelOnRemoteSubscribeFallbackToAudioOnlyHandler ( string  channelId,
uint  uid,
bool  isFallbackOrRecover 
)

Occurs when the remote media stream falls back to audio-only stream due to poor network conditions or switches back to the video stream after the network conditions improve.

If you call SetRemoteSubscribeFallbackOption and set option as STREAM_FALLBACK_OPTION_AUDIO_ONLY(2), the SDK triggers this callback when the remote media stream falls back to audio-only mode due to poor uplink conditions, or when the remote media stream switches back to the video after the uplink network condition improves.

Note
Once the remotely subscribed media stream switches to the low stream due to poor network conditions, you can monitor the stream switch between a high and low stream in the RemoteVideoStats of the ChannelOnRemoteVideoStatsHandler callback.
Parameters
channelId The name of the channel that you join.
uid ID of the remote user sending the stream.
isFallbackOrRecover Whether the remotely subscribed media stream falls back to audio-only or switches back to the video:
  • true: The remotely subscribed media stream falls back to audio-only due to poor network conditions.
  • false: The remotely subscribed media stream switches back to the video stream after the network conditions improved.

◆ ChannelOnRemoteVideoStateChangedHandler()

delegate void agora_gaming_rtc.ChannelOnRemoteVideoStateChangedHandler ( string  channelId,
uint  uid,
REMOTE_VIDEO_STATE  state,
REMOTE_VIDEO_STATE_REASON  reason,
int  elapsed 
)

Occurs when the remote video state changes.

Note
This callback does not work properly when the number of users (in the COMMUNICATION profile) or hosts (in the LIVE_BROADCASTING profile) in the channel exceeds 17.
Parameters
channelId The name of the channel that you join.
uid The ID of the remote user whose video state changes.
state The state of the remote video. See REMOTE_VIDEO_STATE.
reason The reason of the remote video state change. See REMOTE_VIDEO_STATE_REASON.
elapsed The time elapsed (ms) from the local user calling the JoinChannel method until the SDK triggers this callback.

◆ ChannelOnRemoteVideoStatsHandler()

delegate void agora_gaming_rtc.ChannelOnRemoteVideoStatsHandler ( string  channelId,
RemoteVideoStats  remoteVideoStats 
)

Reports the statistics of the video stream from each remote user or host.

The SDK triggers this callback once every two seconds for each remote user or host. If a channel includes multiple remote users, the SDK triggers this callback as many times.

Parameters
channelId The name of the channel that you join.
remoteVideoStats The statistics of the remote video stream. See RemoteVideoStats.

◆ ChannelOnRequestTokenHandler()

delegate void agora_gaming_rtc.ChannelOnRequestTokenHandler ( string  channelId )

Occurs when the token expires.

After a token is specified by calling the JoinChannel method, if the SDK losses connection with the Agora server due to network issues, the token may expire after a certain period of time and a new token may be required to reconnect to the server.

This callback notifies the app to generate a new token and call JoinChannel to rejoin the channel with the new token.

Parameters
channelId The name of the channel that you join.

◆ ChannelOnRtcStatsHandler()

delegate void agora_gaming_rtc.ChannelOnRtcStatsHandler ( string  channelId,
RtcStats  rtcStats 
)

Reports the statistics of the current call session once every two seconds.

Parameters
channelId The name of the channel that you join.
rtcStats The AgoraChannel engine statistics: RtcStats.

◆ ChannelOnRtmpStreamingEventHandler()

delegate void agora_gaming_rtc.ChannelOnRtmpStreamingEventHandler ( string  channelId,
string  url,
RTMP_STREAMING_EVENT  eventCode 
)

Reports events during the RTMP or RTMPS streaming.

Since
v3.2.0
Parameters
channelId The name of the channel that you join.
url The RTMP or RTMPS streaming URL.
eventCode The event code. See RTMP_STREAMING_EVENT

◆ ChannelOnRtmpStreamingStateChangedHandler()

delegate void agora_gaming_rtc.ChannelOnRtmpStreamingStateChangedHandler ( string  channelId,
string  url,
RTMP_STREAM_PUBLISH_STATE  state,
RTMP_STREAM_PUBLISH_ERROR_TYPE  errCode 
)

Occurs when the state of the RTMP or RTMPS streaming changes.

The SDK triggers this callback to report the result of the local user calling the AddPublishStreamUrl or RemovePublishStreamUrl method.

This callback indicates the state of the RTMP or RTMPS streaming. When exceptions occur, you can troubleshoot issues by referring to the detailed error descriptions in the errCode parameter.

Parameters
channelId The name of the channel that you join.
url The CDN streaming URL.
state The RTMP or RTMPS streaming state. See: RTMP_STREAM_PUBLISH_STATE.
errCode The detailed error information for streaming. See: RTMP_STREAM_PUBLISH_ERROR_TYPE.

◆ ChannelOnStreamMessageErrorHandler()

delegate void agora_gaming_rtc.ChannelOnStreamMessageErrorHandler ( string  channelId,
uint  uid,
int  streamId,
int  code,
int  missed,
int  cached 
)

Occurs when the local user does not receive the data stream from the remote user within five seconds.

The SDK triggers this callback when the local user fails to receive the stream message that the remote user sends by calling the SendStreamMessage method.

Parameters
channelId The name of the channel that you join.
uid The user ID of the remote user sending the message.
streamId The stream ID.
code The error code: Error Code.
missed The number of lost messages.
cached The number of incoming cached messages when the data stream is interrupted.

◆ ChannelOnStreamMessageHandler()

delegate void agora_gaming_rtc.ChannelOnStreamMessageHandler ( string  channelId,
uint  uid,
int  streamId,
string  data,
int  length 
)

Occurs when the local user receives the data stream from the remote user within five seconds.

The SDK triggers this callback when the local user receives the stream message that the remote user sends by calling the SendStreamMessage method.

Parameters
channelId The name of the channel that you join.
uid The user ID of the remote user sending the message.
streamId The stream ID.
data The data received by the local user.
length The length of the data in bytes.

◆ ChannelOnTokenPrivilegeWillExpireHandler()

delegate void agora_gaming_rtc.ChannelOnTokenPrivilegeWillExpireHandler ( string  channelId,
string  token 
)

Occurs when the token expires in 30 seconds.

The user becomes offline if the token used in the JoinChannel method expires. The SDK triggers this callback 30 seconds before the token expires to remind the application to get a new token. Upon receiving this callback, generate a new token on the server and call the RenewToken method to pass the new token to the SDK.

Parameters
channelId The name of the channel that you join.
token The token that expires in 30 seconds.

◆ ChannelOnTranscodingUpdatedHandler()

delegate void agora_gaming_rtc.ChannelOnTranscodingUpdatedHandler ( string  channelId )

Occurs when the publisher's transcoding is updated.

When the LiveTranscoding class in the SetLiveTranscoding method updates, the SDK triggers the ChannelOnTranscodingUpdatedHandler callback to report the update information to the local host.

Note
If you call the SetLiveTranscoding method to set the LiveTranscoding class for the first time, the SDK does not trigger the ChannelOnTranscodingUpdatedHandler callback.
Parameters
channelId The name of the channel that you join.

◆ ChannelOnUserJoinedHandler()

delegate void agora_gaming_rtc.ChannelOnUserJoinedHandler ( string  channelId,
uint  uid,
int  elapsed 
)

Occurs when a remote user (Communication) or host (Live Broadcast) joins the channel.

  • Communication profile: This callback notifies the application that another user joins the channel. If other users are already in the channel, the SDK also reports to the application on the existing users.
  • Live-broadcast profile: This callback notifies the application that the host joins the channel. If other hosts are already in the channel, the SDK also reports to the application on the existing hosts. We recommend limiting the number of hosts to 17.

The SDK triggers this callback under one of the following circumstances:

  • A remote user or host joins the channel by calling the JoinChannel method.
  • A remote user switches the user role to the host by calling the SetClientRole method after joining the channel.
  • A remote user or host rejoins the channel after a network interruption.
Note
In the Live-broadcast profile:
  • The host receives this callback when another host joins the channel.
  • The audience in the channel receives this callback when a new host joins the channel.
  • When a web application joins the channel, the SDK triggers this callback as long as the web application publishes streams.
Parameters
channelId The name of the channel that you join.
uid The user ID of the user or host joining the channel.
elapsed Time delay (ms) from the local user calling the JoinChannel method until the SDK triggers this callback.

◆ ChannelOnUserOffLineHandler()

delegate void agora_gaming_rtc.ChannelOnUserOffLineHandler ( string  channelId,
uint  uid,
USER_OFFLINE_REASON  reason 
)

Occurs when a remote user (Communication) or host (Live Broadcast) leaves the channel.

Reasons why the user is offline:

  • Leave the channel: When the user or host leaves the channel, the user or host sends a goodbye message. When the message is received, the SDK assumes that the user or host leaves the channel.
  • Drop offline: When no data packet of the user or host is received for a certain period of time (20 seconds for the Communication profile, and more for the Live-broadcast profile), the SDK assumes that the user or host drops offline. Unreliable network connections may lead to false detections, so we recommend using the Agora RTM SDK for more reliable offline detection.
Parameters
channelId The name of the channel that you join.
uid The user ID of the user leaving the channel or going offline.
reason The reason why the user is offline: USER_OFFLINE_REASON.

◆ ChannelOnUserSuperResolutionEnabledHandler()

delegate void agora_gaming_rtc.ChannelOnUserSuperResolutionEnabledHandler ( string  channelId,
uint  uid,
bool  enabled,
SUPER_RESOLUTION_STATE_REASON  reason 
)

Reports whether the super resolution feature is successfully enabled. (beta feature)

Since
v3.6.1.1

After calling EnableRemoteSuperResolution, the SDK triggers this callback to report whether the super-resolution algorithm is successfully enabled. If not successfully enabled, you can use reason for troubleshooting.

Parameters
channelId The name of the channel that you join.
uid The user ID of the remote user.
enabled Whether super resolution is successfully enabled:
  • true: Super resolution is successfully enabled.
  • false: Super resolution is not successfully enabled.
reason The reason why super resolution is not successfully enabled. See SUPER_RESOLUTION_STATE_REASON.

◆ ChannelOnVideoPublishStateChangedHandler()

delegate void agora_gaming_rtc.ChannelOnVideoPublishStateChangedHandler ( string  channelId,
STREAM_PUBLISH_STATE  oldState,
STREAM_PUBLISH_STATE  newState,
int  elapseSinceLastState 
)

Occurs when the video publishing state changes.

Since
v3.2.0

This callback indicates the publishing state change of the local video stream.

Parameters
channelId The name of the channel that you join.
oldState The previous publishing state. For details, see STREAM_PUBLISH_STATE.
newState The current publishing state. For details, see STREAM_PUBLISH_STATE.
elapseSinceLastState The time elapsed (ms) from the previous state to the current state.

◆ ChannelOnVideoSizeChangedHandler()

delegate void agora_gaming_rtc.ChannelOnVideoSizeChangedHandler ( string  channelId,
uint  uid,
int  width,
int  height,
int  rotation 
)

Occurs when the video size or rotation of a specified user changes.

Parameters
channelId The name of the channel that you join.
uid The user ID of the remote user or local user (0) whose video size or rotation changes.
width The new width (pixels) of the video.
height The new height (pixels) of the video.
rotation The new rotation of the video [0 to 360).

◆ ChannelOnVideoSubscribeStateChangedHandler()

delegate void agora_gaming_rtc.ChannelOnVideoSubscribeStateChangedHandler ( string  channelId,
uint  uid,
STREAM_SUBSCRIBE_STATE  oldState,
STREAM_SUBSCRIBE_STATE  newState,
int  elapseSinceLastState 
)

Occurs when the audio subscribing state changes.

Since
v3.2.0

This callback indicates the subscribing state change of a remote video stream.

Parameters
channelId The name of the channel that you join.
uid The ID of the remote user.
oldState The previous subscribing state. For details, see STREAM_SUBSCRIBE_STATE.
newState The current subscribing state. For details, see STREAM_SUBSCRIBE_STATE.
elapseSinceLastState The time elapsed (ms) from the previous state to the current state.

◆ ChannelOnWarningHandler()

delegate void agora_gaming_rtc.ChannelOnWarningHandler ( string  channelId,
int  warn,
string  message 
)

Reports a warning during SDK runtime.

In most cases, the application can ignore the warning reported by the SDK because the SDK can usually fix the issue and resume running. For example, when losing connection with the server, the SDK may report WARN_LOOKUP_CHANNEL_TIMEOUT(104) and automatically try to reconnect.

Parameters
channelId The name of the channel that you join.
warn The warning code, see Warning Code.
message The warning message.

◆ OnActiveSpeakerHandler()

delegate void agora_gaming_rtc.OnActiveSpeakerHandler ( uint  uid )

Occurs when the most active speaker is detected.

After a successful call of EnableAudioVolumeIndication, the SDK continuously detects which remote user has the loudest volume. During the current period, the remote user, who is detected as the loudest for the most times, is the most active user.

When the number of user is no less than two and an active speaker exists, the SDK triggers this callback and reports the uid of the most active speaker.

  • If the most active speaker is always the same user, the SDK triggers this callback only once.
  • If the most active speaker changes to another user, the SDK triggers this callback again and reports the uid of the new active speaker.
Parameters
uid The user ID of the most active speaker.

◆ OnApiExecutedHandler()

delegate void agora_gaming_rtc.OnApiExecutedHandler ( int  err,
string  api,
string  result 
)

Occurs when a method is executed by the SDK.

Parameters
err The Error Code. returned by the SDK when a method call fails. If the SDK returns 0, then the method call is successful.
api The method executed by the SDK.
result The result of the method call.

◆ OnAudioDeviceStateChangedHandler()

delegate void agora_gaming_rtc.OnAudioDeviceStateChangedHandler ( string  deviceId,
int  deviceType,
int  deviceState 
)

Occurs when the audio device state changes.

This callback notifies the application that the system's audio device state is changed. For example, a headset is unplugged from the device.

Note
This method applies to Windows and macOS only.
Parameters
deviceId The device ID.
deviceType The device type: MEDIA_DEVICE_TYPE.
deviceState The device state: MEDIA_DEVICE_STATE_TYPE.

◆ OnAudioDeviceTestVolumeIndicationHandler()

delegate void agora_gaming_rtc.OnAudioDeviceTestVolumeIndicationHandler ( AudioDeviceTestVolumeType  volumeType,
int  volume 
)

Reports the result of an audio device test.

Since
3.7.0

After successfully calling StartAudioRecordingDeviceTest, StartAudioPlaybackDeviceTest or StartAudioDeviceLoopbackTest to start an audio device test, the SDK triggers this callback at the set time interval to report the volume information of the audio device tested.

Parameters
volumeType The volume type. See AudioDeviceTestVolumeType.
volume The volume, in the range of [0,255].

◆ OnAudioDeviceVolumeChangedHandler()

delegate void agora_gaming_rtc.OnAudioDeviceVolumeChangedHandler ( MEDIA_DEVICE_TYPE  deviceType,
int  volume,
bool  muted 
)

Occurs when the volume of the playback device, microphone, or application changes.

Note
This method applies to Windows only.
Parameters
deviceType Device type: MEDIA_DEVICE_TYPE.
volume Volume of the device. The value ranges between 0 and 255.
muted
  • true: The audio device is muted.
  • false: The audio device is not muted.

◆ OnAudioEffectFinishedHandler()

delegate void agora_gaming_rtc.OnAudioEffectFinishedHandler ( int  soundId )

Occurs when the local audio effect playback finishes.

The SDK triggers this callback when the local audio effect file playback finishes.

Parameters
soundId ID of the local audio effect. Each local audio effect has a unique ID.

◆ OnAudioMixingFinishedHandler()

delegate void agora_gaming_rtc.OnAudioMixingFinishedHandler ( )

Occurs when the audio mixing file playback finishes.

Deprecated:
use OnAudioMixingStateChangedHandler instead.

You can start an audio mixing file playback by calling the StartAudioMixing method. The SDK triggers this callback when the audio mixing file playback finishes.

If the StartAudioMixing method call fails, an error code returns in the OnSDKErrorHandler callback.

◆ OnAudioMixingStateChangedHandler()

delegate void agora_gaming_rtc.OnAudioMixingStateChangedHandler ( AUDIO_MIXING_STATE_TYPE  state,
AUDIO_MIXING_REASON_TYPE  reason 
)

Occurs when the state of the local user's audio mixing file changes.

  • When the audio mixing file plays, pauses playing, or stops playing, this callback returns 710, 711, or 713 in state, and 0 in errorCode.
  • When exceptions occur during playback, this callback returns 714 in state and an error in errorCode.
  • If the local audio mixing file does not exist, or if the SDK does not support the file format or cannot access the music file URL, the SDK returns WARN_AUDIO_MIXING_OPEN_ERROR(701).
Parameters
state The state code. See AUDIO_MIXING_STATE_TYPE.
reason The error code. See AUDIO_MIXING_ERROR_TYPE.

◆ OnAudioPublishStateChangedHandler()

delegate void agora_gaming_rtc.OnAudioPublishStateChangedHandler ( string  channel,
STREAM_PUBLISH_STATE  oldState,
STREAM_PUBLISH_STATE  newState,
int  elapseSinceLastState 
)

Occurs when the audio publishing state changes.

Since
v3.2.0

This callback indicates the publishing state change of the local audio stream.

Parameters
channel The channel name.
oldState The previous publishing state. For details, see STREAM_PUBLISH_STATE.
newState The current publishing state. For details, see STREAM_PUBLISH_STATE.
elapseSinceLastState The time elapsed (ms) from the previous state to the current state.

◆ OnAudioQualityHandler()

delegate void agora_gaming_rtc.OnAudioQualityHandler ( uint  userId,
int  quality,
ushort  delay,
ushort  lost 
)

Reports the statistics of the audio stream from each remote user/host.

Deprecated:
Deprecated as of v2.3.2. Use the OnRemoteAudioStatsHandler callback instead.

The SDK triggers this callback once every two seconds to report the audio quality of each remote user/host sending an audio stream. If a channel has multiple users/hosts sending audio streams, the SDK triggers this callback as many times.

Parameters
userId The user ID of the speaker.
quality The audio quality of the user: QUALITY_TYPE.
delay The time delay (ms) of sending the audio packet from the sender to the receiver, including the time delay of audio sampling pre-processing, transmission, and the jitter buffer.
lost The packet loss rate (%) of the audio packet sent from the sender to the receiver.

◆ OnAudioRouteChangedHandler()

delegate void agora_gaming_rtc.OnAudioRouteChangedHandler ( AUDIO_ROUTE  route )

Occurs when the local audio route changes.

The SDK triggers this callback when the local audio route switches to an earpiece, speakerphone, headset, or Bluetooth device.

Parameters
route The current audio routing. See: AUDIO_ROUTE.

◆ OnAudioSubscribeStateChangedHandler()

delegate void agora_gaming_rtc.OnAudioSubscribeStateChangedHandler ( string  channel,
uint  uid,
STREAM_SUBSCRIBE_STATE  oldState,
STREAM_SUBSCRIBE_STATE  newState,
int  elapseSinceLastState 
)

Occurs when the audio subscribing state changes.

Since
v3.2.0

This callback indicates the subscribing state change of a remote audio stream.

Parameters
channel The channel name.
uid The ID of the remote user.
oldState The previous subscribing state. For details, see STREAM_SUBSCRIBE_STATE.
newState The current subscribing state. For details, see STREAM_SUBSCRIBE_STATE.
elapseSinceLastState The time elapsed (ms) from the previous state to the current state.

◆ OnCameraExposureAreaChangedHandler()

delegate void agora_gaming_rtc.OnCameraExposureAreaChangedHandler ( int  x,
int  y,
int  width,
int  height 
)

Occurs when the camera exposure area changes.

The SDK triggers this callback when the local user changes the camera exposure position by calling the setCameraExposurePosition method.

Note
This callback is for Android and iOS only.
Parameters
x x coordinate of the changed camera exposure area.
y y coordinate of the changed camera exposure area.
width Width of the changed camera exposure area.
height Height of the changed camera exposure area.

◆ OnCameraFocusAreaChangedHandler()

delegate void agora_gaming_rtc.OnCameraFocusAreaChangedHandler ( int  x,
int  y,
int  width,
int  height 
)

Occurs when the camera focus area changes.

The SDK triggers this callback when the local user changes the camera focus position by calling the setCameraFocusPositionInPreview method.

Note
This callback is for Android and iOS only.
Parameters
x x coordinate of the changed camera focus area.
y y coordinate of the changed camera focus area.
width Width of the changed camera focus area.
height Height of the changed camera focus area.

◆ OnCameraReadyHandler()

delegate void agora_gaming_rtc.OnCameraReadyHandler ( )

Occurs when the camera turns on and is ready to capture the video.

Deprecated:
Deprecated as of v2.4.1. Use LOCAL_VIDEO_STREAM_STATE_CAPTURING(1) in the OnLocalVideoStateChangedHandler callback instead.

If the camera fails to turn on, fix the error reported in the OnSDKErrorHandler callback.

◆ OnChannelMediaRelayEventHandler()

delegate void agora_gaming_rtc.OnChannelMediaRelayEventHandler ( CHANNEL_MEDIA_RELAY_EVENT  events )

Reports events during the media stream relay.

Parameters
events The event code in CHANNEL_MEDIA_RELAY_EVENT.

◆ OnChannelMediaRelayStateChangedHandler()

delegate void agora_gaming_rtc.OnChannelMediaRelayStateChangedHandler ( CHANNEL_MEDIA_RELAY_STATE  state,
CHANNEL_MEDIA_RELAY_ERROR  code 
)

Occurs when the state of the media stream relay changes.

The SDK returns the state of the current media relay with any error message.

Parameters
state The state code in CHANNEL_MEDIA_RELAY_STATE.
code The error code in CHANNEL_MEDIA_RELAY_ERROR.

◆ OnClientRoleChangedHandler()

delegate void agora_gaming_rtc.OnClientRoleChangedHandler ( CLIENT_ROLE_TYPE  oldRole,
CLIENT_ROLE_TYPE  newRole 
)

Occurs when the user role switches successfully in the interactive live streaming.

In the LIVE_BROADCASTING channel profile, when the local user successfully calls setClientRole to switch their user role after joining the channel, for example, from a host to an audience member or vice versa, the SDK triggers this callback to report the user role before and after the switch.

Parameters
oldRole Role that the user switches from: CLIENT_ROLE_TYPE.
newRole Role that the user switches to: CLIENT_ROLE_TYPE.

◆ OnClientRoleChangeFailedHandler()

delegate void agora_gaming_rtc.OnClientRoleChangeFailedHandler ( CLIENT_ROLE_CHANGE_FAILED_REASON  reason,
CLIENT_ROLE_TYPE  currentRole 
)

Occurs when the user role switch fails in the interactive live streaming.

Since
3.7.0

In the LIVE_BROADCASTING channel profile, when the local user calls SetClientRole to switch their user role after joining the channel but the switch fails, the SDK triggers this callback to report the reason for the failure and the current user role.

Parameters
reason The reason for the user role switch failure. See CLIENT_ROLE_CHANGE_FAILED_REASON.
currentRole The current user role. See CLIENT_ROLE_TYPE.

◆ OnConnectionBannedHandler()

delegate void agora_gaming_rtc.OnConnectionBannedHandler ( )

Occurs when your connection is banned by the Agora Server.

Deprecated:
from v2.3.2. Replaced by the OnConnectionStateChangedHandler callback.

◆ OnConnectionInterruptedHandler()

delegate void agora_gaming_rtc.OnConnectionInterruptedHandler ( )

Occurs when the connection between the SDK and the server is interrupted.

Deprecated:
Deprecated as of v2.3.2. Replaced by the OnConnectionStateChangedHandler callback.

The SDK triggers this callback when it loses connection with the server for more than four seconds after the connection is established.

After triggering this callback, the SDK tries reconnecting to the server. You can use this callback to implement pop-up reminders.

This callback is different from OnConnectionLostHandler:

  • The SDK triggers the OnConnectionInterruptedHandler callback when it loses connection with the server for more than four seconds after it successfully joins the channel.
  • The SDK triggers the OnConnectionLostHandler callback when it loses connection with the server for more than 10 seconds, whether or not it joins the channel.

If the SDK fails to rejoin the channel 20 minutes after being disconnected from Agora's edge server, the SDK stops rejoining the channel.

◆ OnConnectionLostHandler()

delegate void agora_gaming_rtc.OnConnectionLostHandler ( )

Occurs when the SDK cannot reconnect to Agora's edge server 10 seconds after its connection to the server is interrupted.

The SDK triggers this callback when it cannot connect to the server 10 seconds after calling the JoinChannelByKey method, whether or not it is in the channel.

This callback is different from OnConnectionInterruptedHandler:

  • The SDK triggers the OnConnectionInterruptedHandler callback when it loses connection with the server for more than four seconds after it successfully joins the channel.
  • The SDK triggers the OnConnectionLostHandler callback when it loses connection with the server for more than 10 seconds, whether or not it joins the channel.

If the SDK fails to rejoin the channel 20 minutes after being disconnected from Agora's edge server, the SDK stops rejoining the channel.

◆ OnConnectionStateChangedHandler()

delegate void agora_gaming_rtc.OnConnectionStateChangedHandler ( CONNECTION_STATE_TYPE  state,
CONNECTION_CHANGED_REASON_TYPE  reason 
)

Occurs when the connection state between the SDK and the server changes.

Parameters
state See CONNECTION_STATE_TYPE.
reason See CONNECTION_CHANGED_REASON_TYPE.

◆ OnFacePositionChangedHandler()

delegate void agora_gaming_rtc.OnFacePositionChangedHandler ( int  imageWidth,
int  imageHeight,
Rectangle  vecRectangle,
int  vecDistance,
int  numFaces 
)

Reports the face detection result of the local user. Applies to Android and iOS only.

Since
v3.0.1

Once you enable face detection by calling EnableFaceDetection(true), you can get the following information on the local user in real-time:

  • The width and height of the local video.
  • The position of the human face in the local video.
  • The distance between the human face and the device screen. This value is based on the fitting calculation of the local video size and the position of the human face.
Note
  • If the SDK does not detect a face, it reduces the frequency of this callback to reduce power consumption on the local device.
  • The SDK stops triggering this callback when a human face is in close proximity to the screen.
  • On Android, the distance value reported in this callback may be slightly different from the actual distance. Therefore, Agora does not recommend using it for accurate calculation.
Parameters
imageWidth The width (px) of the local video.
imageHeight The height (px) of the local video.
vecRectangle The position and size of the human face on the local video:
  • x: The x coordinate (px) of the human face in the local video. Taking the top left corner of the captured video as the origin, the x coordinate represents the relative lateral displacement of the top left corner of the human face to the origin.
  • y: The y coordinate (px) of the human face in the local video. Taking the top left corner of the captured video as the origin, the y coordinate represents the relative longitudinal displacement of the top left corner of the human face to the origin.
  • width: The width (px) of the human face in the captured video.
  • height: The height (px) of the human face in the captured video.
vecDistance The distance (cm) between the human face and the screen.
numFaces The number of faces detected. If the value is 0, it means that no human face is detected.

◆ OnFirstLocalAudioFrameHandler()

delegate void agora_gaming_rtc.OnFirstLocalAudioFrameHandler ( int  elapsed )

Occurs when the engine sends the first local audio frame.

Deprecated:
Deprecated as of v3.2.0. Use the OnFirstLocalAudioFramePublishedHandler callback instead.
Parameters
elapsed The time elapsed (ms) from the local user calling JoinChannelByKey until the SDK triggers this callback.

◆ OnFirstLocalAudioFramePublishedHandler()

delegate void agora_gaming_rtc.OnFirstLocalAudioFramePublishedHandler ( int  elapsed )

Occurs when the first audio frame is published.

Since
v3.2.0

The SDK triggers this callback under one of the following circumstances:

Parameters
elapsed The time elapsed (ms) from the local client calling JoinChannelByKey until the SDK triggers this callback.

◆ OnFirstLocalVideoFrameHandler()

delegate void agora_gaming_rtc.OnFirstLocalVideoFrameHandler ( int  width,
int  height,
int  elapsed 
)

Occurs when the first local video frame is displayed/rendered on the local video view.

Parameters
width Width (px) of the first local video frame.
height Height (px) of the first local video frame.
elapsed Time elapsed (ms) from the local user calling the JoinChannelByKey method until the SDK triggers this callback. If you call the StartPreview method before calling the JoinChannelByKey method, then elapsed is the time elapsed from calling the StartPreview method until the SDK triggers this callback.

◆ OnFirstLocalVideoFramePublishedHandler()

delegate void agora_gaming_rtc.OnFirstLocalVideoFramePublishedHandler ( int  elapsed )

Occurs when the first video frame is published.

Since
v3.2.0

The SDK triggers this callback under one of the following circumstances:

Parameters
elapsed The time elapsed (ms) from the local client calling JoinChannelByKey until the SDK triggers this callback.

◆ OnFirstRemoteAudioDecodedHandler()

delegate void agora_gaming_rtc.OnFirstRemoteAudioDecodedHandler ( uint  uid,
int  elapsed 
)

Occurs when the SDK decodes the first remote audio frame for playback.

Deprecated:
v3.0.1 This callback is deprecated. Use OnRemoteAudioStateChangedHandler instead.

This callback is triggered in either of the following scenarios:

  • The remote user joins the channel and sends the audio stream.
  • The remote user stops sending the audio stream and re-sends it after 15 seconds. Reasons for such an interruption include:
    • The remote user leaves channel.
    • The remote user drops offline.
    • The remote user calls the MuteLocalAudioStream method to stop sending the local audio stream.
    • The remote user calls the DisableAudio method to disable audio.
Parameters
uid User ID of the remote user sending the audio stream.
elapsed Time elapsed (ms) from the local user calling the JoinChannelByKey method until the SDK triggers this callback.

◆ OnFirstRemoteAudioFrameHandler()

delegate void agora_gaming_rtc.OnFirstRemoteAudioFrameHandler ( uint  userId,
int  elapsed 
)

Occurs when the engine receives the first audio frame from a specific remote user.

Deprecated:
v3.0.1 This callback is deprecated. Use OnRemoteAudioStateChangedHandler instead.
Parameters
userId The user ID of the remote user.
elapsed The time elapsed (ms) from the remote user calling JoinChannelByKey until the SDK triggers this callback.

◆ OnFirstRemoteVideoDecodedHandler()

delegate void agora_gaming_rtc.OnFirstRemoteVideoDecodedHandler ( uint  uid,
int  width,
int  height,
int  elapsed 
)

Occurs when the first remote video frame is received and decoded.

This callback is triggered in either of the following scenarios:

  • The remote user joins the channel and sends the video stream.
  • The remote user stops sending the video stream and re-sends it after 15 seconds. Reasons for such an interruption include:
    • The remote user leaves the channel.
    • The remote user drops offline.
    • The remote user calls the MuteLocalVideoStream method to stop sending the video stream.
    • The remote user calls the DisableVideo method to disable video. The application can configure the user view settings in this callback.
Parameters
uid The user ID of the remote user sending the video stream.
width The width (px) of the video stream.
height The height (px) of the video stream.
elapsed Time elapsed (ms) from the local user calling the JoinChannelByKey method until the SDK triggers this callback.

◆ OnFirstRemoteVideoFrameHandler()

delegate void agora_gaming_rtc.OnFirstRemoteVideoFrameHandler ( uint  uid,
int  width,
int  height,
int  elapsed 
)

Occurs when the first remote video frame is received and decoded.

The SDK triggers this callback when the first frame of the remote video is displayed in the user's video window. The application can retrieve the time elapsed from a user joining the channel until the first video frame is displayed.

Parameters
uid User ID of the remote user sending the video stream.
width Width (px) of the video frame.
height Height (px) of the video stream.
elapsed Time elapsed (ms) from the local user calling the JoinChannelByKey method until the SDK triggers this callback.

◆ OnJoinChannelSuccessHandler()

delegate void agora_gaming_rtc.OnJoinChannelSuccessHandler ( string  channelName,
uint  uid,
int  elapsed 
)

Occurs when a user joins a channel.

This callback notifies the application that a user joins a specified channel when the application calls the JoinChannelByKey method.

The channel name assignment is based on channelName specified in the JoinChannelByKey method.

If the uid is not specified in the JoinChannelByKey method, the server automatically assigns a uid.

Parameters
channelName The name of the channel that you join.
uid The user ID of the user joining the channel.
elapsed Time elapsed (ms) from the user calling the JoinChannelByKey method until the SDK triggers this callback.

◆ OnLastmileProbeResultHandler()

delegate void agora_gaming_rtc.OnLastmileProbeResultHandler ( LastmileProbeResult  result )

Reports the last-mile network probe result.

The SDK triggers this callback within 30 seconds after the app calls the StartLastmileProbeTest method.

Parameters
result The uplink and downlink last-mile network probe test result. See LastmileProbeResult.

◆ OnLastmileQualityHandler()

delegate void agora_gaming_rtc.OnLastmileQualityHandler ( int  quality )

Reports the last mile network quality of the local user once every two seconds before the user joins the channel.

Last mile refers to the connection between the local device and Agora's edge server. After the application calls the EnableLastmileTest method, this callback reports once every two seconds the uplink and downlink last mile network conditions of the local user before the user joins the channel.

Parameters
quality The last mile network quality: QUALITY_TYPE.

◆ OnLeaveChannelHandler()

delegate void agora_gaming_rtc.OnLeaveChannelHandler ( RtcStats  stats )

Occurs when a user leaves the channel.

This callback notifies the application that a user leaves the channel when the application calls the LeaveChannel method.

The application retrieves information, such as the call duration and statistics.

Parameters
stats The statistics of the call: RtcStats.

◆ OnLocalAudioStateChangedHandler()

delegate void agora_gaming_rtc.OnLocalAudioStateChangedHandler ( LOCAL_AUDIO_STREAM_STATE  state,
LOCAL_AUDIO_STREAM_ERROR  error 
)

Occurs when the local audio state changes.

This callback indicates the state change of the local audio stream, including the state of the audio capturing and encoding, and allows you to troubleshoot issues when exceptions occur.

Note
When the state is LOCAL_AUDIO_STREAM_STATE_FAILED(3), see the error parameter for details.
Parameters
state The state of the local audio. See LOCAL_AUDIO_STREAM_STATE.
error The error information of the local audio. See LOCAL_AUDIO_STREAM_ERROR.

◆ OnLocalAudioStatsHandler()

delegate void agora_gaming_rtc.OnLocalAudioStatsHandler ( LocalAudioStats  localAudioStats )

Reports the statistics of the local audio stream.

The SDK triggers this callback once every two seconds.

Parameters
localAudioStats The statistics of the local audio stream. See LocalAudioStats.

◆ OnLocalPublishFallbackToAudioOnlyHandler()

delegate void agora_gaming_rtc.OnLocalPublishFallbackToAudioOnlyHandler ( bool  isFallbackOrRecover )

Occurs when the locally published media stream falls back to an audio-only stream due to poor network conditions or switches back to the video after the network conditions improve.

If you call SetLocalPublishFallbackOption and set option as STREAM_FALLBACK_OPTION_AUDIO_ONLY(2), the SDK triggers this callback when the locally published stream falls back to audio-only mode due to poor uplink conditions, or when the audio stream switches back to the video after the uplink network condition improves.

Parameters
isFallbackOrRecover Whether the locally published stream falls back to audio-only or switches back to the video:
  • true: The locally published stream falls back to audio-only due to poor network conditions.
  • false: The locally published stream switches back to the video after the network conditions improve.

◆ OnLocalUserRegisteredHandler()

delegate void agora_gaming_rtc.OnLocalUserRegisteredHandler ( uint  uid,
string  userAccount 
)

Occurs when the local user successfully registers a user account by calling the RegisterLocalUserAccount method or joins a channel by calling the JoinChannelByKey method.This callback reports the user ID and user account of the local user.

Parameters
uid The ID of the local user.
userAccount The user account of the local user.

◆ OnLocalVideoStateChangedHandler()

delegate void agora_gaming_rtc.OnLocalVideoStateChangedHandler ( LOCAL_VIDEO_STREAM_STATE  localVideoState,
LOCAL_VIDEO_STREAM_ERROR  error 
)

Occurs when the local video stream state changes.

This callback indicates the state of the local video stream, including camera capturing and video encoding, and allows you to troubleshoot issues when exceptions occur.

Note
For some device models, the SDK will not trigger this callback when the state of the local video changes while the local video capturing device is in use, so you have to make your own timeout judgment.
Parameters
localVideoState State type LOCAL_VIDEO_STREAM_STATE. When the state is LOCAL_VIDEO_STREAM_STATE_FAILED(3), see the error parameter for details.
error The detailed error information. code LOCAL_VIDEO_STREAM_ERROR.

◆ OnLocalVideoStatsHandler()

delegate void agora_gaming_rtc.OnLocalVideoStatsHandler ( LocalVideoStats  localVideoStats )

Reports the statistics of the local video stream.

The SDK triggers this callback once every two seconds for each user/host. If there are multiple users/hosts in the channel, the SDK triggers this callback as many times.

Note
If you have called the EnableDualStreamMode method, the OnLocalVideoStatsHandler callback reports the statistics of the high-video stream (high bitrate, and high-resolution video stream).
Parameters
localVideoStats The statistics of the local video stream. See LocalVideoStats.

◆ OnLocalVoicePitchInHzHandler()

delegate void agora_gaming_rtc.OnLocalVoicePitchInHzHandler ( int  pitchInHz )

Reports the voice pitch of the local user.

Since
3.7.0

After the local audio capture is enabled and you call EnableLocalVoicePitchCallback, the SDK triggers this callback at the time interval set in EnableLocalVoicePitchCallback.

Note
After this callback is enabled, if the user disables the local audio capture, for example, by calling EnableLocalAudio(false), the SDK immediately stops sending the OnLocalVoicePitchInHzHandler callback.
Parameters
pitchInHz The voice pitch (Hz) of the local user.

◆ OnMediaEngineLoadSuccessHandler()

delegate void agora_gaming_rtc.OnMediaEngineLoadSuccessHandler ( )

Occurs when the media engine loads.

◆ OnMediaEngineStartCallSuccessHandler()

delegate void agora_gaming_rtc.OnMediaEngineStartCallSuccessHandler ( )

Occurs when the media engine call starts.

◆ OnMicrophoneEnabledHandler()

delegate void agora_gaming_rtc.OnMicrophoneEnabledHandler ( bool  isEnabled )

Occurs when the microphone is enabled/disabled.

Deprecated:
Use LOCAL_AUDIO_STREAM_STATE_STOPPED(0) or LOCAL_AUDIO_STREAM_STATE_RECORDING(1) in the OnLocalAudioStateChangedHandler callback instead.

The SDK triggers this callback when the local user resumes or stops capturing the local audio stream by calling the EnableLocalAudio method.

Parameters
isEnabled Whether the microphone is enabled/disabled:
  • true: Enabled.
  • false: Disabled.

◆ OnNetworkQualityHandler()

delegate void agora_gaming_rtc.OnNetworkQualityHandler ( uint  uid,
int  txQuality,
int  rxQuality 
)

Reports the last mile network quality of each user in the channel once every two seconds.

Last mile refers to the connection between the local device and the Agora edge server. This callback reports once every two seconds the last mile network conditions of each user in the channel. If a channel includes multiple users, the SDK triggers this callback as many times.

Parameters
uid User ID. The network quality of the user with this uid is reported. If uid is 0, the local network quality is reported.
txQuality Uplink transmission quality rating of the user in terms of the transmission bitrate, packet loss rate, average RTT (Round-Trip Time), and jitter of the uplink network. txQuality is a quality rating helping you understand how well the current uplink network conditions can support the selected VideoEncoderConfiguration. For example, a 1000 Kbps uplink network may be adequate for video frames with a resolution of 640 × 480 and a frame rate of 15 fps in the Live-broadcast profile, but may be inadequate for resolutions higher than 1280 × 720. See QUALITY_TYPE.
rxQuality Downlink network quality rating of the user in terms of the packet loss rate, average RTT, and jitter of the downlink network. See QUALITY_TYPE.

◆ OnNetworkTypeChangedHandler()

delegate void agora_gaming_rtc.OnNetworkTypeChangedHandler ( NETWORK_TYPE  type )

Occurs when the local network type changes.

When the network connection is interrupted, this callback indicates whether the interruption is caused by a network type change or poor network conditions.

Parameters
type See NETWORK_TYPE.

◆ OnProxyConnectedHandler()

delegate void agora_gaming_rtc.OnProxyConnectedHandler ( string  channel,
uint  uid,
PROXY_TYPE  proxyType,
string  localProxyIp,
int  elapsed 
)

Reports the proxy connection state.

Since
3.6.2

You can use this callback to listen for the state of the SDK connecting to a proxy. For example, when a user calls SetCloudProxy and joins a channel successfully, the SDK triggers this callback to report the user ID, the proxy type connected, and the time elapsed from the user calling joinChannel until this callback is triggered.

Parameters
channel The channel name.
uid The user ID.
proxyType The proxy type. See PROXY_TYPE.
localProxyIp Reserved for future use.
elapsed The time elapsed (ms) from the user calling joinChannel until this callback is triggered.

◆ OnReJoinChannelSuccessHandler()

delegate void agora_gaming_rtc.OnReJoinChannelSuccessHandler ( string  channelName,
uint  uid,
int  elapsed 
)

Occurs when a user rejoins the channel after disconnection due to network problems.

When a user loses connection with the server because of network problems, the SDK automatically tries to reconnect and triggers this callback upon reconnection.

Parameters
channelName The name of the channel that you rejoin.
uid The user ID of the user rejoining the channel.
elapsed The time elapsed (ms) from starting to reconnect until the SDK triggers this callback.

◆ OnRemoteAudioMixingBeginHandler()

delegate void agora_gaming_rtc.OnRemoteAudioMixingBeginHandler ( )

Occurs when a remote user starts audio mixing.

When a remote user calls StartAudioMixing to play the background music, the SDK reports this callback.

◆ OnRemoteAudioMixingEndHandler()

delegate void agora_gaming_rtc.OnRemoteAudioMixingEndHandler ( )

Occurs when a remote user finishes audio mixing.

◆ OnRemoteAudioStateChangedHandler()

delegate void agora_gaming_rtc.OnRemoteAudioStateChangedHandler ( uint  uid,
REMOTE_AUDIO_STATE  state,
REMOTE_AUDIO_STATE_REASON  reason,
int  elapsed 
)

Occurs when the remote audio state changes.

This callback indicates the state change of the remote audio stream.

Note
This callback does not work properly when the number of users (in the COMMUNICATION profile) or hosts (in the LIVE_BROADCASTING profile) in the channel exceeds 17.
Parameters
uid The ID of the remote user whose audio state changes.
state The state of the remote audio. See REMOTE_AUDIO_STATE.
reason The reason of the remote audio state change. See REMOTE_AUDIO_STATE_REASON.
elapsed Time elapsed (ms) from the local user calling the JoinChannelByKey method until the SDK triggers this callback.

◆ OnRemoteAudioStatsHandler()

delegate void agora_gaming_rtc.OnRemoteAudioStatsHandler ( RemoteAudioStats  remoteAudioStats )

Reports the statistics of the audio stream from each remote user/host.

This callback replaces the OnAudioQualityHandler callback.

The SDK triggers this callback once every two seconds for each remote user/host. If a channel includes multiple remote users, the SDK triggers this callback as many times.

Parameters
remoteAudioStats The statistics of the received remote audio streams. See RemoteAudioStats.

◆ OnRemoteAudioTransportStatsHandler()

delegate void agora_gaming_rtc.OnRemoteAudioTransportStatsHandler ( uint  uid,
ushort  delay,
ushort  lost,
ushort  rxKBitRate 
)

Reports the transport-layer statistics of each remote audio stream.

Deprecated:
This callback is deprecated and replaced by the OnRemoteAudioStatsHandler callback.

This callback reports the transport-layer statistics, such as the packet loss rate and network time delay, once every two seconds after the local user receives an audio packet from a remote user.

Parameters
uid User ID of the remote user sending the audio packet.
delay Network time delay (ms) from the remote user sending the audio packet to the local user.
lost Packet loss rate (%) of the audio packet sent from the remote user.
rxKBitRate Received bitrate (Kbps) of the audio packet sent from the remote user.

◆ OnRemoteSubscribeFallbackToAudioOnlyHandler()

delegate void agora_gaming_rtc.OnRemoteSubscribeFallbackToAudioOnlyHandler ( uint  uid,
bool  isFallbackOrRecover 
)

Occurs when the remote media stream falls back to audio-only stream due to poor network conditions or switches back to the video stream after the network conditions improve.

If you call SetRemoteSubscribeFallbackOption and set option as STREAM_FALLBACK_OPTION_AUDIO_ONLY(2), the SDK triggers this callback when the remote media stream falls back to audio-only mode due to poor uplink conditions, or when the remote media stream switches back to the video after the uplink network condition improves.

Note
Once the remotely subscribed media stream switches to the low stream due to poor network conditions, you can monitor the stream switch between a high and low stream in the RemoteVideoStats of the OnRemoteVideoStatsHandler callback.
Parameters
uid ID of the remote user sending the stream.
isFallbackOrRecover Whether the remotely subscribed media stream falls back to audio-only or switches back to the video:
  • true: The remotely subscribed media stream falls back to audio-only due to poor network conditions.
  • false: The remotely subscribed media stream switches back to the video stream after the network conditions improved.

◆ OnRemoteVideoStateChangedHandler()

delegate void agora_gaming_rtc.OnRemoteVideoStateChangedHandler ( uint  uid,
REMOTE_VIDEO_STATE  state,
REMOTE_VIDEO_STATE_REASON  reason,
int  elapsed 
)

Occurs when the remote video state changes.

Note
This callback does not work properly when the number of users (in the COMMUNICATION profile) or hosts (in the LIVE_BROADCASTING profile) in the channel exceeds 17.
Parameters
uid The ID of the remote user whose video state changes.
state The state of the remote video. See REMOTE_VIDEO_STATE.
reason The reason of the remote video state change. See REMOTE_VIDEO_STATE_REASON.
elapsed The time elapsed (ms) from the local user calling the JoinChannelByKey method until the SDK triggers this callback.

◆ OnRemoteVideoStatsHandler()

delegate void agora_gaming_rtc.OnRemoteVideoStatsHandler ( RemoteVideoStats  remoteVideoStats )

Reports the statistics of the video stream from each remote user/host.

The SDK triggers this callback once every two seconds for each remote user/host. If a channel includes multiple remote users, the SDK triggers this callback as many times.

Parameters
remoteVideoStats The statistics of the remote video stream. See RemoteVideoStats.

◆ OnRemoteVideoTransportStatsHandler()

delegate void agora_gaming_rtc.OnRemoteVideoTransportStatsHandler ( uint  uid,
ushort  delay,
ushort  lost,
ushort  rxKBitRate 
)

Reports the transport-layer statistics of each remote video stream.

Deprecated:
This callback is deprecated and replaced by the OnRemoteVideoStatsHandler callback.

This callback reports the transport-layer statistics, such as the packet loss rate and network time delay, once every two seconds after the local user receives a video packet from a remote user.

Parameters
uid User ID of the remote user sending the video packet.
delay Network time delay (ms) from the remote user sending the video packet to the local user.
lost Packet loss rate (%) of the video packet sent from the remote user.
rxKBitRate Received bitrate (Kbps) of the video packet sent from the remote user.

◆ OnRequestAudioFileInfoHandler()

delegate void agora_gaming_rtc.OnRequestAudioFileInfoHandler ( AudioFileInfo  info,
AUDIO_FILE_INFO_ERROR  error 
)

Reports the information of an audio file.

Since
v3.6.1.1

After successfully calling GetAudioFileInfo, the SDK triggers this callback to report the information of the audio file, such as the file path and duration.

Parameters
info The information of an audio file, see AudioFileInfo.
error The information acquisition state, see AUDIO_FILE_INFO_ERROR.

◆ OnRequestTokenHandler()

delegate void agora_gaming_rtc.OnRequestTokenHandler ( )

Occurs when the token expires.

After a token is specified by calling the JoinChannelByKey method, if the SDK losses connection with the Agora server due to network issues, the token may expire after a certain period of time and a new token may be required to reconnect to the server.

This callback notifies the app to generate a new token and call JoinChannelByKey to rejoin the channel with the new token.

◆ OnRtcStatsHandler()

delegate void agora_gaming_rtc.OnRtcStatsHandler ( RtcStats  stats )

Reports the statistics of the current call session once every two seconds.

Parameters
stats The RTC engine statistics: RtcStats.

◆ OnRtmpStreamingEventHandler()

delegate void agora_gaming_rtc.OnRtmpStreamingEventHandler ( string  url,
RTMP_STREAMING_EVENT  eventCode 
)

Reports events during the RTMP or RTMPS streaming.

Since
v3.2.0
Parameters
url The RTMP or RTMPS streaming URL.
eventCode The event code. See RTMP_STREAMING_EVENT

◆ OnRtmpStreamingStateChangedHandler()

delegate void agora_gaming_rtc.OnRtmpStreamingStateChangedHandler ( string  url,
RTMP_STREAM_PUBLISH_STATE  state,
RTMP_STREAM_PUBLISH_ERROR_TYPE  errCode 
)

Occurs when the state of the RTMP or RTMPS streaming changes.

The SDK triggers this callback to report the result of the local user calling the AddPublishStreamUrl or RemovePublishStreamUrl method.

This callback indicates the state of the RTMP or RTMPS streaming. When exceptions occur, you can troubleshoot issues by referring to the detailed error descriptions in the errCode parameter.

Parameters
url The CDN streaming URL.
state The RTMP or RTMPS streaming state. See: RTMP_STREAM_PUBLISH_STATE.
errCode The detailed error information for streaming. See: RTMP_STREAM_PUBLISH_ERROR_TYPE.

◆ OnScreenCaptureInfoUpdatedHandler()

delegate void agora_gaming_rtc.OnScreenCaptureInfoUpdatedHandler ( ScreenCaptureInfo  info )

Occurs when the screen sharing information is updated.

Since
v3.6.1.1

When you call StartScreenCaptureByDisplayId or StartScreenCaptureByScreenRect to start screen sharing and use the excludeWindowList attribute to block the specified window, the SDK triggers this callback if the window blocking fails.

Note
This callback is for Windows only.
Parameters
info The screen sharing information. See ScreenCaptureInfo.

◆ OnSDKErrorHandler()

delegate void agora_gaming_rtc.OnSDKErrorHandler ( int  error,
string  msg 
)

Reports an error during SDK runtime.

In most cases, the SDK cannot fix the issue and resume running. The SDK requires the application to take action or informs the user about the issue.

For example, the SDK reports an ERR_START_CALL(1002) error when failing to initialize a call. The application informs the user that the call initialization failed and invokes the LeaveChannel method to leave the channel.

Parameters
error The error code, see Error Code.
msg The error message.

◆ OnSDKWarningHandler()

delegate void agora_gaming_rtc.OnSDKWarningHandler ( int  warn,
string  msg 
)

Reports a warning during SDK runtime.

In most cases, the application can ignore the warning reported by the SDK because the SDK can usually fix the issue and resume running. For example, when losing connection with the server, the SDK may report WARN_LOOKUP_CHANNEL_TIMEOUT(104) and automatically try to reconnect.

Parameters
warn The warning code, see Warning Code.
msg The warning message.

◆ OnSnapshotTakenHandler()

delegate void agora_gaming_rtc.OnSnapshotTakenHandler ( string  channel,
uint  uid,
string  filePath,
int  width,
int  height,
int  errCode 
)

Reports the result of taking a video snapshot.

Since
v3.6.1.1

After a successful TakeSnapshot method call, the SDK triggers this callback to report whether the snapshot is successfully taken as well as the details for the snapshot taken.

Parameters
channel The channel name.
uid The user ID of the user. A uid of 0 indicates the local user.
filePath The local path of the snapshot.
width The width (px) of the snapshot.
height The height (px) of the snapshot.
errCode The message that confirms success or the reason why the snapshot is not successfully taken:
  • 0: Success.
  • < 0: Failure:
    • -1: The SDK fails to write data to a file or encode a JPEG image.
    • -2: The SDK does not find the video stream of the specified user within one second after the TakeSnapshot method call succeeds.

◆ OnStreamMessageErrorHandler()

delegate void agora_gaming_rtc.OnStreamMessageErrorHandler ( uint  userId,
int  streamId,
int  code,
int  missed,
int  cached 
)

Occurs when the local user does not receive the data stream from the remote user within five seconds.

The SDK triggers this callback when the local user fails to receive the stream message that the remote user sends by calling the SendStreamMessage method.

Parameters
userId The user ID of the remote user sending the message.
streamId The stream ID.
code The error code: Error Code.
missed The number of lost messages.
cached The number of incoming cached messages when the data stream is interrupted.

◆ OnStreamMessageHandler()

delegate void agora_gaming_rtc.OnStreamMessageHandler ( uint  userId,
int  streamId,
byte[]  data,
int  length 
)

Occurs when the local user receives the data stream from the remote user within five seconds.

The SDK triggers this callback when the local user receives the stream message that the remote user sends by calling the SendStreamMessage method.

Parameters
userId The user ID of the remote user sending the message.
streamId The stream ID.
data The data received by the local user.
length The length of the data in bytes.

◆ OnStreamPublishedHandler()

delegate void agora_gaming_rtc.OnStreamPublishedHandler ( string  url,
int  error 
)

Reports the result of calling the AddPublishStreamUrl method. (CDN live only.)

Deprecated:
v3.0.1 This method is deprecated. Use OnRtmpStreamingStateChangedHandler instead.
Parameters
url The CDN streaming URL.
error Error code: Error Code.
  • ERR_OK(0): The publishing succeeds.
  • ERR_FAILED(1): The publishing fails.
  • ERR_INVALID_ARGUMENT(2): Invalid argument used. If, for example, you did not call SetLiveTranscoding to configure LiveTranscoding before calling AddPublishStreamUrl, the SDK reports ERR_INVALID_ARGUMENT(2).
  • ERR_TIMEDOUT(10): The publishing timed out.
  • ERR_ALREADY_IN_USE(19): The chosen URL address is already in use for CDN live streaming.
  • ERR_RESOURCE_LIMITED(22): The backend system does not have enough resources for the CDN live streaming.
  • ERR_ENCRYPTED_STREAM_NOT_ALLOWED_PUBLISH(130): You cannot publish an encrypted stream.
  • ERR_PUBLISH_STREAM_CDN_ERROR(151)
  • ERR_PUBLISH_STREAM_NUM_REACH_LIMIT(152)
  • ERR_PUBLISH_STREAM_NOT_AUTHORIZED(153)
  • ERR_PUBLISH_STREAM_INTERNAL_SERVER_ERROR(154)
  • ERR_PUBLISH_STREAM_FORMAT_NOT_SUPPORTED(156)

◆ OnStreamUnpublishedHandler()

delegate void agora_gaming_rtc.OnStreamUnpublishedHandler ( string  url )

Reports the result of calling the RemovePublishStreamUrl method. (CDN live only.)

Deprecated:
v3.0.1 This method is deprecated. Use OnRtmpStreamingStateChangedHandler instead.

This callback indicates whether you have successfully removed an RTMP or RTMPS stream from the CDN.

Parameters
url The CDN streaming URL.

◆ OnTokenPrivilegeWillExpireHandler()

delegate void agora_gaming_rtc.OnTokenPrivilegeWillExpireHandler ( string  token )

Occurs when the token expires in 30 seconds.

The user becomes offline if the token used in the JoinChannelByKey method expires. The SDK triggers this callback 30 seconds before the token expires to remind the application to get a new token. Upon receiving this callback, generate a new token on the server and call the RenewToken method to pass the new token to the SDK.

Parameters
token The token that expires in 30 seconds.

◆ OnTranscodingUpdatedHandler()

delegate void agora_gaming_rtc.OnTranscodingUpdatedHandler ( )

Occurs when the publisher's transcoding is updated.

When the LiveTranscoding class in the SetLiveTranscoding method updates, the SDK triggers the OnTranscodingUpdatedHandler callback to report the update information to the local host.

Note
If you call the SetLiveTranscoding method to set the LiveTranscoding class for the first time, the SDK does not trigger the OnTranscodingUpdatedHandler callback.

◆ OnUserEnableLocalVideoHandler()

delegate void agora_gaming_rtc.OnUserEnableLocalVideoHandler ( uint  uid,
bool  enabled 
)

Occurs when a specified remote user enables/disables the local video capturing function.

Deprecated:
This callback is deprecated and replaced by the OnRemoteVideoStateChangedHandler callback with the following parameters:

This callback is only applicable to the scenario when the user only wants to watch the remote video without sending any video stream to the other user.

The SDK triggers this callback when the remote user resumes or stops capturing the video stream by calling the EnableLocalVideo method.

Parameters
uid User ID of the remote user.
enabled Whether the specified remote user enables/disables the local video capturing function:
  • true: Enable. Other users in the channel can see the video of this remote user.
  • false: Disable. Other users in the channel can no longer receive the video stream from this remote user, while this remote user can still receive the video streams from other users.

◆ OnUserEnableVideoHandler()

delegate void agora_gaming_rtc.OnUserEnableVideoHandler ( uint  uid,
bool  enabled 
)

Occurs when a specific remote user enables/disables the video module.

Deprecated:
This callback is deprecated and replaced by the OnRemoteVideoStateChangedHandler callback with the following parameters:

Once the video module is disabled, the remote user can only use a voice call. The remote user cannot send or receive any video from other users.

The SDK triggers this callback when the remote user enables or disables the video module by calling the EnableVideo or DisableVideo method.

Note
This callback returns invalid when the number of users in a channel exceeds 20.
Parameters
uid User ID of the remote user.
enabled Whether the specified remote user enables/disables the local video capturing function:
  • true: Enable. The remote user can enter a video session.
  • false: Disable. The remote user can only enter a voice session, and cannot send or receive any video stream.

◆ OnUserInfoUpdatedHandler()

delegate void agora_gaming_rtc.OnUserInfoUpdatedHandler ( uint  uid,
UserInfo  userInfo 
)

Occurs when the SDK gets the user ID and user account of the remote user.

After a remote user joins the channel, the SDK gets the UID and user account of the remote user, caches them in a mapping table object (userInfo), and triggers this callback on the local client.

Parameters
uid The ID of the remote user.
userInfo The UserInfo object that contains the user ID and user account of the remote user.

◆ OnUserJoinedHandler()

delegate void agora_gaming_rtc.OnUserJoinedHandler ( uint  uid,
int  elapsed 
)

Occurs when a remote user (Communication)/ host (Live Broadcast) joins the channel.

  • Communication profile: This callback notifies the application that another user joins the channel. If other users are already in the channel, the SDK also reports to the application on the existing users.
  • Live-broadcast profile: This callback notifies the application that the host joins the channel. If other hosts are already in the channel, the SDK also reports to the application on the existing hosts. We recommend limiting the number of hosts to 17.

The SDK triggers this callback under one of the following circumstances:

  • A remote user/host joins the channel by calling the JoinChannelByKey method.
  • A remote user switches the user role to the host by calling the SetClientRole method after joining the channel.
  • A remote user/host rejoins the channel after a network interruption.
Note
In the Live-broadcast profile:
  • The host receives this callback when another host joins the channel.
  • The audience in the channel receives this callback when a new host joins the channel.
  • When a web application joins the channel, the SDK triggers this callback as long as the web application publishes streams.
Parameters
uid The user ID of the user or host joining the channel.
elapsed Time delay (ms) from the local user calling the JoinChannelByKey method until the SDK triggers this callback.

◆ OnUserMutedAudioHandler()

delegate void agora_gaming_rtc.OnUserMutedAudioHandler ( uint  uid,
bool  muted 
)

Occurs when a remote user's audio stream playback pauses/resumes.

Deprecated:
This method is deprecated from v3.0.1, use the OnRemoteAudioStateChangedHandler callback instead.

The SDK triggers this callback when the remote user stops or resumes sending the audio stream by calling the MuteLocalAudioStream method.

Note
This callback does not work properly when the number of users (in the COMMUNICATION profile) or hosts (in the LIVE_BROADCASTING profile) in the channel exceeds 17.
Parameters
uid The user ID of the remote user.
muted Whether the remote user's audio stream is muted/unmuted:
  • true: Muted.
  • false: Unmuted.

◆ OnUserMuteVideoHandler()

delegate void agora_gaming_rtc.OnUserMuteVideoHandler ( uint  uid,
bool  muted 
)

Occurs when a remote user's video stream playback pauses/resumes.

You can also use the OnRemoteVideoStateChangedHandler callback with the following parameters:

The SDK triggers this callback when the remote user stops or resumes sending the video stream by calling the MuteLocalVideoStream method.

Note
This callback does not work properly when the number of users (in the COMMUNICATION profile) or hosts (in the LIVE_BROADCASTING profile) in the channel exceeds 17.
Parameters
uid The user ID of the remote user.
muted Whether the remote user's video stream playback is paused/resumed:
  • true: Paused.
  • false: Resumed.

◆ OnUserOfflineHandler()

delegate void agora_gaming_rtc.OnUserOfflineHandler ( uint  uid,
USER_OFFLINE_REASON  reason 
)

Occurs when a remote user (Communication)/host (Live Broadcast) leaves the channel.

Reasons why the user is offline:

  • Leave the channel: When the user/host leaves the channel, the user/host sends a goodbye message. When the message is received, the SDK assumes that the user/host leaves the channel.
  • Drop offline: When no data packet of the user or host is received for a certain period of time (20 seconds for the Communication profile, and more for the Live-broadcast profile), the SDK assumes that the user/host drops offline. Unreliable network connections may lead to false detections, so we recommend using the Agora RTM SDK for more reliable offline detection.
Parameters
uid The user ID of the user leaving the channel or going offline.
reason The reason why the user is offline: USER_OFFLINE_REASON.

◆ OnUserSuperResolutionEnabledHandler()

delegate void agora_gaming_rtc.OnUserSuperResolutionEnabledHandler ( uint  uid,
bool  enabled,
SUPER_RESOLUTION_STATE_REASON  reason 
)

Reports whether the super-resolution algorithm is enabled.

Since
v3.5.1

After calling EnableRemoteSuperResolution, the SDK triggers this callback to report whether the super-resolution algorithm is successfully enabled. If not successfully enabled, you can use reason for troubleshooting.

Parameters
uid The ID of the remote user.
enabled Whether the super-resolution algorithm is successfully enabled:
  • true: The super-resolution algorithm is successfully enabled.
  • false: The super-resolution algorithm is not successfully enabled.
reason The reason why the super-resolution algorithm is not successfully enabled. See SUPER_RESOLUTION_STATE_REASON.

◆ OnVideoDeviceStateChangedHandler()

delegate void agora_gaming_rtc.OnVideoDeviceStateChangedHandler ( string  deviceId,
int  deviceType,
int  deviceState 
)

Occurs when the video device state changes.

Note
On a Windows device with an external camera for video capturing, the video disables once the external camera is unplugge
Parameters
deviceId The device ID of the video device that changes state.
deviceType The device type: MEDIA_DEVICE_TYPE.
deviceState The device state: MEDIA_DEVICE_STATE_TYPE.

◆ OnVideoPublishStateChangedHandler()

delegate void agora_gaming_rtc.OnVideoPublishStateChangedHandler ( string  channel,
STREAM_PUBLISH_STATE  oldState,
STREAM_PUBLISH_STATE  newState,
int  elapseSinceLastState 
)

Occurs when the video publishing state changes.

Since
v3.2.0

This callback indicates the publishing state change of the local video stream.

Parameters
channel The channel name.
oldState The previous publishing state. For details, see STREAM_PUBLISH_STATE.
newState The current publishing state. For details, see STREAM_PUBLISH_STATE.
elapseSinceLastState The time elapsed (ms) from the previous state to the current state.

◆ OnVideoSizeChangedHandler()

delegate void agora_gaming_rtc.OnVideoSizeChangedHandler ( uint  uid,
int  width,
int  height,
int  rotation 
)

Occurs when the video size or rotation of a specified user changes.

Parameters
uid The user ID of the remote user or local user (0) whose video size or rotation changes.
width The new width (pixels) of the video.
height The new height (pixels) of the video.
rotation The new rotation of the video [0 to 360).

◆ OnVideoStoppedHandler()

delegate void agora_gaming_rtc.OnVideoStoppedHandler ( )

Occurs when the video stops playing.

Deprecated:
Deprecated as of v2.4.1. Use LOCAL_VIDEO_STREAM_STATE_STOPPED(0) in the OnLocalVideoStateChangedHandler callback instead.

The application can use this callback to change the configuration of the view (for example, displaying other pictures in the view) after the video stops playing.

◆ OnVideoSubscribeStateChangedHandler()

delegate void agora_gaming_rtc.OnVideoSubscribeStateChangedHandler ( string  channel,
uint  uid,
STREAM_SUBSCRIBE_STATE  oldState,
STREAM_SUBSCRIBE_STATE  newState,
int  elapseSinceLastState 
)

Occurs when the audio subscribing state changes.

Since
v3.2.0

This callback indicates the subscribing state change of a remote video stream.

Parameters
channel The channel name.
uid The ID of the remote user.
oldState The previous subscribing state. For details, see STREAM_SUBSCRIBE_STATE.
newState The current subscribing state. For details, see STREAM_SUBSCRIBE_STATE.
elapseSinceLastState The time elapsed (ms) from the previous state to the current state.

◆ OnVirtualBackgroundSourceEnabledHandler()

delegate void agora_gaming_rtc.OnVirtualBackgroundSourceEnabledHandler ( bool  enabled,
VIRTUAL_BACKGROUND_SOURCE_STATE_REASON  reason 
)

Reports whether the virtual background is successfully enabled.

After you call EnableVirtualBackground, the SDK triggers this callback to report whether the virtual background is successfully enabled.

Note
If the background image customized in the virtual background is in PNG or JPG format, the triggering of this callback is delayed until the image is read.
Parameters
enabled Whether the virtual background is successfully enabled:
  • true: The virtual background is successfully enabled.
  • false: The virtual background is not successfully enabled.
reason The reason why the virtual background is not successfully enabled or the message that confirms success. See VIRTUAL_BACKGROUND_SOURCE_STATE_REASON.

◆ OnVolumeIndicationHandler()

delegate void agora_gaming_rtc.OnVolumeIndicationHandler ( AudioVolumeInfo[]  speakers,
int  speakerNumber,
int  totalVolume 
)

Reports the volume information of users.

By default, this callback is disabled. You can enable it by calling EnableAudioVolumeIndication. Once this callback is enabled and users send streams in the channel, the SDK triggers the OnVolumeIndicationHandler callback at the time interval set in EnableAudioVolumeIndication.

The SDK triggers two independent OnVolumeIndicationHandler callbacks simultaneously, which separately report the volume information of the local user who sends a stream and the remote users (up to three) whose instantaneous volumes are the highest.

Note
After you enable this callback, calling MuteLocalAudioStream affects the SDK's behavior as follows:
  • If the local user calls MuteLocalAudioStream, the SDK stops triggering the local user's callback.
  • 20 seconds after a remote user whose volume is one of the three highest calls MuteLocalAudioStream, the remote users' callback excludes this remote user's information; 20 seconds after all remote users call MuteLocalAudioStream, the SDK stops triggering the remote users' callback.
Parameters
speakers The volume information of users. See AudioVolumeInfo.

An empty speakers array in the callback indicates that no remote user is in the channel or sending a stream at the moment.

Parameters
speakerNumber Total number of users.
  • In the local user's callback, when the local user sends a stream, speakerNumber = 1.
  • In the remote users' callback, the value ranges between 0 and 3. If the number of remote users who send streams is greater than or equal to three, speakerNumber = 3.
totalVolume Total volume after audio mixing. The value ranges between 0 (lowest volume) and 255 (highest volume).
  • In the local user's callback, totalVolume is the volume of the local user who sends a stream.
  • In the remote users' callback, totalVolume is the sum of the volume of all remote users (up to three) whose instantaneous volumes are the highest.

If the user calls StartAudioMixing, totalVolume is the sum of the voice volume and audio-mixing volume.