CN101030379A - Method and apparatus for allocating digital voice-frequency signal bit - Google Patents

Method and apparatus for allocating digital voice-frequency signal bit Download PDF

Info

Publication number
CN101030379A
CN101030379A CNA2007100647878A CN200710064787A CN101030379A CN 101030379 A CN101030379 A CN 101030379A CN A2007100647878 A CNA2007100647878 A CN A2007100647878A CN 200710064787 A CN200710064787 A CN 200710064787A CN 101030379 A CN101030379 A CN 101030379A
Authority
CN
China
Prior art keywords
bit
particle
bit number
channel
value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CNA2007100647878A
Other languages
Chinese (zh)
Other versions
CN101030379B (en
Inventor
林中松
侯培新
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Vimicro Corp
Original Assignee
Vimicro Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Vimicro Corp filed Critical Vimicro Corp
Priority to CN2007100647878A priority Critical patent/CN101030379B/en
Publication of CN101030379A publication Critical patent/CN101030379A/en
Application granted granted Critical
Publication of CN101030379B publication Critical patent/CN101030379B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

A method for distributing bit of digital audio signal includes intercepting inputted digital audio signal according to set particle to obtain current particle of digital audio signal and distributing bit on current particle according to energy of current particle. The device used for realizing said method is also disclosed.

Description

A kind of method and apparatus of digital audio and video signals Bit Allocation in Discrete
Technical field
The present invention relates to the audio compression coding field, particularly relate to the method and apparatus of a kind of digital audio and video signals Bit Allocation in Discrete in the system that uses the audio compression Code And Decode.
Background technology
Audio compression techniques refers to the digital audio and video signals stream that sampled voice is obtained, use suitable Digital Signal Processing, do not losing the useful information amount, or introduce the loss insignificant condition under, reduce its code check, thereby audio compression techniques is also referred to as compressed encoding, and has to be called accordingly and decompress or the inverse transformation of decoding.Such as, MP3 (MPEGAudioLayer3) utilizes audio compression techniques, when keeping better tonequality, digital audio and video signals can be compressed into the less file of capacity with the compressibility of 1:10 even 1:12.Therefore, the employing audio compression techniques can be removed the redundance in the digital audio and video signals, more good utilisation storage and transfer resource.
At present, before digital audio and video signals is carried out compressed encoding, usually to digital audio and video signals frame by frame or littler allocation units carry out Bit Allocation in Discrete, with the bit number that distributes the employed maximum code long value of digital audio and video signals, should guarantee in compression encoding process that just the code length that uses is no more than the bit number of distribution as this frame of compression or these allocation units.Simultaneously, again as far as possible must be near the bit value of distributing, adopt the method for Bit Allocation in Discrete, can be according to the characteristic of digital audio and video signals, adjust the compressibility of each frame of digital audio and video signals or each cell mesh flexibly, for distributing more bit number than the frame or the unit of multi-bit, frame or the less bit number of unit distribution for the less bit number of needs finally reach the purpose that improves audio visual effect.Usually, the smallest allocation unit with Bit Allocation in Discrete is called particle (granule).
Such as, for MP3, the object of its compressed encoding be to the time domain samples of sampled voice through mixing the domain samples after (hybrid) wave filter, be 576 domain samples to the smallest allocation unit of MP3 Bit Allocation in Discrete, promptly 576 domain samples are called a particle.If the MP3 compressed encoding adopts the mode of cbr (constant bit rate), just the total bit number that transmits in the unit interval is fixed, suppose that the MP3 cbr (constant bit rate) is 128 kilobit per seconds, the sampling rate of its sample is 32000 samples of sampling in the per second, the product that the average assignable bit number of each particle is MP3 cbr (constant bit rate) and sample time multiply by the number of samples that a particle comprises again, i.e. (128 kilobit per second/32000 sample) * 576 kilobits.Like this, though auditory perception less than particle, when compressed encoding, also can take average bit number, therefore, compression coding efficiency is low, tonequality is relatively poor.
And if adopt the digital audio and video signals Bit distribution method, just can be according to the characteristic of each particle, for each particle distributes corresponding bit number, the maximum code long value during as each particle compressed encoding reaches the purpose of raising tonequality.
At present, in the scrambler that ISO 11172-3 Annex C recommends, what adopt is the method for carrying out Bit Allocation in Discrete according to the particle entropy, promptly utilize people's ear to the limited resolution characteristic of signal amplitude, frequency, time and the psychologic acoustics characteristic of human auditory system, set up psychoacoustic model, calculate the entropy of present granule, the quantity of information that comprises of present granule just, obtaining according to the code check of the entropy of present granule and setting then is that present granule distributes maximum bit number.Specifically, be the bit number that present granule distributes different maximums according to the entropy of present granule exactly, the value of the maximum number bits that the bigger particle of entropy is distributed is also bigger, and the value of the maximum number bits that the entropy smaller particles is distributed is also less.Therefore, this method can be adjusted into the bit number that each particle distributes according to auditory perception flexibly under the constant prerequisite of code check, finally reach the purpose that improves acoustical quality.But this method need adopt psychoacoustic model to obtain entropy, the implementation procedure complexity, and operand is big.
In sum, present prior art also exists the process complexity that realizes the digital audio and video signals Bit Allocation in Discrete, the problem that operand is big.
Summary of the invention
In view of this, fundamental purpose of the present invention is to provide a kind of method of digital audio and video signals Bit Allocation in Discrete, and this method can be simplified process, reduces computing.
Another fundamental purpose of the present invention is to provide a kind of device of digital audio and video signals Bit Allocation in Discrete, and this device can be simplified process, reduces computing.
In order to reach above-mentioned first purpose, the technical scheme that the present invention proposes is: a kind of method of digital audio and video signals Bit Allocation in Discrete, and this method is:
According to the particle of setting, the digital audio and video signals of intercepting input obtains the present granule of digital audio and video signals, is this particle allocation bit number according to the energy of this particle.
When input sound channel was not monophony, this method also further comprised:
According to the sample voltage value in the input sound channel of present granule, determine the sound channel that needs the allocation bit number, according to the energy of determining sound channel the bit number that distributes for this particle further is assigned on definite sound channel again.
The method that described energy according to this particle is this particle allocation bit number is:
According to code check, specimen sample rate and the particle set, be calculated as the average number of bits that present granule distributes, the energy according to this particle is adjusted into the average number of bits that this particle distributes again, obtains the bit number that distributes into this particle.
Described energy according to this particle is adjusted into the average number of bits that this particle distributes, and the method that obtains the bit number that distributes for this particle is:
The energy of level and smooth this particle, according to the energy of this particle difference with level and smooth energy, calculate and adjust the bit number initial value, store the available bit number in bit pond of available bits and the maximum number bits that the bit pond can hold according to being used for of setting, select value to adjusting the bit number initial value, obtain adjusting bit value, with average number of bits and the addition of adjustment bit value, the average number of bits that obtains adjusting, according to predefined minimum number bits and maximum number bits for the particle distribution, the average number of bits of adjusting is selected value, obtain the bit number that distributes into particle.
If the present granule energy is P, level and smooth energy is AP, and adjusting the bit number initial value is Δ GL, and the described method that calculates adjustment bit number initial value is according to following formula:
ΔGL = nint ( C * P - AP AP ) Obtain;
Wherein, immediate integer is got in nint () expression, and C is the integer constant of setting that is directly proportional with average number of bits.
The described method that obtains adjusting bit value is:
When the adjustment bit number initial value that calculates is positive integer or zero, judge that whether the adjustment bit number initial value that calculates is greater than the available bit number in the bit pond, if, then adjust bit value and equal bit number available in the bit pond, otherwise adjusting the bit value value is the adjustment bit number initial value that calculates;
When the adjustment bit number initial value that calculates is negative integer, judge the maximum number bits whether difference that available bit number and the adjustment bit number initial value that calculates in the bit pond subtract each other is held greater than the bit pond of setting, if, then adjusting the maximum number bits that bit pond that bit value equals to set holds and the difference of the available bit number in the bit pond, is the adjustment bit number initial value that calculates otherwise adjust bit value.
The described method that obtains the bit number that distributes for this particle is:
If the average number of bits of adjusting is greater than the maximum number bits of setting, then the bit number value of distributing for this particle equals maximum number bits, if less than the minimum number bits of setting, then the bit number value of distributing for this particle equals minimum number bits, otherwise, the average number of bits that the bit number value that this particle distributes equals to adjust.
The described method of determining the sound channel that needs the allocation bit number is:
Calculate the channel energies of center channel, surround channel; The energy of judging surround channel whether greater than center channel energy half, if the sound channel that needs the allocation bit number is L channel and R channel, otherwise the sound channel that needs the allocation bit number is center channel and surround channel.
When described input sound channel was L channel and R channel, the method for the channel energies of described calculating center channel, surround channel comprised: according to the sample voltage value in L channel and the R channel, obtain the sample voltage value of center channel, surround channel; According to the sample voltage value of center channel, surround channel, calculate the energy of center channel, surround channel.
If the channel energies of two sound channels determining is P1 and P2, the bit number initial value that is two channel allocation is GL1 and GL2, for particle allocation bit number is GL, the method that the bit number that described handle distributes for this particle further is assigned on definite sound channel is according to following formula:
GL 1 = max ( min ( GL - MC , nint ( GL * log 2 ( P 1 ) log 2 ( P 1 ) + log 2 ( P 2 ) ) ) , MC ) Obtain.
GL2=GL-GL1
In order to reach above-mentioned second purpose, the technical scheme that the present invention proposes is: a kind of device of digital audio and video signals Bit Allocation in Discrete, this device comprise that the particle bit number distributes mould to determine;
Described particle bit number distribution module, the energy that is used for according to the present granule of input digital audio signal is this particle allocation bit number.
When input sound channel was not monophony, this device further comprised sound channel bit number distribution module;
Described sound channel bit number distribution module is used for the input sound channel energy according to present granule, determines the sound channel that needs the allocation bit number, according to the energy of determining sound channel the bit number that distributes for this particle further is assigned on definite sound channel again.
Described particle bit number distribution module comprises average number of bits computing unit, particle adjustment unit;
Described average number of bits computing unit is used for being calculated as the average number of bits that present granule distributes according to code check, specimen sample rate and the particle set, and the average number of bits of distributing for this particle that calculates is inputed to the particle adjustment unit;
Described particle adjustment unit is used for adjusting the average number of bits for this particle distribution that the average number of bits computing unit is imported according to the energy of present granule, obtains the bit number that distributes into this particle.
Described particle adjustment unit comprises the energy smoother, adjusts bit number initial value counter, adjusts bit value selection value device and particle bit number determiner;
Described energy smoother is used for the particle energy is done smoothly, the flat particles energy that obtains is input to adjusts bit number initial value counter;
Described adjustment bit number initial value counter is used for calculating and adjusting the bit number initial value according to the present granule energy of energy smoother input and the difference of flat particles energy, the adjustment bit number initial value that calculates is input to adjusts bit value selection value device;
Described adjustment bit value is selected the value device, be used for the maximum number bits that the bit pond according to the available bit number in bit pond and setting holds, select the adjustment bit number initial value of value device input to select value to adjusting bit value, obtain adjusting bit value, the adjustment bit value that obtains is input to particle bit number determiner;
Described particle bit number determiner, be used for selecting the adjustment bit value of value device input according to adjusting bit value, calculate the average number of bits of adjustment, again according to the minimum number bits and the maximum number bits of distributing for particle in the predefined unit interval, the average number of bits of adjusting is selected value, obtain the bit number that distributes into particle.
Described sound channel bit number distribution module comprises sound channel determining unit and sound channel adjustment unit;
Described sound channel determining unit, be used for according to particle input sound channel energy, calculate the channel energies of center channel, surround channel, determine the sound channel of needs allocation bit number again according to center channel and surround channel energy relationship, the channel energies of determining that needs the allocation bit number is input to the sound channel adjustment unit;
Described sound channel adjustment unit is used for energy according to definite sound channel of sound channel determining unit input the sound channel of distributing to needs allocation bit number for the bit number of particle distribution.
In sum, the method and apparatus of a kind of digital audio and video signals Bit Allocation in Discrete of the present invention's proposition.Have the following advantages:
The first, the present invention comes for intercepting the present granule allocation bit number that digital audio and video signals obtains according to energy, the value of the bit number that the bigger particle of energy is distributed is also bigger, the value of the bit number that the energy smaller particles is distributed is also less, the computing method of psychoacoustic model have been avoided adopting, process is simple, and operand is few.
The second, the present invention comes by reducing the mode of quantizing noise, to improve tonequality for intercepting the present granule allocation bit number that digital audio and video signals obtains according to energy, can guarantee tonequality when operand is few.
When three, the present invention adopted embedded system to realize, shared datarams expense was little, can save storage resources.
Therefore, a kind of method and apparatus that intercepts the digital audio and video signals Bit Allocation in Discrete provided by the invention can be simplified process, reduces computing.
Description of drawings
Fig. 1 is the schematic flow sheet of the preferred embodiment of the method for digital audio and video signals Bit Allocation in Discrete of the present invention;
Fig. 2 is the structural representation of the preferred embodiment of the device of digital audio and video signals Bit Allocation in Discrete of the present invention.
Embodiment
For making the purpose, technical solutions and advantages of the present invention clearer, the present invention is described in further detail below in conjunction with the accompanying drawings and the specific embodiments.
Technical scheme of the present invention is: at the digital audio and video signals compressed encoding of known code check, just under the situation that total bit number is fixed in the unit interval, in order to make the binary encoding quantizing noise reach minimum, according to the particle of setting, the digital audio and video signals of intercepting input, obtaining the present granule of digital audio and video signals, is this particle allocation bit number according to the energy of this particle.The value of the bit number that the bigger particle of energy is distributed is also bigger, and the value of the bit number that the energy smaller particles is distributed is also less.
Fig. 1 below in conjunction with process flow diagram, provides a specific embodiment of the present invention for the schematic flow sheet of digital audio and video signals Bit Allocation in Discrete of the present invention.
Step 100: by the particle of setting, the intercepting digital audio and video signals obtains present granule.
Step 101: be calculated as the average number of bits that present granule distributes.
In the present embodiment, according to code check and the specimen sample rate set, and the particle of setting, be calculated as the average number of bits that present granule distributes, if the MP3 cbr (constant bit rate) is 128 kilobit per seconds, sampling rate is 32000 samples of per second, and present granule is 576 samples, then average number of bits is (128 kilobit per second/32000 sample) * 576 kilobits, is designated as CL.
Step 102: the energy that calculates present granule.
In the present embodiment, suppose that input sound channel is L channel and R channel, can be according to the method for calculating energy in the prior art, promptly the sample voltage value in the present granule input sound channel is asked square value, calculate the energy of particle input sound channel, energy to left and right input sound channel is sued for peace, and obtains the particle energy.If input sound channel is L channel, R channel, center channel and surround channel, then will calculate the energy of these four input sound channels respectively, and summation obtains the energy of present granule.If input sound channel is a monophony, then the present granule energy just equals the input sound channel energy.
Step 103: flat particles energy.
Present embodiment adopts following formula, and particle energy P is carried out smoothly obtaining flat particles energy AP, and its formula is:
AP=aP+(1-a)AP
Here a is a smoothing factor, and value is between 0 to 1.
Step 104: calculate and adjust the bit number initial value.
In the present embodiment, calculating the method for adjusting bit number initial value Δ GL is according to following formula:
ΔGL = nint ( C * P - AP AP )
Immediate integer is got in nint () expression, and C is the integer constant of setting that is directly proportional with average number of bits.C=0.25*CL in the present embodiment.
Step 105: select value to adjusting the bit number initial value, obtain adjusting bit value.
Select value to adjusting the bit number initial value, obtain adjusting bit value Δ GL 1Process be: when the adjustment bit number initial value that calculates is positive integer or zero, judge that whether the adjustment bit number initial value that calculates is greater than the available bit number in the bit pond, if, then adjust bit value and equal available bit number, otherwise adjusting the bit value value is the adjustment bit number initial value that calculates;
When the adjustment bit number initial value that calculates is negative integer, judge the maximum number bits whether difference that available bit number and the adjustment bit number initial value that calculates in the bit pond subtract each other is held greater than the bit pond of setting, if, then adjusting the maximum number bits that bit pond that bit value equals to set holds and the difference of the available bit number in the bit pond, is the adjustment bit number initial value that calculates otherwise adjust bit value.Its expression formula is:
ΔGL 1=max(min(ΔGL,Re?sev),Re?sev-4095))
Wherein, Re sev represents the size in bit pond;
In the present embodiment, the bit pond is used to store Bit Allocation in Discrete by to the front particle for what set, the available bits that saves, and these bits can be used in the bit number of adjusting present granule, and the value of bit pond size Re sev is between 0 to 4095.
Step 106: the average number of bits of adjusting is selected value, obtain the bit number that distributes into particle.
Earlier with average number of bits and the addition of adjustment bit value, the average number of bits CL that obtains adjusting 1If the average number of bits of adjusting is greater than the maximum number bits of setting, then the bit number value of distributing for particle equals maximum number bits, if less than the minimum number bits of setting, then the bit number value of distributing for particle equals minimum number bits, otherwise, the average number of bits CGL that the bit number value that particle distributes equals to adjust.In the present embodiment, the maximum of setting, minimum bit number average are the integer constant that is directly proportional with average number of bits, such as, minimum number bits MC can get
Figure A20071006478700131
The value of maximum number bits can equal 2CL, and it realizes that formula can be expressed as:
CGL=CL+min(CL,max(ΔGL 1,MC-CL))
Step 107: whether the input sound channel number greater than 1, if, execution in step 108, otherwise execution in step 110.
Step 108: sound channel that need to determine the allocation bit number.
The input sound channel of present embodiment is L channel and R channel, at first will be according to the sample voltage value L and the R of L channel and R channel, obtain the sample voltage value (L+R)/2 of center channel, surround channel and (L-R)/2, then according to energy calculation method in the prior art, obtain the energy of center channel, surround channel, if the energy of surround channel is greater than center channel energy one half, the sound channel that needs the allocation bit number is L channel and R channel, otherwise is center channel and surround channel.If comprise center channel and surround channel in the input sound channel then the direct energy that obtains center channel, surround channel according to center channel, surround channel sample voltage value, then, the energy that carries out surround channel is determined the sound channel that needs the allocation bit number whether greater than the judgement of center channel energy.
Step 109: will distribute to the sound channel that needs the allocation bit number for the bit number that particle distributes.
In the present embodiment, if the channel energies of two sound channels determining is P1 and P2, be that interior bit number initial value of two channel allocation unit interval is GL1 and GL2,, then give the channel allocation bit number that needs the allocation bit number according to following formula for particle allocation bit number is GL:
GL 1 = max ( min ( GL - MC , nint ( GL * log 2 ( P 1 ) log 2 ( P 1 ) + log 2 ( P 2 ) ) ) , MC )
GL2=GL-GL1
Step 110: the bit number that distributes is exported as the maximum code long value of compressed encoding.
Should not make code length surpass the bit value of distribution in the compression encoding process, but will after coding is finished, adjust the numerical value of bit pond Re sev according to the bit number that reality consumed as far as possible near these numerical value.
Fig. 2 is a structural representation of the present invention, and this device comprises particle bit number distribution module 210;
Particle bit number distribution module 210, the energy that is used for according to present granule is this particle allocation bit number.Wherein, particle bit number distribution module 210 comprises average number of bits computing unit 211, particle adjustment unit 212;
Average number of bits computing unit 211, according to code check and the specimen sample rate set, and the particle of setting, be calculated as the average number of bits that particle distributes, the average number of bits of calculating of distributing for particle is inputed to particle adjustment unit 212;
Particle adjustment unit 212 can be adjusted the average number of bits for the particle distribution that average number of bits computing unit 211 is imported according to the present granule energy, exports behind the bit number that obtains distributing for particle.
Energy smoother 213 be can also comprise in the particle adjustment unit 212, adjust bit number initial value counter 214, bit value selection value device 215 and particle bit number determiner 216 adjusted;
Energy smoother 213 is done smoothly the present granule energy, obtains the flat particles energy, the flat particles energy is input to adjusts bit number initial value counter 214;
Adjust bit number initial value counter 214,, calculate and adjust the bit number initial value, the adjustment bit number initial value that obtains is input to the adjustment bit value selects value device 215 according to the present granule energy of energy smoother 213 inputs and the difference of flat particles energy;
Adjust bit value and select value device 215, the maximum number bits of holding according to the bit pond of available bit number in the bit pond and setting, the adjustment bit number initial value of adjusting 214 inputs of bit number initial value counter is selected value, obtain adjusting bit value, will adjust bit value and be input to particle maximum number bits determiner 216;
Particle bit number determiner 216, select the adjustment bit value of value device 215 inputs to calculate the average number of bits of adjusting according to adjusting bit value, according to predefined minimum number bits and maximum number bits for the particle distribution, the average number of bits of adjusting is selected value, this bit value of output behind the bit number that obtains distributing into particle.
The structural representation of Fig. 2 is that input sound channel is not monaural situation, and therefore device also comprises sound channel bit number distribution module 220;
Sound channel bit number distribution module 220 according to the input sound channel energy of present granule, is determined the sound channel that needs the allocation bit number, according to the energy of determining sound channel the bit number that distributes for particle is assigned to definite sound channel again.
Can comprise sound channel determining unit 221 and sound channel adjustment unit 222 in the sound channel bit number distribution module 220;
Sound channel determining unit 221, according to particle input sound channel energy, calculate the channel energies of center channel, surround channel, determine the sound channel of needs allocation bit number again according to center channel and surround channel energy relationship, the channel energies of determining that needs the allocation bit number is input to sound channel adjustment unit 222;
Sound channel adjustment unit 222 is according to the energy of definite sound channel of sound channel determining unit 221 input, distributing to the sound channel that needs the allocation bit number for the bit number of particle distribution.
The present invention can use embedded system to realize, also can adopt processor to realize.
Being preferred embodiment of the present invention only below, is not to be used to limit protection scope of the present invention.Within the spirit and principles in the present invention all, any modification of being done, be equal to replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (15)

