Summary of the invention
The problem that the present invention solves provides a kind of frequency spectrum reconfiguration method and device of audio decoder, and in the situation of the precision that does not affect the decoding processing, the computational complexity in the frequency spectrum reconfiguration process of reduction audio decoder improves decoding efficiency.
For addressing the above problem, technical scheme of the present invention provides a kind of frequency spectrum reconfiguration method of audio decoder, comprising:
Audio code stream to input carries out the entropy decoding, and the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent;
If described audio code stream employing pulse data is processed, then carry out pulse data reconstruct based on the spectral line data of output after processing through inverse quantization, anti-convergent-divergent, the frequency spectrum data that obtains after the described pulse data reconstruct is carried out inverse quantization, the processing of anti-convergent-divergent.
Optionally, described spectral line data based on output after processing through inverse quantization, anti-convergent-divergent is carried out pulse data reconstruct, to the frequency spectrum data that obtains after the described pulse data reconstruct carry out inverse quantization, anti-convergent-divergent is processed and is comprised:
After processing through inverse quantization, anti-convergent-divergent, take out the spectral line data that to carry out pulse data reconstruct the spectral line data of output;
Described spectral line data to taking-up quantizes, convergent-divergent is processed;
The frequency spectrum data that quantizes, convergent-divergent is exported after processing is carried out pulse data reconstruct;
To carry out inverse quantization, the processing of anti-convergent-divergent through the frequency spectrum data that obtains after the pulse data reconstruct.
Optionally, describedly process to be based on and determine that the needs that take out carry out that the symbol of the spectral line data of pulse data reconstruct realizes carry out inverse quantization, anti-convergent-divergent through the frequency spectrum data that obtains after the pulse data reconstruct.
Optionally, whether described audio code stream adopts pulse data to process to be the key word by obtaining in the described audio code stream to judge.
Optionally, the encoding and decoding standard of described audio code stream is AAC.
Optionally, described entropy is decoded as Hofmann decoding.
For addressing the above problem, technical scheme of the present invention also provides a kind of frequency spectrum reconfiguration method of audio decoder, comprise: if the audio code stream of input does not adopt pulse data to process, then described audio code stream is carried out the entropy decoding, the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent.
Optionally, described frequency spectrum reconfiguration method also comprises: if the audio code stream of input adopts pulse data to process, then described audio code stream is carried out the entropy decoding, the frequency spectrum data that parses is carried out pulse data reconstruct, to carry out inverse quantization, the processing of anti-convergent-divergent through the frequency spectrum data after the pulse data reconstruct.
Optionally, the encoding and decoding standard of described audio code stream is AAC, BSAC, WMA, MP3 or Real-Audio.
Optionally, described entropy is decoded as Hofmann decoding or arithmetic decoding.
For addressing the above problem, technical scheme of the present invention also provides a kind of frequency spectrum reconfiguration device of audio decoder, comprising:
The first frequency spectrum reconfiguration unit is suitable for the audio code stream of input is carried out the entropy decoding, and the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent;
Judging unit is suitable for judging whether described audio code stream adopts pulse data to process;
The second frequency spectrum reconfiguration unit, be suitable for when described audio code stream adopts pulse data to process, spectral line data based on output after processing through inverse quantization, anti-convergent-divergent is carried out pulse data reconstruct, and the frequency spectrum data that obtains after the described pulse data reconstruct is carried out inverse quantization, the processing of anti-convergent-divergent.
For addressing the above problem, technical scheme of the present invention also provides a kind of frequency spectrum reconfiguration device of audio decoder, comprising: judging unit is suitable for judging whether the audio code stream of input adopts pulse data to process; The 3rd frequency spectrum reconfiguration unit is suitable for when described judgment unit judges goes out described audio code stream and do not adopt pulse data to process described audio code stream being carried out the entropy decoding, with the frequency spectrum data that obtains after the decoding directly carry out inverse quantization, anti-convergent-divergent is processed.
Optionally, described frequency spectrum reconfiguration device also comprises the 4th frequency spectrum reconfiguration unit, be suitable for when described judgment unit judges goes out described audio code stream employing pulse data processing, described audio code stream is carried out the entropy decoding, the frequency spectrum data that obtains after the decoding is carried out pulse data reconstruct, to carry out inverse quantization, the processing of anti-convergent-divergent through the frequency spectrum data that obtains after the pulse data reconstruct.
For addressing the above problem, technical scheme of the present invention also provides a kind of audio decoder that comprises the frequency spectrum reconfiguration device of above-mentioned audio decoder.
Compared with prior art, the technical program has the following advantages:
Carry out the entropy decoding by the audio code stream to input, the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent, thus entropy decoding and inverse quantization, anti-convergent-divergent are processed and effectively integrated, avoided repeatedly data storage to load and larger calculating redundancy, thereby can be in the situation that do not affect the decoding processing accuracy, reduce computational complexity, improve decoding efficiency.
For the audio code stream that has adopted pulse data to process, the laggard horizontal pulse data reconstruction of spectral line data re-quantization, convergent-divergent of output after then will processing through inverse quantization, anti-convergent-divergent, the frequency spectrum data that obtains behind the paired pulses data reconstruction again carries out inverse quantization, anti-convergent-divergent is processed, even audio code stream has adopted the pulse data processing thus, also can process integrated basis realization to the frequency spectrum reconfiguration of audio code stream in entropy decoding and inverse quantization, anti-convergent-divergent, thereby reduce on the whole computational complexity, improve decoding efficiency.
Embodiment
As stated in the Background Art, in the frequency spectrum reconfiguration process of the audio decoder of prior art, exist repeatedly the data storage to load and larger calculating redundancy, computational complexity increases, decoding efficiency reduces thereby make.The technical program is by processing and effectively integrate with the entropy decoding with inverse quantization, anti-convergent-divergent, avoided repeatedly data storage to load and larger calculating redundancy, thereby can be in the situation that do not affect the decoding processing accuracy, reduction computational complexity, raising decoding efficiency.
For above-mentioned purpose of the present invention, feature and advantage can more be become apparent, below in conjunction with accompanying drawing the specific embodiment of the present invention is described in detail.Set forth detail in the following description so that fully understand the present invention.But the present invention can be different from alternate manner described here and implements with multiple, and those skilled in the art can be in the situation that do similar popularization without prejudice to intension of the present invention.Therefore the present invention is not subjected to the restriction of following public embodiment.
Embodiment one
As stated in the Background Art, in the frequency spectrum reconfiguration process of the audio decoder of prior art, exist repeatedly data storages to load and larger calculating redundant, thereby cause that computational complexity increases, decoding efficiency is lower.Therefore, the inventor considers, can carry out integrated optimization by the step that entropy decoding, inverse quantization processing, anti-convergent-divergent are processed, and makes it carry out efficient higher.Integrated optimization described here comprises a plurality for the treatment of steps to data are merged on the one hand; Refer on the other hand after the processing of data through a treatment step, no longer be stored among the buffer for the result after processing (comprise processing after partial data or total data), but will directly process by next treatment step through the result after this step process (result after this processing temporarily is stored in the register of processor), after data are passed through the processing of integrated whole treatment steps, deposit the result that obtains at last in buffer.For a comparatively simple example explanation, suppose that original whole processing procedure comprises 2 treatment steps, be respectively a+b=c and d+c=e, carrying out so a+b result c afterwards can deposit in the buffer, when carrying out d+c, need from buffer, to load first c, then obtain e with the d addition again based on the c that loads; Through after integrated, whole processing procedure then becomes 1 treatment step, be a+b+d=e, whole processing procedure is directly finished by processor, certainly, the intermediate result of calculating is temporary in the register, does not repeat them here for the common practise of computer realm as for difference between register and the buffer.Need to prove, top only understands the integrated optimization of mentioning in the present embodiment for helping for example, should be as the restriction of the integrated optimization that the steps such as entropy decoding, inverse quantization processing, anti-convergent-divergent processing are carried out.
As the above analysis, one of advantage behind the integrated optimization is, has reduced the number of times that the data storage loads, thereby has improved the efficient that data are processed.Therefore, at first can consider the step that step and the anti-convergent-divergent of inverse quantization processing are processed is carried out integrated optimization, further, the step of the step that entropy can also be decoded and inverse quantization, anti-convergent-divergent is carried out integrated optimization.Owing to just can know the at that time symbol of spectral line when carrying out the entropy decoding, if the step of the step of entropy decoding and inverse quantization, anti-convergent-divergent is carried out integrated, be that inverse quantization, anti-convergent-divergent are directly carried out in the entropy decoding afterwards, the symbol of determined spectral line is directly finished the step of inverse quantization, anti-convergent-divergent in the time of then can utilizing the entropy decoding, and no longer need to rejudge the symbol of spectral line, thereby avoided the repetitive operation for the symbol decision of spectral line.Therefore, another advantage behind the integrated optimization is, reduced the calculating that the symbol decision because of spectral line causes redundant, improved operation efficiency.
Yet, for the audio code stream that adopts the AAC coding, can have the situation that adopts pulse data to process.In the AAC decoding standard, processing for large quantized value, the method that generally can adopt is to carry out pulse data to process, when using the method, large numerical value is deducted a difference and is become fractional value, then use the huffman table coding, the reduction of difference can be helped with a pulse structure in the back, namely carries out the operation of pulse data reconstruct.Therefore, for the frequency spectrum reconfiguration of audio code stream, except the step of entropy decoding, inverse quantization, anti-convergent-divergent, also comprise the step of pulse data reconstruct, this considers entropy decoding, pulse data reconstruct, inverse quantization and four steps of anti-convergent-divergent are carried out integrated optimization with regard to needs.Yet, can be with reference to figure 1, if want above-mentioned four steps are integrated, main trouble is to exist the step of pulse data reconstruction, because this step is to carry out computing to the data after quantizing, its special position has hindered the integrated of entropy decoding and inverse quantization, anti-convergent-divergent.
The frequency spectrum reconfiguration method of the audio decoder that the present embodiment provides has solved the technical matters that above-mentioned entropy decoding and inverse quantization, anti-convergent-divergent are difficult to be integrated optimization.Fig. 2 is the schematic flow sheet of the frequency spectrum reconfiguration method of the audio decoder that provides of the embodiment of the invention one.As shown in Figure 2, the frequency spectrum reconfiguration method of the audio decoder that provides of the present embodiment comprises:
Execution in step S201 carries out the entropy decoding to the audio code stream of inputting, and the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent;
Then execution in step S202 judges whether described audio code stream adopts pulse data to process;
Otherwise finished the frequency spectrum reconfiguration to described audio code stream, execution in step S203 then, spectral line data based on output after processing through inverse quantization, anti-convergent-divergent is carried out pulse data reconstruct, the frequency spectrum data that obtains after the described pulse data reconstruct is carried out inverse quantization, the processing of anti-convergent-divergent, thereby realize frequency spectrum reconfiguration.
In the present embodiment, the encoding and decoding standard of described audio code stream is AAC, for the audio code stream that adopts the AAC coding, can there be the situation that adopts pulse data to process, therefore need to judge whether described audio code stream adopts the step of pulse data processing, be execution in step S202, adopt pulse data to process if judge audio code stream, then also need to carry out pulse data reconstruct.In the present embodiment, described entropy decoding is specially Hofmann decoding, and in other embodiments, described entropy decoding also can be other entropy decoding method, for example arithmetic decoding.
The below elaborates to each step of said method.
At first, step S201 carries out the entropy decoding to the audio code stream of inputting, and the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent.Because described audio code stream is at output terminal (coding side) sound signal of sampling to be processed through quantification, convergent-divergent, and carry out just transferring to after the processing of entropy coding input end (decoding end), therefore, just need to carry out entropy decoding and inverse quantization to this audio code stream at input end, anti-convergent-divergent is processed the frequency spectrum reconfiguration that could realize sound signal.Need to prove, in order to reduce computational complexity, improve decoding efficiency, in the present embodiment, first no matter whether described audio code stream adopts pulse data to process, directly it is carried out the integrated computation of entropy decoding, inverse quantization, anti-convergent-divergent at step S201, then judge by step S202 whether described audio code stream adopts pulse data to process, otherwise having finished the frequency spectrum reconfiguration to described audio code stream, is then to carry out step S203 again.
" directly " described in the step S201 is in order to embody the integrated computation of entropy decoding, inverse quantization, anti-convergent-divergent, particularly, described audio code stream does not deposit first buffer in through the frequency spectrum data that entropy parses, but directly (this frequency spectrum data is stored in the register to the frequency spectrum data that parses, can directly carry out calculation process by microprocessor) carry out the processing of inverse quantization, anti-convergent-divergent, the spectral line data of exporting after the computing with inverse quantization, anti-convergent-divergent is stored in again carries out subsequent treatment in the buffer.
Among the step S202, judge that whether described audio code stream adopts pulse data to process is to realize by the key word that obtains in the described audio code stream.For example, whether to adopt the value of the key word that pulse data processes be 0 if get access to expression, represents that then audio code stream does not adopt pulse data to process; If the value of the described key word that gets access to is 1, represent that then audio code stream adopts pulse data to process, need to carry out to the frequency spectrum data that adopts pulse data to process the operation of pulse data reconstruct this moment.
Adopted the pulse data processing when judging described audio code stream by step S202, then carry out step S203, spectral line data based on output after processing through inverse quantization, anti-convergent-divergent is carried out pulse data reconstruct, the frequency spectrum data that obtains after the described pulse data reconstruct is carried out inverse quantization, the processing of anti-convergent-divergent, thereby realize frequency spectrum reconfiguration.Fig. 3 is the detailed process schematic diagram of step S203 among Fig. 2.Consult Fig. 3, step S203 specifically can comprise the steps:
S203a takes out the spectral line data that need to carry out pulse data reconstruct the spectral line data of output after processing through inverse quantization, anti-convergent-divergent;
S203b, to the described spectral line data of taking out quantize, convergent-divergent processes;
S203c carries out pulse data reconstruct to the frequency spectrum data that quantizes, convergent-divergent is exported after processing;
S203d is to carrying out inverse quantization, the processing of anti-convergent-divergent through the frequency spectrum data that obtains after the pulse data reconstruct.
Wherein, also comprise among the step S203a and determine that the needs that take out carry out the symbol of the spectral line data of pulse data reconstruct, specifically determine to carry out the symbol of the spectral line data of pulse data reconstruct by the mode that symbol is set.Because by entropy decoding and inverse quantization among the step S201, anti-convergent-divergent integrated computation, the symbol of determined spectral line is directly finished inverse quantization in the time of utilizing the entropy decoding, anti-convergent-divergent, pass through so inverse quantization, the symbol of the spectral line data of output was known after anti-convergent-divergent was processed, in subsequent step S203d, the frequency spectrum data that obtains after the reconstruct of process pulse data is carried out inverse quantization, anti-convergent-divergent repeats the computing of symbol decision when processing, then when taking out the spectral line data need to carry out pulse data reconstruct, step S203a just sets the symbol of corresponding spectral line data, in order to can realize the inverse quantization through the frequency spectrum data after the pulse data reconstruct based on set symbol when carrying out step S203d, anti-convergent-divergent is processed.
Particularly, for the setting of symbol, can do following computing:
If the needs that take out carry out the spectral line data spec of pulse data reconstruct<=0, then: spec=-spec (get on the occasion of with carry out follow-up quantification, convergent-divergent is processed); Symbol sign=-1; Otherwise: sign=1.
Set after the symbol sign, spectral line data spec is made quantification, convergent-divergent processing, i.e. execution in step S203b.As previously mentioned, the step of pulse data reconstruct is just can carry out for the frequency spectrum data after quantizing, and therefore, need to re-start to the spectral line data spec that takes out quantification, convergent-divergent processing, specifically based on following formula:
Wherein, q is for re-starting the value of exporting after quantification, the convergent-divergent processing to spectral line data spec; Scf is coding subband zoom factor, is the given value of being imported into by (fixed length code is wherein resolved) in the entropy decoding step of front.
Obtain through quantification, convergent-divergent process after after the frequency spectrum data q of output, just can carry out pulse data reconstruct to q, i.e. execution in step S203c, specifically based on following formula:
q′=q+pulse_amp
Wherein, q ' is the frequency spectrum data that obtains through after the pulse data reconstruct; Pulse_amp is current spectral line pulse height reconstruct offset, equally also is the given value of being imported into by entropy decoding step before (fixed length code is wherein resolved).
Computing through pulse data reconstruct obtains frequency spectrum data q ' afterwards, and then q ' is carried out inverse quantization, anti-convergent-divergent and process to realize frequency spectrum reconfiguration to audio code stream, i.e. execution in step S203d, specifically based on following formula:
Wherein, spec ' is the spectral line data of output after q ' is processed through inverse quantization, anti-convergent-divergent; Sign be before set symbol, the positive negative value that is used for the reduction spectral line, therefore can think, describedly process to be based on and determine that the needs that take out carry out that the symbol of the spectral line data of pulse data reconstruct realizes carry out inverse quantization, anti-convergent-divergent through the frequency spectrum data that obtains after the pulse data reconstruct.
So far, just finished frequency spectrum reconfiguration to described audio code stream.From the implementation of above-mentioned steps S203, in the present embodiment, increased much for the computation complexity of the step of pulse data reconstruct.Be not need to carry out S203b and these two steps of S203d in the implementation method of prior art, because when preparing to carry out the step of pulse data reconstruct, data stream also belongs to the data behind the quantization zooming, and the calculating of directly carrying out pulse data reconstruct gets final product.And in the present embodiment, when preparing to carry out the step of pulse data reconstruct, data stream has been the data after the anti-convergent-divergent of inverse quantization.Therefore, in order to do pulse data reconstruct, need to again do quantization zooming and process, namely the present embodiment is introduced the step of the heavy convergent-divergent of weightization.But because in the AAC coding standard, stipulate that each frame adopts the spectral line number of pulse data reconstruct to be no more than 4 points, the needed subband zoom factor of convergent-divergent all is known simultaneously, do not need to recomputate, therefore the complexity that the integrated computation for realizing the entropy decoding in the step S201 of complexity that pulse data reconstruct increases, inverse quantization, anti-convergent-divergent in the technical scheme of the present embodiment reduces, in general, remain the complexity that has greatly reduced computing, improved the efficient of decoding.
In a large amount of emulation experiments, be the monophony film source of 64k for the bit rate that does not adopt pulse data reconstruct, adopt the described frequency spectrum reconfiguration method of the present embodiment, compare (for example described technical scheme of background technology) with the scheme of prior art, reduce at least approximately 65% complexity; And be 64k for the bit rate that adopts pulse data reconstruct, the spectral line number of pulse data reconstruct is 4 monophony film source, adopts the described frequency spectrum reconfiguration method of the present embodiment, compares with the scheme of prior art, reduces at least approximately 60% complexity.Therefore, also confirm by emulation experiment: although increase to some extent for the computational complexity of realizing pulse data reconstruct in the present embodiment, still reduced generally calculated amount, improved decoding efficiency, and computational accuracy is not produced any impact.
Need to prove, in the calculating of the present embodiment step S201, Hofmann decoding algorithm, inverse quantization and the anti-convergent-divergent algorithm that uses do not limit, be applicable to the anti-Zoom method of all entropy encoding/decodings and inverse quantization, in step S203, S203b, the computing formula implementation method among S203c and the S203d does not limit yet.
Based on the frequency spectrum reconfiguration method of above-mentioned audio decoder, the present embodiment also provides a kind of frequency spectrum reconfiguration device of audio decoder.Fig. 4 is the structural representation of the frequency spectrum reconfiguration device of the audio decoder that provides of the embodiment of the invention one, as shown in Figure 4, the frequency spectrum reconfiguration device of the audio decoder that the present embodiment provides comprises: the first frequency spectrum reconfiguration unit 401, be suitable for the audio code stream of input is carried out the entropy decoding, the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent; Judging unit 402 is suitable for judging whether described audio code stream adopts pulse data to process; The second frequency spectrum reconfiguration unit 403, link to each other with described judging unit 402, be suitable for when described audio code stream adopts pulse data to process, spectral line data based on output after processing through inverse quantization, anti-convergent-divergent is carried out pulse data reconstruct, and the frequency spectrum data that obtains after the described pulse data reconstruct is carried out inverse quantization, the processing of anti-convergent-divergent.
During implementation, described the first frequency spectrum reconfiguration unit 401 can comprise: entropy decoding unit 401a is suitable for the audio code stream of input is carried out the entropy decoding; The anti-unit for scaling 401b of the first inverse quantization is connected with described entropy decoding unit 401a, is suitable for the frequency spectrum data that obtains after the described entropy decoding unit 401a decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent.Described the second frequency spectrum reconfiguration unit 403 comprises: acquiring unit 403a, take out the spectral line data that need to carry out pulse data reconstruct the spectral line data that is suitable for exporting after processing through the anti-unit for scaling 401b of described the first inverse quantization inverse quantization, anti-convergent-divergent; Quantization zooming unit 403b links to each other with described acquiring unit 403a, be suitable for to the described spectral line data that described acquiring unit 403a takes out quantize, convergent-divergent processes; Pulse data reconfiguration unit 403c, unit 403b links to each other with described quantization zooming, is suitable for the frequency spectrum data that described quantization zooming unit 403b quantizes, convergent-divergent is exported after processing is carried out pulse data reconstruct; The anti-unit for scaling 403d of the second inverse quantization links to each other with described pulse data reconfiguration unit 403c, is suitable for the frequency spectrum data that obtains after the pulse data reconstruct of carrying out through described pulse data reconfiguration unit 403c is carried out inverse quantization, the processing of anti-convergent-divergent.
Described the second frequency spectrum reconfiguration unit 403 also comprises symbol determining unit 403e, described symbol determining unit 403e links to each other with acquiring unit 403a, the anti-unit for scaling 403d of the second inverse quantization, is suitable for determining that needs that described acquiring unit 403a takes out carry out the symbol of the spectral line data of pulse data reconstruct; The anti-unit for scaling 403d of described the second inverse quantization processes to the inverse quantization that carries out through the frequency spectrum data that obtains after the pulse data reconstruct, anti-convergent-divergent that the symbol that is based on the determined spectral line data of described symbol determining unit 403e realizes.Described judging unit 402 judges that whether described audio code stream adopts pulse data to process is by obtaining the key word realization in the described audio code stream.
In addition, the present embodiment also provides a kind of audio decoder that comprises the frequency spectrum reconfiguration device of above-mentioned audio decoder.The frequency spectrum reconfiguration device of described audio decoder and the implementation of audio decoder can with reference to the frequency spectrum reconfiguration method of above-mentioned audio decoder, not repeat them here.
Embodiment two
What the present embodiment and embodiment one distinguished to some extent is, audio code stream to input described in the embodiment one carries out the entropy decoding, the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the step that anti-convergent-divergent is processed is to carry out before judging the step whether described audio code stream adopt pulse data to process, and in the present embodiment, described audio code stream to input carries out the entropy decoding, and the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the step that anti-convergent-divergent is processed is based on to judge carries out in the situation that described audio code stream adopts or do not adopt pulse data to process.
Fig. 5 is the schematic flow sheet of the frequency spectrum reconfiguration method of the audio decoder that provides of the embodiment of the invention two.As shown in Figure 5, the frequency spectrum reconfiguration method of the audio decoder that provides of the present embodiment comprises:
Step S301 judges whether the audio code stream of input adopts pulse data to process;
No matter the result after step S301 carries out how, the audio code stream that the present embodiment all will be carried out input carries out the entropy decoding, the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the step that anti-convergent-divergent is processed, judge the situation that adopts the pulse data processing and the situation that does not adopt pulse data to process in order to distinguish, do not adopt pulse data to process if judge, then this step is labeled as step S302a, adopt pulse data to process if judge, then this step is labeled as step S302b, step S302a is identical with the content that step S302b carries out, but, step S302a executes just and has realized frequency spectrum reconfiguration, and after the step S302b execution, also need execution in step S303, based on the process inverse quantization, the spectral line data of output was carried out pulse data reconstruct after anti-convergent-divergent was processed, and the frequency spectrum data that obtains after the described pulse data reconstruct is carried out inverse quantization, anti-convergent-divergent is processed, thereby realizes the frequency spectrum reconfiguration to audio code stream.
But the relevant enforcement of frequency spectrum reconfiguration method does not repeat them here described in the implementation reference example one of the frequency spectrum reconfiguration method of the audio decoder that the present embodiment provides.
Embodiment three
All be to judge first described audio code stream whether process by pulse data among the present embodiment and the embodiment two, then after judging described audio code stream and not adopting pulse data to process, audio code stream to input carries out entropy decoding, the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, anti-convergent-divergent process to realize frequency spectrum reconfiguration to audio code stream.Difference is to some extent, among the embodiment two after judging described audio code stream and adopting pulse data to process, still can carry out to the audio code stream of input the entropy decoding, the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent, the step of carrying out again afterwards pulse data reconstruct with the correlation technique among the embodiment one; And the present embodiment then carries out pulse data reconstruct according to conventional method in the prior art after judging the processing of described audio code stream employing pulse data.
Fig. 6 is the schematic flow sheet of the frequency spectrum reconfiguration method of the audio decoder that provides of the embodiment of the invention three.Consult Fig. 6, the frequency spectrum reconfiguration method of the audio decoder that the present embodiment provides comprises:
Step S601 judges whether the audio code stream of input adopts pulse data to process;
Otherwise execution in step S602 carries out the entropy decoding to described audio code stream, and the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent; Owing to not needing to carry out the operation of pulse data reconstruct, step S602 is finished and has namely realized frequency spectrum reconfiguration to described audio code stream.
Be execution in step S603 then, described audio code stream is carried out the entropy decoding; Then execution in step S604 carries out pulse data reconstruct with the frequency spectrum data that obtains after the decoding; After this execution in step S605 carries out inverse quantization, the processing of anti-convergent-divergent to the frequency spectrum data that obtains after the reconstruct of process pulse data.Can find out, step S603 to the implementation of step S605 be processing mode conventional in the prior art, but because when reality is implemented, the situation that employing pulse data coding is processed in most of film source is fewer (namely judging the situation that adopts pulse data to process less) also, therefore, in general, the complexity that relies on the integrated computation of entropy decoding among the step S602, inverse quantization, anti-convergent-divergent to reduce, still can greatly reduce the complexity of computing, improve the efficient of decoding.
In the present embodiment, the encoding and decoding standard of described audio code stream can be AAC, BSAC, WMA, MP3 or Real-Audio etc., and described entropy decoding is generally Hofmann decoding or arithmetic decoding.Need to prove, because at present except the AAC encoding and decoding standard, all do not relate to the situation that to carry out pulse data reconstruct in other encoding and decoding standards, therefore, during encoding and decoding standard beyond the encoding and decoding standard of described audio code stream is AAC, do not need to judge whether described audio code stream adopts pulse data to process, the integrated computation that only needs to carry out entropy decoding, inverse quantization, anti-convergent-divergent just can be realized the frequency spectrum reconfiguration to audio code stream.
But the relevant enforcement of the implementation reference example one of the frequency spectrum reconfiguration method of the audio decoder that the present embodiment provides and the frequency spectrum reconfiguration method described in the embodiment two does not repeat them here.
Based on the frequency spectrum reconfiguration method of above-mentioned audio decoder, the present embodiment also provides a kind of frequency spectrum reconfiguration device of audio decoder.Fig. 7 is the structural representation of the frequency spectrum reconfiguration device of the audio decoder that provides of the embodiment of the invention three, as shown in Figure 7, the frequency spectrum reconfiguration device of the audio decoder that the present embodiment provides comprises: judging unit 701 is suitable for judging whether the audio code stream of input adopts pulse data to process; The 3rd frequency spectrum reconfiguration unit 702, be connected with described judging unit 701, be suitable for when described judging unit 701 is judged described audio code stream and do not adopted pulse data to process, described audio code stream being carried out the entropy decoding, with the frequency spectrum data that obtains after the decoding directly carry out inverse quantization, anti-convergent-divergent is processed.
Described frequency spectrum reconfiguration device also comprises the 4th frequency spectrum reconfiguration unit 702, be connected with described judging unit 701, be suitable for when described judging unit 701 is judged described audio code stream employing pulse data processing, described audio code stream is carried out the entropy decoding, the frequency spectrum data that obtains after the decoding is carried out pulse data reconstruct, to carry out inverse quantization, the processing of anti-convergent-divergent through the frequency spectrum data that obtains after the pulse data reconstruct.
In the present embodiment, the encoding and decoding standard of described audio code stream is AAC, BSAC, WMA, MP3 or Real-Audio, and described entropy is decoded as Hofmann decoding or arithmetic decoding.
In addition, the present embodiment also provides a kind of audio decoder that comprises the frequency spectrum reconfiguration device of above-mentioned audio decoder.The frequency spectrum reconfiguration device of described audio decoder and the implementation of audio decoder can with reference to the frequency spectrum reconfiguration method of above-mentioned audio decoder, not repeat them here.
To sum up, the frequency spectrum reconfiguration method of the audio decoder that embodiment of the present invention provides and device have following beneficial effect at least:
Carry out the entropy decoding by the audio code stream to input, the frequency spectrum data that obtains after the decoding is directly carried out inverse quantization, the processing of anti-convergent-divergent, thus entropy decoding and inverse quantization, anti-convergent-divergent are processed and effectively integrated, avoided repeatedly data storage to load and larger calculating redundancy, thereby can be in the situation that do not affect the decoding processing accuracy, reduce computational complexity, improve decoding efficiency.
For the audio code stream that has adopted pulse data to process, the laggard horizontal pulse data reconstruction of spectral line data re-quantization, convergent-divergent of output after then will processing through inverse quantization, anti-convergent-divergent, the frequency spectrum data that obtains behind the paired pulses data reconstruction again carries out inverse quantization, anti-convergent-divergent is processed, even audio code stream has adopted the pulse data processing thus, also can process integrated basis realization to the frequency spectrum reconfiguration of audio code stream in entropy decoding and inverse quantization, anti-convergent-divergent, thereby reduce on the whole computational complexity, improve decoding efficiency.
Although the present invention with preferred embodiment openly as above; but it is not to limit the present invention; any those skilled in the art without departing from the spirit and scope of the present invention; can utilize method and the technology contents of above-mentioned announcement that technical solution of the present invention is made possible change and modification; therefore; every content that does not break away from technical solution of the present invention; to any simple modification, equivalent variations and modification that above embodiment does, all belong to the protection domain of technical solution of the present invention according to technical spirit of the present invention.