JP2001306095A - Device and method for audio encoding - Google Patents

Device and method for audio encoding

Info

Publication number
JP2001306095A
JP2001306095A JP2000116412A JP2000116412A JP2001306095A JP 2001306095 A JP2001306095 A JP 2001306095A JP 2000116412 A JP2000116412 A JP 2000116412A JP 2000116412 A JP2000116412 A JP 2000116412A JP 2001306095 A JP2001306095 A JP 2001306095A
Authority
JP
Japan
Prior art keywords
scaling coefficient
coefficient
scaling
code amount
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.)
Pending
Application number
JP2000116412A
Other languages
Japanese (ja)
Inventor
Tetsuro Wada
哲朗 和田
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.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric 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 Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Priority to JP2000116412A priority Critical patent/JP2001306095A/en
Publication of JP2001306095A publication Critical patent/JP2001306095A/en
Pending legal-status Critical Current

Links

Landscapes

  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

PROBLEM TO BE SOLVED: To shorten the convergence time up to the determination of optimum 1st and 2nd scaling coefficients which satisfy a desired code quantity. SOLUTION: A scaling coefficient initial value control part 61 sets the initial value of the 1st scaling coefficient and the initial value of the 2nd scaling coefficient. A scaling coefficient update control part 62 updates the 2nd scaling coefficient in a direction, where the code quantity increases, evaluates a quantized noise quantity and the code quantity to find the optimum value of the 2nd scaling coefficient, and updates the 1st scaling coefficient in the increasing direction of the code quantity so that the difference between the code quantity and a target code quantity, when the 2nd scaling coefficient has an optimum value is put into a specific range, to find the optimum value of the 1st scaling coefficient.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】この発明は、オーディオ信号
を効率的に符号化するオーディオ符号化装置及びオーデ
ィオ符号化方法に関し、特にオーディオ信号を直交変換
後、可変長符号化により圧縮符号化した後の符号量を、
所望の目標符号量に高速に収束制御するオーディオ符号
化装置及びオーディオ符号化方法に関するものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an audio encoding apparatus and an audio encoding method for efficiently encoding an audio signal, and more particularly to an audio encoding method after orthogonally transforming an audio signal and compressing and encoding the audio signal by variable length encoding. Code amount,
The present invention relates to an audio encoding device and an audio encoding method for controlling convergence to a desired target code amount at high speed.

【0002】[0002]

【従来の技術】オーディオ符号化方法には、オーディオ
信号を複数の時間ブロックに分割し、ブロック毎にオー
ディオデータを直交変換して変換係数を得て、これを適
切なスケーリング係数でスケーリング(正規化)し、ス
ケーリング後の変換係数を量子化し、この量子化値をハ
フマン符号等を用いた可変長符号化により符号化する方
法がある。
2. Description of the Related Art In an audio encoding method, an audio signal is divided into a plurality of time blocks, and audio data is orthogonally transformed for each block to obtain a transform coefficient, which is scaled by an appropriate scaling coefficient (normalization). There is a method of quantizing the scaled transform coefficient and encoding the quantized value by variable length encoding using Huffman code or the like.

【0003】このような符号化方法には、例えばISO
/IEC 13818−7として規格化されたMPEG
−2 Advanced Audio Coding
(AAC)符号化方式がある。この符号化における符号
量制御の方法は、変換係数を複数のブロックに分割した
周波数区分において、変換係数に対する全ての区分に共
通である第1スケーリング係数と区分毎に異なる第2ス
ケーリング係数を、聴覚特性を考慮した量子化雑音の分
布となるよう適応的に変化させ、そのときのハフマン符
号による可変長符号化後の符号量を別途定められた目標
符号量に近づけるものである。
[0003] Such encoding methods include, for example, ISO
/ MPEG standardized as IEC 13818-7
-2 Advanced Audio Coding
There is an (AAC) coding scheme. In the coding amount control method in this encoding, in a frequency section in which a transform coefficient is divided into a plurality of blocks, a second scaling coefficient different from the first scaling coefficient common to all sections for the transform coefficient and different from each other in the audio section is used. This is to adaptively change the distribution of the quantization noise in consideration of the characteristics, and to bring the code amount after the variable length coding by the Huffman code at that time closer to a target code amount that is separately determined.

【0004】なお、ここでいう符号量とは符号化に必要
なビット量のことであり、目標符号量とは、ブロック毎
に対して設定される値で、例えば、あらかじめ設定され
た符号化ビットレートから算出されるものであり、ブロ
ック毎に固定であっても可変であっても良い。
Here, the code amount is a bit amount required for encoding, and the target code amount is a value set for each block, for example, a predetermined encoded bit number. It is calculated from the rate, and may be fixed or variable for each block.

【0005】図8は複数の周波数帯域区分毎に変換係数
をスケーリング処理する様子を示す図である。入力され
たオーディオ信号は、直交変換によって変換され、周波
数別の変換係数が得られる。各変換係数は複数の周波数
帯域区分に分割され(ここではsb0からsb6までの
7つの区分を示している)、スケーリング係数を用いて
スケーリング処理が施される。ここで第1スケーリング
係数は、全周波数帯域区分に共通なスケーリング係数で
あり、第2スケーリング係数は周波数帯域区分毎に異な
るスケーリング係数である。
[0005] FIG. 8 is a diagram showing how the transform coefficient is scaled for each of a plurality of frequency band divisions. The input audio signal is transformed by orthogonal transform, and a transform coefficient for each frequency is obtained. Each transform coefficient is divided into a plurality of frequency band sections (here, seven sections from sb0 to sb6 are shown), and a scaling process is performed using the scaling coefficients. Here, the first scaling coefficient is a scaling coefficient common to all frequency band divisions, and the second scaling coefficient is a scaling coefficient different for each frequency band division.

【0006】図9はISO/IEC 13818−7に
規定された従来のオーディオ符号化装置の構成を示すブ
ロック図である。直交変換部1には入力端子101を経
てオーディオ信号が入力される。このオーディオ信号は
通常時系列のデータであり、特定のサンプリング周波数
でサンプリングされ、さらには特定の量子化ビットで量
子化されたデータである。直交変換部1は、変形離散コ
サイン変換(MDCT:Modified Discr
ete Cosine Transform)等の直交
変換により、時系列のデータを周波数系列のデータに変
換する。直交変換後のデータ列を変換係数と呼ぶ。変換
後の変換係数は、周波数軸成分、すなわちスペクトルデ
ータを表している。
FIG. 9 is a block diagram showing the configuration of a conventional audio encoding device specified in ISO / IEC 13818-7. An audio signal is input to the orthogonal transform unit 1 via an input terminal 101. This audio signal is usually time-series data, which is sampled at a specific sampling frequency and further quantized with a specific quantization bit. The orthogonal transform unit 1 performs a modified discrete cosine transform (MDCT: Modified Discr).
The time-series data is converted into frequency-series data by orthogonal transformation such as ET Cosine Transform. The data sequence after the orthogonal transform is called a transform coefficient. The converted conversion coefficient represents a frequency axis component, that is, spectrum data.

【0007】入力端子101からのオーディオ信号は、
また、聴覚特性分析部2にも入力される。聴覚特性分析
部2では人間の聴覚特性をモデル化した分析が行われ
る。聴覚特性の一つにマスキング効果という特性があ
り、これはある音によりその他の音が聞こえなくなると
いう現象のことである。この特性を利用して、符号化の
過程において発生する量子化雑音を人間の耳に知覚させ
ないよう、量子化雑音の発生量を適応的に制御するため
の指標を算出する。この指標はマスキングしきい値や許
容雑音量等と呼ばれる。
The audio signal from the input terminal 101 is
It is also input to the auditory characteristic analyzer 2. The auditory characteristic analyzer 2 performs an analysis modeling human auditory characteristics. One of the hearing characteristics is a characteristic called a masking effect, which is a phenomenon in which a certain sound makes other sounds inaudible. Using this characteristic, an index for adaptively controlling the amount of quantization noise generated is calculated so that the human ear does not perceive the quantization noise generated in the encoding process. This index is called a masking threshold, an allowable noise amount, or the like.

【0008】聴覚特性分析部2は、また、入力信号の特
性を調べ、その急峻性に応じて直交変換のブロックサイ
ズを決定する。これは、直交変換部1での入力信号の分
解能を、時間分解能を優先するか、周波数分解能を優先
するかを決定付けることになる。即ち、入力信号を解析
した結果、入力信号の時間的変化が緩やかな場合は、周
波数分解能を優先するため時間的に長いブロックサイズ
にし、逆に入力信号の時間的変化が急峻な場合は、時間
分解能を優先するため時間的に短いブロックサイズにす
る。
[0008] The auditory characteristic analyzer 2 also examines the characteristics of the input signal, and determines the block size of the orthogonal transform according to its steepness. This determines whether the resolution of the input signal in the orthogonal transform unit 1 is given priority over time resolution or frequency resolution. That is, as a result of analyzing the input signal, if the temporal change of the input signal is gradual, a longer block size is used to give priority to the frequency resolution, and if the temporal change of the input signal is sharp, In order to give priority to the resolution, a block size that is short in time is used.

【0009】直交変換部1から出力される変換係数は、
複数の周波数帯域区分に分割され、スケーリング部3で
正規化され、量子化部4において、この周波数帯域区分
毎に適応的な量子化が行われる。この周波数帯域区分と
しては、人間の聴覚特性を考慮した区分を用いることが
多い。すなわち高域ほど帯域幅の広い臨界帯域区分等で
ある。また、周波数帯域区分毎の量子化においては、量
子化効率を高めるために、周波数帯域区分毎に求めた係
数により、事前にスケーリング部3により正規化が行わ
れる。
The transform coefficient output from the orthogonal transform unit 1 is
It is divided into a plurality of frequency band sections, normalized by the scaling section 3, and adaptively quantized in the quantization section 4 for each of the frequency band sections. As the frequency band division, a division in which human auditory characteristics are considered is often used. In other words, a critical band division or the like having a wider bandwidth as the frequency becomes higher. Further, in the quantization for each frequency band section, normalization is performed in advance by the scaling unit 3 using a coefficient obtained for each frequency band section in order to increase the quantization efficiency.

【0010】周波数帯域区分毎に正規化された変換係数
は、量子化部4で量子化される。MPEG−2 AAC
方式においては、変換係数の正規化及び量子化に、次の
(1)式が用いられる。 xq=int((abs(coeff)*2^((1/4)*(scf−gs cf)))^3/4+α) (1) ここで、xqは量子化値、coeffは変換係数、gs
cfは正規化を行う際に全帯域共通に使用する第1スケ
ーリング係数、scfは正規化を行う際に周波数帯域区
分毎に使用する第2スケーリング係数、αは量子化のた
めの補正値であり、scf及びgscfは0または自然
数とする。なお、intは小数値を切り捨てて整数値化
する関数で、absは絶対値化する関数を示す。
[0010] The transform coefficients normalized for each frequency band section are quantized by the quantization unit 4. MPEG-2 AAC
In the method, the following equation (1) is used for normalization and quantization of transform coefficients. xq = int ((abs (coeff) * 2 ^ ((1/4) * (scf-gscf))) ^ 3/4 + α) (1) where xq is a quantization value, coeff is a transform coefficient, and gs
cf is a first scaling coefficient used for all bands when performing normalization, scf is a second scaling coefficient used for each frequency band division when performing normalization, and α is a correction value for quantization. , Scf and gscf are 0 or natural numbers. Note that int is a function that converts a decimal value to an integer value by truncation, and abs indicates a function that converts the value to an absolute value.

【0011】また、(1)式における第2スケーリング
係数scfの初期値scf_init及び第1スケーリ
ング係数gscfの初期値gscf_initは、次の
(2)式及び(3)式により決定される。 scf_init=0 (2) gscf_init=(16/3)*log2((max_coeff^(3 /4))/MAX_QUANT)) (3) ここで、max_coeffは全変換係数のうち最大値
をとる変換係数で、MAX_QUANTは量子化値の値
域の最大を示す定数である。また、量子化値の値域の条
件により、第1スケーリング係数gscfは、第1スケ
ーリング係数の初期値gscf_initよりも小さい
値となってはならない制限がある。
Further, the initial value scf_init of the second scaling coefficient scf and the initial value gscf_init of the first scaling coefficient gscf in the equation (1) are determined by the following equations (2) and (3). scf_init = 0 (2) gscf_init = (16/3) * log2 ((max_coeff ^ (3/4)) / MAX_QUANT) (3) where max_coeff is a conversion coefficient that takes a maximum value among all conversion coefficients. MAX_QUANT is a constant indicating the maximum value range of the quantization value. Further, there is a restriction that the first scaling coefficient gscf must not be smaller than the initial value gscf_init of the first scaling coefficient depending on the condition of the range of the quantization value.

