JP3234544B2 - Image encoding apparatus and image encoding method - Google Patents

Image encoding apparatus and image encoding method

Info

Publication number
JP3234544B2
JP3234544B2 JP23308297A JP23308297A JP3234544B2 JP 3234544 B2 JP3234544 B2 JP 3234544B2 JP 23308297 A JP23308297 A JP 23308297A JP 23308297 A JP23308297 A JP 23308297A JP 3234544 B2 JP3234544 B2 JP 3234544B2
Authority
JP
Japan
Prior art keywords
image
detection range
value
code
pixels
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.)
Expired - Fee Related
Application number
JP23308297A
Other languages
Japanese (ja)
Other versions
JPH1175199A (en
Inventor
悦子 杉本
天 浦野
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sanyo Electric Co Ltd
Original Assignee
Sanyo Electric Co Ltd
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 Sanyo Electric Co Ltd filed Critical Sanyo Electric Co Ltd
Priority to JP23308297A priority Critical patent/JP3234544B2/en
Publication of JPH1175199A publication Critical patent/JPH1175199A/en
Application granted granted Critical
Publication of JP3234544B2 publication Critical patent/JP3234544B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Description

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

【0001】[0001]

【発明の属する技術分野】本発明は画像符号化装置及び
画像符号化方法、特にMPEG2において動きベクトル
を符号化する際に用いられるパラメータであるfコード
値の設定に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an image encoding apparatus and an image encoding method, and more particularly to setting of an f-code value which is a parameter used when encoding a motion vector in MPEG2.

【0002】[0002]

【従来の技術】従来より、動画像信号を伝送するシステ
ムにおいて、伝送路を効率よく利用するため画像信号を
圧縮符号化する技術が開発されており、特に画像信号の
時間的冗長度を削減できるピクチャ間予測符号化が広く
用いられている。ピクチャ間予測符号化とは、時間的に
異なる2つの画像の差分データと、画像内の動きを表す
動きベクトルを求め、この差分データと動きベクトルを
符号化して伝送する方法である。
2. Description of the Related Art Conventionally, in a system for transmitting a moving image signal, a technique for compressing and encoding the image signal has been developed in order to use a transmission line efficiently, and in particular, the temporal redundancy of the image signal can be reduced. Inter-picture prediction coding is widely used. The inter-picture predictive coding is a method of obtaining difference data between two temporally different images and a motion vector representing a motion in the image, and encoding and transmitting the difference data and the motion vector.

【0003】図12には、予測符号化に用いられる動き
ベクトルの算出方法が模式的に示されている。図におい
て、(a)は予測符号化すべき処理画像であり、(b)
は基準となる参照画像である。処理画像を複数のマクロ
ブロック(16×16画素)に分割し、任意の処理マク
ロブロック100と類似度の高いマクロブロックを参照
画像内でサーチし、両者の位置ずれを動きベクトル10
2として算出する。
FIG. 12 schematically shows a method of calculating a motion vector used for predictive coding. In the figure, (a) is a processed image to be predictively coded, and (b)
Is a reference image serving as a reference. The processed image is divided into a plurality of macroblocks (16 × 16 pixels), a macroblock having a high degree of similarity to an arbitrary processed macroblock 100 is searched for in the reference image, and the displacement between the two is determined by the motion vector
Calculated as 2.

【0004】図13には、動きベクトル102を算出す
る際に用いられるブロックマッチング法が模式的に示さ
れている。図において、(a)は処理画像、(b)〜
(d)は参照画像である。まず、(b)に示すように、
参照画像内で適当な検出範囲104を定め、この検出範
囲104内で処理マクロブロック100を1画素ずつ右
方向にずらしていく。横一列のサーチが終了した後、次
に(c)に示すように下方向に1画素ずらして再び左右
方向のサーチを行う。以上の処理を繰り返し、最終的に
検出範囲104内のすべてのサーチを行う(d)。各サ
ーチにおいては、所定の評価関数を用いて処理マクロブ
ロック100と参照画像のブロックとの差分を評価し、
この評価値が最小となる位置を求めることにより、処理
マクロブロック102の動きベクトルを算出する。
FIG. 13 schematically shows a block matching method used when calculating the motion vector 102. In the figure, (a) is a processed image, (b)-
(D) is a reference image. First, as shown in (b),
An appropriate detection range 104 is determined in the reference image, and the processing macroblock 100 is shifted rightward by one pixel within this detection range 104. After the search in one row is completed, the search in the left and right direction is performed again by shifting one pixel downward as shown in FIG. The above process is repeated, and all searches within the detection range 104 are finally performed (d). In each search, the difference between the processing macroblock 100 and the block of the reference image is evaluated using a predetermined evaluation function,
By calculating the position where the evaluation value becomes minimum, the motion vector of the processing macro block 102 is calculated.

【0005】このようなブロックマッチング法において
は、一般に参照画像と処理画像の画像間距離が増大す
る、つまり両画像の時間差が大きくなるにつれて動きベ
クトルも大きくなることに鑑み、参照画像と処理画像の
画像間距離に応じて検出範囲104を変化させている。
In such a block matching method, in consideration of the fact that the distance between the reference image and the processed image generally increases, that is, as the time difference between the two images increases, the motion vector also increases. The detection range 104 is changed according to the distance between images.

【0006】図14には、画像間距離(フレーム間距
離)が1、2、3の場合に参照画像に設定される検出範
囲104が例示されている。図において、(a)はフレ
ーム間距離が1の場合の検出範囲であり、処理マクロブ
ロックの位置に対応する参照画像位置を中心とする上下
左右の±15画素が検出範囲である。(b)はフレーム
間距離が2の場合の検出範囲であり、処理マクロブロッ
ク位置を中心とする±31画素が検出範囲となる。
(c)はフレーム間距離が3の場合であり、±47画素
が検出範囲となる。すなわち、画像間距離が増大するほ
ど、動きベクトルの検出範囲を大きく設定する。
FIG. 14 exemplifies a detection range 104 set for a reference image when the distance between images (distance between frames) is 1, 2, or 3. In the figure, (a) is a detection range when the inter-frame distance is 1, and ± 15 pixels at the top, bottom, left, and right around the reference image position corresponding to the position of the processing macroblock. (B) shows the detection range when the inter-frame distance is 2, and the detection range is ± 31 pixels centered on the position of the processing macroblock.
(C) shows a case where the distance between frames is 3, and ± 47 pixels are the detection range. That is, the detection range of the motion vector is set to be larger as the inter-image distance increases.

【0007】もちろん、このような検出範囲の設定は画
像の性質に応じて設定することも可能であり、例えば動
きの大きな画像を予測符号化する際には、動きの小さい
画像よりもその検出範囲をさらに大きく設定することも
可能である。
Of course, such a detection range can be set according to the nature of the image. For example, when predictive coding is performed on an image having a large motion, the detection range is set smaller than that of an image having a small motion. Can be set larger.

【0008】図15には、参照画像と処理画像のフレー
ム間距離と検出範囲104との関係が示されており、一
般的な動きの画像の場合と大きな動きの画像の場合に分
けた場合である。例えば、フレーム間距離が2の場合、
一般的な動きの画像の場合は検出範囲104は±31画
素となり、大きな動きの画像の場合には検出範囲104
は±47画素となる。
FIG. 15 shows the relationship between the inter-frame distance between the reference image and the processed image and the detection range 104. The relationship between the general motion image and the large motion image is shown. is there. For example, if the distance between frames is 2,
The detection range 104 is ± 31 pixels for a general motion image, and the detection range 104 for a large motion image.
Is ± 47 pixels.

【0009】以上のようにして検出範囲104を設定し
て動きベクトルを算出すると、処理画像のマクロブロッ
クごとに動きベクトルデータが得られるが、隣接するマ
クロブロックの動きは一般に類似していると考えられる
ので、動きベクトル値そのものを符号化するのではな
く、隣接するマクロブロックの動きベクトルとの差分を
求め、この差分動きベクトルを符号化することにより効
率よく圧縮することができる。
When the motion vector is calculated by setting the detection range 104 as described above, motion vector data is obtained for each macroblock of the processed image, but the motions of adjacent macroblocks are generally considered to be similar. Therefore, instead of encoding the motion vector value itself, a difference from the motion vector of an adjacent macroblock is obtained, and the difference motion vector is encoded, so that the compression can be efficiently performed.

【0010】図16には、処理画像の隣接するマクロブ
ロック、及び各マクロブロックごとに算出された動きベ
クトル成分が示されている。図において、マクロブロッ
クMBi-1、MBi、MBi+1は互いに隣接するマクロブ
ロックであり、MBi-1の動きベクトル成分は(xi-1、
yi-1)、MBiの動きベクトル成分は(xi、yi)、M
Bi+1の動きベクトル成分は(xi+1、yi+1)であると
すると、i番目のマクロブロックであるMBiの差分動き
ベクトルは次式で示される。
FIG. 16 shows adjacent macroblocks of a processed image and motion vector components calculated for each macroblock. In the figure, macroblocks MBi-1, MBi, MBi + 1 are adjacent macroblocks, and the motion vector components of MBi-1 are (xi-1,
yi-1), the motion vector components of MBi are (xi, yi), M
Assuming that the motion vector component of Bi + 1 is (xi + 1, yi + 1), the differential motion vector of MBi, which is the i-th macroblock, is expressed by the following equation.

【0011】[0011]

【数1】ΔMVi=MVi−MVi-1(Δxi=xi−xi-
1、Δyi=yi−yi-1) 以上のようにして差分動きベクトルが得られると、次に
この差分動きベクトルを可変長符号化(VLC)する。
## EQU1 ## ΔMVi = MVi−MVi−1 (Δxi = xi−xi−
1, Δyi = yi−yi−1) When the differential motion vector is obtained as described above, the differential motion vector is then subjected to variable length coding (VLC).

