From: http://www.cnblogs.com/robertfang/articles/1222598.html
1. Overview
Streaming media technology is a new technology specifically used for transmitting and processing multimedia information on the network. This technology can achieve simultaneous transmission and playback of real-time working modes on the network, compared with other audio and video network transmission and processing technologies, streaming media is relatively mature and used, and has become the main solution for online audio and video (especially real-time audio and video) transmission.
The difference between streaming media and conventional video media is that streaming media can be downloaded and played. The important role of "stream" is that it can significantly save time. Because conventional video media files are large and can only be played after downloading, downloading takes a long time, streaming media is a product of Internet development in recent years. It is widely used in distance education, online radio stations, on-demand videos, and paid playback.
At present, the key to restricting the development of streaming media broadband applications lies in the quality of service on the Internet. Streaming Media theoretically solves the real-time requirements for transmission of multimedia data in large-capacity networks, however, data transmission in a large group exchange network is affected by many factors, and the network condition is unreliable, the bandwidth and load changes cannot meet the real-time service quality requirements of streaming media broadband services. In addition, it often causes playback jamming, delay, and severe video jitter, which has a great impact on the user's senses. Therefore, solving the service quality problem of streaming media network applications is extremely important for streaming media broadband applications.
2. Technical Principles of streaming media
Streaming media transmission needs to be cached. Because the Internet implements intermittent asynchronous transmission based on group transmission, a real-time A/V source or A/V file is stored. During transmission, they will be divided into many groups. Because the network changes dynamically, the routes selected by each group may be different, so the delay in reaching the client may not be the same, even the first data group may arrive later. Therefore, the cache system is used to compensate for the impact of latency and jitter, and ensure that the Group order is correct, so that the media data can be output continuously without pausing the video due to temporary network congestion.
Suitable transmission protocols are required for streaming media transmission. Because TCP requires a lot of overhead, it is not suitable for transmitting real-time data. In the implementation scheme of streaming media transmission, HTTP/TCP is generally used to transmit control information, while RTP/UDP is used to transmit real-time sound data.
Figure 1 Basic schematic diagram of streaming media transmission
The streaming media transmission process 1 is shown. The general description is as follows: After selecting a first-class media service, the web browser and the Web server exchange control information over HTTP/tcp to retrieve the real-time data to be transmitted from the original information, then the web browser on the client starts A/V helperProgram, Use http to retrieve relevant parameters from the Web server to initialize the Helper Program. These parameters may include the directory information, the encoding type of A/V data, or the server address related to A/V retrieval.
The A/V Helper Program and A/V server run the real-time stream protocol (RTSP, Real-Time Streaming Protocol) to exchange the control information required for A/V transmission. Similar to functions provided by CD players or VCRs, RTSP provides methods to manipulate commands such as playback, fast forward, fast backward, pause, and recording. A/V server uses the RTP/UDP protocol to transmit a/V Data to A/vcustomer Program (generally it can be considered that the customer program is equivalent to the Helper Program ), once A/V data arrives at the client, the/vclient program can play the output.
It must be noted that it is in streaming media transmission. Use RTP/udp and RTSP/tcp communication protocols to establish contact with A/V server, this is to redirect the server output to a destination address different from the client where the/V helper program is running. Streaming media transmission generally requires dedicated servers and players.
3. Streaming Media Transmission Mode
Streaming Media enables real-time playback of multimedia data through a dedicated network control protocol and data transmission mechanism. The server has a dedicated streaming media publishing system, while the client has a dedicated player. Both of these two parts need to be cached through the data cache area.
Different from the normal group switching network, the data in the cache area of the streaming media system is dynamic during data transmission and can also be in the switching status. The data enters and exits the buffer zone in the stack mode, instead, you do not need to wait until all the data reaches the client before it is released from the buffer zone. Because the data in the data buffer zone is "Flowing, in addition, data playback requires a stable data output speed, and the buffer zone is required to provide data to the player at any time. If no data exists, there will be a treaty of pause and screen in the content playing process. The previous situation is generally due to the network transmission speed not keeping up with the data playing speed, and the data overflow occurs, the latter case occurs because the network transmission speed is too fast and the playback speed is exceeded, without proper transmission control.
4. network transmission and control protocols
Due to its large data volume and real-time features, multimedia service also puts forward corresponding requirements for network transmission, mainly in the areas of high bandwidth, low transmission latency, synchronization and high reliability. To ensure good QoS, transmission mode, protocol stack, and application system control must be considered. The following describes several protocols used for real-time control and transmission of streaming media.
4.1 RTP/RTCP protocol cluster
RTP/RTCP is an end-to-end multicast-based application layer protocol. Among them, RTP (Realtime Transfer Protocol) is used for data transmission, and RTCP (Realtime Transfer Control Protocol) is used for statistics, management, and control of RTP transmission. The two work collaboratively, it can significantly improve the efficiency of real-time network data transmission.
RTP and RTCP are both defined in rfc1889. RTP is used to transmit real-time data in unicast or multicasting situations. It usually works on UDP. The core of the RTP protocol lies in its packet format. It provides multiple domains for multimedia, including VOD, VoIP, and video conferencing, and does not specify the load size, therefore, it can be flexibly applied to various media environments. However, the RTP protocol itself does not provide reliable packet transmission and congestion control, and must rely on RTCP to provide these services. The main function of RTCP is to provide media quality information for applications. During an RTP session, each participant periodically sends an RTCP control packet to each other. The packet contains statistics from the sender or acceptor. This includes the number of sent packets, packet loss, packet jitter, etc. In this way, the sender can change the sending rate based on the information, and the receiver can determine the network segment where the packet loss and other problems occur. In general, RTCP plays a role in streaming media transmission, including QoS management and control, media synchronization, and additional information transmission.
Based on the RTP/RTCP protocol, different media types require different encapsulation and management technologies. At present, international research based on RTP/RTCP Media Streaming technology, including MPEG-1/2/4 media streaming technology.
4.2 RSVP protocol
Resource Reservation Protocol (RSVP) is a protocol proposed to ensure QoS and support multi-point transmission at the transport layer of an IP network. RSVP reserves certain network resources before business flow transmission to establish a static or dynamic transmission logical path. This ensures that each business flow has enough "exclusive" bandwidth to overcome network congestion and packet loss and improve QoS performance.
It is worth mentioning that RSVP is a protocol for the receiver to perform operations. The recipient determines the priority of the reserved resources and initializes and manages the reserved resources. Resources required to be reserved on network nodes (such as routers), including the buffer zone and bandwidth, are generally used by the "package" on the network node to reserve resources, there are three types of RSVP Reserved: no package form, fixed package form, and dynamic package form.
4.3 RTSP Protocol
Real-Time Streaming Protocol is jointly proposed by RealNetworks and Netscape. It is an application layer protocol that works on RTP. Its main goal is to provide reliable playback performance for unicast and multicast. The main idea of RTSP is to provide the function of controlling data transmission of multiple applications. It provides a method to select a transmission channel, such as UDP, TCP, and IP multicast. It also provides methods based on the RTP transmission mechanism. The RTSP control controls the streams sent through a separate protocol and has nothing to do with the control channel. For example, the RTSP control can be connected over TCP, while the data streams pass through UDP. By establishing and controlling one or several time synchronization continuous stream data, which may include control flow, RTSP can provide remote control for the server. In addition, because RTSP is similar in syntax and operation to HTTP, RTSP requests can be parsed by standard HTTP or mime parser, and RTSP requests can be processed by proxies, channels, and caches. Compared with HTTP, RTSP is bidirectional, that is, both the client and server can send RTSP requests.
The system that implements RTSP must support RTSP transmission over TCP and UDP. The default TCP and UDP ports of the RTSP server are 554. Currently, the latest Microsoft Media Services V9 and RealSystem support the RTSP protocol.
5. Media Value Chain and Operation Model
The value chain of the broadband streaming media service must include at least several parts: application providers, content developers, business support system operators, network providers, and users. The user finally obtains and pays for the broadband streaming media application business. The application provider is a direct provider of Broadband Streaming Media businesses and directly provides services to users. Content Providers are the owners of streaming media content resources and are responsible for program production, including the generation, encoding, and compression of streaming media files. The service support system operator provides an independent and operable management and transmission platform to support broadband streaming media applications. Network providers provide basic bearer networks.
At present, the operation mode of streaming media is still developing, and network operators, application providers, and content providers are constantly seeking for mature operation modes and cooperation modes.
6. Conclusion
Streaming Media Technology includes a series of technologies, including server architecture and network protocols. These technologies are still being developed and improved, and operators are also exploring suitable business models. Even so, streaming media technology has transformed the traditional internet into two-dimensional rigid Content Representation of text and images, and is the development direction of broadband applications. At the same time, streaming media can be widely used in VOD, remote teaching, online advertising, interactive video games, etc., greatly broadening the scope of service. Therefore, various telecom operators are optimistic about streaming media services, it also hopes to drive the broadband industry into a period of rapid development. It is foreseeable that the streaming media service will become the mainstream information service on the broadband network.