JP2629409B2 - Motion compensated prediction interframe coding device - Google Patents

Motion compensated prediction interframe coding device

Info

Publication number
JP2629409B2
JP2629409B2 JP16052090A JP16052090A JP2629409B2 JP 2629409 B2 JP2629409 B2 JP 2629409B2 JP 16052090 A JP16052090 A JP 16052090A JP 16052090 A JP16052090 A JP 16052090A JP 2629409 B2 JP2629409 B2 JP 2629409B2
Authority
JP
Japan
Prior art keywords
step size
signal
quantization step
block
coding
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 - Lifetime
Application number
JP16052090A
Other languages
Japanese (ja)
Other versions
JPH0451689A (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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial 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 Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP16052090A priority Critical patent/JP2629409B2/en
Priority to US07/597,853 priority patent/US5144426A/en
Publication of JPH0451689A publication Critical patent/JPH0451689A/en
Priority to US08/298,684 priority patent/USRE37091E1/en
Application granted granted Critical
Publication of JP2629409B2 publication Critical patent/JP2629409B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Description

【発明の詳細な説明】 産業上の利用分野 本発明は、テレビジョン信号の動き補償予測フレーム
間符号化装置に関する。
Description: BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a motion-compensated prediction interframe coding apparatus for a television signal.

従来の技術 近年、動画像符号化技術の発達に伴い、テレビ電話、
テレビ会議システム、CD-ROM、ディジタルVTR等で用い
られるカラー動画像の高能率符号化装置として、動き補
償予測フレーム間符号化装置が開発されている。例え
ば、吹抜敬彦著「TV画像の多次元信号処理」(1988年11
月15日発行、日刊工業新聞社刊、第7章高能率符号化、
pp213-pp291)に記載された動き補償予測フレーム間符
号化装置が知られている。
2. Description of the Related Art In recent years, with the development of video coding technology, videophones,
2. Description of the Related Art A motion-compensated predictive interframe coding apparatus has been developed as a high-efficiency coding apparatus for color moving images used in a video conference system, a CD-ROM, a digital VTR, and the like. For example, Norihiko Fuukiki, “Multidimensional Signal Processing of TV Images” (November 1988
Published on March 15th, published by Nikkan Kogyo Shimbun, Chapter 7, High Efficiency Coding,
pp213-pp291) are known.

動き補償予測フレーム間符号化装置では、一定のフレ
ームレートで映像符号化が実現できるように、発生符号
量が多い場合には予測誤差または入力テレビジョン信号
の画素値の量子化ステップサイズを大きくして発生する
符号量を制限している。従来の量子化ステップサイズの
決定方式として、シー.シー.アイ.ティ.ティ エス
ジーエックスブイ文書#525(C.C.I.T.T.SGXV文書#525
“title:Discription of Ref.Mode 18(RM8),source:W
orking Party XV/4 Specialist Group On Coding for V
isual Telephony,version:June.9.1989")に記載された
動き補償予測フレーム間符号化装置が知られている。
In the motion-compensated prediction interframe encoding device, when the generated code amount is large, the prediction error or the quantization step size of the pixel value of the input television signal is increased so that video encoding can be performed at a constant frame rate. Is limited. As a conventional quantization step size determination method, C.I. C. Eye. T. TSGXV Document # 525 (CCITTSGXV Document # 525
“Title: Discription of Ref.Mode 18 (RM8), source: W
orking Party XV / 4 Specialist Group On Coding for V
There is known a motion-compensated predictive interframe coding apparatus described in "Isual Telephony, version: June. 9.1989").

以下、第2図を参照しながら、従来の動き補償予測フ
レーム間符号化装置について説明する。
Hereinafter, a conventional motion compensated prediction interframe coding apparatus will be described with reference to FIG.

第2図において、51は入力テレビジョン信号が入力す
る入力端子、53は現フレームの符号化ブロックの画信号
と前フレームの再生画信号を比較して符号化ブロックの
動ベクトルを算出する動ベクトル算出部、54は現フレー
ムと前フレームの再生画信号を蓄積する画像メモリ部、
58は前フレームの再生画信号に対して動き補償予測する
動き補償予測部、60は符号化するブロックをフレーム内
符号化するかフレーム間符号化するか判定するフレーム
間・フレーム内判定部、62は動き補償予測信号に対して
2次元ローパスフィルタ処理するループ内フィルタ部、
64は符号化ブロックの原画信号と予測信号の差分演算を
行い予測誤差を算出する予測誤差算出部、66は符号化方
式選択信号により直交変換する信号の選択と再生画像を
算出するための信号の選択を行うスイッチ部、68は直交
変換する信号を直交変換する直交変換部、70は直交変換
係数を量子化する量子化部、73は量子化ステップサイズ
を算出する量子化ステップサイズ算出部、74は伝送フレ
ームを一時蓄積する符号メモリ部、76は量子化した直交
変換係数を逆直交変換する逆直交変換部、78は現フレー
ムの再生画像を算出する再生画像算出部、82は予測誤差
を通信路符号化する予測誤差符号化部、84は動ベクトル
を通信路符号化する動ベクトル符号化部、86は予測符号
と動ベクトル符号より伝送フレームを構成するマルチプ
レクサ部、89は伝送信号を出力する出力端子である。
In FIG. 2, reference numeral 51 denotes an input terminal to which an input television signal is input, and 53, a motion vector for calculating a motion vector of the coding block by comparing the picture signal of the coding block of the current frame and the reproduced picture signal of the previous frame. A calculating unit, 54 is an image memory unit that stores the reproduced image signals of the current frame and the previous frame,
58 is a motion compensation prediction unit that performs motion compensation prediction on the reproduced image signal of the previous frame, 60 is an inter-frame / intra-frame determination unit that determines whether a block to be encoded is to be intra-frame or inter-frame encoded, 62 Is a filter unit in a loop that performs a two-dimensional low-pass filter process on the motion compensated prediction signal,
64 is a prediction error calculation unit that calculates a prediction error by performing a difference operation between the original image signal and the prediction signal of the coding block, and 66 is a signal that is used to select a signal to be orthogonally transformed by the coding method selection signal and calculate a reproduced image. A switch unit for selecting, 68, an orthogonal transform unit for orthogonally transforming a signal to be orthogonally transformed, 70, a quantizer for quantizing orthogonal transform coefficients, 73, a quantization step size calculator for calculating a quantization step size, 74 Is a code memory unit that temporarily stores transmission frames, 76 is an inverse orthogonal transform unit that inversely orthogonally transforms the quantized orthogonal transform coefficients, 78 is a reproduced image calculation unit that calculates the reproduced image of the current frame, and 82 is a communication of the prediction error. A prediction error encoding unit for channel coding, 84 is a motion vector encoding unit for channel coding a motion vector, 86 is a multiplexer unit for forming a transmission frame from the prediction code and the motion vector code, and 89 is a transmission signal. Which is an output terminal for power.

以上のような構成において、以下その動作について説
明する。
The operation of the above configuration will be described below.

図示されていないアナログ・ディジタル変換回路でデ
ィジタル信号に変換され、水平方向M画素、垂直方向N
ラインのブロックに分割されたテレビジョン信号は、入
力端子51より入力テレビジョン信号52として入力する。
The signal is converted into a digital signal by an analog / digital conversion circuit (not shown).
The television signal divided into the line blocks is input from an input terminal 51 as an input television signal 52.

動ベクトル算出部53は、入力テレビジョン信号52と画
像メモリ部54に蓄積されている前フレームの再生テレビ
ジョン信号55を比較し、符号化ブロックの動きを動ベク
トルとして算出し、動ベクトル信号56に出力する。同時
に動ベクトル算出部53は、動ベクトル算出時の評価値を
用いて、符号化ブロックについて動き補償予測の有効・
無効を判定し、その結果を動き補償予測制御信号として
動ベクトル信号56に出力する。従って、動ベクトル信号
56には、動ベクトルと動き補償予測信号が重畳されてい
る。
The motion vector calculation unit 53 compares the input television signal 52 with the reproduction television signal 55 of the previous frame stored in the image memory unit 54, calculates the motion of the encoded block as a motion vector, and calculates a motion vector signal 56. Output to At the same time, the motion vector calculation unit 53 uses the evaluation value at the time of calculating the motion vector to
It determines the invalidity and outputs the result to the motion vector signal 56 as a motion compensation prediction control signal. Therefore, the motion vector signal
In 56, a motion vector and a motion compensation prediction signal are superimposed.