【0012】差分動きベクトルのVLCは、固定のVL
Cテーブルによって符号化される部分(上位ビット)
と、fコードによって符号長が定められる部分(下位ビ
ット)から構成されている。すなわち、fコードとは、
動きベクトル(差分動きベクトル)を符号化する際に用
いられるパラメータであり、このfコードを用いてVL
Cを固定VLCテーブル部分と付加ビット部分に分ける
ことで符号化データの冗長度が軽減される。
The VLC of the differential motion vector is a fixed VL
Part coded by C table (upper bit)
And a portion (lower-order bit) whose code length is determined by the f-code. That is, the f code is
This parameter is used when encoding a motion vector (difference motion vector).
By dividing C into a fixed VLC table portion and an additional bit portion, the redundancy of the encoded data is reduced.

【0013】図17及び図18には差分動きベクトルの
VLCの例が表形式で示されている。図17はfコード
が1の場合のVLCであり、ベクトルの差分値(Δ)が
±31以内、すなわちベクトル値自体が−16〜+15
の場合のVLCである。従って、図17のVLCを用い
ることができるのは、動きベクトルを検出したときの検
出範囲がこれらの値よりも小さい場合である。なお、符
号化される値はハーフペル(半画素)単位であるので、
整数画素単位で表すと−8〜+7.5画素となる。ま
た、図17において、例えば差分値が1の場合と−31
の場合とでは同じVLCを用いることになるが、ベクト
ル値は上述したように−16〜+15の範囲内であるの
で、直前の隣接マクロブロックのベクトル値がわかれば
一義的に決定することができる。例えば、直前の隣接マ
クロブロックのベクトル値が14であれば、ベクトルの
差分値は−31ではなく1である。
FIGS. 17 and 18 show VLC examples of differential motion vectors in a table format. FIG. 17 shows VLC when the f-code is 1, and the vector difference value (Δ) is within ± 31, that is, the vector value itself is −16 to +15.
VLC in the case of Therefore, the VLC shown in FIG. 17 can be used when the detection range when the motion vector is detected is smaller than these values. Since the value to be encoded is in units of half pels (half pixels),
Expressed in integer pixel units, it is -8 to +7.5 pixels. In FIG. 17, for example, the case where the difference value is 1 and -31
Although the same VLC is used in the case of, the vector value is in the range of −16 to +15 as described above, so that it can be uniquely determined if the vector value of the immediately preceding adjacent macroblock is known. . For example, if the vector value of the immediately preceding adjacent macroblock is 14, the vector difference value is 1 instead of −31.

【0014】一方、図18はfコードが2の場合のVL
Cであり、ベクトルの差分値(Δ)が±63以内の場合
のVLCである。図17と図18を比較すると明らかな
ように、図18のVLCの上位ビット部分は図17のV
LCと同一である。すなわち、図18では、図17のV
LCにさらに下位の1ビットが付加される関係にある。
より広い検知範囲で動き検出を行った場合には、大きな
動きベクトル値が検出される場合があるため、さらに下
位ビット部分が長くなる(つまりfコード値が大きくな
る)。しかしながら、下位ビット部分が長くなればそれ
だけ全体の符号長が長くなるため符号化効率が低下する
ことになる。従って、fコード値は検出範囲増大に伴う
予測効率の向上と符号化効率の低下のバランスを考慮し
て設定する必要がある。
FIG. 18 shows the VL when the f code is 2.
C, and is a VLC when the vector difference value (Δ) is within ± 63. As is apparent from a comparison between FIG. 17 and FIG. 18, the upper bit portion of VLC in FIG.
Same as LC. That is, in FIG. 18, V in FIG.
There is a relationship that lower one bit is added to LC.
When motion detection is performed in a wider detection range, a large motion vector value may be detected, so that the lower-order bit portion becomes longer (that is, the f-code value increases). However, the longer the lower bit portion, the longer the entire code length, and the lower the coding efficiency. Therefore, the f-code value needs to be set in consideration of the balance between the improvement of the prediction efficiency and the decrease of the coding efficiency with the increase of the detection range.

【0015】図19には、検出範囲と予測効率との関
係、及び検出範囲と動きベクトルの符号化効率との関係
が示されている。検出範囲が大きくなるほど類似度を大
きくできるため予測効率は向上するが、同時に差分値も
大きくなるため下位ビット部分が多く必要となって符号
化効率が低下する。従来においては、このような符号化
効率の低下が復号画像の画質劣化を招くと考え、検出範
囲に合わせてとり得る最小値を符号化時のfコード値と
して用いていた。
FIG. 19 shows the relationship between the detection range and the prediction efficiency, and the relationship between the detection range and the coding efficiency of the motion vector. As the detection range becomes larger, the similarity can be made larger, so that the prediction efficiency is improved, but at the same time, the difference value becomes larger, so that a larger number of lower-order bits are required and the coding efficiency is reduced. Conventionally, it is considered that such a decrease in coding efficiency causes deterioration in image quality of a decoded image, and a minimum value that can be obtained according to a detection range is used as an f-code value at the time of coding.

【0016】図20には、このようにして規定された従
来のMPEG規格のfコード値が示されている。なお、
フレーム構造でインタレース画像を符号化する場合、フ
レームベクトルとフィールドベクトルの2種類の動きベ
クトルが存在する。この2種類の動きベクトルはそれぞ
れ垂直方向の距離表現が異なる。図20において、同一
のfコード値に対して2種類の検出範囲が存在するのは
フレームベクトルとフィールドベクトルに対応したもの
である。具体的には、例えばフレーム予測符号化の場
合、検出範囲が−8〜+7.5の場合にはfコードは
1、検出範囲が−16〜+15.5の場合にはfコード
は2となる。
FIG. 20 shows f-code values of the conventional MPEG standard defined as described above. In addition,
When encoding an interlaced image with a frame structure, there are two types of motion vectors, a frame vector and a field vector. These two types of motion vectors have different distance expressions in the vertical direction. In FIG. 20, two types of detection ranges exist for the same f-code value corresponding to the frame vector and the field vector. Specifically, for example, in the case of frame prediction coding, the f-code is 1 when the detection range is -8 to +7.5, and the f-code is 2 when the detection range is -16 to +15.5. .

【0017】[0017]

【発明が解決しようとする課題】このように、従来のM
PEG規格においては、検出範囲に応じた所定のfコー
ドが定められており、fコード値が大きくなると符号長
が増すため、許容されるうちで最小のfコード値を用い
るのが通常であった。従って、動画像を符号化するに際
しては、参照画像と処理画像の画像間距離に応じて検出
範囲を変化させるとともに、それぞれの検出範囲に応じ
て定められているうちで最小のfコード値でVLCして
いるので、検出範囲毎に異なるVLCが要求され、結果
として可変長符号化回路の構成が複雑化してしまう問題
があった。
As described above, the conventional M
In the PEG standard, a predetermined f-code corresponding to the detection range is defined, and as the f-code value increases, the code length increases. Therefore, it is usual to use the smallest f-code value that is allowed. . Therefore, when encoding a moving image, the detection range is changed in accordance with the distance between the reference image and the processed image, and the VLC is set to the minimum f-code value defined in accordance with each detection range. Therefore, a different VLC is required for each detection range, and as a result, there is a problem that the configuration of the variable length coding circuit is complicated.

