US 11,869,517 B2
Downmixed signal calculation method and apparatus
Haiting Li, Beijing (CN); Zexin Liu, Beijing (CN); and Bin Wang, Beijing (CN)
Assigned to Huawei Technologies Co., Ltd., Shenzhen (CN)
Filed by HUAWEI TECHNOLOGIES CO., LTD., Guangdong (CN)
Filed on Nov. 23, 2020, as Appl. No. 17/102,190.
Application 17/102,190 is a continuation of application No. PCT/CN2019/070116, filed on Jan. 2, 2019.
Claims priority of application No. 201810549905.2 (CN), filed on May 31, 2018.
Prior Publication US 2021/0082441 A1, Mar. 18, 2021
Int. Cl. G10L 19/008 (2013.01); G10L 25/18 (2013.01); G10L 25/21 (2013.01); H04S 1/00 (2006.01)
CPC G10L 19/008 (2013.01) [G10L 25/18 (2013.01); G10L 25/21 (2013.01); H04S 1/007 (2013.01); H04S 2420/03 (2013.01)] 12 Claims
OG exemplary drawing
 
1. A downmixed signal calculation method, comprising:
determining that a first condition or a second condition is true, wherein determining that the first condition is true comprises determining that a previous frame of a current frame of a stereo audio signal is not a switching frame based on a switching flag of the previous frame and determining that a residual signal in the previous frame does not need to be encoded based on a coding flag of the previous frame, and determining that the second condition is true comprises determining that the current frame is not a switching frame based on a switching flag of the current frame and a residual signal in the current frame does not need to be encoded based on a coding flag of the current frame;
in response to the determining that the first condition or the second condition is true, calculating a first downmixed signal in the current frame, wherein the calculating comprises:
obtaining a second downmixed signal in the current frame;
obtaining a downmix compensation factor of the current frame, wherein the obtaining the downmix compensation factor of the current frame comprises:
calculating a downmix compensation factor in a subframe of the current frame based on a first flag, wherein the first flag indicates whether a stereo parameter other than an inter-channel time difference parameter needs to be encoded in the current frame, the current frame comprises P subframes, and the downmix compensation factor of the current frame comprises the downmix compensation factor of the subframe i of the current frame, wherein both P and i are integers, P≥2, and i∈[0, P−1]; wherein a second frequency-domain signal in the subframe i of the current frame is a left channel frequency-domain signal in the subframe i of the current frame, and the calculating the downmix compensation factor of the subframe i of the current frame comprises:
calculating the downmix compensation factor of the subframe i of the current frame based on the left channel frequency-domain signal in the subframe i of the current frame and a right channel frequency-domain signal in the subframe i of the current frame, wherein
a downmix compensation factor αi(b) in a subband b in the subframe i of the current frame is calculated according to the following formula:
αi(b)=√E_Li(b)+√E_Ri(b)−√E_LRi(b)/2 √E_Li(b)
E_Li(b)=Σk=band_limits(b)k=band_limits(b+1)−1Lib″(k)2,
E_Ri(b)=Σk=band_limits(b)k=band_limits(b+1)−1Rib″(k)2, and
E_LRi(b)=Σk=band_limits(b)k=band_limits(b+1)−1[Lib″(k)2+Rib″(k)]2; or
E_Li(b)=Σk=band_limits(b)k=band_limits(b+1)−1Lib′(k)2,
E_Ri(b)=Σk=band_limits(b)k=band_limits(b+1)−1Rib′(k)2, and
E_LRi(b)=Σk=band_limits(b)k=band_limits(b+1)−1[Lib′(k)+Rib′(k)]2; wherein
E_Li(b) represents an energy sum of a left channel frequency-domain signal in the subband b in the subframe i of the current frame; E_Ri(b) represents an energy sum of a right channel frequency-domain signal in the subband b in the subframe i of the current frame; E_LRi(b) represents an energy sum of the energy of the left channel frequency-domain signal and the energy of the right channel frequency-domain signal in the subband b in the subframe of the current frame; band_limits(b) represents a minimum frequency bin index value of the subband b in the subframe i of the current frame; band_limits(b+1) represents a minimum frequency bin index value of a subband b+1 in the subframe i of the current frame; Lib″(k) represents a left channel frequency-domain signal that is in the subband b in the subframe i of the current frame and that is obtained after adjustment based on a stereo parameter; Rib″(k) represents a right channel frequency-domain signal that is in the subband b in the subframe i of the current frame and that is obtained after adjustment based on the stereo parameter; Lib′(k) represents a left channel frequency-domain signal that is in the subband b in the subframe i of the current frame and that is obtained after time-shift adjustment: Rib′(k) represents a right channel frequency-domain signal that is in the subband b in the subframe i of the current frame and that is obtained after time-shift adjustment and k represents a frequency bin index value, wherein each subframe of the current frame comprises M subbands, the downmix compensation factor of the subframe i of the current frame comprises the downmix compensation factor of the subband b in the subframe i of the current frame, b is an integer, b∈[0, M−1], and M≥2; and
the calculating a compensated downmixed signal in a subframe i of the current frame comprises:
calculating a compensated downmixed signal in the subband b in the subframe i of the current frame according to the following formula:
DMX_compib(k)=αi(b)*Lib″(k), wherein
DMX_compib(ik) represents the compensated downmixed signal in the subband b in the subframe i of the current frame, k represents a frequency bin index value, and k∈[band_limits(b), band_limits(b+1)−1]; and
correcting the second downmixed signal in the current frame based on the downmix compensation factor of the current frame, to obtain the first downmixed signal in the current frame; and
determining the first downmixed signal in the current frame as a downmixed signal in the preset frequency band of the current frame.