Bullet screen display method and device, storage medium and electronic equipment

By identifying the attributes of the target element in the video, and automatically matching and playing associated barrage special effects, the problem of single barrage display solidification is solved, achieving flexibility and user experience improvement of barrage display.

CN119316651APending Publication Date: 2025-01-14TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202310852256.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-07-11
Publication Date
2025-01-14

AI Technical Summary

Technical Problem

In the prior art, the barrage display effect is solidified in a single manner, and the barrage display with user-defined and unified configuration of the platform requires manual operation, which is costly and error-prone, and lacks flexibility.

Method used

By identifying the attributes of the target element in the video display area, automatically match and play the associated barrage display special effects, and adjust the barrage display style to achieve dynamic and diverse barrage display.

Benefits of technology

It improves the flexibility of barrage display, reduces configuration complexity, avoids the single curing effect caused by manual operation, and improves the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119316651A_ABST
    Figure CN119316651A_ABST
Patent Text Reader

Abstract

The invention discloses a bullet screen display method and device, a storage medium and electronic equipment. The method comprises the following steps: playing a target video in a video display area; determining a bullet screen display special effect matched with the element attribute of the target element and a video frame sequence associated with the target element under the condition that the target element is identified from the currently played video content in the video display area; and at least one object bullet screen appearing in the video display area when the video frame sequence is played is displayed after the display style is adjusted according to the bullet screen display special effect. The technical problem that the bullet screen display effect is solidified and single in the prior art 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 bullet screen display method and device, a storage medium, and an electronic device. Background Art

[0002] Nowadays, when many users are watching a selected target video on a video playback platform, they often see comments from other users while watching the target video. At present, the barrage display effects provided by various video playback platforms are relatively fixed, usually including the following two types: 1) The display style of the barrage issued by the user is customized; 2) During important time nodes such as traditional holidays, the platform uniformly configures the display style of the barrage, such as Kongming lanterns, star light boards, fireworks and other fancy barrages, and uniformly cancels the above fancy barrages after the above important time nodes.

[0003] However, whether it is the user-defined display style of the bullet screen or the platform uniformly configures the fancy bullet screen, these bullet screen display effects are manually configured, the configuration operation is costly and prone to errors. Furthermore, if the bullet screen is still displayed in the manner provided by the above-mentioned related technologies, it can only be displayed in a pre-defined or configured display style, and there is a problem that the bullet screen display effect is relatively fixed and single.

[0004] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention

[0005] The embodiments of the present application provide a bullet screen display method and device, a storage medium, and an electronic device to at least solve the technical problem of the fixed and single bullet screen display effect existing in the prior art.

[0006] According to one aspect of an embodiment of the present application, a barrage display method is provided, including: playing a target video in a video display area; when a target element is identified from the video content currently playing in the above-mentioned video display area, determining a barrage display special effect that matches the element attributes of the above-mentioned target element, and a video frame sequence associated with the above-mentioned target element; and displaying at least one object barrage that appears in the above-mentioned video display area when the above-mentioned video frame sequence is played, adjusting the display style according to the above-mentioned barrage display special effect.

[0007] According to another aspect of an embodiment of the present application, a barrage display device is also provided, including: a playback unit, used to play a target video in a video display area; a determination unit, used to determine a barrage display special effect that matches the element attributes of the above target element, and a video frame sequence associated with the above target element when a target element is identified from the video content currently playing in the above video display area; a display unit, used to display at least one object barrage that appears in the above video display area when the above video frame sequence is played, after adjusting the display style according to the above barrage display special effect.

[0008] According to another aspect of the embodiments of the present application, a computer-readable storage medium is provided, in which a computer program is stored, wherein the computer program is configured to execute the above-mentioned bullet screen display method when running.

[0009] According to another aspect of the embodiments of the present application, a computer program product or a computer program is provided, the computer program product or the computer program including computer instructions, the computer instructions being stored in a computer-readable storage medium. 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 above bullet screen display method.

[0010] According to another aspect of an embodiment of the present application, there is also provided an electronic device, including a memory and a processor, wherein a computer program is stored in the memory, and the processor is configured to execute the barrage display method through the computer program.

[0011] In an embodiment of the present application, a target video is played in a video display area, and then when a target element is identified from the video content currently playing in the video display area, a bullet screen display effect that matches the element attributes of the target element and a video frame sequence associated with the target element are determined. Then, at least one object bullet screen that appears in the video display area when the video frame sequence is played is displayed after adjusting the display style according to the bullet screen display effect. In other words, in an embodiment of the present application, when the target element is identified, the bullet screen display effect corresponding to the target element is automatically obtained, and then the object bullet screen adjusted based on the bullet screen display effect is automatically displayed when the video frame sequence is played. This avoids the problem of relatively solidified and single effects caused by manually configuring the bullet screen display effect, and also reduces the operational complexity of the bullet screen display configuration. Thereby achieving the technical effect of improving the flexibility of the displayed bullet screen display effect and simplifying the operational complexity of the bullet screen display configuration. BRIEF DESCRIPTION OF THE DRAWINGS

[0012] 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:

[0013] Figure 1 is a schematic diagram of an application environment of an optional bullet screen display method according to an embodiment of the present application;

[0014] Figure 2 is a flowchart of an optional bullet screen display method according to an embodiment of the present application;

[0015] Figure 3 is a schematic diagram of an optional bullet screen display method according to an embodiment of the present application;

[0016] Figure 4 is a schematic diagram of another optional bullet screen display method according to an embodiment of the present application;

[0017] Figure 5 is a schematic diagram of another optional bullet screen display method according to an embodiment of the present application;

[0018] Figure 6 is a schematic diagram of another optional bullet screen display method according to an embodiment of the present application;

[0019] Figure 7 is a schematic diagram of another optional bullet screen display method according to an embodiment of the present application;

[0020] Figure 8 is a schematic diagram of another optional bullet screen display method according to an embodiment of the present application;

[0021] Fig. 9 is a schematic diagram of another optional bullet screen display method according to an embodiment of the present application;

[0022] Fig.10 is a schematic diagram of another optional bullet screen display method according to an embodiment of the present application;

[0023] Fig.11 is a flowchart of an optional bullet screen display method according to an embodiment of the present application;

[0024] Fig.12 is a schematic diagram of an optional bullet screen display method according to an embodiment of the present application;

[0025] Fig.13 is a flowchart of an optional bullet screen display method according to an embodiment of the present application;

[0026] Fig.14 is a schematic structural diagram of an optional bullet screen display device according to an embodiment of the present application;

[0027] Fig.15 It is a schematic diagram of the structure of an optional electronic device according to an embodiment of the present application. DETAILED DESCRIPTION

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

[0029] 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 sequence. 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 an order 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.

[0030] According to one aspect of an embodiment of the present application, a bullet screen display method is provided. Optionally, as an optional implementation, the bullet screen display method can be but is not limited to being applied to: Figure 1 In the environment shown. Figure 1 As shown, the terminal device 102 includes a memory 104 for storing various data generated during the operation of the terminal device 102, a processor 106 for processing and calculating the above data, and a display 108 for displaying the target video. The terminal device 102 can exchange data with a server 112 through a network 110. The server 112 is connected to a database 114, and the database 114 is used to store various data. The terminal device 102 can run a client or website for displaying the target video.

[0031] Furthermore, the above method Figure 1 The corresponding specific application process in the environment shown is shown in the following steps:

[0032] Steps S102-S104 are executed, and the terminal device 102 sends a request message for requesting the bullet screen display special effect to the server 112 through the network 110. When the server 112 obtains the request message, the bullet screen display special effect is sent to the terminal device 102 through the network 110;

[0033] Next, steps S106-S108 are executed to play the target video in the video display area of ​​the terminal device 102. Further, when a target element is identified from the video content currently played in the video display area, a bullet screen display effect matching the element attribute of the target element and a video frame sequence associated with the target element are determined.

[0034] Further, step S110 is executed to display at least one object bullet screen that appears in the video display area when playing the video frame sequence after adjusting the display style according to the bullet screen display special effect.

