This topic describes the data types that are used in the Windows SDK.
Contents
| Data type | Description | Supported since version |
| AliRtcVideoTrack | Video track type. | 1.1 |
| AliRtcAudioTrack | Audio track type. | 1.1 |
| AliRtcNetworkQuality | Network quality. | 1.1 |
| AliRtcRenderMode | Rendering mode. | 1.1 |
| AliRtcLogLevel | Log level. | 1.1 |
| AliRtcAuthInfo | Authentication information. | 1.1 |
| AliVideoCanvas | Rendering canvas. | 1.17.19 |
| AliRtcOnByeType | OnBye type. | 1.11 |
| AliRtcScreenShareType | Desktop sharing type. | 1.15 |
| AliRtcClientRole | Role type. | 1.16 |
| AliRtcExternalDeviceState | External device state. | 1.16.2 |
| AliRtcScaleRatio | Video scaling ratio. | 1.16.2 |
| AliRtcAudioNumChannelType | Audio channel type. | 1.16.2 |
| AliRtcAudioSampleRate | Audio recording sample rate. | 1.16.2 |
| AliRtcAudioSource | Raw audio data source type. | 1.16.2 |
| AliRtcVideoSource | Raw video data source type. | 1.16.2 |
| AliRtcVideoFormat | Video data format. | 1.17.19 |
| AliRtcBufferType | Video data type. | 1.16.2 |
| AliRtcMuteLocalAudioMode | Local mute mode. | 1.16.2 |
| AliRtcScreenSourceList | Share source list. | 1.16.2 |
| AliRtcScreenShareRegion | Screen sharing region. | 1.16.2 |
| AliRtcScreenSource | Share source. | 1.16.2 |
| AliRtcDeviceList | Device list. | 1.16.2 |
| AliRtcStats | Session statistics. | 1.17.38 |
| AliRtcVideoDataSample | Video data. | 1.16.2 |
| AliRtcAudioDataSample | Audio data. | 1.16.2 |
| AliRtcAudioEffectReverbMode | Reverb effect mode. | 1.17 |
| AliRtcAudioEffectReverbParamType | Reverb effect type. | 1.17 |
| AliRtcRecordType | Record type. | 1.17 |
| AliRtcRecordFormat | Record format. | 1.17 |
| AliRtcAudioQuality | Audio recording quality. | 1.17 |
| AliRtcVideoQuality | Video recording quality. | 1.17 |
| AliRtcRecordAudioConfig | Audio recording settings. | 1.17 |
| AliRtcRecordVideoConfig | Video recording settings. | 1.17 |
| AliRtcLocalVideoStats | Local video statistics. | 1.17 |
| AliRtcRemoteVideoStats | Remote video statistics. | 1.17 |
| AliRtcVideoProfile | Video stream parameters. | 1.17.19 |
| AliRtcUserVolumeInfo | User volume information. | 1.17.9 |
| AliRtcBeautyConfig | Retouching settings. | 1.17.9 |
| AliRtcChannelProfile | Channel type. | 1.17.9 |
| AliRtcFeedbackType | SDK feedback type. | 1.17.12 |
| ErrorCodeEnum | SDK error codes. | 1.17.19 |
| AliRtcRotationMode | Video rotation angle. | 1.17.30 |
| AliRtcVideoEncoderMirrorMode | Video encoder mirror mode. | 1.17.31 |
| AliRtcVideoEncoderConfiguration | Video encoding preferences. | 1.17.31 |
Details
AliRtcVideoTrack: The video track type.
Enumeration Name Description AliRtcVideoTrackNo No video stream. AliRtcVideoTrackCamera Camera stream. AliRtcVideoTrackScreen Screen sharing stream. AliRtcVideoTrackBoth Camera and screen sharing streams. AliRtcAudioTrack: The audio track type.
Enumeration name Description AliRtcAudioTrackNo No audio stream. AliRtcAudioTrackMic Microphone stream. AliRtcNetworkQuality: The network quality.
Enumeration Name Description AliRtcNetworkQualityExcellent Excellent network quality. The video is smooth and clear. AliRtcNetworkQualityGood Good network quality. The video is almost as smooth and clear as the Excellent level. AliRtcNetworkQualityPoor Poor network quality. The audio and video have minor issues with smoothness and clarity, but communication is not affected. AliRtcNetworkQualityBad Bad network quality. The video stutters severely, but audio communication is normal. AliRtcNetworkQualityVeryBad Very bad network quality. Communication is nearly impossible. AliRtcNetworkQualityDisconnect The network is disconnected. AliRtcNetworkQualityUnknow Unknown. AliRtcRenderMode: The rendering mode.
Enumeration Name Description AliRtcRenderModeAuto Auto mode. AliRtcRenderModeStretch Stretches the video to fill the view. The aspect ratio is not maintained. AliRtcRenderModeFill Scales the video while maintaining the aspect ratio. Black bars are added to fill the view. AliRtcRenderModeCrop Scales the video while maintaining the aspect ratio and crops it to fit the view. AliRtcRenderModeScroll Scrolls the view to show more content. AliRtcLogLevel: The log level.
Enumeration Name Description AliRtcLogLevelDump All. AliRtcLogLevelDebug Debug. AliRtcLogLevelVerbose Details AliRtcLogLevelInfo General AliRtcLogLevelWarn Warning. AliRtcLogLevelError Error. AliRtcLogLevelFatal Fatal. AliRtcLogLevelNone None. AliRtcAuthInfo: The authentication information.
Important The session id field is removed in versions 1.9 and later.Parameter Type Description channel AliRtc::String The channel ID. user_id AliRtc::String The user ID. appid AliRtc::String The application ID. nonce AliRtc::String The nonce for the token. token AliRtc::String The token. gslb AliRtc::String The server address. timestamp long long The timestamp. agent AliRtc::StringArray The agent server address. By default, this parameter is not passed. role AliRtc::String The role type. The default value is empty, which indicates that this feature is not used. Valid values: - pub: The streamer role.
- sub: The viewer role.
AliVideoCanvas: The rendering canvas.
Parameter Type Description hWnd HWND The handle of the rendering window. renderMode AliRtcRenderMode The rendering mode. flip bool true: The image is mirrored. false: The image is normal. backgroundColor int The background color in the hexadecimal RGB format. rotation AliRtcRotationMode The video rotation angle. scaleRatio AliRtcScaleRatio The preview scaling ratio. AliRtcOnByeType: The OnBye type.
Enumeration name Description AliRtcOnByeBeKickOut The current user is kicked out of the channel. AliRtcOnByeChannelTerminated The channel is closed. AliRtcOnByeUserReplaced The same user joins the channel on another device, and the current device is forced to go offline. AliRtcScreenShareType: The screen sharing type.
Enumeration name Description AliRtcScreenShareDesktop Desktop sharing. AliRtcScreenShareWindow Window sharing. AliRtcClientRole: The client role type.
Enumeration name Description AliRtcClientRoleInteractive Interactive role. AliRtcClientRoleLive Viewer-only role. AliRtcExternalDeviceState: The external device state.
Enumeration member Description AliRtcExternalDeviceAdd An external device is added. AliRtcExternalDeviceRemove An external device is removed. AliRtcScaleRatio: The video scaling ratio.
Enumeration member Description AliRtcScaleRatio_16_9 16:9. AliRtcScaleRatio_4_3 4:3. AliRtcAudioNumChannelType: The number of audio channels.
Enumeration Name Description AliRtcMonoAudio Mono audio. AliRtcStereoAudio Stereo audio. AliRtcAudioSampleRate: The audio recording sample rate.
Enumeration name Description AliRtcAudioSampleRate_8000 8000 Hz. AliRtcAudioSampleRate_11025 11025 Hz. AliRtcAudioSampleRate_16000 16000 Hz. AliRtcAudioSampleRate_22050 22050 Hz. AliRtcAudioSampleRate_32000 32000 Hz. AliRtcAudioSampleRate_44100 44100 Hz. AliRtcAudioSampleRate_48000 48000 Hz. AliRtcAudioSource: The raw audio data source type.
Enumeration name Description AliRtcAudiosourcePub Publish. AliRtcAudiosourceSub Subscribe. AliRtcAudiosourceRawData Raw data. AliRtcAudioSourceVolume Volume. AliRtcVideoSource: The raw video data source type.
Enumeration Name Description AliRtcVideoSourceCamera Camera stream. AliRtcVideoSourceScreenShare Shared stream. AliRtcVideoFormat: The video data format.
Enumeration name Description AliRtcVideoFormatUnknow Unknown. AliRtcVideoFormatBGRA BGRA format. AliRtcVideoFormatI420 I420 format. AliRtcVideoFormatNV21 NV21 format. AliRtcVideoFormatNV12 NV12 format. AliRtcBufferType: The video data buffer type.
Enumeration name Description AliRtcBufferTypeRawData Raw data. AliRtcBufferTypeCVPixelBuffer Watermark. AliRtcBufferTypeTexture Texture. AliRtcMuteLocalAudioMode: The local audio muting mode.
Enumeration name Description AliRtcMuteLocalAudioModeDefault Default mute mode. AliRtcMuteAllLocalAudioMode Mutes all local audio. AliRtcMuteOnlyMicAudioMode Mutes the microphone. AliRtcScreenSourceList: The list of screen sharing sources.
Parameter Type Description sourceNum long long The number of share sources. sourceId AliRtc::StringArray An array of share source IDs. sourceTitle AliRtc::StringArray An array of share source names. AliRtcScreenShareRegion: The screen sharing region.
Parameter Type Description originX float The x-axis. originY float The y-axis. width float The width. height float The height. AliRtcScreenSource: The screen sharing source.
Parameter Type Description eType AliRtcScreenShareType The desktop sharing type. sourceId AliRtc::String The share source ID. sourceTitle AliRtc::String The share source name. isShareByRegion bool Specifies whether to enable the sharing region. shareRegion AliRtcScreenShareRegion The sharing region. AliRtcDeviceList: The device list.
Parameter Type Description deviceCount long long The number of devices. deviceIds AliRtc::StringArray An array of device IDs. deviceNames AliRtc::StringArray An array of device names. AliRtcStats: The session statistics.
Parameter Type Description sent_kbitrate int64_t The send bitrate. rcvd_kbitrate int64_t The receive bitrate. sent_bytes int64_t The number of bytes sent. rcvd_bytes int64_t The number of bytes received. system_cpu uint32_t The CPU usage of the computer. app_cpu uint32_t The CPU usage of the RTC process. video_rcvd_kbitrate int64_t The video receive bitrate. video_sent_kbitrate int64_t The video send bitrate. call_duration int64_t The call duration in seconds. sent_loss_rate int8_t The packet loss rate for sending. lastmile_delay int64_t The latency in milliseconds. AliRtcVideoDataSample: The video data sample.
Parameter Type Description format AliRtcVideoFormat The video data format. bufferType AliRtcBufferType The video data type. char *data unsigned char * A pointer to the stored data. size_t dataLen size_t The data length. strideY int Luminance. strideU int Chroma. strideV int Concentration height int Height. width int Width. rotation int The rotation in degrees. timeStamp long long The timestamp. AliRtcAudioDataSample: The audio data sample.
Parameter Type Description data unsigned char * The audio data. numOfSamples int The number of samples. bytesPerSample int The audio bit depth in bytes. numOfChannels int The number of sound channels. samplesPerSec int The sample rate. AliRtcAudioEffectReverbMode: The reverb effect mode.
Enumeration name Description AliRtcAudioEffect_Reverb_Off Off. AliRtcAudioEffect_Reverb_Vocal_I Vocal I. AliRtcAudioEffect_Reverb_Vocal_II Vocal II. AliRtcAudioEffect_Reverb_Bathroom Bathhouse. AliRtcAudioEffect_Reverb_Small_Room_Bright Bright small room. AliRtcAudioEffect_Reverb_Small_Room_Dark Dark small room. AliRtcAudioEffect_Reverb_Medium_Room Medium room. AliRtcAudioEffect_Reverb_Large_Room Large room. AliRtcAudioEffect_Reverb_Church_Hall Church Corridor AliRtcAudioEffect_Reverb_Cathedral Cathedral. AliRtcAudioEffectReverbParamType: The reverb effect parameter type.
Enumeration Name Description AliRtcAudioEffect_Reverb_Room_Size The room size. Valid values: [0, 100]. AliRtcAudioEffect_Reverb_Pre_Delay The pre-delay in ms. Valid values: [0, 200]. AliRtcAudioEffect_Reverb_Reverberance The reverberance. Valid values: [0, 100]. AliRtcAudioEffect_Reverb_Hf_Damping The noise suppression level, which ranges from 0 to 100. AliRtcAudioEffect_Reverb_Tone_Low The low tone. Valid values: [0, 100]. AliRtcAudioEffect_Reverb_Tone_High The high tone. Valid values: [0, 100]. AliRtcAudioEffect_Reverb_Dry_Gain The dry gain. Valid values: [-20, 10]. AliRtcAudioEffect_Reverb_Wet_Gain The wet gain. Valid values: [-20, 10]. AliRtcRecordType: The record type.
Enumeration Name Description AliRtcRecordTypeAudio Audio-only recording. AliRtcRecordTypeVideo Video-only recording. AliRtcRecordTypeBoth Audio and video recording. AliRtcRecordFormat: The record format.
Enumeration name Description AliRtcRecordFormatAAC AAC file. AliRtcRecordFormatWAV WAV file. AliRtcRecordFormatMP4 MP4 file. AliRtcAudioQuality: The audio recording quality.
Enumeration name Description AliRtcAudioQualityLow Low. AliRtcAudioQualityMidium Medium. AliRtcAudioQualityHigh High. AliRtcVideoQuality: The video recording quality.
Enumeration name Description AliRtcVideoQualityDefault Default. The recording quality is the same as the capture quality. For example, if the capture resolution is 1080p, the recorded video stream is also 1080p. AliRtcRecordAudioConfig: The audio recording configuration.
Parameter Type Description sampleRate AliRtcAudioSampleRate The audio sampling rate. quality AliRtcAudioQuality The audio quality. externalPcmCaptureRecording bool External PCM input recording. externalPcmRenderRecording bool External PCM rendering recording. AliRtcRecordVideoConfig: The video recording configuration.
Parameter Type Description quality AliRtcVideoQuality The video quality. sourceType AliRtcVideoSource The video source type. AliRtcLocalVideoStats: The local video statistics.
Parameter Type Description track AliRtcVideoTrack The video stream type. sent_bitrate uint32_t The send bitrate. sent_fps uint32_t The send frame rate. encode_fps uint32_t The output frame rate of the encoder. AliRtcRemoteVideoStats: The remote video statistics.
Parameter Type Description user_id AliRtc::String The user ID. track AliRtcVideoTrack The video stream type. width uint32_t Width. height uint32_t Height. decode_fps uint32_t The output frame rate of the encoder. render_fps uint32_t The output frame rate of the renderer. frozen_times uint32_t The number of stutters. AliRtcVideoProfile: The video stream parameters.
The default value is AliRtcVideoProfile_Default. You can set this parameter before or after you join a channel, but you must set it using the setVideoProfile method before you publish a stream.
Enumeration Name Description AliRtcVideoProfile_Default Default. Resolution: 480 × 640. Frame rate: 15. AliRtcVideoProfile_180_240P_15 Resolution: 180 × 240. Frame rate: 15. AliRtcVideoProfile_180_320P_15 Resolution: 180 × 320. Frame rate: 15. AliRtcVideoProfile_180_320P_30 Resolution: 180 × 320. Frame rate: 30. AliRtcVideoProfile_240_320P_15 Resolution: 240 × 320. Frame rate: 15. AliRtcVideoProfile_360_480P_15 Resolution: 360 × 480. Frame rate: 15. AliRtcVideoProfile_360_480P_30 Resolution: 360 × 480. Frame rate: 30. AliRtcVideoProfile_360_640P_15 Resolution: 360 × 640. Frame rate: 15. AliRtcVideoProfile_360_640P_30 Resolution: 360 × 640. Frame rate: 30. AliRtcVideoProfile_480_640P_15 Resolution: 480 × 640. Frame rate: 15. AliRtcVideoProfile_480_640P_30 Resolution: 480 × 640. Frame rate: 30. AliRtcVideoProfile_720_960P_15 Resolution: 720 × 960. Frame rate: 15. AliRtcVideoProfile_720_960P_30 Resolution: 720 × 960. Frame rate: 30. AliRtcVideoProfile_720_1280P_15 Resolution: 720 × 1280. Frame rate: 15. AliRtcVideoProfile_720_1280P_30 Resolution: 720 × 1280. Frame rate: 30. AliRtcVideoProfile_1080_1920P_15 Resolution: 1080 × 1920. Frame rate: 15. AliRtcVideoProfile_1080_1920P_30 Resolution: 1080 × 1920. Frame rate: 30. AliRtcVideoProfile_480_640P_15_1500Kb Resolution: 480 × 640. Frame rate: 15. Bitrate: 1500 Kbps. AliRtcVideoProfile_900_1600P_20 Resolution: 900 × 1600. Frame rate: 20. AliRtcVideoProfile_360_640P_15_800Kb Resolution: 360 × 640. Frame rate: 15. Bitrate: 800 Kbps. AliRtcVideoProfile_480_840P_15_500Kb Resolution: 480 × 840. Frame rate: 15. Bitrate: 500 Kbps. AliRtcVideoProfile_480_840P_15_800Kb Resolution: 480 × 840. Frame rate: 15. Bitrate: 800 Kbps. AliRtcVideoProfile_540_960P_15_800Kb Resolution: 540 × 960. Frame rate: 15. Bitrate: 800 Kbps. AliRtcVideoProfile_540_960P_15_1200Kb Resolution: 540 × 960. Frame rate: 15. Bitrate: 1200 Kbps. AliRtcVideoProfile_540_960P_20 Resolution: 540 × 960. Frame rate: 20. AliRtcVideoProfile_720_1280P_20 Resolution: 720 × 1280. Frame rate: 20. AliRtcVideoProfile_1080_1920P_20 Resolution: 1080 × 1920. Frame rate: 20. AliRtcUserVolumeInfo: The user volume information.
Parameter Type Description user_id AliRtc::String The user ID. This is a unique identifier issued by the AppServer. volume int The user's volume. Valid values: 0 to 255. speech_state int A value of 1 indicates that the user is speaking. AliRtcBeautyConfig: The retouching configuration.
Parameter Type Description whiteningLevel float The whitening level. Valid values: [0, 1]. A larger value indicates a stronger whitening effect. smoothnessLevel float The smoothing level. Valid values: [0, 1]. A larger value indicates a stronger smoothing effect. AliRtcChannelProfile: The channel profile.
Enumeration name Description AliRtcCommunication Communication mode. AliRtcInteractiveLive Interactive mode. AliRtcFeedbackType: The SDK feedback type.
Enumeration name Description AliRtcFeedbackVideoDeviceFail Video device issue. AliRtcFeedbackVideoNotRender No video frames. AliRtcFeedbackAudioDeviceFail Audio device issue. AliRtcFeedbackAudioNotRender No sound. AliRtcFeedbackAudioEchoError Abnormal audio echo. AliRtcFeedbackChannelTypeError Abnormal channel state, such as an error when joining or leaving a channel. AliRtcFeedbackSDKTypeError Other abnormal SDK states. AliRtcFeedbackNetworkUnfluent Network stuttering issue. AliRtcFeedbackVideoBlurring Video clarity issue. AliRtcFeedbackUnkonw Unknown type. - ErrorCodeEnum: The SDK error codes.
Enumeration name Description ERR_JOIN_BAD_APPID = 0x02010201 The AppId does not exist. ERR_JOIN_INVALID_APPID = 0x02010202 The AppId is invalid. ERR_JOIN_BAD_CHANNEL = 0x02010204 The channel does not exist. ERR_JOIN_INVALID_CHANNEL = 0x02010203 The channel is invalid. ERR_JOIN_BAD_TOKEN = 0x02010205 The token does not exist. ERR_JOIN_TIMEOUT = 0x01020204 The request to join the channel timed out. ERR_JOIN_BAD_PARAM = 0x01030101 The parameters for joining the channel are invalid. ERR_MIC_OPEN_FAIL = 0x01040404 Failed to initialize the capture device. ERR_SPEAKER_OPEN_FAIL = 0x01040405 Failed to initialize the playback device. ERR_MIC_INTERRUPT = 0x01040406 An exception occurred during capture. ERR_SPEAKER_INTERRUPT = 0x01040407 An exception occurred during playback. ERR_MIC_AUTH_FAIL = 0x01040408 Failed to obtain authorization for the microphone. ERR_MIC_NOT_AVAILABLE = 0x01040409 Authorization for the microphone is not granted. ERR_SPEAKER_NO_AVAILABLE = 0x01040410 No audio capture device is available. ERR_CAMERA_OPEN_FAIL = 0x01040104 Failed to initialize the camera. ERR_CAMERA_INTERRUPT = 0x01040106 An exception occurred during camera capture. ERR_VIDEO_DISPLAY_OPEN_FAIL = 0x01040201 Failed to initialize the rendering device. ERR_VIDEO_DISPLAY_INTERRUPT = 0x01040202 An exception occurred during rendering. ERR_AUDIO_BUFFER_FULL = 0x01070101 The audio input buffer is full. ERR_ICE_CONNECTION_CONNECT_FAIL = 0x01050201 Failed to establish the media channel. ERR_ICE_CONNECTION_RECONNECT_FAI = 0x01050202 Failed to reconnect to the media channel. ERR_ICE_CONNECTION_HEARTBEAT_TIMEOUT = 0x0102020C The signaling heartbeat timed out. ERR_LOWLATENCY_LIVE_COMMUNICATION_FAIL = 0x01070003 A signaling failure occurred in the interactive stream. ERR_LOWLATENCY_LIVE_MEDIA_SETTING_FAIL = 0x01070004 An error occurred in the media settings for the interactive stream. ERR_LOWLATENCY_LIVE_NONE_BROADCASTER = 0x01070005 No streamer is publishing a stream in the current channel of the interactive stream. ERR_LOWLATENCY_LIVE_NEED_RESTART = 0x01070006 An error occurred in the interactive stream. The application layer must create a new SDK instance. ERR_LOWLATENCY_LIVE_NEEDRESTART_AGAIN_LATER = 0x01070007 An error occurred in the interactive stream. The application layer must wait for a custom interval and then create a new SDK instance. ERR_LOWLATENCY_LIVE_SERVICE_UNAVAILABLE = 0x01070008 The interactive stream service is unavailable or degraded. ERR_LOWLATENCY_LIVE_MEDIA_CONNECTION_INTERRUPTION = 0x01070009 A network disconnection error occurred in the interactive stream. ERR_SDK_INVALID_STATE = 0x01030204 An internal SDK state error occurred. ERR_SESSION_REMOVED = 0x02010105 The session has been removed. ERR_INNER = -1 An internal SDK error occurred. - AliRtcRotationMode: The video rotation mode.
Enumeration Name Description AliRtcRotationMode_0 0-degree rotation. AliRtcRotationMode_90 Rotates the video by 90 degrees. AliRtcRotationMode_180 Rotates the video by 180 degrees. AliRtcRotationMode_270 Rotates the video by 270 degrees. - AliRtcVideoEncoderMirrorMode: The video encoder mirror mode.
Enumeration Name Description AliRtcVideoEncoderMirrorModeDisabled Mirrors the encoded video. AliRtcVideoEncoderMirrorModeEnabled Does not mirror the encoded video. - AliRtcVideoEncoderConfiguration: The video encoder configuration.
Parameter Type Description mirrorMode AliRtcVideoEncoderMirrorMode The mirror mode for the encoded video.