【0012】量子化部4において求められた量子化値
は、可変長符号化部5において、帯域毎に最適なコード
ブックを用いて可変長符号化される。最適なコードブッ
クとは符号化後の符号量が最小となるようなコードブッ
クであり、コードブック別の正確な符号量を求めるため
には、選択可能なコードブック毎に実際に符号化を行い
符号量を求める必要がある。また、(1)式におけるス
ケーリング係数が更新されれば、新たに最適なコードブ
ックを選択し直し、そのときの符号量を再計算する必要
がある。なお、MPEG−2 AAC方式においては、
ハフマン符号を用いたハフマンコードブックが用いられ
ている。
The quantized value obtained by the quantizing section 4 is variable-length coded by a variable-length coding section 5 using an optimum codebook for each band. The optimal codebook is a codebook in which the code amount after encoding is minimized.In order to obtain an accurate code amount for each codebook, encoding is performed for each selectable codebook. It is necessary to determine the code amount. Further, if the scaling coefficient in the equation (1) is updated, it is necessary to select a new optimal codebook again and recalculate the code amount at that time. In the MPEG-2 AAC system,
A Huffman codebook using Huffman codes is used.

【0013】符号化制御部6は、スケーリング部3,量
子化部4,可変長符号化部5を統括して制御する。符号
化制御部6は、聴覚特性分析部2で求めた周波数帯域区
分毎の許容雑音量に基づいて、スケーリング部3の正規
化を行うための第2スケーリング係数scfを指定し、
また、可変長符号化部5で算出される符号量の大小によ
り、量子化部4の量子化のための第1スケーリング係数
gscfを指定する。
The coding control unit 6 controls the scaling unit 3, the quantization unit 4, and the variable-length coding unit 5 in an integrated manner. The encoding control unit 6 specifies a second scaling coefficient scf for normalizing the scaling unit 3 based on the permissible noise amount for each frequency band segment obtained by the auditory characteristic analysis unit 2,
Also, the first scaling coefficient gscf for quantization by the quantization unit 4 is specified based on the magnitude of the code amount calculated by the variable length coding unit 5.

【0014】この第1スケーリング係数gscfと第2
スケーリング係数scfの2つのスケーリング係数を適
応的に更新制御することにより、変換係数の量子化値を
可変長符号化した後の符号量が目標符号量の範囲内にあ
り、かつ変換係数を量子化する際に発生する量子化雑音
が聴覚的に最適な分布となるようなトレードオフの関係
を調整する。一般的に、第1スケーリング係数gscf
を小さくし、第2スケーリング係数scfを大きくする
ほど、量子化値は大きくなり、符号量は増加し、量子化
雑音は減少する。
The first scaling coefficient gscf and the second scaling coefficient
By adaptively updating and controlling the two scaling coefficients of the scaling coefficient scf, the code amount after variable-length coding of the quantization value of the conversion coefficient is within the range of the target code amount, and the conversion coefficient is quantized. The trade-off relationship is adjusted so that the quantization noise generated at the time of performing the distribution has an optimal distribution perceptually. In general, the first scaling factor gscf
And the second scaling coefficient scf increases, the quantization value increases, the code amount increases, and the quantization noise decreases.

【0015】図10は符号化制御部6の処理の手順を示
すフローチャートである。ステップST101におい
て、上記(3)式及び(2)式により、第1スケーリン
グ係数の初期値gscf_init、第2スケーリング
係数の初期値scf_initを設定し、ステップST
102,ステップST103において、設定された第1
スケーリング係数の初期値gscf_init、第2ス
ケーリング係数の初期値scf_initを用いて、
(1)式によりスケーリング及び量子化を行い、量子化
値を求める。
FIG. 10 is a flowchart showing the procedure of the process of the encoding control unit 6. In step ST101, an initial value gscf_init of the first scaling coefficient and an initial value scf_init of the second scaling coefficient are set by the above equations (3) and (2).
102, the first set in step ST103.
Using the initial value gscf_init of the scaling coefficient and the initial value scf_init of the second scaling coefficient,
Scaling and quantization are performed according to equation (1) to obtain a quantization value.

【0016】ステップST104において、求めた量子
化値に対して、帯域毎に最適なコードブックを用いて可
変長符号化を行い、ステップST105において、可変
長符号化した際の符号量を計算し、目標符号量との評価
判定を行う。符号量が目標符号量を上回っている場合は
否判定となり、符号量が目標符号量を下回っている場合
は合判定となる。否判定の場合に、ステップST106
において、符号量が目標符号量を下回るように第1スケ
ーリング係数を更新して、ステップST102に戻る。
In step ST104, the obtained quantized value is subjected to variable length coding using an optimal codebook for each band, and in step ST105, the code amount at the time of performing variable length coding is calculated. An evaluation judgment with the target code amount is performed. If the code amount is larger than the target code amount, the judgment is NO, and if the code amount is smaller than the target code amount, the judgment is GO. In the case of a negative determination, step ST106
In, the first scaling coefficient is updated so that the code amount is smaller than the target code amount, and the process returns to step ST102.

【0017】ステップST105で合判定となった場合
に、ステップST107において、量子化雑音の発生量
に関する評価判定を行い、量子化雑音の発生分布が聴覚
的に最適な分布条件を満たしていなければ否判定とな
り、最適な分布条件を満たしていれば合判定となる。否
判定となった場合に、ステップST108において、量
子化雑音の発生分布を変更するよう第2スケーリング係
数を更新して、ステップST102に戻り、合判定とな
った場合に一連の処理を終了する。
If the determination is affirmative in step ST105, an evaluation determination regarding the amount of quantization noise is performed in step ST107, and if the distribution of quantization noise does not satisfy the acoustically optimal distribution condition, The judgment is made, and if the optimum distribution condition is satisfied, the judgment is a match. If a negative determination is made, in step ST108, the second scaling coefficient is updated so as to change the generation distribution of the quantization noise, and the process returns to step ST102.

【0018】図11は量子化部4が行う上記初期値条件
での量子化の様子を示す図である。max_coeff
及びMAX_QUANTを基準に求められた第1スケー
リング係数の初期値gscf_initを用いると、m
ax_coeffの量子化値はMAX_QUANT相当
になる。このような条件のもとで、量子化値を可変長符
号化した場合、全体的に量子化値が大きな値をとるの
で、結果的に符号量は多くなり、目標符号量を越えてし
まう場合が多くなる。また、その符号量は個々の変換係
数の値に応じて、すなわち入力信号の特性に依存して大
きく変動する。
FIG. 11 is a diagram showing how the quantization unit 4 performs quantization under the above initial value conditions. max_coeff
And the initial value gscf_init of the first scaling coefficient obtained based on MAX_QUANT and
The quantization value of ax_coeff is equivalent to MAX_QUANT. Under such conditions, when the quantized value is subjected to variable-length encoding, the quantized value takes a large value as a whole, and as a result, the code amount increases and exceeds the target code amount. Increase. Also, the code amount greatly varies depending on the value of each transform coefficient, that is, depending on the characteristics of the input signal.

【0019】最後に、目標符号量の範囲内で発生する量
子化雑音が最も知覚されにくいように制御された第1ス
ケーリング係数gscf、第2スケーリング係数scf
の2つのスケーリング係数を用いて、スケーリング、量
子化、可変長符号化の一連の処理が行われ、処理後に得
られる符号は、スケーリング係数等の補助情報と共に決
められたフォーマットに従い多重部7で多重化される。
Finally, the first scaling coefficient gscf and the second scaling coefficient scf are controlled so that quantization noise generated within the range of the target code amount is hardly perceived.
A series of processes of scaling, quantization, and variable-length coding are performed using the two scaling coefficients described above, and the code obtained after the processing is multiplexed by the multiplexing unit 7 in accordance with a format determined together with auxiliary information such as a scaling coefficient. Be transformed into

【0020】以上のように、従来のオーディオ符号化装
置は、1ブロック毎にオーディオデータを直交変換し、
その変換係数を第1スケーリング係数gscf及び第2
スケーリング係数scfでスケーリングし、スケーリン
グ後の変換係数を量子化し、さらに可変長符号化した結
果の符号量が所望の目標符号量以下にならない場合に
は、上記2つのスケーリング係数を更新して再試行す
る、いわゆるフィードバック方式が採られている。この
ような単純なフィードバック方式では、最初の試行のス
ケーリング係数、すなわち第1スケーリング係数の初期
値gscf_initと第2スケーリング係数の初期値
scf_initに、どのような値を選択するかによ
り、目標符号量への収束時間、すなわちフィードバック
回数が左右されてしまう。
As described above, the conventional audio encoding apparatus orthogonally transforms audio data for each block,
The conversion coefficient is converted to a first scaling coefficient gscf and a second scaling coefficient gscf.
If the code amount obtained by scaling with the scaling coefficient scf, quantizing the transformed conversion coefficient, and further performing variable-length encoding does not become less than the desired target code amount, update the above two scaling coefficients and retry. That is, a so-called feedback method is adopted. In such a simple feedback method, the target code amount is determined by what values are selected for the scaling coefficient of the first trial, that is, the initial value gscf_init of the first scaling coefficient and the initial value scf_init of the second scaling coefficient. , Ie, the number of feedbacks is affected.

【0021】また、第1スケーリング係数gscfと第
2スケーリング係数scfの更新方法によっては、符号
量が目標符号量に対してオーバー/アンダーを繰り返し
てしまい、収束時間が増大しフィードバックの回数も増
大することとになる。
Also, depending on the method of updating the first scaling coefficient gscf and the second scaling coefficient scf, the code amount repeatedly over / unders the target code amount, so that the convergence time increases and the number of feedbacks increases. It will be.

【0022】[0022]

【発明が解決しようとする課題】従来のオーディオ符号
化装置は以上のように構成されているので、最適な第1
スケーリング係数の初期値gscf_initと第2ス
ケーリング係数の初期値scf_initが設定できな
いと、所望の符号量を満足するための最適な第1スケー
リング係数scfと第2スケーリング係数scfが得ら
れるまでの収束時間が長くなり、リアルタイムに符号化
ができないという課題があった。また、制御を高速に行
うためには、高機能の演算処理装置が必要であるという
課題があった。このような課題は、目標符号量が少ない
場合に、すなわち低ビットレート符号化の際に特に顕著
であった。
Since the conventional audio encoding apparatus is configured as described above, the optimum first audio encoding apparatus is used.
If the initial value gscf_init of the scaling coefficient and the initial value scf_init of the second scaling coefficient cannot be set, the convergence time until the optimal first scaling coefficient scf and second scaling coefficient scf for satisfying the desired code amount are obtained. However, there is a problem that encoding becomes impossible in real time. In addition, there is a problem that a high-performance arithmetic processing device is required to perform control at high speed. Such a problem is particularly remarkable when the target code amount is small, that is, at the time of low bit rate coding.

【0023】この発明は上記のよう課題を解決するため
になされたもので、フィードバックによる所望の符号量
を満足するための最適な第1スケーリング係数scfと
第2スケーリング係数scfを決定するまでの収束時間
を短くし、符号量制御が高速に収束するオーディオ符号
化装置及びオーディオ符号化方法を得ることを目的とす
る。
SUMMARY OF THE INVENTION The present invention has been made to solve the above-mentioned problem, and converges until the optimum first scaling coefficient scf and second scaling coefficient scf for satisfying a desired code amount by feedback are determined. An object of the present invention is to provide an audio encoding device and an audio encoding method in which time is shortened and code amount control converges at high speed.

【0024】[0024]