[0035] In this embodiment, the target video is played in the video display area, and then when the target element is identified from the video content currently playing in the video display area, the bullet screen display special effects that match the element attributes of the target element and the video frame sequence associated with the target element are determined. Then, at least one object bullet screen that appears in the video display area when the video frame sequence is played is displayed after adjusting the display style according to the bullet screen display special effects. In other words, in an embodiment of the present application, when the target element is identified, the bullet screen display special effects corresponding to the target element are automatically obtained, and then the object bullet screen adjusted based on the bullet screen display special effects is automatically displayed when the video frame sequence is played. This avoids the problem of relatively solidified and single effects caused by manually configuring the bullet screen display effects, and also reduces the operational complexity of the bullet screen display configuration. Thereby achieving the technical effect of improving the flexibility of the displayed bullet screen display effects and simplifying the operational complexity of the bullet screen display configuration.

[0036] Optionally, in this embodiment, the terminal device may be a terminal device configured with a target client, which may include but is not limited to at least one of the following: a mobile phone (such as an Android phone, an iOS phone, etc.), a laptop, a tablet computer, a PDA, a MID (Mobile Internet Devices), a PAD, a desktop computer, a smart TV, etc. The target client may be a video client, an instant messaging client, a browser client, an education client, etc. The network may include but is not limited to: a wired network, a wireless network, wherein the wired network includes: a local area network, a metropolitan area network and a wide area network, and the wireless network includes: Bluetooth, WIFI and other networks that realize wireless communication. The server may be a single server, or a server cluster consisting of multiple servers, or a cloud server. The above is only an example, and this embodiment does not impose any limitation on this.

[0037] Optionally, as an optional implementation, as Figure 2 As shown, the above bullet screen display method includes:

[0038] S202, playing the target video in the video display area;

[0039] S204, when a target element is identified from the video content currently being played in the video display area, determining a bullet screen display special effect that matches the element attribute of the target element, and a video frame sequence associated with the target element;

[0040] S206, displaying at least one object bullet screen that appears in the video display area when playing the video frame sequence after adjusting the display style according to the bullet screen display special effects.

[0041] Optionally, as an optional implementation, the above bullet screen display method can be applied to, but is not limited to, video playback scenarios. For example, in a video playback scenario on a web page or in a video playback scenario on a client, based on the target element identified in the video content, the object bullet screen displayed on the video being played is adjusted according to the bullet screen display special effects corresponding to the target element.

[0042] Optionally, as another optional implementation, the above bullet screen display method can be but is not limited to being applied in a live broadcast scene. For example, when displaying a live broadcast screen, according to the target element identified in the live broadcast screen, the object bullet screen displayed on the live broadcast screen is adjusted according to the bullet screen display special effect corresponding to the target element.

[0043] Furthermore, the video display area may be, but is not limited to, used to indicate an area for displaying a target video. Assuming that the bullet screen display method is applied to a video playback scenario, the video display area may be, but is not limited to, used to indicate an area for displaying a target video on a website, or an area for displaying a target video on a client.

[0044] It should be noted that the above video content may include, but is not limited to: picture frames corresponding to the target video, audio frames corresponding to the target video, etc. Specifically, the above picture frames include: the playback picture corresponding to the target video, and the subtitle information corresponding to the target video. The above audio frames include: the audio information corresponding to the target video.

[0045] Optionally, the target element may include, but is not limited to: an image element displayed in the playback screen corresponding to the target video, such as a flame image element, an iceberg image element, a fireworks image element, etc. In this embodiment, no limitation is made to this. The target element may also include: a specified keyword included in the subtitle information corresponding to the target video, such as flame, iceberg, fireworks, etc. In this embodiment, no limitation is made to this.

[0046] Furthermore, the above element attributes may be used, but are not limited to, to indicate the natural attributes of the above target element. For example, assuming that the above target element is a flame image element, the physical attributes of the flame image element may include: "hot air rises", "objects expand and contract with heat", "smoke", "sparks", etc. Assuming that the above target element is a river image element, the physical attributes of the river image element may include: "flowing with the waves", etc.

[0047] It should be noted that the video frame sequence associated with the target element here may include, but is not limited to: the first video frame when the first character in the object barrage moves into the element display area, the second video frame when the last character in the object barrage moves out of the element display area, and all video frames between the first video frame and the second video frame. Optionally, the video frame sequence associated with the target element may also include: the first video frame in which the target element appears, i.e., the third video frame, the last video frame before the target element disappears, i.e., the fourth video frame, and all video frames between the third video frame and the fourth video frame. Optionally, the video frame sequence associated with the target element may also include: the first video frame when the first character in the object barrage moves into the element display area, the last video frame before the object barrage disappears in the video display area, i.e., the fifth video frame, and all video frames between the first video frame and the fifth video frame. In the embodiment of the present application, no limitation is imposed on this.

[0048] Optionally, as an optional implementation, the bullet screen display special effects here can be, but are not limited to, used to indicate bullet screen display special effects that match the element attributes of the target element. For example, assuming that the above-mentioned target element is a flame image element, the element attributes corresponding to the flame image element include: "flashing sparks", "hot air rising", "object thermal expansion and contraction", "smoke", etc. Then the above-mentioned bullet screen display special effects can be one or more of the "flashing sparks" special effects, "hot air rising" special effects, "object thermal expansion and contraction" special effects, and "smoke" special effects. Specifically, sparks will be displayed around the object bullet screen adjusted according to the "flashing sparks" special effect; the movement trajectory of the object bullet screen adjusted according to the "hot air rising" special effect in the video display area will be affected by the flame image element and change with the change of the flame image element; the font displayed by the object bullet screen adjusted according to the "object thermal expansion and contraction" special effect will become larger; smoke will be displayed around the object bullet screen adjusted according to the "smoke" special effect.

[0049] Assuming that the target element is a river image element, the element attributes corresponding to the river image include: "flow with the waves". Then the above bullet screen display special effect can be "flow with the waves". Specifically, the object bullet screen adjusted according to the "flow with the waves" special effect will rise and fall like leaves in the water or move with the water like paper soaked in water.

[0050] Assuming that the target element is the flame keyword element, the element attributes corresponding to the flame keyword element include: "flashing sparks", "hot air rising", "objects expanding and contracting", "smoke", etc. Correspondingly, the above bullet screen display special effects can be one or more of the "flashing sparks", "hot air rising", "objects expanding and contracting", and "smoke".

[0051] Assuming that the target element is a river keyword element, the element attributes corresponding to the river keyword element include: "flow with the waves". Then the above bullet screen display effect can be "flow with the waves".

[0052] Optionally, as an optional implementation, it is assumed that the above video frame sequence includes the first video frame in which the target element appears, that is, the third video frame, the last video frame before the target element disappears, that is, the fourth video frame, and all video frames between the third video frame and the fourth video frame. It is assumed that the target element is a flame image element included in the picture frame of the target video. The above bullet screen display method is fully illustrated by the following steps:

[0053] Play the target video in the video display area;

[0054] Furthermore, when a flame image element is identified from the picture frames currently playing in the video display area, it is determined that the barrage display special effect that matches the element attributes of the flame image element (i.e., "flashing sparks") is the "flashing sparks" special effect, and it is determined that the video frame sequence associated with the target element includes: the first video frame in which the flame image element appears, i.e., the third video frame, the last video frame before the flame image element disappears, i.e., the fourth video frame, and all video frames between the third video frame and the fourth video frame (that is, the picture frames in which the flame image element exists, i.e., the video frames belonging to the video frame sequence).

[0055] Then, if Figure 3 As shown in (a) to (b), the object barrage (i.e., "The flames are so strong!") that appears in the video display area when the video frame sequence is played will be displayed after adjusting the display style according to the "Mars" special effect, wherein the object barrage is in a linear motion state in the video display area.

[0056] In an embodiment of the present application, a target video is played in a video display area, and then when a target element is identified from the video content currently playing in the video display area, a bullet screen display effect that matches the element attributes of the target element and a video frame sequence associated with the target element are determined. Then, at least one object bullet screen that appears in the video display area when the video frame sequence is played is displayed after adjusting the display style according to the bullet screen display effect. In other words, in an embodiment of the present application, when the target element is identified, the bullet screen display effect corresponding to the target element is automatically obtained, and then the object bullet screen adjusted based on the bullet screen display effect is automatically displayed when the video frame sequence is played. This avoids the problem of relatively solidified and single effects caused by manually configuring the bullet screen display effect, and also reduces the operational complexity of the bullet screen display configuration. Thereby achieving the technical effect of improving the flexibility of the displayed bullet screen display effect and simplifying the operational complexity of the bullet screen display configuration.

