CN-122027839-A - Bullet screen display method, device, system, terminal and storage medium
Abstract
The embodiment of the invention provides a barrage display method, device, system, terminal and storage medium, relating to the technical field of Internet, wherein the method comprises the steps of acquiring configuration resources of a target barrage special effect from a server when the configuration resource acquisition conditions are met; the configuration resources comprise a bullet screen template for using the target bullet screen special effect and a configuration rule for adding data in the bullet screen template, the configuration resource acquisition condition characterizes that the requirement for using the target bullet screen special effect exists, if the condition meeting the special effect triggering condition is detected in the video playing process, the bullet screen to be processed for determining the target bullet screen special effect to be used, text content of the bullet screen to be processed is added to the bullet screen template according to the configuration rule to obtain the bullet screen to be processed for using the target bullet screen special effect as a first bullet screen, and the first bullet screen is displayed in the video playing process, so that the updating frequency of a client can be reduced, and labor and system resources of a terminal are saved.
Inventors
- LI YATAO
- LI GUOQING
- WANG YULONG
- SONG HAO
Assignees
- 北京爱奇艺科技有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20260317
Claims (15)
- 1. A barrage display method, wherein the method is applied to a terminal, the method comprising: when the configuration resource acquisition condition is met, acquiring configuration resources of the target barrage special effect from a server, wherein the configuration resources comprise barrage templates using the target barrage special effect and configuration rules for adding data into the barrage templates, and the configuration resource acquisition condition represents that the requirement for using the target barrage special effect exists; In the process of playing the video, if the condition that the special effect triggering condition is met is detected, determining a bullet screen to be processed of the special effect of the target bullet screen to be used; according to the configuration rule, adding the text content of the bullet screen to be processed to the bullet screen template to obtain the bullet screen to be processed with the special effect of the target bullet screen as a first bullet screen; and displaying the first barrage in the process of playing the video.
- 2. The method of claim 1, wherein a text area and a decoration area of the bullet screen are defined in the bullet screen template; And adding the text content of the bullet screen to be processed to the bullet screen template according to the configuration rule to obtain the bullet screen to be processed using the target bullet screen special effect as a first bullet screen, wherein the bullet screen comprises: According to a configuration rule of a text region, adding the text content of the bullet screen to be processed into the text region; Adding a decorative image to the decorative area according to the configuration rule of the decorative area, wherein the decorative image belongs to the configuration data of the barrage template carried in the configuration resource; And splicing the text area and the decoration area to obtain a bullet screen to be processed with the special effect of the target bullet screen as a first bullet screen.
- 3. The method according to claim 2, wherein adding the text content of the bullet screen to be processed to the text region according to the configuration rule of the text region comprises: calculating the size of a text region when the text content is displayed according to the fonts and the font sizes based on the fonts and the font sizes contained in the configuration rules of the text region and the text content of the bullet screen to be processed; If the size of the text region is consistent with the size of a background image, adding the text content into the background image to obtain the text region, wherein the background image belongs to configuration data of the barrage template carried in the configuration resource; and if the size of the text region is inconsistent with the size of the background image, adjusting the size of the background image to be consistent with the size of the text region, and adding the text content into the adjusted background image to obtain the text region.
- 4. The method of claim 2, wherein the decorative area comprises at least one of a head decorative area, a tail decorative area, a corner mark decorative area; The splicing of the text area and the decoration area to obtain a bullet screen to be processed using the special effect of the target bullet screen as a first bullet screen comprises the following steps: And splicing at least one of the head decoration area, the tail decoration area and the corner mark decoration area with the text area to obtain a bullet screen to be processed with the special effect of the target bullet screen as a first bullet screen.
- 5. The method of claim 1, wherein displaying the first bullet screen during the playing of the video comprises: Determining the last bullet screen to be compared displayed in the bullet screen display track aiming at each bullet screen display track in the bullet screen display area of the terminal, wherein each bullet screen display track is used for displaying a group of bullet screens moving along a designated direction; detecting whether the first barrage is overlapped with the barrage to be compared or not when the first barrage is displayed on the barrage display track; if the first barrage and the barrage to be compared are not overlapped, determining that the barrage display track is a target display track for displaying the first barrage; in the target display track, determining the position outside the screen of the terminal as the initial position of the first barrage; And in the process of playing the video, starting from the initial position, displaying the first barrage in the target display track at a preset movement rate and a preset movement direction.
- 6. The method of claim 5, wherein said displaying the first bullet screen in the target presentation track from the initial position at a predetermined rate and direction of movement during the playing of the video, comprises: displaying the first bullet screen at the initial position in the target display track during the process of playing the video; Calculating the time difference of two adjacent frames of barrages according to the frame rate of the barrages to serve as barrages movement time, wherein the frame rate of the barrages represents the number of frames of barrages displayed per second; Calculating the movement distance of the first barrage in the preset movement direction according to the barrage movement time and the preset movement rate; Calculating the sum of the current position of the first barrage and the movement distance to obtain the target position of the first barrage when the next barrage is played; And when the next frame of barrage is played, displaying the first barrage at the target position in the target display track, and returning to execute the step of calculating the time difference of two adjacent frames of barrages according to the frame rate of the barrages to serve as the barrage movement time.
- 7. The method of claim 5, wherein after said detecting whether said first bullet screen overlaps said bullet screen to be compared when said first bullet screen is displayed on said bullet screen display track, said method further comprises: If the first barrage is displayed on each barrage display track, overlapping the barrages to be compared in the barrage display tracks, and when the preset duration is reached, executing the step of determining the last barrage to be compared displayed in the barrage display tracks for each barrage display track in the barrage display area of the terminal; or alternatively; If the first barrage is displayed on each barrage display track, overlapping the first barrage with the barrage to be compared in the barrage display track, and increasing the movement speed of the displayed barrages in each barrage display track; when the preset duration is reached, executing the step of determining the last bullet screen to be compared displayed in the bullet screen display track aiming at each bullet screen display track in the bullet screen display area of the terminal; Or alternatively If the first barrage is displayed on each barrage display track, the first barrage is overlapped with the barrages to be compared in the barrage display tracks, the first barrage is sent by a target user using the terminal, and a new barrage display track is opened in the barrage display area, so that the target display track for displaying the first barrage is obtained.
- 8. The method of claim 1, wherein after the configuration resource for the target barrage special effect is obtained from the server when the configuration resource obtaining condition is satisfied, the method further comprises: storing the configuration resource to the local of the terminal, and recording the corresponding relation between the identification of the configuration resource and the storage position; And adding the text content of the bullet screen to be processed to the bullet screen template according to the configuration rule to obtain the bullet screen to be processed using the target bullet screen special effect as a first bullet screen, wherein the bullet screen comprises: according to the identification of the configuration resources of the target barrage special effect, determining the storage position of the configuration resources of the target barrage special effect in the corresponding relation; loading configuration resources of the target barrage special effects into a memory from the storage position; And adding the text content of the bullet screen to be processed to the bullet screen template in the memory according to the configuration rule to obtain the bullet screen to be processed with the special effect of the target bullet screen as a first bullet screen.
- 9. The method of claim 1, wherein after the configuration resource for the target barrage special effect is obtained from the server when the configuration resource obtaining condition is satisfied, the method further comprises: If the acquisition of the configuration resource fails, or the equipment performance of the terminal does not meet the use condition of the target barrage special effect, generating a barrage to be processed using the specified barrage special effect as a second barrage according to the specified barrage style and the text content of the barrage to be processed; And displaying the second barrage in the process of playing the video.
- 10. The method according to claim 1, wherein determining the to-be-processed barrage to be specific to the target barrage if the specific trigger condition is detected to be satisfied during the video playing process comprises: Displaying a first interface in the process of playing the video, wherein the first interface displays the identification of a plurality of bullet screen special effects; Responding to a selection instruction of a target user aiming at the identification of the barrage special effect, and determining the target barrage special effect indicated by the selection instruction; responding to the barrage sending operation of the target user, and determining that the special effect triggering condition is met; and determining the barrage sent by the target user as the barrage to be processed with the special effect of the target barrage.
- 11. The method according to claim 1, wherein determining the to-be-processed barrage to be specific to the target barrage if the specific trigger condition is detected to be satisfied during the video playing process comprises: In the process of playing the video, if the video is detected to be played to the appointed scenario, determining that the special effect triggering condition is met; and determining that the barrage acquired from the server is the barrage to be processed with the special effect of the target barrage to be used within the duration of the appointed scenario.
- 12. The bullet screen display system is characterized by comprising a first terminal, a second terminal and a server; the first terminal is used for displaying a first interface, displaying a plurality of bullet screen configuration options in the first interface, responding to a special effect configuration instruction aiming at the bullet screen configuration options, acquiring configuration resources of a target bullet screen special effect carried in the special effect configuration instruction, and sending the configuration resources to a server; the server is used for storing the received configuration resources after receiving the configuration resources; the second terminal for executing the bullet screen display method of any one of claims 1 to 11.
- 13. A barrage display device, the device being for use in a terminal, the device comprising: The system comprises a configuration resource acquisition module, a configuration resource acquisition module and a control module, wherein the configuration resource acquisition module is used for acquiring configuration resources of a target barrage special effect from a server when the configuration resource acquisition condition is met, and the configuration resources comprise barrage templates of the target barrage special effect and configuration rules for adding data into the barrage templates; The bullet screen determining module is used for determining the bullet screen to be used for the target bullet screen special effect if the bullet screen meeting the special effect triggering condition is detected in the video playing process; The first barrage generation module is used for adding the text content of the barrage to be processed to the barrage template according to the configuration rule to obtain the barrage to be processed with the special effect of the target barrage as a first barrage; and the first barrage display module is used for displaying the first barrage in the process of playing the video.
- 14. The terminal is characterized by comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory are communicated with each other through the communication bus; a memory for storing a computer program; a processor for carrying out the method steps of any one of claims 1-11 when executing a program stored on a memory.
- 15. A computer-readable storage medium, characterized in that the computer-readable storage medium has stored therein a computer program which, when executed by a processor, implements the method steps of any of claims 1-11.
Description
Bullet screen display method, device, system, terminal and storage medium Technical Field The present invention relates to the field of internet technologies, and in particular, to a barrage display method, device, system, terminal, and storage medium. Background With the development of internet technology, the real-time interaction demand of users in online video and live broadcast scenes is continuously enhanced, and a barrage is used as an instant and visual interaction mode and has become a standard function of each large video client and each live broadcast client. In the related art, in order to enrich the bullet screen effect, skins including different bullet screen styles (e.g., colors, fonts, etc.) are configured at a client by modifying a code of the client. The client displays the barrages sent by the user according to the skin selected by the user, and realizes displaying barrages in various modes. However, in the above implementation, each time the bullet screen style is updated, the client needs to be reissued after the code of the client is modified, which results in higher update frequency of the client and further wastes more manpower and resources. Disclosure of Invention The embodiment of the invention aims to provide a bullet screen display method, device, system, terminal and storage medium, so as to reduce the update frequency of a client and save the manpower and the system resources of the terminal. The specific technical scheme is as follows: The method comprises the steps of obtaining configuration resources of a target barrage special effect from a server when configuration resource obtaining conditions are met, wherein the configuration resources comprise barrage templates of the target barrage special effect and configuration rules for adding data into the barrage templates, the configuration resource obtaining conditions represent the requirement of using the target barrage special effect, determining a barrage to be processed of the target barrage special effect when the special effect triggering conditions are detected to be met in the video playing process, adding text content of the barrage to be processed to the barrage templates according to the configuration rules to obtain the barrage to be processed of the target barrage special effect, and displaying the first barrage as the first barrage in the video playing process. Optionally, a text area and a decoration area of the barrage are defined in the barrage template; The method comprises the steps of adding text content of a bullet screen to be processed into a bullet screen template according to the configuration rules to obtain the bullet screen to be processed with the target bullet screen special effect as a first bullet screen, adding the text content of the bullet screen to be processed into a text area according to the configuration rules of the text area, adding a decoration map into a decoration area according to the configuration rules of the decoration area, wherein the decoration map belongs to configuration data of the bullet screen template carried in the configuration resources, and splicing the text area with the decoration area to obtain the bullet screen to be processed with the target bullet screen special effect as the first bullet screen. Optionally, the adding the text content of the bullet screen to be processed to the text region according to the configuration rule of the text region includes calculating the size of the text region when the text content is displayed according to the font and the font size based on the font and the font size contained in the configuration rule of the text region and the text content of the bullet screen to be processed, adding the text content to the background map to obtain the text region if the size of the text region is consistent with the size of the background map, wherein the background map belongs to configuration data of the bullet screen template carried in the configuration resource, adjusting the size of the background map to be consistent with the size of the text region if the size of the text region is inconsistent with the size of the background map, and adding the text content to the adjusted background map to obtain the text region. Optionally, the decoration area comprises at least one of a head decoration area, a tail decoration area and an angle mark decoration area; The splicing of the text area and the decoration area to obtain the bullet screen to be processed with the target bullet screen special effect is used as a first bullet screen, and the splicing of at least one of the head decoration area, the tail decoration area and the corner mark decoration area and the text area is performed to obtain the bullet screen to be processed with the target bullet screen special effect as the first bullet screen. The method comprises the steps of displaying a first bullet screen in a video playing process, determining the last bullet screen to be comp