Typedefs | |
typedef unsigned int | uid_t |
typedef void * | view_t |
typedef struct agora::rtc::TranscodingUser | TranscodingUser |
typedef struct agora::rtc::RtcImage | RtcImage |
typedef struct agora::rtc::LiveTranscoding | LiveTranscoding |
typedef struct agora::rtc::Rect | Rect |
typedef struct agora::rtc::WatermarkOptions | WatermarkOptions |
Variables | |
const int | STANDARD_BITRATE = 0 |
const int | COMPATIBLE_BITRATE = -1 |
const int | DEFAULT_MIN_BITRATE = -1 |
typedef unsigned int agora::rtc::uid_t |
typedef void* agora::rtc::view_t |
typedef struct agora::rtc::TranscodingUser agora::rtc::TranscodingUser |
The video and audio properties of the user displaying the video in the CDN live. Agora supports a maximum of 17 transcoding users in a CDN streaming channel.
typedef struct agora::rtc::RtcImage agora::rtc::RtcImage |
Image properties.
The properties of the watermark and background images.
typedef struct agora::rtc::LiveTranscoding agora::rtc::LiveTranscoding |
A struct for managing CDN live audio/video transcoding settings.
typedef struct agora::rtc::Rect agora::rtc::Rect |
DEPRECATED Definition of the rectangular region.
typedef struct agora::rtc::WatermarkOptions agora::rtc::WatermarkOptions |
The options of the watermark image to be added.
The states of the local user's audio mixing file.
Enumerator | |
---|---|
AUDIO_MIXING_STATE_PLAYING | 710: The audio mixing file is playing. |
AUDIO_MIXING_STATE_PAUSED | 711: The audio mixing file pauses playing. |
AUDIO_MIXING_STATE_STOPPED | 713: The audio mixing file stops playing. |
AUDIO_MIXING_STATE_FAILED | 714: An exception occurs when playing the audio mixing file. See AUDIO_MIXING_ERROR_TYPE. |
The error codes of the local user's audio mixing file.
Media device types.
Local video state error codes
Local audio state types.
Local audio state error codes.
Audio recording qualities.
Network quality types.
Video display modes.
DEPRECATED Video profiles.
Audio profiles.
Sets the sample rate, bitrate, encoding mode, and the number of channels:
Audio application scenarios.
The channel profile of the Agora RtcEngine.
Reasons for a user being offline.
States of the RTMP streaming.
Enumerator | |
---|---|
RTMP_STREAM_PUBLISH_STATE_IDLE | The RTMP streaming has not started or has ended. This state is also triggered after you remove an RTMP address from the CDN by calling removePublishStreamUrl. |
RTMP_STREAM_PUBLISH_STATE_CONNECTING | 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 | The RTMP streaming publishes. The SDK successfully publishes the RTMP streaming and returns this state. |
RTMP_STREAM_PUBLISH_STATE_RECOVERING | The RTMP streaming is recovering. When exceptions occur to the CDN, or the streaming is interrupted, the SDK tries to resume RTMP streaming and returns this state.
|
RTMP_STREAM_PUBLISH_STATE_FAILURE | The RTMP streaming fails. See the errCode parameter for the detailed error information. You can also call the addPublishStreamUrl method to publish the RTMP streaming again. |
Error codes of the RTMP streaming.
Enumerator | |
---|---|
RTMP_STREAM_PUBLISH_ERROR_OK | The RTMP 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 streaming is encrypted and cannot be published. |
RTMP_STREAM_PUBLISH_ERROR_CONNECTION_TIMEOUT | Timeout for the RTMP 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 RTMP server. |
RTMP_STREAM_PUBLISH_ERROR_TOO_OFTEN | The RTMP 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 streaming. |
RTMP_STREAM_PUBLISH_ERROR_FORMAT_NOT_SUPPORTED | The format of the RTMP streaming URL is not supported. Check whether the URL format is correct. |
States of importing an external video stream in a live broadcast.
The use mode of the audio data in the onRecordAudioFrame or onPlaybackAudioFrame callback.
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 SDK, then push the RTMP 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. |
Video codec profile types.
Audio equalization band frequencies.
Audio reverberation types.
Local voice changer options.
Local voice reverberation presets.
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 reasons.
Remote video states. 1: The remote video is playing. 2: The remote video is frozen. 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). |
The reason of the remote video state change.
Video output orientation modes.
Video degradation preferences when the bandwidth is a constraint.
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. |
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. |
Connection states.
Enumerator | |
---|---|
CONNECTION_STATE_DISCONNECTED | 1: The SDK is disconnected from Agora's edge server.
|
CONNECTION_STATE_CONNECTING | 2: The SDK is connecting to Agora's edge server.
|
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.
|
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 joinChannel 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 onConnectionBanned (deprecated) and onConnectionStateChanged callbacks. |
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 connection between the SDK and Agora's edge server is banned by Agora's edge 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:
|
CONNECTION_CHANGED_TOKEN_EXPIRED | 9: The connection failed since token is expired. |
CONNECTION_CHANGED_REJECTED_BY_SERVER | 10: The connection is rejected by server. |
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). |
Network type.
States of the last-mile network probe test.
Audio session restriction.
Quality change of the local video in terms of target frame rate and target bit rate since last count.
The error code in 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. |
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. |
The event code in CHANNEL_MEDIA_RELAY_EVENT.
The state code in CHANNEL_MEDIA_RELAY_STATE.
DEPRECATED Lifecycle of the CDN live video stream.
Content hints for screen sharing.
const int agora::rtc::STANDARD_BITRATE = 0 |
(Recommended) The standard bitrate set in the setVideoEncoderConfiguration method.
In this mode, the bitrates differ between the live broadcast and communication profiles:
const int agora::rtc::COMPATIBLE_BITRATE = -1 |
The compatible bitrate set in the setVideoEncoderConfiguration method.
The bitrate remains the same regardless of the channel profile. If you choose this mode in the Live-broadcast profile, the video frame rate may be lower than the set value.
const int agora::rtc::DEFAULT_MIN_BITRATE = -1 |
Use the default minimum bitrate.