【課題を解決するための手段】この発明に係るオーディ
オ符号化装置は、入力されたオーディオ信号を分析し、
直交変換のブロックサイズを決定すると共に、量子化雑
音量を適応的に制御するための許容雑音量を算出する聴
覚特性分析部と、入力されたオーディオ信号を直交変換
し、上記聴覚特性分析部が決定したブロックサイズで、
周波数系列のデータ列である変換係数を出力する直交変
換部と、上記直交変換部から出力された変換係数を複数
のブロックに分割した周波数帯域区分に対し、正規化の
際に全周波数帯域共通に使用する第1スケーリング係数
の初期値と、周波数帯域区分毎に正規化を行うための第
2スケーリング係数の初期値を設定するスケーリング係
数初期値制御部と、上記直交変換部から出力された変換
係数を、上記第1スケーリング係数及び上記第2スケー
リング係数を使用して正規化を行うスケーリング部と、
上記スケーリング部により正規化された変換係数を周波
数帯域区分毎に量子化する量子化部と、上記量子化部に
より量子化された変換係数を周波数帯域区分毎に可変長
符号化する可変長符号化部と、上記量子化部による量子
化後の量子化雑音量を、上記聴覚特性分析部が算出した
許容雑音量に基づき評価すると共に、上記第2スケーリ
ング係数を、与えられた目標符号量を越えないように符
号量が増加する方向に更新することにより、上記第2ス
ケーリング係数の最適値を求め、上記第2スケーリング
係数が最適値の場合の符号量と、上記目標符号量の差が
所定の範囲内に入るように、上記第1スケーリング係数
を、符号量が増加する方向に更新することにより、上記
第1スケーリング係数の最適値を求めるスケーリング係
数更新制御部とを備えたものである。
An audio encoding apparatus according to the present invention analyzes an input audio signal,
A hearing characteristic analysis unit that determines the block size of the orthogonal transformation and calculates an allowable noise amount for adaptively controlling the quantization noise amount, and performs an orthogonal transformation on the input audio signal, and the hearing characteristic analysis unit With the determined block size,
An orthogonal transform unit that outputs a transform coefficient that is a data sequence of a frequency sequence, and a frequency band division obtained by dividing the transform coefficient output from the orthogonal transform unit into a plurality of blocks. An initial value of a first scaling coefficient to be used, a scaling coefficient initial value control section for setting an initial value of a second scaling coefficient for normalization for each frequency band section, and a conversion coefficient output from the orthogonal transform section A scaling unit that performs normalization using the first scaling coefficient and the second scaling coefficient,
A quantization unit that quantizes the transform coefficient normalized by the scaling unit for each frequency band division; and a variable length coding that performs variable length coding of the transform coefficient quantized by the quantization unit for each frequency band division. Unit and the quantization noise amount after quantization by the quantization unit is evaluated based on the permissible noise amount calculated by the auditory characteristic analysis unit, and the second scaling coefficient exceeds the given target code amount. By updating the code amount in a direction in which the code amount increases, the optimum value of the second scaling coefficient is obtained, and the difference between the code amount when the second scaling coefficient is the optimum value and the target code amount is a predetermined value. And updating the first scaling coefficient in a direction in which the code amount increases so as to fall within the range, thereby providing a scaling coefficient update control unit for obtaining an optimum value of the first scaling coefficient. Those were example.

【0025】この発明に係るオーディオ符号化装置は、
スケーリング係数更新制御部が、量子化部による量子化
後の量子化雑音量を算出し、算出した量子化雑音量を聴
覚特性分析部が算出した許容雑音量に基づき評価し、こ
の量子化雑音量の評価結果に基づき、第2スケーリング
係数を増加方向に暫定更新し、上記第2スケーリング係
数を暫定更新した際の符号量を目標符号量に基づき評価
し、目標符号量以下であれば、増加方向に暫定更新した
上記第2スケーリング係数の更新を許可し、目標符号量
以上であれば、増加方向に暫定更新した上記第2スケー
リング係数の更新を中止することにより、上記第2スケ
ーリング係数の最適値を求め、上記第2スケーリング係
数が最適値の場合の符号量と、目標符号量の差が所定の
範囲内に入るように、第1スケーリング係数を減少方向
に更新することにより、上記第1スケーリング係数の最
適値を求めるものである。
An audio encoding device according to the present invention comprises:
The scaling coefficient update control unit calculates the quantization noise amount after quantization by the quantization unit, evaluates the calculated quantization noise amount based on the permissible noise amount calculated by the auditory characteristic analysis unit, and calculates the quantization noise amount. Based on the evaluation result, the second scaling coefficient is provisionally updated in the increasing direction, and the code amount when the second scaling coefficient is provisionally updated is evaluated based on the target code amount. The update of the tentatively updated second scaling coefficient is permitted, and if the code amount is equal to or more than the target code amount, the update of the tentatively updated second scaling coefficient is stopped in the increasing direction to thereby optimize the second scaling coefficient. And updating the first scaling coefficient in a decreasing direction so that the difference between the code amount when the second scaling coefficient is the optimum value and the target code amount falls within a predetermined range. Ri is intended to obtain the optimum value of the first scaling factor.

【0026】この発明に係るオーディオ符号化装置は、
量子化雑音量を許容雑音量に基づき評価した際に、第2
スケーリング係数の更新が不要な場合に、そのときの符
号量と、目標符号量の差が所定の範囲内に入るように、
第1スケーリング係数を減少方向に更新することによ
り、上記第1スケーリング係数の最適値を求めるもので
ある。
An audio encoding device according to the present invention comprises:
When the quantization noise amount is evaluated based on the allowable noise amount, the second
When the update of the scaling coefficient is not necessary, the difference between the code amount at that time and the target code amount falls within a predetermined range.
The optimum value of the first scaling coefficient is obtained by updating the first scaling coefficient in the decreasing direction.

【0027】この発明に係るオーディオ符号化装置は、
スケーリング係数初期値制御部が、第2スケーリング係
数の初期値を「0」に設定し、第1スケーリング係数の
初期値を、最大値をとる変換係数に対する量子化値が1
以下となるように設定するものである。
An audio encoding device according to the present invention comprises:
The scaling coefficient initial value control unit sets the initial value of the second scaling coefficient to “0” and sets the initial value of the first scaling coefficient to 1 as the quantization value for the transform coefficient having the maximum value.
The setting is as follows.

【0028】この発明に係るオーディオ符号化装置は、
スケーリング係数初期値制御部が、第2スケーリング係
数の初期値を、各周波数帯域区分内の最大値をとる変換
係数に対する量子化値が1以下の範囲で、限りなく1に
近い値をとるように設定し、第1スケーリング係数の初
期値を、最大値をとる変換係数に対する量子化値が1以
下となるように設定するものである。
An audio encoding device according to the present invention comprises:
The scaling coefficient initial value control unit sets the initial value of the second scaling coefficient to a value as close as possible to 1 as long as the quantization value for the transform coefficient having the maximum value in each frequency band section is 1 or less. Then, the initial value of the first scaling coefficient is set so that the quantization value for the transform coefficient having the maximum value is 1 or less.

【0029】この発明に係るオーディオ符号化装置は、
スケーリング係数初期値制御部が、第2スケーリング係
数の初期値を「0」に設定するか、又は各周波数帯域区
分内の最大値をとる変換係数に対する量子化値が1以下
の範囲で、限りなく1に近い値をとるように設定し、第
1スケーリング係数の初期値を、最大値をとる変換係数
に対する量子化値が1以下となるようにすると共に、目
標符号量による補正を行った値に設定するものである。
An audio encoding device according to the present invention comprises:
The scaling coefficient initial value control unit sets the initial value of the second scaling coefficient to “0”, or in a range where the quantization value for the transform coefficient having the maximum value in each frequency band section is 1 or less, infinitely. A value close to 1 is set, and the initial value of the first scaling coefficient is set to a value obtained by correcting the quantization coefficient for the transform coefficient having the maximum value to 1 or less and correcting the target code amount. To set.

【0030】この発明に係るオーディオ符号化方法は、
入力されたオーディオ信号を分析し、直交変換のブロッ
クサイズを決定すると共に、量子化雑音量を適応的に制
御するための許容雑音量を算出する聴覚特性分析部と、
入力されたオーディオ信号を直交変換し、上記聴覚特性
分析部が決定したブロックサイズで、周波数系列のデー
タ列である変換係数を出力する直交変換部と、上記直交
変換部から出力された変換係数を、全周波数帯域共通の
第1スケーリング係数及び周波数帯域区分毎の第2スケ
ーリング係数を使用して正規化を行うスケーリング部
と、上記スケーリング部により正規化された変換係数を
周波数帯域区分毎に量子化する量子化部と、上記量子化
部により量子化された変換係数を周波数帯域区分毎に可
変長符号化する可変長符号化部とを備えて、オーディオ
信号を符号化するものにおいて、上記第1スケーリング
係数の初期値と上記第2スケーリング係数の初期値を設
定する第1のステップと、設定した上記第1スケーリン
グ係数と上記第2スケーリング係数により、正規化、量
子化、符号化を行う第2のステップと、上記第2のステ
ップで量子化した際の量子化雑音量を、上記聴覚特性分
析部が算出した許容雑音量に基づき評価し、上記第2ス
ケーリング係数の更新の必要性を確認する第3のステッ
プと、上記第3のステップで上記第2スケーリング係数
の更新の必要性がある場合に、上記第2スケーリング係
数を増加方向に暫定更新し、暫定更新した際の符号量を
目標符号量に基づき評価する第4のステップと、上記第
4のステップで暫定更新した際の符号量が目標符号量以
下であれば、増加方向に暫定更新した上記第2スケーリ
ング係数の更新を許可して、上記第2のステップに移行
する第5のステップと、上記第4のステップで暫定更新
した際の符号量が目標符号量以下であれば、増加方向に
暫定更新した上記第2スケーリング係数の更新を中止す
ることにより、上記第2スケーリング係数の最適値を求
める第6のステップと、上記第2スケーリング係数が最
適値の場合の符号量と、目標符号量の差が所定の範囲内
に入るように、第1スケーリング係数を減少方向に更新
することにより、上記第1スケーリング係数の最適値を
求める第7のステップとを備えたものである。
An audio encoding method according to the present invention comprises:
Analyzing the input audio signal, and determining the block size of the orthogonal transform, the auditory characteristics analysis unit that calculates the allowable noise amount for adaptively controlling the quantization noise amount,
An orthogonal transform unit that orthogonally transforms an input audio signal, outputs a transform coefficient that is a data sequence of a frequency sequence in a block size determined by the auditory characteristic analysis unit, and a transform coefficient output from the orthogonal transform unit. A scaling unit that performs normalization using a first scaling coefficient common to all frequency bands and a second scaling coefficient for each frequency band division, and quantizes the transform coefficient normalized by the scaling unit for each frequency band division And a variable-length encoding unit that performs variable-length encoding of the transform coefficient quantized by the quantization unit for each frequency band division, and encodes the audio signal. A first step of setting an initial value of a scaling coefficient and an initial value of the second scaling coefficient; and setting the first scaling coefficient and the second scaling coefficient. A second step of performing normalization, quantization, and encoding by using the coefficient, and a quantization noise amount at the time of quantization in the second step, based on an allowable noise amount calculated by the auditory characteristic analysis unit. A third step of evaluating and confirming the necessity of updating the second scaling factor; and increasing the second scaling factor when the third step requires updating of the second scaling factor. A fourth step of temporarily updating the code amount in the direction and evaluating the code amount at the time of the temporary update based on the target code amount; and increasing the code amount if the code amount at the time of the temporary update in the fourth step is equal to or less than the target code amount. A fifth step of allowing the update of the second scaling coefficient provisionally updated in the direction and proceeding to the second step, and a code amount when the provisional update is performed in the fourth step is equal to or less than the target code amount. Ah For example, the updating of the second scaling coefficient provisionally updated in the increasing direction is stopped to thereby obtain an optimum value of the second scaling coefficient, and a code amount when the second scaling coefficient is the optimum value. And a seventh step of obtaining the optimum value of the first scaling coefficient by updating the first scaling coefficient in a decreasing direction so that the difference between the target code amounts falls within a predetermined range. is there.

【0031】[0031]

