Barrage display method and device, equipment and storage medium

By switching the bullet screen style attributes between video clips, the problem of difficulty in understanding the plot caused by a large amount of bullet screen data is solved, the user experience is improved and the terminal resource consumption is reduced, and the flexible and smooth display of bullet screen data is achieved.

CN119233033BActive Publication Date: 2025-12-09TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202310808438.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-06-30
Publication Date
2025-12-09
Estimated Expiration
2043-06-30

AI Technical Summary

Technical Problem

When watching video data, as the number of viewers increases, the video data may contain a large amount of bullet screen data, which makes it difficult for users to understand the plot and increases the consumption of terminal resources.

Method used

By switching between different bullet screen style attributes between video clips, bullet screen data in video clips with different plots can be displayed, including the first bullet screen style attribute, the transition bullet screen style attribute, and the second bullet screen style attribute, ensuring that the bullet screen data is smoothly connected when the plot changes.

Benefits of technology

It enhances users' perception of plot changes, reduces terminal resource consumption, avoids the need to replay videos multiple times to understand the plot, and improves the flexibility and diversity of bullet screen data display.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119233033B_ABST
    Figure CN119233033B_ABST
Patent Text Reader

Abstract

Embodiments of the present application disclose a method and device for displaying bullet screen, equipment and storage medium, the method comprises the following steps: displaying the bullet screen data in the first bullet screen set in the first video segment according to the first bullet screen style attribute; if the first video segment is played, playing the first video sub-segment of the second video segment in the target video data, switching to display the bullet screen data in the second bullet screen set in the first video sub-segment according to the transition bullet screen style attribute; the plot of the first video segment is different from the plot of the second video segment; if the first video sub-segment is played, playing the second video sub-segment in the second video segment, switching to display the bullet screen data in the second bullet screen set in the second video sub-segment according to the second bullet screen style attribute. Through the present application, the resource consumption of the terminal can be reduced, and it is beneficial for users to quickly understand the plot of the video data.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of Internet technology, and particularly relates to a method and device for displaying bullet screen, equipment and storage medium. BACKGROUND

[0002] With the continuous development of Internet technology, there are more and more video contents on the network. When watching video data, a user can interact with different viewers by sending bullet screen data to the video data. With the increase of the number of viewers of the video data, the video data can have a large amount of bullet screen data, which causes certain disturbance to the user in understanding the plot of the video data. In practice, it is found that the user needs to play back the video data multiple times to understand the plot of the video data, which increases the resource consumption of the terminal. SUMMARY

[0003] The embodiments of the present application provide a method and device for displaying bullet screen, equipment and storage medium, which reduce the resource consumption of the terminal and are beneficial to the user in quickly understanding the plot of the video data.

[0004] In an aspect, the embodiments of the present application provide a method for displaying bullet screen, comprising:

[0005] In the playing process of a first video segment of target video data, bullet screen data in a first bullet screen set is displayed in the first video segment according to a first bullet screen style attribute;

[0006] If the first video segment is played completely, a first video sub-segment of a second video segment in the target video data is played, and bullet screen data in a second bullet screen set is displayed in the first video sub-segment according to a transition bullet screen style attribute; the plot of the first video segment is different from the plot of the second video segment;

[0007] If the first video sub-segment is played completely, a second video sub-segment in the second video segment is played, and the bullet screen data in the second bullet screen set is displayed in the second video sub-segment according to a second bullet screen style attribute; the first bullet screen style attribute, the transition bullet screen style attribute and the second bullet screen style attribute are different.

[0008] In an aspect, the embodiments of the present application provide a method for displaying bullet screen, comprising:

[0009] In the playing process of a first video sub-segment of target video data, bullet screen data in a first bullet screen set is displayed in the first video sub-segment according to a first bullet screen style attribute; the first video sub-segment belongs to a first video segment in the target video data;

[0010] if the first video sub-fragment is played, a second video sub-fragment in the second video fragment is played, and the display is switched to display the barrage data in the second barrage set in the second video sub-fragment according to a second barrage style attribute; the first barrage style attribute, the transition barrage style attribute, and the second barrage style attribute are different; the plot of the first video fragment is different from the plot of the second video fragment.

[0011] if the first video sub-fragment is played, a second video sub-fragment in the second video fragment is played, and the display is switched to display the barrage data in the second barrage set in the second video sub-fragment according to a second barrage style attribute; the first barrage style attribute, the transition barrage style attribute, and the second barrage style attribute are different; the plot of the first video fragment is different from the plot of the second video fragment.

[0012] The embodiment of the present application provides a barrage display method, comprising:

[0013] during the playing of a first video fragment of target video data, barrage data in a first barrage set is displayed in the first video fragment according to a first barrage style attribute;

[0014] if the first video fragment is played, a second video fragment in the target video data is played, and the display is switched to display barrage data in a second barrage set in the second video fragment according to a second barrage style attribute; the transition barrage style attribute and the second barrage style attribute are different; the plot of the first video fragment is different from the plot of the second video fragment.

[0015] The embodiment of the present application provides a barrage display device, comprising:

[0016] a first display module, configured to display barrage data in a first barrage set in a first video fragment of target video data according to a first barrage style attribute during the playing of the first video fragment;

[0017] a second display module, configured to play a first video sub-fragment in a second video fragment of the target video data if the first video fragment is played, and switch to display barrage data in a second barrage set in the first video sub-fragment according to a transition barrage style attribute; the plot of the first video fragment is different from the plot of the second video fragment;

[0018] a third display module, configured to play a second video sub-fragment in the second video fragment if the first video sub-fragment is played, and switch to display barrage data in the second barrage set in the second video sub-fragment according to a second barrage style attribute; the first barrage style attribute, the transition barrage style attribute, and the second barrage style attribute are different.

[0019] The embodiment of the application provides a device for displaying a barrage, comprising:

[0020] A first display module is configured to display, in a first video sub-clip of a target video data, barrage data in a first barrage set according to a first barrage style attribute during playing of the first video sub-clip; the first video sub-clip belongs to a first video clip in the target video data;

[0021] A second display module is configured to, if the first video sub-clip is played completely, play a second video sub-clip in the first video clip, and switch to display, in the second video sub-clip, the barrage data in the first barrage set according to a transition barrage style attribute;

[0022] A third display module is configured to, if the second video sub-clip is played completely, play a second video clip in the target video data, and switch to display, in the second video clip, barrage data in a second barrage set according to a second barrage style attribute; the first barrage style attribute, the transition barrage style attribute and the second barrage style attribute are different; a plot of the first video clip is different from a plot of the second video clip.

[0023] The embodiment of the application provides a device for displaying a barrage, comprising:

[0024] A first display module is configured to display, in a first video clip of target video data, barrage data in a first barrage set according to a first barrage style attribute during playing of the first video clip;

[0025] A second display module is configured to, if the first video clip is played completely, play a second video clip in the target video data, and switch to display, in the second video clip, barrage data in a second barrage set according to a second barrage style attribute; the plot of the first video clip is different from the plot of the second video clip, and the transition barrage style attribute and the second barrage style attribute are different.

[0026] The embodiment of the application provides a computer device, comprising a memory and a processor, the memory stores a computer program, and the processor executes the computer program to realize the steps of the method.

[0027] The embodiment of the application provides a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to realize the steps of the method.

[0028] The embodiment of the application provides a computer program product, comprising a computer program, and the computer program is executed by a processor to realize the steps of the method.

[0029] In the present application, during the playing process of the target video data, the barrage data in the video segments of different plots is displayed by using different barrage style attributes (i.e., the first barrage style attribute and the second barrage style attribute), so as to prompt the user that there is a plot change between the front and rear video segments (i.e., the first video segment and the second video segment), which is beneficial to improve the user's perception of the plot change, is beneficial to the user to quickly understand the plot of the target video data, improves the display flexibility and diversity of the barrage data; at the same time, it can avoid the user to understand the plot of the video data by multiple times of playing back the video data, and can reduce the resource (such as the resource required for loading the video data) consumption of the terminal. In addition, by using the transition barrage attribute style to display the barrage data between the front and rear video segments, the situation of empty screen (i.e., no barrage data) and abruptness in the video segments can be avoided, so that the barrage data displayed in the front and rear video segments is smooth. BRIEF DESCRIPTION OF DRAWINGS

[0030] In order to more clearly illustrate the technical solutions of the embodiments of the present application or the prior art, the drawings needed to be used in the embodiments or the prior art description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.

[0031] Figure 1 is a schematic diagram of a barrage display system provided by the present application;

[0032] Figure 2 is a flowchart of a barrage display method provided by the present application;

[0033] Figure 3 is a schematic diagram of an interactive scene of a barrage display method provided by the present application;

[0034] Figure 4 is a flowchart of a barrage display method provided by the present application;

[0035] Figure 5 is an interface diagram for obtaining a plot change moment provided by the present application;

[0036] Figure 6 is a display interface diagram of barrage data provided by the present application;

[0037] Figure 7 is a display interface diagram of barrage data provided by the present application;

[0038] Figure 8 is a schematic diagram of a barrage framework provided by the present application;

[0039] Figure 9 is a schematic diagram of an inheritance relationship of a virtual track provided by the present application;

[0040] Figure 10 is a configuration schematic diagram of configuring a barrage backflow provided by the present application;

[0041] Figure 11 is a display interface schematic diagram of barrage data provided by the present application;

[0042] Figure 12 is a schematic diagram of closing a barrage style attribute switching provided by the present application;

[0043] Figure 13 is a flow schematic diagram of a barrage display method provided by the present application;

[0044] Figure 14 is a flow schematic diagram of a barrage display method provided by the present application;

[0045] Figure 15 is a flow schematic diagram of a barrage display method provided by the present application;

[0046] Figure 16 is a structure schematic diagram of a barrage display device provided by the present application;

[0047] Figure 17 is a structure schematic diagram of a barrage display device provided by the present application;

[0048] Figure 18 is a structure schematic diagram of a barrage display device provided by the present application;

[0049] Figure 19 is a structure schematic diagram of a computer device provided by the present application. DETAILED DESCRIPTION

[0050] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all the other embodiments obtained by those of ordinary skill in the art without any creative work fall within the scope of protection of the present application.

[0051] First, the terms involved in the present application are explained.

[0052] Barrage data: refers to the personal comments and the like published by a user in the process of watching video data, and the barrage data is displayed in the video data so that the user can view the barrage data published by himself. When the barrage function of the play application of other users watching the video data is in an open state, the other users can also see the barrage data.

[0053] Barrage moving direction: refers to the moving direction of the barrage data in the video screen, and the barrage moving direction can include a barrage normal flow direction and a barrage reverse flow direction. The barrage normal flow direction refers to the moving direction of the barrage data in the video screen being from right to left. The barrage reverse flow direction refers to the moving direction of the barrage data in the video screen being from left to right. Left refers to the left side of the user when the user faces the video screen, and right refers to the right side of the user when the user faces the video data. The video screen refers to the screen of the terminal playing the video data.

[0054] Barrage arrangement direction: refers to the reading arrangement order of the text content of the barrage data, and the barrage arrangement direction can include a barrage normal arrangement direction and a barrage reverse arrangement direction. The barrage normal arrangement direction refers to the text content of the barrage data being arranged in a reading order from left to right. The barrage reverse arrangement direction refers to the text content of the barrage data being arranged in a reading order from right to left. For example, the barrage data is: The main character of this drama is really beautiful. When the barrage arrangement direction of the barrage data is the barrage normal arrangement direction, the barrage data can be arranged as: The main character of this drama is really beautiful. When the barrage arrangement direction of the barrage data is the barrage reverse arrangement direction, the barrage data can be arranged as: Bright beautiful true angle main drama this.

[0055] Barrage moving speed: refers to the moving speed of the barrage data, and the barrage moving speed includes a general moving speed and an accelerated moving speed. The general moving speed is calculated according to a fixed display time length, that is, the general moving speed refers to moving the barrage data at a fixed moving speed. The general moving speed can be the default moving speed of the target application in which the target video data is located. The accelerated moving speed is calculated according to a fixed acceleration, so that the barrage data presents a faster and faster style in the video screen, or the accelerated moving speed refers to a fixed moving speed greater than the general moving speed.

[0056] The barrage style attribute is used to indicate that the barrage data is displayed in a static display manner, or the barrage style attribute is used to indicate that the barrage data is displayed in a dynamic display manner. The static display manner means that the barrage data is displayed at a fixed position, i.e., the barrage data does not move. The dynamic display manner means that the barrage data moves in a certain direction, and the position of the barrage data changes over time. The barrage style attribute includes a time parameter and a space parameter of the barrage data. The time parameter includes one or more of a barrage data start display time, a barrage data end display time, and a barrage data display time limit. The barrage data display time limit is the maximum display time of the barrage data on the video screen. If the actual display time exceeds the barrage data display time limit, the barrage data is ended. The space parameter includes one or more of a barrage data display position, a barrage arrangement direction, a barrage movement direction, a barrage movement speed, a font size, a font type, a color value, and a transparency. In particular, when the barrage style attribute is used to indicate that the barrage data is displayed in a static display manner, the barrage style attribute does not include the barrage movement direction and the barrage movement speed.

[0057] It should be noted that the first barrage style attribute, the second barrage style attribute, and the transition barrage style attribute in the present application are different barrage style attributes. The first barrage style attribute and the second barrage style attribute are used to display the barrage data in the video segments of different plots, so as to distinguish the video segments of different plots. The transition barrage style attribute is used to display the barrage style of the barrage data in the intermediate video sub-segment. The intermediate video sub-segment can refer to the last n video frames in the first video segment in the playing order, or the first m video frames in the second video segment in the playing order, where n and m are positive integers, or the last n video frames and the first m video frames. The transition barrage style attribute is also used to balance the difference between the first barrage style attribute and the second barrage style attribute, so that the barrage data displayed in the video segments of different plots can be smoothly connected, that is, the first display difference between the first barrage style attribute and the second barrage style attribute is greater than the second display difference between the first barrage style attribute and the transition barrage style attribute, and the first display difference is greater than the third display difference between the second barrage style attribute and the transition barrage style attribute. The first display difference can refer to the difference between the barrage data displayed according to the first barrage style attribute and the barrage data displayed according to the second barrage style attribute. The second display difference can refer to the difference between the barrage data displayed according to the first barrage style attribute and the barrage data displayed according to the transition barrage style attribute. The third display difference can refer to the difference between the barrage data displayed according to the second barrage style attribute and the barrage data displayed according to the transition barrage style attribute. The first display difference, the second display difference, and the third display difference are all calculated for barrage data with the same text content. The transition barrage style attribute can be referred to as a compromise barrage style attribute of the first barrage style attribute and the second barrage style attribute.

[0058] In an embodiment, the transition barrage style attribute is used to indicate that the barrage data is displayed in a static display manner, and the first barrage style attribute and the second barrage style attribute are both used to indicate that the barrage data is displayed in a dynamic display manner. The first barrage style attribute and the second barrage style attribute have one or more of the following differences: a. the first barrage moving direction in the first barrage style attribute is opposite to the second barrage moving direction in the second barrage style attribute, i.e. the first barrage moving direction is opposite to the second barrage moving direction; for example, the first barrage moving direction is from left to right, and the second barrage moving direction is from right to left; or, the first barrage moving direction is from right to left, and the second barrage moving direction is from left to right. b. the first barrage arrangement direction in the first barrage style attribute is opposite to the second barrage arrangement direction in the second barrage style attribute, i.e. the first barrage arrangement direction is opposite to the second barrage arrangement direction; for example, the first barrage arrangement direction is from left to right, and the second barrage arrangement direction is from right to left; or, the first barrage arrangement direction is from right to left, and the second barrage arrangement direction is from left to right. c. the first moving speed in the first barrage style attribute is different from the second moving speed in the second barrage style attribute; for example, the first moving speed (e.g. an accelerated moving speed) is greater than the second moving speed (e.g. a general moving speed), or, the first moving speed (e.g. a general moving speed) is less than the second moving speed (e.g. an accelerated moving speed).