【0018】本発明は、上記従来技術の有する課題に鑑
みなされたものであり、その目的は、動きベクトルを符
号化する際の動きベクトルの検出範囲によらずに符号化
回路を共通化でき、もって回路構成を簡易化できる画像
符号化装置及び画像符号化方法を提供することにある。
SUMMARY OF THE INVENTION The present invention has been made in view of the above-mentioned problems of the related art, and has as its object to enable a common encoding circuit regardless of a motion vector detection range when encoding a motion vector. An object of the present invention is to provide an image encoding device and an image encoding method that can simplify the circuit configuration.

【0019】[0019]

【課題を解決するための手段】上記目的を達成するため
に、第1の発明は、入力画像の動きべクトルをfコード
を用いて符号化する画像符号化装置であって、入力画像
内の動き検出範囲に応じて予め定められたfコード値よ
りも大きな値を用いて動きベクトルを符号化する符号化
手段を有することを特徴とする。ここで、「fコード」
とは、MPEG2において動きベクトルを符号化する際
に用いられるパラメータであり、「動き検出範囲に応じ
て予め定められたfコード値」とは、MPEG規格にお
いて許容される最小のfコード値を意味する。MPEG
規格において許容される最小のfコードよりも大きめの
値を設定することで、より多様な動きベクトルの検出範
囲に対応することができる。
According to a first aspect of the present invention, there is provided an image encoding apparatus for encoding a motion vector of an input image using an f-code. It is characterized by having encoding means for encoding a motion vector using a value larger than an f-code value predetermined according to a motion detection range. Here, "f code"
Is a parameter used when encoding a motion vector in MPEG2, and the “predetermined f-code value according to the motion detection range” means the minimum f-code value allowed in the MPEG standard. I do. MPEG
By setting a value larger than the minimum f-code allowed in the standard, it is possible to cope with a wider variety of motion vector detection ranges.

【0020】また、第2の発明は、第1の発明におい
て、前記fコード値よりも大きな値は、4乃至5である
ことを特徴とする。fコード値を4乃至5に固定するこ
とで、符号化の構成を簡略化できる。
According to a second aspect of the present invention, in the first aspect, a value larger than the f-code value is 4 to 5. By fixing the f-code value to 4 or 5, the coding configuration can be simplified.

【0021】また、第3の発明は、第1、第2の発明に
おいて、前記動き検出範囲は前記入力画像のサイズの3
%乃至4%に固定されることを特徴とする。動き検出範
囲を上記の範囲に固定することで、復号画像の画質を維
持しつつ演算時間を削減することができる。
In a third aspect based on the first and second aspects, the motion detection range is three times the size of the input image.
% To 4%. By fixing the motion detection range to the above range, the calculation time can be reduced while maintaining the image quality of the decoded image.

【0022】また、第4の発明は、第1〜第3の発明に
おいて、前記動き検出範囲は、15×15画素または3
1×15画素のいずれかであることを特徴とする。この
範囲に制限することで、第3の発明と同様に画質向上と
演算時間縮小のバランスをとることができる。
In a fourth aspect based on the first to third aspects, the motion detection range is 15 × 15 pixels or 3 pixels.
It is one of 1 × 15 pixels. By limiting to this range, it is possible to balance the improvement of the image quality and the reduction of the calculation time as in the third invention.

【0023】また、第5の発明は、入力画像の動きベク
トルをfコードを用いて符号化する画像符号化方法であ
って、入力画像内の動きベクトル検出範囲に応じて定め
られたうちで最小のfコード値よりも大きな値を用いて
動きベクトルを符号化することを特徴とする。MPEG
規格において許容されるうちで最小のfコードよりも大
きめの値を設定することで、より多様な動きベクトルの
検出範囲に対応することができる。
According to a fifth aspect of the present invention, there is provided an image encoding method for encoding a motion vector of an input image using an f-code, wherein the minimum value is determined among the motion vector detection ranges in the input image. Is characterized in that the motion vector is encoded using a value larger than the f-code value. MPEG
By setting a value larger than the minimum f-code allowed in the standard, it is possible to cope with a wider variety of motion vector detection ranges.

【0024】また、第6の発明は、第5の発明におい
て、前記fコード値よりも大きな値は4乃至5であるこ
とを特徴とする。fコード値を4乃至5に固定すること
で、従来より簡易に動きベクトルを符号化することがで
きる。
In a sixth aspect based on the fifth aspect, the value larger than the f-code value is 4 to 5. By fixing the f-code value to 4 or 5, it is possible to encode a motion vector more easily than before.

【0025】また、第7の発明は、第5、第6の発明に
おいて、前記動き検出範囲は、前記入力画像のサイズの
3%乃至4%に固定されることを特徴とする。動き検出
範囲を上記の範囲に固定することで、復号画像の画質を
維持しつつ演算時間を削減することができる。
In a seventh aspect based on the fifth and sixth aspects, the motion detection range is fixed at 3% to 4% of the size of the input image. By fixing the motion detection range to the above range, the calculation time can be reduced while maintaining the image quality of the decoded image.

【0026】また、第8の発明は、第5〜第7の発明に
おいて、前記動き検出範囲は、15×15画素または3
1画素×15画素であることを特徴とする。動き検出範
囲を上記の範囲に固定することで、第7の発明と同様に
復号画像の画質を維持しつつ演算時間を削減することが
できる。
In an eighth aspect based on the fifth to seventh aspects, the motion detection range is 15 × 15 pixels or 3 pixels.
It is characterized by 1 pixel × 15 pixels. By fixing the motion detection range to the above range, the calculation time can be reduced while maintaining the image quality of the decoded image, as in the seventh aspect.

【0027】[0027]

【発明の実施の形態】以下、図面に基づき本発明の実施
形態について説明する。
Embodiments of the present invention will be described below with reference to the drawings.

【0028】図1には、本実施形態におけるMPEG2
画像符号化装置の全体構成が示されている。画像並び変
え回路110は、入力された動画像信号の画面順が並び
替える回路である。すなわち、時間的に後の画像を参照
画像として採用する場合、後の画像が先にメモりに格納
されている必要があるため、後の画像が先に処理される
ように画像の並び替えが行われる。前画像を参照してフ
レーム間予測符号化される画像をPピクチャ、前画像や
後画像を参照してフレーム間予測符号化される画像をB
ピクチャ、参照画像によるフレーム間予測符号化の行わ
れない画像をIピクチャとする。
FIG. 1 shows MPEG2 in the present embodiment.
1 shows the overall configuration of an image encoding device. The image rearranging circuit 110 is a circuit that rearranges the screen order of the input moving image signal. In other words, when a temporally later image is used as a reference image, the latter image needs to be stored in the memory first, so that the images are rearranged so that the latter image is processed first. Done. An image to be inter-frame predictively coded with reference to a previous image is a P picture, and an image to be inter-frame predictively coded with reference to a previous image or a subsequent image is a B picture.
An image that is not subjected to inter-frame prediction coding using a picture and a reference image is defined as an I picture.

【0029】走査変換マクロブロック化回路112は、
各画像を8×8画素のブロックに分割する回路で、動き
ベクトル等は4ブロックのマクロブロック単位で算出さ
れ、DCT、量子化はブロック単位で実行される。
The scan conversion macroblock conversion circuit 112
A circuit that divides each image into blocks of 8 × 8 pixels. Motion vectors and the like are calculated in units of four macroblocks, and DCT and quantization are performed in units of blocks.

【0030】減算器114は、走査変換マクロブロック
化回路112から供給された現画像の各画素データから
参照画像の各画素データを減算する回路であり、減算結
果である各画素の差分データはDCT回路116に供給
されてDCT(離散コサイン変換)される。
The subtractor 114 is a circuit for subtracting each pixel data of the reference image from each pixel data of the current image supplied from the scan conversion macroblocking circuit 112. The signal is supplied to a circuit 116 and subjected to DCT (discrete cosine transform).