1, a kind of method of digital audio and video signals Bit Allocation in Discrete is characterized in that, this method is:
According to the particle of setting, the digital audio and video signals of intercepting input obtains the present granule of digital audio and video signals, is this particle allocation bit number according to the energy of this particle.
2, method according to claim 1 is characterized in that, when input sound channel was not monophony, this method also further comprised:
According to the sample voltage value in the input sound channel of present granule, determine the sound channel that needs the allocation bit number, according to the energy of determining sound channel the bit number that distributes for this particle further is assigned on definite sound channel again.
3, method according to claim 1 and 2 is characterized in that, the method that described energy according to this particle is this particle allocation bit number is:
According to code check, specimen sample rate and the particle set, be calculated as the average number of bits that present granule distributes, the energy according to this particle is adjusted into the average number of bits that this particle distributes again, obtains the bit number that distributes into this particle.
4, method according to claim 3 is characterized in that, described energy according to this particle is adjusted into the average number of bits that this particle distributes, and the method that obtains the bit number that distributes for this particle is:
The energy of level and smooth this particle, according to the energy of this particle difference with level and smooth energy, calculate and adjust the bit number initial value, store the available bit number in bit pond of available bits and the maximum number bits that the bit pond can hold according to being used for of setting, select value to adjusting the bit number initial value, obtain adjusting bit value, with average number of bits and the addition of adjustment bit value, the average number of bits that obtains adjusting, according to predefined minimum number bits and maximum number bits for the particle distribution, the average number of bits of adjusting is selected value, obtain the bit number that distributes into particle.
5, method according to claim 4 is characterized in that, establishing the present granule energy is P, and level and smooth energy is AP, and adjusting the bit number initial value is Δ GL, and the described method that calculates adjustment bit number initial value is according to following formula:
ΔGL = min t ( C * P - AP AP ) Obtain;
Wherein, immediate integer is got in nint () expression, and C is the integer constant of setting that is directly proportional with average number of bits.
6, method according to claim 4 is characterized in that, the described method that obtains adjusting bit value is:
When the adjustment bit number initial value that calculates is positive integer or zero, judge that whether the adjustment bit number initial value that calculates is greater than the available bit number in the bit pond, if, then adjust bit value and equal bit number available in the bit pond, otherwise adjusting the bit value value is the adjustment bit number initial value that calculates;
When the adjustment bit number initial value that calculates is negative integer, judge the maximum number bits whether difference that available bit number and the adjustment bit number initial value that calculates in the bit pond subtract each other is held greater than the bit pond of setting, if, then adjusting the maximum number bits that bit pond that bit value equals to set holds and the difference of the available bit number in the bit pond, is the adjustment bit number initial value that calculates otherwise adjust bit value.
7, method according to claim 4 is characterized in that, the described method that obtains the bit number that distributes for this particle is:
If the average number of bits of adjusting is greater than the maximum number bits of setting, then the bit number value of distributing for this particle equals maximum number bits, if less than the minimum number bits of setting, then the bit number value of distributing for this particle equals minimum number bits, otherwise, the average number of bits that the bit number value that this particle distributes equals to adjust.
8, method according to claim 2 is characterized in that, the described method of determining the sound channel that needs the allocation bit number is:
Calculate the channel energies of center channel, surround channel; The energy of judging surround channel whether greater than center channel energy half, if the sound channel that needs the allocation bit number is L channel and R channel, otherwise the sound channel that needs the allocation bit number is center channel and surround channel.
9, method according to claim 8, it is characterized in that, when described input sound channel is L channel and R channel, the method of the channel energies of described calculating center channel, surround channel comprises: according to the sample voltage value in L channel and the R channel, obtain the sample voltage value of center channel, surround channel; According to the sample voltage value of center channel, surround channel, calculate the energy of center channel, surround channel.
10, method according to claim 8, it is characterized in that, if the channel energies of two sound channels determining is P1 and P2, the bit number initial value that is two channel allocation is GL1 and GL2, for particle allocation bit number is GL, the method that the bit number that described handle distributes for this particle further is assigned on definite sound channel is according to following formula:
GL 1 = max ( min ( GL - MC , nint ( GL * log 2 ( P 1 ) log 2 ( P 1 ) + log 2 ( P 2 ) ) ) , MC ) Obtain.
GL2=GL-GL1
11, a kind of device of digital audio and video signals Bit Allocation in Discrete is characterized in that, this device comprises particle bit number distribution module;
Described particle bit number distribution module, the energy that is used for according to the present granule of input digital audio signal is this particle allocation bit number.
12, device according to claim 11 is characterized in that, when input sound channel was not monophony, this device further comprised sound channel bit number distribution module;
Described sound channel bit number distribution module, be used for sample voltage value according to the input sound channel of present granule, determine the sound channel that needs the allocation bit number, according to the energy of determining sound channel the bit number that distributes for this particle further is assigned on definite sound channel again.
13, device according to claim 11 is characterized in that, described particle bit number distribution module comprises average number of bits computing unit, particle adjustment unit;
Described average number of bits computing unit is used for being calculated as the average number of bits that present granule distributes according to code check, specimen sample rate and the particle set, and the average number of bits of distributing for this particle that calculates is inputed to the particle adjustment unit;
Described particle adjustment unit is used for adjusting the average number of bits for this particle distribution that the average number of bits computing unit is imported according to the energy of present granule, obtains the bit number that distributes into this particle.
14, device according to claim 13 is characterized in that, described particle adjustment unit comprises the energy smoother, adjusts bit number initial value counter, adjusts bit value selection value device and particle bit number determiner;
Described energy smoother is used for the particle energy is done smoothly, the flat particles energy that obtains is input to adjusts bit number initial value counter;
Described adjustment bit number initial value counter is used for calculating and adjusting the bit number initial value according to the present granule energy of energy smoother input and the difference of flat particles energy, the adjustment bit number initial value that calculates is input to adjusts bit value selection value device;
Described adjustment bit value is selected the value device, be used for the maximum number bits that the bit pond according to the available bit number in bit pond and setting holds, select the adjustment bit number initial value of value device input to select value to adjusting bit value, obtain adjusting bit value, the adjustment bit value that obtains is input to particle bit number determiner;
Described particle bit number determiner, be used for selecting the adjustment bit value of value device input according to adjusting bit value, calculate the average number of bits of adjustment, again according to the minimum number bits and the maximum number bits of distributing for particle in the predefined unit interval, the average number of bits of adjusting is selected value, obtain the bit number that distributes into particle.
15, device according to claim 12 is characterized in that, described sound channel bit number distribution module comprises sound channel determining unit and sound channel adjustment unit;
Described sound channel determining unit, be used for according to particle input sound channel energy, calculate the channel energies of center channel, surround channel, determine the sound channel of needs allocation bit number again according to center channel and surround channel energy relationship, the channel energies of determining that needs the allocation bit number is input to the sound channel adjustment unit;
Described sound channel adjustment unit is used for energy according to definite sound channel of sound channel determining unit input the sound channel of distributing to needs allocation bit number for the bit number of particle distribution.
CN2007100647878A 2007-03-26 2007-03-26 Method and apparatus for allocating digital voice-frequency signal bit Expired - Fee Related CN101030379B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2007100647878A CN101030379B (en) 2007-03-26 2007-03-26 Method and apparatus for allocating digital voice-frequency signal bit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2007100647878A CN101030379B (en) 2007-03-26 2007-03-26 Method and apparatus for allocating digital voice-frequency signal bit