[0059] In one embodiment, the transitioned BGM style attribute, the first BGM style attribute and the second BGM style attribute all indicate that the BGM data is displayed in a dynamic display manner. The transitioned BGM style attribute, the first BGM style attribute and the second BGM style attribute have one or more of the following differences: 1. The BGM moving speeds included in the transitioned BGM style attribute, the first BGM style attribute and the second BGM style attribute are different from each other, and the BGM moving speed in the transitioned BGM style attribute belongs to a moving speed interval, which is an open interval formed by the BGM moving speed in the first BGM style attribute and the BGM moving speed in the second BGM style attribute. 2. The color values included in the transitioned BGM style attribute, the first BGM style attribute and the second BGM style attribute are different from each other, and the color value in the transitioned BGM style attribute belongs to a color value interval, which is an open interval formed by the color value in the first BGM style attribute and the color value in the second BGM style attribute. 3. The transparency included in the transitioned BGM style attribute, the first BGM style attribute and the second BGM style attribute are different from each other, and the transparency in the transitioned BGM style attribute belongs to a transparency interval, which is an open interval formed by the transparency in the first BGM style attribute and the transparency in the second BGM style attribute. 4. The font sizes included in the transitioned BGM style attribute, the first BGM style attribute and the second BGM style attribute are different from each other, and the font size in the transitioned BGM style attribute belongs to a font size interval, which is an open interval formed by the font size (i.e. font size) in the first BGM style attribute and the font size in the second BGM style attribute, for example, the font size in the first BGM style attribute is 5 font, the font size in the second BGM style attribute is 14 font, and the font size in the transitioned BGM style attribute is 8 font. 5. The font types included in the transitioned BGM style attribute, the first BGM style attribute and the second BGM style attribute are different from each other, for example, the font type in the transitioned BGM style attribute is Song, the font type in the first BGM style attribute is Kai, and the font type in the second BGM style attribute is Hei.

[0060] In one embodiment, the transitioned BGM style attribute, the first BGM style attribute and the second BGM style attribute all indicate that the BGM data is displayed in a static display manner. The font type, font size, color value and transparency included in the transitioned BGM style attribute, the first BGM style attribute and the second BGM style attribute are different from each other.

[0061] Virtual track: abstracting the line on the video screen for displaying the barrage data as L virtual tracks, that is, one line corresponds to one virtual track, the virtual track is used to carry one or more barrage data, and maintain the mapping of the position, size, affine transformation and other barrage style attributes of any barrage data on the virtual track and time, which is a function of spatial information and time information, L is a positive integer. Affine transformation can be the change of barrage style attribute, such as switching from the first barrage style attribute to the transition barrage style attribute.

[0062] Plot: refers to the plot of video data, according to the role, the plot of video data includes the plot of the main character, the plot of the supporting role, etc.; according to the scene, the plot of video data includes indoor plot (the plot of video data shot indoors), outdoor plot (the plot of video data shot outdoors), courtyard plot (the plot of video segment including courtyard), lawn plot (the plot of video segment including lawn), etc. According to the timeline, the plot of video data includes time reversal plot, time sequence plot, time reversal plot refers to the plot presented in a reverse order, time reversal plot is divided into two types, cyclic time reversal plot and non-cyclic time reversal plot. Cyclic time reversal plot refers to playing back the video segment played at the last time in a reverse order, that is, the content presented by the video segment corresponding to the cyclic time reversal plot and the video segment played at the last time is the same, for example, in video segment 1, the growth of a sapling from January to December in 2023 is presented in turn, in video segment 2, the growth of the sapling from December to January in 2023 is presented in turn, that is, the plot of video segment 2 can be called cyclic time reversal plot. Non-cyclic time reversal plot refers to the content presented by the video segment played at the last time and the video segment played at the next time is not the same, and the occurrence time of the plot in the video segment played at the last time is later than the occurrence time of the plot in the video segment played at the next time. For example, in video segment 3, the growth of a sapling in 2023 is presented, then in video segment 4, the growth of the sapling in 2022 is presented, the plot of video segment 4 can be called non-cyclic time reversal plot. Time sequence plot refers to the plot presented in the order of occurrence time, for example, in video segment 5, the growth of a sapling in June 2023 is presented from 1s to 10s, the growth of the sapling in July 2023 is presented from 11s to 20s, that is, the plot of video segment 5 can be called time sequence plot.

[0063] In order to facilitate a clearer understanding of the present application, first introduce the barrage display system for implementing the present application, as shown in the figure, the barrage display system includes a server 10 and a terminal cluster, the terminal cluster can include one or more terminals, here the number of terminals will not be limited. As shown in the figure, Figure 1 Figure 1 ​As shown, the terminal cluster can specifically include terminal 1, terminal 2, …, and terminal y. It can be understood that terminal 1, terminal 2, terminal 3, …, and terminal y can all be connected to the server 10 in a network, so that each terminal can interact with the server 10 through the network connection.

[0064] It can be understood that the server can be an independent physical server, or a server cluster or distributed system composed of at least two physical servers, or a cloud server providing cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDN), and big data and artificial intelligence platforms, etc. Basic cloud computing services. The terminal can specifically refer to a vehicle-mounted terminal, a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart speaker, a screen-equipped speaker, a smart television, a smart watch, etc., but is not limited thereto. Each terminal and the server can be directly or indirectly connected through wired or wireless communication, and the number of terminals and servers can be one or at least two, which is not limited in the present application.

[0065] The terminal is installed with one or more target applications, which can be an application for playing video data, such as an independent application program, a web application, a small program in a host application, etc. The target task can refer to a video live application, a short video application, a video teaching application, a social application, a video playing application, and a video conference application, etc. The server 10 refers to a device that provides backend services for the target application in the terminal, such as the server 10 can be used to optimize and update the target application in the terminal. In the present application, the server 10 can also be used to identify the plot change moment in the video data, and send the plot change moment to the terminal, so that the terminal can divide the video data according to the plot change moment to obtain multiple video segments, and adaptively display the barrage data in the video segments.

[0066] For example, as shown in FIG. 1, the server 10 can be connected to a plurality of terminals, such as terminal 1, terminal 2, …, and terminal y, and the server 10 can be connected to a plurality of terminals through a network, such as a local area network (LAN) or a wide area network (WAN), such as the Internet. Figure 2As shown, the terminal 1 adaptively displays the barrage data in the video clip is taken as an example, the video clip can belong to the target video data, the target video data can be any video data in the target application installed in the terminal 1. The process that the terminal 1 adaptively displays the barrage data in the video clip can be realized by the interaction between the terminal 1 and the server 10, first, the server 10 can identify the plot change moment, the plot change moment reflects the time when the plot changes in the target video data; the plot change moment of the target video data reflects the time when the plot changes in the target video data through any of the following three ways; way one, the server 10 can obtain the plot change moment of the target video data marked by the operator. Way two, the server 10 can call the identification model to identify the plot change moment of the target video data, that is, calling the identification model, according to the barrage data in the target barrage set in the target video data to identify the plot change moment, obtaining the plot change moment of the target video data, the identification model can be a text recognition model, the identification model can specifically include convolution recurrent neural network (Convolutional Recurrent Neural Network, CRNN), robust text recognition and automatic rectification (Robusttext renognizer with Automatic Rectification, RARE) and the like. Way three, the server 10 can call the graphic text recognition model to identify the plot change moment of the target video data, that is, calling the graphic text recognition model, according to the script data of the target video data, identifying the plot change moment of the target video data; the graphic text recognition model is a model used for matching video frames and script data in video data to identify the plot change moment, for example, the script data describes the courtyard and the lawn, the image recognition model is used to identify the video clip presenting the courtyard and the video clip presenting the lawn from the target video data, that is, the starting playing moment of the lawn video clip is the plot change moment. The graphic text recognition model can be a clip model, multi-modal cross attention mechanism (Multi-Modality Cross Attation, MMCA) and the like.

[0067] Once server 10 obtains the plot change moment of the target video data, server 10 can execute a server-side response process, that is, server 10 can send the plot change moment to terminal 1. After receiving the plot change moment, terminal 1 displays and interacts with it. That is, terminal 1 can divide the target video data according to the plot change moment to obtain a first video segment and a second video segment. Furthermore, terminal 1 can switch one or more of the following for the bullet screen data in the second video segment: bullet screen movement direction, bullet screen arrangement direction, bullet screen movement speed, etc. When a trigger operation on the bullet screen style switching control is detected, terminal 1 can turn off the bullet screen switching, that is, display the bullet screen data according to the original bullet screen style attributes.

[0068] For example, such as Figure 3 As shown, taking the example of terminal 1 switching the direction of bullet comment movement and the direction of bullet comment arrangement in the second video segment, the target video data is a video showing the growth of a kitten, and the plot change occurs at the 4th second (s) of the target video data. Therefore, the first video segment includes video frames from the 0th to the 4th second of the target video data, and the first video segment sequentially presents the growth of the kitten from 1 month to 12 months after birth, that is, the plot of the first video segment is a chronological plot. The second video segment consists of video frames from the 4th to the 7th second of the target video data, and the second video segment sequentially presents the growth of the kitten from 12 months to 1 month after birth, that is, the plot of the second video segment is a cyclical time-reversal plot. During the playback of the first video segment, terminal 1 can display bullet comment data from the first bullet comment set according to the first bullet comment style attributes. The bullet comment data in the first bullet comment set is the bullet comment data associated with the first video segment. Taking the first bullet screen style attributes, including the first bullet screen arrangement direction and the first bullet screen movement direction, as an example, the first bullet screen arrangement direction is from left to right, and the first bullet screen movement direction is from right to left. For example... Figure 3In the barrage display region 31a in the video frame 30a, three pieces of barrage data in the first barrage set are included, respectively including good and lovely, good to take home, and petting a cat. The video frame 30a is a video frame at a 2s play time in the first video segment. Similarly, in the barrage display region 33a in the video frame 32a, three pieces of barrage data in the first barrage set are included, respectively including good to take home, still lovely when a cat is small, and the eyes of a grown-up cat become large. The video frame 32a is a video frame at a 4s play time in the first video segment. Comparing the video frame 30a with the video frame 32a, it can be known that the barrage moving direction of the barrage data in the first video segment is from right to left, such as the barrage data good to take home in the video frame 30a, which is located at the left side of the barrage display region 31a, and the barrage data good to take home in the video frame 32a, which is located at the right side of the barrage display region 33a, that is, the barrage data good to take home is moved from the left side of the video screen to the right side. It can be known from the video frame 30a and the video frame 32a that the barrage arrangement direction of the barrage data in the first video segment is from left to right.

[0069] Further, after the first video segment is played, the terminal 1 can play a first video sub-segment of a second video segment, and display barrage data in a second barrage set in the first video sub-segment according to the transition barrage style attribute. The first video sub-segment can be one or more video frames adjacent to the first video segment in the second video segment, and the second barrage set refers to barrage data associated with the second video segment. The second barrage set can be the same as the first barrage set, or the second barrage set has some same barrage data as the first barrage set, or the first barrage set is completely different from the second barrage set. Figure 3 The second barrage set has some same barrage data as the first barrage set is taken as an example for description, and meanwhile, Figure 3 The transition barrage style attribute reflecting the static display of the barrage data is taken as an example for description. Figure 3 In the target video data, the video frame at a 4s play time to a 4.8s play time is the first video sub-segment of the second video segment (not including the video frame displayed at the 4s play time), and the second barrage set includes barrage data displayed at the last video frame in the first video segment in the play order, that is, good to take home, still lovely when a cat is small, and the eyes of a grown-up cat become large. As shown in FIG. 3, the video frame at the 4s play time in the second video segment is the first video sub-segment of the second video segment, and the barrage data displayed at the 4s play time in the second video segment is included in the second barrage set. Figure 3In the second video sub-segment, the three pieces of the second barrage data are included in the barrage display region 37a in the video frame 36a, including: love can wait for the time (i.e., the part of the content that the small cat is still when love can wait for the time), the eyes of the cat have changed (i.e., the part of the content that the cat has grown up and the eyes have changed), and the moving backward barrage; the video frame 36a is the video frame with the playing time of 5s in the target video data. In the barrage display region 39a in the video frame 38a, the three pieces of the second barrage data are included, including: the small cat is still when love can wait for the time, the cat has grown up and the eyes have changed, and the time flows backward; the video frame 38a is the video frame with the playing time of 7s in the target video data. Comparing the video frame 36a and the video frame 38a in the second video sub-segment, it can be known that the moving direction of the barrage data in the second video sub-segment is from left to right, such as the barrage data: love can wait for the time in the video frame 36a, which is located at the right side of the barrage display region 37a, and the barrage data is located at the left side of the barrage display region 39a in the video frame 38a, i.e., the barrage data: love can wait for the time (or the small cat is still when love can wait for the time), which is moved from the right side of the video screen to the left side. It can be known from the video frame 36a and the video frame 38a that the arrangement direction of the barrage data in the second video sub-segment is from right to left.