[0057] As an optional solution, at least one object bullet screen that appears in the video display area when playing the video frame sequence is displayed after adjusting the display style according to the bullet screen display special effect, including:

[0058] S1, when the object bullet screen is configured as an element following display mode, determining an element display area where a target element is located in a video display area;

[0059] S2, when the object bullet screen moves to the element display area, switching the object bullet screen from a default display style to a special effect display style that matches the bullet screen display special effect;

[0060] S3, displays the object bullet screen in a special effect display style.

[0061] It should be noted that the following mode here can be used, but is not limited to, to indicate that the display style of the object bullet chat follows the switching of the target element. That is, when the object bullet chat moves to the display area of ​​the target element, the display style will be switched to a special effect display style that matches the bullet chat display special effect.

[0062] As an optional implementation, assuming that the bullet screen is configured as an element following display mode, assuming that the target element is a flame image element included in the picture frame of the target video. The above bullet screen display method is explained by the following steps:

[0063] like Figure 4 As shown in (a), the element display area where the target element is located in the video display area is determined to be 402, and the display style of the current object bullet screen 404 is the default display style. Then, as Figure 4 As shown in (b), when the object bullet screen 404 moves to the element display area 402, the object bullet screen is switched from the default display style to the "Mars" special effect. Figure 4 From the current video frame shown in (b) to the last video frame before the last character of the object barrage disappears as shown in (c), the object barrage 406 under the "Mars" special effect is displayed.

[0064] In an embodiment of the present application, when the object barrage is configured as the element follow display mode, the element display area where the target element is located in the video display area is determined. Then, when the object barrage moves to the element display area, the object barrage is switched from the default display style to a special effect display style that matches the barrage display special effect. Then, the object barrage under the special effect display style is displayed. In other words, in an embodiment of the present application, the object barrage can automatically switch from the default display style to a special effect display style that matches the barrage display special effect when entering the area where the target element is located. Thereby, the display style switching of the object barrage is made more flexible, thereby achieving the technical effect of improving the flexibility of the barrage display effect.

[0065] As an optional solution, after displaying the object bullet screen in the special effect display style, it also includes:

[0066] S1, when all characters in the object bullet screen leave the element display area, switching the object bullet screen from the special effect display style to the default display style;

[0067] S2, displays the object bullet screen in the default display style.

[0068] As an optional implementation, assuming that the bullet screen is configured as an element following display mode, assuming that the target element is a flame image element included in the picture frame of the target video. The above bullet screen display method is explained by the following steps:

[0069] like Figure 5 As shown in (a), the element display area where the target element is located in the video display area is determined, and the display style of the current object bullet screen is the default display style. Then, Figure 5 As shown in (b), when the object barrage moves to the element display area, the object barrage is switched from the default display style to the display style of the "Mars" special effect, and the object barrage under the "Mars" special effect is displayed.

[0070] Then, if Figure 5 As shown in (c), when all characters in the object bullet comment leave the element display area, the object bullet comment in the default display style is displayed.

[0071] In an embodiment of the present application, when all characters in the object barrage leave the element display area, the object barrage is switched from the special effect display style to the default display style. The object barrage under the default display style is displayed. In other words, in an embodiment of the present application, the object barrage can automatically switch from the default display style to the special effect display style that matches the barrage display special effect when entering the area where the target element is located. When leaving the area where the target element is located, it automatically switches from the special effect display style to the default display style. This makes the display style switching of the object barrage more flexible, thereby achieving the technical effect of improving the flexibility of the barrage display effect.

[0072] As an optional solution, determining a video frame sequence associated with the target element includes:

[0073] S1, determining a first video frame when the first character in the object bullet comment moves into the element display area, and a second video frame when the last character in the object bullet comment moves out of the element display area;

[0074] S2: determining the video frames from the first video frame to the second video frame as a video frame sequence.

[0075] For example, suppose the target element is a flame image element, and the target comment is "The flame is so strong". Figure 6 The first video frame when the first character (ie, "fire") in the object barrage shown moves into the element display area. Figure 7 The second video frame is when the last character (ie, "ah") in the object bullet screen shown moves out of the element display area. Then, the video frames from the first video frame to the second video frame are determined as a video frame sequence.

[0076] In an embodiment of the present application, the first video frame when the first character in the object barrage moves into the element display area, and the second video frame when the last character in the object barrage moves out of the element display area are determined. The video frames from the first video frame to the second video frame are determined as a video frame sequence. This ensures that in the follow display mode, the object barrage can switch from the default display style to a special effect display style that matches the barrage display special effect when entering the area where the target element is located. This makes the display style switching of the object barrage more flexible, thereby achieving the technical effect of improving the flexibility of the barrage display effect.

[0077] As an optional solution, at least one object bullet screen that appears in the video display area when playing the video frame sequence is displayed after adjusting the display style according to the bullet screen display special effect, including:

[0078] S1, when the object bullet screen is not configured as an element following display mode, switching the object bullet screen from a default display style to a special effect display style that matches the bullet screen display special effect;

[0079] S2, before all characters in the object bullet comment exit the video display area, display the object bullet comment in a special effect display style.

[0080] It should be noted that when the object barrage is not configured as the element follow display mode, if there is both the object barrage and the target element in the video display area, the object barrage will be switched from the default display style to a special effect display style that matches the barrage display special effects.

[0081] As an optional implementation, assuming that the bullet screen is configured as an element that is not set to a follow display mode, and assuming that the target element is a flame image element included in the picture frame of the target video. The above bullet screen display method is explained by the following steps:

[0082] Determine the element display area where the target element is located in the video display area. Then, when the video display area includes the flame image element and the object bullet screen moves to the video display area, switch the object bullet screen from the default display style to the display style of the "Mars" special effect, and display the object bullet screen under the "Mars" special effect.

[0083] In an embodiment of the present application, when the object bullet screen is not configured as an element following display mode, the object bullet screen is switched from the default display style to a special effect display style that matches the bullet screen display special effect. Furthermore, before all characters in the object bullet screen exit the video display area, the object bullet screen in the special effect display style is displayed. This makes the display style switching of the object bullet screen more flexible, thereby achieving the technical effect of improving the flexibility of the bullet screen display effect.

[0084] As an optional solution, determining a video frame sequence associated with the target element includes:

[0085] S1, taking the first video frame where the target element appears as the third video frame, and taking the last video frame before the target element disappears as the fourth video frame;

[0086] S2: determine the video frames from the third video frame to the fourth video frame as a video frame sequence.

[0087] For example, assuming that the first video frame in which the target element appears is the Nth video frame in the target video, and assuming that the last video frame before the target element disappears is the N+6th video frame in the target video. The above method includes: determining the Nth video frame in the target video, the N+6th video frame in the target video, and all video frames between the Nth video frame and the N+6th video frame (including: the N+1th video frame, the N+2th video frame, the N+3th video frame, the N+4th video frame, and the N+5th video frame) as a video frame sequence. Wherein, N is a positive integer.

[0088] In an embodiment of the present application, the first video frame in which the target element appears is used as the third video frame, and the last video frame before the target element disappears is used as the fourth video frame. The video frames from the third video frame to the fourth video frame are determined as a video frame sequence. This ensures that the object bullet screen can display a special effect display style before the historical video display area when the target element appears in the target video in a non-follow display mode. This makes the display style switching of the object bullet screen more flexible, thereby achieving a technical effect of improving the flexibility of the bullet screen display effect.

[0089] As an optional solution, at least one object bullet screen that appears in the video display area when playing the video frame sequence is displayed after adjusting the display style according to the bullet screen display special effect, including:

[0090] According to the barrage display special effects, each character contained in the object barrage is adjusted to a display style that matches the element attributes of the target element to obtain adjusted special effect barrage characters, wherein the special effect barrage characters will present a simulation effect corresponding to the element attributes.

[0091] For example, assuming that the target element is a flame image element, the element attributes corresponding to the flame image element include: "flashing sparks", "hot air rising", "object thermal expansion and contraction", "smoke", etc. Then the barrage display special effects can be one or more of the "flashing sparks" special effects, "hot air rising" special effects, "object thermal expansion and contraction" special effects, and "smoke" special effects. Specifically, sparks will be displayed around the object barrage adjusted according to the "flashing sparks" special effect; the movement trajectory of the object barrage adjusted according to the "hot air rising" special effect in the video display area will be affected by the flame image element and change with the change of the flame image element; the font displayed by the object barrage adjusted according to the "object thermal expansion and contraction" special effect will become larger; smoke will be displayed around the object barrage adjusted according to the "smoke" special effect. Assuming that the target element is a river image element, the element attributes corresponding to the river image element include: "flow with the waves". Then the barrage display special effect can be "flow with the waves". Specifically, the object barrage adjusted according to the "flow with the waves" special effect will rise and fall like leaves in the water or move with the water like paper soaked in water.

