Lyrics display method and device, and storage medium
By structuring the lyric data and displaying it dynamically according to the singing progress, the existing lyric display methods have solved the problem of single structure and poor interaction, and a more flexible and immersive lyric display effect is achieved.
Patent Information
- Application Number
- PCT/CN2024/135238
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-11-29
- Filing Date
- 2024-11-28
- Publication Date
- 2025-06-05
AI Technical Summary
The existing lyrics display method uses scrolling lyrics, with a single structure, poor interaction and immersion, and no prompt for singing.
By obtaining the lyrics data of the current song, obtaining the time information of each lyrics based on the lyrics data, encapsulate each lyrics and time information into a data structure, obtaining the target data structure according to the current song singing progress, and using one or more display controls to display the corresponding lyrics in the lyrics display area.
It improves the flexibility of lyrics display, overcomes the problem of single scrolling lyrics structure, enhances user experience, realizes the correlation between lyrics and song rhythm, and provides a prompt function for singing.
Smart Images

Figure CN2024135238_05062025_PF_FP_ABST
Abstract
Description
Lyrics display method, device and storage medium
[0001] This application claims priority to Chinese Patent Application No. 202311616204.3 filed on November 29, 2023, and the contents of the above-mentioned Chinese patent application disclosure are hereby cited in their entirety as a part of this application. Technical Field
[0002] Embodiments of the present disclosure relate to a lyrics display method, device, and storage medium. Background Art
[0003] With the development of network communication technology, terminals can provide not only listening to songs, but also singing and karaoke functions, and can also provide multi-person karaoke or live karaoke functions. Lyrics need to be displayed during the singing process.
[0004] Currently, lyrics are usually displayed by scrolling, but the lyrics structure is simple and the sense of interactivity and immersion is poor. Summary of the Invention
[0005] The embodiments of the present disclosure provide a lyrics display method, device, and storage medium to improve the lyrics display effect and enhance the user experience.
[0006] In a first aspect, an embodiment of the present disclosure provides a method for displaying lyrics, comprising:
[0007] Get the lyrics data of the current song;
[0008] Acquire time information of multiple lyrics according to the lyrics data, and encapsulate each of the multiple lyrics and the corresponding time information into a data structure according to the time information of each of the multiple lyrics, to obtain multiple data structures;
[0009] According to the time information corresponding to the current song singing progress, a target data structure is obtained from the multiple data structures, and corresponding lyrics are displayed in one or more display controls in the lyrics display area according to the target data structure.
[0010] In a second aspect, an embodiment of the present disclosure provides a lyrics display device, comprising:
[0011] An acquisition unit, used to acquire lyrics data of the current song;
[0012] a processing unit, configured to obtain time information of multiple lyrics according to the lyrics data, and encapsulate each of the multiple lyrics and the corresponding time information into a data structure according to the time information of each of the multiple lyrics, thereby obtaining multiple data structures;
[0013] The display unit is used to obtain a target data structure from the multiple data structures according to the time information corresponding to the current song singing progress, and display corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure.
[0014] In a third aspect, an embodiment of the present disclosure provides an electronic device, including: at least one processor and a memory;
[0015] The memory stores computer-executable instructions;
[0016] The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the lyrics display method described in the first aspect and various possible designs of the first aspect.
[0017] In a fourth aspect, an embodiment of the present disclosure provides a computer-readable storage medium, in which computer execution instructions are stored. When a processor executes the computer execution instructions, the lyrics display method described in the first aspect and various possible designs of the first aspect is implemented.
[0018] In a fifth aspect, an embodiment of the present disclosure provides a computer program product, comprising computer-executable instructions. When a processor executes the computer-executable instructions, the lyrics display method as described in the first aspect and various possible designs of the first aspect is implemented. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] In order to more clearly illustrate the technical solutions in the embodiments of the present disclosure, a brief introduction will be given below to the drawings required for use in the description of the embodiments. Obviously, the drawings described below are some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.
[0020] FIG1 is an example diagram of an interface for displaying lyrics;
[0021] FIG2 is a schematic diagram of an interface of a lyrics display method provided by an embodiment of the present disclosure;
[0022] FIG3 is a flow chart of a method for displaying lyrics according to an embodiment of the present disclosure;
[0023] FIG4 is a schematic diagram of a first display control and a second display control provided by an embodiment of the present disclosure;
[0024] FIG5 is a schematic diagram of an interface for storing lyrics provided by an embodiment of the present disclosure;
[0025] FIG6 is a schematic diagram of an interface for storing lyrics provided by another embodiment of the present disclosure;
[0026] FIG7 is a schematic diagram of an interface for a start-of-singing prompt provided by an embodiment of the present disclosure;
[0027] FIG8 is a structural block diagram of a lyrics display device provided by an embodiment of the present disclosure;
[0028] FIG9 is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION
[0029] To make the objectives, technical solutions, and advantages of the embodiments of the present disclosure more clear, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present disclosure, not all of the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present disclosure without making any creative efforts shall fall within the scope of protection of the present disclosure.
[0030] Currently, lyrics are typically displayed using scrolling lyrics, for example, using a CollectionView scrolling view. As shown in Figure 1, the first row displays the current song's lyrics (with a revolving lantern effect), and the second row displays the lyrics to be sung. However, the lyrics are structured in a simple manner, resulting in a poor sense of interactivity and immersion. Furthermore, the rhythm of the lyrics is unrelated to the song's performance. During long interludes, the completed lyrics remain on the first row, affecting the user experience. There is also no prompt to proceed with the song.
[0031] In order to solve at least one of the above technical problems, the present disclosure hopes to improve the flexibility of lyrics display, overcome the problem of a single scrolling lyrics structure, and meet the user's personalized needs for lyrics display. For example, a lyrics display method similar to that of offline KTV, or other display methods, is adopted to improve the lyrics display effect. Therefore, the present disclosure adopts one or more display controls to display lyrics in the lyrics display area. The number and / or position of the display controls can be set according to needs, making the display of lyrics more flexible. As shown in Figure 2, in order to realize the lyrics display method of offline KTV, the first display control 202 and the second display control 203 are used to display lyrics in the lyrics display area 201, wherein the first display control 202 can be located above, to the left or in the upper left of the second display control 203. Optionally, the first display control 202 is located in the upper left of the lyrics display area 201, and the second display control 203 is located in the lower right of the lyrics display area 201. In order to support the lyrics display area to display lyrics through display controls of different numbers and / or positions, in the embodiment of the present disclosure, each sentence of lyrics and the corresponding time information are encapsulated into a data structure to obtain multiple data structures. In this way, each display control only needs to obtain the corresponding target data structure from the multiple data structures according to the time information corresponding to the current song singing progress, and display the corresponding lyrics according to the target data structure. There is no need to extract lyrics and process time information from the original lyrics data during the singing process, thereby ensuring accurate and stable lyrics display.
[0032] It should be noted that the user information and data involved in this disclosure are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of relevant countries and regions, and provide corresponding operation entrances for users to choose to authorize or refuse.
[0033] The lyrics display method disclosed in the present invention will be described in detail below with reference to specific embodiments.
[0034] Refer to Figure 3, which is a flow chart of a method for displaying lyrics according to an embodiment of the present disclosure. The method of this embodiment can be applied to electronic devices such as terminal devices, and specifically to any application with karaoke or singing functions. It can also be applied to scenarios such as live broadcasts with live karaoke and live broadcast hosts singing songs.
[0035] The lyrics display method includes:
[0036] S301, obtaining lyrics data of the current song.
[0037] In this embodiment, when the lyrics of the current song need to be displayed, the lyrics data of the current song can be obtained first. The lyrics data can include the time information of each word in the lyrics. For example, the format of the lyrics data can be KRC format or other formats, which are not limited here. Of course, the lyrics data can also include other information, such as song information, lyrics producer information, etc.
[0038] Optionally, in an application with karaoke and singing functions, the lyrics data of the current song are obtained after the user selects the current song to be sung, or when the accompaniment of the current song starts to play, or when a song switch occurs.
[0039] Optionally, in a live broadcast scenario, after selecting the current song to be sung, or when the accompaniment of the current song starts playing, or when a song switch occurs, the host-side device, other singing participant devices, and the audience-side device can obtain the lyrics data of the current song. In addition, when the audience-side device enters the live broadcast room, it can also obtain the lyrics data of the current song in the live broadcast room.
[0040] S302: obtaining time information of multiple lyrics according to the lyrics data, and encapsulating each of the multiple lyrics and the corresponding time information into a data structure according to the time information of each of the multiple lyrics, to obtain multiple data structures.
[0041] In this embodiment, when obtaining the lyrics data of the current song, the lyrics data can be traversed to obtain the time information of each line of lyrics from the lyrics data. For example, for any line of lyrics, one or more of the following time information including but not limited to the current lyrics can be obtained: the time interval between the end time of the current lyrics and the start time of the next line of lyrics, the start display time of the current lyrics, the end display time of the current lyrics, and the display duration of the current lyrics.
[0042] Furthermore, each line of lyrics and the corresponding time information can be encapsulated into a data structure based on the time information of each line of lyrics. For example, the data structure can be a data model (model, responsible for data acquisition and storage) in the MVVM pattern. The data structure is an instance of the UI data source object in the lyrics display area, which includes the lyrics content and the time information of the lyrics, and of course the time information of each word in the lyrics (used to control the revolving lantern effect). Through the above encapsulation process, each line of lyrics can correspond to a data structure, and then a data structure list modellist is obtained. By reconstructing the data structure of the lyrics information at the data layer and processing the alienation logic, the lyrics display is transformed from being dependent on the singing time of a single line of lyrics to being dependent on the display time of a single line of lyrics.
[0043] Optionally, before encapsulation, it is also possible to determine whether the length of each lyric exceeds a preset length. The preset length can be the upper limit of the length of lyrics that can be displayed in a line in the lyrics display area, or a preset length can be set according to demand. If the length of any sentence of lyrics exceeds the preset length, the sentence of lyrics is split into at least two sentences of lyrics, and the at least two sentences of lyrics obtained by splitting and their corresponding time information (which can be retrieved after splitting) are respectively encapsulated into at least two data structures, and each sentence of lyrics obtained by splitting corresponds to one data structure.
[0044] S303. According to the time information corresponding to the current song singing progress, a target data structure is obtained from the multiple data structures, and corresponding lyrics are displayed in one or more display controls in the lyrics display area according to the target data structure.
[0045] In this embodiment, during the current song singing process, each data structure can be consumed from multiple data structures, that is, the data structure list modellist, according to the time information corresponding to the current song singing progress (or accompaniment playback progress), and lyrics are displayed in the lyrics display area in turn according to each data structure. Specifically, the lyrics display area includes one or more display controls, and the display controls can be used to display lyrics according to the target data structure. Each display control obtains a target data structure matching the time information corresponding to the singing progress from multiple data structures according to the time information corresponding to the current song singing progress. If there is only one display control, each data structure is obtained in turn according to the time information corresponding to the singing progress for lyrics display; if there are multiple display controls, each display control displays the lyrics alternately, that is, each display control alternately obtains a data structure from multiple data structures according to the time information corresponding to the current song singing progress as the target structure for lyrics display.
[0046] Optionally, one or more display controls may specifically include a first display control and a second display control, wherein the first display control may be located above, to the left, or to the upper left of the second display control, and the first display control and the second display control alternately display lyrics according to the progress of the performance. For example, the first display control displays the first line of lyrics, the second display control displays the second line of lyrics, the first display control displays the third line of lyrics, the second display control displays the fourth line of lyrics, and so on. Optionally, similar to the lyrics of an offline KTV, the first display control is located in the upper left of the lyrics display area, and the second display control is located in the lower right of the lyrics display area. The first display control and the second display control alternately display lyrics according to the progress of the performance, which is more immersive and interactive than scrolling lyrics, and realizes the effect of a revolving lantern of lyrics. Of course, one or more display controls are not limited to the above examples, and can also be arranged in any other manner, which can be selected according to user needs (different arrangement modes can be provided for users to choose, and display controls are arranged in the lyrics display area in response to the user's selection instructions), or freely set by the user (for example, in response to the user's personalized arrangement instructions, display controls are arranged in the lyrics display area according to the arrangement instructions).
[0047] Optionally, as shown in Figure 4, the first display control and the second display control set a lyric text content display sub-control in the container. For example, the display of the lyric text content can be achieved through a label control. It can also include a mask control, and a mask is set on the lyric text content display sub-control paper. The mask is set with a preset color and / or pattern. The mask control can adjust the mask width according to the current singing progress of the song, so that the sung part and the unsung part of each sentence of lyrics are displayed separately, so that the sung part and the unsung part present different display effects. For example, each word of the lyric text content changes color and / or pattern in turn according to the singing progress to achieve a revolving lantern effect.
[0048] Based on this, displaying the corresponding lyrics in the display control in S303 may specifically include displaying the corresponding lyrics text content in the display control, and controlling the width of the mask set above the lyrics text content in the display control according to the time information corresponding to the current song singing progress, so as to distinguish between the sung part and the unsung part in each sentence of lyrics, so that the sung part and the unsung part present different display effects, thereby realizing the lyrics carousel effect.
[0049] Optionally, after obtaining multiple data structures in S302, the display position of the lyrics corresponding to any data structure in the lyrics display area can be determined, that is, whether the lyrics corresponding to any data structure are displayed in the first display control or the second display control is judged, and the data structure corresponding to the lyrics displayed in the first display control is added to the first data structure set, and the data structure corresponding to the lyrics displayed in the second display control is added to the second data structure set, thereby obtaining two data structure sets (or lists).
[0050] Furthermore, when executing S303, according to the time information corresponding to the current song singing progress, the corresponding first target data structure is obtained from the first data structure set, and the corresponding lyrics are displayed in the first display control according to the first target data structure; and / or, the corresponding second target data structure is obtained from the second data structure set, and the corresponding lyrics are displayed in the second display control according to the second target data structure, so that the first display control only needs to consume data structures from the first data structure set in sequence, and the second display control only needs to consume data structures from the second data structure set in sequence, without having to judge the display position of the lyrics corresponding to any data structure in the lyrics display area during the current song singing process, thereby ensuring the stable display of lyrics during the current song singing process. Of course, if there are more than three display controls in the lyrics display area, the corresponding data structure set corresponding to each display control can be obtained, and then each display control can obtain the target data structure from the corresponding data structure set to display the corresponding lyrics.
[0051] Optionally, in an audio live broadcast scenario, the live stream data does not include video images. Therefore, for the host-end device and the audience-end device in the live broadcast room, it is necessary to execute the above-mentioned S301-S303 processes respectively to realize the lyrics display on the host-end device and the audience-end device (and other singing participant device ends). The live stream data is audio live stream data, and can also carry time information corresponding to the current song singing progress. When executing S303, the audience-end device can obtain the time information corresponding to the current song singing progress from the live stream data, and according to the time information corresponding to the current song singing progress, obtain the corresponding target data structure from the multiple data structures obtained by the audience-end device itself, and then display the corresponding lyrics in the first display control and / or the second display control.
[0052] The lyrics display method provided by this embodiment obtains lyrics data of the current song; obtains time information of multiple lyrics based on the lyrics data, and encapsulates each lyrics sentence and the corresponding time information into a data structure based on the time information of each lyrics sentence in the multiple lyrics, thereby obtaining multiple data structures; obtains a target data structure from the multiple data structures based on the time information corresponding to the singing progress of the current song, and displays the corresponding lyrics in one or more display controls in the lyrics display area based on the target data structure. In this embodiment, one or more display controls are used in the lyrics display area to display lyrics. The number and / or position of the display controls can be set according to needs, making the display of lyrics more flexible, overcoming the problem of a single scrolling lyrics structure, meeting the user's personalized needs for lyrics display methods, and improving user experience. In order to support the lyrics display area to display lyrics through display controls of different numbers and / or positions, in this embodiment, each sentence of lyrics and the corresponding time information are encapsulated into a data structure to obtain multiple data structures. In this way, each display control only needs to obtain the corresponding target data structure from the multiple data structures according to the time information corresponding to the current song singing progress, and display the corresponding lyrics according to the target data structure. There is no need to extract lyrics and process time information from the original lyrics data during the singing process, thereby ensuring accurate and stable lyrics display.
[0053] In the above embodiment, in order to simulate offline KTV lyrics as realistically as possible, it is also necessary to implement the retention of lyrics before the interlude or outro, that is, to continuously display the lyrics until the end of the interlude or outro (or to n seconds before the end of the interlude or outro).
[0054] Specifically, before acquiring multiple data structures in S302, especially before adding the data structure corresponding to the lyrics displayed in the first display control to the first data structure set and before adding the data structure corresponding to the lyrics displayed in the second display control to the second data structure set, the following steps may also be included:
[0055] Determine whether any data structure is the data structure corresponding to the last line of lyrics before the interlude or the outro;
[0056] If any of the data structures is a data structure corresponding to the last line of lyrics before an interlude or an outro, and the lyrics corresponding to any of the data structures are displayed in the first display control, then insert an empty data structure after the any of the data structures, and align the end display time corresponding to the empty data structure with the end display time corresponding to the any of the data structures; or
[0057] If any of the data structures is a data structure corresponding to the last sentence of lyrics before the interlude or the outro, and the lyrics corresponding to any of the data structures are displayed in the second display control, then the end display time corresponding to the previous data structure of any of the data structures is aligned with the end display time corresponding to any of the data structures.
[0058] In this embodiment, for any data structure, whether the data structure is the data structure corresponding to the last sentence of lyrics before the interlude or the outro can be judged based on the time interval between the end time of the lyrics corresponding to the any data structure and the start time of the next sentence of lyrics, that is, whether the time interval between the end time of the lyrics corresponding to the any data structure and the start time of the next sentence of lyrics exceeds the preset time interval. If so, it is determined that the data structure is the data structure corresponding to the last sentence of lyrics before the interlude or the outro.
[0059] If it is determined that any data structure is the data structure corresponding to the last line of lyrics before the interlude or outro, the lyrics need to be retained and can be continuously displayed until the end of the interlude or outro (or continuously displayed until n seconds before the end of the interlude or outro). However, different processing methods exist depending on the different display positions of the last line of lyrics before the interlude or outro in the lyrics display area.
[0060] As shown in Figure 5, if the last sentence lyrics before interlude or outing show in the first display control, then this sentence lyrics resides in interlude or outing process, simultaneously the second display control does not need to show next sentence lyrics in interlude or outing process, also namely the second display control is empty, therefore if this arbitrary data structure is the data structure corresponding to the last sentence lyrics before interlude or outing, and the corresponding lyrics of this arbitrary data structure show in the first display control, then an empty data structure can be inserted after this arbitrary data structure, and the end display time corresponding to this arbitrary data structure and the end display time corresponding to this empty data structure are set to interlude or outing end time (or interlude or outing end before n seconds), thus realize that the lyrics in interlude or outing process reside.And the corresponding start display time of empty data structure can be interlude or outing start time, or is the end display time of the last lyrics shown in the second display control.
[0061] As shown in Figure 6, if the last sentence of lyrics before the interlude or outro is displayed in the second display control, then the sentence of lyrics will reside during the interlude or outro, and the previous sentence of lyrics of the last sentence also needs to reside during the interlude or outro, and the previous sentence of lyrics of the last sentence is displayed in the first display control. Therefore, if any data structure is the data structure corresponding to the last sentence of lyrics before the interlude or outro, and the lyrics corresponding to any data structure are displayed in the second display control, then the end display time corresponding to any data structure and the end display time corresponding to the previous data structure of any data structure are set to the end time of the interlude or outro (or n seconds before the end of the interlude or outro), and the end display time of the previous sentence of lyrics and the end display time of the last sentence of lyrics are aligned with the end time of the interlude or outro (or n seconds before the end of the interlude or outro), thereby achieving the residence of the two sentences of lyrics during the interlude or outro.
[0062] On the basis of any of the above embodiments, in order to simulate offline KTV lyrics as realistically as possible, it is also necessary to implement a singing prompt function after the prelude or interlude, that is, to prompt the start time of singing the first sentence of lyrics after the prelude or interlude.
[0063] Specifically, the step of displaying corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure in S303 may further include:
[0064] If it is determined that the display control displays the lyrics as the first line of lyrics after the prelude or interlude, a countdown prompt control is displayed according to the current song singing progress and the start display time of the line of lyrics. The countdown prompt control is used to prompt the start time of singing the line of lyrics.
[0065] In this embodiment, the first line of lyrics after the prelude or interlude can be determined based on the time information of each line of lyrics, and an array is maintained to record the start time of singing the first line of lyrics after the prelude or interlude.
[0066] Furthermore, during the current song singing process, a timer can be configured to update the time at a high frequency to synchronize the time information corresponding to the current song singing progress, and a judgment logic can be added to the timer to determine whether the current song singing progress enters the time range of the first sentence of lyrics after the prelude or interlude in the above array to start singing, for example, whether it enters the time range of 3 seconds before the first sentence of lyrics after the prelude or interlude to start singing. If so, a countdown prompt control is displayed and refreshed once per second to achieve the effect of prompting the start of singing. As shown in Figure 7, the countdown prompt control 701 can use dots to represent the countdown, for example, 3 dots represent 3 seconds remaining, 2 dots represent 2 seconds remaining, and one dot represents 1 second remaining.
[0067] It should be noted that in a live broadcast scenario, for an audience-side device, if the audience-side device enters the live broadcast room, based on the current song singing progress and the start display time of the first line of lyrics after the prelude or interlude, it is determined that the remaining time from the current song singing progress to the start of singing the first line of lyrics after the prelude or interlude exceeds the preset time length (for example, more than 2.5 seconds), then the above-mentioned countdown prompt control will be displayed; however, if it is determined that the remaining time from the current song singing progress to the start of singing the first line of lyrics after the prelude or interlude does not exceed the preset time length (for example, no more than 2.5 seconds), then the time is insufficient to fully play the singing effect, so the above-mentioned countdown prompt control may not be displayed. The preset time length may be equal to the time length of the advance prompt for the start of singing, or slightly shorter than the time length of the advance prompt for the start of singing.
[0068] Corresponding to the lyric display method described in the preceding embodiment, FIG8 is a block diagram of a lyric display device provided in an embodiment of the present disclosure. For ease of illustration, only the portions relevant to the embodiment of the present disclosure are shown. Referring to FIG8 , the lyric display device 800 includes an acquisition unit 801, a processing unit 802, and a display unit 803.
[0069] The acquisition unit 801 is used to acquire the lyrics data of the current song;
[0070] The processing unit 802 is configured to obtain time information of multiple lyrics according to the lyrics data, and encapsulate each of the multiple lyrics and the corresponding time information into a data structure according to the time information of each of the multiple lyrics, thereby obtaining multiple data structures.
[0071] The display unit 803 is used to obtain a target data structure from the multiple data structures according to the time information corresponding to the current song singing progress, and display corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure.
[0072] In one or more embodiments of the present disclosure, the one or more display controls include a first display control and a second display control, wherein the first display control is located above, to the left, or above and to the left of the second display control.
[0073] In one or more embodiments of the present disclosure, when acquiring time information of multiple lyrics according to the lyrics data, the processing unit 802 is configured to:
[0074] Get one or more of the following time information for any line of lyrics: the time interval between the end time of the current line and the start time of the next line, the start time of the current line, the end time of the current line, and the duration of the current line.
[0075] In one or more embodiments of the present disclosure, after obtaining the multiple data structures, the processing unit 802 is configured to:
[0076] Determine the display position of lyrics corresponding to any data structure in the lyrics display area;
[0077] The data structure corresponding to the lyrics displayed in the first display control is added to the first data structure set, and the data structure corresponding to the lyrics displayed in the second display control is added to the second data structure set.
[0078] In one or more embodiments of the present disclosure, when the display unit 803 obtains a target data structure from the multiple data structures according to the time information corresponding to the current song singing progress, and displays corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure, it is used to:
[0079] According to the time information corresponding to the current song singing progress, the corresponding first target data structure is obtained from the first data structure set, and the corresponding lyrics are displayed in the first display control according to the first target data structure; and / or, the corresponding second target data structure is obtained from the second data structure set, and the corresponding lyrics are displayed in the second display control according to the second target data structure.
[0080] In one or more embodiments of the present disclosure, the processing unit 802 is further configured to: before adding the data structure corresponding to the lyrics displayed in the first display control to the first data structure set and adding the data structure corresponding to the lyrics displayed in the second display control to the second data structure set:
[0081] Determine whether any data structure is the data structure corresponding to the last line of lyrics before the interlude or the outro;
[0082] If any of the data structures is a data structure corresponding to the last line of lyrics before an interlude or an outro, and the lyrics corresponding to any of the data structures are displayed in the first display control, then insert an empty data structure after the any of the data structures, and align the end display time corresponding to the empty data structure with the end display time corresponding to the any of the data structures; or
[0083] If any of the data structures is a data structure corresponding to the last sentence of lyrics before the interlude or the outro, and the lyrics corresponding to any of the data structures are displayed in the second display control, then the end display time corresponding to the previous data structure of any of the data structures is aligned with the end display time corresponding to any of the data structures.
[0084] In one or more embodiments of the present disclosure, when determining whether any data structure is a data structure corresponding to the last line of lyrics before an interlude or an outro, the processing unit 802 is configured to:
[0085] Determine whether the time interval between the end time of the lyrics corresponding to any data structure and the start time of the next lyrics exceeds the preset time interval. If so, determine that the any data structure is the data structure corresponding to the last lyrics before the interlude or the outro.
[0086] In one or more embodiments of the present disclosure, the processing unit 802 encapsulates each sentence of lyrics and the corresponding time information into a data structure according to the time information of each sentence of lyrics, and is further configured to:
[0087] If the length of any sentence of lyrics exceeds a preset length, the any sentence of lyrics is split into at least two sentences of lyrics, and the at least two sentences of lyrics and their corresponding time information are respectively encapsulated into at least two data structures.
[0088] In one or more embodiments of the present disclosure, when displaying corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure, the display unit 803 is configured to:
[0089] Displaying corresponding lyrics text content in the display control;
[0090] According to the time information corresponding to the current song singing progress, the width of the mask set above the lyrics text content in the display control is controlled to distinguish between the sung part and the unsung part of each sentence of lyrics.
[0091] In one or more embodiments of the present disclosure, the method is applied to a host-end device and / or a viewer-end device in a live broadcast room.
[0092] In one or more embodiments of the present disclosure, if the method is applied to a viewer-end device, the acquisition unit 801 is used to:
[0093] After the viewer-end device enters the live broadcast room, or after the viewer-end device detects a song switch based on live broadcast stream data, the lyrics data of the current song are obtained;
[0094] When the display unit 803 obtains the target data structure from the multiple data structures according to the time information corresponding to the current song performance progress, it is used to:
[0095] The time information corresponding to the current song singing progress is obtained from the live streaming data, and the target data structure is obtained from the multiple data structures according to the time information corresponding to the current song singing progress.
[0096] In one or more embodiments of the present disclosure, when displaying corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure, the display unit 803 is configured to:
[0097] If it is determined that the display control displays the lyrics as the first line of lyrics after the prelude or interlude, a countdown prompt control is displayed according to the current song singing progress and the start display time of the line of lyrics. The countdown prompt control is used to prompt the start time of singing the line of lyrics.
[0098] In one or more embodiments of the present disclosure, if the method is applied to a viewer-end device, the display unit 803, when displaying a countdown prompt control based on the current song performance progress and the start time of the lyrics, is used to:
[0099] If the audience device enters the live broadcast room, based on the current song singing progress and the start display time of the lyrics, it is determined that the remaining time until the start of singing the lyrics exceeds the preset duration, then the countdown prompt control is displayed.
[0100] The lyrics display device provided in this embodiment can be used to execute the technical solution of the above-mentioned method embodiment. Its implementation principle and technical effects are similar and will not be described in detail in this embodiment.
[0101] Referring to FIG9 , a schematic diagram of the structure of an electronic device 900 suitable for implementing an embodiment of the present disclosure is shown. The electronic device 900 may be a terminal device or a server. The terminal device may include, but is not limited to, mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, personal digital assistants (PDAs), tablet computers (Portable Android Devices, PADs), portable multimedia players (PMPs), vehicle-mounted terminals (e.g., vehicle-mounted navigation terminals), and fixed terminals such as digital TVs and desktop computers. The electronic device shown in FIG9 is merely an example and should not limit the functionality and scope of use of the embodiments of the present disclosure.
[0102] As shown in Figure 9, the electronic device 900 may include a processing device (e.g., a central processing unit, a graphics processing unit, etc.) 901, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 902 or a program loaded from a storage device 908 into a random access memory (RAM) 903. Various programs and data required for the operation of the electronic device 900 are also stored in the RAM 903. The processing device 901, the ROM 902, and the RAM 903 are connected to each other via a bus 904. An input / output (I / O) interface 905 is also connected to the bus 904.
[0103] Typically, the following devices may be connected to the I / O interface 905: an input device 906 including, for example, a touch screen, a touchpad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, etc.; an output device 907 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, etc.; a storage device 908 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 909. The communication device 909 may allow the electronic device 900 to communicate with other devices wirelessly or by wire to exchange data. Although FIG9 shows an electronic device 900 with various devices, it should be understood that it is not required to implement or have all of the devices shown. More or fewer devices may be implemented or have alternatively.
[0104] In particular, according to an embodiment of the present disclosure, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present disclosure includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network via the communication device 909, or installed from the storage device 908, or installed from the ROM 902. When the computer program is executed by the processing device 901, the above-mentioned functions defined in the method of the embodiment of the present disclosure are performed.
[0105] It should be noted that the computer-readable medium mentioned above in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium, or any combination of the two. A computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device, or component, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, device, or component. In the present disclosure, a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, which carries computer-readable program code. Such a propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport a program for use by or in conjunction with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium may be transmitted using any suitable medium, including but not limited to wires, optical cables, RF (radio frequency), etc., or any suitable combination thereof.
[0106] The computer-readable medium may be included in the electronic device, or may exist independently without being incorporated into the electronic device.
[0107] The computer-readable medium carries one or more programs. When the one or more programs are executed by the electronic device, the electronic device executes the method shown in the above embodiment.
[0108] Computer program code for performing the operations of the present disclosure may be written in one or more programming languages, or a combination thereof, including object-oriented programming languages such as Java, Smalltalk, C++, and conventional procedural programming languages such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a stand-alone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet Service Provider).
[0109] The flowcharts and block diagrams in the accompanying drawings illustrate the possible implementation architecture, functions and operations of the systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each box in the flowchart or block diagram can represent a module, program segment, or a part of code, and the module, program segment, or a part of code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order than that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of the boxes in the block diagram and / or flowchart, can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0110] The units involved in the embodiments described in this disclosure may be implemented in software or hardware. In some cases, the name of a unit does not limit the unit itself. For example, the first acquisition unit may also be described as a "unit for acquiring at least two Internet Protocol addresses."
[0111] The functions described above herein may be performed, at least in part, by one or more hardware logic components. For example, and without limitation, exemplary types of hardware logic components that may be used include: field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chip (SOCs), complex programmable logic devices (CPLDs), and the like.
[0112] In the context of the present disclosure, a machine-readable medium can be a tangible medium that can contain or store a program for use by or in conjunction with an instruction execution system, device or equipment. A machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or equipment, or any suitable combination of the foregoing. A more specific example of a machine-readable storage medium can include an electrical connection based on one or more lines, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0113] In a first aspect, according to one or more embodiments of the present disclosure, a method for displaying lyrics is provided, comprising:
[0114] Get the lyrics data of the current song;
[0115] Acquire time information of multiple lyrics according to the lyrics data, and encapsulate each of the multiple lyrics and the corresponding time information into a data structure according to the time information of each of the multiple lyrics, to obtain multiple data structures;
[0116] According to the time information corresponding to the current song singing progress, a target data structure is obtained from the multiple data structures, and corresponding lyrics are displayed in one or more display controls in the lyrics display area according to the target data structure.
[0117] According to one or more embodiments of the present disclosure, the one or more display controls include a first display control and a second display control, wherein the first display control is located above, to the left, or above and to the left of the second display control.
[0118] According to one or more embodiments of the present disclosure, the step of obtaining time information of multiple lyrics based on the lyrics data includes:
[0119] Get one or more of the following time information for any line of lyrics: the time interval between the end time of the current line and the start time of the next line, the start time of the current line, the end time of the current line, and the duration of the current line.
[0120] According to one or more embodiments of the present disclosure, after obtaining the multiple data structures, the method further includes:
[0121] Determine the display position of lyrics corresponding to any data structure in the lyrics display area;
[0122] The data structure corresponding to the lyrics displayed in the first display control is added to the first data structure set, and the data structure corresponding to the lyrics displayed in the second display control is added to the second data structure set.
[0123] According to one or more embodiments of the present disclosure, obtaining a target data structure from the multiple data structures based on the time information corresponding to the current song performance progress, and displaying corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure, includes:
[0124] According to the time information corresponding to the current song singing progress, the corresponding first target data structure is obtained from the first data structure set, and the corresponding lyrics are displayed in the first display control according to the first target data structure; and / or, the corresponding second target data structure is obtained from the second data structure set, and the corresponding lyrics are displayed in the second display control according to the second target data structure.
[0125] According to one or more embodiments of the present disclosure, before adding the data structure corresponding to the lyrics displayed in the first display control to the first data structure set and adding the data structure corresponding to the lyrics displayed in the second display control to the second data structure set, the method further includes:
[0126] Determine whether any data structure is the data structure corresponding to the last line of lyrics before the interlude or the outro;
[0127] If any of the data structures is a data structure corresponding to the last line of lyrics before an interlude or an outro, and the lyrics corresponding to any of the data structures are displayed in the first display control, then insert an empty data structure after the any of the data structures, and align the end display time corresponding to the empty data structure with the end display time corresponding to the any of the data structures; or
[0128] If any of the data structures is a data structure corresponding to the last sentence of lyrics before the interlude or the outro, and the lyrics corresponding to any of the data structures are displayed in the second display control, then the end display time corresponding to the previous data structure of any of the data structures is aligned with the end display time corresponding to any of the data structures.
[0129] According to one or more embodiments of the present disclosure, determining whether any data structure is a data structure corresponding to the last line of lyrics before an interlude or an outro includes:
[0130] Determine whether the time interval between the end time of the lyrics corresponding to any data structure and the start time of the next lyrics exceeds the preset time interval. If so, determine that the any data structure is the data structure corresponding to the last lyrics before the interlude or the outro.
[0131] According to one or more embodiments of the present disclosure, encapsulating each sentence of lyrics and the corresponding time information into a data structure according to the time information of each sentence of lyrics in the multiple sentences further includes:
[0132] If the length of any sentence of lyrics exceeds a preset length, the any sentence of lyrics is split into at least two sentences of lyrics, and the at least two sentences of lyrics and their corresponding time information are respectively encapsulated into at least two data structures.
[0133] According to one or more embodiments of the present disclosure, displaying corresponding lyrics in one or more display controls in a lyrics display area according to the target data structure includes:
[0134] Displaying corresponding lyrics text content in the display control;
[0135] According to the time information corresponding to the current song singing progress, the width of the mask set above the lyrics text content in the display control is controlled to distinguish between the sung part and the unsung part of each sentence of lyrics.
[0136] According to one or more embodiments of the present disclosure, the method is applied to a host-end device and / or a viewer-end device in a live broadcast room.
[0137] According to one or more embodiments of the present disclosure, if the method is applied to a viewer-end device, obtaining lyrics data of the current song includes:
[0138] After the viewer-end device enters the live broadcast room, or after the viewer-end device detects a song switch based on live broadcast stream data, the lyrics data of the current song are obtained;
[0139] The step of obtaining a target data structure from the plurality of data structures according to the time information corresponding to the current song singing progress includes:
[0140] The time information corresponding to the current song singing progress is obtained from the live streaming data, and the target data structure is obtained from the multiple data structures according to the time information corresponding to the current song singing progress.
[0141] According to one or more embodiments of the present disclosure, displaying corresponding lyrics in one or more display controls in a lyrics display area according to the target data structure includes:
[0142] If it is determined that the display control displays the lyrics as the first line of lyrics after the prelude or interlude, a countdown prompt control is displayed according to the current song singing progress and the start display time of the line of lyrics. The countdown prompt control is used to prompt the start time of singing the line of lyrics.
[0143] According to one or more embodiments of the present disclosure, if the method is applied to a viewer-end device, displaying a countdown prompt control based on the current song performance progress and the start time of the lyrics includes:
[0144] If the audience device enters the live broadcast room, based on the current song singing progress and the start display time of the lyrics, it is determined that the remaining time until the start of singing the lyrics exceeds the preset duration, then the countdown prompt control is displayed.
[0145] In a second aspect, according to one or more embodiments of the present disclosure, a lyrics display device is provided, comprising:
[0146] An acquisition unit, used to acquire lyrics data of the current song;
[0147] a processing unit, configured to obtain time information of multiple lyrics according to the lyrics data, and encapsulate each of the multiple lyrics and the corresponding time information into a data structure according to the time information of each of the multiple lyrics, thereby obtaining multiple data structures;
[0148] The display unit is used to obtain a target data structure from the multiple data structures according to the time information corresponding to the current song singing progress, and display corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure.
[0149] According to one or more embodiments of the present disclosure, the one or more display controls include a first display control and a second display control, wherein the first display control is located above, to the left, or above and to the left of the second display control.
[0150] According to one or more embodiments of the present disclosure, when the processing unit obtains time information of multiple lyrics according to the lyrics data, it is configured to:
[0151] Get one or more of the following time information for any line of lyrics: the time interval between the end time of the current line and the start time of the next line, the start time of the current line, the end time of the current line, and the duration of the current line.
[0152] According to one or more embodiments of the present disclosure, after obtaining the multiple data structures, the processing unit is further configured to:
[0153] Determine the display position of lyrics corresponding to any data structure in the lyrics display area;
[0154] The data structure corresponding to the lyrics displayed in the first display control is added to the first data structure set, and the data structure corresponding to the lyrics displayed in the second display control is added to the second data structure set.
[0155] According to one or more embodiments of the present disclosure, when the display unit obtains a target data structure from the multiple data structures based on the time information corresponding to the current song performance progress, and displays corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure, it is used to:
[0156] According to the time information corresponding to the current song singing progress, the corresponding first target data structure is obtained from the first data structure set, and the corresponding lyrics are displayed in the first display control according to the first target data structure; and / or, the corresponding second target data structure is obtained from the second data structure set, and the corresponding lyrics are displayed in the second display control according to the second target data structure.
[0157] According to one or more embodiments of the present disclosure, the processing unit is further configured to: before adding the data structure corresponding to the lyrics displayed in the first display control to the first data structure set and adding the data structure corresponding to the lyrics displayed in the second display control to the second data structure set:
[0158] Determine whether any data structure is the data structure corresponding to the last line of lyrics before the interlude or the outro;
[0159] If any of the data structures is a data structure corresponding to the last line of lyrics before an interlude or an outro, and the lyrics corresponding to any of the data structures are displayed in the first display control, then insert an empty data structure after the any of the data structures, and align the end display time corresponding to the empty data structure with the end display time corresponding to the any of the data structures; or
[0160] If any of the data structures is a data structure corresponding to the last sentence of lyrics before the interlude or the outro, and the lyrics corresponding to any of the data structures are displayed in the second display control, then the end display time corresponding to the previous data structure of any of the data structures is aligned with the end display time corresponding to any of the data structures.
[0161] According to one or more embodiments of the present disclosure, when determining whether any data structure is a data structure corresponding to the last line of lyrics before an interlude or an outro, the processing unit is configured to:
[0162] Determine whether the time interval between the end time of the lyrics corresponding to any data structure and the start time of the next lyrics exceeds the preset time interval. If so, determine that the any data structure is the data structure corresponding to the last lyrics before the interlude or the outro.
[0163] According to one or more embodiments of the present disclosure, the processing unit encapsulates each sentence of lyrics and the corresponding time information into a data structure according to the time information of each sentence of lyrics, and is further configured to:
[0164] If the length of any sentence of lyrics exceeds a preset length, the any sentence of lyrics is split into at least two sentences of lyrics, and the at least two sentences of lyrics and their corresponding time information are respectively encapsulated into at least two data structures.
[0165] According to one or more embodiments of the present disclosure, when the display unit displays corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure, it is configured to:
[0166] Displaying corresponding lyrics text content in the display control;
[0167] According to the time information corresponding to the current song singing progress, the width of the mask set above the lyrics text content in the display control is controlled to distinguish between the sung part and the unsung part of each sentence of lyrics.
[0168] According to one or more embodiments of the present disclosure, the method is applied to a host-end device and / or a viewer-end device in a live broadcast room.
[0169] According to one or more embodiments of the present disclosure, if the method is applied to a viewer-end device, the acquisition unit, when acquiring lyrics data of the current song, is configured to:
[0170] After the viewer-end device enters the live broadcast room, or after the viewer-end device detects a song switch based on live broadcast stream data, the lyrics data of the current song are obtained;
[0171] When the display unit obtains the target data structure from the multiple data structures according to the time information corresponding to the current song performance progress, it is used to:
[0172] The time information corresponding to the current song singing progress is obtained from the live streaming data, and the target data structure is obtained from the multiple data structures according to the time information corresponding to the current song singing progress.
[0173] According to one or more embodiments of the present disclosure, when the display unit displays corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure, it is configured to:
[0174] If it is determined that the display control displays the lyrics as the first line of lyrics after the prelude or interlude, a countdown prompt control is displayed according to the current song singing progress and the start display time of the line of lyrics. The countdown prompt control is used to prompt the start time of singing the line of lyrics.
[0175] According to one or more embodiments of the present disclosure, if the method is applied to a viewer-end device, the display unit, when displaying a countdown prompt control based on the current song performance progress and the start time of the lyrics, is used to:
[0176] If the audience device enters the live broadcast room, based on the current song singing progress and the start display time of the lyrics, it is determined that the remaining time until the start of singing the lyrics exceeds the preset duration, then the countdown prompt control is displayed.
[0177] In a third aspect, according to one or more embodiments of the present disclosure, there is provided an electronic device, comprising: at least one processor and a memory;
[0178] The memory stores computer-executable instructions;
[0179] The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor executes the lyrics display method described in the first aspect and various possible designs of the first aspect.
[0180] In a fourth aspect, according to one or more embodiments of the present disclosure, a computer-readable storage medium is provided, in which computer execution instructions are stored. When a processor executes the computer execution instructions, the lyrics display method described in the first aspect and various possible designs of the first aspect is implemented.
[0181] In a fifth aspect, according to one or more embodiments of the present disclosure, a computer program product is provided, comprising computer-executable instructions. When a processor executes the computer-executable instructions, the lyrics display method as described in the first aspect and various possible designs of the first aspect is implemented.
[0182] The above description is merely a preferred embodiment of the present disclosure and an illustration of the technical principles employed. Those skilled in the art should understand that the scope of disclosure involved in the present disclosure is not limited to the technical solutions formed by the specific combination of the above-mentioned technical features, but also includes other technical solutions formed by any combination of the above-mentioned technical features or their equivalents without departing from the above-mentioned disclosed concepts. For example, a technical solution formed by replacing the above-mentioned features with (but not limited to) technical features with similar functions disclosed in this disclosure.
[0183] In addition, although each operation is described in a specific order, this should not be understood as requiring these operations to be performed in the specific order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Similarly, although some specific implementation details have been included in the above discussion, these should not be interpreted as limiting the scope of the present disclosure. Some features described in the context of a separate embodiment can also be implemented in a single embodiment in combination. On the contrary, the various features described in the context of a single embodiment can also be implemented in multiple embodiments individually or in any suitable sub-combination mode.
[0184] Although the subject matter has been described in language specific to structural features and / or methodological logical acts, it should be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are merely example forms of implementing the claims.
Claims
1. A lyrics display method, comprising: Get the lyrics data of the current song; Acquire time information of multiple lyrics according to the lyrics data, and encapsulate each of the lyrics and the corresponding time information into a data structure according to the time information of each of the multiple lyrics, to obtain multiple data structures; According to the time information corresponding to the current song singing progress, a target data structure is obtained from the multiple data structures, and corresponding lyrics are displayed in one or more display controls in the lyrics display area according to the target data structure.
2. The method according to claim 1, wherein: The one or more display controls include a first display control and a second display control, wherein the first display control is located above, to the left, or to the upper left of the second display control.
3. The method according to claim 2, wherein: The step of obtaining time information of multiple lyrics according to the lyrics data includes: Get one or more of the following time information of any line of lyrics: the time interval between the end time of the current lyrics and the start time of the next lyrics, the start time of the current lyrics, the end time of the current lyrics, and the display duration of the current lyrics.
4. The method according to claim 3, wherein: After obtaining the plurality of data structures, the method further comprises: Determine the display position of the lyrics corresponding to any data structure in the lyrics display area; The data structure corresponding to the lyrics displayed in the first display control is added to the first data structure set, and the data structure corresponding to the lyrics displayed in the second display control is added to the second data structure set.
5. The method according to claim 4, wherein: The step of acquiring a target data structure from the plurality of data structures according to the time information corresponding to the current song singing progress, and displaying corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure comprises: According to the time information corresponding to the current song singing progress, the corresponding first target data structure is obtained from the first data structure set, and the corresponding lyrics are displayed in the first display control according to the first target data structure; and / or, the corresponding second target data structure is obtained from the second data structure set, and the corresponding lyrics are displayed in the second display control according to the second target data structure.
6. The method according to claim 4, wherein: Before adding the data structure corresponding to the lyrics displayed in the first display control to the first data structure set and adding the data structure corresponding to the lyrics displayed in the second display control to the second data structure set, the method further includes: Determine whether any of the data structures is a data structure corresponding to the last line of lyrics before an interlude or an outro; If any of the data structures is a data structure corresponding to the last line of lyrics before the interlude or the outro, and the lyrics corresponding to any of the data structures are displayed in the first display control, then an empty data structure is inserted after the any of the data structures, and the end display time corresponding to the empty data structure is aligned with the end display time corresponding to the any of the data structures; or If any of the data structures is a data structure corresponding to the last sentence of lyrics before the interlude or outro, and the lyrics corresponding to any of the data structures are displayed in the second display control, then the end display time corresponding to the previous data structure of any of the data structures is aligned with the end display time corresponding to any of the data structures.
7. The method according to claim 4, wherein: The step of judging whether any data structure is a data structure corresponding to the last line of lyrics before an interlude or an outro comprises: Determine whether the time interval between the end time of the lyrics corresponding to any of the data structures and the start time of the next lyrics exceeds a preset time interval. If so, determine that any of the data structures is the data structure corresponding to the last lyrics before the interlude or outro.
8. The method according to any one of claims 1 to 7, wherein: The method further comprises encapsulating each line of lyrics and the corresponding time information into a data structure according to the time information of each line of lyrics: If the length of any sentence of lyrics exceeds a preset length, the any sentence of lyrics is split into at least two sentences of lyrics, and the at least two sentences of lyrics and their corresponding time information are respectively encapsulated into at least two data structures.
9. The method according to any one of claims 1 to 8, wherein: The step of displaying corresponding lyrics in one or more display controls in a lyrics display area according to the target data structure includes: Displaying corresponding lyrics text content in the display control; According to the time information corresponding to the current song singing progress, the width of the mask set on the lyrics text content in the display control is controlled to distinguish between the sung part and the unsung part of each sentence of lyrics.
10. The method according to any one of claims 1 to 9, wherein: The method is applied to a host-end device and / or a viewer-end device in a live broadcast room.
11. The method according to claim 10, wherein: If the method is applied to a viewer-end device, the step of obtaining lyrics data of the current song includes: After the audience device enters the live broadcast room, or after the audience device detects a song switch according to live broadcast stream data, the lyrics data of the current song are obtained; The step of obtaining a target data structure from the plurality of data structures according to the time information corresponding to the current song singing progress includes: The time information corresponding to the current song singing progress is obtained from the live streaming data, and the target data structure is obtained from the multiple data structures according to the time information corresponding to the current song singing progress.
12. The method according to any one of claims 1 to 8, wherein: The step of displaying corresponding lyrics in one or more display controls in a lyrics display area according to the target data structure includes: If it is determined that the display control displays the lyrics as the first line of lyrics after the prelude or interlude, a countdown prompt control is displayed according to the current song singing progress and the start display time of the first line of lyrics. The countdown prompt control is used to prompt the start time of singing the lyrics.
13. The method according to claim 12, wherein: If the method is applied to a viewer-end device in a live broadcast room, the countdown prompt control is displayed according to the current song singing progress and the start display time of the first line of lyrics, including: If the audience device enters the live broadcast room, based on the current song singing progress and the start display time of the first line of lyrics, it is determined that the remaining time until the start of singing the lyrics exceeds the preset duration, then the countdown prompt control is displayed.
14. A lyrics display device, comprising: An acquisition unit, configured to acquire lyrics data of a current song; A processing unit is configured to obtain time information of multiple lyrics according to the lyrics data, and encapsulate each of the lyrics and the corresponding time information into a data structure according to the time information of each of the multiple lyrics, so as to obtain multiple data structures; The display unit is configured to obtain a target data structure from the multiple data structures according to the time information corresponding to the current song singing progress, and display corresponding lyrics in one or more display controls in the lyrics display area according to the target data structure.
15. An electronic device comprising at least one processor and a memory, wherein: The memory stores computer-executable instructions; The at least one processor executes the computer-executable instructions stored in the memory, so that the at least one processor performs the method according to any one of claims 1 to 13.
16. A computer-readable storage medium storing computer-executable instructions, wherein: When the processor executes the computer-executable instructions, the method according to any one of claims 1 to 13 is implemented.
17. A computer program product comprising computer executable instructions, wherein: When the processor executes the computer-executable instructions, the method according to any one of claims 1 to 13 is implemented.
Citation Information
Patent Citations
Lyrics display processing method and device, electronic device and computer storage medium
CN109543064A
System, method and device for processing information
CN110087122A
Live stream processing method, device and system, electronic equipment and storage medium
CN110267081A
Lyric video display method and device, electronic equipment and computer readable medium
CN112423107A
Systems and methods for object storage and retrieval
US20220250840A1