To use the Real-Time Streaming (RTS) feature in ApsaraVideo Live, you must integrate Native RTS SDK into your player. This topic describes Native RTS SDK directories and shows you how to integrate Native RTS SDK into various players to use the RTS feature.

Basic integration process

Three types of players are supported: ApsaraVideo Player, third-party players that are based on FFmpeg, and third-party players that are not based on FFmpeg. The following table describes the basic process of integrating Native RTS SDK into these players to use the RTS feature.

Player Basic integration process
ApsaraVideo Player
  1. Integrate Native RTS SDK as a plug-in into ApsaraVideo Player SDK.
  2. Integrate ApsaraVideo Player SDK into your project.
  3. Call the methods of ApsaraVideo Player SDK to use the RTS feature.

RTS SDK for macOS or Windows is embedded with ApsaraVideo Player. Therefore, no integration is required. In addition, no ApsaraVideo Player is available for RTS SDK for macOS. For more information about how to integrate Native RTS SDK for Android or iOS into ApsaraVideo Player SDK, see Integrate Native RTS SDK with ApsaraVideo Player SDK.

Third-party players that are based on FFmpeg
  1. Integrate Native RTS SDK as a plug-in into a third-party player that is based on FFmpeg.
  2. Integrate the third-party player into your project.
  3. Call the methods of the third-party player to use the RTS feature.

For more information about how to integrate Native RTS SDK with a third-party player that is based on FFmpeg, see Integrate Native RTS SDK with a third-party player that is based on FFmpeg.

To simplify development, you can also use the rtsdec.c file to encapsulate Native RTS SDK as an FFmpeg demuxer plug-in for a third-party player that is based on FFmpeg.

Third-party players that are not based on FFmpeg
  1. Integrate Native RTS SDK as a plug-in into a third-party player that is not based on FFmpeg.
  2. Integrate the third-party player into your project.
  3. Call the methods of the third-party player to use the RTS feature.

This integration method applies to self-developed players. You need to copy dynamic frameworks and header files of Native RTS SDK to your project. For more information, see the rtsdec.c or rtsenc.c file in Native RTS SDK to develop the demuxer.

Native RTS SDK directories

Operating system Directory Description
Android aar The Maven dependencies, which must be used with ApsaraVideo Player SDK.
  • lib
  • include
You must provide your own artc Demuxer. If FFmpeg is used, you can develop artc Demuxer based on source/rtsdec.c.
jar The JAR packages available for V1.4.1 or later. You need to import the JAR packages if you use local dependencies for integration.
iOS source This dependency file can be used by ApsaraVideo Player and third-party players. If you use a third-party player, you must provide your own artc Demuxer. If the third-party player is based on FFmpeg, you can develop your software based on source/rtsdec.c.
RtsSDK.framework
macOS source
  • source/rtsdec.c: sample code for stream pulling by using FFmpeg
  • source/rtsenc.c: sample code for stream ingest by using FFmpeg.
lib The dynamic framework file libRtsSDK.dylib.
include The header files of Native RTS SDK.
Windows source
  • source/rtsdec.c: sample code for stream pulling by using FFmpeg
  • source/rtsenc.c: sample code for stream ingest by using FFmpeg.
lib The dynamic framework files RtsSDK.dll and RtsSDK.lib on Windows.
include The header files of Native RTS SDK.