Summary of the invention
Embodiment of the present invention technical problem to be solved is, it is provided that the method for a kind of audio frequency broadcasting, Apparatus and system, can automatically carry out volume control.
In order to solve above-mentioned technical problem, the embodiment of the present invention provides a kind of method that audio frequency is play, including:
Obtain the average volume gain information being arranged in audio file, and decode described audio file;
The player output volume that currently described audio file is decoded the audio frequency obtained is adjusted according to described average volume gain information;
According to the player output volume after adjusting, control described audio file is currently decoded the broadcast sound volume of the audio frequency obtained.
Wherein, the average volume gain information that described acquisition is arranged in audio file, and decode described audio file, including:
Download audio file, obtain the file header part of described audio file, and obtain the average volume gain information of the described audio file being preset in described file header part;
Download the voice data of described audio file, and decode the voice data that download obtains.
Wherein, before the average volume gain information that described acquisition is arranged in audio file, also include:
Obtain complete audio file;
Compare with preset standard pronunciation value according to the average volume value in described complete audio file, determine the average volume gain information of described audio file;
Described average volume gain information is arranged described audio file.
Wherein, the average volume gain information that described acquisition is arranged in audio file, including:
Described audio file is downloaded from server;
Obtain the average volume gain information that described server is arranged in described audio file;
Wherein, described server arranges average volume gain information in described audio file and includes: after described server gets the described audio file uploaded, average volume value according to described complete audio file compares with preset standard pronunciation value, determine the average volume gain information of described audio file, described average volume gain information is arranged described audio file.
Wherein, described average volume gain information includes the average volume gain information being preset in the label tag information of described audio file;Or including the average volume gain information being preset in the audio description file for describing described audio file.
Correspondingly, the embodiment of the present invention additionally provides a kind of terminal unit play for audio frequency, including:
Acquisition module, for obtaining the average volume gain information being arranged in audio file, decodes described audio file;
Adjusting module, for adjusting the player output volume that described audio file currently decodes the audio frequency obtained according to described average volume gain information;
Control module, for according to the player output volume after adjusting, controlling currently to decode described audio file the broadcast sound volume of the audio frequency obtained.
Wherein, described acquisition module includes:
Acquiring unit, for obtaining the file header part of described audio file from download audio file, and obtains the average volume gain information of the described audio file being preset in described file header part;
Decoding unit, for decoding the voice data of the described audio file of download.
Wherein, also include:
Memory module, for obtaining complete audio file;
Computing module, for comparing with preset standard pronunciation value according to the average volume value in described complete audio file, determines the average volume gain information of described audio file;
Module is set, for described average volume gain information is arranged described audio file.
Wherein, also include:
Download module, for downloading described audio file from server;
Described acquisition module, specifically for obtaining the average volume gain information that described server is arranged in described audio file;
Wherein, described server arranges average volume gain information in described audio file and includes: after described server gets the described audio file uploaded, compare with preset standard pronunciation value according to the average volume value in described complete audio file, determine the average volume gain information of described audio file, described average volume gain information is arranged described audio file.
Wherein, described module is set, specifically for arranging described average volume gain information in the label tag information of described audio file, or described average volume gain information is set in the audio description file for describing described audio file.
Correspondingly, the embodiment of the present invention additionally provides a kind of server play for audio frequency, including:
Receiver module, for receiving the audio file that user uploads;
Processing module, for after uploading at described audio file, compares with preset standard pronunciation value according to the average volume value of described complete audio file, determines the average volume gain information of described audio file;
Add module, for described average volume gain information is arranged described audio file.
Wherein, described interpolation module, specifically for arranging described average volume gain information in the label tag information of described audio file, or described average volume gain information is set in the audio description file for describing described audio file.
Correspondingly, the embodiment of the present invention additionally provides a kind of system play for audio frequency, including: terminal unit and server, wherein, in described server, storage has the audio file that user uploads;
Described terminal unit, for downloading described audio file to described server, obtain the average volume gain information being arranged in audio file, decode described audio file, the player output volume that currently described audio file is decoded the audio frequency obtained is adjusted according to described average volume gain information, and according to the player output volume after adjusting, control described audio file is currently decoded the broadcast sound volume of the audio frequency obtained;
Described server, for comparing with preset standard pronunciation value according to the average volume value of described audio file, determines the average volume gain information of described audio file, described average volume gain information is arranged described audio file.
Wherein, described server, specifically for arranging described average volume gain information in the label tag information of described audio file, or described average volume gain information is set in the audio description file for describing described audio file.
Implement the embodiment of the present invention, have the advantages that
Can be directly according to the volume of the average volume gain information regulation player being arranged in audio file, substantially can be implemented in player plays audio frequency and complete the function that average gain adjusts, avoid when playing different audio file, the problem that the volume of player output is suddenly big or suddenly small.
Detailed description of the invention
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is clearly and completely described, it is clear that described embodiment is only a part of embodiment of the present invention rather than whole embodiments.Based on the embodiment in the present invention, the every other embodiment that those of ordinary skill in the art are obtained under not making creative work premise, broadly fall into the scope of protection of the invention.
Refer to Fig. 1, be the schematic flow sheet of the method for a kind of audio frequency broadcasting of the embodiment of the present invention;The described method of the present embodiment can be applicable in the terminal unit that music play by mobile phone, computer etc., and the described method of the present embodiment specifically includes:
S101: obtain the average volume gain information being arranged in audio file, decode described audio file.
Described average volume gain information be one for indicating regulation player output audio frequency time the yield value of volume, this average volume yield value can be during after described audio file has been recorded, any time be arranged on described audio file.Such as can be calculated average volume gain information by recording arrangement and be arranged in described audio file while recording completes;Or uploading after described audio file completes to music servers, music servers described audio file is being calculated and calculated volume gain information is arranged in described audio file;Or after being got described audio file by terminal unit, when detecting that described audio file does not include average volume gain information, described audio file is calculated and calculated volume gain information is arranged in described audio file.
Average volume gain information may be provided in the file header of audio file in label tag information, when downloading described audio file from server to play, first the tag information obtaining described audio file can be downloaded, when playing on download limit, limit, player can acquire described average volume gain information from the tag information of the described audio file downloaded.Or when reading locally stored audio file and playing, first player can read the tag information in the file header of described audio file, acquires described average volume gain information.Described average volume gain is that the volume value according to standard draws, so that when playing this audio file, its volume is at a standard value adnexa, wherein, this standard pronunciation value can be to calculate the value that local terminal audio file is calculated by preset one such as the server of average volume gain or terminal unit.
S102: adjust the player output volume that currently described audio file is decoded the audio frequency obtained according to described average volume gain information.
After having obtained average volume gain information, according to the described average volume gain information obtained, the volume of the audio frequency that decoding obtains can be adjusted, increase or reduce the volume of player the most adaptively.
S103: according to the player output volume after adjusting, control described audio file is currently decoded the broadcast sound volume of the audio frequency obtained.
I.e. according to the player output volume after adjusting, media player is controlled, with the audio frequency to loudspeaker apparatus output respective output volume size, the audio frequency completing described audio file is play, and the volume of described loudspeaker apparatus is then that the volume that the volume after being conditioned according to media player and user are regulated by hardware volume knob comprehensively draws.
By the description of above-described embodiment, the method have the advantages that
Can be directly according to the volume of the average volume gain information regulation player being arranged in audio file, substantially can be implemented in player plays audio frequency and complete the function that average gain adjusts, avoid when playing different audio file, the problem that the volume of player output is suddenly big or suddenly small.
Refer to Fig. 2 again, be the schematic flow sheet of the method for another audio frequency broadcasting of the embodiment of the present invention;The embodiment of the present invention is applied in the scene that audio file is broadcast below by limit, and described method can be applicable in the terminal unit that music play by mobile phone, computer etc., and concrete, described method includes:
S201: download audio file, obtains the file header part of described audio file, and obtains the average volume gain information of the described audio file being preset in described file header part.
Open corresponding downloaded software to enable download thread from the equipment such as server, download audio file, first the file header part obtaining audio file is downloaded, tag information from which obtains default average audio gain, in order to when playing audio frequency according to the volume of average audio Gain tuning audio frequency.
S202: download the voice data of described audio file, and decode the voice data that download obtains.
Continue through download thread and download the audio data portion of audio file, and be decoded according to corresponding agreement, in order to be converted into corresponding acoustical signal and play.
S203: adjust the player output volume that currently described audio file is decoded the audio frequency obtained according to described average volume gain information.
After having obtained average volume gain information, the some or all of voice data obtained can be carried out audio decoder, then according to the volume of the audio frequency that decoding obtains is adjusted by the described average volume gain information obtained, increase or reduce the volume of player the most adaptively.
S204: according to the player output volume after adjusting, control described audio file is currently decoded the broadcast sound volume of the audio frequency obtained.
I.e. according to the player output volume after adjusting, media player is controlled, with the audio frequency to loudspeaker apparatus output respective output volume size, the audio frequency completing described audio file is play, and the volume of described loudspeaker apparatus is then that the volume that the volume after being conditioned according to media player and user are regulated by hardware volume knob comprehensively draws.
Implement the embodiment of the present invention and according to a standard pronunciation value, audio file can be arranged average volume gain information, any time afterwards is made to play described audio file, can be directly according to the volume of the average volume gain information regulation player being arranged in audio file, substantially can be implemented in player plays audio frequency and complete the function that average gain adjusts, realize download limit, limit to play, it is to avoid the problem that the volume of player output is suddenly big or suddenly small when downloading and playing different audio files.
Refer to Fig. 3 again, be the schematic flow sheet of the method for the another kind of audio frequency broadcasting of the embodiment of the present invention;The described method of the present embodiment can be applicable in the terminal unit that music play by mobile phone, computer etc., in the present embodiment, described audio files storage is in mobile phone, apparatus such as computer, average volume gain information and the setting up procedure of average volume gain information is calculated by corresponding mobile phone or computer, concrete, the described method of the present embodiment includes:
S301: obtain complete audio file.
Can by download or by other mobile memory unloadings by the way of get complete audio file.
S302: compare with preset standard pronunciation value according to the average volume value in described complete audio file, determines the average volume gain information of described audio file.
In described S302, the step obtaining average volume gain may include that the complete code rate information of the described audio file of acquisition and carries out track analysis;Average volume information according to audio file described in track Analysis result calculation;Carry out difference according to average volume information with a standard pronunciation value to compare, obtain described average volume gain information.Described mark volume value is value preset in the terminal unit such as mobile phone or computer, in the terminal units such as corresponding mobile phone or computer, all uses this standard pronunciation value to carry out corresponding average volume gain and calculates.
S303: described average volume gain information is arranged described audio file.
Described average volume gain information specifically can be set in the label tag information of described audio file.Or described average volume gain information is set in the audio description file for describing described audio file, such as, this average volume gain information is set in the associated with including the described audio file lyrics.
Above three step is the setting up procedure of the average volume gain information of audio file, can at the terminal unit such as mobile phone or computer after getting complete audio file, need any time before playing described audio file to complete.Completing after above-mentioned average gain information arranges, user can perform following step at any time.
S304: obtain the average volume gain information being arranged in audio file, and decode described audio file.
S305: adjust the player output volume that currently described audio file is decoded the audio frequency obtained according to described average volume gain information.
S306: according to the player output volume after adjusting, control described audio file is currently decoded the broadcast sound volume of the audio frequency obtained.
The process processing broadcasting of described S304 to S306 is identical with above-mentioned first embodiment, is not repeated herein.
By the description of above-described embodiment, the method have the advantages that
According to a standard pronunciation value, audio file can be arranged average volume gain information, any time afterwards is made to play described audio file, can be directly according to the volume of the average volume gain information regulation player being arranged in audio file, substantially can be implemented in player plays audio frequency and complete the function that average gain adjusts, avoid when playing different audio file, the problem that the volume of player output is suddenly big or suddenly small.
Refer to Fig. 4 again, be the schematic flow sheet of the method for another audio frequency broadcasting of the embodiment of the present invention;The described method of the present embodiment can be applicable in the terminal unit that music play by mobile phone, computer etc., in the present embodiment, described audio files storage is supplied to the terminal unit such as mobile phone, computer in the server of network side and downloads, the server of the most described network side of setting up procedure of described average volume gain information and average volume gain information performs, concrete, the described method of the present embodiment includes:
After S401: server gets the described audio file uploaded, compare with preset standard pronunciation value according to the average volume value of described complete audio file, determine the average volume gain information of described audio file.
In described S401, described server is after receiving complete audio file, and server obtains the step of average volume gain and may include that the complete code rate information of the described audio file of acquisition and carry out track analysis;Average volume information according to audio file described in track Analysis result calculation;Carry out difference according to average volume information with a standard pronunciation value to compare, obtain described average volume gain information.Described mark volume value is value preset in the terminal unit such as mobile phone or computer, in the terminal units such as corresponding mobile phone or computer, all uses this standard pronunciation value to carry out corresponding average volume gain and calculates.
Described average volume gain information is arranged described audio file by S402: server.
Server specifically can arrange described average volume gain information in the label tag information of described audio file.Or described average volume gain information is set in the audio description file for describing described audio file, such as, this average volume gain information is set in the associated with including the described audio file lyrics.
S403: terminal unit downloads described audio file from server.
S404: terminal unit obtains the average volume gain information that described server is arranged in described audio file, and decodes described audio file.
Terminal unit includes mobile phone, apparatus such as computer.When downloading audio file, terminal unit is all the header file first downloading to described audio file, obtains the tag information of described audio file, thus reads average volume gain information therein.Or first download to the header file of the lyrics file associated with described audio file, thus obtain described average volume gain information.
S405: terminal unit adjusts the player output volume that described audio file currently decodes the audio frequency obtained according to described average volume gain information.
S406: terminal unit, according to the player output volume after adjusting, controls currently to decode described audio file the broadcast sound volume of the audio frequency obtained.
The process being decoded to play of described S405 with S406 is identical with above-mentioned first embodiment, is not repeated herein.
Refer to Fig. 5 again, it it is the schematic flow sheet of the method that the audio file limit of the embodiment of the present invention is broadcast below, in embodiments of the present invention, audio files storage is in the server of network side, the terminal unit such as mobile phone, computer starts download thread and plays thread, by downloading described audio file in corresponding network entry to described server and playing, concrete, the described method of the embodiment of the present invention includes:
S4001: player obtains song link, and downloads described audio file according to song link request;
S4002: download described audio file by corresponding download protocol;Described download protocol includes http protocol, P2P agreement, BT agreement etc..
S4003: download audio file header and divide;Obtain after audio file header divides in download, while continuing to download described audio file until having downloaded and i.e. performing following S4004, perform following S4011.
S4004: download voice data.Download thread can be closed after the download is complete.
S4011: divide middle reading tag information from audio file header, obtain average audio gain therein;
S4012: read the voice data downloading the described audio file obtained;I.e. read the voice data downloaded in described S404.
S4013: judge whether to read voice data;If then performing following S4014, otherwise continuing executing with described S4012, if not judging not read voice data, such as 10 seconds preset in certain period of time, then may determine that audio frequency finishes, closing and play process accordingly.
S4014: decoding reads voice data;
S4015: utilize the volume that average audio Gain tuning player exports;
S4016: according to the player output volume after adjusting, control described audio file is currently decoded the broadcast sound volume of the audio frequency obtained.After playback ends, can close and play thread accordingly, if fruit is not over, continue executing with above-mentioned S4012 to S4016.
By the description of above-described embodiment, the method have the advantages that
According to a standard pronunciation value, audio file can be arranged average volume gain information in the server, the terminal unit downloading described audio file from server is made to play described audio file at any time, can be directly according to the volume of the average volume gain information regulation player being arranged in audio file, substantially can be implemented in player plays audio frequency and complete the function that average gain adjusts, avoid when playing different audio file, the problem that the volume of player output is suddenly big or suddenly small.
Below terminal unit and the system play for audio frequency of the embodiment of the present invention is described in detail.
Refer to Fig. 6, be the structural representation of a kind of terminal unit play for audio frequency of the embodiment of the present invention;The described terminal unit play for audio frequency of the embodiment of the present invention is specifically as follows the equipment of the playable audio file such as mobile phone, computer, and it specifically may include that
Acquisition module 11, for obtaining the average volume gain information being arranged in audio file, decodes described audio file;
Adjusting module 12, for adjusting the player output volume that described audio file currently decodes the audio frequency obtained according to described average volume gain information;
Control module 13, for according to the player output volume after adjusting, controlling currently to decode described audio file the broadcast sound volume of the audio frequency obtained.
The average volume gain information that described acquisition module 11 gets be one for indicating regulation player output audio frequency time the yield value of volume, this average volume yield value can be during after described audio file has been recorded, any time be arranged on described audio file.Such as can be calculated average volume gain information by recording arrangement and be arranged in described audio file while recording completes;Or uploading after described audio file completes to music servers, by music servers, described audio file is calculated and calculated volume gain information is arranged in described audio file, or by for store play audio file terminal unit get described audio file after, when detecting that described audio file does not include average volume gain information, described audio file is calculated and calculated volume gain information is arranged in described audio file.
Average volume gain information may be provided in the file header of audio file in label tag information, when downloading described audio file from server to play, first the tag information obtaining described audio file can be downloaded, when playing on download limit, limit, player can acquire described average volume gain information from the tag information of the described audio file downloaded.Or when reading locally stored audio file and playing, first described acquisition module 11 can read the tag information in the file header of described audio file, acquires described average volume gain information.Described average volume gain is that the volume value according to standard draws, so that when playing this audio file, its volume is at a standard value adnexa, wherein, this standard pronunciation value can be to calculate the value that local terminal audio file is calculated by preset one such as the server of average volume gain or terminal unit.
After described acquisition module 11 has obtained average volume gain information, described adjusting module 12 can carry out audio decoder to the some or all of voice data obtained, then according to the volume of the audio frequency that decoding obtains is adjusted by the described average volume gain information obtained, increase or reduce the volume of player the most adaptively.
In described control module 13 according to the player output volume after adjusting, media player is controlled, with the audio frequency to loudspeaker apparatus output respective output volume size, the audio frequency completing described audio file is play, and the volume of described loudspeaker apparatus is then that the volume that the volume after being conditioned according to media player and user are regulated by hardware volume knob comprehensively draws.
By the description of above-described embodiment, the method have the advantages that
Can be directly according to the volume of the average volume gain information regulation player being arranged in audio file, substantially can be implemented in player plays audio frequency and complete the function that average gain adjusts, avoid when playing different audio file, the problem that the volume of player output is suddenly big or suddenly small.
Refer to Fig. 7 again, be the structural representation of the terminal unit that the another kind of the embodiment of the present invention is play for audio frequency;The described terminal unit play for audio frequency of the embodiment of the present invention is specifically as follows the equipment of the playable audio file such as mobile phone, computer, and it includes in above-described embodiment: acquisition module 11, adjusting module 12 and control module 13.
The most described acquisition module 11 can also include: acquiring unit and decoding unit, and described acquisition module 11 can realize limit by described acquiring unit and decoding unit and download voice data limit playing audio-fequency data, concrete:
Described acquiring unit, for obtaining the file header part of described audio file from download audio file, and obtains the average volume gain information of the described audio file being preset in described file header part;
Described decoding unit, for decoding the voice data of the described audio file of download.
The corresponding downloaded software of mobile terminal unlatching enables download thread and downloads audio file from the equipment such as server, first the file header part obtaining audio file is downloaded, described acquiring unit tag information from which obtains default average audio gain, in order to when playing audio frequency according to the volume of average audio Gain tuning audio frequency.Then proceeding to download voice data, described decoding unit is play after being decoded.
Further, then referring to Fig. 7, described terminal unit also includes that following module arranges average volume gain information to getting audio file.It is specifically as follows:
Memory module 14, for obtaining complete audio file;
Computing module 15, for comparing with preset standard pronunciation value according to the average volume value in described complete audio file, determines the average volume gain information of described audio file;
Module 16 is set, for described average volume gain information is arranged described audio file.
Described memory module 14 can by download or by other mobile memory unloadings by the way of get complete audio file.
Described computing module 15 obtains average volume gain calculation process and may include that the complete code rate information of the described audio file of acquisition and carry out track analysis;Average volume information according to audio file described in track Analysis result calculation;Carry out difference according to average volume information with a standard pronunciation value to compare, obtain described average volume gain information.Described mark volume value is value preset in the terminal unit such as mobile phone or computer, in the terminal units such as corresponding mobile phone or computer, all uses this standard pronunciation value to carry out corresponding average volume gain and calculates.
The described module 16 that arranges specifically can arrange described average volume gain information in the label tag information of described audio file.Or described average volume gain information is set in the audio description file for describing described audio file, such as, this average volume gain information is set in the associated with including the described audio file lyrics.
Above three module is the setting up procedure of the average volume gain information of audio file, can at the terminal unit such as mobile phone or computer after getting complete audio file, need any time before playing described audio file to complete.Completing after above-mentioned average gain information arranges, user can be reached by above-mentioned acquisition module 11, adjusting module 12 and control module 13 and play described audio file.
The most alternatively, the described terminal unit play for audio frequency can also include:
Download module 17, for downloading described audio file from server;
Described acquisition module 11, specifically for obtaining the average volume gain information that described server is arranged in described audio file;
Wherein, described server arranges average volume gain information in described audio file and includes: after described server gets the described audio file uploaded, compare with preset standard pronunciation value according to the average volume value in described complete audio file, determine the average volume gain information of described audio file, described average volume gain information is arranged described audio file.
Equally, the calculating process of described server acquisition average volume gain may include that and obtains the complete code rate information of described audio file and carry out track analysis;Average volume information according to audio file described in track Analysis result calculation;Carry out difference according to average volume information with a standard pronunciation value to compare, obtain described average volume gain information.Described mark volume value is value preset in the terminal unit such as mobile phone or computer, in the terminal units such as corresponding mobile phone or computer, all uses this standard pronunciation value to carry out corresponding average volume gain and calculates.Server specifically can arrange described average volume gain information in the label tag information of described audio file.Or described average volume gain information is set in the audio description file for describing described audio file, such as, this average volume gain information is set in the associated with including the described audio file lyrics.
Described for audio frequency play terminal unit can be by above-mentioned download module 17 to server be downloaded the audio file being provided with average volume gain information after, it is possible to need not above-mentioned computing module 15 and arrange module 16 to download after audio file average volume gain information is set.Concrete, the described terminal unit play for audio frequency can also include that a detection module is for detecting the audio file obtained or store, judge whether audio file exists average volume gain information, if it did not, again by described computing module 15 and arrange module 16 and be averaged the setting of volume gain information.
The most concrete, described module 16 is set, specifically for arranging described average volume gain information in the label tag information of described audio file, or described average volume gain information is set in the audio description file for describing described audio file.
By the description of above-described embodiment, the method have the advantages that
According to a standard pronunciation value, audio file can be arranged average volume gain information, any time afterwards is made to play described audio file, can be directly according to the volume of the average volume gain information regulation player being arranged in audio file, substantially can be implemented in player plays audio frequency and complete the function that average gain adjusts, avoid when playing different audio file, the problem that the volume of player output is suddenly big or suddenly small.
Refer to Fig. 8 again, be the structural representation of a kind of server play for audio frequency of the embodiment of the present invention;In the described server of the embodiment of the present invention, storage has audio file, and by book server, audio file is arranged average volume gain information, and concrete, described server includes:
Receiver module 21, for receiving the audio file that user uploads.
Processing module 22, for after uploading at described audio file, compares with preset standard pronunciation value according to the average volume value of described complete audio file, determines the average volume gain information of described audio file.
Add module 23, for described average volume gain information is arranged described audio file.
Described server receives audio file that user uploads to realize the network storage of described audio file by described receiver module 21.After complete audio file is uploaded by user, complete audio file is processed by server by described process 22, determines the average volume gain information of described audio file.
Described processing module 22 obtains average volume gain and may include that the complete code rate information of the described audio file of acquisition and carry out track analysis;Average volume information according to audio file described in track Analysis result calculation;Carry out difference according to average volume information with a standard pronunciation value to compare, obtain described average volume gain information.Described mark volume value is value preset in the terminal unit such as mobile phone or computer, in the terminal units such as corresponding mobile phone or computer, all uses this standard pronunciation value to carry out corresponding average volume gain and calculates.
Equally, described server can also include whether a detection module includes average volume gain information for detecting in the audio file that user uploads, if do not include, calculated by described processing module 22 and average volume gain information is set by described interpolation module 23, if including, directly performing storage and operating.
Described interpolation module 23, specifically for arranging described average volume gain information in the label tag information of described audio file, or arranges described average volume gain information in the audio description file for describing described audio file.
By the description of above-described embodiment, the method have the advantages that
According to a standard pronunciation value, audio file can be arranged average volume gain information in the server, the terminal unit downloading described audio file from server is made to play described audio file at any time, can be directly according to the volume of the average volume gain information regulation player being arranged in audio file, substantially can be implemented in player plays audio frequency and complete the function that average gain adjusts, avoid when playing different audio file, the problem that the volume of player output is suddenly big or suddenly small.
Referring to Fig. 9 again, be the structural representation of a kind of system play for audio frequency of the embodiment of the present invention, the described system of the present embodiment includes: terminal unit 1 and server 2, wherein, stores the audio file having user to upload in described server 2;Described terminal unit 1 then can include multiple.
Described terminal unit 1, for downloading described audio file to described server 2, obtain the average volume gain information being arranged in audio file, decode described audio file, the player output volume that currently described audio file is decoded the audio frequency obtained is adjusted according to described average volume gain information, and according to the player output volume after adjusting, control described audio file is currently decoded the broadcast sound volume of the audio frequency obtained;
Described server 2, for comparing with preset standard pronunciation value according to the average volume value of described audio file, determines the average volume gain information of described audio file, described average volume gain information is arranged described audio file.
Concrete, described server 2, specifically for arranging described average volume gain information in the label tag information of described audio file, or described average volume gain information is set in the audio description file for describing described audio file.
Wherein, described server 2 is after receiving complete audio file, and server 2 obtains the step of average volume gain and may include that the complete code rate information of the described audio file of acquisition and carry out track analysis;Average volume information according to audio file described in track Analysis result calculation;Carry out difference according to average volume information with a standard pronunciation value to compare, obtain described average volume gain information.Described mark volume value is value preset in the terminal unit such as mobile phone or computer, in the terminal units such as corresponding mobile phone or computer, all uses this standard pronunciation value to carry out corresponding average volume gain and calculates.
Described terminal unit 1 is after having obtained average volume gain information, the some or all of voice data obtained can be carried out audio decoder, then according to the volume of the audio frequency that decoding obtains is adjusted by the described average volume gain information obtained, increase or reduce the volume of player the most adaptively.
The volume of the loudspeaker apparatus of described terminal unit 1 is then that the volume that the volume after being conditioned according to player and user are regulated by hardware volume knob comprehensively draws.
By the description of above-described embodiment, the invention have the advantages that
According to a standard pronunciation value, audio file can be arranged average volume gain information in the server, the terminal unit downloading described audio file from server is made to play described audio file at any time, can be directly according to the volume of the average volume gain information regulation player being arranged in audio file, substantially can be implemented in player plays audio frequency and complete the function that average gain adjusts, avoid when playing different audio file, the problem that the volume of player output is suddenly big or suddenly small.
One of ordinary skill in the art will appreciate that all or part of flow process realizing in above-described embodiment method, can be by computer program and complete to instruct relevant hardware, described program can be stored in a computer read/write memory medium, this program is upon execution, it may include such as the flow process of the embodiment of above-mentioned each method.Wherein, described storage medium can be magnetic disc, CD, read-only store-memory body (Read-OnlyMemory, ROM) or random store-memory body (RandomAccessMemory, RAM) etc..
The above disclosed present pre-ferred embodiments that is only, certainly can not limit the interest field of the present invention, the equivalent variations therefore made according to the claims in the present invention with this, still belong to the scope that the present invention is contained.