[0092] In the embodiment of the present application, according to the barrage display special effects, each character contained in the object barrage is adjusted to a display style that matches the element attribute of the target element, and the adjusted special effect barrage characters are obtained, wherein the special effect barrage characters will present the simulation effect corresponding to the element attribute. This makes the display form of the object barrage more abundant, thereby achieving the technical effect of improving user interest.

[0093] As an optional solution, when a target element is identified from the video content currently being played in the video display area, determining a bullet screen display special effect that matches an element attribute of the target element includes:

[0094] S1, performing element recognition on a picture frame sequence corresponding to the currently played video content;

[0095] S2, determining an element identifier of the target element based on an element contour of the target element identified from a key picture frame of the picture frame sequence;

[0096] S3, searching for a target bullet screen special effect file that matches the element identifier of the target element in a special effect file library, wherein the special effect file library includes multiple bullet screen special effect files, and the bullet screen special effect file includes element attributes of the target element and coloring information for rendering the bullet screen display special effect;

[0097] S4, when the target barrage special effect file is found, determine to use the target barrage special effect file to provide barrage display special effects for the object barrage.

[0098] It should be noted that the key picture frame here can be but is not limited to being used to indicate the picture frame including the object barrage in the video display area.

[0099] Optionally, the above-mentioned element recognition of the picture frame sequence corresponding to the currently played video content may include but is not limited to: using the image recognition tool OpenCV to perform edge detection on the picture frame sequence corresponding to the previously played video content to obtain the element contour of the target element.

[0100] Furthermore, based on the element contour of the target element identified from the key picture frames of the picture frame sequence, determining the element identification of the target element may include but is not limited to: based on the element contour of the target element identified from the key picture frames of the picture frame sequence, determining the element type of the element of the target element, and then determining the element identification of the target element.

[0101] It should be noted that the above-mentioned special effects file library can be, but is not limited to, a special effects file library that is obtained in advance from a server and stored locally.

[0102] Optionally, the above element attributes may be, but are not limited to, used to indicate the physical properties of the target element, and the above coloring information for rendering the bullet screen display special effects may be, but are not limited to, used to indicate the background code for rendering the bullet screen display special effects.<key,value> stored in the form of.

[0103] Furthermore, in the above-mentioned case where the target barrage special effects file is found, determining to use the target barrage special effects file to provide barrage display special effects for the object barrage may include but is not limited to: in the special effects file library, when a barrage special effects file whose file identifier matches the element identifier of the target element is found, determining to use the target barrage special effects file to provide barrage display special effects for the object barrage.

[0104] For example, the key picture frame is identified to determine that a river image element is identified in the currently identified key picture frame. Then, the physical property of the river image element is determined to be "flowing with the waves", and the special effect matching the river image element is determined to be the "flowing with the waves" special effect. Thus, when a bullet screen special effect file with a file identifier of "flowing with the waves" is found in the special effect file library, it is determined to use the "flowing with the waves" special effect to provide a bullet screen display special effect for the object bullet screen.

[0105] In this embodiment, it is possible but not limited to the embodiment of the present application to perform element recognition on the picture frame sequence corresponding to the currently played video content. Then, based on the element outline of the target element identified from the key picture frame of the picture frame sequence, the element identification of the target element is determined. Next, the target bullet screen special effect file matching the element identification of the target element is searched in the special effect file library, wherein the special effect file library includes multiple bullet screen special effect files, and the bullet screen special effect file includes the element attributes of the target element, and the coloring information for rendering the bullet screen display special effect. Then, in the case of finding the target bullet screen special effect file, it is determined to use the target bullet screen special effect file to provide the object bullet screen with a bullet screen display special effect. That is to say, in the embodiment of the present application, the target bullet screen special effect file is obtained by searching the special effect file library for a pre-stored target bullet screen special effect file matching the element identification of the target element. Then, the acquisition process of the target bullet screen special effect file is simplified, and the purpose of improving the display efficiency of the special effect of the bullet screen is achieved.

[0106] As an optional solution, performing element recognition on a picture frame sequence corresponding to the currently played video content includes at least one of the following:

[0107] S1, identifying image elements displayed in each picture frame of the picture frame sequence;

[0108] S2, extracting subtitle text from each picture frame of the picture frame sequence, and recognizing character elements in the subtitle text.

[0109] It should be noted that the above-mentioned extraction of subtitle text from each frame of the picture frame sequence and recognition of character elements in the subtitle text may include but is not limited to: converting the subtitle information in each frame of the picture frame sequence into subtitle text and recognizing character elements in the subtitle text.

[0110] For example, suppose the subtitle included in the currently recognized picture frame is "What is displayed on the screen now is a beautiful river". The image elements displayed in the currently recognized picture frame are recognized, and the subtitle text is extracted as "What is displayed on the screen now is a beautiful river". It is determined that the subtitle text includes the keyword "river" that matches the "river" special effect identifier, and then it is determined that the target element, that is, the river keyword element, is recognized in the picture frame sequence corresponding to the currently played video content.

[0111] In an embodiment of the present application, the image elements displayed in each picture frame of the picture frame sequence are identified. Subtitle text is extracted from each picture frame of the picture frame sequence, and the character elements in the subtitle text are identified. In other words, in an embodiment of the present application, the subtitle text in the image element displayed in the picture frame is identified to obtain the target element. The conditions for triggering the adjustment of the special effects of the barrage display are enriched, so that the display style switching of the object barrage is more flexible, thereby achieving the technical effect of improving the flexibility of the barrage display effect.

[0112] As an optional solution, when a target element is identified from the video content currently being played in the video display area, determining a bullet screen display special effect that matches an element attribute of the target element includes:

[0113] S1, performing element recognition on the audio frame sequence corresponding to the currently played video content;

[0114] S2, determining an element identifier of the target element based on identifying an element keyword as the target element from a key audio frame of the audio frame sequence;

[0115] S3, searching for a target bullet screen special effect file that matches the element identifier of the target element in a special effect file library, wherein the special effect file library includes multiple bullet screen special effect files, and the bullet screen special effect file includes element attributes of the target element and coloring information for rendering the bullet screen display special effect;

[0116] S4, when the target barrage special effect file is found, determine to use the target barrage special effect file to provide barrage display special effects for the object barrage.

[0117] It should be noted that identifying the element keywords as the target element from the key audio frames of the audio frame sequence includes: using the STT technology to convert the sound in the video into a target text, and then identifying the element keywords as the target element in the target text.

[0118] Furthermore, in the above-mentioned case where the target barrage special effects file is found, determining to use the target barrage special effects file to provide barrage display special effects for the object barrage may include but is not limited to: in the special effects file library, when a barrage special effects file whose file identifier matches the element identifier of the target element is found, determining to use the target barrage special effects file to provide barrage display special effects for the object barrage.

[0119] In an embodiment of the present application, element recognition is performed on the audio frame sequence corresponding to the currently playing video content. Then, based on identifying the element keyword as the target element from the key audio frame of the audio frame sequence, the element identifier of the target element is determined, and the target barrage special effect file that matches the element identifier of the target element is searched in the special effect file library, wherein the special effect file library includes multiple barrage special effect files, and the barrage special effect file includes the element attributes of the target element, and the coloring information for rendering the barrage display special effect. Furthermore, when the target barrage special effect file is found, it is determined to use the target barrage special effect file to provide the object barrage with a barrage display special effect. In other words, in an embodiment of the present application, the method of obtaining the target element is adopted by performing element recognition on the audio frame sequence corresponding to the currently playing video content. The conditions for triggering the adjustment of the barrage display special effect are enriched, so that the display style switching of the object barrage is more flexible, thereby achieving the technical effect of improving the flexibility of the barrage display effect.

[0120] As an optional solution, when playing the target video in the video display area, it also includes:

[0121] S1, start identifying the target element of the video content played in the video display area;

[0122] S2, in response to a pause operation on the video content played in the video display area, pausing the recognition of the target element;