【発明の実施の形態】以下、この発明の実施の一形態を
説明する。 実施の形態1.図1はこの発明の実施の形態1によるオ
ーディオ符号化装置の構成を示すブロック図である。図
において、符号化制御部60以外は、従来の図9に示す
オーディオ符号化装置と同一の構成であり、その動作の
説明は省略する。61は符号化制御部60内に設けたス
ケーリング係数初期値制御部で、62は符号化制御部6
0内に設けたスケーリング係数更新制御部である。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS One embodiment of the present invention will be described below. Embodiment 1 FIG. FIG. 1 is a block diagram showing a configuration of an audio encoding device according to Embodiment 1 of the present invention. In the figure, the configuration other than the encoding control unit 60 is the same as that of the conventional audio encoding device shown in FIG. 9, and the description of the operation is omitted. 61 is a scaling coefficient initial value control unit provided in the coding control unit 60, and 62 is a coding control unit 6
This is a scaling coefficient update control unit provided in 0.

【0032】次に動作について説明する。図2は符号化
制御部60の処理の流れを示すフローチャートである。
ステップST11において、スケーリング係数初期値制
御部61は、下記の(5)式及び(4)式により、第1
スケーリング係数の初期値gscf_init及び第2
スケーリング係数の初期値scf_initを設定す
る。 scf_init=0 (4) gscf_init=(16/3)*log2(max_coeff^(3/ 4)) (5) 上記(5)式は、第1スケーリング係数の初期値gsc
f_initを、全変換係数のうち最大値をとる変換係
数max_coeffに対する量子化値が1以下となる
ように設定するものである。
Next, the operation will be described. FIG. 2 is a flowchart showing the flow of the processing of the encoding control unit 60.
In step ST11, the scaling coefficient initial value control unit 61 uses the following equations (5) and (4) to set the first
Initial value gscf_init of scaling factor and second value
Set the initial value scf_init of the scaling factor. scf_init = 0 (4) gscf_init = (16/3) * log2 (max_coeff ^ (3/4)) (5) The above equation (5) is an initial value gsc of the first scaling coefficient.
f_init is set so that the quantization value for the transform coefficient max_coeff that takes the maximum value among all the transform coefficients is 1 or less.

【0033】図3は量子化部4が行う上記初期値条件で
の量子化の様子を示す図である。max_coeffに
対する量子化値が1以下となるように定義しているため
に、その他の変換係数も全て量子化値は1以下となる。
このような場合に、量子化値を可変長符号化すると、可
変長符号化に用いるコードブックの内容にも依存する
が、一般的に符号量は少ない。
FIG. 3 is a diagram showing how the quantization unit 4 performs quantization under the above initial value conditions. Since the quantization value for max_coeff is defined to be 1 or less, the quantization values of all other transform coefficients are also 1 or less.
In such a case, if the quantized value is variable-length coded, the code amount is generally small, though it depends on the contents of the codebook used for variable-length coding.

【0034】上記初期値条件の下、直交変換部1から出
力される変換係数に対し、ステップST12〜ST14
において、スケーリング、量子化、可変長符号化の一連
の処理が実施される。ステップST15において、符号
化制御部60のスケーリング係数更新制御部62は、一
連の処理において出力される量子化値、符号データを参
照して、周波数帯域区分毎の量子化雑音量の評価を行う
と共に、周波数帯域区分毎の符号量の評価を行いなが
ら、第2スケーリング係数の最適値を求める。
Under the above initial value conditions, the transform coefficients output from the orthogonal transform unit 1 are subjected to steps ST12 to ST14.
In, a series of processes of scaling, quantization, and variable-length coding are performed. In step ST15, the scaling coefficient update control unit 62 of the encoding control unit 60 evaluates the amount of quantization noise for each frequency band section with reference to the quantization value and the code data output in the series of processing. , The optimum value of the second scaling coefficient is determined while evaluating the code amount for each frequency band section.

【0035】図4はスケーリング係数更新制御部62に
よる上記ステップST15における詳細な処理の手順を
示すフローチャートである。スケーリング係数更新制御
部62は、ステップST21において、量子化部4によ
り行われた量子化結果から量子化雑音量を算出し、ステ
ップST22において、算出した量子化雑音量を評価し
て、第2スケーリング係数の更新が必要であるかを確認
する。
FIG. 4 is a flow chart showing a detailed processing procedure in step ST15 by the scaling coefficient update control section 62. In step ST21, the scaling coefficient update control unit 62 calculates the amount of quantization noise from the quantization result performed by the quantization unit 4, and in step ST22, evaluates the calculated amount of quantization noise to perform the second scaling. Check if the coefficient needs to be updated.

【0036】この量子化雑音量の評価とは、聴覚特性分
析部2で求めた許容雑音量と実際の量子化雑音量を算出
した結果の相対関係から、マスキング効果の度合いを判
定するものである。例えば、周波数帯域区分において、
許容雑音量と量子化雑音量の大小を比較し、量子化雑音
量の方が許容雑音量よりも小さければ、マスキング効果
が十分にあると判定して、第2スケーリング係数の更新
は不要とし、全ての周波数帯域区分において、第2スケ
ーリング係数の更新は不要と判定された場合には、図2
のステップST17の処理に移行する。
The evaluation of the quantization noise amount is to judge the degree of the masking effect from the relative relationship between the permissible noise amount obtained by the auditory characteristic analyzer 2 and the result of calculating the actual quantization noise amount. . For example, in the frequency band division,
Comparing the allowable noise amount and the magnitude of the quantization noise amount, if the quantization noise amount is smaller than the allowable noise amount, it is determined that the masking effect is sufficient, and the update of the second scaling coefficient is unnecessary, If it is determined that the update of the second scaling coefficient is unnecessary in all the frequency band sections, FIG.
The process proceeds to step ST17.

【0037】上記ステップST22で、第2スケーリン
グ係数の更新が必要と判断された場合には、ステップS
T23において、スケーリング係数更新制御部62は、
量子化雑音量を減少すべき周波数帯域区分を選出する。
ここで、選出する周波数帯域区分は1つでも同時に複数
でも良い。ステップST24において、スケーリング係
数更新制御部62は、選出された周波数帯域区分に対し
て、量子化雑音量が減少するように第2スケーリング係
数を暫定的に更新する。例えば、現在の第2スケーリン
グ係数scfの値に対して1加算するものであったり、
許容雑音量と量子化雑音量との相対関係を考慮して、重
み付けを行った値を加算しても良い。
If it is determined in step ST22 that the second scaling coefficient needs to be updated, the process proceeds to step S22.
At T23, the scaling coefficient update control unit 62
A frequency band section in which the amount of quantization noise should be reduced is selected.
Here, one or a plurality of frequency band divisions may be selected at the same time. In step ST24, the scaling coefficient update control unit 62 tentatively updates the second scaling coefficient for the selected frequency band section so that the quantization noise amount decreases. For example, one is added to the current value of the second scaling coefficient scf,
The weighted value may be added in consideration of the relative relationship between the allowable noise amount and the quantization noise amount.

【0038】ステップST25において、スケーリング
係数更新制御部62は、第2スケーリング係数scfを
暫定的に更新した場合の符号量を算出して符号量の評価
を行う。評価の結果、符号量が目標符号量を下回ってい
れば、ステップST26において、第2スケーリング係
数の更新を許可し、図2のステップST16において、
スケーリング係数更新制御部62は、第2スケーリング
係数scfを更新しステップST12に戻る。
In step ST25, the scaling coefficient update control section 62 calculates the code amount when the second scaling coefficient scf is provisionally updated, and evaluates the code amount. As a result of the evaluation, if the code amount is smaller than the target code amount, in step ST26, the update of the second scaling coefficient is permitted, and in step ST16 of FIG.
The scaling coefficient update control unit 62 updates the second scaling coefficient scf and returns to step ST12.

【0039】上記ステップST25で、符号量が目標符
号量を上回っていれば、ステップST27において、第
2スケーリング係数scfの更新を中止し、ステップS
T28において、選出した周波数帯域区分を、以降、第
2スケーリング係数scfの更新が必要とされる周波数
帯域区分の選出対象から除外する。
If the code amount exceeds the target code amount in step ST25, the update of the second scaling coefficient scf is stopped in step ST27, and the process proceeds to step ST27.
At T28, the selected frequency band division is excluded from the selection of the frequency band division for which the second scaling coefficient scf needs to be updated thereafter.

【0040】ステップST29において、全周波数帯域
区分の全帯域が選出対象から除外されたかを確認し、全
帯域が選出対象から除外されていない場合には、図2の
ステップST16以降の処理を行う。ステップST29
で、最終的に全ての周波数帯域区分が選出対象外となっ
た場合に、第2スケーリング係数scfは最適化された
ものとして、第2スケーリング係数scfの更新処理を
終了し、図2のステップST17の処理に移行する。な
お、ステップST25で符号量の評価を行い、符号量が
目標以上になった場合には、ステップST27で第2ス
ケーリング係数scfの更新を中止しているので、この
時点において、符号量は目標符号量を必ず下回ってい
る。
In step ST29, it is confirmed whether or not all the bands in all the frequency band divisions have been excluded from the selection targets. If not all the bands have been excluded from the selection targets, the processes after step ST16 in FIG. 2 are performed. Step ST29
Then, when all the frequency band divisions are finally excluded from the selection target, the second scaling coefficient scf is determined to be optimized, the update processing of the second scaling coefficient scf is completed, and the step ST17 in FIG. Move to the processing of. The code amount is evaluated in step ST25, and if the code amount exceeds the target, the update of the second scaling coefficient scf is stopped in step ST27. It is always below the amount.

【0041】なお、上記第2スケーリング係数scfの
更新処理においては、全周波数帯域区分に共通な第1ス
ケーリング係数gscfに関する更新は行わないため、
該当する周波数帯域区分のみに対して、量子化雑音量と
符号量の再計算を実施すれば良い。
In the updating process of the second scaling coefficient scf, the updating of the first scaling coefficient gscf common to all frequency band divisions is not performed.
The recalculation of the quantization noise amount and the code amount may be performed only for the corresponding frequency band section.

【0042】上記ステップST22で第2スケーリング
係数scfの更新は不要と判定されて第2スケーリング
係数scfの最適化が完了し、図2のステップST17
に移行した時点では、符号量が目標符号量に対して大き
く下回っている場合がある。例えば、入力信号が正弦波
信号のような場合には、その正弦波信号を含む周波数帯
域区分のみにおいて量子化雑音量を許容雑音量以下に減
少させるだけで済むことがあり、そのために必要な符号
量は入力信号が各種の周波数成分を含む場合に比べてか
なり少ない。このような場合に対しても、スケーリング
係数更新制御部62は、次のステップとして第1スケー
リング係数gscfに関する更新制御を行う。
In step ST22, it is determined that the update of the second scaling coefficient scf is unnecessary, and the optimization of the second scaling coefficient scf is completed. In step ST17 of FIG.
At the point in time, the code amount may be significantly lower than the target code amount. For example, if the input signal is a sine wave signal, it may be sufficient to reduce the quantization noise amount to less than the permissible noise amount only in the frequency band section containing the sine wave signal. The amount is much smaller than when the input signal contains various frequency components. Even in such a case, the scaling coefficient update control unit 62 performs update control on the first scaling coefficient gscf as the next step.

【0043】図2のステップST17において、スケー
リング係数更新制御部62は、第2スケーリング係数s
cfの更新処理終了時点での符号量と目標符号量を比較
し、その差が所定の範囲内にあるかを調べて、第1スケ
ーリング係数gscfが最適であるかを確認する。その
差が所定の範囲内になければ、ステップST18におい
て、符号化制御部60は第1スケーリング係数の更新を
行い、上記ステップST12以降の処理を繰り返す。こ
の更新は、例えば、現在の第1スケーリング係数gsc
fの値に対して1減算するものであったり、符号量と目
標符号量との差分に応じて重み付けされた値を減算して
も良い。
In step ST17 of FIG. 2, the scaling coefficient update control section 62 sets the second scaling coefficient s
The code amount at the end of the cf update process is compared with the target code amount, and it is checked whether the difference is within a predetermined range to confirm whether the first scaling coefficient gscf is optimal. If the difference is not within the predetermined range, in step ST18, the coding control unit 60 updates the first scaling coefficient, and repeats the processing in step ST12 and thereafter. This update is performed by, for example, the current first scaling factor gsc.
One may be subtracted from the value of f, or a value weighted according to the difference between the code amount and the target code amount may be subtracted.

