Search

CN-115623246-B - Video optimization method, playing device, gateway device, storage medium and system

CN115623246BCN 115623246 BCN115623246 BCN 115623246BCN-115623246-B

Abstract

The embodiment of the application discloses a video optimization method, a playing device, a gateway device, a storage medium and a system, wherein the method comprises the steps of determining video parameter data corresponding to a current video stream; and sending the target resolution to the gateway equipment so that the resolution of the video stream to be transmitted, which is sent by the gateway equipment in the last receiving service equipment, is the target resolution. Therefore, after the target resolution is sent to the gateway equipment, the resolution of the video stream to be transmitted subsequently can be the target resolution, and the software development kit SDK is integrated in the playing equipment, so that the resolution of the video stream can be dynamically adjusted based on the video parameter data, the video clamping phenomenon caused by poor network conditions is effectively relieved, the dynamic adjustment of the resolution can be more accurate and reasonable, and the video quality is improved.

Inventors

  • JIANG XIAO
  • LI FENG
  • CHEN WEI
  • TONG CHAO
  • CHENG JIAN

Assignees

  • 中移(杭州)信息技术有限公司
  • 中国移动通信集团有限公司

Dates

Publication Date
20260505
Application Date
20210712

Claims (11)

  1. 1. A video optimization method, applied to a playback device, the method comprising: determining video parameter data corresponding to a current video stream, wherein the video parameter data comprises video resolution, video frame number, packet loss rate, buffer data length and network bandwidth; Determining a first resolution according to the number of video frames and the network bandwidth; performing weighted calculation on the video resolution, the packet loss rate, the buffer data length and the first resolution to obtain a second resolution; Comparing the second resolution with a candidate resolution set, and determining a target resolution according to a comparison result, wherein the candidate resolution set is composed of at least one candidate resolution supported by the current video stream; and sending the target resolution to gateway equipment so that the resolution of the video stream to be transmitted, which is sent by the gateway equipment in the last receiving service equipment, is the target resolution.
  2. 2. The method of claim 1, wherein the step of determining the position of the substrate comprises, After determining the video parameter data corresponding to the current video stream, the method further comprises: And sending the video parameter data to the gateway equipment so that the gateway equipment performs video optimization on the video stream to be transmitted.
  3. 3. The method of claim 1, wherein determining the target resolution based on the comparison result comprises: selecting a candidate resolution less than or equal to the second resolution from the at least one candidate resolution according to the comparison result; And selecting the maximum resolution from the selected candidate resolutions, and determining the maximum resolution as the target resolution.
  4. 4. The method according to claim 1, wherein the method further comprises: obtaining the maximum resolution supported by the playing equipment; calculating the ratio of the maximum resolution supported by the playing equipment to the video resolution corresponding to the current video stream, and determining a first ratio; if the first ratio is larger than a preset superdivision threshold, performing super-resolution processing on the current video stream to obtain a processed video stream, and playing the processed video stream; and if the first ratio is smaller than or equal to a preset superdivision threshold value, playing the current video stream.
  5. 5. The method according to claim 1, wherein the method further comprises: Message detection is carried out on the current video stream based on a preset detection strategy, and a detection result is obtained; If the detection result indicates that the current video stream has a missing message, judging whether the missing message is received within a first preset time; If the missing message is not received within the first preset time, sending a packet loss retransmission request to the gateway equipment; And receiving the missing message returned by the gateway equipment.
  6. 6. The method of claim 5, wherein the performing packet detection on the current video stream based on a preset detection policy to obtain a detection result includes: Detecting the continuity of the message sequence number of the current video stream, and determining whether the sequence number jump occurs to the message sequence number; If the sequence number jump occurs to the message sequence number, determining that the current video stream has a missing message; And if the sequence number of the message does not jump, determining that the current video stream does not have the missing message.
  7. 7. The method of claim 6, wherein after said receiving said missing message returned by said gateway device, said method further comprises: if the received sequence number of the missing message is determined to be wrong, continuing to execute the step of sending a packet loss retransmission request to the gateway equipment.
  8. 8. A playback apparatus, characterized in that the playback apparatus comprises a first determination unit and a first transmission unit, wherein, The first determining unit is configured to determine video parameter data corresponding to a current video stream, wherein the video parameter data comprises video resolution, video frame number, packet loss rate, buffer data length and network bandwidth, determine a first resolution according to the video frame number and the network bandwidth, perform weighted calculation on the video resolution, the packet loss rate, the buffer data length and the first resolution to obtain a second resolution, compare the second resolution with a candidate resolution set, and determine a target resolution according to a comparison result, wherein the candidate resolution set is composed of at least one candidate resolution supported by the current video stream; the sending unit is configured to send the target resolution to the gateway device, so that the resolution of the video stream to be transmitted, which is sent by the gateway device at the last time of receiving the service device, is the target resolution.
  9. 9. A playback device, characterized in that the playback device comprises a first memory and a first processor, wherein, The first memory is used for storing a computer program capable of running on the first processor; The first processor being configured to perform the video optimization method of any one of claims 1 to 7 when the computer program is run.
  10. 10. A computer storage medium storing a computer program which, when executed by a first processor, implements the video optimization method of any one of claims 1 to 7.
  11. 11. A video optimization system, characterized in that it comprises a playback device as claimed in claim 8 or 9, and a service device.

