Video stream code rate adjusting method and device, computer device and storage medium

By detecting network status and progressively adjusting video frame redundancy, adaptive adjustment of video stream bitrate is achieved, solving the problem of poor accuracy in manual adjustment by users in existing technologies, and improving the accuracy of bitrate adjustment and user experience.

CN117014608BActive Publication Date: 2026-11-24TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202211091363.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-07
Publication Date
2026-11-24
Estimated Expiration
2042-09-07

AI Technical Summary

Technical Problem

The existing video stream bitrate switching method requires users to manually try multiple times, and the accuracy of the adjustment is difficult to guarantee, which cannot meet the needs of low-latency scenarios such as live streaming.

Method used

By detecting network status, the redundancy of video frames is gradually adjusted multiple times until the adjusted bitrate matches the target bitrate, avoiding blindly increasing the bitrate and causing stuttering. An adaptive bitrate adjustment method is adopted.

Benefits of technology

Significantly improves the accuracy of bitrate adjustment, reduces live streaming latency, enhances user experience, and avoids adverse effects caused by repeated bitrate switching.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117014608B_ABST
    Figure CN117014608B_ABST
Patent Text Reader

Abstract

This application discloses a video stream bitrate adjustment method, apparatus, computer equipment, storage medium, and computer program product, which can be applied in cloud-based content delivery networks to achieve adaptive adjustment of video streams. The method includes: responding to a playback request initiated by a terminal, transmitting a video stream to the terminal via a transmission link; during the playback of the video stream on the terminal, when the network status of the transmission link determines that bitrate adjustment is necessary, progressively adjusting the redundancy of the video frames transmitted to the terminal multiple times until the bitrate corresponding to the adjusted video frames matches the target bitrate; if the network status of the transmission link meets the network smoothness conditions during the multiple progressive adjustments, then converting the video stream to the target bitrate before transmitting it to the terminal. This method can accurately adjust the video stream bitrate.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of streaming media technology, and in particular to a video stream bitrate adjustment method, apparatus, computer equipment, storage medium, and computer program product. Background Technology

[0002] Currently, when a client starts playing a video stream, it defaults to selecting a video bitrate, usually the original bitrate of the video stream. If playback stutters during the video stream, the user needs to manually select a lower bitrate to switch to smoother playback. Similarly, if the user wants to watch a higher quality video, they also need to manually select a higher bitrate.

[0003] The current method of switching video stream bitrates requires users to make multiple attempts. The effect of video playback (such as stuttering) after each attempt to switch the bitrate is unpredictable, and the accuracy of bitrate adjustment is difficult to guarantee. Summary of the Invention

[0004] Therefore, it is necessary to provide a video stream bitrate adjustment method, apparatus, computer equipment, computer-readable storage medium, and computer program product that can improve the accuracy of bitrate adjustment in response to the above-mentioned technical problems.

[0005] On one hand, this application provides a method for adjusting the bitrate of a video stream. The method includes:

[0006] In response to a playback request initiated by the terminal, a video stream is transmitted to the terminal via a transmission link;

[0007] During the playback of the video stream on the terminal, when it is determined that bitrate adjustment is needed based on the network status of the transmission link, the redundancy of the video frames transmitted to the terminal is adjusted gradually multiple times until the bitrate corresponding to the adjusted video frame matches the target bitrate.

[0008] If the network status of the transmission link meets the network smoothness conditions during multiple progressive adjustments, the video stream is converted to the target bitrate and then transmitted to the terminal.

[0009] On the other hand, this application also provides a video stream bitrate adjustment device. The device includes:

[0010] The response module is used to respond to a playback request initiated by the terminal and transmit a video stream to the terminal via the transmission link;

[0011] The adjustment module is used to, during the playback of the video stream on the terminal, when it is determined based on the network status of the transmission link that bitrate adjustment is required, progressively adjust the redundancy of the video frames transmitted to the terminal multiple times until the bitrate corresponding to the adjusted video frame matches the target bitrate and then stops.

[0012] The transmission module is used to convert the video stream into a target bitrate and transmit it to the terminal when the network status of the transmission link meets the network smoothness conditions during multiple progressive adjustments.

[0013] In some embodiments, the response module is further configured to respond to a playback request initiated by the terminal, and based on the playback bitrate carried in the playback request, obtain a video stream with a playback bitrate obtained by transcoding the video stream with the original bitrate; wherein, the playback bitrate is a preset bitrate corresponding to any level in the preset bitrate levels; and transmit the video stream with the playback bitrate to the terminal through the transmission link.

[0014] In some embodiments, the response module is further configured to transcode the original bitrate video stream to obtain a playback bitrate video stream by adjusting the encoding parameters of the video stream; or, to send a request to the transcoding server to receive the playback bitrate video stream transcoded by the transcoding server.

[0015] In some embodiments, the device further includes a first detection module, configured to receive a feedback message sent by the terminal during the playback of a video stream on the terminal; the feedback message carries network status information; the feedback message is parsed and the network status information of the transmission link is extracted, and the network status of the transmission link is determined based on the network status information to determine whether bitrate adjustment is required.

[0016] In some embodiments, the apparatus further includes a second detection module, configured to determine that bitrate adjustment is required when a bitrate adjustment request is received from a terminal; wherein the bitrate adjustment request is generated by the terminal detecting network status information during the playback of the video stream and when the network status information is detected to meet the bitrate adjustment conditions.

[0017] In some embodiments, the adjustment module is further configured to, when it is determined based on the network status of the transmission link that the bitrate needs to be increased, start from the first keyframe in the untransmitted video stream, determine multiple video frames including the first keyframe and several video frames after the first keyframe; adjust the redundancy coding parameters of each video frame in the multiple video frames to improve the redundancy of the multiple video frames, and send the multiple video frames with adjusted redundancy coding parameters to the terminal; obtain the latest network status of the transmission link, and if the latest network status of the transmission link meets the network smoothness conditions, continue to increase the redundancy of the video frames in the untransmitted video stream until the bitrate corresponding to the video frames after multiple adjustments reaches the target bitrate and then stops.

[0018] In some embodiments, the apparatus further includes an exit module, configured to, during the process of progressively adjusting the redundancy of video frames, if at any moment the network status of the transmission link is detected to be unsatisfactory, stop adjusting the redundancy of video frames and exit the bitrate adjustment process, and control the bitrate of the video stream transmitted to the terminal to remain unchanged.

[0019] In some embodiments, the transmission module is further configured to, during multiple progressive adjustments, if the number of times the network status of the transmission link meets the network smoothness condition is higher than the number of times the network smoothness condition is not met, then convert the video stream to the target bitrate and transmit it to the terminal; or, during multiple progressive adjustments, if the number of times the network status of the transmission link meets the network smoothness condition reaches a preset threshold, then convert the video stream to the target bitrate and transmit it to the terminal.

[0020] In some embodiments, the apparatus further includes a first down-adjustment module, configured to, when it is determined based on the network status of the transmission link that a down-adjustment of the bitrate is required, adjust the bitrate transmitted to the video stream level by level from a preset multiple bitrate levels, starting from a bitrate level one level lower than the current playback bitrate, until the network status information of the transmission link meets the network smoothness condition, at which point the bitrate adjustment stops; when the network status information of the transmission link meets the network smoothness condition, the adjusted bitrate is determined as the target bitrate, and the video stream is converted to the target bitrate before being transmitted to the terminal.

[0021] In some embodiments, the apparatus further includes a second down-rate module, configured to, when it is determined based on the network status of the transmission link that a down-rate needs to be reduced, determine the highest supported bitrate level among a plurality of preset bitrate levels based on the network status of the transmission link; and transmit the video stream to the terminal after converting it to the highest bitrate level.

[0022] In some embodiments, the transmission module is further configured to acquire a video stream with a target bitrate and determine a first keyframe after the current moment in the video stream with the target bitrate; in the currently transmitted video stream with a playback bitrate, search for a second keyframe with the same timestamp as the first keyframe; if a second keyframe with the same timestamp exists, continue transmitting the video stream with the playback bitrate to the terminal until the second keyframe is reached, and then transmit the video stream with the target bitrate that includes the first keyframe to the terminal.

[0023] On the other hand, this application also provides a computer device. The computer device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the steps of the video stream bitrate adjustment method described above.

[0024] On the other hand, this application also provides a computer-readable storage medium. The computer-readable storage medium stores a computer program thereon, which, when executed by a processor, implements the steps of the above-described video stream bitrate adjustment method.

[0025] On the other hand, this application also provides a computer program product. The computer program product includes a computer program that, when executed by a processor, implements the steps of the video stream bitrate adjustment method described above.

[0026] The aforementioned video stream bitrate adjustment method, apparatus, computer equipment, storage medium, and computer program product, in response to a playback request initiated by a terminal, transmit a video stream to the terminal via a transmission link. During the playback of the video stream on the terminal, the network status of the transmission link is detected. When the network status determines that bitrate adjustment is necessary, the bitrate is adjusted by progressively adjusting the redundancy of video frames multiple times until the bitrate corresponding to the adjusted video frames matches the target bitrate. Thus, by adaptively adjusting the stream bitrate based on the detected network environment, service quality can be improved under limited network conditions, and the user experience for viewers can be greatly enhanced. Furthermore, the network status is checked during this process to ensure network smoothness. If network smoothness is maintained during the progressive redundancy adjustment, the video stream is then converted to the target bitrate and transmitted to the terminal, avoiding stuttering caused by blindly increasing the bitrate and avoiding repeated bitrate switching, significantly improving the accuracy of bitrate adjustment. Attached Figure Description