[0123] S3, in response to a closing operation on the video display area, closing the recognition of the target element.

[0124] For example, when a target video is played in the video display area, the recognition of the target element of the video content played in the video display area is enabled. When the pause control displayed in the video display area is triggered, the recognition of the target element is paused. When the client or webpage where the video display area is located is closed, the recognition of the target element is turned off.

[0125] In an embodiment of the present application, the recognition of the target element of the video content played in the video display area is turned on. Then, in response to the pause operation of the video content played in the video display area, the recognition of the target element is paused. Furthermore, in response to the closing operation of the video display area, the recognition of the target element is turned off. In other words, in an embodiment of the present application, when the target video is paused or closed, the recognition of the target element is turned off. This avoids unnecessary waste of system resources, thereby achieving the technical effect of saving system resources.

[0126] As an optional solution, at least one object bullet screen that appears in the video display area when playing the video frame sequence is displayed after adjusting the display style according to the bullet screen display special effect, including:

[0127] S1, loading a bullet screen special effect file corresponding to a bullet screen special effect through a processing engine associated with a video display area, wherein a bullet screen component is configured for each object bullet screen in the processing engine;

[0128] S2, mounting the barrage special effect file to the barrage component of the corresponding object barrage to display the object barrage after adjusting the display style according to the barrage display special effect.

[0129] It should be noted that the above-mentioned processing engine can be but is not limited to being used to instruct a game engine, and a barrage component is configured for each object barrage in the game engine.

[0130] It should be further explained that the special effect file library also stores the bullet screen special effect file information, wherein the bullet screen special effect file information stores the identifier of the bullet screen special effect file and the storage address of the bullet screen special effect file. Specifically, the identifier of the bullet screen special effect file and the storage address of the bullet screen special effect file can be, but are not limited to, a key-value pair.<key,value> stored in the form of.

[0131] Optionally, taking the target element as a river image element as an example, the above bullet screen display method is explained by the following steps:

[0132] When the game processing engine obtains the barrage special effects file information (i.e., <"flow with the wave", address 1>), it obtains the barrage special effects file based on address 1, and then mounts the barrage special effects file on the barrage component of the object barrage to display the object barrage after adjusting the display style according to the barrage display special effects.

[0133] In an embodiment of the present application, a barrage special effect file corresponding to the barrage display special effect is loaded through a processing engine associated with a video display area, wherein a barrage component is configured for each object barrage in the processing engine. Then, the barrage special effect file is mounted on the barrage component of the corresponding object barrage to display the object barrage after adjusting the display style according to the barrage display special effect. That is to say, in an embodiment of the present application, the barrage special effect file corresponding to the barrage component of the object barrage is accurately and efficiently mounted through the processing engine. Thereby achieving the technical effect of improving the switching efficiency of the barrage display special effect.

[0134] As an optional solution, before loading the bullet screen special effect file corresponding to the bullet screen display special effect through the processing engine associated with the video display area, it also includes:

[0135] S1, determining the current hardware status parameters of the terminal device where the video display area is located, wherein the hardware status parameters include: the remaining power value of the terminal device, the memory usage rate of the terminal device, and the remaining storage space of the terminal device;

[0136] S2, when the hardware status parameters meet the bullet screen loading conditions, determine to allow the processing engine to load the bullet screen special effect file.

[0137] It should be noted that, when the hardware status parameters meet the barrage loading conditions, determining to allow the processing engine to load the barrage special effect file may include, but is not limited to: when the remaining power value of the terminal device is greater than the first predetermined threshold, the memory usage rate of the terminal device is greater than the second predetermined threshold, and the remaining storage space of the terminal device is greater than the third predetermined threshold, determining to allow the processing engine to load the barrage special effect file. The first predetermined threshold, the second predetermined threshold, and the third predetermined threshold are positive numbers.

[0138] In an embodiment of the present application, the current hardware status parameters of the terminal device where the video display area is located are determined, wherein the hardware status parameters include: the remaining power value of the terminal device, the memory usage rate of the terminal device, and the remaining storage space of the terminal device. Furthermore, when the hardware status parameters meet the barrage loading conditions, it is determined to allow the processing engine to load the barrage special effects file. In other words, in an embodiment of the present application, by verifying the current hardware status parameters of the terminal device, the technical problem of barrage loading failure caused by the terminal device not meeting the barrage loading conditions is avoided. Thereby achieving the technical effect of improving the success rate of barrage loading and improving user experience.

[0139] As an optional solution, before playing the target video in the video display area, the following is also included:

[0140] S1, determining the current number of network requests of the terminal device where the video display area is located;

[0141] S2, when the number of network requests is less than the target threshold, download the bullet screen special effect file and verify the bullet screen special effect file;

[0142] S3, when the bullet screen special effect file passes the verification, the bullet screen special effect file is saved to the special effect file library of the terminal device.

[0143] It should be noted that, before determining the current number of network requests of the terminal device where the video display area is located, the method further includes: the server encrypts the barrage special effects file based on the md5 algorithm to prevent the barrage special effects file from being tampered with during transmission.

[0144] It should be further explained that, when determining the current number of network requests of the terminal device where the video display area is located, it also includes: determining that the current terminal device is connected to a wireless network.

[0145] It should be noted that the barrage special effect file can be verified by using, but is not limited to, the md5 algorithm.

[0146] As an optional implementation, the above method is explained by the following steps:

[0147] When it is determined that the terminal device in the video display area is connected to the wireless network and the current number of network requests is less than the target threshold, the bullet screen special effect file is loaded and verified based on the md5 algorithm. If the bullet screen special effect file passes the verification, the bullet screen special effect file is saved to the special effect file library of the terminal device.

[0148] In an embodiment of the present application, the current number of network requests of the terminal device where the video display area is located is determined; when the number of network requests is less than the target threshold, the bullet screen special effect file is downloaded and the bullet screen special effect file is verified; when the bullet screen special effect file passes the verification, the bullet screen special effect file is saved to the special effect file library of the terminal device. That is to say, in an embodiment of the present application, when the network of the terminal device is good and in a relatively idle state, the bullet screen special effect file is downloaded in advance, and the bullet screen special effect file is security-verified to facilitate the subsequent switching of the special effects of the bullet screen. Thereby achieving the technical effect of improving the efficiency of switching the bullet screen special effects.

[0149] As an optional implementation, assuming that the target element is a river keyword element, assuming that the above video frame sequence includes the first video frame in which the target element appears, i.e., the third video frame, the last video frame before the target element disappears, i.e., the fourth video frame, and all video frames between the third video frame and the fourth video frame. The above bullet screen display method is fully illustrated by the following steps:

[0150] Play the target video in the video display area;

[0151] Furthermore, when the river keyword element is identified from the subtitle text in the target video frame (i.e., "What you are seeing is a beautiful river"), the barrage display effect that matches the element attribute of the river keyword element (i.e., "flow with the waves") is determined to be the "flow with the waves" effect, and the video frame sequence associated with the target element is determined to include: the first video frame in which the target element appears, i.e., the third video frame, the last video frame before the target element disappears, i.e., the fourth video frame, and all video frames between the third video frame and the fourth video frame.

[0152] Then, if Figure 8 As shown in (a) to (c) in the figure, the object barrage (i.e., "Come come come come come come come come come come") that appears in the video display area when the video frame sequence is played will be displayed after adjusting the display style according to the "flow with the wave" special effect, wherein the object barrage is in a linear motion state in the video display area.

[0153] As an optional implementation, assuming that the target element is a river keyword element, the above method is explained by the following steps:

[0154] Play the target video in the video display area;

[0155] Furthermore, when the river keyword element is identified from the audio frame of the target video, the barrage display effect that matches the element attribute of the river keyword element (i.e., "flow with the waves") is determined to be the "flow with the waves" effect, and the video frame sequence associated with the target element is determined to include: the first video frame in which the target element appears, i.e., the third video frame, the last video frame before the target element disappears, i.e., the fourth video frame, and all video frames between the third video frame and the fourth video frame.

[0156] Then, if Fig. 9 As shown in (a) to (c) in the figure, the object barrage (i.e., "Come come come come come come come come come come") that appears in the video display area when the video frame sequence is played will be displayed after adjusting the display style according to the "flow with the wave" special effect, wherein the object barrage is in a linear motion state in the video display area.

[0157] As an optional implementation, the above bullet screen display method mainly includes the following steps:

