Streaming Media Data Processing Method, Streaming Media Playing Method, Device and Program Product
By pre-parsing a segment of flow media data based on a target duration, the method addresses the inefficiency in initial playback, allowing immediate presentation and seamless continuation, thereby improving playback efficiency.
Patent Information
- Application Number
- CN202210449535.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-24
- Publication Date
- 2025-07-15
- Estimated Expiration
- 2042-04-24
AI Technical Summary
In the prior art, when a user requests to play streaming content, the terminal needs to spend a period of time parsing the streaming media data, resulting in low playback efficiency.
By obtaining the original data of the streaming media content, the target resolution time is determined, the previous streaming media data is pre-parsed, and the latter streaming media data is reorganized to form streaming media data that can be played directly.
The playback efficiency of streaming content is improved. The terminal can save time to parse the previous streaming media data, directly play the previous content, and simultaneously parse the latter data to achieve continuous playback.
Smart Images

Figure CN114845135B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of streaming media technology, and particularly to a streaming media data processing method, a streaming media playing method, a computer device, and a computer program product. Background Art
[0002] With the development of network and audio-video related technologies, application programs such as short video applications and music applications provide users with rich streaming media playing services.
[0003] In the current technology, when a user requests to play relevant streaming media content, the terminal needs to spend a period of time parsing the streaming media data and then presenting the relevant streaming media content to the user, resulting in a problem of low playing efficiency of the streaming media content. Summary of the Invention
[0004] Based on this, it is necessary to provide a streaming media data processing method, a streaming media playing method, a computer device, and a computer program product for the above technical problems.
[0005] In a first aspect, this application provides a streaming media data processing method. The method includes:
[0006] Obtain the original streaming media data corresponding to the streaming media content;
[0007] Determine the target parsing duration of the streaming media content;
[0008] Parse the front-segment streaming media data to be parsed corresponding to the target parsing duration in the original streaming media data to obtain pre-parsed front-segment streaming media data;
[0009] Obtain the streaming media data corresponding to the streaming media content according to the pre-parsed front-segment streaming media data and the back-segment streaming media data to be parsed in the original streaming media data.
[0010] In a second aspect, this application provides a streaming media playing method. The method includes:
[0011] Obtain the streaming media data corresponding to the streaming media content to be played from a server; the streaming media data includes pre-parsed front-segment streaming media data and back-segment streaming media data to be parsed; the streaming media data is obtained according to the above method;
[0012] Play the front-segment streaming media content corresponding to the front-segment streaming media data, and parse the back-segment streaming media data to obtain the back-segment streaming media content;
[0013] Apply the back-segment streaming media content to the continuous playing of the front-segment streaming media content.
[0014] In a third aspect, the present application also provides a computer device. The computer device includes a memory and a processor. The memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:
[0015] Obtain the original streaming media data corresponding to the streaming media content; determine the target parsing duration of the streaming media content; parse the front-segment streaming media data to be parsed corresponding to the target parsing duration in the original streaming media data to obtain pre-parsed front-segment streaming media data; and obtain the streaming media data corresponding to the streaming media content according to the pre-parsed front-segment streaming media data and the back-segment streaming media data to be parsed in the original streaming media data.
[0016] In a fourth aspect, the present application also provides a computer device. The computer device includes a memory and a processor. The memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:
[0017] Obtain the streaming media data corresponding to the streaming media content to be played from a server; the streaming media data includes pre-parsed front-segment streaming media data and back-segment streaming media data to be parsed; the streaming media data is obtained according to the above method; play the front-segment streaming media content corresponding to the front-segment streaming media data, and parse the back-segment streaming media data to obtain the back-segment streaming media content; and apply the back-segment streaming media content to the continuous playback of the front-segment streaming media content.
[0018] In a fifth aspect, the present application also provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0019] Obtain the original streaming media data corresponding to the streaming media content; determine the target parsing duration of the streaming media content; parse the front-segment streaming media data to be parsed corresponding to the target parsing duration in the original streaming media data to obtain pre-parsed front-segment streaming media data; and obtain the streaming media data corresponding to the streaming media content according to the pre-parsed front-segment streaming media data and the back-segment streaming media data to be parsed in the original streaming media data.
[0020] In a sixth aspect, the present application also provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0021] Obtain the streaming media data corresponding to the streaming media content to be played from the server; the streaming media data includes pre-parsed front-segment streaming media data and post-segment streaming media data to be parsed; the streaming media data is obtained according to the above method; play the front-segment streaming media content corresponding to the front-segment streaming media data, and parse the post-segment streaming media data to obtain the post-segment streaming media content; apply the post-segment streaming media content to the continuous playback of the front-segment streaming media content.
[0022] The above streaming media data processing method, streaming media playback method, computer device, and computer program product obtain the original streaming media data corresponding to the streaming media content, determine the target parsing duration of the streaming media content, parse the front-segment streaming media data to be parsed corresponding to the target parsing duration in the original streaming media data to obtain pre-parsed front-segment streaming media data, and obtain the streaming media data corresponding to the streaming media content according to the pre-parsed front-segment streaming media data and the post-segment streaming media data to be parsed in the original streaming media data. This solution reconstructs the original streaming media data corresponding to the streaming media content, pre-parses the front-segment streaming media data to be parsed corresponding to the target parsing duration therein, and then can recombine the pre-parsed front-segment streaming media data and the post-segment streaming media data to be parsed in the original streaming media data into the streaming media data corresponding to the streaming media content. Since the front-segment data of the reconstructed streaming media data has been pre-parsed, when the terminal needs to play the streaming media content, it can save the parsing time of the front-segment streaming media data and directly play the corresponding front-segment streaming media content. At the same time, it can synchronously parse the post-segment streaming media data for the continuous playback of the front-segment streaming media content, thereby improving the playback efficiency of the streaming media content. Description of the Drawings
[0023] Figure 1 It is an application environment diagram of the streaming media data processing method and the streaming media playback method in an embodiment;
[0024] Figure 2 It is a flowchart of the streaming media data processing method in an embodiment;
[0025] Figure 3 It is a composition diagram of the reconstructed streaming media data of the present application in an embodiment;
[0026] Figure 4 It is a flowchart of determining the target parsing duration of the streaming media content in an embodiment;
[0027] Figure 5 It is a flowchart of the streaming media playback method in an embodiment;
[0028] Figure 6 It is a flowchart of the streaming media processing and playback method in an application example;
[0029] Figure 7Internal structure diagram of a computer device in an embodiment;
[0030] Figure 8 Internal structure diagram of a computer device in another embodiment. Detailed implementation manners
[0031] In order to make the objectives, technical solutions and advantages of the present application clearer and more understandable, the present application will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0032] The streaming media data processing method and the streaming media playing method provided by the embodiments of the present application can be applied to an application environment as Figure 1 shown. The application environment may include a terminal 110 and a server 120, and the terminal 110 communicates with the server 120 through a network. A data storage system can store the data that the server 120 needs to process. The data storage system can be integrated on the server 120, or can be placed in the cloud or on other network servers. Among them, the terminal 110 can be, but is not limited to, various personal computers, laptop computers, smart phones, tablet computers, Internet of Things devices and portable wearable devices. The Internet of Things devices can be smart speakers, smart TVs, smart vehicle-mounted devices, etc. The portable wearable devices can be smart watches, smart bracelets, head-mounted devices, etc. The server 120 can be implemented by an independent server or a server cluster composed of multiple servers.
[0033] Specifically, the server 120 can obtain the original streaming media data corresponding to the streaming media content, determine the target parsing duration of the streaming media content, parse the front-segment streaming media data to be parsed corresponding to the target parsing duration in the original streaming media data to obtain the pre-parsed front-segment streaming media data, and then obtain the streaming media data corresponding to the streaming media content according to the pre-parsed front-segment streaming media data and the back-segment streaming media data to be parsed in the original streaming media data. The server 120 can store the streaming media data corresponding to the streaming media content in the streaming media content library for the terminal 110 to pull when requesting to play the streaming media data corresponding to the relevant streaming media content. Among them, when the user requests to play a streaming media content on the terminal 110, the terminal 110 can use the streaming media content requested by the user as the streaming media content to be played, and then obtain the streaming media data corresponding to the streaming media content to be played from the server 120. The streaming media data includes the pre-parsed front-segment streaming media data and the back-segment streaming media data to be parsed by the server 120. Thus, the terminal 110 can directly play the front-segment streaming media content corresponding to the front-segment streaming media data, and at the same time parse the back-segment streaming media data to obtain the back-segment streaming media content, and apply the parsed back-segment streaming media content to the continuous playback of the front-segment streaming media content, so that the terminal 110 can save the parsing time of the front-segment streaming media data and directly play the corresponding front-segment streaming media content, and at the same time synchronously parse the back-segment streaming media data for the continuous playback of the front-segment streaming media content, improving the playback efficiency of the streaming media content.
[0034] The following part will specifically describe the streaming media data processing method and the streaming media playback method provided by the present application in sequence in combination with each embodiment and the corresponding drawings.
[0035] In one embodiment, as Figure 2 shown, a streaming media data processing method is provided. This method can be executed by the server 120 as Figure 1 shown, and may include the following steps:
[0036] Step S201, obtain the original streaming media data corresponding to the streaming media content.
[0037] Among them, the streaming media content can be the streaming media content in the streaming media content library that needs to be data-reconstructed or called data-rearranged. The streaming media content library can be maintained by the server 120, and can be specifically integrated in the server 120, or can be placed on the cloud or other network servers. In this step, the server 120 determines the streaming media content that needs to be data-reconstructed from the streaming media content library, and obtains the corresponding original streaming media data from the streaming media content library. Among them, the original streaming media data refers to the streaming media data in the original data format, such as the streaming media data in mp4 and flv formats.
[0038] Step S202, determine the target parsing duration of the streaming media content.
[0039] Among them, each streaming media content can correspond to its own target parsing duration, which refers to the duration of the front-segment streaming media data that needs to be pre-parsed for a streaming media content. In specific applications, different streaming media contents can have the same target parsing duration or different target parsing durations. For example, the target parsing duration of all streaming media contents that need to be pre-parsed can be set to 1 second, or the target parsing duration of some streaming media contents that need to be pre-parsed can be set to 1.2 seconds, 0.8 seconds, etc. This embodiment does not make specific limitations on this.
[0040] Step S203: Parse the front-segment streaming media data to be parsed corresponding to the target parsing duration in the original streaming media data to obtain pre-parsed front-segment streaming media data.
[0041] This step mainly parses the front-segment streaming media data to be parsed with the corresponding duration in the original streaming media data obtained in step S201 according to the target parsing duration determined in step S202 to obtain pre-parsed front-segment streaming media data, that is, parses out the front-segment streaming media data corresponding to the target parsing duration from the original streaming media data as the pre-parsed front-segment streaming media data. In specific applications, the parsing of the original streaming media data can be performed according to the agreed format of application programs such as short video applications and music applications on the terminal 110. For example, the agreed format of application program A is a raw stream compressed by h264. Assuming the target parsing duration is 1 second and the original data format is mp4 format, then the server 120 can parse out the data of the 1st second in the mp4-format original streaming media data and generate data in the agreed format (raw stream compressed by h264) of the aforementioned application program A as the pre-parsed front-segment streaming media data.
[0042] Step S204: Obtain the streaming media data corresponding to the streaming media content according to the pre-parsed front-segment streaming media data and the unparsed back-segment streaming media data in the original streaming media data.
[0043] In this step, the pre-parsed front-segment streaming media data obtained in step S203 can be combined with the unparsed or so-called back-segment streaming media data in the original streaming media data to form the streaming media data corresponding to the streaming media content. Exemplarily, such as Figure 3As shown in the figure, assume that the target parsing duration is 1 second. Then, the front-segment streaming media data is the streaming media data of the 1st second, and the back-segment streaming media data is the streaming media data after the 1st second. The pre-parsed front-segment streaming media data corresponds to the streaming media content of the 1st second (i.e., the front-segment streaming media content), and the back-segment streaming media data to be parsed corresponds to the streaming media content after the 1st second (i.e., the back-segment streaming media content). The streaming media data corresponding to the streaming media content obtained by the server 120 through this process may include the front-segment streaming media data corresponding to the raw stream compressed by h264 and the back-segment streaming media data corresponding to mp4. The data format of the reconstructed / reassembled streaming media data can be further defined as nMp4.
[0044] In the streaming media data processing method of this embodiment, the original streaming media data corresponding to the streaming media content is obtained, the target parsing duration of the streaming media content is determined, the front-segment streaming media data to be parsed corresponding to the target parsing duration in the original streaming media data is parsed to obtain the pre-parsed front-segment streaming media data, and the streaming media data corresponding to the streaming media content is obtained according to the pre-parsed front-segment streaming media data and the back-segment streaming media data to be parsed in the original streaming media data. This solution reconstructs the original streaming media data corresponding to the streaming media content, pre-parses the front-segment streaming media data to be parsed corresponding to the target parsing duration therein, and then the pre-parsed front-segment streaming media data and the back-segment streaming media data to be parsed in the original streaming media data can be reassembled into the streaming media data corresponding to the streaming media content. Since the front-segment data of the reconstructed streaming media data has been pre-parsed, when the terminal needs to play the streaming media content, it can save the parsing time of the front-segment streaming media data and directly play the corresponding front-segment streaming media content. At the same time, it can synchronously parse the back-segment streaming media data for continuous playback of the front-segment streaming media content, thereby improving the playback efficiency of the streaming media content.
[0045] In one embodiment, as Figure 4 shown, determining the target parsing duration of the streaming media content in step S202 above may include:
[0046] Step S401, obtaining the playback popularity of the streaming media content.
[0047] Specifically, the server 120 can obtain the playback popularity of the streaming media content according to information such as the number of plays, the played duration, the number of comments, the number of likes, and the number of forwards of the streaming media content.
[0048] Step S402, determining the corresponding parsing duration ratio according to the playback popularity.
[0049] Among them, the higher the playback popularity of the streaming media content, the more likely it is to be browsed by the user from beginning to end. On the contrary, the lower the playback popularity of the streaming media content, the more likely it is to be quickly closed by the user after the start of playback and then the user browses other streaming media content. Therefore, for streaming media content with high playback popularity, a relatively higher parsing duration ratio can be set for it, and for streaming media content with low playback popularity, a relatively lower parsing duration ratio can be set for it, so as to save the resources for parsing and transmitting the streaming media data on the basis of improving the playback efficiency of the streaming media content. Exemplarily, if the playback popularity of the streaming media content is at a low popularity level, the server 120 can determine that the corresponding parsing duration ratio is 0.1; if the playback popularity of the streaming media content is at a medium popularity level, the server 120 can determine that the corresponding parsing duration ratio is 0.5; if the playback popularity of the streaming media content is at a high popularity level, the server 120 can determine that the corresponding parsing duration ratio is 1.
[0050] Step S403: Obtain the target parsing duration of the streaming media content according to the preset parsing duration threshold and the parsing duration ratio.
[0051] In this step, the preset parsing duration threshold can represent the upper limit of the target parsing duration, that is, the target parsing duration of any streaming media content needs to be less than or equal to this preset parsing duration threshold. Specifically, the server 120 can use the product of the preset parsing duration threshold and the parsing duration ratio as the target parsing duration of the streaming media content. Exemplarily, if the preset parsing duration threshold is 1 second, when the parsing duration ratios are 0.1, 0.5, and 1 respectively, the corresponding target parsing durations are 0.1 second, 0.5 second, and 1 second.
[0052] This embodiment can determine the corresponding target parsing duration for the front-end streaming media data parsing according to the playback popularity of the streaming media content, and save the resources for parsing and transmitting the streaming media data on the basis of improving the playback efficiency of the streaming media content.
[0053] Further, in some embodiments, obtaining the playback popularity of the streaming media content in step S401 may include: if the historical playback record of the streaming media content meets the statistical duration condition, determine the playback popularity of the streaming media content according to the historical playback record of the streaming media content within the preset historical period.
[0054] Among them, the statistical duration condition may be whether the streaming media content has historical play records in a recent period such as the past week or the past two weeks. And the historical play record of the streaming media content meeting the statistical duration condition means that the streaming media content has historical play records in the recent period. In this case, the server 120 may determine the play popularity of the streaming media content according to the historical play record of the streaming media content itself within a preset historical period. Among them, the preset historical period may be less than or equal to the aforementioned statistical duration. If the statistical duration is the past two weeks, the preset historical period may be the past week, the past half week, etc., for the server 120 to accurately determine the play popularity of the streaming media content according to its recent historical play record.
[0055] As an implementation manner, the server 120 may count the historical play records of the streaming media content within a preset historical period, obtain the total number of play times of the streaming media content within the preset historical period. When the total number of play times does not reach the first play times threshold, it may be determined that its play popularity is at a low popularity level. When the total number of play times reaches the first play times threshold but does not reach the second play times threshold, it may be determined that it is at a medium popularity level. When the total number of play times reaches the second play times threshold, it may be determined that it is at a high popularity level.
[0056] Furthermore, in some embodiments, determining the play popularity of the streaming media content according to the historical play record of the streaming media content within a preset historical period in the above embodiments may specifically include:
[0057] Obtaining statistical information on the single play duration of the streaming media content according to the historical play record of the streaming media content within a preset historical period; determining the play popularity of the streaming media content according to the statistical information on the single play duration of the streaming media content.
[0058] In this embodiment, the server 120 counts the single-play duration of the streaming media content, and obtains the statistical information of the single-play duration according to the historical play records of the streaming media content within a preset historical period. Among them, the single-play duration refers to the duration of the streaming media content being played each time within the aforementioned preset historical period. Exemplarily, if a user views the streaming media content and closes it after the streaming media content has been played for a seconds, then a seconds is the single-play duration for this time. The statistical information of the single-play duration includes the single-play duration corresponding to each play of the streaming media content within the aforementioned preset historical period. Then, the server 120 determines its play popularity according to the statistical information of the single-play duration of the streaming media content. As an implementation manner, the server 120 can take the average value of the single-play durations corresponding to each play according to the statistical information of the single-play duration of the streaming media content to obtain the average single-play duration, and determine the play popularity of the streaming media content according to the ratio of the average single-play duration to the total play duration of the streaming media content itself. Exemplarily, when the play duration ratio does not reach the first ratio threshold, its play popularity can be determined to be a low popularity level; when the play duration ratio reaches the first ratio threshold but does not reach the second ratio threshold, its play popularity can be determined to be a medium popularity level; when the play duration ratio reaches the second ratio threshold, its play popularity can be determined to be a high popularity level.
[0059] The solution of this embodiment can more accurately determine the play popularity of the streaming media content according to the statistical information of the single-play duration of the streaming media content within a preset historical period, and provide a reasonable reference for its target parsing duration.
[0060] For obtaining the play popularity of the streaming media content in step S401, in some other embodiments, the following steps may be included:
[0061] If the historical play record of the streaming media content does not meet the statistical duration condition, then according to the label information of the streaming media content, the target streaming media content is determined from the streaming media content library; according to the play popularity of the target streaming media content, the play popularity of the streaming media content is determined.
[0062] As described in the above embodiments, the statistical duration condition is whether the streaming content has historical play records in a recent period such as the past week or the past two weeks. If the historical play record of the streaming content does not meet the statistical duration condition, it means that the streaming content does not have historical play records in the recent period. Such streaming content can be referred to as newly released streaming content in the near future. For such streaming content, the server 120 can obtain the tag information of the streaming content, which may include the content tag, publisher tag, etc. of the streaming content. The content tag can be used to indicate what type of content the streaming content is, such as popular, classical, etc. The publisher tag can be used to indicate which entity publishes the streaming content, such as Zhang San, Li Si, etc. Then, the server 120 matches according to the tag information of the streaming content in the streaming content library to determine the target streaming content. Among them, the target streaming content refers to the streaming content in the streaming content library that matches the tag information of the streaming content and whose play popularity has been determined. Specifically, the server 120 can query in the streaming content library for the streaming content whose tag information is completely or partially consistent with the tag information of the streaming content as the matching candidate target streaming content. If the play popularity of the candidate target streaming content has been determined, it can be further determined as the target streaming content. Among them, the determination of the play popularity of the candidate target streaming content can be carried out by referring to the method described in the foregoing embodiments. Then, the server 120 determines the play popularity of the streaming content according to the play popularity of the target streaming content. As an implementation manner, the server 120 can directly set the play popularity of the streaming content to the play popularity of the target streaming content. That is, for the newly released streaming content in the near future, in this embodiment, by using its tag information to query in the streaming content library for the similar or so-called same-kind streaming content whose play popularity has been determined, the play popularity of the newly released streaming content in the near future can be accurately and efficiently determined.
[0063] Further, in one embodiment, the determining the play popularity of the streaming content according to the play popularity of the target streaming content in the above embodiments may specifically include:
[0064] When the number of target streaming contents is multiple, the play popularity of the streaming content is obtained according to the average value of the play popularities of the preset number of target streaming contents with the highest matching degree with the tag information.
[0065] Specifically, when the number of target streaming media contents is one, the server 120 can directly use the playback popularity of the target streaming media content as the playback popularity of the streaming media content. When the number of target streaming media contents is multiple, the server 120 can perform a matching degree sorting on these target streaming media contents, select a preset number (such as 3) of target streaming media contents with the highest matching degree with the tag information, obtain the playback popularity of each of the preset number of target streaming media contents and calculate the corresponding playback popularity average value based on this, and use the playback popularity average value as the playback popularity of the streaming media content.
[0066] In one embodiment, determining the corresponding parsing duration ratio according to the playback popularity in the above step S402 specifically includes:
[0067] Determine the popularity level to which the playback popularity belongs; based on the preset popularity level - duration ratio correspondence, determine the parsing duration ratio corresponding to the popularity level to which the playback popularity belongs from multiple optional parsing duration ratios.
[0068] This embodiment can be used as an implementation method for determining the parsing duration ratio. After the server 120 obtains the playback popularity of the streaming media content, it determines the popularity level to which the playback popularity belongs. Exemplarily, the popularity level to which the playback popularity belongs can be a low popularity level, a medium popularity level, or a high popularity level. The server 120 can also preset the popularity level - duration ratio correspondence, such as the low popularity level corresponding to the parsing duration ratio of 0.1, the medium popularity level corresponding to the parsing duration ratio of 0.5, and the high popularity level corresponding to the parsing duration ratio of 1, etc. Thus, after the server 120 determines the popularity level to which the playback popularity belongs, it can determine the parsing duration ratio corresponding to the belonging popularity level from multiple optional parsing duration ratios (such as 0.1, 0.5, and 1) based on this preset popularity level - duration ratio correspondence.
[0069] In one embodiment, a streaming media playback method is provided, and this method can be executed by the terminal 110 as shown in Figure 1 shown, as shown in Figure 5 shown, this method can include the following steps:
[0070] Step S501, obtain the streaming media data corresponding to the streaming media content to be played from the server.
[0071] In this step, when the user requests to play a streaming media content on the terminal 110, the terminal 110 can use the streaming media content as the streaming media content to be played and obtain the streaming media data corresponding to the streaming media content to be played from the server 120. Among them, the streaming media data can include the pre - parsed front - end streaming media data and the post - end streaming media data to be parsed; the streaming media data can be specifically obtained by the server 120 according to the method described in any of the above embodiments.
[0072] Exemplarily, the streaming media data obtained by the terminal 110 from the server 120 may include the front - segment streaming media data corresponding to the raw stream compressed by h264 and the back - segment streaming media data corresponding to mp4.
[0073] Step S502: Play the front - segment streaming media content corresponding to the front - segment streaming media data, and parse the back - segment streaming media data to obtain the back - segment streaming media content.
[0074] In this step, the terminal 110 directly plays the front - segment streaming media content corresponding to the front - segment streaming media data. At the same time, the terminal 110 synchronously parses the back - segment streaming media data to obtain the back - segment streaming media content.
[0075] Step S503: Apply the back - segment streaming media content to the continuous play of the front - segment streaming media content.
[0076] Specifically, after the front - segment streaming media content is played, the terminal 110 can continue to play the parsed back - segment streaming media content.
[0077] As an application example, as Figure 6 shown, the server 120 first obtains the original streaming media data corresponding to the streaming media content, such as the streaming media data in mp4 format corresponding to the streaming media content. Then the server 120 parses the first second of the original streaming media data according to the agreed - upon format (raw stream compressed by h264) on the application A on the terminal 110 and generates the data corresponding to this agreed - upon format as the pre - parsed front - segment streaming media data. Then, based on this pre - parsed front - segment streaming media data (agreed - upon format) and the back - segment streaming media data to be parsed (mp4 format), the reconstructed streaming media data is obtained. Based on this, when the application A on the terminal 110 requests to play this streaming media content, the terminal 110 obtains this reconstructed streaming media data. Then, the terminal 110 plays the front - segment streaming media content corresponding to the front - segment streaming media data therein. At the same time, the terminal 110 concurrently parses the back - segment streaming media data therein to obtain the back - segment streaming media content, and after the front - segment streaming media content is played, continues to play this back - segment streaming media content.
[0078] The solution of this embodiment reconstructs the original streaming media data corresponding to the streaming media content. The front - segment data of the reconstructed streaming media data has been pre - parsed. When the terminal plays this streaming media content, the parsing time of the front - segment streaming media data can be saved and the corresponding front - segment streaming media content can be directly played, and the back - segment streaming media data is concurrently parsed to obtain the back - segment streaming media content for the continuous play of the front - segment streaming media content, thereby improving the play efficiency of the streaming media content.
[0079] It should be understood that although the steps in the flowcharts involved in the above-described embodiments are shown in sequence according to the indications of the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless there is a clear indication in this article, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, at least some of the steps in the flowcharts involved in the above-described embodiments may include multiple steps or multiple stages. These steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be executed alternately or in turn with at least some of the steps or stages in other steps or other steps.
[0080] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as Figure 7 shown. The computer device includes a processor, a memory, and a network interface connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store streaming media data. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, it implements a method for processing streaming media data.
[0081] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as Figure 8 shown. The computer device includes a processor, a memory, a communication interface, a display screen, and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner. The wireless manner can be implemented through WIFI, a mobile cellular network, NFC (Near Field Communication), or other technologies. When the computer program is executed by the processor, it implements a method for playing streaming media. The display screen of the computer device may be a liquid crystal display screen or an electronic ink display screen. The input device of the computer device may be a touch layer covering the display screen, or a button, a trackball, or a touchpad provided on the housing of the computer device, or an external keyboard, a touchpad, or a mouse, etc.
[0082] Those skilled in the art can understand that Figure 7 and Figure 8 the structures shown in are only block diagrams of some of the structures related to the solution of this application, and do not constitute a limitation on the computer device to which the solution of this application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine some components, or have a different component layout.
[0083] In one embodiment, a computer device is further provided, including a memory and a processor. A computer program is stored in the memory, and when the processor executes the computer program, the steps in the above method embodiments are implemented.
[0084] In one embodiment, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.
[0085] Those of ordinary skill in the art can understand that all or part of the processes of implementing the methods in the above embodiments can be completed by instructing relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above methods. Among them, any reference to a memory, database, or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memories. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM), etc. The databases involved in the embodiments provided in the present application can include at least one of relational databases and non-relational databases. Non-relational databases can include distributed databases based on blockchain, etc., without limitation. The processors involved in the embodiments provided in the present application can be general-purpose processors, central processors, graphics processors, digital signal processors, programmable logic devices, data processing logics based on quantum computing, etc., without limitation.
[0086] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data for analysis, stored data, displayed data, etc.) involved in the present application are all information and data that have been authorized by the user or fully authorized by all parties.
[0087] The technical features of the above embodiments can be combined arbitrarily. For the sake of brevity of description, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, it should be considered as the scope recorded in this specification.
[0088] The above-described embodiments merely represent several implementation manners of the present application. The description thereof is relatively specific and detailed, but it should not be construed as a limitation on the patent scope of the present application. It should be noted that for those of ordinary skill in the art, without departing from the concept of the present application, several variations and improvements can still be made, and these all fall within the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the appended claims.
Claims
1. A method for processing streaming media data, characterized in that, Applied to a server, the method includes: Obtain the original streaming media data corresponding to the streaming media content; the original streaming media data can be parsed by the server and the terminal; If the streaming media content has a historical play record within a preset historical period, determine the play popularity of the streaming media content according to the historical play record of the streaming media content within the preset historical period; If the streaming media content does not have a historical play record within a preset historical period, determine the target streaming media content from the streaming media content library according to the tag information of the streaming media content, and determine the play popularity of the streaming media content according to the play popularity of the target streaming media content; the target streaming media content is the streaming media content in the streaming media content library that matches the tag information and whose play popularity has been determined; Determine the corresponding parsing duration ratio according to the play popularity; the parsing duration ratio increases as the heat level of the play popularity rises; Obtain the target parsing duration of the streaming media content according to the preset parsing duration threshold and the parsing duration ratio; Parse the pre-parsing front-end streaming media data corresponding to the target parsing duration in the original streaming media data to obtain the pre-parsed front-end streaming media data that allows the terminal to directly play; Obtain the streaming media data corresponding to the streaming media content sent to the terminal according to the pre-parsed front-end streaming media data and the back-end streaming media data to be parsed by the terminal in the original streaming media data; the streaming media data includes the pre-parsed front-end streaming media data and the back-end streaming media data to be parsed by the terminal, and the duration of the back-end streaming media data parsed by the terminal is negatively correlated with the play popularity.
2. The method according to claim 1, wherein The original streaming media data is the streaming media data in the original data format in the streaming media content library.
3. The method according to claim 1, wherein The determining the play popularity of the streaming media content according to the historical play record of the streaming media content within a preset historical period includes: Obtain the statistical information of the single play duration of the streaming media content according to the historical play record of the streaming media content within a preset historical period; Determine the play popularity of the streaming media content according to the statistical information of the single play duration of the streaming media content.
4. The method according to claim 1, wherein The play popularity of the target streaming media content is determined according to the historical play record of the target streaming media content within a preset historical period.
5. The method according to claim 1, characterized in that, The determining the play popularity of the streaming media content according to the play popularity of the target streaming media content includes: When the number of the target streaming media content is multiple, obtain the play popularity of the streaming media content according to the average value of the play popularity of the preset number of target streaming media content with the highest matching degree with the tag information.
6. The method according to any one of claims 1 to 5, characterized in that, The determining the corresponding parsing duration ratio according to the play popularity includes: Determine the heat level to which the play popularity belongs; Based on the preset heat level - duration ratio correspondence, determine the parsing duration ratio corresponding to the heat level to which the play popularity belongs from multiple optional parsing duration ratios.
7. A streaming media playing method, characterized in that, Applied to a terminal, the method includes: Obtain the streaming media data corresponding to the streaming media content to be played from the server; the streaming media data includes pre-parsed front-segment streaming media data and post-segment streaming media data to be parsed; the streaming media data is obtained according to the method described in any one of claims 1 to 6; Play the front-segment streaming media content corresponding to the front-segment streaming media data, and parse the post-segment streaming media data to obtain the post-segment streaming media content; Apply the post-segment streaming media content to the continuous playback of the front-segment streaming media content.
8. A computer device, comprising a memory and a processor, the memory storing a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method described in any one of claims 1 to 6 or 7.
9. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the steps of the method described in any one of claims 1 to 6 or 7.
Citation Information
Patent Citations
Multimedia data processing method and device, computer device and storage medium
CN110740374A
Video playing method and system, electronic equipment and storage medium
CN114071241A
Method and system for streaming a media file during a concurrent transcoding thereof
US20190208241A1