[0027] Figure 1 This is a diagram illustrating the application environment of a video stream bitrate adjustment method in one embodiment.

[0028] Figure 2 This is a diagram illustrating the application environment of the video stream bitrate adjustment method in another embodiment;

[0029] Figure 3 This is a flowchart illustrating a video stream bitrate adjustment method in one embodiment;

[0030] Figure 4 This is a schematic diagram illustrating the principle of timestamp alignment in one embodiment;

[0031] Figure 5 This is a schematic diagram of the overall architecture in one embodiment;

[0032] Figure 6 This is a schematic diagram of the overall architecture in another embodiment;

[0033] Figure 7 This is a schematic diagram of the pre-rate boosting process in one embodiment;

[0034] Figure 8 This is a schematic diagram of the client interface in one embodiment;

[0035] Figure 9 This is a schematic diagram of the client interface in another embodiment;

[0036] Figure 10 This is a structural block diagram of a video stream bitrate adjustment device in one embodiment;

[0037] Figure 11 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0038] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0039] Related technologies, such as Dash (Dynamic Adaptive Streaming over HTTP) and HLS (HTTP Live Streaming), all rely on slicing media data for bitrate switching. Each media slice is a GOP (Group of Pictures, a complete sequence of decodable video frames) as its smallest unit. When the video stream begins, the client first requests and downloads a media file from the server. This media file includes a list of slices and detailed information about each slice. The client parses this media file to obtain the video stream's slice information, selects the appropriate slice for the current situation, extracts the slice's address, and uses that address to request the corresponding data stream from the server. However, slice-based bitrate switching suffers from significant latency, failing to meet the high latency requirements of current live streaming and other similar scenarios.

[0040] In view of this, embodiments of this application provide a video stream bitrate adjustment method. By adopting an adaptive bitrate adjustment method similar to live streaming, it significantly reduces live streaming latency and improves real-time performance. This method detects network conditions and pre-increases the bitrate when network conditions permit. It then uses network condition feedback to determine whether to increase the bitrate, avoiding stuttering caused by blindly increasing the bitrate, which leads to a poor user experience. It also avoids repeatedly switching bitrates, significantly improving the accuracy of bitrate adjustment.

[0041] The video stream bitrate adjustment method provided in this application embodiment can be applied to, for example, Figure 1In the application environment shown, terminal 102 communicates with server 104 via a network. A data storage system can store the data that server 104 needs to process. The data storage system can be integrated onto server 104, or it can be located in the cloud or on another server. In response to a user's trigger operation, terminal 102 sends a playback request to server 104; server 104 responds to the playback request, acquires the video stream, and transmits it to terminal 102 via a transmission link. Terminal 102 acquires and plays the video stream in real time based on the transmission link. During the playback of the video stream by terminal 102, when the network status of the transmission link determines that bitrate adjustment is necessary, server 104 progressively adjusts the redundancy of the video frames transmitted to terminal 102 multiple times until the bitrate corresponding to the adjusted video frames matches the target bitrate. Simultaneously, during these progressive adjustments, if the network status of the transmission link meets the network smoothness requirements, server 104 converts the video stream to the target bitrate and transmits it to terminal 102.

[0042] The terminal 102 may be, but is not limited to, one or more of various desktop computers, laptops, smartphones, tablets, IoT devices, or portable wearable devices. IoT devices may be one or more of smart speakers, smart TVs, smart air conditioners, or smart in-vehicle devices. Portable wearable devices may be one or more of smartwatches, smart bracelets, or head-mounted devices.

[0043] In some embodiments, the terminal may have an application (APP) or an application with video playback capabilities installed, including traditional applications that require separate installation, and mini-program applications that can be used without downloading and installation, such as one or more of browser clients, web clients, or standalone APP clients. The terminal can obtain and play the video stream transmitted from the server through the application, such as watching videos or live streams. The terminal can manually switch the bitrate through the application, or it can select adaptive bitrate and have the server perform the bitrate switching.

[0044] Among them, server 104 can be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms.

[0045] Content Delivery Network (CDN) technology is a method that distributes content from a central server to edge servers closer to users, thereby enabling distributed, proximity-based access to content. CDN technology effectively improves the quality of service for content access and supports large-scale concurrent access capabilities.

[0046] In some embodiments, the application environment to which this application can be applied may be as follows: Figure 2 As shown, the system includes a capture terminal 202 for capturing video streams, a content delivery network (CDN), and a client 102 for playing the video streams. The CDN is a network architecture provided by a server cluster or distributed system consisting of multiple content delivery servers. The content delivery servers in the CDN can establish communication connections with each other to achieve data interaction. The capture terminal 202 captures the video stream and pushes it to the content delivery server. The content delivery server caches the video stream and forwards it to one or more terminals 102. The capture terminal can be a terminal used to capture video streams. The CDN may also include an origin server. The origin server can be used to store the raw video streams captured by the capture terminal. When the content delivery server has not cached video stream resources or the cached video stream resources have expired, the content delivery server can retrieve resources from the origin server to return the acquired video stream to the terminal.

[0047] In some embodiments, the content delivery network architecture may further include a transcoding server. The transcoding server can be a server cluster consisting of multiple content delivery servers or any server in a distributed system, and can be used to transcode the original bitrate video stream to produce multiple video streams of different resolutions. In another embodiment, the transcoding function can also be integrated into the content delivery server to perform transcoding processing on the video stream through transcoding services provided by itself or other content delivery servers.

[0048] In some embodiments, such as Figure 3 As shown, a video stream bitrate adjustment method is provided, which can be applied to... Figure 1 Taking a server as an example, this method can be a content delivery server. The method includes the following steps:

[0049] In step S302, in response to the playback request initiated by the terminal, the video stream is transmitted to the terminal through the transmission link.

[0050] This application's embodiments can be applied to scenarios such as video playback and live streaming. In a video playback scenario, the terminal sends a playback request to the server. The server parses the playback request to obtain the corresponding video and transmits the video to the terminal for playback. In a live streaming scenario, the acquisition end acquires the raw video stream and uploads it to a content delivery network. The content delivery server caches the stream and distributes it to various terminals, which then play the video stream through their clients.

[0051] In some embodiments, the client pre-sets multiple bitrate levels, each corresponding to a specific bitrate. Different bitrate levels correspond to different video resolutions. For example, bitrate levels include, but are not limited to, 360Kbps, 550Kbps, 1200Kbps, or 2000Kbps, with corresponding video resolutions such as smooth, standard definition, high definition, or 2K.

[0052] Specifically, the terminal generates a playback request in response to the user's trigger operation and sends the playback request to the server. After receiving the playback request from the terminal, the server sends the corresponding video stream to the terminal. In a live streaming scenario, the server can establish a transmission link with the terminal to transmit the video stream to the terminal through this transmission link; on the other hand, the server parses the playback request to determine the specific video or video stream requested for playback and transmits that specific video or video stream to the terminal.

[0053] Taking live streaming as an example, after the server and the terminal establish a transmission link, the server can continuously transmit video streams to the terminal, and the terminal can watch the live content in real time.

[0054] In this context, the transmission link refers to the data transmission channel established between the terminal and the server. This transmission link enables the streaming and distribution of video streams, as well as the uploading of requests and the feedback of results after request execution. In some embodiments, the transmission link includes at least a streaming media channel and a signaling channel. The streaming media channel is used to transmit the media data of the video stream, while the signaling channel is used to transmit requests and responses between the terminal and the server.

[0055] The playback request must include at least the source identifier of the requested video stream. This source identifier identifies the specific video stream and distinguishes it from other video streams. The source identifier can be represented using one or more methods, such as an address link or string encoding. However, it is not limited to these methods. For example, the playback request may also include the playback bitrate, which can be one of the following: the bitrate set by the client installed on the terminal each time a video stream is started; the bitrate when the user last watched a video or live stream through the client; or the bitrate selected by the user for this playback. The playback bitrate can be the bitrate corresponding to a specific bitrate level from a set of preset bitrate levels.

[0056] Accordingly, in some embodiments, after receiving a playback request from a terminal, the server parses the playback request to obtain the playback bitrate it carries, acquires the video stream at that playback bitrate, and transmits the video stream at that playback bitrate to the terminal for playback. The video stream at the playback bitrate can be obtained by transcoding an original video stream with the original bitrate.

[0057] Step S304: During the playback of the video stream on the terminal, when it is determined that bitrate adjustment is needed based on the network status of the transmission link, the redundancy of the video frames transmitted to the terminal is adjusted gradually multiple times until the bitrate corresponding to the adjusted video frame matches the target bitrate.

[0058] During video streaming on the terminal, the terminal or server can detect the network status of the transmission link at a certain frequency to determine whether bitrate adjustment is needed. Bitrate adjustment includes, but is not limited to, increasing the bitrate, maintaining the bitrate, or decreasing the bitrate. The detection frequency can be set according to actual needs, and is not limited in this embodiment. The network status can be determined based on one or more of the following: transmission link speed, bandwidth, latency, latency-bandwidth product, packet loss rate, or throughput.

[0059] In some embodiments, if there are no stutters or dropped frames during the playback of a video stream at the specified bitrate via a client, the current network condition can be considered good. A good network condition can be one where the video stream can be played stably at the specified bitrate (i.e., increasing the bitrate might lead to network instability and stuttering), or it can be one where increasing the bitrate still ensures smooth video playback (i.e., the network has sufficient capacity to accommodate higher bitrate video streams). Therefore, when the current network condition is good, it can be determined that the bitrate of subsequent transmitted video streams needs to be increased to provide the best Quality of Service (QoS) within the network's capabilities and significantly improve the viewer's Quality of Experience (QoE).

[0060] In another embodiment, if stuttering or frame drops occur during the playback of a video stream at a specified bitrate via a client on the terminal, it indicates that the current network conditions are poor and the bitrate that the transmission link can accommodate is limited. Therefore, given the current limited network conditions, it can be determined that the bitrate of subsequent transmitted video streams needs to be reduced to eliminate stuttering and thus ensure the viewer's user experience.

[0061] In some embodiments, the terminal detects the network status of the transmission link during video stream playback. Accordingly, when the terminal determines that bitrate adjustment is needed based on the network status of the transmission link, the terminal sends a request to the server to instruct the server to perform the video stream bitrate adjustment step.

[0062] In another embodiment, during the playback of the video stream on the terminal, the server detects the network status of the transmission link. Accordingly, when the server determines that bitrate adjustment is needed based on the network status of the transmission link, it automatically executes the video stream bitrate adjustment step.

[0063] Specifically, during video streaming on the terminal, when the network status of the transmission link determines that bitrate adjustment is necessary, the server attempts to pre-increase the bitrate by adjusting the redundancy of the video frames transmitted to the terminal, and obtains information on changes in the network status of the transmission link, such as through terminal detection, server feedback received from the terminal, or direct detection by the server. If the network status remains good, the redundancy of the video frames is adjusted again, and the network status changes are obtained again... This process of gradually adjusting redundancy is repeated until the bitrate corresponding to the adjusted video frames matches the desired bitrate (called the target bitrate), at which point the bitrate adjustment process stops.

[0064] The target bitrate is the bitrate corresponding to any one of a preset set of bitrate levels. The target bitrate can be one level higher (or lower) than the current playback bitrate, or two or more levels higher (or lower). For example, assuming the current playback bitrate is 550Kbps (corresponding to standard definition), the target bitrate could be 1200Kbps or 2000Kbps when increasing the bitrate, and 480Kbps or 360Kbps when decreasing the bitrate.

[0065] The redundancy of a video frame is directly related to its bitrate. For example, a raw video frame requires 800 raw packets to transmit, corresponding to bitrate A. Adding 600 redundant packets results in bitrate B, and adding 1000 redundant packets results in bitrate C (where A < B < C). Using bitrate adjustments as an example, the redundancy of the video frame is gradually increased. After each adjustment, the network status is checked to ensure the transmission link can withstand the corresponding bitrate before further increases are made… until the bitrate of the video frame reaches the target bitrate after a certain adjustment.

[0066] In some embodiments, the server can increase the redundancy of video frames through redundancy coding to detect changes in network status caused by changes in bitrate. Redundancy coding methods include, but are not limited to, FEC (Forward Error Correction) redundancy coding. FEC redundancy coding methods include, but are not limited to, one or more of Hamming coding, RS (Reed-solomon codes), and convolutional codes. For example, the server can introduce redundant packets when compressing video frames and encapsulate the original data packets corresponding to the video frame together with the redundant packets into a message for transmission. By adjusting the number of redundant packets, the redundancy of the video frame can be adjusted. Taking RS coding as an example, if the original data packets corresponding to a video frame are k, the server can generate m redundant packets and use a k*m transformation matrix (such as a VanderMont matrix) to obtain FEC data containing redundant data.

[0067] To avoid the sudden impact on the network caused by a sudden increase in bitrate, and to prevent the transmission link from being unable to handle the increased bitrate and causing stuttering during video playback on the terminal, the bitrate adjustment process between each adjacent bitrate level is performed gradually in multiple adjustments. In some embodiments, the redundancy level of each adjustment can be the same, for example, adding 500 redundant packets each time, or increasing the redundancy by 20% each time. Alternatively, the redundancy level of each adjustment can be different, for example, adding 100 redundant packets the first time, 300 redundant packets the second time, and so on, or increasing by 10% the first time, and 20% the second time, etc. When the redundancy level of each adjustment is different, the redundancy level of the server can change regularly, such as through arithmetic or geometric progression; or it can change irregularly, for example, the server can adjust the redundancy level in real time based on network conditions, and so on.

[0068] In some embodiments, when the network condition of the transmission link determines that a bitrate reduction is necessary, it indicates that the current network condition is already limited. Therefore, instead of making multiple adjustments gradually between adjacent bitrate levels, one or more preset bitrate levels can be directly reduced. For example, the server can reduce the bitrate by one level, and if the network condition is still poor, it can reduce it by another level, and so on, until the target bitrate is reached. It should be noted that during gradual adjustments, the server does not change the original actual bitrate of the video stream; rather, it indirectly achieves the required bitrate through redundancy.

[0069] In step S306, if the network status of the transmission link meets the network smoothness conditions during multiple progressive adjustments, the video stream is converted into the target bitrate and transmitted to the terminal.

[0070] In some embodiments, during the process of progressively adjusting the redundancy of video frames, if the network status of the transmission link meets the network smoothness requirements after each adjustment, the server converts the subsequently transmitted video stream to the target bitrate, timestamps the target bitrate video stream and aligns its timestamp with the playback bitrate video stream to complete the media splicing process, and then transmits the video stream to the terminal at the target bitrate, thereby achieving a smooth and seamless switch from the original bitrate to the target bitrate. Alternatively, after determining that the bitrate has been adjusted to the target bitrate, the server pulls the stream from the source station to obtain the target bitrate video stream and timestamps it, thereby achieving the bitrate switch.

[0071] In some embodiments, during multiple progressive adjustments, if the number of times the network status of the transmission link meets the network smoothness condition is higher than the number of times the network smoothness condition is not met, the server may convert the video stream to the target bitrate and transmit it to the terminal.

[0072] In some embodiments, during multiple gradual adjustments, the server may convert the video stream to the target bitrate and transmit it to the terminal if the number of times the network status of the transmission link meets the network smoothness condition reaches a preset threshold.

[0073] In the aforementioned video stream bitrate adjustment method, a video stream is transmitted to the terminal via a transmission link in response to a playback request initiated by the terminal. During video stream playback, the network status of the transmission link is monitored. When the network status determines that bitrate adjustment is necessary, the bitrate is adjusted by progressively increasing the redundancy of video frames until the bitrate of the adjusted video frames matches the target bitrate. Thus, by adaptively adjusting the stream bitrate based on the detected network environment, service quality can be improved under limited network conditions, significantly enhancing the viewer's user experience. Furthermore, the network status is checked to ensure smooth network operation. If smooth network operation is maintained during the progressive redundancy adjustment process, the video stream is converted to the target bitrate before being transmitted to the terminal. This avoids stuttering caused by blindly increasing the bitrate and avoids repeated bitrate switching, significantly improving the accuracy of bitrate adjustment.

[0074] On the other hand, by moving the stream switching and concatenation steps to the server, end-to-end latency can be reduced, lowering the outgoing streaming costs for both the client and server. Simultaneously, it avoids the significant bandwidth consumption that would occur when the client performs stream switching, as it would need to pull a new bitrate video stream while maintaining the original bitrate. Furthermore, in poor network conditions, client-side stream switching can easily exacerbate stuttering, impacting the playback experience. In the video stream bitrate adjustment method of this application embodiment, the stream switching and concatenation actions are performed by the server, avoiding the sudden increase in bandwidth consumption caused by pulling two streams simultaneously during switching, reducing the probability of stuttering during stream switching, and saving bandwidth costs.

[0075] In some embodiments, in response to a playback request initiated by a terminal, transmitting a video stream to the terminal via a transmission link includes: in response to a playback request initiated by a terminal, obtaining a video stream with a playback bitrate obtained by transcoding the original bitrate video stream based on the playback bitrate carried in the playback request; wherein the playback bitrate is a preset bitrate corresponding to any level in the preset bitrate levels; and transmitting the video stream with the playback bitrate to the terminal via the transmission link.

[0076] Specifically, the acquisition end captures the raw video stream and sends it to the server. Taking a live streaming scenario as an example, when the broadcaster starts the live stream, the raw video stream at its original bitrate is pushed to the content delivery network (CDN). The CDN's content delivery servers can perform caching and other processing. When a user wants to watch the video, they can trigger a playback request through the client. The corresponding terminal then sends a playback request to the CDN to request the stream to be pulled. That is, in response to the user's trigger operation, the terminal obtains the playback bitrate of the video stream to be played and encapsulates this bitrate into a message to generate a playback request.

[0077] After parsing the playback request, the server obtains the video stream at the specified playback bitrate based on the bitrate carried in the request. The server can obtain the video stream at the playback bitrate by transcoding the original bitrate video stream, including: transcoding the original bitrate video stream itself; pulling the stream from the origin server; or requesting transcoding from a transcoding server, which then transcodes the original bitrate video stream.

[0078] In the above embodiments, when the terminal requests to play a video stream, the video stream at the corresponding bitrate is obtained based on the playback bitrate required by the terminal and transmitted to the terminal. The playback bitrate is one of the preset bitrate levels, and the relevant encoding parameters have been set in advance, thereby enabling rapid transcoding and transmission with a fast response speed.

[0079] In some embodiments, obtaining a video stream with a playback bitrate obtained by transcoding a video stream with the original bitrate includes: transcoding a video stream with the original bitrate to obtain a video stream with a playback bitrate by adjusting the encoding parameters of the video stream; or, sending a request to a transcoding server to receive a video stream with a playback bitrate obtained by transcoding the video stream with the transcoding server.

[0080] Specifically, when the server performs transcoding, the transcoding process includes: during the encoding and decoding of the video stream, the server adjusts the encoding parameters of the video frames in the video stream to transcode the original bitrate video stream into a playback bitrate video stream. The encoding parameters include, but are not limited to, one or more of video resolution or bitrate. Specific encoding methods include, but are not limited to, H.264 / H.265 (video compression coding standards) and other video encoding methods.

[0081] Alternatively, the server can send a request to the transcoding server, which will then transcode the original bitrate video stream and return the transcoded video stream at the desired playback bitrate to the server.

[0082] In the above embodiments, the video stream is transcoded by a server or transcoding server to quickly obtain a video stream with the corresponding bitrate. The most suitable bitrate can be selected based on network conditions to balance playback smoothness and picture quality.

[0083] The network status of the transmission link can be detected by the terminal or server. Taking the terminal detecting the network status of the transmission link as an example, in some embodiments, the method of determining whether bitrate adjustment is needed based on the network status of the transmission link includes: receiving a feedback message sent by the terminal during the playback of the video stream; the feedback message carrying network status information; parsing the feedback message and extracting the network status information of the transmission link, and determining the network status of the transmission link based on the network status information to determine whether bitrate adjustment is needed.

[0084] Specifically, during video streaming on the terminal, the terminal detects the network status of the transmission link, obtains network status information, encapsulates this information into a feedback message, and sends it to the server. This network status information includes, but is not limited to, one or more of the following: RTP (Real-time Transport Protocol) message arrival time, packet loss rate, link bandwidth, or congestion signals. The feedback message can include, but is not limited to, messages that report RTP message arrival times (e.g., Transport-CC (Transport-wide Congestion Control) messages), messages reporting RTP packet reception statistics, I-frame request messages, or NACK (Negative Acknowledgements) messages, etc. These can be standard WebRTC (Web Real-Time Communications) RTCP (Real-time Control Protocol) messages or proprietary messages.

[0085] Therefore, the server receives the feedback message sent by the terminal, parses the feedback message and extracts the network status information of the transmission link, determines the network status of the transmission link based on the network status information, and thus determines whether a bitrate adjustment is needed.

[0086] For example, the server uses these feedback messages to assess the bandwidth capacity of the transmission link, thereby providing a decision for subsequent bitrate adjustments. The bandwidth capacity assessment methods include, but are not limited to, one or more of the following: standard WebRTC's GCC (Google Congestion Control) algorithm, BBR (Bottleneck Bandwidth and Round-trip Propagation Time) algorithm, or meta-reinforcement learning algorithms. The bandwidth capacity assessment results can be used to determine the optimal bitrate for adjustment. For instance, among several preset bitrate levels, the bitrate can be lowered by one or more levels, or raised by one or more levels, based on the bandwidth capacity assessment results.

[0087] In the above embodiments, by detecting the network status of the transmission link and determining whether bitrate adjustment is needed, the bitrate of the video stream can be adaptively adjusted according to the network conditions. While ensuring smooth viewing, the image quality can be adaptively improved, balancing image quality and smoothness, thus enhancing the viewing experience.

[0088] Taking the server's detection of the network status of the transmission link as an example, in some embodiments, the method of determining the need for bitrate adjustment based on the network status of the transmission link includes: when receiving a bitrate adjustment request sent by the terminal, it is determined that bitrate adjustment is needed; wherein, the bitrate adjustment request is generated by the terminal detecting network status information during the playback of the video stream, and when the network status information is detected to meet the bitrate adjustment conditions.

[0089] Specifically, during video streaming, the terminal detects the network status of the transmission link to obtain network status information. Based on whether the network status information meets the bitrate adjustment conditions, it determines whether bitrate adjustment is necessary. Bitrate adjustment conditions may include one or more of the following: bandwidth capacity mismatch with the current bitrate (e.g., too high or too low), packet loss, detection of congestion signals, or playback stuttering.

[0090] When a terminal determines that a bitrate adjustment is needed—for example, when it detects bandwidth limitations or playback stuttering—it sends a bitrate adjustment request to the server. This request may include the current playback bitrate. Upon receiving the request, the server can then determine that a bitrate adjustment is necessary.

[0091] For example, during video streaming, when the terminal senses limited network capacity or playback stuttering, it requests the server to reduce the bitrate via a signaling channel to improve the stuttering rate. This can be done by sending an HTTP (Hypertext Transfer Protocol) request or an RTCP request. When the terminal senses increased network capacity or playback stuttering has resolved, it requests the server to adjust the bitrate via the signaling channel to improve image quality.

[0092] In the above embodiments, the terminal detects the network status of the transmission link and sends a request to the server when the bitrate needs to be adjusted, instructing the server to adjust the bitrate. This allows the video stream bitrate to be adjusted adaptively according to network and playback conditions, improving picture quality while ensuring smooth viewing. It balances picture quality and smoothness, thus enhancing the viewing experience.

[0093] In some embodiments, when it is determined that bitrate adjustment is needed based on the network state of the transmission link, the redundancy of video frames transmitted to the terminal is adjusted progressively multiple times until the bitrate corresponding to the adjusted video frame matches the target bitrate. This includes: when it is determined that the bitrate needs to be increased based on the network state of the transmission link, starting from the first keyframe in the untransmitted video stream, determining multiple video frames, including the first keyframe and several video frames after the first keyframe; adjusting the redundancy coding parameters of each video frame in the multiple video frames to increase the redundancy of the multiple video frames, and sending the multiple video frames with adjusted redundancy coding parameters to the terminal; obtaining the latest network state of the transmission link, and if the latest network state of the transmission link meets the network smoothness conditions, continuing to increase the redundancy of video frames in the untransmitted video stream until the bitrate corresponding to the video frame after multiple adjustments reaches the target bitrate.

[0094] When it's determined that the bitrate needs to be increased, the server finds the first keyframe (I-frame) in the untransmitted video stream and identifies several subsequent frames starting from that keyframe. These keyframes and the subsequent frames constitute the multiple video frames for which redundancy needs to be increased. These frames are used to increase redundancy and detect the impact of bitrate changes on network conditions. To avoid stuttering, black screens, or other issues during video playback, the number of these video frames should be less than the size of a Group of Pictures (GOP). Typically, three to five video frames following the I-frame are selected for redundancy adjustment.

[0095] The server first increases the redundancy of each video frame by adjusting its redundancy coding parameters, and then sends these adjusted video frames to the terminal. Next, the server obtains the latest network status of the transmission link. Assuming that the increased redundancy still satisfies network smoothness requirements, the server continues to find the next keyframe, identify multiple video frames, and increase their redundancy... This process continues until the bitrate of the adjusted video frames reaches the target bitrate. The redundancy adjusted each time can be the same or different. Similarly, the number of video frames selected for each adjustment can also be the same or different.

[0096] For example, after reaching the target bitrate, the server can be observed for a decision period before it officially begins to increase the bitrate. A decision period is typically 3-5 RTTs (Round-Trip Time).

[0097] In the above embodiments, by gradually adjusting the redundancy of video frames multiple times and detecting the network status during each adjustment, the bitrate is officially increased only if the network status is still good during the pre-increase bitrate process. This avoids stuttering caused by blindly increasing the bitrate and avoids repeatedly switching the bitrate back and forth, thus greatly improving the accuracy of bitrate adjustment.

[0098] In some embodiments, the method further includes: during the process of progressively adjusting the redundancy of video frames, if at any time the network status of the transmission link is detected to be unsatisfactory, stopping the adjustment of the redundancy of video frames and exiting the bitrate adjustment process, and controlling the bitrate of the video stream transmitted to the terminal to remain unchanged.

[0099] Specifically, during the process of the server progressively adjusting the redundancy of video frames, after each adjustment, the server determines the latest network status of the transmission link based on the acquired network status information to ascertain the impact of the bitrate adjustment on the network status. If at any moment the network status of the transmission link (which can be detected by the client and parsed from feedback messages received by the server) is found to be unsatisfactory, the server stops adjusting the redundancy of the video frames and exits the bitrate adjustment process. At this point, the server maintains the same bitrate for the video stream transmitted to the terminal, keeping it at the previous playback bitrate.

[0100] In the above embodiments, during the process of gradually adjusting the redundancy of video frames, if the network status is detected as not meeting the network smoothness conditions, the bitrate adjustment process is exited, thereby maximizing the smoothness of video playback and improving the user's viewing experience.

[0101] In some embodiments, if the network state of the transmission link meets the network smoothness condition during multiple progressive adjustments, the video stream is converted to the target bitrate and transmitted to the terminal. This includes: if, during multiple progressive adjustments, the number of times the network state of the transmission link meets the network smoothness condition is higher than the number of times the network smoothness condition is not met, the video stream is converted to the target bitrate and transmitted to the terminal.

[0102] Specifically, during multiple incremental adjustments, the server checks the network status of the transmission link to ensure smooth network operation at each adjustment, either through self-monitoring or feedback messages sent from the terminal. If the number of times the network smoothness condition is met exceeds the number of times it is not, the server converts the video stream to the target bitrate before transmitting it to the terminal. For example, the server can pre-determine the total number of adjustments required to move from the current playback bitrate to the target bitrate, after setting redundancy for each adjustment. Throughout the adjustment process, the server determines the number of times the network smoothness condition is met and the number of times it is not after the adjustment, and based on this, determines whether to ultimately adjust to the target bitrate.

[0103] In another embodiment, during multiple gradual adjustments, if the server detects, through its own detection or feedback messages sent by the terminal, that the number of times the network status of the transmission link meets the network smoothness conditions reaches a preset threshold, then the video stream is converted to the target bitrate and transmitted to the terminal. For example, if the number of times the network smoothness conditions are met exceeds the preset value, it indicates that the network status can basically support the target bitrate, and then an attempt can be made to adjust to the target bitrate.

[0104] Therefore, by making multiple gradual adjustments, the percentage of times the network condition meets the smoothness requirements, or by comparing it with the threshold, determines whether to adjust to the target bitrate. If the network condition is met more often, it indicates that the failure to meet the network condition may be due to short-term network fluctuations. In this case, it is advisable to try adjusting to the target bitrate to provide a high-quality or smooth viewing experience.

[0105] Considering that when the network status of the transmission link determines that a reduction in bitrate is necessary, it indicates that the current network status is already limited. Therefore, instead of making multiple adjustments gradually between each two adjacent bitrate levels, one or more preset bitrate levels can be directly reduced. In some embodiments, during the playback of a video stream on the terminal, the method further includes: when the network status of the transmission link determines that a reduction in bitrate is necessary, starting from a bitrate level one level lower than the current playback bitrate among the preset bitrate levels, the bitrate transmitted to the video stream is adjusted level by level until the network status information of the transmission link meets the network smoothness condition, at which point the bitrate adjustment stops; when the network status information of the transmission link meets the network smoothness condition, the adjusted bitrate is determined as the target bitrate, and the video stream is converted to the target bitrate before being transmitted to the terminal.

[0106] Specifically, when the terminal or server determines that the bitrate needs to be lowered based on the network status of the transmission link, the server adjusts the bitrate step by step from a preset bitrate level, starting from a bitrate level one level lower than the current playback bitrate, until the network smoothness conditions are met.

[0107] For example, assuming the current playback bitrate is ultra-high definition (UHD), the server first tries to switch to high definition (HD). If switching to HD satisfies the network smoothness requirements, the adjustment stops, the HD bitrate is set as the target bitrate, and the UHD video stream is converted to an HD video stream and transmitted to the terminal. If, after switching to HD, the network conditions still do not meet the smoothness requirements, the server then switches back to standard definition (SD) to reconfirm whether the network smoothness requirements are met.

[0108] Therefore, by gradually reducing the bitrate, it is possible to meet the requirements of picture quality as much as possible while ensuring smooth playback, thereby improving the user's viewing experience.

[0109] In another embodiment, during the playback of a video stream on the terminal, the method further includes: when it is determined that the bitrate needs to be reduced based on the network status of the transmission link, determining the highest supported bitrate level among a preset number of bitrate levels based on the network status of the transmission link; and transmitting the video stream to the terminal after converting it to the highest bitrate level.

[0110] Specifically, when a terminal or server determines that the bitrate needs to be reduced based on the network status of the transmission link, the terminal or server performs calculations based on the network status information, such as calculating and evaluating the link bandwidth capacity, to determine the highest bitrate that can be supported under the current network conditions.

[0111] For example, the server assesses the link bandwidth capacity based on the network status and determines the highest standard definition bitrate it can currently support. If the video stream played by the terminal is in ultra-high definition (UHD) bitrate, the server will directly adjust to the standard definition bitrate and convert the UHD bitrate video stream to the standard definition bitrate before transmitting it to the terminal.

[0112] Therefore, by matching the most suitable bitrate level based on the network status and switching the bitrate, it is possible to quickly achieve adaptive bitrate adjustment under network fluctuations, avoid stuttering when switching bitrates, make users unaware of network fluctuations, and ensure the user's viewing experience.

[0113] In some embodiments, transmitting a video stream to a terminal after converting it to a target bitrate includes: acquiring a video stream at the target bitrate and determining a first keyframe after the current moment in the video stream at the target bitrate; searching for a second keyframe with the same timestamp as the first keyframe in the currently transmitted video stream at the playback bitrate; if a second keyframe with the same timestamp exists, continuing to transmit the video stream at the playback bitrate to the terminal until the second keyframe is reached, and transmitting the video stream at the target bitrate, including the first keyframe, to the terminal.

[0114] Specifically, the server can obtain the video stream at the target bitrate either by performing transcoding itself or by sending a request to a transcoding server. For distinction, keyframes in the target bitrate video stream are called the first keyframes, and keyframes in the currently transmitted playback bitrate video stream are called the second keyframes. The server then finds the first and second keyframes with the same timestamps among several first and second keyframes, thus aligning the keyframe timestamps. In video playback scenarios, the timestamp corresponding to a video frame can represent a specific moment in the entire video duration; for example, for a 25-minute video, the timestamp could represent 17 minutes and 58 seconds as the corresponding video frame. In live streaming scenarios, the timestamp corresponding to a video frame can be physical time, such as X hours, X minutes, and X seconds. After timestamp alignment, the server switches the video stream to the target bitrate and transmits the target bitrate video stream to the terminal.

[0115] Specifically, at the current moment, the server continues to transmit the video stream at the playback bitrate to the terminal. Within the target bitrate video stream, the server determines the first keyframe after the current moment and searches the cached currently transmitted playback bitrate video stream for a second keyframe with the same timestamp as the first keyframe. If a second keyframe with the same timestamp exists, the server prepares to switch the video stream to the target bitrate. That is, the server continues transmitting the playback bitrate video stream to the terminal until it reaches the second keyframe, at which point it stops transmitting the original playback bitrate video stream and switches to the first keyframe corresponding to the second keyframe. From this first keyframe, the server transmits the subsequent target bitrate video stream to the terminal. In other words, the server switches to the first keyframe corresponding to the second keyframe and transmits the target bitrate video stream including the moments following the first keyframe. It should be noted that when the server transmits the playback bitrate video stream until it reaches the second keyframe, this could be a state where all video frames before the second keyframe have been transmitted, but the second keyframe has not yet been transmitted.

[0116] For example, assuming the current time is T_1, after acquiring the high-bitrate video stream, the server searches through the cached low-bitrate video stream and finds that at time T_n, there are first and second keyframes with the same timestamp. Therefore, the server continues to transmit the low-bitrate video stream, including video frames from time T_2, time T_3, and so on, until it reaches the keyframe at time T_n. At this point, the server stops transmitting the low-bitrate video stream and switches to the high-bitrate video stream; that is, the server begins transmitting the high-bitrate video stream (starting from the keyframe at time T_n) to the terminal.

[0117] For example, such as Figure 4As shown, taking the upslicing bitrate in a live streaming scenario as an example, the content delivery server sends a request to the transcoding server to receive the high-bitrate transcoded stream. Then, it finds two I-frames with the same timestamp in the buffers of the high-bitrate transcoded stream and the low-bitrate video stream, completing I-frame timestamp alignment. After I-frame timestamp alignment, the content delivery server switches from the original bitrate to the new high bitrate, thus achieving a smooth and seamless switching of the video stream bitrate.

[0118] In cases where a second keyframe with the same timestamp does not exist, and there is a higher demand for improved image quality, the server, after determining that a second keyframe with the same timestamp does not exist, directly switches the video stream at the playback bitrate to the target bitrate based on the first keyframe and transmits it to the terminal. This allows for adaptive adjustment of the video stream bitrate and rapid bitrate switching. Specifically, the server continues to transmit the video stream at the playback bitrate to the terminal until it reaches the moment corresponding to the first keyframe. At this point, it stops transmitting the original playback bitrate video stream and switches to the first keyframe, from which it begins transmitting the subsequent video stream at the target bitrate to the terminal.

[0119] In other cases where smoothness is more critical, if the server determines that a second keyframe with the same timestamp does not exist, it can continue transmitting and buffering the current bitrate video stream and determine if the next keyframe in the target bitrate video stream can be timestamped. If not, it continues to determine the next keyframe, and so on, until the timestamps are aligned. It then determines the first and second keyframes with aligned timestamps, completes the bitrate switch, and transmits the target bitrate video stream to the terminal. This ensures smooth, stutter-free video playback. Therefore, even without a second keyframe with the same timestamp, bitrate switching can be achieved based on the next keyframe in the target bitrate video stream, avoiding repeated bitrate switching and significantly improving the accuracy of bitrate adjustment.

[0120] In the above embodiments, smooth and seamless switching of video stream bitrate is achieved through timestamp alignment, so there will be no stuttering or black screen when the terminal plays the video, which greatly ensures the user's viewing experience.

[0121] In one specific embodiment, the overall architecture can be as follows: Figure 5As shown, taking a Content Delivery Network (CDN) server as an example, the transmission link between the client and the CDN server includes a streaming media channel and a signaling channel. The client and CDN server transmit video streams through the streaming media channel and communicate via the signaling channel, such as sending requests and responses. The CDN server includes a stream-switching decision module, which determines whether the bitrate needs to be adjusted based on the network status of the transmission link obtained by the client through packet feedback. If the stream-switching decision module determines that a bitrate increase is needed, a pre-incrementing bitrate module performs a gradual pre-incrementing of the bitrate and determines the adjusted target bitrate while meeting network smoothness requirements. The CDN server sends a high-bitrate video stream back to the transcoding source. Upon receiving the high-bitrate video stream, the media splicing module aligns the timestamps of video frames (including but not limited to I-frames) of different bitrates, thereby switching the video stream to the new bitrate. During transcoding, multiple pre-set bitrate levels (e.g., standard definition, high definition, ultra-high definition, 4K, etc.) can be used for transcoding, and timestamp alignment is performed.

[0122] For example, when a client requests playback, it sends a bitrate template (including specific bitrate information and parameters) and a playback bitrate (one of several preset bitrate levels) to the CDN server. The server (CDN) calculates and evaluates network capacity in real time by sensing network changes. When it senses that the network capacity is limited or playback is choppy, it reduces the bitrate and transcodes back to the source at a lower bitrate. After receiving the lower bitrate and aligning it with the current bitrate timestamp, it switches to the new lower bitrate.

[0123] For example, when the CDN server senses that the network capacity has increased and the playback stuttering has been resolved, it first uses the pre-upgrade module to gradually increase the bitrate by increasing a certain proportion of redundancy when sending a few frames, and observes the response of the transmission link. If it continues to be normal, it sends a high bitrate back to the transcoded source. When the high bitrate stream is received, the CDN server switches to the new high bitrate through timestamp alignment to improve the picture quality.

[0124] When the client makes the decision, such as Figure 6 As shown, taking the server as the content distribution server as an example, the client calculates and evaluates the network capacity in real time by sensing network changes. When it senses that the network capacity is limited or that playback is choppy, it requests the server to reduce the bitrate through the signaling channel to improve the stuttering rate. When the client senses that the network capacity has increased and the playback stuttering has been restored, it requests the server to increase the bitrate through the signaling channel to improve the picture quality.

[0125] For example, such as Figure 7As shown, suppose a client sends a WebRTC request containing all bitrate templates (including 2000Kbps, 1200Kbps, 800Kbps, and 550Kbps) and bitrate levels supported by the client, as well as the current playback bitrate. Assuming an initial bitrate of 2000Kbps, the client sends packets back to the CDN server. The CDN server assesses the link bandwidth. If the assessment determines that network capacity is insufficient, the flow switching decision module progressively reduces the bitrate based on the supported bitrate templates until network smoothness conditions are met. Alternatively, the flow switching decision module can directly match the most suitable bitrate based on network capacity. Assuming an initial bitrate of 550Kbps, the CDN server assesses the link bandwidth capacity based on packet feedback. When it determines that the bitrate can be increased, the stream switching decision module attempts to raise the bitrate. First, it increases the redundancy of several frames starting from the I-frame to temporarily increase the bitrate, then observes the link bandwidth assessment results… This process is repeated gradually, increasing the redundancy of several frames starting from the I-frame. If packet loss or other congestion signals occur, the pre-increase bitrate process is terminated; otherwise, the bitrate continues to be gradually increased until the target bitrate (e.g., the next higher bitrate level) is reached. After observing for one decision cycle (3-5 RTTs), the formal bitrate increase can begin. The CDN server then transcodes the video stream back to the source at the corresponding bitrate, timestamps it, and transmits it to the client.

[0126] After the CDN server makes the stream switching decision, it initiates a back-to-origin request to the transcoding server. Upon receiving the high-bitrate transcoded stream, the CDN server needs to find I-frames with the same timestamp in the buffers of both the high-bitrate and low-bitrate video streams, completing I-frame timestamp alignment. After I-frame timestamp alignment, the CDN server switches the original bitrate to the new high bitrate, thus achieving a smooth and seamless bitrate switching.

[0127] This application also provides an application scenario in which the above-described video stream bitrate adjustment method is applied. Specifically, the video stream bitrate adjustment method is applied in this scenario as follows: A user clicks to play a video through a client installed on a terminal, triggering the client to generate a playback request; the terminal requests the video stream from the server via a transmission link. The server responds to the playback request initiated by the terminal and transmits the video stream to the terminal via the transmission link for the client to play. During the playback of the video stream on the terminal, when it is determined based on the network status of the transmission link that the bitrate needs to be increased, the server progressively adjusts the redundancy of the video frames transmitted to the terminal multiple times until the bitrate corresponding to the adjusted video frames matches the target bitrate. During this process, if each adjustment meets the network smoothness condition, the server converts the video stream to the target bitrate and transmits it to the terminal; otherwise, if packet loss or congestion signals are detected at any time, the progressive redundancy adjustment process is exited, and the current playback bitrate of the client remains unchanged.

[0128] Of course, it is not limited to this. The video stream bitrate adjustment provided in this application can also be applied to other application scenarios, such as cloud gaming, cloud classrooms / conferences, etc.

[0129] Cloud gaming, also known as game on demand, is an online gaming technology based on cloud computing. In cloud gaming, the game doesn't reside on the player's terminal but runs on a cloud server. The cloud server renders the game scene as a video and audio stream, which is then transmitted to the player's terminal via the network. The player's terminal doesn't need powerful graphics processing and data handling capabilities; it only needs basic streaming media playback capabilities and the ability to receive player input commands and send them to the cloud server. During cloud gaming, the bitrate of the video and audio streams can be adaptively adjusted and switched.

[0130] In practical application scenarios, for example Figure 8 The web client shown, or for example, Figure 9 The illustrated app client provides a resolution (or image quality) selection menu within the video window. Users can trigger this menu to select an option for the corresponding video resolution (or image quality). In the application scenario of this application, this menu can provide an adaptive bitrate option (e.g., "automatic" or "adaptive"). When the user selects this option, the bitrate and resolution are adaptively adjusted based on network conditions during video streaming on the client, achieving a smooth and seamless transition during bitrate switching, making it imperceptible to the user.

[0131] In e-commerce live streaming, adaptive bitrate adjustment can significantly improve the viewing experience. For users with good network conditions, increasing the bitrate enhances image quality, better showcasing product details and helping to increase conversion rates. Conversely, for users with poor network conditions, decreasing the bitrate improves the smoothness of the live stream.

[0132] In a specific example, taking a live streaming scenario, the broadcaster starts broadcasting at the original bitrate through a client (corresponding to the acquisition end) installed on the terminal. The video stream acquired by the client is pushed to the server. The content distribution server can establish transmission links with one or more users' terminals. In some embodiments, the video stream acquired by the acquisition end is pushed to the source station, where it is received and stored for subsequent distribution. The source station can also transcode the original bitrate video stream to a video stream of a certain bitrate, such as standard definition, high definition, ultra-high definition, or 2K, in real time according to the pull request from the content distribution server. In another embodiment, the transcoding process can also be performed by the content distribution server. The steps of the source station or content distribution server performing the transcoding process include, for example, encoding the video frames in the video stream using video encoding compression methods, and changing the bitrate of the video stream by changing the encoding parameters (e.g., resolution, bitrate, etc.) corresponding to the video frames.

[0133] When a user wants to watch a live streamer's video, the user triggers the client to instruct the terminal to send a playback request to the content delivery server. This playback request carries the playback bitrate selected by the user or set by the client's default setting. Based on this playback bitrate, the content delivery server can either request a video stream of the corresponding bitrate from the origin server or transcode it itself to obtain the corresponding bitrate video stream, and then transmit the video stream at the playback bitrate to the client; the client receives the video stream and plays it.

[0134] During playback, either the client or the content delivery server can determine whether the bitrate of the video stream played by the client should be increased or decreased based on the network status of the transmission link between them. Methods for assessing network status can include client-side assessment or content delivery server assessment.

[0135] In some embodiments, the content delivery server transmits a video stream to the client via a streaming media channel, and simultaneously sends a detection message to the client via a signaling channel to obtain network status information. After receiving the detection message via the signaling channel, the client detects the network status of the transmission link, obtains network status information, encapsulates this information into a feedback message, and sends it to the content delivery server. The content delivery server parses the feedback message to obtain the network status information, and can then assess the network status of the transmission link.

[0136] In another embodiment, the client monitors the network status in real time and obtains network status information during the playback of the video stream. When it determines that the bitrate can be increased or decreased, it sends a request to the content distribution server through the signaling channel to instruct the content distribution server to perform the video stream bitrate adjustment step.

[0137] When a bitrate increase is needed, the content delivery server (CDGDC) for the current bitrate video stream, starting from the first I-frame, increases the instantaneous bitrate by adding redundancy for several frames (no more than the size of a group of blocks), including that I-frame, to attempt a pre-increment of the bitrate, while observing changes in network conditions. The CDGDC progressively increases the redundancy of video frames multiple times. If packet loss or other congestion signals are detected at any point during this process, the pre-increment process is terminated. Otherwise, the CDGDC continues to progressively increase redundancy to increase the bitrate until it reaches the bitrate corresponding to the next higher bitrate level. Afterward, the CDGDC can observe for a decision period (e.g., 3-5 RTTs). If the network conditions are good during this period, the CDGDC will begin the formal bitrate increase. After determining the bitrate increase, the CDGDC can request a video stream of the corresponding bitrate from the origin server or initiate a request to the transcoding server. Upon receiving the video stream of the corresponding bitrate, the CDGDC searches its cache for I-frames with the same timestamp to perform I-frame timestamp alignment. If an I-frame with the same timestamp is found, timestamp alignment is completed, the content delivery server switches the video stream and sends the new video stream to the client, thus smoothly and seamlessly switching the original video stream to the new bitrate video stream. If no I-frame with the same timestamp is found, the content delivery server can continue searching for the next I-frame and performing timestamp alignment, or it can directly switch the video stream based on the next I-frame.

[0138] In some embodiments, when bitrate reduction is required, the client obtains network status information and determines the network status to decide whether bitrate reduction is necessary. If so, the client sends a request to the content delivery server via a signaling channel; the content delivery server then downgrades the bitrate by one or more levels. In another embodiment, the content delivery server obtains network status information based on the feedback message sent by the client, determines the network status, and uses this information to decide whether bitrate reduction is necessary. If so, the content delivery server determines to downgrade by one or more levels, or directly downgrades to the optimal bitrate under the current network conditions.

[0139] It should be understood that although the steps in the flowcharts of the above embodiments are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the above embodiments may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0140] Based on the same inventive concept, this application also provides a video stream bitrate adjustment device for implementing the video stream bitrate adjustment method described above. The solution provided by this device is similar to the implementation described in the above method; therefore, the specific limitations in one or more video stream bitrate adjustment device embodiments provided below can be found in the limitations of the video stream bitrate adjustment method described above, and will not be repeated here.

[0141] In some embodiments, such as Figure 10 As shown, a video stream bitrate adjustment device 1000 is provided, including: a response module 1001, an adjustment module 1002, and a transmission module 1003, wherein:

[0142] The response module 1001 is used to respond to a playback request initiated by the terminal and transmit a video stream to the terminal through the transmission link.

[0143] The adjustment module 1002 is used to gradually adjust the redundancy of the video frames transmitted to the terminal multiple times when the network status of the transmission link determines that bitrate adjustment is required during the playback of the video stream on the terminal, until the bitrate corresponding to the adjusted video frame matches the target bitrate.

[0144] The transmission module 1003 is used to convert the video stream into the target bitrate and transmit it to the terminal when the network status of the transmission link meets the network smoothness conditions during multiple progressive adjustments.

[0145] In some embodiments, the response module is further configured to respond to a playback request initiated by the terminal, and based on the playback bitrate carried in the playback request, obtain a video stream with a playback bitrate obtained by transcoding the original bitrate video stream; wherein the playback bitrate is a preset bitrate corresponding to any level in the preset bitrate levels; and transmit the video stream with the playback bitrate to the terminal through the transmission link.

[0146] In some embodiments, the response module is further configured to transcode the original bitrate video stream to obtain a playback bitrate video stream by adjusting the encoding parameters of the video stream; or, to send a request to the transcoding server to receive the playback bitrate video stream transcoded by the transcoding server.

[0147] In some embodiments, the above-described apparatus further includes a first detection module, configured to receive a feedback message sent by the terminal during the playback of a video stream on the terminal; the feedback message carries network status information; the feedback message is parsed and the network status information of the transmission link is extracted, and the network status of the transmission link is determined based on the network status information to determine whether bitrate adjustment is required.

[0148] In some embodiments, the above-described apparatus further includes a second detection module, configured to determine that bitrate adjustment is required when a bitrate adjustment request is received from a terminal; wherein the bitrate adjustment request is generated by the terminal detecting network status information during the playback of the video stream and when the network status information is detected to meet the bitrate adjustment conditions.

[0149] In some embodiments, the adjustment module is further configured to, when it is determined based on the network status of the transmission link that the bitrate needs to be increased, start from the first keyframe in the untransmitted video stream, determine multiple video frames including the first keyframe and several video frames after the first keyframe; adjust the redundancy coding parameters of each video frame in the multiple video frames to improve the redundancy of the multiple video frames, and send the multiple video frames with adjusted redundancy coding parameters to the terminal; obtain the latest network status of the transmission link, and if the latest network status of the transmission link meets the network smoothness conditions, continue to increase the redundancy of the video frames in the untransmitted video stream until the bitrate corresponding to the video frames after multiple adjustments reaches the target bitrate and then stops.

[0150] In some embodiments, the above-described apparatus further includes an exit module, which, during the process of progressively adjusting the redundancy of video frames, stops adjusting the redundancy of video frames and exits the bitrate adjustment process when it is detected at any time that the network status of the transmission link does not meet the network smoothness conditions, and controls the bitrate of the video stream transmitted to the terminal to remain unchanged.

[0151] In some embodiments, the transmission module is further configured to, during multiple progressive adjustments, if the number of times the network status of the transmission link meets the network smoothness condition is higher than the number of times the network smoothness condition is not met, then convert the video stream to the target bitrate and transmit it to the terminal; or, during multiple progressive adjustments, if the number of times the network status of the transmission link meets the network smoothness condition reaches a preset threshold, then convert the video stream to the target bitrate and transmit it to the terminal.

[0152] In some embodiments, the above-described apparatus further includes a first down-adjustment module, configured to, when it is determined based on the network status of the transmission link that the bitrate needs to be down-adjusted, adjust the bitrate transmitted to the video stream level by level from a preset multiple bitrate levels, starting from a bitrate level one level lower than the current playback bitrate, until the network status information of the transmission link meets the network smoothness condition, and then stop adjusting the bitrate; when the network status information of the transmission link meets the network smoothness condition, the adjusted bitrate is determined as the target bitrate, and the video stream is converted to the target bitrate and transmitted to the terminal.

[0153] In some embodiments, the above-described apparatus further includes a second down-rate module, configured to determine the highest supported bitrate level among a plurality of preset bitrate levels based on the network status of the transmission link when it is determined that the bitrate needs to be down-rate based on the network status of the transmission link; and to transmit the video stream to the terminal after converting it to the highest bitrate level.

[0154] In some embodiments, the transmission module is further configured to acquire a video stream with a target bitrate and determine a first keyframe after the current moment in the video stream with the target bitrate; in the currently transmitted video stream with a playback bitrate, search for a second keyframe with the same timestamp as the first keyframe; if a second keyframe with the same timestamp exists, continue transmitting the video stream with the playback bitrate to the terminal until the second keyframe is reached, and then transmit the video stream with the target bitrate that includes the first keyframe to the terminal.

[0155] Each module in the aforementioned video stream bitrate adjustment device can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in the processor of a computer device in hardware form or independent of it, or stored in the memory of a computer device in software form, so that the processor can call and execute the corresponding operations of each module.

[0156] In some embodiments, a computer device is provided, which may be a server or terminal as described in the foregoing embodiments. Taking a server as an example, its internal structure diagram may be as follows. Figure 11As shown, this computer device includes a processor, memory, input / output interfaces (I / O), and a communication interface. The processor, memory, and I / O interfaces are connected via a system bus, and the communication interface is also connected to the system bus via the I / O interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and a database. The internal memory provides the environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The database stores video stream data. The I / O interfaces are used for exchanging information between the processor and external devices. The communication interface is used for communicating with external terminals via a network connection. When executed by the processor, the computer program implements a video stream bitrate adjustment method.

[0157] Those skilled in the art will understand that Figure 11 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device to which the present application is applied. Specific computer devices may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0158] In some embodiments, a computer device is also provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps in the above method embodiments.

[0159] In some embodiments, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the steps in the above method embodiments.

[0160] In some embodiments, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps in the above method embodiments.

[0161] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited to these.

[0162] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0163] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A method for adjusting the bitrate of a video stream, characterized in that, The method includes: In response to a playback request initiated by the terminal, a video stream is transmitted to the terminal via a transmission link; When it is determined that the bitrate needs to be increased based on the network status of the transmission link, the target bitrate to be adjusted is the bitrate corresponding to the bitrate level that is higher than the current playback bitrate among a number of preset bitrate levels. Starting from the first keyframe in the untransmitted video stream, a number of video frames are determined, including the first keyframe and several video frames after the first keyframe. The number of the multiple video frames is less than the number of a group of GOPs. The redundancy coding parameters of each of the multiple video frames are adjusted to improve the redundancy of the multiple video frames, and the multiple video frames with adjusted redundancy coding parameters are sent to the terminal. Obtain the latest network status of the transmission link. If the latest network status of the transmission link meets the network smoothness condition, continue to increase the redundancy of multiple video frames starting from the next key frame in the untransmitted video stream until the bitrate corresponding to the video frame after multiple progressive adjustments reaches the target bitrate. During multiple progressive adjustments, if at any moment the network status of the transmission link is detected to be unsatisfactory, the adjustment of video frame redundancy is stopped and the bitrate adjustment process is exited, and the bitrate of the video stream transmitted to the terminal is kept constant. If the network status of the transmission link meets the network smoothness condition during multiple progressive adjustments, then the target bitrate video stream is acquired, and the first keyframe after the current moment is determined in the target bitrate video stream. The second keyframe with the same timestamp as the first keyframe is searched in the currently transmitted playback bitrate video stream. When the second keyframe is found, the playback bitrate video stream continues to be transmitted to the terminal until the second keyframe is reached, and then the video stream including the first keyframe in the target bitrate video stream is transmitted to the terminal.

2. The method according to claim 1, characterized in that, The step of transmitting a video stream to the terminal via a transmission link in response to a playback request initiated by the terminal includes: In response to a playback request initiated by the terminal, based on the playback bitrate carried in the playback request, a video stream with the playback bitrate obtained by transcoding the original bitrate video stream is obtained; wherein, the playback bitrate is a preset bitrate corresponding to any level in the preset bitrate levels; The video stream at the specified playback bitrate is transmitted to the terminal via a transmission link.

3. The method according to claim 2, characterized in that, The process of obtaining the video stream with the playback bitrate obtained by transcoding the original bitrate video stream includes: By adjusting the encoding parameters of the video stream, the original bitrate video stream is transcoded to obtain the playback bitrate video stream; or, a request is sent to a transcoding server to receive the playback bitrate video stream transcoded by the transcoding server.

4. The method according to claim 1, characterized in that, The method further includes: During the playback of the video stream on the terminal, a feedback message sent by the terminal is received; the feedback message carries network status information. The feedback message is parsed and the network status information of the transmission link is extracted. Based on the network status information, the network status of the transmission link is determined to determine whether a bitrate adjustment is needed.

5. The method according to claim 1, characterized in that, The method further includes: Upon receiving a bitrate adjustment request from the terminal, it is determined that bitrate adjustment is required. The bitrate adjustment request is generated by the terminal detecting network status information during the playback of the video stream and generating the request when the network status information meets the bitrate adjustment conditions.

6. The method according to claim 1, characterized in that, The method further includes: During multiple gradual adjustments, if the number of times the network status of the transmission link meets the network smoothness conditions is higher than the number of times the network smoothness conditions are not met, then the video stream is converted to the target bitrate and transmitted to the terminal, or... During multiple gradual adjustments, if the number of times the network status of the transmission link meets the network smoothness condition reaches a preset threshold, then the video stream is converted to the target bitrate and transmitted to the terminal.

7. The method according to claim 1, characterized in that, During the playback of the video stream on the terminal, the method further includes: When it is determined that the bitrate needs to be reduced based on the network status of the transmission link, the bitrate transmitted to the video stream is adjusted step by step from the bitrate level one level lower than the current playback bitrate among a number of preset bitrate levels, until the network status information of the transmission link meets the network smoothness conditions, and then the bitrate adjustment stops. When the network status information of the transmission link meets the network smoothness conditions, the adjusted bitrate is determined as the target bitrate, and the video stream is converted to the target bitrate and then transmitted to the terminal.

8. The method according to claim 1, characterized in that, During the playback of the video stream on the terminal, the method further includes: When it is determined that the bitrate needs to be reduced based on the network status of the transmission link, the highest bitrate that can be supported is determined from a set of preset bitrate levels based on the network status of the transmission link. The video stream is converted to the highest bitrate and then transmitted to the terminal.

9. A video stream bitrate adjustment device, characterized in that, The device includes: The response module is used to respond to a playback request initiated by the terminal and transmit a video stream to the terminal via the transmission link; The adjustment module is used to, when it is determined based on the network status of the transmission link that the bitrate needs to be increased, adjust the target bitrate to the bitrate corresponding to a bitrate level higher than the current playback bitrate among a pre-set multiple bitrate levels. Starting from the first keyframe in the untransmitted video stream, it determines multiple video frames, including the first keyframe and several video frames following it, where the number of video frames is less than the number of a group of blocks (GOPs). It adjusts the redundancy coding parameters of each video frame to increase the redundancy of the multiple video frames and sends the adjusted video frames to the terminal. It obtains the latest network status of the transmission link, and if the latest network status satisfies network smoothness conditions, it continues to increase the redundancy of multiple video frames starting from the next keyframe in the untransmitted video stream until the bitrate corresponding to the video frames after multiple progressive adjustments reaches the target bitrate. The exit module is used to stop adjusting the redundancy of video frames and exit the bitrate adjustment process when the network status of the transmission link is detected to be unsatisfactory during multiple progressive adjustments, and to control the bitrate of the video stream transmitted to the terminal to remain unchanged. The transmission module is configured to, when the network status of the transmission link meets the network smoothness condition during multiple progressive adjustments, acquire a video stream with a target bitrate, determine a first keyframe after the current moment in the video stream with the target bitrate, search for a second keyframe with the same timestamp as the first keyframe in the currently transmitted video stream with the playback bitrate, continue transmitting the video stream with the playback bitrate to the terminal when the second keyframe is found, and stop transmitting when the second keyframe is reached, and transmit the video stream with the target bitrate including the first keyframe to the terminal.

10. The apparatus according to claim 9, characterized in that, The response module is further configured to respond to a playback request initiated by the terminal, and based on the playback bitrate carried in the playback request, obtain a video stream with the playback bitrate obtained by transcoding the original bitrate video stream; wherein, the playback bitrate is a preset bitrate corresponding to any level in the preset bitrate levels; and transmit the video stream with the playback bitrate to the terminal through the transmission link.

11. The apparatus according to claim 10, characterized in that, The response module is also configured to transcode the original bitrate video stream to obtain the playback bitrate video stream by adjusting the encoding parameters of the video stream; or, send a request to the transcoding server to receive the playback bitrate video stream transcoded by the transcoding server.

12. The apparatus according to claim 9, characterized in that, The device further includes a first detection module, used to receive a feedback message sent by the terminal during the playback of the video stream on the terminal; the feedback message carries network status information; the module parses the feedback message and extracts the network status information of the transmission link, and determines the network status of the transmission link based on the network status information to determine whether bitrate adjustment is required.

13. The apparatus according to claim 9, characterized in that, The device further includes a second detection module, which determines that bitrate adjustment is required when a bitrate adjustment request is received from the terminal; wherein the bitrate adjustment request is generated by the terminal detecting network status information during the playback of the video stream and when the network status information is detected to meet the bitrate adjustment conditions.

14. The apparatus according to claim 9, characterized in that, The transmission module is further configured to, during multiple progressive adjustments, if the number of times the network status of the transmission link meets the network smoothness condition is higher than the number of times the network smoothness condition is not met, then convert the video stream to the target bitrate and transmit it to the terminal; or, during multiple progressive adjustments, if the number of times the network status of the transmission link meets the network smoothness condition reaches a preset threshold, then convert the video stream to the target bitrate and transmit it to the terminal.

15. The apparatus according to claim 9, characterized in that, The device further includes a first down-adjustment module, configured to, when it is determined based on the network status of the transmission link that a down-adjustment of the bitrate is required, adjust the bitrate transmitted to the video stream level by level from a preset multiple bitrate levels, starting from a bitrate level one level lower than the current playback bitrate, until the network status information of the transmission link meets the network smoothness condition, at which point the bitrate adjustment stops; when the network status information of the transmission link meets the network smoothness condition, the adjusted bitrate is determined as the target bitrate, and the video stream is converted to the target bitrate before being transmitted to the terminal.

16. The apparatus according to claim 9, characterized in that, The device further includes a second down-rate module, which is used to determine the highest supported bitrate level among a plurality of preset bitrate levels when it is determined that the bitrate needs to be down-rate based on the network status of the transmission link; and to transmit the video stream to the terminal after converting it into the highest bitrate level.

17. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 8.

18. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 8.

19. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Video code rate adjustment method and device, server and storage medium

    CN110290402A