[0158] S1, special effects generation, such as Fig.10 As shown, the barrage special effect is generated by using the graphic video processing software 1002, and then the barrage special effect is encrypted by using the encryption plug-in 1004, thereby generating a special effect file 1006. Then, the special effect file 1006 is uploaded to the server 1008.

[0159] It should be noted that the above-mentioned graphic and video processing software may include but is not limited to "Adobe AfterEffects" referred to as "AE", "Autodesk Maya" referred to as "MAYA" and the like.

[0160] S2, special effects display, special effects display consists of three parts: special effects download, screen element detection, special effects loading:

[0161] 1) Download special effects

[0162] The downloading of special effects is basically the same as that of ordinary files. There are two points that need to be specially explained:

[0163] Download during off-peak hours: The download function is enabled only when the phone is connected to a wireless network (wifi) and the number of network requests for the current APP is less than the threshold (the threshold can be set).

[0164] Resource verification: The special effects file on the server side is in zip format. In order to prevent the file from being tampered with, the mobile phone needs to verify the message digest algorithm 5 (Message-digest Algorithm5, referred to as md5) value of the file after the download is completed. Only after the verification is passed will the next step be carried out, otherwise the file will be discarded.

[0165] Specifically, the specific process of special effects download is as follows Fig.11 The following steps are shown:

[0166] S1102, opening an application that plays the target video;

[0167] S1104, detecting whether the wireless network is currently connected. If the wireless network is currently connected, executing step S1106; if the wireless network is not currently connected, executing step S1114;

[0168] S1106, detecting whether the current number of network connections is less than a threshold value, if the current number of network connections is less than the threshold value, executing step S1106, if the current number of network connections is greater than the threshold value, executing step S1114;

[0169] S1108, download special effect files;

[0170] S1110, determining whether the special effects file has passed the verification, if the special effects file has passed the verification, executing step S1112, if the special effects file has not passed the verification, executing step S1114;

[0171] S1112, storing the special effect file into a database;

[0172] S1114, end downloading.

[0173] It should be noted that since this detection is time-consuming, all these detections will be performed in sub-threads, so that time can be saved by opening multiple sub-threads without affecting user interaction.

[0174] 2) Screen element detection

[0175] Screen element detection is divided into two ways: visual detection and text detection

[0176] Visual detection mainly uses audio and video codec tools (fast forward moving picture expert group, referred to as ffmpeg). When the video is playing, I frames are extracted from the video within a certain period of time after the current playback time. The specific length of time can be set.

[0177] The I frames in a certain time period are summarized into a picture list, and the picture recognition tool (Open Source Computer Vision Library, referred to as OpenCV) is loaded to perform edge detection on these pictures. The detected results are matched with the special effect file names in the database. If the match is successful, it means that there is an available special effect file on the I frame. At this time, the three key attributes of the I frame time, the address of the special effect file, and the contour information of the object on the I frame need to be saved in the memory and sent to the game engine for subsequent loading. If the match is not successful, the frame is discarded and the next frame detection is carried out.

[0178] Text detection first extracts the subtitles of the video and converts them into text using optical character recognition technology (OCR). For videos without subtitles, speech-to-text technology (STT) is used to convert the speech in the video into text. Then the text and the physical effect name are matched. If the match is successful, it is considered that the spatial range that the physical effect needs to display is the entire screen, and the three key attributes of the time point when the text appears, the address of the special effect file, and the entire screen range are saved in the memory for subsequent loading. If the match is not successful, the text is discarded and the next text is judged.

[0179] The page element detection function is automatically turned on when entering the video playback page. This function is completely related to the video playback progress. If the video is paused, the detection function is also paused; when exiting the video playback page, the function will also be turned off.

[0180] In addition, in the embodiments of the present application, Fig.12 As shown, you can also set the display time of the special effect bullet in the settings panel. On the bullet setting page, you can choose whether the special effect bullet disappears when it scrolls out of the screen (i.e., non-follow mode), or when the physical effect (fire, river) on the screen disappears, the special effect bullet disappears with it (i.e., follow mode). If it is a physical special effect obtained by text detection and matching, the bullet cannot be configured with a display time, and the special effect will only disappear when it scrolls out of the screen.

[0181] Furthermore, the complete execution process of screen element detection is described as follows:

[0182] For visual inspection, such as Fig.13As shown in (a), when playing a video, ffmpeg is started to extract I frames from the video within a certain time period after the current playback time. The specific time length can be set. At the same time, OpenVC is loaded to perform edge detection on these images. After edge detection of the image, check whether there are special effects that match it. If there are matching special effects, the three key attributes of the I frame time, the address of the special effect file, and the outline information of the object on the I frame are saved in the memory and sent to the game engine for subsequent loading. If no match is successful, the frame is discarded and the next frame detection continues.

[0183] For text detection, Fig.13 As shown in (a), when playing a video, detect whether there are subtitles in the target video. If there are subtitles, start OCR to extract and process the text in the subtitles. If there are no subtitles, start STT to convert the voice in the video into text. Then detect whether there are special effects that match it. If there are special effects that match it, the three key attributes of the I frame time, the address of the special effects file, and the outline information of the object on the I frame are saved to the memory and sent to the game engine for subsequent loading. If no match is successful, the frame is discarded and the next text is extracted.

[0184] 3) Special effects loading

[0185] It should be noted that in order to achieve the requirement mentioned by the product side that two physical effects cannot be displayed simultaneously in the same area of ​​the screen, before the barrage needs to run shader code or change properties, it is necessary to check whether the barrage in front of it has physical effects. If so, the shader code will no longer be run and the properties will not be changed.

[0186] Furthermore, the loading of special effects requires the use of a game engine. All barrages are loaded and displayed by the game engine, so the game engine needs to be started when entering the playback page. The player will synchronize the playback progress to the game engine in real time, and the engine will determine which barrages need to be displayed based on the playback progress. In order to ensure the user experience, the game engine first determines whether the start-up conditions are met when entering the playback page, and the engine will only be started if the conditions are met. At the same time, if the APP is in use, the engine's usage conditions will be detected in a polling manner. If the conditions are not met, the engine will be exited directly. Avoid the decline in the APP's user experience due to barrage special effects.

[0187] Specific conditions include: the battery level of the phone, the memory usage rate of the phone, and the storage space of the phone.

[0188] Barrage effects are only allowed to be loaded when all the above conditions are met.

[0189] The specific loading process of the barrage special effects is to uniformly submit the matched barrage special effects name, barrage special effects file path and the corresponding element (screen display) position to the game engine. The engine is responsible for loading and displaying all barrages (including ordinary barrages). When the special effect barrage parameters are detected, the engine will load the barrage special effects files from the special effects file path and mount these files. When the barrage runs to the area where the special effects need to be displayed, the barrage will start to display the special effects.

[0190] Each bullet comment corresponds to a basic unit in the game engine (unity is a gameobject, cocoacreator is a node), on which different effect codes can be dynamically mounted. The special effect file mainly contains the physical properties of the element and the shader code (shader), which will be mounted on the bullet comment component, and the display effect of the bullet comment is to run the shader code. For example, the flame effect is as follows:

[0191] Generally, when the elements contained in the keyframe on the screen change, the I frame will definitely change. However, in order to prevent the problem of two different physical special effects being superimposed due to the I frame not being loaded or parsing failure in some unexpected situations, this solution needs to determine whether there is an ongoing special effect bullet screen in the playback area before the bullet screen special effect is loaded. If so, the latest bullet screen special effect will be discarded. Priority is given to ensuring the playback effect of the special effects on the current screen.

[0192] Specifically, if Fig.13 As shown in (b), the key attributes obtained by screen detection will be notified to the engine in the form of a list. Before the bullet screen is displayed, the engine will determine whether the bullet needs to load physical special effects based on the playback progress and the bullet display time. For special effects that do not need to be loaded, the bullet is displayed normally until the bullet disappears. For special effects that need to be loaded, the special effects file is obtained according to the special effects file path, and then the special effects file is decrypted (because the file was encrypted when exported, decryption at this time can prevent the file from being stolen). Next, the special effects file is mounted. Specifically, the decrypted special effects file is an executable shader code and attributes, which will be directly mounted on the corresponding bullet component. Further, it is determined whether the bullet moves to the special effects display area. When the bullet moves to the screen, the special effects file is loaded until the bullet disappears, that is, the shader code is run or its own physical properties are modified. At this time, the bullet will display the corresponding physical special effects. If the bullet does not move to the special effects display area, the bullet is displayed normally and it continues to be determined whether the bullet moves to the special effects display area.

