Media file playing method, system, device, storage medium and processor
Technical Field
The present invention relates to the field of computers, and in particular, to a method, a system, an apparatus, a storage medium, and a processor for playing a media file.
Background
At present, when playing a media file, a unified playing control is usually called, and a unified playing parameter is used to play the media file.
Because the playing control is preset and the playing parameters are fixed, the playing segments in the media file cannot be well displayed according to the requirements of the playing scene, for example, low-level and high-grey pictures in some video files and heavy-low tone parts in some audio files cannot be played normally, or the playing is weakened, especially when the playing effect of the media file has higher enhancement requirements in the corresponding playing scene, the playing effect of the media file cannot be well realized, and thus the technical problem that the playing effect of the media file cannot adapt to the scene requirements exists.
Aiming at the technical problem that the playing effect of the media file in the prior art is difficult to adapt to the scene requirement, an effective solution is not provided at present.
Disclosure of Invention
The invention mainly aims to provide a method, a system, a device, a storage medium and a processor for playing a media file, so as to at least solve the technical problem that the playing effect of the media file is difficult to adapt to the scene requirement.
In order to achieve the above object, according to one aspect of the present invention, there is provided a method of playing a media file. The method can comprise the following steps: acquiring media information of a target media file; identifying the type of a target playing scene applicable to the target media file based on the media information; acquiring a target playing enhancement parameter corresponding to the type of a target playing scene, wherein the target playing enhancement parameter is used for enhancing the playing effect of a target media file in the target playing scene; and playing the target media file according to the target playing enhancement parameters.
Optionally, identifying the type of the target playback scene to which the target media file is applicable based on the media information includes: sending the media information to a server; and acquiring a target label determined by the server based on the media information, and classifying the target media file through the target label to obtain the type of the target playing scene.
Optionally, identifying the type of the target playback scene to which the target media file is applicable based on the media information includes: sending the media information to a server; and acquiring the type of the target playing scene determined by the server based on the media information.
Optionally, the obtaining of the target playing enhancement parameter corresponding to the type of the target playing scene includes: and searching the target playing enhancement parameters from a first database according to the types of the target playing scenes, wherein the first database stores the playing enhancement parameters respectively corresponding to the types of the plurality of playing scenes in advance.
Optionally, the obtaining of the target playing enhancement parameter corresponding to the type of the target playing scene includes: and acquiring a target playing enhancement parameter determined by the server based on the type of the target playing scene.
Optionally, playing the target media file according to the target playing enhancement parameter includes: determining a corresponding playing position of the target playing enhancement parameter in the target media file; replacing the original playing parameters corresponding to the playing positions with target playing enhancement parameters; and when the target media file is played to the playing position, playing through the target playing enhancement parameter.
Optionally, playing the target media file according to the target playing enhancement parameter includes: determining a corresponding playing position of the target playing enhancement parameter in the target media file; adjusting the original playing parameters corresponding to the playing positions through the target playing enhancement parameters to obtain adjusted playing parameters; and when the target media file is played to the playing position, the target media file is played by adjusting the playing parameters.
Optionally, the obtaining of the media information of the target media file includes at least one of: acquiring audio waveform information of an audio media file; and acquiring video picture information of the video media file.
In order to achieve the above object, according to another aspect of the present invention, a method for playing a media file is also provided. The method can comprise the following steps: acquiring media information of a target media file; identifying the type of a target playing scene applicable to the target media file based on the media information; and acquiring a target playing enhancement parameter corresponding to the type of the target playing scene, and issuing the target playing enhancement parameter to the player, wherein the target playing enhancement parameter is used for enhancing the playing effect of the player for playing the target media file in the target playing scene.
Optionally, the obtaining of the target playing enhancement parameter corresponding to the type of the target playing scene includes: and searching the target playing enhancement parameters from a second database according to the types of the target playing scenes, wherein the second database stores the playing enhancement parameters respectively corresponding to the types of the plurality of playing scenes in advance.
Optionally, the obtaining the media information of the target media file includes: and acquiring media information obtained by analyzing the target media file by the player.
Optionally, the obtaining of the media information of the target media file includes at least one of: acquiring audio waveform information of a target audio media file; and acquiring video picture information of the target video media file.
In order to achieve the above object, according to another aspect of the present invention, another method for playing a media file is also provided. The method can comprise the following steps: displaying the media information of the target media file on the interactive interface; displaying the type of a target playing scene applicable to the target media file on an interactive interface, wherein the type of the target playing scene is obtained based on media information identification; and playing the target media file according to the target playing enhancement parameters corresponding to the type of the target playing scene, wherein the target playing enhancement parameters are used for enhancing the playing effect of the target media file in the target playing scene.
In order to achieve the above object, according to another aspect of the present invention, there is also provided a system for playing a media file. The system may include: the first player is used for sending the media information of the target media file; the first server is used for acquiring the media information and determining a target label based on the media information; the first player is used for obtaining a target label and classifying the target media file through the target label to obtain the type of a target playing scene applicable to the target media file; acquiring a target playing enhancement parameter corresponding to the type of a target playing scene, wherein the target playing enhancement parameter is used for enhancing the playing effect of a target media file in the target playing scene; and playing the target media file according to the target playing enhancement parameters.
To achieve the above object, according to another aspect of the present invention, another media file playing system is provided. The system may include: the second player is used for sending the media information of the target media file; the second server is used for acquiring the media information, identifying the type of a target playing scene applicable to the target media file based on the media information, and sending a target playing enhancement parameter corresponding to the type of the target playing scene to the second player, wherein the target playing enhancement parameter is used for enhancing the playing effect of the target media file in the target playing scene; and the second player is used for playing the target media file according to the target playing enhancement parameter.
In order to achieve the above object, according to another aspect of the present invention, there is also provided a playing apparatus of a media file. The apparatus may include: a first obtaining unit, configured to obtain media information of a target media file; the first identification unit is used for identifying the type of a target playing scene applicable to the target media file based on the media information; the second acquisition unit is used for acquiring a target playing enhancement parameter corresponding to the type of the target playing scene, wherein the target playing enhancement parameter is used for enhancing the playing effect of the target media file in the target playing scene; and the playing unit is used for playing the target media file according to the target playing enhancement parameter.
In order to achieve the above object, according to another aspect of the present invention, there is provided another media file playing apparatus. The apparatus may include: a third obtaining unit, configured to obtain media information of the target media file; the second identification unit is used for identifying the type of a target playing scene applicable to the target media file based on the media information; and the fourth obtaining unit is used for obtaining a target playing enhancement parameter corresponding to the type of the target playing scene and sending the target playing enhancement parameter to the player, wherein the target playing enhancement parameter is used for enhancing the playing effect of the player for playing the target media file in the target playing scene.
In order to achieve the above object, according to another aspect of the present invention, there is provided another media file playing apparatus. The apparatus may include: the first display unit is used for displaying the media information of the target media file on the interactive interface; the second display unit is used for displaying the type of a target playing scene applicable to the target media file on the interactive interface, wherein the type of the target playing scene is obtained based on media information identification; and the playing unit is used for playing the target media file according to the target playing enhancement parameter corresponding to the type of the target playing scene, wherein the target playing enhancement parameter is used for enhancing the playing effect of the target media file in the target playing scene.
In order to achieve the above object, according to another aspect of the present invention, there is also provided a storage medium. The storage medium includes a stored program, wherein when the program is executed by the processor, the apparatus where the storage medium is located is controlled to execute the method for playing the media file according to the embodiment of the present invention.
To achieve the above object, according to another aspect of the present invention, there is also provided a processor. The processor is used for running the program, wherein the program executes the playing method of the media file in the embodiment of the invention when running.
In the method for playing a media file in this embodiment, media information of a target media file is obtained; identifying the type of a target playing scene applicable to the target media file based on the media information; acquiring a target playing enhancement parameter corresponding to the type of a target playing scene, wherein the target playing enhancement parameter is used for enhancing the playing effect of a target media file in the target playing scene; and playing the target media file according to the target playing enhancement parameters. That is to say, the target playing enhancement parameter corresponding to the type of the target playing scene suitable for the target media file is obtained, and the target media file is played through the target playing enhancement parameter, so that the playing effect of the target media file is enhanced, the situation that the media file cannot be well shown according to the requirement of the playing scene is avoided, the technical problem that the playing effect of the media file is difficult to adapt to the requirement of the scene is solved, and the technical effect that the playing effect of the media file can adapt to the requirement of the scene is achieved.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this application, illustrate embodiments of the invention and, together with the description, serve to explain the invention and not to limit the invention. In the drawings:
fig. 1 is a flowchart of a method for playing a media file according to an embodiment of the present invention;
FIG. 2 is a flow chart of another method of playing a media file according to an embodiment of the invention;
FIG. 3 is a flowchart of another method for playing a media file according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of a system for playing media files according to an embodiment of the present invention;
FIG. 5 is a schematic diagram of another media file playback system according to an embodiment of the present invention;
FIG. 6 is a diagram of a device for playing media files according to an embodiment of the present invention;
FIG. 7 is a schematic diagram of another media file playback device according to an embodiment of the present invention; and
fig. 8 is a schematic diagram of another media file playing apparatus according to an embodiment of the present invention.
Detailed Description
It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict. The present invention will be described in detail below with reference to the embodiments with reference to the attached drawings.
In order to make the technical solutions better understood by those skilled in the art, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only partial embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and claims of this application and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It should be understood that the data so used may be interchanged under appropriate circumstances such that embodiments of the application described herein may be used. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Example 1
The invention provides a method for playing a media file. The following describes a method for playing a media file according to an embodiment of the present invention from a player side.
Fig. 1 is a flowchart of a method for playing a media file according to an embodiment of the present invention. As shown in fig. 1, the method may include the steps of:
step S102, media information of the target media file is obtained.
In the technical solution provided by step S102 of the present invention, a system in which the player is located may obtain media information of a target media file, where the target media file may include a target audio file, a target video file, or a target audio file and a target video file that are played simultaneously. The display of the player may be a small-distance display screen of Light Emitting Diodes (LEDs), which is not limited herein.
In this embodiment, obtaining the media information of the target media file includes at least one of: acquiring audio waveform information of a target audio media file; and acquiring video picture information of the target video media file.
The embodiment acquires the media information of the target media file, and can read and analyze the target media file to obtain media information, for example, the media information is audio waveform information, video picture information, and a key frame in a unit time period selected by analyzing a video picture.
And step S104, identifying the type of the target playing scene applicable to the target media file based on the media information.
In the technical solution provided by step S104 of the present invention, after the media information of the target media file is obtained, the player identifies the type of the target playing scene to which the target media file is applicable based on the media information.
In this embodiment, the media information may be used to determine the type of target playback scene to which the target media file is applicable, wherein the type of target playback scene may include, but is not limited to, scenes such as a opera house, Live broadcast (Live), concert, bar, street, home, and the like. The player of this embodiment can analyze the target media file based on the media information, thereby determining the type of the target playing scene to which the target media file is applicable, that is, classifying the playing scene of the target media file.
Step S106, obtaining the target playing enhancement parameter corresponding to the type of the target playing scene.
In the technical solution provided in step S106 of the present invention, after the player identifies the type of the target playing scene applicable to the target media file based on the media information, the player obtains a target playing enhancement parameter corresponding to the type of the target playing scene, where the target playing enhancement parameter is used to enhance the playing effect of the target media file in the target playing scene.
In this embodiment, different types of target playback scenes may correspond to different target playback enhancement parameters, and the playback effect of the target media file in the target playback scene is enhanced by the target playback enhancement parameters to achieve the playback enhancement effect in the different target playback scenes, where the playback enhancement parameters may be parameters that are adjusted for brightness, contrast, sound, and the like, and the playback enhancement effect may be an enhancement effect of a picture and a sound channel.
The embodiment can store the playing enhancement parameters corresponding to different playing scene types locally in advance, so as to be used as playing enhancement parameters for selecting the target playing enhancement parameters corresponding to the types of the target playing scenes; the embodiment can also acquire the target playing parameters corresponding to the type of the target scene from the cloud server.
And step S108, playing the target media file according to the target playing enhancement parameter.
In the technical solution provided in step S108 of the present invention, after the player obtains the target playing enhancement parameter corresponding to the type of the target playing scene, the target media file can be played according to the target playing enhancement parameter.
In this embodiment, the target playing enhancement parameter is a part of parameters in all parameters for playing the target media file, and when the target media file is played to a playing segment that needs to be enhanced to be played, the target playing parameter can be called to play the target media file, so that the playing segment of the part is well shown, for example, a low-level and high-grey picture in the target video file and heavy low-level and low-level sound parts in some target audio files can be normally played, thereby avoiding the situation of playing weakening, and achieving the technical effect that the playing effect of the media file adapts to the scene requirements; and when the target media file is played to a segment which does not need to be enhanced, the normal playing parameters of the target media file can be called to play the target media file.
Optionally, for an all-in-one machine that plays the audio/video file for the first time but is not networked, the corresponding playing parameters may be set according to the type of the playing scene of the all-in-one machine for storage, and subsequently, when the audio/video media file of the same type of playing scene is played, the corresponding playing parameters may be directly called to perform enhanced playing on the audio/video media file, so as to achieve a technical effect of adapting the playing effect of the video media file to the requirement of the playing scene.
The above-described method of this embodiment is further described below.
As an alternative implementation, the step S104, identifying the type of the target playing scene to which the target media file is applicable based on the media information includes: sending the media information to a server; and acquiring a target label determined by the server based on the media information, and classifying the target media file through the target label to obtain the type of the target playing scene.
In this embodiment, when the type of the target playing scene applicable to the target media file is identified based on the media information, the media information may be sent to a server, where the server is also a cloud server, the media information may be an audio waveform read from the target audio file or a key frame in a unit time period obtained by analyzing a video picture of the target video file, and the audio waveform or the key frame in the unit time period may be uploaded to the server. After the server obtains the media information, the server may further analyze the media information to obtain an analysis result, and compare the analysis result with analysis results of the media information of the plurality of media files stored in the database of the server to search for a media file corresponding to the target media file in the database of the server, where a similarity between the analysis result of the searched media file and the analysis result of the target media file may be higher than a target threshold, so as to determine the tag of the searched media file as the target tag. The player can obtain the target label issued by the server, and records and permanently records the target label, so that when the player plays the target media file, the target media file can be classified according to the target label, and the type of the target playing scene of the target media file is obtained.
For example, the analysis result is an audio analysis result obtained by analyzing an audio waveform of the target audio file, the database of the server is a network song library, the audio analysis result is compared with audio analysis results of a plurality of audio files in the network song library to search for an audio file corresponding to the target audio file in the network song library, and the similarity between the analysis result of the searched audio file and the analysis result of the target audio file is higher than a target threshold value, so that the label of the searched audio file is determined to be the target label. The player can obtain the target label issued by the server, and records and permanently records the target label, so that when the player plays the target audio file, the target audio file can be classified according to the target label, and the type of the target playing scene of the target audio file is obtained.
As an alternative implementation, the step S104, identifying the type of the target playing scene to which the target media file is applicable based on the media information includes: sending the media information to a server; and acquiring the type of the target playing scene determined by the server based on the media information.
In this embodiment, when the type of the target playback scene to which the target media file is applicable is identified based on the media information, the media information of the target media file may be sent to the server first. After the server obtains the media information of the target media file, the server may determine the type of the target playing scene based on the media information of the target media file, for example, the server analyzes the media information of the target media file, may determine whether the media information of the target media file conforms to the media information corresponding to the type of the target playing scene, and if it is determined that the media information of the target media file conforms to the media information corresponding to the type of the target playing scene, may determine that the type of the playing scene of the target media file is the type of the target playing scene. After the server determines the type of the target playing scene of the target media file, the player may obtain the type of the target playing scene sent by the server.
As an optional implementation manner, in step S106, the obtaining of the target playing enhancement parameter corresponding to the type of the target playing scene includes: and searching the target playing enhancement parameters from a first database according to the types of the target playing scenes, wherein the first database stores the playing enhancement parameters respectively corresponding to the types of the plurality of playing scenes in advance.
In this embodiment, the player locally has a first database, that is, a local database, in which play enhancement parameters respectively corresponding to the types of the plurality of play scenes are stored in advance. After the player identifies the type of the target playing scene of the target media file based on the media information, the target playing enhancement parameter corresponding to the type of the target playing scene can be searched from the first database, so that when the player plays the target media file, the target media file can be enhanced and played according to the target playing enhancement parameter corresponding to the type of the target playing scene, for example, the target media file is enhanced in picture and sound channel, so that the playing of the target media file is more in line with the atmosphere of the target playing scene, and the technical effect that the playing effect of the media file adapts to the scene requirement of the target media file is achieved.
As an optional implementation manner, in step S106, the obtaining of the target playing enhancement parameter corresponding to the type of the target playing scene includes: and acquiring a target playing enhancement parameter determined by the server based on the type of the target playing scene.
In this embodiment, when obtaining the target playing enhancement parameter corresponding to the type of the target playing scene is implemented, the target playing enhancement parameter may also be determined by the server, except that the player searches from the first database. Optionally, the server may determine the target playing enhancement parameter according to the type of the target playing scene determined by the server or the type of the target playing scene determined by the target tag sent by the player, and then the server issues the determined target playing enhancement parameter to the player, and the player may obtain the target playing enhancement parameter issued by the server, and then play the target media file according to the target playing enhancement parameter, so as to enhance the playing effect of the target media file in the target playing scene, thereby achieving the technical effect that the playing effect of the media file adapts to the scene requirements thereof.
As an optional implementation manner, in step S108, playing the target media file according to the target playing enhancement parameter includes: determining a corresponding playing position of the target playing enhancement parameter in the target media file; replacing the original playing parameters corresponding to the playing positions with target playing enhancement parameters; and when the target media file is played to the playing position, playing through the target playing enhancement parameter.
In this embodiment, when the target media file is played according to the target playing enhancement parameter, a playing position corresponding to the target playing enhancement parameter in the target media file may be determined, where the playing position is also a playing segment that needs to be played and enhanced through the target playing enhancement parameter in the target media file, for example, a playing segment corresponding to a low-volume high-grey picture in the target video file, and a playing segment of a heavy low-volume sound part in the target audio file. After determining the playing position of the target playing enhancement parameter corresponding to the target media file, the original playing parameter corresponding to the playing position may be obtained, optionally, the target playing enhancement parameter of this embodiment may be all playing parameters required when the target media file is enhanced to be played at the playing position, the original playing parameter may be replaced with the target playing enhancement parameter, and then when the target media file is played to the playing position, the target media file may be directly played through the target playing enhancement parameter, so as to enhance the playing effect of the target media file in the target playing scene, thereby achieving the technical effect that the playing effect of the media file adapts to the scene requirements of the target media file.
As an optional implementation manner, in step S108, playing the target media file according to the target playing enhancement parameter includes: determining a corresponding playing position of the target playing enhancement parameter in the target media file; adjusting the original playing parameters corresponding to the playing positions through the target playing enhancement parameters to obtain adjusted playing parameters; and when the target media file is played to the playing position, the target media file is played by adjusting the playing parameters.
In this embodiment, the target playing enhancement parameter may be a parameter for adjusting an original playing parameter corresponding to the playing position, so that when the target media file is played according to the target playing enhancement parameter, a playing position corresponding to the target playing enhancement parameter in the target media file may be determined first, and then the original playing parameter corresponding to the playing position is adjusted by the target playing enhancement parameter, so as to obtain an adjusted playing parameter, and the adjusted playing parameter may be used for enhancing playing of the target media file, so that when the target media file is played to the playing position, the target media file may be played by adjusting the playing parameter, so as to enhance a playing effect of the target media file in the target playing scene, thereby achieving a technical effect that the playing effect of the media file adapts to a scene requirement.
In the method for playing a media file in this embodiment, a player obtains media information of a target media file; identifying the type of a target playing scene applicable to the target media file based on the media information; acquiring a target playing enhancement parameter corresponding to the type of a target playing scene, wherein the target playing enhancement parameter is used for enhancing the playing effect of a target media file in the target playing scene; and playing the target media file according to the target playing enhancement parameters. That is to say, the player of the present invention obtains the target playing enhancement parameter corresponding to the type of the target playing scene to which the target media file is applicable, and plays the target media file through the target playing enhancement parameter, thereby enhancing the playing effect thereof, avoiding that the media file cannot be well shown according to the requirement of the playing scene, solving the technical problem that the playing effect of the media file is difficult to adapt to the requirement of the scene thereof, and further achieving the technical effect that the playing effect of the media file can adapt to the requirement of the scene thereof.
The following is a description of a method for playing a media file according to an embodiment of the present invention from a server side.
Fig. 2 is a flowchart of another method for playing a media file according to an embodiment of the present invention. As shown in fig. 2, the method may include the steps of:
step S202, media information of the target media file is obtained.
In the technical solution provided in step S202 of the present invention, the server, that is, the cloud server, may obtain the media information of the target media file sent by the player, where the target media file may include a target audio file and a target video file, and may also include a target audio file and a target video file that are played simultaneously.
In this embodiment, the server obtaining the media information of the target media file includes at least one of: the server acquires audio waveform information of a target audio media file; the server acquires video picture information of the target video media file.
In this embodiment, the server obtains the media information of the target media file, and may obtain that the player reads and parses the target media file to obtain media information, for example, the media information is audio waveform information and video picture information, and a key frame in a unit time period selected by parsing a video picture.
Step S204, identifying the type of the target playing scene suitable for the target media file based on the media information.
In the technical solution provided by step S204 of the present invention, after the server acquires the media information of the target media file, the server identifies the type of the target playback scene to which the target media file is applicable based on the media information.
In this embodiment, the media information may be used to determine the type of target playback scene to which the target media file is applicable, wherein the type of target playback scene may include, but is not limited to, scenes such as a opera house, a live broadcast, a concert, a bar, a street, a family, and the like. The server of this embodiment analyzes the target media file based on the media information, thereby determining the type of the target playback scene to which the target media file is applicable, that is, the server classifies the playback scene of the target media file.
Optionally, the server obtains the media information of the target media file sent by the player. After the server obtains the media information of the target media file, the server may determine the type of the target playing scene based on the media information of the target media file, for example, the server analyzes the media information of the target media file, may determine whether the media information of the target media file conforms to the media information corresponding to the type of the target playing scene, and if the server determines that the media information of the target media file conforms to the media information corresponding to the type of the target playing scene, the type of the playing scene of the target media file may be determined as the type of the target playing scene.
Step S206, obtaining the target playing enhancement parameter corresponding to the type of the target playing scene, and sending the target playing enhancement parameter to the player.
In the technical solution provided in step S206 of the present invention, after the server identifies the type of the target playing scene applicable to the target media file based on the media information, the server obtains the target playing enhancement parameter corresponding to the type of the target playing scene, and sends the target playing enhancement parameter to the player.
In this embodiment, different types of target playback scenes may correspond to different target playback enhancement parameters, and the playback effect of the target media file in the target playback scene is enhanced by the target playback enhancement parameters to achieve the playback enhancement effect in the different target playback scenes, where the playback enhancement parameters may be parameters that are adjusted for brightness, contrast, sound, and the like, and the playback enhancement effect may be an enhancement effect of a picture and a sound channel.
When the server acquires the target playing enhancement parameter corresponding to the type of the target playing scene, the server can determine the target playing enhancement parameter through the type of the target playing scene determined by the server, and then the server issues the determined target playing enhancement parameter to the player, and the player can acquire the target playing enhancement parameter issued by the server, and then play the target media file according to the target playing enhancement parameter, so as to enhance the playing effect of the target media file in the target playing scene, and achieve the technical effect that the playing effect of the media file adapts to the scene requirement.
The above-described method of this embodiment is further described below.
As an optional implementation manner, in step S206, the obtaining of the target playing enhancement parameter corresponding to the type of the target playing scene includes: and searching the target playing enhancement parameters from a second database according to the types of the target playing scenes, wherein the second database stores the playing enhancement parameters respectively corresponding to the types of the plurality of playing scenes in advance.
In this embodiment, the server has a second database in which playback enhancement parameters respectively corresponding to the types of a plurality of playback scenes are stored in advance. After the server identifies the type of the target playing scene of the target media file based on the media information, the server can search the target playing enhancement parameter corresponding to the type of the target playing scene from the second database, and then issue the target playing parameter to the player, so that when the player plays the target media file, the target media file can be enhanced and played according to the target playing enhancement parameter corresponding to the type of the target playing scene, for example, the target media file is enhanced in picture and sound channel, so that the playing of the target media file better conforms to the atmosphere of the target playing scene, and the technical effect that the playing effect of the media file adapts to the scene requirement is achieved.
As an alternative implementation manner, in step S202, the acquiring the media information of the target media file includes: and acquiring media information obtained by analyzing the target media file by the player.
In this embodiment, when acquiring the media information of the target media file, the player may first parse the target media file, for example, the player parses the video picture of the target video file, selects a key frame in a unit time period, uploads the selected key frame to the server, and the server acquires the media information of the target media file uploaded by the player.
In this embodiment, the server obtains media information of a target media file, identifies a type of a target playing scene applicable to the target media file based on the media information, obtains a target playing enhancement parameter corresponding to the type of the target playing scene, and issues the target playing enhancement parameter to the player, where the target playing enhancement parameter is used to enhance a playing effect of the player for playing the target media file in the target playing scene. That is to say, the server of the present invention can obtain the target playing enhancement parameter corresponding to the type of the target playing scene to which the target media file is applicable, and issue the target playing enhancement parameter to the player, so that the player plays the target media file through the target playing enhancement parameter, thereby enhancing the playing effect thereof, avoiding that the media file cannot be well displayed according to the requirement of the playing scene, solving the technical problem that the playing effect of the media file is difficult to adapt to the requirement of the scene, and further achieving the technical effect that the playing effect of the media file can adapt to the requirement of the scene.
The following describes a method for playing a media file according to an embodiment of the present invention from a user interaction side.
Fig. 3 is a flowchart of another method for playing a media file according to an embodiment of the present invention. As shown in fig. 3, the method may include the steps of:
step S302, displaying the media information of the target media file on the interactive interface.
In the technical solution provided by step S302 of the present invention, the media information of the target media file may be displayed on the interactive interface, where the target media file may include a target audio file, a target video file, or a target audio file and a target video file that are played simultaneously.
In this embodiment, the media information of the target media file displayed on the interactive interface includes at least one of: audio waveform information for the target audio media file; video picture information of the target video media file.
The embodiment displays the media information of the target media file on the interactive interface, and can display that the player reads and analyzes the target media file to obtain media information, for example, the media information is audio waveform information and video picture information, and a key frame in a unit time period selected by analyzing a video picture.
Step S304, displaying the type of the target playing scene suitable for the target media file on the interactive interface, wherein the type of the target playing scene is obtained by media information identification.
In the technical solution provided by step S304 of the present invention, after the media information of the target media file is displayed on the interactive interface, the type of the target playing scene applicable to the target media file may be displayed on the interactive interface, where the type of the target playing scene is identified and obtained based on the media information.
In this embodiment, the media information may be used to determine the type of target playback scene to which the target media file is applicable, wherein the type of target playback scene may include, but is not limited to, scenes such as a opera house, a live broadcast, a concert, a bar, a street, a family, and the like. The player of the embodiment can analyze the target media file based on the media information, so as to determine the type of the target playing scene applicable to the target media file, that is, classify the playing scene of the target media file, and further display the type of the target playing scene applicable to the target media file on the interactive interface.
Step S306, playing the target media file according to the target playing enhancement parameter corresponding to the type of the target playing scene.
In the technical solution provided in step S306 of the present invention, after the type of the target playing scene applicable to the target media file is displayed on the interactive interface, the target media file is played according to the target playing enhancement parameter corresponding to the type of the target playing scene.
In this embodiment, the type of the target playing scene may correspond to different target playing enhancement parameters, and the playing effect of the target media file in the target playing scene is enhanced by the target playing enhancement parameters, so as to achieve the playing enhancement effect in different target playing scenes.
The embodiment can store the playing enhancement parameters corresponding to different playing scene types locally in advance, so as to be used as playing enhancement parameters for selecting the target playing enhancement parameters corresponding to the types of the target playing scenes; the embodiment can also acquire the target playing parameters corresponding to the types of the target scenes from the server.
In this embodiment, the target playing enhancement parameter is a part of parameters in all parameters for playing the target media file, and when the target media file is played to a playing segment that needs to be enhanced to be played, the target playing parameter can be called to play the target media file, so that the playing segment of the part is well shown, for example, a low-level and high-grey picture in the target video file and heavy low-level and low-level sound parts in some target audio files can be normally played, thereby avoiding the situation of playing weakening, and achieving the technical effect that the playing effect of the media file adapts to the scene requirements; when the target media file is played to a segment which does not need to be enhanced and played, the normal playing parameters of the target media file can be called to enhance and play the target media file, so that the technical effect of enabling the playing effect of the video media file to adapt to the requirement of the playing scene is achieved.
In this embodiment, media information of the target media file is displayed on the interactive interface; displaying the type of a target playing scene applicable to the target media file on an interactive interface, wherein the type of the target playing scene is obtained based on media information identification; and playing the target media file according to the target playing enhancement parameters corresponding to the type of the target playing scene, wherein the target playing enhancement parameters are used for enhancing the playing effect of the target media file in the target playing scene. That is to say, the invention obtains the target playing enhancement parameter corresponding to the type of the target playing scene suitable for the target media file, and plays the target media file through the target playing enhancement parameter, thereby enhancing the playing effect, avoiding that the media file can not be well shown according to the requirements of the playing scene, solving the technical problem that the playing effect of the media file is difficult to adapt to the requirements of the scene, and further achieving the technical effect that the playing effect of the media file can adapt to the requirements of the scene.
It should be noted that the steps illustrated in the flowcharts of the figures may be performed in a computer system such as a set of computer-executable instructions and that, although a logical order is illustrated in the flowcharts, in some cases, the steps illustrated or described may be performed in an order different than presented herein.
Example 2
The embodiment of the invention also provides a schematic diagram of a media file playing system.
Fig. 4 is a schematic diagram of a system for playing a media file according to an embodiment of the present invention. As shown in fig. 4, the media file playing system 40 may include: a first player 41 and a first server 42.
A first player 41 for transmitting the media information of the target media file.
In this embodiment, the first player 41 may send the media information of the target media file to the first server 42, and may read and parse the target media file to obtain media information, for example, the media information is frequency waveform information, video picture information, and a key frame in a unit time period selected by parsing the video picture, and then send the key frame to the first server 42.
A first server 42 for obtaining media information, and determining a target tag based on the media information; the first player 41 is configured to obtain a target tag, and classify a target media file through the target tag to obtain a type of a target playing scene applicable to the target media file; acquiring a target playing enhancement parameter corresponding to the type of a target playing scene, wherein the target playing enhancement parameter is used for enhancing the playing effect of a target media file in the target playing scene; and playing the target media file according to the target playing enhancement parameters.
In this embodiment, the first server 42 may obtain the media information sent by the first player 41, may further analyze the media information to obtain an analysis result, and compare the analysis result with the analysis results of the media information of the multiple media files stored in the database of the first server 42 to search for a media file corresponding to the target media file in the database of the first server 42, where a similarity between the analysis result of the searched media file and the analysis result of the target media file may be higher than a target threshold, so as to determine the tag of the searched media file as the target tag. The first player 41 may obtain a target tag issued by the first server 42, and record and permanently record the target tag, so that when the player plays the target media file, the player may classify the target media file according to the target tag to obtain a type of a target playing scene of the target media file, further obtain a target playing enhancement parameter corresponding to the type of the target playing scene, and play the target media file according to the target playing enhancement parameter, thereby achieving an object of enhancing a playing effect of the target media file in the target playing scene.
The embodiment of the invention also provides a schematic diagram of another media file playing system.
Fig. 5 is a schematic diagram of another media file playing system according to an embodiment of the present invention. As shown in fig. 5, the system 50 for playing the media file may include: a second player 51 and a second server 52.
And a second player 51 for transmitting the media information of the target media file.
In this embodiment, the second player 51 may send the media information of the target media file to the second server 52, and may read and parse the target media file to obtain media information, for example, the media information is frequency waveform information and video picture information, and a key frame in a unit time period selected by parsing the video picture, and then send the key frame to the second server 52.
The second server 52 is configured to obtain media information, identify a type of a target playing scene applicable to the target media file based on the media information, and send a target playing enhancement parameter corresponding to the type of the target playing scene to the second player 51, where the target playing enhancement parameter is used to enhance a playing effect of the target media file in the target playing scene; wherein the second player 51 is configured to play the target media file according to the target playing enhancement parameter.
In this embodiment, after the second server 52 acquires the media information of the target media file, the second server 52 may determine the type of the target playing scene based on the media information of the target media file, for example, the second server 52 analyzes the media information of the target media file, and may determine whether the media information of the target media file conforms to the media information corresponding to the type of the target playing scene, and if the second server 52 determines that the media information of the target media file conforms to the media information corresponding to the type of the target playing scene, the type of the playing scene of the target media file may be determined as the type of the target playing scene.
The second server 52 can determine the target playing enhancement parameter according to the type of the target playing scene determined by itself, and then the second server 52 issues the determined target playing enhancement parameter to the second player 51, and the second player 51 can acquire the target playing enhancement parameter sent by the second server 52, and then play the target media file according to the target playing enhancement parameter, so as to enhance the playing effect of the target media file in the target playing scene, thereby achieving the technical effect that the playing effect of the media file adapts to the scene requirements thereof.
According to the embodiment, the target media file is played through the target playing enhancement parameter corresponding to the type of the target playing scene to which the target media file is applicable, so that the playing effect of the target media file is enhanced, the situation that the media file cannot be well displayed according to the requirement of the playing scene is avoided, the technical problem that the playing effect of the media file is difficult to adapt to the requirement of the scene is solved, and the technical effect that the playing effect of the media file can adapt to the requirement of the scene is achieved.
Example 3
The technical solutions of the embodiments of the present invention will be illustrated below with reference to preferred embodiments.
When the current device comprising the LED small-spacing display screen plays audio and video, a unified audio and video playing control is called, and an audio and video file is played by using a unified audio and video playing parameter, so that playing enhancement is not performed according to habits of users in different playing scenes.
Therefore, playing segments in some media files cannot be well displayed, for example, a low-level and high-grayscale picture in a video file and an audio file cannot be normally played according to a low-level and high-level audio part in the video file, or playing is weakened, and particularly when an object using the product has a high requirement for enhancing the playing effect of the audio and video, the current technical scheme cannot meet the requirement.
And the embodiment realizes the scene mode function based on the LED small-distance display screen.
The following describes a method of playing an audio file according to this embodiment.
In this embodiment, the media file playing system may pre-read the audio waveform of the first audio file, and upload the read audio waveform to the cloud server, the cloud server analyzes the audio waveform to obtain an analysis result, and compares the analysis result with the analysis results of the audio waveforms corresponding to the multiple audio files in the network song library, so as to find a corresponding second audio file in the multiple audio files, where the similarity between the second audio file and the first audio file is higher than a target threshold, obtain the tag of the second audio file, and send the tag of the second audio file to the local player, where the local player determines the tag of the second audio file as the tag of the first audio file, and permanently records the tag of the first audio file, so that when the local player plays the first audio file, the playing scenes of the first audio file can be classified according to the labels to obtain a classification result, wherein each type of audio file corresponds to different playing parameters, and each type of audio file corresponds to different playing parameters and can be stored in a database of the local player in advance. Therefore, the playing parameters corresponding to the playing scenes can be obtained according to the classification result, and the playing effect of the first audio file in the playing scenes can be enhanced through the playing parameters. Wherein, this broadcast effect can be broadcast scenes such as the opera house effect of building, Live (Live), concert, bar, street to avoided the unable normal broadcast of heavy bass sound portion in some audio files, perhaps had the condition of weakening broadcast, and then reached the technological effect who makes the broadcast effect of audio files adapt to its demand of broadcast scene.
The following describes a playing method of a video file according to this embodiment.
In this embodiment, the playing system of the media file can parse the video frame of the video file, select the key frame in the unit time period from the video file, uploading the selected key frames in the unit time period to a cloud server, classifying the playing scene of the video file by the cloud server according to the key frames in the unit time period to obtain a classification result, returning the classification result of the playing scene of the video file to the local server by the cloud server, then the local player obtains corresponding playing parameters according to the classification result, so that the picture and sound track enhancement can be carried out on the video file through the obtained playing parameters when the video file of the type is played, thereby creating playing scenes of cinema, family, outdoor and the like, avoiding the condition that some video files have low-level and high-grey pictures, and further, the technical effect that the playing effect of the video media file is adapted to the requirement of the playing scene is achieved.
In the embodiment, for an all-in-one machine which plays audio and video files for the first time but is not networked, corresponding playing parameters can be set according to the type of the playing scene of the all-in-one machine for storage, and then when the audio and video media files of the same type of playing scene are played, the corresponding playing parameters can be directly called to perform enhanced playing on the audio and video media files, so that the technical effect that the playing effect of the video media files meets the requirement of the playing scene is achieved.
Example 4
The embodiment of the invention also provides a device for playing the media file. It should be noted that the playing apparatus of the media file of this embodiment can be used to execute the playing method of the media file of the embodiment shown in fig. 1.
Fig. 6 is a schematic diagram of a device for playing a media file according to an embodiment of the present invention. As shown in fig. 6, the playing device 60 for the media file may include: a first acquisition unit 61, a first recognition unit 62, a second acquisition unit 63, and a playback unit 64.
A first obtaining unit 61, configured to obtain media information of a target media file.
A first identifying unit 62, configured to identify a type of a target playback scene to which the target media file is applicable based on the media information.
A second obtaining unit 63, configured to obtain a target playing enhancement parameter corresponding to the type of the target playing scene, where the target playing enhancement parameter is used to enhance the playing effect of the target media file in the target playing scene.
And a playing unit 64, configured to play the target media file according to the target playing enhancement parameter.
The embodiment of the invention also provides another media file playing device. It should be noted that the playing apparatus of the media file of this embodiment can be used to execute the playing method of the media file of the embodiment shown in fig. 2.
Fig. 7 is a schematic diagram of another media file playing apparatus according to an embodiment of the present invention. As shown in fig. 7, the playing device 70 for the media file may include: a third acquisition unit 71, a second recognition unit 72 and a fourth acquisition unit 73.
A third obtaining unit 71, configured to obtain media information of the target media file.
A second identifying unit 72, configured to identify a type of a target playback scene to which the target media file is applicable based on the media information.
A fourth obtaining unit 73, configured to obtain a target playing enhancement parameter corresponding to the type of the target playing scene, and send the target playing enhancement parameter to the player, where the target playing enhancement parameter is used to enhance a playing effect of the player for playing the target media file in the target playing scene.
The embodiment of the invention also provides another media file playing device. It should be noted that the playing apparatus of the media file of this embodiment can be used to execute the playing method of the media file of the embodiment shown in fig. 3.
Fig. 8 is a schematic diagram of another media file playing apparatus according to an embodiment of the present invention. As shown in fig. 8, the playing device 80 for the media file may include: a first display unit 81, a second display unit 82, and a playback unit 83.
A first display unit 81 for displaying media information of a target media file on an interactive interface;
the second display unit 82 is configured to display, on the interactive interface, a type of a target playing scene to which the target media file is applicable, where the type of the target playing scene is identified based on the media information;
and the playing unit 83 is configured to play the target media file according to a target playing enhancement parameter corresponding to the type of the target playing scene, where the target playing enhancement parameter is used to enhance a playing effect of the target media file in the target playing scene.
In this embodiment, the target playing enhancement parameter corresponding to the type of the target playing scene to which the target media file is applicable is obtained, and the target media file is played through the target playing enhancement parameter, so that the playing effect of the target media file is enhanced, the situation that the media file cannot be well shown according to the requirement of the playing scene is avoided, the technical problem that the playing effect of the media file is difficult to adapt to the requirement of the scene is solved, and the technical effect that the playing effect of the media file can adapt to the requirement of the scene is achieved.
Example 5
The embodiment of the invention also provides a storage medium. The storage medium includes a stored program, wherein when the program is executed by the processor, the apparatus where the storage medium is located is controlled to execute the method for playing the media file according to the embodiment of the present invention.
Example 6
The embodiment of the invention also provides a processor. The processor is used for running the program, wherein the program executes the playing method of the media file in the embodiment of the invention when running.
It will be apparent to those skilled in the art that the modules or steps of the present invention described above may be implemented by a general purpose computing device, they may be centralized on a single computing device or distributed across a network of multiple computing devices, and they may alternatively be implemented by program code executable by a computing device, such that they may be stored in a storage device and executed by a computing device, or fabricated separately as individual integrated circuit modules, or fabricated as a single integrated circuit module from multiple modules or steps. Thus, the present invention is not limited to any specific combination of hardware and software.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.