Embodiment
For the purpose, technical scheme and the advantage that make the embodiment of the invention clearer, below in conjunction with the accompanying drawing in the embodiment of the invention, technical scheme in the embodiment of the invention is clearly and completely described, obviously, described embodiment is the present invention's part embodiment, rather than whole embodiment.Based on the embodiment among the present invention, the every other embodiment that those of ordinary skills obtain under the prerequisite of not making creative work belongs to the scope of protection of the invention.
The embodiment of the invention provides a kind of generation method of lower mixed signal, and method comprises:
The left channel signals that receives and right-channel signals are carried out time-frequency conversion obtain frequency-region signal, described frequency-region signal is divided into some frequency bands;
Calculate the channel energies of each frequency band than (Channel Level Difference, CLD) and sound channel phase differential (Internal Phase Difference, IPD), described channel energies has been than having reflected left channel signals and the right-channel signals energy Ratios information at each frequency band, and described sound channel phase differential has reflected that left channel signals and right-channel signals are at the phase information of each frequency band;
According to mixed signal and the first sound channel signal are at the phase differential of each frequency band under channel energies ratio and the sound channel phase difference calculating, described the first sound channel signal is described left channel signals or described right-channel signals;
According to described left channel signals, right-channel signals, described lower mixed signal and the first sound channel signal mixed signal under the phase difference calculating frequency domain of each frequency band.
Please refer to accompanying drawing 1, Fig. 1 is the process flow diagram that is generated an embodiment of lower mixed signal method by left channel signals and right-channel signals, and step comprises:
S101 carries out time-frequency conversion to the left channel signals that receives and right-channel signals and obtains frequency-region signal, and described frequency-region signal is divided into some frequency bands;
S103 calculates channel energies ratio and the sound channel phase differential of each frequency band;
Mixed signal and the first sound channel signal were at the phase differential of each frequency band under S105 calculated;
S107 calculates mixed signal under the frequency domain.
S101 carries out time-frequency conversion to left channel signals and right-channel signals, in concrete implementation method, can use Fourier transform (Fourier Transform, FT), fast fourier transform (Fast Fourier Transform, the transform methods such as FFT), orthogonal mirror image conversion (Quadrature Mirror Filterbanks, QMF).Left channel signals and right-channel signals transform to frequency domain, obtain respectively L (k) and R (k).
Frequency-region signal is divided into some frequency bands, and in one embodiment of the invention, frequency span is 1.If k is the Frequency point index, b is band index, and kb is the initial frequency point index of b frequency band.
S103 calculates CLD and the IPD of each frequency band, comprises according to following formula calculating:
IPD (b)=∠ cor (b), wherein
Wherein, X1 (k) is left channel signals, and X2 (k) is right-channel signals.
Mixed signal and the first sound channel signal were at the phase differential of each frequency band under S105 calculated.
Embodiment 1: in one embodiment of the invention, the first sound channel is L channel.
Described lower mixed signal and left channel signals are calculated according to following formula at the phase differential of each frequency band:
C (b)=10 wherein
CLD (b) 10
CLD (b) is the described channel energies ratio of b frequency band, c (b) is for the intermediate value variable that calculates, IPD (b) is the described sound channel phase differential of b frequency band, and θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
The left channel signals energy is larger, and the phase differential of described lower mixed signal and L channel is less; And when the R channel energy was larger, the phase differential of lower mixed signal and L channel was larger, and the phase differential of lower mixed signal and right channel is less.Lower mixed signal becomes positive relationship with the phase differential of L channel with the left channel signals energy, lower mixed signal becomes inverse relationship with the phase differential of L channel with the R channel energy, and lower mixed signal becomes positive relationship with the phase differential of L channel with the sound channel phase differential.
S107 calculates mixed signal under the frequency domain, and mixed signal calculates according to following formula under the described frequency domain:
K is the Frequency point index, L
r(k) be the real part of k Frequency point of left channel signals time-frequency conversion, L
i(k) be the imaginary part of k Frequency point of left channel signals time-frequency conversion, R
Mag(k) be the amplitude of k Frequency point of right-channel signals time-frequency conversion, L
Mag(k) be the amplitude of k Frequency point of left channel signals time-frequency conversion, M
i(k) be the real part of k Frequency point of lower mixed signal time-frequency conversion, M
r(k) be the imaginary part of k Frequency point of lower mixed signal time-frequency conversion, θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
Embodiment 2: in another embodiment of the present invention, the first sound channel is R channel.
Described lower mixed signal and right-channel signals are calculated according to following formula at the phase differential of each frequency band:
C (b)=10 wherein
CLD (b) 10
CLD (b) is the described channel energies ratio of b frequency band, c (b) is for the intermediate value variable that calculates, IPD (b) is the described sound channel phase differential of b frequency band, and θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
The left channel signals energy is larger, and the phase differential of described lower mixed signal and R channel is larger, and the phase differential of lower mixed signal and L channel is less; And when the R channel energy was larger, the phase differential of lower mixed signal and R channel was less.Described lower mixed signal becomes inverse relationship with the phase differential of R channel with the energy of R channel, and described lower mixed signal becomes positive relationship with the phase differential of R channel with the energy of L channel, becomes positive relationship with described sound channel phase differential.
S107 calculates mixed signal under the frequency domain, and mixed signal calculates according to following formula under the described frequency domain:
K is the Frequency point index, L
r(k) be the real part of k Frequency point of left channel signals time-frequency conversion, L
i(k) be the imaginary part of k Frequency point of left channel signals time-frequency conversion, R
Mag(k) be the amplitude of k Frequency point of right-channel signals time-frequency conversion, L
Mag(k) be the amplitude of k Frequency point of left channel signals time-frequency conversion, M
i(k) be the real part of k Frequency point of lower mixed signal time-frequency conversion, M
r(k) be the imaginary part of k Frequency point of lower mixed signal time-frequency conversion, θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
Embodiment 3: in another embodiment of the present invention, the first sound channel is the larger sound channel of signal amplitude in L channel and the R channel.
If the amplitude of left channel signals is greater than the amplitude of right-channel signals, the first sound channel is L channel, and the phase differential of the sound channel that signal amplitude is larger in lower mixed signal and described L channel and the R channel calculates according to following formula:
C (b)=10 wherein
CLD (b)/10
S107 calculates mixed signal under the frequency domain, and mixed signal calculates according to following formula under the described frequency domain:
K is the Frequency point index, L
r(k) be the real part of k Frequency point of left channel signals time-frequency conversion, L
i(k) be the imaginary part of k Frequency point of left channel signals time-frequency conversion, R
Mag(k) be the amplitude of k Frequency point of right-channel signals time-frequency conversion, L
Mag(k) be the amplitude of k Frequency point of left channel signals time-frequency conversion, M
i(k) be the real part of k Frequency point of lower mixed signal time-frequency conversion, M
r(k) be the imaginary part of k Frequency point of lower mixed signal time-frequency conversion, θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
If the amplitude of right-channel signals is greater than the amplitude of left channel signals, the first sound channel is R channel, and the phase differential of the sound channel that signal amplitude is larger in lower mixed signal and described L channel and the R channel calculates according to following formula:
C (b)=10 wherein
CLD (b)/10
S107 calculates mixed signal under the frequency domain, and mixed signal calculates according to following formula under the described frequency domain:
K is the Frequency point index, L
r(k) be the real part of k Frequency point of left channel signals time-frequency conversion, L
i(k) be the imaginary part of k Frequency point of left channel signals time-frequency conversion, R
Mag(k) be the amplitude of k Frequency point of right-channel signals time-frequency conversion, L
Mag(k) be the amplitude of k Frequency point of left channel signals time-frequency conversion, M
i(k) be the real part of k Frequency point of lower mixed signal time-frequency conversion, M
r(k) be the imaginary part of k Frequency point of lower mixed signal time-frequency conversion, θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
The lower mixed signal creating method of the embodiment of the invention not only has the advantage of embodiment 1 and embodiment 2, can also effectively solve the problem of the stereo lower mixcibility energy of the very fast impact of small-signal phase tranformation.
Embodiment 4: among another embodiment of the present invention, described according to channel energies than and the sound channel phase difference calculating under mix signal and the phase differential of the first sound channel signal at each frequency band after, also comprise: the phase differential of described lower mixed signal and the first sound channel upgrades according to the faciation position, and the frequency domain envelope similarity of left channel signals and right-channel signals has been reflected in described faciation position.
In one embodiment of the invention, group's phase theta
gIt is the average of each frequency band IPD.
If the first sound channel is L channel: described lower mixed signal and left channel signals are calculated according to following formula at the phase differential of each frequency band:
C (b)=10 wherein
CLD (b)/10
CLD (b) is the described channel energies ratio of b frequency band, c (b) is for the intermediate value variable that calculates, IPD (b) is the described sound channel phase differential of b frequency band, and θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
The left channel signals energy is larger, and the phase differential of described lower mixed signal and L channel is less; And when the R channel energy was larger, the phase differential of lower mixed signal and R channel was less.
S107 calculates mixed signal under the frequency domain, and mixed signal calculates according to following formula under the described frequency domain:
K is the Frequency point index, L
r(k) be the real part of k Frequency point of left channel signals time-frequency conversion, L
i(k) be the imaginary part of k Frequency point of left channel signals time-frequency conversion, R
Mag(k) be the amplitude of k Frequency point of right-channel signals time-frequency conversion, L
Mag(k) be the amplitude of k Frequency point of left channel signals time-frequency conversion, M
i(k) be the real part of k Frequency point of lower mixed signal time-frequency conversion, M
r(k) be the imaginary part of k Frequency point of lower mixed signal time-frequency conversion, θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
If the first sound channel is R channel, described lower mixed signal and right-channel signals are calculated according to following formula at the phase differential of each frequency band:
C (b)=10 wherein
CLD (b)/10
The left channel signals energy is larger, and the phase differential of described lower mixed signal and left channel signals is less; And when the R channel energy was larger, the phase differential of lower mixed signal and right-channel signals was less.
S107 calculates mixed signal under the frequency domain, and mixed signal calculates according to following formula under the described frequency domain:
K is the Frequency point index, L
r(k) be the real part of k Frequency point of left channel signals time-frequency conversion, L
i(k) be the imaginary part of k Frequency point of left channel signals time-frequency conversion, R
Mag(k) be the amplitude of k Frequency point of right-channel signals time-frequency conversion, L
Mag(k) be the amplitude of k Frequency point of left channel signals time-frequency conversion, M
i(k) be the real part of k Frequency point of lower mixed signal time-frequency conversion, M
r(k) be the imaginary part of k Frequency point of lower mixed signal time-frequency conversion, θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
After the mixed signal, the method for the embodiment of the invention also comprises under described S107 calculating frequency domain:
Obtain mixed signal under the time domain of lower mixed signal by frequency-time domain transformation;
Obtain under the time domain the lower mixed monophony bit stream of mixed signal by the monophony scrambler, G.711.1 the monophony scrambler of the embodiment of the invention comprises ITU-T or G.722 waits.
When the frequency domain conversion of using in described monophony scrambler and the lower mixed signal is identical, can not need carries out frequency-time domain transformation and directly mixed signal under the frequency domain is encoded.
In order to keep coding side and decoding end CLD, the consistance of IPD, the embodiment of the invention adopts the CLD after quantizing, and IPD carries out lower mixed.The stereo parameter bit stream that CLD after the quantification, IPD obtain, and lower mixed monophony bit stream sends to decoding end in the lump.
The embodiment of the invention provides a kind of generating apparatus of lower mixed signal, comprising: 201 time-frequency conversion unit: be used for that the left channel signals that receives and right-channel signals are carried out time-frequency conversion and obtain frequency-region signal, described frequency-region signal is divided into some frequency bands; 203 frequency band computing units: the channel energies ratio and the sound channel phase differential that are used for calculating each frequency band, described channel energies has been than having reflected left channel signals and the right-channel signals energy Ratios information at each frequency band, and described sound channel phase differential has reflected that left channel signals and right-channel signals are at the phase information of each frequency band; 205 phase difference calculating unit: be used for according to channel energies than and the described lower mixed signal of sound channel phase difference calculating and the first sound channel signal at the phase differential of each frequency band, described the first sound channel signal is described left channel signals or described right-channel signals; Mixed signature computation unit under the frequency domain: 207 times mixed signature computation unit are used for according to described left channel signals, right-channel signals, described lower mixed signal and the first sound channel signal mixed signal under the phase difference calculating frequency domain of each frequency band.
Described 205 phase difference calculating unit be used for according to channel energies than and the described lower mixed signal of sound channel phase difference calculating and the first sound channel signal comprise at the phase differential of each frequency band: be used for according to channel energies compares and the described lower mixed signal of sound channel phase difference calculating and L channel and R channel signal amplitude the are larger sound channel signal phase differential at each frequency band.
When described the first sound channel is described L channel, described phase difference calculating unit be used for according to channel energies than and the described lower mixed signal of sound channel phase difference calculating and the first sound channel signal specifically comprise at the phase differential of each frequency band, according to following formula calculating:
c(b)=10
CLD(b)/10;
Wherein, CLD (b) is the described channel energies ratio of b frequency band, c (b) is that IPD (b) is the described sound channel phase differential of b frequency band for the intermediate value variable that calculates, and θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
When the first sound channel was described R channel, described phase difference calculating unit was used for specifically comprising at the phase differential of each frequency band according to mixed signal and the first sound channel signal under channel energies ratio and the sound channel phase difference calculating, calculates according to following formula:
c(b)=10
CLD(b)/10;
CLD (b) is the described channel energies ratio of b frequency band, c (b) is for the intermediate value variable that calculates, IPD (b) is the described sound channel phase differential of b frequency band, and θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
Described phase difference calculating unit mixes signal and the phase differential of the first sound channel signal at each frequency band under being used for according to channel energies ratio and sound channel phase difference calculating after, also be used for: the phase differential of described lower mixed signal and the first sound channel is upgraded according to the faciation position, and the frequency domain envelope similarity of left channel signals and right-channel signals has been reflected in described faciation position.
When described the first sound channel is described L channel, described lower mixed signature computation unit, be used for specifically comprising according to described left channel signals, right-channel signals, described lower mixed signal and the first sound channel signal mixed signal under the phase difference calculating frequency domain of each frequency band, calculate according to following formula:
K is the Frequency point index, L
r(k) be the real part of k Frequency point of left channel signals time-frequency conversion, L
i(k) be the imaginary part of k Frequency point of left channel signals time-frequency conversion, R
Mag(k) be the amplitude of k Frequency point of right-channel signals time-frequency conversion, L
Mag(k) be the amplitude of k Frequency point of left channel signals time-frequency conversion, M
i(k) be the real part of k Frequency point of lower mixed signal time-frequency conversion, M
r(k) be the imaginary part of k Frequency point of lower mixed signal time-frequency conversion, θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
When described the first sound channel is described R channel, describedly state lower mixed signature computation unit, be used for specifically comprising according to described left channel signals, right-channel signals, described lower mixed signal and the first sound channel signal mixed signal under the phase difference calculating frequency domain of each frequency band, calculate according to following formula:
Wherein, k is the Frequency point index, R
r(k) be the real part of k Frequency point of right-channel signals time-frequency conversion, R
i(k) be the imaginary part of k Frequency point of right-channel signals time-frequency conversion, R
Mag(k) be the amplitude of k Frequency point of right-channel signals time-frequency conversion, L
Mag(k) be the amplitude of k Frequency point of left channel signals time-frequency conversion, M
i(k) be the real part of k Frequency point of lower mixed signal time-frequency conversion, M
r(k) be the imaginary part of k Frequency point of lower mixed signal time-frequency conversion, θ (b) is that described lower mixed signal and the first sound channel signal are at the phase differential of b frequency band.
The embodiment of the invention has proposed a kind of method of reducing of lower mixed signal, and as shown in Figure 3, Fig. 3 provides the process flow diagram of an embodiment of the inventive method, comprising:
S301 calculates respectively the frequency-region signal amplitude of left channel signals, the frequency-region signal amplitude of right-channel signals according to the frequency-region signal amplitude of described lower mixed signal, the channel energies ratio of reception;
S303 according to the channel energies of the frequency-region signal phase place of described lower mixed signal, reception than and the sound channel phase difference do not calculate the frequency-region signal phase place of left channel signals, the frequency-region signal phase place of right-channel signals, described sound channel phase differential has reflected that left channel signals and right-channel signals are at the phase information of each frequency band;
S305 is according to the frequency-region signal amplitude of left channel signals, the frequency-region signal of the synthetic left channel signals of frequency-region signal phase place, according to the frequency-region signal amplitude of right-channel signals, the frequency-region signal of the synthetic right-channel signals of frequency-region signal phase place.
In one embodiment of the invention, obtain lower mixed monophony time-domain signal by the mono decoder decoding, obtain stereo parameter CLD, IPD by the de-quantizer decoding.Lower mixed time-domain signal can obtain frequency-region signal by time-frequency conversion.
The channel energies of the described frequency-region signal amplitude according to described lower mixed signal of S301, reception is calculated the frequency-region signal amplitude of left channel signals than respectively, the frequency-region signal amplitude of right-channel signals specifically comprises, calculates according to following formula:
c(b)=10
CLD(b)/10,
Wherein, k is the Frequency point index, CLD (b) is that described channel energies is than the channel energies ratio at b frequency band, c (b) is for the intermediate value variable that calculates, | M (k) | be that lower mixed signal M (k) is in the frequency-region signal amplitude of Frequency point k, | L (k) | be L channel road signal L (k) in the frequency-region signal amplitude of Frequency point k, | R (k) | be that right-channel signals R (k) is in the frequency-region signal amplitude of Frequency point k.
The described frequency-region signal phase place according to lower mixed signal of S303, channel energies than and the sound channel phase difference does not calculate the frequency-region signal phase place of left channel signals, the frequency-region signal phase place of right-channel signals specifically comprises, calculate according to following formula:
c(b)=10
CLD(b)/10
C (b) is for the intermediate value variable that calculates, IPD (b) is that described sound channel phase differential is at the sound channel phase differential of b frequency band, ∠ M (k) is that lower mixed signal M (k) is in the frequency-region signal phase place of Frequency point k, ∠ L (k) be left channel signals L (k) in the frequency-region signal phase place of Frequency point k, ∠ R (k) is that right-channel signals R (k) is in the frequency-region signal phase place of Frequency point k.
In one embodiment of the invention, the value of IPD (pi, pi].
Synthesize the frequency-region signal of left channel signals at S305 according to frequency-region signal amplitude, frequency-region signal phase place according to left channel signals, after the frequency-region signal according to the frequency-region signal amplitude of right-channel signals, the synthetic right-channel signals of frequency-region signal phase place, frequency-region signal obtains left and right acoustic channels time solution coded signal by frequency-time domain transformation.
The embodiment of the invention provides a kind of reduction apparatus of lower mixed signal, comprise: 401 signal amplitude computing units: be used for calculating the frequency-region signal amplitude of left channel signals, the frequency-region signal amplitude of right-channel signals according to the frequency-region signal amplitude of described lower mixed signal, the channel energies of reception than respectively, described sound channel amount is than having reflected left channel signals and the right-channel signals energy Ratios information at each frequency band; 403 signal phase computing units: the channel energies that is used for frequency-region signal phase place, reception according to described lower mixed signal than and the sound channel phase difference do not calculate the frequency-region signal phase place of left channel signals, the frequency-region signal phase place of right-channel signals, described sound channel phase differential has reflected that left channel signals and right-channel signals are at the phase information of each frequency band; 405 frequency-region signal synthesis units: be used for the frequency-region signal amplitude according to left channel signals, the frequency-region signal of the synthetic left channel signals of frequency-region signal phase place, according to the frequency-region signal amplitude of right-channel signals, the frequency-region signal of the synthetic right-channel signals of frequency-region signal phase place.
401 described signal amplitude computing units are used for that the channel energies of frequency-region signal amplitude, reception according to described lower mixed signal is calculated the frequency-region signal amplitude of left channel signals than respectively, the frequency-region signal amplitude of right-channel signals specifically comprises, according to following formula calculating:
c(b)=10
CLD(b)/10,
Wherein, k is the Frequency point index, CLD (b) is that described channel energies is than the channel energies ratio at b frequency band, c (b) is for the intermediate value variable that calculates, | M (k) | be that lower mixed signal M (k) is in the frequency-region signal amplitude of Frequency point k, | L (k) | be L channel road signal L (k) in the frequency-region signal amplitude of Frequency point k, | R (k) | be that right-channel signals R (k) is in the frequency-region signal amplitude of Frequency point k.
403 described signal phase computing units are used for frequency-region signal phase place, the channel energies ratio according to lower mixed signal and the sound channel phase difference does not calculate the frequency-region signal phase place of left channel signals, the frequency-region signal phase place of right-channel signals specifically comprises, calculate according to following formula:
c(b)=10
CLD(b)/10
C (b) is for the intermediate value variable that calculates, IPD (b) is that described sound channel phase differential is at the sound channel phase differential of b frequency band, ∠ M (k) is that lower mixed signal M (k) is in the frequency-region signal phase place of Frequency point k, ∠ L (k) be left channel signals L (k) in the frequency-region signal phase place of Frequency point k, ∠ R (k) is that right-channel signals R (k) is in the frequency-region signal phase place of Frequency point k.
It will be appreciated by those skilled in the art that the module in the device among the embodiment can be distributed in the device of embodiment according to the embodiment description, also can carry out respective change and be arranged in the one or more devices that are different from present embodiment.The module of above-described embodiment can be merged into a module, also can further split into a plurality of submodules.
It should be noted that at last: above embodiment only in order to technical scheme of the present invention to be described, is not intended to limit; Although with reference to previous embodiment the present invention is had been described in detail, those of ordinary skill in the art is to be understood that: it still can be made amendment to the technical scheme that aforementioned each embodiment puts down in writing, and perhaps part technical characterictic wherein is equal to replacement; And these modifications or replacement do not make the essence of appropriate technical solution break away from the spirit and scope of various embodiments of the present invention technical scheme.