[0193] 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 the present application is not limited by the described order of actions, because according to the present 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 the present application.

[0194] According to another aspect of the embodiments of the present application, a bullet screen display device for implementing the above bullet screen display method is also provided. Fig.14 As shown, the device comprises:

[0195] The playing unit 1402 is used to play the target video in the video display area;

[0196] The determination unit 1404 is used to determine the bullet screen display effect matching the element attribute of the target element and the video frame sequence associated with the target element when the target element is identified from the video content currently played in the video display area;

[0197] The display unit 1406 is used to display at least one object bullet screen that appears in the video display area when playing the video frame sequence after adjusting the display style according to the bullet screen display special effects.

[0198] Optionally, the display unit includes:

[0199] A first determination module is used to determine an element display area where a target element is located in a video display area when the object bullet screen is configured as an element follow display mode;

[0200] A first switching module is used to switch the object bullet screen from a default display style to a special effect display style matching the bullet screen display special effect when the object bullet screen moves to the element display area;

[0201] The first display module is used to display object bullet screens in a special effect display style.

[0202] Optionally, the display unit further includes:

[0203] The second switching module is used to switch the object bullet screen from the special effect display style to the default display style when all characters in the object bullet screen leave the element display area;

[0204] The second display module is used to display the object bullet screen in the default display style.

[0205] Optionally, the determining unit includes:

[0206] A second determination module is used to determine a first video frame when the first character in the object bullet screen moves into the element display area, and a second video frame when the last character in the object bullet screen moves out of the element display area;

[0207] The third determining module is used to determine the video frames from the first video frame to the second video frame as a video frame sequence.

[0208] Optionally, the display unit further includes:

[0209] A third switching module is used to switch the object bullet screen from a default display style to a special effect display style matching the bullet screen display special effect when the object bullet screen is not configured as an element following display mode;

[0210] The third display unit is used to display the object bullet screen in a special effect display style before all characters in the object bullet screen exit the video display area.

[0211] Optionally, the determining unit further includes:

[0212] A fourth determination module, configured to use the first video frame in which the target element appears as the third video frame, and use the last video frame before the target element disappears as the fourth video frame;

[0213] The fifth determining module is used to determine the video frames from the third video frame to the fourth video frame as a video frame sequence.

[0214] Optionally, the above-mentioned display unit is also used to: according to the barrage display special effects, adjust the various characters contained in the object barrage to a display style that matches the element attributes of the target element, and obtain adjusted special effect barrage characters, wherein the special effect barrage characters will present a simulation effect corresponding to the element attributes.

[0215] Optionally, the determining unit further includes:

[0216] A first recognition module is used to perform element recognition on a picture frame sequence corresponding to the currently played video content;

[0217] a sixth determination module, configured to determine an element identifier of a target element based on an element contour of the target element identified from a key picture frame of the picture frame sequence;

[0218] A first search module is used to search for a target bullet screen special effect file that matches an element identifier of a target element in a special effect file library, wherein the special effect file library includes multiple bullet screen special effect files, and the bullet screen special effect file includes element attributes of the target element and coloring information for rendering a bullet screen display special effect;

[0219] The seventh determination module is used to determine the use of the target barrage special effects file to provide barrage display effects for the object barrage when the target barrage special effects file is found.

[0220] Optionally, the first recognition module is further used to: recognize image elements displayed in each picture frame of the picture frame sequence; extract subtitle text from each picture frame of the picture frame sequence, and recognize character elements in the subtitle text.

[0221] Optionally, the determining unit further includes:

[0222] The second recognition module is used to perform element recognition on the audio frame sequence corresponding to the currently played video content;

[0223] an eighth determination module, configured to determine an element identifier of a target element based on identifying an element keyword as a target element from a key audio frame of the audio frame sequence;

[0224] A second search module is used to search for a target bullet screen special effect file that matches an element identifier of a target element in a special effect file library, wherein the special effect file library includes multiple bullet screen special effect files, and the bullet screen special effect file includes element attributes of the target element and coloring information for rendering a bullet screen display special effect;

[0225] The ninth determination module is used to determine the use of the target barrage special effects file to provide barrage display effects for the object barrage when the target barrage special effects file is found.

[0226] Optionally, the above device further includes:

[0227] A first recognition unit, used to start the recognition of target elements of the video content played in the video display area;

[0228] A first pause unit, configured to pause the recognition of a target element in response to a pause operation on the video content played in the video display area;

[0229] The first closing unit is used to close the recognition of the target element in response to the closing operation of the video display area.

[0230] Optionally, the above-mentioned determination unit is also used to: load the barrage special effect file corresponding to the barrage display special effect through the processing engine associated with the video display area, wherein a barrage component is configured for each object barrage in the processing engine; mount the barrage special effect file to the barrage component of the corresponding object barrage to display the object barrage after the display style is adjusted according to the barrage display special effect.

[0231] Optionally, the above-mentioned determination unit is also used to: determine the current hardware status parameters of the terminal device where the video display area is located, wherein the hardware status parameters include: the remaining power value of the terminal device, the memory usage rate of the terminal device, and the remaining storage space of the terminal device; when the hardware status parameters meet the barrage loading conditions, determine to allow the processing engine to load the barrage special effects file.

[0232] Optionally, the above device further includes:

[0233] A first determining unit, used to determine the current number of network requests of the terminal device where the video display area is located;

[0234] A first downloading unit is used to download the bullet screen special effect file and verify the bullet screen special effect file when the number of network requests is less than the target threshold;

[0235] The first storage unit is used to save the barrage special effect file to the special effect file library of the terminal device when the barrage special effect file passes the verification.

[0236] For the specific implementation, reference may be made to the example shown in the above-mentioned bullet screen display method, and this embodiment will not be described in detail here.

[0237] According to another aspect of the embodiment of the present application, an electronic device for implementing the above-mentioned bullet screen display method is also provided. The electronic device may be Figure 1 The terminal device shown in FIG. This embodiment is described by taking the electronic device as a terminal as an example. Fig.15 As shown, the electronic device includes a memory 1502 and a processor 1504. The memory 1502 stores a computer program, and the processor 1504 is configured to execute the steps in any of the above method embodiments through the computer program.

[0238] 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.

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

[0240] S1, play the target video in the video display area;

[0241] S2, when a target element is identified from the video content currently being played in the video display area, determining a bullet screen display special effect that matches the element attribute of the target element, and a video frame sequence associated with the target element;

[0242] S3, displaying at least one object bullet screen that appears in the video display area when playing the video frame sequence after adjusting the display style according to the bullet screen display special effects.

[0243] Alternatively, a person skilled in the art may understand that: Fig.15 The structure shown is for illustration only, and the electronic device may also be a smart phone (such as an Android phone, an iOS phone, etc.), a tablet computer, a PDA, a mobile Internet device (Mobile Internet Devices, MID), a PAD, or other terminal devices. Fig.15 The structure of the electronic device is not limited. Fig.15 More or fewer components (such as network interfaces, etc.) as shown in, or with Fig.15 Different configurations are shown.

[0244] Among them, the memory 1502 can be used to store software programs and modules, such as the program instructions / modules corresponding to the bullet screen display method and device in the embodiment of the present application. The processor 1504 executes various functional applications and data processing by running the software programs and modules stored in the memory 1502, that is, realizing the above-mentioned bullet screen display method. The memory 1502 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 1502 may further include a memory remotely located relative to the processor 1504, and these remote memories may be connected to the terminal 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 1502 can be specifically, but not limited to, used to store information such as target elements. As an example, such as Fig.15 As shown, the memory 1502 may include, but is not limited to, the playback unit 1402, the determination unit 1404, and the generation and display unit 1408 in the bullet screen display device. In addition, other module units in the bullet screen display device may also be included but are not limited to, which will not be repeated in this example.

[0245] Optionally, the transmission device 1506 is used to receive or send data via a network. Specific examples of the above-mentioned network may include a wired network and a wireless network. In one example, the transmission device 1506 includes a network adapter (Network Interface Controller, NIC), which can be connected to other network devices and routers via a network cable so as to communicate with the Internet or a local area network. In one example, the transmission device 1506 is a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.

[0246] In addition, the electronic device mentioned above further includes: a connection bus 1508, which is used to connect various module components in the electronic device mentioned above.

[0247] In other embodiments, the terminal device 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 the multiple nodes through network communication. The nodes may form a point-to-point network, and any form of computing device, such as a server, terminal or other electronic device, may become a node in the blockchain system by joining the point-to-point network.

[0248] According to one aspect of the present application, a computer program product is provided, the computer program product comprising a computer program / instruction, the computer program / instruction comprising a program code for executing the above method. In such an embodiment, the computer program can be downloaded and installed from a network through a communication part, and / or installed from a removable medium. When the computer program is executed by a central processing unit, various functions provided by the embodiments of the present application are executed.

[0249] According to one aspect of the present application, a computer program product is provided, the computer program product comprising a computer program / instruction, the computer program / instruction comprising a program code for executing the above method. In such an embodiment, the computer program can be downloaded and installed from a network through a communication part, and / or installed from a removable medium. When the computer program is executed by a central processing unit, various functions provided by the embodiments of the present application are executed.

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

[0251] S1, play the target video in the video display area;

[0252] S2, when a target element is identified from the video content currently being played in the video display area, determining a bullet screen display special effect that matches the element attribute of the target element, and a video frame sequence associated with the target element;

[0253] S3, displaying at least one object bullet screen that appears in the video display area when playing the video frame sequence after adjusting the display style according to the bullet screen display special effects.

[0254] 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 terminal device through a program, and the program may be stored in a computer-readable storage medium, and the storage medium may include: a flash drive, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, etc.

[0255] 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 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 may be personal computers, servers, or network devices, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present application.

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

[0257] In the several embodiments provided in the present application, it should be understood that the disclosed client can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that 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.

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

[0259] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0260] The above is only a preferred implementation 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 bullet screen display method, characterized in that: include: Play the target video in the video display area; When a target element is identified from the video content currently being played in the video display area, determining a bullet screen display special effect that matches the element attribute of the target element, and a video frame sequence associated with the target element; At least one object barrage that appears in the video display area when the video frame sequence is played is displayed, and the display style is adjusted according to the barrage display special effects.

2. The method according to claim 1, characterized in that: The at least one object barrage that appears in the video display area when the video frame sequence is to be played, and the display style is adjusted according to the barrage display special effects and then displayed includes: When the object barrage is configured as an element following display mode, it is determined that the element display area in which the target element is located in the video display area; When the object barrage is moved to the element display area, the object barrage is switched from the default display style to a special effect display style that matches the barrage display special effect; Displays the object barrage in the special effect display style.

3. The method according to claim 2, characterized in that After the display of the object barrage in the special effect display style, it further includes: When all characters in the object barrage leave the element display area, the object barrage is switched from the special effect display style to the default display style; Displays the object barrage in the default display style.

4. The method according to claim 2, characterized in that: Determining a sequence of video frames associated with the target element includes: Determine a first video frame when a first character in the object bullet screen moves into the element display area, and a second video frame when a last character in the object bullet screen moves out of the element display area; A video frame from the first video frame to the second video frame is determined as the video frame sequence.

5. The method according to claim 1, characterized in that The at least one object barrage that appears in the video display area when the video frame sequence is to be played, and the display style is adjusted according to the barrage display special effects and then displayed includes: When the object barrage is not configured as the element following display mode, the object barrage is switched from the default display style to a special effect display style that matches the barrage display special effect; The object barrage in the special effect display style is displayed before all characters in the object barrage exit the video display area.

6. The method according to claim 5, characterized in that Determining a sequence of video frames associated with the target element includes: The first video frame of the target element appears as the third video frame, and the last video frame before the target element disappears as the fourth video frame; A video frame from the third video frame to the fourth video frame is determined as the video frame sequence.

7. The method according to claim 1, characterized in that The at least one object barrage that appears in the video display area when the video frame sequence is to be played, and the display style is adjusted according to the barrage display special effects and then displayed includes: According to the barrage display special effects, each character contained in the object barrage is adjusted to a display style that matches the element attributes of the target element to obtain an adjusted special effect barrage character, wherein the special effect barrage character will present a simulation effect corresponding to the element attributes.

8. The method according to claim 1, characterized in that When the target element is identified from the currently played video content in the video display area, the barrage display special effect that determines a matching element attribute of the target element includes: Element recognition is performed on the picture frame sequence corresponding to the currently played video content; An element identification of the target element is determined based on the element outline of the target element identified from the key picture frames of the picture frame sequence; Searching for a target bullet screen special effect file that matches the element identifier of the target element in a special effect file library, wherein the special effect file library includes a plurality of bullet screen special effect files, and the bullet screen special effect file includes element attributes of the target element and coloring information for rendering the bullet screen display special effect; When the target barrage special effect file is found, it is determined that the target barrage display special effect is provided for the target barrage.

9. The method according to claim 8, characterized in that The element identification of the picture frame sequence corresponding to the currently played video content includes at least one of the following: The image elements displayed in each picture frame of the picture frame sequence are identified; Subtitle text is extracted from each picture frame of the sequence of picture frames, and character elements in the subtitle text are identified.

10. The method according to claim 1, characterized in that When the target element is identified from the currently played video content in the video display area, the barrage display special effect that determines a matching element attribute of the target element includes: Element recognition is performed on the audio frame sequence corresponding to the currently played video content; Based on identifying the element keyword as the target element from the key audio frames of the audio frame sequence, an element identification of the target element is determined; Searching for a target bullet screen special effect file that matches the element identifier of the target element in a special effect file library, wherein the special effect file library includes a plurality of bullet screen special effect files, and the bullet screen special effect file includes element attributes of the target element and coloring information for rendering the bullet screen display special effect; When the target barrage special effect file is found, it is determined that the target barrage display special effect is provided for the target barrage.

11. The method according to any one of claims 1 to 10, characterized in that When playing the target video in the video display area, it also includes: Turn on the recognition of the target element of the video content played in the video display area; Responsive to a pause operation of the video content played within the video display area, the recognition of the target element is paused; In response to a closing operation of the video display area, identification of the target element is turned off.

12. The method according to any one of claims 1 to 10, characterized in that The step of displaying at least one object bullet screen that appears in the video display area when the video frame sequence is played and adjusting the display style according to the bullet screen display special effect comprises: Loading a bullet screen special effect file corresponding to the bullet screen display special effect through a processing engine associated with the video display area, wherein a bullet screen component is configured for each of the object bullet screens in the processing engine; The barrage special effect file is mounted on the corresponding barrage component of the object barrage to display the object barrage after adjusting the display style according to the barrage display special effect.

13. The method according to claim 12, characterized in that Before loading the barrage special effect file corresponding to the barrage display special effect through the processing engine associated with the video display area, the barrage display special effect file is also included: Determine the current hardware status parameters of the terminal device where the video display area is located, wherein the hardware status parameters include: the remaining power value of the terminal device, the memory usage rate of the terminal device, and the remaining storage space of the terminal device; When the hardware state parameter reaches the barrage loading condition, it is determined that the processing engine is allowed to load the barrage special effect file.

14. The method according to any one of claims 1 to 10, characterized in that Before playing the target video in the video display area, it is further included: Determine the current number of network requests of the terminal device where the video display area is located; When the number of network requests is less than the target threshold, download the barrage special effect file and verify the barrage special effect file; When the barrage special effect file passes verification, the barrage special effect file is saved in the special effect file library of the terminal device.

15. A bullet screen display device, characterized in that: include: Playing unit, used to play target videos in the video display area; A determination unit, configured to determine, when a target element is identified from the video content currently being played in the video display area, a bullet screen display special effect that matches an element attribute of the target element, and a video frame sequence associated with the target element; The display unit is configured to display at least one object barrage that appears in the video display area when the video frame sequence is played, and then adjust the display style according to the barrage display special effects and display it.

16. A computer readable storage medium characterized in that The computer-readable storage medium comprises a stored program, wherein the program is executed when run by a processor.

17. A computer program product comprising a computer program / instructions, characterized in that The computer program / instructions implement the steps of the method of any one of claims 1 to 14 when executed by the processor.

18. An electronic device, including a memory and a processor, characterized in that A computer program is stored in the memory, and the processor is arranged to perform the method of any one of the claims 1 to 14 through the computer program.

Citation Information

Cited By

  • Data processing method, device and equipment and readable storage medium

    CN120455759A