動き補償予測部58は、(1)動き補償予測制御信号が
動き補償予測の有効を指示している場合には、前フレー
ムの再生テレビジョン信号55を動ベクトルで動き補償予
測し、(2)動き補償予測制御信号が動き補償予測の無
効を指示している場合には、前フレームの再生テレビジ
ョン信号55をそのまま動き補償予測信号59として出力す
る。
The motion compensation prediction unit 58 performs (1) motion compensation prediction of the reproduced television signal 55 of the previous frame with a motion vector when the motion compensation prediction control signal indicates that the motion compensation prediction is valid, and (2) When the motion compensation prediction control signal indicates that the motion compensation prediction is invalid, the reproduced television signal 55 of the previous frame is output as it is as the motion compensation prediction signal 59.

フレーム間・フレーム内判定部60は、ブロック単位に
入力テレビジョン信号52と動き補償予測信号59を比較
し、動き補償予測の有効性を判定し、動き補償予測の有
効性が小さい場合は該当ブロックについてフレーム内符
号化が有効と判定し、動き補償予測の有効性が大きい場
合は該当ブロックについてフレーム間符号化が有効と判
定し、その結果を符号化方式選択信号61として出力す
る。ブロック単位に符号化方式をフレーム内符号化方式
とフレーム間符号化方式で切り替えることにより、フレ
ーム間符号化方式のみで符号化する場合に比べ、以下の
改善が図れる。
The inter-frame / intra-frame determination unit 60 compares the input television signal 52 and the motion compensation prediction signal 59 in block units, determines the validity of the motion compensation prediction, and if the effectiveness of the motion compensation prediction is small, the corresponding block Is determined to be valid, and if the effectiveness of motion compensation prediction is high, it is determined that interframe coding is valid for the corresponding block, and the result is output as a coding method selection signal 61. By switching the coding method between the intra-frame coding method and the inter-frame coding method on a block-by-block basis, the following improvements can be achieved as compared with the case of coding using only the inter-frame coding method.

即ち、(1)シーンチェンジ発生時、フレーム内符号
化が選択されるためにシーンチェンジ後の画質向上が図
れる。(2)動体の大きな動きが発生すると、動体の陰
に隠れていた背景領域が出現し、この場合にフレーム内
符号化が選択されるために、画質向上が図れる。また、
CD-ROM等に用いる蓄積系メディア符号化方式では、再生
画像の編集機能や逆方向再生機能を実現するために、一
定フレーム周期毎に全ブロックをフレーム内符号化した
フレーム(このフレームを、「リフレッシュ・フレーム
(Refresh Frame)」と呼ぶ。)を挿入する必要があ
り、動き補償予測フレーム間符号化装置にフレーム内符
号化機能を具備することによりリフレッシュ・フレーム
の挿入が実現できる。
That is, (1) when a scene change occurs, intra-frame encoding is selected, so that image quality after the scene change can be improved. (2) When a large motion of the moving object occurs, a background area hidden behind the moving object appears. In this case, since the intra-frame encoding is selected, the image quality can be improved. Also,
In a storage media coding method used for a CD-ROM or the like, in order to realize a function of editing a reproduced image and a function of reproducing in the backward direction, a frame in which all blocks are intra-coded at a fixed frame period (this frame is referred to as “ It is necessary to insert a refresh frame, and the insertion of a refresh frame can be realized by providing the motion-compensated inter-frame coding apparatus with an intra-frame coding function.

ループ内フィルタ部62は動ベクトルを用いて動き補償
予測した符号化ブロックに対して、2次元ローパスフィ
ルタ処理を行い、予測信号63を算出する。予測誤差算出
部64は、符号化ブロックの入力テレビジョン信号52と予
測信号63の差分演算を行い、その結果を予測誤差信号65
として出力する。
The in-loop filter unit 62 performs a two-dimensional low-pass filter process on the coded block motion-compensated and predicted using the motion vector, and calculates a predicted signal 63. The prediction error calculation unit 64 performs a difference operation between the input television signal 52 of the coding block and the prediction signal 63, and outputs the result to the prediction error signal 65.
Output as

スイッチ部66は、(1)符号化方式選択信号61がフレ
ーム内符号化を選択している場合には、直交変換する信
号67として入力テレビジョン信号52を選択し、(2)符
号化方式選択信号61がフレーム間符号化を選択している
場合には、直交変換する信号67として予測誤差信号65を
選択する。
The switch unit 66 selects (1) the input television signal 52 as the signal 67 to be orthogonally transformed when the encoding method selection signal 61 selects the intra-frame encoding, and (2) the encoding method selection. When the signal 61 selects the inter-frame coding, the prediction error signal 65 is selected as the signal 67 to be orthogonally transformed.

直交変換部68は、直交変換する信号67に対して直交変
換を行い、直交変換する信号67の近傍画素間が持つ高い
相関性を除去して、直交変換係数69を算出する。直交変
換方式としては、多くの場合、高い変換効率を持ち、ハ
ードウェア化について実現性のある離散コサイン変換が
用いられる。
The orthogonal transformation unit 68 performs orthogonal transformation on the signal 67 to be orthogonally transformed, removes high correlation between neighboring pixels of the signal 67 to be orthogonally transformed, and calculates an orthogonal transformation coefficient 69. In many cases, as the orthogonal transform method, a discrete cosine transform that has high conversion efficiency and is feasible in terms of hardware is used.

量子化部70は、量子化ステップサイズ71を用いて直交
変換係数69を量子化し、直交変換量子化係数72を算出す
る。
The quantization unit 70 quantizes the orthogonal transform coefficient 69 using the quantization step size 71, and calculates an orthogonal transform quantized coefficient 72.

量子化ステップサイズ算出部73は、以下に示した方式
により、符号メモリ部74内の残留符号量75より量子化ス
テップサイズ71を算出する。
The quantization step size calculation unit 73 calculates the quantization step size 71 from the residual code amount 75 in the code memory unit 74 by the following method.

以下に、本従来例における量子化ステップサイズ71の
算出方法について記述する。
Hereinafter, a method of calculating the quantization step size 71 in the conventional example will be described.

この従来例では、入力テレビジョン信号は第3図に示
すように、水平方向352画素、垂直方向288ラインの大き
さを有し、水平方向16画素、垂直方向16ラインの領域
(「マクロブロック(Macro Block)」と呼んでい
る。)に分割されている。量子化ステップサイズQbは、
nマクロブロック周期で、量子化開始時に第(1)式よ
り算出する。
In this conventional example, as shown in FIG. 3, the input television signal has a size of 352 pixels in the horizontal direction and 288 lines in the vertical direction, and an area of 16 pixels in the horizontal direction and 16 lines in the vertical direction (“macro block ( Macro Block).) The quantization step size Qb is
It is calculated from equation (1) at the start of quantization in n macroblock periods.

Qb=2×INT[Bcont÷200q]+2 ……(1) 但し、第(1)式において以下のように定義する。Qb = 2 × INT [Bcont ÷ 200q] +2 (1) However, in Expression (1), it is defined as follows.

(a)INT[*]は小数点を切り捨てる関数とする。(A) INT [*] is a function that rounds down the decimal point.

例:INT[1.5]=1、INT[1.3]=1、INT[1.6]=1 (b)Bcontは符号メモリ部74の残留符号量を示す。Example: INT [1.5] = 1, INT [1.3] = 1, INT [1.6] = 1 (b) Bcont indicates the residual code amount of the code memory unit 74.

(c)qは、符号化速度パラメータであり、符号化速度
Vと第(2)式の関係がある。
(C) q is a coding speed parameter, and has a relationship with the coding speed V according to the expression (2).

V=q×64kbit/sec ……(2) 例:V=q×64kbit/secの時、q=1となる。V = q × 64 kbit / sec (2) Example: When V = q × 64 kbit / sec, q = 1.

第(1)式より明らかなように、残留符号量Bcontが多
くなると、量子化ステップサイズQbが大きくなり発生符
号量が制限され、一定フレームレートの映像信号符号化
が実現できる。例えば、量子化ステップサイズQbの算出
時に、残留符号量Bcont=700bitのときは、量子化ステ
ップサイズQb=8となり、残留符号量Bcont=6100bitの
ときは、量子化ステップサイズQb=62となる。ただし、
第1マクロブロックから第(n−1)マクロブロックま
では予め定めた量子化ステップサイズQbで量子化を行
う。例えば、V=64kbit/sec(q=1)の場合、Qb=32
とする。
As is clear from the equation (1), when the residual code amount Bcont increases, the quantization step size Qb increases, the generated code amount is limited, and video signal encoding at a constant frame rate can be realized. For example, when calculating the quantization step size Qb, when the residual code amount Bcont = 700 bits, the quantization step size Qb = 8, and when the residual code amount Bcont = 6100 bits, the quantization step size Qb = 62. However,
From the first macroblock to the (n-1) th macroblock, quantization is performed with a predetermined quantization step size Qb. For example, when V = 64 kbit / sec (q = 1), Qb = 32
And

本従来例では、量子化ステップサイズQbの算出周期n
は、n=12としている。
In this conventional example, the calculation cycle n of the quantization step size Qb is n
Is n = 12.

逆直交変換部76は、直交変換量子化係数72を逆直交変
換し、量子化誤差を含んだ直交変換した信号77を算出す
る。
The inverse orthogonal transform unit 76 performs an inverse orthogonal transform on the orthogonal transform quantization coefficient 72, and calculates an orthogonally transformed signal 77 including a quantization error.

スイッチ部66は、(1)符号化方式選択信号61がフレ
ーム内符号化を選択している場合には再生画像算出信号
79として数値「0」信号80を選択し、(2)符号化方式
選択信号61がフレーム間符号化を選択している場合には
再生画像算出信号79として予測信号63を選択する。
The switch unit 66 provides a (1) reproduced image calculation signal when the encoding method selection signal 61 selects intra-frame encoding.
The numerical value “0” signal 80 is selected as 79, and (2) the prediction signal 63 is selected as the reproduced image calculation signal 79 when the encoding method selection signal 61 selects the inter-frame encoding.

再生画像算出部78は量子化誤差を含んだ直交変換した
信号77と再生画像算出信号79を加算し、符号化ブロック
の再生画像81を算出する。
The reproduced image calculation unit 78 adds the orthogonally transformed signal 77 including the quantization error and the reproduced image calculation signal 79 to calculate the reproduced image 81 of the encoded block.

画像メモリ44は現フレームの再生画像信号81を蓄積
し、前フレームの再生画像信号55を出力する。予測誤差
符号化部82は直交変換量子化係数72、量子化ステップサ
イズ71、符号化方式選択信号61を符号化し、予測誤差符
号83を算出する。量子化ステップサイズ71の符号化は、
量子化ステップサイズ71の値が変化したとき、即ちnマ
クロブロックに1回のみとする。
The image memory 44 stores the reproduced image signal 81 of the current frame and outputs the reproduced image signal 55 of the previous frame. The prediction error encoding unit 82 encodes the orthogonal transform quantization coefficient 72, the quantization step size 71, and the encoding method selection signal 61, and calculates a prediction error code 83. The encoding of the quantization step size 71 is
When the value of the quantization step size 71 changes, that is, only once for n macroblocks.

動ベクトル符号化部84は動ベクトル信号56を符号化
し、動ベクトル符号85を算出する。マルチプレクサ部86
は予測誤差符号83と動ベクトル符号85より、所定の形式
の伝送フレーム87を算出する。
The motion vector encoding unit 84 encodes the motion vector signal 56 and calculates a motion vector code 85. Multiplexer unit 86
Calculates a transmission frame 87 of a predetermined format from the prediction error code 83 and the motion vector code 85.

符号メモリ部74は伝送フレーム87を一旦蓄積し、図示
していない外部より入力するクロック信号に同期して、
伝送符号88として出力端子89より出力する。同時に、符
号メモリ部74はメモリ内に残留している符号量を残留符
号量75として算出する。
The code memory unit 74 temporarily stores the transmission frame 87 and synchronizes with a clock signal input from outside (not shown),
It is output from an output terminal 89 as a transmission code 88. At the same time, the code memory unit 74 calculates the code amount remaining in the memory as a residual code amount 75.

発明が解決しようとする課題 しかし、以上のような構成では、量子化ステップサイ
ズQbが、量子化ステップサイズを算出するブロック周期
間(従来例では、nマクロブロック周期間)は固定され
るために、連続したnブロック間は入力テレビジョン信
号の持つ特徴に拘らず、同一の量子化ステップサイズQb
で量子化した直交変換係数が量子化される。即ち、同一
の量子化ステップサイズ周期に属する連続したブロック
内で、フレーム内符号化する精微なパターンを持つブロ
ックが、他のブロックと同じ量子化ステップサイズQbで
量子化されるために、フレーム内符号化した精微なパタ
ーンを持つブロックの画質が劣化するという問題があっ
た。
However, in the above configuration, the quantization step size Qb is fixed between block periods for calculating the quantization step size (in the conventional example, between n macroblock periods). , The same quantization step size Qb between successive n blocks regardless of the characteristics of the input television signal
The quantized orthogonal transform coefficients are quantized. That is, in a continuous block belonging to the same quantization step size cycle, a block having a fine pattern to be intra-frame encoded is quantized with the same quantization step size Qb as other blocks, so that the intra-frame There is a problem that the image quality of a block having an encoded fine pattern is deteriorated.

すなわち、フレーム内符号化した精微なパターンを持
つブロックより発生する直交変換係数を、大きな量子化
ステップサイズで量子化することにより、原画像の持つ
精微性が失われ、平坦なブロックとなる「ブロック歪
み」が発生し、視覚的に大きな画質劣化として認識され
ていた。
That is, by quantizing an orthogonal transform coefficient generated from a block having a fine pattern encoded in a frame with a large quantization step size, the fineness of the original image is lost, and the “block” becomes a flat block. “Distortion” occurred and was visually recognized as a large deterioration in image quality.

一方、量子化ステップサイズを符号化して発生する符
号量を削減するために、同一の量子化ステップサイズで
量子化する連続したブロック数は一定値以上でなければ
ならない(従来例では、nマクロブロック)ので、毎ブ
ロックごとに量子化ステップサイズを算出して変更する
ことはできない。
On the other hand, in order to reduce the amount of code generated by encoding the quantization step size, the number of consecutive blocks quantized with the same quantization step size must be equal to or greater than a certain value (in the conventional example, n macro blocks ), The quantization step size cannot be calculated and changed for each block.

本発明は、以上のような課題に鑑み、輝度信号ブロッ
クであり、かつフレーム内符号化するブロックについ
て、発生符号量より算出した基準となる第1の量子化ス
テップサイズで量子化される連続したブロックで、画素
値の平均値が一定値以上であるとき該当ブロックの持つ
画像的な精微性に比例して、第1の量子化ステップサイ
ズから、第2の量子化ステップサイズを算出し、第2の
量子化ステップサイズを用いて、直交変換係数を量子化
することにより、原画像の精微性を保持し、その結果と
して画質の向上を図ることを目的とする。
The present invention has been made in view of the above-described problems, and is a luminance signal block, and for a block to be intra-coded, continuous blocks quantized at a first quantization step size serving as a reference calculated from a generated code amount. In the block, when the average value of the pixel values is equal to or more than a certain value, a second quantization step size is calculated from the first quantization step size in proportion to the image definition of the block. It is an object of the present invention to quantize orthogonal transform coefficients using a quantization step size of 2, thereby maintaining the definition of the original image and improving the image quality as a result.

即ち、フレーム内符号化する輝度信号ブロックの画素
値の平均値が一定値以上であり、かつ精微性が高いブロ
ックは、実際の量子化ステップサイズを、基準となる量
子化ステップサイズより小さくすることで、発生符号量
は制限しつつ、精微性を保持し、その結果としてブロッ
クの画質を向上させることができる。
That is, for a block having an average pixel value of a luminance signal block to be encoded in a frame that is equal to or more than a certain value and having high precision, the actual quantization step size is set to be smaller than the reference quantization step size. Thus, it is possible to maintain the fineness while limiting the generated code amount, and as a result, it is possible to improve the image quality of the block.

また、第1の量子化ステップサイズが一定値以上であ
るときは、第2の量子化ステップサイズを算出するため
の閾値を補正することにより、輝度信号の符号量を削減
し色差信号の符号量を増加させ、色差信号の符号量が極
端に少ないことによって生じる符号化ブロックの色の劣
化を防ぐことができる。結果として画像全体の画質向上
が達成できる。
Further, when the first quantization step size is equal to or larger than a certain value, the code amount of the luminance signal is reduced by correcting the threshold value for calculating the second quantization step size, and the code amount of the chrominance signal is reduced. Can be increased, and the color degradation of the coded block caused by the extremely small code amount of the color difference signal can be prevented. As a result, the image quality of the entire image can be improved.

課題を解決するための手段 この目的を達成するために、本発明は、テレビジョン
信号をアナログディジタル変換するA/D変換手段と、デ
ィジタル化した入力テレビジョン信号の1フレームまた
は1フィールドを定められた大きさのブロックに分割す
るブロック化手段と、個々のブロックについてテレビジ
ョン画像の動きである動ベクトルを算出する動ベクトル
検出手段と、個々のブロックについて動ベクトルを用い
て動き補償予測するか判定する動き補償判定手段と、動
き補償予測するブロックについて、前フレームの再生画
像を動ベクトルで動き補償予測し、予測画素値を算出す
る動き補償予測手段と、入力テレビジョン信号の画素値
と予測画素値との差分を予測誤差値として算出する誤差
算出手段と、個々のブロックについて、フレーム間符号
化するかフレーム内符号化するかを判定する符号化方法
決定手段と、ブロック毎に符号化方法決定手段の判定結
果により、直交変換する信号を入力テレビジョン信号の
画素値とするか予測誤差値とするか切り替える切り替え
手段と、入力テレビジョン信号の画素値または予測誤差
値を、直交変換し、直交変換係数を算出する直交変換手
段と、発生符号量より第1の量子化ステップサイズを算
出する第1量子化ステップサイズ決定手段と、入力テレ
ビジョン信号の輝度信号のブロック毎の画素値の平均と
分散を算出する平均・分散算出手段と、輝度信号ブロッ
クであり、かつフレーム内符号化するブロックを平均ま
たは分散によってクラス分けするために予め定められた
閾値を第1の量子化ステップサイズによって補正する手
段と、輝度信号のブロックでありかつフレーム内符号化
するブロックについては、平均と分散と補正された閾値
よりブロックをクラス分けし、各クラス毎に第1の量子
化ステップサイズより第2の量子化ステップサイズを算
出し、その他のブロックについては、第1の量子化ステ
ップサイズを第2の量子化ステップサイズとする第2量
子化ステップサイズ決定手段と、第2の量子化ステップ
サイズを用いて、直交変換係数を量子化し、量子化した
直交変換係数を算出する量子化手段と、フレーム内符号
化かフレーム間符号化かの情報と、第1の量子化ステッ
プサイズと量子化のクラス分けに関する情報と、量子化
した直交変換係数を符号化する符号化手段と。量子化し
た直交変換係数を逆直交変換し、逆量子化信号を算出す
る逆量子化手段と、符号化方法決定手段の判定結果によ
り再生画素値算出時に用いる画素値を動き補償予測した
予測画素値とするか、数値「0」とするか切り替える切
り替え手段と、予測画素値または数値「0」と逆量子化
信号より再生画像を算出する画像再生手段と、再生画像
を蓄積する画像蓄積手段と、動ベクトルとを符号化する
動ベクトル符号化手段を設けるように構成されている。
Means for Solving the Problems In order to achieve this object, the present invention provides an A / D converter for converting a television signal from analog to digital, and one frame or one field of a digitized input television signal. Means for dividing a block into blocks having different sizes, a motion vector detecting means for calculating a motion vector which is a motion of a television image for each block, and determining whether motion compensation prediction is performed using a motion vector for each block. Compensation prediction means for performing motion compensation prediction on a reproduced image of a previous frame with a motion vector for a block to be compensated for motion, and calculating a prediction pixel value; and a pixel value and a prediction pixel value of an input television signal. Error calculating means for calculating a difference from the predicted value as a prediction error value; An encoding method determining unit that determines whether to perform encoding or intra-frame encoding, and a determination result of the encoding method determining unit for each block, which determines whether a signal to be orthogonally transformed is a pixel value of an input television signal or a prediction error. Switching means for switching to a value, an orthogonal transformation means for orthogonally transforming a pixel value or a prediction error value of an input television signal and calculating an orthogonal transformation coefficient, and calculating a first quantization step size from a generated code amount A first quantization step size determining means, an average and variance calculating means for calculating an average and a variance of a pixel value of each block of the luminance signal of the input television signal, and a luminance signal block, and performing intra-frame encoding. Means for correcting a predetermined threshold for classifying the blocks by average or variance by a first quantization step size; , And for intra-frame coding, the blocks are classified into classes based on the average, the variance, and the corrected threshold value, and the second quantization step size is calculated for each class from the first quantization step size. For the other blocks, a second quantization step size determining unit that sets the first quantization step size to a second quantization step size, and an orthogonal transformation coefficient using the second quantization step size are used. Quantizing means for quantizing and calculating a quantized orthogonal transform coefficient, information on intra-frame coding or inter-frame coding, information on a first quantization step size and classification of quantization, Encoding means for encoding the orthogonal transform coefficients thus obtained. Inverse quantization means for inversely orthogonally transforming the quantized orthogonal transform coefficients to calculate an inverse quantization signal; and a prediction pixel value obtained by motion compensation prediction of a pixel value used in calculating a reproduction pixel value based on a determination result of the encoding method determination means. Or a switching means for switching between a numerical value “0”, an image reproducing means for calculating a reproduced image from a predicted pixel value or a numerical value “0” and an inversely quantized signal, and an image storing means for accumulating the reproduced image. It is configured to provide a motion vector encoding means for encoding a motion vector.

作用 本発明は、上記構成により、入力テレビジョン信号の
持つブロック毎の精微性は、ブロック内の画素値の分散
σで測定できると考えられる。例えば、精微なパター
ンを持つブロックの分散σは、急峻な画素値の変化を
持つ「粗い」ブロックの分散σに比べ小さいと考えら
れる。また精微性の高いブロックほど分散σが小さく
なると考えられる。
Operation According to the present invention, it is considered that the fineness of each block of the input television signal can be measured by the variance σ 2 of the pixel values in the block by the above configuration. For example, the variance σ 2 of a block having a fine pattern is considered to be smaller than the variance σ 2 of a “coarse” block having a sharp change in pixel value. Also, it is considered that the variance σ 2 becomes smaller as the block has higher definition.

また、分散が小さいブロックであっても、画素値の平
均値が一定値より小さいときには、精微性が高くとも視
覚的にほとんど目立たないブロックであるといえる。
Also, even if the block has a small variance, when the average value of the pixel values is smaller than a certain value, it can be said that the block is hardly visually noticeable even if the definition is high.

従って、本発明は上記構成により、入力テレビジョン
信号の輝度信号の持つブロック毎の精微性を分散σ
測定し、同一の基準となる第1の量子化ステップサイズ
で量子化する連続したブロックで、フレーム内符号化す
る精微な画像を有し、かつ画素値の平均値が一定値以上
であるブロックについては、第1の量子化ステップサイ
ズを、該当ブロックの画素値の平均と分散と第1の量子
化ステップサイズにより補正した閾値に応じて小さくし
た第2の量子化ステップサイズで直交変換係数を量子化
することにより、発生符号量を制限しつつ、精微な画像
を有するブロックの画質を向上することができるように
したものである。
Therefore, according to the present invention, with the above-described configuration, successive blocks which measure the fineness of each block of the luminance signal of the input television signal with the variance σ 2 and quantize with the same reference first quantization step size are used. For a block having a fine image to be intra-coded and having an average pixel value equal to or larger than a certain value, the first quantization step size is set to the average and variance of the pixel value of the block and the first quantization step size. By quantizing the orthogonal transform coefficients with the second quantization step size reduced according to the threshold value corrected by the quantization step size of 1, the image quality of a block having a fine image can be reduced while limiting the amount of generated code. It is something that can be improved.

実施例 以下、本発明の一実施例について図面を参照しながら
説明する。第1図は、本発明による動き補償予測フレー
ム間符号化装置の一実施例を示すブロック図である。
Embodiment Hereinafter, an embodiment of the present invention will be described with reference to the drawings. FIG. 1 is a block diagram showing an embodiment of a motion compensated prediction interframe coding apparatus according to the present invention.

1は入力テレビジョン信号が入力する入力端子、3は
現フレームの符号化ブロックの画信号と前フレームの再
生画信号を比較して符号化ブロックの動ベクトルと動き
補償予測制御信号を算出する動ベクトル算出部、4は現
フレームと前フレームの再生画信号を蓄積する画像メモ
リ部、7は前フレームの再生画信号に対して動き補償予
測する動き補償予測部、9は符号化するブロックをフレ
ーム間符号化するかフレーム内符号化するかを判定する
フレーム間・フレーム内判定部、11は動き補償予測信号
に対して2次元ローパスフィルタ処理するループ内フィ
ルタ部、13は符号化ブロックの原画信号と予測信号の差
分演算を行い予測誤差を算出する予測誤差算出部、15は
符号化方式選択信号により、直交変換する信号の選択と
再生画像を算出するための信号を選択するスイッチ部、
17は直交変換する直交変換部、19は直交変換係数を量子
化する量子化部、21は第2の量子化ステップサイズを算
出する第2量子化ステップサイズ算出部、22は第1の量
子化ステップサイズを算出する第1量子化サイズ算出
部、25は入力テレビジョン信号の平均と分散を算出する
平均・分散値算出部、28は伝送フレームを一時蓄積する
符号メモリ部、30は量子化した直交変換係数を逆直交変
換する逆直交変換部、34は現フレームの再生画像を算出
する再生画像算出部、36は符号化方式選択信号、予測誤
差、第1量子化ステップサイズ、および量子化クラス情
報を通信路符号化する予測誤差符号化部、38は動ベクト
ルを通信路符号化する動ベクトル符号化部、40は予測符
号と動ベクトル符号より伝送フレームを構成するマルチ
プレクサ部、43は伝送信号を出力する出力端子である。
Reference numeral 1 denotes an input terminal to which an input television signal is input, and reference numeral 3 denotes an operation for comparing the image signal of the encoded block of the current frame with the reproduced image signal of the previous frame to calculate a motion vector of the encoded block and a motion compensation prediction control signal. A vector calculation unit, 4 is an image memory unit that stores the reproduced image signals of the current frame and the previous frame, 7 is a motion compensation prediction unit that performs motion compensation prediction on the reproduced image signal of the previous frame, and 9 is a block that encodes the block to be encoded. An inter-frame / intra-frame determination unit for determining whether to perform inter-coding or intra-frame encoding; 11, an in-loop filter unit for performing a two-dimensional low-pass filter process on a motion compensation prediction signal; 13, an original image signal of an encoded block A prediction error calculation unit that calculates a prediction error by performing a difference operation between the prediction signal and the prediction signal, and selects a signal to be orthogonally transformed and calculates a reproduced image based on the encoding method selection signal. Switch unit for selecting a signal,
17 is an orthogonal transformation unit for orthogonal transformation, 19 is a quantization unit for quantizing orthogonal transformation coefficients, 21 is a second quantization step size calculation unit for calculating a second quantization step size, and 22 is the first quantization A first quantization size calculator for calculating a step size, 25 an average / variance value calculator for calculating the average and variance of the input television signal, 28 a code memory unit for temporarily storing transmission frames, and 30 a quantized An inverse orthogonal transform unit for performing an inverse orthogonal transform of the orthogonal transform coefficient; 34, a reproduced image calculating unit for calculating a reproduced image of the current frame; 36, a coding method selection signal, a prediction error, a first quantization step size, and a quantization class A prediction error encoding unit for channel-encoding information; 38, a motion vector encoding unit for channel-coding a motion vector; 40, a multiplexer unit for forming a transmission frame from the prediction code and the motion vector code; 43, a transmission signal To Which is an output terminal for power.

以上のような構成において、以下その動作を説明す
る。
The operation of the above configuration will be described below.

テレビジョン信号は、第1図に図示されていない信号
処理部でアナログ・ディジタル変換され、水平方向M画
素、垂直方向Nラインのブロックに分割され、入力端子
1より入力テレビジョン信号2として入力する。
The television signal is analog-to-digital converted by a signal processing unit (not shown in FIG. 1), divided into blocks of M pixels in the horizontal direction and N lines in the vertical direction, and input as an input television signal 2 from the input terminal 1. .

次に、動ベクトル算出部3は入力テレビジョン信号2
と、画像メモリ部4より読み出した前フレームの再生画
像5を比較し、動ベクトルを算出し、動ベクトル信号6
に出力する。同時に、動ベクトル算出部3は動ベクトル
算出時の評価値を用いて、符号化ブロックに対する動き
補償予測が有効か無効かを判定し、その結果を動き補償
予測制御情報として動ベクトル信号6に出力する。
Next, the motion vector calculation unit 3 calculates the input television signal 2
And the reproduced image 5 of the previous frame read from the image memory unit 4 to calculate a motion vector,
Output to At the same time, the motion vector calculation unit 3 determines whether the motion compensation prediction for the encoded block is valid or invalid using the evaluation value at the time of motion vector calculation, and outputs the result to the motion vector signal 6 as motion compensation prediction control information. I do.

動き補償予測部7は、符号化ブロックと同一位置の前
フレームの再生画像5に対し、動ベクトル信号6により
動き補償予測する場合は動ベクトルで動き補償予測し、
動き補償予測しない場合は何もせずに動き補償予測信号
8として出力する。
The motion compensation prediction unit 7 performs motion compensation prediction using a motion vector when performing motion compensation prediction on the reproduced image 5 of the previous frame at the same position as the encoded block using the motion vector signal 6,
If no motion compensation prediction is performed, the motion compensation prediction signal 8 is output without any operation.

フレーム間・フレーム内判定部9は、ブロック単位に
入力テレビジョン信号2と動き補償予測信号8を比較
し、動き補償予測の有効性を判定し、動き補償予測の有
効性が小さい場合は該当ブロックについてフレーム内符
号化が有効と判定し、動き補償予測の有効性が大きい場
合は該当ブロックについてフレーム間符号化が有効と判
定し、その結果を符号化方式選択信号10として出力す
る。また、フレーム内・フレーム間判定部9は、リフレ
ッシュフレームの挿入が必要な符号化装置の場合は、一
定フレーム周期で全ブロックをフレーム内符号化するよ
うに符号化方式選択信号10を出力する。
The inter-frame / intra-frame determination unit 9 compares the input television signal 2 and the motion compensation prediction signal 8 on a block-by-block basis to determine the effectiveness of the motion compensation prediction. Is determined to be valid, and if the effectiveness of motion compensation prediction is high, it is determined that interframe coding is valid for the corresponding block, and the result is output as a coding method selection signal 10. In the case of an encoding device that requires the insertion of a refresh frame, the intra-frame / inter-frame determination unit 9 outputs an encoding method selection signal 10 so that all blocks are intra-frame encoded at a fixed frame period.

ループ内フィルタ部11は、動き補償予測信号8に対
し、符号化ブロックが動き補償予測するブロックである
ときは2次元ローパスフィルタ処理であるループ内フィ
ルタ処理を行い、その他の場合はループ内フィルタ処理
しないで予測信号12として出力する。
The in-loop filter unit 11 performs in-loop filter processing, which is a two-dimensional low-pass filter processing, on the motion-compensated prediction signal 8 when the coding block is a block to be motion-compensated and predicted, and otherwise performs in-loop filter processing. Instead, it is output as the prediction signal 12.

予測誤差算出部13は、符号化ブロックの入力テレビジ
ョン信号2と予測信号12の差分演算を行い、その結果を
予測誤差信号14として出力する。
The prediction error calculation unit 13 performs a difference operation between the input television signal 2 of the coding block and the prediction signal 12, and outputs the result as a prediction error signal 14.

スイッチ部15は、(1)符号化方式選択信号10がフレ
ーム内符号化を選択している場合には直交変換する信号
16として入力テレビジョン信号2を選択し、(2)符号
化方式選択信号10がフレーム間符号化を選択している場
合には直交変換する信号16として予測誤差信号14を選択
する。
The switch unit 15 performs (1) a signal to be orthogonally transformed when the encoding method selection signal 10 selects intra-frame encoding.
The input television signal 2 is selected as 16 and (2) the prediction error signal 14 is selected as the signal 16 to be orthogonally transformed when the encoding method selection signal 10 has selected inter-frame encoding.

直交変換部17は、直交変換する信号16に対して直交変
換を行い、直交変換する信号16の近傍画素間が持つ高い
相関性を除去して、直交変換係数18を算出する。直交変
換方式としては、多くの場合、高い変換効率を持ち、ハ
ードウェア化について実現性のある離散コサイン変換が
用いられる。
The orthogonal transformation unit 17 performs orthogonal transformation on the signal 16 to be orthogonally transformed, removes high correlation between neighboring pixels of the signal 16 to be orthogonally transformed, and calculates an orthogonal transformation coefficient 18. In many cases, as the orthogonal transform method, a discrete cosine transform that has high conversion efficiency and is feasible in terms of hardware is used.

量子化部19は、第2の量子化ステップサイズ20で直交
変換係数18を量子化する。以下に、第2の量子化ステッ
プサイズ20の算出方法について記述する。
The quantization unit 19 quantizes the orthogonal transform coefficients 18 with a second quantization step size 20. Hereinafter, a method of calculating the second quantization step size 20 will be described.

(1)符号化するブロックが輝度信号ブロックではない
か、またはフレーム間符号化ブロックである場合 第2量子化ステップサイズ部21は、第1量子化ステッ
プサイズ算出部22が、前記の従来例に記述した方式によ
り残留符号量23より算出した第1の量子化ステップサイ
ズを第2の量子化ステップサイズとして出力する。
(1) When the block to be coded is not a luminance signal block or is an inter-frame coded block, the second quantization step size unit 21 determines whether the first quantization step size calculation unit 22 The first quantization step size calculated from the residual code amount 23 according to the described method is output as the second quantization step size.

(2)符号化するブロックが輝度信号ブロックであり、
かつフレーム内符号化ブロックである場合 以下に示した方式により、符号化ブロックの画素値の
平均と分散を算出し、算出した平均と分散より該当ブロ
ックをクラス分けし、各クラス毎に基準となる第1の量
子化ステップサイズより実際の量子化で用いる第2の量
子化ステップサイズを算出する。
(2) The block to be encoded is a luminance signal block,
In the case of an intra-coded block, the average and variance of the pixel values of the coded block are calculated by the method shown below, and the corresponding block is classified based on the calculated average and variance, which is a reference for each class. A second quantization step size used in actual quantization is calculated from the first quantization step size.

平均・分散値算出部25は、符号化ブロックの入力テレ
ビジョン信号2の画素値の平均値μと分散σを第
(3)および第(4)式により算出し、平均信号44、分
散信号26として出力する。平均μはブロックの精微性に
応じて第1ステップサイズを変化させるかどうかの判断
に用いる。
The average / dispersion value calculation unit 25 calculates the average value μ and the variance σ 2 of the pixel values of the input television signal 2 of the coding block according to the formulas (3) and (4), and calculates the average signal 44 and the variance signal. Output as 26. The average μ is used to determine whether to change the first step size according to the fineness of the block.

分散σは、入力テレビジョン信号2の精微性が高い
ブロックでは小さい値となり、入力テレビジョン信号2
の精微性が低いブロックでは大きい値となる。
The variance σ 2 has a small value in a block having high definition of the input television signal 2, and
The value is large in a block with low definition.

但し、第(3)および第(4)式において以下のよう
に定義する。
However, they are defined as follows in equations (3) and (4).

(a)Mはブロックの水平方向画素数を示す。(A) M indicates the number of pixels in the horizontal direction of the block.

(b)Nはブロックの垂直方向ライン数を示す。(B) N indicates the number of vertical lines in the block.

(c)P(i,j)はブロック内アドレス(i,j)の画素値
を示す。
(C) P (i, j) indicates the pixel value of the address (i, j) in the block.

第2量子化ステップサイズ算出部21は、符号化ブロッ
クの平均信号44と分散信号26と第1の量子化ステップサ
イズ24より、第2の量子化ステップサイズ20と量子化ク
ラス情報27を算出する。第1の量子化ステップサイズ24
は、第1量子化ステップサイズ算出部22で、符号メモリ
部28内の符号残留量23より、前記の従来例で記述した方
式により求めたものである。第2量子化ステップサイズ
算出部21は、まず第1の量子化ステップサイズによっ
て、予め定められた閾値を補正する。補正の方法は以下
の通りである。
The second quantization step size calculation unit 21 calculates the second quantization step size 20 and the quantization class information 27 from the average signal 44, the variance signal 26, and the first quantization step size 24 of the coding block. . First quantization step size 24
Is obtained by the first quantization step size calculation unit 22 from the code remaining amount 23 in the code memory unit 28 by the method described in the above conventional example. First, the second quantization step size calculation unit 21 corrects a predetermined threshold value based on the first quantization step size. The correction method is as follows.

第1の量子化ステップサイズQbと予め定められた閾値
thqを比較する。
First quantization step size Qb and predetermined threshold
Compare thq.

(1)Qb<=thqの時 クラス分けに使用する閾値th1,th2,th3,th4を補正せ
ずそのままとする。
(1) When Qb <= thq The thresholds th1, th2, th3, and th4 used for classification are left uncorrected.

(2)Qb>thqの時 クラス分けに使用する閾値th1,th2,th3,th4を次式に
より補正する。
(2) When Qb> thq The threshold values th1, th2, th3, and th4 used for classification are corrected by the following equation.

i=1,2,3,4 maxは量子化ステップサイズQbの最大値 量子化ステップサイズQbと閾値th1、th2、th3、th4の
関係図を第4図に示す。
i = 1, 2, 3, 4 max is the maximum value of the quantization step size Qb. FIG. 4 shows a relationship diagram between the quantization step size Qb and the threshold values th1, th2, th3, and th4.

次に輝度信号であり、かつフレーム内符号化するブロ
ックに関し、平均信号44、分散信号26と前記閾値th1、t
h2、th3、th4を比較し、各ブロックを4つの量子化クラ
スに分け、量子化クラスにより第1の量子化ステップサ
イズ24より第2の量子化ステップサイズ20を算出する。
但し、第1の量子化ステップサイズをQbとし、第2の量
子化ステップサイズをQstepとする。
Next, for a block that is a luminance signal and to be intra-coded, the average signal 44, the variance signal 26, and the thresholds th1, t
h2, th3, and th4 are compared, each block is divided into four quantization classes, and the second quantization step size 20 is calculated from the first quantization step size 24 by the quantization class.
Here, the first quantization step size is Qb, and the second quantization step size is Qstep.

(1)0≦σ<th1かつμ>th4の場合 Qstep Class=1 (2)th1≦σ<th2かつμ>th4の場合 Qstep Class=2 (3)th2≦σ<th3かつμ>th4の場合 Qstep Class=3 (4)th3≦σかつμ>th4の場合 Qstep Class=4 Qstep=Qb 以上のようにすることにより、輝度信号ブロックであ
り、かつフレーム内符号化するブロックの第2の量子化
ステップサイズ20は、入力テレビジョン信号2の画素の
平均値が一定値以上であり、かつ精微性が高いブロック
に対しては、第1の量子化ステップサイズ24より小さく
なる。また第1の量子化ステップサイズが一定値を越え
るときはクラス分けの閾値を補正することにより、第1
の量子化ステップサイズより小さい量子化ステップサイ
ズで量子化されるブロックを少なくし、輝度信号の符号
量を削減し、色差信号の符号量が極端に少ないことによ
って生じる符号化ブロックの色の劣化を防ぐことができ
る。
(1) When 0 ≦ σ 2 <th1 and μ> th4 Qstep Class = 1 (2) When th1 ≦ σ 2 <th2 and μ> th4 Qstep Class = 2 (3) When th2 ≦ σ 2 <th3 and μ> th4 Qstep Class = 3 (4) th3 by the ≦ sigma 2 cutlet mu> For th4 Qstep Class = 4 Qstep = Qb above, the luminance signal is a block, and the second quantization step size 20 of the block to be encoded frame Is smaller than the first quantization step size 24 for a block in which the average value of the pixels of the input television signal 2 is equal to or more than a certain value and the resolution is high. When the first quantization step size exceeds a certain value, the first threshold is corrected by correcting the classification threshold.
The number of blocks quantized with a quantization step size smaller than the quantization step size of the number of blocks is reduced, the code amount of the luminance signal is reduced, and the color deterioration of the coded block caused by the extremely small code amount of the color difference signal is reduced. Can be prevented.

量子化部19は、直交変換係数14を第2の量子化ステッ
プサイズ20で量子化し、直交変換量子化係数29を算出す
る。逆直交変換部30は、直交変換量子化係数29を逆直交
変換し、量子化誤差を含んだ信号31を算出する。
The quantization unit 19 quantizes the orthogonal transform coefficient 14 with the second quantization step size 20, and calculates an orthogonal transform quantized coefficient 29. The inverse orthogonal transform unit 30 performs an inverse orthogonal transform on the orthogonal transform quantization coefficient 29, and calculates a signal 31 including a quantization error.

スイッチ部16は、(1)符号化方式選択信号10がフレ
ーム内符号化を選択している場合には再生画像算出信号
32として数値「0」信号33を選択し、(2)符号化方式
選択信号10がフレーム間符号化を選択している場合には
再生画像算出信号32として予測信号12を選択する。
The switch unit 16 controls the (1) reproduced image calculation signal when the encoding method selection signal 10 selects intra-frame encoding.
The numerical value “0” signal 33 is selected as 32, and (2) the prediction signal 12 is selected as the reproduced image calculation signal 32 when the encoding method selection signal 10 has selected the inter-frame encoding.

再生画像算出部34は量子化誤差を含んだ信号31と再生
画像算出信号32を加算し、符号化ブロックの再生画像35
を算出する。画像メモリ4は現フレームの再生画像信号
35を蓄積し、前フレームの再生画像信号5を出力する。
The reproduced image calculation unit 34 adds the signal 31 including the quantization error and the reproduced image calculation signal 32 to generate a reproduced image 35 of the encoded block.
Is calculated. The image memory 4 stores a reproduced image signal of the current frame.
35, and outputs the reproduced image signal 5 of the previous frame.

予測誤差符号化部36は、符号化方式選択信号10、第1
の量子化ステップサイズ24、量子化クラス情報27、およ
び直交変換量子化係数25を符号化し、予測誤差符号37を
算出する。
The prediction error encoding unit 36 outputs the encoding method selection signal 10 and the first
, The quantization step size 24, the quantization class information 27, and the orthogonal transform quantization coefficient 25 are encoded, and a prediction error code 37 is calculated.

動ベクトル符号化部38は動き補償予測したブロックの
動ベクトル信号6を符号化し、動ベクトル符号39を算出
する。
The motion vector encoding unit 38 encodes the motion vector signal 6 of the motion-compensated block and calculates a motion vector code 39.

マルチプレクサ部40は予測誤差符号37と動ベクトル符
号39より、所定の形式の伝送フレーム41を算出する。
The multiplexer unit 40 calculates a transmission frame 41 of a predetermined format from the prediction error code 37 and the motion vector code 39.

符号メモリ部28は伝送フレーム41を、一旦蓄積し、図
示していない外部より入力するクロック信号に同期し
て、伝送符号42として出力端子43より出力する。同時
に、符号メモリ部28はメモリ内に残留している符号量を
残留符号量23として算出する。
The code memory unit 28 temporarily stores the transmission frame 41, and outputs the transmission frame 41 from the output terminal 43 as a transmission code 42 in synchronization with a clock signal input from the outside (not shown). At the same time, the code memory unit 28 calculates the code amount remaining in the memory as the residual code amount 23.

以上の説明から明らかなように、本実施例によれば、
輝度信号ブロックの符号化時に、同一の量子化ステップ
サイズに属する連続したブロック群において、フレーム
内符号化し、かつ画素値の平均値が一定値以上であるブ
ロックではブロックの精微性に比例して、基準となる第
1の量子化ステップサイズより、第2の量子化ステップ
サイズを算出し、第2の量子化ステップサイズを用いて
直交変換係数を量子化するので、画像の精微性を損なわ
ず、画像全体の画質向上が達成できる。
As is apparent from the above description, according to the present embodiment,
At the time of encoding a luminance signal block, in a continuous block group belonging to the same quantization step size, intra-frame encoding, and in a block in which the average value of pixel values is a certain value or more, in proportion to the fineness of the block, Since the second quantization step size is calculated from the reference first quantization step size, and the orthogonal transform coefficients are quantized using the second quantization step size, the fineness of the image is not impaired. The image quality of the entire image can be improved.

また、第1の量子化ステップサイズが一定値を越える
ときは、クラス分けのための閾値を補正することにより
第1の量子化ステップサイズより小さい量子化ステップ
サイズで量子化されるブロック数を削減し、輝度信号の
符号量を削減し、その結果、色差信号の符号量が増加
し、色差信号の符号量が極端に少ないことによって生じ
る符号化ブロックの色の劣化を防ぐことができる。
Further, when the first quantization step size exceeds a certain value, the number of blocks quantized with a quantization step size smaller than the first quantization step size is reduced by correcting a threshold for classifying. Then, the code amount of the luminance signal is reduced, and as a result, the code amount of the chrominance signal increases, and it is possible to prevent the deterioration of the color of the coded block caused by the extremely small code amount of the chrominance signal.

なお、以上の説明では平均・分散値算出部25で算出す
る分散値26を第(3)式で定義したが、入力テレビジョ
ン信号2の精細性を測定できる分散であれば、他の測定
尺度でもよい。例えば、一般にブロックの大きさ(水平
方向画素数:M、垂直方向ライン数:N)は固定値であるか
ら、計算処理が簡単な尺度として第(6)式に示した数
値Dがある。ただし、p(i,j)はブロック内アドレス
(i,j)の画素値、μはブロックの平均画素値を示す。
In the above description, the variance value 26 calculated by the average / variance value calculation unit 25 is defined by the equation (3). However, if the variance can measure the definition of the input television signal 2, any other measurement scale can be used. May be. For example, since the size of a block (the number of pixels in the horizontal direction: M, the number of lines in the vertical direction: N) is generally a fixed value, there is a numerical value D shown in Expression (6) as a scale for easily calculating. Here, p (i, j) indicates the pixel value of the address (i, j) in the block, and μ indicates the average pixel value of the block.

また、以上の説明では、第1の量子化ステップサイズ
を変化させるかどうかを画素値の平均値によって決定し
たが、全体の画素値の特徴を表現するその他の尺度でよ
い。
Further, in the above description, whether to change the first quantization step size is determined by the average value of the pixel values, but may be another measure expressing the characteristics of the entire pixel value.

更に、以上の説明では、量子化ステップサイズのクラ
ス分けを4クラスとしたが、他のクラス分け数でもよ
い。
Further, in the above description, the quantization step size is classified into four classes, but another classification number may be used.

更に、以上の説明では、クラス分け毎に基準となる第
1の量子化ステップサイズを等分し、第2の量子化ステ
ップサイズを決定したが、分散が小さいブロックに対し
て、第2の量子化ステップサイズが小さくなるように算
出されれば、他の方法でもよい。
Further, in the above description, the first quantization step size, which is a reference, is equally divided for each classification, and the second quantization step size is determined. Another method may be used as long as it is calculated so that the conversion step size is reduced.

更に、クラス分けのための閾値を(5)式によって補
正したが、量子化ステップサイズが大きくなるにつれて
閾値が小さくなるような他の補正の方法でもよい。
Further, the threshold value for classification is corrected by the equation (5), but another correction method may be used in which the threshold value decreases as the quantization step size increases.

発明の効果 以上のように本発明は、フレーム内符号化するブロッ
クの入力テレビジョン信号の持つ精微性に関する特徴を
測定し、同一の量子化ステップサイズで量子化する連続
したブロック群内で平均値が一定値以上であり、かつ精
微な絵柄を持つフレーム内符号化するブロックに対して
は、前記量子化ステップサイズを小さくすることによ
り、発生符号量は制限しつつ、原画像の持つ精微性を損
なうことなく動画像符号化が行えるために、画質の向上
を図ることが可能となる。
As described above, the present invention measures the characteristics related to the fineness of the input television signal of the block to be intra-coded, and calculates the average value within a continuous block group quantized with the same quantization step size. Is greater than or equal to a certain value, and for a block to be intra-coded having a fine picture, by reducing the quantization step size, the amount of generated code is restricted, and the fineness of the original image is reduced. Since video coding can be performed without loss, it is possible to improve image quality.

特に、リフレッシュフレームの画質改善効果が顕著で
ある。
In particular, the effect of improving the image quality of the refresh frame is remarkable.

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

第1図は本発明の一実施例における動き補償予測フレー
ム間符号化装置のブロック図、第2図は従来の動き補償
予測フレーム間符号化装置のブロック図、第3図は従来
例における画像とマクロブロックの関係を示した概念
図、第4図は本発明の一実施例における動き補償予測フ
レーム間符号化装置の量子化ステップサイズとの関係を
示す特性図である。 1、51……入力端子、3、53……動ベクトル算出部、
4、54……画像メモリ部、58……動き補償予測部、9、
60……フレーム内・フレーム間判定部、11、62……ルー
プ内フィルタ部、13、64……予測誤差算出部、15、66…
…スイッチ部、17、68……直交変換部、19、70……量子
化部、21……第2量子化ステップサイズ算出部、22、59
……第1量子化ステップサイズ算出部、25……平均・分
散値算出部、28、74……符号メモリ部、30、76……逆直
交変換部、34、78……再生画像算出部、36、82……予測
誤差符号化部、38、84……動ベクトル符号化部、41、86
……マルチプレクサ部、43、89……出力端子。
FIG. 1 is a block diagram of a motion-compensated prediction interframe coding apparatus according to an embodiment of the present invention, FIG. 2 is a block diagram of a conventional motion-compensated prediction interframe coding apparatus, and FIG. FIG. 4 is a conceptual diagram showing the relationship between macroblocks, and FIG. 4 is a characteristic diagram showing the relationship with the quantization step size of the motion compensated prediction interframe coding apparatus according to one embodiment of the present invention. 1, 51 ... input terminal, 3, 53 ... motion vector calculation unit,
4, 54: image memory unit, 58: motion compensation prediction unit, 9,
60 ... intra-frame / inter-frame determination unit, 11, 62 ... intra-loop filter unit, 13, 64 ... prediction error calculation unit, 15, 66 ...
... Switch section, 17, 68... Orthogonal transform section, 19, 70... Quantization section 21,... Second quantization step size calculation section, 22, 59.
... A first quantization step size calculator, 25... An average / variance value calculator, 28, 74... A code memory unit, 30, 76... An inverse orthogonal transform unit, 34, 78. 36, 82 ... prediction error coding unit, 38, 84 ... motion vector coding unit, 41, 86
... Multiplexer, 43, 89 ... Output terminals.

Claims (1)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】テレビジョン信号をアナログディジタル変
換するA/D変換手段と、ディジタル化した入力テレビジ
ョン信号の1フレームまたは1フィールドを定められた
大きさのブロックに分割するブロック化手段と、個々の
ブロックについてテレビジョン画像の動きである動ベク
トルを算出する動ベクトル検出手段と、個々のブロック
について前記動ベクトルを用いて動き補償予測するか判
定する動き補償判定手段と、動き補償予測するブロック
について、前フレームの再生画像を動ベクトルで動き補
償予測し、予測画素値を算出する動き補償予測手段と、
入力テレビジョン信号の画素値と予測画素値との差分を
予測誤差値として算出する誤差算出手段と、個々のブロ
ックについて、フレーム間符号化するかフレーム内符号
化するかを判定する符号化方法決定手段と、ブロック毎
に前記符号化方法決定手段の判定結果により直交変換す
る信号を入力テレビジョン信号の画素値とするか予測誤
差値とするか切り替える切り替え手段と、入力テレビジ
ョン信号の画素値または予測誤差値を、直交変換し、直
交変換係数を算出する直交変換手段と、発生符号量より
第1の量子化ステップサイズを算出する第1量子化ステ
ップサイズ決定手段と、入力テレビジョン信号の輝度信
号のブロック毎の画素値の平均と分散を算出する平均・
分散算出手段と、輝度信号ブロックであり、かつフレー
ム内符号化するブロックを平均または分散によってクラ
ス分けするために、予め定められた閾値を第1の量子化
ステップサイズによって補正する手段と、輝度信号のブ
ロックでありかつフレーム内符号化するブロックについ
ては、前記平均と分散と補正された閾値よりブロックを
クラス分けし、各クラス毎に第1の量子化ステップサイ
ズより第2の量子化ステップサイズを算出し、その他の
ブロックについては、第1の量子化ステップサイズを第
2の量子化ステップサイズとする第2量子化ステップサ
イズ決定手段と、第2の量子化ステップサイズを用い
て、直交変換係数を量子化し、量子化した直交変換係数
を算出する量子化手段と、フレーム内符号化かフレーム
間符号化かの情報と第1の量子化ステップサイズと量子
化のクラス分けに関する情報と量子化した直交変換係数
を符号化する符号化手段と、量子化した直交変換係数を
逆直交変換し、逆量子化信号を算出する逆量子化手段
と、前記符号化方法決定手段の判定結果により、再生画
素値算出時に用いる画素値を動き補償予測した予測画素
値とするか、数値「0」とするか切り替える切り替え手
段と、予測画素値または数値「0」と逆量子化信号より
再生画像を算出する画像再生手段と、再生画像を蓄積す
る画像蓄積手段と、動ベクトルとを符号化する動ベクト
ル符号化手段を具備する動き補償予測フレーム間符号化
装置。
A / D conversion means for analog-to-digital conversion of a television signal, blocking means for dividing one frame or one field of a digitized input television signal into blocks of a predetermined size, Motion vector detecting means for calculating a motion vector which is the motion of the television image for the block, motion compensation judging means for judging whether to perform motion compensation prediction using the motion vector for each block, and a block for motion compensation prediction. Motion-compensated prediction means for performing motion-compensated prediction of the reproduced image of the previous frame with a motion vector and calculating a predicted pixel value
Error calculating means for calculating a difference between a pixel value of an input television signal and a predicted pixel value as a prediction error value, and a coding method determination for determining whether to perform inter-frame coding or intra-frame coding for each block Means, and switching means for switching between a signal to be orthogonally transformed based on the determination result of the encoding method determining means for each block as a pixel value of an input television signal or a prediction error value, and a pixel value of an input television signal or Orthogonal transform means for orthogonally transforming the prediction error value to calculate an orthogonal transform coefficient; first quantization step size determining means for calculating a first quantization step size from the generated code amount; and luminance of the input television signal. Average to calculate the average and variance of pixel values for each block of signal
Variance calculating means, means for correcting a predetermined threshold value by a first quantization step size to classify the blocks which are luminance signal blocks and to be intra-coded by average or variance, and And for blocks to be intra-coded, the blocks are classified into classes based on the average, the variance, and the corrected threshold, and the second quantization step size is determined for each class from the first quantization step size. For the other blocks, the second quantization step size determining means for setting the first quantization step size to the second quantization step size and the second quantization step size are used to calculate the orthogonal transform coefficients. And quantization means for calculating a quantized orthogonal transform coefficient, and information on intra-frame coding or inter-frame coding. Coding means for coding information relating to the quantization step size and quantization classification of 1 and quantized orthogonal transform coefficients, and inverse orthogonal transform of the quantized orthogonal transform coefficients to calculate an inverse quantized signal. A quantizing unit, a switching unit for switching between a pixel value used in calculating a reproduction pixel value and a motion compensated predicted pixel value or a numerical value “0” based on a determination result of the encoding method determining unit; Motion compensation prediction including image reproducing means for calculating a reproduced image from a value or a numerical value "0" and an inversely quantized signal, image storing means for storing the reproduced image, and motion vector coding means for coding a motion vector Interframe coding device.
JP16052090A 1989-10-13 1990-06-19 Motion compensated prediction interframe coding device Expired - Lifetime JP2629409B2 (en)

Priority Applications (3)

Application Number Priority Date Filing Date Title
JP16052090A JP2629409B2 (en) 1990-06-19 1990-06-19 Motion compensated prediction interframe coding device
US07/597,853 US5144426A (en) 1989-10-13 1990-10-12 Motion compensated prediction interframe coding system
US08/298,684 USRE37091E1 (en) 1989-10-13 1994-08-31 Motion compensated prediction interframe coding system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP16052090A JP2629409B2 (en) 1990-06-19 1990-06-19 Motion compensated prediction interframe coding device

Publications (2)

Publication Number Publication Date
JPH0451689A JPH0451689A (en) 1992-02-20
JP2629409B2 true JP2629409B2 (en) 1997-07-09

Family

ID=15716736

Family Applications (1)

Application Number Title Priority Date Filing Date
JP16052090A Expired - Lifetime JP2629409B2 (en) 1989-10-13 1990-06-19 Motion compensated prediction interframe coding device

Country Status (1)

Country Link
JP (1) JP2629409B2 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6870884B1 (en) 1992-01-29 2005-03-22 Mitsubishi Denki Kabushiki Kaisha High-efficiency encoder and video information recording/reproducing apparatus
JPH05344490A (en) * 1992-06-10 1993-12-24 Canon Inc Coding method and coder
JP3348310B2 (en) * 1992-09-28 2002-11-20 ソニー株式会社 Moving picture coding method and moving picture coding apparatus
JP5988577B2 (en) 2011-12-28 2016-09-07 キヤノン株式会社 Image coding apparatus, image coding method, and program

Also Published As

Publication number Publication date
JPH0451689A (en) 1992-02-20

Similar Documents

Publication Publication Date Title
JP2969867B2 (en) High-efficiency encoder for digital image signals.
JP3888597B2 (en) Motion compensation coding apparatus and motion compensation coding / decoding method
US5144426A (en) Motion compensated prediction interframe coding system
US5592302A (en) Coding method for coding pixel blocks and apparatus therefor
KR0166722B1 (en) Encoding and decoding method and apparatus thereof
JPH06189281A (en) Video signal encoding device using compression of adaptive frame/field format
JPH0746594A (en) Encoding method and its device
EP1082855A1 (en) Video coding method and corresponding video coder
JPH10243399A (en) Code amount controller and moving image encoder provided with the same
JP2629409B2 (en) Motion compensated prediction interframe coding device
KR950005624B1 (en) Image compressing &amp; encoding apparatus and method
JPS61201570A (en) Coding system between frames and in frame
JPH05227513A (en) Video signal transmitter
JP2630022B2 (en) Motion compensated interframe coding device
JPH04268891A (en) Encoding device between movement compensation predicting frames
JP3104803B2 (en) Video signal transmission device
JPH04259182A (en) Movement compensation prediction inter-frame coder
JP3279927B2 (en) Image encoding method and apparatus
JP3144573B2 (en) Video signal transmission equipment
JPH0761153B2 (en) Motion compensation prediction interframe coding device
JPH04268890A (en) Encoding device between movement compensation predicting frames
JPH0761154B2 (en) Motion compensation prediction interframe coding device
JPH05227510A (en) Video signal transmitter
JP2922155B2 (en) Image encoding method, image encoding device, and image processing system
JPH0761155B2 (en) Motion compensation prediction interframe coding device

Legal Events

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

Free format text: PAYMENT UNTIL: 20080418

Year of fee payment: 11

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

Free format text: PAYMENT UNTIL: 20090418

Year of fee payment: 12

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

Free format text: PAYMENT UNTIL: 20100418

Year of fee payment: 13

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

Free format text: PAYMENT UNTIL: 20110418

Year of fee payment: 14

EXPY Cancellation because of completion of term
FPAY Renewal fee payment (prs date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110418

Year of fee payment: 14