【0044】上記ステップST17で、符号量と目標符
号量との差が所定の範囲内ににあれば、第1スケーリン
グ係数gscfが最適化されていると判断して処理を終
了する。なお、この所定の範囲は、例えば、第1スケー
リング係数gscfの更新に伴って変化する符号量の変
化量に基づいて設定される値であり、フレーム毎に異な
る値であっても良い。
In step ST17, if the difference between the code amount and the target code amount is within a predetermined range, it is determined that the first scaling coefficient gscf has been optimized, and the process ends. The predetermined range is a value set based on the amount of change in the code amount that changes with the update of the first scaling coefficient gscf, for example, and may be different for each frame.

【0045】また、場合によっては、以下に示すよう
に、符号量に変化が生じないように、第1スケーリング
係数gscfを更新しても良い。量子化の計算式である
(1)式において scf−gscf=一定 (6) の関係が保たれていれば、量子化値xqは不変であるこ
とは明らかである。すなわち、量子化雑音量や符号量も
変わらない。この理論に基づいて、第1スケーリング係
数gscfの更新においては、その更新量をβとすれ
ば、gscfをβ減少させるのと同時に、全ての周波数
帯域区分の第2スケーリング係数scfもβ減少させ
る。このときの更新量βとしては、量子化雑音量と符号
量を細かく制御することができる最小の更新量であるβ
=1が基本的だが、処理量削減のために一度に大きく変
化させることができるβ>1の値であっても良く、ま
た、フィードバックループ毎に適応的に変化させるもの
であっても良い。
In some cases, as described below, the first scaling coefficient gscf may be updated so that the code amount does not change. It is clear that the quantization value xq is invariable if the relationship of scf-gscf = constant (6) is maintained in the expression (1) which is a calculation expression of quantization. That is, the quantization noise amount and the code amount do not change. Based on this theory, in updating the first scaling coefficient gscf, if the update amount is β, the gscf is decreased by β, and at the same time, the second scaling coefficients scf of all the frequency band sections are also decreased by β. The update amount β at this time is the minimum update amount β that can finely control the quantization noise amount and the code amount.
= 1, but may be a value of β> 1 which can be changed greatly at a time to reduce the processing amount, or may be changed adaptively for each feedback loop.

【0046】符号化制御部60のフードバックループに
おいて、第2スケーリング係数scfと第1スケーリン
グ係数gscfの更新を繰り返して最適な値が得られ、
符号量が収束したならばフードバックループの処理を完
了しているが、このフィードバックループの過程におけ
る符号量については、必ず目標符号量よりも下回るよう
に制御が行われている。従って、第2スケーリング係数
scfと第1スケーリング係数gscfの更新処理にお
いて、常に符号量を増加させる方向での処理を行うだけ
で良く、符号量を減少させる方向での処理を必要としな
い。言い換えれば、量子化雑音量が改善される方向での
み、第2スケーリング係数scfと第1スケーリング係
数gscfを更新すれば良い。すなわち、符号量を減少
させる工程を省略することができると共に、フィードバ
ックループの収束判断においても、目標符号量に対して
符号量がオーバー/アンダーの両面から判断する必要が
なくなり判断が容易となる。
In the feedback loop of the coding control unit 60, the updating of the second scaling coefficient scf and the first scaling coefficient gscf is repeated to obtain an optimum value.
If the code amount has converged, the process of the feedback loop has been completed. However, the code amount in the process of this feedback loop is controlled so as to be always lower than the target code amount. Therefore, in the updating processing of the second scaling coefficient scf and the first scaling coefficient gscf, it is only necessary to always perform the processing in the direction of increasing the code amount, and does not need the processing in the direction of decreasing the code amount. In other words, the second scaling coefficient scf and the first scaling coefficient gscf may be updated only in a direction in which the amount of quantization noise is improved. That is, the step of reducing the code amount can be omitted, and the convergence of the feedback loop does not need to be determined from both the over and under of the target code amount, making the determination easy.

【0047】また、上記符号量評価の説明においては、
符号量の大部分を占める変換係数についてのみ詳細に説
明したが、もちろん符号量評価の際には、スケーリング
係数等の補助情報に必要な符号量の変動についても、考
慮していることを付け加えておく。
In the above description of the code amount evaluation,
Although only the conversion coefficient that accounts for the majority of the code amount has been described in detail, it is added that, of course, the code amount evaluation also considers the change in the code amount necessary for auxiliary information such as a scaling coefficient. deep.

【0048】以上のように、この実施の形態1によれ
ば、第1スケーリング係数の初期値gscf_init
を、最大値をとる変換係数に対する量子化値が1以下と
なるよう設定し、第2スケーリング係数の初期値scf
_initを0と設定し、第1スケーリング係数gsc
fと第2スケーリング係数scfの更新処理において、
常に符号量を増加させる方向での更新処理を行うことに
より、所望の符号量を満足するための最適な第1スケー
リング係数gscfと第2スケーリング係数scfの決
定までのフィードバックによる収束時間を短くでき、符
号量制御を高速に収束することができるという効果が得
られる。
As described above, according to the first embodiment, the initial value gscf_init of the first scaling coefficient is set.
Is set so that the quantization value for the transform coefficient having the maximum value is 1 or less, and the initial value scf of the second scaling coefficient is set.
_Init is set to 0, and the first scaling coefficient gsc
In the updating process of f and the second scaling coefficient scf,
By always performing the updating process in the direction of increasing the code amount, the convergence time by feedback until the determination of the optimal first scaling coefficient gscf and the second scaling coefficient scf to satisfy the desired code amount can be shortened. The effect that code amount control can be converged at high speed is obtained.

【0049】実施の形態2.この実施の形態によるオー
ディオ符号化装置の構成は、実施の形態1の図1に示す
構成と同じであり、符号化制御部60の処理の流れは、
実施の形態1の図2に示すフローチャートと基本的に同
等である。
Embodiment 2 The configuration of the audio encoding device according to this embodiment is the same as the configuration shown in FIG. 1 of the first embodiment, and the flow of processing of the encoding control unit 60 is as follows.
This is basically equivalent to the flowchart shown in FIG. 2 of the first embodiment.

【0050】次に動作について説明する。図2のステッ
プST11において、スケーリング係数初期値制御部6
1は、上記(5)式及び下記の(7)式により、第1ス
ケーリング係数の初期値gscf_init及び第2ス
ケーリング係数の初期値scf_initを設定する。
scf_init=(16/3)*log2((max
_coeff/sb_ max_coeff)^(3/4)) (7) 上記(7)式におけるsb_max_coeffは、周
波数帯域区分毎の最大値をとる変換係数である。その様
子を図5に示す。
Next, the operation will be described. In step ST11 of FIG. 2, the scaling coefficient initial value control unit 6
1 sets the initial value gscf_init of the first scaling coefficient and the initial value scf_init of the second scaling coefficient by the above equation (5) and the following equation (7).
scf_init = (16/3) * log2 ((max
_Coeff / sb_max_coeff) ^ (3/4)) (7) sb_max_coeff in the above equation (7) is a transform coefficient that takes the maximum value for each frequency band section. This is shown in FIG.

【0051】図6は上記初期値条件での量子化の様子を
示している。上記(7)式により第2スケーリング係数
の初期値scf_initを設定した結果、各周波数帯
域区分内の最大値をとる変換係数sb_max_coe
ffに対する量子化値は1以下の範囲内で、限りなく1
に近い値をとる。つまり、各周波数帯域区分毎の第2ス
ケーリング係数の初期値scf_initを考える場
合、全周波数帯域において最大値をとる変換係数max
_coeffと各周波数帯域区分におけるsb_max
_coeffの相対的な比の関係を考慮することによ
り、各周波数帯域区分における正規化を効率良く行うこ
とができる。言い換えれば、上記(1)式による量子化
において、実施の形態1と比較して、あらかじめ量子化
精度を向上させることに相当する。
FIG. 6 shows the state of quantization under the above initial value condition. As a result of setting the initial value scf_init of the second scaling coefficient by the above equation (7), the transform coefficient sb_max_coe having the maximum value in each frequency band section is set.
The quantization value for ff is within the range of 1 or less,
Take a value close to. That is, when considering the initial value scf_init of the second scaling coefficient for each frequency band section, the transform coefficient max that takes the maximum value in all frequency bands
_Coeff and sb_max in each frequency band division
By taking into account the relative ratio relationship of _coeff, normalization in each frequency band section can be performed efficiently. In other words, the quantization according to the above equation (1) corresponds to improving the quantization accuracy in advance as compared with the first embodiment.

【0052】上記初期値条件の下、スケーリング、量子
化、可変長符号化を行った場合、初期符号量を少量に抑
えつつ、かつ実施の形態1の(4)式と実施の形態2の
(7)式を比較すると、(7)式で計算した第2スケー
リング係数の初期値scf_initの方が大きくなる
ため、実施の形態1と比較して、第2スケーリング係数
scfの更新処理をあらかじめ実行することになり、そ
の分だけ全体のフィードバックループの処理量を抑える
ことができる。
When scaling, quantization, and variable length coding are performed under the above initial value conditions, the initial code amount is suppressed to a small amount, and the equation (4) of the first embodiment and the equation (4) of the second embodiment are used. When the equation (7) is compared, the initial value scf_init of the second scaling coefficient calculated by the equation (7) becomes larger. Therefore, the update processing of the second scaling coefficient scf is executed in advance as compared with the first embodiment. In other words, the processing amount of the entire feedback loop can be reduced accordingly.

【0053】図2のステップST12以降の処理及び図
4の処理については、実施の形態1と同じである。
The processing after step ST12 in FIG. 2 and the processing in FIG. 4 are the same as those in the first embodiment.

【0054】以上のように、この実施の形態2によれ
ば、第1スケーリング係数の初期値gscf_init
を、最大値をとる変換係数に対する量子化値が1以下と
なるよう設定し、第2スケーリング係数の初期値scf
_initを、各周波数帯域区分内の最大値をとる変換
係数に対する量子化値が1以下の範囲で、限りなく1に
近い値をとるように設定し、第1スケーリング係数gs
cfと第2スケーリング係数scfの更新処理におい
て、常に符号量を増加させる方向での更新処理を行うこ
とにより、所望の符号量を満足するための最適な第1ス
ケーリング係数gscfと第2スケーリング係数scf
の決定までのフィードバックによる収束時間を短くで
き、符号量制御を高速に収束することができるという効
果が得られる。
As described above, according to the second embodiment, the initial value gscf_init of the first scaling coefficient is set.
Is set so that the quantization value for the transform coefficient having the maximum value is 1 or less, and the initial value scf of the second scaling coefficient is set.
_Init is set such that the quantization value for the transform coefficient having the maximum value in each frequency band section takes a value as close as possible to 1 within a range of 1 or less, and the first scaling coefficient gs
In the updating process of the cf and the second scaling coefficient scf, the updating process in the direction of always increasing the code amount is performed, so that the optimal first scaling coefficient gscf and the second scaling coefficient scf to satisfy the desired code amount.
The convergence time due to the feedback up to the determination can be shortened, and the code amount control can be converged at high speed.

【0055】実施の形態3.この実施の形態によるオー
ディオ符号化装置の構成は、実施の形態1の図1に示す
構成と同じであり、符号化制御部60の処理の流れは、
実施の形態1の図2に示すフローチャートと基本的に同
等である。
Embodiment 3 The configuration of the audio encoding device according to this embodiment is the same as the configuration shown in FIG. 1 of the first embodiment, and the flow of processing of the encoding control unit 60 is as follows.
This is basically equivalent to the flowchart shown in FIG. 2 of the first embodiment.

【0056】次に動作について説明する。図2のステッ
プST11において、スケーリング係数初期値制御部6
1は、目標符号量の値に応じて、下記の(8)式により
第1スケーリング係数の初期値gscf_initを設
定する。 gscf_init=16/3*log2(max_coeff^(3/4) )−rate*γ (8) ここで、rateは目標符号量、γは定数である。な
お、第2スケーリング係数の初期値scf_init
は、実施の形態1の(4)式、又は実施の形態2の
(7)式により設定した値とする。
Next, the operation will be described. In step ST11 of FIG. 2, the scaling coefficient initial value control unit 6
1 sets the initial value gscf_init of the first scaling coefficient by the following equation (8) according to the value of the target code amount. gscf_init = 16/3 * log2 (max_coeff ^ (3/4))-rate * γ (8) where rate is a target code amount and γ is a constant. Note that the initial value scf_init of the second scaling coefficient
Is a value set by the equation (4) of the first embodiment or the equation (7) of the second embodiment.

