JPH10200413A - Variable length code generator and generating method - Google Patents
Variable length code generator and generating methodInfo
- Publication number
- JPH10200413A JPH10200413A JP34832496A JP34832496A JPH10200413A JP H10200413 A JPH10200413 A JP H10200413A JP 34832496 A JP34832496 A JP 34832496A JP 34832496 A JP34832496 A JP 34832496A JP H10200413 A JPH10200413 A JP H10200413A
- Authority
- JP
- Japan
- Prior art keywords
- code
- run
- variable length
- level
- length code
- 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
Links
- 238000000034 method Methods 0.000 title claims description 26
- 230000015572 biosynthetic process Effects 0.000 claims description 4
- 238000003786 synthesis reaction Methods 0.000 claims description 4
- 238000006243 chemical reaction Methods 0.000 claims description 2
- 230000002194 synthesizing effect Effects 0.000 abstract description 6
- 230000009466 transformation Effects 0.000 abstract 1
- 230000008569 process Effects 0.000 description 7
- 238000012545 processing Methods 0.000 description 6
- 238000013139 quantization Methods 0.000 description 6
- 230000002457 bidirectional effect Effects 0.000 description 5
- 230000005540 biological transmission Effects 0.000 description 5
- 238000010586 diagram Methods 0.000 description 5
- 230000000694 effects Effects 0.000 description 5
- 238000007796 conventional method Methods 0.000 description 4
- 230000006870 function Effects 0.000 description 4
- 230000008901 benefit Effects 0.000 description 2
- 230000008859 change Effects 0.000 description 2
- 238000012937 correction Methods 0.000 description 2
- 230000006872 improvement Effects 0.000 description 2
- 238000012795 verification Methods 0.000 description 2
- 238000004891 communication Methods 0.000 description 1
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 230000007423 decrease Effects 0.000 description 1
- 238000002474 experimental method Methods 0.000 description 1
- 238000005457 optimization Methods 0.000 description 1
- 230000000644 propagated effect Effects 0.000 description 1
- 238000011084 recovery Methods 0.000 description 1
- 230000009467 reduction Effects 0.000 description 1
- 230000004044 response Effects 0.000 description 1
- 230000009291 secondary effect Effects 0.000 description 1
- 230000001360 synchronised effect Effects 0.000 description 1
- 238000012360 testing method Methods 0.000 description 1
Landscapes
- Compression Or Coding Systems Of Tv Signals (AREA)
- Compression Of Band Width Or Redundancy In Fax (AREA)
- Compression, Expansion, Code Conversion, And Decoders (AREA)
Abstract
Description
【0001】[0001]
【産業上の利用分野】本発明は画像符号化、特に、DC
T係数等からの可変長コードの生成に関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to image coding, and more particularly to DC coding.
The present invention relates to generation of a variable length code from a T coefficient or the like.
【0002】[0002]
【従来の技術及びその課題】画像符号化においては、D
CT(離散コサイン変換(Discrete Cosine Transform
))が広く用いられている。この手法は、人間の視覚
に敏感な成分(低周波成分)とそうでない成分(高周波
成分)とに分ける作用がある。DCTを施した後の成分
はDCT係数と呼ばれ、低周波成分の方から優先的に伝
送することにより少ない情報量で見た目に自然な画像が
伝送できる。DCT係数は、周波数を表すラン長(正確
には低周波側の直前の成分からの距離)と信号の強度を
表すレベルの組合せ、すなわち、(ラン長、レベル)で
表現される。通常、8×8画素の領域(これを、ブロッ
クという)でDCTが施されるためラン長は0から63
の値を、また、レベルは−127から+127の値をと
る。2. Description of the Related Art In image coding, D
CT (Discrete Cosine Transform
)) Is widely used. This method has an effect of dividing into components sensitive to human vision (low-frequency components) and components not sensitive to human vision (high-frequency components). The components after DCT are called DCT coefficients. By transmitting the low-frequency components preferentially, a visually natural image can be transmitted with a small amount of information. The DCT coefficient is represented by a combination of a run length representing the frequency (more precisely, a distance from the immediately preceding component on the low frequency side) and a level representing the signal strength, that is, (run length, level). Normally, since the DCT is applied to an area of 8 × 8 pixels (this is called a block), the run length is from 0 to 63.
And the level takes a value from -127 to +127.
【0003】そして、全体的な伝送符号量を削減するた
め、ラン長及びレベルについて、絶対値が小さい係数ほ
ど出現する確率が高くなるという性質を利用して可変長
符号化(エントロピー符号化ともいう)を行なう。ま
ず、各(ラン長、レベル)の出現確率に応じた長さの可
変長コードを決め、その対応関係を予めテーブルにして
おく。(これを、ハフマン・テーブルという)。通常、
出現確率の高い係数ほど短いコードを割り当てて全体的
な符号量を削減する。そして、符号化する際はDCT係
数の(ラン長、レベル)に対応する可変長コードをハフ
マン・テーブル(通常120個程度の要素から成る)か
ら読み出して出力する(これを、テーブル参照とい
う)。また、ハフマン・テーブルにはEOB(End Of B
lock)という特殊なコードがあり、ブロックのなかの最
後の係数の直後に挿入することによってブロック境界を
表している。画像符号化では、この一連の処理が画像内
の全ブロックに対して行なわれる。In order to reduce the overall transmission code amount, variable length coding (also referred to as entropy coding) is performed by using the property that the smaller the absolute value of a run length and the level, the higher the probability of occurrence of a coefficient. ). First, a variable length code having a length corresponding to the appearance probability of each (run length, level) is determined, and the correspondence is previously stored in a table. (This is called the Huffman table). Normal,
A shorter code is assigned to a coefficient having a higher appearance probability to reduce the overall code amount. At the time of encoding, a variable length code corresponding to the (run length, level) of the DCT coefficient is read from a Huffman table (usually composed of about 120 elements) and output (this is referred to as a table). The Huffman table has EOB (End Of B
There is a special code called lock), which indicates a block boundary by inserting it immediately after the last coefficient in the block. In image coding, this series of processing is performed on all blocks in an image.
【0004】しかし、規格化された画像符号化法を用い
るときは、それに規定されているハフマン・テーブルを
使用しなければならず、種々の状況に柔軟に対応できな
いことがある。例えば、EOBが4ビットのコードであ
るにも関わらず、ほとんどのブロックでDCT係数が伝
送されない場合はブロック当たり約4ビット消費するこ
とになる。このEOBを2ビットにすればブロック当た
り2ビット削減することができ、圧縮効果が上がる。し
かし、現行の規格では、せいぜい2種類のハフマン・テ
ーブルを選択できるようにしてあるのが最善の対処であ
り、より柔軟な対応は不可能である。However, when a standardized image coding method is used, a Huffman table specified in the method must be used, and it may not be possible to flexibly cope with various situations. For example, if the DCT coefficients are not transmitted in most blocks even though the EOB is a 4-bit code, about 4 bits are consumed per block. If the EOB is set to 2 bits, it is possible to reduce 2 bits per block, and the compression effect is improved. However, in the current standard, the best solution is to allow at most two types of Huffman tables to be selected, and more flexible handling is not possible.
【0005】又、ハフマン・テーブルを複数個用意する
と別の弊害が発生する。すなわち、符号器と復号器共に
ハフマン・テーブルをメモリー(記憶素子)に保持する
必要があり、それだけ多くのメモリー容量を要する。ま
た、復号器側では可変長コードの連鎖であるビット列を
元の(ラン長、レベル)の表現に戻すためにハフマン・
テーブルの中を検索する必要があり、テーブルの要素の
数に比例して復号に要する時間が増大することになる。
上述のように、DCT係数の可変長符号化においては種
々の課題がある。すなわち、既定のハフマン・テーブル
を使用すると画像の種類や符号化パラメータの変化に対
して柔軟に対応できない。また、これを解決するために
ハフマン・テーブルを複数用意すると要素の数に比例し
て装置の複雑さが増し、かつ動作速度も遅くなる。Another problem arises when a plurality of Huffman tables are prepared. That is, both the encoder and the decoder need to hold the Huffman table in the memory (storage element), which requires a large memory capacity. On the decoder side, a Huffman code is used to return the bit string, which is a chain of variable length codes, to the original (run length, level) representation.
It is necessary to search the table, and the time required for decoding increases in proportion to the number of elements in the table.
As described above, there are various problems in variable-length coding of DCT coefficients. In other words, if a predetermined Huffman table is used, it is not possible to flexibly cope with changes in the type of image and changes in encoding parameters. Further, if a plurality of Huffman tables are prepared to solve this problem, the complexity of the apparatus increases in proportion to the number of elements, and the operation speed also decreases.
【0006】本発明の目的は、ハフマン・テーブルの要
素数を削減しつつ、画像の種類や符号化パラメータの変
化に対して柔軟に対応する機能を提供することである。
このことにより、符号化・復号化装置の簡略化と復号化
処理の高速化が同時に達成できる。本発明の他の目的
は、狭帯域(64キロビット毎秒以下)の通信回線を用
いて画像伝送を行なう携帯端末に搭載する画像符号化装
置における可変長符号化及び復号化の部分を簡略化し、
かつ、高速化する機能を提供することである。An object of the present invention is to provide a function capable of flexibly responding to changes in image types and coding parameters while reducing the number of elements in a Huffman table.
Thus, simplification of the encoding / decoding device and speeding up of the decoding process can be achieved at the same time. Another object of the present invention is to simplify a variable length coding and decoding part in an image coding apparatus mounted on a portable terminal that performs image transmission using a communication band of a narrow band (64 kilobits per second or less),
And to provide a function for speeding up.
【0007】[0007]
【課題を達成するための手段及び作用】本発明は、入力
したDCT係数のラン長の値の属するラン・グループを
定め、その定めたグループを表すラン可変長コードを生
成し、かつ、前記ラン長の値を表すラン固定長コードを
生成して、前記ラン可変長コードと前記ラン固定長コー
ドを合成してラン・コードを生成するラン・コード生成
部と、入力したDCT係数のレベルの値の属するレベル
・グループを定め、その定めたグループを表すレベル可
変長コードを生成し、かつ、前記レベルの値を表すレベ
ル固定長コードを生成して、前記レベル可変長コードと
前記レベル固定長コードを合成してレベル・コードを生
成するレベル・コード生成部と、前記ラン・コード及び
前記レベル・コードに基いて可変長コードを生成する合
成部を含む可変長コード生成装置を提供する。According to the present invention, a run group to which a value of a run length of an input DCT coefficient belongs is determined, a run variable length code representing the determined group is generated, and the run A run code generation unit that generates a run fixed length code representing a length value, and synthesizes the run variable length code and the run fixed length code to generate a run code; and a level value of an input DCT coefficient , And a level variable length code representing the defined group is generated, and a level fixed length code representing the level value is generated, and the level variable length code and the level fixed length code are generated. Variable length including a level code generation unit that generates a level code by synthesizing the run code and a variable length code based on the run code and the level code Providing over de generator.
【0008】又、画素信号からDCT変換によりDCT
係数を生成し、その生成したDCT係数から可変長コー
ドを出力する可変長コード生成方法であって、ブロック
内の最後のDCT係数であることを意味するコード、又
は、ブロック内にDCT係数が継続して存在することを
意味するコードのいずれか一方のコードを、ブロック内
のDCT係数の数に従って付加して可変長コードとして
出力するステップを含む可変長コード生成方法を提供す
る。更に、可変長部分と固定長部分を組合わせて可変長
コードとして出力する可変長コード生成方法であって、
表現する数値が属するグループに対応する可変長部分を
構成するビットと、前記表現する数値に対応する固定長
部分を構成するビットとを一定の割合で交互に折り合わ
せて合成し、前記合成したビット群を可変長コードとし
て出力するステップを含む可変長コード生成方法を提供
する。[0008] Also, DCT is performed by DCT conversion from the pixel signal.
A variable-length code generation method for generating a coefficient and outputting a variable-length code from the generated DCT coefficient, wherein the code indicates that the code is the last DCT coefficient in the block, or the DCT coefficient continues in the block. A variable-length code generation method including the step of adding one of the codes indicating that the code exists and adding the code according to the number of DCT coefficients in the block, and outputting the variable-length code. Further, there is provided a variable length code generation method for combining a variable length portion and a fixed length portion and outputting the variable length code as a variable length code,
The bits forming the variable-length portion corresponding to the group to which the numerical value to be represented belongs and the bits forming the fixed-length portion corresponding to the numerical value to be expressed are alternately folded at a fixed ratio and synthesized, and the synthesized bits A variable length code generation method includes a step of outputting a group as a variable length code.
【0009】一実施例において、ハフマン・テーブルを
持たず、その代わりに10個程度の“コードの種”を規
定する。そして、符号化時に、“コードの種”の組合せ
により16,000種類にも及ぶコードを構成する。ま
た、従来手法では、16,000種類の中の120個の
コードをハフマン・テーブルで表し、その他は、エスケ
ープ・シーケンスを用いている。これは、出現確率の低
いDCT係数をエスケープ・コード(7ビットの可変長
コード)に続くラン長とレベルを表す固定長のコード
(ラン長は6ビット、レベルは8ビット)で表現するも
のである。この際、可変長符号化器では、エスケープ・
コードを使用するか否かを判定するための16,000
ビット相当の付加テーブルが必要になる。これに対し、
“コードの種”の組合せを用いることにより、ハフマン
・テーブルと同等なコード表を表現するためのメモリー
容量が1/50以下に縮小できる。In one embodiment, there is no Huffman table and instead about ten "code seeds" are defined. Then, at the time of encoding, as many as 16,000 types of codes are configured by combinations of “code types”. In the conventional method, 120 codes out of 16,000 kinds are represented by a Huffman table, and the other codes use an escape sequence. In this method, a DCT coefficient having a low appearance probability is represented by a fixed length code (run length is 6 bits and level is 8 bits) representing a run length and a level following an escape code (a 7-bit variable length code). is there. At this time, the variable length encoder uses
16,000 to determine whether to use the code
An additional table equivalent to bits is required. In contrast,
By using a combination of "code types", the memory capacity for expressing a code table equivalent to the Huffman table can be reduced to 1/50 or less.
【0010】また、ブロック境界を表すEOBを“コー
ドの種”の1つに割り当て、このコード長を可変にする
ことによりブロック内のDCT係数の個数の変化に柔軟
に対応できる。このEOBコードの特殊な場合として、
nEOB(ネガティブEOB)を当該ブロック内に符号
化・復号化されるべきDCT係数が存在することを意味
するコードとして定義する。これにより、ブロック当た
りの平均DCT係数が1に近いような状況(低ビットレ
ートで符号化する際などに発生)に対応できる。そし
て、ラン長とレベルを独立に符号化・復号化する。この
際、ラン長とレベルともに同様の符号構成を採用し、ま
た“コードの種”を共有することによって装置を簡略化
できる。これにより復号化側は従来1つのDCT係数に
つき最大120回の照合を要していたところを、ラン長
とレベルで最大合計20回の照合で実現でき、復号に要
する時間を1/6程度にまで削減が可能である。[0010] Further, by assigning an EOB representing a block boundary to one of "code types" and making the code length variable, it is possible to flexibly cope with a change in the number of DCT coefficients in a block. As a special case of this EOB code,
nEOB (negative EOB) is defined as a code indicating that DCT coefficients to be encoded / decoded exist in the block. This makes it possible to cope with a situation where the average DCT coefficient per block is close to 1 (occurs when encoding at a low bit rate, etc.). Then, the run length and the level are encoded and decoded independently. At this time, the apparatus can be simplified by adopting the same code configuration for both the run length and the level and sharing the "code type". As a result, the decoding side can perform a maximum of a total of 20 verifications using a run length and a level, which has conventionally required a maximum of 120 verifications for one DCT coefficient, and reduces the time required for decoding to about 1/6. It is possible to reduce up to.
【0011】副次的な作用として、16×16画素単位
のDCT(現行は、8×8画素単位)への拡張性があ
る。すなわち、16×16画素単位のDCTの場合はラ
ン長が最大255となるが、既定のハフマン・テーブル
では63以上のラン長には対応できない。本発明では、
“コードの種”を2つ加えるだけで対応が可能となる。
また、双方向から復号可能な可変長コードの生成方法も
提供する。伝送路上でビット列に誤りが生じた場合、誤
りが生じた部分を回避して次の既知のコード(これを同
期コードという)まで飛び越し、そこから逆方向(すな
わち過去に溯る方向)に復号を行なう。これにより従来
破棄せざるを得なかった復号不可能なビット列を回復で
き、誤りの影響を最小限に抑制できる。As a secondary effect, there is expandability to DCT of 16 × 16 pixels (currently, 8 × 8 pixels). In other words, in the case of DCT in units of 16 × 16 pixels, the maximum run length is 255, but the predetermined Huffman table cannot cope with a run length of 63 or more. In the present invention,
Only by adding two “code seeds” can the response be made.
Also, a method of generating a variable-length code that can be decoded in both directions is provided. If an error occurs in the bit string on the transmission line, the error is avoided and the process skips to the next known code (this is called a synchronization code), and performs decoding in the reverse direction (that is, the direction going back in the past). . This makes it possible to recover an undecodable bit string that had to be discarded in the past, and to minimize the effects of errors.
【0012】[0012]
【実施例】以下、本発明の実施例について図面を参照し
て詳細に説明する。図1は、本発明の可変長符号化を適
用した画像符号化装置の構成例を示すブロック図であ
る。同図において、DCT部1が8×8画素ブロックを
DCT(離散コサイン変換)処理し、量子化部2におい
て、DCT係数を人間の視覚に適合するように低周波成
分が精度良く量子化される。そして可変長符号化部3が
(ラン長、レベル)で表された各DCT係数を可変長コ
ード化する。可変長符号化部3と接続する符号化制御部
4は、画像単位で最適な符号化モードを決定する。符号
化制御部4からの出力として示されているnEOBフラ
ッグ及びEOBコード長は、符号量を最小にするモード
を示しており、通常画像単位で切替える。これに対し
て、量子化部2からの出力として示されているブロック
境界信号は符号量制御を目的にしたものではなく、ブロ
ック内のDCT係数の分布から一意に決定される。Embodiments of the present invention will be described below in detail with reference to the drawings. FIG. 1 is a block diagram illustrating a configuration example of an image encoding device to which the variable length encoding according to the present invention is applied. In FIG. 1, a DCT unit 1 performs a DCT (discrete cosine transform) process on an 8 × 8 pixel block, and a quantization unit 2 accurately quantizes low-frequency components so that the DCT coefficients match human vision. . Then, the variable length coding unit 3 converts each DCT coefficient represented by (run length, level) into a variable length code. An encoding control unit 4 connected to the variable length encoding unit 3 determines an optimal encoding mode for each image. The nEOB flag and the EOB code length shown as outputs from the encoding control unit 4 indicate a mode in which the code amount is minimized, and are switched in units of normal images. On the other hand, the block boundary signal shown as an output from the quantization unit 2 is not intended for code amount control, but is uniquely determined from the distribution of DCT coefficients in the block.
【0013】図2は図1の可変長符号化部を説明するた
めのブロック図である。この可変長符号化部では、ラン
長及びレベルを独立に符号化した後にラン長、レベルの
順にそれぞれのコードを合成し、最終的な可変長コード
を出力する。ラン長及びレベルともに2段階でコードを
生成する。まず、第1段階では、入力値の属するグルー
プを求め、そのグループを表す可変長コードを出力す
る。第2段階では、入力値そのものを表す固定長コード
を出力する。すなわち、ラン長を表すラン・コードはラ
ン可変長コードとラン固定長コードからなり、レベルを
表すレベル・コードはレベル可変長コードとレベル固定
長コードからなる。即ち、ラン・コード生成部10では
量子化部2から入力したラン長に基きコード表に従って
ラン可変長コードとラン固定長コードを生成し、それら
を合成したラン・コードを合成部13に送る。レベル・
コード生成部12は、量子化部2から入力したレベルに
基きコード表に従ってレベル可変長コードとレベル固定
長コードを生成し、それらを合成したレベル・コードを
合成部13に送る。なお、それぞれのコードを合成する
に当って、ラン長、レベルという順序で送ることは必ず
しも必要でない。この順序は逆もあり得るし、又、ラン
長を1ブロック分(最大64個)低周波側から順々に伝
送した後に、同じ数のレベルをラン長の順番に対応させ
て伝送することも可能である。また、このラン長とレベ
ルをブロック単位ではなく画像単位でまとめて伝送する
ことも可能である。FIG. 2 is a block diagram for explaining the variable length coding unit of FIG. The variable-length encoding unit independently encodes the run length and the level, synthesizes the respective codes in the order of the run length and the level, and outputs a final variable-length code. The code is generated in two steps for both the run length and the level. First, in the first stage, a group to which an input value belongs is obtained, and a variable length code representing the group is output. In the second stage, a fixed length code representing the input value itself is output. That is, the run code representing the run length is composed of a variable run length code and a fixed run length code, and the level code representing the level is composed of a variable level length code and a fixed level length code. That is, the run code generation unit 10 generates a run variable length code and a fixed run length code in accordance with the code table based on the run length input from the quantization unit 2, and sends the combined run code to the synthesis unit 13. level·
The code generation unit 12 generates a level variable length code and a fixed level length code in accordance with the code table based on the level input from the quantization unit 2, and sends a level code obtained by synthesizing them to the synthesis unit 13. In synthesizing the respective codes, it is not always necessary to transmit the codes in the order of the run length and the level. This order may be reversed. Alternatively, the run length may be transmitted one block (up to 64 blocks) sequentially from the low frequency side, and then the same number of levels may be transmitted in correspondence with the run length order. It is possible. It is also possible to transmit the run length and the level collectively in an image unit instead of a block unit.
【0014】なお、ラン長及びレベルを独立に符号化す
ることの利点は次の通りである。DCT係数を表すラン
長とレベルをエラー耐性(エラーが発生したときに復号
画像に致命的な影響を与えないようにする機能)の面か
ら考慮するとラン長の方が重要である。従って、ラン長
とレベルでエラー訂正の強度(エラーが発生したときに
それを検出し、また、訂正する能力の度合)を変えて伝
送する手法が有効である。この場合は、重要な情報であ
るラン長のエラー訂正の強度をより強くする(これは同
時に冗長なビットを増やして符号化効率を下げることに
なる)ことで効率的にエラー耐性を向上させることがで
きる。例えば、あるDCT係数(R、L)を想定し、ラ
ン長が1だけずれたもの(R+1、L)とレベルが1だ
けずれたもの(R、L+1)とを考える。エラーが発生
した2つの係数を逆DCT(DCT係数をブロック画像
に変換する処理)を施して比較すると、(R、L)に逆
DCTを施した元の画像に近いのは(R、L+1)の方
である。つまり、ラン長に強いエラー耐性をかければラ
ン長に誤りが発生し難くなり、仮にレベルにエラーが発
生してもラン長のエラーほど致命的な影響を与えない。The advantages of independently encoding the run length and the level are as follows. The run length is more important when the run length and level representing the DCT coefficient are considered from the viewpoint of error resistance (a function for preventing a fatal effect on a decoded image when an error occurs). Therefore, a method of changing the error correction strength (the degree of ability to detect and correct an error when it occurs) based on the run length and the level is effective. In this case, it is necessary to increase the error correction strength of the run length, which is important information (this also increases the number of redundant bits and lowers the coding efficiency), thereby efficiently improving the error resilience. Can be. For example, assuming a certain DCT coefficient (R, L), a case where the run length is shifted by 1 (R + 1, L) and a case where the level is shifted by 1 (R, L + 1) are considered. When two coefficients in which an error has occurred are subjected to inverse DCT (a process of converting DCT coefficients into a block image) and compared, (R, L + 1) is close to the original image in which (R, L) has been subjected to inverse DCT. It is. In other words, if a strong error resistance is applied to the run length, errors in the run length hardly occur, and even if an error occurs in the level, it does not have as fatal influence as an error in the run length.
【0015】又、本実施例では、ブロック境界を表すE
OBコードをレベル可変長コードの1つとして割り当て
る。このEOBコード長を変更することによってブロッ
ク内のDCT係数の個数の変化に対応する。EOBコー
ド長の決定は符号化制御部4(符号化側)で実施し、画
像内符号化か画像間符号化の区別、対象とする画像の種
類及び符号化レート(消費できる符号量)などを考慮し
て行なう。一般に、画像の内容が複雑なほど、また、符
号化レートを大きくするほどDCT係数の個数が増加す
るので、このような場合はEOBコード長を長くする。
ほとんどの場合、EOBコード長は画像内符号化で3も
しくは4ビット、画像間符号化で2ビットに設定すれば
適切に動作する。画像内符号化でのEOBコード長の切
替えは、ブロック内のDCT係数の平均個数が8個以内
であれば3ビット、8個以上であれば4ビットにすると
いう判定基準を用いれば確率論的な意味で適切である。
通常モード(EOBモードと呼び、nEOBフラッグが
OFFの状態をいう)においては、ブロック境界信号が
ONのときEOBコードをラン・コードとレベル・コー
ドの間に挿入する。なおこのブロック境界信号は、ブロ
ック内の最後のDCT係数であるときのみONになる。
即ち、量子化部2では、ブロック内のDCT係数を低周
波側から順に1個ずつ(8×8ブロックの場合は最大6
4個のDCT係数を1個ずつ)可変長符号化部3に出力
するが、あるブロックの処理を開始するときは常にブロ
ック境界信号をOFFにし、最後のDCT係数のときに
ONにする。In this embodiment, E represents a block boundary.
The OB code is assigned as one of the level variable length codes. Changing the EOB code length corresponds to a change in the number of DCT coefficients in the block. The determination of the EOB code length is performed by the encoding control unit 4 (encoding side), and the discrimination between intra-image encoding and inter-image encoding, the type of the target image and the encoding rate (consumable code amount), etc. Take this into consideration. In general, the number of DCT coefficients increases as the content of an image becomes more complicated and as the coding rate increases. In such a case, the EOB code length is increased.
In most cases, it works properly if the EOB code length is set to 3 or 4 bits for intra-picture coding and 2 bits for inter-picture coding. Switching of the EOB code length in intra-picture coding is probabilistic if a determination criterion is used in which the number of DCT coefficients in a block is 3 bits if the average number is less than 8, and 4 bits if the average number is 8 or more. Appropriate in some sense.
In the normal mode (called the EOB mode, in which the nEOB flag is OFF), the EOB code is inserted between the run code and the level code when the block boundary signal is ON. Note that this block boundary signal is turned ON only when it is the last DCT coefficient in the block.
That is, in the quantization unit 2, the DCT coefficients in the block are sequentially set one by one from the low frequency side (a maximum of 6
(4 DCT coefficients are output one by one) to the variable-length coding unit 3. When processing of a certain block is started, the block boundary signal is always turned off, and when the last DCT coefficient is turned on, the block boundary signal is turned on.
【0016】即ち図2において、EOBコード生成部1
1は符号化制御部4から入力したnEOBフラッグ、E
OBコード長に基きコード表に従ってEOBコードを生
成し、合成部13へ送る。EOBコードの生成について
は後述する。そして合成部13から最終的な可変長コー
ドが出力される。本実施例におけるラン長及びレベルの
コード決定、並びにEOBコードの生成について以下に
説明する。That is, in FIG. 2, the EOB code generator 1
1 is an nEOB flag input from the encoding control unit 4;
An EOB code is generated based on the OB code length according to the code table, and sent to the synthesizing unit 13. Generation of the EOB code will be described later. Then, the final variable length code is output from the synthesizing unit 13. The determination of the code of the run length and the level and the generation of the EOB code in this embodiment will be described below.
【0017】本実施例では、DCT係数の出現確率につ
いて次のようなモデルを仮定し、ラン長及びレベルのコ
ードを決定した。 (1) ラン長の確率モデル ラン長=0を表す可変長コードを0とする(出現確率1
/2に相当)。 以下、2のべき乗で表される範囲のラン長を1グループ
とし可変長コードに1を加える。 (2) レベルの確率モデル レベルの絶対値=1を表す可変長コードを0とする(出
現確率1/2に相当)。以下、2のべき乗で表される範
囲の絶対値レベルを1グループとし可変長コードに1を
加える。In this embodiment, the following model is assumed for the appearance probability of the DCT coefficient, and the codes of the run length and the level are determined. (1) Run length probability model A variable length code representing run length = 0 is set to 0 (probability of occurrence 1
/ 2). Hereinafter, the run length in the range represented by the power of 2 is set as one group, and 1 is added to the variable length code. (2) Level Probability Model The variable length code representing the absolute value of the level = 1 is set to 0 (corresponding to 1/2 the occurrence probability). Hereinafter, the absolute value level in the range represented by the power of 2 is set as one group, and 1 is added to the variable length code.
【0018】このモデルは、ハフマン・テーブルほど最
適化はなされていないが、出現頻度の高い(つまり、ラ
ン長、絶対値レベルともに小さい値を持つ)DCT係数
については、ほぼハフマン・テーブルに近い性能を示
す。表1、2に上記モデルに基いたラン長及びレベルの
コード表(“コードの種”の組合せ表)を示す。この表
は、ブロック内のDCT係数が比較的多い画像内符号化
に適合させるため、EOBコード長を3ビットに設定し
ている。例えば、DCT係数(3、−5)を可変長符号
化する場合を考える。表1よりランの値3を含むグルー
プ2のラン可変長コードは“110”、ラン固定長コー
ドは“1”(3を表す2進数“11”の最上位ビットを
除いたビット列)となり、ラン・コード“1101”を
得る。また、表2よりレベルの値−5を含むグループ2
のレベル可変長コードは“1110”、レベル固定長コ
ードは“101”(最上位ビットは負を表す)となり、
レベル・コード“1110101”を得る。そして、ラ
ン・コード、レベル・コードの順に合成すると、DCT
係数(3、−5)を表す可変長コード“1101111
0101”を得る。また、これがブロック内の最後(ブ
ロック境界)の係数であれば、ラン・コードとレベル・
コードの間にEOBコード“110”を入れて“110
11101110101”となる。Although this model is not optimized as much as the Huffman table, the performance of DCT coefficients with a high frequency of appearance (that is, both run length and absolute value level are small) is almost similar to that of the Huffman table. Is shown. Tables 1 and 2 show a code table of run lengths and levels (combination table of "code types") based on the above model. In this table, the EOB code length is set to 3 bits in order to adapt to intra-picture encoding in which DCT coefficients in a block are relatively large. For example, consider a case where DCT coefficients (3, -5) are variable-length coded. From Table 1, the run variable length code of group 2 including run value 3 is “110”, the run fixed length code is “1” (a bit string excluding the most significant bit of binary number “11” representing 3), and the run is -Code "1101" is obtained. Also, from Table 2, group 2 including level value -5
Is "1110", the fixed-level code is "101" (the most significant bit indicates negative), and
The level code “1110101” is obtained. When the run code and the level code are combined in this order, the DCT
Variable length code “1101111” representing coefficient (3, −5)
0101 ". If this is the last coefficient (block boundary) in the block, the run code and the level code
Insert the EOB code “110” between the codes and enter “110”
11101110101 ".
【0019】なお同じラングループ2に属する異なるラ
ン長(ランの値2)を有するDCT係数(2,−5)の
場合は、DCT係数(3,−5)とはラン固定長コード
のみが異なることになる。即ち、そのラン固定長コード
は“0”(2を表す2進数“10”の最上位ビットを除
いたビット列)となり、DCT係数(2,−5)を表す
可変長コードは“11001110101”となり、先
頭から4ビット目だけがDCT係数(3,−5)を表す
可変長コードと異なる。また、表3にブロック内のDC
T係数が比較的少ない画像間符号化に適合させるため、
EOBコード長を2ビットに設定した“コードの種”を
示す。このように画像単位でEOBコード長を変更する
ことによって最適化が可能であり、しかも、これは8個
の“コードの種”からなるレベル可変長コードを入れ換
えるだけで実現できる。従来のハフマン・テーブルを用
いる方法でEOBコード長を変化させると全ての可変長
コードを入れ換える必要があり、結局テーブルを複数持
たざるを得ない。In the case of DCT coefficients (2, -5) belonging to the same run group 2 and having different run lengths (run values 2), only the fixed run length code differs from the DCT coefficients (3, -5). Will be. That is, the run fixed-length code is “0” (a bit string excluding the most significant bit of the binary number “10” representing 2), the variable-length code representing the DCT coefficient (2, −5) is “11001110101”, Only the fourth bit from the beginning is different from the variable length code representing the DCT coefficient (3, -5). Table 3 shows the DC in the block.
In order to adapt to inter-picture coding with relatively few T coefficients,
This indicates a "code type" in which the EOB code length is set to 2 bits. As described above, optimization can be performed by changing the EOB code length for each image, and furthermore, this can be realized only by replacing the level variable length code including eight “code types”. If the EOB code length is changed by a conventional method using a Huffman table, it is necessary to replace all the variable length codes, and after all, a plurality of tables must be provided.
【0020】[0020]
【表1】 [Table 1]
【0021】[0021]
【表2】 [Table 2]
【0022】[0022]
【表3】 [Table 3]
【0023】次に、ブロック内のDCT係数の平均個数
が1に近い場合についての効果的な対策を考える。この
状況は、特に低符号化レートで画像間符号化したときに
発生しやすい。表4は4ブロックにおけるDCT係数の
分布例を示し、4個のブロック中3ブロックがDCT係
数1個で、残りの1ブロックがDCT係数2個ある場合
を示している。上述のように、EOBコード長を2ビッ
トに設定した場合、ブロック内のDCT係数が1個のと
きブロック境界を示すために2ビットを要する。EOB
コード長が2ビットというのは、ブロック内のDCT係
数の平均個数が4程度を仮定しており確率論的な意味で
不適切である。表5に対策を施さずに表4のDCT係数
を可変長符号化した結果を示す。Next, an effective measure for a case where the average number of DCT coefficients in a block is close to 1 will be considered. This situation tends to occur particularly when inter-coding is performed at a low coding rate. Table 4 shows a distribution example of DCT coefficients in four blocks, and shows a case where three of four blocks have one DCT coefficient and the remaining one has two DCT coefficients. As described above, when the EOB code length is set to 2 bits, two bits are required to indicate a block boundary when there is one DCT coefficient in the block. EOB
The code length of 2 bits is unsuitable in a probabilistic sense, assuming that the average number of DCT coefficients in a block is about 4. Table 5 shows the results of variable-length coding of the DCT coefficients of Table 4 without taking any measures.
【0024】[0024]
【表4】 [Table 4]
【表5】 [Table 5]
【0025】上述の対策として、EOBと反対の意味を
持つコードを定義してブロック境界を示すのに要するビ
ット数を軽減する。これをnEOB(ネガティブEO
B)と呼び、コードはEOBと同じものを使用する。E
OBモードとnEOBモードの画像単位での切替えは、
符号化制御部(符号化側)で行なう。nEOBモードで
は、ブロック内のDCT係数が1の場合nEOBコード
を送る必要がない。つまり、nEOBコードはDCT係
数が2個以上存在する場合のみ“継続”を表すコードと
して挿入される。表6にnEOBモードにより表4のD
CT係数を可変長符号化した結果を示す。表5と表6の
結果から、表4のようにブロック内のDCT係数の平均
個数が1に近い状況ではnEOBモードはEOBモード
と比較して符号量を20%程度削減できる。nEOBモ
ード(nEOBフラッグがON)においては、ブロック
境界信号がOFFのときラン・コードとレベル・コード
の間にEOBコードが挿入される。As a countermeasure described above, a code having a meaning opposite to that of EOB is defined to reduce the number of bits required to indicate a block boundary. This is called nEOB (negative EO).
Call it B) and use the same code as EOB. E
Switching between OB mode and nEOB mode in image units
This is performed by the encoding control unit (encoding side). In the nEOB mode, if the DCT coefficient in the block is 1, there is no need to send the nEOB code. That is, the nEOB code is inserted as a code representing “continuation” only when there are two or more DCT coefficients. Table 6 shows D in Table 4 according to the nEOB mode.
The result of variable length coding of the CT coefficient is shown. From the results of Tables 5 and 6, as shown in Table 4, when the average number of DCT coefficients in a block is close to 1, the code amount of the nEOB mode can be reduced by about 20% as compared with the EOB mode. In the nEOB mode (the nEOB flag is ON), when the block boundary signal is OFF, an EOB code is inserted between the run code and the level code.
【0026】[0026]
【表6】 [Table 6]
【0027】本発明と従来のハフマン・テーブルを用い
た場合の可変長符号化装置の複雑さ及び処理速度につい
て比較する。必要となるメモリー容量に関しては、本発
明ではハフマン・テーブルを用いた従来手法と比較し
て、符号化側では1/50以下、また、復号化側では1
/10程度まで縮小できる。処理速度に関しては、本発
明では従来手法と比較して、符号化側では同等、また、
復号化側では従来1つのDCT係数につき最大120回
の照合を要していたところを、本発明ではラン長とレベ
ルで合計15回の照合で実現でき、8倍程度の速度向上
が可能である。次に、本発明の第2の実施例について説
明する。この実施例では、16×16画素単位のDCT
(現行は、8×8画素単位)への拡張を実現している。
すなわち、16×16画素単位のDCTの場合はラン長
が最大255となるが、既定のハフマン・テーブルでは
63以上のラン長には対応できない。本発明では、“コ
ードの種”を2つ加えるだけで対応が可能となる。A comparison will be made between the complexity and processing speed of the variable-length coding device using the present invention and the conventional Huffman table. In the present invention, the required memory capacity is 1/50 or less on the encoding side and 1/50 on the decoding side, as compared with the conventional method using the Huffman table.
It can be reduced to about / 10. Regarding the processing speed, in the present invention, as compared with the conventional method, the encoding side is equivalent,
Whereas the decoding side conventionally required a maximum of 120 checks for one DCT coefficient, the present invention can realize a total of 15 checks for the run length and level, and can improve the speed by about 8 times. . Next, a second embodiment of the present invention will be described. In this embodiment, a DCT of 16 × 16 pixels is used.
(Currently, 8 × 8 pixel units).
In other words, in the case of DCT of 16 × 16 pixels, the run length is a maximum of 255, but the predetermined Huffman table cannot cope with a run length of 63 or more. According to the present invention, it is possible to cope with the situation simply by adding two “code types”.
【0028】表7に16×16DCT拡張版ラン・コー
ド表を示す。同様にしてより大きなブロック単位でのD
CTに対しても拡張可能である。Table 7 shows a 16 × 16 DCT extended version run code table. Similarly, D in a larger block unit
It can be extended to CT.
【表7】 [Table 7]
【0029】また、レベルについても“コードの種”を
追加するだけで拡張が可能となる。表8に絶対値255
までのレベルに拡張対応したレベルのコード表を示す。The level can be expanded simply by adding a "code type". Table 8 shows the absolute value of 255.
Here is a code table of the levels corresponding to the levels up to and including:
【表8】 [Table 8]
【0030】本実施例の性能評価のためコンピュータに
よる実験を行なった。比較の対象として、低ビットレー
トでの動画像伝送標準であるH.263を用いた。本実
施例では、画像内符号化ではEOBモードでEOBコー
ド長を3ビット、また、画像間符号化ではnEOB(ネ
ガティブEOB)モードでEOBコード長を2ビットに
設定した。テスト画像としては、標準画像であるマザー
&ドーターとフォアマンの2つを用いた。表9に各画像
においてDCT係数を符号化するのに要したビット数を
示す。An experiment using a computer was performed to evaluate the performance of this embodiment. For comparison, H.264, which is a video transmission standard at a low bit rate, is used. 263 was used. In this embodiment, the EOB code length is set to 3 bits in the EOB mode in intra-picture coding, and the EOB code length is set to 2 bits in the nEOB (negative EOB) mode in inter-picture coding. As test images, two standard images, Mother & Daughter and Foreman, were used. Table 9 shows the number of bits required to encode DCT coefficients in each image.
【表9】 [Table 9]
【0031】この結果から本実施例は、従来標準である
H.263と比較して、画像内符号化、画像間符号化と
もに1ないし3%の性能向上が確認できる。仮に性能が
同等であっても、符号化装置の簡略化と処理速度の向上
が達成できる本実施例の方が有利であると判断できる。
H.263のハフマン・テーブルは画像間符号化用に最
適化されたものであるが、本実施例は更にそれを上回っ
ている。これは、nEOBモードが効果的に働いている
ためである。From this result, the present embodiment is based on the conventional standard H.264. As compared with H.263, the performance improvement of 1 to 3% can be confirmed for both intra-picture coding and inter-picture coding. Even if the performances are equivalent, it can be determined that the present embodiment, which can achieve the simplification of the encoding device and the improvement of the processing speed, is more advantageous.
H. The Huffman table of H.263 has been optimized for inter-picture coding, but this embodiment further exceeds it. This is because the nEOB mode is working effectively.
【0032】次に、請求項4に記載の発明に関し、伝送
路上の雑音成分などによりビット列が影響を受け可変長
コードに誤りが生じた場合の復号処理を図3 に示す。同
図(a)は一方向(前方向)に復号可能な可変長コード
を用いた誤り回避のみによる復号処理である。ビット列
中に誤りが発生した場合、復号化側では別の可変長コー
ドとして復号されるか、もしくは、該当する可変長コー
ドが存在しないという理由で復号を中止することにな
る。前者の場合、仮にコード長が正しければ誤りは伝播
しないが、ほとんどの場合最終的には後者のケースに至
る。そして、後者の場合、次の同期コードを探して復号
を再開する。しかし、前方向にのみ復号可能な従来の可
変長コードでは同期コードから逆方向に復号することが
できないため、誤り発生箇所から同期コードまでのビッ
ト列は破棄せざるを得ず、この間のビット列が正常であ
っても誤りの影響を受けることになる。この例では、可
変長コードaからeまでが破棄されることになる。Next, FIG. 3 shows a decoding process in the case where a bit string is affected by a noise component on a transmission path and an error occurs in a variable length code according to the fourth aspect of the present invention. FIG. 11A shows a decoding process using only a variable length code that can be decoded in one direction (forward direction) and only error avoidance. When an error occurs in the bit string, the decoding side decodes the code as another variable length code, or stops decoding because there is no corresponding variable length code. In the former case, if the code length is correct, no error is propagated, but in most cases, the latter case will eventually be reached. In the latter case, decoding is resumed by searching for the next synchronization code. However, conventional variable-length codes that can only be decoded in the forward direction cannot be decoded in the reverse direction from the synchronization code, so the bit string from the error occurrence point to the synchronization code must be discarded. Even so, they are affected by errors. In this example, the variable length codes a to e are discarded.
【0033】誤りの影響を抑制する方法として、図3
(b)に示すように以前から双方向に復号可能な可変長
コードを使って同期コードから逆方向(すなわち過去に
溯る方向)にも復号を行う双方向復号方式が検討されて
いる。この例では、後方向復号(誤り回復)により可変
長コードbからeまでが復号可能であり、破棄されるの
は可変長コードaのみである。しかし、一般に双方向復
号方式では前方向用と後方向用のハフマン・テーブルを
別個に持つ必要があり、復号化装置がその分複雑にな
る。As a method for suppressing the influence of errors, FIG.
As shown in (b), a bidirectional decoding method in which a variable length code that can be bidirectionally decoded is used for decoding in the reverse direction (that is, the direction going back in the past) from a synchronous code has been studied. In this example, the variable length codes b to e can be decoded by backward decoding (error recovery), and only the variable length code a is discarded. However, in general, in the bidirectional decoding method, it is necessary to have separate Huffman tables for the forward direction and the backward direction, which complicates the decoding device.
【0034】そこで、“コードの種”とそれによって長
さが規定される固定長コードとの組合せにより伝送すべ
き可変長コードを構成するという上述の発明の特徴を活
かし、“コードの種”と固定長コードとを一定の割合で
交互に折り合わせることにより(例えば、“コードの
種”と固定長コードから1ビットずつ順に重ね合わせ
る)双方向に復号可能な可変長コードを作成する。表1
0に“コードの種”(可変長部分)と固定長コード(固
定長部分)を1ビットずつ交互に折り合わせた可変長コ
ードの一例を示す。例えば、可変長コード“0111
0”は可変長部分が“010”。固定長部分が“11”
に相当するので6を表していることになる。表10を用
いて双方向復号可能な可変長コードを作成した例(0、
2、10、5を符号化)を図4に示す。Therefore, taking advantage of the above-described feature of the present invention that a variable length code to be transmitted is constituted by a combination of a "code type" and a fixed length code whose length is defined by the "code type", By alternately folding the fixed-length code at a fixed rate (for example, “code type” and the fixed-length code are superimposed one bit at a time), a bidirectionally decodable variable-length code is created. Table 1
0 shows an example of a variable length code obtained by alternately folding a "code type" (variable length portion) and a fixed length code (fixed length portion) one bit at a time. For example, the variable length code "0111
“0” indicates that the variable length portion is “010”, and the fixed length portion is “11”.
Therefore, 6 is represented. Example of creating a variable length code capable of bidirectional decoding using Table 10 (0,
2, 10, 5) are shown in FIG.
【0035】[0035]
【表10】 [Table 10]
【0036】この際、全ての可変長コードにおいて可変
長部分のビット長:Mと固定長部分のビット長:Lとが
1次式の関係(すなわち、gM=hL+i、ここでg,
hは自然数,iは整数)にあること及び可変長部分が対
称(前方向、後方向のいずれから見ても等しい)になっ
ていることが双方向に復号可能な可変長コードを生成す
る条件となる。表10の場合はM=L+1の関係になっ
ている。この条件のもとに作成された可変長コードは、
前方向、後方向のいずれから見ても可変長部分と固定長
部分とがh対gの割合で重ね合わされた形になってい
る。上述の様に実施例に関し詳述したが、本発明はこれ
に限られるものではない。At this time, in all the variable length codes, the bit length of the variable length part: M and the bit length of the fixed length part: L have a linear relationship (ie, gM = hL + i, where g,
h is a natural number, i is an integer) and the variable length part is symmetric (equal in both forward and backward directions) Conditions for generating a bidirectionally decodable variable length code Becomes In the case of Table 10, the relationship is M = L + 1. The variable length code created under this condition is
The variable length portion and the fixed length portion are superposed at a ratio of h: g when viewed from both the front and rear directions. Although the embodiment has been described in detail as described above, the present invention is not limited to this.
【0037】[0037]
【発明の効果】本発明によれば、画像情報を符号化・復
号化する際に、画像の種類や符号化パラメータの変化に
対して柔軟に対応する機能が提供できるとともに、符号
化・復号化装置の簡略化と復号化処理の高速化が同時に
達成できる。また、符号量削減の効果は、現行標準と同
等の性能が得られる。According to the present invention, when encoding / decoding image information, it is possible to provide a function that can flexibly respond to changes in the type of image and changes in encoding parameters. Simultaneous simplification of the apparatus and speeding up of the decoding process can be achieved. In addition, the effect of code amount reduction is equivalent to that of the current standard.
【図1】本発明の可変長コード生成技術を適用した画像
符号化装置の構成例を示すブロック図。FIG. 1 is a block diagram showing a configuration example of an image coding apparatus to which a variable length code generation technique according to the present invention is applied.
【図2】可変長符号化部のブロック図。FIG. 2 is a block diagram of a variable length encoding unit.
【図3】双方向復号を用いた復号処理を説明する図。FIG. 3 is a view for explaining decoding processing using bidirectional decoding.
【図4】双方向復号可能な可変長コードを示す図。FIG. 4 is a diagram showing a variable length code capable of bidirectional decoding.
1 DCT部 2 量子化部 3 可変長符号化部 4 符号化制御部 10 ラン・コード生成部 11 EOBコード生成部 12 レベル・コード生成部 13 合成部 DESCRIPTION OF SYMBOLS 1 DCT part 2 Quantization part 3 Variable length encoding part 4 Encoding control part 10 Run code generation part 11 EOB code generation part 12 Level code generation part 13 Synthesis part
Claims (4)
るラン・グループを定め、その定めたグループを表すラ
ン可変長コードを生成し、かつ、前記ラン長の値を表す
ラン固定長コードを生成して、前記ラン可変長コードと
前記ラン固定長コードを合成してラン・コードを生成す
るラン・コード生成部と、 入力したDCT係数のレベルの値の属するレベル・グル
ープを定め、その定めたグループを表すレベル可変長コ
ードを生成し、かつ、前記レベルの値を表すレベル固定
長コードを生成して、前記レベル可変長コードと前記レ
ベル固定長コードを合成してレベル・コードを生成する
レベル・コード生成部と、 前記ラン・コード及び前記レベル・コードに基いて可変
長コードを生成する合成部を含む可変長コード生成装
置。1. A run group to which a value of a run length of an input DCT coefficient belongs is determined, a run variable length code representing the defined group is generated, and a run fixed length code representing the run length value is generated. A run code generation unit that generates the run variable length code and the run fixed length code to generate a run code; and determines a level group to which the level value of the input DCT coefficient belongs. Generating a level variable length code representing the group, and generating a level fixed length code representing the value of the level, and combining the level variable length code and the level fixed length code to generate a level code. A variable length code generation device, comprising: a level code generation unit; and a synthesis unit that generates a variable length code based on the run code and the level code.
を表すコードを生成するEOBコード生成部を含む請求
項1記載の可変長コード生成装置。2. The variable length code generation device according to claim 1, further comprising an EOB code generation unit that generates a code representing a block boundary to be included in the variable length code.
数を生成し、その生成したDCT係数から可変長コード
を出力する可変長コード生成方法であって、ブロック内
の最後のDCT係数であることを意味するコード、又
は、ブロック内にDCT係数が継続して存在することを
意味するコードのいずれか一方のコードを、ブロック内
のDCT係数の数に従って付加して可変長コードとして
出力するステップを含む可変長コード生成方法。3. A variable-length code generating method for generating a DCT coefficient from a pixel signal by DCT conversion and outputting a variable-length code from the generated DCT coefficient, which means that the variable-length code is the last DCT coefficient in a block. And adding a code indicating that DCT coefficients are continuously present in the block according to the number of DCT coefficients in the block and outputting the code as a variable length code. Long code generation method.
変長コードとして出力する可変長コード生成方法であっ
て、 表現する数値が属するグループに対応する可変長部分を
構成するビットと、前記表現する数値に対応する固定長
部分を構成するビットとを一定の割合で交互に折り合わ
せて合成し、 前記合成したビット群を可変長コードとして出力するス
テップを含む可変長コード生成方法。4. A variable length code generating method for combining a variable length portion and a fixed length portion and outputting the variable length code as a variable length code, comprising: a bit forming a variable length portion corresponding to a group to which a numerical value to be represented belongs; A variable length code generation method, comprising the steps of: alternately folding a fixed length portion corresponding to a numerical value to be represented and a bit constituting a fixed length portion at a fixed ratio to synthesize; and outputting the synthesized bit group as a variable length code.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP34832496A JPH10200413A (en) | 1996-12-26 | 1996-12-26 | Variable length code generator and generating method |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP34832496A JPH10200413A (en) | 1996-12-26 | 1996-12-26 | Variable length code generator and generating method |
Related Child Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2006000125A Division JP2006157944A (en) | 2006-01-04 | 2006-01-04 | Variable-length code formation method, encoding apparatus, and decoding apparatus |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH10200413A true JPH10200413A (en) | 1998-07-31 |
Family
ID=18396273
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP34832496A Pending JPH10200413A (en) | 1996-12-26 | 1996-12-26 | Variable length code generator and generating method |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH10200413A (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2016006961A (en) * | 2008-11-10 | 2016-01-14 | アップル インコーポレイテッド | System and method for compressing a stream of integer data |
-
1996
- 1996-12-26 JP JP34832496A patent/JPH10200413A/en active Pending
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2016006961A (en) * | 2008-11-10 | 2016-01-14 | アップル インコーポレイテッド | System and method for compressing a stream of integer data |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US11082695B2 (en) | Method and apparatus of binarization and context-adaptive coding for syntax in video coding | |
| JP3210996B2 (en) | High efficiency coding device and high efficiency decoding device | |
| US6711295B2 (en) | Encoding apparatus and method, and storage medium | |
| EP1267582B1 (en) | Moving picture coding System, and variable-length coding system | |
| US6265997B1 (en) | Arithmetic-encoding device and an arithmetic-decoding device | |
| US5550542A (en) | Variable length code look-up table having separate code length determination | |
| JPH0937271A (en) | Image compressing method | |
| JPH08317388A (en) | Image signal encoding device and decoding device | |
| US8116373B2 (en) | Context-sensitive encoding and decoding of a video data stream | |
| JP3087835B2 (en) | Image encoding method and apparatus and image decoding method and apparatus | |
| JPH05347710A (en) | Adaptive variable length coding method | |
| JP3278948B2 (en) | Variable length coding method | |
| JPH10200413A (en) | Variable length code generator and generating method | |
| JP2006157944A (en) | Variable-length code formation method, encoding apparatus, and decoding apparatus | |
| JPH10200595A (en) | Variable length coded data transmission device, transmission side device, reception side device and method therefor | |
| KR0148152B1 (en) | Adaptive variable length coding/decoding method and apparatus of image data | |
| US20030044079A1 (en) | Code converter, encoder, image output device and method thereof | |
| JP3609814B2 (en) | Variable length decoding method and apparatus | |
| JP3766426B2 (en) | Variable length coding method and apparatus | |
| JP3164806B2 (en) | Variable length encoding method and apparatus | |
| JP3609813B2 (en) | Variable length coding method and apparatus | |
| JP3822629B2 (en) | Variable length coding method and apparatus | |
| JP3612315B2 (en) | Variable length decoding method and apparatus | |
| JP3822630B2 (en) | Variable length decoding method and apparatus | |
| JP2768351B2 (en) | How to scan DCT coefficients |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20050701 |
|
| A601 | Written request for extension of time |
Free format text: JAPANESE INTERMEDIATE CODE: A601 Effective date: 20051003 |
|
| A602 | Written permission of extension of time |
Free format text: JAPANESE INTERMEDIATE CODE: A602 Effective date: 20051006 |
|
| A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20060104 |
|
| A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20060120 |
|
| A601 | Written request for extension of time |
Free format text: JAPANESE INTERMEDIATE CODE: A601 Effective date: 20060420 |
|
| A602 | Written permission of extension of time |
Free format text: JAPANESE INTERMEDIATE CODE: A602 Effective date: 20060427 |
|
| A02 | Decision of refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A02 Effective date: 20060922 |