The present disclosure is generally related to audio processing.
Advances in technology have resulted in smaller and more powerful computing devices. For example, there currently exist a variety of portable personal computing devices, including wireless telephones such as mobile and smart phones, tablets and laptop computers that are small, lightweight, and easily carried by users. These devices can communicate voice and data packets over wireless networks. Further, many such devices incorporate additional functionality such as a digital still camera, a digital video camera, a digital recorder, and an audio file player. Also, such devices can process executable instructions, including software applications, such as a web browser application, that can be used to access the Internet. As such, these devices can include significant computing capabilities.
A computing device may include multiple microphones to receive audio signals. Generally, a sound source is closer to a first microphone than to a second microphone of the multiple microphones. Accordingly, a second audio signal received from the second microphone may be delayed relative to a first audio signal received from the first microphone. In stereo-encoding, audio signals from the microphones may be encoded to generate a mid channel signal and one or more side channel signals. The mid channel signal may correspond to a sum of the first audio signal and the second audio signal. A side channel signal may correspond to a difference between the first audio signal and the second audio signal. The first audio signal may not be temporally aligned with the second audio signal because of the delay in receiving the second audio signal relative to the first audio signal. The misalignment (or “temporal offset”) of the first audio signal relative to the second audio signal may increase a magnitude of the side channel signal. Because of the increase in magnitude of the side channel signal, a greater number of bits may be needed to encode the side channel signal.
Additionally, different frame types may cause the computing device to generate different temporal offsets or shift estimates. For example, the computing device may determine that a voiced frame of the first audio signal is offset by a corresponding voiced frame in the second audio signal by a particular amount. However, due to a relatively high amount of noise, the computing device may determine that a transition frame (or unvoiced frame) of the first audio signal is offset by a corresponding transition frame (or corresponding unvoiced frame) of the second audio signal by a different amount. Variations in the shift estimates may cause sample repetition and artifact skipping at frame boundaries. Additionally, variation in shift estimates may result in higher side channel energies, which may reduce coding efficiency.
According to one implementation of the techniques disclosed herein, a device for communication includes a processor and a transmitter. The processor is configured to determine a first mismatch value indicative of a first amount of a temporal mismatch between a first audio signal and a second audio signal. The first mismatch value is associated with a first frame to be encoded. The processor is also configured to determine a second mismatch value indicative of a second amount of a temporal mismatch between the first audio signal and the second audio signal. The second mismatch value is associated with a second frame to be encoded. The second frame to be encoded is subsequent to the first frame to be encoded. The processor is further configured to determine an effective mismatch value based on the first mismatch value and the second mismatch value. The second frame to be encoded includes first samples of the first audio signal and second samples of the second audio signal. The second samples are selected based at least in part on the effective mismatch value. The processor is also configured to generate, based at least partially on the second frame to be encoded, at least one encoded signal having a bit allocation. The bit allocation is at least partially based on the effective mismatch value. The transmitter configured to transmit the at least one encoded signal to a second device.
According to another implementation of the techniques disclosed herein, a method of communication includes determining, at a device, a first mismatch value indicative of a first amount of a temporal mismatch between a first audio signal and a second audio signal. The first mismatch value is associated with a first frame to be encoded. The method also includes determining, at the device, a second mismatch value. The second mismatch value is indicative of a second amount of a temporal mismatch between the first audio signal and the second audio signal. The second mismatch value is associated with a second frame to be encoded. The second frame to be encoded is subsequent to the first frame to be encoded. The method further includes determining, at the device, an effective mismatch value based on the first mismatch value and the second mismatch value. The second frame to be encoded includes first samples of the first audio signal and second samples of the second audio signal. The second samples are selected based at least in part on the effective mismatch value. The method also includes generating, based at least partially on the second frame to be encoded, at least one encoded signal having a bit allocation. The bit allocation is at least partially based on the effective mismatch value. The method also includes sending the at least one encoded signal to a second device.
According to another implementation of the techniques disclosed herein, a computer-readable storage device stores instructions that, when executed by a processor, cause the processor to perform operations including determining a first mismatch value indicative of a first amount of temporal mismatch between a first audio signal and a second audio signal. The first mismatch value is associated with a first frame to be encoded. The operations also include determining a second mismatch value indicative of a second amount of temporal mismatch between the first audio signal and the second audio signal. The second mismatch value is associated with a second frame to be encoded. The second frame to be encoded is subsequent to the first frame to be encoded. The operations further include determining an effective mismatch value based on the first mismatch value and the second mismatch value. The second frame to be encoded includes first samples of the first audio signal and second samples of the second audio signal. The second samples are selected based at least in part on the effective mismatch value. The operations also include generating, based at least partially on the second frame to be encoded, at least one encoded signal having a bit allocation. The bit allocation is at least partially based on the effective mismatch value.
According to another implementation of the techniques disclosed herein, a device for communication includes a processor configured to determine a shift value and a second shift value. The shift value is indicative off a shift of a first audio signal relative to a second audio signal. The second shift value is based on the shift value. The processor is also configured to determine a bit allocation based on the second shift value and the shift value. The processor is further configured to generate at least one encoded signal based on the bit allocation. The at least one encoded signal is based on first samples of the first audio signal and second samples of the second audio signal. The second samples are time-shifted relative to the first samples by an amount that is based on the second shift value. The device also includes a transmitter configured to transmit the at least one encoded signal to a second device.
According to another implementation of the techniques disclosed herein, a method of communication includes determining, at a device, a shift value and a second shift value. The shift value is indicative of a shift of a first audio signal relative to a second audio signal. The second shift value is based on the shift value. The method also includes determining, at the device, a coding mode based on the second shift value and the shift value. The method further includes generating, at the device, at least one encoded signal based on the coding mode. The at least one encoded signal is based on first samples of the first audio signal and second samples of the second audio signal. The second samples are time-shifted relative to the first samples by an amount that is based on the second shift value. The method also includes sending the at least one encoded signal to a second device.
According to another implementation of the techniques described herein, a computer-readable storage device stores instructions that, when executed by a processor, cause the processor to perform operations including determining a shift value and a second shift value. The shift value is indicative of a shift of a first audio signal relative to a second audio signal. The second shift value is based on the shift value. The operations also include determining a bit allocation based on the second shift value and the shift value. The operations further include generating at least one encoded signal based on the bit allocation. The at least one encoded signal is based on first samples of the first audio signal and second samples of the second audio signal. The second samples are time-shifted relative to the first samples by an amount that is based on the second shift value.
According to another implementation of the techniques described herein, an apparatus includes means for determining a bit allocation based on a shift value and a second shift value. The shift value is indicative of a shift of a first audio signal relative to a second audio signal. The second shift value is based on the shift value. The apparatus also includes means for transmitting at least one encoded signal that is generated based on the bit allocation. The at least one encoded signal is based on first samples of the first audio signal and second samples of the second audio signal. The second samples are time-shifted relative to the first samples by an amount that is based on the second shift value.
Systems and devices operable to encode multiple audio signals are disclosed. A device may include an encoder configured to encode the multiple audio signals. The multiple audio signals may be captured concurrently in time using multiple recording devices, e.g., multiple microphones. In some examples, the multiple audio signals (or multi-channel audio) may be synthetically (e.g., artificially) generated by multiplexing several audio channels that are recorded at the same time or at different times. As illustrative examples, the concurrent recording or multiplexing of the audio channels may result in a 2-channel configuration (i.e., Stereo: Left and Right), a 5.1 channel configuration (Left, Right, Center, Left Surround, Right Surround, and the low frequency emphasis (LFE) channels), a 7.1 channel configuration, a 7.1+4 channel configuration, a 22.2 channel configuration, or a N-channel configuration.
Audio capture devices in teleconference rooms (or telepresence rooms) may include multiple microphones that acquire spatial audio. The spatial audio may include speech as well as background audio that is encoded and transmitted. The speech/audio from a given source (e.g., a talker) may arrive at the multiple microphones at different times depending on how the microphones are arranged as well as where the source (e.g., the talker) is located with respect to the microphones and room dimensions. For example, a sound source (e.g., a talker) may be closer to a first microphone associated with the device than to a second microphone associated with the device. Thus, a sound emitted from the sound source may reach the first microphone earlier in time than the second microphone. The device may receive a first audio signal via the first microphone and may receive a second audio signal via the second microphone.
Mid-side (MS) coding and parametric stereo (PS) coding are stereo coding techniques that may provide improved efficiency over the dual-mono coding techniques. In dual-mono coding, the Left (L) channel (or signal) and the Right (R) channel (or signal) are independently coded without making use of inter-channel correlation. MS coding reduces the redundancy between a correlated L/R channel-pair by transforming the Left channel and the Right channel to a sum-channel and a difference-channel (e.g., a side channel) prior to coding. The sum signal and the difference signal are waveform coded in MS coding. Relatively more bits are spent on the sum signal than on the side signal. PS coding reduces redundancy in each sub-band by transforming the L/R signals into a sum signal and a set of side parameters. The side parameters may indicate an inter-channel intensity difference (IID), an inter-channel phase difference (IPD), an inter-channel time difference (ITD), etc. The sum signal is waveform coded and transmitted along with the side parameters. In a hybrid system, the side-channel may be waveform coded in the lower bands (e.g., less than 2 kilohertz (kHz)) and PS coded in the upper bands (e.g., greater than or equal to 2 kHz) where the inter-channel phase preservation is perceptually less critical.
The MS coding and the PS coding may be done in either the frequency domain or in the sub-band domain. In some examples, the Left channel and the Right channel may be uncorrelated. For example, the Left channel and the Right channel may include uncorrelated synthetic signals. When the Left channel and the Right channel are uncorrelated, the coding efficiency of the MS coding, the PS coding, or both, may approach the coding efficiency of the dual-mono coding.
Depending on a recording configuration, there may be a temporal shift (or a temporal mismatch) between a Left channel and a Right channel, as well as other spatial effects such as echo and room reverberation. If the temporal shift and phase mismatch between the channels are not compensated, the sum channel and the difference channel may contain comparable energies reducing the coding-gains associated with MS or PS techniques. The reduction in the coding-gains may be based on the amount of temporal (or phase) shift. The comparable energies of the sum signal and the difference signal may limit the usage of MS coding in certain frames where the channels are temporally shifted but are highly correlated. In stereo coding, a Mid channel (e.g., a sum channel) and a Side channel (e.g., a difference channel) may be generated based on the following Formula:
M=(L+R)/2,S=(L−R)/2, Formula 1
where M corresponds to the Mid channel, S corresponds to the Side channel, L corresponds to the Left channel, and R corresponds to the Right channel.
In some cases, the Mid channel and the Side channel may be generated based on the following Formula:
M=c(L+R),S=c(L−R), Formula 2
where c corresponds to a complex value which is frequency dependent. Generating the Mid channel and the Side channel based on Formula 1 or Formula 2 may be referred to as performing a “downmixing” algorithm. A reverse process of generating the Left channel and the Right channel from the Mid channel and the Side channel based on Formula 1 or Formula 2 may be referred to as performing an “upmixing” algorithm.
An ad-hoc approach used to choose between MS coding or dual-mono coding for a particular frame may include generating a mid signal and a side signal, calculating energies of the mid signal and the side signal, and determining whether to perform MS coding based on the energies. For example, MS coding may be performed in response to determining that the ratio of energies of the side signal and the mid signal is less than a threshold. To illustrate, if a Right channel is shifted by at least a first time (e.g., about 0.001 seconds or 48 samples at 48 kHz), a first energy of the mid signal (corresponding to a sum of the left signal and the right signal) may be comparable to a second energy of the side signal (corresponding to a difference between the left signal and the right signal) for voiced speech frames. When the first energy is comparable to the second energy, a higher number of bits may be used to encode the Side channel, thereby reducing coding efficiency of MS coding relative to dual-mono coding. Dual-mono coding may thus be used when the first energy is comparable to the second energy (e.g., when the ratio of the first energy and the second energy is greater than or equal to the threshold). In an alternative approach, the decision between MS coding and dual-mono coding for a particular frame may be made based on a comparison of a threshold and normalized cross-correlation values of the Left channel and the Right channel.
In some examples, the encoder may determine a temporal shift value indicative of a shift of the first audio signal relative to the second audio signal. The shift value may correspond to an amount of temporal delay between receipt of the first audio signal at the first microphone and receipt of the second audio signal at the second microphone. Furthermore, the encoder may determine the shift value on a frame-by-frame basis, e.g., based on each 20 milliseconds (ms) speech/audio frame. For example, the shift value may correspond to an amount of time that a second frame of the second audio signal is delayed with respect to a first frame of the first audio signal. Alternatively, the shift value may correspond to an amount of time that the first frame of the first audio signal is delayed with respect to the second frame of the second audio signal.
When the sound source is closer to the first microphone than to the second microphone, frames of the second audio signal may be delayed relative to frames of the first audio signal. In this case, the first audio signal may be referred to as the “reference audio signal” or “reference channel” and the delayed second audio signal may be referred to as the “target audio signal” or “target channel”. Alternatively, when the sound source is closer to the second microphone than to the first microphone, frames of the first audio signal may be delayed relative to frames of the second audio signal. In this case, the second audio signal may be referred to as the reference audio signal or reference channel and the delayed first audio signal may be referred to as the target audio signal or target channel.
Depending on where the sound sources (e.g., talkers) are located in a conference or telepresence room or how the sound source (e.g., talker) position changes relative to the microphones, the reference channel and the target channel may change from one frame to another; similarly, the temporal delay value may also change from one frame to another. However, in some implementations, the shift value may always be positive to indicate an amount of delay of the “target” channel relative to the “reference” channel. Furthermore, the shift value may correspond to a “non-causal shift” value by which the delayed target channel is “pulled back” in time such that the target channel is aligned (e.g., maximally aligned) with the “reference” channel. The down mix algorithm to determine the mid channel and the side channel may be performed on the reference channel and the non-causal shifted target channel.
The encoder may determine the shift value based on the reference audio channel and a plurality of shift values applied to the target audio channel. For example, a first frame of the reference audio channel, X, may be received at a first time (m1). A first particular frame of the target audio channel, Y, may be received at a second time (n1) corresponding to a first shift value, e.g., shift1=n1−m1. Further, a second frame of the reference audio channel may be received at a third time (m2). A second particular frame of the target audio channel may be received at a fourth time (n2) corresponding to a second shift value, e.g., shift2=n2−m2.
The device may perform a framing or a buffering algorithm to generate a frame (e.g., 20 ms samples) at a first sampling rate (e.g., 32 kHz sampling rate (i.e., 640 samples per frame)). The encoder may, in response to determining that a first frame of the first audio signal and a second frame of the second audio signal arrive at the same time at the device, estimate a shift value (e.g., shift1) as equal to zero samples. A Left channel (e.g., corresponding to the first audio signal) and a Right channel (e.g., corresponding to the second audio signal) may be temporally aligned. In some cases, the Left channel and the Right channel, even when aligned, may differ in energy due to various reasons (e.g., microphone calibration).
In some examples, the Left channel and the Right channel may be temporally not aligned due to various reasons (e.g., a sound source, such as a talker, may be closer to one of the microphones than another and the two microphones may be greater than a threshold (e.g., 1-20 centimeters) distance apart). A location of the sound source relative to the microphones may introduce different delays in the Left channel and the Right channel. In addition, there may be a gain difference, an energy difference, or a level difference between the Left channel and the Right channel.
In some examples, a time of arrival of audio signals at the microphones from multiple sound sources (e.g., talkers) may vary when the multiple talkers are alternatively talking (e.g., without overlap). In such a case, the encoder may dynamically adjust a temporal shift value based on the talker to identify the reference channel. In some other examples, the multiple talkers may be talking at the same time, which may result in varying temporal shift values depending on who is the loudest talker, closest to the microphone, etc.
In some examples, the first audio signal and second audio signal may be synthesized or artificially generated when the two signals potentially show less (e.g., no) correlation. It should be understood that the examples described herein are illustrative and may be instructive in determining a relationship between the first audio signal and the second audio signal in similar or different situations.
The encoder may generate comparison values (e.g., difference values, variation values, or cross-correlation values) based on a comparison of a first frame of the first audio signal and a plurality of frames of the second audio signal. Each frame of the plurality of frames may correspond to a particular shift value. The encoder may generate a first estimated shift value based on the comparison values. For example, the first estimated shift value may correspond to a comparison value indicating a higher temporal-similarity (or lower difference) between the first frame of the first audio signal and a corresponding first frame of the second audio signal.
The encoder may determine the final shift value by refining, in multiple stages, a series of estimated shift values. For example, the encoder may first estimate a “tentative” shift value based on comparison values generated from stereo pre-processed and re-sampled versions of the first audio signal and the second audio signal. The encoder may generate interpolated comparison values associated with shift values proximate to the estimated “tentative” shift value. The encoder may determine a second estimated “interpolated” shift value based on the interpolated comparison values. For example, the second estimated “interpolated” shift value may correspond to a particular interpolated comparison value that indicates a higher temporal-similarity (or lower difference) than the remaining interpolated comparison values and the first estimated “tentative” shift value. If the second estimated “interpolated” shift value of the current frame (e.g., the first frame of the first audio signal) is different than a final shift value of a previous frame (e.g., a frame of the first audio signal that precedes the first frame), then the “interpolated” shift value of the current frame is further “amended” to improve the temporal-similarity between the first audio signal and the shifted second audio signal. In particular, a third estimated “amended” shift value may correspond to a more accurate measure of temporal-similarity by searching around the second estimated “interpolated” shift value of the current frame and the final estimated shift value of the previous frame. The third estimated “amended” shift value is further conditioned to estimate the final shift value by limiting any spurious changes in the shift value between frames and further controlled to not switch from a negative shift value to a positive shift value (or vice versa) in two successive (or consecutive) frames as described herein.
In some examples, the encoder may refrain from switching between a positive shift value and a negative shift value or vice-versa in consecutive frames or in adjacent frames. For example, the encoder may set the final shift value to a particular value (e.g., 0) indicating no temporal-shift based on the estimated “interpolated” or “amended” shift value of the first frame and a corresponding estimated “interpolated” or “amended” or final shift value in a particular frame that precedes the first frame. To illustrate, the encoder may set the final shift value of the current frame (e.g., the first frame) to indicate no temporal-shift, i.e., shift1=0, in response to determining that one of the estimated “tentative” or “interpolated” or “amended” shift value of the current frame is positive and the other of the estimated “tentative” or “interpolated” or “amended” or “final” estimated shift value of the previous frame (e.g., the frame preceding the first frame) is negative. Alternatively, the encoder may also set the final shift value of the current frame (e.g., the first frame) to indicate no temporal-shift, i.e., shift1=0, in response to determining that one of the estimated “tentative” or “interpolated” or “amended” shift value of the current frame is negative and the other of the estimated “tentative” or “interpolated” or “amended” or “final” estimated shift value of the previous frame (e.g., the frame preceding the first frame) is positive.
The encoder may select a frame of the first audio signal or the second audio signal as a “reference” or “target” based on the shift value. For example, in response to determining that the final shift value is positive, the encoder may generate a reference channel or signal indicator having a first value (e.g., 0) indicating that the first audio signal is a “reference” signal and that the second audio signal is the “target” signal. Alternatively, in response to determining that the final shift value is negative, the encoder may generate the reference channel or signal indicator having a second value (e.g., 1) indicating that the second audio signal is the “reference” signal and that the first audio signal is the “target” signal.
The encoder may estimate a relative gain (e.g., a relative gain parameter) associated with the reference signal and the non-causal shifted target signal. For example, in response to determining that the final shift value is positive, the encoder may estimate a gain value to normalize or equalize the energy or power levels of the first audio signal relative to the second audio signal that is offset by the non-causal shift value (e.g., an absolute value of the final shift value). Alternatively, in response to determining that the final shift value is negative, the encoder may estimate a gain value to normalize or equalize the power levels of the non-causal shifted first audio signal relative to the second audio signal. In some examples, the encoder may estimate a gain value to normalize or equalize the energy or power levels of the “reference” signal relative to the non-causal shifted “target” signal. In other examples, the encoder may estimate the gain value (e.g., a relative gain value) based on the reference signal relative to the target signal (e.g., the unshifted target signal).
The encoder may generate at least one encoded signal (e.g., a mid signal, a side signal, or both) based on the reference signal, the target signal, the non-causal shift value, and the relative gain parameter. The side signal may correspond to a difference between first samples of the first frame of the first audio signal and selected samples of a selected frame of the second audio signal. The encoder may select the selected frame based on the final shift value. Fewer bits may be used to encode the side channel signal because of reduced difference between the first samples and the selected samples as compared to other samples of the second audio signal that correspond to a frame of the second audio signal that is received by the device at the same time as the first frame. A transmitter of the device may transmit the at least one encoded signal, the non-causal shift value, the relative gain parameter, the reference channel or signal indicator, or a combination thereof.
The encoder may generate at least one encoded signal (e.g., a mid signal, a side signal, or both) based on the reference signal, the target signal, the non-causal shift value, the relative gain parameter, low band parameters of a particular frame of the first audio signal, high band parameters of the particular frame, or a combination thereof. The particular frame may precede the first frame. Certain low band parameters, high band parameters, or a combination thereof, from one or more preceding frames may be used to encode a mid signal, a side signal, or both, of the first frame. Encoding the mid signal, the side signal, or both, based on the low band parameters, the high band parameters, or a combination thereof, may improve estimates of the non-causal shift value and inter-channel relative gain parameter. The low band parameters, the high band parameters, or a combination thereof, may include a pitch parameter, a voicing parameter, a coder type parameter, a low-band energy parameter, a high-band energy parameter, a tilt parameter, a pitch gain parameter, a FCB gain parameter, a coding mode parameter, a voice activity parameter, a noise estimate parameter, a signal-to-noise ratio parameter, a formants parameter, a speech/music decision parameter, the non-causal shift, the inter-channel gain parameter, or a combination thereof. A transmitter of the device may transmit the at least one encoded signal, the non-causal shift value, the relative gain parameter, the reference channel (or signal) indicator, or a combination thereof.
Referring to
The first device 104 may include an encoder 114, a transmitter 110, one or more input interfaces 112, or a combination thereof. A first input interface of the input interfaces 112 may be coupled to a first microphone 146. A second input interface of the input interface(s) 112 may be coupled to a second microphone 148. The encoder 114 may include a temporal equalizer 108 and may be configured to down mix and encode multiple audio signals, as described herein. The first device 104 may also include a memory 153 configured to store analysis data 190. The second device 106 may include a decoder 118. The decoder 118 may include a temporal balancer 124 that is configured to upmix and render the multiple channels. The second device 106 may be coupled to a first loudspeaker 142, a second loudspeaker 144, or both.
During operation, the first device 104 may receive a first audio signal 130 via the first input interface from the first microphone 146 and may receive a second audio signal 132 via the second input interface from the second microphone 148. The first audio signal 130 may correspond to one of a right channel signal or a left channel signal. The second audio signal 132 may correspond to the other of the right channel signal or the left channel signal. A sound source 152 (e.g., a user, a speaker, ambient noise, a musical instrument, etc.) may be closer to the first microphone 146 than to the second microphone 148. Accordingly, an audio signal from the sound source 152 may be received at the input interface(s) 112 via the first microphone 146 at an earlier time than via the second microphone 148. This natural delay in the multi-channel signal acquisition through the multiple microphones may introduce a temporal shift between the first audio signal 130 and the second audio signal 132.
The temporal equalizer 108 may be configured to estimate a temporal offset between audio captured at the microphones 146, 148. The temporal offset may be estimated based on a delay between a first frame of the first audio signal 130 and a second frame of the second audio signal 132, where the second frame includes substantially similar content as the first frame. For example, the temporal equalizer 108 may determine a cross-correlation between the first frame and the second frame. The cross-correlation may measure the similarity of the two frames as a function of the lag of one frame relative to the other. Based on the cross-correlation, the temporal equalizer 108 may determine the delay (e.g., lag) between the first frame and the second frame. The temporal equalizer 108 may estimate the temporal offset between the first audio signal 130 and the second audio signal 132 based on the delay and historical delay data.
The historical data may include delays between frames captured from the first microphone 146 and corresponding frames captured from the second microphone 148. For example, the temporal equalizer 108 may determine a cross-correlation (e.g., a lag) between previous frames associated with the first audio signal 130 and corresponding frames associated with the second audio signal 132. Each lag may be represented by a “comparison value”. That is, a comparison value may indicate a time shift (k) between a frame of the first audio signal 130 and a corresponding frame of the second audio signal 132. According to one implementation, the comparison values for previous frames may be stored at the memory 153. A smoother 192 of the temporal equalizer 108 may “smooth” (or average) comparison values over a long-term set of frames and use the long-term smoothed comparison values for estimating a temporal offset (e.g., “shift”) between the first audio signal 130 and the second audio signal 132.
To illustrate, if CompValN (k) represents the comparison value at a shift of k for the frame N, the frame N may have comparison values from k×T_MIN (a minimum shift) to k=T_MAX (a maximum shift). The smoothing may be performed such that a long-term comparison value CompValLT
The smoothing techniques described above may substantially normalize the shift estimate between voiced frames, unvoiced frames, and transition frames. Normalized shift estimates may reduce sample repetition and artifact skipping at frame boundaries. Additionally, normalized shift estimates may result in reduced side channel energies, which may improve coding efficiency.
The temporal equalizer 108 may determine a final shift value 116 (e.g., a non-causal shift value) indicative of the shift (e.g., a non-causal shift) of the first audio signal 130 (e.g., “target”) relative to the second audio signal 132 (e.g., “reference”). The final shift value 116 may be based on the instantaneous comparison value CompValN(k) and the long-term comparison CompValLT
In some implementations, the third value (e.g., 0) of the final shift value 116 may indicate that delay between the first audio signal 130 and the second audio signal 132 has switched sign. For example, a first particular frame of the first audio signal 130 may precede the first frame. The first particular frame and a second particular frame of the second audio signal 132 may correspond to the same sound emitted by the sound source 152. The delay between the first audio signal 130 and the second audio signal 132 may switch from having the first particular frame delayed with respect to the second particular frame to having the second frame delayed with respect to the first frame. Alternatively, the delay between the first audio signal 130 and the second audio signal 132 may switch from having the second particular frame delayed with respect to the first particular frame to having the first frame delayed with respect to the second frame. The temporal equalizer 108 may set the final shift value 116 to indicate the third value (e.g., 0) in response to determining that the delay between the first audio signal 130 and the second audio signal 132 has switched sign.
The temporal equalizer 108 may generate a reference signal indicator 164 based on the final shift value 116. For example, the temporal equalizer 108 may, in response to determining that the final shift value 116 indicates a first value (e.g., a positive value), generate the reference signal indicator 164 to have a first value (e.g., 0) indicating that the first audio signal 130 is a “reference” signal. The temporal equalizer 108 may determine that the second audio signal 132 corresponds to a “target” signal in response to determining that the final shift value 116 indicates the first value (e.g., a positive value). Alternatively, the temporal equalizer 108 may, in response to determining that the final shift value 116 indicates a second value (e.g., a negative value), generate the reference signal indicator 164 to have a second value (e.g., 1) indicating that the second audio signal 132 is the “reference” signal. The temporal equalizer 108 may determine that the first audio signal 130 corresponds to the “target” signal in response to determining that the final shift value 116 indicates the second value (e.g., a negative value). The temporal equalizer 108 may, in response to determining that the final shift value 116 indicates a third value (e.g., 0), generate the reference signal indicator 164 to have a first value (e.g., 0) indicating that the first audio signal 130 is a “reference” signal. The temporal equalizer 108 may determine that the second audio signal 132 corresponds to a “target” signal in response to determining that the final shift value 116 indicates the third value (e.g., 0). Alternatively, the temporal equalizer 108 may, in response to determining that the final shift value 116 indicates the third value (e.g., 0), generate the reference signal indicator 164 to have a second value (e.g., 1) indicating that the second audio signal 132 is a “reference” signal. The temporal equalizer 108 may determine that the first audio signal 130 corresponds to a “target” signal in response to determining that the final shift value 116 indicates the third value (e.g., 0). In some implementations, the temporal equalizer 108 may, in response to determining that the final shift value 116 indicates a third value (e.g., 0), leave the reference signal indicator 164 unchanged. For example, the reference signal indicator 164 may be the same as a reference signal indicator corresponding to the first particular frame of the first audio signal 130. The temporal equalizer 108 may generate a non-causal shift value 162 indicating an absolute value of the final shift value 116.
The temporal equalizer 108 may generate a gain parameter 160 (e.g., a codec gain parameter) based on samples of the “target” signal and based on samples of the “reference” signal. For example, the temporal equalizer 108 may select samples of the second audio signal 132 based on the non-causal shift value 162. Alternatively, the temporal equalizer 108 may select samples of the second audio signal 132 independent of the non-causal shift value 162. The temporal equalizer 108 may, in response to determining that the first audio signal 130 is the reference signal, determine the gain parameter 160 of the selected samples based on the first samples of the first frame of the first audio signal 130. Alternatively, the temporal equalizer 108 may, in response to determining that the second audio signal 132 is the reference signal, determine the gain parameter 160 of the first samples based on the selected samples. As an example, the gain parameter 160 may be based on one of the following Equations:
where gD corresponds to the relative gain parameter 160 for down mix processing, Ref (n) corresponds to samples of the “reference” signal, N1 corresponds to the non-causal shift value 162 of the first frame, and Targ(n+N1) corresponds to samples of the “target” signal. The gain parameter 160 (gD) may be modified, e.g., based on one of the Equations 1a-1f, to incorporate long term smoothing/hysteresis logic to avoid large jumps in gain between frames. When the target signal includes the first audio signal 130, the first samples may include samples of the target signal and the selected samples may include samples of the reference signal. When the target signal includes the second audio signal 132, the first samples may include samples of the reference signal, and the selected samples may include samples of the target signal.
In some implementations, the temporal equalizer 108 may generate the gain parameter 160 based on treating the first audio signal 130 as a reference signal and treating the second audio signal 132 as a target signal, irrespective of the reference signal indicator 164. For example, the temporal equalizer 108 may generate the gain parameter 160 based on one of the Equations 1a-1f where Ref(n) corresponds to samples (e.g., the first samples) of the first audio signal 130 and Targ(n+N1) corresponds to samples (e.g., the selected samples) of the second audio signal 132. In alternate implementations, the temporal equalizer 108 may generate the gain parameter 160 based on treating the second audio signal 132 as a reference signal and treating the first audio signal 130 as a target signal, irrespective of the reference signal indicator 164. For example, the temporal equalizer 108 may generate the gain parameter 160 based on one of the Equations 1a-1f where Ref(n) corresponds to samples (e.g., the selected samples) of the second audio signal 132 and Targ(n+N1) corresponds to samples (e.g., the first samples) of the first audio signal 130.
The temporal equalizer 108 may generate one or more encoded signals 102 (e.g., a mid channel signal, a side channel signal, or both) based on the first samples, the selected samples, and the relative gain parameter 160 for down mix processing. For example, the temporal equalizer 108 may generate the mid signal based on one of the following Equations:
M=Ref(n)+gDT arg(n+N1), Equation 2a
M=Ref(n)+T arg(n+N1), Equation 2b
M=DMXFAC*Ref(n)+(1−DMXFAC)*gDT arg(n+N1), Equation 2c
M=DMXFAC*Ref(n)+(1+DMXFAC)*T arg(n+N1), Equation 2d
where M corresponds to the mid channel signal, YD corresponds to the relative gain parameter 160 for downmix processing, Ref (n) corresponds to samples of the “reference” signal, N1 corresponds to the non-causal shift value 162 of the first frame, and Targ(n+N1) corresponds to samples of the “target” signal. DMXFAC may correspond to a downmix factor, as further described with reference to
The temporal equalizer 108 may generate the side channel signal based on one of the following Equations:
S=Ref(n)−gDT arg(n+N1), Equation 3a
S=g
DRef(n)−T arg(n+N1), Equation 3b
S=(1−DMXFAC)*Ref(n)−(DMXFAC)*gDT arg(n+N1), Equation 3c
S=(1−DMXFAC)*Ref(n)−(DMXFAC)*T arg(n+N1), Equation 3d
where S corresponds to the side channel signal, gD corresponds to the relative gain parameter 160 for downmix processing, Ref (n) corresponds to samples of the “reference” signal, N1 corresponds to the non-causal shift value 162 of the first frame, and Targ(n+N1) corresponds to samples of the “target” signal.
The transmitter 110 may transmit the encoded signals 102 (e.g., the mid channel signal, the side channel signal, or both), the reference signal indicator 164, the non-causal shift value 162, the gain parameter 160, or a combination thereof, via the network 120, to the second device 106. In some implementations, the transmitter 110 may store the encoded signals 102 (e.g., the mid channel signal, the side channel signal, or both), the reference signal indicator 164, the non-causal shift value 162, the gain parameter 160, or a combination thereof, at a device of the network 120 or a local device for further processing or decoding later.
The decoder 118 may decode the encoded signals 102. The temporal balancer 124 may perform upmixing to generate a first output signal 126 (e.g., corresponding to first audio signal 130), a second output signal 128 (e.g., corresponding to the second audio signal 132), or both. The second device 106 may output the first output signal 126 via the first loudspeaker 142. The second device 106 may output the second output signal 128 via the second loudspeaker 144.
The system 100 may thus enable the temporal equalizer 108 to encode the side channel signal using fewer bits than the mid signal. The first samples of the first frame of the first audio signal 130 and selected samples of the second audio signal 132 may correspond to the same sound emitted by the sound source 152 and hence a difference between the first samples and the selected samples may be lower than between the first samples and other samples of the second audio signal 132. The side channel signal may correspond to the difference between the first samples and the selected samples.
Referring to
During operation, the first device 204 may receive more than two audio signals. For example, the first device 204 may receive the first audio signal 130 via the first microphone 146, an Nth audio signal 232 via the Nth microphone 248, and one or more additional audio signals (e.g., the second audio signal 132) via the additional microphones (e.g., the second microphone 148).
The temporal equalizer(s) 208 may generate one or more reference signal indicators 264, final shift values 216, non-causal shift values 262, gain parameters 260, encoded signals 202, or a combination thereof. For example, the temporal equalizer(s) 208 may determine that the first audio signal 130 is a reference signal and that each of the Nth audio signal 232 and the additional audio signals is a target signal. The temporal equalizer(s) 208 may generate the reference signal indicator 164, the final shift values 216, the non-causal shift values 262, the gain parameters 260, and the encoded signals 202 corresponding to the first audio signal 130 and each of the Nth audio signal 232 and the additional audio signals.
The reference signal indicators 264 may include the reference signal indicator 164. The final shift values 216 may include the final shift value 116 indicative of a shift of the second audio signal 132 relative to the first audio signal 130, a second final shift value indicative of a shift of the Nth audio signal 232 relative to the first audio signal 130, or both. The non-causal shift values 262 may include the non-causal shift value 162 corresponding to an absolute value of the final shift value 116, a second non-causal shift value corresponding to an absolute value of the second final shift value, or both. The gain parameters 260 may include the gain parameter 160 of selected samples of the second audio signal 132, a second gain parameter of selected samples of the Nth audio signal 232, or both. The encoded signals 202 may include at least one of the encoded signals 102. For example, the encoded signals 202 may include the side channel signal corresponding to first samples of the first audio signal 130 and selected samples of the second audio signal 132, a second side channel corresponding to the first samples and selected samples of the Nth audio signal 232, or both. The encoded signals 202 may include a mid channel signal corresponding to the first samples, the selected samples of the second audio signal 132, and the selected samples of the Nth audio signal 232.
In some implementations, the temporal equalizer(s) 208 may determine multiple reference signals and corresponding target signals, as described with reference to
The transmitter 110 may transmit the reference signal indicators 264, the non-causal shift values 262, the gain parameters 260, the encoded signals 202, or a combination thereof, via the network 120, to the second device 106. The decoder 118 may generate one or more output signals based on the reference signal indicators 264, the non-causal shift values 262, the gain parameters 260, the encoded signals 202, or a combination thereof. For example, the decoder 118 may output a first output signal 226 via the first loudspeaker 142, a Yth output signal 228 via the Yth loudspeaker 244, one or more additional output signals (e.g., the second output signal 128) via one or more additional loudspeakers (e.g., the second loudspeaker 144), or a combination thereof.
The system 200 may thus enable the temporal equalizer(s) 208 to encode more than two audio signals. For example, the encoded signals 202 may include multiple side channel signals that are encoded using fewer bits than corresponding mid channels by generating the side channel signals based on the non-causal shift values 262.
Referring to
The samples 300 may include first samples 320 corresponding to the first audio signal 130, second samples 350 corresponding to the second audio signal 132, or both. The first samples 320 may include a sample 322, a sample 324, a sample 326, a sample 328, a sample 330, a sample 332, a sample 334, a sample 336, one or more additional samples, or a combination thereof. The second samples 350 may include a sample 352, a sample 354, a sample 356, a sample 358, a sample 360, a sample 362, a sample 364, a sample 366, one or more additional samples, or a combination thereof.
The first audio signal 130 may correspond to a plurality of frames (e.g., a frame 302, a frame 304, a frame 306, or a combination thereof). Each of the plurality of frames may correspond to a subset of samples (e.g., corresponding to 20 ms, such as 640 samples at 32 kHz or 960 samples at 48 kHz) of the first samples 320. For example, the frame 302 may correspond to the sample 322, the sample 324, one or more additional samples, or a combination thereof. The frame 304 may correspond to the sample 326, the sample 328, the sample 330, the sample 332, one or more additional samples, or a combination thereof. The frame 306 may correspond to the sample 334, the sample 336, one or more additional samples, or a combination thereof.
The sample 322 may be received at the input interface(s) 112 of
A first value (e.g., a positive value) of the final shift value 116 may indicate that the second audio signal 132 is delayed relative to the first audio signal 130. For example, a first value (e.g., +X ms or +Y samples, where X and Y include positive real numbers) of the final shift value 116 may indicate that the frame 304 (e.g., the samples 326-332) correspond to the samples 358-364. The samples 326-332 and the samples 358-364 may correspond to the same sound emitted from the sound source 152. The samples 358-364 may correspond to a frame 344 of the second audio signal 132. Illustration of samples with cross-hatching in one or more of
It should be understood that a temporal offset of Y samples, as shown in
The temporal equalizer 108 of
Referring to
A second value (e.g., a negative value) of the final shift value 116 may indicate that the first audio signal 130 is delayed relative to the second audio signal 132. For example, the second value (e.g., −X ms or −Y samples, where X and Y include positive real numbers) of the final shift value 116 may indicate that the frame 304 (e.g., the samples 326-332) correspond to the samples 354-360. The samples 354-360 may correspond to the frame 344 of the second audio signal 132. The samples 354-360 (e.g., the frame 344) and the samples 326-332 (e.g., the frame 304) may correspond to the same sound emitted from the sound source 152.
It should be understood that a temporal offset of −Y samples, as shown in
The temporal equalizer 108 of
Referring to
During operation, the resampler 504 may generate one or more resampled signals, as further described with reference to
The signal comparator 506 may generate comparison values 534 (e.g., difference values, variation values, similarity values, coherence values, or cross-correlation values), a tentative shift value 536, or both, as further described with reference to
The first resampled signal 530 may include fewer samples or more samples than the first audio signal 130. The second resampled signal 532 may include fewer samples or more samples than the second audio signal 132. Determining the comparison values 534 based on the fewer samples of the resampled signals (e.g., the first resampled signal 530 and the second resampled signal 532) may use fewer resources (e.g., time, number of operations, or both) than on samples of the original signals (e.g., the first audio signal 130 and the second audio signal 132). Determining the comparison values 534 based on the more samples of the resampled signals (e.g., the first resampled signal 530 and the second resampled signal 532) may increase precision than on samples of the original signals (e.g., the first audio signal 130 and the second audio signal 132). The signal comparator 506 may provide the comparison values 534, the tentative shift value 536, or both, to the interpolator 510.
The interpolator 510 may extend the tentative shift value 536. For example, the interpolator 510 may generate an interpolated shift value 538, as further described with reference to
The interpolated comparison values may be based on a finer granularity of shift values that are proximate to the resampled tentative shift value 536. For example, the interpolated comparison values may be based on a second subset of the set of shift values so that a difference between a highest shift value of the second subset and the resampled tentative shift value 536 is less than the threshold (e.g., ≥1), and a difference between a lowest shift value of the second subset and the resampled tentative shift value 536 is less than the threshold. Determining the comparison values 534 based on the coarser granularity (e.g., the first subset) of the set of shift values may use fewer resources (e.g., time, operations, or both) than determining the comparison values 534 based on a finer granularity (e.g., all) of the set of shift values. Determining the interpolated comparison values corresponding to the second subset of shift values may extend the tentative shift value 536 based on a finer granularity of a smaller set of shift values that are proximate to the tentative shift value 536 without determining comparison values corresponding to each shift value of the set of shift values. Thus, determining the tentative shift value 536 based on the first subset of shift values and determining the interpolated shift value 538 based on the interpolated comparison values may balance resource usage and refinement of the estimated shift value. The interpolator 510 may provide the interpolated shift value 538 to the shift refiner 511.
According to one implementation, the interpolator 510 may retrieve interpolated shift values for previous frames and may modify the interpolated shift value 538 based on a long-term smoothing operation using the interpolated shift values for previous frames. For example, the interpolated shift value 538 may include a long-term interpolated shift value InterValLT
The shift refiner 511 may generate an amended shift value 540 by refining the interpolated shift value 538, as further described with reference to
According to one implementation, the shift refiner may retrieve amended shift values for previous frames and may modify the amended shift value 540 based on a long-term smoothing operation using the amended shift values for previous frames. For example, the amended shift value 540 may include a long-term amended shift value AmendValLT
In some implementations, the shift refiner 511 may adjust the interpolated shift value 538, as described with reference to
The shift change analyzer 512 may determine whether the amended shift value 540 indicates a switch or reverse in timing between the first audio signal 130 and the second audio signal 132, as described with reference to
The absolute shift generator 513 may generate the non-causal shift value 162 by applying an absolute function to the final shift value 116. The absolute shift generator 513 may provide the non-causal shift value 162 to the gain parameter generator 514.
The reference signal designator 508 may generate the reference signal indicator 164, as further described with reference to
The gain parameter generator 514 may select samples of the target signal (e.g., the second audio signal 132) based on the non-causal shift value 162. To illustrate, the gain parameter generator 514 may select the samples 358-364 in response to determining that the non-causal shift value 162 has a first value (e.g., +X ms or +Y samples, where X and Y include positive real numbers). The gain parameter generator 514 may select the samples 354-360 in response to determining that the non-causal shift value 162 has a second value (e.g., −X ms or −Y samples). The gain parameter generator 514 may select the samples 356-362 in response to determining that the non-causal shift value 162 has a value (e.g., 0) indicating no time shift.
The gain parameter generator 514 may determine whether the first audio signal 130 is the reference signal or the second audio signal 132 is the reference signal based on the reference signal indicator 164. The gain parameter generator 514 may generate the gain parameter 160 based on the samples 326-332 of the frame 304 and the selected samples (e.g., the samples 354-360, the samples 356-362, or the samples 358-364) of the second audio signal 132, as described with reference to
The gain parameter generator 514 may provide the gain parameter 160, the reference signal indicator 164, the non-causal shift value 162, or a combination thereof, to the signal generator 516. The signal generator 516 may generate the encoded signals 102, as described with reference to
The temporal equalizer 108 may store the first resampled signal 530, the second resampled signal 532, the comparison values 534, the tentative shift value 536, the interpolated shift value 538, the amended shift value 540, the non-causal shift value 162, the reference signal indicator 164, the final shift value 116, the gain parameter 160, the first encoded signal frame 564, the second encoded signal frame 566, or a combination thereof, in the memory 153. For example, the analysis data 190 may include the first resampled signal 530, the second resampled signal 532, the comparison values 534, the tentative shift value 536, the interpolated shift value 538, the amended shift value 540, the non-causal shift value 162, the reference signal indicator 164, the final shift value 116, the gain parameter 160, the first encoded signal frame 564, the second encoded signal frame 566, or a combination thereof.
The smoothing techniques described above may substantially normalize the shift estimate between voiced frames, unvoiced frames, and transition frames. Normalized shift estimates may reduce sample repetition and artifact skipping at frame boundaries. Additionally, normalized shift estimates may result in reduced side channel energies, which may improve coding efficiency.
Referring to
The resampler 504 may generate first samples 620 of the first resampled signal 530 by resampling (e.g., downsampling or upsampling) the first audio signal 130 of
The first audio signal 130 may be sampled at a first sample rate (Fs) to generate the first samples 320 of
In some implementations, the resampler 504 may pre-process the first audio signal 130 (or the second audio signal 132) prior to resampling the first audio signal 130 (or the second audio signal 132). The resampler 504 may pre-process the first audio signal 130 (or the second audio signal 132) by filtering the first audio signal 130 (or the second audio signal 132) based on an infinite impulse response (IIR) filter (e.g., a first order IIR filter). The IIR filter may be based on the following Equation:
H
pre(z)=1/(1−az−1) Equation 4
where α is positive, such as 0.68 or 0.72. Performing the de-emphasis prior to resampling may reduce effects, such as aliasing, signal conditioning, or both. The first audio signal 130 (e.g., the pre-processed first audio signal 130) and the second audio signal 132 (e.g., the pre-processed second audio signal 132) may be resampled based on a resampling factor (D). The resampling factor (D) may be based on the first sample rate (Fs) (e.g., D=Fs/8, D=2Fs, etc.).
In alternate implementations, the first audio signal 130 and the second audio signal 132 may be low-pass filtered or decimated using an anti-aliasing filter prior to resampling. The decimation filter may be based on the resampling factor (D). In a particular example, the resampler 504 may select a decimation filter with a first cut-off frequency (e.g., π/D or π/4) in response to determining that the first sample rate (Fs) corresponds to a particular rate (e.g., 32 kHz). Reducing aliasing by de-emphasizing multiple signals (e.g., the first audio signal 130 and the second audio signal 132) may be computationally less expensive than applying a decimation filter to the multiple signals.
The first samples 620 may include a sample 622, a sample 624, a sample 626, a sample 628, a sample 630, a sample 632, a sample 634, a sample 636, one or more additional samples, or a combination thereof. The first samples 620 may include a subset (e.g., ⅛ th) of the first samples 320 of
The second samples 650 may include a sample 652, a sample 654, a sample 656, a sample 658, a sample 660, a sample 662, a sample 664, a sample 667, one or more additional samples, or a combination thereof. The second samples 650 may include a subset (e.g., ⅛ th) of the second samples 350 of
The resampler 504 may store the first samples 620, the second samples 650, or both, in the memory 153. For example, the analysis data 190 may include the first samples 620, the second samples 650, or both.
Referring to
The memory 153 may store a plurality of shift values 760. The shift values 760 may include a first shift value 764 (e.g., −X ms or −Y samples, where X and Y include positive real numbers), a second shift value 766 (e.g., +X ms or +Y samples, where X and Y include positive real numbers), or both. The shift values 760 may range from a lower shift value (e.g., a minimum shift value, T_MIN) to a higher shift value (e.g., a maximum shift value, T_MAX). The shift values 760 may indicate an expected temporal shift (e.g., a maximum expected temporal shift) between the first audio signal 130 and the second audio signal 132.
During operation, the signal comparator 506 may determine the comparison values 534 based on the first samples 620 and the shift values 760 applied to the second samples 650. For example, the samples 626-632 may correspond to a first time (t). To illustrate, the input interface(s) 112 of
The samples 654-660 may correspond to the second time (t−1). For example, the input interface(s) 112 may receive the samples 654-660 at approximately the second time (t−1). The signal comparator 506 may determine a first comparison value 714 (e.g., a difference value, a variation value, or a cross-correlation value) corresponding to the first shift value 764 based on the samples 626-632 and the samples 654-660. For example, the first comparison value 714 may correspond to an absolute value of cross-correlation of the samples 626-632 and the samples 654-660. As another example, the first comparison value 714 may indicate a difference between the samples 626-632 and the samples 654-660.
The second shift value 766 (e.g., +X ms or +Y samples, where X and Y include positive real numbers) may correspond to a third time (t+1). The samples 658-664 may correspond to the third time (t+1). For example, the input interface(s) 112 may receive the samples 658-664 at approximately the third time (t+1). The signal comparator 506 may determine a second comparison value 716 (e.g., a difference value, a variation value, or a cross-correlation value) corresponding to the second shift value 766 based on the samples 626-632 and the samples 658-664. For example, the second comparison value 716 may correspond to an absolute value of cross-correlation of the samples 626-632 and the samples 658-664. As another example, the second comparison value 716 may indicate a difference between the samples 626-632 and the samples 658-664. The signal comparator 506 may store the comparison values 534 in the memory 153. For example, the analysis data 190 may include the comparison values 534.
The signal comparator 506 may identify a selected comparison value 736 of the comparison values 534 that has a higher (or lower) value than other values of the comparison values 534. For example, the signal comparator 506 may select the second comparison value 716 as the selected comparison value 736 in response to determining that the second comparison value 716 is greater than or equal to the first comparison value 714. In some implementations, the comparison values 534 may correspond to cross-correlation values. The signal comparator 506 may, in response to determining that the second comparison value 716 is greater than the first comparison value 714, determine that the samples 626-632 have a higher correlation with the samples 658-664 than with the samples 654-660. The signal comparator 506 may select the second comparison value 716 that indicates the higher correlation as the selected comparison value 736. In other implementations, the comparison values 534 may correspond to difference values (e.g., variation values). The signal comparator 506 may, in response to determining that the second comparison value 716 is lower than the first comparison value 714, determine that the samples 626-632 have a greater similarity with (e.g., a lower difference to) the samples 658-664 than the samples 654-660. The signal comparator 506 may select the second comparison value 716 that indicates a lower difference as the selected comparison value 736.
The selected comparison value 736 may indicate a higher correlation (or a lower difference) than the other values of the comparison values 534. The signal comparator 506 may identify the tentative shift value 536 of the shift values 760 that corresponds to the selected comparison value 736. For example, the signal comparator 506 may identify the second shift value 766 as the tentative shift value 536 in response to determining that the second shift value 766 corresponds to the selected comparison value 736 (e.g., the second comparison value 716).
The signal comparator 506 may determine the selected comparison value 736 based on the following Equation:
maxXCorr=max(|Σk=−KKw(n)l′(n)*w(n+k)r′(n+k)|), Equation 5
where maxXCorr corresponds to the selected comparison value 736 and k corresponds to a shift value. w(n)*l′ corresponds to de-emphasized, resampled, and windowed first audio signal 130, and w(n)*r′ corresponds to de-emphasized, resampled, and windowed second audio signal 132. For example, w(n)*l′ may correspond to the samples 626-632, w(n−1)*r′ may correspond to the samples 654-660, w(n)*r′ may correspond to the samples 656-662, and w(n+1)*r′ may correspond to the samples 658-664. −K may correspond to a lower shift value (e.g., a minimum shift value) of the shift values 760, and K may correspond to a higher shift value (e.g., a maximum shift value) of the shift values 760. In Equation 5, w(n)*l′ corresponds to the first audio signal 130 independently of whether the first audio signal 130 corresponds to a right (r) channel signal or a left (l) channel signal. In Equation 5, w(n)*r′ corresponds to the second audio signal 132 independently of whether the second audio signal 132 corresponds to the right (r) channel signal or the left (l) channel signal.
The signal comparator 506 may determine the tentative shift value 536 based on the following Equation:
T=
k
argmax(|Σk=−KKw(n)l′(n)*w(n+k)r′(n+k)|), Equation 6
where T corresponds to the tentative shift value 536.
The signal comparator 506 may map the tentative shift value 536 from the resampled samples to the original samples based on the resampling factor (D) of
Referring to
During operation, the interpolator 510 may generate the shift values 860 proximate to the tentative shift value 536 (e.g., 12), as described herein. Mapped shift values may correspond to the shift values 760 mapped from the resampled samples to the original samples based on the resampling factor (D). For example, a first mapped shift value of the mapped shift values may correspond to a product of the first shift value 764 and the resampling factor (D). A difference between a first mapped shift value of the mapped shift values and each second mapped shift value of the mapped shift values may be greater than or equal to a threshold value (e.g., the resampling factor (D), such as 4). The shift values 860 may have finer granularity than the shift values 760. For example, a difference between a lower value (e.g., a minimum value) of the shift values 860 and the tentative shift value 536 may be less than the threshold value (e.g., 4). The threshold value may correspond to the resampling factor (D) of
The interpolator 510 may generate interpolated comparison values 816 corresponding to the shift values 860 by performing interpolation on the comparison values 534, as described herein. Comparison values corresponding to one or more of the shift values 860 may be excluded from the comparison values 534 because of the lower granularity of the comparison values 534. Using the interpolated comparison values 816 may enable searching of interpolated comparison values corresponding to the one or more of the shift values 860 to determine whether an interpolated comparison value corresponding to a particular shift value proximate to the tentative shift value 536 indicates a higher correlation (or lower difference) than the second comparison value 716 of
R(k)32 kHz=Σi=−44R({circumflex over (t)}N2−i)8 kHz*b(3i+t), Equation 7
where t=k−{circumflex over (t)}N2 corresponds to a windowed sinc function, tN2 corresponds to the tentative shift value 536. R({circumflex over (t)}N2−i)8 kHz may correspond to a particular comparison value of the comparison values 534. For example, R({circumflex over (t)}N2−i)8 kHz may indicate a first comparison value of the comparison values 534 that corresponds to a first shift value (e.g., 8) when i corresponds to 4. R({circumflex over (t)}N2−i)8 kHz may indicate the second comparison value 716 that corresponds to the tentative shift value 536 (e.g., 12) when i corresponds to 0. R({circumflex over (t)}N2−i)8 kHz may indicate a third comparison value of the comparison values 534 that corresponds to a third shift value (e.g., 16) when i corresponds to −4.
R(k)32 kHz may correspond to a particular interpolated value of the interpolated comparison values 816. Each interpolated value of the interpolated comparison values 816 may correspond to a sum of a product of the windowed sinc function (b) and each of the first comparison value, the second comparison value 716, and the third comparison value. For example, the interpolator 510 may determine a first product of the windowed sinc function (b) and the first comparison value, a second product of the windowed sinc function (b) and the second comparison value 716, and a third product of the windowed sinc function (b) and the third comparison value. The interpolator 510 may determine a particular interpolated value based on a sum of the first product, the second product, and the third product. A first interpolated value of the interpolated comparison values 816 may correspond to a first shift value (e.g., 9). The windowed sinc function (b) may have a first value corresponding to the first shift value. A second interpolated value of the interpolated comparison values 816 may correspond to a second shift value (e.g., 10). The windowed sinc function (b) may have a second value corresponding to the second shift value. The first value of the windowed sinc function (b) may be distinct from the second value. The first interpolated value may thus be distinct from the second interpolated value.
In Equation 7, 8 kHz may correspond to a first rate of the comparison values 534. For example, the first rate may indicate a number (e.g., 8) of comparison values corresponding to a frame (e.g., the frame 304 of
The interpolator 510 may select an interpolated comparison value 838 (e.g., a maximum value or a minimum value) of the interpolated comparison values 816. The interpolator 510 may select a shift value (e.g., 14) of the shift values 860 that corresponds to the interpolated comparison value 838. The interpolator 510 may generate the interpolated shift value 538 indicating the selected shift value (e.g., the second shift value 866).
Using a coarse approach to determine the tentative shift value 536 and searching around the tentative shift value 536 to determine the interpolated shift value 538 may reduce search complexity without compromising search efficiency or accuracy.
Referring to
The method 920 includes determining whether an absolute value of α difference between the first shift value 962 and the interpolated shift value 538 is greater than a first threshold, at 901. For example, the shift refiner 911 may determine whether an absolute value of α difference between the first shift value 962 and the interpolated shift value 538 is greater than a first threshold (e.g., a shift change threshold).
The method 920 also includes, in response to determining that the absolute value is less than or equal to the first threshold, at 901, setting the amended shift value 540 to indicate the interpolated shift value 538, at 902. For example, the shift refiner 911 may, in response to determining that the absolute value is less than or equal to the shift change threshold, set the amended shift value 540 to indicate the interpolated shift value 538. In some implementations, the shift change threshold may have a first value (e.g., 0) indicating that the amended shift value 540 is to be set to the interpolated shift value 538 when the first shift value 962 is equal to the interpolated shift value 538. In alternate implementations, the shift change threshold may have a second value (e.g., ≥1) indicating that the amended shift value 540 is to be set to the interpolated shift value 538, at 902, with a greater degree of freedom. For example, the amended shift value 540 may be set to the interpolated shift value 538 for a range of differences between the first shift value 962 and the interpolated shift value 538. To illustrate, the amended shift value 540 may be set to the interpolated shift value 538 when an absolute value of α difference (e.g., −2, −1, 0, 1, 2) between the first shift value 962 and the interpolated shift value 538 is less than or equal to the shift change threshold (e.g., 2).
The method 920 further includes, in response to determining that the absolute value is greater than the first threshold, at 901, determining whether the first shift value 962 is greater than the interpolated shift value 538, at 904. For example, the shift refiner 911 may, in response to determining that the absolute value is greater than the shift change threshold, determine whether the first shift value 962 is greater than the interpolated shift value 538.
The method 920 also includes, in response to determining that the first shift value 962 is greater than the interpolated shift value 538, at 904, setting a lower shift value 930 to a difference between the first shift value 962 and a second threshold, and setting a greater shift value 932 to the first shift value 962, at 906. For example, the shift refiner 911 may, in response to determining that the first shift value 962 (e.g., 20) is greater than the interpolated shift value 538 (e.g., 14), set the lower shift value 930 (e.g., 17) to a difference between the first shift value 962 (e.g., 20) and a second threshold (e.g., 3). Additionally, or in the alternative, the shift refiner 911 may, in response to determining that the first shift value 962 is greater than the interpolated shift value 538, set the greater shift value 932 (e.g., 20) to the first shift value 962. The second threshold may be based on the difference between the first shift value 962 and the interpolated shift value 538. In some implementations, the lower shift value 930 may be set to a difference between the interpolated shift value 538 offset and a threshold (e.g., the second threshold) and the greater shift value 932 may be set to a difference between the first shift value 962 and a threshold (e.g., the second threshold).
The method 920 further includes, in response to determining that the first shift value 962 is less than or equal to the interpolated shift value 538, at 904, setting the lower shift value 930 to the first shift value 962, and setting a greater shift value 932 to a sum of the first shift value 962 and a third threshold, at 910. For example, the shift refiner 911 may, in response to determining that the first shift value 962 (e.g., 10) is less than or equal to the interpolated shift value 538 (e.g., 14), set the lower shift value 930 to the first shift value 962 (e.g., 10). Additionally, or in the alternative, the shift refiner 911 may, in response to determining that the first shift value 962 is less than or equal to the interpolated shift value 538, set the greater shift value 932 (e.g., 13) to a sum of the first shift value 962 (e.g., 10) and a third threshold (e.g., 3). The third threshold may be based on the difference between the first shift value 962 and the interpolated shift value 538. In some implementations, the lower shift value 930 may be set to a difference between the first shift value 962 offset and a threshold (e.g., the third threshold) and the greater shift value 932 may be set to a difference between the interpolated shift value 538 and a threshold (e.g., the third threshold).
The method 920 also includes determining comparison values 916 based on the first audio signal 130 and shift values 960 applied to the second audio signal 132, at 908. For example, the shift refiner 911 (or the signal comparator 506) may generate the comparison values 916, as described with reference to
The method 920 further includes determining the amended shift value 540 based on the comparison values 916 generated based on the first audio signal 130 and the second audio signal 132, at 912. For example, the shift refiner 911 may determine the amended shift value 540 based on the comparison values 916. To illustrate, in a first case, when the comparison values 916 correspond to cross-correlation values, the shift refiner 911 may determine that the interpolated comparison value 838 of
In a second case, when the comparison values 916 correspond to cross-correlation values, the shift refiner 911 may determine that the interpolated comparison value 838 is less than the highest comparison value of the comparison values 916 and may set the amended shift value 540 to a particular shift value (e.g., 18) of the shift values 960 that corresponds to the highest comparison value. Alternatively, when the comparison values 916 correspond to difference values (e.g., variation values), the shift refiner 911 may determine that the interpolated comparison value 838 is greater than the lowest comparison value of the comparison values 916 and may set the amended shift value 540 to a particular shift value (e.g., 18) of the shift values 960 that corresponds to the lowest comparison value.
The comparison values 916 may be generated based on the first audio signal 130, the second audio signal 132, and the shift values 960. The amended shift value 540 may be generated based on comparison values 916 using a similar procedure as performed by the signal comparator 506, as described with reference to
The method 920 may thus enable the shift refiner 911 to limit a change in a shift value associated with consecutive (or adjacent) frames. The reduced change in the shift value may reduce sample loss or sample duplication during encoding.
Referring to
The method 951 includes generating an offset 957 based on a difference between the first shift value 962 and an unconstrained interpolated shift value 956, at 952. For example, the interpolated shift adjuster 958 may generate the offset 957 based on a difference between the first shift value 962 and an unconstrained interpolated shift value 956. The unconstrained interpolated shift value 956 may correspond to the interpolated shift value 538 (e.g., prior to adjustment by the interpolated shift adjuster 958). The interpolated shift adjuster 958 may store the unconstrained interpolated shift value 956 in the memory 153. For example, the analysis data 190 may include the unconstrained interpolated shift value 956.
The method 951 also includes determining whether an absolute value of the offset 957 is greater than a threshold, at 953. For example, the interpolated shift adjuster 958 may determine whether an absolute value of the offset 957 satisfies a threshold. The threshold may correspond to an interpolated shift limitation MAX_SHIFT_CHANGE (e.g., 4).
The method 951 includes, in response to determining that the absolute value of the offset 957 is greater than the threshold, at 953, setting the interpolated shift value 538 based on the first shift value 962, a sign of the offset 957, and the threshold, at 954. For example, the interpolated shift adjuster 958 may in response to determining that the absolute value of the offset 957 fails to satisfy (e.g., is greater than) the threshold, constrain the interpolated shift value 538. To illustrate, the interpolated shift adjuster 958 may adjust the interpolated shift value 538 based on the first shift value 962, a sign (e.g., +1 or −1) of the offset 957, and the threshold (e.g., the interpolated shift value 538=the first shift value 962+sign (the offset 957)*Threshold).
The method 951 includes, in response to determining that the absolute value of the offset 957 is less than or equal to the threshold, at 953, set the interpolated shift value 538 to the unconstrained interpolated shift value 956, at 955. For example, the interpolated shift adjuster 958 may in response to determining that the absolute value of the offset 957 satisfies (e.g., is less than or equal to) the threshold, refrain from changing the interpolated shift value 538.
The method 951 may thus enable constraining the interpolated shift value 538 such that a change in the interpolated shift value 538 relative to the first shift value 962 satisfies an interpolation shift limitation.
Referring to
The method 971 includes determining whether a difference between the first shift value 962 and the interpolated shift value 538 is non-zero, at 972. For example, the shift refiner 921 may determine whether a difference between the first shift value 962 and the interpolated shift value 538 is non-zero.
The method 971 includes, in response to determining that the difference between the first shift value 962 and the interpolated shift value 538 is zero, at 972, setting the amended shift value 540 to the interpolated shift value 538, at 973. For example, the shift refiner 921 may, in response to determining that the difference between the first shift value 962 and the interpolated shift value 538 is zero, determine the amended shift value 540 based on the interpolated shift value 538 (e.g., the amended shift value 540=the interpolated shift value 538).
The method 971 includes, in response to determining that the difference between the first shift value 962 and the interpolated shift value 538 is non-zero, at 972, determining whether an absolute value of the offset 957 is greater than a threshold, at 975. For example, the shift refiner 921 may, in response to determining that the difference between the first shift value 962 and the interpolated shift value 538 is non-zero, determine whether an absolute value of the offset 957 is greater than a threshold. The offset 957 may correspond to a difference between the first shift value 962 and the unconstrained interpolated shift value 956, as described with reference to
The method 971 includes, in response to determining that a difference between the first shift value 962 and the interpolated shift value 538 is non-zero, at 972, or determining that the absolute value of the offset 957 is less than or equal to the threshold, at 975, setting the lower shift value 930 to a difference between a first threshold and a minimum of the first shift value 962 and the interpolated shift value 538, and setting the greater shift value 932 to a sum of a second threshold and a maximum of the first shift value 962 and the interpolated shift value 538, at 976. For example, the shift refiner 921 may, in response to determining that the absolute value of the offset 957 is less than or equal to the threshold, determine the lower shift value 930 based on a difference between a first threshold and a minimum of the first shift value 962 and the interpolated shift value 538. The shift refiner 921 may also determine the greater shift value 932 based on a sum of a second threshold and a maximum of the first shift value 962 and the interpolated shift value 538.
The method 971 also includes generating the comparison values 916 based on the first audio signal 130 and the shift values 960 applied to the second audio signal 132, at 977. For example, the shift refiner 921 (or the signal comparator 506) may generate the comparison values 916, as described with reference to
The method 971 includes, in response to determining that the absolute value of the offset 957 is greater than the threshold, at 975, generating a comparison value 915 based on the first audio signal 130 and the unconstrained interpolated shift value 956 applied to the second audio signal 132, at 978. For example, the shift refiner 921 (or the signal comparator 506) may generate the comparison value 915, as described with reference to
The method 971 also includes determining the amended shift value 540 based on the comparison values 916, the comparison value 915, or a combination thereof, at 979. For example, the shift refiner 921 may determine the amended shift value 540 based on the comparison values 916, the comparison value 915, or a combination thereof, as described with reference to
In some cases, an inherent pitch of the first audio signal 130, the first resampled signal 530, the second audio signal 132, the second resampled signal 532, or a combination thereof, may interfere with the shift estimation process. In such cases, pitch de-emphasis or pitch filtering may be performed to reduce the interference due to pitch and to improve reliability of shift estimation between multiple channels. In some cases, background noise may be present in the first audio signal 130, the first resampled signal 530, the second audio signal 132, the second resampled signal 532, or a combination thereof, that may interfere with the shift estimation process. In such cases, noise suppression or noise cancellation may be used to improve reliability of shift estimation between multiple channels.
Referring to
The method 1020 includes determining whether the first shift value 962 is equal to 0, at 1001. For example, the shift change analyzer 512 may determine whether the first shift value 962 corresponding to the frame 302 has a first value (e.g., 0) indicating no time shift. The method 1020 includes, in response to determining that the first shift value 962 is equal to 0, at 1001, proceeding to 1010.
The method 1020 includes, in response to determining that the first shift value 962 is non-zero, at 1001, determining whether the first shift value 962 is greater than 0, at 1002. For example, the shift change analyzer 512 may determine whether the first shift value 962 corresponding to the frame 302 has a first value (e.g., a positive value) indicating that the second audio signal 132 is delayed in time relative to the first audio signal 130.
The method 1020 includes, in response to determining that the first shift value 962 is greater than 0, at 1002, determining whether the amended shift value 540 is less than 0, at 1004. For example, the shift change analyzer 512 may, in response to determining that the first shift value 962 has the first value (e.g., a positive value), determine whether the amended shift value 540 has a second value (e.g., a negative value) indicating that the first audio signal 130 is delayed in time relative to the second audio signal 132. The method 1020 includes, in response to determining that the amended shift value 540 is less than 0, at 1004, proceeding to 1008. The method 1020 includes, in response to determining that the amended shift value 540 is greater than or equal to 0, at 1004, proceeding to 1010.
The method 1020 includes, in response to determining that the first shift value 962 is less than 0, at 1002, determining whether the amended shift value 540 is greater than 0, at 1006. For example, the shift change analyzer 512 may in response to determining that the first shift value 962 has the second value (e.g., a negative value), determine whether the amended shift value 540 has a first value (e.g., a positive value) indicating that the second audio signal 132 is delayed in time with respect to the first audio signal 130. The method 1020 includes, in response to determining that the amended shift value 540 is greater than 0, at 1006, proceeding to 1008. The method 1020 includes, in response to determining that the amended shift value 540 is less than or equal to 0, at 1006, proceeding to 1010.
The method 1020 includes setting the final shift value 116 to 0, at 1008. For example, the shift change analyzer 512 may set the final shift value 116 to a particular value (e.g., 0) that indicates no time shift.
The method 1020 includes determining whether the first shift value 962 is equal to the amended shift value 540, at 1010. For example, the shift change analyzer 512 may determine whether the first shift value 962 and the amended shift value 540 indicate the same time delay between the first audio signal 130 and the second audio signal 132.
The method 1020 includes, in response to determining that the first shift value 962 is equal to the amended shift value 540, at 1010, setting the final shift value 116 to the amended shift value 540, at 1012. For example, the shift change analyzer 512 may set the final shift value 116 to the amended shift value 540.
The method 1020 includes, in response to determining that the first shift value 962 is not equal to the amended shift value 540, at 1010, generating an estimated shift value 1072, at 1014. For example, the shift change analyzer 512 may determine the estimated shift value 1072 by refining the amended shift value 540, as further described with reference to
The method 1020 includes setting the final shift value 116 to the estimated shift value 1072, at 1016. For example, the shift change analyzer 512 may set the final shift value 116 to the estimated shift value 1072.
In some implementations, the shift change analyzer 512 may set the non-causal shift value 162 to indicate the second estimated shift value in response to determining that the delay between the first audio signal 130 and the second audio signal 132 did not switch. For example, the shift change analyzer 512 may set the non-causal shift value 162 to indicate the amended shift value 540 in response to determining that the first shift value 962 is equal to 0, 1001, that the amended shift value 540 is greater than or equal to 0, at 1004, or that the amended shift value 540 is less than or equal to 0, at 1006.
The shift change analyzer 512 may thus set the non-causal shift value 162 to indicate no time shift in response to determining that delay between the first audio signal 130 and the second audio signal 132 switched between the frame 302 and the frame 304 of
Referring to
The method 1031 includes determining whether the first shift value 962 is greater than zero and the amended shift value 540 is less than zero, at 1032. For example, the shift change analyzer 512 may determine whether the first shift value 962 is greater than zero and whether the amended shift value 540 is less than zero.
The method 1031 includes, in response to determining that the first shift value 962 is greater than zero and that the amended shift value 540 is less than zero, at 1032, setting the final shift value 116 to zero, at 1033. For example, the shift change analyzer 512 may, in response to determining that the first shift value 962 is greater than zero and that the amended shift value 540 is less than zero, set the final shift value 116 to a first value (e.g., 0) that indicates no time shift.
The method 1031 includes, in response to determining that the first shift value 962 is less than or equal to zero or that the amended shift value 540 is greater than or equal to zero, at 1032, determining whether the first shift value 962 is less than zero and whether the amended shift value 540 is greater than zero, at 1034. For example, the shift change analyzer 512 may, in response to determining that the first shift value 962 is less than or equal to zero or that the amended shift value 540 is greater than or equal to zero, determine whether the first shift value 962 is less than zero and whether the amended shift value 540 is greater than zero.
The method 1031 includes, in response to determining that the first shift value 962 is less than zero and that the amended shift value 540 is greater than zero, proceeding to 1033. The method 1031 includes, in response to determining that the first shift value 962 is greater than or equal to zero or that the amended shift value 540 is less than or equal to zero, setting the final shift value 116 to the amended shift value 540, at 1035. For example, the shift change analyzer 512 may, in response to determining that the first shift value 962 is greater than or equal to zero or that the amended shift value 540 is less than or equal to zero, set the final shift value 116 to the amended shift value 540.
Referring to
The method 1120 includes determining whether the first shift value 962 is greater than the amended shift value 540, at 1104. For example, the shift change analyzer 512 may determine whether the first shift value 962 is greater than the amended shift value 540.
The method 1120 also includes, in response to determining that the first shift value 962 is greater than the amended shift value 540, at 1104, setting a first shift value 1130 to a difference between the amended shift value 540 and a first offset, and setting a second shift value 1132 to a sum of the first shift value 962 and the first offset, at 1106. For example, the shift change analyzer 512 may, in response to determining that the first shift value 962 (e.g., 20) is greater than the amended shift value 540 (e.g., 18), determine the first shift value 1130 (e.g., 17) based on the amended shift value 540 (e.g., amended shift value 540−a first offset). Alternatively, or in addition, the shift change analyzer 512 may determine the second shift value 1132 (e.g., 21) based on the first shift value 962 (e.g., the first shift value 962+the first offset). The method 1120 may proceed to 1108.
The method 1120 further includes, in response to determining that the first shift value 962 is less than or equal to the amended shift value 540, at 1104, setting the first shift value 1130 to a difference between the first shift value 962 and a second offset, and setting the second shift value 1132 to a sum of the amended shift value 540 and the second offset. For example, the shift change analyzer 512 may, in response to determining that the first shift value 962 (e.g., 10) is less than or equal to the amended shift value 540 (e.g., 12), determine the first shift value 1130 (e.g., 9) based on the first shift value 962 (e.g., first shift value 962−a second offset). Alternatively, or in addition, the shift change analyzer 512 may determine the second shift value 1132 (e.g., 13) based on the amended shift value 540 (e.g., the amended shift value 540+the second offset). The first offset (e.g., 2) may be distinct from the second offset (e.g., 3). In some implementations, the first offset may be the same as the second offset. A higher value of the first offset, the second offset, or both, may improve a search range.
The method 1120 also includes generating comparison values 1140 based on the first audio signal 130 and shift values 1160 applied to the second audio signal 132, at 1108. For example, the shift change analyzer 512 may generate the comparison values 1140, as described with reference to
The method 1120 further includes determining the estimated shift value 1072 based on the comparison values 1140, at 1112. For example, the shift change analyzer 512 may, when the comparison values 1140 correspond to cross-correlation values, select a highest comparison value of the comparison values 1140 as the estimated shift value 1072. Alternatively, the shift change analyzer 512 may, when the comparison values 1140 correspond to difference values (e.g., variation values), select a lowest comparison value of the comparison values 1140 as the estimated shift value 1072.
The method 1120 may thus enable the shift change analyzer 512 to generate the estimated shift value 1072 by refining the amended shift value 540. For example, the shift change analyzer 512 may determine the comparison values 1140 based on original samples and may select the estimated shift value 1072 corresponding to a comparison value of the comparison values 1140 that indicates a highest correlation (or lowest difference).
Referring to
The method 1220 includes determining whether the final shift value 116 is equal to 0, at 1202. For example, the reference signal designator 508 may determine whether the final shift value 116 has a particular value (e.g., 0) indicating no time shift.
The method 1220 includes, in response to determining that the final shift value 116 is equal to 0, at 1202, leaving the reference signal indicator 164 unchanged, at 1204. For example, the reference signal designator 508 may, in response to determining that the final shift value 116 has the particular value (e.g., 0) indicating no time shift, leave the reference signal indicator 164 unchanged. To illustrate, the reference signal indicator 164 may indicate that the same audio signal (e.g., the first audio signal 130 or the second audio signal 132) is a reference signal associated with the frame 304 as with the frame 302.
The method 1220 includes, in response to determining that the final shift value 116 is non-zero, at 1202, determining whether the final shift value 116 is greater than 0, at 1206. For example, the reference signal designator 508 may, in response to determining that the final shift value 116 has a particular value (e.g., a non-zero value) indicating a time shift, determine whether the final shift value 116 has a first value (e.g., a positive value) indicating that the second audio signal 132 is delayed relative to the first audio signal 130 or a second value (e.g., a negative value) indicating that the first audio signal 130 is delayed relative to the second audio signal 132.
The method 1220 includes, in response to determining that the final shift value 116 has the first value (e.g., a positive value), set the reference signal indicator 164 to have a first value (e.g., 0) indicating that the first audio signal 130 is a reference signal, at 1208. For example, the reference signal designator 508 may, in response to determining that the final shift value 116 has the first value (e.g., a positive value), set the reference signal indicator 164 to a first value (e.g., 0) indicating that the first audio signal 130 is a reference signal. The reference signal designator 508 may, in response to determining that the final shift value 116 has the first value (e.g., the positive value), determine that the second audio signal 132 corresponds to a target signal.
The method 1220 includes, in response to determining that the final shift value 116 has the second value (e.g., a negative value), set the reference signal indicator 164 to have a second value (e.g., 1) indicating that the second audio signal 132 is a reference signal, at 1210. For example, the reference signal designator 508 may, in response to determining that the final shift value 116 has the second value (e.g., a negative value) indicating that the first audio signal 130 is delayed relative to the second audio signal 132, set the reference signal indicator 164 to a second value (e.g., 1) indicating that the second audio signal 132 is a reference signal. The reference signal designator 508 may, in response to determining that the final shift value 116 has the second value (e.g., the negative value), determine that the first audio signal 130 corresponds to a target signal.
The reference signal designator 508 may provide the reference signal indicator 164 to the gain parameter generator 514. The gain parameter generator 514 may determine a gain parameter (e.g., a gain parameter 160) of a target signal based on a reference signal, as described with reference to
A target signal may be delayed in time relative to a reference signal. The reference signal indicator 164 may indicate whether the first audio signal 130 or the second audio signal 132 corresponds to the reference signal. The reference signal indicator 164 may indicate whether the gain parameter 160 corresponds to the first audio signal 130 or the second audio signal 132.
Referring to
The method 1300 includes determining whether the final shift value 116 is greater than or equal to zero, at 1302. For example, the reference signal designator 508 may determine whether the final shift value 116 is greater than or equal to zero. The method 1300 also includes, in response to determining that the final shift value 116 is greater than or equal to zero, at 1302, proceeding to 1208. The method 1300 further includes, in response to determining that the final shift value 116 is less than zero, at 1302, proceeding to 1210. The method 1300 differs from the method 1220 of
The method 1300 may thus enable setting the reference signal indicator 164 to a particular value (e.g., 0) indicating that the first audio signal 130 corresponds to a reference signal when the final shift value 116 indicates no time shift independently of whether the first audio signal 130 corresponds to the reference signal for the frame 302.
Referring to
The signal comparator 506 may generate the comparison values 534 (e.g., difference values, variance values, similarity values, coherence values, or cross-correlation values), the tentative shift value 536, or both. For example, the signal comparator 506 may generate the comparison values 534 based on the first resampled signal 530 and a plurality of shift values 1450 applied to the second resampled signal 532. The signal comparator 506 may determine the tentative shift value 536 based on the comparison values 534. The signal comparator 506 includes a smoother 1410 configured to retrieve comparison values for previous frames of the resampled signals 530, 532 and may modify the comparison values 534 based on a long-term smoothing operation using the comparison values for previous frames. For example, the comparison values 534 may include the long-term comparison value CompValLT
The interpolator 510 may extend the tentative shift value 536 to generate the interpolated shift value 538. For example, the interpolator 510 may generate interpolated comparison values corresponding to shift values that are proximate to the tentative shift value 536 by interpolating the comparison values 534. The interpolator 510 may determine the interpolated shift value 538 based on the interpolated comparison values and the comparison values 534. The comparison values 534 may be based on a coarser granularity of the shift values. The interpolated comparison values may be based on a finer granularity of shift values that are proximate to the resampled tentative shift value 536. Determining the comparison values 534 based on the coarser granularity (e.g., the first subset) of the set of shift values may use fewer resources (e.g., time, operations, or both) than determining the comparison values 534 based on a finer granularity (e.g., all) of the set of shift values. Determining the interpolated comparison values corresponding to the second subset of shift values may extend the tentative shift value 536 based on a finer granularity of a smaller set of shift values that are proximate to the tentative shift value 536 without determining comparison values corresponding to each shift value of the set of shift values. Thus, determining the tentative shift value 536 based on the first subset of shift values and determining the interpolated shift value 538 based on the interpolated comparison values may balance resource usage and refinement of the estimated shift value. The interpolator 510 may provide the interpolated shift value 538 to the shift refiner 511.
The interpolator 510 includes a smoother 1420 configured to retrieve interpolated shift values for previous frames and may modify the interpolated shift value 538 based on a long-term smoothing operation using the interpolated shift values for previous frames. For example, the interpolated shift value 538 may include a long-term interpolated shift value InterValLT
The shift refiner 511 may generate the amended shift value 540 by refining the interpolated shift value 538. For example, the shift refiner 511 may determine whether the interpolated shift value 538 indicates that a change in a shift between the first audio signal 130 and the second audio signal 132 is greater than a shift change threshold. The change in the shift may be indicated by a difference between the interpolated shift value 538 and a first shift value associated with the frame 302 of
The shift refiner 511 includes a smoother 1430 configured to retrieve amended shift values for previous frames and may modify the amended shift value 540 based on a long-term smoothing operation using the amended shift values for previous frames. For example, the amended shift value 540 may include a long-term amended shift value AmendValLT
The shift change analyzer 512 may determine whether the amended shift value 540 indicates a switch or reverse in timing between the first audio signal 130 and the second audio signal 132. The shift change analyzer 512 may determine whether the delay between the first audio signal 130 and the second audio signal 132 has switched sign based on the amended shift value 540 and the first shift value associated with the frame 302. The shift change analyzer 512 may, in response to determining that the delay between the first audio signal 130 and the second audio signal 132 has switched sign, set the final shift value 116 to a value (e.g., 0) indicating no time shift. Alternatively, the shift change analyzer 512 may set the final shift value 116 to the amended shift value 540 in response to determining that the delay between the first audio signal 130 and the second audio signal 132 has not switched sign.
The shift change analyzer 512 may generate an estimated shift value by refining the amended shift value 540. The shift change analyzer 512 may set the final shift value 116 to the estimated shift value. Setting the final shift value 116 to indicate no time shift may reduce distortion at a decoder by refraining from time shifting the first audio signal 130 and the second audio signal 132 in opposite directions for consecutive (or adjacent) frames of the first audio signal 130. The shift change analyzer 512 may provide the final shift value 116 to the absolute shift generator 513. The absolute shift generator 513 may generate the non-causal shift value 162 by applying an absolute function to the final shift value 116.
The smoothing techniques described above may substantially normalize the shift estimate between voiced frames, unvoiced frames, and transition frames. Normalized shift estimates may reduce sample repetition and artifact skipping at frame boundaries. Additionally, normalized shift estimates may result in reduced side channel energies, which may improve coding efficiency.
As described with respect to
Referring to
The cross-correlation represented in each graph 1502, 1504, 1506 may be substantially different. For example, the graph 1502 illustrates that a peak cross-correlation between a voiced frame captured by the first microphone 146 of
According to
The comparison value long-term smoothing process described with respect to
Referring to
The method 1600 includes capturing a first audio signal at a first microphone, at 1602. The first audio signal may include a first frame. For example, referring to
A second audio signal may be captured at a second microphone, at 1604. The second audio signal may include a second frame, and the second frame may have substantially similar content as the first frame. For example, referring to
A delay between the first frame and the second frame may be estimated, at 1606. For example, referring to
The historical data may include delays between frames captured from the first microphone 146 and corresponding frames captured from the second microphone 148. For example, the temporal equalizer 108 may determine a cross-correlation (e.g., a lag) between previous frames associated with the first audio signal 130 and corresponding frames associated with the second audio signal 132. Each lag may be represented by a “comparison value”. That is, a comparison value may indicate a time shift (k) between a frame of the first audio signal 130 and a corresponding frame of the second audio signal 132. According to one implementation, the comparison values for previous frames may be stored at the memory 153. A smoother 192 of the temporal equalizer 108 may “smooth” (or average) comparison values over a long-term set of frames and used the long-term smoothed comparison values for estimating a temporal offset (e.g., “shift”) between the first audio signal 130 and the second audio signal 132.
Thus, the historical delay data may be generated based on smoothed comparison values associated with the first audio signal 130 and the second audio signal 132. For example, the method 1600 may include smoothing comparison values associated with the first audio signal 130 and the second audio signal 132 to generate the historical delay data. The smoothed comparison values may be based on frames of the first audio signal 130 generated earlier in time than the first frame and based on frames of the second audio signal 132 generated earlier in time than the second frame. According to one implementation, the method 1600 may include temporally shifting the second frame by the temporal offset.
To illustrate, if CompValN(k) represents the comparison value at a shift of k for the frame N, the frame N may have comparison values from k=T_MIN (a minimum shift) to k=T_MAX (a maximum shift). The smoothing may be performed such that a long-term comparison value CompValLT
According to one implementation, the method 1600 may include adjusting a range of comparison values that are used to estimate the delay between the first frame and the second frame, as described in greater detail with respect to
The method 1600 of
Referring to
According to the process diagram 1700, a detector may be configured to determine whether the comparison values in the vicinity of a right boundary or left boundary is increasing or decreasing. The search range boundaries for future comparison value generation may be pushed outward to accommodate more shift values based on the determination. For example, the search range boundaries may be pushed outward for comparison values in subsequent frames or comparison values in a same frame when comparison values are regenerated. The detector may initiate search boundary extension based on the comparison values generated for a current frame or based on comparison values generated for one or more previous frames.
At 1702, the detector may determine whether comparison values at the right boundary are monotonically increasing. As a non-limiting example, the search range may extend from −20 to 20 (e.g., from 20 sample shifts in the negative direction to 20 samples shifts in the positive direction). As used herein, a shift in the negative direction corresponds to a first signal, such as the first audio signal 130 of
If the comparison values at the right boundary are monotonically increasing, at 1702, the detector may adjust the right boundary outwards to increase the search range, at 1704. To illustrate, if comparison value at sample shift 19 has a particular value and the comparison value at sample shift 20 has a higher value, the detector may extend the search range in the positive direction. As a non-limiting example, the detector may extend the search range from −20 to 25. The detector may extend the search range in increments of one sample, two samples, three samples, etc. According to one implementation, the determination at 1702 may be performed by detecting comparison values at a plurality of samples towards the right boundary to reduce the likelihood of expanding the search range based on a spurious jump at the right boundary.
If the comparison values at the right boundary are not monotonically increasing, at 1702, the detector may determine whether the comparison values at the left boundary are monotonically increasing, at 1706. If the comparison values at the left boundary are monotonically increasing, at 1706, the detector may adjust the left boundary outwards to increase the search range, at 1708. To illustrate, if comparison value at sample shift −19 has a particular value and the comparison value at sample shift −20 has a higher value, the detector may extend the search range in the negative direction. As a non-limiting example, the detector may extend the search range from −25 to 20. The detector may extend the search range in increments of one sample, two samples, three samples, etc. According to one implementation, the determination at 1702 may be performed by detecting comparison values at a plurality of samples towards the left boundary to reduce the likelihood of expanding the search range based on a spurious jump at the left boundary. If the comparison values at the left boundary are not monotonically increasing, at 1706, the detector may leave the search range unchanged, at 1710.
Thus, the process diagram 1700 of
Referring to
According to Table 1, the detector may expand the search range if a particular boundary increases at three or more consecutive frames. The first graph 1802 illustrates comparison values for frame i−2. According to the first graph 1802, the left boundary is not monotonically increasing and the right boundary is monotonically increasing for one consecutive frame. As a result, the search range remains unchanged for the next frame (e.g., frame i−1) and the boundary may range from −20 to 20. The second graph 1804 illustrates comparison values for frame i−1. According to the second graph 1804, the left boundary is not monotonically increasing and the right boundary is monotonically increasing for two consecutive frames. As a result, the search range remains unchanged for the next frame (e.g., frame i) and the boundary may range from −20 to 20.
The third graph 1806 illustrates comparison values for frame i. According to the third graph 1806, the left boundary is not monotonically increasing and the right boundary is monotonically increasing for three consecutive frames. Because the right boundary in monotonically increasing for three or more consecutive frame, the search range for the next frame (e.g., frame i+1) may be expanded and the boundary for the next frame may range from −23 to 23. The fourth graph 1808 illustrates comparison values for frame i+1. According to the fourth graph 1808, the left boundary is not monotonically increasing and the right boundary is monotonically increasing for four consecutive frames. Because the right boundary in monotonically increasing for three or more consecutive frame, the search range for the next frame (e.g., frame i+2) may be expanded and the boundary for the next frame may range from −26 to 26. The fifth graph 1810 illustrates comparison values for frame i+2. According to the fifth graph 1810, the left boundary is not monotonically increasing and the right boundary is monotonically increasing for five consecutive frames. Because the right boundary in monotonically increasing for three or more consecutive frame, the search range for the next frame (e.g., frame i+3) may be expanded and the boundary for the next frame may range from −29 to 29.
The sixth graph 1812 illustrates comparison values for frame i+3. According to the sixth graph 1812, the left boundary is not monotonically increasing and the right boundary is not monotonically increasing. As a result, the search range remains unchanged for the next frame (e.g., frame i+4) and the boundary may range from −29 to 29. The seventh graph 1814 illustrates comparison values for frame i+4. According to the seventh graph 1814, the left boundary is not monotonically increasing and the right boundary is monotonically increasing for one consecutive frame. As a result, the search range remains unchanged for the next frame and the boundary may range from −29 to 29.
According to
According to one implementation, when the detector indicates a particular boundary is to be expanded outwards, the amount of samples that the particular boundary is expanded outward may be determined based on the comparison values. For example, when the detector determines that the right boundary is to be expanded outwards based on the comparison values, a new set of comparison values may be generated on a wider shift search range and the detector may use the newly generated comparison values and the existing comparison values to determine the final search range. To illustrate, for frame i+1, a set of comparison values on a wider range of shifts ranging from −30 to 30 may be generated. The final search range may be limited based on the comparison values generated in the wider search range.
Although the examples in
Referring to
The first device 104 includes similar components and may operate in a substantially similar manner as described with respect to
The encoder 114 (or another processor at the first device 104) may determine the final shift value 116 and the amended shift value 540 according to the techniques described with respect to
The bit allocator 1908 may be configured to determine a bit allocation based on the final shift value 116 and the amended shift value 540. For example, the bit allocator 1908 may determine a variation between the final shift value 116 and the amended shift value 540. After determining the variation, the bit allocator 1908 may compare variation to the first threshold 1902. As described below, if the variation satisfies the first threshold 1902, the number of bits allocated to a mid signal and the number of bits allocated to a side signal may be adjusted during an encoding operation.
To illustrate, the encoder 114 may be configured to generate at least one encoded signal (e.g., the encoded signals 102) based on the bit allocation. The encoded signals 102 may include a first encoded signal and a second encoded signal. According to one implementation, the first encoded signal may correspond to a mid signal and the second encoded signal may correspond to a side signal. The encoder 114 may generate the mid signal (e.g., the first encoded signal) based on a sum of the first audio signal 130 and the second audio signal 132. The encoder 114 may generate the side signal based on a difference between the first audio signal 130 and the second audio signal 132. According to one implementation, the first encoded signal and the second encoded signal may include low-band signals. For example, the first encoded signal may include a low-band mid signal, and the second encoded signal may include a low-band side signal. The first encoded signal and the second encoded signal may include high-band signals. For example, the first encoded signal may include a high-band mid signal, and the second encoded signal may include a high-band side signal.
If the final shift value 116 (e.g., a shift amount used for encoding the encoded signals 102) is different than the amended shift value 540 (e.g., a shift amount calculated to reduce side signal energy), additional bits may be allocated to the side signal coding as compared to a scenario where the final shift value 116 and the amended shift value 540 are similar. After allocating the additional bits to the side signal coding, the remainder of the available bits may be allocated to the mid signal coding and to the side parameters. Having a similar final shift value 116 and amended shift value 540 may substantially reduce the likelihood of sign reversals in successive frames, substantially reduce an occurrence of a large jump in the shift between the audio signals 130, 132, and/or may temporally slow-shift the target signal from frame to frame. For example, the shift may evolve (e.g., change) slowly because the side channel is not fully decorrelated and because changing the shift in large steps may generate artifacts. Additionally, if the shift changes more than a particular amount from frame to frame and a final shift variation is limited, increased side frame energy may occur. Thus, additional bits may be allocated to the side signal coding to account for the increased side frame energy.
To illustrate, the bit allocator 1908 may allocate the first number of bits 1916 to the first encoded signal (e.g., the mid signal) and may allocate the second number of bits 1918 to the second encoded signal (e.g., the side signal). The bit allocator 1908 may determine the variation (or the difference) between the final shift value 116 and the amended shift value 540. After determining the variation, the bit allocator 1908 may compare variation to the first threshold 1902. In response to the variation between the amended shift value 540 and the final shift value 116 satisfying the first threshold 1902, the bit allocator 1908 may decrease the first number of bits 1916 and increase the second number of bits 1918. For example, the bit allocator 1908 may decrease the number of bits allocated to the mid signal and may increase the number of bits allocated to the side signal. According to one implementation, the first threshold 1902 may be equal to relatively small value (e.g., zero or one) such that the additional bits are allocated to the side signal if the final shift value 116 and the amended shift value 540 are not (substantially) similar.
As described above, the encoder 114 may generate the encoded signals 102 based on the bit allocation. Additionally, the encoded signals 102 may be based on a coding mode, and the coding mode may be based on the amended shift value 540 (e.g., the shift value) and the final shift value 116 (e.g., the second shift value). For example, the encoder 114 may be configured to determine the coding mode based on the amended shift value 540 and the final shift value 116. As described above, the encoder 114 may determine the difference between the amended shift value 540 and the final shift value 116.
In response to the difference satisfying a threshold, the encoder 114 may generate the first encoded signal (e.g., the mid signal) based on a first coding mode and may generate the second encoded signal (e.g., the side signal) based on a second coding mode. Examples of coding modes are described further with reference to
According to one implementation, in response to the difference between the amended shift value 540 and the final shift value 116 failing to satisfy the threshold, the encoder 114 may generate an encoded low-band mid signal (e.g., the first encoded signal) based on an ACELP coding mode and may generate an encoded low-band side signal (e.g., the second encoded signal) based on a predictive ACELP coding mode. In this scenario, the encoded signals 102 may include the encoded low-band mid signal and one or more parameters corresponding to the encoded low-band side signal.
According to a particular implementation, the encoder 114 may, based on determining at least that the variation in a second shift value (e.g., the amended shift value 540 or the final shift value 116 of the frame 304) relative to the first shift value 962 (e.g., the final shift of the frame 302) exceeds a particular threshold, set a shift variation tracking flag. The encoder 114 may estimate, based on the shift variation tracking flag, the gain parameter 160 (e.g., an estimated target gain), or both, an energy ratio value or a downmix factor (e.g., DMXFAC (as in Equations 2c-2d)). The encoder 114 may determine the bit allocation for the frame 304 based on the downmix factor (DMXFAC) that is controlled by the shift variation, as shown in the pseudo code below.
Pseudo code: Generating the shift variation tracking flag
Pseudo code: Adjusting downmix factor based on shift variation, target gain.
Pseudo code: Adjusting bit allocation based on downmix factor.
The “sideChannel_bits” may correspond to the second number of bits 1918. The “midChannel_bits” may correspond to the first number of bits 1916. According to a particular implementation, the sideChannel_bits may be estimated based on the downmix factor (e.g., DMXFAC), the coding mode (e.g., ACELP, TCX, INACTIVE, etc.), or both. The high band bit allocation, HighBand_bits may be based on the coder type (ACELP, voiced, unvoiced), the core sample rate (12.8 kHz or 16 kHz core), the fixed total bit rate available for side-channel coding, mid-channel coding, and high-band coding, or a combination thereof. The remaining number of bits after allocating to side-channel coding and high-band coding may be allocated for mid-channel coding.
In a particular implementation, the final shift value 116 chosen for target channel adjustment may be distinct from the suggested or actual amended shift value (e.g., the amended shift value 540). A state machine (e.g., the encoder 114) may, in response to determining that the amended shift value 540 is greater than a threshold and would result in a large shift or adjustment in the target channel, set the final shift value 116 to an intermediate value. For example, the encoder 114 may set the final shift value 116 to an intermediate value between the first shift value 962 (e.g., the previous frame's final shift value) and the amended shift value 540 (e.g., the current frame's suggested or amended shift value). When the final shift value 116 is distinct from the amended shift value 540, the side channel may not be maximally decorrelated. Setting the final shift value 116 to an intermediate value (i.e., not the true or actual shift value, such as represented by the amended shift value 540) may result in allocating more bits to the side-channel coding. The side-channel bit allocation may be directly based on the shift variation or indirectly based on the shift variation tracking flag, target gain, the downmix factor DMXFAC, or a combination thereof.
According to another implementation, in response to the difference between the amended shift value 540 and the final shift value 116 failing to satisfy the threshold, the encoder 114 may generate an encoded high-band mid signal (e.g., the first encoded signal) based on a BWE coding mode and may generate an encoded high-band side signal (e.g., the second encoded signal) based on a blind BWE coding mode. In this scenario, the encoded signals 102 may include the encoded high-band mid signal and one or more parameters corresponding to the encoded high-band side signal.
The encoded signals 102 may be based on first samples of the first audio signal 130 and second samples of the second audio signal 132. The second samples may be time-shifted relative to the first samples by an amount that is based on the final shift value 116 (e.g., the second shift value). The transmitter 110 may be configured to transmit the encoded signals 102 to the second device 106 via the network 120. Upon receiving the encoded signal 102, the second device 106 may operate in a substantially similar manner as described with respect to
The system 1900 of
Referring to
At 2052, the method 2000 includes determining a difference 2057 between the final shift value 116 and the amended shift value 540. For example, the bit allocator 1908 may determine the difference 2057 by subtracting the amended shift value 540 from the final shift value 116.
At 2053, the method 2000 includes comparing the difference 2057 (e.g., the absolute value of the difference 2057) to the first threshold 1902. For example, the bit allocator 1908 may determine whether the absolute value of the difference is greater than the first threshold 1902. If the absolute value of the difference 2057 is greater than the first threshold 1902, the bit allocator 1908 may decrease the first number of bits 1916 and may increase the second number of bits 1918, at 2054. For example, the bit allocator 1908 may decrease the number of bits allocated to the mid signal and may increase the number of bits allocated to the side signal.
If the absolute value of the difference 2057 is not greater than the first threshold 1902, the bit allocator 1908 may determine whether the absolute value of the difference 2057 is less than the second threshold 1904, at 2055. If the absolute value of the difference 2057 is less than the second threshold 1904, the bit allocator 1908 may increase the first number of bits 1916 and may decrease the second number of bits 1918, at 2056. For example, the bit allocator 1908 may increase the number of bits allocated to the mid signal and may decrease the number of bits allocated to the side channel. If the absolute value of the difference 2057 is not less than the second threshold 1904, the first number of bits 1916 and the second number of bits 1918 may remain unchanged, at 2057.
The method 2000 of
Referring to
At 2152, the method 2100 includes determining the difference 2057 between the final shift value 116 and the amended shift value 540. For example, the bit allocator 1908 may determine the difference 2057 by subtracting the amended shift value 540 from the final shift value 2052.
At 2153, the method 2100 includes comparing the difference 2057 (e.g., the absolute value of the difference 2057) to the first threshold 1902. For example, the bit allocator 1908 may determine whether the absolute value of the difference is greater than the first threshold 1902. If the absolute value of the difference 2057 is greater than the first threshold 1902, the coding mode selector 1910 may select a BWE coding mode as the first HB coding mode 1912, select an ACELP coding mode as the first LB coding mode 1913, select a BWE coding mode as the second HB coding mode 1914, and select an ACELP coding mode as the second LB coding mode 1915, at 2154. An illustrative implementation of coding according to this scenario is depicted as a coding scheme 2202 in
Referring back to
Referring back to
Thus, according to the method 2100, the coding scheme 2202 may allocate a large number of bits for side channel coding, the coding scheme 2204 may allocate a smaller number of bits for side channel coding, and the coding scheme 2206 may allocate an even smaller number of bits for side channel coding. If the signals 130, 132 are noise-like signals, the coding mode selector 1910 may encode the signals 130, 132 according to a coding scheme 2208. For example, the side channel may be encoded using residual or predictive coding. The high-band and low-band side channel may be encoded using transform domain (e.g., Discrete Fourier Transform (DFT) or Modified Discrete Cosine Transform (MDCT) coding). If the signals 130, 132 have reduced noise (e.g., music-like signals), the coding mode selector 1910 may encode the signals 130, 132 according to a coding scheme 2210. The coding scheme 2210 may be similar to the coding scheme 2208, however, the mid channel coding according to the coding scheme 2210 includes transform coded excitation (TCX) coding.
The method 2100 of
Referring to
The inter-frame shift variation analyzer 2306 may be coupled, via the target signal adjuster 2308, to the gain parameter generator 2315. The target signal adjuster 2308 may be configured to adjust a target signal based on a difference between shift values. For example, the target signal adjuster 2308 may be configured to perform interpolation on a subset of samples to generate estimated samples that are used to generate adjusted samples of the target signal. The gain parameter generator 2315 may be configured to determine a gain parameter of the reference signal that “normalizes” (e.g., equalizes) a power level of the reference signal relative to a power level of the target signal. Alternatively, the gain parameter generator 2315 may be configured to determine a gain parameter of the target signal that normalizes (e.g., equalizes) a power level of the target signal relative to a power level of the reference signal.
The reference signal designator 2309 may be coupled to the inter-frame shift variation analyzer 2306, to the gain parameter generator 2315, or both. The target signal adjuster 2308 may be coupled to a midside generator 2310, to the gain parameter generator 2315, or to both. The gain parameter generator 2315 may be coupled to the midside generator 2310. The midside generator 2310 may be configured to perform encoding on the reference signal and the adjusted target signal to generate at least one encoded signal. For example, the midside generator 2310 may be configured to perform stereo encoding to generate a mid channel signal 2370 and a side channel signal 2372.
The midside generator 2310 may be coupled to a bandwidth extension (BWE) spatial balancer 2312, a mid BWE coder 2314, a low band (LB) signal regenerator 2316, or a combination thereof. The LB signal regenerator 2316 may be coupled to a LB side core coder 2318, a LB mid core coder 2320, or both. The mid BWE coder 2314 may be coupled to the BWE spatial balancer 2312, the LB mid core coder 2320, or both. The BWE spatial balancer 2312, the mid BWE coder 2314, the LB signal regenerator 2316, the LB side core coder 2318, and the LB mid core coder 2320 may be configured to perform bandwidth extension and additional coding, such as low band coding and mid band coding, on the mid channel signal 2370, the side channel signal 2372, or both. Performing bandwidth extension and additional coding may include performing additional signal encoding, generating parameters, or both.
During operation, the signal pre-processor 2302 may receive the audio signals 2328. The audio signals 2328 may include the first audio signal 130, the second audio signal 132, or both. In a particular implementation, the audio signals 2328 may include a left channel signal and a right channel signal. In other implementations, the audio signals 2328 may include other signals. The signal pre-processor 2302 may downsample (or resample) the first audio signal 130 and the second audio signal 132 to generate the resampled signals 2330, 2332 (e.g., the downsampled first audio signal 130 and the downsampled second audio signal 132).
The shift estimator 2304 may generate shift values based on the resampled signals 2330, 2332. In a particular implementation, the shift estimator 2304 may generate a non-causal shift value (NC_SHIFT_INDX) 2361 after performance of an absolute value operation. In a particular implementation, the shift estimator 2304 may prevent a next shift value from having a different sign (e.g., positive or negative) than a current shift value. For example, when the shift value for a first frame is negative and the shift value for a second frame is determined to be positive, the shift estimator 2304 may set the shift value for the second frame to be zero. As another example, when the shift value for the first frame is positive and the shift value for the second frame is determined to be negative, the shift estimator 2304 may set the shift value for the second frame to be zero. Thus, in this implementation, a shift value for a current frame has the same sign (e.g., positive or negative) as a shift value for a previous frame, or the shift value for the current frame is zero.
The reference signal designator 2309 may select one of the first audio signal 130 and the second audio signal 132 as a reference signal for a time period corresponding to the third frame and the fourth frame. The reference signal designator 2309 may determine the reference signal based on the final shift value 116 from the shift estimator 2304. For example, when the final shift value 116 is negative, the reference signal designator 2309 may identify the second audio signal 132 as the reference signal and the first audio signal 130 as the target signal. When the final shift value 116 is positive or zero, the reference signal designator 2309 may identify the second audio signal 132 as the target signal and the first audio signal 130 as the reference signal. The reference signal designator 2309 may generate the reference signal indicator 2365 that has a value that indicates the reference signal. For example, the reference signal indicator 2365 may have a first value (e.g., a logical zero value) when the first audio signal 130 is identified as the reference signal, and the reference signal indicator 2365 may have a second value (e.g., a logical one value) when the second audio signal 132 is identified as the reference signal. The reference signal designator 2309 may provide the reference signal indicator 2365 to the inter-frame shift variation analyzer 2306 and to the gain parameter generator 2315.
The inter-frame shift variation analyzer 2306 may generate a target signal indicator 2364 based on the final shift value 116, a first shift value 2363, a target signal 2342, a reference signal 2340, and the reference signal indicator 2365. The target signal indicator 2364 indicates an adjusted target channel. For example, a first value (e.g., a logical zero value) of the target signal indicator 2364 may indicate that the first audio signal 130 is the adjusted target channel, and a second value (e.g., a logical one value) of the target signal indicator 2364 may indicate that the second audio signal 132 is the adjusted target channel. The inter-frame shift variation analyzer 2306 may provide the target signal indicator 2364 to the target signal adjuster 2308.
The target signal adjuster 2308 may adjust samples corresponding to the adjusted target signal to generate the adjusted samples an adjusted target signal 2352. The target signal adjuster 2308 may provide the adjusted target signal 2352 to the gain parameter generator 2315 and to the midside generator 2310. The gain parameter generator 2315 may generate a gain parameter 261 based on the reference signal indicator 2365 and the adjusted target signal 2352. The gain parameter 261 may normalize (e.g., equalize) a power level of the target signal relative to a power level of the reference signal. Alternatively, the gain parameter generator 2315 may receive the reference signal (or samples thereof) and determine the gain parameter 261 that normalizes a power level of the reference signal relative to a power level of the target signal. The gain parameter generator 2315 may provide the gain parameter 261 to the midside generator 2310.
The midside generator 2310 may generate the mid channel signal 2370, the side channel signal 2372, or both, based on the adjusted target signal 2352, the reference signal 2340, and the gain parameter 261. The midside generator 2310 may provide the side channel signal 2372 to the BWE spatial balancer 2312, the LB signal regenerator 2316, or both. The midside generator 2310 may provide the mid channel signal 2370 to the mid BWE coder 2314, the LB signal regenerator 2316, or both. The LB signal regenerator 2316 may generate a LB mid signal 2360 based on the mid channel signal 2370. For example, the LB signal regenerator 2316 may generate the LB mid signal 2360 by filtering the mid channel signal 2370. The LB signal regenerator 2316 may provide the LB mid signal 2360 to the LB mid core coder 2320. The LB mid core coder 2320 may generate parameters (e.g., core parameters 2371, parameters 2375, or both) based on the LB mid signal 2360. The core parameters 2371, the parameters 2375, or both, may include an excitation parameter, a voicing parameter, etc. The LB mid core coder 2320 may provide the core parameters 2371 to the mid BWE coder 2314, the parameters 2375 to the LB side core coder 2318, or both. The core parameters 2371 may be the same as or distinct from the parameters 2375. For example, the core parameters 2371 may include one or more of the parameters 2375, may exclude one or more of the parameters 2375, may include one or more additional parameters, or a combination thereof. The mid BWE coder 2314 may generate a coded mid BWE signal 2373 based on the mid channel signal 2370, the core parameters 2371, or a combination thereof. The mid BWE coder 2314 may also generate a set of first gain parameters 2394 and LPC parameters 2392 based on the mid channel signal 2370, the core parameters 2371, or a combination thereof. The mid BWE coder 2314 may provide the coded mid BWE signal 2373 to the BWE spatial balancer 2312. The BWE spatial balancer 2312 may generate parameters (e.g., one or more gain parameters, spectral adjustment parameters, other parameters, or a combination thereof) based on the coded mid BWE signal 2373, a left HB signal 2396 (e.g., a high-band portion of a left channel signal), a right HB signal 2398 (e.g., a high-band portion of a right channel signal), or a combination thereof.
The LB signal regenerator 2316 may generate a LB side signal 2362 based on the side channel signal 2372. For example, the LB signal regenerator 2316 may generate the LB side signal 2362 by filtering the side channel signal 2372. The LB signal regenerator 2316 may provide the LB side signal 2362 to the LB side core coder 2318.
Thus, the system 2300 of
Referring to
The encoded HB mid signal 2102 includes the LPC parameters 2392 and the set of first gain parameters 2394. The LPC parameters 2392 may indicate a high-band line spectral frequency (LSF) index. The set of first gain parameters 2394 may indicate a gain frame index, a gain shapes index, or both. The encoded HB side signal 2108 includes LPC parameters 2492 and a set of gain parameters 2494. The LPC parameters 2492 may indicate a high-band LSF index. The set of gain parameters 2494 may indicate a gain frame index, a gain shapes index, or both. The encoded LB mid signal 2104 may include core parameters 2371, and the encoded LB side signal 2110 may include core parameters 2471.
Referring to
An audio signal 2528 may be provided to the down-mixer 2502. According to one implementation, the audio signal 2528 may include the first audio signal 130 and the second audio signal 132. The down-mixer 2502 may perform a down-mix operation to generate the mid channel signal 2370 and the side channel signal 2372. The mid channel signal 2370 may be provided to the pre-processor 2504, and the side channel signal 2372 may be provided to the side-coder 2510.
The pre-processor 2504 may generate pre-processing parameters 2570 based on the mid channel signal 2370. The pre-processing parameters 2570 may include the first number of bits 1916, the second number of bits 1918, the first HB coding mode 1912, the first LB coding mode 1913, the second HB coding mode 1914, and the second LB coding mode 1915. The mid channel signal 2370 and the pre-processing parameters 2570 may be provided to the mid-coder 2506. Based on the coding mode, the mid-coder 2506 may selectively couple to the first HB mid-coder 2508 or to the second HB mid-coder 2509. The side-coder 2510 may couple to the HB side-coder 2512.
Referring to
The method 2600 includes determining, at a device, a shift value and a second shift value, at 2602. The shift value may be indicative of a shift of a first audio signal relative to a second audio signal, and the second shift value may be based on the shift value. For example, referring to
The method 2600 also includes determining, at the device, a bit allocation based on the second shift value and the shift value, at 2604. For example, referring to
The method 2600 also includes generating, at the device, at least one encoded signal based on the bit allocation, at 2606. The at least one encoded signal may be based on first samples of the first audio signal and second samples of the second audio signal. The second samples may be time-shifted relative to the first samples by an amount that is based on the second shift value. For example, referring to
The method 2600 also includes sending the at least one encoded signal to a second device, at 2608. For example, referring to
According to one implementation, the method 2600 includes determining that the bit allocation has a first value in response to a difference between the shift value and the second shift value satisfying a threshold. The at least one encoded signal may include a first encoded signal and a second encoded signal. The first encoded signal may correspond to a mid signal and the second encoded signal may correspond to a side signal. The bit allocation may indicate that a first number of bits are allocated to the first encoded signal and that a second number of bits are allocated to the second encoded signal. The method 2600 may also include decreasing the first number of bits and increasing the second number of bits in response to a difference between the shift value and the second shift value satisfying a first threshold.
According to one implementation, the method 2600 may include generating the mid signal based on a sum of the first audio signal and the second audio signal. The method 2600 may also include generating the side signal based on a difference between the first audio signal and the second audio signal. According to one implementation of the method 2600, the first encoded signal includes a low-band mid signal and the second encoded signal includes a low-band side signal. According to another implementation of the method 2600, the first encoded signal includes a high-band mid signal and the second encoded signal includes a high-band side signal.
According to one implementation, the method 2600 includes determining a coding mode based on the shift value and the second shift value. The at least one encoded signal may be based on the coding mode. The method 2600 may also include generating a first encoded signal based on a first coding mode and generating a second encoded signal based on a second mode in response to a difference between the shift value and the second shift value satisfying a threshold. The at least one encoded signal may include the first encoded signal and the second encoded signal. According to one implementation, the first encoded signal may include a low-band mid signal, and the second encoded signal may include a low-band side signal. The first coding mode and the second coding mode may include an ACELP coding mode. According to another implementation, the first encoded signal may include a high-band mid signal, and the second encoded signal may include a high-band side signal. The first coding mode and the second coding mode may include a BWE code mode.
According to one implementation, the method 2600 includes generating an encoded low-band mid signal based on an ACELP coding mode and generating an encoded low-band side signal based on a predictive ACELP coding mode. The at least one encoded signal may include the encoded low-band mid signal and one or more parameters corresponding to the encoded low-band side signal.
According to one implementation, the method 2600 includes generating an encoded high-band mid signal based on a BWE coding mode in response to a difference between the shift value and the second shift value failing to satisfy a threshold. The method 2600 may also include generating an encoded high-band side signal based on a blind BWE coding mode in response to the difference failing to satisfy the threshold. The at least one encoded signal may include the encoded high-band mid signal and one or more parameters corresponding to the encoded high-band side signal.
The method 2600 of
Referring to
The method 2700 may include determining, at a device, a shift value and a second shift value, at 2702. The shift value may be indicative of a shift of a first audio signal relative to a second audio signal, and the second shift value may be based on the shift value. For example, referring to
The method 2700 may also include determining, at the device, a coding mode based on the second shift value and the shift value, at 2704. The method 2700 may also include generating, at the device, at least one encoded signal based on the coding mode, at 2706. The at least one encoded signal may be based on first samples of the first audio signal and second samples of the second audio signal. The second samples may be time-shifted relative to the first samples by an amount that is based on the second shift value. For example, referring to
The method 2700 may also include sending the at least one encoded signal to a second device, at 2708. For example, referring to
The method 2700 may also include generating a first encoded signal based on a first coding mode and generating a second encoded signal based on a second coding mode in response to a difference between the shift value and the second shift value satisfying a threshold. The at least one encoded signal may include the first encoded signal and the second encoded signal. According to one implementation, the first encoded signal may include a low-band mid signal, and the second encoded signal may include a low-band side signal. The first coding mode and the second coding mode may include an ACELP coding mode. According to another implementation, the first encoded signal may include a high-band mid signal, and the second encoded signal may include a high-band side signal. The first coding mode and the second coding mode may include a BWE coding mode.
According to one implementation, the method 2700 may also include generating an encoded low-band mid signal based on an ACELP coding mode and generating an encoded low-band side signal based on a predictive ACELP coding mode in response to a difference between the shift value and the second shift value failing to satisfy a threshold. The at least one encoded signal may include the encoded low-band mid signal and one or more parameters corresponding to the encoded low-band side signal.
According to another implementation, the method 2700 may also include generating an encoded high-band mid signal based on a BWE coding mode and generating an encoded high-band side signal based on a blind BWE coding mode in response to a difference between the shift value and the second shift value failing to satisfy a threshold. The at least one encoded signal may include the encoded high-band mid signal and one or more parameters corresponding to the encoded high-band side signal.
According to one implementation, in response to a difference between the shift value and the second shift value satisfying a first threshold and failing to satisfy a second threshold, the method 2700 may include generating an encoded low-band mid signal and an encoded low-band side signal based on an ACELP coding mode. The method 2700 may also include generating an encoded high-band signal based on a BWE coding mode and generating an encoded high-band side signal based on a blind BWE coding mode. The at least one encoded signal may include the encoded high-band mid signal, the encoded low-band mid signal, the encoded low-band side signal, and one or more parameters corresponding to the encoded high-band side signal.
According to one implementation, the method 2700 may include determining a bit allocation based on the second shift value and the shift value. The at least one encoded signal may be generated based on the bit allocation. The at least one encoded signal may include a first encoded signal and a second encoded signal. The bit allocation may indicate that a first number of bits are allocated to the first encoded signal and that a second number of bits are allocated to the second encoded signal. The method 2700 may also include decreasing the first number of bits and increasing the second number of bits in response to a difference between the shift value and the second shift value satisfying a first threshold.
Referring to
The method 2800 includes determining, at a device, a first mismatch value indicative of a first amount of a temporal mismatch between a first audio signal and a second audio signal, at 2802. For example, referring to
The method 2800 also includes determining, at the device, a second mismatch value, the second mismatch value indicative of a second amount of a temporal mismatch between the first audio signal and the second audio signal, at 2804. For example, the encoder 114 (or another processor at the first device 104) may determine the tentative shift value 536, the interpolated shift value 538, the amended shift value 540, or a combination thereof, as described with reference to
The second frame to be encoded may be subsequent to the first frame to be encoded. For example, at least some samples associated with the second frame to be encoded may be subsequent to at least some samples associated with the first frame to be encoded in the first samples 320 of the first audio signal 130 or in the second samples 350 of the second audio signal 132. In a particular aspect, the samples 326-332 of the second frame to be encoded may be subsequent to the samples 322-324 of the first frame to be encoded in the first samples 320 of the first audio signal 130. To illustrate, each of the samples 326-332 may be associated with a timestamp indicating a later time than indicated by a timestamp associated with any of the samples 322-324. In some aspects, the samples 354-360 (or the samples 358-364) of the second frame to be encoded may be subsequent to the particular samples of the first frame to be encoded in the second samples 350 of the second audio signal 132.
The method 2800 further includes determining, at the device, an effective mismatch value based on the first mismatch value and the second mismatch value, at 2806. For example, the encoder 114 (or another processor at the first device 104) may determine the amended shift value 540, the final shift value 116, or both, according to the techniques described with respect to
The encoder 114 (or another processor at the first device 104) may generate the effective mismatch value to be greater than or equal to the first value and less than or equal to the second value. For example, the encoder 114 may generate the final shift value 116 to equal a particular value (e.g., 0) that indicates no time shift in response to determining that the first shift value 962 is greater than 0 and the amended shift value 540 is less than 0 or that the first shift value 962 is less than 0 and the amended shift value 540 is greater than 0, as described with reference to
As another example, the encoder 114 may generate the final shift value 116 to equal the estimated shift value 1072, as described with reference to
In a particular aspect, the encoder 114 may generate the amended shift value 540 to be greater than or equal to the lower shift value 930 and less than or equal to the greater shift value 932, as described with reference to
The method 2800 also includes generating, based at least partially on the second frame to be encoded, at least one encoded signal having a bit allocation. For example, the encoder 114 (or another processor at the first device 104) may generate the encoded signals 102 based on the second frame to be encoded, as described with reference to
The encoded signals 102 may have a bit allocation, as described with reference to
The method 2800 further includes sending the at least one encoded signal to a second device, at 2810. For example, referring to
The method 2800 may also include generating a first bit allocation associated with the first frame to be encoded, as described with reference to
The method 2800 may further include determining the comparison values 534 of
The method 2800 may also include determining boundary comparison values of the comparison values, as described with reference to
The encoder 114 may determine that a particular number of frames to be encoded (e.g., three frames) that are prior to the second frame to be encoded are identified as indicative of a monotonic trend, as described with reference to
The method 2800 may further include determining a coding mode based at least in part on the effective mismatch value. For example, the encoder 114 may determine the first LB coding mode 1913, the second LB coding mode 1915, the first HB coding mode 1912, the second HB coding mode 1914, or a combination thereof, as described with reference to
According to some implementations, the first HB coding mode 1912 may include a BWE coding mode, and the second HB coding mode 1914 may include a blind BWE coding mode, as described with reference to
According to some implementations, the first HB coding mode 1912 may include a BWE coding mode, and the second HB coding mode 1914 may include a BWE coding mode, as described with reference to
According to some implementations, the first LB coding mode 1913 may include an ACELP coding mode, the second LB coding mode 1915 may include an ACELP coding mode, the first HB coding mode 1912 may include a BWE coding mode, the second HB coding mode 1914 may include a blind BWE coding mode, or a combination thereof, as described with reference to
According to some implementations, the first LB coding mode 1913 may include an ACELP coding mode, the second LB coding mode 1915 may include a predictive ACELP coding mode, or both, as described with reference to
Referring to
In a particular implementation, the device 2900 includes a processor 2906 (e.g., a central processing unit (CPU)). The device 2900 may include one or more additional processors 2910 (e.g., one or more digital signal processors (DSPs)). The processors 2910 may include a media (e.g., speech and music) coder-decoder (CODEC) 2908, and an echo canceller 2912. The media CODEC 2908 may include the decoder 118, the encoder 114, or both, of
The device 2900 may include a memory 153 and a CODEC 2934. Although the media CODEC 2908 is illustrated as a component of the processors 2910 (e.g., dedicated circuitry and/or executable programming code), in other implementations one or more components of the media CODEC 2908, such as the decoder 118, the encoder 114, or both, may be included in the processor 2906, the CODEC 2934, another processing component, or a combination thereof.
The device 2900 may include the transmitter 110 coupled to an antenna 2942. The device 2900 may include a display 2928 coupled to a display controller 2926. One or more speakers 2948 may be coupled to the CODEC 2934. One or more microphones 2946 may be coupled, via the input interface(s) 112, to the CODEC 2934. In a particular implementation, the speakers 2948 may include the first loudspeaker 142, the second loudspeaker 144 of
The memory 153 may include instructions 2960 executable by the processor 2906, the processors 2910, the CODEC 2934, another processing unit of the device 2900, or a combination thereof, to perform one or more operations described with reference to
One or more components of the device 2900 may be implemented via dedicated hardware (e.g., circuitry), by a processor executing instructions to perform one or more tasks, or a combination thereof. As an example, the memory 153 or one or more components of the processor 2906, the processors 2910, and/or the CODEC 2934 may be a memory device, such as a random access memory (RAM), magnetoresistive random access memory (MRAM), spin-torque transfer MRAM (STT-MRAM), flash memory, read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), registers, hard disk, a removable disk, or a compact disc read-only memory (CD-ROM). The memory device may include instructions (e.g., the instructions 2960) that, when executed by a computer (e.g., a processor in the CODEC 2934, the processor 2906, and/or the processors 2910), may cause the computer to perform one or more operations described with reference to
In a particular implementation, the device 2900 may be included in a system-in-package or system-on-chip device (e.g., a mobile station modem (MSM)) 2922. In a particular implementation, the processor 2906, the processors 2910, the display controller 2926, the memory 153, the CODEC 2934, and the transmitter 110 are included in a system-in-package or the system-on-chip device 2922. In a particular implementation, an input device 2930, such as a touchscreen and/or keypad, and a power supply 2944 are coupled to the system-on-chip device 2922. Moreover, in a particular implementation, as illustrated in
The device 2900 may include a wireless telephone, a mobile communication device, a mobile phone, a smart phone, a cellular phone, a laptop computer, a desktop computer, a computer, a tablet computer, a set top box, a personal digital assistant (PDA), a display device, a television, a gaming console, a music player, a radio, a video player, an entertainment unit, a communication device, a fixed location data unit, a personal media player, a digital video player, a digital video disc (DVD) player, a tuner, a camera, a navigation device, a decoder system, an encoder system, a base station, a vehicle, or any combination thereof.
In a particular implementation, one or more components of the systems described herein and the device 2900 may be integrated into a decoding system or apparatus (e.g., an electronic device, a CODEC, or a processor therein), into an encoding system or apparatus, or both. In other implementations, one or more components of the systems described herein and the device 2900 may be integrated into a wireless communication device (e.g., a wireless telephone), a tablet computer, a desktop computer, a laptop computer, a set top box, a music player, a video player, an entertainment unit, a television, a game console, a navigation device, a communication device, a personal digital assistant (PDA), a fixed location data unit, a personal media player, a base station, a vehicle, or another type of device.
It should be noted that various functions performed by the one or more components of the systems described herein and the device 2900 are described as being performed by certain components or modules. This division of components and modules is for illustration only. In an alternate implementation, a function performed by a particular component or module may be divided amongst multiple components or modules. Moreover, in an alternate implementation, two or more components or modules of the systems described herein may be integrated into a single component or module. Each component or module illustrated in systems described herein may be implemented using hardware (e.g., a field-programmable gate array (FPGA) device, an application-specific integrated circuit (ASIC), a DSP, a controller, etc.), software (e.g., instructions executable by a processor), or any combination thereof.
In conjunction with the described implementations, an apparatus includes means for determining a bit allocation based on a shift value and a second shift value. The shift value may be indicative of a shift of a first audio signal relative to a second audio signal, and the second shift value may be based on the shift value. For example, the means for determining the bit allocation may include the bit allocator 1908 of
The apparatus may also include means for transmitting at least one encoded signal that is generated based on the bit allocation. The at least one encoded signal may be based on first samples of the first audio signal and second samples of the second audio signal, and the second samples may be time-shifted relative to the first samples by an amount that is based on the second shift value. For example, the means for transmitting may include the transmitter 110 of
Also in conjunction with the described implementations, an apparatus includes means for determining a first mismatch value indicative of a first amount of temporal mismatch between a first audio signal and a second audio signal. The first mismatch value is associated with a first frame to be encoded. For example, the means for determining the first mismatch value may include the encoder 114, the temporal equalizer 108 of
The apparatus also includes means for determining a second mismatch value indicative of a second amount of temporal mismatch between the first audio signal and the second audio signal. The second mismatch value is associated with a second frame to be encoded. The second frame to be encoded is subsequent to the first frame to be encoded. For example, the means for determining the second mismatch value may include the encoder 114, the temporal equalizer 108 of
The apparatus further includes means for determining an effective mismatch value based on the first mismatch value and the second mismatch value. The second frame to be encoded includes first samples of the first audio signal and second samples of the second audio signal. The second samples are selected based at least in part on the effective mismatch value. For example, the means for determining the effective mismatch value may include the encoder 114, the temporal equalizer 108 of
The apparatus also includes means for transmitting at least one encoded signal having a bit allocation that is at least partially based on the effective mismatch value. The at least one encoded signal is generated based at least partially on the second frame to be encoded. For example, the means for transmitting may include the transmitter 110 of
Those of skill would further appreciate that the various illustrative logical blocks, configurations, modules, circuits, and algorithm steps described in connection with the implementations disclosed herein may be implemented as electronic hardware, computer software executed by a processing device such as a hardware processor, or combinations of both. Various illustrative components, blocks, configurations, modules, circuits, and steps have been described above generally in terms of their functionality. Whether such functionality is implemented as hardware or executable software depends upon the particular application and design constraints imposed on the overall system. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present disclosure.
The steps of a method or algorithm described in connection with the implementations disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. A software module may reside in a memory device, such as random access memory (RAM), magnetoresistive random access memory (MRAM), spin-torque transfer MRAM (STT-MRAM), flash memory, read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), registers, hard disk, a removable disk, or a compact disc read-only memory (CD-ROM). An exemplary memory device is coupled to the processor such that the processor can read information from, and write information to, the memory device. In the alternative, the memory device may be integral to the processor. The processor and the storage medium may reside in an application-specific integrated circuit (ASIC). The ASIC may reside in a computing device or a user terminal. In the alternative, the processor and the storage medium may reside as discrete components in a computing device or a user terminal.
The previous description of the disclosed implementations is provided to enable a person skilled in the art to make or use the disclosed implementations. Various modifications to these implementations will be readily apparent to those skilled in the art, and the principles defined herein may be applied to other implementations without departing from the scope of the disclosure. Thus, the present disclosure is not intended to be limited to the implementations shown herein but is to be accorded the widest scope possible consistent with the principles and novel features as defined by the following claims.
The present application claims priority from and is a continuation application of pending U.S. patent application Ser. No. 15/461,356, filed Mar. 16, 2017 and entitled “AUDIO PROCESSING FOR TEMPORALLY MISMATCHED SIGNALS,” which claims priority from U.S. Provisional Patent Application No. 62/310,611, filed Mar. 18, 2016, and entitled “AUDIO PROCESSING FOR TEMPORALLY OFFSET SIGNALS,” the contents of both of which are incorporated by reference in their entirety.
Number | Date | Country | |
---|---|---|---|
62310611 | Mar 2016 | US |
Number | Date | Country | |
---|---|---|---|
Parent | 15461356 | Mar 2017 | US |
Child | 16049688 | US |