【0031】DCT回路116は、ブロック単位(8×
8画素)で離散コサイン変換を行う回路であり、8×8
画素の各ブロックを低周波数項〜高周波数項の8行8列
の係数行列Cijに変換する。各係数は、量子化回路11
8に供給される。
The DCT circuit 116 has a block unit (8 ×
8 × 8 × 8 × 8 × 8 × 8 × 8 × 8 × 8 × 8 × 8
Each block of pixels is converted into a coefficient matrix Cij of 8 rows and 8 columns of low frequency terms to high frequency terms. Each coefficient is represented by a quantization circuit 11
8 is supplied.

【0032】重み付量子化回路118は、各係数Cijを
Qijで除算し、その余りを丸めることにより量子化して
データ量を削減する回路である。なお、量子化ステップ
幅は、ビットレート制御回路124から供給される。
The weighted quantization circuit 118 is a circuit that divides each coefficient Cij by Qij and rounds the remainder to quantize and reduce the data amount. The quantization step width is supplied from the bit rate control circuit 124.

【0033】量子化後、低周波数項〜高周波数項の順番
で出力される係数データは、可変長符号化回路120に
て可変長符号化(VLC)され、さらにデータ量が削減
される。可変長符号化後のデータは、バッファメモリ1
22に一時的に蓄えられた後、所定のビットレートで読
み出され、ビットストリームとして出力される。
After the quantization, the coefficient data output in the order of the low frequency term to the high frequency term is subjected to variable length coding (VLC) by the variable length coding circuit 120, and the data amount is further reduced. The data after the variable length encoding is stored in the buffer memory 1
After being temporarily stored in the memory 22, the data is read out at a predetermined bit rate and output as a bit stream.

【0034】逆量子化回路126、逆DCT回路128
は、参照画像として供するための前画像及び後画像の画
像データを再現するためのローカルエンコーダであり、
再現された画像は、画像メモリ132に格納されて減算
器114に出力される。なお、加算器130は、ローカ
ルデコーダ126、128で復号された画像データが差
分データである場合に、該差分データに動き補償付きの
参照画像データを加算して画像を完成するための回路で
ある。
Inverse quantization circuit 126, inverse DCT circuit 128
Is a local encoder for reproducing the image data of the previous image and the subsequent image to serve as a reference image,
The reproduced image is stored in the image memory 132 and output to the subtractor 114. When the image data decoded by the local decoders 126 and 128 is difference data, the adder 130 is a circuit for adding reference image data with motion compensation to the difference data to complete an image. .

【0035】画像メモリ132は、少なくとも2画面分
の画像データを蓄えるメモリであり、端子132bから
は参照用の画像データがマクロブロック単位で出力され
る。また、端子132aからは動きベクトル算出のため
の画像データが動き検出回路138に供給される。
The image memory 132 is a memory for storing image data for at least two screens, and image data for reference is output from the terminal 132b in macroblock units. Further, image data for calculating a motion vector is supplied to the motion detection circuit 138 from the terminal 132a.

【0036】動き検出回路138は、現画像内の現マク
ロブロックに最も類似する参照マクロブロックを検出
し、その位置ずれを動きベクトルとして検出する。検出
された動きベクトルは、可変長符号化(VLC)回路1
20に出力され、定められたfコード値で符号化され
る。
The motion detection circuit 138 detects a reference macroblock most similar to the current macroblock in the current image, and detects the displacement as a motion vector. The detected motion vector is stored in a variable length coding (VLC) circuit 1
20 and encoded with the determined f-code value.

【0037】また、動き補償回路134は、動きベクト
ル情報で指示される領域(参照マクロブロック領域)を
画像メモリ132の端子132bから出力させる。これ
により、参照マクロブロックの画像データが減算器11
4に供給され、上述したように現マクロブロックと参照
マクロブロックの差分が演算される。なお、動き補償回
路134の処理は、モード判定回路136から供給され
るマクロブロックタイプ情報MBTを参照して実行され
る。すなわち、画像メモリ132から前画像を出力する
か、後画像を出力するか、前画像及び後画像を出力する
か、出力しないかの選択は、MBTに基づいて行われ
る。
Further, the motion compensation circuit 134 outputs an area (reference macroblock area) specified by the motion vector information from the terminal 132b of the image memory 132. As a result, the image data of the reference macroblock is
4 and the difference between the current macroblock and the reference macroblock is calculated as described above. Note that the processing of the motion compensation circuit 134 is executed with reference to the macroblock type information MBT supplied from the mode determination circuit 136. That is, the selection of outputting the previous image, outputting the subsequent image, outputting the previous image and the subsequent image, or not outputting the image from the image memory 132 is performed based on the MBT.

【0038】以上のような符号化回路の構成において、
動きの異なる4種類の画像を用意し、これらの画像に対
して動きベクトルの検出範囲とfコード値を種々に変化
させて符号化し、さらに符号化された画像を従来と同様
の復号装置で復号してその画質を評価した。評価に用い
た画像は以下の通りである。
In the configuration of the encoding circuit as described above,
Four types of images having different motions are prepared, and these images are coded by changing the detection range of the motion vector and the f-code value in various ways. Further, the coded images are decoded by a decoding device similar to the conventional one. The image quality was evaluated. The images used for the evaluation are as follows.

【0039】 画像A:人と車のすれ違い程度の動きのある画像 画像B:走行中の車両から見たトンネル出口の画像 画像C:精細なオブジェクトの動きがある画像 画像D:複数の人間が高速でランダムに動き、特に横方
向の動きが大きい画像 これらの画像の動き量を比較すると、おおよそ画像C<
画像B<画像A<画像Dとなる。また、各画像のサイズ
は704×480(画素)であり、ビットレートは3M
bps、ピクチャー構造はフレーム構造で予測方式はフ
レーム動き補償である。
Image A: Image with movement of human and car passing each other Image B: Image of tunnel exit seen from running vehicle Image C: Image with fine object movement Image D: Multiple people at high speed The image moves randomly, and particularly the horizontal motion is large. Comparing the amounts of motion of these images, it can be roughly found that the image C <
Image B <Image A <Image D The size of each image is 704 × 480 (pixels), and the bit rate is 3M.
bps, the picture structure is a frame structure, and the prediction method is frame motion compensation.

【0040】図2には、画像Aの評価結果が示されてい
る。なお、検出範囲の表現として、−8〜+7画素を
「7×7画素」、−16〜+15画素を「15×15画
素」、−32〜+31画素を「31×31画素」などと
簡易的に表している。図において横軸はfコード値であ
り、縦軸は復号画像の輝度のS/Nである。また、折線
aは検出範囲が7×7画素のS/N、折線bは検出範囲
が15×15画素のS/N、折線cは31×31画素の
S/N、折線dは63×63画素のS/N、折線eは1
27×127画素のS/Nをそれぞれ示している。折線
a(7×7画素)に着目すると、MPEG規格において
従来用いられてきた最小のfコード値は1であり、この
場合のS/Nよりもfコード値が2乃至5の場合に同等
以上のS/Nが得られている。また、折線b(15×1
5画素)においても、MPEG規格において用いられて
きた最小のfコード値は2であり、この場合のS/Nよ
りもfコード値が3乃至5の場合に同等以上のS/Nが
得られている。
FIG. 2 shows the evaluation result of the image A. Note that the detection range is simply expressed as “7 × 7 pixels” for −8 to +7 pixels, “15 × 15 pixels” for −16 to +15 pixels, and “31 × 31 pixels” for −32 to +31 pixels. Is represented in In the figure, the horizontal axis is the f-code value, and the vertical axis is the S / N of the luminance of the decoded image. The broken line a has a detection range of 7 × 7 pixels S / N, the broken line b has a detection range of 15 × 15 pixels S / N, the broken line c has 31 × 31 pixels S / N, and the broken line d has 63 × 63. S / N of pixel, broken line e is 1
The S / N of 27 × 127 pixels is shown. Focusing on the polygonal line a (7 × 7 pixels), the minimum f-code value conventionally used in the MPEG standard is 1, which is equal to or greater than the S / N in the case where the f-code value is 2 to 5, Is obtained. Also, the folded line b (15 × 1
5 pixels), the minimum f-code value used in the MPEG standard is 2, and when the f-code value is 3 to 5, an S / N equal to or higher than that in this case is obtained. ing.

【0041】図3には、画像Bの評価結果が示されてい
る。図2と同様に、折線aは検出範囲が7×7画素のS
/N、折線bは検出範囲が15×15画素のS/N、折
線cは検出範囲が31×31画素のS/Nをそれぞれ示
している。この画像Bにおいても、折線aに着目すると
MPEG規格で従来用いられてきた最小のfコード値1
の場合のS/Nよりもfコード値が2乃至5の場合の方
が同等以上のS/Nが得られている。また、折線bにお
いても、MPEG規格で従来用いられてきた最小のfコ
ード値が2の場合のS/Nに比べて、fコード値が3乃
至5の場合に同等以上のS/Nが得られている。
FIG. 3 shows an evaluation result of the image B. As in FIG. 2, the broken line a indicates that the detection range is 7 × 7 pixels.
/ N, broken line b shows the S / N of the detection range of 15 × 15 pixels, and broken line c shows the S / N of the detection range of 31 × 31 pixels. Also in this image B, focusing on the polygonal line a, the minimum f-code value 1 conventionally used in the MPEG standard
When the f-code value is 2 to 5, the same or higher S / N is obtained than the S / N in the case of. Also at the broken line b, when the f-code value is 3 to 5, an S / N equal to or higher than that when the minimum f-code value is 2 conventionally used in the MPEG standard is 2 is obtained. Have been.

【0042】図4には、画像Cの評価結果が示されてい
る。折線aは検出範囲が7×7画素のS/N、折線bは
検出範囲が15×15画素のS/N、折線cは検出範囲
が31×31画素のS/Nをそれぞれ示している。この
画像Cにおいても、折線aではfコード値が従来の1の
場合に比べて2乃至5の場合に同等以上のS/Nが得ら
れており、折線bの場合もfコード値が従来の2の場合
に比べて3乃至5の場合に同等以上のS/Nが得られて
いる。
FIG. 4 shows the evaluation result of the image C. The broken line a shows the S / N of the detection range of 7 × 7 pixels, the broken line b shows the S / N of the detection range of 15 × 15 pixels, and the broken line c shows the S / N of the detection range of 31 × 31 pixels. Also in this image C, the S / N of the broken line a is equal to or higher than that of the conventional f code value of 1 to 2 when the f code value is 2 to 5, and the f code value of the broken line b is the same as the conventional f code value. Compared with the case of 2, the S / N equal to or higher than that of the case of 3 to 5 was obtained.

【0043】図5には、画像Dの評価結果が示されてい
る。折線aは検出範囲が7×7画素のS/N、折線bは
検出範囲が15×15画素のS/N、折線cは検出範囲
が31×31画素のS/N、折線dは検出範囲が63×
63画素のS/N、折線eは検出範囲が127×127
画素のS/Nをそれぞれ示している。この画像Dにおい
ても、折線aではfコード値が従来の1の場合に比べて
2乃至5の場合に同等以上のS/Nが得られており、折
線bの場合にもfコード値が従来の場合に比べて3乃至
5の場合に同等以上のS/Nが得られている。さらに、
折線cの場合でも、MPEG規格で従来用いられてきた
最小のfコード値が3の場合に比べて4乃至5の場合に
同等以上のS/Nが得られている。
FIG. 5 shows the evaluation result of the image D. The broken line a has a detection range of 7 × 7 pixels S / N, the broken line b has a detection range of 15 × 15 pixels S / N, the broken line c has a detection range of 31 × 31 pixels S / N, and the broken line d has a detection range. Is 63 ×
S / N of 63 pixels, broken line e has a detection range of 127 × 127
The S / N of each pixel is shown. In this image D as well, the S / N of the broken line a is equal to or higher than that of the conventional case where the f code value is 2 to 5 when the f code value is 2 to 5, and the f code value is the same as that of the broken line b in the conventional case. As compared with the case of 3, the S / N equal to or higher than that of the case of 3 to 5 is obtained. further,
Even in the case of the broken line c, an S / N equal to or higher than that of the case where the minimum f-code value conventionally used in the MPEG standard is 3 or 4 is 5 or 5 is obtained.

【0044】図6には、画像Dの他の評価結果が示され
ている。図において、折線aは検出範囲が7×3画素
(横が−8〜+7、縦が−4〜+3)のS/N、折線b
は検出範囲が15×7画素のS/N、折線cは検出範囲
が31×15画素のS/Nをそれぞれ示している。この
ような検出範囲を設定したのは、画像Dの性質、すなわ
ち横方向の動きが特に大きいという性質を考慮したもの
である。このような検出範囲を設定した場合でも、従来
のMPEG規格で用いられてきた最小のfコード値より
も大きなfコード値を設定することにより同等以上のS
/Nが得られることがわかる。すなわち、折線aの場合
では、fコード値が1の場合に比べて2乃至5の場合に
同等以上のS/Nが得られ、折線bの場合にもfコード
値が2の場合に比べて3乃至5の場合に同等以上のS/
Nが得られている。また、折線cの場合には他の検出範
囲に比べて特にS/Nが大きく、またfコード値が3の
場合に比べて4乃至5の場合に同等以上のS/Nが得ら
れている。
FIG. 6 shows another evaluation result of the image D. In the figure, a broken line a is an S / N of a detection range of 7 × 3 pixels (−8 to +7 in the horizontal direction, −4 to +3 in the vertical direction), and a broken line b.
Indicates the S / N of the detection range of 15 × 7 pixels, and the broken line c indicates the S / N of the detection range of 31 × 15 pixels. The detection range is set in consideration of the property of the image D, that is, the property that the horizontal movement is particularly large. Even when such a detection range is set, by setting an f-code value larger than the minimum f-code value used in the conventional MPEG standard, the same or higher S-code value can be obtained.
/ N is obtained. That is, in the case of the polygonal line a, an S / N equal to or higher than that in the case where the f-code value is 2 is obtained when the f-code value is 2 to 5 as compared with the case where the f-code value is 1. S / S equal to or greater than 3/5
N has been obtained. Further, in the case of the broken line c, the S / N is particularly large as compared with the other detection ranges, and the S / N equal to or higher than that in the case where the f code value is 3 is 4 or 5 as compared with the case where the f code value is 3. .

【0045】以上の評価結果から明らかなように、従来
のMPEG規格で用いられてきた最小のfコード値より
も大きなfコード値を設定しても、画質は劣化すること
なくむしろ良好となる場合があり、特にfコード値が4
乃至5の場合にその傾向が顕著であることがわかる。
As is apparent from the above evaluation results, when the f-code value larger than the minimum f-code value used in the conventional MPEG standard is set, the image quality is improved without deterioration. Especially when the f-code value is 4
It can be seen that the tendency is remarkable in the cases of Nos. 1 to 5.

【0046】この事実は、fコード値が大きくなればデ
ータの冗長度が増大し、符号化効率が低下するので復号
画像の画質も劣化するとした従来の考えが必ずしも妥当
でなく、むしろfコード値としては検出範囲に応じてと
り得る最小値(図20参照)よりも大きな値を設定した
方が好ましいことを意味している。このようにfコード
値を従来のMPEG規格で用いられてきた最小値よりも
大きめに設定することで以下のような利点が生じる。す
なわち、従来においては、検出範囲に応じた最小のfコ
ード値を用いていたため、検出範囲に応じて異なるVL
C(下位ビット長の長さが異なる)を行っていたが、f
コード値を大きめに設定し、特に4乃至5に設定するこ
とで、検出範囲が7×7画素、15×15画素、31×
31画素と変化しても共通のfコード値を用いて共通の
VLCを行うことが可能となる。
It is not true that the conventional idea that if the f-code value increases, the redundancy of data increases and the coding efficiency decreases, so that the image quality of the decoded image also deteriorates, is rather unreasonable. Means that it is preferable to set a value larger than the minimum value that can be taken according to the detection range (see FIG. 20). By setting the f-code value larger than the minimum value used in the conventional MPEG standard, the following advantages are obtained. That is, in the related art, since the minimum f-code value corresponding to the detection range is used, different VL values vary according to the detection range.
C (the length of the lower bit length is different), but f
By setting the code value to a relatively large value, particularly to 4 to 5, the detection range becomes 7 × 7 pixels, 15 × 15 pixels, 31 ×
Even if the number of pixels changes to 31, the common VLC can be performed using the common f-code value.

【0047】なお、従来のMPEG規格のfコード値よ
りも大きめのfコード値(特に4乃至5)に設定するこ
とにより復号画像の画質が向上する理由は、以下のよう
に考えられる。すなわち、実際に符号化される値は、上
述したように動きベクトル値ではなく直前に符号化した
マクロブロックの動きベクトル値と符号化するマクロブ
ロックの動きベクトル値との差分であり、画像シーケン
ス内のオブジェクトやカメラの動きが単純で検出した動
きベクトルの向きが揃っていれば差分値はゼロに近い値
になる。一方、複数のオブジェクトがランダムに動くシ
ーケンスでは差分の絶対値が大きくなる。従って、動き
ベクトルデータの符号長は、この差分値の大きさとfコ
ードによって定まり、差分値分布に適応したfコード値
を設定することで符号化効率が向上し、復号画像の画質
も向上すると考えられる。
The reason why the quality of the decoded image is improved by setting the f-code value (particularly, 4 or 5) larger than the f-code value of the conventional MPEG standard is considered as follows. That is, the value to be actually coded is not the motion vector value as described above, but the difference between the motion vector value of the macroblock coded immediately before and the motion vector value of the macroblock to be coded. If the motion of the object or the camera is simple and the directions of the detected motion vectors are the same, the difference value becomes a value close to zero. On the other hand, in a sequence in which a plurality of objects move randomly, the absolute value of the difference increases. Therefore, the code length of the motion vector data is determined by the magnitude of the difference value and the f-code, and by setting the f-code value adapted to the difference value distribution, the coding efficiency is improved, and the image quality of the decoded image is also considered to be improved. Can be

【0048】図7〜図12には、上述の画像A、B、
C、Dの差分値分布が示されている。図7は画像Aの差
分値分布であり、(a)は検出範囲が7×7画素の差分
値分布、(b)は検出範囲が15×15画素の差分値分
布、(c)は検出範囲が31×31画素の差分値分布で
ある。各図において、横軸は差分値Δ、縦軸は分布数で
ある。図からわかるように、差分値がゼロとなる場合が
かなり多く、また絶対値が小さいところに集中してい
る。
FIGS. 7 to 12 show the images A, B,
The difference value distribution of C and D is shown. 7A and 7B show the difference value distribution of the image A, wherein FIG. 7A shows a difference value distribution having a detection range of 7 × 7 pixels, FIG. 7B shows a difference value distribution having a detection range of 15 × 15 pixels, and FIG. Is a difference value distribution of 31 × 31 pixels. In each figure, the horizontal axis is the difference value Δ, and the vertical axis is the number of distributions. As can be seen from the figure, there are many cases where the difference value is zero, and the difference value is concentrated on a place where the absolute value is small.

【0049】図8は画像Bの差分値分布であり、(a)
は検出範囲が7×7画素の差分値分布、(b)は検出範
囲が15×15画素の差分値分布、(C)は検出範囲が
31×31画素の差分値分布である。この画像Bも画像
Aと同様に差分値ゼロとなる場合がかなり多く、また絶
対値が小さいところに集中する傾向がある。
FIG. 8 shows the difference value distribution of the image B.
Is a difference value distribution having a detection range of 7 × 7 pixels, (b) is a difference value distribution having a detection range of 15 × 15 pixels, and (C) is a difference value distribution having a detection range of 31 × 31 pixels. As in the case of the image A, the image B often has a difference value of zero, and tends to concentrate on a place where the absolute value is small.

【0050】図9は画像Cの差分値分布であり、(a)
は検出範囲が7×7画素の差分値分布、(b)は検出範
囲が15×15画素の差分値分布、(c)は検出範囲が
31×31画素の差分値分布である。画像AまたはBの
場合に比べて差分値がゼロとなる場合が少なく、絶対値
が大きいところにも分布している。
FIG. 9 shows the difference value distribution of the image C.
In the figure, (b) shows a difference value distribution having a detection range of 15 × 15 pixels, and (c) shows a difference value distribution having a detection range of 31 × 31 pixels. The difference value is less likely to be zero than in the case of the image A or B, and the difference value is also distributed where the absolute value is large.

【0051】図10は画像Dの差分値分布であり、
(a)は検出範囲が7×7画素の差分値分布、(b)は
検出範囲が15×15画素の差分値分布、(c)は検出
範囲が31×31画素の差分値分布である。この画像D
でも、画像A、Bに比べて差分値がゼロとなる場合が少
なく、また絶対値が大きい付近にも分布が多くなってい
る。
FIG. 10 shows the difference value distribution of the image D.
(A) is a difference value distribution having a detection range of 7 × 7 pixels, (b) is a difference value distribution having a detection range of 15 × 15 pixels, and (c) is a difference value distribution having a detection range of 31 × 31 pixels. This image D
However, the difference value is less likely to be zero as compared with the images A and B, and the distribution increases near the area where the absolute value is large.

【0052】一方、図11にはfコード値が1及び2の
場合の動きベクトル(実際には差分動きベクトル)の符
号長が示されている。(a)はfコード値が1の場合で
あり、横軸は差分値(Δ)、縦軸は符号長である。図よ
り、動きベクトルの符号量を少なくするためには、差分
値の絶対値が10〜8以下であるか、または25以上で
あればよい。特に、差分値がゼロとなる場合には、他の
場合よりも少なくとも2ビット軽減できるため非常に有
利である。
On the other hand, FIG. 11 shows the code length of a motion vector (actually, a difference motion vector) when the f-code values are 1 and 2. (A) shows the case where the f-code value is 1, the horizontal axis represents the difference value (Δ), and the vertical axis represents the code length. As shown in the figure, in order to reduce the code amount of the motion vector, the absolute value of the difference value needs to be 10 to 8 or less, or 25 or more. In particular, when the difference value becomes zero, it is very advantageous because at least two bits can be reduced as compared with other cases.

【0053】また、(b)はfコード値が2の場合であ
り、動きベクトルの符号量を少なくするためには、差分
値の絶対値が20以下であるか、または50以上であれ
ばよい。
(B) shows a case where the f-code value is 2, and in order to reduce the amount of code of the motion vector, the absolute value of the difference value should be 20 or less, or 50 or more. .

【0054】このような差分値と符号長との関係、並び
に図7から図10に示された差分値分布を考慮すると以
下のことが明らかとなる。すなわち、画像Aにおいては
差分値がゼロとなる場合が他の画像に比べて極端に多い
ので、符号長が少なく、符号化効率がよい。一方、画像
Dの差分値分布は画像Aに比べてフラットであり、差分
値がゼロとなる場合の数が少ない。しかし、差分値の絶
対値が大きい部分の個数も多いため、符号量を少なくす
るのに役立っている。
Considering the relationship between the difference value and the code length and the difference value distribution shown in FIGS. 7 to 10, the following becomes clear. That is, in the image A, the difference value is extremely zero in many cases as compared with other images, so that the code length is small and the coding efficiency is good. On the other hand, the difference value distribution of the image D is flatter than the image A, and the number of cases where the difference value becomes zero is small. However, since the number of parts having a large absolute value of the difference value is large, this is useful for reducing the code amount.

【0055】また、画像Cは差分値の絶対値が大きくな
るにつれ個数が減少する傾向にあるが、差分値がゼロの
場合の数も少ない。このため、従来のfコード値では十
分に符号量を少なくすることができない。そこで、fコ
ード値を従来より大きめに設定することで符号効率を向
上させ、S/Nを改善することができる。
Further, the number of the images C tends to decrease as the absolute value of the difference value increases, but the number when the difference value is zero is also small. For this reason, the code amount cannot be sufficiently reduced with the conventional f-code value. Therefore, by setting the f-code value to be larger than before, the code efficiency can be improved, and the S / N can be improved.

【0056】また、画像Bの場合は差分値がゼロの場合
の個数が多い点では画像Aと似ており、その他の傾向で
は画像Cと似ている。従って、画像Bは画像Aと画像C
の中間の傾向をとり、画像Cと同様に従来のMPEG規
格におけるfコード値よりも大きなfコード値を設定す
ることで符号効率が向上する。
The image B is similar to the image A in that the number of cases where the difference value is zero is large, and is similar to the image C in other tendencies. Therefore, image B is composed of image A and image C.
By setting an f-code value larger than the f-code value in the conventional MPEG standard as in the case of the image C, the coding efficiency is improved.

【0057】このように、従来のMPEG規格のfコー
ド値よりも大きいfコード値を設定して予測符号化する
ことにより、復号画像の画質を劣化させることなく、動
きベクトルを符号化することが可能となる。好適には、
fコード値を4乃至5に設定することにより、S/Nを
従来と同等以上に保持しつつ、任意の検出範囲から算出
された動きベクトルを符号化することができる。
As described above, by setting an f-code value larger than the f-code value of the conventional MPEG standard and performing predictive coding, a motion vector can be coded without deteriorating the image quality of a decoded image. It becomes possible. Preferably,
By setting the f-code value to 4 or 5, it is possible to encode a motion vector calculated from an arbitrary detection range while maintaining the S / N at or above that of the related art.

【0058】具体的な回路構成としては、図1において
可変長符号化回路120が従来のように動き検出回路1
38からの動き検出範囲情報に応じたfコード値(MP
EG規格の中で従来用いられてきた最小値)でVLCを
行うのではなく、固定のfコード値でVLCを行うこと
になる。従って、従来の可変長符号化回路120におい
ては、fコード値が変数であるためこれを処理するため
の演算回路が必要であったところ、本実施形態の可変長
符号化回路120ではこのような演算回路が不要とな
り、構成が簡略化される。
As a specific circuit configuration, the variable length encoding circuit 120 in FIG.
F code value (MP
Instead of performing VLC with the minimum value conventionally used in the EG standard), VLC is performed with a fixed f-code value. Therefore, the conventional variable-length encoding circuit 120 requires an arithmetic circuit for processing the f-code value because it is a variable, but the variable-length encoding circuit 120 according to the present embodiment requires such an arithmetic circuit. An arithmetic circuit is not required, and the configuration is simplified.

【0059】また、検出範囲はフレーム間距離に応じて
設定することができるが、図2〜図6から明らかなよう
に、検出範囲を15×15画素に制限しても十分なS/
Nが得られるので、フレーム間距離によらず検出範囲を
この値に固定するのも好ましい。一般に、動き検出範囲
の面積が2倍になると、動きベクトルを算出するための
演算量は面積に比例して2倍となる。従って、動き検出
範囲を15×15画素に固定することにより、演算処理
時間の削減を図ることが可能となる。
Although the detection range can be set according to the inter-frame distance, as is apparent from FIGS. 2 to 6, even if the detection range is limited to 15 × 15 pixels, a sufficient S / S ratio is obtained.
Since N is obtained, it is also preferable to fix the detection range to this value regardless of the inter-frame distance. Generally, when the area of the motion detection range is doubled, the amount of calculation for calculating the motion vector is doubled in proportion to the area. Therefore, by fixing the motion detection range to 15 × 15 pixels, it is possible to reduce the calculation processing time.

【0060】また、特に画像Dのように横方向の動きが
大きい画像に対しては、31×15画素のような横長の
検出範囲に固定することがS/N及び演算時間の観点か
ら好ましい。これら15×15画素または31×15画
素はフレームサイズの約3〜4%に相当する大きさであ
り、一般にこの範囲に動き検出範囲を制限することによ
り、復号画像の画質を劣化させることなく演算時間の短
縮を図ることができる。
In particular, for an image having a large horizontal movement such as the image D, it is preferable to fix it to a horizontally long detection range such as 31 × 15 pixels from the viewpoint of S / N and calculation time. These 15 × 15 pixels or 31 × 15 pixels have a size corresponding to about 3 to 4% of the frame size. Generally, by restricting the motion detection range to this range, the calculation is performed without deteriorating the image quality of the decoded image. Time can be reduced.

【0061】具体的な回路構成としては、図1において
動き検出回路138が従来のようにフレーム間距離に応
じて動き検出範囲を変化させて動きベクトルを検出する
のではなく、動き検出範囲を入力画像サイズの約3%〜
4%に相当する範囲に固定して処理することになる。従
って、従来の動き検出回路138においては、フレーム
間距離に応じて動き検出範囲を設定する処理回路及び処
理する画像データ分を格納するメモリ容量が必要であっ
たところ、本実施形態の動き検出回路138ではこのよ
うな処理回路が不要となるとともに一定の小容量メモリ
で済むことになり、構成が簡略化されることになる。
As a specific circuit configuration, in FIG. 1, the motion detection circuit 138 inputs the motion detection range instead of detecting the motion vector by changing the motion detection range according to the inter-frame distance as in the related art. About 3% of the image size
The processing is fixed at a range corresponding to 4%. Therefore, the conventional motion detection circuit 138 requires a processing circuit for setting a motion detection range according to the inter-frame distance and a memory capacity for storing image data to be processed. In the case of 138, such a processing circuit is not required, and a fixed small-capacity memory is required, so that the configuration is simplified.

【0062】[0062]

【発明の効果】以上説明したように、本発明の画像符号
化装置及び画像符号化方法によれば、従来のMPEG規
格のfコード値よりも大きなfコード値、好ましくは4
乃至5に固定することで動き検出範囲によらず共通の符
号化回路を用いることが可能となり、装置構成の簡略化
を図ることができる。
As described above, according to the image coding apparatus and the image coding method of the present invention, the f-code value larger than that of the conventional MPEG standard, preferably 4
By fixing to 5 or less, a common encoding circuit can be used regardless of the motion detection range, and the device configuration can be simplified.

【0063】また、動き検出範囲を特にフレームサイズ
の3〜4%に制限することにより復号画像の画質を維持
しつつ演算処理時間の削減を図ることができる。
Further, by limiting the motion detection range to 3 to 4% of the frame size, it is possible to reduce the calculation processing time while maintaining the image quality of the decoded image.

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

【図1】 本発明の実施形態の全体構成図である。FIG. 1 is an overall configuration diagram of an embodiment of the present invention.

【図2】 実施形態の画像AのfコードとS/Nの関係
を示すグラフ図である。
FIG. 2 is a graph illustrating a relationship between an f-code and S / N of an image A according to the embodiment.

【図3】 実施形態の画像BのfコードとS/Nの関係
を示すグラフ図である。
FIG. 3 is a graph showing the relationship between the f-code and S / N of an image B according to the embodiment.

【図4】 実施形態の画像CのfコードとS/Nの関係
を示すグラフ図である。
FIG. 4 is a graph illustrating the relationship between the f-code and S / N of an image C according to the embodiment.

【図5】 実施形態の画像DのfコードとS/Nの関係
を示すグラフ図である。
FIG. 5 is a graph illustrating a relationship between an f-code and an S / N of an image D according to the embodiment.

【図6】 実施形態における画像Dの他の検出範囲にお
けるfコードとS/Nの関係を示すグラフ図である。
FIG. 6 is a graph showing the relationship between f code and S / N in another detection range of the image D according to the embodiment.

【図7】 実施形態の画像Aの差分値分布を示すグラフ
図である。
FIG. 7 is a graph illustrating a difference value distribution of an image A according to the embodiment.

【図8】 実施形態の画像Bの差分値分布を示すグラフ
図である。
FIG. 8 is a graph illustrating a difference value distribution of an image B according to the embodiment.

【図9】 実施形態の画像Cの差分値分布を示すグラフ
図である。
FIG. 9 is a graph showing a difference value distribution of an image C according to the embodiment.

【図10】 実施形態の画像Dの差分値分布を示すグラ
フ図である。
FIG. 10 is a graph illustrating a difference value distribution of an image D according to the embodiment.

【図11】 実施形態のfコード値が1の場合の動きベ
クトル符号長を示すグラフ図である。
FIG. 11 is a graph showing a motion vector code length when an f-code value is 1 in the embodiment.

【図12】 動きベクトル算出処理を示す説明図であ
る。
FIG. 12 is an explanatory diagram showing a motion vector calculation process.

【図13】 ブロックマッチング法の説明図である。FIG. 13 is an explanatory diagram of a block matching method.

【図14】 フレーム間距離と検出範囲との関係を示す
説明図である。
FIG. 14 is an explanatory diagram showing a relationship between an inter-frame distance and a detection range.

【図15】 フレーム間距離と検出範囲との関係を示す
表図である。
FIG. 15 is a table showing the relationship between the inter-frame distance and the detection range.

【図16】 差分動きベクトル算出説明図である。FIG. 16 is an explanatory diagram of calculating a differential motion vector.

【図17】 動きベクトルのVLC説明図(fコード=
1の場合)である。
FIG. 17 is an explanatory diagram of VLC of a motion vector (f code =
1).

【図18】 動きベクトルのVLC説明図(fコード=
2の場合)である。
FIG. 18 is an explanatory diagram of VLC of a motion vector (f code =
2).

【図19】 検出範囲と予測効率及び符号化効率との関
係を示すグラフ図である。
FIG. 19 is a graph showing a relationship between a detection range, prediction efficiency, and coding efficiency.

【図20】 従来のMPEG規格における検出範囲とf
コード値との関係を示す説明図である。
FIG. 20 shows a detection range and f in the conventional MPEG standard.
FIG. 4 is an explanatory diagram showing a relationship with a code value.

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

110 画像並び変え、112 走査変換マクロブロッ
ク化、116 DCT、118 重み付量子化、120
可変長符号化、122 バッファ、124ビットレー
ト制御、126 逆量子化、128 逆DCT、132
画像メモリ、134 動き補償、136 モード判
定、138 動き検出。
110 image rearrangement, 112 scan conversion macroblock conversion, 116 DCT, 118 weighted quantization, 120
Variable length coding, 122 buffer, 124 bit rate control, 126 inverse quantization, 128 inverse DCT, 132
Image memory, 134 motion compensation, 136 mode determination, 138 motion detection.

───────────────────────────────────────────────────── フロントページの続き (56)参考文献 特開 平6−334993(JP,A) 特開 平7−274174(JP,A) 米国特許5731850(US,A) テレビジョン学会編,「MPEG」, 初版,オーム社,平成8年4月,p.94 −96 (58)調査した分野(Int.Cl.7,DB名) H04N 7/24 - 7/68 JICSTファイル(JOIS)────────────────────────────────────────────────── ─── Continuation of the front page (56) References JP-A-6-334993 (JP, A) JP-A-7-274174 (JP, A) US Pat. No. 5,731,850 (US, A) Television Society, “MPEG” , First Edition, Ohmsha, April 1996, p. 94 -96 (58) Field surveyed (Int.Cl. 7 , DB name) H04N 7/ 24-7/68 JICST file (JOIS)

Claims (10)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 入力画像の動きべクトルをfコードを用
いて符号化する画像符号化装置であって、 入力画像内の動き検出範囲の動きベクトル値に応じて許
容される複数のfコード値のうち、最小値よりも大きな
fコード値を用いて動きベクトルを符号化する符号化手
段を有することを特徴とする画像符号化装置。
1. An image encoding apparatus for encoding a motion vector of an input image using an f-code, comprising a plurality of f-code values allowed according to a motion vector value of a motion detection range in the input image. An image coding apparatus comprising: coding means for coding a motion vector using an f-code value larger than a minimum value.
【請求項2】 前記fコード値は、最小値よりも1乃至
2大きな値であることを特徴とする請求項1記載の画像
符号化装置。
2. The image coding apparatus according to claim 1, wherein the f-code value is a value that is 1 or 2 larger than a minimum value.
【請求項3】 前記fコード値は、4乃至5であること
を特徴とする請求項1記載の画像符号化装置。
3. The image coding apparatus according to claim 1, wherein said f-code value is 4 to 5.
【請求項4】 前記動き検出範囲は、前記入力画像のサ
イズの3%乃至4%に固定されることを特徴とする請求
項1〜3のいずれかに記載の画像符号化装置。
4. The image encoding apparatus according to claim 1, wherein the motion detection range is fixed to 3% to 4% of the size of the input image.
【請求項5】 前記動き検出範囲は、15×15画素ま
たは31×15画素のいずれかであることを特徴とする
請求項1〜4のいずれかに記載の画像符号化装置。
5. The image encoding apparatus according to claim 1, wherein the motion detection range is any one of 15 × 15 pixels and 31 × 15 pixels.
【請求項6】 入力画像の動きベクトルをfコードを用
いて符号化する画像符号化方法であって、 入力画像内の動き検出範囲の動きベクトル値に応じて許
容される複数のfコード値のうち、最小値よりも大きな
fコード値を用いて動きベクトルを符号化することを特
徴とする画像符号化方法。
6. An image encoding method for encoding a motion vector of an input image using an f-code, comprising a plurality of f-code values allowed according to a motion vector value of a motion detection range in the input image. An image coding method characterized by coding a motion vector using an f-code value larger than a minimum value.
【請求項7】 前記fコード値は、最小値よりも1乃至
2大きな値であることを特徴とする請求項6記載の画像
符号化方法。
7. The image encoding method according to claim 6, wherein the f-code value is a value that is one or two times larger than a minimum value.
【請求項8】 前記fコード値は、4乃至5であること
を特徴とする請求項6記載の画像符号化方法。
8. The image encoding method according to claim 6, wherein the f-code value is 4 to 5.
【請求項9】 前記動き検出範囲は、前記入力画像のサ
イズの3%乃至4%に固定されることを特徴とする請求
項6〜8のいずれかに記載の画像符号化方法。
9. The image encoding method according to claim 6, wherein the motion detection range is fixed at 3% to 4% of the size of the input image.
【請求項10】 前記動き検出範囲は、15×15画素
または31×15画素のいずれかであることを特徴とす
る請求項6〜9のいずれかに記載の画像符号化方法。
10. The image encoding method according to claim 6, wherein the motion detection range is one of 15 × 15 pixels and 31 × 15 pixels.
JP23308297A 1997-08-28 1997-08-28 Image encoding apparatus and image encoding method Expired - Fee Related JP3234544B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP23308297A JP3234544B2 (en) 1997-08-28 1997-08-28 Image encoding apparatus and image encoding method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP23308297A JP3234544B2 (en) 1997-08-28 1997-08-28 Image encoding apparatus and image encoding method

Publications (2)

Publication Number Publication Date
JPH1175199A JPH1175199A (en) 1999-03-16
JP3234544B2 true JP3234544B2 (en) 2001-12-04

Family

ID=16949525

Family Applications (1)

Application Number Title Priority Date Filing Date
JP23308297A Expired - Fee Related JP3234544B2 (en) 1997-08-28 1997-08-28 Image encoding apparatus and image encoding method

Country Status (1)

Country Link
JP (1) JP3234544B2 (en)

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
テレビジョン学会編,「MPEG」,初版,オーム社,平成8年4月,p.94−96

Also Published As

Publication number Publication date
JPH1175199A (en) 1999-03-16

Similar Documents

Publication Publication Date Title
US8290288B2 (en) Encoding macroblock type and coded block pattern information
US5946043A (en) Video coding using adaptive coding of block parameters for coded/uncoded blocks
US5453799A (en) Unified motion estimation architecture
CA2218865A1 (en) Hybrid hierarchical/full-search mpeg encoder motion estimation
US6795498B1 (en) Decoding apparatus, decoding method, encoding apparatus, encoding method, image processing system, and image processing method
US6016365A (en) Decoder having adaptive function of eliminating block effect
JPH0846969A (en) System for encoding video signal
JPH08298665A (en) Circuit and method for detecting motion vector
JP3599942B2 (en) Moving picture coding method and moving picture coding apparatus
JP3234544B2 (en) Image encoding apparatus and image encoding method
JP2000261809A (en) Image coder coping with feature of picture
JP2868445B2 (en) Moving image compression method and apparatus
JP4359273B2 (en) Coding mode selection method
JP3240737B2 (en) Image signal encoding method and apparatus, decoding method and apparatus
JP4359274B2 (en) Video compression encoding device
JP4353928B2 (en) Data compression method, recording method, and transmission method
JPH08205171A (en) Dynamic image encoding device
KR100210124B1 (en) Data deformatting circuit of picture encoder
JPH10178643A (en) Signal compressing device
JPH11215505A (en) Dynamic image coder and dynamic image coding method
WO2002001848A2 (en) System and method for reducing the computational complexity of mpeg video decoding

Legal Events

Date Code Title Description
FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20070921

Year of fee payment: 6

FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20080921

Year of fee payment: 7

FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20090921

Year of fee payment: 8

LAPS Cancellation because of no payment of annual fees