【0057】上記(8)式は、実施の形態1の(5)式
に対して、rate*γの項により補正を行ったもの
で、第1スケーリング係数の初期値gscf_init
を、最大値をとる変換係数に対する量子化値が1以下と
なるようにすると共に、目標符号量による補正を行った
値に設定するものである。上記(8)式の第1スケーリ
ング係数の初期値gscf_initの値は、rate
*γの項により、実施の形態1の(5)式の場合と比較
して小さくなる。このような第1スケーリング係数の初
期値gscf_initを用いた場合の(1)式による
量子化について着目すると、第1スケーリング係数の初
期値gscf_initの値が小さい場合には、全周波
数帯域区分における量子化精度が向上すると共に量子化
雑音は減少する。また、量子化値が大きくなるため、多
くの符号量を必要とする。
The above equation (8) is obtained by correcting the equation (5) of the first embodiment with the term rate * γ, and the initial value gscf_init of the first scaling coefficient is obtained.
Is set so that the quantization value for the transform coefficient having the maximum value is 1 or less, and is corrected to a target code amount. The value of the initial value gscf_init of the first scaling coefficient in the above equation (8) is rate
Due to the term * γ, the value is smaller than that in the case of the expression (5) in the first embodiment. Focusing on the quantization by the expression (1) in the case where the initial value gscf_init of the first scaling coefficient is used, if the value of the initial value gscf_init of the first scaling coefficient is small, the quantization in the entire frequency band division is performed. As the accuracy increases, the quantization noise decreases. In addition, a large quantization value requires a large amount of code.

【0058】図7は実施の形態1の(5)式により第1
スケーリング係数の初期値gscf_initを設定し
た場合と、上記(8)式により第1スケーリング係数の
初期値gscf_initを設定した場合の符号量推移
の相違を示す図である。スケーリング係数更新制御部6
2の第1回目のループ処理後の符号量について、上記
(5)式により第1スケーリング係数の初期値gscf
_initを設定した場合をmとし、上記(8)式によ
り第1スケーリング係数の初期値gscf_initを
設定した場合をnとすると、このときのmとnの関係は
m<nとなる。
FIG. 7 shows the first equation according to the equation (5) of the first embodiment.
It is a figure which shows the difference of code amount transition when the initial value gscf_init of a scaling coefficient is set, and when the initial value gscf_init of a 1st scaling coefficient is set by the said (8) formula. Scaling coefficient update controller 6
2 for the code amount after the first loop processing, the initial value gscf of the first scaling coefficient by the above equation (5).
If the case where _init is set is m and the case where the initial value gscf_init of the first scaling coefficient is set by the above equation (8) is n, then the relationship between m and n is m <n.

【0059】この後、それぞれ符号量が目標符号量ra
teに収束するまでフィードバックループを繰り返す。
符号量が目標符号量rateに収束したときのフィード
バックループの反復回数について、上記(5)式により
第1スケーリング係数の初期値gscf_initを設
定した場合をMとし、上記(8)式により第1スケーリ
ング係数の初期値gscf_initを設定した場合を
Nとすると、このときのMとNの関係はM>Nとなる。
これは、すなわち、実施の形態1と比較して、符号化制
御部60で行うフィードバックループにおける処理を、
あらかじめ実行しておくことに相当する。
Thereafter, the code amount is set to the target code amount ra.
The feedback loop is repeated until te converges.
Regarding the number of repetitions of the feedback loop when the code amount converges to the target code amount rate, let M be the case where the initial value gscf_init of the first scaling coefficient is set by the above equation (5), and make the first scaling by the above equation (8). When the initial value gscf_init of the coefficient is set as N, the relationship between M and N at this time is M> N.
This means that the process in the feedback loop performed by the encoding control unit 60 is
This is equivalent to executing in advance.

【0060】上記初期値条件の下、スケーリング、量子
化、可変長符号化を行った場合、初期符号量を少量に抑
えつつ、かつ実施の形態1と比較して、第1スケーリン
グ係数の更新処理をあらかじめ実行することになり、そ
の分だけ全体のフィードバックループの処理量を抑える
ことができる。
When scaling, quantization, and variable length coding are performed under the above initial value condition, the first scaling coefficient is updated while the initial code amount is kept small and compared with the first embodiment. Is executed in advance, and the processing amount of the entire feedback loop can be suppressed by that amount.

【0061】図2のステップST12以降の処理及び図
4の処理については、実施の形態1と同じである。
The processing after step ST12 in FIG. 2 and the processing in FIG. 4 are the same as those in the first embodiment.

【0062】以上のように、この実施の形態3によれ
ば、第1スケーリング係数の初期値gscf_init
を、最大値をとる変換係数に対する量子化値が1以下と
なるようにすると共に、目標符号量による補正を行った
値に設定し、第2スケーリング係数の初期値scf_i
nitを、0に設定するか、又は各周波数帯域区分内の
最大値をとる変換係数に対する量子化値が1以下の範囲
で、限りなく1に近い値をとるように設定し、第1スケ
ーリング係数gscfと第2スケーリング係数scf_
initの更新処理において、常に符号量を増加させる
方向での更新処理を行うことにより、所望の符号量を満
足するための最適な第1スケーリング係数gscfと第
2スケーリング係数scfの決定までのフィードバック
による収束時間を短くでき、符号量制御を高速に収束す
ることができるという効果が得られる。
As described above, according to the third embodiment, the initial value gscf_init of the first scaling coefficient is set.
Is set so that the quantization value for the transform coefficient having the maximum value is 1 or less, and is set to a value corrected by the target code amount, and the initial value scf_i of the second scaling coefficient is set.
nit is set to 0, or the quantization value for the transform coefficient having the maximum value in each frequency band section is set to take a value as close as possible to 1 within a range of 1 or less, and the first scaling coefficient gscf and second scaling coefficient scf_
In the updating process of init, by always performing the updating process in the direction of increasing the code amount, the feedback by the feedback up to the determination of the optimal first scaling coefficient gscf and the second scaling coefficient scf for satisfying the desired code amount is performed. The effect is obtained that the convergence time can be shortened and the code amount control can be converged at high speed.

【0063】[0063]

【発明の効果】以上のように、この発明によれば、変換
係数を複数のブロックに分割した周波数帯域区分に対
し、正規化の際に全周波数帯域共通に使用する第1スケ
ーリング係数の初期値と、周波数帯域区分毎に正規化を
行うための第2スケーリング係数の初期値を設定するス
ケーリング係数初期値制御部と、量子化雑音量を許容雑
音量に基づき評価すると共に、第2スケーリング係数
を、与えられた目標符号量を越えないように符号量が増
加する方向に更新することにより、第2スケーリング係
数の最適値を求め、第2スケーリング係数が最適値の場
合の符号量と、目標符号量の差が所定の範囲内に入るよ
うに、第1スケーリング係数を、符号量が増加する方向
に更新することにより、第1スケーリング係数の最適値
を求めるスケーリング係数更新制御部とを備えたことに
より、所望の符号量を満足するための最適な第1スケー
リング係数と第2スケーリング係数の決定までのフィー
ドバックによる収束時間を短くでき、符号量制御を高速
に収束することができるという効果がある。
As described above, according to the present invention, the initial value of the first scaling coefficient used in common for all frequency bands at the time of normalization for the frequency band division obtained by dividing the transform coefficient into a plurality of blocks. And a scaling coefficient initial value control unit for setting an initial value of a second scaling coefficient for performing normalization for each frequency band section, and evaluating the quantization noise amount based on the allowable noise amount, and setting the second scaling coefficient , The code amount is updated so as not to exceed the given target code amount, so that the optimum value of the second scaling coefficient is obtained, and the code amount when the second scaling coefficient is the optimum value and the target code The first scaling coefficient is updated in a direction in which the code amount increases so that the difference in the amount falls within a predetermined range, thereby performing scaling for obtaining an optimum value of the first scaling coefficient. By providing the number update control unit, the convergence time due to feedback until the optimal first scaling coefficient and the second scaling coefficient for satisfying the desired code amount can be shortened, and the code amount control can be quickly converged. There is an effect that can be.

【0064】この発明によれば、スケーリング係数更新
制御部が、算出した量子化雑音量を許容雑音量に基づき
評価し、この量子化雑音量の評価結果に基づき、第2ス
ケーリング係数を増加方向に暫定更新し、第2スケーリ
ング係数を暫定更新した際の符号量を目標符号量に基づ
き評価し、目標符号量以下であれば、増加方向に暫定更
新した第2スケーリング係数の更新を許可し、目標符号
量以上であれば、増加方向に暫定更新した第2スケーリ
ング係数の更新を中止することにより、第2スケーリン
グ係数の最適値を求め、第2スケーリング係数が最適値
の場合の符号量と、目標符号量の差が所定の範囲内に入
るように、第1スケーリング係数を減少方向に更新する
ことにより、第1スケーリング係数の最適値を求めるこ
とにより、所望の符号量を満足するための最適な第1ス
ケーリング係数と第2スケーリング係数の決定までのフ
ィードバックによる収束時間を短くでき、符号量制御を
高速に収束することができるという効果がある。
According to the present invention, the scaling coefficient update control unit evaluates the calculated quantization noise amount based on the allowable noise amount, and based on the quantization noise amount evaluation result, increases the second scaling coefficient in the increasing direction. The code amount when the provisional update is performed and the second scaling coefficient is provisionally updated is evaluated based on the target code amount. If the code amount is equal to or less than the target code amount, the provisional update of the provisionally updated second scaling coefficient in the increasing direction is permitted. If the code amount is equal to or more than the code amount, the update of the second scaling coefficient provisionally updated in the increasing direction is stopped to obtain the optimum value of the second scaling coefficient. By updating the first scaling coefficient in a decreasing direction so that the difference in code amount falls within a predetermined range, a desired value of the first scaling coefficient is obtained, Convergence time by optimal first scaling factor to satisfy the issue amount and feedback to the determination of the second scaling factor to be shortened, there is an effect that it is possible to converge the code amount control at high speed.

【0065】この発明によれば、量子化雑音量を許容雑
音量に基づき評価した際に、第2スケーリング係数の更
新が不要な場合に、そのときの符号量と、目標符号量の
差が所定の範囲内に入るように、第1スケーリング係数
を減少方向に更新することにより、第1スケーリング係
数の最適値を求めることにより、所望の符号量を満足す
るための最適な第1スケーリング係数と第2スケーリン
グ係数の決定までのフィードバックによる収束時間を短
くでき、符号量制御を高速に収束することができるとい
う効果がある。
According to the present invention, when the quantization noise amount is evaluated based on the permissible noise amount, if it is not necessary to update the second scaling coefficient, the difference between the code amount at that time and the target code amount is determined. By updating the first scaling coefficient in the decreasing direction so as to fall within the range, the optimum value of the first scaling coefficient is obtained. 2 There is an effect that the convergence time due to feedback up to the determination of the scaling coefficient can be shortened, and the code amount control can be converged at high speed.

【0066】この発明によれば、スケーリング係数初期
値制御部が、第2スケーリング係数の初期値を「0」に
設定し、第1スケーリング係数の初期値を、最大値をと
る変換係数に対する量子化値が1以下となるように設定
することにより、所望の符号量を満足するための最適な
第1スケーリング係数と第2スケーリング係数の決定ま
でのフィードバックによる収束時間を短くでき、符号量
制御を高速に収束することができるという効果がある。
According to the present invention, the scaling coefficient initial value control unit sets the initial value of the second scaling coefficient to “0” and sets the initial value of the first scaling coefficient to the quantization coefficient for the transform coefficient having the maximum value. By setting the value to be 1 or less, it is possible to shorten the convergence time due to feedback until the optimal first scaling coefficient and second scaling coefficient for satisfying the desired code amount are determined, and the code amount control is performed at high speed. Has the effect of being able to converge.

