Choice of two video cloud protocols: RTMP and GB28181

At present, various public clouds, private clouds, and streaming media servers basically support two video transmission protocols, one is RTMP and the other is GB/T28181. I understand that these two protocols have their own advantages and disadvantages:

  • RTMP uses TCP transmission, which has strong reliability and basically does not lose frames. If it is lost, the entire segment or the entire segment of the push end or the server end is lost. In the current network environment, there are not too many frame loss situations in conventional live broadcasts;
  • GB28181 has multiple transmission modes of TCP and UDP, but the degree of support of various devices is different, and the requirements for the network are relatively high, so the transmission of GB28181 is suitable for viewing, not very suitable for storage;
  • RTMP belongs to the push end to send data to the server in a single brain. From a conventional understanding, there is no on-demand push;
  • GB28181 has a signaling flow and a data flow, and the signaling flow controls the start and stop of the data flow;

Therefore, there is a difference in the choice of the two protocols of RTMP and GB28181. When there are the following requirements, it is necessary to choose GB28181 for video upload to the cloud:

  • PTZ control requirements;
  • Lens zoom requirements;
  • Equipment video playback requirements;

Is the on-demand live broadcast demand mentioned above not listed?
Although the RTMP streaming protocol does not have a signaling stream, there is also a handshake to establish a connection during the streaming process of RTMP. We can actively disconnect the server at the beginning of the server push to establish a connection or during the push process. Open the connection with the push end to achieve the purpose of stopping push; and in order to ensure that the server can receive the stream at the fastest speed when RTMP push is required, the push end needs to continuously reconnect and push. , Once the reconnection is successful, immediately start the streaming process, so that the timeliness and real-timeness of the entire process are the same as the streaming effect of signaling flow control!

Guess you like

Origin blog.csdn.net/xiejiashu/article/details/113102183