[0070] Then, after the first video sub-segment is played, the terminal 1 can play the second video sub-segment in the second video segment, and switch to display the barrage data in the second barrage set in the second video sub-segment according to the second barrage style attribute; the second video sub-segment refers to the video frame in the second video segment in the playing order after the first video sub-segment. The second video sub-segment includes the video frames with the playing time from 4.8s to 7s in the target video data (not including the video frame with the playing time of 4.8s; taking the second barrage style attribute including the second barrage arrangement direction and the second barrage moving direction as an example, the second barrage arrangement direction is from right to left, and the second barrage moving direction is from left to right. As shown in FIG. 4, the second video sub-segment includes the video frames with the playing time from 5s to 7s in the target video data. Figure 3 In the second video sub-segment, the three pieces of the second barrage data are included in the barrage display region 37a in the video frame 36a, including: love can wait for the time (i.e., the part of the content that the small cat is still when love can wait for the time), the eyes of the cat have changed (i.e., the part of the content that the cat has grown up and the eyes have changed), and the moving backward barrage; the video frame 36a is the video frame with the playing time of 5s in the target video data. In the barrage display region 39a in the video frame 38a, the three pieces of the second barrage data are included, including: the small cat is still when love can wait for the time, the cat has grown up and the eyes have changed, and the time flows backward; the video frame 38a is the video frame with the playing time of 7s in the target video data. Comparing the video frame 36a and the video frame 38a in the second video sub-segment, it can be known that the moving direction of the barrage data in the second video sub-segment is from left to right, such as the barrage data: love can wait for the time in the video frame 36a, which is located at the right side of the barrage display region 37a, and the barrage data is located at the left side of the barrage display region 39a in the video frame 38a, i.e., the barrage data: love can wait for the time (or the small cat is still when love can wait for the time), which is moved from the right side of the video screen to the left side. It can be known from the video frame 36a and the video frame 38a that the arrangement direction of the barrage data in the second video sub-segment is from right to left.

[0071] In summary, by switching the direction of the barrage arrangement and the direction of the barrage movement for the barrage data, the user is prompted that there is a plot change between the front and rear video clips (i.e., the first video clip and the second video clip), which is conducive to improving the user's perception of the plot change, helping the user quickly understand the plot of the target video data, improving the display flexibility and diversity of the barrage data; at the same time, it can avoid the user understanding the plot of the video data by multiple video data playback, and can reduce the resource (such as the resource required to load the video data) overhead of the terminal. In addition, by pausing the moving barrage data in the middle video sub-clip (i.e., the first video sub-clip), it can avoid the situation of empty screen (i.e., no barrage data) and abruptness in the video clip, and make the barrage data displayed in the front and rear video clips smoothly connected.

[0072] Further, please refer to Figure 4 , which is a flowchart of a barrage display method provided by an embodiment of the present application. As Figure 4 indicated, the method can be executed by any terminal in the terminal cluster, or can be executed by the server, or can be executed by the terminal and the server in cooperation, that is, the device for executing the barrage display method in the present application can be a computer device, which can be a terminal or a server. In the present embodiment, the computer device is taken as an example for illustration. The method can include the following steps: Figure 1 Figure 1 S101, during the playing process of the first video clip of the target video data, displaying the barrage data in the first barrage set in the first video clip according to the first barrage style attribute. Figure 1 In the present application, the computer device can play the first video clip in the target video data, and display the barrage data in the first barrage set in the first video clip according to the first barrage style attribute. The barrage data in the first barrage set is the barrage data associated with the first video clip, such as the comment data (also referred to as the message data) published by the viewer when watching the first video clip.

[0073] It should be noted that the first barrage style attribute indicates that the barrage data is displayed in a static display mode, or the first barrage style attribute indicates that the barrage data is displayed in a dynamic display mode; the first barrage style attribute includes the time parameter and the space parameter mentioned above.

[0074]

[0075]

[0076] ​​​Optionally, when the first barrage style attribute indicates to display the barrage data in a dynamic display manner, the first barrage style attribute comprises a first barrage moving direction and a first barrage arrangement direction; and the displaying, according to the first barrage style attribute, the barrage data in the first video segment in the first barrage set comprises: the computer device can arrange the text content of the barrage data in the first barrage set according to the first barrage arrangement direction, and move the arranged barrage data in the first barrage set in the first video segment according to the first barrage moving direction.

[0077] It should be noted that the first barrage arrangement direction can be the aforementioned barrage normal arrangement direction or barrage reverse arrangement direction, and the first barrage moving direction can be the aforementioned barrage normal flow direction or barrage reverse flow direction.

[0078] Optionally, the first barrage style attribute can further comprise a first moving speed, which is the aforementioned or accelerated moving speed; and the computer device can move the arranged barrage data in the first barrage set in the first video segment according to the first barrage moving direction and the first moving speed, i.e., constantly update the position of the arranged barrage data in the first barrage set in the first video segment according to the first barrage moving direction and the first moving speed.

[0079] It can be understood that the computer device can obtain the first video segment and the second video segment in the target video data by any one of the following three obtaining manners. In the first obtaining manner, the computer device can obtain a plot change moment of the target video data marked by an operator, divide the target video data according to the plot change moment to obtain the first video segment and the second video segment. For example, the plot change moment comprises a start time point, and the start time point is the start time of the second video segment. At this time, the computer device can determine the video segment between the last plot change moment and the plot change moment as the first video segment, and determine the video segment between the plot change moment and the next plot change moment as the second video segment. Alternatively, the plot change moment comprises a start time point and an end time point, the start time point can be the start time point of the second video segment, i.e., the start time point is also called the end time point of the first video segment, and the end time point can be the end time of the second video segment. At this time, the computer device can determine the video segment between the end time point contained in the last plot change moment and the start time point of the plot change moment in the target video data as the first video segment, and determine the video segment between the start time point contained in the plot change moment and the end time point of the plot change moment in the target video data as the second video segment.

[0080] For example, asFigure 5 As shown, the computer device can display a configuration interface 50a in response to a configuration operation for a plot change time, the configuration interface 50a can include a start time point setting control 51a and an end time point setting control 52a of a plot change time, in response to a trigger operation for the start time point setting control 51a, the time point selected (or input) through the start time point setting control 51a is obtained as a start time point; in response to a trigger operation for the end time point setting control 52a, the time point selected (or input) through the end time point setting control 52a is obtained as an end time point. The start time point and the end time point are determined as the plot change time, and the target video data is divided according to the plot change time to obtain the first video segment and the second video segment. By setting the plot change time by the user, the flexibility of obtaining the plot change time is improved.

[0081] In a second obtaining manner, the computer device can obtain a target barrage set in the target video data; the first barrage set and the second barrage set are subsets of the target barrage set, that is, the target barrage set includes the barrage data in the first barrage set and the second barrage set. The computer device can call the recognition model to perform text feature recognition on the barrage data in the target barrage set to obtain the text feature of the barrage data in the target barrage set, and the text feature is used to reflect the semantics of the corresponding barrage data. Further, the target video data is divided according to the text feature of the barrage data in the target barrage set to obtain the first video segment and the second video segment.

[0082] Optionally, the computer device can divide the target video data according to the text feature of the barrage data in the target barrage set to obtain the first video segment and the second video segment. The implementation manner can include the first dividing manner and the second dividing manner. In the first dividing manner, the computer device can traverse the text features of the barrage data in the target barrage set in the order of the publishing time of the barrage data, and when the similarity of the text features of adjacent barrage data is less than a similarity threshold, the publishing time of any barrage data in the adjacent barrage data is determined as the plot change time of the target video data, and the target video frame is divided according to the plot change time to obtain the first video segment and the second video segment. The adjacent barrage data here can refer to the two barrage data with the closest publishing time.

[0083] In the second segmentation method, the computer equipment can determine the text similarity between the text features of the bullet screen data in the target bullet screen set and the text features of plot change. The plot change text features can be obtained by feature extraction of text content reflecting plot changes, including timelines, past events, flashbacks, scene changes, replays, and rewinds. Further, the number of bullet screens in the target bullet screen set whose text similarity is greater than a similarity threshold within S release times is counted. These S release times are the times when the bullet screen data in the target bullet screen set is released, where S is a positive integer. From these S times, the moments when the number of bullet screens exceeds a threshold are selected as plot change moments. That is, when a large number of bullet screens reflecting plot changes appear at a certain moment, that moment is determined as a plot change moment. Then, based on the plot change moment, the target video data is segmented to obtain the first video segment and the second video segment.

[0084] For example, such as Figure 6 As shown, in the target video data, video frames with playback time from the 5th to the 6th second all display bullet screen data where the text similarity between text features and plot change text features is greater than the similarity threshold, such as... Figure 6 The bullet screen display area 61a in video frame 60a displays bullet screen data: time rewind, replay, the sapling has grown taller. That is, the text similarity between the text features of the bullet screen data: time rewind and replay and the text features of script change is greater than the similarity threshold. Video frame 60a is the video frame with a playback time of 5 seconds in the target video data. Figure 6 In video frame 62a, the bullet screen display area 63a displays bullet screen data: timeline, replay, and sapling. This means the text similarity between the text features of the bullet screen data (timeline and replay) and the script change text features is greater than the similarity threshold. Video frame 62a is the video frame in the target video data with a playback time of 6 seconds. Assuming a threshold of 4, 5 similar bullet screen data are counted from the video frames in the target video data with playback times from 5 seconds to 6 seconds. This means the similar bullet screen data are those whose text similarity between the text features and the script change text features is greater than the similarity threshold. Any moment in [5,6] seconds can be considered a plot change moment; for example, 5 seconds can be considered a plot change moment, 6 seconds can be considered a plot change moment, or 5.5 seconds can be considered a plot change moment.

[0085] The third obtaining manner is that the computer device can obtain the script data corresponding to the target video data from a webpage or locally. The script data is mainly composed of dialogues and stage instructions (i.e., scene descriptions) of the target video data, and is a text basis for dramatic art creation and a basis for directors and actors to perform. Then, the aforementioned OCR model is called to extract object description information and the occurrence time of the object description information from the script data corresponding to the target video data. The object description information refers to information for describing an object (i.e., a real object), which can include a character, a building, a plant, an action, etc. Further, the script scene information set associated with the target video data is determined according to the occurrence time of the object description information and the object description information. The script scene information set includes one or more script scene information. The script scene information is used to reflect a scene described in the script data. The scene can include an indoor scene, an outdoor scene, a lawn scene, a courtyard scene, a time-space reversal scene, a time sequence scene, etc. The time-space reversal scene herein refers to a time at which a plot described in a text segment 1 is later than a time at which a plot described in a text segment 2, the text segment 2 appears earlier than the text segment 1 in the script data, i.e., the scene described in the text segment 2 is a time-space reversal scene. The time-space reversal scene includes a cyclic time-space reversal scene and a non-cyclic time-space reversal scene. For example, when the text segment 2 describes a playback of the plot described in the text segment 1, the scene described in the text segment 2 is a cyclic time-space reversal scene. When the text segment 2 describes a playback of a plot that occurs before the plot described in the text segment 1, the scene described in the text segment 2 is a non-cyclic time-space reversal scene. After obtaining the script scene information set, the target video data can be divided according to the script scene information set to obtain the first video segment and the second video segment.

[0086] Optionally, the dividing of the target video data according to the script scene information set to obtain the first video segment and the second video segment includes that the computer device can call the aforementioned OCR model to perform frame-by-frame traversal between the script scene information i in the script scene information set and the video frames that have not been traversed in the target video data, where i is less than or equal to F, and F is the number of script scene information in the script scene information set. If the matching degree between the target video frame and the script scene information i is less than a matching degree threshold, the computer device can determine the playing time of the target video frame as a plot change time of the target video data, and divide the target video data according to the plot change time to obtain the first video segment and the second video segment.

[0087] S102, if the first video segment is played, a first video sub-segment of a second video segment in the target video data is played, and switching to display the second set of bullet screen data in the first video sub-segment according to the transition bullet screen style attribute; the plot of the first video segment is different from the plot of the second video segment.

[0088] In the present application, if the first video segment is played, the computer device can play a first video sub-segment in the second video segment in the target video data, and switch to display the second set of bullet screen data in the first video sub-segment according to the fixed bullet screen style attribute. The first video sub-segment can refer to one or more video frames adjacent to the first video segment in the second video segment. The number of frames in the first video sub-segment can be determined according to the transition bullet screen style attribute. For example, the transition bullet screen style attribute indicates that the moving bullet screen data is paused, and the duration of the pause is a preset duration. The first video sub-segment is the first m video frames in the second video segment in the order of play. The play duration of the first m video frames can be the preset duration. The preset duration can also be referred to as the display duration of the second set of bullet screen data according to the transition bullet screen style attribute.

[0089] It should be noted that the plot of the first video segment is different from the plot of the second video segment, which means that: 1. According to the role division, the plot of the first video segment is the main character plot, and the plot of the second video segment is the supporting character plot; or, the plot of the first video segment is the supporting character plot, and the plot of the second video segment is the main character plot. 2. According to the scene division, the plot of the first video segment and the plot of the second video segment are any one of indoor plot, outdoor plot, courtyard plot, lawn plot, etc. For example, the plot of the first video segment is indoor plot, and the plot of the second video segment is outdoor plot. 3. According to the timeline division, the plot of the first video segment can be time sequence plot, and the plot of the second video segment can be time-space reversal plot; or, the plot of the first video segment can be time-space reversal plot, and the plot of the second video segment can be time sequence plot. 4. According to the authenticity division, the plot of the first video segment can be real plot, and the plot of the second video segment can be virtual plot; or, the plot of the first video segment can be virtual plot, and the plot of the second video segment can be real plot; real plot can refer to real story, and virtual plot can refer to story imagined by the actor in the current scene. For example, the first video segment plays a segment of Xiaowang making a travel plan to A place, and the second video segment plays Xiaowang's imagination of the food and scenery in A place during the process of making the travel plan to A place, i.e. the plot of the first video segment can be referred to as real plot, and the plot of the second video segment can be referred to as virtual plot.

[0090] It should be noted that the barrage data in the second barrage set can include barrage data associated with the second video segment, that is, the barrage data in the second barrage set includes comment data (also referred to as message data) published by the viewer when watching the second video segment.

[0091] In an embodiment, the second barrage set can be the same as the first barrage set, for example, if the content described by the second video segment is the same as the content described by the first video segment, indicating that the second video segment is a playback of the first video segment, that is, the plot of the second video segment is a cyclic time-space reverse plot, the first barrage set is the same as the second barrage set, the first barrage set is associated with the first video segment, or the first barrage set is associated with the second video segment; the first barrage set is cyclically displayed in the second video segment. At this time, the first barrage set and the second barrage set both include barrage data published by the viewer when watching the first video segment and the second video segment.

[0092] In an embodiment, the second barrage set has some same barrage data as the first barrage set, for example, when the content described by the second video segment is not the same as the content described by the first video segment, the second barrage set includes barrage data displayed in the last video frame of the first video segment in the first barrage set, and barrage data associated with the second video segment, the first barrage set includes barrage data associated with the first video segment, and the last video frame is a video frame located at the end of the playing order in the first video segment. In other words, the first barrage set includes barrage data published by the viewer when watching the first video segment, and the second barrage set includes barrage data displayed in the last video frame of the first video segment in the first barrage set, and barrage data published by the viewer when watching the second video segment, which facilitates smooth connection of barrage data.

[0093] In an embodiment, the first barrage set is completely different from the second barrage set, for example, when the content described by the second video segment is not the same as the content described by the first video segment, the first barrage set is associated with the first video segment, that is, the barrage data in the first barrage set is associated with the first video segment; the second barrage set is associated with the second video segment, that is, the barrage data in the second barrage set is associated with the second video segment. Since the content described by the second video segment is not the same as the content described by the first video segment, the first barrage set is different from the second barrage set. That is, when the content described by the video segment is different, the barrage data will also be updated following the change of the content, ensuring that the barrage data read by the user is real-time changed following the content described by the video segment, and improving the association degree of the barrage data and the video segment.

[0094] It should be noted that the first and second barrage sets are completely different, which means that the first barrage set includes the barrage data published by the viewer when playing the first video segment, and the second barrage set includes the barrage data published by the viewer when watching the second video segment. However, the first and second barrage sets may include barrage data with the same text content, such as the first barrage set and the second barrage set both including: This drama is so wonderful. Because the publishing times are different, the first barrage set including: This drama is so wonderful is considered different from the second barrage set including: This drama is so wonderful.

[0095] Optionally, the transition barrage style attribute is used to instruct to display the barrage data in a static display manner, and the transition barrage style attribute includes a display duration; the switching to display the barrage data in the second barrage set in the first video sub-segment according to the transition barrage style attribute includes that the computer device can display the barrage data in the second barrage set at a fixed position in the first video sub-segment according to the display duration.

[0096] In one embodiment, when the second barrage set is the same as the first barrage set, or the second barrage set has partially same barrage data as the first barrage set, the computer device can obtain the barrage data (referred to as last barrage data) displayed in the video frame with the last playing order in the first video segment, and display the last barrage data at a fixed position in the first video sub-segment according to the display duration. As shown in Figure 3 The computer device can display the last barrage data at a fixed position in the video frame with a playing time of 4s to 4.8s in the target video data, and the last barrage data is the barrage data displayed in the video frame (i.e., video frame 32a) with the last playing order in the first video segment, that is, good to take home, or cute when a cat is small, and the eyes of a cat become large after growing up.

[0097] In one embodiment, the first and second barrage sets are completely different, and the computer device can obtain the barrage data associated with the first video segment from the second barrage set, and display the barrage data associated with the first video segment at a fixed position in the first video sub-segment according to the display duration. The barrage data associated with the first video segment refers to the barrage data published by the viewer when watching the first video sub-segment.

[0098] For example, as Figure 7As shown, the video frame 70a can be the last video frame in the playing order in the first video segment, and the video frame 70a can be the video frame with the playing time of 5s in the target video data. The BGM displayed in the BGM display area 71a in the video frame 70a includes: a teacher, and I have read this book. The video frame 72a can be the first video frame in the playing order in the first video sub-segment, and the video frame 72a can be the video frame with the playing time of 5.1s in the target video data. The BGM displayed in the BGM display area 73a in the video frame 72a includes: the main character appears, is there anyone, and the main character is very beautiful. Comparing the video frame 72a with the video frame 70a, it can be found that the BGM displayed in the video frame 72a is different from the BGM displayed in the video frame 70a. The other video frames in the first video sub-segment continue to display the BGM in the video frame 72a in the display manner of the video frame 72a, and the other video frames are the video frames in the first video sub-segment except the video frame 72a.

[0099] Optionally, the fixed position is determined according to the position of the BGM displayed in the last video frame in the playing order in the first video segment, and the fixed position refers to the position of the BGM displayed in the last video frame in the playing order in the first video segment, so as to facilitate the smooth connection of the BGM.

[0100] Optionally, the fixed position is any position in the BGM display area in the first video sub-segment.

[0101] S103, if the first video sub-segment is played, the second video sub-segment in the second video segment is played, and the display of the BGM data in the second BGM set in the second video sub-segment is switched to the second BGM style attribute; the first BGM style attribute, the transition BGM style attribute and the second BGM style attribute are different.

[0102] In this application, if the first video sub-segment is played, the second video sub-segment in the second video segment is played, and the display of the BGM data in the second BGM set in the second video sub-segment is switched to the second BGM style attribute, and the second video sub-segment includes the video frames in the second video segment except the first video segment.

[0103] It should be noted that the scroll data displayed in the first g video frames in the second video sub-fragment is the same as the scroll data displayed in the first video sub-fragment, where the same refers to the same scroll data, g can be a positive integer, and the scroll data in the second scroll set that is not displayed is displayed in the video frames after the first g video frames in the second video sub-fragment, that is, the scroll data displayed in the video frames after the first g video frames in the second video sub-fragment is different from the scroll data displayed in the first video sub-fragment.

[0104] It should be noted that the second scroll style attribute indicates that the scroll data is displayed in a static display manner, or the second scroll style attribute indicates that the scroll data is displayed in a dynamic display manner; the second scroll style attribute includes the time parameter and the space parameter mentioned above.

[0105] It should be noted that when the first scroll style attribute and the second scroll style attribute both indicate that the scroll data is displayed in a dynamic display manner, the first scroll style attribute includes a first scroll moving direction, a first scroll arrangement direction, and a first moving speed; the second scroll style attribute includes a second scroll moving direction, a second scroll arrangement direction, and a second moving speed. The first scroll style attribute and the second scroll style attribute have one or more of the following differences: a, the first scroll moving direction is the opposite direction of the second scroll moving direction; b, the first scroll arrangement direction is the opposite direction of the second scroll arrangement direction, c, the first moving speed and the second moving speed are different.

[0106] Optionally, the second scroll moving direction included in the second scroll style attribute is different from the first scroll moving direction included in the first scroll style attribute; the above displaying the scroll data in the second scroll set in the second video sub-fragment according to the second scroll style attribute includes that the computer device can move and display the scroll data in the second scroll set in the second video sub-fragment according to the second scroll moving direction. By switching the scroll moving direction, the user is prompted that the plot of the video sub-fragment has changed, the user's perception of the plot change is improved, and the user's plot interpretation ability is enhanced.

[0107] Optionally, the second barrage style attribute further comprises a second moving speed, and the moving display of the barrage data in the second barrage set in the second video sub-segment according to the second barrage moving direction comprises: moving display of the barrage data in the second barrage set in the second video sub-segment according to the second barrage moving direction and the second moving speed. The second moving speed can be determined according to the switching speed of the video frames in the second video segment. Similarly, the first moving speed in the first barrage attribute style can be determined according to the switching speed of the video frames in the first video segment. Therefore, when the switching speed of the video frames in the second video sub-segment is equal to the switching speed of the video frames in the first video segment, the second moving speed is equal to the first moving speed; when the switching speed of the video frames in the second video sub-segment is less than the switching speed of the video frames in the first video segment, the second moving speed is less than the first moving speed. When the switching speed of the video frames in the second video sub-segment is greater than the switching speed of the video frames in the first video segment, the second moving speed is greater than the first moving speed. By adjusting the moving speed of the barrage data adaptively according to the switching speed of the video frames, the display flexibility of the barrage data is increased.

[0108] For example, when the plot of the second video segment is a time-space reversal plot, if the switching speed of the video frames in the second video sub-segment is less than or equal to the switching speed threshold, generally, the plot of the second video segment is a non-cyclic time-space reversal plot, that is, the video picture presents a slow and natural time-space switching effect, at this time, the second moving speed can be a general moving speed, then the computer device can move display the arranged barrage data in the second barrage set in the second video sub-segment according to the second barrage moving direction and the general moving speed, to display the effect of normally moving barrage data. If the switching speed of the video frames in the second video sub-segment is greater than the switching speed threshold, generally, the plot of the second video segment is a cyclic time-space reversal plot, that is, the video picture presents a fast reversal (i.e. playback) effect, at this time, the second moving speed can be an accelerated moving speed, then the computer device can move display the arranged barrage data in the second barrage set in the second video sub-segment according to the second barrage moving direction and the accelerated moving speed; to display the effect of accelerated moving barrage data, that is, by increasing the moving speed of the barrage data, the effect of fast reversal of the video picture can be matched.

[0109] Similarly, if the switching speed of the video frames in the first video sub-segment is less than or equal to the switching speed threshold, the first moving speed can be the general moving speed mentioned above; if the switching speed of the video frames in the first video sub-segment is greater than the switching speed threshold, the first moving speed can be the accelerated moving speed mentioned above.

[0110] Optionally, the first moving speed and the second moving speed can be preset, for example, the first moving speed can be a general moving speed and the second moving speed can be an accelerated moving speed; or the first moving speed can be an accelerated moving speed and the second moving speed can be a general moving speed.

[0111] In one embodiment, the second barrage arrangement direction included in the second barrage style attribute is different from the first barrage arrangement direction included in the first barrage style attribute, for example, the first barrage arrangement direction is a normal barrage arrangement direction and the second barrage arrangement direction is a reverse barrage arrangement direction. The computer device can arrange the text content of the barrage data in the second barrage set according to the second barrage arrangement direction, and display the arranged barrage data in the second barrage set in the second video sub-segment. By switching the barrage arrangement direction, the user can be prompted that the plot of the video segment has changed, the user's perception of the plot change can be improved, and the user's plot interpretation ability can be enhanced.

[0112] In one embodiment, the second moving speed included in the second barrage style attribute is different from the first moving speed included in the first barrage style attribute, for example, the first moving speed is greater than the second moving speed, or the second moving speed is greater than the first moving speed, for example, the first moving speed can be a general moving speed and the second moving speed can be an accelerated moving speed. The computer device can display the barrage data in the second barrage set in the second video sub-segment according to the second moving speed. By switching the barrage moving speed, the user can be prompted that the plot of the video segment has changed, the user's perception of the plot change can be improved, and the user's plot interpretation ability can be enhanced.

[0113] In one embodiment, the second barrage style attribute includes a second barrage moving direction and a second moving speed, the second barrage moving direction is opposite to the first barrage moving direction, and the second moving speed is different from the first moving speed. The computer device can display the barrage data in the second barrage set in the second video sub-segment according to the second barrage moving direction and the second moving speed. By switching the barrage moving direction and the barrage moving speed, the user can be prompted that the plot of the video segment has changed, the user's perception of the plot change can be improved, and the user's plot interpretation ability can be enhanced.

[0114] Optionally, the second barrage style attribute comprises a second barrage moving direction and a second barrage arrangement direction; the second barrage moving direction is opposite to the first barrage moving direction, and the second barrage arrangement direction is opposite to the first barrage arrangement direction; and the computer device displays the barrage data in the second barrage set in the second video sub-clip according to the second barrage style attribute, which comprises: the computer device arranges the text content of the barrage data in the second barrage set according to the second barrage arrangement direction, and displays the arranged barrage data in the second barrage set in the second video sub-clip according to the second barrage moving direction, i.e., constantly updates the position of the arranged barrage data in the second barrage set in the second video sub-clip according to the second barrage moving direction. By displaying the barrage data in the video clips of different plots with different barrage style attributes, the user is prompted that the plots of the video clips (i.e., the first video clip and the second video clip) change, which is conducive to improving the user's perception of the plot change, helping the user quickly understand the plot of the target video data, and improving the display flexibility and diversity of the barrage data. By switching the barrage arrangement direction and the barrage moving direction, the user is prompted that the plot of the video clip changes, the reminding strength is enhanced, the user's perception of the plot change is improved, and the user's plot interpretation ability is enhanced. Optionally, when the second barrage style attribute indicates that the barrage data is displayed in a dynamic display mode, the second barrage style attribute can further comprise a second moving speed, which is different from the first moving speed. The second moving speed is the general moving speed or the accelerated moving speed mentioned above. The computer device displays the arranged barrage data in the second barrage set in the second video sub-clip according to the second barrage moving direction and the second moving speed, i.e., constantly updates the position of the arranged barrage data in the second barrage set in the second video sub-clip according to the second barrage moving direction and the second moving speed. By switching the barrage moving speed, the barrage arrangement direction and the barrage moving direction, the user is prompted that the plot of the video clip changes, the reminding strength is enhanced, the user's perception of the plot change is improved, and the user's plot interpretation ability is enhanced.

[0115] In one embodiment, the present application provides a barrage framework, which comprises Figure 8As shown, the barrage framework includes an interface layer, a track and distribution layer, and a barrage rendering layer. The interface layer includes a facade class, which is an interface provided to the outside. The facade class includes a barrage facade management class component and barrage style attributes. The barrage facade management class component integrates other components inside the entire barrage framework and provides external calling methods and barrage event callbacks. The external calling methods include methods for adding and deleting virtual tracks, starting, pausing, and clearing the screen, etc. For example, the track control component can call the external calling methods in the barrage facade management class to add a track (i.e., add a single virtual track), delete a track (i.e., delete a single virtual track), delete all tracks (i.e., delete all virtual tracks, i.e., close the barrage display function), insert attributes, and add a track collection (i.e., add multiple virtual tracks). The insert attributes refer to updating the barrage style attributes of the barrage data. The barrage event callbacks include event callbacks for creating, entering, and leaving the barrage display area. The barrage style attributes are used to control the display mode of the barrage data, including attributes such as the display time limit, position, start display time, and end display time of the barrage data.

[0116] The track and distribution layer can include a barrage dispatcher component, a track control component, a barrage track collection, a barrage clock, a timer, a distribution strategy, queue management, and track management. The track control component is used to maintain barrage data that has been displayed on the virtual track (i.e., already displayed) and barrage data that is waiting to be displayed on the virtual track (i.e., not displayed), and is used for track management (i.e., managing virtual tracks), such as maintaining (e.g., adding and deleting) virtual tracks. The barrage dispatcher component is used to add barrage data to the virtual track according to the distribution strategy. One barrage dispatcher component usually manages multiple virtual tracks and has a barrage queue built-in to store barrage data. The barrage dispatcher component is also used for queue management, such as continuously querying idle virtual tracks under the drive of the barrage clock. When a virtual track meets the condition that the idle degree is greater than the idle degree threshold and the distribution strategy, the barrage data at the head of the barrage queue is added to the virtual track. The idle degree of the virtual track can be determined according to the number of barrage data. The distribution strategy can be a condition for indicating how to distribute barrage data to the virtual track, such as indicating that barrage data is added to the virtual track when there is no text with a length less than a text length threshold on the virtual track. The barrage clock is used to record the update time and addition time of the barrage data and is a driver for changes in barrage style attributes. The barrage track collection refers to a collection of all virtual tracks.

[0117] The rendering layer includes a rendering component, which is a component for rendering the video data and the barrage data according to the barrage style attribute. The rendering component can be an Open Graphics Library (OpenGL), Matal, or a native draw.

[0118] It should be noted that the barrage framework is hierarchically managed according to an interface layer, a track and distribution layer, and a barrage rendering layer. The layers are low-coupled, the virtual track is designed flexibly, and the effect of moving the barrage data on a plurality of virtual tracks can be simply and efficiently achieved.

[0119] In an embodiment, the inheritance relationship of the track control component and the inheritance relationship of the track are as shown in Figure 9 Since the virtual track Track is abstracted in the present application, such a track control component TrackController can be matched with one or more virtual tracks to achieve a plurality of moving effects of the barrage data. Therefore, the present application provides a virtual track that can support bidirectional (forward and reverse directions of the barrage) moving of the barrage data. From the above Figure 9The inheritance relationship can know that the base class of the track control component is VBDanmuAbstractTrackController, the base class of the track control component is used to describe the general function of the track control component, and the general function includes adding a virtual track, deleting a virtual track, etc. The track control component can include a danmu moving controller VBDanmuBaseMoveTrackController, a danmu forward moving controller VBDanmuHorizontalMoveTrackController, and a danmu bidirectional moving controller VBDanmuHorizontalBidirectionalMoveTrackController. Among them, the danmu moving controller is used to describe the ability of the track control component to move the danmu data. The danmu forward moving controller is used to describe the ability of the track control component to move the danmu data along the danmu forward flow direction. The danmu reverse flow moving controller is used to describe the ability of the track control component to move the danmu data along the danmu reverse flow direction. The danmu bidirectional moving controller extends the ability to move the danmu data along the danmu reverse flow direction through the inheritance relationship between the danmu reverse flow moving controller and the danmu forward moving controller, while retaining the original ability to move the danmu data along the danmu forward flow direction. The base class of the virtual track is VBDanmuAbstractTrack, and the base class of the virtual track is used to describe the general function of the virtual track. The general function includes the ability to carry danmu data. The virtual track includes a virtual track VBDanmuHorizontalMoveTrack that supports forward movement (i.e., supports moving the danmu data along the danmu forward flow direction) and a virtual track VBDanmuHorizontalBidirectionalMoveTrack that supports bidirectional movement (i.e., supports moving the danmu data along the danmu forward flow direction and the danmu reverse flow direction). The virtual track that supports bidirectional movement allows the track control component to distinguish whether the danmu moving direction of the danmu data is the danmu forward flow direction or the danmu reverse flow direction through the field value (backFlow) of the reverse flow field in the danmu display configuration response file. The field value is 0 or NO, indicating the danmu forward flow direction (moving from right to left), and a non-0 value indicates the danmu reverse flow direction. For an introduction to the danmu display configuration response file, please refer to Figure 10 The virtual track that supports bidirectional movement allows the track control component to update the remaining display duration of the danmu data after updating the danmu moving direction.

[0120] In one embodiment, in order to realize the effect of the reverse flow danmu, the reverse flow danmu refers to the danmu data moving along the danmu reverse flow direction mentioned above. The computer device can configure the danmu style attribute of the target video data. Specifically, as shown in Figure 10As shown, the computer device can receive a barrage display configuration request file for target video data, the barrage display configuration request file including a video ID of the target video data, the video ID being of a string (vid:string) type, and the barrage display configuration request file being used to request to configure a barrage style attribute for the target video data. The computer device can detect whether the barrage style attribute of the target video data meets a configuration condition, such as whether a play length of the target video data is greater than a play length threshold. If the play length of the target video data is greater than the play length, it is determined that the barrage style attribute of the target video data meets the configuration condition. If the play length of the target video data is less than or equal to the play length, it is determined that the barrage style attribute of the target video data does not meet the configuration condition. If the barrage style attribute of the target video data does not meet the configuration condition, the computer device can generate a barrage display configuration response file carrying an error code (errorCode), the (errorCode) being of an integer (int) type. If the barrage style attribute of the target video data meets the configuration condition, the computer device can display a display list, the display list including a barrage display configuration item (DMDisplayEgg), the barrage display configuration item being used to configure an attribute ID (id:string) of the barrage style attribute, a start time (startTime:int), an end time (endTime:int), and an attribute list (effectArray:List). The start time and the end time reflect a use time of the configured barrage style attribute, and the attribute ID reflects an identification of the configured barrage style attribute. The attribute list (effectArray:List) can include a barrage display effect (DMDisplayEffect), the barrage attribute effect being used to configure an option of an attribute in the barrage style attribute. For example, the computer device can display an attribute type in response to a trigger operation for the barrage attribute effect, the attribute type including a reverse flow attribute, a font attribute, and the like. The reverse flow attribute is used to configure a barrage arrangement direction, a barrage movement direction, and a barrage movement speed of the barrage data. The font attribute is used to configure a font size, a font size, and a font type of the barrage data.

[0121] Further, the computer device can obtain a configuration result of the user for the barrage style attribute of the barrage data, and generate a barrage display configuration response file according to the configuration result. For example, if the configuration result indicates that the user configures the backflow attribute, the field value (backFlowInfo: DMBackFlowInfo) of the backflow information field in the barrage display configuration response file can be set to a valid value, such as a non-zero value. The default field value of the backflow information field is 0, indicating that the user does not configure the backflow attribute. If the configuration result indicates that the user configures the barrage arrangement direction of the barrage data as the barrage reverse arrangement direction, the field value (textInverted: bool) of the text reverse arrangement field in the barrage display configuration response file can be set to a valid value. If the configuration result indicates that the user configures the barrage movement direction of the barrage data as the barrage backflow direction, the field value (backFlow: bool) of the backflow field in the barrage display configuration response file can be set to a valid value. The default value of the backflow field is NO, indicating that the default barrage movement direction of the barrage data is the barrage forward flow direction. If the configuration result indicates that the user configures the barrage movement speed of the barrage data as the accelerated movement speed, the field value (acclerate: bool) of the acceleration field in the barrage display configuration response file can be set to a valid value. When the field value of the acceleration field is a valid value, the computer device can obtain the acceleration factor configured by the user, and add the acceleration factor to the barrage display configuration response file. The acceleration factor refers to the amount of increase in the barrage movement speed of the barrage data.

[0122] It should be noted that the first barrage style attribute in the present application can be the default barrage style attribute in the target application corresponding to the target video data. The computer device can determine the barrage style attribute indicated in the barrage display configuration response file as the second barrage style attribute. It can be understood that the second barrage style attribute can be configured by the viewer, or the second barrage style attribute can be configured by the operator.

[0123] In one embodiment, the above-mentioned displaying the barrage data in the second barrage set in the second video sub-fragment according to the second barrage style attribute includes: the computer device can display the barrage data in the second barrage set on L virtual tracks in the second video sub-fragment according to the second barrage style attribute. This is beneficial to present one or more lines of barrage data to the user.

[0124] Optionally, the second barrage moving direction included in the second barrage style attribute is different from the first barrage moving direction included in the first barrage style attribute; and the L virtual tracks are the virtual tracks supporting bidirectional movement. For example, the computer device can query the field value of the reverse flow field in the barrage display configuration response file. If the field value of the reverse flow field is a valid value, it is determined that the second barrage moving direction is a barrage reverse flow direction. The barrage bidirectional movement controller in the track control component can be called to display the barrage data in the second barrage set on the L virtual tracks in the second video sub-clip in the barrage reverse flow direction, i.e., the position of the barrage data in the second barrage set is updated in the L virtual tracks in the second video sub-clip in the direction from left to right. If the field value of the reverse flow field is a non-valid value, such as NO, it is determined that the second barrage moving direction is a barrage forward flow direction. The barrage bidirectional movement controller in the track control component can be called to display the barrage data in the second barrage set on the L virtual tracks in the second video sub-clip in the barrage forward flow direction, i.e., the position of the barrage data in the second barrage set is updated in the L virtual tracks in the second video sub-clip in the direction from right to left.

[0125] Optionally, the start time t1 and the end time t2 of using the second barrage style attribute are configured in the barrage display configuration response file, i.e., the use time interval of the second barrage style attribute is [t1, t2]. During the process of playing the second video sub-clip in the target video data, the computer device can detect whether the playing time hits the interval. If the playing time hits the use time interval, the computer device can read the second barrage style attribute from the barrage display configuration response file, and display the barrage data in the second barrage set on the L virtual tracks in the second video sub-clip according to the second barrage style attribute.

[0126] Optionally, the L virtual tracks in the second video sub-fragment, according to the second barrage style attribute, display the barrage data in the second barrage set; L is a positive integer, including: the computer device can be in the L virtual tracks in the second video sub-fragment, according to the second barrage style attribute, display x barrage data in the second barrage set; x is a positive integer less than or equal to Q, Q is the number of barrage in the second barrage set; if the time reaches the barrage update time, call the track control component, update and display x barrage data in the second barrage set according to the second barrage style attribute. The barrage update time here is determined according to the barrage update time interval, and the barrage update time interval can be preset. In other words, the computer device can first display part of the barrage data (i.e. x barrage data) on the L virtual tracks, and periodically update the barrage data on the L virtual tracks according to the time period, which is beneficial to display more barrage data to the user. Optionally, if the time reaches the barrage update time, the track control component is called to update and display x barrage data in the second barrage set according to the second barrage style attribute, including: the computer device removes part of the barrage data on the L virtual tracks, and adds new barrage data to the virtual track. Specifically, if the time reaches the barrage update time, the computer device can call the track control component to update the remaining display time of the x barrage data, and obtain the updated remaining display time of the x barrage data. The updated remaining display time is the maximum time that the x barrage data can be displayed on the video screen, and the updated remaining display time of the x barrage data can be the same or different. The updated remaining display time of the x barrage data is determined according to the start display time of the corresponding barrage data, the text content, etc. Therefore, the computer device can call the barrage facade management class component to remove the barrage data in the x barrage data whose updated remaining display time is less than or equal to the time threshold from the L virtual tracks. The time threshold can be preset, such as 0. The track control component is called to display the valid barrage data in the x barrage data on the L virtual tracks according to the second barrage style attribute, the valid barrage data being the barrage data in the x barrage data whose updated remaining display time is greater than the time threshold. Then, the track control component is called to display the remaining barrage data on the L virtual tracks according to the second barrage style attribute; the remaining barrage data is the barrage data in the second barrage set except the x barrage data. By removing the barrage data whose time is less than or equal to the time threshold, new barrage data is added to the L virtual tracks, so as to present more barrage data to the user.

[0127] Optionally, the calling the track control component to display the valid barrage data in the x barrage data on the L virtual tracks according to the second barrage style attribute includes: when the second barrage style attribute is used to indicate that the barrage data is displayed in a dynamic display mode, the computer device can call the track control component to update the position of the valid barrage data in the x barrage data on the L virtual tracks according to the second barrage moving speed and the second barrage moving direction contained in the second barrage style attribute; that is, the product of the barrage update interval and the second barrage moving speed is the moving distance, and the valid barrage data is moved on the L tracks along the second barrage moving direction, and the moving distance is the product of the barrage update interval and the second barrage moving speed. When the second barrage style attribute is used to indicate that the barrage data is displayed in a static display mode, the computer device can call the track control component to display the valid barrage data on the L virtual tracks according to the current position of the valid barrage data.

[0128] Optionally, if the x barrage data has been displayed in the first video segment according to the first barrage style attribute, when the first barrage set and the second barrage set are the same, or partially the same, or part of the barrage data in the second barrage set is displayed in the first video segment first and then displayed in the first video sub-segment and the second video sub-segment, the computer device can obtain the updated remaining display duration of the x barrage data in the following manner. Specifically, the computer device can call the track control component to determine the display duration of the x barrage data in the first video segment as the remaining display duration of the x barrage data; further, the interval duration from the start time of displaying the x barrage data in the second video segment to the barrage update time is obtained; and the remaining display duration of the x barrage data and the interval duration are subtracted to obtain the remaining display duration of the x barrage data. By updating the remaining display duration of the barrage data, it can be avoided that the position of the barrage data is updated for a long time, such as the barrage data has moved out of the video screen, and the position of the barrage data is still updated, resulting in resource waste.

[0129] It should be noted that the display duration of the barrage data in the second barrage set when the barrage data is displayed in the transition barrage style attribute affects the remaining display duration of the barrage data, that is, the display duration of the barrage data in the second barrage set when the barrage data is displayed in the transition barrage style attribute will not be used to update the remaining display duration of the barrage data. The display duration of the barrage data in the second barrage set when the barrage data is displayed in the transition barrage style attribute is determined by the transition barrage style attribute, such as 0.8s.

[0130] For example, Figure 11As shown, assuming that the limited display duration of the barrage data is 0.5s, assuming that the moving direction of the barrage data in the first barrage style is the normal flow direction of the barrage, the moving direction of the barrage data in the second barrage style is the reverse flow direction of the barrage, the transition barrage style attribute indicates to pause the moving barrage data, and the duration of the pause is 0.8s. The first barrage moving speed in the first barrage style is the same as the second barrage moving speed in the second barrage style, which is taken as an example for description. The display duration of the barrage data: I want to take home in the first video frame 100a in the first video segment is 0.4s, and the computer device can continue to display the barrage data in the first video frame 100a at a fixed position in the first video sub-segment. After 0.8s, the computer device can display the barrage data: home take want good according to the reverse flow direction of the barrage. Since the barrage data: I want to take home is displayed for 0.4s in the first video segment, the moving direction of the barrage data needs to be changed, and it takes 0.4s to move the barrage data out of the video screen, that is, the display duration of the barrage data: I want to take home in the first video segment is determined as the remaining display duration of the barrage data: home take want good.

[0131] It should be noted that when the first barrage set and the second barrage set are not the same, or when the x barrage data is the barrage data with a relatively late display order in the second barrage set, the x barrage data will not be displayed in the first video segment according to the first barrage style attribute. At this time, the computer device can obtain the updated remaining display duration of the barrage data according to the following manner. The computer device can determine the limited display duration of the x barrage data as the remaining display duration of the x barrage data, obtain the interval duration from the start time of displaying the x barrage data in the second video segment to the barrage update time; and obtain the remaining display duration of the x barrage data by subtracting the interval duration from the remaining display duration of the x barrage data. By updating the remaining display duration of the barrage data, it can be avoided that the position of the barrage data is updated for a long time, such as the barrage data has been moved out of the video screen, but the position of the barrage data is still being updated, resulting in resource waste.

[0132] For example, the computer device can calculate the remaining display duration of the barrage data by using the following formula (1):

[0133] newCurrentAliveTime = attributes.totalAliveTime - attributes.currentAliveTime (1)

[0134] In formula (1), attributes.totalAliveTime is referred to as total display duration (i.e., total alive time), also referred to as the above-mentioned limited display duration, attributes.currentAliveTime represents the current alive time of the bullet screen data, i.e., the interval duration, and newCurrentAliveTime is the updated remaining display duration, also referred to as the updated alive time.

[0135] Optionally, the calling of the track control component to display the remaining bullet screen data on the L virtual tracks in the second bullet screen style attribute includes that the computer device can call the bullet screen distribution component to determine a virtual track with an idle degree greater than an idle degree threshold from the L virtual tracks as a target virtual track, the idle degree of the virtual track can be determined according to the number of currently displayed bullet screen data on the virtual track, call the bullet screen distribution component to read the remaining bullet screen data in the second bullet screen set from the bullet screen queue, and add the remaining bullet screen data to the target virtual track. Then, the track control component is called to display the remaining bullet screen data on the target virtual track in the second bullet screen style attribute.

[0136] Optionally, the first moving speed included in the first bullet screen style attribute is different from the second moving speed included in the second bullet screen style attribute; and the displaying of the bullet screen data in the second bullet screen set in the second video sub-clip in the second bullet screen style attribute includes that the computer device can call the track control component to obtain the total display duration of the bullet screen data in the second bullet screen set; the total display duration is determined according to the first moving speed; the computer device can obtain the speed ratio between the second moving speed and the first moving speed; the speed ratio is the amount of moving speed increase. The computer device can divide the total display duration by the speed ratio to obtain the limited display duration of the x bullet screen data, for example, assuming that the speed ratio is 1.5 and the second moving speed is V2, V2 / 1.5 (V2 divided by 1.5) can be taken as the limited display duration of the x bullet screen data. Then, the bullet screen data in the second bullet screen set is displayed in the second video sub-clip according to the limited display duration and the second moving speed. When the moving speed of the bullet screen data changes, the display duration of the bullet screen data can be updated to realize the moving effect of the bullet screen data.

[0137] It should be noted that, assuming that the first moving speed is V1, the second moving speed is V2, then the speed ratio is V2 / V1; that is, V2 divided by V1, when the first moving speed is less than the second moving speed, the speed ratio is a number greater than 1, the speed ratio can be referred to as the acceleration factor mentioned above, that is, the second moving speed becomes larger, and the limit display time calculated based on the second moving speed becomes smaller. In other words, when the moving speed of the barrage data becomes larger, the acceleration moving effect of the barrage data can be realized by shortening the display time of the barrage data. When the first moving speed is greater than the second moving speed, the speed ratio is a number less than 1, and the speed ratio can be referred to as a deceleration factor, that is, the second moving speed becomes smaller, and the limit display time calculated based on the second moving speed becomes larger. In other words, when the moving speed of the barrage data becomes smaller, the deceleration moving effect of the barrage data can be realized by prolonging the display time of the barrage data. Optionally, the first barrage style attribute includes a first barrage arrangement direction, which is the opposite direction of the second barrage arrangement direction included in the second barrage style attribute; the above displaying the barrage data in the second video sub-clip according to the second barrage style attribute includes: the computer device can call a barrage rendering component, update the initial barrage rendering order according to the second barrage arrangement direction to obtain an updated barrage rendering order; the initial barrage rendering order is determined according to the first barrage arrangement direction; the barrage rendering component is a component (functional module) for rendering the barrage data, and renders the barrage data in the second barrage set according to the updated barrage rendering order; and the rendered barrage data is displayed in the second video sub-clip.

[0138] For example, the first barrage style attribute indicates to display the barrage data in the barrage normal arrangement direction, and the second barrage style attribute indicates to display the barrage data in the barrage reverse arrangement direction. The computer device can call a barrage rendering component, update the initial barrage rendering order in the barrage reverse arrangement direction to obtain an updated barrage rendering order; and render the barrage data in the second barrage set according to the updated barrage rendering order (that is, according to the barrage reverse arrangement direction) in sequence; and display the rendered barrage data in the second video sub-clip, that is, display the rendered barrage data in sequence according to the barrage reverse arrangement order.

[0139] In one embodiment, the computer device can display the barrage data in the second video sub-clip according to the first barrage style attribute in response to the closing operation of the barrage style attribute switching control. In other words, the user can manually close the barrage style attribute switching function to meet the personalized needs of the user.

[0140] For example, the first barrage style attribute indicates to display the barrage data in the barrage normal arrangement direction, and the second barrage style attribute indicates to display the barrage data in the barrage reverse arrangement direction.Figure 12 As shown, the barrage display region 111a of the video frame 110a in the second video sub-clip displays the barrage data: the cat is still cute when it is a kitten, the cat's eyes become larger when it grows up, and the time and space flow backward. Figure 12 As shown, the barrage display region 114a of the video frame 113a in the second video sub-clip displays the barrage data: the cat is still cute when it is a kitten, the cat's eyes become larger when it grows up, and the time and space flow backward.

[0141] Further, please refer to Figure 13 FIG. 1 is a flow diagram of a method for displaying a barrage according to an embodiment of the present application. As shown, the method can be executed by any terminal in a terminal cluster, or by a server, or by a terminal and a server in the terminal cluster and the server cooperatively. Figure 13 As shown, the method can be executed by any terminal in a terminal cluster, or by a server, or by a terminal and a server in the terminal cluster and the server cooperatively. Figure 1 As shown, the method can be executed by any terminal in a terminal cluster, or by a server, or by a terminal and a server in the terminal cluster and the server cooperatively. Figure 1 As shown, the method can be executed by any terminal in a terminal cluster, or by a server, or by a terminal and a server in the terminal cluster and the server cooperatively. Figure 1 As shown, the method can be executed by any terminal in a terminal cluster, or by a server, or by a terminal and a server in the terminal cluster and the server cooperatively.

[0142] S201, in a playing process of a first video sub-clip of target video data, display, according to a first barrage style attribute, barrage data in a first barrage set in the first video sub-clip; the first video sub-clip belongs to a first video clip in the target video data.

[0143] In the present application, the computer device can play a first video sub-clip of target video data, display, according to the first barrage style attribute, barrage data in a first barrage set in the first video sub-clip, and the first video sub-clip is a video frame located in the front h in the playing order in the first video clip.

[0144] S202, if the first video sub-clip is played completely, play a second video sub-clip in the first video clip, and switch to display, according to a transition barrage style attribute, barrage data in the first barrage set in the second video sub-clip.

[0145] In the present application, if the first video sub-clip is played to completion, a second video sub-clip in the first video clip can be played, and switching to displaying the barrage data in the first barrage set in the second video sub-clip according to the transition barrage style attribute. The second video sub-clip can include video frames in the first video clip other than the first video sub-clip.

[0146] S203, if the second video sub-clip is played to completion, a second video clip in the target video data is played, and switching to displaying the barrage data in the second barrage set in the second video clip according to the second barrage style attribute; the first barrage style attribute, the transition barrage style attribute, and the second barrage style attribute are different; the plot of the first video clip is different from the plot of the second video clip.

[0147] In the present application, if the second video sub-clip is played to completion, the computer device can play a second video clip in the target video data, and switching to display the barrage data in the second barrage set in the second video clip according to the second barrage style attribute.

[0148] It should be noted that, Figure 13 The difference between Figure 4 lies in that: Figure 4 In the second video clip, the barrage data is displayed according to the transition barrage style attribute, Figure 13 In the first video clip, the barrage data is displayed according to the transition barrage style attribute. Therefore, the specific description of step S201 in the present application can refer to the above-mentioned step S101, the specific description of step S202 can refer to the above-mentioned step S102, and the specific description of step S203 can refer to the above-mentioned step S103, and the repeated parts will not be repeated.

[0149] Further, please refer to Figure 14 , which is a flowchart of a barrage display method provided by an embodiment of the present application. As Figure 14 shown, the method can be executed by any terminal in the terminal cluster in Figure 1 , or can be executed by the server in Figure 1 , or can be executed by the terminal and the server in Figure 1 collaboratively, that is, the device used to execute the barrage display method in the present application can be a computer device, which can be a terminal or a server. In the present embodiment, the computer device is taken as an example to be described. The method can include the following steps:

[0150] S301, in the playing process of a first video clip of target video data, displaying barrage data in a first barrage set in the first video clip according to a first barrage style attribute.

[0151] In an embodiment, step S301 comprises: during playing of a first video sub-segment in the first video segment of the target video data, displaying the barrage data in the first barrage set in the first video sub-segment of the first video segment according to the first barrage style attribute; if the playing of the first video sub-segment in the first video segment is completed, playing a second video sub-segment of the first video segment, and switching to display the barrage data in the first barrage set in the second video sub-segment of the first video segment according to the transition barrage style attribute. That is, by displaying the barrage data in the second video sub-segment of the first video segment in the transition barrage style, the situation of empty screen (i.e. no barrage data), abruptness, etc. in the second video sub-segment of the first video segment can be avoided, and the display of the barrage data in the previous and subsequent video segments is smooth.

[0152] S302, if the playing of the first video segment is completed, playing a second video segment in the target video data, and switching to display the barrage data in the second barrage set in the second video segment according to the second barrage style attribute; the plot of the first video segment is different from the plot of the second video segment.

[0153] In an embodiment, step S302 comprises: if the playing of the first video segment is completed, playing a first video sub-segment of a second video segment in the target video data, and switching to display the barrage data in the second barrage set in the first video sub-segment according to the transition barrage style attribute; if the playing of the first video sub-segment is completed, playing a second video sub-segment in the second video segment, and switching to display the barrage data in the second barrage set in the second video sub-segment of the second video segment according to the second barrage style attribute. That is, by displaying the barrage data in the first video sub-segment of the second video segment in the transition barrage style, the situation of empty screen (i.e. no barrage data), abruptness, etc. in the second video segment can be avoided, and the display of the barrage data in the previous and subsequent video segments is smooth.

[0154] It should be noted that the description of steps S301 and S302 in the present application can refer to the description of the related steps in the foregoing, such as the description of step S301 can refer to the description of step S101, and the description of step S302 can refer to steps S102 and S103, and the repeated parts will not be described herein.

[0155] In the present application, when there is a plot change in the target video data, the screen data is displayed by switching different screen style attributes, which is beneficial to improve the user's perception of the plot change, is beneficial to the user to quickly understand the plot of the target video data, improves the display flexibility and diversity of the screen data; At the same time, it can avoid the user to understand the plot of the video data by multiple video data playback, which can reduce the resource (such as the resource required to load the video data) overhead of the terminal.

[0156] In one embodiment, the screen display method can include as Figure 15The steps 140b-165b shown: 140b, start the barrage, 141b, start the timer, 142b, pre-request logic, 143b, format conversion, 144b, whether to play. 145b, the barrage data is added to the barrage library, 146b, sent to the barrage distribution component, 147b, whether high priority 148b, whether the maximum number is exceeded, 149b, whether the maximum number is exceeded. 150b, added to the tail of the barrage queue; 151b, pre-render texture, 152b, recycle resources, 153b, added to the tail of the barrage queue; 154b, according to the weight order. Among them, steps 140b-154b are called barrage placement phase, specifically, when the computer device detects that the barrage is started, that is, the barrage display function is started, the timer can be started. The timer is used for the playing time of the target video data. Receive pre-request logic, which includes initial barrage data, the format of the barrage data can be based on the format of the http segment request. The computer device can perform format conversion on the initial barrage data to obtain barrage data, and the format of the barrage data is the barrage format of the target application corresponding to the target video data. Detect whether the target video data is playing, if so, the computer device can send the barrage data to the barrage facade management class component, and the barrage facade management class component adds the barrage data to the barrage library and sends the barrage data to the barrage distribution component. The barrage distribution component determines the priority of the barrage data, which can be determined according to the correlation between the barrage data and the target video data, the level of the publisher of the barrage data in the target application, and the number of times the barrage data is sent. Determine whether the barrage data belongs to high priority, high priority refers to priority greater than priority threshold, if the barrage data belongs to high priority, the barrage distribution component can determine whether the number of barrage data in the barrage queue exceeds the maximum number, if the number of barrage data in the barrage queue does not exceed the maximum number, the barrage data can be added to the tail of the barrage queue, that is, the barrage data is added to the tail of the barrage queue, and the barrage data is pre-prepared. If the barrage data does not belong to high priority, the barrage distribution component can determine whether the number of barrage data in the barrage queue exceeds the maximum number, if the number of barrage data in the barrage queue exceeds the maximum number, the barrage data can be recycled, and the barrage data is deleted; if the number of barrage data in the barrage queue does not exceed the maximum number, the barrage data can be added to the tail of the barrage queue, and the barrage data is sorted according to the weight of the barrage data to obtain the display order of the barrage data. The display order moves to the head of the barrage queue, and the display order moves to the tail of the barrage queue. The weight of the barrage data can be determined according to the priority of the barrage data.

[0157] Wherein, 155b, start on screen, 156b, start the BGM timer, 157b, BGM facade management class component; 158b, track control component. 159b, update the position and the remaining display time length, 160b, whether the remaining display time length is less than or equal to the time length threshold. 161b, BGM distribution component, 162b, whether a suitable track (virtual track) is queried, 163b, read BGM data from the BGM queue, 164b, pre-render texture, 165b, the track control component uploads the texture to the rendering component. Steps 155b-165b are called BGM update phase. Specifically, the computer device can start on screen the BGM data in the BGM queue, display the BGM data at the head of the queue in the first video segment in the target video data according to the first BGM style attribute, that is, the BGM data at the head of the queue is called the BGM data in the first BGM set. And start the BGM timer, which is used to record the update time of the BGM data, call the BGM facade management class component to obtain the time in the BGM timer, calculate the time interval between the current time and the last update time of the BGM, and send the time interval to the track control component and the BGM distribution. After receiving the time interval, the track control component updates the remaining display time length of the BGM data displayed in the virtual track, that is, subtracts the time interval from the remaining display time length to obtain the updated remaining display time length of the BGM data. If the updated display remaining time length of the BGM data is greater than the time length threshold, update the position of the BGM data in the virtual track. After receiving the time interval, the BGM distribution component traverses all virtual tracks to determine whether a suitable virtual track is queried, that is, whether there is a virtual track with an idle degree greater than the idle degree threshold. If a virtual track with an idle degree greater than the idle degree threshold is found, the BGM data can be read from the BGM queue and added to the virtual track with an idle degree greater than the idle degree threshold. The track control component can add the view of the added BGM data to the BGM display area. Specifically, if it is a texture BGM data, pre-render texture is performed, the texture is uploaded to the rendering component, the rendering component renders the texture to obtain the view of the BGM data, and the view of the BGM data is added to the BGM display area.

[0158] Optionally, the BGM display method further includes a BGM uninstallation phase. Specifically, when the updated display remaining time length of the BGM data is less than or equal to the time length threshold, the track control component can remove the view of the BGM data from the BGM display area, and remove the information about the BGM data (such as position information, etc.). The BGM facade management class component can call the uninstallation callback function to remove the BGM data and the attributes of the BGM data (such as priority, etc.).

[0159] Optionally, the method further comprises a distribution stage, specifically, the danmaku facade management component usually contains a danmaku distribution component, which usually manages multiple virtual tracks, and stores danmaku data in a danmaku queue. The danmaku facade management component continuously queries the idle virtual tracks under the drive of the danmaku clock, and when a virtual track meets the idle degree requirement and the distribution strategy, the danmaku data at the head of the danmaku queue is added to the virtual track. The specific process is as follows: the danmaku facade management component calls the insertNewAttributes method to insert the danmaku data (danmaku attribute) into the danmaku queue, the danmaku facade management component is driven by the danmaku clock, and calls the dispatchNewAttributesToFreeTracks method to select an idle virtual track that meets the distribution strategy from the virtual tracks, and add the danmaku data at the head of the danmaku queue to the idle virtual track that meets the distribution strategy. The track control component displays the added danmaku data.

[0160] Optionally, the method further comprises a moving stage, in combination with the basic process in Figure 14 The moving principle of the danmaku data is that, under the drive of the danmaku clock, new danmaku data is gradually driven on screen and the on-screen danmaku data changes position according to the predetermined rules. In the industry, the danmaku data usually appears from the right edge of the video screen as the video data is played, and moves uniformly to the left side of the video screen until it disappears from the left side. According to this example, the corresponding virtual track track is an animation representing uniform movement from the right edge of the video screen to the left edge of the video screen until it is off-screen. The duration of this process is the limited display time TotalTime specified in the danmaku style attribute of the danmaku data. With the periodic callback of the danmaku clock (usually, the callback interval of the danmaku clock depends on the screen refresh rate. If the refresh rate is 60 frames per second, the callback interval is 0.0167), the track control component receives a callback of a small time interval, and then performs the following steps: (1) traverses all the danmaku data on the current virtual track, adds the time interval to the display time of each danmaku data to obtain the updated display time; (2) if the updated display time of this danmaku data exceeds the limited display time after adding the time interval, this danmaku data is put into an uninstall function and uninstalled in the uninstall function. (3) If the updated display time of this danmaku data does not reach the limited display time after adding the time interval, the track control component calls the virtual track to update the position of this danmaku data. Of course, the track control component can uninstall the danmaku data and update the position of the danmaku data based on the remaining display time of the danmaku data mentioned above.

[0161] Optionally, the method further comprises a reverse flow barrage configuration stage. In order to support the effect of the reverse flow barrage, the barrage display configuration response file specifies a use time interval [t1, t2] of the reverse flow barrage. During the playing of the target video data, the track control component receives an interval duration, detects whether the use time interval is hit, and if the use time interval is hit, detects whether the reverse flow information field in the barrage display configuration response file is a valid value. If the value is valid, the reverse flow attribute of the barrage display configuration response file is obtained. When the playing time of the target video data exceeds the use time interval, the barrage style attribute switching is closed, and the default barrage effect of the target application is restored, that is, the default barrage style attribute is restored.

[0162] Optionally, the method further comprises a reverse flow barrage stage. The description of the reverse flow barrage can be referred to the above, and will not be repeated here.

[0163] Optionally, the method further comprises a reverse flow barrage stage. After receiving the barrage reverse flow configuration, if it is identified that the field value of the textInverted field in the barrage display configuration response file is true (a valid value), the barrage rendering component can update the rendering order of the barrage data, and render the barrage data according to the updated rendering order.

[0164] Optionally, the method further comprises a barrage acceleration stage. After receiving the barrage reverse flow configuration, if it is identified that the field value of the acclerate field in the barrage display configuration response file is true, the moving speed of the barrage data is accelerated, which means that the display time limit of the barrage data is reduced. The acceleration of the barrage data can be realized by reducing the display time limit of the barrage data. The display time limit of the barrage data can be updated according to the acceleration factor in the barrage display configuration response file, so as to realize the acceleration effect of the barrage.

[0165] Please refer to Figure 16 , which is a structural schematic diagram of a barrage display device provided by an embodiment of the present application. As shown in Figure 16 , the barrage display device can include:

[0166] The first display module 161 is configured to display, in a first video segment of target video data, barrage data in a first barrage set according to a first barrage style attribute during playing of the first video segment.

[0167] The second display module 162 is configured to, if the first video segment is played completely, play a first video sub-segment of a second video segment in the target video data, and switch to display the barrage data in the second barrage set in the first video sub-segment according to a transition barrage style attribute.

[0168] The third display module 163 is configured to, if the first video sub-segment is played completely, play a second video sub-segment in the second video segment, and switch to display the barrage data in the second barrage set in the second video sub-segment according to a second barrage style attribute. The first barrage style attribute, the transition barrage style attribute, and the second barrage style attribute are different.

[0169] Optionally, the transition barrage style attribute is used to instruct to display the barrage data in a static display manner, and the transition barrage style attribute includes a display duration.

[0170] The second display module 162 is configured to display the barrage data in the second barrage set according to the display duration at a fixed position in the first video sub-segment.

[0171] Optionally, the fixed position is determined according to a position of the displayed barrage data in a video frame located at the last in the playing order in the first video segment, or the fixed position is any position in a barrage display area in the first video sub-segment.

[0172] Optionally, a second barrage moving direction included in the second barrage style attribute is different from a first barrage moving direction included in the first barrage style attribute, and the third display module 163 is configured to display the barrage data in the second barrage set in the second video sub-segment according to the second barrage moving direction.

[0173] The third display module 163 is configured to display the barrage data in the second barrage set in the second video sub-segment according to the second barrage moving direction and the second moving speed.

[0174] Optionally, a second barrage arrangement direction included in the second barrage style attribute is different from a first barrage arrangement direction included in the first barrage style attribute, and the third display module 163 is configured to arrange the text content of the barrage data in the second barrage set according to the second barrage arrangement direction, and display the arranged barrage data in the second barrage set in the second video sub-segment.

[0175] Optionally, the second moving speed included in the second barrage style attribute is different from the first moving speed included in the first barrage style attribute; the third display module 163 is configured to display the barrage data in the second barrage set in the second video sub-clip according to the second moving speed.

[0176] Optionally, if the content described by the second video clip is the same as the content described by the first video clip, the first barrage set and the second barrage set are the same, the first barrage set is associated with the first video clip, or the first barrage set is associated with the second video clip; if the content described by the second video clip is not the same as the content described by the first video clip, the first barrage set is associated with the first video clip, and the second barrage set is associated with the second video clip.

[0177] The first display module 161 is further configured to, in response to a closing operation on the barrage style attribute switching control, display the barrage data in the second barrage set in the second video clip according to the first barrage style attribute.

[0178] 16Optionally, the third display module 163 is configured to, if the second barrage style attribute indicates that the barrage data is moved in a barrage backflow direction, display the barrage data in the second barrage set on the L virtual tracks in the second video sub-clip according to the barrage backflow direction; if the second barrage style attribute indicates that the barrage data is moved in a barrage forward flow direction, display the barrage data in the second barrage set on the L virtual tracks in the second video sub-clip according to the barrage forward flow direction. L is a positive integer;

[0179] Optionally, the third display module 163 is configured to display x barrage data in the second barrage set on the L virtual tracks in the second video sub-clip according to the second barrage style attribute; x is a positive integer less than or equal to Q, Q is the number of barrages in the second barrage set; L is a positive integer;

[0180] If the time reaches the barrage update moment, the track control component is called to update the display of the x barrage data in the second barrage set according to the second barrage style attribute.

[0181] Optionally, the third display module 163 is configured to: if time reaches a barrage update moment, call the track control component to update the remaining display time length of the x barrage data, to obtain updated remaining display time length of the x barrage data; call a barrage facade management class component to remove, from the L virtual tracks, barrage data in the x barrage data whose updated remaining display time length is less than or equal to a time threshold; call the track control component to display, on the L virtual tracks, valid barrage data in the x barrage data according to the second barrage style attribute; the valid barrage data is barrage data in the x barrage data whose updated remaining display time length is greater than the time threshold; call the track control component to display, on the L virtual tracks, remaining barrage data according to the second barrage style attribute; the remaining barrage data is barrage data in the second barrage set other than the x barrage data.

[0182] Optionally, a barrage moving direction included in the first barrage style attribute is opposite to a barrage moving direction included in the second barrage style attribute; optionally, the third display module 163 is configured to: if the x barrage data has been displayed in the first video segment according to the first barrage style attribute, call the track control component to determine, as the remaining display time length of the x barrage data, a display time length of the x barrage data in the first video segment; obtain an interval time length from a start moment of displaying the x barrage data in the second video segment to the barrage update moment; and obtain the remaining display time length of the x barrage data by subtracting the interval time length from the remaining display time length of the x barrage data.

[0183] Optionally, the third display module 163 is configured to: call a barrage distribution component to determine, from the L virtual tracks, a virtual track whose idle degree is greater than an idle degree threshold as a target virtual track; call the barrage distribution component to add, to the target virtual track, remaining barrage data in a barrage queue that belongs to the second barrage set and has not been displayed; and call the track control component to display, on the target virtual track, the remaining barrage data according to the second barrage style attribute.

[0184] Optionally, a first moving speed included in the first barrage style attribute is different from a second moving speed included in the second barrage style attribute.

[0185] Optionally, the third display module 163 is configured to invoke a track control component to obtain a total display time length of the barrage data in the second barrage set, the total display time length being determined according to the first moving speed, obtain a speed ratio between the second moving speed and the first moving speed, divide the total display time length by the speed ratio to obtain a limited display time length of the x pieces of barrage data, and display the barrage data in the second barrage set in the second video sub-clip according to the limited display time length and the second moving speed.

[0186] Optionally, the first barrage arrangement direction included in the first barrage style attribute is opposite to the second barrage arrangement direction included in the second barrage style attribute.

[0187] Optionally, the third display module 163 is configured to invoke a barrage rendering component to update an initial barrage rendering order according to the second barrage arrangement direction to obtain an updated barrage rendering order, the initial barrage rendering order being determined according to the first barrage arrangement direction, render the barrage data in the second barrage set according to the updated barrage rendering order, and display the rendered barrage data in the second video sub-clip.

[0188] Optionally, the division module 164 is configured to display a configuration interface in response to a configuration operation on a plot change time, obtain a plot change time input in the configuration interface, and divide the target video data according to the plot change time to obtain the first video clip and the second video clip.

[0189] Optionally, the division module 164 is configured to obtain a target barrage set in the target video data, the first barrage set and the second barrage set being subsets of the target barrage set.

[0190] Optionally, the division module 164 is configured to obtain a target barrage set in the target video data, the first barrage set and the second barrage set being subsets of the target barrage set.

[0191] Optionally, the division module 164 is configured to obtain a target barrage set in the target video data, the first barrage set and the second barrage set being subsets of the target barrage set.

[0192] Optionally, the dividing module 164 is configured to determine a text similarity between a text feature of the barrage data in the target barrage set and a plot change text feature; count a number of barrages in the target barrage set whose text similarity is greater than a similarity threshold value within S publishing time points; the S publishing time points are publishing time points of the barrage data in the target barrage set, and S is a positive integer; filter time points corresponding to a number of barrages greater than a number threshold value from the S time points as plot change time points; and divide the target video data according to the plot change time points to obtain the first video segment and the second video segment.

[0193] Optionally, the dividing module 164 is configured to obtain script data corresponding to the target video data; extract object description information and an occurrence time of the object description information from the script data corresponding to the target video data; determine a script scene information set associated with the target video data according to the occurrence time of the object description information and the object description information.

[0194] The target video data is divided according to the script scene information set to obtain the first video segment and the second video segment.

[0195] Optionally, the dividing module 164 is configured to: perform frame-by-frame traversal between script scene information i in the script scene information set and a video frame that has not been traversed in the target video data; i is less than or equal to F, and F is a number of script scene information in the script scene information set; if a matching degree between a target video frame and the script scene information i is less than a matching degree threshold value, the target video data is divided according to a playing time of the target video frame to obtain the first video segment and the second video segment.

[0196] It should be noted that the barrage display device in the present application can be used to execute the foregoing description of the barrage display method in the foregoing embodiments. When the barrage display device executes the foregoing description of the barrage display method, the beneficial effects brought by the barrage display device can refer to the beneficial effects described in the foregoing embodiments of the barrage display method, which will not be described herein again.

[0197] In the present application, during the playing process of the target video data, the barrage data in the video segments of different plots is displayed in different barrage style attributes (i.e., the first barrage style attribute and the second barrage style attribute), so as to prompt the user that there is a plot change between the front and rear video segments (i.e., the first video segment and the second video segment), which is beneficial to improve the user's perception of the plot change, help the user quickly understand the plot of the target video data, improve the display flexibility and diversity of the barrage data; at the same time, it can avoid the user understanding the plot of the video data by multiple video data playback, and can reduce the resource (such as the resource required to load the video data) overhead of the terminal. In addition, by displaying the barrage data between the front and rear video segments in the transition barrage attribute, it can avoid the situation of empty screen (i.e., no barrage data) and abruptness in the video segment, so that the barrage data displayed in the front and rear video segments is smooth.

[0198] Please refer to Figure 17 , which is a structural schematic diagram of a barrage display device provided by the present application. As Figure 17 indicated, the barrage display device can include:

[0199] The first display module 171 is configured to display the barrage data in the first barrage set in the first video segment according to the first barrage style attribute during the playing process of the first video segment of the target video data.

[0200] The second display module 172 is configured to, if the first video segment is played, play the first video sub-segment of the second video segment in the target video data, and switch to display the barrage data in the second barrage set in the first video sub-segment according to the transition barrage style attribute; the plot of the first video segment is different from the plot of the second video segment.

[0201] The third display module 173 is configured to, if the first video sub-segment is played, play the second video sub-segment in the second video segment, and switch to display the barrage data in the second barrage set in the second video sub-segment according to the second barrage style attribute; the first barrage style attribute, the transition barrage style attribute, and the second barrage style attribute are different.

[0202] It should be noted that the barrage display device in the present application can be used to execute the above description of the barrage display method in the corresponding embodiment described above. When the barrage display device executes the above description of the barrage display method, the beneficial effects brought by the barrage display device can refer to the beneficial effects described in the corresponding embodiment of the barrage display method, which will not be repeated here.

[0203] In the present application, during the playing process of the target video data, the scroll data in the video segments of different plots is displayed in different scroll style attributes (i.e., the first scroll style attribute and the second scroll style attribute) to prompt the user that there is a plot change between the front and rear video segments (i.e., the first video segment and the second video segment), which is beneficial to improve the user's perception of the plot change, help the user quickly understand the plot of the target video data, improve the display flexibility and diversity of the scroll data; at the same time, it can avoid the user to understand the plot of the video data by multiple video data playback, which can reduce the resource (such as the resource required to load the video data) overhead of the terminal. In addition, by displaying the scroll data between the front and rear video segments through the transition scroll attribute, it can avoid the situation of empty screen (i.e., no scroll data) and abruptness in the video segment, and make the scroll data displayed in the front and rear video segments smooth.

[0204] Please refer to Figure 18 , which is a structural schematic diagram of a scroll display device provided by the present application. As Figure 18 indicated, the scroll display device can include:

[0205] The first display module 181 is configured to display the scroll data in the first scroll set in the first video segment according to the first scroll style attribute during the playing process of the first video segment of the target video data.

[0206] The second display module 182 is configured to, if the playing of the first video segment is completed, play the second video segment in the target video data, and switch to display the scroll data in the second scroll set in the second video segment according to the second scroll style attribute. The plot of the first video segment is different from the plot of the second video segment, and the first scroll style attribute, the transition scroll style attribute, and the second scroll style attribute are different.

[0207] It should be noted that the scroll display device in the present application can be used to execute the description of the above-mentioned scroll display method in the corresponding embodiment of the foregoing description. When the scroll display device executes the foregoing description of the scroll display method, the beneficial effects brought by the scroll display device can refer to the beneficial effects described in the corresponding embodiment of the foregoing scroll display method, which will not be repeated here.

[0208] In the present application, during the playing process of the target video data, the barrage data in the video clips of different plots is displayed by using different barrage style attributes (i.e., the first barrage style attribute and the second barrage style attribute), so as to prompt the user that there is a plot change between the front and rear video clips (i.e., the first video clip and the second video clip), which is beneficial to improving the user's perception of the plot change, helping the user quickly understand the plot of the target video data, improving the display flexibility and diversity of the barrage data; at the same time, it can avoid the user understanding the plot of the video data by multiple video data playback, and can reduce the resource (such as the resource required for loading the video data) consumption of the terminal. In addition, by displaying the barrage data between the front and rear video clips by using the transition barrage attribute, it can avoid the situation of empty screen (i.e., no barrage data) and abruptness in the video clip, so as to make the barrage data displayed in the front and rear video clips smooth.

[0209] Please refer to Figure 19 is a structural schematic diagram of a computer device provided by an embodiment of the present application. As shown in Figure 19 , the above computer device 1000 can refer to a terminal or a server, comprising a processor 1001, a network interface 1004 and a memory 1005, in addition, the above computer device 1000 can further comprise a user interface 1003, and at least one communication bus 1002. Wherein, the communication bus 1002 is used to realize the connection communication between these components. Wherein, in some embodiments, the user interface 1003 can comprise a display screen (Display), a keyboard (Keyboard), and the optional user interface 1003 can further comprise a standard wired interface, a wireless interface. The network interface 1004 can optionally comprise a standard wired interface, a wireless interface (such as a WI-FI interface). The memory 1005 can be a high-speed RAM memory, or a non-volatile memory (non-volatile Memory), for example, at least one disk storage. The memory 1005 can optionally be at least one storage device away from the above processor 1001. As shown in Figure 19 , the memory 1005 as a computer readable storage medium can comprise an operating system, a network communication module, a user interface module and a computer program.

[0210] In Figure 19In the computer device 1000 shown, the network interface 1004 can provide network communication functions; the user interface 1003 is mainly used to provide an input interface; and the processor 1001 can be used to call a computer program stored in the memory 1005 to execute the description of the above-mentioned barrage display method in the foregoing embodiments, and also can execute the description of the above-mentioned barrage display device in the foregoing embodiments, which will not be described here. In addition, when the processor 1001 executes the description of the foregoing barrage display method, or when the processor 1001 executes the description of the foregoing barrage display device, the beneficial effects brought by the foregoing barrage display method can refer to the beneficial effects described in the foregoing embodiments corresponding to the barrage display method, which will not be described here.

[0211] In addition, it should be pointed out here that the embodiments of the present application also provide a computer readable storage medium, and the above-mentioned computer readable storage medium stores the computer program executed by the foregoing barrage display device mentioned above, and the above-mentioned computer program includes program instructions, when the above-mentioned processor executes the above-mentioned program instructions, the above-mentioned barrage display method described in the foregoing embodiments can be executed, therefore, this will not be described here. In addition, the beneficial effects of using the same method will not be described here. For the technical details of the computer readable storage medium embodiments involved in the present application, please refer to the description of the method embodiments of the present application.

[0212] As an example, the above-mentioned program instructions can be deployed on one computer device for execution, or deployed on at least two computer devices in one place for execution, or deployed on at least two computer devices distributed in at least two places and interconnected through a communication network for execution, and the at least two computer devices distributed in at least two places and interconnected through a communication network can constitute a blockchain network.

[0213] The above-mentioned computer readable storage medium can be the barrage display device provided by any of the foregoing embodiments or the storage unit of the above-mentioned computer device, for example, the hard disk or the storage of the computer device. The computer readable storage medium can also be an external storage device of the computer device, for example, a plug-in hard disk, an SMC, an SD card, a flash card, etc. equipped on the computer device. Further, the computer readable storage medium can include both the internal storage unit and the external storage device of the computer device. The computer readable storage medium is used to store the computer program and other programs and data required by the computer device. The computer readable storage medium can also be used to temporarily store data that has been output or will be output.

[0214] The terms "first", "second", etc. in the specification and claims of the present application and the drawings are used to distinguish different media, rather than to describe a specific order. In addition, the term "comprising" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, device, product or equipment including a series of steps or units is not limited to the listed steps or modules, but can optionally include steps or modules not listed, or can optionally include other steps or units inherent to the process, method, device, product or equipment.

[0215] The relevant data collection and processing in the present application should strictly comply with the requirements of relevant national laws and regulations, obtain the informed consent or separate consent of the personal information subject, and within the scope of authorization of laws and regulations and the personal information subject, carry out subsequent data use and processing behavior.

[0216] The embodiments of the present application also provide a computer program product, including a computer program, which, when executed by a processor, realizes the description of the above-mentioned barrage display method and decoding method in the corresponding embodiments of the foregoing. Therefore, this will not be described again. In addition, the beneficial effects of using the same method are not described again. For technical details not disclosed in the embodiments of the computer program product involved in the present application, please refer to the description of the method embodiments of the present application.

[0217] Those of ordinary skill in the art can realize that the units and algorithm steps of each example described in combination with the embodiments disclosed herein can be realized in electronic hardware, computer software or a combination of both. In order to clearly illustrate the interchangeability of hardware and software, the components and steps of each example have been described in the above description in general terms. Whether the functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. A person skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present application.

[0218] The method and related apparatus provided by the embodiments of the present application are described with reference to the method flowchart and / or structural schematic diagram provided by the embodiments of the present application. Each flow and / or block in the method flowchart and / or structural schematic diagram, and the combination of flows and / or blocks in the flowchart and / or block diagram can be realized by computer program instructions. These computer program instructions can be provided to a general-purpose computer, a special-purpose computer, an embedded processor or other programmable network-connected devices to produce a machine, so that the instructions executed by the computer or other programmable network-connected devices produce a machine that implements the flowchart and / or block diagram in the flowchart and / or block diagram. Figure 1 Each flow or multiple flows and / or structural schematic Figure 1apparatus that performs the specific functions. These computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable network connection device to function in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture including instructions which implement the flow Figure 1 flow or flows and / or a schematic diagram of a structure Figure 1 flow or flows and / or a schematic diagram of a structure Figure 1 flow or flows and / or a schematic diagram of a structure

[0219] The above disclosure is merely preferred embodiments of the application and is not to be taken in a limiting sense. Variations and modifications can be made to the application without departing from the spirit thereof as claimed in the following claims.

Claims

1. A method for displaying bullet comments, characterized in that, The method comprises the following steps: During playing of a first video segment of target video data, displaying, in the first video segment, the barrage data in a first barrage set according to a first barrage style attribute; If the first video segment is played completely, playing a first video sub-segment of a second video segment in the target video data, and switching to display the barrage data in a second barrage set in the first video sub-segment according to a transition barrage style attribute; the plot of the first video segment is different from the plot of the second video segment; If the first video sub-segment is played completely, playing a second video sub-segment in the second video segment, and switching to display the barrage data in the second barrage set in the second video sub-segment according to a second barrage style attribute; the first barrage style attribute, the transition barrage style attribute and the second barrage style attribute are different; The second barrage moving direction included in the second barrage style attribute is different from the first barrage moving direction included in the first barrage style attribute; or The second barrage arrangement direction included in the second barrage style attribute is different from the first barrage arrangement direction included in the first barrage style attribute; or The second moving speed included in the second barrage style attribute is different from the first moving speed included in the first barrage style attribute. The transition barrage style attribute is used to indicate that the barrage data is displayed in a static display mode, and the transition barrage style attribute includes a display duration; 2. The method of claim 1, wherein, The switching to display the barrage data in the second barrage set in the first video sub-segment according to the transition barrage style attribute comprises: Displaying the barrage data in the second barrage set according to the display duration at a fixed position in the first video sub-segment. The fixed position is determined according to the position of the displayed barrage data in the video frame located at the last in the playing order in the first video segment; or 3. The method of claim 2, wherein, The fixed position is any position in a barrage display area in the first video sub-segment.

4. The method of claim 1, wherein The displaying of the barrage data in the second barrage set in the second video sub-segment according to the second barrage style attribute comprises: Moving the barrage data in the second barrage set in the second video sub-segment according to the second barrage moving direction. The second barrage style attribute further includes a second moving speed; 5. The method of claim 4, wherein, The moving of the barrage data in the second barrage set in the second video sub-segment according to the second barrage moving direction comprises: Moving the barrage data in the second barrage set in the second video sub-segment according to the second barrage moving direction and the second moving speed.

6. The method of claim 1, wherein The displaying of the barrage data in the second barrage set in the second video sub-segment according to the second barrage style attribute comprises: Arranging the text content of the barrage data in the second barrage set according to the second barrage arrangement direction. ​ In the second video sub-fragment, display the ranked barrage data in the second barrage set.

7. The method of claim 1, wherein, The displaying the barrage data in the second barrage set in the second video sub-fragment according to the second barrage style attribute comprises: The displaying the barrage data in the second barrage set in the second video sub-fragment according to the second moving speed comprises:

8. The method of claim 1, wherein, If the content described by the second video segment is the same as the content described by the first video segment, the first barrage set is the same as the second barrage set, the first barrage set is associated with the first video segment, or the first barrage set is associated with the second video segment. If the content described by the second video segment is not the same as the content described by the first video segment, the first barrage set is associated with the first video segment, and the second barrage set is associated with the second video segment.

9. The method of claim 1, wherein, The method further comprises: In response to a closing operation on the barrage style attribute switching control, display the barrage data in the second barrage set in the second video segment according to the first barrage style attribute.

10. The method of claim 1, wherein, The displaying the barrage data in the second barrage set in the second video sub-fragment according to the second barrage style attribute comprises: If the second barrage moving direction is a barrage reverse flow direction, display the barrage data in the second barrage set in the L virtual tracks in the second video sub-fragment according to the barrage reverse flow direction; L is a positive integer. If the second barrage moving direction is a barrage forward flow direction, display the barrage data in the second barrage set in the L virtual tracks in the second video sub-fragment according to the barrage forward flow direction.

11. The method of claim 1, wherein, The displaying the barrage data in the second barrage set in the second video sub-fragment according to the second barrage style attribute comprises: Display x barrage data in the second barrage set in the L virtual tracks in the second video sub-fragment according to the second barrage style attribute; x is a positive integer less than or equal to Q, Q is the number of barrages in the second barrage set, and L is a positive integer. If the time reaches a barrage update time, call a track control component to update the display of the x barrage data in the second barrage set according to the second barrage style attribute.

12. The method of claim 11, wherein, The updating the display of the x barrage data in the second barrage set according to the second barrage style attribute if the time reaches a barrage update time comprises: If the time reaches a barrage update time, call the track control component to update the remaining display duration of the x barrage data to obtain updated remaining display durations of the x barrage data. Call a barrage facade management class component to remove, from the L virtual tracks, barrage data in the x barrage data that has an updated remaining display duration less than or equal to a duration threshold; The track control component is called to display valid barrage data in the x barrage data on the L virtual tracks according to the second barrage style attribute; the valid barrage data is barrage data in the x barrage data whose remaining display duration is greater than the duration threshold; The track control component is called to display remaining barrage data on the L virtual tracks according to the second barrage style attribute; the remaining barrage data is barrage data in the second barrage set other than the x barrage data.

13. The method of claim 12, wherein, The first barrage moving direction included in the first barrage style attribute is opposite to the second barrage moving direction included in the second barrage style attribute; The track control component is called to update the remaining display duration of the x barrage data to obtain the updated remaining display duration of the x barrage data, including: If the x barrage data has been displayed in the first video segment according to the first barrage style attribute, the track control component is called to determine the display duration of the x barrage data in the first video segment as the remaining display duration of the x barrage data; An interval duration from a starting moment of displaying the x barrage data in the second video segment to the barrage update moment is obtained; The remaining display duration of the x barrage data is subtracted from the interval duration to obtain the remaining display duration of the x barrage data.

14. The method of claim 13, wherein, The track control component is called to display remaining barrage data on the L virtual tracks according to the second barrage style attribute, including: A barrage distribution component is called to determine a virtual track with an idle degree greater than an idle degree threshold from the L virtual tracks as a target virtual track; The barrage distribution component is called to add un-displayed remaining barrage data belonging to the second barrage set in a barrage queue to the target virtual track; The track control component is called to display the remaining barrage data on the target virtual track according to the second barrage style attribute.

15. The method of claim 1, wherein The display of the barrage data in the second barrage set in the second video sub-segment according to the second barrage style attribute includes: A track control component is called to obtain a total display duration of the barrage data in the second barrage set; the total display duration is determined according to the first moving speed; A speed ratio between the second moving speed and the first moving speed is obtained; The total display duration is divided by the speed ratio to obtain a limited display duration of x barrage data in the second barrage set; x is a positive integer less than or equal to Q, Q is the number of barrages in the second barrage set, and L is a positive integer; The barrage data in the second barrage set is displayed in the second video sub-segment according to the limited display duration and the second moving speed.

16. The method of claim 1, wherein, The first barrage arrangement direction included in the first barrage style attribute is the opposite direction of the second barrage arrangement direction included in the second barrage style attribute; The method further comprises: In response to a configuration operation on the plot change moment, a configuration interface is displayed; The plot change moment input in the configuration interface is obtained, and the target video data is divided according to the plot change moment, to obtain the first video segment and the second video segment. The method further comprises:

17. The method of claim 1, wherein, A target barrage set in the target video data is obtained; the first barrage set and the second barrage set are subsets of the target barrage set; Text feature recognition is performed on the barrage data in the target barrage set, to obtain the text features of the barrage data in the target barrage set; The target video data is divided according to the text features of the barrage data in the target barrage set, to obtain the first video segment and the second video segment.

18. The method of claim 1, wherein, The method further comprises: The text similarity between the text features of the barrage data in the target barrage set and the plot change text features is determined; The number of barrages in the target barrage set whose text similarity is greater than a similarity threshold is counted within S publishing moments; the S publishing moments are the publishing moments of the barrage data in the target barrage set, and S is a positive integer; Moments corresponding to a number of barrages greater than a number threshold are filtered out from the S publishing moments as plot change moments; 19. The method of claim 18, wherein, The target video data is divided according to the plot change moments, to obtain the first video segment and the second video segment. The method further comprises: The script data corresponding to the target video data is obtained; Object description information and the appearance time of the object description information are extracted from the script data corresponding to the target video data; The set of script scene information associated with the target video data is determined according to the object description information and the appearance time of the object description information; 20. The method of claim 1, wherein, The target video data is divided according to the set of script scene information, to obtain the first video segment and the second video segment. The method further comprises: The script scene information i in the set of script scene information is iterated frame by frame with the video frames in the target video data that have not been iterated; i is less than or equal to F, and F is the number of script scene information in the set of script scene information; ​ ​ 21. The method of claim 20, wherein, ​ ​ If the matching degree between the target video frame and the script scene information i is less than the matching degree threshold, the target video data is divided according to the playing time of the target video frame, and the first video segment and the second video segment are obtained.

22. A method for displaying a barrage, the method comprising: Comprise: In the playing process of the first video sub-segment of the target video data, the first barrage data in the first barrage set is displayed in the first video sub-segment according to the first barrage style attribute; the first video sub-segment belongs to the first video segment in the target video data; If the first video sub-segment is played, the second video sub-segment in the first video segment is played, and the display of the first barrage data in the first barrage set in the second video sub-segment is switched to the transition barrage style attribute; If the second video sub-segment is played, the second video segment in the target video data is played, and the display of the second barrage data in the second barrage set in the second video segment is switched to the second barrage style attribute; the first barrage style attribute, the transition barrage style attribute and the second barrage style attribute are different; the plot of the first video segment is different from the plot of the second video segment; Wherein, the second barrage moving direction included in the second barrage style attribute is different from the first barrage moving direction included in the first barrage style attribute; or, The second barrage arrangement direction included in the second barrage style attribute is different from the first barrage arrangement direction included in the first barrage style attribute. Or, The second moving speed included in the second barrage style attribute is different from the first moving speed included in the first barrage style attribute.

23. A method for displaying a barrage, the method comprising: Comprise: In the playing process of the first video segment of the target video data, the first barrage data in the first barrage set is displayed in the first video segment according to the first barrage style attribute; If the first video segment is played, the second video segment in the target video data is played, and the display of the second barrage data in the second barrage set in the second video segment is switched to the second barrage style attribute; the plot of the first video segment is different from the plot of the second video segment; Wherein, the second barrage moving direction included in the second barrage style attribute is different from the first barrage moving direction included in the first barrage style attribute; or, The second barrage arrangement direction included in the second barrage style attribute is different from the first barrage arrangement direction included in the first barrage style attribute. 24.A bullet screen display device, characterized by, Comprise: The first display module is used for displaying the first barrage data in the first barrage set in the first video segment according to the first barrage style attribute in the playing process of the first video segment of the target video data; The second display module is configured to, if the first video segment is played completely, play a first video sub-segment of a second video segment in the target video data, and switch to display the barrage data in the second barrage set in the first video sub-segment according to a transition barrage style attribute; the plot of the first video segment is different from the plot of the second video segment; the third display module is configured to, if the first video sub-segment is played completely, play a second video sub-segment in the second video segment, and switch to display the barrage data in the second barrage set in the second video sub-segment according to a second barrage style attribute; the first barrage style attribute, the transition barrage style attribute, and the second barrage style attribute are different from each other. The second barrage moving direction included in the second barrage style attribute is different from the first barrage moving direction included in the first barrage style attribute; or The second barrage arrangement direction included in the second barrage style attribute is different from the first barrage arrangement direction included in the first barrage style attribute; or The second moving speed included in the second barrage style attribute is different from the first moving speed included in the first barrage style attribute. The first display module is configured to, in a playing process of a first video sub-segment of target video data, display the barrage data in a first barrage set in the first video sub-segment according to a first barrage style attribute; the first video sub-segment belongs to a first video segment in the target video data. 25.A bullet screen display device, characterized by, The second display module is configured to, if the first video sub-segment is played completely, play a second video sub-segment in the first video segment, and switch to display the barrage data in the first barrage set in the second video sub-segment according to a transition barrage style attribute. The third display module is configured to, if the second video sub-segment is played completely, play a second video segment in the target video data, and switch to display the barrage data in a second barrage set in the second video segment according to a second barrage style attribute; the first barrage style attribute, the transition barrage style attribute, and the second barrage style attribute are different from each other; the plot of the first video segment is different from the plot of the second video segment. The second barrage moving direction included in the second barrage style attribute is different from the first barrage moving direction included in the first barrage style attribute; or The second barrage arrangement direction included in the second barrage style attribute is different from the first barrage arrangement direction included in the first barrage style attribute; or The second moving speed included in the second barrage style attribute is different from the first moving speed included in the first barrage style attribute. The processor executes the computer program to implement the method in any one of claims 1 to 23. The computer storage medium stores the computer program, and the computer program is executed by the processor to implement the method in any one of claims 1 to 23. ​ 26.A computer device, comprising a memory and a processor, wherein the memory stores a computer program. ​ 27. A computer storage medium, comprising, ​ 28. A computer program product comprising a computer program, characterised in that, The computer program, which when executed by the processor, implements the method of any one of claims 1 to 23.

Citation Information

Patent Citations

  • Bullet screen adjusting method and device, electronic device and storage medium

    CN110958493A

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

    CN111277910A

  • Bullet screen display method and device, equipment, medium and program product

    CN116017016A