【0067】この発明によれば、スケーリング係数初期
値制御部が、第2スケーリング係数の初期値を、各周波
数帯域区分内の最大値をとる変換係数に対する量子化値
が1以下の範囲で、限りなく1に近い値をとるように設
定し、第1スケーリング係数の初期値を、最大値をとる
変換係数に対する量子化値が1以下となるように設定す
ることにより、所望の符号量を満足するための最適な第
1スケーリング係数と第2スケーリング係数の決定まで
のフィードバックによる収束時間を短くでき、符号量制
御を高速に収束することができるという効果がある。
According to the present invention, the scaling coefficient initial value control unit sets the initial value of the second scaling coefficient to a maximum value within a range where the quantization value for the transform coefficient having the maximum value in each frequency band section is 1 or less. And a value close to 1 is set, and the initial value of the first scaling coefficient is set so that the quantization value for the transform coefficient having the maximum value is 1 or less, thereby satisfying a desired code amount. The convergence time due to feedback until the optimal first scaling coefficient and second scaling coefficient are determined can be shortened, and the code amount control can be converged at high speed.

【0068】この発明によれば、スケーリング係数初期
値制御部が、第2スケーリング係数の初期値を「0」に
設定するか、又は各周波数帯域区分内の最大値をとる変
換係数に対する量子化値が1以下の範囲で、限りなく1
に近い値をとるように設定し、第1スケーリング係数の
初期値を、最大値をとる変換係数に対する量子化値が1
以下となるようにすると共に、目標符号量による補正を
行った値に設定することにより、所望の符号量を満足す
るための最適な第1スケーリング係数と第2スケーリン
グ係数の決定までのフィードバックによる収束時間を短
くでき、符号量制御を高速に収束することができるとい
う効果がある。
According to the present invention, the scaling coefficient initial value control unit sets the initial value of the second scaling coefficient to “0” or sets the quantization value for the transform coefficient having the maximum value in each frequency band section. Is in the range of 1 or less,
, And the initial value of the first scaling coefficient is set to 1 as the quantization value for the transform coefficient having the maximum value.
By setting the value to a value corrected by the target code amount, convergence by feedback until the determination of the optimal first and second scaling coefficients for satisfying the desired code amount is performed. There is an effect that time can be shortened and code amount control can be converged at high speed.

【0069】この発明によれば、第1スケーリング係数
の初期値と第2スケーリング係数の初期値を設定する第
1のステップと、設定した第1スケーリング係数と第2
スケーリング係数により、正規化、量子化、符号化を行
う第2のステップと、第2のステップで量子化した際の
量子化雑音量を許容雑音量に基づき評価し、第2スケー
リング係数の更新の必要性を確認する第3のステップ
と、第3のステップで第2スケーリング係数の更新の必
要性がある場合に、第2スケーリング係数を増加方向に
暫定更新し、暫定更新した際の符号量を目標符号量に基
づき評価する第4のステップと、第4のステップで暫定
更新した際の符号量が目標符号量以下であれば、増加方
向に暫定更新した第2スケーリング係数の更新を許可し
て、第2のステップに移行する第5のステップと、第4
のステップで暫定更新した際の符号量が目標符号量以下
であれば、増加方向に暫定更新した第2スケーリング係
数の更新を中止することにより、第2スケーリング係数
の最適値を求める第6のステップと、第2スケーリング
係数が最適値の場合の符号量と、目標符号量の差が所定
の範囲内に入るように、第1スケーリング係数を減少方
向に更新することにより、第1スケーリング係数の最適
値を求める第7のステップとを備えたことにより、所望
の符号量を満足するための最適な第1スケーリング係数
と第2スケーリング係数の決定までのフィードバックに
よる収束時間を短くでき、符号量制御を高速に収束する
ことができるという効果がある。
According to the present invention, the first step of setting the initial value of the first scaling coefficient and the initial value of the second scaling coefficient,
A second step of performing normalization, quantization, and encoding using the scaling coefficient, and evaluating a quantization noise amount at the time of quantization in the second step based on the allowable noise amount, and updating the second scaling coefficient. A third step of confirming the necessity, and, if there is a need to update the second scaling coefficient in the third step, the second scaling coefficient is provisionally updated in the increasing direction, and the code amount at the time of the provisional update is reduced. A fourth step of evaluating based on the target code amount, and if the code amount at the time of the provisional update in the fourth step is equal to or smaller than the target code amount, updating of the second scaling coefficient provisionally updated in the increasing direction is permitted. A fifth step for shifting to the second step, and a fourth step for
If the code amount at the time of the provisional update in the step is less than or equal to the target code amount, the update of the provisionally updated second scaling coefficient in the increasing direction is stopped, thereby obtaining an optimum value of the second scaling coefficient. And updating the first scaling coefficient in the decreasing direction so that the difference between the code amount when the second scaling coefficient is the optimum value and the target code amount falls within a predetermined range, thereby achieving the optimum value of the first scaling coefficient. By providing the seventh step of obtaining the value, the convergence time due to feedback until the optimal first scaling coefficient and the second scaling coefficient for satisfying the desired code amount can be shortened, and the code amount control can be performed. There is an effect that convergence can be achieved at high speed.

【図面の簡単な説明】[Brief description of the drawings]

【図1】 この発明の実施の形態1によるオーディオ符
号化装置の構成を示すブロック図である。
FIG. 1 is a block diagram illustrating a configuration of an audio encoding device according to Embodiment 1 of the present invention.

【図2】 この発明の実施の形態1による符号化制御部
の処理の流れを示すフローチャートである。
FIG. 2 is a flowchart showing a processing flow of an encoding control unit according to the first embodiment of the present invention.

【図3】 この発明の実施の形態1による量子化部が行
う量子化の様子を示す図である。
FIG. 3 is a diagram showing a state of quantization performed by a quantization unit according to the first embodiment of the present invention.

【図4】 この発明の実施の形態1によるスケーリング
係数更新制御部の詳細な処理の手順を示すフローチャー
トである。
FIG. 4 is a flowchart illustrating a detailed processing procedure of a scaling coefficient update control unit according to the first embodiment of the present invention.

【図5】 この発明の実施の形態2による周波数帯域区
分毎の変換係数を示す図である。
FIG. 5 is a diagram showing transform coefficients for each frequency band section according to Embodiment 2 of the present invention.

【図6】 この発明の実施の形態2による量子化部が行
う量子化の様子を示す図である。
FIG. 6 is a diagram illustrating a state of quantization performed by a quantization unit according to a second embodiment of the present invention.

【図7】 この発明の実施の形態3における第1スケー
リング係数の初期値の相違による符号量推移の相違を示
す図である。
FIG. 7 is a diagram illustrating a difference in code amount transition due to a difference in an initial value of a first scaling coefficient according to the third embodiment of the present invention.

【図8】 複数の周波数帯域区分毎に変換係数をスケー
リング処理する様子を示す図である。
FIG. 8 is a diagram illustrating a state in which a transform coefficient is scaled for each of a plurality of frequency band divisions.

【図9】 従来のオーディオ符号化装置の構成を示すブ
ロック図である。
FIG. 9 is a block diagram illustrating a configuration of a conventional audio encoding device.

【図10】 従来の符号化制御部の処理の手順を示すフ
ローチャートである。
FIG. 10 is a flowchart showing a procedure of processing of a conventional encoding control unit.

【図11】 従来の量子化部が行う量子化の様子を示す
図である。
FIG. 11 is a diagram illustrating a state of quantization performed by a conventional quantization unit.

【符号の説明】[Explanation of symbols]

1 直交変換部、2 聴覚特性分析部、3 スケーリン
グ部、4 量子化部、5 可変長符号化部、7 多重
部、60 符号化制御部、61 スケーリング係数初期
値制御部、62 スケーリング係数更新制御部、101
入力端子、102 出力端子。
DESCRIPTION OF SYMBOLS 1 Orthogonal transformation part, 2 auditory-characteristic analysis part, 3 scaling part, 4 quantization part, 5 variable-length coding part, 7 multiplexing part, 60 coding control part, 61 scaling coefficient initial value control part, 62 scaling coefficient update control Part, 101
Input terminal, 102 output terminal.

Claims (7)