Description

Video optimization method, playing device, gateway device, storage medium and system Technical Field The present application relates to the field of video processing technologies, and in particular, to a video optimization method, a playback device, a gateway device, a storage medium, and a system. Background When video is transmitted from a server to a playing device, the video is often easily affected by a network environment, and when the network condition is poor, the video is easily blocked so as to affect the watching experience. Currently, in the related art, when the network condition is poor, the video code rate is reduced to solve the problem of blocking, and for the playing device such as a large-screen television, the definition of the low-code rate video is poor, which results in poor viewing experience. In addition, when the network repeatedly fluctuates, the frequent switching code rate also causes the video experience to be reduced, and because the variety of playing equipment (including a set top box, a television, a mobile phone, a tablet personal computer and the like) is numerous, if a unified video optimization scheme is to be realized, the development workload is extremely high. Disclosure of Invention The application provides a video optimization method, a playing device, a gateway device, a storage medium and a system, which can effectively relieve the video clamping phenomenon caused by the network problem and can also improve the video quality. The technical scheme of the application is realized as follows: in a first aspect, an embodiment of the present application provides a video optimization method, applied to a playback device, where the method includes: determining video parameter data corresponding to a current video stream; Performing resolution calculation according to the video parameter data, and determining target resolution; and sending the target resolution to gateway equipment so that the resolution of the video stream to be transmitted, which is sent by the gateway equipment in the last receiving service equipment, is the target resolution. In a second aspect, an embodiment of the present application further provides a video optimization method, applied to a gateway device, where the method includes: receiving video parameter data sent by playing equipment; determining a frame number threshold according to the video parameter data; Receiving a video stream to be transmitted sent by a service device, and carrying out optimization processing on the video stream to be transmitted by utilizing the frame number threshold value to obtain an optimized video stream to be transmitted; and sending the optimized video stream to be transmitted to the playing device. In a third aspect, an embodiment of the present application further provides a playback apparatus, where the playback apparatus includes a first determination unit and a first transmission unit, where, The first determining unit is configured to determine video parameter data corresponding to the current video stream, and perform resolution calculation according to the video parameter data to determine a target resolution; the sending unit is configured to send the target resolution to the gateway device, so that the resolution of the video stream to be transmitted, which is sent by the gateway device at the last time of receiving the service device, is the target resolution. In a fourth aspect, the embodiment of the present application further provides a gateway device, where the gateway device includes a second receiving unit, a second determining unit and a second transmitting unit, where, The second receiving unit is configured to receive video parameter data sent by the playing device; The second determining unit is configured to determine a frame number threshold according to the video parameter data; the second receiving unit is further configured to receive a video stream to be transmitted sent by the service equipment; the second determining unit is further configured to perform optimization processing on the video stream to be transmitted by using the frame number threshold value to obtain an optimized video stream to be transmitted; The second sending unit is configured to send the optimized video stream to be transmitted to the playing device. In a fifth aspect, embodiments of the present application also provide another playback device, where the playback device includes a first memory and a first processor, where, The first memory is used for storing a computer program capable of running on the first processor; The first processor is configured to execute the video optimization method according to the first aspect when the computer program is executed. In a sixth aspect, the present embodiment further provides another gateway device, where the gateway device includes a second memory and a second processor, where, The second memory is used for storing a computer program capable of running on the second