Publications (2)

Publication Number Publication Date
CN101030379A true CN101030379A (en) 2007-09-05
CN101030379B CN101030379B (en) 2011-10-12

Family

ID=38715681

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2007100647878A Expired - Fee Related CN101030379B (en) 2007-03-26 2007-03-26 Method and apparatus for allocating digital voice-frequency signal bit

Country Status (1)

Country Link
CN (1) CN101030379B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102714037A (en) * 2009-12-22 2012-10-03 高通股份有限公司 Audio and speech processing with optimal bit-allocation for constant bit rate applications
WO2022257824A1 (en) * 2021-06-11 2022-12-15 华为技术有限公司 Three-dimensional audio signal processing method and apparatus

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100435485C (en) * 2002-08-21 2008-11-19 广州广晟数码技术有限公司 Decoder for decoding and re-establishing multiple audio track andio signal from audio data code stream

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102714037A (en) * 2009-12-22 2012-10-03 高通股份有限公司 Audio and speech processing with optimal bit-allocation for constant bit rate applications
US8781822B2 (en) 2009-12-22 2014-07-15 Qualcomm Incorporated Audio and speech processing with optimal bit-allocation for constant bit rate applications
CN102714037B (en) * 2009-12-22 2014-09-03 高通股份有限公司 Audio and speech processing with optimal bit-allocation for constant bit rate applications
WO2022257824A1 (en) * 2021-06-11 2022-12-15 华为技术有限公司 Three-dimensional audio signal processing method and apparatus

Also Published As

Publication number Publication date
CN101030379B (en) 2011-10-12

Similar Documents

Publication Publication Date Title
CN1669359A (en) Audio coding
CN1926610A (en) Synthesizing a mono audio signal based on an encoded multi-channel audio signal
CN1647156A (en) Parametric multi-channel audio representation
CN1183685C (en) System and method for entropy ercoding quantized transform coefficients of a sigral
CN101044552A (en) Sound encoder and sound encoding method
CN1968419A (en) Image encoding method and apparatus and image decoding method and apparatus using characteristics of the human visual system
CN1248339A (en) Apparatus and method for rate determination in commuincation system
CN1092420C (en) Audio data decoding apparatus and audio data coding/decoding system
CN1947172A (en) Method, device, encoder apparatus, decoder apparatus and frequency system
CN1462429A (en) Audio coding
CN1787383A (en) Methods and apparatuses for transforming, adaptively encoding, inversely transforming and adaptively decoding an audio signal
CN1065565A (en) The coding method of digital audio and video signals
CN1512488A (en) Method and device for selecting coding speed in variable speed vocoder
CN1756086A (en) Multichannel audio data encoding/decoding method and equipment
CN1151491C (en) Audio encoding apparatus and audio encoding and decoding apparatus
CN1708787A (en) Method for encoding digital audio using advanced psychoacoustic model and apparatus thereof
CN101031960A (en) Scalable encoding device, scalable decoding device, and method thereof
CN1735928A (en) Method for encoding and decoding audio at a variable rate
CN105164749A (en) Hybrid encoding of multichannel audio
CN101067927A (en) Sound volume adjusting method and device
CN1918630A (en) Method and device for quantizing an information signal
CN103443854A (en) Automatic configuration of metadata for use in mixing audio programs from two encoded bitstreams
CN1677491A (en) Intensified audio-frequency coding-decoding device and method
CN1661924A (en) Audio codec system and audio signal encoding method using the same
CN101030379A (en) Method and apparatus for allocating digital voice-frequency signal bit

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
C17 Cessation of patent right
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20111012

Termination date: 20120326