【特許請求の範囲】[Claims] 【請求項1】 入力されたオーディオ信号を分析し、直
交変換のブロックサイズを決定すると共に、量子化雑音
量を適応的に制御するための許容雑音量を算出する聴覚
特性分析部と、 入力されたオーディオ信号を直交変換し、上記聴覚特性
分析部が決定したブロックサイズで、周波数系列のデー
タ列である変換係数を出力する直交変換部と、 上記直交変換部から出力された変換係数を複数のブロッ
クに分割した周波数帯域区分に対し、正規化の際に全周
波数帯域共通に使用する第1スケーリング係数の初期値
と、周波数帯域区分毎に正規化を行うための第2スケー
リング係数の初期値を設定するスケーリング係数初期値
制御部と、 上記直交変換部から出力された変換係数を、上記第1ス
ケーリング係数及び上記第2スケーリング係数を使用し
て正規化を行うスケーリング部と、 上記スケーリング部により正規化された変換係数を周波
数帯域区分毎に量子化する量子化部と、 上記量子化部により量子化された変換係数を周波数帯域
区分毎に可変長符号化する可変長符号化部と、 上記量子化部による量子化後の量子化雑音量を、上記聴
覚特性分析部が算出した許容雑音量に基づき評価すると
共に、上記第2スケーリング係数を、与えられた目標符
号量を越えないように符号量が増加する方向に更新する
ことにより、上記第2スケーリング係数の最適値を求
め、上記第2スケーリング係数が最適値の場合の符号量
と、上記目標符号量の差が所定の範囲内に入るように、
上記第1スケーリング係数を、符号量が増加する方向に
更新することにより、上記第1スケーリング係数の最適
値を求めるスケーリング係数更新制御部とを備えたこと
を特徴とするオーディオ符号化装置。
1. An auditory characteristic analyzer for analyzing an input audio signal, determining an orthogonal transform block size, and calculating an allowable noise amount for adaptively controlling a quantization noise amount. Orthogonal transformation of the audio signal, and an orthogonal transformation unit that outputs a transformation coefficient, which is a data sequence of a frequency sequence, in a block size determined by the auditory characteristic analysis unit, and a plurality of transformation coefficients output from the orthogonal transformation unit. For the frequency band divisions divided into blocks, the initial value of the first scaling coefficient used in common for all frequency bands at the time of normalization and the initial value of the second scaling coefficient for performing normalization for each frequency band division A scaling coefficient initial value control unit to be set, and a conversion coefficient output from the orthogonal transformation unit, using the first scaling coefficient and the second scaling coefficient. A quantization unit that quantizes the transform coefficient normalized by the scaling unit for each frequency band division; and a quantization unit that quantizes the transform coefficient quantized by the quantization unit for each frequency band division. A variable-length encoding unit for performing variable-length encoding, and a quantization noise amount after quantization by the quantization unit is evaluated based on an allowable noise amount calculated by the auditory characteristic analysis unit, and the second scaling coefficient is calculated. By updating the code amount in a direction in which the code amount increases so as not to exceed the given target code amount, the optimum value of the second scaling coefficient is obtained, and the code amount when the second scaling coefficient is the optimum value, In order that the difference between the target code amounts falls within a predetermined range,
An audio encoding device, comprising: a scaling coefficient update control unit that obtains an optimum value of the first scaling coefficient by updating the first scaling coefficient in a direction in which a code amount increases.
【請求項2】 スケーリング係数更新制御部が、 量子化部による量子化後の量子化雑音量を算出し、算出
した量子化雑音量を聴覚特性分析部が算出した許容雑音
量に基づき評価し、この量子化雑音量の評価結果に基づ
き、第2スケーリング係数を増加方向に暫定更新し、上
記第2スケーリング係数を暫定更新した際の符号量を目
標符号量に基づき評価し、目標符号量以下であれば、増
加方向に暫定更新した上記第2スケーリング係数の更新
を許可し、目標符号量以上であれば、増加方向に暫定更
新した上記第2スケーリング係数の更新を中止すること
により、上記第2スケーリング係数の最適値を求め、 上記第2スケーリング係数が最適値の場合の符号量と、
目標符号量の差が所定の範囲内に入るように、第1スケ
ーリング係数を減少方向に更新することにより、上記第
1スケーリング係数の最適値を求めることを特徴とする
請求項1記載のオーディオ符号化装置。
2. A scaling coefficient update control unit calculates a quantization noise amount after quantization by the quantization unit, and evaluates the calculated quantization noise amount based on an allowable noise amount calculated by the auditory characteristic analysis unit. Based on the evaluation result of the quantization noise amount, the second scaling coefficient is provisionally updated in the increasing direction, and the code amount when the second scaling coefficient is provisionally updated is evaluated based on the target code amount. If there is, the update of the second scaling coefficient provisionally updated in the increasing direction is permitted, and if the code amount is equal to or larger than the target code amount, the update of the second scaling coefficient provisionally updated in the increasing direction is stopped, thereby updating the second scaling coefficient. Calculating the optimum value of the scaling coefficient, and the code amount when the second scaling coefficient is the optimum value;
2. The audio code according to claim 1, wherein an optimum value of the first scaling coefficient is obtained by updating the first scaling coefficient in a decreasing direction so that a difference between the target code amounts falls within a predetermined range. Device.
【請求項3】 量子化雑音量を許容雑音量に基づき評価
した際に、第2スケーリング係数の更新が不要な場合
に、そのときの符号量と、目標符号量の差が所定の範囲
内に入るように、第1スケーリング係数を減少方向に更
新することにより、上記第1スケーリング係数の最適値
を求めることを特徴とする請求項2記載のオーディオ符
号化装置。
3. When the quantization noise amount is evaluated based on the permissible noise amount and the update of the second scaling coefficient is not necessary, the difference between the code amount at that time and the target code amount falls within a predetermined range. 3. The audio encoding apparatus according to claim 2, wherein the optimum value of the first scaling coefficient is obtained by updating the first scaling coefficient in a decreasing direction so as to be included.
【請求項4】 スケーリング係数初期値制御部が、 第2スケーリング係数の初期値を「0」に設定し、第1
スケーリング係数の初期値を、最大値をとる変換係数に
対する量子化値が1以下となるように設定することを特
徴とする請求項1記載のオーディオ符号化装置。
4. A scaling coefficient initial value control section sets an initial value of a second scaling coefficient to “0”,
2. The audio encoding apparatus according to claim 1, wherein an initial value of the scaling coefficient is set such that a quantization value for a transform coefficient having a maximum value is 1 or less.
【請求項5】 スケーリング係数初期値制御部が、 第2スケーリング係数の初期値を、各周波数帯域区分内
の最大値をとる変換係数に対する量子化値が1以下の範
囲で、限りなく1に近い値をとるように設定し、第1ス
ケーリング係数の初期値を、最大値をとる変換係数に対
する量子化値が1以下となるように設定することを特徴
とする請求項1記載のオーディオ符号化装置。
5. A scaling coefficient initial value control unit sets an initial value of the second scaling coefficient to a value close to 1 in a range where a quantization value for a transform coefficient having a maximum value in each frequency band section is 1 or less. 2. The audio encoding apparatus according to claim 1, wherein the audio encoding apparatus is set to take a value, and the initial value of the first scaling coefficient is set so that a quantization value for a transform coefficient having a maximum value is 1 or less. .
【請求項6】 スケーリング係数初期値制御部が、 第2スケーリング係数の初期値を「0」に設定するか、
又は各周波数帯域区分内の最大値をとる変換係数に対す
る量子化値が1以下の範囲で、限りなく1に近い値をと
るように設定し、第1スケーリング係数の初期値を、最
大値をとる変換係数に対する量子化値が1以下となるよ
うにすると共に、目標符号量による補正を行った値に設
定することを特徴とする請求項1記載のオーディオ符号
化装置。
6. A scaling factor initial value control unit sets an initial value of a second scaling factor to “0”,
Alternatively, the quantization value for the transform coefficient having the maximum value in each frequency band section is set to be as close as possible to 1 within a range of 1 or less, and the initial value of the first scaling coefficient is set to the maximum value. 2. The audio encoding apparatus according to claim 1, wherein the quantization value for the transform coefficient is set to 1 or less, and the value is set to a value corrected by the target code amount.
【請求項7】 入力されたオーディオ信号を分析し、直
交変換のブロックサイズを決定すると共に、量子化雑音
量を適応的に制御するための許容雑音量を算出する聴覚
特性分析部と、 入力されたオーディオ信号を直交変換し、上記聴覚特性
分析部が決定したブロックサイズで、周波数系列のデー
タ列である変換係数を出力する直交変換部と、上記直交
変換部から出力された変換係数を、全周波数帯域共通の
第1スケーリング係数及び周波数帯域区分毎の第2スケ
ーリング係数を使用して正規化を行うスケーリング部
と、 上記スケーリング部により正規化された変換係数を周波
数帯域区分毎に量子化する量子化部と、 上記量子化部により量子化された変換係数を周波数帯域
区分毎に可変長符号化する可変長符号化部とを備えて、 オーディオ信号を符号化するオーディオ信号符号化方法
において、 上記第1スケーリング係数の初期値と上記第2スケーリ
ング係数の初期値を設定する第1のステップと、 設定した上記第1スケーリング係数と上記第2スケーリ
ング係数により、正規化、量子化、符号化を行う第2の
ステップと、 上記第2のステップで量子化した際の量子化雑音量を、
上記聴覚特性分析部が算出した許容雑音量に基づき評価
し、上記第2スケーリング係数の更新の必要性を確認す
る第3のステップと、 上記第3のステップで上記第2スケーリング係数の更新
の必要性がある場合に、上記第2スケーリング係数を増
加方向に暫定更新し、暫定更新した際の符号量を目標符
号量に基づき評価する第4のステップと、 上記第4のステップで暫定更新した際の符号量が目標符
号量以下であれば、増加方向に暫定更新した上記第2ス
ケーリング係数の更新を許可して、上記第2のステップ
に移行する第5のステップと、 上記第4のステップで暫定更新した際の符号量が目標符
号量以下であれば、増加方向に暫定更新した上記第2ス
ケーリング係数の更新を中止することにより、上記第2
スケーリング係数の最適値を求める第6のステップと、 上記第2スケーリング係数が最適値の場合の符号量と、
目標符号量の差が所定の範囲内に入るように、第1スケ
ーリング係数を減少方向に更新することにより、上記第
1スケーリング係数の最適値を求める第7のステップと
を備えたことを特徴とするオーディオ符号化方法。
7. An auditory characteristic analyzer for analyzing an input audio signal, determining an orthogonal transform block size, and calculating an allowable noise amount for adaptively controlling a quantization noise amount. An orthogonal transform unit that orthogonally transforms the converted audio signal and outputs a transform coefficient that is a data sequence of a frequency sequence in a block size determined by the auditory characteristic analysis unit; and a transform coefficient output from the orthogonal transform unit. A scaling unit that performs normalization using a first scaling coefficient common to frequency bands and a second scaling coefficient for each frequency band division; and a quantum that quantizes the transform coefficient normalized by the scaling unit for each frequency band division. An audio signal, comprising: a coding section; and a variable-length coding section that performs variable-length coding on the transform coefficient quantized by the quantization section for each frequency band section. A first step of setting an initial value of the first scaling factor and an initial value of the second scaling factor; and setting the first scaling factor and the second scaling factor. And the second step of performing normalization, quantization and encoding, and the quantization noise amount when quantizing in the second step
A third step of evaluating based on the permissible noise amount calculated by the auditory characteristic analyzer and confirming the necessity of updating the second scaling coefficient; and a necessity of updating the second scaling coefficient in the third step. A fourth step of tentatively updating the second scaling coefficient in an increasing direction and evaluating a code amount at the time of the tentative update based on a target code amount, and a tentative update in the fourth step. If the code amount is less than or equal to the target code amount, the fifth step of allowing the update of the second scaling coefficient provisionally updated in the increasing direction and proceeding to the second step, and the fourth step If the code amount at the time of the provisional update is equal to or less than the target code amount, the update of the second scaling coefficient provisionally updated in the increasing direction is stopped, and the second
A sixth step of obtaining an optimum value of the scaling coefficient; a code amount when the second scaling coefficient is an optimum value;
And updating the first scaling coefficient in a decreasing direction so that the difference between the target code amounts falls within a predetermined range, thereby obtaining an optimum value of the first scaling coefficient. Audio encoding method to use.
JP2000116412A 2000-04-18 2000-04-18 Device and method for audio encoding Pending JP2001306095A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2000116412A JP2001306095A (en) 2000-04-18 2000-04-18 Device and method for audio encoding

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2000116412A JP2001306095A (en) 2000-04-18 2000-04-18 Device and method for audio encoding

Publications (1)

Publication Number Publication Date
JP2001306095A true JP2001306095A (en) 2001-11-02

Family

ID=18627880

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2000116412A Pending JP2001306095A (en) 2000-04-18 2000-04-18 Device and method for audio encoding

Country Status (1)

Country Link
JP (1) JP2001306095A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2006001159A1 (en) * 2004-06-28 2006-01-05 Sony Corporation Signal encoding device and method, and signal decoding device and method
JP2007017659A (en) * 2005-07-07 2007-01-25 Fujitsu Ltd Audio encoding method and device
JP2007507750A (en) * 2003-09-29 2007-03-29 ソニー エレクトロニクス インク Rate-distortion control method in audio coding
WO2007126106A1 (en) * 2006-04-26 2007-11-08 Sony Corporation Encoding method and encoding device
JP2008065162A (en) * 2006-09-08 2008-03-21 Toshiba Corp Audio encoding device
JP2012519309A (en) * 2009-03-04 2012-08-23 コア ロジック,インコーポレイテッド Quantization for audio coding

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007507750A (en) * 2003-09-29 2007-03-29 ソニー エレクトロニクス インク Rate-distortion control method in audio coding
WO2006001159A1 (en) * 2004-06-28 2006-01-05 Sony Corporation Signal encoding device and method, and signal decoding device and method
JP2006011170A (en) * 2004-06-28 2006-01-12 Sony Corp Signal-coding device and method, and signal-decoding device and method
CN101010727B (en) * 2004-06-28 2011-07-06 索尼株式会社 Signal encoding device and method, and signal decoding device and method
JP4734859B2 (en) * 2004-06-28 2011-07-27 ソニー株式会社 Signal encoding apparatus and method, and signal decoding apparatus and method
US8015001B2 (en) 2004-06-28 2011-09-06 Sony Corporation Signal encoding apparatus and method thereof, and signal decoding apparatus and method thereof
JP2007017659A (en) * 2005-07-07 2007-01-25 Fujitsu Ltd Audio encoding method and device
WO2007126106A1 (en) * 2006-04-26 2007-11-08 Sony Corporation Encoding method and encoding device
JP2008065162A (en) * 2006-09-08 2008-03-21 Toshiba Corp Audio encoding device
JP2012519309A (en) * 2009-03-04 2012-08-23 コア ロジック,インコーポレイテッド Quantization for audio coding
US8600764B2 (en) 2009-03-04 2013-12-03 Core Logic Inc. Determining an initial common scale factor for audio encoding based upon spectral differences between frames

Similar Documents

Publication Publication Date Title
US7822601B2 (en) Adaptive vector Huffman coding and decoding based on a sum of values of audio data symbols
US7433824B2 (en) Entropy coding by adapting coding between level and run-length/level modes
KR100904605B1 (en) Audio coding apparatus, audio decoding apparatus, audio coding method and audio decoding method
US20090083042A1 (en) Encoding Method and Encoding Apparatus
US7974848B2 (en) Method and apparatus for encoding audio data
KR20210144939A (en) Encoder, Decoder, System and Methods for Encoding and Decoding
BRPI0506627B1 (en) method and device for quantizing an information signal
JP2001306095A (en) Device and method for audio encoding
US6678653B1 (en) Apparatus and method for coding audio data at high speed using precision information
JP5539992B2 (en) RATE CONTROL DEVICE, RATE CONTROL METHOD, AND RATE CONTROL PROGRAM
WO2006008817A1 (en) Audio encoding apparatus and audio encoding method
US20040230425A1 (en) Rate control for coding audio frames
JP2000347679A (en) Audio encoder, and audio coding method
JP2002311993A (en) Audio coding device
JP7005036B2 (en) Adaptive audio codec system, method and medium
JP5019437B2 (en) Audio bit rate conversion method and apparatus
JP4516345B2 (en) Speech coding information processing apparatus and speech coding information processing program
JP4273062B2 (en) Encoding method, encoding apparatus, decoding method, and decoding apparatus
JP2001148632A (en) Encoding device, encoding method and recording medium
JPH0944198A (en) Quasi-reversible encoding device for voice
JP2003271199A (en) Encoding method and encoding system for audio signal
JP2010175633A (en) Encoding device and method and program
KR100880995B1 (en) Audio encoding apparatus and audio encoding method
JP2001154695A (en) Audio encoding device and its method