Since the birth of RTMP push stream protocol, the development of push stream based on RTMP protocol has not stopped. Until a more perfect substitute is found, the mainstream push stream on the market will still be implemented by RTMP protocol. As well known to the public, RTMP has always been the mainstream video broadcast scheme on PC side Web, including EasyCVR, which is developed by us, and supports RTMP streaming in the latest version.
The focus of this article is on live streaming HTML5 video. With the explosive growth of live broadcasting platforms, the demand for H5 live broadcasting has become extremely rich. The overall process of H5 live broadcast can be roughly divided into three modules:
Video collection: This module includes the collection of audio and video equipment on the computer, camera and microphone on the mobile phone, audio and video of TV station/competition scene camera, etc. For the H5 push stream live broadcast, the main direction of collection is the audio and video collection of camera on the mobile phone and TV station.
Decoding and distribution: This module is mainly completed by video streaming media server. After video collection, a Nginx server is required for processing. The video stream transmitted by the video recording end (H264/ACC encoding) is collected, and the server end parses the encoding and pushes the RTMP/HLS format video stream to the video player end.
Video playing: Video playing depends on the player used by the user, including computer player, mobile phone player, and H5 video label.
For PC H5 video recording, weBRTC technology with more advantages can be selected. The basic process of video recording with WEBRTC is briefly summarized as follows:
1, call window. The navigator. WebkitGetUserMedia (), get the user’s PC camera video data.
2, will get to video streaming data into the window. The webkitRTCPeerConnection (a video streaming data format).
3. Use WebScoket to transfer video stream data to the server.
Video recording is completed, you need a set of RTMP live streaming service to ensure that the video streaming transmission, at the same time also have conversion live streaming format and the coding stream function, when the server receives the come streaming video to record the transfer, it is necessary to parse the coding, push RTMP/HLS format video to video playback.
We also said before, there are several ways to obtain a set of streaming media service platform, including yourself from zero to build, the use of open source platforms in infrastructure changes, direct search on third party access platform, platform structures themselves laborious, so the comparison is recommended by the open source platforms, or directly to find service providers.
EasyDarwin is an open source platform based on WebRTC, which can help developers easily build streaming media services. At present, EasyDarwin platform has a stable operating environment and professional technical support. These two advantages are powerful backing for users in the process of using. At the same time, we also have such RTMP live broadcast on demand platform as EasyDSS, which can also realize H5 push stream live broadcast of video stream after installation and deployment. EasyDSS also has very rich secondary development interface, which can be easily carried out secondary development and application.