"Hu Bo, Zhao Due, Wang Zhongjun. Based on H.265 Code HD Video Transmission System [J]. Applied Technology, 2017, 44 (1): 27-32.
HIGH-Definition Video Transmission System Based On H.265 [J]. Applied Science And Technology, 2017, 44 (1): 27-32.
Doi: 10.11991 / YYKJ.201604018
H.265-based codec HD video transmission system
Hu Bo,
Zhao Due,
Wang Zhongjun
School of Information and Communication Engineering, Harbin Engineering, Harbin 150001, China
Abstract: To solve the real-time transmission of HD video, the increase in bandwidth pressure is increased, and a new high-definition video transmission system design method is proposed to improve the above situation based on H.265 codec. The system first uses the HI3516A processor to perform H.265 hardcodes for HD video, and then use Boost: ASIO library for dedicated streaming media server design, and finally based on DirectX for rendering display scheme design. After system experimental verification, the system is transferred to 120 ms by 120 ms when codecs the HD 1 080p video in 25 FPS frame rate and 2 m code stream transmission. At the same time, in normal HD 720P and standard clearance 480i video acquisition conditions, H.265 relative to H.264 decoded the PSNR value of the image after the transmission code rate is half-transmitted, and the PSNR value of the image after the H.264 is decoded is basically the same. However, under HD 1 080P video acquisition conditions, the PSNR value of the post-decoded image after 1 m yield transmission is significantly better than that of the H.264 codec is decoded at 2 m y code rate. The PSNR value is decoded.
Key words:
Video transmission
Transmission system
H.265 codec
HD video
Boost: ASIO library
Rendering
Low delay
hardcode
flow media services
HIGH-Definition Video Transmission System Based on H.265
Hu Bo,
ZHAO DANFENG,
Wang Zhongkan
COLLEGE OF INFORMATION AND Comunication Engeering, Harbin Engineering University, Harbin 150001, CHINA
Abstract: In order to solve the problems of the bandwidth pressure and the time delay when transmittting HD video in real time, this paper proposed a new method to improve the situation of the time delay and bandwidth pressure in the area of the real-time transmission of HD video First, the transmission system proposed used Hi3516A processor to decode HD video Then, the dedicated streaming media server based on Boost:... asio was designed In the end, the system rendered the decoded video based on DirectX According to experiments. , the delay time of the transmission system was about 120ms, when the video of 1080P eccoded by H.265 transmitted in the condition of 25 fps and the rate of 2M. At the same time, the PSNR of decoded video by H.265 / HEVC was almost equal to the PSNR of decoded video by H.264 / AVC in double bandwidth under the same quality of source video in the condition of capturing the SD video and HD video. But the PSNR of decoded video by H.265 / HEVC WAS Better Than the PSNR of Doulity of Source Video, When the System Transmitted The Video Of 1 080p.
Key Words:
Video Transmission
Transmission System, TRANSMISSION SYSTEM
H.265 CODEC
HIGH-Definition Video
Boost: Asio
render
Low latency
Hard-Coded
Streaming Media Server
With the opening of the closed cell, the establishment of smart communities, video surveillance will receive further demand. Video surveillance is currently in a high-definition era that is mainly based on CIF and D1-based standard clearance, with a HD era of 720p, 1080p. At present, the H.264 video codec standard still occupies 80% of the video network transmission [1]. However, with the improvement of the image quality of the camera, the H.264 video decoding standard is increasingly unable to meet the requirements of HD video transmission.
Currently, Google's VP9 and JCT-VC developed H.265 video codec standard [2], which is better than the H.264 codec standard in video codec performance. DUMIC et al. [3] The comparison of H.265 and H.264 compressed performance in network transmission, proves that H.265 is stronger than H.264 for HD video compression performance. Grois, Dan et al [4] performs comparative study of X264 and X265 compression code rates, and it is understood that X.265 has a 32.6% increase in code rate in X.265. The solution to realize video codec is mainly divided into 2 categories, which are hard-wedding decoding and soft-editing decoding schemes. With the market research, I've released the first H.265 video decoder, Huawei Haisi, Bo Tong, and ZTE and Haokang and other enterprises have launched the H.265-based hardware equipment [5]. Soft-won decoding mainly has FFMPEGH265 and X265 [6], which is streamlined for the H.265 codec function to ensure the timeliness of codec. For high-definition video network transmission bandwidth, time extension, etc., using H.265 hardware and soft-decoded schemes for system hardware and software integrated design.
1 HD video capture code
The video capture coding terminal uses Huawei Hi3516A processor to perform different format video signal acquisition, H.265 and H.264 hardcodes, and the function application design of client interaction control, where interactive control is shown in Figure 1. The video capture coding terminal mainly completes video acquisition coding and function development design with client interaction, including the acquisition coding of all the way HD video data, the user can customize the selection of the encoded format, video image clarity, and custom transmission code rate.
Figure 1 System interaction
Figure option
The overall architecture map of the acquisition coding end is shown in Figure 2. After the video image is collected by the VI video input module, the system control module VPSS is transmitted, and then the encoding channel encoding is entered. The video signal is primarily encoded for the video signal.
Figure 2 Equipment End Monitor
Figure option
1.1 video capture
The video stream hardware interface circuit of the acquisition encoding end is collected by an external HDMI interface. Since the HI3516A processor video interface has a BT.656 / 601, a BT.1120 interface, a digital camera interface, and MIPI RX (including MIPI, LVDS, HISPI) interfaces. The video capture unit VICAP (Video Capture) in the Hi3516A processor is accepted by the BT.1120 interface in the design of the BT.1120 interface. The video source is issued by the HDMI interface. The resolution is 1 920 × 1 080 (1 080p). As a result, the IC chip SIL9135A is driven to the BT.1120 format video data to send the HI3516A processor, and after the Gigabit Ethernet is sent.
Video acquisition thread application design mainly includes initializing the module parameters of the system, initializing the MPP platform parameters, opening physical channels and expansion channels, starting VPSS and binding VPSS and VI, and opening via VI modules. Among them, the initialization system parameter is mainly obtained by obtaining input image size information, calculating the size of the video buffer blocks required for different video formats and applies for the corresponding size video buffer. The video capture flow chart is shown in Figure 3.
Figure 3 Video Acquisition Process
Figure option
1.2 video coding
In the video encoding thread, the encoding channel acquires the encoded code stream from each configuration channel. In the process of obtaining the encoded post-encoded stream, first inquire about the number of packets included in the frame code stream for the corresponding encoding channel. For the number of corresponding packets, the memory space is applied, and then the encoded code stream data is read, stored. The program design finally remembers the release of memory, avoiding the memory space being applied, the system crashes. Video channel encoding threads are shown in Figure 4.
Figure 4 channel coding process
Figure option
1.3 thread interaction
The interaction thread in the main program (shown in Figure 5), mainly completed interactions between the client, performs updates and corresponding control operations of encoding parameters. Since the update of the encoding parameters is not dynamically updated, the system is turned off after each update parameter, and the system is restarted again.
Figure 5 Interaction thread flow
Figure option
The data points received each time the device is classified, and one is the control command information, and the other is information that contains video encoding parameters. The system completes information transfer by setting a private communication protocol. In the interaction thread, first, the corresponding memory is applied for the data. After the system receives the data, the data type is classified according to the frame header data content. If it is parameter information, the updated corresponding parameter operation is updated, then restart the system; if it is control command information, the corresponding command operation is performed directly. Print out of the shell client is shown in Figure 6, 7.
Figure 6 Executes Update Parameters Command
Figure option
Figure 7 Executes stop playback command
Figure option
2 streaming media server based on Boost: ASIO library
At present, most streaming media servers are based on the RTSP transport protocol, and the network technology and streaming media techniques are used to develop design [7]. However, whether it is open source or commercial streaming media servers, the versatility is better, but the function is more complicated, and it is more difficult to complete its function. If the scenario needs a full-feature streaming server, you can select an open source or commercial streaming server [8]. Since the system is only required to transfer all the wayThe live stream of H.264 or H.265, so the design dedicated streaming media server is designed according to system requirements. The paper uses the C / S architecture to stream media server design, and finally based on the BOOST: ASIO library to achieve development and design of asynchronous servers, where the server is divided into two parts-oriented connection and non-consecutive connection.
After the streaming media server is designed, when the seeding video stream and the reception video frequency code are designed, the stream structure of the NAL layer of the H.264 and H.265 is required to analyze. After the encoding thread is completed, the encoded code stream is sent to the sending thread. First determine the NALU package type when the server-side sending thread receives the NALU packet. It is determined whether the packet is a NALU package such as SPS, PPS. If it is, the corresponding frame header is added as a logo and code stream adjustment when decoding as a selection basis for discarding the packet. Second, due to the limit of the network transmission code flow, if the network transmission stream exceeds a certain length, it needs to be split, and the system is not exceeding 1 500 BYTES in the system for the system. The code stream analysis process is shown in Figure 8. The code stream transmits through the shell client printing effect chart as shown in Figure 9.
Figure 8 Code stream package process
Figure option
Figure 9 code stream sending a schematic
Figure option
3 client software design
The video data decoding portion in the paper mainly decodes streaming decoding. Since the decoder output video data is the YUV420 format, the image display is generally RGB format [9]. However, the YUV format data of HD video to RGB format data conversion requires a larger computer resource, and the real-time decoding of HD video also occupies more computer resources, so decoding display time will be long [10]. Therefore, the paper terminal display scheme selects the DirectDraw technology to implement the YUV format data rendering display of HD video. The display flow chart is shown in Figure 10.
Figure 10 Rendering Display Process
Figure option
Since the video format conversion is omitted during the display system design, the graphics resources are taken, so it is displayed smooth and reduces the display delay.
The decoding process is shown in Figure 11. The system is divided into the following two cases for the input code stream: First, the code stream is less than one frame of video data, then the input stream is required to decode; secondly, when the code stream includes several frame video data, it is required. Decoding a frame image repeatedly calls the decoding function to decode the remaining stream. One thing to note during the decoding process is that after the card is completed, it must enter the residual image in the FLUSH mode clear the decoder until there is no residual image in the decoder.
Figure 11 Decoding program flow
Figure option
4 test results
4.1 Comparison of image quality
Since the peak signal-to-noise ratio PSNR is the most common index of current image quality evaluation, this section verifies video image transmission of the H.265 video-coded by H.264 video in the same source image quality transmission. Video image transmission is transmitted relative to H.264. The situation, compare the PSNR value of the post-decoded image of H.265 and H.264.
The experiment was carried out in 3 groups below, and the 1 080p video image, 720p video image, and 480i video images were experiments at 25 FPS frame rates.
1) Comparison of image quality comparison of H.265 and H.264 is coded for 1 080p video image.
As shown in FIG. 12, the reference image is acquired by a 1 080p format, and (a) is an image after codec under 1 m code rate condition, and 12 (b) is H. 264 The image after codec.
Figure 12 1 080p video image decoding post-image quality contrast
Figure option
GRAZ, AUSTRIA: IEEE, 2015: 1-7. [4] Grois D, Marpe D, Nguyen T, et al. Comparative assessment of H.265 / MPEG-HEVC, VP9, AND H.264 / MPEG-AVC Encoders for low-delay video application of the spie 9217, Applications of Digital Image Processing xxxvii. San Diego CA, United States: Spie, 2014: 92170q. [5] Yang Dong. Analysis of H.265 New Trend of Codes [J]. China Security, 2015 (6): 84-86 [6] Zhang Zheng.H.265 opens security new era [J]. China Public Safety, 2015 (8): 116-118 [ 7] RUPALWALA S S. ARM 11 based real-time video streaming server using RTSP protocol [C] // Proceedings of International Conference on Electrical, Electronics, Signals, Communication and Optimization Visakhapatnam, India:. IEEE, 2015: 1-5. [8] Zhao Jin, Ye Fei, Feng Yili.Seconductive Research on RC Based on RTP / RTCP [J]. China Cable TV, 2004 (1): 6-9 [9] Li Hua. Network Video Monitoring System Client Design and Implementation of Audio Software [D]. Wuhan: Huazhong University of Science and Technology, 2007. [10] Guo Fang, Zhang Jiashu. H.265 Safety and Efficient Index Columbus Code Scheme [J]. Computer Application & Software, 2013, 30 (10): 85-86 [11] JI Qiujia, Yu Hewei, Chen Haihao. A Smart Android Based Remote Monitoring System [C] // Proceedings of The 3rd International Conference ON Technolo Gical Advances in Electrical, Electronics and Computer Engineering. Beirut, Lebanon: IEEE, 2015: 181-184. "
Visual observation of the human eye Figure 12 (a), (b) does not have too much difference, and the image difference can be judged by Table 1.
Table 1 1 080P video image PSNR contrast
Bandwidth PSNR-Y PSNR-U PSNR-V H.265 (1 m) 41.040 74 41.540 80 41.880 81 H.264 (2 M) 18.974 96 19.624 50 20.549 20
Table option
The image PSNR value is obtained by coding by H.265 by the H.265 by the comparison 1 080p video image, respectively, and the image PSNR value is coded by the H.264, which can be seen that the image quality is very different. 1 080p The image is coded by the H.265, although the code rate is only half the H.264 transmission rate, but the image quality is far exceeds the image quality after the H.264 codec. The image quality after the image quality and the H.265 coding are so large after the codec, the main reason is that the H.264 encoding module in the HI3516A processor is not good for 1080p HD video encoding.
2) Comparison of image quality comparison of 720P video is coded by H.265 and H.264.
As shown in FIG. 13, the reference image is acquired by the 720P format, and (a) is an image after being coded by H.265 under 0.5 m rate conditions; (b) is H.264 under 1 m code rate conditions. Decoded images.
Figure 13 720p video image decoding image quality comparison
Figure option
The image PSNR value is coded by the H.265 by the H.265 by the H.265 by the H.265 by the H.265, and the image PSNR value is coded by the H.264, respectively, and the image quality difference is small, and the PSNR value can be seen. All are around 33. After the 720p image is coded by H.265, although the transmission rate is only half the rate of H.264, the image quality and H.264 are basically the same.
Table 2 720p video image PSNR contrast
Bandwidth PSNR-Y PSNR-U PSNR-V H.265 (0.5 m) 33.17912 35.000 71 33.152 47 H.264 (1 M) 33.113 80 34.834 72 32.947 76
Table option
3) The image quality comparison of the 480i video image is coded by the H.265 and H.264.
As shown in FIG. 14, the reference image is acquired by 480i format, and (a) is an image after being coded by H.265 under 0.25 m code rate conditions; (b) is H.264 under 0.5 m code rate conditions. Decoded images.
Figure 14 480i video image decoding post-image quality comparison
Figure option
Table 3 480i video image PSNR comparison
Bandwidth PSNR-Y PSNR-U PSNR-V H.265 (0.25 m) 29.94754 31.26621 30.58239 H.264 (0.5 m) 30.32712 31.79496 30.99647
Table option
By the comparison 480i video image, the image PSNR value is coded by the H.265 by the H.264 by the H.264 by the H.264, respectively, and the analysis can be known that the 480i standard clearance image is coded after H.264. The image quality is slightly stronger than the image quality after the H.265 is coded.
Through the above experiments, the H.265 video codec is significantly better than H.264 video encoding for HD video processing performance.
4.2 Image transmission delay test
The system time delay travel test is shown in Table 4 for the system. According to system analysis, video transmission delays are mainly divided into 3 parts, codec delay, network transmission delay, and display delay [10]. The experiment was encoded for the video data, and 10 sets of time delay tests were performed in the case of high yard ratio and low yardre transmission. The test frame rate in the test frame rate of 1,080p in the experiment is 25, with high yD rate finger 2 m and low yard ratios 1 M. The 10 sets of test data in H.265 encoding are shown in Table 4.
Table 4 H.265 encoding conditions 10 sets of experimental data
Group of high-yd rate situations / s decoding / s time difference / s pre-code / s decoding / s / s time difference / s 1 8.14 8.26 0.12 Group 6 03.53 03.75 0.22 Group 2 9.12 9.23 0.11 Group 7 14.49 14.79 0.30 groups 3 13.83 13.94 0.11 groups 8 27.74 28.01 0.27 groups 4 44.81 44.93 0.12 groups 9 34.76 34.99 0.23 groups 5 86.34 86.46 0.12 groups 10 59.74 60.03 0.27
Table option
10 sets of test data analysis under the H.265 coding conditions, the system's time level is about 120 ms in the case of high-size rate. When a 1 m low rate transmission is used under the same conditions, the corresponding system delay is increased, and the average is about 250 ms.
Through the above experiment, the transmission system can reduce the system transmission delay in the case of high yard ratio. The main reason is that the system prolongs the decoding processing time when decoding process decoding processing under low yard ratio. The field test is shown in Figure 15.
Figure 15 Video real-time transmission delay effect
Figure option
5 Conclusion
The paper completed the design and implementation of integrated system based on HI3516A processor hard coding and client soft decoding based on H.265 HD video network transmission system.
1) H.265 codec is a PSNR value of the post-definition image with respect to the codec of the H.264 codec, the PSNR value of the post-definition 480i is slightly better than that of the codec of H.264 in the case. .265.
2) When transmitting a 720P image, the PSNR values are substantially equal.
3) When transmitting a high definition 1080p image, the encoding performance of H.264 is significantly reduced relative to H.265. Experiments show that the codec performance of H.264 is superior in low definition video transmission, but the image quality declines quickly after high-definition video decoding. Therefore, with the popularity of HD video, H.264 will not adapt to HD video transmission.
At the same time, the paper passes the HD 1 080p video format video through the experiment, compared the low yard ratio and the high yield rate, and the system is delayed in the transmission of the system in the high-yaw rate of 120. About the MS, the low yard ratio is about 250 ms, which can meet the needs of the project. Experiments have shown that the software and hardware integrated design of this system is good, and can meet real-time system transmission requirements. At present, the system is experimenting at a fixed code rate, which will be tested under an adaptive code rate of the encoder.
references
[1] Gao Dandan, Wang Cheng. H.265 leads the video new era [J]. Technology Innovation Dance, 2014 (20): 231 [2] He Haidong, Dong Quanwu, Ji Lin. H.265 / HEVC, VP9, H.264 Comparison and Performance Test Analysis of Coding Algorithm [J]. Broadcast and Television Technology, 2014, 41 (10): 47-52 [3] Dumić E, GRGIć S, FRANK D, ET Al. Subjective Quality Assessment of H.265 VERSUS H .264 Video Coding for High-Definition Video Systems [C] // Proceedings of The 13th International Conference ON TelecomGRAZ, AUSTRIA: IEEE, 2015: 1-7. [4] Grois D, Marpe D, Nguyen T, et al. Comparative assessment of H.265 / MPEG-HEVC, VP9, AND H.264 / MPEG-AVC Encoders for low-delay video application of the spie 9217, Applications of Digital Image Processing xxxvii. San Diego CA, United States: Spie, 2014: 92170q. [5] Yang Dong. Analysis of H.265 New Trend of Codes [J]. China Security, 2015 (6): 84-86 [6] Zhang Zheng.H.265 opens security new era [J]. China Public Safety, 2015 (8): 116-118 [ 7] RUPALWALA S S. ARM 11 based real-time video streaming server using RTSP protocol [C] // Proceedings of International Conference on Electrical, Electronics, Signals, Communication and Optimization Visakhapatnam, India:. IEEE, 2015: 1-5. [8] Zhao Jin, Ye Fei, Feng Yili.Seconductive Research on RC Based on RTP / RTCP [J]. China Cable TV, 2004 (1): 6-9 [9] Li Hua. Network Video Monitoring System Client Design and Implementation of Audio Software [D]. Wuhan: Huazhong University of Science and Technology, 2007. [10] Guo Fang, Zhang Jiashu. H.265 Safety and Efficient Index Columbus Code Scheme [J]. Computer Application & Software, 2013, 30 (10): 85-86 [11] JI Qiujia, Yu Hewei, Chen Haihao. A Smart Android Based Remote Monitoring System [C] // Proceedings of The 3rd International Conference ON Technolo Gical Advances in Electrical, Electronics and Computer Engineering. Beirut, Lebanon: IEEE, 2015: 181-184. "
Our other product: