Frame rate adjustment method and device for special-effect bullet screen, storage medium and electronic equipment

By dynamically adjusting the frame rate in special effects barrage, matching the initial frame rate according to device performance and special effects type, and monitoring and adjusting during operation, the problem of device performance mismatch caused by inaccurate frame rate settings in the existing technology is solved, and smooth and high-quality barrage display effects can be achieved on different devices.

CN120640060APending Publication Date: 2025-09-12HUNAN HAPPLY SUNSHINE INTERACTIVE ENTERTAINMENT MEDIA CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510690096.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-26
Publication Date
2025-09-12

AI Technical Summary

Technical Problem

In the existing technology, the frame rate adjustment strategy of special effects barrage generally adopts a fixed frame rate, which may cause low-end devices to experience lag due to the high frame rate requirements of special effects barrage, and high-end devices may not be able to display the best visual effects due to the low frame rate requirements, resulting in insufficient resource utilization.

Method used

By obtaining the special effect type and device type of the special effect barrage, matching the initial running frame rate, dividing the running window into multiple windows during the running process, monitoring the average frame rate of each window, and dynamically adjusting the frame rate to meet the expected conditions, the frame rate setting is ensured to adapt to the device performance.

Benefits of technology

The accurate determination of the running frame rate of special effect bullet screen is achieved, which avoids the lag of low-end devices and the waste of resources of high-end devices, and ensures smooth and high-quality bullet screen display effects on different devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120640060A_ABST
    Figure CN120640060A_ABST
Patent Text Reader

Abstract

The invention discloses a frame rate adjustment method and device for a special-effect bullet screen, a storage medium and electronic equipment. The method comprises the steps that a first operation frame rate matched with a special effect type of a special effect bullet screen and an equipment type of operation equipment is acquired, and the special effect bullet screen is used for operating an expected time period on the operation equipment by taking the first operation frame rate as an initial operation frame rate; obtaining the average frame rate of each operation window in the operation process of the special effect bullet screen in the expected time period; under the condition that the average frame rate of the multiple running windows meets an expected condition, an adjustment operation corresponding to the expected condition is executed on the first running frame rate to obtain a second running frame rate, and after the adjustment operation, other special effect barrages of the same special effect type as the special effect barrages are subjected to the second running frame rate; and taking the second operation frame rate as the initial operation frame rate when the operation equipment operates. The technical problem that the running effect of the special-effect bullet screen is poor is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computers, and more specifically, to a method and device for adjusting the frame rate of special effect bullet screens, a storage medium, and an electronic device. Background Art

[0002] Existing frame rate adjustment strategies for special effects bullet screens generally use a fixed frame rate. This one-size-fits-all approach can cause low-end devices to experience stuttering due to the high frame rate requirements of special effects bullet screens, affecting video playback smoothness and the user's viewing experience. High-end devices may not be able to display the optimal visual effects of special effects bullet screens due to the lower frame rate requirements, resulting in underutilized hardware resources.

[0003] Therefore, due to the inaccurate determination of the running frame rate of the special effect barrage, there is a technical problem in the related art that the running effect of the special effect barrage is poor. Summary of the Invention

[0004] The embodiments of the present application provide a method and device for adjusting the frame rate of special effect barrage, a storage medium, and an electronic device, so as to at least solve the technical problem of poor operating effect of special effect barrage in related technologies.

[0005] According to one aspect of an embodiment of the present application, a method for adjusting the frame rate of a special effect barrage is provided, including: obtaining a first running frame rate that matches the special effect type of the special effect barrage and the device type of the running device, wherein the special effect barrage is used to run on the running device with the first running frame rate as the initial running frame rate for an expected time period; obtaining the average frame rate of each running window during the running of the special effect barrage in the expected time period, wherein the expected time period is divided into multiple running windows; when the average frame rates of the multiple running windows meet the expected conditions, performing an adjustment operation corresponding to the expected conditions on the first running frame rate to obtain a second running frame rate, wherein other special effect barrages with the same special effect type as the special effect barrage use the second running frame rate as the initial running frame rate when running on the running device after the adjustment operation.

[0006] According to another aspect of an embodiment of the present application, a frame rate adjustment device for special effect barrage is also provided, including: a first acquisition unit, used to obtain a first running frame rate that matches the special effect type of the special effect barrage and the device type of the running device, wherein the special effect barrage is used to run on the running device with the first running frame rate as the initial running frame rate for an expected time period; a second acquisition unit, used to obtain the average frame rate of each running window of the special effect barrage during the running process of the expected time period, wherein the expected time period is divided into multiple running windows; an adjustment unit, used to perform an adjustment operation corresponding to the expected condition on the first running frame rate when the average frame rate of the multiple running windows meets the expected condition, to obtain a second running frame rate, wherein other special effect barrages with the same special effect type as the special effect barrage use the second running frame rate as the initial running frame rate when the running device runs after the adjustment operation.

[0007] According to another aspect of the embodiments of the present application, a computer program product is provided, comprising a computer program / instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer program / instructions from the computer-readable storage medium and executes the computer program / instructions, causing the computer device to perform the above-described method for adjusting the frame rate of a special effects bullet comment.

[0008] According to another aspect of an embodiment of the present application, an electronic device is also provided, including a memory, a processor, and a computer program stored in the memory and runnable on the processor, wherein the processor executes the frame rate adjustment method of the special effects barrage through the computer program.

[0009] In this embodiment, a first running frame rate that matches a specific special effect (bullet screen) type and (running) device type is obtained as the initial running frame rate of the special effect bullet screen. During the expected running time of the special effect bullet screen, the average frame rate of each running window is further monitored and calculated, and a dynamic judgment is made based on this. When the average frame rates of multiple running windows meet the expected conditions, the frame rate is adjusted to obtain an optimized second running frame rate, which serves as the initial running frame rate for other special effect bullet screens of the same special effect type when subsequently running on running devices of the same device type. This embodiment can determine the initial running frame rate of the initialization based on device performance and bullet screen special effect type, and then dynamically adjust the initial running frame rate of the initialization based on the average frame rate of multiple running windows during actual operation, thereby achieving the technical effect of accurately determining the running frame rate of the special effect bullet screen, avoiding the stuttering phenomenon caused by excessively high frame rates on low-end devices, and ensuring that high-end devices can present special effect bullet screens at the optimal frame rate, solving the technical problem of poor running effects of special effect bullet screens in related technologies. BRIEF DESCRIPTION OF THE DRAWINGS

[0010] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0011] Figure 1 This is a schematic diagram of a process of an optional method for adjusting the frame rate of a special effect bullet screen according to an embodiment of the present application;

[0012] Figure 2 This is a schematic diagram of an optional framework of an SDK and engine library for running special effects barrage according to an embodiment of the present application;

[0013] Figure 3 This is a schematic diagram of an optional operation flow of a special effect barrage according to an embodiment of the present application;

[0014] Figure 4 is a schematic diagram of an optional frame rate adjustment device for special effect bullet screen according to an embodiment of the present application;

[0015] Figure 5 A schematic structural diagram of an optional electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

[0016] In order to enable those skilled in the art to better understand the present invention, the following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of this application.

[0017] It should be noted that the terms "first", "second", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequential order. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in a sequence other than those illustrated or described herein. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device comprising a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0018] Alternatively, as an optional implementation, Figure 1 As shown in the figure, the frame rate adjustment method of the special effect barrage includes the following steps:

[0019] S102, obtaining a first running frame rate that matches the special effect type of the special effect bullet screen and the device type of the running device, wherein the special effect bullet screen is used to run on the running device at the first running frame rate as an initial running frame rate for an expected period of time;

[0020] S104, obtaining an average frame rate of each running window during the running of the special effect bullet screen in the expected time period, wherein the expected time period is divided into multiple running windows;

[0021] S106, when the average frame rate of multiple running windows meets the expected conditions, an adjustment operation corresponding to the expected conditions is performed on the first running frame rate to obtain a second running frame rate, wherein other special effect barrages of the same special effect type as the special effect barrage use the second running frame rate as the initial running frame rate when the running device is running after the adjustment operation.

[0022] Optionally, the above-mentioned special effects bullet screen frame rate adjustment method can be applied to, but is not limited to, real-time bullet screen rendering optimization in scenarios such as video playback, live interactive broadcasting, and gaming on the Android platform. The above-mentioned special effects bullet screen frame rate adjustment method can be combined with, but is not limited to, a graphics rendering engine (such as Cocos2d-x) and system-level performance monitoring technology to dynamically adjust the bullet screen frame rate to achieve a cross-device performance and display effect balance and enhance the user experience.

[0023] Optionally, in this embodiment, special effects barrage can refer to, but are not limited to, barrage information processed with visual effects in online videos and live broadcast platforms to enhance the audience's interactive experience. Special effects barrage can refer to, but are not limited to, animations, particle effects, 3D rendering, etc., to enhance the visual appeal and interactivity of the barrage.

[0024] Optionally, in this embodiment, the first running frame rate may refer to, but is not limited to, a frame rate preset at the startup of the special effect barrage based on device performance and barrage type, serving as the initial benchmark rate for rendering the special effect barrage. The running device may refer to, but is not limited to, any electronic device capable of receiving, parsing, and rendering the special effect barrage, such as a smartphone, tablet computer, smart TV, or in-car entertainment system.

[0025] Optionally, in this embodiment, the expected time period may refer to, but is not limited to, the time period during which the special effects bullet screen is expected to be fully rendered. Frame rate monitoring and adjustment will be performed during this time period. The running window refers to a continuous series of equal-length sub-periods within the expected time period, used to calculate and analyze the average frame rate. The average frame rate refers to the average frame rate of the special effects bullet screen within the running window. This window slides over time to reflect the latest frame rate status.

[0026] Optionally, in this embodiment, the expected condition may be, but is not limited to, a set frame rate adjustment standard, including but not limited to performance thresholds, stability, and user experience considerations, used to determine whether and how to adjust the first operating frame rate. Optionally, the expected condition may include, but is not limited to, an expected frame increase condition for instructing to increase the first operating frame rate, and may also include, but is not limited to, an expected frame decrease condition for instructing to decrease the first operating frame rate.

[0027] It can be understood that in this embodiment, by obtaining a first running frame rate that matches the special effect type and the running device type of the special effect barrage, the method ensures that the special effect barrage can obtain a more reasonable running speed on the target device when it is started. Subsequently, the method further monitors the running status of the special effect barrage within the expected time period, and by counting the average frame rate in each running window, it can carefully evaluate the actual performance of the barrage on a specific device. When the average frame rate meets the predetermined expected conditions, the method dynamically adjusts the first running frame rate to generate a more suitable second running frame rate. This adjustment is not only for the current barrage, but also affects the initial frame rate setting of future barrages of the same type, thereby ensuring that the performance of the same type of barrage on the same device is always optimized.

[0028] Specifically, first, this embodiment uses deep learning and performance testing to pre-establish a database of device performance grading and bullet screen special effects complexity grading, providing a basis for subsequent frame rate adjustment. When the special effects bullet screen is activated, the first running frame rate is intelligently selected based on the device's hardware information and the type of special effects bullet screen, as the initial rendering speed of the special effects bullet screen. This initial frame rate is not fixed, but is optimized through real-time monitoring and dynamic adjustment as the special effects bullet screen runs.

[0029] During the expected runtime of the special effects bullet screen, the average frame rate within each running window is continuously obtained. This mechanism can promptly capture the changing trends in bullet screen rendering performance. Compared to a single average value calculation, the sliding window method can more sensitively respond to sudden performance fluctuations, ensuring the timeliness and accuracy of frame rate adjustments. When the monitored average frame rate is higher or lower than the set threshold for a period of time, it indicates that the current frame rate setting may not be optimal. At this time, the first running frame rate will be adjusted to achieve a more ideal second running frame rate.

[0030] It is worth noting that the adjustment strategy of this embodiment is not limited to immediate effects, but also focuses on future optimization of bullet screen rendering. Once the frame rate of a special effect bullet screen type is successfully adjusted, the optimized second running frame rate will be used as the initial running frame rate for subsequent bullet screens of the same type, thus establishing a set of adaptive special effect bullet screen frame rate strategies based on device performance. The iterative and learning process of this strategy enables the device to obtain bullet screen rendering effects that are more in line with its own hardware conditions after multiple runs, greatly improving the consistency and satisfaction of the user experience.

[0031] To further illustrate, when adjusting to obtain the second running frame rate and in the process of subsequently running other special effects barrages on the running device with the second running frame rate as the initial running frame rate, the average frame rate in each corresponding running window is also continuously obtained, and the same strategy as above is used. If it is detected that the current second running frame rate setting may not be optimal, the adjustment of the second running frame rate will be triggered in order to achieve a more ideal third running frame rate.

[0032] It is understandable that during the operation of each special effects barrage, the above-mentioned real-time operation monitoring and dynamic frame rate adjustment are adopted to continuously, in real time and dynamically perform adaptive frame rate adjustment on the special effects barrage.

[0033] Through the embodiments provided by the present application, in this embodiment, a first running frame rate that matches a specific special effect (bullet screen) type and (running) device type is obtained as the initial running frame rate of the special effect bullet screen. During the expected running time of the special effect bullet screen, the average frame rate of each running window is further monitored and calculated, and based on this, the frame rate is dynamically judged and adjusted when the average frame rates of multiple running windows meet the expected conditions, to obtain an optimized second running frame rate, which serves as the initial running frame rate for other special effect bullet screens of the same special effect type when subsequently running on running devices of the same device type. This embodiment can determine the initial running frame rate of the initialization based on device performance and bullet screen special effect type, and then dynamically adjust the initial running frame rate of the initialization based on the average frame rate of multiple running windows during actual operation, thereby achieving the technical effect of accurately determining the running frame rate of the special effect bullet screen.

[0034] As an optional solution, when the average frame rates of the multiple running windows meet the expected conditions, performing an adjustment operation corresponding to the expected conditions on the first running frame rate to obtain a second running frame rate includes:

[0035] When the average frame rates of the plurality of operating windows meet the expected frame rate increase condition, performing a frame increase operation corresponding to the expected frame rate increase condition on the first operating frame rate to obtain a third operating frame rate having a frame rate higher than the first operating frame rate; and determining the third operating frame rate as the second operating frame rate;

[0036] When the average frame rate of multiple running windows meets the expected frame rate reduction condition, a frame reduction operation corresponding to the expected frame rate reduction condition is performed on the first running frame rate to obtain a fourth running frame rate whose frame rate is lower than the first running frame rate; and the fourth running frame rate is determined as the second running frame rate.

[0037] Optionally, in this embodiment, the expected frame rate increase condition may be, but is not limited to, a set of frame rate increase standards, indicating that the operating device can support a higher frame rate, thereby triggering a frame rate increase operation. For further example, if, among multiple operating windows, a first number of operating windows having an average frame rate greater than the expected frame rate accounts for a total number of operating windows included in the multiple operating windows and is greater than a first percentage threshold, the expected frame rate increase condition is determined to be met.

[0038] Optionally, in this embodiment, the expected frame reduction condition may be, but is not limited to, another set of frame reduction standards, indicating that the operating device is experiencing a significant lag at its current frame rate and needs to reduce the frame rate, thereby triggering a frame reduction operation. For further example, if, among multiple operating windows, the proportion of a second number of operating windows having an average frame rate less than a minimum threshold to the total number of operating windows included in the multiple operating windows is greater than a second proportion threshold, the expected frame reduction condition is determined to be met.

[0039] When the average frame rate meets the expected frame rate increase conditions, the system automatically detects that the device has sufficient margin to increase the frame rate, triggering the frame rate increase. The core of the frame rate increase is to intelligently generate a higher third operating frame rate based on the current device performance margin and the visual requirements of the special effects barrage. This frame rate increase will significantly enhance the dynamic visual effects and smoothness of the special effects barrage, especially on high-end devices, providing users with a more stunning and immersive viewing experience.

[0040] When the average frame rate meets the expected frame rate reduction conditions, indicating that the current frame rate setting exceeds the device's performance capacity, the frame rate reduction operation will be initiated to generate a lower fourth operating frame rate. The purpose of the frame reduction operation is to moderately reduce the frame rate of the special effects barrage while ensuring the basic smoothness of video playback or live interaction to avoid device lag or excessive resource utilization. This strategy is particularly suitable for low-end devices. By reducing the frame rate of the special effects barrage, it can provide the most stable barrage display effect without affecting the smoothness of the main business.

[0041] Through the embodiments provided in this application, this embodiment proposes frame rate adjustment operations under two expected conditions: "frame increase" and "frame decrease". By real-time monitoring of the average frame rate, the rendering speed of special effects barrage is dynamically adjusted to ensure the best display effect and smoothness on different devices.

[0042] As an optional solution, before performing an adjustment operation corresponding to the expected condition on the first running frame rate to obtain the second running frame rate, the method further includes:

[0043] Acquire a first number of the running windows whose average frame rate is greater than the expected frame rate among the multiple running windows, and acquire a total number of the running windows included in the multiple running windows;

[0044] Calculate the first quantity and divide it by the total quantity to get the first proportion;

[0045] When the first proportion is greater than the first proportion threshold, it is determined that the average frame rates of the plurality of running windows meet the expected frame rate increase condition, wherein the expected condition includes the expected frame rate increase condition.

[0046] Optionally, in this embodiment, the expected frame rate refers to the expected frame rate standard for special effects bullet screens running on a device, used to assess whether the device can meet the performance requirements for special effects bullet screen rendering. The first number refers to the number of running windows with an average frame rate higher than the expected frame rate among multiple running windows, used to measure whether the device has the potential to increase frame rates.

[0047] Optionally, in this embodiment, the first percentage is the ratio of the calculated number of running windows whose average frame rate exceeds the expected frame rate to the total number of all running windows, which is used to determine whether the expected frame upgrade condition is met. The first percentage threshold is a pre-set ratio standard used to determine whether it is reasonable to perform a frame upgrade operation on the current device. It is typically set between 0 and 1 and represents the ratio of the number of running windows whose average frame rate exceeds the expected frame rate to the total number of running windows.

[0048] Optionally, in this embodiment, the number of windows whose average frame rate across all running windows is greater than the expected frame rate within the expected time period is counted, i.e., a first number. The total number of running windows within the entire expected time period is then obtained. Based on these two values, a first ratio between the first number and the total number is calculated. This ratio intuitively reflects the performance of the special effects barrage on the device, i.e., the proportion of high-performance windows.

[0049] When the calculated first percentage exceeds the pre-set first percentage threshold, the current device's performance is determined to be sufficient to support a higher frame rate, and a frame rate increase is performed. This judgment logic ensures the feasibility of the frame rate increase and avoids video playback stuttering or unstable bullet screen rendering caused by blindly increasing the frame rate due to insufficient device performance. At the same time, by comparing the first percentage with the first percentage threshold, the match between device performance and special effects bullet screen rendering requirements can be accurately measured, allowing for more precise frame rate adjustment decisions.

[0050] It should be noted that, in this embodiment, the frame rate adjustment is not only based on instantaneous performance monitoring, but also through long-term performance trend analysis to ensure that the adjustment operation is more cautious and accurate. By setting the first percentage threshold, temporary frame rate fluctuations caused by network fluctuations, system load and other reasons can be filtered out to a certain extent, avoiding the incorrect execution of frame upgrade operations, thereby preventing adverse effects on video playback or live interaction. At the same time, it also enhances the adaptability between device performance and special effects barrage requirements, ensuring that the frame upgrade operation can fully utilize the advantages of device hardware without causing waste or overload of resources, providing users with a consistent and high-quality interactive experience.

[0051] As an optional solution, before obtaining a first number of running windows whose average frame rate is greater than the expected frame rate among the multiple running windows, the method further includes:

[0052] Get the device performance parameters corresponding to the device type, and get the special effect level parameters corresponding to the feature type;

[0053] When the basic frame rate corresponding to the device type is obtained, the basic frame rate is adjusted according to the device performance parameters and special effect level parameters to obtain the expected frame rate.

[0054] Optionally, in this embodiment, the device performance parameter may be used to indicate, but is not limited to, the device performance level of the operating device. A higher device performance level indicates a higher performance in processing special effects bullet comments, and a higher device performance parameter value indicates a higher expected frame rate. The device performance level of the operating device may be determined based on, but is not limited to, a comprehensive combination of the device type, processor speed, GPU model, memory size, screen resolution, and the like.

[0055] Optionally, in this embodiment, the special effect level parameter may be, but is not limited to, used to indicate the complexity of the special effect barrage. The more complex the special effect barrage, the higher the special effect barrage parameter, the lower the performance of processing the special effect barrage, and the lower the expected frame rate. The special effect level parameter of the special effect barrage may be, but is not limited to, determined based on the special effect type of the special effect barrage. For example, a simple text type corresponds to the lowest special effect level parameter, while a 3D type corresponds to the highest special effect level parameter.

[0056] Optionally, in this embodiment, a more accurate frame rate adaptation is achieved by comprehensively considering the device performance parameters and special effect level parameters. At the beginning of the special effect barrage, a base frame rate is preset according to the device type, which generally reflects the performance of that type of device when processing general barrage. However, this base frame rate does not fully take into account the differences in device hardware and the specific rendering requirements of barrage special effects, and therefore may not accurately reflect the actual performance of the device in the current special effect barrage rendering scenario.

[0057] To overcome this limitation, this embodiment introduces a dynamic adjustment mechanism for device performance parameters and special effects level parameters. First, the device's performance parameters are obtained through the device hardware information interface, which directly determines the device's processing power when rendering special effects bullet screens. Furthermore, by analyzing the special effects bullet screen type, the special effects level parameter is obtained. This parameter quantifies the complexity and resource requirements of bullet screen special effects, such as 2D particle effects and 3D model rendering, and directly affects the rendering efficiency and visual quality of the bullet screen.

[0058] After identifying the base frame rate corresponding to the device type, the system intelligently adjusts the base frame rate using device performance parameters and special effects level parameters to arrive at the final expected frame rate. This adjustment process essentially uses an algorithmic model to comprehensively analyze the device's hardware configuration and the rendering difficulty of the special effects barrage, dynamically calculating a target frame rate that suits the current device performance and special effects requirements. The setting of the expected frame rate takes into account both the device's hardware capacity and the visual requirements of the special effects barrage, ensuring smooth and high-quality barrage rendering on different devices.

[0059] To further illustrate, the expected threshold and the calculation formula of the minimum threshold are as follows:

[0060]

[0061] Among them, the parameter θ 预期 is the expected threshold, parameter θ 最低 is the minimum threshold, the parameter BaseFPS has a value range of 50 / 60, which is used to indicate the revised basic frame rate (for example, 50 for TV, 60 for mobile phone, 60 for tablet, and 60 for car machine), the parameter DeviceLevel has a value range of 0-3, which is used to indicate the device performance grade (for example, 0 for low-end devices, 1 for high-end devices, and 2 for flagship devices), the parameter EffectLevel has a value range of 1-5, which is used to indicate the revised special effects level (for example, simple text special effects correspond to 1, 2D particle / frame animation special effects correspond to 2, video animation special effects correspond to 3, and 3D effects special effects correspond to 5), and the parameter β is the minimum frame rate ratio coefficient, with a value range of 0.5-0.8, which can be dynamically configured.

[0062] For example, when playing 3D effects (EffectLevel=5) on a flagship phone (DeviceLevel=3) and the minimum frame rate ratio coefficient is 0.6 by default, θ 预期 =60×(1+0.3)×(1-0.25)=58.5FPS, rounded up to 58FPS. 最低 =0.6×58.5=35.1FPS, and finally rounded to 35FPS.

[0063] Through this mechanism, the special effects barrage frame rate adjustment method of this embodiment can not only adaptively set the expected frame rate according to the real-time performance status of the device and the complexity of the barrage special effects, but also, on this basis, through monitoring and analysis of the average frame rate, intelligently judge whether it meets the expected conditions for increasing or decreasing the frame rate, thereby realizing the optimized adjustment and stable operation of the special effects barrage on different devices, significantly improving the user's interactive experience and video viewing quality.

[0064] As an optional solution, before performing an adjustment operation corresponding to the expected condition on the first running frame rate to obtain the second running frame rate, the method further includes:

[0065] Acquire a second number of the running windows whose average frame rate is less than a minimum threshold among the multiple running windows, and acquire a total number of the running windows included in the multiple running windows;

[0066] Calculate the second quantity and divide it by the total quantity to obtain the second proportion;

[0067] When the second proportion is greater than the second proportion threshold, it is determined that the average frame rates of the plurality of running windows meet the expected frame reduction condition, wherein the expected condition includes the expected frame reduction condition.

[0068] Optionally, in this embodiment, the lowest threshold is obtained by multiplying the expected frame rate by a preset parameter, and the preset parameter is greater than 0 and less than 1.

[0069] Optionally, in this embodiment, the minimum threshold is used to indicate the minimum frame rate standard for the special effects bullet screen running on the device, to ensure the smoothness of video playback or live interaction and avoid lag caused by the rendering of the special effects bullet screen. The preset parameter is a value between 0 and 1, which is used to calculate the minimum threshold, and is usually set between 0.6 and 0.8, reflecting the trade-off between the rendering performance of the special effects bullet screen and the smoothness of the main video screen.

[0070] Optionally, in this embodiment, the second number is the number of running windows whose average frame rate falls below a minimum threshold during the execution of the special effects bullet screen, used to measure whether the device's performance meets the basic requirements for bullet screen rendering. The second percentage is the ratio of the calculated second number to the total number of all running windows, used to determine whether the special effects bullet screen is running stably on the device and is key to determining whether to perform a frame rate reduction operation.

[0071] Optionally, in this embodiment, the number of running windows whose average frame rate is lower than the minimum threshold in multiple running windows is counted, that is, the second number. At the same time, the total number of the entire running window is collected. The setting of the minimum threshold is calculated based on the expected frame rate multiplied by a preset parameter. This parameter reflects the balance between device performance and special effects barrage rendering requirements. By calculating the ratio of the second number to the total number, a second proportion is obtained to determine whether the performance of the device during the special effects barrage operation is stable and whether it exceeds the threshold of the expected frame reduction condition, so as to perform a frame reduction operation when necessary.

[0072] Through the embodiments provided in this application, the device avoids the jamming phenomenon caused by setting the frame rate too high when processing complex special effects barrage. By setting the second ratio threshold, when the device performance is not up to standard for a long time, timely frame reduction measures can be taken to ensure the smooth playback of video or live content while maintaining the interactivity and visual effects of the barrage. Such a strategy not only improves the consistency of user experience, but also reduces the load on device resources, especially on low-end devices, effectively avoiding the performance bottleneck caused by special effects barrage rendering, thereby improving the user satisfaction and viewing experience of the entire platform.

[0073] As an optional solution, after obtaining the average frame rate of each running window of the special effect bullet screen during the expected time period, the method further includes:

[0074] When, among multiple running windows, there are continuous, at least a preset number of running windows whose average frame rates are lower than a minimum threshold, prompt information and guidance information are displayed, wherein the prompt information is used to prompt the special effects barrage to use the first running frame rate as the initial running frame rate on the running device, and the running results of the expected running time period meet the conditions for closing the special effects barrage, and the guidance information is used to guide the closing and premature termination of the running of the special effects barrage on the running device.

[0075] Optionally, in this embodiment, the preset number is a pre-set threshold value of the number of continuously running windows, which is used to determine whether the barrage closing condition is met, and is usually set to 3 to 5 windows to ensure the accuracy and stability of the adjustment decision.

[0076] Optionally, in this embodiment, the prompt information is used to warn the user that the current special effects barrage is not functioning well and may affect the video playback quality. The guidance information is used to guide the user on how to turn off the special effects barrage to reduce the device load and ensure smooth playback of the video or live content.

[0077] Optionally, in this embodiment, a check is performed to determine whether there are at least a preset number of consecutive running windows with an average frame rate below a minimum threshold. When this condition is met, the system is triggered to display a prompt and guidance message. The prompt message clearly informs the user that the current special effects barrage is not working well and may have a negative impact on video playback, while the guidance message provides detailed step-by-step instructions to help the user turn off the special effects barrage to reduce the load on the device and ensure smooth operation of the video or live broadcast content.

[0078] The embodiments provided in this application not only enhance the ability to respond to fluctuations in device performance, but also improve the user's ability to cope with insufficient performance through a friendly user interface design, avoiding video playback freezes caused by the display of special effects bullet screens, thereby achieving a balance between ensuring video smoothness and ensuring user experience. For users with limited device performance, this mechanism can significantly improve the consistency and satisfaction of video viewing, while also providing an effective means for platform resource management and performance optimization, ensuring the consistency and high-quality experience of special effects bullet screens running on various devices.

[0079] As an optional solution, obtain the average frame rate of each running window of the special effects bullet screen during the expected time period, including:

[0080] Obtaining a frame rate corresponding to each frame in a plurality of frames included in each running window, wherein each running window includes the same number of frames;

[0081] After summing the frame rates corresponding to each frame, the sum is divided by the number of frames included in each running window to obtain the average frame rate of each running window.

[0082] Optionally, in this embodiment, each running window is used to indicate a fixed time interval during the running of the special effects barrage, which is used to calculate the average frame rate. Multiple frames are a set of image frames rendered in the running window, and each frame corresponds to a specific rendering time point. The frame rate corresponding to each frame refers to the value obtained by reciprocating the time interval for the rendering of each frame during the rendering of the special effects barrage, reflecting the rendering speed of the special effects barrage. The average frame rate is used to indicate the average value obtained by summing the frame rates of all frames in a continuous running window and dividing it by the total number of frames in the window, which is used to evaluate the running efficiency of the special effects barrage on the device.

[0083] Optionally, in this embodiment, the frame rate corresponding to each frame in the running window is first collected. In order to ensure the consistency and comparability of the data, each running window is set to contain the same number of frames, which helps to eliminate the calculation deviation caused by the difference in the number of frames. Subsequently, the frame rates of all frames in each running window are summed and then divided by the number of frames in the window to obtain the average frame rate of the running window. This calculation process is a quantitative evaluation of the rendering efficiency of special effects barrage, which is used to monitor the performance of the device when processing special effects barrage, and provides a data basis for subsequent frame rate adjustment decisions.

[0084] Through the embodiments provided in this application, the operating efficiency of special effects barrage on different devices can be effectively monitored, ensuring accurate evaluation and intelligent adjustment of device performance. At the same time, through the refined management of the frame rate within each running window, it is possible to respond to changes in device performance in a timely manner, providing users with a stable and high-quality barrage experience. In particular, when processing complex special effects barrage, it is possible to intelligently optimize the frame rate setting to avoid resource waste or performance bottlenecks, thereby ensuring the smooth playback of video or live content, maximizing the visual effect of the barrage, and enhancing the immersiveness and smoothness of user interaction.

[0085] As an optional solution, the aforementioned frame rate adjustment method for special effects bullet screens can be applied to intelligent adaptive special effects bullet screen scenarios. In this scenario, through real-time frame rate monitoring and dynamic algorithms, the rendering frame rate of bullet screen special effects is adaptively adjusted, ensuring smoothness while also catering to the needs of devices with different performance capabilities. This ensures that basic special effects can run smoothly on low-end devices while retaining full special effects performance on high-end devices, achieving cross-device adaptive optimization of bullet screen special effects.

[0086] In this scenario, special effects bullet screens generally run at a fixed frame rate, unable to dynamically adjust based on device performance and bullet screen complexity, resulting in wasted resources or insufficient performance. This also fails to fully account for device hardware differences (such as GPU architecture and memory), leading to inconsistent experiences across devices. Manual optimization for different devices is often required, increasing development and maintenance costs.

[0087] To address the above-mentioned defects, this embodiment is based on the frame rate adjustment method of the above-mentioned special effect barrage. By constructing a multi-dimensional performance grading model and combining it with the barrage special effect complexity grading, it realizes dynamic frame rate adaptation of the special effect barrage, ensuring that a smooth and efficient barrage display effect can be obtained on devices with different performance.

[0088] Specifically, the framework diagram of the SDK and engine library for running special effects bullet screen is used as an example to illustrate. Figure 2 As shown,

[0089] The special effects bullet screen resource package is stored in the cloud and contains files such as images, text, video, special effects resources, and TypeScript scripts, all packaged in a compressed format. During runtime, the SDK will download the bullet screen resource package from the cloud, decompress it locally, and pass the local path of the resource package to the special effects bullet screen engine (lib library). After the engine loads the resources, it runs in the business module (such as on-demand and live broadcast). The TypeScript script is executed by the jscore engine, and ultimately renders and displays images, text, special effects and other resources as special effects bullet screen. In this process, real-time frame rate monitoring and dynamic adaptation are achieved. Performance grading is mainly achieved through the following steps:

[0090] Step 1: Obtain the listener for when the special effects bullet screen rendering starts and ends. Because the frame rate of the special effects bullet screen is actually rendered, it is necessary to exclude the frame rate interference before and after the rendering. Special effects bullet screen is based on the Cocos engine, and the rendering start and stop events can be monitored through the Cocos engine's cross-platform communication mechanism. Specific implementation methods may include:

[0091] In the case of the Android platform, the engine provides a "reflection-based mechanism to realize native communication between JavaScript and Android system" reflection mechanism to realize the communication between JS and Java layer. The Java static method is defined on the special effects barrage engine side. The special effects barrage script control side can call it by specifying the method name, method signature, and parameters.

[0092] In the case of iOS, the engine also provides a "reflection-based mechanism for communicating in JavaScript using Objective-C", creating a static method with the same name and parameter labels through Objective-C.

[0093] On PC, the engine uses JsbBridge communication technology to send JSON-formatted status events, including the event type and rendering status data. Finally, the TypeScript script controller notifies the SDK of the start and end of the special effects bullet screen in different ways based on the platform type, allowing for accurate capture of the rendering cycle.

[0094] Step 2: Obtain the real-time frame rate. This is achieved by customizing the Cocos engine lib code, obtaining and saving the real-time frame rate per second in the engine source code. On the Android platform, Java static methods can be exposed through JNI. On the iOS platform, the frame rate data can be read through a new C++ bridge method added to Objective-C. On the PC side, a C++ plug-in can be used to encapsulate the DLL / SO library to provide a frame rate query interface. Ultimately, the frame rate per second is obtained through the encapsulated interface.

[0095] Step 3: Use the sliding window algorithm to calculate the average frame rate. The main principle is as follows: maintain a fixed time window (such as the last 5 seconds), and only calculate the average frame rate data within the window. The window slides and updates as new data is added. The calculation formula for the average frame rate is as follows:

[0096]

[0097] Where Σ(frame rate) is the sum of the frame rates per second in the window within the unit time (e.g., if it is 5 seconds, then the sum of these 5 values ​​is taken). n is the total number of frames in the window (or the length of the time window, e.g., the number of frames in 5 seconds).

[0098] It should be noted that when the average frame rate in the window continues to be lower than the threshold (such as 30FPS) for more than N window cycles (such as 3 times), the prompt rate of the special effect barrage running poor effect is triggered, guiding the user to turn off the special effect barrage to save device memory and CPU, thereby ensuring the main business and improving user experience.

[0099] Step 4: Establish a dynamic frame rate adaptation mechanism to dynamically trigger the barrage refresh frame rate through a frame rate formula based on a sliding window and threshold determination.

[0100] The formula for the dynamic frame rate adaptation mechanism is as follows:

[0101]

[0102] Among them, the parameter θ 预期 is the expected threshold, for example 45FPS, parameter θ 最低 is the minimum threshold, for example 30FPS. Parameter N is the total number of windows (total duration / calculation step length), for example 12. Parameter AvgFPS k is the average frame rate of the kth window, I(x) is the conditional function, which is 1 if x meets the condition, otherwise it is 0, where x is the parameter AvgFPS k Greater than or equal to parameter θ 预期 or less than the parameter θ 最低 .

[0103] The calculation of the total number of windows N takes a total duration of 60 special effects bullet comments and an average frame rate of 5 seconds as an example. The final generalized formula is: if the total duration is T seconds and the step size is Δt seconds, then N = T / Δt.

[0104] Calculation example, assuming the following scenario:

[0105]

[0106] The total monitoring duration is T = 60 seconds, and the calculation step size is Δt = 5 seconds. N = 12 windows. The threshold θ = 45 FPS, and the pass rate ρ = 0.9. If the average frame rates of the 12 windows are as follows: [47, 47, 48, 46, 44, 49, 45, 47, 42, 48, 46, 47], the number of qualified windows is I (≥ 45) = 11, and the pass rate is 11 / 12 ≈ 0.91 > 0.9 → frame rate is increased.

[0107] If the frame rate detection results of 12 windows are: [47, 29, 48, 46, 28, 49, 45, 47, 25, 48, 46, 47], the windows below 30 FPS are: the 2nd, 5th, and 9th windows → 3 / 12 = 25% (does not reach the 30% threshold, so no frame rate drop).

[0108] The window to reach 45FPS: 8 / 12≈67% (does not reach the 90% threshold, no frame increase).

[0109] Final action: Maintain current frame rate.

[0110] If the fourth window also drops to 28 FPS (4 / 12≈33%): frame drop is triggered (because it exceeds the minimum threshold of 30%).

[0111] Step 5: Load matching: Based on the current device performance, the barrage special effects are registered, and the follow-up formula is used to determine the expected threshold and minimum threshold of the current special effects barrage on the device.

[0112] The expected threshold and the calculation formula of the minimum threshold are as follows:

[0113]

[0114] Among them, the parameter θ 预期 is the expected threshold, parameter θ 最低 is the minimum threshold, the parameter BaseFPS has a value range of 50 / 60, which is used to indicate the revised basic frame rate (for example, 50 for TV, 60 for mobile phone, 60 for tablet, and 60 for car machine), the parameter DeviceLevel has a value range of 0-3, which is used to indicate the device performance grade (for example, 0 for low-end devices, 1 for high-end devices, and 2 for flagship devices), the parameter EffectLevel has a value range of 1-5, which is used to indicate the revised special effects level (for example, simple text special effects correspond to 1, 2D particle / frame animation special effects correspond to 2, video animation special effects correspond to 3, and 3D effects special effects correspond to 5), and the parameter β is the minimum frame rate ratio coefficient, with a value range of 0.5-0.8, which can be dynamically configured.

[0115] For example, when playing 3D effects (EffectLevel=5) on a flagship phone (DeviceLevel=3) and the minimum frame rate ratio coefficient is 0.6 by default, θ 预期=60×(1+0.3)×(1-0.25)=58.5FPS, rounded up to 58FPS. 最低 =0.6×58.5=35.1FPS, and finally rounded to 35FPS.

[0116] Step 6: Set the frame rate before rendering the special effects barrage. The main method is to dynamically set the frame rate before rendering the special effects barrage through a new JNI interface. Specifically, a new JNI call interface is added to the barrage engine SDK layer for frame rate setting. The underlying layer expands and optimizes the original fixed frame rate setting interface through in-depth modification of the Cocos2d-x engine, realizing the special effects barrage SDK's ability to set the barrage rendering frame rate.

[0117] To further illustrate, a schematic diagram of an optional special effect bullet screen operation process is as follows: Figure 3 Shown, including:

[0118] S302, initialize the special effects barrage SDK;

[0119] S304, building a performance grading model based on device hardware (GPU / CPU), memory configuration, and terminal type;

[0120] S306, obtaining metadata of special effect bullet screen resources (classification type, resource file download address), downloading and decompressing the special effect resource package;

[0121] S308, determining whether the locally stored optimal frame rate for the classification is read;

[0122] S310: yes: set the bullet screen rendering frame rate to a local configuration value;

[0123] S312, No: Use the initial default frame rate (e.g., 60 FPS);

[0124] S314, starting the special effects bullet screen rendering engine and binding it to the video playback timeline;

[0125] S316, real-time monitoring of frame rate (start / end event trigger sampling);

[0126] S318, determining whether the frame rate is continuously too low for a long period of time;

[0127] S320: prompting the user that "special effects may cause lag" and guiding the user to turn off special effects to ensure the performance of the main service;

[0128] S322, No: The bullet screen playback is completed, and all real-time frame rates during the bullet screen operation are obtained;

[0129] S324, dynamic frame rate adjustment determination (determining whether to adjust the frame rate based on the algorithm and strategy);

[0130] S326, No: Read the current frame rate configuration;

[0131] S328: determining whether the frame rate needs to be reduced according to the algorithm;

[0132] S330, No: Determine whether the frame rate needs to be lowered or raised according to the algorithm; if the frame rate needs to be raised, then further execute S332; if the frame rate does not need to be raised, then keep the frame rate unchanged, and the operation ends ( Figure 3 (not continued in the middle);

[0133] S332 is: updating the optimal frame rate configuration of the special effect type;

[0134] S334, policy persistence, writes the optimized frame rate policy into the local configuration or synchronizes it to the cloud performance grading model (for prediction of other devices).

[0135] Through the embodiments provided in this application, real-time dynamic frame rate adaptation technology can effectively reduce frame rate fluctuations and significantly improve the stability of barrage display. At the same time, through the intelligent frame rate adjustment mechanism, while ensuring the smooth operation of core businesses such as live broadcast, the special effects barrage rendering performance optimization is achieved, so that the stuttering rate of low-end devices is effectively reduced, and the special effects expression of high-end devices is effectively improved, truly achieving a consistent experience across devices, so that all types of devices from entry-level to flagship level can obtain the best barrage display effect that matches their hardware performance, which not only avoids excessive loading of low-end devices, but also fully utilizes the hardware potential of high-end devices, and achieves a good balance between video playback smoothness, user interaction response speed and barrage special effects presentation quality.

[0136] It is understandable that in the specific implementation of this application, related data such as user information is involved. When the above embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards of relevant countries and regions.

[0137] It should be noted that for the aforementioned method embodiments, for the sake of simplicity, they are all expressed as a series of action combinations, but those skilled in the art should be aware that this application is not limited by the order of the actions described, because according to this application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by this application.

[0138] According to another aspect of the embodiment of the present application, a frame rate adjustment device for special effect barrage for implementing the frame rate adjustment method of special effect barrage is also provided. Figure 4 As shown, the device includes:

[0139] A first acquiring unit 402 is configured to acquire a first running frame rate that matches the special effect type of the special effect bullet screen and the device type of the running device, wherein the special effect bullet screen is used to run on the running device at the first running frame rate as an initial running frame rate for an expected period of time;

[0140] The second acquisition unit 404 is configured to acquire an average frame rate of each running window during the running of the special effect bullet screen in an expected time period, wherein the expected time period is divided into a plurality of running windows;

[0141] The adjustment unit 406 is used to perform an adjustment operation corresponding to the expected conditions on the first running frame rate when the average frame rate of multiple running windows meets the expected conditions, so as to obtain a second running frame rate, wherein other special effect barrages of the same special effect type as the special effect barrage use the second running frame rate as the initial running frame rate when the running device is running after the adjustment operation.

[0142] As an optional solution, the adjustment unit 406 includes:

[0143] a frame upscaling module configured to, when an average frame rate of a plurality of operating windows meets an expected frame upscaling condition, perform a frame upscaling operation corresponding to the expected frame upscaling condition on a first operating frame rate to obtain a third operating frame rate having a frame rate higher than the first operating frame rate; and determine the third operating frame rate as a second operating frame rate;

[0144] The frame reduction module is used to perform a frame reduction operation corresponding to the expected frame reduction condition on the first running frame rate when the average frame rate of multiple running windows meets the expected frame reduction condition, so as to obtain a fourth running frame rate whose frame rate is lower than the first running frame rate; and determine the fourth running frame rate as the second running frame rate.

[0145] As an optional solution, the device further includes:

[0146] a first acquisition module configured to, before performing an adjustment operation corresponding to an expected condition on the first running frame rate to obtain a second running frame rate, acquire a first number of running windows having an average frame rate greater than the expected frame rate among the multiple running windows, and acquire a total number of running windows included in the multiple running windows;

[0147] a first calculation module, configured to calculate the first quantity divided by the total quantity to obtain a first proportion before performing an adjustment operation corresponding to the expected condition on the first running frame rate to obtain a second running frame rate;

[0148] The first determination module is used to determine whether the average frame rate of multiple running windows meets the expected frame upgrade condition before performing an adjustment operation corresponding to the expected condition on the first running frame rate to obtain the second running frame rate, when the first proportion is greater than the first proportion threshold, wherein the expected condition includes the expected frame upgrade condition.

[0149] As an optional solution, the device further includes:

[0150] A second acquisition module is configured to acquire device performance parameters corresponding to the device type and special effect level parameters corresponding to the feature type before acquiring a first number of running windows whose average frame rate is greater than the expected frame rate among the multiple running windows;

[0151] The adjustment module is used to adjust the basic frame rate according to the device performance parameters and special effect level parameters to obtain the expected frame rate before obtaining the first number of running windows whose average frame rate is greater than the expected frame rate among multiple running windows and when the basic frame rate corresponding to the device type is obtained.

[0152] As an optional solution, the device further includes:

[0153] a third acquisition module, configured to, before performing an adjustment operation corresponding to the expected condition on the first running frame rate to obtain a second running frame rate, obtain a second number of running windows having an average frame rate less than a minimum threshold among the multiple running windows, and obtain a total number of running windows included in the multiple running windows;

[0154] a second calculation module, configured to calculate the second number and divide it by the total number to obtain a second proportion before performing an adjustment operation corresponding to the expected condition on the first running frame rate to obtain the second running frame rate;

[0155] The second determination module is used to perform an adjustment operation corresponding to the expected condition on the first running frame rate to obtain the second running frame rate, and before the second proportion is greater than the second proportion threshold, determine whether the average frame rate of multiple running windows meets the expected frame reduction condition, wherein the expected condition includes the expected frame reduction condition.

[0156] As an optional solution, the device further includes:

[0157] The display module is used to display prompt information and guidance information after obtaining the average frame rate of each running window during the running process of the special effect barrage in the expected time period. When there are continuous, at least a preset number of running windows with an average frame rate lower than a minimum threshold value among multiple running windows, the prompt information is used to prompt the special effect barrage to use the first running frame rate as the initial running frame rate on the running device, and the running result of the expected time period meets the closing condition of the special effect barrage, and the guidance information is used to guide the closing to terminate the running of the special effect barrage on the running device in advance.

[0158] As an optional solution, the second obtaining unit 404 includes:

[0159] a fourth acquisition module, configured to acquire a frame rate corresponding to each frame in a plurality of frames included in each running window, wherein each running window includes the same number of frames;

[0160] The third calculation module is configured to sum the frame rates corresponding to each frame and divide the sum by the number of frames included in each running window to obtain an average frame rate of each running window.

[0161] According to another aspect of the embodiment of the present application, an electronic device for implementing the frame rate adjustment method of the special effect barrage is further provided, Figure 5 As shown, the electronic device includes a memory 502 and a processor 504. The memory 502 stores a computer program, and the processor 504 is configured to execute the steps in any of the above method embodiments through the computer program.

[0162] Optionally, in this embodiment, the electronic device may be located in at least one network device among a plurality of network devices of a computer network.

[0163] Optionally, in this embodiment, the processor may be configured to execute the following steps through a computer program:

[0164] S1, obtaining a first running frame rate that matches the special effect type of the special effect bullet screen and the device type of the running device, wherein the special effect bullet screen is used to run on the running device at the first running frame rate as the initial running frame rate for an expected time period;

[0165] S2, obtaining an average frame rate of each running window during the running of the special effect bullet screen in the expected time period, wherein the expected time period is divided into multiple running windows;

[0166] S3, when the average frame rate of multiple running windows meets the expected conditions, an adjustment operation corresponding to the expected conditions is performed on the first running frame rate to obtain a second running frame rate, wherein other special effect barrages of the same special effect type as the special effect barrage use the second running frame rate as the initial running frame rate when the running device is running after the adjustment operation.

[0167] Alternatively, those skilled in the art will appreciate that Figure 5 The structure shown is for illustration only. Figure 5 It does not limit the structure of the above electronic device. For example, the electronic device may also include Figure 5 More or fewer components (such as network interfaces, etc.) as shown in, or with Figure 5 Different configurations shown.

[0168] Among them, the memory 502 can be used to store software programs and modules, such as the program instructions / modules corresponding to the frame rate adjustment method and device of the special effects barrage in the embodiment of the present application. The processor 504 executes various functional applications and data processing by running the software programs and modules stored in the memory 502, that is, realizing the above-mentioned frame rate adjustment method of the special effects barrage. The memory 502 may include a high-speed random access memory, and may also include a non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 502 may further include a memory remotely located relative to the processor 504, and these remote memories may be connected to the electronic device via a network. Examples of the above-mentioned networks include but are not limited to the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof. Among them, the memory 502 can be used to store, but is not limited to, information such as the first operating frame rate and the second operating frame rate. As an example, such as Figure 5 As shown, the memory 502 may include, but is not limited to, the first acquisition unit 402, the second acquisition unit 404, and the adjustment unit 406 in the frame rate adjustment device for special effect barrage. In addition, it may also include, but is not limited to, other module units in the frame rate adjustment device for special effect barrage, which will not be repeated in this example.

[0169] Optionally, the transmission device 506 is configured to receive or send data via a network. Specific examples of the network may include a wired network and a wireless network. In one embodiment, the transmission device 506 includes a network interface controller (NIC), which can be connected to other network devices and a router via a network cable to communicate with the Internet or a local area network. In one embodiment, the transmission device 506 is a radio frequency (RF) module, which is configured to communicate with the Internet wirelessly.

[0170] In addition, the electronic device further includes: a display 508 for displaying information such as the first operating frame rate and the second operating frame rate; and a connection bus 510 for connecting various module components in the electronic device.

[0171] In other embodiments, the client or server may be a node in a distributed system, wherein the distributed system may be a blockchain system, and the blockchain system may be a distributed system formed by connecting multiple nodes via network communication. The nodes may form a peer-to-peer network, and any computing device, such as a server, client, or other electronic device, may become a node in the blockchain system by joining the peer-to-peer network.

[0172] According to one aspect of the present application, a computer program product is provided, comprising a computer program / instructions containing program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network via a communication component and / or installed from a removable medium. When the computer program is executed by a central processing unit, the various functions provided in the embodiments of the present application are performed.

[0173] The serial numbers of the above embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.

[0174] It should be noted that the computer system of the electronic device is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0175] A computer system includes a central processing unit (CPU), which can perform various appropriate actions and processes based on programs stored in read-only memory (ROM) or programs loaded from the storage unit into random access memory (RAM). The RAM also stores various programs and data required for system operation. The CPU, the read-only memory, and the RAM are connected to each other via a bus. Input / output interfaces (I / O interfaces) are also connected to the bus.

[0176] The following components are connected to the input / output interface: an input section including a keyboard, mouse, etc.; an output section including a cathode ray tube (CRT), liquid crystal display (LCD), and speakers; a storage section including a hard disk; and a communication section including a network interface card such as a local area network card and a modem. The communication section performs communication processing via a network such as the Internet. A drive is also connected to the input / output interface as needed. Removable media such as magnetic disks, optical disks, magneto-optical disks, semiconductor memories, etc. are installed in the drive as needed so that computer programs read from them can be installed into the storage section as needed.

[0177] In particular, according to an embodiment of the present application, the processes described in the various method flow charts can be implemented as computer software programs. For example, an embodiment of the present application includes a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for executing the methods shown in the flow charts. In such an embodiment, the computer program can be downloaded and installed from a network via a communication portion, and / or installed from a removable medium. When the computer program is executed by a central processing unit, the various functions defined in the system of the present application are performed.

[0178] According to one aspect of the present application, a computer-readable storage medium is provided, and a processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the methods provided in the various optional implementations described above.

[0179] Optionally, in this embodiment, the computer-readable storage medium may be configured to store a computer program for performing the following steps:

[0180] S1, obtaining a first running frame rate that matches the special effect type of the special effect bullet screen and the device type of the running device, wherein the special effect bullet screen is used to run on the running device at the first running frame rate as the initial running frame rate for an expected time period;

[0181] S2, obtaining an average frame rate of each running window during the running of the special effect bullet screen in the expected time period, wherein the expected time period is divided into multiple running windows;

[0182] S3, when the average frame rate of multiple running windows meets the expected conditions, an adjustment operation corresponding to the expected conditions is performed on the first running frame rate to obtain a second running frame rate, wherein other special effect barrages of the same special effect type as the special effect barrage use the second running frame rate as the initial running frame rate when the running device is running after the adjustment operation.

[0183] Optionally, in this embodiment, a person of ordinary skill in the art may understand that all or part of the steps in the various methods of the above embodiments may be completed by instructing hardware related to the electronic device through a program, and the program may be stored in a computer-readable storage medium, which may include: a flash drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.

[0184] The serial numbers of the above embodiments of the present application are for description only and do not represent the advantages or disadvantages of the embodiments.

[0185] If the integrated units in the above embodiments are implemented in the form of software functional units and sold or used as independent products, they can be stored in the above-mentioned computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for enabling one or more computer devices (which can be personal computers, servers, or network devices, etc.) to execute all or part of the steps of the methods of each embodiment of the present application.

[0186] In the above embodiments of the present application, the description of each embodiment has its own focus. For parts that are not described in detail in a certain embodiment, please refer to the relevant description of other embodiments.

[0187] In the several embodiments provided in this application, it should be understood that the recorded client can be implemented in other ways. Among them, the device embodiments described above are merely illustrative. For example, the division of units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of units or modules, which can be electrical or other forms.

[0188] Units described as separate components may or may not be physically separate, and components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0189] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0190] The above is only a preferred embodiment of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.

Claims

1. A method for adjusting the frame rate of a special effect bullet screen, characterized in that: include: Obtaining a first running frame rate that matches the special effect type of the special effect bullet screen and the device type of the running device, wherein the special effect bullet screen is used to run on the running device at the first running frame rate as the initial running frame rate for an expected period of time; Obtaining an average frame rate of each running window of the special effect bullet screen during the running process of the expected time period, wherein the expected time period is divided into multiple running windows; When the average frame rate of the multiple running windows meets the expected conditions, an adjustment operation corresponding to the expected conditions is performed on the first running frame rate to obtain a second running frame rate, wherein, after the adjustment operation, other special effect barrages of the same special effect type as the special effect barrage use the second running frame rate as the initial running frame rate when the running device is running.

2. The method according to claim 1, characterized in that Before performing an adjustment operation corresponding to the expected condition on the first running frame rate to obtain a second running frame rate, the method further includes: Acquire a first number of the running windows whose average frame rate is greater than the expected frame rate among the multiple running windows, and acquire a total number of the running windows included in the multiple running windows; Calculate the first quantity and divide it by the total quantity to obtain a first proportion; When the first proportion is greater than a first proportion threshold, it is determined that the average frame rates of the multiple running windows meet the expected frame rate increase condition, wherein the expected condition includes the expected frame rate increase condition.

3. The method according to claim 2, characterized in that Before obtaining a first number of the running windows whose average frame rate is greater than the expected frame rate among the multiple running windows, the method further includes: Obtaining device performance parameters corresponding to the device type, and obtaining special effect level parameters corresponding to the feature type; When the basic frame rate corresponding to the device type is obtained, the basic frame rate is adjusted according to the device performance parameter and the special effect level parameter to obtain the expected frame rate.

4. The method according to claim 1, wherein Before performing an adjustment operation corresponding to the expected condition on the first running frame rate to obtain a second running frame rate, the method further includes: Acquire a second number of the running windows whose average frame rates are less than a minimum threshold value among the multiple running windows, and acquire a total number of the running windows included in the multiple running windows; Calculate the second quantity and divide it by the total quantity to obtain a second proportion; When the second proportion is greater than a second proportion threshold, it is determined that the average frame rates of the multiple running windows meet the expected frame reduction condition, wherein the expected condition includes the expected frame reduction condition.

5. The method according to any one of claims 1 to 4, characterized in that After obtaining the average frame rate of each running window of the special effect bullet screen during the expected time period, the method further includes: When, among the multiple running windows, there are continuous running windows with an average frame rate of at least a preset number being lower than a minimum threshold, prompt information and guidance information are displayed, wherein the prompt information is used to prompt the special effects barrage to use the first running frame rate as the initial running frame rate on the running device, and the running result of the expected running time period meets the conditions for closing the special effects barrage, and the guidance information is used to guide the closing and premature termination of the running of the special effects barrage on the running device.

6. The method according to any one of claims 1 to 4, characterized in that The step of obtaining the average frame rate of each running window of the special effect bullet screen during the running of the expected time period includes: Obtaining a frame rate corresponding to each frame among a plurality of frames included in each running window, wherein each running window includes the same number of frames; After summing the frame rates corresponding to each frame, the sum is divided by the number of frames included in each running window to obtain an average frame rate of each running window.

7. The method according to any one of claims 1 to 4, characterized in that When the average frame rates of the plurality of running windows meet the expected condition, performing an adjustment operation corresponding to the expected condition on the first running frame rate to obtain a second running frame rate includes: When the average frame rates of the plurality of operating windows meet an expected frame rate increase condition, performing a frame increase operation corresponding to the expected frame rate increase condition on the first operating frame rate to obtain a third operating frame rate having a frame rate higher than the first operating frame rate; and determining the third operating frame rate as the second operating frame rate; When the average frame rates of the multiple running windows meet the expected frame rate reduction conditions, a frame reduction operation corresponding to the expected frame rate reduction conditions is performed on the first running frame rate to obtain a fourth running frame rate whose frame rate is lower than the first running frame rate; and the fourth running frame rate is determined as the second running frame rate.

8. A frame rate adjustment device for special effect bullet screen, characterized in that: include: A first acquiring unit is configured to acquire a first running frame rate that matches a special effect type of the special effect bullet screen and a device type of a running device, wherein the special effect bullet screen is used to run on the running device at the first running frame rate as an initial running frame rate for an expected period of time; A second acquiring unit is configured to acquire an average frame rate of each running window of the special effect bullet screen during the running process of the expected time period, wherein the expected time period is divided into a plurality of running windows; An adjustment unit is used to perform an adjustment operation corresponding to the expected conditions on the first running frame rate when the average frame rate of the multiple running windows meets the expected conditions, so as to obtain a second running frame rate, wherein, after the adjustment operation, other special effect bullet screens of the same special effect type as the special effect bullet screen use the second running frame rate as the initial running frame rate when the running device is running.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein the program is executed by an electronic device to perform the method according to any one of claims 1 to 7.

10. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to execute the method according to any one of claims 1 to 7 through the computer program.