The present invention relates to an audio processing technology field, and in particular to a multi-channel signal encoding method, decoding method, encoding apparatus, decoding apparatus, and encoding and decoding system.
As the people's living standards are increasingly improved, high-quality speakers are gradually spreading among ordinary families. A multi-channel speaker produces high-quality acoustic effects. The channel level difference (channel level difference, CLD) is an important parameter that reflects the sound field of multi-channel signals. This parameter indicates the energy relationship between two signals in a multi-channel signal within each frequency band. It is widely used in existing multi-channel encoding algorithms, such as strength multi-channel signal, parameter multi-channel signal, and Panning algorithms. The channel level difference uses a scalar quantizer for quantization processing. This scalar quantizer is a 31-dimensional vector codebook CLDs. This vector codebook CLDs=[−50, −45, −40, −35, −30, −25, −22, −19, −16, −13, −10, −8, −6, −4, −2, 0, 2, 4, 6, 8, 10, 13, 16, 19, 22, 25, 30, 35, 40, 45, 50]. The dimension of the codebook is five bits. Quantization processing is performed for the channel level difference according to the vector codebook CLDs. Each element in the vector codebook CLDs indicates the quantization level for CLD.
During the implementation of the present invention, the inventor discovers the following disadvantages in the prior art:
The prior art uses a same method for quantization processing of channel level differences of all types, but does not quantizes the channel level differences according to the characteristics of the channel level differences, leading to poor flexibility in quantizing channel level differences of a multi-channel signal.
Embodiments of the present invention provide a multi-channel signal encoding method, decoding method, encoding apparatus, and decoding apparatus, which may improve flexibility in quantizing channel level differences of a multi-channel signal.
An embodiment of the present invention provides a multi-channel signal encoding method. The method includes:
determining a sum of channel level differences (CLDs) of a current frame of a multi-channel signal in a certain frequency band area;
determining an average value of sums of channel level differences of at least two frames before the current frame in the certain frequency band area;
according to the sum of channel level differences of the current frame of the multi-channel signal in the certain frequency band area, the average value of the sums of channel level differences of at least two frames before the current frame in the certain frequency band area, and a preset threshold, judging whether the channel level differences of the current frame are in a transient state or a non-transient state, and obtaining a judgment result; and
according to the judgment result, performing quantization processing on the channel level differences of the current frame of the multi-channel signal.
An embodiment of the present invention provides a multi-channel signal decoding method. The method includes:
receiving encoding information from an encoding end, where the encoding information indicates whether channel level differences of a current frame of a multi-channel signal are in a transient state or a non-transient state;
if the encoding information indicates that the channel level differences of the current frame are in the transient state, using first quantization precision to de-quantize encoding data of the channel level differences of the current frame of the multi-channel signal; and
if the encoding information indicates that the channel level differences of the current frame are in the non-transient state, using second quantization precision to de-quantize encoding data of the channel level differences of the current frame of the multi-channel signal; where,
the first quantization precision is higher than the second quantization precision.
An embodiment of the present invention provides a multi-channel signal encoding apparatus. The apparatus includes:
a first determining unit, configured to determine a sum of channel level differences (CLDs) of a current frame of a multi-channel signal in a certain frequency band area;
a second determining unit, configured to determine an average value of sums of channel level differences (CLDs) of at least two frames before the current frame in the certain frequency band area;
a judging unit, configured to: according to the sum of channel level differences (CLDs) of the current frame of the multi-channel signal in the certain frequency band area, the average value of the sums of channel level differences (CLDs) of at least two frames before the current frame in the certain frequency band area, and a preset threshold, judge whether the channel level differences of the current frame are in a transient state or a non-transient state, and obtain a judgment result;
a quantizing unit, configured to: according to the judgment result, perform quantization processing on the channel level differences of the current frame of the multi-channel signal.
An embodiment of the present invention provides a multi-channel signal decoding apparatus. The apparatus includes:
a receiving unit, configured to receive encoding information from an encoding end, where the encoding information indicates whether CLDs of a current frame of a multi-channel signal are in a transient state or a non-transient state; and
a de-quantizing unit, configured to: if the encoding information indicates that the channel level differences (CLDs) of the current frame are in the transient state, use first quantization precision to de-quantize encoding data of the channel level differences of the current frame of the multi-channel signal; and if the encoding information indicates that the channel level differences of the current frame are in the non-transient state, use second quantization precision to de-quantize encoding data of the channel level differences of the current frame of the multi-channel signal; where,
the first quantization precision is higher than the second quantization precision.
An embodiment of the present invention provides a multi-channel signal encoding and decoding system. The system includes:
an encoding end, configured to: determine a sum of channel level differences (CLDs) of a current frame of a multi-channel signal in a certain frequency band area; determine an average value of sums of channel level differences (CLDs) of at least two frames before the current frame in the certain frequency band area; according to the sum of channel level differences of the current frame of the multi-channel signal in the certain frequency band area, the average value of the sums of channel level differences of at least two frames before the current frame in the certain frequency band area, and a preset threshold, judge whether the CLDs of the current frame are in a transient state or a non-transient state, and obtain a judgment result; according to the judgment result, perform quantization processing on the channel level differences of the current frame of the multi-channel signal to obtain encoding data of channel level differences of the current frame; and send the encoding data of channel level differences of the current frame and the judgment result to a decoding end; and
a decoding end, configured to receive the encoding data of channel level differences of the current frame and the judgment result sent from the encoding end, and de-quantize the encoding data of channel level differences of the current frame according to the judgment result.
Embodiments of the present invention provide a multi-channel signal encoding method, decoding method, encoding device, and decoding device to judge on the encoding end whether the CLDs of the current frame are in a transient state or a non-transient state, and perform relevant quantization processing on the channel level differences of the current frame of the multi-channel signal, improving flexibility in quantizing channel level differences of multi-channel signal.
To make the technical solution of the present invention clearer, the accompanying drawings for illustrating the embodiments of the present invention or the prior art are described below. Apparently, the accompanying drawings are for the exemplary purpose only, and person having ordinary skill in the art may derive other drawings from such accompanying drawings without any creative effort.
The technical solution under the present invention is described below with reference to the accompanying drawings. Evidently, the embodiments described below are for the exemplary purpose only, without covering all embodiments of the present invention. Those skilled in the art may derive other embodiments from the embodiments given herein without making any creative effort, and all such embodiments are covered in the protection scope of the present invention.
The channel level difference (Channel Level Difference, CLD) is a parameter that reflects the sound field of multi-channel signals. The parameter reflects the energy relationship between two signals in a multi-channel signal within each frequency band. The logarithmic energy ratio of the CLD in each frequency band is as follows:
where, k indicates a frequency index, X1[k] indicates the kth spectral coefficient of the first audio channel, X1*[k] indicates the conjugation of X1[k], X2[k] indicates the kth spectral coefficient of the second audio channel, X2*[k] indicates the conjugation of X2[k], b indicates a frequency band index, and Kb indicates the start frequency band index of the bth frequency band.
The multi-channel signal in this embodiment include a multi-channel signal such as stereo, 5.1 audio channels, 7.1 audio channels, and 10.2 audio channels.
In this embodiment, the transient state may be that: the sound field of multi-channel signals switches from one state to another state, which takes short time, and is in an unstable state.
As shown in
Step 102: Determine a sum of channel level differences (CLDs) of a current frame of a multi-channel signal in a certain frequency band area.
In this embodiment, the certain frequency band area may be an entire frequency band, or a preset partial frequency band area. For example, an entire frequency band is divided into two frequency bands: a high frequency band and a low frequency band. The sum of CLDs of the current frame of the multi-channel signal in the high frequency band area is calculated.
Step 104: Determine an average value of sums of channel level differences (CLDs) of at least two frames before the current frame in the certain frequency band area.
This step may be as follows: calculating an average value of CLDs of N frames that include the current frame and N−1 frames before the current frame according to the sum of CLDs of the current frame in the certain frequency band area and the sum of CLDs of the N−1 frames before the current frame in the certain frequency band area. The N−1 frames may be consecutive or non-consecutive.
In this embodiment, the at least two frames before the current frame may be at least two frames that include the current frame, or at least two frames that do not include the current frame.
Step 106: According to the sum of CLDs of the current frame, the average value of sums of CLDs of at least two frames before the current frame, and a preset threshold (non-negative number), judge whether the CLDs of the current frame are in a transient state or a non-transient state and obtain a judgment result. This step may be as follows:
obtaining an absolute value of a difference between the sum of CLDs of the current frame and the average value of the CLDs of the at least two frames before the current frame;
comparing the absolute value of the difference with the preset threshold;
if the absolute value of the difference is greater than the threshold, determining that the CLDs of the current frame are in the transient state; and
if the absolute value of the difference is smaller than the threshold, determining that the CLDs of the current frame are in the non-transient state.
The threshold in this embodiment may be obtained according to experience values, or by collecting statistics. For example, statistics about all absolute values of differences in historic data are collected, and a minimum value corresponding to the case in which the CLDs are in the transient state is preset as the threshold.
Step 108: According to the judgment result obtained in step 106, perform quantization processing on the channel level differences of the current frame of the multi-channel signal.
This step may be as follows:
when the CLDs of the current frame are in the transient state, using first quantization precision to quantize the channel level differences of the current frame of the multi-channel signal; and
when the CLDs of the current frame are in the non-transient state, using second quantization precision to quantize the channel level differences of the current frame of the multi-channel signal; where,
the first quantization precision may be higher than the second quantization precision. For example, the first quantization precision is 5, and the second quantization precision is 1.
The channel level differences of the current frame of the multi-channel signal that are quantized in this step may be channel level differences in an entire frequency band or a certain frequency band area.
Alternatively, this embodiment may further include:
Step 110: Send encoding data of the channel level differences of the current frame obtained through quantization in step 108 to a decoding end to decode.
Alternatively, this embodiment may further include:
Step 112: Send the judgment result obtained in step 106 to the decoding end, so that the decoding end decodes the encoding data of the channel level differences of the current frame according to the judgment result. Decoding, by the decoding end, the encoding data of the channel level differences of the current frame according to the judgment result includes:
if the judgment result indicates that the CLDs of the current frame are in the transient state, using, by the decoding end, the first quantization precision to de-quantize the encoding data of the channel level differences of the current frame of the multi-channel signal; and
if the judgment result indicates that the CLDs of the current frame are in the non-transient state, using, by the decoding end, the second quantization precision to de-quantize the encoding data of the channel level differences of the current frame of the multi-channel signal; where,
the first quantization precision is higher than the second quantization precision.
Alternatively, this embodiment may further include:
Step 114: If the judgment result obtained in step 106 indicates that the CLDs of the current frame are in the transient state, send the first quantization precision used in step 108 to the decoding end, so that the decoding end de-quantizes the encoding data of the channel level differences of the current frame of the multi-channel signal according to the first quantization precision.
Step 116: If the judgment result obtained in step 106 indicates that the CLDs of the current frame are in the non-transient state, send the second quantization precision used in step 108 to the decoding end, so that the decoding end de-quantizes the encoding data of the channel level differences of the current frame of the multi-channel signal according to the second quantization precision.
The sequence of the preceding steps in this embodiment may be adjusted according to actual needs. The preceding steps may be executed by the decoding end.
Through the embodiment of the present invention, by judging whether the CLDs of the current frame are in the transient or non-transient state and performing quantization processing on the channel level differences of the current frame of the multi-channel signal according to the judgment result, flexibility in quantizing channel level differences of a multi-channel signal may be improved; by using high quantization precision to quantize the channel level differences of the current frame of the multi-channel signal in the transient state, the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained or improved; by using low quantization precision to quantize the channel level differences of the current frame of the multi-channel signal in the non-transient state, a bit rate may be reduced, and the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained.
As shown in
Step 202: Calculate the sum of CLDs of the current frame of the multi-channel signal in the entire frequency band, that is:
where, c indicates the index number of the current frame, b indicates a frequency band index, M indicates the number of frequency bands in the entire frequency band, CLD(c) [b] indicates the channel level difference of the current frame in the bth frequency band, and CLD(c)_sum indicates the sum of CLDs of the current frame in the entire frequency band.
Step 204: Calculate the sum of CLDs of each frame of N−1 frames before the current frame in the entire frequency band, where the N−1 frames may be consecutive or non-consecutive. To facilitate description, the following takes consecutive N−1 frames as an example. That is:
where, i=c−N+1, c−2, c−1; i indicates the index number of the current frame, b indicates a frequency band index, M indicates the number of frequency bands in the entire frequency band, CLD(i) [b] indicates the channel level difference of the ith frame in the bth frequency band, and CLD(i)_sum indicates the sum of CLDs of the ith frame in the entire frequency band.
Step 206: According to the sum of CLDs of the current frame of the multi-channel signal in the entire frequency band, and the sum of CLDs of the N−1 frames before the current frame in the entire frequency band, calculate an average value of the sums of the CLDs of the total N frames, that is:
where, CLD(Ave
In this step, when the average value is calculated, only the average value of the sums of CLDs of the N−1 frames before the current frame in the entire frequency band may be calculated, without considering the sum of CLDs of the current frame. The calculation method may be flexibly adjusted according to actual situations.
Step 208: Obtain an absolute value of a difference between the sum of CLDs of the current frame obtained through calculation in step 202 and the average value obtained in step 206, that is:
sub=abs(CLD(c)_sum−CLD(Ave
Step 210: Compare the absolute value of the difference obtained in step 208 with the preset threshold Thr (non-negative number); if the absolute value of the difference is greater than the threshold, that is, sub>Thr, determine that the CLDs of the current frame are in the transient state, and go to step 212; if the absolute value of the difference is smaller than the threshold, that is, sub<Thr, determine that the CLDs of the current frame are in the non-transient state, and go to step 214; if the absolute value of the difference is equal to the threshold, that is, sub=Thr, determine that the CLDs of the current frame are in the transient or non-transient state.
Step 212: Use the first quantization precision to quantize the channel level differences of the current frame of the multi-channel signal.
Step 214: Use the second quantization precision to quantize the channel level differences of the current frame of the multi-channel signal.
The channel level differences of the current frame of the multi-channel signal that are quantized in this embodiment may be channel level differences in an entire frequency band or a certain frequency band area.
The first quantization precision is higher than the second quantization precision. For example, the first quantization precision is 5, and the second quantization precision is 1.
The sequence of the preceding steps in this embodiment may be adjusted according to actual needs. The preceding steps may be executed by the decoding end.
Through the embodiment of the present invention, by judging whether the CLDs of the current frame are in the transient or non-transient state, and performing quantization processing on the channel level differences of the current frame of the multi-channel signal according to the judgment result, flexibility in quantizing channel level differences of a multi-channel signal may be improved; by using high quantization precision to quantize the channel level differences of the current frame of the multi-channel signal in the transient state, the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained or improved; by using low quantization precision to quantize the channel level differences of the current frame of the multi-channel signal in the non-transient state, a bit rate may be reduced, and the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained.
This embodiment is based on Embodiment 2. The difference lies in that, in this embodiment, the entire frequency band is divided into two frequency bands: a high frequency band and a low frequency band, and the high frequency band area may be selected to calculate the sum of CLDs. Certainly, the low frequency band area may be also selected to calculate the sum of CLDs.
As shown in
Step 302: Calculate the sum of CLDs of the current frame of the multi-channel signal in the high frequency band area, that is:
where, c indicates the index number of the current frame, b indicates a frequency band index, M indicates the number of frequency bands in the entire frequency band, K indicates the lower cut-off band of the high frequency band area (K<M), CLD(c) [b] indicates the channel level difference of the current frame in the bth frequency band, and CLD(i)_sum indicates the sum of CLDs of the current frame in the high frequency band area.
Step 304: Calculate the sum of CLDs of each frame of N−1 frames before the current frame in the high frequency band area, where the N−1 frames may be consecutive or non-consecutive. To facilitate description, the following takes consecutive N−1 frames as an example. That is:
where, i=c−N+1, . . . , c−2, c−1; i indicates the index number of the current frame, b indicates a frequency band index, M indicates the number of frequency bands in the entire frequency band, K indicates the lower cut-off band of the high frequency band area (K<M), CLD(i) [b] indicates the channel level difference of the ith frame in the bth frequency band, and CLD(c)_sum_h indicates the sum of CLDs of the ith frame in the high frequency band area.
Step 306: According to the sum of CLDs of the current frame in the high frequency band area, and the sum of CLDs of the N−1 frames before the current frame in the high frequency band area, calculate an average value of the sums of the CLDs of the total N frames in the high frequency band area, that is:
where, CLD(Ave
In this step, when the average value is calculated, only the average value of the sums of CLDs of the N−1 frames before the current frame in the high frequency band area may be calculated, without considering the sum of CLDs of the current frame. The calculation method may be flexibly adjusted according to actual situations.
Step 308: Obtain an absolute value of the difference between the sum of CLDs of the current frame of the multi-channel signal obtained through calculation in step 302 and the average value obtained in step 306;
sub=abs(CLD(c)_sum_h−CLD(Ave
Step 310: Compare the absolute value of the difference obtained in step 308 with the preset threshold Thr (non-negative number); if the absolute value of the difference is greater than the threshold, that is, sub>Thr, determine that the CLDs of the current frame are in the transient state, and go to step 312; if the absolute value of the difference is smaller than the threshold, that is, sub<Thr, determine that the CLDs of the current frame are in the non-transient state, and go to step 314; if the absolute value of the difference is equal to the threshold, that is, sub=Thr, determine that the CLDs of the current frame are in the transient or non-transient state.
Step 312: Use the first quantization precision to quantize the channel level differences of the current frame of the multi-channel signal.
Step 314: Use the second quantization precision to quantize the channel level differences of the current frame of the multi-channel signal;
The channel level differences of the current frame of the multi-channel signal that are quantized in this embodiment may be channel level differences in an entire frequency band or a certain frequency band area.
The first quantization precision is higher than the second quantization precision. For example, the first quantization precision is 5, and the second quantization precision is 1.
The sequence of the preceding steps in this embodiment may be adjusted according to actual needs. The preceding steps may be executed by the decoding end.
Through the embodiment of the present invention, by judging whether the CLDs of the current frame are in the transient or non-transient state, and performing quantization processing on the channel level differences of the current frame of the multi-channel signal according to the judgment result, flexibility in quantizing channel level differences of multi-channel signal may be improved; by using high quantization precision to quantize the channel level differences of the multi-channel signal in the transient state, the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained or improved; by using low quantization precision to quantize the channel level differences of the multi-channel signal in the non-transient state, a bit rate may be reduced, and the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained.
This embodiment is based on Embodiment 2 and Embodiment 3. Embodiment 2 is executed to obtain a judgment result D1 when the entire frequency band is selected as the frequency band area for calculating the CLDs; Embodiment 3 is executed to obtain a judgment result D2 when the high frequency band area is selected as the frequency band area for calculating the CLDs. By considering D1 and D2, a final judgment result D3 is obtained.
For example, implement OR on D1 and D2 to obtain D3. Specifically, the following method may be used: if the judgment result indicates the transient state, the value of the judgment result is 1; if the judgment result indicates the non-transient state, the value of the judgment result is 0. Then, when D1 indicates the transient state, that is, D1=1: if D2 indicates the non-transient state, that is, D2=0, D3=D1 or D2=1 or 0=1; if D2 indicates the transient state, that is, D2=1, D3=D1 or D2=1 or 1=1. Then, when D1 indicates the non-transient state, that is, D1=0: if D2 indicates the non-transient state, that is, D2=0, D3=D1 or D2=0 or 0=0; if D2 indicates the transient state, that is, D2=1, D3=D1 or D2=0 or 1=1. That is, as long as one judgment result indicates that the CLDs are in the transient state, the final result is the transient state. Certainly, the value of the transient state may also be 0.
The sequence of the preceding steps in this embodiment may be adjusted according to actual needs. The preceding steps may be executed by the decoding end. The channel level differences of the current frame of the multi-channel signal that are quantized in this embodiment may be channel level differences in an entire frequency band or a certain frequency band area.
Through the embodiment of the present invention, by judging whether the CLDs of the current frame are in the transient or non-transient state, and performing quantization processing on the channel level differences of the current frame of the multi-channel signal according to the judgment result, flexibility in quantizing channel level differences of multi-channel signal may be improved; by using high quantization precision to quantize the CLDs of the multi-channel signal in the transient state, the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained or improved; by using low quantization precision to quantize the channel level differences of the current frame in the non-transient state, a bit rate may be reduced, and the re-establishment quality of the channel level differences of the current frame may be maintained.
As shown in
Step 402: Receive encoding information from an encoding end, where the encoding information indicates whether the CLDs of a current frame of a multi-channel signal are in a transient or non-transient state; if the encoding information indicates that the CLDs of the current frame of the multi-channel signal are in the transient state, go to step 404; if the encoding information indicates that the CLDs of the current frame of the multi-channel signal are in the non-transient state, go to step 406.
Step 404: Use first quantization precision to de-quantize encoding data of the channel level differences of the current frame of the multi-channel signal.
Step 406: Use second quantization precision to de-quantize the encoding data of the channel level differences of the current frame of the multi-channel signal.
The first quantization precision is higher than the second quantization precision. For example, the first quantization precision is 5, and the second quantization precision is 1.
In addition, the encoding information from the encoding end may indicate the quantization precision of the current frame. A decoding end de-quantizes the encoding data of the channel level differences of the current frame according to the quantization precision information.
This embodiment may further include:
Step 400: Receive the encoding data of the channel level differences of the current frame of the multi-channel signal from the encoding end.
The sequence of the preceding steps in this embodiment may be adjusted according to actual needs. The preceding steps may be executed by the decoding end.
Through the embodiment of the present invention, by de-quantizing the encoding data of the channel level differences of the current frame of the multi-channel signal according to the encoding information, flexibility in de-quantizing channel level differences of a multi-channel signal may be improved; by using high quantization precision to de-quantize the encoding data of the channel level differences in the transient state, the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained or improved; by using low quantization precision to de-quantize the encoding data of the channel level differences in the non-transient state, a bit rate may be reduced, and the re-establishment quality of the channel level differences of the current frame may be maintained.
As shown in
a first determining unit 502, configured to determine a sum of channel level differences (CLDs) of a current frame of a multi-channel signal in a certain frequency band area;
a second determining unit 504, configured to determine an average value of sums of channel level differences (CLDs) of at least two frames before the current frame in the certain frequency band area;
a judging unit 506, configured to: according to the sum of the CLDs of the current frame determined by the first determining unit 502, the average value of the sums of the CLDs of the at least two frames before the current frame that is determined by the second determining unit 504, and a preset threshold, judge whether the CLDs of the current frame are in a transient state or a non-transient state, and obtain a judgment result; and
a quantizing unit 508, configured to: according to the judgment result obtained by the judging unit 506, perform quantization processing on the channel level differences of the current frame of the multi-channel signal.
The channel level differences of the current frame of the multi-channel signal that are quantized in this embodiment may be channel level differences in an entire frequency band or a certain frequency band area.
In this embodiment, the certain frequency band area may be an entire frequency band, or a preset partial frequency band area. For example, an entire frequency band is divided into two frequency bands: a high frequency band and a low frequency band. The sum of the CLDs of the current frame of the multi-channel signal in the high frequency band area is calculated. In this embodiment, the at least two frames before the current frame may be at least two frames that include the current frame, or at least two frames that do not include the current frame.
As shown in
a calculating unit 602, configured to obtain an absolute value of the difference between the sum of the CLDs of the current frame of the multi-channel signal that is determined by the first determining unit 502 and the average value determined by the second determining unit 504; and
a comparing unit 604, configured to compare the absolute value of the difference obtained by the calculating unit 602 with the preset threshold; if the absolute value of the difference is greater than the threshold, determine that the CLDs of the current frame are in the transient state; and if the absolute value of the difference is smaller than the threshold, determine that the CLDs of the current frame are in the non-transient state.
As shown in
a first quantizing unit 702, configured to use first quantization precision to quantize the channel level differences of the current frame of the multi-channel signal when the judging unit 506 determines that the CLDs of the current frame are in the transient state; and
a second quantizing unit 704, configured to use second quantization precision to quantize the channel level differences of the current frame of the multi-channel signal when the judging unit 506 determines that the CLDs of the current frame are in the non-transient state; where,
the first quantization precision is higher than the second quantization precision. For example, the first quantization precision is 5, and the second quantization precision is 1.
As shown in
a judgment result sending unit 802, configured to send the judgment result obtained by the judging unit 506 to a decoding end, so that the decoding end decodes encoding data of the channel level differences of the current frame according to the judgment result.
As shown in
a quantization precision information sending unit 902, configured to: when the judging unit 506 determines that the CLDs of the current frame are in the transient state, send first quantization precision to the decoding end, so that the decoding end de-quantizes the encoding data of the channel level differences of the current frame of the multi-channel signal according to the first quantization precision; and when the judging unit 506 determines that the CLDs of the current frame are in the non-transient state, send the second quantization precision to the decoding end, so that the decoding end de-quantizes the encoding data of the channel level differences of the current frame of the multi-channel signal according to the second quantization precision.
The multi-channel signal encoding apparatus in this embodiment may further include: an encoding data sending unit, configured to send the encoding data of the channel level differences of the current frame of the multi-channel signal quantized by the quantizing unit 508 to the decoding end.
Other details about the multi-channel signal encoding apparatus in this embodiment are similar to those about multi-channel signal encoding methods in Embodiment 1 to Embodiment 4.
All the units in this embodiment may be integrated or separately deployed. The preceding unit may be combined into one unit, or further divided into a plurality of sub units. The encoding apparatus in this embodiment may be integrated in a circuit or chip, including CPU, digital signal processing (Digital Signal Processing, DSP), or communication chip; or may be a mobile phone, an audio processing device, a computer, or a server.
Through the embodiment of the present invention, by judging whether the CLDs of the current frame are in the transient or non-transient state, and performing quantization processing on the channel level differences of the current frame of the multi-channel signal according to the judgment result, flexibility in quantizing channel level differences of a multi-channel signal may be improved; by using high quantization precision to quantize the channel level differences of the current frame of the multi-channel signal in the transient state, the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained or improved; by using low quantization precision to quantize the channel level differences of the current frame in the non-transient state, a bit rate may be reduced, and the re-establishment quality of the channel level differences of the current frame may be maintained.
As shown in
a receiving unit 1002, configured to receive encoding information from an encoding end, where the encoding information indicates whether CLDs of a current frame are in a transient state or a non-transient state; and
a de-quantizing unit 1004, configured to: when the encoding information indicates that the CLDs of the current frame are in the transient state, use first quantization precision to de-quantize encoding data of the channel level differences of the current frame of a multi-channel signal; and when the encoding information indicates that the CLDs of the current frame are in the non-transient state, use second quantization precision to de-quantize the encoding data of the channel level differences of the current frame of the multi-channel signal; where,
the first quantization precision is higher than the second quantization precision. For example, the first quantization precision is 5, and the second quantization precision is 1.
In addition, the receiving unit 1002 may be configured to receive information that indicates quantization precision of the current frame from the encoding end, and the de-quantizing unit 1004 may be configured to de-quantize the encoding data of the channel level differences of the current frame according to the information. The receiving unit 1002 may also be configured to receive the encoding data of the channel level differences of the current frame from the encoding end. Other details about the multi-channel signal decoding apparatus in this embodiment are similar to those in the fifth embodiment.
Through the embodiment of the present invention, by de-quantizing the encoding data of the channel level differences of the current frame of the multi-channel signal according to the encoding information, flexibility in de-quantizing channel level differences of a multi-channel signal may be improved; by using high quantization precision to de-quantize the encoding data of the channel level differences in the transient state, the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained or improved; by using low quantization precision to de-quantize the encoding data of the channel level differences in the non-transient state, a bit rate may be reduced, and the re-establishment quality of the channel level differences of the current frame may be maintained.
All the units in this embodiment may be integrated or separately deployed. The preceding unit may be combined into one unit, or further divided into a plurality of sub units. The encoding apparatus in this embodiment may be integrated in a circuit or chip, including CPU, digital signal processing (Digital Signal Processing, DSP), or communication chip; or may be a mobile phone, audio processing device, computer, or server.
As shown in
an encoding end 1102, configured to: determine a sum of channel level differences (CLDs) of a current frame of a multi-channel signal in a certain frequency band area; determine an average value of sums of channel level differences (CLDs) of at least two frames before the current frame in the certain frequency band area; according to the sum of CLDs of the current frame, the average value of the sums of CLDs of at least two frames before the current frame, and a preset threshold, judge whether the CLDs of the current frame are in a transient state or a non-transient state, and obtain a judgment result; according to the judgment result, perform quantization processing on the channel level differences of the current frame of the multi-channel signal to obtain encoding data of channel level differences of the current frame; and send the judgment result to a decoding end; and
a decoding end 1104, configured to receive the encoding data of the channel level differences of the current frame and the judgment result from the encoding end, and de-quantize the encoding data of the channel level differences of the current frame according to the judgment result.
If the judgment result information indicates that the CLDs of the current frame are in the transient state, the decoding end 1104 uses first quantization precision to de-quantize the encoding data of the channel level differences of the current frame of the multi-channel signal; and if the judgment result information indicates that the CLDs of the current frame are in the non-transient state, the decoding end 1104 uses second quantization precision to de-quantize the encoding data of the channel level differences of the current frame of the multi-channel signal; the first quantization precision is higher than the second quantization precision. For example, the first quantization precision is 5, and the second quantization precision is 1. The channel level differences of the current frame of the multi-channel signal that are quantized in this embodiment may be channel level differences in an entire frequency band or a certain frequency band area.
Other details about the encoding end and decoding end in this embodiment are similar to those in Embodiment 1 to Embodiment 8.
All the units in this embodiment may be integrated or separately deployed. The preceding unit may be combined into one unit, or further divided into a plurality of sub units. The encoding and decoding system in this embodiment may be applied to a mobile phone, an audio processing device, a computer, or a server.
The multi-channel signal in this embodiment include a multi-channel signal such as stereo, 5.1 audio channels, 7.1 audio channels, and 10.2 audio channels.
Through the embodiment of the present invention, by judging whether the CLDs of the current frame are in the transient or non-transient state, and performing quantization processing on the channel level differences of the current frame of the multi-channel signal according to the judgment result, flexibility in quantizing channel level differences of multi-channel signal may be improved; by using high quantization precision to quantize the CLDs of the current frame in the transient state, the re-establishment quality of the channel level differences of the current frame of the multi-channel signal may be maintained or improved; by using low quantization precision to quantize the channel level differences of the current frame in the non-transient state, a bit rate may be reduced, and the re-establishment quality of the channel level differences of the current frame may be maintained.
The units, algorithms, and steps in each example described in the public embodiments of the present invention may be implemented by electronic hardware, computer software, or combination of both. To clearly describe the changeability of the hardware and software, the composition and steps of each example are generally described according to functions in the preceding description. Whether these functions are executed through hardware or software depends on the specific applications and design constraints of the technical scheme. Those skilled in the art may use different methods to implement the described functions for each specific application. However, such implementation should not be considered as beyond the scope of the present invention.
The steps of the methods or algorithms described in the public embodiments of the present invention may be implemented by hardware, software modules executed by the processor, or a combination of both. The software module may be placed in a random access memory (RAM), memory, read only memory (ROM), electrically programmable ROM, electrically erasable and programmable ROM, register, hard disk, mobile disk, CD-ROM, or any other form of storage medium.
The above are merely specific embodiments of the present invention. However, the scope of the present invention is not limited thereto. Changes or replacements readily apparent to those skilled in the prior art within the technical scope of the present invention should fall within the scope of the present invention. Therefore, the protection scope of the present invention is subject to the appended claims.
Number | Date | Country | Kind |
---|---|---|---|
2010 1 0113634 | Feb 2010 | CN | national |
This application is a continuation of International Application No. PCT/CN2010/079167, filed on Nov. 26, 2010, which claims priority to Chinese Patent Application No. 201010113634.X, filed on Feb. 11, 2010, both of which are hereby incorporated by reference in their entireties.
Number | Name | Date | Kind |
---|---|---|---|
6741965 | Shimoyoshi et al. | May 2004 | B1 |
7719445 | Jung et al. | May 2010 | B2 |
20070242833 | Herre et al. | Oct 2007 | A1 |
20080167880 | Seo et al. | Jul 2008 | A1 |
20080252510 | Jung et al. | Oct 2008 | A1 |
20110224994 | Norvell et al. | Sep 2011 | A1 |
Number | Date | Country |
---|---|---|
1228236 | Sep 1999 | CN |
1477872 | Feb 2004 | CN |
101223598 | Jul 2008 | CN |
101421779 | Apr 2009 | CN |
101427307 | May 2009 | CN |
20100007750 | Jan 2010 | KR |
2007011157 | Jan 2007 | WO |
2007037621 | Apr 2007 | WO |
Entry |
---|
International search report for International application No. PCT/CN2010/079167, dated Mar. 3, 2011, total 5 pages. |
Foreign Communication From A Counterpart Application, PCT Application No. PCT/CN2010/079167, Written Opinion dated Mar. 3, 2011, 6 pages. |
Number | Date | Country | |
---|---|---|---|
20120265543 A1 | Oct 2012 | US |
Number | Date | Country | |
---|---|---|---|
Parent | PCT/CN2010/079167 | Nov 2010 | US |
Child | 13530819 | US |