Release notes
Updated
Information about changes in each release of Video Calling.
This page provides the release notes for the RTC SDK release streams used by Video Calling.
RTC SDK
Known issues
Library conflict
Starting from v4.5.0, both RTC SDK and Signaling SDK v2.2.0 and later include the libaosl.dll library. If you manually integrate RTC SDK through a CDN and also use Signaling SDK, delete the earlier version of libaosl.dll to avoid conflicts. You can check the library version in the libaosl.dll file properties.
v4.6.2
Released on January 19, 2026.
New features
Included in this release:
-
Support for getting audio buffer delay
To address the issue where the main vocal and background accompaniment may be out of sync in karaoke scenarios, this release adds the
getAudioBufferDelaymethod to the Media Player module to get the millisecond-level audio buffer delay when playing media files.
Improvements
This release includes the following enhancements:
-
Seamless switching for sound effect files
Adds support for seamless switching of sound effect files. For the same sound effect file, if you call
preloadEffectfollowed byplayEffect, the SDK does not close the file after playback completes or whenstopEffectis called. When you callplayEffectagain, the SDK reuses the loaded file to enable loop playback and seamless switching. This feature also works in multi-channel scenarios. -
Window exclusion support for second screen sharing
In versions prior to 4.6.2, when using
startScreenCaptureByDisplayIdto share a screen by screen ID, it was not possible to configure excluded windows (excludeWindowListinScreenCaptureParameters) in multi-screen scenarios. This version adds support for this configuration to improve the screen sharing experience. Additionally, a new enum valueLOCAL_VIDEO_STREAM_REASON_SCREEN_CAPTURE_EXCLUDE_WINDOW_FAILED (34)is added toLOCAL_VIDEO_STREAM_REASONto report failures in excluding windows during screen capture. -
Optimized timing for
onVideoDeviceStateChangedcallbackThis version optimizes the trigger timing of the
onVideoDeviceStateChangedcallback. In previous versions, this callback was only triggered after joining a channel. Starting from this version, it is triggered once afterRtcEngineis initialized, and continues to be available after joining a channel. -
Improved accuracy of network quality evaluation
Improves the accuracy of network quality evaluation in the
onNetworkQualitycallback, making the reported data better reflect the user's perceived experience. -
Support for 24kHz sampling rate for audio playback
Adds support for audio data with a sample rate of 24000 Hz in
onPlaybackAudioFrame. When callingsetPlaybackAudioFrameParametersto set the playback audio format, you can setsampleRateto24000. -
onEncodedVideoFrameReceivedsupportschannelIdAdds the
channelIdparameter to theonEncodedVideoFrameReceivedcallback, helping you identify which channel the encoded video data belongs to. -
Additional improvements
- Adds error codes
ERR_PCMSEND_FORMAT (200)andERR_PCMSEND_BUFFEROVERFLOW (201)to report PCM data transmission errors.
- Adds error codes
Compatibility changes
This release introduces the following compatibility changes:
-
Removed
uidfromEncodedVideoFrameInfostructThe
uidparameter is removed from theEncodedVideoFrameInfostruct. You can retrieve theuiddirectly from theonEncodedVideoFrameReceivedcallback. Update your integration logic accordingly. -
Decoder plugins built into the SDK
The relevant decoder plugins are now built into the SDK to ensure overall decoding compatibility.
Issues fixed
This release fixes the following issues:
- The second call to
enumerateVideoDevicesdid not return the device list. - On Windows 7 devices, when sharing a PPT window in full-screen auto-play mode with many animations, the remote side saw flickering.
v4.6.0
Released on August 26, 2025.
The version of the libaosl.dll library in the v4.6.0 SDK is 1.3.0. You can find the library version information by checking the properties of the libaosl.dll file.
Compatibility changes
This version includes SDK behavior changes, API deprecations, and deletions. To ensure your app functions correctly, update your code after upgrading to this version.
For details on deprecated and deleted APIs in each version, see the API Sunset Notice.
-
Deprecation of direct CDN streaming APIs
Deprecates the APIs related to direct CDN streaming, which will be removed in a future release. Agora recommends using Media Push instead.
setDirectCdnStreamingAudioConfigurationsetDirectCdnStreamingVideoConfigurationstartDirectCdnStreamingstopDirectCdnStreamingupdateDirectCdnStreamingMediaOptionsDirectCdnStreamingMediaOptionsDirectCdnStreamingStatsDIRECT_CDN_STREAMING_STATEDIRECT_CDN_STREAMING_REASON
-
Deprecation of virtual metronome APIs
Deprecates the APIs for the virtual metronome feature, which will be removed in a future release.
startRhythmPlayerconfigRhythmPlayeronRhythmPlayerStateChanged
-
Deprecation of watermark APIs
Deprecates the old watermark APIs. Agora recommends using the new watermark APIs introduced in this version.
addVideoWatermark2addVideoWatermarkEx
-
Deletion of redundant APIs
Removed the following redundant APIs and parameters:
setLocalPublishFallbackOptiononLocalPublishFallbackToAudioOnlyonDownlinkNetworkInfoUpdatedonWlAccStatsWlAccStatsonWlAccMessageWLACC_MESSAGE_REASONWLACC_SUGGEST_ACTIONenableWirelessAccelerate
-
Behavior changes in dual-stream mode
- Before v4.6.0: When the sender enabled adaptive stream mode (
AUTO_SIMULCAST_STREAM), the low stream was not sent proactively. The sender only started sending the low stream after receiving a request from a host-role receiver callingsetRemoteVideoStreamType. - Starting from v4.6.0: When the sender enables adaptive low-stream mode (
AUTO_SIMULCAST_STREAM), the SDK automatically decides whether to send or stop sending streams based on the downlink network quality of subscribing users. If you setmodeto another sending mode or explicitly configure the width, height, bitrate, or frame rate, this adaptive behavior is disabled.
- Before v4.6.0: When the sender enabled adaptive stream mode (
-
Changes to int UID and string UID mapping
- Before v4.6.0: If
registerLocalUserAccountwas used to register a string UID (for example, "aa") and obtain an int UID (for example, 123), joining a channel later with the int UID automatically mapped it to the original string UID ("aa"). - From v4.6.0: The SDK no longer automatically maps an int UID to the original string UID. If
registerLocalUserAccountwas called to get an int UID but the channel needs to be joined with the original string UID, calljoinChannelWithUserAccountdirectly with the string UID. After upgrading, review and update app logic to ensure users join the channel with the expected identity.
- Before v4.6.0: If
-
Added domain whitelist
If you have upgraded from a previous SDK version to v4.6.0 and are using the domain whitelist feature (set
domainLimittotrueinRtcEngineConfig), add the following domains to the whitelist to ensure uninterrupted communication:*.rtnsvc.com*.realtimemesh.com
New features
-
Simulcasting multi-bitrate video streams (Beta)
Added support for sending multiple video streams of different resolutions from a single video source, including in multi-channel scenarios. You can now configure up to four layers: one high-resolution stream and up to three lower-resolution streams. Use configuration options to define resolution, bitrate, and whether to automatically reduce the number of streams when network or device performance drops. Subscribers can choose which stream to receive based on their network conditions. This feature helps developers deliver smooth experiences in scenarios such as conferences, large classes, and interactive live streaming, even when network conditions are poor.
-
Multipath network transmission
Introduced multipath transmission for devices with multiple network interfaces (for example, 5G, Wi-Fi, and LAN). This feature effectively reduces or eliminates experience degradation caused by poor network conditions, making it suitable for real-time audio and video communication scenarios that demand high transmission stability, such as in-vehicle systems, IoT, trains, and highways. Enable it by setting
enableMultipathinChannelMediaOptionstotrue.- Dynamic mode: Dynamically selects the optimal path based on network conditions. Optionally set
preferMultipathTypeto prioritize a path type. If not set, all path types have the same default weight. - Duplicate mode: Sends data simultaneously over all available paths for maximum stability. This mode incurs additional costs and eliminates the impact of poor network conditions.
Configure uplink and downlink modes separately with
uplinkMultipathModeanddownlinkMultipathMode. Monitor performance with theonMultipathStatscallback, which reports real-time transmission statistics for each path, including data consumption. Contact support@agora.io to enable duplicate mode. - Dynamic mode: Dynamically selects the optimal path based on network conditions. Optionally set
-
Video quality scoring
Added the
mosValuemember toRemoteVideoStatsto report a score from 1 (extremely poor with severe blurring) to 5 (excellent with clear image and no artifacts) for received video quality. This enables real-time monitoring of the subjective quality of remote video streams, which helps in dynamically adjusting video parameters for quality monitoring and alerting. Contact support@agora.io to enable this feature. -
Support for adding multiple watermarks
Introduced
addVideoWatermark3andaddVideoWatermarkEx1, which support multiple watermarks with IDs and layering order. Remove a specific watermark usingremoveVideoWatermark. -
Asynchronous engine destruction
Added the
releasemethod with acallbackparameter, supporting synchronous or asynchronous engine destruction. In asynchronous mode, the SDK triggers theRtcEngineReleaseCallbackcallback. -
Token renewal result callback
Added the
onRenewTokenResultcallback andRENEW_TOKEN_ERROR_CODEto report the result ofrenewToken. This allows developers to handle Token renewal failures promptly within the callback. -
Advanced beauty (Beta)
Introduced a brand-new advanced beauty feature, delivering a powerful yet easy-to-use beautification solution.
-
Precision beauty effects
- Face shaping: Supports independent fine-tuning of 29 facial areas (for example, slimming face, enlarging eyes, narrowing nose) or one-click natural effects via presets.
- Style makeup: Offers rich effects including eyeshadow, colored contacts, eyeliner, eyebrow shaping, lipstick, blush, under-eye highlights, and facial contouring.
- Skin enhancement: Includes professional skin optimizations such as teeth whitening, nasolabial fold removal, dark circle reduction, and eye brightening.
-
Unified and simple API Manage all beauty, makeup, and filter functions through three core nodes —
BEAUTY,STYLE_MAKEUP, andFILTER— usingIVideoEffectObjectfor unified parameter setup and lifecycle control. -
Ready-to-use presets Integrates multiple out-of-the-box style templates (for example, "Natural Beauty," "Senior Makeup," "Cool White Filter") for instant polished results.
-
Dynamic parameter control Enables real-time reading and modification of granular parameters (for example, smoothing strength, lipstick type) via key-value pairs, with support for saving custom configurations and resetting defaults.
-
Local resource guarantee All beauty resources (effects, filters, makeup) are packaged as local bundle files, ensuring stability and reliability.
-
-
Other new features
- Added
setPlaybackAudioFrameBeforeMixingParameters2to configure the format of raw audio frames returned inonPlaybackAudioFrameBeforeMixing, including sample rate, number of channels, and the number of samples per callback. - Added
preloadEffectExto preload audio effects into a specific channel. Supports both local and online audio files, enabling faster playback later and is suitable for multi-channel scenarios. - Added
playEffectExfor advanced audio effect playback in a specific channel with parameters such as loop count, pitch, spatial position, volume, whether to publish to the channel, and the starting playback position. - Added the
positionmember inContentInspectModuleto choose the capture point for screenshot uploads from either the raw video data or the video stream before or after effects processing. - Added the
screenColorTypemember toSegmentationPropertyfor specifying or auto-detecting background screen color (green, blue, or auto-detect) to improve the accuracy and stability of portrait segmentation when using virtual backgrounds.
- Added
Improvements
- Optimized permission requests on Windows 11 24H2 and later versions to avoid unnecessarily acquiring location information.
- Added support for G.711 and G.722 audio codecs when interoperating with the Web SDK for improved cross-platform audio compatibility and clarity.
- Improved video clarity in screen sharing scenarios involving documents.
Issues fixed
This version fixes the following issues:
- Online audio effect playback restarted from the beginning when
seekwas called. - Occasional echoes in media volume mode when publishing a microphone stream while simultaneously playing effects with
playEffect3and music withstartAudioMixing2. - SDK crashed on Windows when handling file paths containing Chinese characters due to an encoding conversion error.
- Media relay occasionally reported
RELAY_STATE_FAILUREandRELAY_ERROR_SERVER_ERROR_RESPONSEafter join, relay, unpublish, leave, rejoin, and relay again sequences. - Receivers occasionally heard echoes when the sender shared their screen and audio from certain laptop models with power-saving mode enabled.
- In online education scenarios, the teacher's local view of multiple students' video and audio was occasionally out of sync.
v4.5.2
v4.5.2 was released on April 22, 2025.
Note
The aosl.dll library version in RTC SDK v4.5.2 is 1.2.13.
Issues fixed
This release fixes the following issues:
- When playing a multi-track media file, you could hear noise after calling the
setAudioPitchmethod to adjust the pitch. - After the host called
createCustomAudioTrackwithtrackTypeset toAUDIO_TRACK_DIRECT, pushed custom audio frames usingpushAudioFrame, and played audio effects withplayEffect, audience members heard noise. - Apps integrated with the SDK occasionally experienced UI lag due to main thread blocking during audio and video interactions.
- The local preview of a shared screen flickered after calling
startScreenCapture [2/2], enablingenableHighLightinScreenCaptureParameters, placing the shared window on the top layer, and maximizing it. - When using
startScreenCaptureByDisplayIdwithexcludeWindowListinScreenCaptureParameters, some windows failed to be excluded as expected. - The app crashed after sharing video from an external screen and then disconnecting the screen.
- Calling
openWithMediaSourceand settingisLiveSourcetotruefailed to play the video stream. - When sending multi-channel encoded audio, the receiver occasionally heard noise.
- When the app integrated a media player and called
opentwice to load different media resources in succession, theonPlayerInfoUpdated [1/2]callback incorrectly returned info for the first resource. - After calling
enableAudioVolumeIndication, thertcEngine:reportAudioVolumeIndicationOfSpeakers:totalVolume:callback returned a local user volume of 0 for both local and remote users. - In scenarios involving audio/video communication and screen sharing on a 21 ultra-wide display, setting a high resolution such as 3840×2160 resulted in the shared screen image being cropped in both the local preview and on the receiver's display.
- When the app called
enableVideoImageSourceto enable the video image source feature, the sender appeared to stream successfully, but theonVideoPublishStateChangedcallback did not return as expected. - In multi-channel scenarios, if the app called
setupRemoteVideoExto initialize the remote user’s view before successfully callingjoinChannelEx, the first frame of the remote video was significantly delayed.
v4.5.1
v4.5.1 was released on March 4, 2025.
Note
The aosl.dll library version in RTC SDK v4.5.1 is 1.2.13.
New Features
AI Conversation Scenario
This version introduces the AUDIO_SCENARIO_AI_CLIENT audio scenario, specifically designed for interacting with the conversational AI agent created by Conversational AI Engine. This scenario optimizes the audio transmission algorithm based on the characteristics of AI-generated voices, ensuring stable voice data transmission even in weak network conditions with up to 80% packet loss. The optimization enhances conversation continuity and reliability, adapting to various challenging network environments.
Issues Fixed
This release resolves the following issues:
- When joining two or more channels simultaneously and calling
takeSnapshotExto capture local video stream screenshots consecutively, the first channel's screenshot failed. - When using the
pausemethod to pause playback, then callingseekto move to a specific position, and finally callingplay, the Media Player resumed from the paused position instead of the specified position. - When using the Media Player, the file path of the media resource returned by
getPlaySrcdid not update after callingswitchSrcto switch to a new media resource. - In interactive live streaming scenarios, after joining a channel as an audience member using a
stringuser ID, audio occasionally became unsynchronized with video. - AI noise suppression and AI echo cancellation plugins sometimes failed when used together.
v4.5.0
This version was released on November 27, 2024.
Compatibility changes
This version includes optimizations to some features, including changes to SDK behavior, API renaming and deletion. To ensure normal operation of the project, update the code in the app after upgrading to this release.
Note
As of v4.5.0, both RTC SDK and Signaling SDK (v2.2.0 and above) include the aosl.dll library. If you manually integrate RTC SDK via CDN and also use Signaling SDK, delete the earlier version of the aosl.dll library to avoid conflicts. The aosl.dll library version in RTC SDK v4.5.0 is 1.2.13. You can check the version by viewing the aosl.dll file properties.
-
Member parameter type changes
To enhance the adaptability of various frameworks to the SDK, this version has made the following modifications to some API members or parameters:
API Members/Parameters Change startScreenCaptureByDisplayIddisplayId Changed from uint32_ttoint64_tstartScreenCaptureByWindowIdwindowId Changed from view_ttoint64_tScreenCaptureConfiguration- displayId
- windowId
- displayId: Changed from
uint32_ttoint64_t - windowId: Changed from
view_ttoint64_t
ScreenCaptureSourceInfo- sourceDisplayId
- sourceId
- sourceDisplayId: Changed from
view_ttoint64_t - sourceId:Default value changed from
nullptrto0
-
Changes in strong video noise suppression
This version adjusts the implementation of strong video noise suppression.
VIDEO_DENOISER_LEVEL_STRENGTHinVIDEO_DENOISER_LEVELis removed. Instead, after enabling video noise suppression by callingsetVideoDenoiserOptions, you can call thesetBeautyEffectOptionsmethod to enable the beauty skin smoothing feature. Using both together will help achieve better video noise suppression effects. For strong noise suppression, it is recommended to set the skin smoothing parameters as detailed insetVideoDenoiserOptions.Additionally, due to this adjustment, to achieve the best low-light enhancement effect with a focus on image quality, enable video noise suppression first and use specific settings as detailed in
setLowlightEnhanceOptions. -
Changes in camera plug and unplug status
In previous versions, when the camera was unplugged and replugged, the
onVideoDeviceStateChangedcallback would report the device status asMEDIA_DEVICE_STATE_ACTIVE(1) (device in use). Starting from this version, after the camera is replugged, the device status will change toMEDIA_DEVICE_STATE_IDLE(0) (device ready). -
Changes in video encoding preferences
To enhance the user’s video interaction experience, this version optimizes the default preferences for video encoding:
- In the
COMPRESSION_PREFERENCEenumeration class, a newPREFER_COMPRESSION_AUTO(-1) enumeration is added, replacing the originalPREFER_QUALITY(1) as the default value. In this mode, the SDK will automatically choose betweenPREFER_LOW_LATENCYorPREFER_QUALITYbased on your video scene settings to achieve the best user experience. - In the
DEGRADATION_PREFERENCEenumeration class, a newMAINTAIN_AUTO(-1) enumeration is added, replacing the originalMAINTAIN_QUALITY(1) as the default value. In this mode, the SDK will automatically choose betweenMAINTAIN_FRAMERATE,MAINTAIN_BALANCED, orMAINTAIN_RESOLUTIONbased on your video scene settings to achieve the optimal overall quality of experience (QoE).
- In the
New features
-
Live show scenario
This version adds the
APPLICATION_SCENARIO_LIVESHOW(3) (Live Show) enumeration to theVIDEO_APPLICATION_SCENARIO_TYPE. You can callsetVideoScenarioto set the video business scenario to showroom. In this scenario, fast video rendering and high image quality are crucial. The SDK implements several performance optimizations, such as enabling accelerated audio and video frame rendering to minimize first-frame latency for better image quality and bandwidth efficiency. -
Maximum frame rate for video rendering
This version adds the
setLocalRenderTargetFpsandsetRemoteRenderTargetFpsmethods, which support setting the maximum frame rate for video rendering locally and remotely. The actual frame rate for video rendering by the SDK will be as close to this value as possible.In use-cases where the frame rate requirement for video rendering is not high (for example, screen sharing, online education) or when the remote end uses mid-to-low-end devices, you can use this set of methods to limit the video rendering frame rate, thereby reducing CPU consumption and improving system performance.
-
Filter effects
This version introduces the
setFilterEffectOptionsmethod. You can pass a cube map file (.cube) in theconfigparameter to apply custom filter effects such as whitening, vivid, cool, black and white, and others. Additionally, the SDK provides a built-inbuilt_in_whiten_filter.cubefile to quickly apply a whitening filter effect. -
Local audio mixing
This version introduces the local audio mixing feature. You can call the
startLocalAudioMixermethod to mix the audio streams from the local microphone, media player, sound card, and remote audio streams into a single audio stream, which can then be published to the channel. When you no longer need audio mixing, you can call thestopLocalAudioMixermethod to stop local audio mixing. During the mixing process, you can call theupdateLocalAudioMixerConfigurationmethod to update the configuration of the audio streams being mixed.Example use cases for this feature include:
- By utilizing the local video mixing feature, the associated audio streams of the mixed video streams can be simultaneously captured and published.
- In live streaming use-cases, users can receive audio streams within the channel, mix multiple audio streams locally, and then forward the mixed audio stream to other channels.
- In educational use-cases, teachers can mix the audio from interactions with students locally and then forward the mixed audio stream to other channels.
-
Color space settings
This version adds the colorSpace parameter to
VideoFrameandExternalVideoFrame. You can use this parameter to set the color space properties of the video frame. By default, the color space uses Full Range and BT.709 standard configuration. You can flexibly adjust according to your own capture or rendering needs, further enhancing the customization capabilities of video processing. -
Others
onLocalVideoStateChangedcallback adds theLOCAL_VIDEO_STREAM_REASON_DEVICE_DISCONNECTEDenumeration, indicating that the currently used video capture device has been disconnected (for example, unplugged).MEDIA_DEVICE_STATE_TYPEadds theMEDIA_DEVICE_STATE_PLUGGED_INenumeration, indicating that the device has been plugged in.
Improvements
-
Virtual background algorithm optimization
This version upgrades the virtual background algorithm, making the segmentation between the portrait and the background more accurate. There is no background exposure, the body contour of the portrait is complete, and the detail recognition of fingers is significantly improved. Additionally, the edges between the portrait and the background are more stable, reducing edge jumping and flickering in continuous video frames.
-
Snapshot at specified video observation points
This version introduces the
takeSnapshot [2/2]andtakeSnapshotEx [2/2]methods. You can use theconfigparameter when calling these methods to take snapshots at specified video observation points, such as before encoding, after encoding, or before rendering, to achieve more flexible snapshot effects. -
Custom audio capture improvements
This version adds the
enableAudioProcessingmember parameter toAudioTrackConfig, which is used to control whether to enable 3A audio processing for custom audio capture tracks of theAUDIO_TRACK_DIRECTtype. The default value of this parameter isfalse, meaning that audio processing is not enabled. Users can enable it as needed, enhancing the flexibility of custom audio processing. -
Other improvements
- This version optimizes the logic for calling
queryDeviceScoreto obtain device score levels, improving the accuracy of the score results. - Supports using virtual cameras in YV12 format as video capture devices.
- When calling
switchSrcto switch between live streams or on-demand streams of different resolutions, smooth and seamless switching can be achieved. An automatic retry mechanism has been added in case of switching failures. The SDK will automatically retry 3 times after a failure. If it still fails, theonPlayerEventcallback will report thePLAYER_EVENT_SWITCH_ERRORevent, indicating that an error has occurred during media resource switching. - When calling
setPlaybackSpeedto set the playback speed of an audio file, the minimum supported speed is 0.3x.
- This version optimizes the logic for calling
Bug fixes
This version fixes the following issues:
- When calling
startScreenCaptureByWindowIdto share the screen, the window capture area specified byregionRectis inaccurate, resulting in incorrect width and height of the screen sharing window seen by the receiving end. - Occasional errors of not finding system files during audio and video interaction on Windows 7 systems.
- When calling
followSystemRecordingDeviceorfollowSystemPlaybackDeviceto set the audio capture or playback device used by the SDK to not follow the system default audio playback device, the local audio state callbackonLocalAudioStateChangedis not triggered when the audio device is removed. - Calling
startAudioMixing [1/2]and then immediately callingpauseAudioMixingto pause the music file playback does not take effect.
v4.4.0
v4.4.0 was released on August 5, 2024.
Compatibility changes
This version includes optimizations to some features, including changes to SDK behavior and API renaming and deletion. To ensure normal operation of the project, update the code in the app after upgrading to this release.
Note
Starting from v4.4.0, the SDK provides an API sunset notice, which includes information about deprecated and removed APIs in each version. See API Sunset Notice.
-
To distinguish context information in different extension callbacks, this version removes the original extension callbacks and adds corresponding callbacks that contain context information (see table below). You can identify the extension name, the user ID, and the service provider name through
ExtensionContextin each callback.Original callback New callback onExtensionEventonExtensionEventWithContextonExtensionStartedonExtensionStartedWithContextonExtensionStoppedonExtensionStoppedWithContextonExtensionErroronExtensionErrorWithContext -
This version renames the following members in
ExternalVideoFrame:d3d11_texture_2dis renamed tod3d11Texture2d.texture_slice_indexis renamed totextureSliceIndex.metadata_bufferis renamed tometadataBuffer.metadata_sizeis renamed tometadataSize.
New features
-
Alpha transparency effects
This version introduces the Alpha transparency effects feature, supporting the transmission and rendering of Alpha channel data in video frames for SDK capture and custom capture use-cases, enabling transparent gift effects, custom backgrounds on the receiver end, and so on:
VideoFrameandExternalVideoFrameadd thealphaBuffermember, which sets the Alpha channel data.ExternalVideoFrameadds thefillAlphaBuffermember. For BGRA or RGBA formatted video data, it sets whether to automatically extract the Alpha channel data and fill it intoalphaBuffer.VideoFrameandExternalVideoFrameadd thealphaStitchModemember, which sets the relative position ofalphaBufferand video frame stitching.
Additionally,
AdvanceOptionsadds a new memberencodeAlpha, which is used to set whether to encode and send Alpha information to the remote end. By default, the SDK does not encode and send Alpha information; if you need to encode and send Alpha information to the remote end (for example, when virtual background is enabled), explicitly callsetVideoEncoderConfigurationto set the video encoding properties and setencodeAlphatotrue. -
Voice AI tuner
This version introduces the voice AI tuner feature, which can enhance the sound quality and tone, similar to a physical sound card. You can enable the voice AI tuner feature by calling the
enableVoiceAITunermethod and passing in the sound effect types supported in theVOICE_AI_TUNER_TYPEenum to achieve effects like deep voice, cute voice, husky singing voice, and so on.
Improvements
-
Adaptive hardware decoding support
This release introduces adaptive hardware decoding support, enhancing rendering smoothness on low-end devices and effectively reducing system load.
-
Rendering performance enhancement
DirectX 11 renderer is now enabled by default on Windows devices, providing high-performance and high-quality graphics rendering capabilities.
-
Facial region beautification
To avoid losing details in non-facial areas during heavy skin smoothing, this version improves the skin smoothing algorithm. The SDK now recognizes various parts of the face, applying smoothing to facial skin areas excluding the mouth, eyes, and eyebrows. In addition, the SDK supports smoothing up to two faces simultaneously.
-
Other improvements
This version also includes the following improvements:
- Optimizes the transmission strategy: Calling
enableInstantMediaRenderingno longer impacts the security of the transmission link. - The
LOCAL_VIDEO_STREAM_REASON_SCREEN_CAPTURE_DISPLAY_DISCONNECTEDenumerator is added inonLocalVideoStateChangedcallback, indicating that the display used for screen capture has been disconnected. - Improves echo cancellation for screen sharing use-cases.
- Adds the
channelIdparameter toMetadata, which is used to get the channel name from which the metadata is sent. - Deprecates redundant enumeration values
CLIENT_ROLE_CHANGE_FAILED_REQUEST_TIME_OUTandCLIENT_ROLE_CHANGE_FAILED_CONNECTION_FAILEDinCLIENT_ROLE_CHANGE_FAILED_REASON.
- Optimizes the transmission strategy: Calling
v4.3.2
v4.3.2 was released on June 4, 2024.
Improvements
This release enhances the usability of the setRemoteSubscribeFallbackOption method by removing the timing requirements for invocation. It can now be called both before and after joining the channel to dynamically switch audio and video stream fallback options in weak network conditions.
Issues fixed
This version fixed the following issues:
- Occasional video smoothness issues during audio and video interactions.
- The app occasionally crashed when the decoded video resolution on the receiving end was an odd number.
- The app occasionally crashed when remote users left the channel.
- The screen occasionally flickered on the receiver's side when sharing a PPT window using startScreenCaptureByWindowId and playing PPT animations.
- The window border did not retain its original size after exiting the presentation and then maximizing the PPT window when sharing a WPS PPT window on Windows 7 using startScreenCaptureByWindowId and setting
enableHighLightin ScreenCaptureParameters totrue. - The specified window could not be brought to the foreground if it was covered by other windows when sharing a window using startScreenCaptureByWindowId and setting
windowFocusandenableHighLightin ScreenCaptureParameters totrue. - Clicking on the desktop widget caused the outlined part to flicker when sharing and highlighting a window on a Windows 7 device.
v4.3.1
v4.3.1 was released on April 29, 2024.
New features
-
Data stream encryption
This version adds
datastreamEncryptionEnabledto EncryptionConfig for enabling data stream encryption. You can set this when you activate encryption with enableEncryption. If there are issues causing failures in data stream encryption or decryption, these can be identified by the newly addedENCRYPTION_ERROR_DATASTREAM_DECRYPTION_FAILUREandENCRYPTION_ERROR_DATASTREAM_ENCRYPTION_FAILUREenumerations. -
Adaptive configuration for low-quality video streams
This version introduces adaptive configuration for low-quality video streams. When you activate dual-stream mode and set up low-quality video streams on the sending side using setDualStreamMode [2/2], the SDK defaults to the following behaviors:
- The default encoding resolution for low-quality video streams is set to 50% of the original video encoding resolution.
- The bitrate for the small streams is automatically matched based on the video resolution and frame rate, eliminating the need for manual specification.
-
Other features
- A new method enableEncryptionEx is added for enabling media stream or data stream encryption in multi-channel use-cases.
- A new method setAudioMixingPlaybackSpeed is introduced for setting the playback speed of audio files.
- A new method getCallIdEx is introduced for retrieving call IDs in multi-channel use-cases.
-
Beta features
- Speech driven avatar is released in beta. See beta documentation for details.
Improvements
-
Optimization for game use-case screen sharing
This version specifically optimizes screen sharing for game use-cases, enhancing performance, stability, and clarity in ultra-high definition (4K, 60 fps) game scenarios, resulting in a clearer, smoother, and more stable gaming experience for players.
-
Virtual background algorithm optimization
To enhance the accuracy and stability of human segmentation when activating virtual backgrounds against solid colors, this version optimizes the green screen segmentation algorithm:
- Supports recognition of any solid color background, no longer limited to green screens.
- Improves accuracy in recognizing background colors and reduces the background exposure during human segmentation.
- After segmentation, the edges of the human figure (especially around the fingers) are more stable, significantly reducing flickering at the edges.
-
CPU consumption reduction of in-ear monitoring
This release adds an enumerator
EAR_MONITORING_FILTER_REUSE_POST_PROCESSING_FILTERinEAR_MONITORING_FILTER_TYPE. For complex audio processing use-cases, you can specify this option to reuse the audio filter after sender-side processing in in-ear monitoring, thereby reducing CPU consumption. Note that this option may increase the latency of in-ear monitoring, which is suitable for latency-tolerant use-cases requiring low CPU consumption. -
Other improvements
This version also includes the following improvements:
- Optimization of video encoding and decoding strategies in non-screen sharing use-cases to save system performance overhead.
- Enhanced media player capabilities to handle WebM format videos, including support for rendering Alpha channels.
- In AUDIO_EFFECT_PRESET, a new enumeration
ROOM_ACOUSTICS_CHORUS(chorus effect) is added, enhancing the spatial presence of vocals in chorus use-cases. - In RemoteAudioStats, a new
e2eDelayfield is added to report the delay from when the audio is captured on the sending end to when the audio is played on the receiving end.
Issues fixed
This version fixed the following issues:
- Fixed an issue where SEI data output did not synchronize with video rendering when playing media streams containing SEI data using the media player.
- In screen sharing use-cases, when the app enabled sound card capture with enableLoopbackRecording to capture audio from the shared screen, the transmission of sound card captured audio failed after a local user manually disabled the local audio capture device, causing remote users to not hear the shared screen's audio.
- When a user plugged and unplugged a Bluetooth or wired headset once, the audio state change callback onAudioDeviceStateChanged was triggered multiple times.
- During interactions, when a local user set the system default playback device to speakers using setDevice, there was no sound from the remote end.
- When sharing an Excel document window, remote users occasionally saw a green screen.
- On devices using Intel graphics cards, occasionally there was a performance regression when publishing a small video stream.
- When the network conditions of the sender deteriorated (for example, in poor network environments), the receiver occasionally experienced a decrease in video smoothness and an increase in lag.
API changes
Added
- registerFaceInfoObserver
- IFaceInfoObserver
- onFaceInfo
- The
publishLipSyncTrackmember in ChannelMediaOptions - MEDIA_SOURCE_TYPE adds
SPEECH_DRIVEN_VIDEO_SOURCE - VIDEO_SOURCE_TYPE adds
VIDEO_SOURCE_SPEECH_DRIVEN - EncryptionConfig adds
datastreamEncryptionEnabled - ENCRYPTION_ERROR_TYPE adds the following enumerations:
ENCRYPTION_ERROR_DATASTREAM_DECRYPTION_FAILUREENCRYPTION_ERROR_DATASTREAM_ENCRYPTION_FAILURE
- RemoteAudioStats adds
e2eDelay - ERROR_CODE_TYPE adds
ERR_DATASTREAM_DECRYPTION_FAILED - AUDIO_EFFECT_PRESET adds
ROOM_ACOUSTICS_CHORUS, enhancing the spatial presence of vocals in chorus use-cases. - getCallIdEx
- enableEncryptionEx
- setAudioMixingPlaybackSpeed
- EAR_MONITORING_FILTER_TYPE adds a new enumeration
EAR_MONITORING_FILTER_BUILT_IN_AUDIO_FILTERS
v4.3.0
v4.3.0 was released on February 22, 2024.
Compatibility changes
This release has optimized the implementation of some functions, involving renaming or deletion of some APIs. To ensure the normal operation of the project, you need to update the code in the app after upgrading to this release.
-
Renaming parameters in callbacks
In order to make the parameters in some callbacks and the naming of enumerations in enumeration classes easier to understand, the following modifications have been made in this release. Please modify the parameter settings in the callbacks after upgrading to this release.
Callback Original parameter name New parameter name onLocalAudioStateChangederrorreasononLocalVideoStateChangederrorreasononDirectCdnStreamingStateChangederrorreasononPlayerSourceStateChangedecreasononRtmpStreamingStateChangederrCodereasonOriginal enumeration class New enumeration class LOCAL_AUDIO_STREAM_ERRORLOCAL_AUDIO_STREAM_REASONLOCAL_VIDEO_STREAM_ERRORLOCAL_VIDEO_STREAM_REASONDIRECT_CDN_STREAMING_ERRORDIRECT_CDN_STREAMING_REASONMEDIA_PLAYER_ERRORMEDIA_PLAYER_REASONRTMP_STREAM_PUBLISH_ERRORRTMP_STREAM_PUBLISH_REASONNote: For specific renaming of enumerations, please refer to API changes.
-
Channel media relay
To improve interface usability, this release removes some methods and callbacks for channel media relay. Use the alternative options listed in the table below:
Deleted methods and callbacks Alternative methods and callbacks startChannelMediaRelayupdateChannelMediaRelay
startOrUpdateChannelMediaRelaystartChannelMediaRelayExupdateChannelMediaRelayEx
startOrUpdateChannelMediaRelayExonChannelMediaRelayEventonChannelMediaRelayStateChanged -
Reasons for local video state changes
This release makes the following modifications to the enumerations in the LOCAL_VIDEO_STREAM_ERROR class:
- The value of
LOCAL_VIDEO_STREAM_REASON_SCREEN_CAPTURE_PAUSED(formerlyLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_PAUSED) has been changed from 23 to 28. - The value of
LOCAL_VIDEO_STREAM_REASON_SCREEN_CAPTURE_RESUMED(formerlyLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_RESUMED) has been changed from 24 to 29. - The
LOCAL_VIDEO_STREAM_ERROR_CODEC_NOT_SUPPORTenumeration has been changed toLOCAL_VIDEO_STREAM_REASON_CODEC_NOT_SUPPORT.
- The value of
-
Audio loopback capturing
-
Before v4.3.0, if you call the disableAudio method to disable the audio module, audio loopback capturing will not be disabled.
-
As of v4.3.0, if you call the disableAudio method to disable the audio module, audio loopback capturing will be disabled as well. If you need to enable audio loopback capturing, you need to enable the audio module by calling the enableAudio method and then call enableLoopbackRecording.
-
-
Log encryption behavior changes
For security and performance reasons, as of this release, the SDK encrypts logs and no longer supports printing plaintext logs via the console.
Refer to the following solutions for different needs:
- If you need to know the API call status, please check the API logs and print the SDK callback logs yourself.
- For any other special requirements, please contact technical support and provide the corresponding encrypted logs.
New features
-
Local preview with multiple views
This release supports local preview with simultaneous display of multiple frames, where the videos shown in the frames are positioned at different observation positions along the video link. Examples of usage are as follows:
- Call setupLocalVideo to set the first view: Set the
positionparameter toPOSITION_POST_CAPTURER_ORIGIN(introduced in this release) inVideoCanvas. This corresponds to the position after local video capture and before preprocessing. The video observed here does not have preprocessing effects. - Call setupLocalVideo to set the second view: Set the
positionparameter toPOSITION_POST_CAPTURERinVideoCanvas, the video observed here has the effect of video preprocessing. - Observe the local preview effect: The first view is the original video of a real person; the second view is the virtual portrait after video preprocessing (including image enhancement, virtual background, and local preview of watermarks) effects.
- Call setupLocalVideo to set the first view: Set the
-
Query Device Score
This release adds the queryDeviceScore method to query the device's score level to ensure that the user-set parameters do not exceed the device's capabilities. For example, in HD or UHD video use-cases, you can first call this method to query the device's score. If the returned score is low (for example, below 60), you need to lower the video resolution to avoid affecting the video experience. The minimum device score required for different business use-cases is varied. For specific score recommendations, please contact technical support.
-
Select different audio tracks for local playback and streaming
This release introduces the selectMultiAudioTrack method that allows you to select different audio tracks for local playback and streaming to remote users. For example, in use-cases like online karaoke, the host can choose to play the original sound locally and publish the accompaniment in the channel. Before using this function, you need to open the media file through the openWithMediaSource method and enable this function by setting the
enableMultiAudioTrackparameter in MediaSource. -
Others
This release has passed the test verification of the following APIs and can be applied to the entire series of RTC 4.x SDK.
- setRemoteSubscribeFallbackOption: Sets fallback option for the subscribed video stream in weak network conditions.
- onRemoteSubscribeFallbackToAudioOnly: Occurs when the subscribed video stream falls back to audio-only stream due to weak network conditions or switches back to the video stream after the network conditions improve.
- setPlaybackDeviceVolume: Sets the volume of the audio playback device.
- getRecordingDeviceVolume: Sets the volume of the audio capturing device.
- setPlayerOption: Sets media player options for providing technical previews or special customization features.
- enableCustomAudioLocalPlayback: Sets whether to enable the local playback of external audio source.
Improvements
-
SDK task processing scheduling optimization
This release optimizes the scheduling mechanism for internal tasks within the SDK, with improvements in the following aspects:
- The speed of video rendering and audio playback for both remote and local first frames improves by 10% to 20%.
- The API call duration and response time are reduced by 5% to 50%.
- The SDK's parallel processing capability significantly improves, delivering higher video quality (720P, 24 fps) even on lower-end devices. Additionally, image processing remains more stable in use-cases involving high resolutions and frame rates.
- The stability of the SDK is further enhanced, leading to a noticeable decrease in the crash rate across various specific use-cases.
-
In-ear monitoring volume boost
This release provides users with more flexible in-ear monitoring audio adjustment options, supporting the ability to set the in-ear monitoring volume to four times the original volume by calling setInEarMonitoringVolume.
-
Spatial audio effects usability improvement
- This release optimizes the design of the setZones method, supporting the ability to set the
zonesparameter toNULL, indicating the clearing of all echo cancellation zones. - As of this release, it is no longer necessary to unsubscribe from the audio streams of all remote users within the channel before calling the methods in ILocalSpatialAudioEngine class.
- This release optimizes the design of the setZones method, supporting the ability to set the
-
Other Improvements
This release also includes the following improvements:
- The onLocalVideoStateChanged callback is improved with the inclusion of the
LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_AUTO_FALLBACKenumeration, signaling unexpected errors during the screen sharing process (potentially due to window blocking failure), resulting in performance degradation without impacting the screen sharing process itself. - This release optimizes the SDK's domain name resolution strategy, improving the stability of calling to resolve domain names in complex network environments.
- When passing in an image with transparent background as the virtual background image, the transparent background can be filled with customized color.
- This release adds the
earMonitorDelayandaecEstimatedDelaymembers in LocalAudioStats to report ear monitor delay and acoustic echo cancellation (AEC) delay, respectively. - The onPlayerCacheStats callback is added to report the statistics of the media file being cached. This callback is triggered once per second after file caching is started.
- The onPlayerPlaybackStats callback is added to report the statistics of the media file being played. This callback is triggered once per second after the media file starts playing. You can obtain information like the audio and video bitrate of the media file through PlayerPlaybackStats.
- The onLocalVideoStateChanged callback is improved with the inclusion of the
Issues fixed
This release fixes the following issues:
- When sharing two screen sharing video streams simultaneously, the reported
captureFrameRatein the onLocalVideoStats callback is 0, which is not as expected. - When sharing in a specified screen area, the mouse coordinates within the shared area are inaccurate. When the mouse is near the border of the shared area, the mouse may not be visible in the shared screen.
- The SDK failed to detect any changes in the audio routing after plugging in and out 3.5mm earphones.
API changes
Added
- The
subviewUidmember in VideoCanvas - enableCustomAudioLocalPlayback
- queryDeviceScore
- The
CUSTOM_VIDEO_SOURCEenumeration in MEDIA_SOURCE_TYPE - The
ROUTE_BLUETOOTH_DEVICE_A2DPenumeration in AudioRoute - selectMultiAudioTrack
- onPlayerCacheStats
- onPlayerPlaybackStats
- PlayerPlaybackStats
Modified
- All
ERRORfields in the following enumerations are changed toREASON:LOCAL_AUDIO_STREAM_ERROR_OKLOCAL_AUDIO_STREAM_ERROR_FAILURELOCAL_AUDIO_STREAM_ERROR_DEVICE_NO_PERMISSIONLOCAL_AUDIO_STREAM_ERROR_DEVICE_BUSYLOCAL_AUDIO_STREAM_ERROR_RECORD_FAILURELOCAL_AUDIO_STREAM_ERROR_ENCODE_FAILURELOCAL_AUDIO_STREAM_ERROR_RECORD_INVALID_IDLOCAL_AUDIO_STREAM_ERROR_PLAYOUT_INVALID_IDLOCAL_VIDEO_STREAM_ERROR_OKLOCAL_VIDEO_STREAM_ERROR_FAILURELOCAL_VIDEO_STREAM_ERROR_DEVICE_NO_PERMISSIONLOCAL_VIDEO_STREAM_ERROR_DEVICE_BUSYLOCAL_VIDEO_STREAM_ERROR_CAPTURE_FAILURELOCAL_VIDEO_STREAM_ERROR_CODEC_NOT_SUPPORTLOCAL_VIDEO_STREAM_ERROR_DEVICE_NOT_FOUNDLOCAL_VIDEO_STREAM_ERROR_DEVICE_DISCONNECTEDLOCAL_VIDEO_STREAM_ERROR_DEVICE_INVALID_IDLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_MINIMIZEDLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_CLOSEDLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_OCCLUDEDLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_NO_PERMISSIONLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_PAUSEDLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_RESUMEDLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_HIDDENLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_RECOVER_FROM_HIDDENLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_RECOVER_FROM_MINIMIZEDLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_FAILURELOCAL_VIDEO_STREAM_ERROR_DEVICE_SYSTEM_PRESSUREDIRECT_CDN_STREAMING_ERROR_OKDIRECT_CDN_STREAMING_ERROR_FAILEDDIRECT_CDN_STREAMING_ERROR_AUDIO_PUBLICATIONDIRECT_CDN_STREAMING_ERROR_VIDEO_PUBLICATIONDIRECT_CDN_STREAMING_ERROR_NET_CONNECTDIRECT_CDN_STREAMING_ERROR_BAD_NAMEPLAYER_ERROR_NONEPLAYER_ERROR_INVALID_ARGUMENTSPLAYER_ERROR_INTERNALPLAYER_ERROR_NO_RESOURCEPLAYER_ERROR_INVALID_MEDIA_SOURCEPLAYER_ERROR_UNKNOWN_STREAM_TYPEPLAYER_ERROR_OBJ_NOT_INITIALIZEDPLAYER_ERROR_CODEC_NOT_SUPPORTEDPLAYER_ERROR_VIDEO_RENDER_FAILEDPLAYER_ERROR_INVALID_STATEPLAYER_ERROR_URL_NOT_FOUNDPLAYER_ERROR_INVALID_CONNECTION_STATEPLAYER_ERROR_SRC_BUFFER_UNDERFLOWPLAYER_ERROR_INTERRUPTEDPLAYER_ERROR_NOT_SUPPORTEDPLAYER_ERROR_TOKEN_EXPIREDPLAYER_ERROR_UNKNOWNRTMP_STREAM_PUBLISH_ERROR_OKRTMP_STREAM_PUBLISH_ERROR_INVALID_ARGUMENTRTMP_STREAM_PUBLISH_ERROR_ENCRYPTED_STREAM_NOT_ALLOWEDRTMP_STREAM_PUBLISH_ERROR_CONNECTION_TIMEOUTRTMP_STREAM_PUBLISH_ERROR_INTERNAL_SERVER_ERRORRTMP_STREAM_PUBLISH_ERROR_RTMP_SERVER_ERRORRTMP_STREAM_PUBLISH_ERROR_TOO_OFTENRTMP_STREAM_PUBLISH_ERROR_REACH_LIMITRTMP_STREAM_PUBLISH_ERROR_NOT_AUTHORIZEDRTMP_STREAM_PUBLISH_ERROR_STREAM_NOT_FOUNDRTMP_STREAM_PUBLISH_ERROR_FORMAT_NOT_SUPPORTEDRTMP_STREAM_PUBLISH_ERROR_NOT_BROADCASTERRTMP_STREAM_PUBLISH_ERROR_TRANSCODING_NO_MIX_STREAMRTMP_STREAM_PUBLISH_ERROR_NET_DOWNRTMP_STREAM_PUBLISH_ERROR_INVALID_PRIVILEGERTMP_STREAM_UNPUBLISH_ERROR_OK
Deleted
startChannelMediaRelayupdateChannelMediaRelaystartChannelMediaRelayExupdateChannelMediaRelayExonChannelMediaRelayEventCHANNEL_MEDIA_RELAY_EVENT
v4.2.6
v4.2.6 was released on November 17, 2023.
Issues fixed
This release fixes the following issue:
- In specific use-cases, such as when the network packet loss rate was high or when the broadcaster left the channel without destroying the engine and then re-joined the channel, the video on the receiving end stuttered or froze.
v4.2.3
v4.2.3 was released on October 11, 2023.
New features
-
Update video screenshot and upload
To facilitate the integration of third-party video moderation services from Agora Extensions Marketplace, this version has the following changes:
- The
CONTENT_INSPECT_IMAGE_MODERATIONenumeration is added inCONTENT_INSPECT_TYPEwhich means using video moderation extensions from Agora Extensions Marketplace to take video screenshots and upload them. - An optional parameter
serverConfigis added inContentInspectConfig, which is for server-side configuration related to video screenshot and upload via extensions from Agora Extensions Marketplace. By configuring this parameter, you can integrate multiple third-party moderation extensions and achieve flexible control over extension switches and other features. For more details, please contact technical support.
In addition, this version also introduces the
enableContentInspectExmethod, which supports taking screenshots for multiple video streams and uploading them. - The
-
ID3D11Texture2D Rendering
As of this release, the SDK supports video formats of type ID3D11Texture2D, improving the rendering effect of video frames in game use-cases. You can set
formattoVIDEO_TEXTURE_ID3D11TEXTURE2Dwhen pushing external raw video frames to the SDK by callingpushVideoFrame. By setting thed3d11_texture_2dandtexture_slice_indexproperties, you can determine the ID3D11Texture2D texture object to use. -
Local video status error code update
In order to help users understand the exact reasons for local video errors in screen sharing use-cases, the following sets of enumerations have been added to the
onLocalVideoStateChangedcallback:LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_PAUSED(23): Screen capture has been paused. Common use-cases for reporting this error code: The current screen may have been switched to a secure desktop, such as a UAC dialog box or Winlogon desktop.LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_RESUMED(24): Screen capture has resumed from the paused state.LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_HIDDEN(25): The window being captured on the current screen is in a hidden state and is not visible on the current screen.LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_RECOVER_FROM_HIDDEN(26): The window for screen capture has been restored from the hidden state.LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_RECOVER_FROM_MINIMIZED(27): The window for screen capture has been restored from the minimized state.
-
Check device support for advanced features
This version adds the
isFeatureAvailableOnDevicemethod to check whether the capability of the current device meets the requirements of the specified advanced feature, such as virtual background and image enhancement.Before using advanced features, you can check whether the current device supports these features based on the call result. This helps to avoid performance degradation or unavailable features when enabling advanced features on low-end devices. Based on the return value of this method, you can decide whether to display or enable the corresponding feature button, or notify the user when the device's capabilities are insufficient.
In addition, since this version, calling
enableVirtualBackgroundandsetBeautyEffectOptionsautomatically triggers a test on the capability of the current device. When the device is considered underperformed, the error code-4:ERR_NOT_SUPPORTEDis returned, indicating the device does not support the feature.
Improvements
-
Optimize virtual background memory usage
This version has upgraded the virtual background algorithm, reducing the memory usage of the virtual background feature. Compared to the previous version, the memory consumption of the app during the use of the virtual background feature on low-end devices has been reduced by approximately 4% to 10% (specific values may vary depending on the device model and platform).
-
Screen sharing use-case optimization
This release optimizes the performance and encoding efficiency in ultra-high-definition (4K, 60 fps) game sharing use-cases, effectively reducing the system resource usage during screen sharing.
Other Improvements
This release includes the following additional improvements:
- Optimizes the logic of handling invalid parameters. When you call the
setPlaybackSpeedmethod to set the playback speed of audio files, if you pass an invalid parameter, the SDK returns the error code -2, which means that you need to reset the parameter. - Optimizes the logic of Token parsing, in order to prevent an app from crash when an invalid token is passed in.
Issues fixed
This release fixes the following issues:
- Occasional crashes and dropped frames occurred in screen sharing use-cases.
- Occasional failure of joining a channel when the local system time was not set correctly.
- When calling the
playEffectmethod to play two audio files using the samesoundId, the first audio file was sometimes played repeatedly. - Calling
takeSnapshotExonce receives theonSnapshotTakencallback for multiple times.
API changes
Added
- The following enumerations in
onLocalVideoStateChanged:LOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_PAUSEDLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_RESUMEDLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_HIDDENLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_RECOVER_FROM_HIDDENLOCAL_VIDEO_STREAM_ERROR_SCREEN_CAPTURE_WINDOW_RECOVER_FROM_MINIMIZED
d3d11_texture_2dandtexture_slice_indexmembers inExternalVideoFrame.VIDEO_TEXTURE_ID3D11TEXTURE2DinVIDEO_PIXEL_FORMAT.enableContentInspectExCONTENT_INSPECT_IMAGE_MODERATIONinCONTENT_INSPECT_TYPE.serverConfiginContentInspectConfigisFeatureAvailableOnDeviceFeatureType
v4.2.2
v4.2.2 was released on july 27, 2023.
New features
-
Wildcard token
This release introduces wildcard tokens. Agora supports setting the channel name used for generating a token as a wildcard character. The token generated can be used to join any channel if you use the same user id. In use-cases involving multiple channels, such as switching between different channels, using a wildcard token can avoid repeated application of tokens every time users joining a new channel, which reduces the pressure on your token server. See Secure authentication with tokens.
All 4.x SDKs support using wildcard tokens. :::
-
Preloading channels
This release adds
preloadChannel[1/2]andpreloadChannel[2/2]methods, which allows a user whose role is set as audience to preload channels before joining one. Calling the method can help shortening the time of joining a channel, thus reducing the time it takes for audience members to hear and see the host.When preloading more than one channels, Agora recommends that you use a wildcard token for preloading to avoid repeated application of tokens every time you joining a new channel, thus saving the time for switching between channels. See Secure authentication with tokens.
-
Customized background color of video canvas
In this release, the
backgroundColormember has been added toVideoCanvas, which allows you to customize the background color of the video canvas when setting the properties of local or remote video display. -
Publishing video streams from different sources
This release adds the following members in
ChannelMediaOptionsto allow you publish video streams captured from the third and fourth camera or screen:publishThirdCameraTrack: Publishing the video stream captured from the third camera.publishFourthCameraTrack: Publishing the video stream captured from the fourth camera.publishThirdScreenTrack: Publishing the video stream captured from the third screen.publishFourthScreenTrack: Publishing the video stream captured from the fourth screen.
For one RtcConnection, Agora supports publishing multiple audio streams and one video stream at the same time.
:::
Improvements
-
Virtual Background Algorithm Upgrade
This version has upgraded the portrait segmentation algorithm of the virtual background, which comprehensively improves the accuracy of portrait segmentation, the smoothness of the portrait edge with the virtual background, and the fit of the edge when the person moves. In addition, it optimizes the precision of the person's edge in use-cases such as meetings, offices, homes, and under backlight or weak light conditions.
-
Channel media relay
The number of target channels for media relay has been increased to 6. When calling
startOrUpdateChannelMediaRelayandstartOrUpdateChannelMediaRelayEx, you can specify up to 6 target channels. -
Enhancement in video codec query capability
To improve the video codec query capability, this release adds the
codecLevelsmember inCodecCapInfo. After successfully callingqueryCodecCapability, you can obtain the hardware and software decoding capability levels of the device for H.264 and H.265 video formats throughcodecLevels.
This release includes the following additional improvements:
- The SDK automatically adjusts the frame rate of the sending end based on the screen sharing use-case. Especially in document sharing use-cases, this feature avoids exceeding the expected video bitrate on the sending end to improve transmission efficiency and reduce network burden.
- To help users understand the reasons for more types of remote video state changes, the
REMOTE_VIDEO_STATE_REASON_CODEC_NOT_SUPPORTenumeration has been added to theonRemoteVideoStateChangedcallback, indicating that the local video decoder does not support decoding the received remote video stream.
Issues fixed
This release fixes the following issues:
- Slow channel reconnection after the connection was interrupted due to network reasons.
- In screen sharing use-cases, the delay of seeing the shared screen was occasionally higher than expected on some devices.
- In custom video capturing use-cases,
setBeautyEffectOptions,setLowlightEnhanceOptions,setVideoDenoiserOptions, andsetColorEnhanceOptionscould not load extensions automatically. - In multi-device audio recording use-cases, after repeatedly plugging and unplugging or enabling/disabling the audio recording device, no sound could be heard occasionally when calling the
startRecordingDeviceTestto start an audio capturing device test.
API changes
Added
preloadChannel[1/2]preloadChannel[2/2]updatePreloadChannelToken- The following members in
ChannelMediaOptions:publishThirdCameraTrackpublishFourthCameraTrackpublishThirdScreenTrackpublishFourthScreenTrack
CodecCapLevelsVIDEO_CODEC_CAPABILITY_LEVELbackgroundColorinVideoCanvascodecLevelsinCodecCapInfoREMOTE_VIDEO_STATE_REASON_CODEC_NOT_SUPPORTinREMOTE_VIDEO_STATE_REASON
v4.2.1
This version was released on June 21, 2023.
Improvements
This version improves the network transmission strategy, enhancing the smoothness of audio and video interactions.
Issues fixed
This version fixed the following issues:
- Inability to join channels caused by SDK's incompatibility with some older versions of AccessToken.
- After the sending end called
setAINSModeto activate AI noise reduction, occasional echo was observed by the receiving end. - Brief noise occurred while playing media files using the media player.
- When the sending end mixed and published two streams of video captured by two cameras locally, the video from the second camera was occasionally missing on the receiving end.
v4.2.0
v4.2.0 was released on May 24, 2023.
Compatibility changes
If you use the features mentioned in this section, ensure that you modify the implementation of the relevant features after upgrading the SDK.
1. Video capture
This release optimizes the APIs for camera and screen capture function. As of v4.2.0, ensure you use the alternative methods listed in the table below and specify the video source by setting the sourceType parameter.
| Deleted Methods | Alternative Methods |
|---|---|
startPrimaryCameraCapturestartSecondaryCameraCapture | startCameraCapture |
stopPrimaryCameraCapturestopSecondaryCameraCapture | stopCameraCapture |
startPrimaryScreenCapturestartSecondaryScreenCapture | startScreenCapture[2/2] |
stopPrimaryScreenCapturestopSecondaryScreenCapture | stopScreenCapture[2/2] |
2. Video data acquisition
- The
onCaptureVideoFrameandonPreEncodeVideoFramecallbacks are added with a new parameter calledsourceType, which is used to indicate the specific video source type. - The following callbacks are deleted. Get the video source type through the
sourceTypeparameter in theonPreEncodeVideoFrameandonCaptureVideoFramecallbacks.onSecondaryPreEncodeCameraVideoFrameonScreenCaptureVideoFrameonPreEncodeScreenVideoFrameonSecondaryPreEncodeScreenVideoFrame
3. Channel media options
publishCustomAudioTrackEnableAecinChannelMediaOptionsis deleted. UsepublishCustomAudioTrackinstead.publishTrancodedVideoTrackinChannelMediaOptionsis renamed topublishTranscodedVideoTrack.publishCustomAudioSourceIdinChannelMediaOptionsis renamed topublishCustomAudioTrackId.
4. Local video mixing
- The
VideoInputStreamsinLocalTranscoderConfigurationis changed tovideoInputStreams. - The
MEDIA_SOURCE_TYPEinTranscodingVideoStreamis changed toVIDEO_SOURCE_TYPE.
5. Miscellaneous
onApiCallExecutedis deleted. Agora recommends getting the results of the API implementation through relevant channels and media callbacks.- The
IAudioFrameObserverclass is renamed toIAudioPcmFrameSink, thus the prototypes of the following methods are updated accordingly:onFrameregisterAudioFrameObserver[1/2] andregisterAudioFrameObserver[2/2] inIMediaPlayer
enableDualStreamMode[1/2] andenableDualStreamMode[2/2] are deprecated. UsesetDualStreamMode[1/2] andsetDualStreamMode[2/2] instead.startChannelMediaRelay,updateChannelMediaRelay,startChannelMediaRelayEx, andupdateChannelMediaRelayExare deprecated. UsestartOrUpdateChannelMediaRelayandstartOrUpdateChannelMediaRelayExinstead.
New features
1. AI Noise Suppression
This release introduces public APIs for the AI Noise Suppression function. Once enabled, the SDK automatically detects and reduces background noises. Whether in bustling public venues or real-time competitive arenas that demand lightning-fast responsiveness, this function guarantees optimal audio clarity, providing users with an elevated audio experience. You can enable this function through the newly-introduced setAINSMode method and set the noise reduction mode as balance, aggressive, or low latency according to your use-case.
Agora charges separately for this function. See AI Noise Suppression unit pricing.
2. Enhanced Virtual Background
To increase the fun of real-time video calls and protect user privacy, this version has enhanced the Virtual Background feature. You can now set custom backgrounds of various types by calling the enableVirtualBackground method, including:
- Process the background as Alpha information without replacement, only separating the portrait and the background. This can be combined with the local video mixing feature to achieve a portrait-in-picture effect.
- Replace the background with various formats of local videos.
See Virtual Background documentation.
3. Video scenario settings
This release introduces setVideoScenario for setting the video application scene. The SDK will automatically enable the best practice strategy based on different scenes, adjusting key performance indicators to optimize video quality and improve user experience. Whether it is a formal business meeting or a casual online gathering, this feature ensures that the video quality meets the requirements.
Currently, this feature provides targeted optimizations for real-time video conferencing scenarios, including:
- Automatically activate multiple anti-weak-network technologies to enhance the capability and performance of low-quality video streams in meeting scenarios where high bitrates are required, ensuring smoothness when multiple streams are subscribed by the receiving end.
- Monitor the number of subscribers for the high-quality and low-quality video streams in real time, dynamically adjusting the configuration of the high-quality stream and dynamically enabling or disabling the low-quality stream, to save uplink bandwidth and consumption.
4. Local video mixing
This release adds the onLocalVideoTranscoderError callback. When there is an error in starting or updating the local video mixing, the SDK triggers this callback to report the reason for the failure.
5. Cross-device synchronization
In real-time collaborative singing use-cases, network issues can cause inconsistencies in the downlinks of different client devices. To address this, this release introduces getNtpWallTimeInMs for obtaining the current Network Time Protocol (NTP) time. By using this method to synchronize lyrics and music across multiple client devices, users can achieve synchronized singing and lyrics progression, resulting in a better collaborative experience.
Improvements
1. Voice changer
This release introduces the setLocalVoiceFormant method that allows you to adjust the formant ratio to change the timbre of the voice. This method can be used together with the setLocalVoicePitch method to adjust the pitch and timbre of voice at the same time, enabling a wider range of voice transformation effects.
2. Enhanced rendering compatibility
This release enhances the rendering compatibility of the SDK. Issues like black screens caused by rendering failures on certain devices are fixed.
3. Audio and video synchronization
For custom video and audio capture use-cases, this release introduces getCurrentMonotonicTimeInMs for obtaining the current Monotonic Time. By passing this value into the timestamps of audio and video frames, developers can accurately control the timing of their audio and video streams, ensuring proper synchronization.
4. Multi-camera capture and multi-screen capture
This release introduces startCameraCapture and startScreenCapture[2/2]. By calling these methods multiple times and specifying the sourceType parameter, developers can start capturing video streams from multiple cameras and screens for local video mixing or multi-channel publishing. This particularly useful for use-cases such as remote medical care and online education, where multiple cameras and displays need to be connected.
5. Channel media relay
This release introduces startOrUpdateChannelMediaRelay and startOrUpdateChannelMediaRelayEx, allowing for a simpler and smoother way to start and update media relay across channels. With these methods, developers can easily start the media relay across channels and update the target channels for media relay with a single method. Additionally, the internal interaction frequency has been optimized, effectively reducing latency in function calls.
6. Custom audio tracks
To better meet the needs of custom audio capture use-cases, this release adds createCustomAudioTrack and destroyCustomAudioTrack for creating and destroying custom audio tracks. Two types of audio tracks are also provided for users to choose from, further improving the flexibility of capturing external audio source:
- Mixable audio track: Supports mixing multiple external audio sources and publishing them to the same channel, suitable for multi-channel audio capture use-cases.
- Direct audio track: Only supports publishing one external audio source to a single channel, suitable for low-latency audio capture use-cases.
Issues fixed
This release fixes the issue that when the host frequently switched the user role between broadcaster and audience in a short period of time, the audience members could not hear the audio of the host.
API changes
Added
startCameraCapturestopCameraCapturestartScreenCapture[2/2]stopScreenCapture[2/2]startOrUpdateChannelMediaRelaystartOrUpdateChannelMediaRelayExgetNtpWallTimeInMssetVideoScenariogetCurrentMonotonicTimeInMsonLocalVideoTranscoderErrorsetAINSModecreateAudioCustomTrackdestroyAudioCustomTrackAudioTrackConfigAUDIO_TRACK_TYPEVIDEO_APPLICATION_SCENARIO_TYPESCREEN_CAPTURE_FRAMERATE_CAPABILITY- The
domainLimitandautoRegisterAgoraExtensionsmembers inRtcEngineContext - The
sourceTypeparameter inonCaptureVideoFrameandonPreEncodeVideoFramecallbacks - The
BACKGROUND_NONEandBACKGROUND_VIDEOenumerators inBACKGROUND_SOURCE_TYPE
Deprecated
enableDualStreamMode[1/2]enableDualStreamMode[2/2]startChannelMediaRelaystartChannelMediaRelayExupdateChannelMediaRelayupdateChannelMediaRelayExonChannelMediaRelayEventCHANNEL_MEDIA_RELAY_EVENT
Deleted
startPrimaryScreenCapturestartSecondaryScreenCapturestopPrimaryScreenCapturestopSecondaryScreenCapturestartPrimaryCameraCapturestartSecondaryCameraCapturestopPrimaryCameraCapturestopSecondaryCameraCaptureonSecondaryPreEncodeCameraVideoFrameonScreenCaptureVideoFrameonPreEncodeScreenVideoFrameonSecondaryPreEncodeScreenVideoFrameonApiCallExecutedpublishCustomAudioTrackEnableAecinChannelMediaOptions
v4.1.1
v4.1.1 was released on February 8, 2023.
Compatibility changes
As of this release, the SDK optimizes the video encoder algorithm and upgrades the default video encoding resolution from 640 × 360 to 960 × 540 to accommodate improvements in device performance and network bandwidth, providing users with a full-link HD experience in various audio and video interaction use-cases.
Call the setVideoEncoderConfiguration method to set the expected video encoding resolution in the video encoding parameters configuration.
The increase in the default resolution affects the aggregate resolution and thus the billing rate. See Pricing.
New features
1. Instant frame rendering
This release adds the enableInstantMediaRendering method to enable instant rendering mode for audio and video frames, which can speed up the first video or audio frame rendering after the user joins the channel.
2. Video rendering tracing
This release adds the startMediaRenderingTracing and startMediaRenderingTracingEx methods. The SDK starts tracing the rendering status of the video frames in the channel from the moment this method is called and reports information about the event through the onVideoRenderingTracingResult callback.
Agora recommends that you use this method in conjunction with the UI settings, such as buttons and sliders, in your app. For example, call this method when the user clicks
Join Channel button and then get the indicators in the video frame rendering process through the onVideoRenderingTracingResult callback.
This enables developers to optimize the indicators and improve the user experience.
Improvements
Video frame observer
As of this release, the SDK optimizes the onRenderVideoFrame callback, and the meaning of the return value is different depending on the video processing mode:
- When the video processing mode is
PROCESS_MODE_READ_ONLY, the return value is reserved for future use. - When the video processing mode is
PROCESS_MODE_READ_WRITE, the SDK receives the video frame when the return value istrue. The video frame is discarded when the return value isfalse.
Issues fixed
This release fixes the following issues:
- When using Agora Media Player to play RTSP video streams, the video images sometimes appeared pixelated.
- Playing audio files with a sample rate of 48 kHz failed.
- Adding an Alpha channel to an image in PNG or GIF format failed when the local client mixed video streams.
- After joining the channel, remotes users saw a watermark even though the watermark was deleted.
- If a watermark was added after starting screen sharing, the watermark did not display the screen.
- When joining a channel and accessing an external camera, calling
setDeviceto specify the video capture device as the external camera did not take effect. - When trying to outline the shared window and put it on top, the shared window did not stay on top of other windows.
- When there were multiple video streams in a channel, calling some video enhancement APIs occasionally failed.
API changes
Added
enableInstantMediaRenderingstartMediaRenderingTracingstartMediaRenderingTracingExonVideoRenderingTracingResultMEDIA_RENDER_TRACE_EVENTVideoRenderingTracingInfo
Deleted
enableRemoteSuperResolutionsuperResolutionTypeinRemoteVideoStats
v4.1.0
v4.1.0 was released on December 15, 2022.
New features
1. Headphone equalization effect
This release adds the setHeadphoneEQParameters method, which is used to adjust the low- and high-frequency parameters of the headphone EQ. This mainly useful in spatial audio use-cases. If you cannot achieve the expected headphone EQ effect after calling setHeadphoneEQPreset, you can call setHeadphoneEQParameters to adjust the EQ.
2. Encoded video frame observer
This release adds the setRemoteVideoSubscriptionOptions and setRemoteVideoSubscriptionOptionsEx methods. When you call the registerVideoEncodedFrameObserver method to register a video frame observer for the encoded video frames, the SDK subscribes to the encoded video frames by default. If you want to change the subscription options, you can call these new methods to set them.
For more information about registering video observers and subscription options, see the API reference.
3. MPUDP (MultiPath UDP) (Beta)
As of this release, the SDK supports MPUDP protocol, which enables you to connect and use multiple paths to maximize the use of channel resources based on the UDP protocol. You can use different physical NICs on both mobile and desktop and aggregate them to effectively combat network jitter and improve transmission quality.
To enable this feature, contact support@agora.io.
4. Register extensions
This release adds the registerExtension method for registering extensions. When using a third-party extension, you need to call the extension-related APIs in the following order:
loadExtensionProvider -> registerExtension -> setExtensionProviderProperty -> enableExtension
5. Device management
This release adds a series of callbacks to help you better understand the status of your audio and video devices:
onVideoDeviceStateChanged: Occurs when the status of the video device changes.onAudioDeviceStateChanged: Occurs when the status of the audio device changes.onAudioDeviceVolumeChanged: Occurs when the volume of an audio device or app changes.
6. Camera capture options
This release adds the followEncodeDimensionRatio member in CameraCapturerConfiguration, which enables you to set whether to follow the video aspect ratio already set in setVideoEncoderConfiguration when capturing video with the camera.
7. Multi-channel management
This release adds a series of multi-channel related methods that you can call to manage audio and video streams in multi-channel use-cases.
- The
muteLocalAudioStreamExandmuteLocalVideoStreamExmethods are used to cancel or resume publishing a local audio or video stream, respectively. - The
muteAllRemoteAudioStreamsExandmuteAllRemoteVideoStreamsExare used to cancel or resume the subscription of all remote users to audio or video streams, respectively. - The
startRtmpStreamWithoutTranscodingEx,startRtmpStreamWithTranscodingEx,updateRtmpTranscodingEx, andstopRtmpStreamExmethods are used to implement Media Push in multi-channel use-cases. - The
startChannelMediaRelayEx,updateChannelMediaRelayEx,pauseAllChannelMediaRelayEx,resumeAllChannelMediaRelayEx, andstopChannelMediaRelayExmethods are used to relay media streams across channels in multi-channel use-cases. - Adds the
leaveChannelEx[2/2] method. Compared with theleaveChannelEx[1/2] method, a new options parameter is added, which is used to choose whether to stop recording with the microphone when leaving a channel in a multi-channel use-case.
8. Video encoding preferences
In general use-cases, the default video encoding configuration meets most requirements. For certain specific use-cases, this release adds the advanceOptions member in VideoEncoderConfiguration for advanced settings of video encoding properties:
compressionPreference: The compression preferences for video encoding, which is used to select low-latency or high-quality video preferences.encodingPreference: The video encoder preference, which is used to select adaptive preference, software encoder preference, or hardware encoder video preferences.
9. Client role switching
In order to enable users to know whether the switched user role is low-latency or ultra-low-latency, this release adds the newRoleOptions parameter to the onClientRoleChanged callback. The value of this parameter is as follows:
AUDIENCE_LATENCY_LEVEL_LOW_LATENCY(1): Low latency.AUDIENCE_LATENCY_LEVEL_ULTRA_LOW_LATENCY(2): Ultra-low latency.
10. Brand-new AI Noise Suppression
The SDK supports a new version of AI noise reduction (in comparison to the basic AI noise reduction in v3.7.x). The new AI noise reduction has better vocal fidelity, cleaner noise suppression, and adds a dereverberation option.
To experience this feature, contact support@agora.io.
11. Spatial audio effect
This release adds the following features applicable to spatial audio effect use-cases, which can effectively enhance the user's sense of presence experience in virtual interactive use-cases.
- Sound insulation area: You can set a sound insulation area and sound attenuation parameter by calling
setZones. When the sound source (which can be a user or the media player) and the listener belong to the inside and outside of the sound insulation area, the listener experiences an attenuation effect similar to that of the sound in the real environment when it encounters a building partition. You can also set the sound attenuation parameter for the media player and the user, respectively, by callingsetPlayerAttenuationandsetRemoteAudioAttenuation, and specify whether to use that setting to force an override of the sound attenuation parameter insetZones. - Doppler sound: You can enable Doppler sound by setting the
enable_dopplerparameter inSpatialAudioParams, and the receiver experiences noticeable tonal changes in the event of a high-speed relative displacement between the source and receiver (such as in a racing game use-case). - Headphone equalizer: You can use a preset headphone equalization effect by calling the
setHeadphoneEQPresetmethod to improve the hearing of the headphones.
Improvements
1. Screen sharing
In addition to the usability enhancements detailed in the fixed issued section, this release includes a number of functional improvements to screen sharing, as follows:
- New
minimizeWindowmember inScreenCaptureSourceInfoto indicate whether the target window is minimized. - New
enableHighLight,highLightColor, andhighLightWidthmembers inScreenCaptureParametersso that you can place a border around the target window or screen when screen sharing. - Compatibility with a greater number of mainstream apps, including WPS Office, Microsoft Office PowerPoint, Visual Studio Code, Adobe Photoshop, Windows Media Player, and Scratch.
- Compatibility with additional devices and operating systems, including: Window 8 systems, devices without discrete graphics cards, and dual graphics devices.
- Support for Ultra HD video (4K, 60 fps) on devices that meet the requirements. Agora recommends a device with an Intel Core i7-9750H CPU @ 2.60 GHz or better.
2. Relaying media streams across channels
This release optimizes the updateChannelMediaRelay method as follows:
- Before v4.1.0: If the target channel update fails due to internal reasons in the server, the SDK returns the error code
RELAY_EVENT_PACKET_UPDATE_DEST_CHANNEL_REFUSED(8), and you need to call theupdateChannelMediaRelaymethod again. - v4.1.0 and later: If the target channel update fails due to internal server reasons, the SDK retries the update until the target channel update is successful.
3. Reconstructed AIAEC algorithm
This release reconstructs the AEC algorithm based on the AI method. Compared with the traditional AEC algorithm, the new algorithm can preserve the complete, clear, and smooth near-end vocals under poor echo-to-signal conditions, significantly improving the system's echo cancellation and dual-talk performance. This gives users a more comfortable call and live-broadcast experience. AIAEC is suitable for conference calls, chats, karaoke, and other use-cases.
4. Virtual background
This release optimizes the virtual background algorithm. Improvements include the following:
- The boundaries of virtual backgrounds are handled in a more nuanced way and image matting is now extremely thin.
- The stability of the virtual background is improved whether the portrait is still or moving, effectively eliminating the problem of background flickering and exceeding the range of the picture.
- More application use-cases are now supported, and a user obtains a good virtual background effect day or night, indoors or out.
- A larger variety of postures are now recognized, when half the body is motionless, the body is shaking, the hands are swinging, or there is fine finger movement. This helps to achieve a good virtual background effect in conjunction with many different gestures.
Other improvements
This release includes the following additional improvements:
- Reduces the latency when pushing external audio sources.
- Improves the performance of echo cancellation when using the
AUDIO_SCENARIO_MEETINGscenario. - Improves the smoothness of SDK video rendering.
- Reduces the CPU usage and power consumption of the local device when the host calls the
muteLocalVideoStreammethod. - Enhances the ability to identify different network protocol stacks and improves the SDK's access capabilities in multiple-operator network use-cases.
Issues fixed
This release fixes the following issues:
- In screen sharing use-cases, when the user minimized and then restored the shared window, the remote video occasionally switched to the low-quality stream.
- When the host started screen sharing during live streaming, the audience members sometimes heard echoes.
- In screen sharing use-cases, the system volume of the local user occasionally decreased.
- In screen sharing use-cases, a black screen appeared when sharing a screen between a landscape monitor and a portrait monitor.
- In screen sharing use-cases with a window excluded, the application crashed when the specified shared area exceeded the screen resolution.
- The application failed to exclude a window using the
startScreenCaptureByDisplayIdmethod for screen sharing. - In screen sharing use-cases, the screen seen by the remote user occasionally crashed, lagged, or displayed a black screen.
- The uplink network quality reported by the
onNetworkQualitycallback was inaccurate for the user who was sharing a screen. - In screen sharing use-cases, when the user shared the screen by window, the mouse in the shared screen was not in its actual position.
- When switching from a non-screen sharing use-case to a screen sharing one, the application occasionally crashed if the user did not switch the resolution accordingly.
- Audience members heard buzzing noises when the host switched between speakers and earphones during live streaming.
- The call
getExtensionPropertyfailed and returned an empty string. - When entering a live streaming room that has been played for a long time as an audience, the time for the first frame to be rendered was shortened.
API changes
Added
-
setHeadphoneEQParameters -
setRemoteVideoSubscriptionOptions -
setRemoteVideoSubscriptionOptionsEx -
VideoSubscriptionOptions -
leaveChannelEx [2/2] -
muteLocalAudioStreamEx -
muteLocalVideoStreamEx -
muteAllRemoteAudioStreamsEx -
muteAllRemoteVideoStreamsEx -
startRtmpStreamWithoutTranscodingEx -
startRtmpStreamWithTranscodingEx -
updateRtmpTranscodingEx -
stopRtmpStreamEx -
startChannelMediaRelayEx -
updateChannelMediaRelayEx -
pauseAllChannelMediaRelayEx -
resumeAllChannelMediaRelayEx -
stopChannelMediaRelayEx -
followEncodeDimensionRatioinCameraCapturerConfiguration -
hwEncoderAcceleratinginLocalVideoStats -
advanceOptions in VideoEncoderConfiguration -
newRoleOptions in onClientRoleChanged -
adjustUserPlaybackSignalVolumeEx -
onVideoDeviceStateChanged -
onAudioDeviceStateChanged -
onAudioDeviceVolumeChanged
Deprecated
onApiCallExecuted. Use the callbacks triggered by specific methods instead.
Deleted
- Removes
RELAY_EVENT_PACKET_UPDATE_DEST_CHANNEL_REFUSED(8) inonChannelMediaRelayEventcallback.
v4.0.1
v4.0.1 was released on September 29, 2022.
Compatibility changes
This release deletes the sourceType parameter in enableDualStreamMode [3/3] and enableDualStreamModeEx, and the enableDualStreamMode [2/3] method, because the SDK supports enabling dual-stream mode for various video sources captured by custom capture or SDK, you don't need to specify the video source type any more.
New features
1. In-ear monitoring
This release adds support for in-ear monitoring. You can call enableInEarMonitoring to enable the in-ear monitoring function.
After successfully enabling the in-ear monitoring function, you can call registerAudioFrameObserver to register the audio observer, and the SDK triggers the onEarMonitoringAudioFrame callback to report the audio frame data. You can use your own audio effect processing module to pre-process the audio frame data of the in-ear monitoring to implement custom audio effects. Agora recommends that you choose one of the following two methods to set the audio data format of the in-ear monitoring:
- Call the
setEarMonitoringAudioFrameParametersmethod to set the audio data format of in-ear monitoring. The SDK calculates the sampling interval based on the parameters in this method, and triggers theonEarMonitoringAudioFramecallback based on the sampling interval. - Set the audio data format in the return value of the
getEarMonitoringAudioParamscallback. The SDK calculates the sampling interval based on the return value of the callback, and triggers the onEarMonitoringAudioFrame callback based on the sampling interval.
To adjust the in-ear monitoring volume, you can call setInEarMonitoringVolume.
2. Local network connection types
To make it easier for users to know the connection type of the local network at any stage, this release adds the getNetworkType method. You can use this method to get the type of network connection in use, including UNKNOWN, DISCONNECTED, LAN, WIFI, 2G, 3G, 4G, 5G. When the local network connection type changes, the SDK triggers the onNetworkTypeChanged callback to report the current network connection type.
3. Audio stream filter
This release introduces filtering audio streams based on volume. Once this function is enabled, the Agora server ranks all audio streams by volume and transports 3 audio streams with the highest volumes to the receivers by default. The number of audio streams to be transported can be adjusted; you can contact support@agora.io to adjust this number according to your use-case.
Meanwhile, Agora supports publishers to choose whether or not the audio streams being published are to be filtered based on volume. Streams that are not filtered will bypass this filter mechanism and transported directly to the receivers. In use-cases where there are a number of publishers, enabling this function helps reducing the bandwidth and device system pressure for the receivers.
To enable this function, contact technical support.
4. Dual-stream mode
This release optimizes the dual-stream mode, you can call enableDualStreamMode and enableDualStreamModeEx before and after joining a channel.
The implementation of subscribing low-quality video stream is expanded. The SDK enables the low-quality video stream auto mode on the sender by default (the SDK does not send low-quality video streams), you can follow these steps to enable sending low-quality video streams:
- The host at the receiving end calls
setRemoteVideoStreamTypeorsetRemoteDefaultVideoStreamTypeto initiate a low-quality video stream request. - After receiving the application, the sender automatically switches to sending low-quality video stream mode.
If you want to modify the default behavior above, you can call setDualStreamMode[1/2] or setDualStreamMode[2/2] and set the mode parameter to DISABLE_SIMULCAST_STREAM (always do not send low-quality video streams) or ENABLE_SIMULCAST_STREAM (always send low-quality video streams).
5. Loopback device
The SDK uses the playback device as the loopback device by default. Since 4.2.0, you can specify a loopback device separately and publish the captured audio to the remote end.
setLoopbackDevice:Specifies the loopback device. If you do not want the current playback device to be the loopback device, you can call this method to specify another device as the loopback device.getLoopbackDevice:Gets the current loopback device.followSystemLoopbackDevice:Whether the loopback device follows the default playback device of the system.
Improvements
1. Video information change callback
This release optimizes the trigger logic of onVideoSizeChanged, which can also be triggered and report the local video size change when startPreview is called separately.
2. First video frame rendering
This release speeds up the first video frame rendering time to improve the video experience.
Issues fixed
This release fixes the following issues.
- When
stopPreviewwas called to disable the local video preview, the virtual background that has been set up was occasionally invalidated. - Occasional crash when exiting a channel and joining it multiple times with virtual background enabled and set to blur effect.
- If the local client used a 1920 x 1080 camera as the video capture source, the resolution of the remote video was occasionally inconsistent with the local client.
- When capturing video through the camera, if the video aspect ratio set in
CameraCapturerConfigurationwas inconsistent with that set insetVideoEncoderConfiguration, the aspect ratio of the local video preview was not rendered according to the latter setting. - When calling
setVideoEncoderConfigurationExin the channel to increase the resolution of the video, it occasionally failed. - When using the Agora media player to play videos, after you play and pause the video, and then call the seek method to specify a new position for playback, the video image might remain unchanged; if you call the resume method to resume playback, the video might be played in a speed faster than the original one.
API changes
Added
enableInEarMonitoringsetEarMonitoringAudioFrameParametersonEarMonitoringAudioFramesetInEarMonitoringVolumegetEarMonitoringAudioParamsgetNetworkTypesetRecordingDeviceVolumeisAudioFilterablein theChannelMediaOptionssetDualStreamMode[1/2]setDualStreamMode[2/2]setDualStreamModeExSIMULCAST_STREAM_MODEsetLoopbackDevicegetLoopbackDevicefollowSystemLoopbackDevicesetZonessetPlayerAttenuationsetRemoteAudioAttenuationmuteRemoteAudioStreamSpatialAudioParamssetHeadphoneEQPresetHEADPHONE_EQUALIZER_PRESET
Modified
enableDualStreamMode[1/3]enableDualStreamMode[3/3]enableDualStreamModeEx
Deprecated
startEchoTest[2/3]
Deleted
enableDualStreamMode[2/3]
v4.0.0
v4.0.0 was released on September 15, 2022.
Compatibility changes
Integration change
This release has optimized the implementation of some features, resulting in incompatibility with v3.7.x. The following are the main features with compatibility changes:
- Multiple channel
- Media stream publishing control
- Custom video capture and rendering (Media IO)
- Warning codes
After upgrading the SDK, you need to update the code in your app according to your business use-cases. For details, see Migrate from v3.7.x to v4.0.0.
New features
1. Multiple media tracks
This release supports one IRtcEngine instance to collect multiple audio and video sources at the same time and publish them to the remote users by setting RtcEngineEx and ChannelMediaOptions.
- After calling
joinChannelto join the first channel, calljoinChannelExmultiple times to join multiple channels, and publish the specified stream to different channels through different user ID (localUid) andChannelMediaOptionssettings. - You can simultaneously publish multiple sets of video streams captured by multiple cameras or screen sharing by setting
publishSecondaryCameraTrackandpublishSecondaryScreenTrackinChannelMediaOptions.
This release adds createCustomVideoTrack method to implement video custom capture. You can refer to the following steps to publish multiple custom captured video in the channel:
- Create a custom video track: Call this method to create a video track, and get the video track ID.
- Set the custom video track to be published in the channel: In each channel's
ChannelMediaOptions, set thecustomVideoTrackIdparameter to the ID of the video track you want to publish, and setpublishCustomVideoTracktotrue. - Pushing an external video source: Call
pushVideoFrame, and specifyvideoTrackIdas the ID of the custom video track in step 2 in order to publish the corresponding custom video source in multiple channels.
You can also experience the following features with the multi-channel capability:
- Publish multiple sets of audio and video streams to the remote users through different user IDs (
uid). - Mix multiple audio streams and publish to the remote users through a user ID (
uid). - Combine multiple video streams and publish them to the remote users through a user ID (
uid).
2. Ultra HD resolution (Beta)
In order to improve the interactive video experience, the SDK optimizes the whole process of video capture, encoding, decoding and rendering, and now supports 4K resolution. The improved FEC (Forward Error Correction) algorithm enables adaptive switches according to the frame rate and number of video frame packets, which further reduces the video stuttering rate in 4K scenes.
Additionally, you can set the encoding resolution to 4K (3840 × 2160) and the frame rate to 60 fps when calling SetVideoEncoderConfiguration. The SDK supports automatic fallback to the appropriate resolution and frame rate if your device does not support 4K.
This feature has certain requirements with regards to device performance and network bandwidth, and the supported upstream and downstream frame rates vary on different platforms. To enable this feature, contact support@agora.io.
The increase in the default resolution affects the aggregate resolution and thus the billing rate. See Pricing.
3. Build-in media player
To make it easier for users to integrate the Agora SDK and reduce the SDK's package size, this release introduces the Agora media player. After calling the createMediaPlayer method to create a media player object, you can then call the methods in the IMediaPlayer class to experience a series of functions, such as playing local and online media files, preloading a media file, changing the CDN route for playing according to your network conditions, or sharing the audio and video streams being played with remote users.
4. Ultra-high audio quality
To make the audio clearer and restore more details, this release adds the ULTRA_HIGH_QUALITY_VOICE enumeration. In use-cases that mainly feature the human voice, such as chat or singing, you can call setVoiceBeautifierPreset and use this enumeration to experience ultra-high audio quality.
5. Spatial audio
This feature is in experimental status. To enable this feature, contact support@agora.io. Contact technical support if needed.
You can set the spatial audio for the remote user as following:
- Local Cartesian Coordinate System Calculation: This solution uses the
ILocalSpatialAudioEngineclass to implement spatial audio by calculating the spatial coordinates of the remote user. You need to callupdateSelfPositionandupdateRemotePositionto update the spatial coordinates of the local and remote users, respectively, so that the local user can hear the spatial audio effect of the remote user.
You can also set the spatial audio for the media player as following:
- Local Cartesian Coordinate System Calculation: This solution uses the
ILocalSpatialAudioEngineclass to implement spatial audio. You need to callupdateSelfPositionandupdatePlayerPositionInfoto update the spatial coordinates of the local user and media player, respectively, so that the local user can hear the spatial audio effect of media player.
6. Real-time chorus
This release gives real-time chorus the following abilities:
- Two or more choruses are supported.
- Each singer is independent of each other. If one singer fails or quits the chorus, the other singers can continue to sing.
- Very low latency experience. Each singer can hear each other in real time, and the audience can also hear each singer in real time.
This release adds the AUDIO_SCENARIO_CHORUS enumeration in AUDIO_SCENARIO_TYPE. With this enumeration, users can experience ultra-low latency in real-time chorus when the network conditions are good.
7. Extensions from the Agora extensions marketplace
In order to enhance the real-time audio and video interactive activities based on the Agora SDK, this release supports the one-stop solution for the extensions from the Agora extensions marketplace:
- Easy to integrate: The integration of modular functions can be achieved simply by calling an API, and the integration efficiency is improved by nearly 95%.
- Extensibility design: The modular and extensible SDK design style endows the Agora SDK with good extensibility, which enables developers to quickly build real-time interactive apps based on the Agora extensions marketplace ecosystem.
- Build an ecosystem: A community of real-time audio and video apps has developed that can accommodate a wide range of developers, offering a variety of extension combinations. After integrating the extensions, developers can build richer real-time interactive functions. For details, see Use an Extension.
- Become a vendor: Vendors can integrate their products with Agora SDK in the form of extensions, display and publish them in the Agora extensions marketplace, and build a real-time interactive ecosystem for developers together with Agora. For details on how to develop and publish extensions, see Become a Vendor.
8. Enhanced channel management
To meet the channel management requirements of various business use-cases, this release adds the following functions to the ChannelMediaOptions structure:
- Sets or switches the publishing of multiple audio and video sources.
- Sets or switches channel profile and user role.
- Sets or switches the stream type of the subscribed video.
- Controls audio publishing delay.
Set ChannelMediaOptions when calling joinChannel or joinChannelEx to specify the publishing and subscription behavior of a media stream, for example, whether to publish video streams captured by cameras or screen sharing, and whether to subscribe to the audio and video streams of remote users. After joining the channel, call updateChannelMediaOptions to update the settings in ChannelMediaOptions at any time, for example, to switch the published audio and video sources.
9. Screen sharing
This release optimizes the screen sharing function. You can enable this function in the following ways.
- Call the
StartScreenCaptureByDisplayIdmethod before joining a channel, and then callJoinChannel[2/2] to join a channel and setpublishScreenTrackorpublishSecondaryScreenTrackas true. - Call the
StartScreenCaptureByDisplayIdmethod after joining a channel, and then callUpdateChannelMediaOptionsto setpublishScreenTrackorpublishSecondaryScreenTrackas true.
10. Subscription allowlists and blocklists
This release introduces subscription allowlists and blocklists for remote audio and video streams. You can add a user ID that you want to subscribe to in your whitelist, or add a user ID for the streams you do not wish to see to your blacklists. You can experience this feature through the following APIs, and in use-cases that involve multiple channels, you can call the following methods in the IRtcEngineEx interface:
SetSubscribeAudioBlacklist:Set the audio subscription blocklist.SetSubscribeAudioWhitelist:Set the audio subscription allowlist.SetSubscribeVideoBlacklist:Set the video subscription blocklist.SetSubscribeVideoWhitelist:Set the video subscription allowlist.
If a user is added in a blacklist and a whitelist at the same time, only the blacklist takes effect.
11. Set audio scenarios
To make it easier to change audio scenarios, this release adds the SetAudioScenario method. For example, if you want to change the audio scenario from AUDIO_SCENARIO_DEFAULT to AUDIO_SCENARIO_GAME_STREAMING when you are in a channel, you can call this method.
12. Local video mixing
This release adds a series of APIs supporting local video mixing functions. You can mix multiple video streams into one video stream locally. Common use-cases are as follows:
- In interactive live streaming use-cases with cohosts or when using the Media Push function, you can merge the screens of multiple hosts into one view locally.
- In use-cases where you capture multiple local video streams (for example, video captured by cameras, screen sharing streams, video files or pictures), you can and merge them into one video stream and then publish the mixed video stream in the channel.
You can call the startLocalVideoTranscoder method to start local video mixing and call the stopLocalVideoTranscoder method to stop local video mixing. After the local video mixing starts, you can call updateLocalTranscoderConfiguration to update the local video mixing configuration.
13. Video device management
Video capture devices can support multiple video formats, each supporting a different combination of video frame width, video frame height, and frame rate.
This release adds the numberOfCapabilities and getCapability methods for getting the number of video formats supported by the video capture device and the details of the video frames in the specified video format. When calling the startPrimaryCameraCapture or startSecondaryCameraCapture method to capture video using the camera, you can use the specified video format.
The SDK automatically selects the best video format for the video capture device based on your settings in VideoEncoderConfiguration, so normally you should not need to use these new methods.
Improvements
1. Fast channel switching
This release can achieve the same switching speed as SwitchChannel in v3.7.x through the LeaveChannel and JoinChannel methods so that you don't need to take the time to call the SwitchChannel method.
2. Push external video frames
This releases supports pushing video frames in I422 format. You can call the pushVideoFrame[1/2] method to push such video frames to the SDK.
3. Voice pitch of the local user
This release adds voicePitch in AudioVolumeInfo of onAudioVolumeIndication. You can use voicePitch to get the local user's voice pitch and perform business functions such as rating for singing.
4. Video preview
This release improves the implementation logic of startPreview. You can call the startPreview method to enable video preview at any time.
5. Video types of subscription
You can call the setRemoteDefaultVideoStreamType method to choose the video stream type when subscribing to streams.
Extensions
Notifications
2022.10
- After you enable Agora Notifications, your server receives the events that you subscribe to in the form of HTTPS requests.
- To improve communication security between the Agora Notifications and your server, Agora backend uses signatures for identity verification.
- As of this release, you can use Agora Notifications in conjunction with this product.
