This topic describes the data structures that the SDK for macOS uses.
Contents
Data type | Description |
User volume information. | |
Audio sample. | |
Video sample. | |
Channel mode. | |
User role. | |
Session statistics. | |
Local video statistics. | |
Remote video statistics. | |
Local audio statistics. | |
Remote audio statistics. | |
Video data output position. | |
Video data format. | |
External device type. | |
External device state. | |
Network connection status. | |
Reason for a network connection status change. | |
Video stream type. | |
Stream ingest state. | |
Subscription state. | |
Reason why a user went offline. | |
Camera stream type. | |
Audio stream type. | |
Network quality. | |
Rendering mode. | |
Mirror mode. | |
Rotation angle. | |
Log level. | |
The number of sound channels. | |
Audio recording sample rate. | |
Record type. | |
Record format | |
Audio quality of the recorded audio file. | |
Video quality of the recorded video file. | |
Video codec type. | |
Video encoding type. | |
Audio quality. | |
Audio quality mode. | |
Audio scenario mode parameter. | |
Local mute mode. | |
Audio recording settings. | |
Video recording settings. | |
Canvas size for video recording settings. | |
Device information. | |
Enumeration of OnBye types. | |
Voice changer effect mode. | |
Reverb effect mode. | |
Reverb effect parameters. | |
Rendering canvas. | |
Bypass stream ingest error code. | |
Watermark image settings. | |
Camera capture preference properties. | |
Specifies the camera capture resolution. | |
Camera capture preference. | |
Video encoding frame rate. | |
Video encoding bitrate. | |
Encoded video mirror mode. | |
Encoded video rotation mode. | |
Video encoding preferences. | |
Screen sharing encoding preferences. | |
Screen sharing configuration. | |
Screen sharing region. | |
Screen sharing source information. | |
Screen sharing configuration information. | |
Screen sharing type. | |
Authentication information. | |
Raw video data source type. | |
Raw audio data source type. | |
Video data type. | |
Error code. | |
Alignment mode for video output width. | |
Dashboard display type. | |
Bypass LiveStream ingest status. | |
Display type for images in bypass live streaming. | |
Font type for text in bypass live streaming. | |
Input segmentation type for bypass live streaming. | |
Input source type for bypass live streaming. | |
Video stream state change. | |
Reason for a video stream state change. | |
Cropping mode for bypass live streaming. | |
Media processing mode for bypass live streaming. | |
Stream type for bypass live streaming. | |
Mode for bypass live streaming. | |
Status of bypass live streaming. | |
Text information for bypass live streaming. | |
Image information for bypass live streaming. | |
Custom user stream information for bypass live streaming. | |
Configuration for bypass live streaming. | |
Stream mixing parameters for bypass mode. | |
Single-stream parameters for bypass mode. | |
Billing specifications for bypass live streaming. | |
Encoding parameters for bypass live streaming. | |
Audio sample rate for bypass live streaming. | |
Clock widget for bypass live streaming. | |
Network quality. | |
A profile that aggregates features. This is one of the parameters for joining a channel. | |
Parameters for joining a channel. | |
Parameter settings for network probing. | |
Network probing result. | |
Audio frame struct. | |
AliRtcVideoPipelineMirrorMode: Specifies the mirror mode of the video pipeline. | Video pipeline mirror type. |
AliRtcCapturePipelineScaleMode: The scaling type of the capture pipeline. | Capture pipeline scaling type. |
Configuration for audio accompaniment playback. | |
Audio file information. | |
Raw video data. | |
Data message definition. | |
Data message type. | |
Local device type. | |
Current device exception type. | |
Callback for the local audio capture state. | |
Callback for the local video capture state. | |
Playback state of the audio accompaniment. | |
Error code for audio accompaniment playback. | |
Video encoder for bypass live streaming. |
Details
AliRtcUserVolumeInfo: User volume information.
Parameter | Type | Description |
uid | NSString * _Nonnull | The UID of the user. Valid values:
|
volume | int | The volume in the current callback. |
speech_state | BOOL | Indicates whether the user is speaking. `true`: The user is speaking. `false`: The user is not speaking. |
AliRtcAudioDataSample: Audio sample.
Parameter | Type | Description |
dataPtr | long | A pointer to the audio data. |
numOfSamples | int | The number of sample points for each sound channel. |
bytesPerSample | int | The number of bytes per sample point. For Pulse-Code Modulation (PCM) data, the value is typically 16 bits, which is 2 bytes. |
numOfChannels | int | The number of sound channels. Valid values:
|
samplesPerSec | int | The number of sample points per channel per second, which is the sample rate. |
AliRtcVideoDataSample: Video sample.
Parameter | Type | Description |
format | The video data format. | |
type | The video data type. | |
pixelBuffer | CVPixelBufferRef _Nullable | The pixel buffer data. |
dataPtr | long | A pointer to the YUV data. |
dataYPtr | long | A pointer to the Y component. |
dataUPtr | long | A pointer to the U component. |
dataVPtr | long | A pointer to the V component. |
dataLength | long | The data size. |
strideY | int | The stride of the Y buffer in the YUV data. |
strideU | int | The stride of the U buffer in the YUV data. |
strideV | int | The stride of the V buffer in the YUV data. |
stride | int | The stride for the RGB format. |
height | int | The height of the video frame. |
width | int | The width of the video frame. |
rotation | int | The rotation angle of the video frame. |
timeStamp | long long | The timestamp. |
encodeCostMs | int | The time consumed for encoding. |
AliRtcChannelProfile: Channel mode.
Enum name | Description |
AliRtcCommunication | Communication mode. |
AliRtcInteractivelive | Interactive mode. |
AliRtcInteractiveWithLowLatencyLive | Low-latency interactive live streaming mode. |
AliRtcClientRole: User role.
Enum name | Description |
AliRtcClientRoleInteractive | Streamer. |
AliRtcClientRolelive | Viewer. |
AliRtcStats: Session statistics.
Parameter | Type | Description |
sent_kbitrate | long long | The sending bitrate. |
rcvd_kbitrate | long long | The receiving bitrate. |
sent_bytes | long long | The number of bytes sent. |
rcvd_bytes | long long | The number of bytes received. |
systemCpuUsage | float | The system CPU usage. |
cpu_usage | float | The CPU usage of the RTC process. |
video_rcvd_kbitrate | long | The video receiving bitrate. |
video_sent_kbitrate | long | The video sending bitrate. |
call_duration | long | The call duration, in seconds. |
sent_loss_rate | long | The packet loss rate from the client to the server. |
sent_loss_pkts | long long | The number of lost packets from the client to the server. |
sent_expected_pkts | long long | The total number of packets sent from the client to the server. |
rcvd_loss_rate | long long | The packet loss rate on the downlink from the server to the client. |
rcvd_loss_pkts | long long | The number of downstream lost packets from the server to the client. |
rcvd_expected_pkts | long long | The total number of downstream packets from the server to the client. |
lastmile_delay | int | The latency, in milliseconds (ms). |
available_sent_kbitrate | long long | The available sending bandwidth, in kbps. |
AliRtcLocalVideoStats: Local video statistics.
Parameter | Type | Description |
track | The stream type. | |
capture_width | unsigned int | The capture width. |
capture_height | unsigned int | The capture height. |
encode_width | unsigned int | The encoding width. |
encode_height | unsigned int | The encoding height. |
sent_bitrate | unsigned int | The publishing bitrate. |
sent_fps | unsigned int | The publishing frame rate. |
encode_fps | unsigned int | The encoding frame rate. |
target_encode_bitrate | unsigned int | The target encoding bitrate. |
actual_encode_bitrate | unsigned int | The actual encoding bitrate. |
capture_fps | unsigned int | The capture frame rate. |
AliRtcRemoteVideoStats: Remote video statistics.
Parameter | Type | Description |
userId | NSString * _Nonnull | The user ID. |
track | The video stream type. | |
width | unsigned int | The width. |
height | unsigned int | High. |
decode_fps | unsigned int | The output frame rate of the encoder. |
render_fps | unsigned int | The output frame rate of the renderer. |
frozen_times | unsigned int | The number of freezes. |
video_total_frozen_time | unsigned int | The total freeze duration of video playback, in ms. |
video_total_frozen_rate | unsigned int | The total freeze rate of video playback, in percentage (%). Formula: Total freeze rate = Total video freeze duration / Total video playback duration. |
AliRtcLocalAudioStats: Local audio statistics.
Parameter | Type | Description |
track | The audio stream type. | |
sent_bitrate | int | The sending bitrate, in Kbps. |
sent_samplerate | int | The sending sample rate. |
num_channel | int | The number of sound channels. |
send_loss | int | The sending packet loss rate. |
AliRtcRemoteAudioStats: Remote audio statistics.
Parameter | Type | Description |
userId | NSString * _Nonnull | The UID of the remote user. |
track | The audio stream type. | |
sample_rate | unsigned int | The sample rate. |
channels | unsigned int | The number of sound channels. |
quality | unsigned int | The audio quality. |
audio_loss_rate | unsigned int | The audio frame loss rate within the callback period. |
rcvd_bitrate | unsigned int | The instantaneous bitrate of the received stream, in Kbps. |
totalFrozenTimes | unsigned int | The number of freezes. |
network_transport_delay | unsigned int | The network latency from the sender to the receiver, in milliseconds (ms). |
jitter_buffer_delay | unsigned int | The network latency from the receiver to the anti-jitter buffer, in milliseconds (ms). |
AliRtcVideoObserPosition: Video data output position.
Enum name | Description |
AliRtcPositionPostCapture | Captured video data. |
AliRtcPositionPreRender | Video data for rendering. |
AliRtcPositionPreEncoder | Video data before encoding. |
AliRtcVideoFormat: Video data format.
Enum name | Description |
AliRtcVideoFormat_UNKNOW | Unknown. |
AliRtcVideoFormat_BGRA | BGRA. |
AliRtcVideoFormat_I420 | I420. |
AliRtcVideoFormat_NV21 | NV21. |
AliRtcVideoFormat_NV12 | NV12. |
AliRtcVideoFormat_RGBA | RGBA. |
AliRtcVideoFormat_I422 | I422. |
AliRtcVideoFormat_ARGB | ARGB. |
AliRtcVideoFormat_ABGR | ABGR. |
AliRtcVideoFormat_RGB24 | RGB24. |
AliRtcVideoFormat_BGR24 | BGR24. |
AliRtcVideoFormat_RGB565 | RGB565. |
AliRtcVideoFormat_TextureOES | OES texture. |
AliRtcVideoFormat_Texture2D | Texture2D texture. |
AliRtcVideoFormat_H264 | H.264 encoded stream. |
AliRtcVideoFormat_H265 | H.265 encoded stream. |
AliRtcVideoFormat_File | File. |
AliRtcLiveTranscodingVideoCodec: Video encoder for bypass live streaming.
Enum name | Description |
AliRtcLiveTranscodingVideoCodec_H264 | H.264 |
AliRtcLiveTranscodingVideoCodec_H265 | H.265 |
AliRtcConnectionStatus: Network connection status.
Enum name | Description |
AliRtcConnectionStatusInit | Initialization is complete. |
AliRtcConnectionStatusDisconnected | The network connection is disconnected. |
AliRtcConnectionStatusConnecting | Connecting to the network. |
AliRtcConnectionStatusConnected | The network is connected. |
AliRtcConnectionStatusReconnecting | Reconnecting to the network. |
AliRtcConnectionStatusFailed | The network connection failed. |
AliRtcConnectionStatusChangeReason: Reason for a network connection status change.
Enum name | Description |
AliRtcConnectionChangedDummyReason | Unknown reason. |
AliRtcConnectionChangedMediaPathChanged | The media channel changed. |
AliRtcConnectionChangedSignalingHeartbeatTimeout | Heartbeat timeout. |
AliRtcConnectionChangedSignalingHeartbeatAlive | Heartbeat recovered. |
AliRtcConnectionChangedSignalingHttpdnsResolved | DNS resolution is successful. |
AliRtcConnectionChangedSignalingHttpdnsFailure | DNS resolution failed. |
AliRtcConnectionChangedSignalingGslbFailure | GSLB request failed. |
AliRtcConnectionChangedSignalingGslbSucccess | GSLB request is successful. |
AliRtcConnectionChangedSignalingJoinChannelFailure | Failed to join the channel. |
AliRtcConnectionChangedSignalingJoinChannelSuccess | Joined the channel. |
AliRtcConnectionChangedSignalingLeaveRoom | Left the channel. |
AliRtcConnectionChangedSignalingConnecting | Establishing a signaling connection. |
AliRtcVideoTrack: Video stream type.
Enum name | Description |
AliRtcVideoTrackNo | No video stream. |
AliRtcVideoTrackCamera | Camera stream. |
AliRtcVideoTrackScreen | Screen sharing stream. |
AliRtcVideoTrackBoth | Camera and screen sharing streams. |
AliRtcPublishState: Stream ingest state.
Enum name | Description |
AliRtcStatsPublishIdle | Initial state. |
AliRtcStatsNoPublish | Not published. |
AliRtcStatsPublishing | Publishing. |
AliRtcStatsPublished | Published. |
AliRtcSubscribeState: Subscription state.
Enum name | Description |
AliRtcStatsSubscribeIdle | Initial state. |
AliRtcStatsNoSubscribe | Not subscribed. |
AliRtcStatsSubscribing | Subscribing. |
AliRtcStatsSubscribed | Subscribed. |
AliRtcUserOfflineReason: Reason why a user went offline.
Enum name | Description |
AliRtcUserOfflineQuit | The user left the channel voluntarily. |
AliRtcUserOfflineDropped | The user is dropped due to a connection timeout. This occurs if no data packets are received from the user for an extended period. |
AliRtcUserOfflineBecomeAudience | Triggered when the user role switches from streamer to viewer. |
AliRtcVideoStreamType: Camera stream type.
Enum name | Description |
AliRtcVideoStreamTypeNone | No video stream. |
AliRtcVideoStreamTypeHigh | High-resolution stream. |
AliRtcVideoStreamTypeLow | Substream. |
AliRtcAudioTrack: Audio stream type.
Enum name | Description |
AliRtcAudioTrackNo | No audio stream. |
AliRtcAudioTrackMic | Microphone stream. |
AliRtcAudioTrackDual | Second audio stream. |
AliRtcAudioTrackBoth | Microphone stream and second audio stream. |
AliRtcNetworkQuality: Network quality.
Enum name | Description |
Network_Excellent | The network quality is excellent, providing good fluency and definition. |
Network_Good | The network quality is good. The fluency and definition are similar to the Excellent level. |
Network_Poor | The network quality is poor. The audio and video fluency and definition are flawed but do not affect communication. |
Network_Bad | The network quality is bad. The video experiences severe freezes, but audio communication is normal. |
Network_VeryBad | The network quality is very bad. Communication is almost impossible. |
Network_Disconnected | The network is disconnected. |
Network_Unknow | Unknown reason. |
AliRtcRenderMode: Rendering mode.
Enum name | Description |
AliRtcRenderModeAuto | Automatic. |
AliRtcRenderModeStretch | Stretches the video to fill the view. The aspect ratio is not preserved. |
AliRtcRenderModeFill | Scales the video while preserving the aspect ratio. Black bars are added to fill the remaining space. |
AliRtcRenderModeClip | Scales the video while preserving the aspect ratio. The video is cropped to fit the view. |
AliRtcRenderMirrorMode: Mirror mode.
Enum name | Description |
AliRtcRenderMirrorModeAllEnabled | Mirroring is enabled for all. |
AliRtcRenderMirrorModeAllDisable | Mirroring is disabled for all. |
AliRtcRotationMode: Rotation angle.
Enum name | Description |
AliRtcRotationMode_0 | No rotation. |
AliRtcRotationMode_90 | Rotate 90 degrees. |
AliRtcRotationMode_180 | Rotate 180 degrees. |
AliRtcRotationMode_270 | Rotate 270 degrees. |
AliRtcLogLevel: Log level.
Enum name | Description |
AliRtcLogLevelInfo | The status is normal. |
AliRtcLogLevelWarn | Warning. |
AliRtcLogLevelError | Error. |
AliRtcLogLevelFatal | Fatal. |
AliRtcLogLevelNone | None. |
AliRtcAudioNumChannel: Number of sound channels.
Enum name | Description |
AliRtcMonoAudio | Mono. |
AliRtcStereoAudio | Stereo. |
AliRtcAudioSampleRate: Audio recording sample rate.
Enum name | Description |
AliRtcAudioSampleRate_8000 | Sample rate of 8,000 Hz. |
AliRtcAudioSampleRate_11025 | Sample rate of 11,025 Hz. |
AliRtcAudioSampleRate_16000 | Sample rate of 16,000 Hz. |
AliRtcAudioSampleRate_22050 | Sample rate of 22,050 Hz. |
AliRtcAudioSampleRate_32000 | Sample rate of 32,000 Hz. |
AliRtcAudioSampleRate_44100 | Sample rate of 44,100 Hz. |
AliRtcAudioSampleRate_48000 | Sample rate of 48,000 Hz. |
AliRtcAudioSampleRate_Unknown | Unknown sample rate. Used in some scenarios. |
AliRtcRecordType: Record type.
Enum name | Description |
AliRtcRecordTypeAudio | Record an audio-only file. |
AliRtcRecordTypeVideo | Record a video file. |
AliRtcRecordFormat: Record format.
Enum name | Description |
AliRtcRecordFormatAAC | AAC file. |
AliRtcRecordFormatWAV | WAV file. |
AliRtcRecordFormatMP4 | MP4 file. |
AliRtcAudioQuality: Audio recording quality.
Enum name | Description |
AliRtcAudioQualityLow | Low. |
AliRtcAudioQualityMidium | Medium. |
AliRtcAudioQualityHigh | High. |
AliRtcVideoQuality: Video recording quality.
Enum name | Description |
AliRtcVideoQualityDefault | The default quality, which is the same as the capture quality. |
AliRtcTransportAudioQuality: Audio quality.
Enum name | Description |
AliRtcAudioQulityUnknow | Unknown quality. |
AliRtcAudioQulityExcellent | Excellent quality. |
AliRtcAudioQulityGood | The subjective user experience is similar to Excellent, but the bitrate may be slightly lower. |
AliRtcAudioQulityPoor | The subjective user experience is flawed but does not affect communication. |
AliRtcAudioQulityBad | Communication is barely possible but not smooth. |
AliRtcAudioQulityVeryBad | The network quality is very poor. Communication is almost impossible. |
AliRtcAudioQulityNetworkDisconnected | The network connection is disconnected. Communication is impossible. |
AliRtcAudioProfile: Audio quality mode.
Enum name | Description |
AliRtcEngineLowQualityMode | Low audio quality mode. |
AliRtcEngineBasicQualityMode | Standard audio quality mode. |
AliRtcEngineHighQualityMode | High audio quality mode. |
AliRtcEngineStereoHighQualityMode | Stereo high audio quality mode. |
AliRtcEngineSuperHighQualityMode | Ultra-high audio quality mode. |
AliRtcEngineStereoSuperHighQualityMode | Stereo ultra-high audio quality mode. |
AliRtcAudioScenario: Audio scenario mode.
Enum name | Description |
AliRtcSceneDefaultMode | Default scenario. Recommended for general audio and video communication scenarios. |
AliRtcSceneEducationMode | Education scenario. Prioritizes audio continuity and stability. |
AliRtcSceneMediaMode | Media scenario. Preserves the quality of human voices and music. Recommended for interactive streaming with co-streamers. |
AliRtcSceneMusicMode | Music scenario. Provides high-fidelity music quality. Recommended for scenarios with high requirements for music quality, such as musical instrument lessons. |
AliRtcSceneChatroomMode | Chat room scenario. Suitable for chat scenarios where users frequently join and leave with their microphones on. |
AliRtcMuteLocalAudioMode: Local mute mode.
Enum name | Description |
AliRtcMuteAudioModeDefault | Default mode. Mutes all audio, including microphone and external audio input. |
AliRtcMuteAllAudioMode | Mutes all audio, including microphone and external audio input. |
AliRtcMuteOnlyMicAudioMode | Mutes only the microphone. |
AliRtcMuteLocalAudioMax | Placeholder. |
AliRtcRecordAudioConfig: Audio recording settings.
Parameter | Type | Description |
sampleRate | The audio sample rate. | |
quality | The audio quality. | |
enableRecordExternalRenderPCM | bool | Specifies whether to allow recording of external PCM input rendering data. |
enableRecordExternalCapturePCM | bool | Specifies whether to allow recording of external PCM input capture data. |
AliRtcRecordVideoConfig: Video recording settings.
Parameter | Type | Description |
quality | The video quality. |
AliRtcBeautyConfig: Basic retouching settings.
Parameter | Type | Description |
whiteningLevel | float | The whitening level. Valid values: [0, 1]. A larger value indicates a stronger whitening effect. |
smoothnessLevel | float | The skin smoothing level. Valid values: [0, 1]. A larger value indicates a stronger smoothing effect. |
AliRtcOnByeType: Enumeration of OnBye types.
Enum name | Description |
AliRtcOnByeBeKickedOut | Kicked out. |
AliRtcOnByeChannelTerminated | The channel is terminated. You must leave the meeting. |
AliRtcOnByeUserReplaced | A user with the same UID joins the channel from another device, and the current device is kicked offline. |
AliRtcOnByeExpire | Timeout. |
AliRtcOnByeReconnect | Reconnecting. |
AliRtcOnByeBeBaned | Banned. |
AliRtcAudioEffectVoiceChangerMode: Voice changer effect mode.
Enum name | Description |
AliRtcAudioEffectvVoiceChanger_OFF | Off. |
AliRtcAudioEffectvVoiceChanger_OLD_MAN | Old man. |
AliRtcAudioEffectvVoiceChanger_BABYBOY | Baby boy. |
AliRtcAudioEffectvVoiceChanger_BABYGILR | Baby girl. |
AliRtcAudioEffectvVoiceChanger_ROBOT | Robot. |
AliRtcAudioEffectvVoiceChanger_DAIMO | Devil. |
AliRtcAudioEffectvVoiceChanger_KTV | KTV. |
AliRtcAudioEffectVoiceChanger_ECHO | Echo. |
AliRtcAudioEffectvVoiceChangerR_DIALECT | Dialect. |
AliRtcAudioEffectvVoiceChangerR_HOWL | Howl. |
AliRtcAudioEffectvVoiceChangerR_ELECTRONIC | Electronic. |
AliRtcAudioEffectvVoiceChangerR_PHONOGRAPH | Phonograph. |
AliRtcAudioEffectvVoiceChanger_MAX | Placeholder. No meaning. |
AliRtcAudioEffectReverbMode: Reverb effect mode.
Enum name | Description |
AliRtcAudioEffectReverb_Off | Off. |
AliRtcAudioEffectReverb_Vocal_I | Vocal I. |
AliRtcAudioEffectReverb_Vocal_II | Vocal II. |
AliRtcAudioEffectReverb_Bathroom | Bathhouse. |
AliRtcAudioEffectReverb_Small_Room_Bright | Bright small room. |
AliRtcAudioEffectReverb_Small_Room_Dark | Dark small room. |
AliRtcAudioEffectReverb_Medium_Room | Medium room. |
AliRtcAudioEffectReverb_Large_Room | Large room. |
AliRtcAudioEffectReverb_Church_Hall | Church hall. |
AliRtcAudioEffectReverb_Cathedral | Cathedral. |
AliRtcAudioEffectReverb_Mode_Max | Placeholder. No meaning. |
AliRtcAudioEffectReverbParamType: Reverb effect parameters.
Enum name | Description |
AliRtcAudioEffectReverb_Room_Size | Room size. Valid values: [0, 100]. |
AliRtcAudioEffectReverb_Pre_Delay | Pre-delay, in ms. Valid values: [0, 200]. |
AliRtcAudioEffectReverb_Revetberance | Reverberance. Valid values: [0, 100]. |
AliRtcAudioEffectReverb_Hf_Damping | Damping. Valid values: [0, 100]. |
AliRtcAudioEffectReverb_Tone_Low | Low tone. Valid values: [0, 100]. |
AliRtcAudioEffectReverb_Tone_High | High tone. Valid values: [0, 100]. |
AliRtcAudioEffectReverb_Dry_Gain | Dry gain. Valid values: [-20, 10]. |
AliRtcAudioEffectReverb_Wet_Gain | Wet gain. Valid values: [-20, 10]. |
AliRtcAudioEffectReverb_Type_Max | Placeholder. No meaning. |
AliVideoCanvas: Rendering canvas.
Parameter | Type | Description |
view | UIView * _Nonnull | The rendering view. This cannot be nil. |
renderMode | The rendering mode. Default value: AliRtcRenderModeAuto. | |
mirrorMode | The mirror mode. Default value: AliRtcRenderMirrorModeOnlyFront. | |
backgroundColor | int | The background color, in hexadecimal RGB format. |
rotationMode | The video rotation angle. The default is no rotation. |
AliRtcTranscodingLiveStreamErrorCode: Error code for bypass live streaming.
Enum name | Description |
AliRtcTranscodingLiveStreamErrorPublishOk | Stream ingest is successful. |
AliRtcTranscodingLiveStreamErrorStreamNotFound | Error: Stream not found. |
AliRtcTranscodingLiveStreamErrorStreamAlreadyExist | Error: The destination stream already exists. |
AliRtcTranscodingLiveStreamErrorInvalidParam | Error: Invalid parameter. |
AliRtcTranscodingLiveStreamErrorInternalError | Error: Internal error. |
AliRtcTranscodingLiveStreamErrorRtmpServerError | Error: RTMP service is abnormal. |
AliRtcTranscodingLiveStreamErrorRtmpStreamUrlError | Error: The URL is abnormal. |
AliRtcTranscodingLiveStreamErrorPublishTimeout | Error: The task timed out. |
AliRtcTranscodingLiveStreamErrorNotAuthorized | Error: The operation is not authorized. |
AliRtcWatermarkConfig: Watermark image settings.
Parameter | Type | Description |
visibleInPreview | BOOL | Specifies whether the watermark is visible in the local preview. |
positionInLandscapeMode | CGRect | The watermark coordinates in landscape mode. |
positionInPortraitMode | CGRect | The watermark coordinates in portrait mode. |
alpha | float | The transparency. |
normalized | BOOL | Specifies whether to normalize the coordinates. |
AliRtcCameraCapturerConfiguration: Camera capture preferences.
Parameter | Type | Description |
preference | The capture preference. | |
fps | int | The frames per second (fps). |
cameraCaptureProfile | Specifies a specific resolution for video capture. | |
disableVideoCaptureReverse | int | Disables flipping the captured video frame based on the aspect ratio. |
captureObserverOriginal | int | Specifies whether to call back the original video frame data. |
nativeBufferObserver | int | Calls back the texture ID. |
captureCallbackCvpixelbufferToRaw | int | The video capture callback uses CVPixelBuffer. |
AliRtcCameraCaptureProfile: Camera capture resolution.
Enum name | Description |
AliRtcCameraCaptureProfileDefault | Default. |
AliRtcCameraCaptureProfile1080P | 1080p video. If enabled, the camera captures video at a resolution of 1080p. |
AliRtcCaptureOutputPreference: Camera capture preference.
Enum name | Description |
AliRtcCaptureOutputPreferenceAuto | Automatically adjusts capture parameters. |
AliRtcCaptureOutputPreferencePerformance | Prioritizes device performance. Selects the camera output parameters that are closest to the parameters set by `setVideoProfile`. |
AliRtcCaptureOutputPreferencePreview | Prioritizes video preview quality. Selects higher camera output parameters. |
AliRtcVideoEncoderFrameRate: Video encoding frame rate.
Enum name | Description |
AliRtcVideoEncoderFrameRate_FPS_5 | 5 FPS. |
AliRtcVideoEncoderFrameRate_FPS_10 | 10 FPS. |
AliRtcVideoEncoderFrameRate_FPS_15 | 15 FPS. |
AliRtcVideoEncoderFrameRate_FPS_20 | 20 FPS. |
AliRtcVideoEncoderFrameRate_FPS_30 | 30 FPS. |
AliRtcVideoEncoderBitrate: Video encoding bitrate.
Enum name | Description |
AliRtcVideoEncoderStandardBitrate | Standard bitrate mode. |
AliRtcVideoEncoderMirrorMode: Encoded video mirror mode.
Enumeration name | Description |
AliRtcVideoEncoderMirrorModeDisabled | The encoded video is not mirrored. |
AliRtcVideoEncoderMirrorModeEnabled | The encoded video is mirrored. |
AliRtcVideoCodecType: Video codec type.
Enum name | Description |
AliRtcVideoCodecTypeDefault | Not set. The default value (hardware encoding) is used. |
AliRtcVideoCodecTypeSoftware | Software video encoder. |
AliRtcVideoCodecTypeHardware | Hardware video encoder. |
AliRtcVideoEncodeCodecType: Encoder type.
Enum name | Description |
AliRtcVideoEncodeCodecTypeDefault | Not set. The default value (currently H.264) is used. |
AliRtcVideoEncodeCodecTypeH264 | H.264 encoding. |
AliRtcVideoEncodeCodecTypeHevc | HEVC encoding. |
AliRtcVideoEncoderOrientationMode: Encoded video rotation mode.
Enum name | Description |
AliRtcVideoEncoderOrientationModeAdaptive | Adaptive. The orientation is the same as the captured video. |
AliRtcVideoEncoderOrientationModeFixedLandscape | Fixed landscape. |
AliRtcVideoEncoderOrientationModeFixedPortrait | Fixed portrait. |
AliRtcVideoEncoderConfiguration: Video encoding preferences.
Parameter | Type | Description |
dimensions | CGSize | The video resolution. |
frameRate | NSInteger | The video encoding frame rate. |
bitrate | NSInteger | The video encoding bitrate. |
min_bitrate | NSInteger | The minimum video encoding bitrate, in Kbps. Default value: 0. |
keyFrameInterval | NSInteger | The keyframe interval, in milliseconds. Default value: 0. This indicates that the SDK controls the keyframe interval. |
forceStrictKeyFrameInterval | bool | Specifies whether to force the encoder to generate keyframes at the specified interval. Default value: false.
|
mirrorMode | The encoded video mirror mode. | |
orientationMode | The encoded video rotation mode. | |
rotationMode | The video rotation angle. | |
codecType | The codec type. | |
encoderType | The video encoding type. | |
seiForceFrontIFrame | NSInteger | Forces an I-frame before sending an SEI message. -1: Use the default value. 0: Do not force. 1: Force (default). |
enableDynamicEncode | NSInteger | Enables dynamic encoding. Creates both hardware and software encoders. If the hardware encoder fails, it degrades to the software encoder. -1: Use the default value. 0: Do not create both types of encoders. 1: Create both types of encoders. |
disableDipenseResolutionChange | NSInteger | Disables the ability of Quality of Service (QoS) to reduce resolution. QoS reduces the video encoding resolution if it detects that the real-time bandwidth is insufficient for the current resolution. -1: Use the default value. 0: Allow reduction. 1: Do not allow QoS to reduce the resolution. |
enableDowngrade | NSInteger | Allows QoS to reduce the video encoding bitrate based on the detected bandwidth. -1: Use the default value. 0: Do not allow reduction of the encoding bitrate. 1: Allow reduction of the encoding bitrate. |
enableH264BFrame | NSInteger | Specifies whether to enable H.264 B-frame support. -1: Use the default value. 0: Disable B-frame support. 1: Enable B-frame support. Important If you enable this feature, you must also enable B-frame support on the decoding end. |
enableHevcBFrame | NSInteger | Specifies whether to enable HEVC B-frame support. -1: Use the default value. 0: Disable B-frame support. 1: Enable B-frame support. Important If you enable this feature, you must also enable B-frame support on the decoding end. |
AliRtcScreenShareEncoderConfiguration: Screen sharing encoding preferences.
Parameter | Type | Description |
dimensions | CGSize | The video resolution. |
frameRate | NSInteger | The video encoding frame rate. |
bitrate | NSInteger | The video encoding bitrate. |
rotation | The screen rotation angle. | |
keyFrameInterval | NSInteger | The keyframe interval, in milliseconds. Default value: 0. This indicates that the SDK controls the keyframe interval. |
forceStrictKeyFrameInterval | bool | Specifies whether to force the encoder to generate keyframes at the specified interval. Default value: false. false: The encoder responds to keyframe requests, such as when another user joins the channel. The actual keyframe interval may not strictly match the specified value. true: The encoder does not respond to other keyframe requests and strictly generates keyframes at the specified interval. This may increase the time to render the first frame for subscribers. |
AliRtcVideoDecoderConfiguration: Video decoder settings.
Parameter | Type | Description |
codecType | The codec type. The default value is AliRtcVideoCodecTypeDefault, which uses the system's default settings. | |
enableDecoderBframe | NSInteger | Specifies whether to enable B-frames for the decoder. The default setting is -1. Set to 0 to disable B-frames, or 1 to enable B-frames. |
backgroundHardwareToSoftware | NSInteger | Specifies whether to degrade from hardware decoding to software encoding when the app moves to the background. The default setting is -1. Set to 0 to disable this feature, or 1 to enable the degradation logic. |
AliRtcAuthInfo: Authentication information.
Parameter | Type | Description |
channelId | NSString * _Nonnull | The channel ID. |
userId | NSString * _Nonnull | The user ID. |
appId | NSString * _Nonnull | The application ID. |
nonce | NSString * _Nonnull | A random string. |
token | NSString * _Nonnull | The token. |
gslb | NSArray <NSString *> * | The GSLB address. |
timestamp | long long | The timestamp. |
AliRtcDeviceVolumeType: Device volume type (iOS only).
Enum name | Description |
AliRtcDeviceVolumeTypeAuto | The SDK automatically sets the volume type (default). The SDK automatically selects the appropriate volume type. We do not recommend changing this setting unless you have specific requirements. |
AliRtcDeviceVolumeTypeMedia | Sets the volume to media volume. This is suitable for media playback scenarios where the volume can be adjusted to zero. |
AliRtcDeviceVolumeTypeVOIP | Sets the volume to call volume. This is suitable for call scenarios where the volume cannot be adjusted to zero. |
AliRtcVideoSource: Raw video data source type.
Enum name | Description |
AliRtcVideosourceCameraType | Video stream. |
AliRtcVideosourceScreenShareType | Screen sharing stream. |
AliRtcVideosourceBoth | Video stream and screen sharing stream. |
AliRtcVideosourceTypeMax | Placeholder. |
AliRtcAudioSource: Raw audio data source type.
Enum name | Description |
AliRtcAudioSourceCaptured | Captured audio data. |
AliRtcAudioSourceProcessCaptured | Audio data after 3A processing. |
AliRtcAudiosourcePub | Audio data for stream ingest. |
AliRtcAudioSourcePlayback | Audio data for playback. |
AliRtcAudioSourceMixedAll | Mixed audio data from stream ingest and playback. Not currently supported. |
AliRtcAudioSourceRemoteUser | Remote audio data from stream pulling. |
AliRtcBufferType: Video data type.
Enum name | Description |
AliRtcBufferType_Raw_Data | Raw YUV data. |
AliRtcBufferType_CVPixelBuffer | CVPixelBuffer data. |
AliRtcBufferType_Texture | Texture. |
AliRtcBufferType_File | File path. |
AliRtcErrorCode: Error code.
Enum name | Description |
AliRtcErrNone | None. |
AliRtcErrJoinBadAppId | The App ID does not exist. |
AliRtcErrJoinInvalidAppId | The App ID is invalid. |
AliRtcErrJoinBadChannel | The channel does not exist. |
AliRtcErrJoinInvalidChannel | The channel is invalid. |
AliRtcErrJoinBadToken | The token does not exist. |
AliRtcErrJoinTimeout | Timed out when joining the channel. |
AliRtcErrJoinBadParam | Parameter error. |
AliRtcErrJoinChannelFailed | Failed to join the channel. |
AliRtcErrLogAlreadyInit | The log module is already initialized. |
AliRtcErrLogRootPathError | The root path of the log module is incorrect. Check if the path exists and has write permissions. |
AliRtcErrMicOpenFail | Failed to initialize the capture device. |
AliRtcErrSpeakerOpenFail | Failed to initialize the playback device. |
AliRtcErrMicInterrupt | An exception occurred during capture. |
AliRtcErrSpeakerInterrupt | An exception occurred during playback. |
AliRtcErrMicAuthFail | The microphone is not authorized. |
AliRtcErrMicNotAvailable | No audio capture device is available. |
AliRtcErrSpeakerNotAvailable | No audio playback device is available. |
AliRtcErrCameraOpenFail | Failed to initialize the capture device. |
AliRtcErrCameraInterrupt | An exception occurred during capture. |
AliRtcErrDisplayOpenFail | Failed to initialize the rendering device. |
AliRtcErrDisplayInterrupt | An exception occurred during rendering. |
AliRtcErrIceConnectionConnectFail | Failed to establish the media channel. |
AliRtcErrIceConnectionReconnectFail | Failed to reconnect to the media channel. |
AliRtcErrIceConnectionHeartbeatTimeout | Signaling heartbeat timeout. |
AliRtcErrIceConnectionMobilityFail | Media channel mobility failed. The application layer needs to rejoin the channel. |
AliRtcErrCdnLiveCommunicationFailed | Low-latency interactive live streaming signaling failed. |
AliRtcErrCdnLiveMeidaSettingFailed | Low-latency interactive live streaming media settings error. |
AliRtcErrCdnLiveNoneBroadcaster | No streamer is publishing in the current low-latency interactive live streaming channel. |
AliRtcErrCdnLiveNeedRestart | Low-latency interactive live streaming error. The application layer needs to create a new SDK instance. |
AliRtcErrCdnLiveNeedRestartAgainLater | Low-latency interactive live streaming error. The application layer needs to wait for a custom interval and then create a new SDK instance. |
AliRtcErrCdnLiveServiceUnavailable | The low-latency interactive live streaming service is unavailable or degraded. The client should use another method to pull the stream instead of pulling from the CDN SFU. |
AliRtcErrCdnLiveMediaConnectionInterruption | Low-latency interactive live streaming network interruption error. Destroy the current SDK instance, create a new one, and then resubscribe. |
AliRtcErrPublishInvaild | Invalid stream ingest. |
AliRtcErrPublishNotJoinChannel | Failed to ingest stream because the user has not joined the channel. |
AliRtcErrPublishAudioStreamFailed | Failed to publish the audio stream. |
AliRtcErrPublishVideoStreamFailed | Failed to publish the video stream. |
AliRtcErrPublishDualStreamFailed | Failed to publish dual streams. |
AliRtcErrPublishScreenShareFailed | Failed to publish the screen sharing stream. |
AliRtcErrPublishScreenShareConfigError | Screen sharing configuration error. |
AliRtcErrSubscribeInvaild | Invalid subscription. |
AliRtcErrSubscribeNotJoinChannel | Subscription error because the user has not joined the channel. |
AliRtcErrSubscribeAudioStreamFailed | Failed to subscribe to the audio stream. |
AliRtcErrSubscribeVideoStreamFailed | Failed to subscribe to the video stream. |
AliRtcErrSubscribeDualStreamFailed | Failed to subscribe to dual streams. |
AliRtcErrSubscribeScreenShareFailed | Failed to subscribe to the screen sharing stream. |
AliRtcErrSubscribeRtsStreamFailed | Failed to subscribe to the RTS stream. |
AliRtcErrPauseRtsStreamFailed | Failed to pause the RTS stream. |
AliRtcErrSdkInvalidState | SDK state error. |
AliRtcErrSessionRemoved | The session has been removed. |
AliRtcErrInvalidArguments | Parameter mismatch. |
AliRtcErrAudioBufferFull | The buffer queue is full. This is for the external raw data transport feature. |
AliRtcErrVideoBufferFull | The buffer queue is full. This is for the external raw data transport feature. |
AliRtcErrUpdateRoleChannel | Error setting role in interactive mode. |
AliRtcErrInner | Other errors. |
AliRtcExternalDeviceType: External device type.
Enum name | Description |
AliRtcExternalTypeUnknown | Unknown type. |
AliRtcExternalTypeAudioCapture | Audio capture device. |
AliRtcExternalTypeAudioPlayout | Audio playback device. |
AliRtcExternalTypeVideoCapture | Video capture device. |
AliRtcExternalDeviceState: External device state.
Enum name | Description |
AliRtcExternalDeviceAdd | An external device is added. |
AliRtcExternalDeviceRemove | An external device is removed. |
AliRtcRecordVideoCanvasConfig: Canvas size for video recording.
Parameter | Type | Description |
canvasWidth | int | The width of the canvas. |
canvasHeight | int | The height of the canvas. |
AliRtcRecordVideoBgColor: Background color for video recording.
Parameter | Type | Description |
r | uint8_t | The value of red in the color mix. |
g | uint8_t | The value of green in the color mix. |
b | uint8_t | The value of blue in the color mix. |
AliRtcDeviceInfo: Device information.
Parameter | Type | Description |
deviceName | NSString * _Nullable | The device name. |
deviceID | NSString * _Nullable | The device ID. |
AliRtcScreenShareConfig: Screen sharing configuration.
Parameter | Type | Description |
isShareByRegion | bool | Specifies whether to share a region. |
shareRegion | * _Nonnull | The layout information for region sharing. |
AliRtcScreenShareRegion: Screen sharing region.
Parameter | Type | Description |
originX | float | The x-coordinate. |
originY | float | The y-coordinate. |
width | float | The width. |
height | float | The height. |
AliRtcScreenSourceInfo: Screen sharing source information.
Parameter | Type | Description |
sourceId | NSString * _Nonnull | The source ID for sharing. |
sourceName | NSString * _Nonnull | The source name for sharing. |
AliRtcScreenShareInfo: Screen sharing configuration information.
Parameter | Type | Description |
sourceType | The sharing type. | |
sourceId | NSString * _Nonnull | The source ID for sharing. |
config | * _Nonnull | The screen sharing configuration. |
AliRtcScreenShareType: Screen sharing type.
Enum name | Description |
AliRtcScreenShareDesktop | Desktop sharing. |
AliRtcScreenShareWindow | Window sharing. |
AliRtcVideoObserAlignment: Alignment mode for video output width.
Enum name | Description |
AliRtcAlignmentDefault | Keep the original video width (default). |
AliRtcAlignmentEven | Align the width to an even number. |
AliRtcAlignment4 | The width is a multiple of 4. |
AliRtcAlignment8 | The width is a multiple of 8. |
AliRtcAlignment16 | The width is a multiple of 16. |
AliRtcShowDebugViewType: Dashboard display type.
Enum name | Description |
AliRtcShowTypeNone | Do not display. |
AliRtcShowTypeAudio | Audio. |
AliRtcShowTypeVideo | Video. |
AliRtcShowTypeNetwork | Network. |
AliRtcShowTypeAll | All. |
AliRtcTranscodingLiveTaskStatus: Status of a bypass live streaming task.
Enum name | Description |
AliRtcTranscodingLiveTaskStatusStart | The task starts. |
AliRtcTranscodingLiveTaskStatusUpdate | The task is updated. |
AliRtcTranscodingLiveTaskStatusStop | The task has stopped. |
AliRtcLiveTranscodingDisplayType: Display type for images in bypass live streaming.
Enum name | Description |
AliRtcLiveTranscodingDisplayType_NOT_DISPLAY | Do not display. |
AliRtcLiveTranscodingDisplayType_ALWAYS | Always display. |
AliRtcLiveTranscodingDisplayType_WHEN_NO_VIDEO | Display when there is no video. |
AliRtcLiveTranscodingFontType: Font type for text in bypass live streaming.
Enum name | Description |
NOTO_SERIF_CJKSC_REGULAR | NotoSerifCJKsc-REGULAR. |
ALIBABA_PUHUITI_REGULAR | Alibaba-PuHuiTi-Regular. |
ALIBABA_PUHUITI_BOLD | Alibaba-PuHuiTi-Bold. |
ALIBABA_PUHUITI_Heavy | Alibaba-PuHuiTi-Heavy. |
ALIBABA_PUHUITI_LIGHT | Alibaba-PuHuiTi-Light. |
ALIBABA_PUHUITI_MEDIUM | Alibaba-PuHuiTi-Medium. |
AliRtcLiveTranscodingSegmentType: Input segmentation type for bypass live streaming.
Enum name | Description |
AliRtcLiveTranscodingNoBody | No portrait segmentation. |
AliRtcLiveTranscodingBody | Portrait segmentation. |
AliRtcLiveTranscodingSourceType: Input source type for bypass live streaming.
Enum name | Description |
AliRtcLiveTranscodingCamera | Camera. |
AliRtcLiveTranscodingShareScreen | Screen sharing. |
AliRtcVideoState: Video stream state change.
Enum name | Description |
AliRtcVideoVideoClose | Close the video stream. |
AliRtcVideoVideoOpen | Resume the video stream. |
AliRtcVideoReason: Reason for a video stream state change.
Enum name | Description |
AliRTCVideoChangedByClient | Client. |
AliRTCVideoChangedByServer | Server. |
AliRtcLiveTranscodingCropMode: Cropping mode for bypass live streaming.
Enum name | Description |
AliRtcLiveTranscodingCrop | Crop while preserving the aspect ratio. |
AliRtcLiveTranscodingFill | Fill with black bars while preserving the aspect ratio (default). |
AliRtcLiveTranscodingMediaProcessMode: Media processing mode for bypass live streaming.
Enum name | Description |
AliRtcLiveTranscodingNormal | Normal mode. |
AliRtcLiveTranscodingVirtualBackground | Virtual background mode. |
AliRtcLiveTranscodingStreamType: Stream type for bypass live streaming.
Enum name | Description |
AliRtcLiveTranscodingOrigin | Transcode the original stream. |
AliRtcLiveTranscodingAudio | Transcode only the audio stream. |
AliRtcLiveTranscodingVideo | Only the video stream is forwarded. |
AliRtcLiveTranscodingMixMode: Mode for bypass live streaming.
Enum name | Description |
AliRtcLiveTranscodingSINGLE | Single-stream transcoding. Does not mix or transcode streams. Only transcodes the original single stream. No stream mixing or transcoding parameters need to be configured. |
AliRtcLiveTranscodingMIX | Stream mixing and transcoding (default). Supports mixed and transcoded output. |
AliRtcLiveTranscodingState: Status of bypass live streaming.
Enum name | Description |
AliRtcLiveTranscodingState_IDLE | Stream ingest is idle. |
AliRtcLiveTranscodingState_CONNNECT | Connecting to the stream ingest server. |
AliRtcLiveTranscodingState_RUNNING | Stream ingest is in progress. |
AliRtcLiveTranscodingState_RECOVERING | Recovering stream ingest. |
AliRtcLiveTranscodingState_FAILURE | Stream ingest failed. |
AliRtcLiveTranscodingState_END | Stream ingest has ended. |
AliRtcLiveTranscodingText: Text information for bypass live streaming.
Parameter | Type | Description |
text | NSString | The text information. |
x | int | The x-coordinate, in pixels. |
y | int | The y-coordinate, in pixels. |
fontType | The font for bypass live streaming. | |
fontSize | int | The font size. |
zOrder | int | The z-order. 0 is the bottom layer, 1 is above 0, and so on. |
fontColor | int | The font color. |
AliRtcLiveTranscodingImage: Image information for bypass live streaming.
Parameter | Type | Description |
url | NSString | The image URL. |
alpha | float | The transparency. 0.0 is fully transparent, and 1.0 is fully opaque. |
display | The image display. | |
x | int | The x-coordinate, in pixels. |
y | int | The y-coordinate, in pixels. |
width | int | The image width. |
height | int | The image height. |
zOrder | int | The z-order. 0 is the bottom layer, 1 is above 0, and so on. |
AliRtcLiveTranscodingUser: Custom user stream information for bypass live streaming.
Parameter | Type | Description |
x | int | The x-coordinate, in pixels. |
y | int | The y-coordinate, in pixels. |
width | int | The pane width. |
height | int | The pane height. |
zOrder | int | The z-order. 0 is the bottom layer, 1 is above 0, and so on. |
userId | NSString * | The user ID. |
streamType | The stream type for bypass live streaming. | |
sourceType | The stream type. | |
segmentType | The input segmentation type for bypass live streaming. | |
images | NSArray<AliRtcLiveTranscodingImage *> * | The image information for bypass live streaming. |
texts | NSArray<AliRtcLiveTranscodingText *> * | The text information for bypass live streaming. |
AliRtcLiveTranscodingParam: Configuration for bypass live streaming.
Parameter | Type | Description |
mixMode | The mode for bypass live streaming. | |
singleParam | AliRtcLiveTranscodingSingleParam * | The single-stream parameters for bypass live streaming. |
mixParam | The stream mixing parameters for bypass live streaming. |
AliRtcLiveTranscodingMixParam: Stream mixing parameters for bypass live streaming.
Parameter | Type | Description |
taskProfile | The billing specifications for bypass live streaming. | |
encodeParam | AliRtcLiveTranscodingEncodeParam * | The encoding parameters for bypass live streaming. |
users | NSArray<AliRtcLiveTranscodingUser *> * | The user list for bypass live streaming. |
backgroundColor | int | The background color. |
backgrounds | NSArray<AliRtcLiveTranscodingImage *> * | The list of background images. |
watermarks | NSArray<AliRtcLiveTranscodingImage *> * | The list of watermark images. |
clockWidgets | NSArray<AliRtcLiveTranscodingClockWidget *> * | The list of clock widgets. |
cropMode | The cropping mode for bypass live streaming. | |
mediaProcessMode | The media processing mode for bypass live streaming. |
AliRtcLiveTranscodingSingleParam: Single-stream parameters for bypass live streaming.
Parameter | Type | Description |
userId | NSString * | The user ID. |
streamType | The stream type for bypass live streaming. | |
sourceType | The video stream type for bypass live streaming. |
AliRtcLiveTranscodingTaskProfile: Billing specifications for bypass live streaming.
Enum name | Description |
AliRtcLiveTranscoding_Profile_1IN_1080P | 1IN_1080P. |
AliRtcLiveTranscoding_Profile_1IN_720P | 1IN_720P. |
AliRtcLiveTranscoding_Profile_1IN_360P | 1IN_360P. |
AliRtcLiveTranscoding_Profile_2IN_1080P | 2IN_1080P. |
AliRtcLiveTranscoding_Profile_2IN_720P | 2IN_720P. |
AliRtcLiveTranscoding_Profile_2IN_360P | 2IN_360P. |
AliRtcLiveTranscoding_Profile_4IN_1080P | 4IN_1080P. |
AliRtcLiveTranscoding_Profile_4IN_720P | 4IN_720P. |
AliRtcLiveTranscoding_Profile_4IN_360P | 4IN_360P. |
AliRtcLiveTranscoding_Profile_9IN_1080P | 9IN_1080P. |
AliRtcLiveTranscoding_Profile_9IN_720P | 9IN_720P. |
AliRtcLiveTranscoding_Profile_9IN_360P | 9IN_360P. |
AliRtcLiveTranscoding_Profile_12IN_1080P | 12IN_1080P. |
AliRtcLiveTranscoding_Profile_12IN_720P | 12IN_720P. |
AliRtcLiveTranscoding_Profile_12IN_360P | 12IN_360P. |
AliRtcLiveTranscoding_Profile_16IN_1080P | 16IN_1080P. |
AliRtcLiveTranscoding_Profile_16IN_720P | 16IN_720P. |
AliRtcLiveTranscoding_Profile_16IN_360P | 16IN_360P. |
AliRtcLiveTranscoding_Profile_Mixed | Audio-only. |
AliRtcLiveTranscodingEncodeParam: Encoding parameters for bypass live streaming.
Parameter | Type | Description |
videoWidth | int | The width. |
videoHeight | int | High |
videoFramerate | int | The frame rate. |
videoBitrate | int | The bitrate. |
videoGop | int | The GOP. |
videoCodec | The video encoder for bypass live streaming. | |
audioSamplerate | The audio sample rate for bypass live streaming. | |
audioBitrate | int | The audio bitrate. |
audioChannels | int | The number of audio channels. |
AliRtcLiveTranscodingAudioSampleRate: Audio sample rate for bypass live streaming.
Enum name | Description |
AliRtcLiveTranscoding_HZ_48000 | Sample rate of 48,000 Hz. |
AliRtcLiveTranscoding_HZ_44100 | Sample rate of 44,100 Hz. |
AliRtcLiveTranscoding_HZ_32000 | Sample rate of 32,000 Hz. |
AliRtcLiveTranscoding_HZ_16000 | Sample rate of 16,000 Hz. |
AliRtcLiveTranscoding_HZ_8000 | Sample rate of 8,000 Hz. |
AliRtcLiveTranscodingClockWidget: Clock widget for bypass live streaming.
Parameter | Type | Description |
x | int | The x-coordinate, in pixels. |
y | int | The y-coordinate, in pixels. |
fontSize | int | The font size for bypass live streaming. |
zOrder | int | The z-order. 0 is the bottom layer, 1 is above 0, and so on. |
fontColor | int | The font color for bypass live streaming. |
fontType | The font for bypass live streaming. |
AliRtcVideoPipelineMirrorMode: Video pipeline mirror type.
Enum name | Description |
AliRtcVideoPipelineMirrorModeNoMirror | Mirroring is disabled for both preview and encoding. |
AliRtcVideoPipelineMirrorModeBothMirror | Mirroring is enabled for both preview and encoding. |
AliRtcVideoPipelineMirrorModeOnlyPreviewMirror | Mirroring is enabled for preview only. |
AliRtcVideoPipelineMirrorModeOnlyPublishMirror | Mirroring is enabled for stream ingest only. |
AliRtcCapturePipelineScaleMode: Capture pipeline scaling type.
Enum name | Description |
AliRtcCapturePipelineScaleModePre | Scales immediately after capture (default). |
AliRtcCapturePipelineScaleModePost | Scales during encoding. |
AliRtcNetworkQuality: Network quality.
Enum name | Description |
AlivcRtcNetworkQualityExcellent | The network quality is excellent, providing good fluency and definition. |
AlivcRtcNetworkQualityGood | The network quality is good. The fluency and definition are similar to the Excellent level. |
AlivcRtcNetworkQualityPoor | The network quality is poor. The audio and video fluency and definition are flawed but do not affect communication. |
AlivcRtcNetworkQualityBad | The network quality is bad. The video experiences severe freezes, but audio communication is normal. |
AlivcRtcNetworkQualityVeryBad | The network quality is very bad. Communication is almost impossible. |
AlivcRtcNetworkQualityDisconnect | The network is disconnected. |
AlivcRtcNetworkQualityUnknow | The network quality is unknown. |
AliRtcCapabilityProfile: A profile that aggregates features.
Enum name | Description |
AliRtcCapabilityProfileDefault | Default value. No special requirements. |
AliRtcCapabilityProfileAiHuman | Features for a real user in an AI agent call scenario. |
AliRtcCapabilityProfileAiRobot | Features for a robot in an AI agent call scenario. |
AliRtcChannelParam: Parameters for joining a channel.
Parameter | Type | Description |
channelId | NSString* | The channel to join. This must be the same as the channel ID used to generate the token. This parameter is optional. If not specified, the channel ID used to generate the token is used by default. |
userId | NSString* | The user ID for joining the channel. This must be the same as the user ID used to generate the token. This parameter is optional. If not specified, the user ID used to generate the token is used by default. |
userName | NSString* | Any display name for the user, not the user ID. This parameter is optional. If not specified, it indicates no username. |
capabilityProfile | AliRtcCapabilityProfile | The feature profile. If you have other feature requirements in an AI agent call scenario, you can directly select a profile instead of enabling features one by one. |
AliRtcNetworkQualityProbeConfig: Network probing parameters.
Parameter | Type | Description |
probeUplink | BOOL | Specifies whether to probe the upstream network. Default value: NO. |
probeDownlink | BOOL | Specifies whether to probe the downstream network. Default value: NO. This feature is not currently supported. |
upLinkBandWidth | int | The peak upstream bandwidth to probe, in kbps. Default value: 1000. |
DownLinkBandWidth | int | The peak downstream bandwidth to probe, in kbps. Default value: 1000. This feature is not currently supported. |
AliRtcNetworkQualityProbeResult: Network probing result.
Parameter | Type | Description |
rtt | int | The round-trip time (RTT) of the link, in ms. |
upLinkLossRate | int | The upstream packet loss rate, up to 100%. |
upLinkJitter | int | The upstream network jitter, in ms. |
upLinkBandWidth | int | The upstream network bandwidth, in kbps. |
downLinkLossRate | int | The downstream packet loss rate, up to 100%. This feature is not currently supported. |
downLinkJitter | int | The downstream network jitter, in ms. This feature is not currently supported. |
downLinkBandWidth | int | The downstream network bandwidth, in kbps. This feature is not currently supported. |
AliRtcAudioAccompanyConfig: Configuration for audio accompaniment playback.
Parameter | Type | Description |
onlyLocalPlay | BOOL | Specifies whether to play only locally. |
replaceMic | BOOL | Specifies whether to replace the microphone. |
loopCycles | int | The number of loops. You can set this to -1 for an infinite loop or a positive integer greater than 0. Other values are invalid. |
startPosMs | NSInteger | The starting position for playback, in ms. |
publishVolume | int | The stream ingest volume. Valid values: [0, 100]. Default value: 50. |
playoutVolume | int | The playback volume. Valid values: [0, 100]. Default value: 50. |
AliRtcAudioFileInfo: Audio file information.
Parameter | Type | Description |
filePath | NSString * | The audio file path. |
durationMs | NSInteger | The audio file duration, in ms. |
AliRtcAudioFrame: Raw audio data.
Parameter | Type | Description |
dataPtr | void * | A pointer to the audio data. |
numOfSamples | int | The number of samples. |
bytesPerSample | int | The number of bytes per sample. |
numOfChannels | int | The number of sound channels. |
samplesPerSec | int | The sample rate. |
AliRtcDataMsgType: Data message type.
Enum | Description |
AliRtcDataMsgNone | Undefined message. |
AliRtcDataMsgMusicProgress | Music progress message. |
AliRtcDataMsgCustom | Custom user message. |
AliRtcDataChannelMsg: Data message definition.
Parameter | Type | Description |
type | AliRtcDataMsgType | A pointer to the audio data. |
networkTime | long long | The network timestamp. |
progress | int | The progress. |
data | NSData* | The data. |
AliRtcLocalDeviceType: Local device type.
Enum value | Description |
AliRtcLocalDeviceTypeUnknown | Unknown device type. |
AliRtcLocalDeviceTypeMic | Microphone device. |
AliRtcLocalDeviceTypeSpeaker | Speaker device. |
AliRtcLocalDeviceTypeAudioDevice | Audio device. |
AliRtcLocalDeviceTypeCamera | Camera device. |
AliRtcLocalDeviceTypeDisplay | Display device. |
AliRtcLocalDeviceTypeVideoDevice | Video device. |
AliRtcLocalDeviceExceptionType: Local device exception type.
Enum value | Description |
AliRtcLocalDeviceExceptionTypeUnknown | Unknown exception type. |
AliRtcLocalDeviceExceptionTypeMicOpenFail | Failed to open the microphone. |
AliRtcLocalDeviceExceptionTypeMicInterrupt | The microphone was interrupted. |
AliRtcLocalDeviceExceptionTypeMicAuthFail | No permission for the microphone. |
AliRtcLocalDeviceExceptionTypeMicNotAvailable | No microphone is available. |
AliRtcLocalDeviceExceptionTypeSpeakerOpenFail | Failed to open the speaker. |
AliRtcLocalDeviceExceptionTypeSpeakerInterrupt | The speaker was interrupted. |
AliRtcLocalDeviceExceptionTypeSpeakerNotAvailable | No speaker is available. |
AliRtcLocalDeviceExceptionTypeAudioDeviceException | Audio device exception. |
AliRtcLocalDeviceExceptionTypeCameraOpenFail | Failed to open the camera. |
AliRtcLocalDeviceExceptionTypeCameraInterrupt | The camera was interrupted. |
AliRtcLocalDeviceExceptionTypeCameraAuthFail | No permission for the camera. |
AliRtcLocalDeviceExceptionTypeDisplayExecption | Display device exception. |
AliRtcLocalDeviceExceptionTypeVideoDeviceException | Video device exception. |
AliRtcLocalAudioStateType: Local audio capture state.
Enum value | Description |
AliRtcLocalAudioStateTypeStarting | Starting. |
AliRtcLocalAudioStateTypeStarted | The startup is complete. |
AliRtcLocalAudioStateTypeStopping | Stopping. |
AliRtcLocalAudioStateTypeStopped | Stopped. |
AliRtcLocalVideoStateType: Local video device state.
Enum value | Description |
AliRtcLocalVideoStateTypeStarting | Starting. |
AliRtcLocalVideoStateTypeStarted | Started. |
AliRtcLocalVideoStateTypeStopping | Stopping. |
AliRtcLocalVideoStateTypeStopped | Stopped. |
AliRtcAudioAccompanyStateCode: Playback state of the audio accompaniment.
Enum value | Description |
AliRtcAudioAccompanyStarted | Playback started. |
AliRtcAudioAccompanyStopped | Playback stopped. |
AliRtcAudioAccompanyPaused | Playback paused. |
AliRtcAudioAccompanyResumed | Playback resumed. |
AliRtcAudioAccompanyEnded | Playback ended. |
AliRtcAudioAccompanyBuffering | Buffering. |
AliRtcAudioAccompanyBufferingEnd | Buffering ended. |
AliRtcAudioAccompanyFailed | Playback failed. |
AliRtcAudioAccompanyErrorCode: Error code for audio accompaniment playback.
Enum value | Description |
AliRtcAudioAccompanyNoError | No error. |
AliRtcAudioAccompanyOpenFailed | Failed to open the file. |
AliRtcAudioAccompanyDecodeFailed | Failed to decode the file. |