You can play a live stream using VLC media player, the ApsaraVideo Live demo, or the ApsaraVideo Player SDK. This topic describes how to use each method to play a video stream.
Prerequisites
You have completed stream ingest. For more information, see Live stream ingest.
You have generated a streaming URL. For more information, see Generate ingest and streaming URLs.
If an exception occurs during stream ingest or playback, you can use the self-service troubleshooting tool to run a check. This tool can quickly diagnose common live playback issues and provide solutions. For more information, see Self-service troubleshooting.
Use VLC media player to play a stream
VLC media player supports Windows, macOS, Linux, Android, and iOS. This topic uses VLC for Windows version 3.0.16 as an example. Operations are similar for other versions and platforms. For more information about VLC, visit VLC media player.
Download and install VLC media player. Download link: VLC media player.
Run VLC media player.
In the menu bar, choose Media > Open Network Stream....
On the Network tab, enter the streaming URL. Example:
rtmp://example.aliyundoc.com/app/stream?auth_key=1543300311-0-0-d47ce016332bf280cf275********.Click Play.
Use the ApsaraVideo Live demo to play a stream
Use a mobile device to scan the QR code and install the ApsaraVideo Live demo.
NoteIf you install the demo on an iOS device by scanning the QR code and receive an Untrusted Enterprise Developer message, go to Settings > General > Device Management. Find the Taobao profile and trust it.
Run the ApsaraVideo Live demo.
Select Live Playback.
Enter the generated streaming URL. Example:
rtmp://example.aliyundoc.com/app/stream?auth_key=1543300311-0-0-d47ce016332bf280cf275********.Click Start Playback to begin playing the stream on your mobile device.
Use ApsaraVideo Player SDK to play a stream
ApsaraVideo Player SDK is a cross-platform audio and video playback tool developed by Alibaba Cloud. The SDK is a sub-module of ApsaraVideo MediaBox SDK. The SDK allows you to play videos in live streaming scenarios and supports multiple platforms, such as the web, Android, iOS, Flutter, Windows, and macOS. The SDK provides features such as loop playback, definition switching, image ads, video ads, bullet comments, and subtitles. To try the SDK on the web, visit Feature Display.
Playback procedure | |
ApsaraVideo Player SDK for Android |
|
ApsaraVideo Player SDK for iOS |
|
ApsaraVideo Player SDK for Flutter |
|
ApsaraVideo Player SDK for Web |
|
ApsaraVideo Player SDK for Windows | Note To obtain ApsaraVideo Player SDK for Windows, contact your Alibaba Cloud business manager to request the download. |
References
Why am I unable to play a video in ApsaraVideo Live after the ingest URL is generated?