JP2008011564A - Image encoding device and image decoding device - Google Patents

Image encoding device and image decoding device Download PDF

Info

Publication number
JP2008011564A
JP2008011564A JP2007220412A JP2007220412A JP2008011564A JP 2008011564 A JP2008011564 A JP 2008011564A JP 2007220412 A JP2007220412 A JP 2007220412A JP 2007220412 A JP2007220412 A JP 2007220412A JP 2008011564 A JP2008011564 A JP 2008011564A
Authority
JP
Japan
Prior art keywords
circuit
encoding
block
frame
signal
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.)
Abandoned
Application number
JP2007220412A
Other languages
Japanese (ja)
Other versions
JP2008011564A5 (en
Inventor
Noboru Yamaguchi
昇 山口
Takashi Ida
孝 井田
Yoshihiro Kikuchi
義浩 菊池
Toshiaki Watanabe
敏明 渡邊
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.)
Toshiba Corp
Original Assignee
Toshiba Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Toshiba Corp filed Critical Toshiba Corp
Priority to JP2007220412A priority Critical patent/JP2008011564A/en
Publication of JP2008011564A publication Critical patent/JP2008011564A/en
Publication of JP2008011564A5 publication Critical patent/JP2008011564A5/ja
Abandoned legal-status Critical Current

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a device which encodes the shape information of an object efficiently. <P>SOLUTION: An encoding circuit for an alphamap representing an object (Ob) shape in a motion image encoding device that encodes a multi-frame motion image signal obtained as time-series data per an arbitrary shaped object has a means to split a rectangular region including the Ob for a block (BL) composed of M×N pixels and a means 220 to sequentially encode the BL with a fixed rule in the rectangular region, and a binarization image encoding device which applies relative address encoding for all or a part of the BL has a means to store a BL neighborhood regenerative value, a regenerative signal retention means FM to store a regenerative signal for the already-encoded frame (FM), a predicting means 250 to generate a motion compensation predictive value using the regenerative signal in the retention method, and a means to detect a changing pixel including the BL neighborhood regenerative value, and a reference changing pixel for the relative address encoding is calculated from the motion compensation predictive value not from a pixel value in the BL. <P>COPYRIGHT: (C)2008,JPO&INPIT

Description

本発明は、画像信号を高能率に符号化し、伝送・蓄積すると共に、復号するための画像符号化装置および画像復号化装置に関する。   The present invention relates to an image encoding device and an image decoding device for encoding, transmitting, storing, and decoding an image signal with high efficiency.

画像信号は膨大な情報量を持つため、伝送や蓄積に供する場合には圧縮符号化するのが一般的である。そして、画像信号を高能率に符号化するには、フレーム単位の画像を、所要画素数単位(例えば、M×N画素(M:水平方向の画素数、N:垂直方向の画素数))でブロックに分割し、その分割した各ブロック毎に直交変換して画像の持つ空間周波数を各周波数成分に分離し、変換係数として取得してこれを符号化する。   Since an image signal has an enormous amount of information, it is generally compressed and encoded when used for transmission or storage. In order to encode an image signal with high efficiency, an image in units of frames is converted into a required number of pixels (for example, M × N pixels (M: number of pixels in the horizontal direction, N: number of pixels in the vertical direction)). The image is divided into blocks, orthogonally transformed for each of the divided blocks, the spatial frequency of the image is separated into frequency components, acquired as transform coefficients, and encoded.

ところで、画像符号化の一つとして、『J.Y.A.Wang et.al.“Applying Mid-level Vision Techniques for Video Data Compression and Manipulation”,M.I.T.Media Lab.Tech.Report No.263,Feb.1994,』において、ミッドレベル符号化と呼ばれる範疇に属する画像符号化法が提案されている。   By the way, as one of the image coding, “JYAWang et.al.“ Applying Mid-level Vision Techniques for Video Data Compression and Manipulation ”, MITMedia Lab.Tech.Report No.263, Feb.1994,” An image encoding method belonging to a category called mid-level encoding has been proposed.

この方式では、例えば、図16(a)のような背景と被写体(以後、被写体をオブジェクトと呼ぶ)からなる画像があったとして、この背景とオブジェクトを図16の(b),(c)のように分けて符号化している。   In this method, for example, assuming that there is an image composed of a background and a subject (hereinafter, the subject is referred to as an object) as shown in FIG. 16A, the background and the object are shown in FIGS. 16B and 16C. They are encoded separately.

このように、背景(図16(c))やオブジェクト(図16(b))を別々に符号化するためには、オブジェクトの形状や画面内の位置を表す例えば2値の副画像情報であるアルファマップ信号(図16(d)参照、図中、白画素がオブジェクトの画素を示す)が必要となる。なお、背景のアルファマップ信号(図16(e))は、オブジェクトのアルファマップ信号から一意に求められる。   Thus, in order to separately encode the background (FIG. 16C) and the object (FIG. 16B), for example, binary sub-image information representing the shape of the object and the position in the screen is used. An alpha map signal (see FIG. 16D, in which white pixels indicate object pixels) is required. The background alpha map signal (FIG. 16E) is uniquely obtained from the alpha map signal of the object.

ところで、このアルファマップ信号を効率的に符号化する方法として、2値画像の符号化法(例えば、MMR(Modified Modified READ)符号化等)や、線図形の符号化法(チェイン符号化等)が用いられている。   By the way, as a method of efficiently encoding the alpha map signal, a binary image encoding method (for example, MMR (Modified Modified READ) encoding) or a line figure encoding method (chain encoding or the like) is used. Is used.

また、更にアルファマップの符号量を低減するために、形状の輪郭線をポリゴン近似してスプライン曲線でスムーシングする方法(J.Ostermann,“Object-based analysis-synthesis coding based on the souece model of moving rigid 3D objects”,Signal Process.:Image Comm.Vol.6 No.2 pp.143-161,1994)や、アルファマップを縮小して符号化し、拡大する際に曲線近似する方法(特願平5−297133号参照)などがある。   In order to further reduce the amount of alpha map code, J. Ostermann, “Object-based analysis-synthesis coding based on the souece model of moving rigid” 3D objects ”, Signal Process.:Image Comm.Vol.6 No.2 pp.143-161,1994) and encoding method by reducing the alpha map and approximating the curve when enlarging (Japanese Patent Application No. Hei 5- No. 297133).

ここで、アルファマップを縮小して符号化し、拡大する際に曲線近似する方法の例を説明する。   Here, an example of a method of approximating a curve when the alpha map is reduced and encoded and enlarged will be described.

<MMR符号化回路の具体例>
(ブロックベース符号化の具体例)
図18(a)は、ブロック単位(例えば、M×N画素構成のブロック単位(M:水平方向の画素数、N:垂直方向の画素数))で符号化する場合の変化画素の関係を表す図である。また、図18(b)は、参照変化画素b1を検出するための参照領域を表す図である。
ブロックベース符号化においては、以下のように変化画素の符号化を単純化して符号化しても良い。なお、以下の処理は、スキャンの順序を切り換えても良いし、縮小されたブロックに適用しても良い。
<Specific Example of MMR Encoding Circuit>
(Specific example of block-based coding)
FIG. 18A shows the relationship of change pixels when encoding is performed in block units (for example, block units in an M × N pixel configuration (M: number of pixels in the horizontal direction, N: number of pixels in the vertical direction)). FIG. FIG. 18B is a diagram illustrating a reference area for detecting the reference change pixel b1.
In block-based encoding, encoding of changed pixels may be simplified as follows. The following processing may be performed by switching the scan order or may be applied to a reduced block.

単純化した変化画素の符号化は、次のようにして行う。
今、変化画素ai (i=0 〜1)、参照変化画素b1それぞれについての、画面左上からラスタ順に求めた際のアドレス(または画素順序)を各々、abs_ai (i=0 〜1)、abs_b1 と表記し、変化画素a0 の属するラインをa0_lineと表記すると、a0_lineおよびr_ ai (i=0 〜1)、r_ b1 の値は、以下の式で求められる。
The simplified change pixel encoding is performed as follows.
Now, the addresses (or pixel order) of the change pixel ai (i = 0 to 1) and the reference change pixel b1 obtained in raster order from the upper left of the screen are abs_ai (i = 0 to 1), abs_b1, respectively. When the line to which the change pixel a0 belongs is expressed as a0_line, the values of a0_line, r_ai (i = 0 to 1), and r_b1 are obtained by the following equations.

a0_line = (int)((abs_ a0 +WIDTH)/WIDTH)−1
r_ a0 = abs_a0 − a0_line*WIDTH
r_ a1 = abs_a1 − a0_line*WIDTH
r_ b1 = abs_b1 − (a0_line−1)*WIDTH
上記式において、*は乗算を、(int)(X) はXの小数点以下切り捨てを意味しており、WIDTH はブロックの水平方向の画素数を示している。
a0_line = (int) ((abs_a0 + WIDTH) / WIDTH) -1
r_a0 = abs_a0-a0_line * WIDTH
r_a1 = abs_a1-a0_line * WIDTH
r_b1 = abs_b1− (a0_line−1) * WIDTH
In the above formula, * means multiplication, (int) (X) means truncation after the decimal point of X, and WIDTH indicates the number of pixels in the horizontal direction of the block.

そして、変化画素の相対アドレス“r_a1−r_b1”あるいは、“r_a1−r_a0”の値を符号化することで、再生値が得られる。これが、上述の “単純化した変化画素の符号化”である。   Then, the reproduction value is obtained by encoding the value of the relative address “r_a1-r_b1” or “r_a1-r_a0” of the change pixel. This is the above-described “simplified change pixel encoding”.

図19は、2値画像の符号化法であるMMR符号化を、ブロックベースで実施する場合の処理の流れを示すフローチャートである。以後、フローチャートに従って符号化処理を説明する。ここでの処理は、まず、起点変化画素の位置を初期化し(S501)、初期位置(ブロックの左上画素)での画素値を1ビットで符号化する(S502)、次に初期位置において参照変化画素b1を検出する(S503)。   FIG. 19 is a flowchart showing the flow of processing when MMR encoding, which is a binary image encoding method, is performed on a block basis. Hereinafter, the encoding process will be described according to the flowchart. In this process, first, the position of the starting point change pixel is initialized (S501), the pixel value at the initial position (the upper left pixel of the block) is encoded with 1 bit (S502), and then the reference change is performed at the initial position. The pixel b1 is detected (S503).

ここで、参照変化画素b1が検出されなかった場合には、参照領域に変化画素が存在しないことから垂直モードが使えないため、垂直パスモードの状態を“TRUE”(真)とし、b1が検出された場合は垂直モードが使えるため、垂直パスモードの状態を“FALSE”(偽)とする。   Here, when the reference change pixel b1 is not detected, since the change mode does not exist in the reference area, the vertical mode cannot be used. Therefore, the state of the vertical pass mode is set to “TRUE” (true) and b1 is detected. In this case, since the vertical mode can be used, the state of the vertical path mode is set to “FALSE” (false).

以上で初期状態のセッティングを終了し、符号化ループの処理に移る。
まず、変化画素a1を検出し(S505)、変化画素a1が検出されたか否かを判定し(S506)、変化画素a1が検出されなかった場合には、以後、変化画素が無いため、符号化の終了を示す符号化処理終了符号(EOMB;End of MB)を符号化する(S507)。
The initial setting is thus completed, and the process proceeds to the encoding loop process.
First, the change pixel a1 is detected (S505), and it is determined whether or not the change pixel a1 is detected (S506). If the change pixel a1 is not detected, then there is no change pixel, so that encoding is performed. An encoding process end code (EOMB; End of MB) indicating the end of is encoded (S507).

また、S506での判定の結果、変化画素a1が検出された場合には、垂直パスモード(Vertical pass mode)の状態を判定する(S508)。ここで、垂直パスモードの状態が“TRUE”ならば、垂直パスモードの符号化処理(S516)を行い、垂直パスモードの状態が“FALSE”ならば、b1を検出する (S509)。   If the change pixel a1 is detected as a result of the determination in S506, the state of the vertical pass mode is determined (S508). If the vertical path mode state is “TRUE”, vertical path mode encoding processing (S516) is performed. If the vertical path mode state is “FALSE”, b1 is detected (S509).

次に、b1が検出されたか否かを判定し(S510)、参照変化画素b1が検出されなかった場合には、水平モードのステップ(S513)に進み、参照変化画素b1が検出された場合には、”r_a1−r_b1”の絶対値がしきい値 (VTH)よりも大きいか否かを判定し(S511)、その結果、しきい値(VTH)以下の場合には、垂直モードのステップ(S512)に進み、しきい値 (VTH)よりも大きい場合には、水平モードのステップ(S513)に進む。   Next, it is determined whether or not b1 has been detected (S510). If the reference change pixel b1 has not been detected, the process proceeds to step S513 in the horizontal mode, and if the reference change pixel b1 has been detected. Determines whether or not the absolute value of “r_a1−r_b1” is larger than the threshold value (VTH) (S511). The process proceeds to S512), and if larger than the threshold value (VTH), the process proceeds to step S513 in the horizontal mode.

水平モードのステップ(S513)では、“r_a1−r_a0”の値が符号化される。ここで、“r_a1−r_a0”の値が“WIDTH”よりも小さいか否かを判定し(S514)、その結果、“WIDTH”以上の場合には、垂直パスモードの状態を“TRUE”(真)として(S515)、垂直パスモードのステップ(S516)に進み、垂直パスモードのステップ(S516)が終了したら、垂直パスモードの状態を“FALSE”(偽)とする。   In the horizontal mode step (S513), the value of “r_a1-r_a0” is encoded. Here, it is determined whether or not the value of “r_a1-r_a0” is smaller than “WIDTH” (S514). As a result, if the value is “WIDTH” or more, the state of the vertical path mode is set to “TRUE” (true ) (S515), the process proceeds to the step (S516) of the vertical pass mode. When the step (S516) of the vertical pass mode is completed, the state of the vertical pass mode is set to “FALSE” (false).

以上、垂直モード、水平モード、垂直パスモードの何れかが終了した後(alまでの符号化が終了した後)、a1の位置を新たなa0の位置として(S518)、S505の処理に戻る。   As described above, after any of the vertical mode, the horizontal mode, and the vertical pass mode is completed (after the encoding up to al is completed), the position of a1 is set as a new position of a0 (S518), and the process returns to S505.

図17は、VLCテーブル(可変長符号テーブル)の例である。
ここで、垂直パスモードの状態が“TRUE”の場合には、符号の種類はV0(モードV0)、H(水平モード)、EOMB(符号化処理終了符号)の3種類しか生起しないため、垂直パスモードの状態に応じて、VLCを切り換えることができる。なお、垂直パスモードの状態が“TRUE”の場合、EOMBはa0がブロックの左上の位置(初期位置)にある場合のみ生起する。従って、この場合には、図17の“0”内の符号が用いられる。
J. Y. A. Wang et. al. “Applying Mid-level Vision Techniques for Video Data Compression and Manipulation” ,M. I. T. Media Lab. Tech. Report No. 263, Feb. 1994 J. Ostermann, “Object-based analysis-synthesis coding based on the souece model of moving rigid 3D objects”, Signal Process. :Image Comm. Vol. 6 No. 2 pp. 143-161,1994
FIG. 17 is an example of a VLC table (variable length code table).
Here, when the state of the vertical path mode is “TRUE”, only three types of codes, V0 (mode V0), H (horizontal mode), and EOMB (encoding processing end code), occur. The VLC can be switched according to the state of the pass mode. When the state of the vertical path mode is “TRUE”, EOMB occurs only when a0 is at the upper left position (initial position) of the block. Therefore, in this case, the code in “0” of FIG. 17 is used.
JYA Wang et. Al. “Applying Mid-level Vision Techniques for Video Data Compression and Manipulation”, MIT Media Lab. Tech. Report No. 263, Feb. 1994 J. Ostermann, “Object-based analysis-synthesis coding based on the souece model of moving rigid 3D objects”, Signal Process.:Image Comm. Vol. 6 No. 2 pp. 143-161,1994

画像を符号化する場合に、画面内を背景とオブジェクトに分割して符号化する方式があるが、この場合、背景とオブジェクトを分けるために、オブジェクトの形状や画面内の位置を表すアルファマップ信号が必要となる。そして、画像の符号化情報と共に、このアルファマップの情報も符号化してビットストリーム化し、伝送や蓄積に供する。   When encoding an image, there is a method that divides the inside of the screen into a background and an object, and in this case, in order to separate the background and the object, an alpha map signal indicating the shape of the object and the position in the screen is used. Is required. The information of the alpha map as well as the encoded information of the image is also encoded to form a bit stream for transmission and storage.

しかし、画面内を背景とオブジェクトに分割して符号化する方式の場合、従来の符号化法のように画面内を一括して符号化するのに比べ、アルファマップがある分、符号量増加が問題となり、このアルファマップの符号量増加による符号化効率の低下が問題となる。   However, in the method of encoding by dividing the inside of the screen into the background and the object, the amount of code increases by the amount of alpha map compared to the case of encoding in the screen all at once as in the conventional encoding method. There is a problem, and a decrease in encoding efficiency due to an increase in the code amount of the alpha map becomes a problem.

そこでこの発明の目的とするところは、オブジェクトの形状や画面内の位置などを表す副画像情報であるアルファマップの情報を効率良く符号化できるとともに、その復号を行うことができるようにした画像符号化装置および画像復号化装置を提供することにある。   Accordingly, an object of the present invention is to efficiently encode the information of the alpha map, which is sub-image information representing the shape of the object, the position in the screen, and the like, and an image code that can be decoded. It is to provide an encoding device and an image decoding device.

上記目的を達成するため、本発明は次のように構成する。   In order to achieve the above object, the present invention is configured as follows.

第1には、画像をその画像のオブジェクト領域と背景領域に区別するための情報であるアルファマップと共に符号化し、前記アルファマップは相対アドレス符号化を用いて符号化する画像符号化装置において、
既に符号化した変化画素を参照変化画素とし、この参照変化画素と、次に符号化する変化画素の相対的な位置を表すシンボルを可変長符号化テーブルを用いて符号化する手段と、前記可変長符号化テーブルを2つ以上保持し、既に符号化した前記アルファマップのパターンによって、前記可変長符号化テーブルを切り替える手段とを備えることを特徴とする。
First, in an image encoding apparatus that encodes an image together with an alpha map that is information for distinguishing the object region and the background region of the image, the alpha map is encoded using relative address encoding.
A change pixel that has already been encoded is used as a reference change pixel, and a symbol representing the relative position of the reference change pixel and the change pixel to be encoded next is encoded using a variable-length encoding table; Means for holding two or more long coding tables and switching the variable length coding table according to the already-encoded alpha map pattern.

第2には、この符号化装置により符号化されて得られた符号化ビットストリームを復号する復号化装置であって、
前記シンボルを可変長符号化テーブルを用いて復号する手段と、前記可変長符号化テーブルを2つ以上保持し、既に復号した前記アルファマップのパターンによって、前記可変長符号化テーブルを切り替える手段とを備えることを特徴とする。
The second is a decoding device for decoding the encoded bitstream obtained by encoding by this encoding device,
Means for decoding the symbols using a variable-length coding table; and means for holding two or more variable-length coding tables and switching the variable-length coding table according to the already-decoded alpha map pattern. It is characterized by providing.

さらには、前記可変長符号化テーブルを切り替える手段は、参照変化画素の近くのパターンによって切り替えることを特徴とする。   Furthermore, the means for switching the variable length coding table is switched by a pattern near the reference change pixel.

このような構成の本装置は、変化画素の位置を特定するシンボルを可変長符号化テーブルを用いて符号化することにより符号量を少なくするようにした符号化/復号化において、複数種の可変長符号化テーブルを用意しておき、既に符号化した前記アルファマップのパターンによって、その可変長符号化テーブルを切り替えることを特徴とするものであり、このような本発明によれば、アルファマップの符号量をいっそう低減できる効果が得られる。   This apparatus configured as described above is capable of performing a plurality of types of variable in encoding / decoding in which the amount of code is reduced by encoding a symbol that specifies the position of a change pixel using a variable-length encoding table. A long encoding table is prepared, and the variable length encoding table is switched according to the already encoded alpha map pattern. According to the present invention, the alpha map An effect of further reducing the code amount can be obtained.

また、第2には本発明は、時系列データとして得られる複数フレーム(画像フレーム)の動画像信号を任意形状のオブジェクト毎に符号化する動画像符号化装置における、オブジェクトの形状を表すアルファマップを符号化する符号化回路であって、オブジェクトを含む方形領域をM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に分割する手段と、この分割されて得られた上記ブロックを、前記方形領域内において一定規則により順次、符号化する手段とを有し、ブロックの全てあるいは一部に対して相対アドレス符号化を適用する2値画像符号化装置において、
ブロック近傍の再生値を蓄える再生値蓄積手段と、すでに符号化されたフレーム(画像フレーム)の再生信号を蓄える画像保持手段(フレームメモリ)と、画像保持手段(フレームメモリ)内の再生信号を用いて、動き補償予測値を生成する動き補償予測回路と、前記再生値蓄積手段を参照し、ブロック近傍の再生値も含めて変化画素を検出する手段とを有し、相対アドレス符号化の参照変化画素を、上記ブロック内の画素値からでなく、動き補償予測信号から求めるようにしたものである。
Second, the present invention relates to an alpha map representing the shape of an object in a moving image encoding apparatus that encodes a plurality of frames (image frames) of moving image signals obtained as time series data for each object having an arbitrary shape. Means for dividing a rectangular region including an object into blocks each composed of M × N pixels (M: number of pixels in the horizontal direction, N: number of pixels in the vertical direction); A binary image code which has means for sequentially encoding the blocks obtained by the division in the square area according to a certain rule, and applies relative address encoding to all or a part of the blocks; In the conversion device,
Using reproduction value storage means for storing the reproduction values in the vicinity of the block, image holding means (frame memory) for storing a reproduction signal of an already encoded frame (image frame), and reproduction signals in the image holding means (frame memory) A reference value for relative address encoding, and a motion compensation prediction circuit for generating a motion compensation prediction value and a means for detecting a change pixel including a reproduction value near a block with reference to the reproduction value storage means. The pixels are obtained from the motion compensated prediction signal, not from the pixel values in the block.

また、アルファマップ復号化回路において、M×N画素で構成されるブロック毎に、オブジェクトを含む方形領域内を一定規則で順次復号化する手段と、ブロック近傍の再生値を蓄える手段と、すでに符号化されたフレーム(画像フレーム)の再生信号を蓄える画像保持手段(フレームメモリ)と、画像保持手段(フレームメモリ)内の再生信号を用いて、動き補償予測値を生成する動き補償予測回路と、ブロック近傍の再生値も含めて変化画素を検出する手段とを有し、相対アドレス符号化の参照変化画素を、上記ブロック内の画素値からでなく、動き補償予測信号から求めるようにしたものである。   Further, in the alpha map decoding circuit, for each block composed of M × N pixels, means for sequentially decoding the rectangular area including the object according to a certain rule, means for storing a reproduction value in the vicinity of the block, and code An image holding means (frame memory) for storing a reproduction signal of the converted frame (image frame), a motion compensation prediction circuit for generating a motion compensation prediction value using the reproduction signal in the image holding means (frame memory), Means for detecting a change pixel including a reproduction value in the vicinity of the block, and the reference change pixel of the relative address encoding is obtained not from the pixel value in the block but from the motion compensated prediction signal. is there.

これにより、オブジェクトの形状や画面内の位置などを表す副画像情報であるアルファマップの情報を効率良く符号化できるとともに、その復号を行うことができるようになる。   As a result, it is possible to efficiently encode and decode the alpha map information, which is the sub-image information representing the shape of the object, the position in the screen, and the like.

また、ブロック近傍の再生値を蓄える手段と、すでに符号化されたフレーム (画像フレーム)の再生信号を蓄える画像保持手段(フレームメモリ)と、画像保持手段(フレームメモリ)内の再生信号を用いて、動き補償予測値を生成する動き補償予測回路と、ブロック近傍の再生値も含めて変化画素を検出する手段と、上記ブロック内の再生画素値から求められた、相対アドレス符号化の参照変化画素と、動き補償予測信号から求められた、相対アドレス符号化の参照変化画素を切り替える手段とを有し、相対アドレス符号化情報を、切り替え情報と共に符号化するものである。   Also, using means for storing reproduction values in the vicinity of the block, image holding means (frame memory) for storing reproduction signals of already encoded frames (image frames), and reproduction signals in the image holding means (frame memory) A motion compensation prediction circuit for generating a motion compensation prediction value, means for detecting a change pixel including a reproduction value near the block, and a reference change pixel of relative address encoding obtained from the reproduction pixel value in the block And means for switching the reference change pixel of the relative address encoding obtained from the motion compensation prediction signal, and encodes the relative address encoding information together with the switching information.

また、アルファマップ復号化回路において、M×N画素で構成されるブロック毎に、オブジェクトを含む方形領域内を一定規則で順次復号化する手段と、ブロック近傍の再生値を蓄える手段と、すでに符号化されたフレーム(画像フレーム)の再生信号を蓄える画像保持手段(フレームメモリ)と、画像保持手段(フレームメモリ)内の再生信号を用いて、動き補償予測値を生成する動き補償予測回路と、ブロック近傍の再生値も含めて変化画素を検出する手段とを有し、上記ブロック内の再生画素値から求められた、相対アドレス符号化の参照変化画素と、動き補償予測信号から求められた、相対アドレス符号化の参照変化画素を切り替える手段を有し、切り替え情報にしたがって参照変化画素を求めるようにしたものである。   Further, in the alpha map decoding circuit, for each block composed of M × N pixels, means for sequentially decoding the rectangular area including the object according to a certain rule, means for storing a reproduction value in the vicinity of the block, and code An image holding means (frame memory) for storing a reproduction signal of the converted frame (image frame), a motion compensation prediction circuit for generating a motion compensation prediction value using the reproduction signal in the image holding means (frame memory), Means for detecting a change pixel including a reproduction value in the vicinity of the block, and obtained from a reference change pixel of relative address encoding obtained from the reproduction pixel value in the block and a motion compensation prediction signal. Means for switching the reference change pixel of relative address encoding is provided, and the reference change pixel is obtained according to the switching information.

この場合、相対アドレス符号化にあたり、参照変化画素b1を現在処理中の画像のブロックである“current block ”内より検出するか、前回処理した画像のブロックである“ compensated block”内より検出するかを、ブロック単位で切り替えて処理することができ、符号化側ではこの切り替え用の情報も併せて符号化し、復号化側ではこれを復号して、復号化処理の際に当該切り替え用の情報に基づいて、参照変化画素b1を“current block ”内より検出するか、“ compensated block”内より検出するかを、ブロック単位で切り替えるようにすることができ、このようにすることによって、ブロック単位の画像内容に基づいて、最適処理が可能になり、一層、効率の良い符号化が可能になる。   In this case, in relative address encoding, whether the reference change pixel b1 is detected from the “current block” that is the block of the image currently being processed or the “compensated block” that is the block of the previously processed image Can be switched and processed in units of blocks, the encoding side also encodes this switching information, the decoding side decodes this, and the decoding information is converted into the switching information during decoding processing. On the basis of this, it is possible to switch the reference change pixel b1 from the “current block” or the “compensated block” to be detected in units of blocks. Optimal processing is possible based on the image content, and more efficient encoding is possible.

また本発明は、時系列データとして得られる複数フレームの動画像信号を任意形状のオブジェクト毎に符号化する動画像符号化装置であって、オブジェクトを含む方形領域をM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に分割すると共に、この分割されて得られた上記ブロック毎に、前記方形領域内を一定規則により順次、符号化する画像符号化装置において、
オブジェクトの形状を表すアルファマップ信号について、ブロック近傍の再生信号を含む該フレームの再生信号と、符号化が終了したフレームの再生信号を蓄えるフレームメモリと、
ブロック内の画素値を2値の何れか一方の値で全て置き換える手段と、
フレームメモリ内のすでに符号化が終了したフレームの再生信号を用いて、動き補償予測値を生成する動き補償予測手段と、
ブロック毎に2値画像を縮小・拡大する手段と、
その縮小・拡大率をサイド情報として符号化する手段と、
ブロック毎に縮小された2値画像を符号化する2値画像符号化手段とからなるアルファマップ符号化手段を備えて構成した。
The present invention is also a moving image encoding apparatus that encodes a plurality of frames of moving image signals obtained as time-series data for each object having an arbitrary shape, and a rectangular region including the object is represented by M × N pixels (M: horizontal). An image that is divided into blocks each having a number of pixels in the direction, N: the number of pixels in the vertical direction), and that is obtained by sequentially encoding the inside of the rectangular region according to a certain rule for each of the blocks obtained by the division. In the encoding device,
For an alpha map signal representing the shape of an object, a frame memory that stores a reproduction signal of the frame including a reproduction signal near the block, and a reproduction signal of a frame that has been encoded;
Means for replacing all pixel values in a block with one of two values;
Motion-compensated prediction means for generating a motion-compensated prediction value using a reproduction signal of a frame that has already been encoded in the frame memory;
Means for reducing / enlarging the binary image for each block;
Means for encoding the reduction / enlargement ratio as side information;
An alpha map encoding means comprising a binary image encoding means for encoding a binary image reduced for each block is provided.

そして、前記アルファマップ符号化手段は前記ブロックの再生画像を、ブロック内を2値の何れか一方の値で全て置き換えた再生値と、動き補償予測値と、ブロック毎に縮小・拡大する事で得られた再生値とのうちの何れかから選択するようにした。従って、アルファマップ信号の符号化を、高品位で効率の良い形態で実施でき、高品位の画質を維持し、かつ、高圧縮率で符号化することができるようになる。   Then, the alpha map encoding means reduces or enlarges the reproduction image of the block for each block, a reproduction value obtained by replacing all the values in the block with one of the two values, a motion compensation prediction value, and the like. One of the obtained reproduction values is selected. Therefore, the encoding of the alpha map signal can be performed in a high-quality and efficient form, the high-quality image quality can be maintained, and the encoding can be performed with a high compression rate.

また、時系列データとして得られる複数フレームの動画像信号を任意形状のオブジェクト毎に復号化する動画像復号化装置であって、オブジェクトを含むM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に、その方形領域内を一定規則により順次、復号化する画像復号化装置において、
ブロック近傍の再生信号を含む該フレームの再生信号と、符号化済みフレームの再生信号を蓄えるフレームメモリと、
ブロック内の画素値を2値の何れか一方の値で全て置き換える手段と、
フレームメモリ内のすでに符号化が終了したフレームの再生信号を用いて、動き補償予測値を生成する動き補償予測手段と、
ブロック毎に2値画像を縮小・拡大する手段と、
ブロック毎に縮小された2値画像を復号化する2値画像復号化手段とからなるアルファマップ復号化手段を備えて構成した。
Further, it is a moving picture decoding apparatus that decodes a plurality of frames of moving picture signals obtained as time series data for each object having an arbitrary shape, and includes M × N pixels (M: number of pixels in the horizontal direction, N : In an image decoding apparatus that sequentially decodes the rectangular area according to a certain rule for each block composed of:
A frame memory for storing a reproduction signal of the frame including a reproduction signal in the vicinity of the block, and a reproduction signal of an encoded frame;
Means for replacing all pixel values in a block with one of two values;
Motion-compensated prediction means for generating a motion-compensated prediction value using a reproduction signal of a frame that has already been encoded in the frame memory;
Means for reducing / enlarging the binary image for each block;
An alpha map decoding unit comprising a binary image decoding unit for decoding a binary image reduced for each block is provided.

そして、前記アルファマップ復号化手段は、前記ブロックの再生画像を、ブロック内を2値の何れか一方の値で全て置き換えた再生値と、動き補償予測値と、ブロック毎に縮小・拡大することで得られた再生値のうちの何れかから選択するようにした。従って、高品位の画像を再生できるようになる。   The alpha map decoding means reduces or enlarges the reproduction image of the block for each block, a reproduction value obtained by replacing all of the inside of the block with one of the two values, a motion compensation prediction value, and the like. It was made to select from any one of the reproduction values obtained in (1). Therefore, a high-quality image can be reproduced.

また、アルファマップをブロック毎に符号化する際に、ブロック毎の属性を符号化する方式であって、オブジェクトを含む、ブロックサイズの倍数で表される符号化領域を設定する手段と、
この領域内をブロックに分割する手段と、
各ブロックに対して、各々の属性に固有のラベルを割り当てるラベル付け手段と、上記ラベルをフレーム毎に保持する記億手段と、
現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する決定手段と、
少なくとも上記記憶手段に保持された前フレームのラベルと上記参照ブロックによって予測値を決定する予測手段と、
上記符号化ブロックのラベル情報を、上記予測値を用いて符号化する符号化手段とを有して構成するようにした。
Further, when encoding an alpha map for each block, a method for encoding an attribute for each block, including an object, a means for setting an encoding area represented by a multiple of a block size,
Means for dividing the area into blocks;
Labeling means for assigning a unique label to each attribute for each block; storage means for holding the label for each frame;
Determining means for determining a reference block of a previous frame corresponding to an encoded block of a current frame;
Prediction means for determining a prediction value by at least the label of the previous frame held in the storage means and the reference block;
The encoding block label information is configured to include encoding means for encoding using the prediction value.

また、アルファマップのブロック毎の属性を再生する復号化装置として、
復号化したラベルをフレーム毎に保持する記憶手段と、
現フレームの復号ブロックに対応する前フレームの参照ブロックを決定する決定手段と、
少なくとも上記記億手段に保持された前フレームのラベルと上記参照ブロックによつて予測値を決定する予測手段と、
上記復号ブロックのラベル情報を、上記予測値を用いて復号化する復号化手段を備えて構成するようにした。
In addition, as a decoding device that reproduces the attribute of each block of the alpha map,
Storage means for holding the decrypted label for each frame;
Determining means for determining a reference block of a previous frame corresponding to a decoded block of a current frame;
Prediction means for determining a prediction value by at least the label of the previous frame held in the storage means and the reference block;
The decoding block label information is configured to include decoding means for decoding using the predicted value.

これらにより、アルファマップをマクロブロック(画像を例えば、16×16画素といった所定の複数画素構成に分割した場合のその分割した単位画像ブロック)毎に符号化する際に、各ブロックの属性に固有のラベルを付してこれを符号化するようにし、このラベルを再生して元のアルファマップのデータを再生することにより、効率の良い符号化できるようになる。   As a result, when the alpha map is encoded for each macro block (the divided unit image block when the image is divided into a predetermined plurality of pixel configurations such as 16 × 16 pixels), it is specific to the attribute of each block. By attaching a label and encoding it, and reproducing the label and reproducing the original alpha map data, efficient encoding can be performed.

また、本発明は、画像を、その画像のオブジェクト領域と背景領域に区別するための情報であるアルファマップと共に符号化するに当たり、アルファマップをブロック毎に符号化する際に、ブロック毎の属性を符号化するようにした方式の画像符号化装置であって、
オブジェクトを含む、ブロックサイズの倍数で表される符号化領域を設定する手段と、この領域内をブロックに分割する手段と、各ブロックに対して、各々の属性に固有のラベルを割り当てるラベル付け手段と、上記ラベルあるいは上記アルファマップをフレーム毎に保持する記億手段と、現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する決定手段と、少なくとも上記記憶手段に保持された前フレームのラベルあるいはアルファマップと、上記参照ブロックによって予測値を決定する予測手段と、上記符号化ブロックのラベル情報を、上記予測値を用いて符号化する符号化手段とを有する構成とする。
Further, the present invention encodes an image together with an alpha map that is information for distinguishing the object area and the background area of the image. When the alpha map is encoded for each block, the attribute for each block is set. An image encoding device of a method for encoding,
Means for setting an encoding area including an object expressed by a multiple of the block size, means for dividing the area into blocks, and labeling means for assigning a unique label to each attribute for each block Storage means for holding the label or the alpha map for each frame, determination means for determining a reference block of the previous frame corresponding to the encoded block of the current frame, and at least the previous frame held in the storage means And an alpha map, a predicting unit that determines a predicted value by the reference block, and an encoding unit that encodes the label information of the encoded block using the predicted value.

さらには、フレーム単位での縮小・拡大率を保持する記憶手段を設けると共に、上記符号化手段は、フレーム単位でフレームの縮小・拡大率が可変であり、上記縮小・拡大縮率対応に符号化する手段を備え、また、上記決定手段は、現フレームの縮小・拡大率と、上記記億手段から得た前フレームの縮小・拡大率を用いて現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する手段を備えるようにする。   Furthermore, storage means for holding the reduction / enlargement ratio in units of frames is provided, and the encoding means can change the reduction / enlargement ratio of the frames in units of frames, and encodes corresponding to the reduction / enlargement / reduction ratios. And the determining means uses the reduction / enlargement ratio of the current frame and the reduction / enlargement ratio of the previous frame obtained from the storage means to determine the previous frame corresponding to the encoded block of the current frame. Means for determining a reference block are provided.

あるいは、フレーム単位での縮小・拡大率を保持する記憶手段を設けると共に、上記符号化手段は、フレーム単位でフレームの縮小・拡大率が可変であり、上記縮小・拡大縮率対応に符号化する手段を備え、また、上記決定手段は、現フレームの縮小・拡大率と、上記記億手段から得た前フレームの縮小・拡大率を用いて現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する手段を備え、また、上記予測手段は、参照ブロックが複数ある場合には、上記複数の参照ブロックのラベルのうち、数が多いラベルを予測値とする手段を備えるようにする。   Alternatively, storage means for holding the reduction / enlargement ratio in units of frames is provided, and the encoding means can change the reduction / enlargement ratio of the frames in units of frames and performs encoding corresponding to the reduction / enlargement / reduction ratios. Means for determining a reference to a previous frame corresponding to an encoded block of the current frame using the reduction / enlargement ratio of the current frame and the reduction / enlargement ratio of the previous frame obtained from the storage means. A means for determining a block is provided, and when there are a plurality of reference blocks, the prediction means is provided with a means for setting a label having a large number among the labels of the plurality of reference blocks as a predicted value.

あるいは、フレーム単位での縮小・拡大率を保持する記憶手段を設けると共に、 上記符号化手段は、フレーム単位でフレームの縮小・拡大率が可変であり、上記縮小・拡大縮率対応に符号化するものであって、前フレームあるいは現フレームあるいはその両方の縮小・拡大率に応じて、複数種のうちから選択した一つの可変長符号化テーブルを用いて符号化ブロックの符号化処理をする手段を備え、また、上記決定手段は、現フレームの縮小・拡大率と、上記記億手段から得た前フレームの縮小・拡大率を用いて現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する手段を備える。   Alternatively, storage means for holding the reduction / enlargement ratio in units of frames is provided, and the encoding means encodes the reduction / enlargement ratio corresponding to the reduction / enlargement / reduction ratios in which the reduction / enlargement ratio of the frames is variable in units of frames. Means for encoding a coding block using a variable length coding table selected from a plurality of types according to the reduction / enlargement ratio of the previous frame or the current frame or both. And the determination means uses the current frame reduction / enlargement ratio and the previous frame reduction / enlargement ratio obtained from the storage means to determine the reference block of the previous frame corresponding to the encoded block of the current frame. Means for determining;

また、アルファマップのブロック毎の属性を再生する復号化装置において、
復号化したラベルあるいはアルファマップをフレーム毎に保持する記憶手段と、現フレームの復号ブロックに対応する前フレームの参照ブロックを決定する決定手段と、少なくとも上記記億手段に保持された前フレームのラベルあるいはアルファマップと上記参照ブロックによつて予測値を決定する予測手段と、上記復号ブロックのラベル情報を、上記予測値を用いて復号化する復号化手段を有することを特徴とする。
Also, in a decoding device that reproduces the attribute of each block of the alpha map,
Storage means for holding the decoded label or alpha map for each frame, determination means for determining a reference block of the previous frame corresponding to the decoded block of the current frame, and label of the previous frame held by at least the storage means Or it has the prediction means which determines a predicted value with an alpha map and the said reference block, and the decoding means which decodes the label information of the said decoding block using the said predicted value, It is characterized by the above-mentioned.

そして、さらには、フレーム単位でフレームの縮小・拡大率が可変であり、上記縮小・拡大率情報を復号化する手段と、
上記縮小・拡大情報を保持する記憶手段とを有し、
上記決定手段は、現フレームの縮小・拡大率と、上記記億手段から読み出される、前フレームの縮小・拡大率を用いて現フレームの復号ブロックに対応する前フレームの参照ブロックを決定する機能を備えるものであることを特徴とする。
Further, the frame reduction / enlargement rate is variable in units of frames, and means for decoding the reduction / enlargement rate information,
Storage means for holding the reduction / enlargement information,
The determination means has a function of determining a reference block of the previous frame corresponding to a decoded block of the current frame using the reduction / enlargement ratio of the current frame and the reduction / enlargement ratio of the previous frame read from the storage means. It is characterized by comprising.

あるいは、フレーム単位でフレームの縮小・拡大率が可変であり、上記縮小・拡大率情報を復号化する手段と、
上記縮小・拡大情報を保持する記憶手段とを有し、
上記決定手段は、現フレームの縮小・拡大率と、上記記億手段から読み出される、前フレームの縮小・拡大率を用いて現フレームの復号ブロックに対応する前フレームの参照ブロックを決定する機能を備え、上記予測手段は、参照ブロックが複数ある場合には、複数の参照ブロックのラベルのうち、数が多いラベルを予測値とするものであることを特徴とする。
Alternatively, the frame reduction / enlargement rate is variable on a frame basis, and means for decoding the reduction / enlargement rate information;
Storage means for holding the reduction / enlargement information,
The determination means has a function of determining a reference block of the previous frame corresponding to a decoded block of the current frame using the reduction / enlargement ratio of the current frame and the reduction / enlargement ratio of the previous frame read from the storage means. The predicting means is characterized in that, when there are a plurality of reference blocks, a label having a large number among the labels of the plurality of reference blocks is used as a predicted value.

また、水平・垂直方向共に1/2N (N=1,2,3,…)に縮小された2値画像のブロックを拡大する拡大回路として、
該ブロック近傍再生値を保持するメモリと、該ブロックの縮小率に応じて上記メモリに保持された再生値を1/2N に縮小することで参照画素値を求める手段と、水平・垂直共に2倍に拡大する処理をN回繰り返すことで元のサイズに拡大する手段とを備え、上記拡大手段においては、常に1/2N に縮小された参照画素値を用いることを特徴とする。
As an enlargement circuit for enlarging a block of a binary image reduced to 1 / 2N (N = 1, 2, 3,...) In both the horizontal and vertical directions,
A memory for holding the reproduction value near the block, a means for obtaining a reference pixel value by reducing the reproduction value held in the memory to 1 / 2N according to the reduction ratio of the block, and a horizontal and vertical double. Means for enlarging to the original size by repeating the process of enlarging N times N times, and the enlarging means always uses a reference pixel value reduced to 1 / 2N.

また、時系列データとして得られる複数フレームの動画像信号を任意形状のオブジェクト毎に符号化する動画像符号化装置であって、オブジェクトを含む方形領域をM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に分割すると共に、この分割されて得られた上記ブロック毎に、前記方形領域内を一定規則により順次、符号化する画像符号化装置であって、
上記フレーム内において、オブジェクトを含むブロックサイズの倍数で表される領域を設定する設定手段と、この設定手段により設定された領域内をブロックに分割する分割手段と、分割された上記ブロック内を動き補償予測するために必要な動きベクトルを予測符号化する手段とを有する画像符号化装置において、
参照フレーム内の領域のフレーム内における位置を表す第1の位置ベクトルを保持するメモリと、該参照フレーム内領域のフレーム内での位置を表す第2の位置ベクトルを符号化する符号化手段と、符号化対象ブロック近傍の再生済みのブロックの動きベクトルを保持する動きベクトルメモリと、上記動きベクトルメモリに蓄えられている動きベクトルを用いて、符号化対象ブロックの動きベクトルを予測する手段とを備えてなり、
上記予測手段において使用する動きベクトルが、前記動きベクトルメモリに存在しない場合にはデフォルトの動きベクトルを予測値とし、このデフォルトの動きベクトルは第1の位置ベクトルと第2の位置ベクトルとの差分ベクトルと、ゼロベクトルを切り換えて用いるようにすることを特徴とする。
Further, the present invention is a moving image encoding apparatus that encodes a plurality of frames of moving image signals obtained as time series data for each object having an arbitrary shape, and includes a square area including the object of M × N pixels (M: horizontal pixels). And N: the number of pixels in the vertical direction), and an image encoding device that sequentially encodes the inside of the rectangular area according to a predetermined rule for each of the blocks obtained by the division. Because
Setting means for setting an area represented by a multiple of the block size including the object in the frame, a dividing means for dividing the area set by the setting means into blocks, and a motion in the divided block In an image coding apparatus having means for predictively coding a motion vector necessary for compensated prediction,
A memory for holding a first position vector representing the position of the region in the reference frame in the frame; an encoding means for encoding a second position vector representing the position of the region in the reference frame in the frame; A motion vector memory that holds a motion vector of a reproduced block near the encoding target block, and means for predicting a motion vector of the encoding target block using the motion vector stored in the motion vector memory. And
When the motion vector used in the prediction means does not exist in the motion vector memory, a default motion vector is used as a predicted value, and the default motion vector is a difference vector between the first position vector and the second position vector. The zero vector is switched and used.

また、時系列データとして得られる複数フレームの動画像信号を任意形状のオブジェクト毎に復号化する動画像復号化装置であって、オブジェクトを含むM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に、その方形領域内を一定規則により順次、復号化する画像復号化装置であって、該フレーム内において、オブジェクトを含むブロックサイズの倍数で表される領域をブロック毎に再生する画像復号化装置において、
上記ブロック内を動き補償予測するために必要な、予測符号化された動きベクトルを復号する手段と、参照フレーム内を動き補償予測するために必要な、予測符号化された動きベクトルを復号する手段と、参照フレーム内の領域のフレーム内での位置を表す第1の位置ベクトルを保持するメモリと、該フレーム内の領域のフレーム内での位置を表す第2の位置ベクトルを復号化する手段と、復号化対象ブロック近傍の補正済みのブロックの動きベクトルを保持する動きベクトルメモリと、上記動きベクトルメモリに保持された動きベクトルを用いて、復号化対象ブロックの動きベクトルを予測する予測手段とを有し、
上記予測手段で使用するための動きベクトルが、上記動きベクトルメモリに存在しない場合にはデフォルトの動きベクトルを予測値とし、このデフォルトの動きベクトルは第1の位置ベクトルと第2の位置ベクトルとの差分ベクトルと、ゼロベクトルのいずれかとすることを特徴とする。
Further, it is a moving picture decoding apparatus that decodes a plurality of frames of moving picture signals obtained as time series data for each object having an arbitrary shape, and includes M × N pixels (M: number of pixels in the horizontal direction, N : A picture decoding apparatus that sequentially decodes the rectangular area in accordance with a certain rule for each block composed of: (number of pixels in the vertical direction), and is represented by a multiple of the block size including the object in the frame. In an image decoding device that reproduces a block area for each block,
Means for decoding motion-predicted motion vectors necessary for motion compensation prediction in the block, and means for decoding motion-predicted motion vectors necessary for motion compensation prediction in the reference frame And a memory for holding a first position vector representing the position of the region in the reference frame within the frame, and a means for decoding the second position vector representing the position of the region within the frame within the frame; A motion vector memory that holds a motion vector of a corrected block near the decoding target block, and a prediction unit that predicts a motion vector of the decoding target block using the motion vector held in the motion vector memory. Have
If a motion vector to be used by the prediction means does not exist in the motion vector memory, a default motion vector is used as a predicted value, and the default motion vector is a combination of the first position vector and the second position vector. It is characterized by being either a difference vector or a zero vector.

本発明によれば、アルファマップの符号量を低減することができるため、フレーム単位で符号化する従来の符号化法と比べて、大幅な符号化効率の低下なしにオブジェクト毎に別々に符号化することができるようになる。   According to the present invention, since the amount of alpha map code can be reduced, encoding is performed separately for each object without a significant decrease in encoding efficiency compared to the conventional encoding method in which encoding is performed in units of frames. Will be able to.

以下、本発明の具体例について、図面を参照して説明する。初めに、本発明が適用される画像符号化および画像復号化装置について概略を説明しておく。   Hereinafter, specific examples of the present invention will be described with reference to the drawings. First, an outline of an image encoding and image decoding apparatus to which the present invention is applied will be described.

(本発明が適用される画像符号化および画像復号化装置)
図1は、画像を符号化する場合に、画面内を背景とオブジェクトに分割して符号化する方式であって本発明を適用した画像符号化装置のブロック図である。本発明における画像符号化装置は、図1に示すように、差分回路100、動き補償予測回路(MC)110、直交変換回路120、量子化回路130、可変長符号化回路(VLC)140、逆量子化回路(IQ)150、逆直交変換回路160、加算回路170、多重化回路180、アルファマップ符号化回路200とから構成される。
(Image coding and image decoding apparatus to which the present invention is applied)
FIG. 1 is a block diagram of an image encoding apparatus to which the present invention is applied, which is a method of encoding an image by dividing the screen into a background and an object. As shown in FIG. 1, the image coding apparatus according to the present invention includes a difference circuit 100, a motion compensation prediction circuit (MC) 110, an orthogonal transformation circuit 120, a quantization circuit 130, a variable length coding circuit (VLC) 140, and an inverse circuit. A quantization circuit (IQ) 150, an inverse orthogonal transform circuit 160, an adder circuit 170, a multiplexing circuit 180, and an alpha map encoding circuit 200 are configured.

アルファマップ符号化回路200は、入力されたアルファマップを符号化し、この符号化された信号をアルファマップ信号として多重化回路180に出力する機能と、このアルファマップ信号を復号して局部復号信号として出力する機能を有する。   The alpha map encoding circuit 200 encodes the input alpha map and outputs the encoded signal to the multiplexing circuit 180 as an alpha map signal, and decodes the alpha map signal as a local decoded signal. Has a function to output.

特に、本アルファマップ符号化回路200は、入力されたアルファマップを符号化するにあたり、与えられた縮小率(倍率)で解像度を縮小する処理を行い、この解像度縮小処理されたものを符号化すると共に、この符号化したものと縮小率の情報(倍率情報)とを多重化してこれをアルファマップ信号として多重化回路180に出力する機能を有する。そして、局部復号信号としては、解像度縮小処理されたものを元の解像度に戻す処理をして得たものを用いる構成である。   In particular, the present alpha map encoding circuit 200 performs a process of reducing the resolution at a given reduction rate (magnification) when encoding the input alpha map, and encodes the resolution reduced process. At the same time, it has a function of multiplexing the encoded data and reduction rate information (magnification information) and outputting the multiplexed data to the multiplexing circuit 180 as an alpha map signal. As the local decoded signal, a signal obtained by performing processing for returning the resolution-reduced signal to the original resolution is used.

差分回路100は、動き補償予測回路110より供給される動き補償予測信号と入力画像信号との差分信号を算出するものであり、直交変換回路120は、差分回路100から供給された差分信号を、アルファマップの情報にしたがって、直交変換係数に変換して出力するものである。   The difference circuit 100 calculates a difference signal between the motion compensation prediction signal supplied from the motion compensation prediction circuit 110 and the input image signal, and the orthogonal transformation circuit 120 converts the difference signal supplied from the difference circuit 100 into the difference signal. According to the information of the alpha map, it is converted into an orthogonal transform coefficient and output.

量子化回路130はこの直交変換回路120により得られた直交変換係数を量子化する回路であり、可変長符号化回路140はこの量子化回路130の出力を符号化して出力するものである。多重化回路180はこの可変長符号化回路140により符号化されたものと、前記アルファマップ信号とを、動きベクトル情報等のサイド情報と共に多重化多重化してビットストリームとして出力するものである。   The quantization circuit 130 is a circuit that quantizes the orthogonal transform coefficient obtained by the orthogonal transform circuit 120, and the variable length coding circuit 140 codes and outputs the output of the quantization circuit 130. The multiplexing circuit 180 multiplexes and multiplexes the signal encoded by the variable length encoding circuit 140 and the alpha map signal together with side information such as motion vector information and outputs the result as a bit stream.

逆量子化回路150は量子化回路130の出力を逆量子化するものであり、逆直交変換回路160はこの逆量子化回路150の出力を前記アルファマップに基いて逆直交変換するものであり、加算回路170はこの逆直交変換回路160の出力と動き補償予測回路110から与えられる予測信号(動き補償予測信号)とを加算して差分回路100に出力するものである。   The inverse quantization circuit 150 performs inverse quantization on the output of the quantization circuit 130, and the inverse orthogonal transform circuit 160 performs inverse orthogonal transform on the output of the inverse quantization circuit 150 based on the alpha map. The adder circuit 170 adds the output of the inverse orthogonal transform circuit 160 and the prediction signal (motion compensation prediction signal) given from the motion compensation prediction circuit 110 and outputs the result to the difference circuit 100.

動き補償予測回路110は、フレームメモリを有し、アルファマップ復号化回路200から与えられる局部復号信号にもとづいて動作してオブジェクト領域の信号、背景領域の信号を蓄積する機能を有する。また、動き補償予測回路110は蓄積したオブジェクト領域の画像から動き補償値を予測して予測値として出力し、また、蓄積した背景領域の画像から動き補償値を予測して予測値として出力する機能を有する。   The motion compensation prediction circuit 110 has a frame memory and has a function of accumulating an object area signal and a background area signal by operating based on a local decoded signal supplied from the alpha map decoding circuit 200. The motion compensation prediction circuit 110 also predicts a motion compensation value from the accumulated image of the object region and outputs it as a prediction value, and predicts a motion compensation value from the accumulated image of the background region and outputs it as a prediction value. Have

このような構成の本装置の作用を説明する。本装置には、画像信号とその画像信号のアルファマップが入力される。   The operation of the apparatus having such a configuration will be described. The apparatus receives an image signal and an alpha map of the image signal.

そして、これらのうち、画像信号はフレーム毎にそれぞれ所定画素サイズ(例えば、M×N画素(M:水平方向の画素数、N:垂直方向の画素数))のブロックに分割された後、ブロック位置順に信号線10を介して差分回路100に供給される。そして、差分回路100では、この入力(画像信号)と、予測信号(オブジェクト予測回路110からの動き補償予測信号の出力)との差分信号が算出され、直交変換回路120に供給される。   Of these, the image signal is divided into blocks each having a predetermined pixel size (for example, M × N pixels (M: number of pixels in the horizontal direction, N: number of pixels in the vertical direction)) for each frame, and then the blocks The signals are supplied to the difference circuit 100 via the signal line 10 in the order of position. The difference circuit 100 calculates a difference signal between the input (image signal) and the prediction signal (output of the motion compensation prediction signal from the object prediction circuit 110) and supplies the difference signal to the orthogonal transformation circuit 120.

直交変換回路120では、供給された差分信号を、信号線40を介してアルファマップ符号化回路200から供給されるアルファマップの情報にしたがって、直交変換係数に変換した後、量子化回路130に供給する。そして、ここで量子化される。量子化回路130にて量子化されて得られた変換係数は、可変長符号化回路140において符号化されると共に、逆量子化回路150に供給される。   In the orthogonal transform circuit 120, the supplied difference signal is converted into an orthogonal transform coefficient in accordance with the information of the alpha map supplied from the alpha map encoding circuit 200 via the signal line 40, and then supplied to the quantization circuit 130. To do. And it is quantized here. The transform coefficient obtained by quantization by the quantization circuit 130 is encoded by the variable length encoding circuit 140 and supplied to the inverse quantization circuit 150.

逆量子化回路150に供給された変換係数は、ここで逆量子化された後、逆直交変換回路160において逆変換される。そして、加算回路170において動き補償予測回路110より供給される動き補償予測値と加算され、局部復号画像として出力されて、再び動き補償予測回路110に入力される。   The transform coefficient supplied to the inverse quantization circuit 150 is inversely quantized here, and then inverse transformed in the inverse orthogonal transform circuit 160. Then, the addition circuit 170 adds the motion compensation prediction value supplied from the motion compensation prediction circuit 110, outputs it as a locally decoded image, and inputs it again to the motion compensation prediction circuit 110.

そして、この加算回路170の出力である局部復号画像は、動き補償予測回路110内のフレームメモリに蓄えられる。   The locally decoded image that is the output of the adder circuit 170 is stored in the frame memory in the motion compensation prediction circuit 110.

一方、この動き補償予測回路110は、アルファマップ復号化回路200から与えられる局部復号信号に基づいてオブジェクトの領域のブロックの処理のタイミングでは“オブジェクトの動き補償予測値”を、また、それ以外のタイミングでは“背景部分の動き補償予測値”を出力して差分回路100に与える。   On the other hand, the motion compensation prediction circuit 110 generates an “object motion compensation prediction value” at the processing timing of the block in the object region based on the local decoded signal given from the alpha map decoding circuit 200, and other than that. At the timing, the “background portion motion compensation predicted value” is output and supplied to the difference circuit 100.

すなわち、動き補償予測回路110ではアルファマップ信号の局部復号信号から現在、オブジェクトのブロック対応部分の画像信号が差分回路100に入力されているのか、あるいは背景部分のブロック対応部分の画像信号が差分回路100に入力されているのかを知り、オブジェクトのブロック対応部分の画像信号の入力期間中であれば、オブジェクトの動き補償予測信号を、そして、背景部分のブロック対応部分の画像信号入力期間中であれば、背景の動き補償予測信号を、差分回路100に与える。   That is, in the motion compensation prediction circuit 110, whether the image signal of the block corresponding portion of the object is currently input to the difference circuit 100 from the local decoded signal of the alpha map signal, or the image signal of the block corresponding portion of the background portion is the difference circuit. If it is during the input period of the image signal of the object corresponding to the block of the object, the motion compensation prediction signal of the object and the image signal input period of the block corresponding part of the background portion may be detected. For example, the background motion compensation prediction signal is supplied to the difference circuit 100.

差分回路100では、この入力された画像信号と、その画像の領域対応の予測信号との差を算出するので、その結果、入力画像がオブジェクト対応の領域のものであれば、そのオブジェクトの対応位置での予測値との差分信号が、また、入力画像が背景の領域のものであれば、その背景位置対応の予測値との差分信号が算出され、直交変換回路120に供給される。   The difference circuit 100 calculates the difference between the input image signal and the prediction signal corresponding to the region of the image. As a result, if the input image is in the region corresponding to the object, the corresponding position of the object If the difference signal from the predicted value in FIG. 4 is a background region, the difference signal from the predicted value corresponding to the background position is calculated and supplied to the orthogonal transformation circuit 120.

直交変換回路120では、供給された差分信号を信号線40を介して供給されるアルファマップの情報にしたがって、直交変換係数に変換した後、量子化回路130に供給する。そして、直交変換係数はこの量子化回路130にて量子化される。   In the orthogonal transform circuit 120, the supplied differential signal is converted into an orthogonal transform coefficient according to the information of the alpha map supplied via the signal line 40, and then supplied to the quantization circuit 130. The orthogonal transform coefficient is quantized by the quantization circuit 130.

量子化回路130にて量子化された変換係数は、可変長符号化回路140において符号化されると共に、逆量子化回路150に供給される。そして、逆量子化回路150に供給された変換係数はここで逆量子化された後、逆直交変換回路160において逆変換されて加算回路170に供給される。そして、予測値切り換え回路500を介して加算回路170に供給される予測値と加算されることになる。   The transform coefficient quantized by the quantization circuit 130 is encoded by the variable length encoding circuit 140 and supplied to the inverse quantization circuit 150. The transform coefficient supplied to the inverse quantization circuit 150 is inversely quantized here, and then inverse transformed in the inverse orthogonal transform circuit 160 and supplied to the adder circuit 170. Then, the predicted value supplied to the adding circuit 170 via the predicted value switching circuit 500 is added.

加算回路170の出力である局部復号画像の信号は、動き補償予測回路110に供給される。そして、この動き補償予測回路110ではアルファマップ信号の局部復号信号から現在、加算回路170からオブジェクトのブロック対応の信号が出力されているのか、あるいは背景部分のブロック対応の信号が出力されているのかを知り、その結果、オブジェクトのブロック対応の信号の出力中であれば、オブジェクト用のフレームメモリに、また、背景部分のブロック対応の信号の出力中であれば、背景用のメモリに与えるべく動作して対応のメモリに蓄える。   The signal of the locally decoded image that is the output of the adder circuit 170 is supplied to the motion compensation prediction circuit 110. In this motion compensation prediction circuit 110, whether the signal corresponding to the block of the object is currently output from the local decoding signal of the alpha map signal, or whether the signal corresponding to the block of the background portion is output. As a result, if the signal corresponding to the block of the object is being output, it is applied to the frame memory for the object, and if the signal corresponding to the block of the background portion is being output, the operation is performed to the background memory. And store it in the corresponding memory.

そして、これにより、オブジェクト用のフレームメモリにはオブジェクト画像のみが、また、背景用のメモリには背景画像のみの画像が得られることになる。これにより、動き補償予測回路110はオブジェクト画像を利用してオブジェクト画像の予測値を求めることができ、また、背景部分の画像を利用して背景画像の予測値を求めることができる。   Thus, only the object image is obtained in the object frame memory, and only the background image is obtained in the background memory. As a result, the motion compensation prediction circuit 110 can obtain the predicted value of the object image using the object image, and can obtain the predicted value of the background image using the image of the background portion.

上述したように、アルファマップ符号化回路200では、入力されるアルファマップを符号化し、この符号化されたアルファマップ信号を信号線30を介して多重化回路180に供給している。   As described above, the alpha map encoding circuit 200 encodes an input alpha map, and supplies the encoded alpha map signal to the multiplexing circuit 180 via the signal line 30.

また、多重化回路180には、可変長符号化回路140から出力された変換係数が線40を介して供給されている。そして、多重化回路180は供給されているこれらアルファマップ信号および変換係数の符号化値とを、動きベクトル情報等のサイド情報と共に多重化した後、信号線50を介して出力して本画像符号化装置の最終出力としての符号化ビットストリームとなる。   Further, the transform coefficient output from the variable length coding circuit 140 is supplied to the multiplexing circuit 180 via the line 40. The multiplexing circuit 180 multiplexes the supplied alpha map signal and the encoded value of the transform coefficient together with side information such as motion vector information, and then outputs the multiplexed image signal via the signal line 50 to output the main image code. The encoded bit stream is the final output of the encoding device.

以上が符号化装置の構成と作用であり、画像の誤差信号を得るにあたって、オブジェクト用および背景用の画像により動き補償予測を行うべく、アルファマップにしたがって処理中の画像の現在ブロック位置がオブジェクト領域位置であるのか、背景領域位置であるのかを判別しながら、処理中の画像の現在ブロック位置がオブジェクト領域位置であればオブジェクト用の画像から求めた予測値を用い、背景領域位置であれば背景用の画像から求めた予測値を用いて差分を求めるようにした。   The above is the configuration and operation of the encoding device. When obtaining an error signal of an image, the current block position of the image being processed according to the alpha map is the object region in order to perform motion compensation prediction using the object and background images. If the current block position of the image being processed is the object area position, the predicted value obtained from the object image is used while determining whether the current position is the position or the background area position. The difference is obtained using the predicted value obtained from the image for use.

そして、オブジェクト用および背景用の予測には動き補償予測回路に、この差分から得た画像について、アルファマップにしたがってそれぞれ対応の領域部分の画像を保持させ、予測に供するようにした。これにより、オブジェクトおよび背景それぞれで最適な動き補償予測を行うことができるようになり、質の良い画像圧縮符号化と復号化を可能にする。   Then, for object and background prediction, the motion compensation prediction circuit holds the images of the corresponding region portions of the images obtained from the differences according to the alpha map, and is used for the prediction. As a result, optimal motion compensation prediction can be performed for each object and background, enabling high-quality image compression encoding and decoding.

一方、図2は本発明が用いられる復号化装置のブロック図である。復号化装置は、図2に示すように、分離化回路300、可変長復号化回路310、逆量子化回路320、逆直交変換回路330、加算回路340、動き補償予測回路350、アルファマップ復号化回路400とより構成される。   On the other hand, FIG. 2 is a block diagram of a decoding apparatus in which the present invention is used. As shown in FIG. 2, the decoding apparatus includes a separation circuit 300, a variable length decoding circuit 310, an inverse quantization circuit 320, an inverse orthogonal transform circuit 330, an addition circuit 340, a motion compensation prediction circuit 350, an alpha map decoding. The circuit 400 is constituted.

分離化回路300は入力される符号化ビットストリームを分離化処理してアルファマップ信号と画像の符号化信号等を得る回路であり、アルファマップ復号化回路400はこの分離化回路300にて分離されたアルファマップ信号を復号してアルファマップを再生する回路である。   The separation circuit 300 is a circuit that obtains an alpha map signal and a coded image signal by separating the input encoded bit stream, and the alpha map decoding circuit 400 is separated by the separation circuit 300. This circuit decodes the alpha map signal and reproduces the alpha map.

可変長復号化回路310は、分離化回路300にて分離された画像の符号化信号を復号するものであり、逆量子化回路320はこの復号されたものを逆量子化して元の係数に戻すものであり、逆直交変換回路330はこの係数をアルファマップにしたがって逆直交変換して予測誤差信号に戻すものであり、加算回路340は、この予測誤差信号に動き補償予測回路350からの動き補償予測値を加算して再生画像信号として出力するものである。この再生画像信号が復号化装置の最終出力となる。   The variable length decoding circuit 310 decodes the encoded signal of the image separated by the separation circuit 300, and the inverse quantization circuit 320 inversely quantizes the decoded signal to return to the original coefficient. The inverse orthogonal transform circuit 330 performs inverse orthogonal transform on the coefficients in accordance with the alpha map to return the prediction error signal to the prediction error signal. The adder circuit 340 applies the motion compensation from the motion compensation prediction circuit 350 to the prediction error signal. The predicted value is added and output as a reproduced image signal. This reproduced image signal becomes the final output of the decoding apparatus.

動き補償予測回路350は、加算回路340から出力された再生画像信号をアルファマップにしたがってフレームメモリに蓄積することによりオブジェクト画像と背景画像とを得ると共に、この蓄積されて得られた画像からオブジェクトの動き補償予測信号、背景の動き補償予測を得るものである。   The motion compensation prediction circuit 350 obtains an object image and a background image by accumulating the reproduced image signal output from the adder circuit 340 in a frame memory according to an alpha map, and obtains an object image from the accumulated image. A motion compensation prediction signal and a background motion compensation prediction are obtained.

このような構成の復号化装置においては、符号化ビットストリームは、線70を介して分離化回路300に供給され、分離化回路300において各々の情報毎に分離されることにより、アルファマップ信号に関する符号と、画像信号の可変長符号とに分けられる。   In the decoding apparatus having such a configuration, the encoded bit stream is supplied to the demultiplexing circuit 300 via the line 70 and is separated for each piece of information by the demultiplexing circuit 300, so that the alpha map signal is related. It is divided into a code and a variable length code of the image signal.

そして、アルファマップ信号に関する符号は、信号線80を介してアルファマップ復号化回路400に供給され、また、画像信号の可変長符号は可変長復号化回路310にそれぞれ供給される。   The code relating to the alpha map signal is supplied to the alpha map decoding circuit 400 via the signal line 80, and the variable length code of the image signal is supplied to the variable length decoding circuit 310, respectively.

アルファマップ信号に関する符号はアルファマップ復号化回路400においてアルファマップ信号に再生され、信号線90を介して逆直交変換回路330と動き補償予測回路350に出力される。   The code relating to the alpha map signal is reproduced as an alpha map signal by the alpha map decoding circuit 400 and output to the inverse orthogonal transform circuit 330 and the motion compensation prediction circuit 350 via the signal line 90.

一方、可変長復号化回路310では、分離化回路300から供給される符号を復号し、逆量子化回路320に供給して、ここで逆量子化する。逆量子化された変換係数は、線90を介して供給されるアルファマップにしたがって逆直交変換回路330により逆変換され、加算回路340に供給される。加算回路340では、逆直交変換回路330からの逆直交変換された信号と、動き補償予測回路350より供給される動き補償予測信号とを加算し、再生画像を得る。   On the other hand, the variable length decoding circuit 310 decodes the code supplied from the demultiplexing circuit 300 and supplies it to the inverse quantization circuit 320, where it is inversely quantized. The inversely quantized transform coefficient is inversely transformed by the inverse orthogonal transform circuit 330 according to the alpha map supplied via the line 90 and supplied to the adder circuit 340. The adder circuit 340 adds the inversely orthogonally transformed signal from the inverse orthogonal transform circuit 330 and the motion compensation prediction signal supplied from the motion compensation prediction circuit 350 to obtain a reproduced image.

以上が本発明を適用する画像符号化装置および画像復号化装置の概要である。 本発明は、図1に示す符号化装置の構成要素であるアルファマップ符号化回路200および図2に示す復号化装置の構成要素であるアルファマップ復号化回路400に関わるものであり、具体的な実施形態を示すものである。   The above is the outline of the image coding apparatus and the image decoding apparatus to which the present invention is applied. The present invention relates to an alpha map encoding circuit 200 that is a component of the encoding device shown in FIG. 1 and an alpha map decoding circuit 400 that is a component of the decoding device shown in FIG. An embodiment is shown.

本発明の要部詳細の説明に入る前に、先行技術としてのアルファマップ符号化回路200に触れておく。図3は、先行技術(特願平8−237053号)におけるアルファマップ符号化回路200の構成を示すブロック図である。図に示すように、先行技術におけるアルファマップ符号化回路200は、解像度変換回路(縮小回路)210、(拡大回路)230、2値画像符号化回路(block-based MMR encoder )220、多重化回路240とから構成されている。   Prior to describing the details of the main part of the present invention, the alpha map encoding circuit 200 as the prior art will be mentioned. FIG. 3 is a block diagram showing a configuration of an alpha map encoding circuit 200 in the prior art (Japanese Patent Application No. 8-237053). As shown in the figure, an alpha map encoding circuit 200 in the prior art includes a resolution conversion circuit (reduction circuit) 210, an (enlargement circuit) 230, a binary image encoding circuit (block-based MMR encoder) 220, a multiplexing circuit. 240.

これらのうち、解像度変換回路210は解像度縮小変換用の変換回路であり、与えられる拡大率に従った縮小率でアルファマップを符号化し、また、解像度変換回路230は解像度縮拡大変換用の変換回路であって、与えられる拡大率に従った拡大率でアルファマップを符号化する機能を有する。   Among these, the resolution conversion circuit 210 is a conversion circuit for resolution reduction conversion, encodes an alpha map at a reduction rate according to a given enlargement rate, and the resolution conversion circuit 230 is a conversion circuit for resolution reduction / enlargement conversion. And it has a function which encodes an alpha map with the expansion rate according to the expansion rate given.

解像度変換回路230は解像度変換回路210が解像度縮小変換したものを元のサイズに戻すために設けてあり、この解像度変換回路230により元のサイズに戻されたアルファマップが、信号線40を介して直交変換回路120,逆直交変換回路160に与えられるアルファマップ局部復号信号となる。   The resolution conversion circuit 230 is provided in order to restore the resolution converted by the resolution conversion circuit 210 to the original size, and the alpha map restored to the original size by the resolution conversion circuit 230 is transmitted via the signal line 40. It becomes an alpha map local decoded signal given to the orthogonal transformation circuit 120 and the inverse orthogonal transformation circuit 160.

2値画像符号化回路220は解像度変換回路210の出力する解像度縮小変換されたアルファマップ信号を2値画像符号化して出力するものであり、多重化回路240は2値画像符号化出力と前記信号線60を介して与えられる拡大率の情報とを多重化して出力するものである。   The binary image encoding circuit 220 performs binary image encoding on the alpha map signal that has been subjected to resolution reduction conversion output from the resolution conversion circuit 210, and outputs the binary image encoding output. The information of the enlargement ratio given through the line 60 is multiplexed and output.

このような構成のアルファマップ符号化回路200においては、アルファマップ信号入力線20を介して入力されるアルファマップを、解像度変換回路210により指定の拡大率で縮小符号化し、この符号化されたアルファマップ信号を信号線30を介して出力し、また、縮小符号化されたアルファマップ信号を解像度変換回路230により元の解像度に復号して得た局部復号信号を信号線40を介して直交変換回路120,逆直交変換回路160に出力する。   In the alpha map encoding circuit 200 having such a configuration, the alpha map input via the alpha map signal input line 20 is reduced and encoded at a specified enlargement rate by the resolution conversion circuit 210, and the encoded alpha map is displayed. The map signal is output via the signal line 30, and the local decoded signal obtained by decoding the reduced-encoded alpha map signal to the original resolution by the resolution conversion circuit 230 is converted to the orthogonal conversion circuit via the signal line 40. 120, and output to the inverse orthogonal transform circuit 160.

すなわち、信号線60を介してアルファマップ符号化回路200に所望とする縮小・拡大率の設定情報を供給することで、上記トレードオフを図ることが可能となる。   That is, by supplying the desired reduction / enlargement ratio setting information to the alpha map encoding circuit 200 via the signal line 60, the above trade-off can be achieved.

信号線60を介して供給された縮小・拡大率の設定情報信号は、解像度変換回路210,230、2値画像符号化回路220に供給され、アルファマップ信号の発生符号量を制御することが可能となる。また、信号線60を介して供給された縮小・拡大率の符号(設定情報信号)は、多重化回路240にて、符号化されたアルファマップ信号と多重化され、信号線30を介して出力され、アルファマップの符号化信号として画像符号化装置の最終出力段である多重化回路180に与えられることになる。   The setting information signal of the reduction / enlargement ratio supplied via the signal line 60 is supplied to the resolution conversion circuits 210 and 230 and the binary image encoding circuit 220, and the generated code amount of the alpha map signal can be controlled. It becomes. Further, the code of the reduction / enlargement ratio (setting information signal) supplied via the signal line 60 is multiplexed with the encoded alpha map signal by the multiplexing circuit 240 and output via the signal line 30. Then, it is supplied as an alpha map encoded signal to the multiplexing circuit 180 which is the final output stage of the image encoding apparatus.

次に先行技術としてのアルファマップ復号化回路400に触れておく。図4は先行技術(特願平8−237053号)における具体的なアルファマップ復号化回路400である。   Next, the alpha map decoding circuit 400 as a prior art will be mentioned. FIG. 4 shows a specific alpha map decoding circuit 400 in the prior art (Japanese Patent Application No. 8-237053).

図に示すように、アルファマップ復号化回路400は、2値画像復号化回路410(block-based MMR decoder )、解像度変換回路420、分離化回路430にて構成される。   As shown in the figure, the alpha map decoding circuit 400 includes a binary image decoding circuit 410 (block-based MMR decoder), a resolution conversion circuit 420, and a separation circuit 430.

分離化回路430は、図2に示す画像復号化装置内の分離化回路300で分離されて当該アルファマップ復号化回路400に入力されたアルファマップ信号からアルファマップ信号の符号と縮小・拡大率の符号(縮小・拡大率の設定情報信号)に分離する回路であり、2値画像復号化回路410はアルファマップ信号の符号を、分離化回路430から分離して与えられる縮小・拡大率の符号にしたがって2値画像に戻す回路であり、解像度変換回路420はこの2値画像を、分離化回路430から分離して与えられる縮小・拡大率の符号にしたがって解像度拡大変換して出力するものである。   The demultiplexing circuit 430 determines the sign of the alpha map signal and the reduction / enlargement ratio from the alpha map signal separated by the demultiplexing circuit 300 in the image decoding apparatus shown in FIG. 2 and input to the alpha map decoding circuit 400. The binary image decoding circuit 410 converts the code of the alpha map signal into the code of the reduction / enlargement ratio that is given separately from the separation circuit 430. Therefore, this is a circuit for converting back to a binary image, and the resolution conversion circuit 420 converts the binary image according to the sign of the reduction / enlargement ratio given separately from the separation circuit 430 and outputs the result.

図4において、信号線80を介してアルファマップ復号化回路400に供給された符号は、分離化回路430によりアルファマップ信号の符号と縮小・拡大率の符号に分離され、各々信号線81および信号線82を介して出力される。   In FIG. 4, the code supplied to the alpha map decoding circuit 400 via the signal line 80 is separated into the code of the alpha map signal and the code of the reduction / enlargement ratio by the separation circuit 430. It is output via line 82.

2値画像復号化回路410では、信号線81を介して供給されるアルファマップ信号の符号と信号線82を介して供給される縮小・拡大率の符号から、縮小されたアルファマップ信号を再生し、信号線83を介して解像度変換回路420に供給する。解像度変換回路420では、信号線82を介して供給される縮小・拡大率の符号から、縮小されたアルファマップ信号を元のサイズに拡大してアルファマップ信号を再生した後、信号線90を介して出力する。   The binary image decoding circuit 410 reproduces a reduced alpha map signal from the code of the alpha map signal supplied via the signal line 81 and the code of the reduction / enlargement ratio supplied via the signal line 82. , And supplied to the resolution conversion circuit 420 via the signal line 83. The resolution conversion circuit 420 reproduces the alpha map signal by enlarging the reduced alpha map signal to the original size from the sign of the reduction / enlargement ratio supplied via the signal line 82, and then via the signal line 90. Output.

以上が、本発明を適用する前提となる符号化回路および復号化回路の概要である。   The above is the outline of the encoding circuit and the decoding circuit on which the present invention is applied.

次に、このような符号化回路および復号化回路に適用する本発明の詳細を説明する。はじめに、変化画素の位置を特定するシンボルを可変長符号化テーブルを用いて符号化するにあたり、出現頻度の多いシンボルには短い符号を割り当てるように可変長符号化テーブル(VLCテーブル)を作っておくことにより、総符号量を少なくする場合に、既に符号化/復号化されたアルファマップの画素パターンによって、可変長符号化テーブル(VLCテーブル)を適応的に切り替えることで、さらに符号量を削減するようにした具体例を説明する。   Next, details of the present invention applied to such an encoding circuit and decoding circuit will be described. First, a variable length coding table (VLC table) is created so that a short code is assigned to a symbol having a high appearance frequency when a symbol that specifies the position of a change pixel is coded using a variable length coding table. Thus, when the total code amount is reduced, the code amount is further reduced by adaptively switching the variable length coding table (VLC table) according to the already encoded / decoded alpha map pixel pattern. A specific example will be described.

(第1の具体例)
第1の具体例に示す本発明は、変化画素の位置を特定するシンボルを可変長符号化テーブルを用いて符号化し、既に符号化した前記アルファマップのパターンによって、その可変長符号化テーブルを切り替えることを特徴とするものである。
(First specific example)
The present invention shown in the first specific example encodes a symbol specifying the position of a change pixel using a variable-length encoding table, and switches the variable-length encoding table according to the already-encoded alpha map pattern. It is characterized by this.

本発明の第1の具体例を説明する。   A first specific example of the present invention will be described.

図3の2値画像符号化回路220では、図17で示した可変長符号化テーブル(VLCテーブル)を用いて、変化画素の位置を表すシンボル(Mode)が符号化される。例えば、垂直パスモードが“FALSE”で、“V0(垂直モードでr_a1−r_b1=0)”であった時には符号として“1”を出力する。あるいは、“V1(垂直モードで|r_a1−r_b1|=1)”の時は“01s” (s:r_a1−r_b1の正負によって“0”あるいは“1”)を出力し、 “EOMB(符号化終了)”の時は“0001”を出力する。   In the binary image encoding circuit 220 in FIG. 3, a symbol (Mode) representing the position of the changed pixel is encoded using the variable length encoding table (VLC table) shown in FIG. 17. For example, when the vertical path mode is “FALSE” and “V0 (r_a1-r_b1 = 0 in the vertical mode)”, “1” is output as a code. Alternatively, when "V1 (| r_a1-r_b1 | = 1 in vertical mode)", "01s" (s: "0" or "1" depending on the sign of r_a1-r_b1) is output, and "EOMB (end of encoding)" ) ”,“ 0001 ”is output.

一方、図4の2値画像復号化回路410では、符号化に利用したもの同じ図17のVLCテーブルを用いて、例えば、入力された符号が“1”である場合には“V0を再”生し、入力された符号が“0001”である場合には“EOMB”を再生する。   On the other hand, the binary image decoding circuit 410 in FIG. 4 uses the same VLC table in FIG. 17 as that used for encoding. For example, when the input code is “1”, “V0 is regenerated”. If the input code is “0001”, “EOMB” is reproduced.

この場合に、出現頻度の多いシンボルには短い符号を割り当てるように可変長符号化テーブル(VLCテーブル)を作っておけば、総符号量を少なくできる。   In this case, if a variable length coding table (VLC table) is created so that a short code is assigned to a symbol having a high appearance frequency, the total code amount can be reduced.

本発明は、既に符号化/復号化されたアルファマップの画素パターンによって、可変長符号化テーブル(VLCテーブル)を適応的に切り替えることで、さらに符号量を削減するものである。   The present invention further reduces the code amount by adaptively switching the variable length coding table (VLC table) according to the pixel pattern of the alpha map that has already been coded / decoded.

<第1の具体例の符号化回路の構成>
図5は、図1のアルファマップ符号化回路200あるいは、図3の2値画像符号化回路220をより詳細に表した、本発明の一具体例を示すブロック図である。
<Configuration of Encoding Circuit of First Specific Example>
FIG. 5 is a block diagram showing a specific example of the present invention, showing the alpha map encoding circuit 200 of FIG. 1 or the binary image encoding circuit 220 of FIG. 3 in more detail.

アルファマップ信号1は、a1検出回路2、及び符号化済みのアルファマップを保持するメモリ3に入力される。a1検出回路2では、図18等を用いて説明した変化画素a1の位置4が検出され、モード決定回路5に送られる。同時にまた、メモリ3からは参照変化画素b1の位置6がモード決定回路5に送られる。   The alpha map signal 1 is input to an a1 detection circuit 2 and a memory 3 that holds an encoded alpha map. In the a1 detection circuit 2, the position 4 of the change pixel a1 described with reference to FIG. 18 and the like is detected and sent to the mode determination circuit 5. At the same time, the position 6 of the reference change pixel b 1 is sent from the memory 3 to the mode determination circuit 5.

モード決定回路5では、図19を用いて説明したアルゴリズムにより、モードが決定され、そのモードが、符号化されるシンボル7として符号化回路8に送られる。   In the mode determination circuit 5, the mode is determined by the algorithm described with reference to FIG. 19, and the mode is sent to the encoding circuit 8 as a symbol 7 to be encoded.

メモリ3からは、符号化済みの参照変化画素b1の周囲のパターン9が、テーブル決定回路1−10に送られる。テーブル決定回路1−10では、複数の可変長符号化テーブルのうちの一つが選択されて出力される。   From the memory 3, the pattern 9 around the encoded reference change pixel b1 is sent to the table determination circuit 1-10. The table determination circuit 1-10 selects and outputs one of a plurality of variable length coding tables.

ここで、例えば、図7に示すように、参照変化画素b1の上方において、右上から左下向きのエッジがある場合は、参照変化画素b1の下方にも同じエッジが直線的に延びる場合が多いので、画素x1、x2、x3の中ではx1にa1がある確率が高い。   Here, for example, as shown in FIG. 7, when there is an edge from the upper right to the lower left above the reference change pixel b1, the same edge often extends linearly below the reference change pixel b1. Among the pixels x1, x2, and x3, there is a high probability that a1 is in x1.

そこで、参照変化画素b1の上方がこのようなパターンの時には、VL1(r_a1−r_b1=−1)に短い符号を割り当てたテーブルを用いる。   Therefore, when the pattern above the reference change pixel b1 has such a pattern, a table in which a short code is assigned to VL1 (r_a1-r_b1 = −1) is used.

<テーブル決定方法のより詳細な具体例>
テーブル決定方法のより詳細な具体例を図8と図9に示す。ここでは、図8に示した参照変化画素b1の上2ラインのc0〜c5に着目する。これらの画素が参照変化画素b1と同じ値なら“1”、異なる値なら“0”として、図9に示したように、c0〜c5の順序で“0”と“1”を並べる。
この2進数を10進数に変換したものをコンテキスト番号と呼ぶ。
<Detailed example of table determination method>
A more specific example of the table determination method is shown in FIGS. Here, attention is focused on the upper two lines c0 to c5 of the reference change pixel b1 shown in FIG. If these pixels have the same value as the reference change pixel b1, “1” is set, and if they are different, “0” is set, and “0” and “1” are arranged in the order of c0 to c5 as shown in FIG.
The binary number converted to a decimal number is called a context number.

そして、各々のコンテキスト番号に対応させて、例えば、
[コンテキスト番号=0の時]
V0 1
VL1 010
VR1 011
VL2 000010
VR2 000011
EOMB 0001
H 001
[コンテキスト番号=1の時]
V0 010
VL1 1
VR1 000010
VL2 011
VR2 000011
EOMB 0001
H 001
[コンテキスト番号=2の時]
以下省略
といったように可変長符号化テーブルを用意しておく。
And corresponding to each context number, for example,
[When context number = 0]
V0 1
VL1 010
VR1 011
VL2 000010
VR2 000011
EOMB 0001
H 001
[When context number = 1]
V0 010
VL1 1
VR1 000010
VL2 011
VR2 000011
EOMB 0001
H 001
[When context number = 2]
A variable length coding table is prepared so that it is omitted below.

このテーブルで、
VL1は、r_a1−r_b1=−1を表し、
VL2は、r_a1−r_b1=−2、
VR1は、r_a1−r_b1=1、
VR2は、r_a1−r_b1=2を表す。
In this table,
VL1 represents r_a1-r_b1 = −1,
VL2 is r_a1-r_b1 = −2,
VR1 is r_a1-r_b1 = 1,
VR2 represents r_a1-r_b1 = 2.

図7はコンテキスト番号=1となるので、上のVL1が1ビットで符号化できるテーブルが選択される。   In FIG. 7, since the context number = 1, a table in which the above VL1 can be encoded with 1 bit is selected.

再び図5に戻り、説明を続ける。符号化回路8ではテーブル決定回路1−10から送られてくる選択されたテーブル11を用いて符号12が決定される。そして、その決定した符号12を出力する。   Returning to FIG. 5 again, the description will be continued. The encoding circuit 8 determines the code 12 using the selected table 11 sent from the table determination circuit 1-10. Then, the determined code 12 is output.

図6に、図2に示した復号化装置の構成要素としてのアルファマップ復号化回路400あるいは、図4に示した復号化装置の構成要素としての2値画像復号化回路410を、より詳細に表したブロック構成図を示す。これは、図5の具体例で生成される符号12を復号するものである。   FIG. 6 shows in more detail the alpha map decoding circuit 400 as a component of the decoding device shown in FIG. 2 or the binary image decoding circuit 410 as a component of the decoding device shown in FIG. A block configuration diagram is shown. This decodes the code | symbol 12 produced | generated by the specific example of FIG.

符号12は復号化回路13に入力される。   The code 12 is input to the decoding circuit 13.

メモリ14にはそれまでに復号されたアルファマップが保持されており、参照変化画素b1の周囲のパターン15がテーブル決定回路16に送られる。   The memory 14 holds the alpha map decoded so far, and the pattern 15 around the reference change pixel b1 is sent to the table determination circuit 16.

テーブル決定回路16では、複数の可変長符号化テーブルのうちの一つが選択されたテーブル17として、復号化回路13に送られる。テーブル決定のアルゴリズムは図5のテーブル決定回路1−10と同じである。   In the table determination circuit 16, one of a plurality of variable length coding tables is sent to the decoding circuit 13 as a selected table 17. The table determination algorithm is the same as that of the table determination circuit 1-10 in FIG.

テーブル17によって、シンボル18が復号され、a1再生回路19に送られる。a1再生回路19ではシンボル18とメモリ14から送られてくるb1の位置1−20によってa1の位置を求め、a1までのアルファマップ1−21を再生する。   The symbol 18 is decoded by the table 17 and sent to the a1 reproducing circuit 19. The a1 reproduction circuit 19 obtains the position of a1 based on the symbol 18 and the position 1-20 of b1 sent from the memory 14, and reproduces the alpha map 1-21 up to a1.

再生されたアルファマップ1−21は出力され、また、今後の復号のためにメモリ14に保持される。   The reproduced alpha map 1-21 is output and held in the memory 14 for future decoding.

以上、第1の具体例は、複数の所定の可変長符号化テーブルを切り替えるものであるが、図10に、実際に生起したシンボルの頻度によって、テーブルをダイナミックに修正していく具体例を次に第2の具体例として示す。   As described above, the first specific example switches a plurality of predetermined variable length coding tables. FIG. 10 shows a specific example in which the table is dynamically modified according to the frequency of the symbols actually generated. Is shown as a second specific example.

(第2の具体例)
<第2の具体例の符号化装置の構成>
以上の第1の具体例は、複数の所定の可変長符号化テーブルを切り替えるものであるが、図10に、実際に生起したシンボルの頻度によって、テーブルをダイナミックに修正していく具体例を示す。これは第1の具体例の構成である図5の構成に、カウンタ22とハフマンテーブル生成回路23を加えた構成である。
(Second specific example)
<Configuration of Encoding Device of Second Specific Example>
In the first specific example described above, a plurality of predetermined variable length coding tables are switched. FIG. 10 shows a specific example in which the table is dynamically corrected according to the frequency of symbols that have actually occurred. . This is a configuration in which a counter 22 and a Huffman table generation circuit 23 are added to the configuration of FIG. 5 which is the configuration of the first specific example.

カウンタ22にはモード決定回路5からのシンボル7と、テーブル決定回路1−10からのコンテキスト番号24が入力される。カウンタ22では、各シンボルの発生回数をコンテキスト番号別に保持する。   The counter 22 receives the symbol 7 from the mode determination circuit 5 and the context number 24 from the table determination circuit 1-10. The counter 22 holds the number of occurrences of each symbol for each context number.

そして、一定の時間が経過した後にコンテキスト番号別に各シンボルの発生回数25がハフマンテーブル生成回路23に送られる。   After a certain period of time has elapsed, the number of occurrences 25 of each symbol is sent to the Huffman table generation circuit 23 for each context number.

ハフマンテーブル生成回路23では、ハフマン符号化(藤田「基礎情報理論」(昭晃堂)pp.52−53、1987年)によって符号化テーブル26が
生成される。そのテーブル26がテーブル決定回路1−10に送られて、該当するコンテキスト番号のテーブルがテーブル26で置き換えられる。このハフマンテーブルの生成と置き換えを全てのコンテキスト番号について行う。
In the Huffman table generation circuit 23, the encoding table 26 is generated by Huffman encoding (Fujita "Basic Information Theory" (Shokodo) pp. 52-53, 1987). The table 26 is sent to the table determination circuit 1-10, and the table of the corresponding context number is replaced with the table 26. This Huffman table is generated and replaced for all context numbers.

<第2の具体例の復号化装置の構成>
図10の具体例で生成される符号を復号するための復号化装置を図11に示す。図11に示す第1の具体例としての復号化装置も、やはり、図6ににカウンタ27とハフマンテーブル生成回路28を加えた構成である。
<Configuration of Decoding Device of Second Specific Example>
FIG. 11 shows a decoding apparatus for decoding the code generated in the specific example of FIG. The decoding apparatus as the first specific example shown in FIG. 11 is also configured by adding a counter 27 and a Huffman table generation circuit 28 to FIG.

カウンタ27とハフマンテーブル生成回路28の動作は図10と同じである。 以上述べたように、第1および第2の具体例は、変化画素の位置を特定するシンボルを可変長符号化テーブルを用いて符号化することにより符号量を少なくするようにした符号化/復号化において、複数種の可変長符号化テーブルを用意しておき、既に符号化した前記アルファマップのパターンによって、その可変長符号化テーブルを切り替えることを特徴とするものであり、このような本発明によれば、アルファマップの符号量をいっそう低減できる効果が得られる。   The operations of the counter 27 and the Huffman table generation circuit 28 are the same as those in FIG. As described above, in the first and second specific examples, encoding / decoding is performed in which the code amount is reduced by encoding the symbol specifying the position of the changed pixel using the variable-length encoding table. In the conversion, a plurality of types of variable-length coding tables are prepared, and the variable-length coding tables are switched according to the already-encoded alpha map pattern. According to the above, an effect of further reducing the code amount of the alpha map can be obtained.

次に、相対アドレス符号化の参照変化画素を、M×N画素(M:水平方向の画素数、N:垂直方向の画素数)構成のブロック内の画素値からでなく、動き補償予測信号から求めるようにした具体例を第3の具体例として説明する。   Next, a reference change pixel of relative address encoding is determined not from a pixel value in a block having a configuration of M × N pixels (M: the number of pixels in the horizontal direction and N: the number of pixels in the vertical direction) but from a motion compensation prediction signal. A specific example obtained will be described as a third specific example.

(第3の具体例)
第3の具体例は、相対アドレス符号化の参照変化画素を、上記ブロック内の画素値からだけでなく、動き補償予測信号からも求められることを特徴とするものである。
(Third example)
The third specific example is characterized in that a reference change pixel of relative address encoding is obtained not only from a pixel value in the block but also from a motion compensation prediction signal.

図12は、第3の具体例としてのアルファマップ符号化回路を説明するブロック図である。また、図13は、第3の具体例としてのアルファマップ復号化回路を説明するブロック図である。   FIG. 12 is a block diagram illustrating an alpha map encoding circuit as a third specific example. FIG. 13 is a block diagram illustrating an alpha map decoding circuit as a third specific example.

図12、図13および図14を用いて本発明のアルファマップ符号化回路200およびアルファマップ復号化回路400を説明する。   The alpha map encoding circuit 200 and the alpha map decoding circuit 400 of the present invention will be described with reference to FIGS.

第3の具体例においては、図3に示すアルファマップ符号化回路200を、図12の如く構成し、また、図4に示すアルファマップ復号化回路400を、図13の如く構成する。   In the third specific example, the alpha map encoding circuit 200 shown in FIG. 3 is configured as shown in FIG. 12, and the alpha map decoding circuit 400 shown in FIG. 4 is configured as shown in FIG.

図12に示すように、本具体例のアルファマップ符号化回路200は、解像度変換回路(縮小処理用回路)210、解像度変換回路(拡大処理用回路)230、2値画像符号化回路(block-based MMR encoder )220、多重化回路240、そして、さらに動き補償予測回路250および縮小回路260とから構成されている。   As shown in FIG. 12, the alpha map encoding circuit 200 of this specific example includes a resolution conversion circuit (reduction processing circuit) 210, a resolution conversion circuit (enlargement processing circuit) 230, and a binary image encoding circuit (block-). based MMR encoder) 220, a multiplexing circuit 240, and a motion compensation prediction circuit 250 and a reduction circuit 260.

これらのうち、解像度変換回路210は解像度縮小変換用の変換回路であり、与えられる縮小・拡大率の設定情報信号に従った縮小率でアルファマップを符号化し、また、解像度変換回路230は解像度縮拡大変換用の変換回路であって、与えられる拡大率に従った拡大率でアルファマップを符号化する機能を有する。   Among these, the resolution conversion circuit 210 is a conversion circuit for resolution reduction conversion, encodes an alpha map at a reduction rate according to a given reduction / enlargement rate setting information signal, and the resolution conversion circuit 230 reduces the resolution. This is a conversion circuit for enlargement conversion, and has a function of encoding an alpha map at an enlargement rate according to a given enlargement rate.

解像度変換回路230は解像度変換回路210が解像度縮小変換したものを元のサイズに戻すために設けてあり、この解像度変換回路230により元のサイズに戻されたアルファマップが、信号線40を介して直交変換回路120,逆直交変換回路160に与えられるアルファマップ局部復号信号となる。   The resolution conversion circuit 230 is provided in order to restore the resolution converted by the resolution conversion circuit 210 to the original size, and the alpha map restored to the original size by the resolution conversion circuit 230 is transmitted via the signal line 40. It becomes an alpha map local decoded signal given to the orthogonal transformation circuit 120 and the inverse orthogonal transformation circuit 160.

2値画像符号化回路220は、解像度変換回路210の出力する解像度縮小変換されたアルファマップ信号を2値画像符号化して出力するものであって、詳細は後述するが、縮小処理用の解像度変換回路260から信号線42にて供給される解像度縮小変換されたアルファマップの動き補償予測信号を利用して符号化するものである。また、多重化回路240は2値画像符号化出力と前記与えられる拡大率の情報とを多重化して出力するものである。   The binary image encoding circuit 220 encodes and outputs the alpha map signal that has been subjected to resolution reduction conversion output from the resolution conversion circuit 210 and outputs the binary image. Details will be described later, but resolution conversion for reduction processing will be described later. The encoding is performed using the motion compensated prediction signal of the alpha map that has been resolution-reduced and converted supplied from the circuit 260 through the signal line 42. The multiplexing circuit 240 multiplexes and outputs the binary image encoded output and the given enlargement ratio information.

第3の具体例における符号化回路の構成は、動き補償予測回路250および縮小処理用の解像度変換回路260を備えている点が、上述した先行技術の構成(図3の回路)と異なるものであり、動き補償予測回路250には、先に符号化されたフレームの再生画像を蓄積するフレームメモリが具備されていて、拡大回路230より供給される再生信号が蓄えることができる構成であると共に、更に、動き補償予測回路250には、動きベクトル信号(図示せず)が供給され、この動きベクトル信号にしたがって動き補償予測信号を生成し、信号線41を介して縮小処理用の解像度変換回路260に供給する構成としてある。   The configuration of the encoding circuit in the third specific example is different from the configuration of the prior art (the circuit in FIG. 3) described above in that it includes a motion compensation prediction circuit 250 and a resolution conversion circuit 260 for reduction processing. In addition, the motion compensation prediction circuit 250 includes a frame memory that stores a reproduction image of a previously encoded frame, and can store a reproduction signal supplied from the enlargement circuit 230. Further, a motion vector signal (not shown) is supplied to the motion compensation prediction circuit 250, a motion compensation prediction signal is generated according to this motion vector signal, and a resolution conversion circuit 260 for reduction processing is provided via the signal line 41. It is as composition to supply to.

縮小処理用の解像度変換回路260は、信号線41を介して供給される動き補償予測回路250からの動き補償信号を、信号線60を介して供給される縮小・拡大率の設定情報信号に応じて縮小した後、信号線42を介して2値画像符号化回路220に出力する。   The resolution conversion circuit 260 for the reduction process uses the motion compensation signal from the motion compensation prediction circuit 250 supplied via the signal line 41 in accordance with the setting information signal for the reduction / enlargement ratio supplied via the signal line 60. And then output to the binary image encoding circuit 220 via the signal line 42.

なお、2値画像符号化回路220として構成する場合では、信号線21を介して供給される解像度変換回路210からの解像度縮小変換されたアルファマップ信号を2値画像符号化して出力する。   In the case of configuring as the binary image encoding circuit 220, the alpha map signal subjected to resolution reduction conversion from the resolution conversion circuit 210 supplied via the signal line 21 is binary image encoded and output.

このような構成のアルファマップ符号化回路200においては、信号線60を介して供給される縮小・拡大率の設定情報信号は、解像度変換回路210,230,260、および2値画像符号化回路220に供給され、アルファマップ信号の発生符号量を制御することを可能とする。また、信号線60を介して供給された縮小・拡大率の符号(設定情報信号)は、多重化回路240にて、符号化されたアルファマップ信号と多重化され、信号線30を介して出力され、アルファマップの符号化信号として画像符号化装置の最終出力段である図1の多重化回路180に与えられることになる。   In the alpha map encoding circuit 200 having such a configuration, the setting information signal of the reduction / enlargement ratio supplied via the signal line 60 is sent to the resolution conversion circuits 210, 230, 260, and the binary image encoding circuit 220. The generated code amount of the alpha map signal can be controlled. Further, the code of the reduction / enlargement ratio (setting information signal) supplied via the signal line 60 is multiplexed with the encoded alpha map signal by the multiplexing circuit 240 and output via the signal line 30. Then, it is supplied as an alpha map encoded signal to the multiplexing circuit 180 of FIG. 1 which is the final output stage of the image encoding apparatus.

本装置では、アルファマップ信号入力線20を介して入力されるアルファマップを、信号線60を介して与えられる所望の縮小・拡大率の設定情報に従って解像度変換回路210は縮小符号化し、2値画像符号化回路220に与える。   In the present apparatus, the resolution conversion circuit 210 reduces and encodes the alpha map input via the alpha map signal input line 20 according to the desired reduction / enlargement ratio setting information given via the signal line 60. The signal is supplied to the encoding circuit 220.

2値画像符号化回路220は、解像度変換回路210から得られた解像度縮小変換済みアルファマップ信号を、縮小処理用の解像度変換回路260から信号線42にて供給される解像度縮小変換されたアルファマップの動き補償予測信号を利用して符号化し、2値画像符号化出力として多重化回路240と解像度変換回路230とに与える。そして、多重化回路240はこの2値画像符号化出力である符号化されたアルファマップ信号と、前記信号線60を介して与えられる拡大率の情報とを多重化して信号線30に出力する。   The binary image encoding circuit 220 converts the resolution-reduced and converted alpha-map signal obtained from the resolution conversion circuit 210 to the resolution-reduced and converted alpha-map supplied from the resolution conversion circuit 260 for reduction processing through the signal line 42. Are encoded using the motion compensated prediction signal, and supplied to the multiplexing circuit 240 and the resolution conversion circuit 230 as a binary image encoding output. The multiplexing circuit 240 multiplexes the encoded alpha map signal, which is the binary image encoding output, and the enlargement ratio information given through the signal line 60 and outputs the multiplexed signal to the signal line 30.

一方、解像度変換回路230では、この2値画像符号化回路220から与えられたこの縮小符号化されたアルファマップ信号(2値画像符号化出力)を、信号線60を介して得た縮小・拡大率の設定情報信号に従って元の解像度に復号し、局部復号信号として得て、この得た局部復号信号を信号線40を介して動き補償予測回路250および図1の直交変換回路120,逆直交変換回路160に出力する。   On the other hand, the resolution conversion circuit 230 reduces / enlarges the reduced-encoded alpha map signal (binary image encoded output) given from the binary image encoding circuit 220 via the signal line 60. 1 is decoded to the original resolution in accordance with the rate setting information signal and obtained as a local decoded signal. The obtained local decoded signal is obtained through the signal line 40 through the motion compensation prediction circuit 250 and the orthogonal transform circuit 120 in FIG. Output to the circuit 160.

一方、動き補償予測回路250には、先に符号化されたフレームの再生画像を蓄積するフレームメモリが具備されており、拡大処理用の解像度変換回路230より供給される再生信号が蓄えられる。そして、動き補償予測回路250は、別途供給される動きベクトル信号にしたがってアルファマップの動き補償予測信号を生成し、信号線41を介して縮小処理用の解像度変換回路260に供給する。解像度変換回路260はこの供給された動き補償予測信号を、信号線60を介して得た縮小・拡大率の設定情報信号に従って解像度縮小変換し、2値画像符号化回路220に与える。   On the other hand, the motion compensation prediction circuit 250 is provided with a frame memory for storing a reproduction image of a previously encoded frame, and stores a reproduction signal supplied from the resolution conversion circuit 230 for enlargement processing. Then, the motion compensation prediction circuit 250 generates an alpha map motion compensation prediction signal in accordance with a separately supplied motion vector signal, and supplies it to the resolution conversion circuit 260 for reduction processing via the signal line 41. The resolution conversion circuit 260 performs resolution reduction conversion on the supplied motion compensation prediction signal according to the setting information signal of the reduction / enlargement ratio obtained via the signal line 60, and provides the binary image encoding circuit 220 with the resolution reduction conversion.

2値画像符号化回路220は、縮小処理用の解像度変換回路260から与えられた解像度縮小変換されたアルファマップの動き補償予測信号を利用し、解像度変換回路210から得られた解像度縮小変換済みアルファマップ信号を符号化する。   The binary image encoding circuit 220 uses the motion-compensated prediction signal of the alpha map that has undergone resolution reduction conversion provided from the resolution conversion circuit 260 for reduction processing, and uses the resolution reduction-converted alpha obtained from the resolution conversion circuit 210. Encode the map signal.

以上が、第3の具体例のアルファマップ符号化回路の概要である。アルファマップ復号化回路は次のようになる。   The above is the outline of the alpha map encoding circuit of the third specific example. The alpha map decoding circuit is as follows.

図13に示すように、本具体例のアルファマップ復号化回路400は、2値画像復号化回路410(block-based MMR decoder )、解像度変換回路(拡大処理用回路)420、分離化回路430、そして、さらに動き補償予測回路440、および解像度変換回路(縮小処理用回路)450にて構成されている。   As shown in FIG. 13, the alpha map decoding circuit 400 of this specific example includes a binary image decoding circuit 410 (block-based MMR decoder), a resolution conversion circuit (enlargement processing circuit) 420, a separation circuit 430, Further, it includes a motion compensation prediction circuit 440 and a resolution conversion circuit (reduction processing circuit) 450.

これらのうち、分離化回路430は、図2に示す画像復号化装置内の分離化回路300で分離され、当該アルファマップ復号化回路400に入力されたアルファマップ信号からアルファマップ信号の符号と縮小・拡大率の符号に分離する回路であり、2値画像復号化回路410はアルファマップ信号の符号を、分離化回路430から分離して与えられる縮小・拡大率の符号(縮小・拡大率の設定情報信号)にしたがって2値画像に戻す回路であり、詳細は後述するが、縮小処理用の解像度変換回路450から信号線92にて供給される解像度縮小変換されたアルファマップの動き補償予測信号を利用して復号化するものである。   Among these, the separation circuit 430 is separated by the separation circuit 300 in the image decoding apparatus shown in FIG. 2, and the sign and reduction of the alpha map signal from the alpha map signal input to the alpha map decoding circuit 400. A circuit that separates the code of the enlargement ratio, and the binary image decoding circuit 410 sets the code of the reduction / enlargement ratio given by separating the code of the alpha map signal from the separation circuit 430 (setting of the reduction / enlargement ratio) In accordance with (information signal), a circuit for returning to a binary image, which will be described in detail later, is a resolution-compensated alpha map motion compensated prediction signal supplied from a resolution conversion circuit 450 for reduction processing through a signal line 92. It is used for decryption.

拡大処理用の解像度変換回路420はこの2値画像復号化回路410からのアルファマップ信号の符号である2値画像を、分離化回路430から分離して与えられる縮小・拡大率の符号(縮小・拡大率の設定情報信号)にしたがって解像度拡大変換して出力するものである。   The resolution conversion circuit 420 for enlargement processing is provided with a code of reduction / enlargement ratio (reduction / enlargement ratio) given by separating the binary image, which is the code of the alpha map signal from the binary image decoding circuit 410, from the separation circuit 430. (Enlargement rate setting information signal) and output after resolution enlargement conversion.

第3の具体例における復号化回路の構成は、動き補償予測回路440および縮小処理用の解像度変換回路450を備えている点が、上述した先行技術の構成 (図4の回路)と異なるものである。そして、動き補償予測回路440は、先に符号化されたフレームの再生画像を蓄積するフレームメモリを有しており、拡大処理用の解像度変換回路420より供給される再生信号を蓄えると共に、動きベクトル信号(図示せず)が供給され、この動きベクトル信号にしたがって動き補償予測信号を生成し、信号線91を介して縮小処理用の解像度変換回路450に供給する構成となっている。   The configuration of the decoding circuit in the third specific example is different from the configuration of the prior art (the circuit in FIG. 4) described above in that it includes a motion compensation prediction circuit 440 and a resolution conversion circuit 450 for reduction processing. is there. The motion compensation prediction circuit 440 includes a frame memory that stores the reproduction image of the previously encoded frame, stores the reproduction signal supplied from the resolution conversion circuit 420 for enlargement processing, and also provides a motion vector. A signal (not shown) is supplied, a motion compensated prediction signal is generated according to this motion vector signal, and is supplied to the resolution conversion circuit 450 for reduction processing via the signal line 91.

解像度変換回路450はこの動き補償予測信号を、信号線82を介して供給される縮小・拡大率の設定情報信号に応じて縮小した後、信号線92を介して2値画像復号化回路410に出力する。   The resolution conversion circuit 450 reduces the motion compensated prediction signal in accordance with the setting information signal of the reduction / enlargement ratio supplied via the signal line 82, and then sends it to the binary image decoding circuit 410 via the signal line 92. Output.

このような構成のアルファマップ復号化回路400においては、信号線80を介してアルファマップ復号化回路400に供給された符号は、分離化回路430によりアルファマップ信号の符号と縮小・拡大率の符号に分離され、各々信号線81および信号線82を介して出力される。   In the alpha map decoding circuit 400 having such a configuration, the code supplied to the alpha map decoding circuit 400 via the signal line 80 is the code of the alpha map signal and the code of the reduction / enlargement ratio by the separation circuit 430. And are output via the signal line 81 and the signal line 82, respectively.

2値画像復号化回路410では、詳細は後述するが、縮小処理用の解像度変換回路450から信号線92にて供給される解像度縮小変換されたアルファマップの動き補償予測信号を利用し、信号線81を介して供給されるアルファマップ信号の符号と信号線82を介して供給される縮小・拡大率の符号(縮小・拡大率の設定情報信号)に従って2値画像に戻す復号化処理を施すことにより、縮小されているアルファマップ信号を再生し、信号線83を介して解像度変換回路420に供給する。   As will be described in detail later, the binary image decoding circuit 410 uses a resolution-compensated alpha map motion compensated prediction signal supplied from a resolution conversion circuit 450 for reduction processing on a signal line 92 to obtain a signal line. A decoding process for returning to a binary image is performed in accordance with the code of the alpha map signal supplied through 81 and the code of the reduction / enlargement ratio (reduction / enlargement ratio setting information signal) supplied through the signal line 82. Thus, the reduced alpha map signal is reproduced and supplied to the resolution conversion circuit 420 via the signal line 83.

解像度変換回路420では、2値画像復号化回路410の再生した縮小されているアルファマップ信号を、信号線82を介して供給される縮小・拡大率の符号に基づいて元のサイズに拡大してアルファマップ信号を再生した後、信号線90を介して出力する。   The resolution conversion circuit 420 expands the reduced alpha map signal reproduced by the binary image decoding circuit 410 to the original size based on the sign of the reduction / enlargement ratio supplied via the signal line 82. After the alpha map signal is reproduced, it is output via the signal line 90.

2値画像符号化回路220は、解像度変換回路210から得られた解像度縮小変換済みアルファマップ信号を、縮小処理用の解像度変換回路260から信号線42にて供給される解像度縮小変換されたアルファマップの動き補償予測信号を利用して符号化し、2値画像符号化出力として多重化回路240と解像度変換回路230とに与える。そして、多重化回路240はこの2値画像符号化出力である符号化されたアルファマップ信号と、前記信号線60を介して与えられる拡大率の情報とを多重化して信号線30に出力する。   The binary image encoding circuit 220 converts the resolution-reduced and converted alpha-map signal obtained from the resolution conversion circuit 210 to the resolution-reduced and converted alpha-map supplied from the resolution conversion circuit 260 for reduction processing through the signal line 42. Are encoded using the motion compensated prediction signal, and supplied to the multiplexing circuit 240 and the resolution conversion circuit 230 as a binary image encoding output. The multiplexing circuit 240 multiplexes the encoded alpha map signal, which is the binary image encoding output, and the enlargement ratio information given through the signal line 60 and outputs the multiplexed signal to the signal line 30.

一方、解像度変換回路420では、この2値画像復号化回路410から与えられたこの縮小符号化されたアルファマップ信号(2値画像符号化出力)を、信号線82を介して得た縮小・拡大率の設定情報信号に従って元の解像度に復号し、局部復号信号として得て、この得た局部復号信号を動き補償予測回路440に出力する。   On the other hand, the resolution conversion circuit 420 reduces / enlarges the reduced-encoded alpha map signal (binary image encoded output) given from the binary image decoding circuit 410 via the signal line 82. It decodes to the original resolution according to the rate setting information signal, obtains it as a local decoded signal, and outputs the obtained local decoded signal to the motion compensation prediction circuit 440.

一方、動き補償予測回路440には、先に符号化されたフレームの再生画像を蓄積するフレームメモリが具備されており、拡大処理用の解像度変換回路420より供給される再生信号が蓄えられる。そして、動き補償予測回路420は、別途供給される動きベクトル信号にしたがってアルファマップの動き補償予測信号を生成し、信号線91を介して縮小処理用の解像度変換回路450に供給する。解像度変換回路450はこの供給された動き補償予測信号を、信号線82を介して得た縮小・拡大率の設定情報信号に従って解像度縮小変換し、2値画像復号化回路410に与える。   On the other hand, the motion compensation prediction circuit 440 is provided with a frame memory that stores a reproduction image of the previously encoded frame, and stores a reproduction signal supplied from the resolution conversion circuit 420 for enlargement processing. Then, the motion compensation prediction circuit 420 generates an alpha map motion compensation prediction signal according to a separately supplied motion vector signal, and supplies it to the resolution conversion circuit 450 for reduction processing via the signal line 91. The resolution conversion circuit 450 performs resolution reduction conversion on the supplied motion compensation prediction signal in accordance with the setting information signal of the reduction / enlargement ratio obtained via the signal line 82, and provides it to the binary image decoding circuit 410.

2値画像復号化回路410は、縮小処理用の解像度変換回路450から与えられた解像度縮小変換されたアルファマップの動き補償予測信号を利用し、分離化回路430からの縮小・拡大率の設定情報信号に従って、分離化回路430からのアルファマップ信号を復号化する。   The binary image decoding circuit 410 uses the alpha map motion compensated prediction signal subjected to resolution reduction conversion given from the resolution conversion circuit 450 for reduction processing, and sets the reduction / enlargement ratio setting information from the separation circuit 430. The alpha map signal from the separation circuit 430 is decoded according to the signal.

以上が、本発明を適用した復号化回路の概要である。   The above is the outline of the decoding circuit to which the present invention is applied.

既に説明しているように、本発明を適用した第3の具体例における符号化回路の構成は、動き補償予測回路250および縮小回路260を備えている点が先行技術の構成(図3の回路)と異なり、また、復号化回路の構成は、動き補償予測回路440および縮小回路450を備えている点が先行技術の構成(図4の回路)と異なる。   As already described, the configuration of the encoding circuit in the third specific example to which the present invention is applied is that the configuration of the prior art (the circuit of FIG. 3) includes the motion compensation prediction circuit 250 and the reduction circuit 260. In addition, the configuration of the decoding circuit is different from that of the prior art (the circuit of FIG. 4) in that it includes a motion compensation prediction circuit 440 and a reduction circuit 450.

動き補償予測回路250または440には、先に符号化されたフレームの再生画像を蓄積するフレームメモリが具備されており、拡大回路230または420より供給される再生信号が蓄えられる。更に、動き補償予測回路250または440には、ここには図示していない動きベクトル信号が供給され、この動きベクトル信号にしたがって動き補償予測信号を生成し、信号線41および信号線91を介して縮小回路260または450に供給する。   The motion compensation prediction circuit 250 or 440 is provided with a frame memory that stores a reproduction image of a previously encoded frame, and stores a reproduction signal supplied from the enlargement circuit 230 or 420. Further, a motion vector signal (not shown) is supplied to the motion compensation prediction circuit 250 or 440, and a motion compensation prediction signal is generated in accordance with the motion vector signal, via the signal line 41 and the signal line 91. This is supplied to the reduction circuit 260 or 450.

ここで、動きベクトル信号は、図1および図2の装置に具備されている、動き補償予測回路110または350で用いられる動きベクトル信号を利用しても良いし、アルファマップ符号化回路200において、アルファマップ用の動きベクトル検出回路を具備することにより、アルファマップ用の動きベクトル信号を求めても良い。   Here, as the motion vector signal, a motion vector signal used in the motion compensated prediction circuit 110 or 350 included in the apparatus of FIGS. 1 and 2 may be used. In the alpha map encoding circuit 200, An alpha map motion vector signal may be obtained by providing an alpha map motion vector detection circuit.

すなわち、動き補償予測回路250または440に供給される動きベクトル信号の求め方は種々知られており、本発明に関わるものではないため、ここではこれ以上言及しない。   That is, various methods for obtaining the motion vector signal supplied to the motion compensation prediction circuit 250 or 440 are known and are not related to the present invention, and thus will not be further described here.

縮小回路260または450においては、信号線41および信号線91を介して供給される動き補償信号を、信号線60および信号線82を介して供給される縮小・拡大率の設定情報信号に応じて縮小した後、信号線42および信号線92を介して出力する。   In the reduction circuit 260 or 450, the motion compensation signal supplied via the signal line 41 and the signal line 91 is converted into the reduction / enlargement ratio setting information signal supplied via the signal line 60 and the signal line 82. After the reduction, the signal is output via the signal line 42 and the signal line 92.

なお、2値画像符号化回路220として構成する場合では、信号線21を介して供給される解像度縮小変換されたアルファマップ信号を2値画像符号化して出力する。   In the case where the binary image encoding circuit 220 is configured, the alpha map signal subjected to resolution reduction conversion supplied via the signal line 21 is binary image encoded and output.

ここで、本具体例にかかる2値画像符号化回路220が上述した先行技術と根本的に異なる点は、信号線42を介して供給される、解像度縮小変換されたアルファマップの動き補償予測信号を利用して符号化する機能を具備していることである。
このことについて、詳しく説明する。
Here, the binary image encoding circuit 220 according to the present specific example is fundamentally different from the above-described prior art in that the motion compensation prediction signal of the resolution-converted alpha map supplied via the signal line 42 is used. It has the function to encode using.
This will be described in detail.

図14は、動き補償予測信号を利用して符号化する方法を説明する図であり、フレーム画像単位の画像における分割されたN×M画素構成の画像ブロックのうちの一つを示している。   FIG. 14 is a diagram for explaining a method of encoding using a motion compensated prediction signal, and shows one of the divided N × M pixel configuration image blocks in an image in units of frame images.

図14において、“current block ”は処理対象ブロックであり、入力された現在の処理画像のブロックである。また、“compensated block ”は補償ブロックであり、前回処理対象となった画像のブロックである。   In FIG. 14, “current block” is a processing target block, which is a block of an input current processed image. Further, “compensated block” is a compensation block, which is a block of an image that has been processed last time.

本発明の適用前提となる先行技術では、現在の処理対象画像のブロックに対応するアルファマップの該当ブロック上での参照変化画素b1を変化画素a0、a1と同じ“current block ”内で検出していた。   In the prior art which is the application premise of the present invention, the reference change pixel b1 on the corresponding block of the alpha map corresponding to the block of the current processing target image is detected in the same “current block” as the change pixels a0 and a1. It was.

一方、本発明では、参照変化画素b1を動き補償予測信号である“compensated block ”内から検出しており、この点が新しい概念である。すなわち、現在の処理対象画像のブロックに対応するアルファマップの該当ブロック上での参照変化画素b1を、動き補償予測信号である“compensated block ”内から検出している。   On the other hand, in the present invention, the reference change pixel b1 is detected from the “compensated block” that is a motion compensated prediction signal, which is a new concept. That is, the reference change pixel b1 on the corresponding block of the alpha map corresponding to the block of the current processing target image is detected from the “compensated block” that is the motion compensated prediction signal.

なお、本発明は、参照変化画素b1の検出手段が異なるだけで、a0 、a1およびb1の相対アドレスを用いて符号化・復号化を行う点は、先行技術と同一である。   The present invention is the same as the prior art in that encoding / decoding is performed using the relative addresses of a0, a1 and b1, except that the detection means for the reference change pixel b1 is different.

図14において、a0 は起点変化画素であり、すでに起点変化画素a0 までは符号化が済んでいる。また、a1 は、起点変化画素a0 の次の変化画素であり、b0 は、“ compensated block”内において、a0 と同じ位置の画素(変化画素とは限らない)である。また、a0 (b0 )が属するラインを“a0 - line”と表記すると、参照変化画素b1は次のように定義される。   In FIG. 14, a0 is a starting point change pixel, and encoding up to the starting point change pixel a0 has already been completed. Further, a1 is a change pixel next to the start point change pixel a0, and b0 is a pixel (not necessarily a change pixel) at the same position as a0 in the "compensated block". If the line to which a0 (b0) belongs is expressed as “a0-line”, the reference change pixel b1 is defined as follows.

ここで、abs_Xをブロック左上の画素からブロック内をラスタ順にスキャンした際の、画素Xのアドレスとする。なお、ブロック左上の画素のアドレスは“0”とする。   Here, abs_X is the address of the pixel X when the block is scanned in raster order from the upper left pixel of the block. Note that the address of the pixel at the upper left of the block is “0”.

abs_b0 <abs_b1 であり、符号“×”を付して示す画素は変化画素であって、変化画素×が“a0 - line”上にある場合には、“a0 ”と反対色の最初の変加画素を参照変化画素b1とし、変化画素が“a0 - line”上にない場合は、該ライン上の最初の変加画素を参照変化画素b1 とする。   If abs_b0 <abs_b1 and the pixel indicated by the symbol “x” is a change pixel and the change pixel x is on “a0-line”, the first change of the opposite color to “a0” If the pixel is the reference change pixel b1 and the change pixel is not on "a0-line", the first change pixel on the line is set as the reference change pixel b1.

図14(a)は変化画素が“a0_line”上にない場合であり、この場合、次のラインの最初の変化画素を“b1 ”としている。   FIG. 14A shows a case where the change pixel is not on “a0_line”. In this case, the first change pixel of the next line is set to “b1”.

また、図14(b)は、変化画素が“a0 - line”上にある場合であるが、この変化画素×は、“a”と反対色ではないので“b1”とはせずに、次のラインの最初の変化画素を“b1”としている。   FIG. 14B shows a case where the change pixel is on “a 0 -line”. Since this change pixel x is not the opposite color to “a”, it is not set to “b 1”. The first changed pixel of the line is “b1”.

なお、“a0 - line”および“r_ai (i=0 〜1)”、“r_b1 ”の値は、以下の式で求められる。   Note that the values of “a0-line”, “r_ai (i = 0 to 1)”, and “r_b1” are obtained by the following equations.

a0 - line= (int)((abs- a0 +WIDTH)/WIDTH)−1
r- a0 = abs - a0 − a0 - line*WIDTH
r- a1 = abs - a1 − a0 - line*WIDTH
r- b1 = abs - b1 − a0 - line*WIDTH
上記式において、*は乗算を、また、(int)(X) はXの小数点以下切り捨てを意味しており、WIDTH はブロックの水平方向の画素数を示している。
a0-line = (int) ((abs-a0 + WIDTH) / WIDTH) -1
r-a0 = abs-a0-a0-line * WIDTH
r- a1 = abs-a1-a0-line * WIDTH
r-b1 = abs-b1-a0-line * WIDTH
In the above formula, * means multiplication, (int) (X) means truncation after the decimal point of X, and WIDTH indicates the number of pixels in the horizontal direction of the block.

本発明では、参照変化画素b1の定義が先行技術とは変わったため、“r_ b1 ”の定義も、上式のように変更される。   In the present invention, since the definition of the reference change pixel b1 is different from the prior art, the definition of “r_b1” is also changed as shown in the above equation.

図14を用いて説明した例は、“ compensated block”内から参照変化画素b1を求める手段の一例であり、参照変化画素b1の検出については種々変形が可能である。   The example described with reference to FIG. 14 is an example of a means for obtaining the reference change pixel b1 from the “compensated block”, and various modifications can be made for the detection of the reference change pixel b1.

また、2値画像復号化回路においては、信号線92を介して供給される解像度縮小変換されたアルファマップの動き補償予測信号(“ compensated block”)を利用して、2値画像符号化回路220と同一の手順で参照変化画素b1を検出する。   Further, in the binary image decoding circuit, a binary image encoding circuit 220 is used by using a motion compensated prediction signal (“compensated block”) of an alpha map subjected to resolution reduction conversion supplied via a signal line 92. The reference change pixel b1 is detected by the same procedure.

更に、参照変化画素b1を“current block ”内より検出するか、“ compensated block”内より検出するかを、たとえばブロック単位で切り替えるようにすることもできる。この際、2値画像符号化回路220では切り替え用の情報も併せて符号化し、2値画像復号化回路410では当該切り替え用の情報も復号化して、復号化処理の際には当該切り替え用の情報に基づいて、参照変化画素b1を“current block ”内より検出するか、“ compensated block”内より検出するかを、たとえばブロック単位で切り替えるようにする。   Furthermore, whether the reference change pixel b1 is detected from the “current block” or the “compensated block” can be switched, for example, in units of blocks. At this time, the binary image encoding circuit 220 also encodes the switching information, and the binary image decoding circuit 410 also decodes the switching information, and at the time of decoding processing, the switching information. Based on the information, whether the reference change pixel b1 is detected from the “current block” or the “compensated block” is switched, for example, in units of blocks.

このようにすると、ブロック単位の画像内容に基づいて、最適処理が可能になり、一層、効率の良い符号化が可能になる。   In this way, it is possible to perform optimum processing based on the image content in units of blocks, and it is possible to perform more efficient encoding.

また、先行技術と同様、スキャン順序を切り替える手段を具備して図15(a)に示すように、スキャン順序を横方向スキャンに切り替えたり、図15(b)に示すように、縦方向スキャンに切り替えるようにすることで、変化画素の数が減り、更に符号量が削減されて、これも一層、効率の良い符号化につながる。   Also, as in the prior art, a means for switching the scan order is provided, and the scan order is switched to the horizontal scan as shown in FIG. 15 (a), or the vertical scan is used as shown in FIG. 15 (b). By switching, the number of changed pixels is reduced, and the amount of codes is further reduced, which also leads to more efficient encoding.

以上、第3の具体例は、時系列データとして得られる複数フレームの動画像信号を任意形状のオブジェクト毎に符号化する動画像符号化装置における、オブジェクトの形状を表すアルファマップを符号化する符号化回路であって、オブジェクトを含む方形領域をM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に分割する手段と、この分割されて得られた上記ブロックを、前記方形領域内において一定規則により順次、符号化する手段とを有し、ブロックの全てあるいは一部に対して相対アドレス符号化を適用する2値画像符号化装置において、
ブロック近傍の再生値を蓄える手段と、すでに符号化されたフレームの再生信号を蓄えるフレームメモリと、フレームメモリ内の再生信号を用いて、動き補償予測値を生成する動き補償予測回路と、ブロック近傍の再生値も含めて変化画素を検出する手段とを有し、相対アドレス符号化の参照変化画素を、上記ブロック内の画素値からでなく、動き補償予測信号から求めるようにしたものである。
As described above, the third specific example is a code for encoding an alpha map representing the shape of an object in a moving image encoding apparatus that encodes a plurality of frames of moving image signals obtained as time-series data for each object having an arbitrary shape. And a means for dividing a rectangular region including an object into blocks each composed of M × N pixels (M: number of pixels in the horizontal direction, N: number of pixels in the vertical direction). Means for sequentially encoding the block in the square area according to a certain rule, and applying a relative address encoding to all or a part of the block,
Means for storing reproduction values in the vicinity of a block, frame memory for storing a reproduction signal of an already encoded frame, a motion compensation prediction circuit for generating a motion compensation prediction value using the reproduction signal in the frame memory, and the vicinity of the block Means for detecting a change pixel including the reproduction value of the reference value, and the reference change pixel of the relative address encoding is obtained not from the pixel value in the block but from the motion compensated prediction signal.

また、アルファマップ復号化回路において、M×N画素で構成されるブロック毎に、オブジェクトを含む方形領域内を一定規則で順次復号化する手段と、ブロック近傍の再生値を蓄える手段と、すでに符号化されたフレームの再生信号を蓄えるフレームメモリと、フレームメモリ内の再生信号を用いて、動き補償予測値を生成する動き補償予測回路と、ブロック近傍の再生値も含めて変化画素を検出する手段とを有し、相対アドレス符号化の参照変化画素を、上記ブロック内の画素値からでなく、動き補償予測信号から求めるようにしたものである。   Further, in the alpha map decoding circuit, for each block composed of M × N pixels, means for sequentially decoding the rectangular area including the object according to a certain rule, means for storing a reproduction value in the vicinity of the block, and code Frame memory for storing the regenerated signal of the converted frame, a motion compensation prediction circuit for generating a motion compensated prediction value using the regenerated signal in the frame memory, and means for detecting a change pixel including a replay value near the block The reference change pixel of relative address encoding is obtained from the motion compensated prediction signal instead of the pixel value in the block.

これにより、オブジェクトの形状や画面内の位置などを表す副画像情報であるアルファマップの情報を効率良く符号化できるとともに、その復号を行うことができるようになる。   As a result, it is possible to efficiently encode and decode the alpha map information, which is the sub-image information representing the shape of the object, the position in the screen, and the like.

また、ブロック近傍の再生値を蓄える再生値蓄積手段と、すでに符号化されたフレームの再生信号を蓄えるフレームメモリと、フレームメモリ内の再生信号を用いて、動き補償予測値を生成する動き補償予測回路と、前記再生値蓄積手段の蓄積再生値の情報を参照し、ブロック近傍の再生値も含めて変化画素を検出する手段と、上記ブロック内の再生画素値から求められた、相対アドレス符号化の参照変化画素と、動き補償予測信号から求められた、相対アドレス符号化の参照変化画素を切り替える手段とを有し、相対アドレス符号化情報を、切り替え情報と共に符号化するものである。   Also, a motion compensation prediction that generates a motion compensation prediction value using a playback value storage means for storing playback values in the vicinity of a block, a frame memory for storing playback signals of already encoded frames, and playback signals in the frame memory. Relative address encoding obtained from a reproduction pixel value in the block, a circuit, means for detecting a change pixel including reproduction values in the vicinity of the block with reference to information of the accumulation reproduction value of the reproduction value accumulation means And a means for switching the reference change pixel of the relative address encoding obtained from the motion compensated prediction signal, and encodes the relative address encoding information together with the switching information.

また、アルファマップ復号化回路において、M×N画素で構成されるブロック毎に、オブジェクトを含む方形領域内を一定規則で順次復号化する手段と、ブロック近傍の再生値を蓄える再生値蓄積手段と、すでに符号化されたフレームの再生信号を蓄えるフレームメモリと、フレームメモリ内の再生信号を用いて、動き補償予測値を生成する動き補償予測回路と、ブロック近傍の再生値も含めて変化画素を検出する手段とを有し、上記ブロック内の再生画素値から求められた、相対アドレス符号化の参照変化画素と、動き補償予測信号から求められた、相対アドレス符号化の参照変化画素を切り替える手段を有し、切り替え情報にしたがって参照変化画素を求めるようにしたものである。   Further, in the alpha map decoding circuit, means for sequentially decoding the rectangular area including the object in a predetermined rule for each block composed of M × N pixels, and reproduction value accumulation means for storing reproduction values near the block; A frame memory that stores a reproduction signal of an already encoded frame, a motion compensation prediction circuit that generates a motion compensation prediction value using the reproduction signal in the frame memory, and a change pixel including a reproduction value near the block. Means for detecting the relative address encoding reference change pixel obtained from the reproduction pixel value in the block and the relative address encoding reference change pixel obtained from the motion compensation prediction signal. The reference change pixel is obtained according to the switching information.

この場合、相対アドレス符号化にあたり、参照変化画素b1を“current block ”内より検出するか、“ compensated block”内より検出するかを、ブロック単位で切り替えて処理することができ、符号化側ではこの切り替え用の情報も併せて符号化し、復号化側ではこれを復号化して、符号化されたアルファマップの復号化処理の際に当該切り替え用の情報に基づいて、参照変化画素b1を“current block ”内より検出するか、“ compensated block”内より検出するかを、ブロック単位で切り替えるようにすることができ、このようにすることによって、ブロック単位の画像内容に基づいて、最適処理が可能になり、一層、効率の良い符号化が可能になる。   In this case, in relative address encoding, whether the reference change pixel b1 is detected from the “current block” or the “compensated block” can be switched and processed in units of blocks. The switching information is also encoded and decoded on the decoding side, and the reference change pixel b1 is set to “current” based on the switching information at the time of decoding the encoded alpha map. Whether to detect from “block” or from “compensated block” can be switched on a block-by-block basis, which enables optimal processing based on the image content of each block. Thus, more efficient encoding becomes possible.

以上、本発明によれば、オブジェクトの形状や画面内の位置などを表す副画像情報であるアルファマップの情報を効率良く符号化できるとともに、その復号を行うことができるようにした画像符号化装置および画像復号化装置が得られる。   As described above, according to the present invention, it is possible to efficiently encode alpha map information, which is sub-image information representing the shape of an object, a position in a screen, and the like, and to perform the decoding thereof. And an image decoding apparatus is obtained.

以上の具体例は、アルファマップ符号化回路200の構成において、MMR(Modified Modified READ)符号化を用いた場合の例を説明したものであった。しかし、本発明はMMR符号化に限定されるものではなく、他の任意の2値画像符号化回路を用いても実現可能である。そこで、そのような例を以下説明する。   The specific example described above is an example in which MMR (Modified Modified READ) encoding is used in the configuration of the alpha map encoding circuit 200. However, the present invention is not limited to MMR encoding, and can be implemented using any other binary image encoding circuit. Such an example will be described below.

(第4の具体例)
図21、図22および図20を用いてアルファマップ符号化回路200およびアルファマップ復号化回路400の具体的な構成を説明する。
(Fourth specific example)
Specific configurations of the alpha map encoding circuit 200 and the alpha map decoding circuit 400 will be described with reference to FIGS.

図20は、アルファマップの画面内を例えば、16×16画素といった所定の複数画素構成によるマクロブロック(MB)単位に分割した図であり、正方形の升目で示したものが分割の境界線であって、升目一つ一つがマクロブロック(MB)である。   FIG. 20 is a diagram in which the screen of the alpha map is divided into macroblock (MB) units having a predetermined plural pixel configuration such as 16 × 16 pixels, for example, and the areas shown by squares are division boundaries. Each cell is a macro block (MB).

2値で表現されたアルファマップの場合(オブジェクトを合成する際の重み係数も含めて多値で表現される場合もある)、オブジェクトの形状情報は画素毎に白か黒かのいずれかで表される。従って、図20に示されるように、アルファマップの画面における各マクロブロック(MB)の中身の状態は、“allW”(全て白)、“allB”(全て黒)、“Multi”(その他)の3種類のいずれかに分類される。   In the case of an alpha map expressed in binary (in some cases, it may be expressed in multiple values including a weighting factor when compositing the object), the object shape information is expressed in either white or black for each pixel. Is done. Therefore, as shown in FIG. 20, the contents of each macro block (MB) on the alpha map screen are “allW” (all white), “allB” (all black), “Multi” (other). It is classified into one of three types.

人物像のアルファマップである図20のような画面の場合、背景は“白”、人物部分は“黒”であるから、“Multi”に分類されるオブジェクトの境界部分が含まれるマクロブロック(MB)のみ、2値画像符号化すればよい。また、“Multi”に分類されるブロック(MB)の中でも、動き補償予測誤差値が設定値(しきい値)以下の場合には、該ブロック(MB)を動き補償予測値でコピーする。このように、コピーされるマクロブロック(MB)のモードを“copy”、2値面像符号化されるマクロブロック(MB)のモードを“coded”と表記すると、該マクロブロック(MB)の符号化モードは次の4通りとなる。   In the case of a screen as shown in FIG. 20 which is an alpha map of a human image, the background is “white” and the human part is “black”, so that the macro block (MB) including the boundary part of the object classified as “Multi” is included. ) Only for binary image coding. Also, among the blocks (MB) classified as “Multi”, when the motion compensation prediction error value is equal to or less than the set value (threshold value), the block (MB) is copied with the motion compensation prediction value. Thus, when the mode of a macroblock (MB) to be copied is expressed as “copy”, and the mode of a macroblock (MB) subjected to binary plane image encoding is expressed as “coded”, the code of the macroblock (MB) is coded. The following four modes are available.

(1)“allW”
(2)“allB”
(3)“copy”
(4)“coded”
それぞれのモードの符号化法あるいは復号化法については、アルファマップ符号化回路200、アルファマップ復号化回路400の中で説明する。
(1) “allW”
(2) “allB”
(3) “copy”
(4) “coded”
The encoding method or decoding method of each mode will be described in the alpha map encoding circuit 200 and the alpha map decoding circuit 400.

<第4の具体例におけるアルファマップ符号化回路の構成例>
図21は、アルファマップ符号化回路200の詳細な構成図である。図21の構成においては、モード判定回路1100、CR(縮小・拡大率)判定回路1110、セレクタ1200、ブロック内画素値設定回路1400,1500、動き補償予測回路1600、2値画像符号化回路1700、縮小回路1710,1730,1740、拡大回路1720、フレームメモリ1300、転置回路1750,1760、スキャンタイプ(ST)判定回路1770、動きベクトル検出回路(MVE)1780、MV符号化回路1790、VLC(可変長符号化)・多重化回路1800からなる。
<Configuration Example of Alpha Map Encoding Circuit in Fourth Specific Example>
FIG. 21 is a detailed configuration diagram of the alpha map encoding circuit 200. In the configuration of FIG. 21, a mode determination circuit 1100, a CR (reduction / enlargement ratio) determination circuit 1110, a selector 1200, intra-block pixel value setting circuits 1400 and 1500, a motion compensation prediction circuit 1600, a binary image encoding circuit 1700, Reduction circuit 1710, 1730, 1740, enlargement circuit 1720, frame memory 1300, transposition circuit 1750, 1760, scan type (ST) determination circuit 1770, motion vector detection circuit (MVE) 1780, MV encoding circuit 1790, VLC (variable length) Encoding) / multiplexing circuit 1800.

これらのうち、ブロック内画素値設定回路1400はマクロブロック内の画素値を全て白とする画素データを発生する回路であり、ブロック内画素値設定回路1500はマクロブロック内の画素値を全て黒とする画素データを発生する回路である。   Among these, the in-block pixel value setting circuit 1400 is a circuit that generates pixel data in which all the pixel values in the macroblock are white, and the in-block pixel value setting circuit 1500 sets all the pixel values in the macroblock to black. This is a circuit for generating pixel data.

CR(縮小・拡大率)判定回路1110は、アルファマップ信号入力線20を介して供給されるアルファマップ信号を解析し、1フレーム分のアルファマップ画像をどの程度の縮小・拡大率で処理すべきかを判定すると共にその判定結果を縮小・拡大率情報b2として出力するものである。また、縮小回路1710はアルファマップ信号入力線20を介して供給されるアルファマップ信号をフレーム全体について、前記スキャンタイプ(ST)判定回路1770は2値画像符号化回路1700からの出力符号化出力を基にスキャン方向を判定してスキャン方向情報b4を出力するものである。   A CR (reduction / enlargement ratio) determination circuit 1110 analyzes an alpha map signal supplied via the alpha map signal input line 20 and determines at what reduction / enlargement ratio an alpha map image for one frame should be processed. And the determination result is output as the reduction / enlargement ratio information b2. The reduction circuit 1710 outputs the alpha map signal supplied via the alpha map signal input line 20 for the entire frame, and the scan type (ST) determination circuit 1770 outputs the output encoded output from the binary image encoding circuit 1700. Based on this, the scan direction is determined and the scan direction information b4 is output.

また、転置回路1750はこのスキャンタイプ(ST)判定回路1770の出力するスキャン方向情報b4を基に、前記縮小回路1710の縮小処理した1フレーム分のアルファマップ信号について各マクロブロックの位置を、転置処理する回路であり、転置回路1760はスキャンタイプ判定回路1770の出力するスキャン方向情報b4を基に、前記縮小回路1710,1720,1730の出力を転置処理して出力する回路であり、2値画像符号化回路1700はこれらの転置回路1750、1760を介して与えられた縮小アルファマップ信号を符号化処理して出力するものである。   Further, the transposition circuit 1750 transposes the position of each macroblock in the alpha map signal for one frame subjected to the reduction processing by the reduction circuit 1710 based on the scan direction information b4 output from the scan type (ST) determination circuit 1770. The transposition circuit 1760 is a circuit that transposes and outputs the outputs of the reduction circuits 1710, 1720, and 1730 based on the scan direction information b4 output from the scan type determination circuit 1770, and outputs the binary image. The encoding circuit 1700 encodes the reduced alpha map signal given through these transposition circuits 1750 and 1760 and outputs the result.

また、拡大回路1720は縮小回路1710を介して与えられるアルファマップ信号を前記CR判定回路1110の出力する縮小・拡大率で拡大処理する回路であり、動き補償予測回路1600はフレームメモリ1300に蓄積されている参照フレームの再生画像を用いて動き補償予測信号を生成し、モード判定回路1100および縮小回路1740に出力するものであり、縮小回路1740は前記動き補償予測信号を前記CR判定回路1110の出力する縮小・拡大率で縮小処理する回路であり、縮小回路1730は前記フレームメモリ1300に蓄積されている参照フレームの再生画像を前記CR判定回路1110の出力する縮小・拡大率で縮小処理する回路である。   The enlargement circuit 1720 is a circuit that enlarges the alpha map signal supplied through the reduction circuit 1710 at the reduction / enlargement ratio output from the CR determination circuit 1110. The motion compensation prediction circuit 1600 is stored in the frame memory 1300. A motion compensated prediction signal is generated using the reproduced image of the reference frame, and is output to the mode determination circuit 1100 and the reduction circuit 1740. The reduction circuit 1740 outputs the motion compensation prediction signal to the output of the CR determination circuit 1110. The reduction circuit 1730 is a circuit that reduces the reproduction image of the reference frame stored in the frame memory 1300 with the reduction / enlargement ratio output from the CR determination circuit 1110. is there.

また、セレクタ1200はモード判定回路1100の出力する分類情報に従ってブロック内画素値設定回路1400からの再生信号m0,ブロック内画素値設定回路1500からの再生信号m1,動き補償予測回路1600からの動き補償予測信号m2,拡大回路1720からの再生信号m3のうち、所要のものを選択して出力する回路であり、フレームメモリ1300はこのセレクタ1200の出力をフレーム単位で記憶するメモリである。   In addition, the selector 1200 follows the classification information output from the mode determination circuit 1100, the reproduction signal m 0 from the in-block pixel value setting circuit 1400, the reproduction signal m 1 from the in-block pixel value setting circuit 1500, and the motion compensation from the motion compensation prediction circuit 1600. Of the prediction signal m2 and the reproduction signal m3 from the expansion circuit 1720, a circuit that selects and outputs a required signal, and the frame memory 1300 is a memory that stores the output of the selector 1200 in units of frames.

また、モード判定回路1100は、動き補償予測回路1600からの動き補償予測信号と2値画像符号化回路1700からの符号化信号b4を参照して、アルファマップ信号入力線20を介して供給されるアルファマップ信号を解析し、マクロブロック毎に“allW”、“allB”、“copy”、“coded”の何れに分類されるかを判定すると共に判定結果をモード情報b0として出力するものである。   The mode determination circuit 1100 is supplied via the alpha map signal input line 20 with reference to the motion compensation prediction signal from the motion compensation prediction circuit 1600 and the encoded signal b4 from the binary image encoding circuit 1700. The alpha map signal is analyzed to determine whether each macroblock is classified into “allW”, “allB”, “copy”, or “coded”, and the determination result is output as mode information b0.

動きベクトル検出回路(MVE)1780は、アルファマップ信号入力線20を介して供給されるアルファマップ信号から動きベクトルを検出するものであり、MV符号化回路1790は、動きベクトル検出回路(MVE)1780で検出された動きベクトルを符号化し、その符号化結果を動きベクトル情報b1として出力するものである。例えば、MV符号化回路1970に予測符号化を適用した場合にはその予測誤差信号が動きベクトル情報b1として出力されることになる。   The motion vector detection circuit (MVE) 1780 detects a motion vector from the alpha map signal supplied via the alpha map signal input line 20, and the MV encoding circuit 1790 is a motion vector detection circuit (MVE) 1780. The motion vector detected in step 1 is encoded, and the encoded result is output as motion vector information b1. For example, when predictive encoding is applied to the MV encoding circuit 1970, the prediction error signal is output as motion vector information b1.

VLC(可変長符号化)・多重化回路1800は、モード判定回路1100からのモード情報b0およびMV符号化回路1790からの動きベクトル情報b1およびCR(縮小・拡大率)判定回路1110からの縮小・拡大率情報b2およびスキャンタイプ(ST)判定回路1770からのスキャン方向情報b3および2値画像符号化回路1700からの2値符号化情報b4を受けてこれらを可変長符号化し、多重化して信号線30へと出力するものである。   A VLC (variable length encoding) / multiplexing circuit 1800 is provided with mode information b0 from the mode determination circuit 1100, motion vector information b1 from the MV encoding circuit 1790, and reduction / enlargement from the CR (reduction / enlargement ratio) determination circuit 1110. Upon receiving the enlargement factor information b2, the scan direction information b3 from the scan type (ST) determination circuit 1770, and the binary encoded information b4 from the binary image encoding circuit 1700, these are variable length encoded, multiplexed, and signal lines 30 is output.

このような構成において、符号化対象であるアルファマップ信号は、アルファマップ信号入力線20を介してアルファマップ符号化回路200に供給される。そして、これを受けたアルファマップ符号化回路200では、そのモード判定回路1100においてアルファマップ信号を解析し、マクロブロック毎に“allW”、“allB”、“copy”、“coded”の何れに分類されるかを判定する。ここで、分類の評・価基準としては、例えば、ミスマッチ画素数を用いる。   In such a configuration, the alpha map signal to be encoded is supplied to the alpha map encoding circuit 200 via the alpha map signal input line 20. In response to this, the alpha map encoding circuit 200 analyzes the alpha map signal in the mode determination circuit 1100 and classifies it into “allW”, “allB”, “copy”, or “coded” for each macroblock. Determine whether it will be done. Here, for example, the number of mismatched pixels is used as the classification evaluation / value criterion.

具体的には次の通りである。
モード判定回路1100は、まず、入力されたマクロブロック内の信号を全て白に置き換えた場合のミスマッチ画素数を計算し、この数がしきい値以下となるマクロブロックを“allW”に分類する。同様に、モード判定回路1100は、マクロブロック内を全て黒に置き換えた場合“allW”に分類する。同様に、マクロブロック内を全て黒に置き換えた場合のミスマッチ画素数がしきい値以下となるマクロブロックを“allB”に分類する。
次に、モード判定回路1100は、“allW”にも“allB”にも分類されないマクロブロックに対して、信号線1010を介して供給される動き補償予測値とのミスマッチ画素数を計算し、この数がしきい値以下となるブロックを“copy”に分類する。
ここで、“allW”“allB”あるいは“copy”にも分類されなかったマクロブロックは、“coded”に分類される。
Specifically, it is as follows.
First, the mode determination circuit 1100 calculates the number of mismatched pixels when all signals in the input macroblock are replaced with white, and classifies the macroblock whose number is equal to or less than the threshold value as “allW”. Similarly, the mode determination circuit 1100 classifies the macroblock as “allW” when all the macroblocks are replaced with black. Similarly, a macroblock in which the number of mismatch pixels when a macroblock is entirely replaced with black is equal to or less than a threshold value is classified as “allB”.
Next, the mode determination circuit 1100 calculates the number of mismatched pixels with the motion compensated prediction value supplied via the signal line 1010 for a macroblock that is not classified as “allW” or “allB”. A block whose number is less than or equal to the threshold is classified as “copy”.
Here, macroblocks that are not classified as “allW”, “allB”, or “copy” are classified as “coded”.

モード判定回路1100によるこの分類情報b0は、信号線1020を介してセレクタ1200に供給され、セレクタ1200では該ブロックのモードが“allW”の場合は、ブロック内画素値設定回路1400においてブロック内画素値が全て白にされた再生信号m0を選択し、信号線40を介してフレームメモリ1300に供給し、該フレームの記憶領域に蓄えると共に、アルファマップ符号化回路200の出力として出力する。   This classification information b0 from the mode determination circuit 1100 is supplied to the selector 1200 via the signal line 1020. When the mode of the block is “allW” in the selector 1200, the pixel value in the block is determined in the pixel value setting circuit 1400 in the block. Is selected as white, supplied to the frame memory 1300 via the signal line 40, stored in the storage area of the frame, and output as the output of the alpha map encoding circuit 200.

同様に、該マクロブロックのモードが“allB”の場合は、セレクタ1200はマクロブロック内画素値設定回路1500においてマクロブロック内画素値が全て黒にされた再生信号m1を選択し、また、該マクロブロックのモードが“copy”の場合は、信号線1010を介して供給される動き補償予測回路1600により生成された動き補償予測信号m2を選択し、また、該マクロブロックのモードが“coded”の場合には、縮小回路1710、拡大回路1720を経て供給される再生信号m3を選択して、これを信号線40を介してフレームメモリ1300に供給し、該フレームの記憶領域に蓄えると共に、アルファマップ符号化回路200の出力信号として出力する。   Similarly, when the mode of the macroblock is “allB”, the selector 1200 selects the reproduction signal m1 in which the pixel values in the macroblock are all black in the macroblock pixel value setting circuit 1500, and the macroblock When the block mode is “copy”, the motion compensation prediction signal m2 generated by the motion compensation prediction circuit 1600 supplied via the signal line 1010 is selected, and the macroblock mode is “coded”. In this case, the reproduction signal m3 supplied through the reduction circuit 1710 and the enlargement circuit 1720 is selected, supplied to the frame memory 1300 via the signal line 40, stored in the storage area of the frame, and the alpha map. This is output as an output signal of the encoding circuit 200.

また、モード判定回路1110において“coded”に分類されたマクロブロックの画素値は、縮小回路1710において縮小された後、2値画像符号化回路1700において符号化される。ここで、縮小回路1710で用いられる縮小・拡大率(CR(Conversion Ratio))の設定情報は、CR判定回路1110において求められる。例えば、縮小率を“1(縮小しない)”、“1/2(水平・垂直共に1/2)”、“1/4(水平・垂直共に1/4)”の3通りに定めた場合、CR判定回路1110では、次のステップでCR(縮小・拡大率)が求められる。   Further, the pixel value of the macroblock classified as “coded” in the mode determination circuit 1110 is reduced in the reduction circuit 1710 and then encoded in the binary image encoding circuit 1700. Here, the setting information of the reduction / enlargement ratio (CR (Conversion Ratio)) used in the reduction circuit 1710 is obtained in the CR determination circuit 1110. For example, when the reduction ratio is set to three types of “1 (not reduced)”, “1/2 (1/2 for both horizontal and vertical)” and “1/4 (for both horizontal and vertical)”, The CR determination circuit 1110 obtains CR (reduction / enlargement ratio) in the next step.

(1) 該マクロブロックを“1/4”に縮小した際の再生信号と、該マクロブロックとのミスマッチ数を計算し、この数がしきい値以下の場合には、縮小率を“1/4”とする。       (1) The number of mismatches between the reproduction signal when the macroblock is reduced to “1/4” and the macroblock is calculated. If this number is equal to or less than the threshold value, the reduction ratio is set to “1/1”. 4 ".

(2) 上記(1)でミスマッチ数がしきい値よりも大きい場合には、該マクロブロックを“1/2”に縮小した際の再生信号と、該マクロブロックとのミスマッチ数を計算し、この数がしきい値以下の楊合には、縮小率を“1/2”とする。       (2) If the number of mismatches is larger than the threshold value in (1) above, calculate the number of mismatches between the playback signal when the macroblock is reduced to “1/2” and the macroblock, When this number is less than or equal to the threshold value, the reduction ratio is set to “1/2”.

(3) 上記(2)でミスマッチ数がしきい値よりも大きい場合には、該マクロブロックの縮小率を“1”とする。       (3) If the number of mismatches is larger than the threshold value in (2) above, the reduction ratio of the macroblock is set to “1”.

このようにして求められたCR(縮小・拡大率)の値は、信号線1030を介して縮小回路1710,1730,1740、拡大回路1720および2値画像符号化回路1700に供給されると共に、VLC(可変長符号化)・多重化回路1800に供給され符号化された後、他の符号と多重化される。また、転置回路1750では、縮小回路1710より供給される、縮小された該ブロックの信号の位置が転置される(水平方向のアドレスと垂直方向のアドレスが入れ替えられる)。   The CR (reduction / enlargement ratio) value obtained in this manner is supplied to the reduction circuits 1710, 1730, 1740, the enlargement circuit 1720, and the binary image encoding circuit 1700 via the signal line 1030, and also the VLC. (Variable Length Coding) • After being supplied to the multiplexing circuit 1800 and encoded, it is multiplexed with other codes. Also, the transposition circuit 1750 transposes the position of the reduced signal of the block supplied from the reduction circuit 1710 (the horizontal address and the vertical address are exchanged).

このことにより、符号化の順序を水平方向のスキャン順に行うか、垂直方向のスキャン順に行うかが切り換えられる。また、転置回路1760では、縮小回路1730により縮小された該マクロブロック近傍の再生画素値と、縮小回路1740により縮小された動き補償予測信号とで、それぞれの信号の位置が転置される。   As a result, the encoding order can be switched between the horizontal scanning order and the vertical scanning order. Further, the transposition circuit 1760 transposes the position of each signal between the reproduction pixel value near the macroblock reduced by the reduction circuit 1730 and the motion compensated prediction signal reduced by the reduction circuit 1740.

転置回路1750,1760において、転置処理するか否かの判定は、例えば、2値画像符号化回路1700において水平スキャンと垂直スキャンとでそれぞれ符号化を行い、信号線1040を介して出力される符号化情報b4をST(Scan Type)判定回路1770に供給することによって、このST判定回路1770が、符号量の少なくなるスキャン方向を選択することで決まる。   In transposition circuits 1750 and 1760, whether or not to perform transposition processing is determined by, for example, encoding in horizontal scan and vertical scan in binary image encoding circuit 1700, respectively, and output via signal line 1040. By supplying the conversion information b4 to an ST (Scan Type) determination circuit 1770, the ST determination circuit 1770 is determined by selecting a scan direction in which the code amount decreases.

2値画像符号化回路1700では、転置回路1750より供給される該マクロブロックの信号を、転置回路1760より供給される参照信号を用いて符号化する。   In the binary image encoding circuit 1700, the signal of the macroblock supplied from the transposing circuit 1750 is encoded using the reference signal supplied from the transposing circuit 1760.

なお、具体的な2値画像符号化法の一例として、上述の第3の具体例で用いた手法が挙げられるが、これに限らず、第4の具体例でのこの2値画像符号化回路1700では他の2値画像符号化を適用することができる。   An example of a specific binary image encoding method is the method used in the third specific example described above, but is not limited thereto, and this binary image encoding circuit in the fourth specific example is used. In 1700, other binary image coding can be applied.

“coded”に分類されたブロックの中には、フレーム内の参照画素を用いる“intra”符号化モードと、動き補償予測信号を参照する“inter”符号化モードとがある。ここで、intra/interの切り替えは、例えば、線1040を介して供給される2値画像符号化回路1700からの符号化情報をモード判定回路1100に供給し、符号量の少なくなるモードを選択すればよい。ここで、選択された符号化モード(intra/inter)の情報は、信号線1050を介して2値画像符号化回路1700に供給される。   Among the blocks classified as “coded”, there are an “intra” coding mode using a reference pixel in a frame and an “inter” coding mode referring to a motion compensation prediction signal. Here, the intra / inter switching is performed by, for example, supplying the encoding information from the binary image encoding circuit 1700 supplied via the line 1040 to the mode determination circuit 1100 and selecting a mode with a small code amount. That's fine. Here, information on the selected encoding mode (intra / inter) is supplied to the binary image encoding circuit 1700 via the signal line 1050.

以上の手段により選択された最適なモードにて符号化された、2値画像符号化回路1700の符号化情報は、信号線1040を介してVLC・多重化回路1800に供給され、他の符号と共に多重化される。また、モード判定回路1100からは最適なモードの情報が信号線1060を介してVLC・多重化回路1800に供給され、符号化された後、他の符号と共に多重化される。また、動きベクトル検出回路(MVE)1780では、最適な動きベクトルが検出される。ここで、動きベクトルの検出方法については、種々存在しており、また、動きベクトルの検出法そのものは、本発明の要部ではないため、ここでは省略する。検出された動きベクトルは、信号線1070を介して動き補償予測回路1600に供給されると共に、MV符号化回路1790にて符号化された後、VLC・多重化回路1800に供給され、符号化された後、他の符号と共に多重化される。   The encoded information of the binary image encoding circuit 1700 encoded in the optimum mode selected by the above means is supplied to the VLC / multiplexing circuit 1800 via the signal line 1040, and together with other codes Multiplexed. Further, the mode determination circuit 1100 supplies information on the optimum mode to the VLC / multiplexing circuit 1800 via the signal line 1060, and after encoding, the information is multiplexed together with other codes. The motion vector detection circuit (MVE) 1780 detects an optimal motion vector. Here, there are various motion vector detection methods, and since the motion vector detection method itself is not a main part of the present invention, it is omitted here. The detected motion vector is supplied to the motion compensated prediction circuit 1600 via the signal line 1070 and encoded by the MV encoding circuit 1790 and then supplied to the VLC / multiplexing circuit 1800 and encoded. And then multiplexed with other codes.

多重化された符号は、信号線30を介して出力される。動き補償予測回路1600では、信号線1070を介して供給される動きベクトル信号に基づいてフレームメモリ1300に蓄積されている参照フレームの再生画像を用いて動き補償予測信号を生成し、信号線1010を介してモード判定回路1100および縮小回路1740に出力する。   The multiplexed code is output via the signal line 30. The motion compensation prediction circuit 1600 generates a motion compensation prediction signal using a reconstructed image of the reference frame stored in the frame memory 1300 based on the motion vector signal supplied via the signal line 1070, To the mode determination circuit 1100 and the reduction circuit 1740.

以上の処理の結果、画質の良い、しかも、高圧縮率での画像符号化をすることができる。   As a result of the above processing, it is possible to perform image coding with good image quality and high compression rate.

次に復号化について説明する。   Next, decoding will be described.

<アルファマップ復号化回路の構成例>
図22は、アルファマップ復号化回路400の詳細な構成図である。
図に示すように、アルファマップ復号化回路400は、VLC(可変長符号化)・分離化回路2100、モード再生回路2200、セレクタ2300、マクロブロック内画素値設定回路2400,2500、動き補償予測回路2600、フレームメモリ2700、2値画像復号化回路2800、拡大回路2810、転置回路2820,2850、縮小回路2830,2840、2値画像復号化回路2800、動きベクトル再生回路2900より構成される。
<Example of configuration of alpha map decoding circuit>
FIG. 22 is a detailed configuration diagram of the alpha map decoding circuit 400.
As shown in the figure, an alpha map decoding circuit 400 includes a VLC (variable length coding) / separation circuit 2100, a mode reproduction circuit 2200, a selector 2300, intra-macroblock pixel value setting circuits 2400 and 2500, and a motion compensation prediction circuit. 2600, frame memory 2700, binary image decoding circuit 2800, expansion circuit 2810, transposition circuits 2820 and 2850, reduction circuits 2830 and 2840, binary image decoding circuit 2800, and motion vector reproduction circuit 2900.

これらのうち、VLC(可変長符号化)・分離化回路2100は、多重化されて送られてきたアルファマップの符号化ビットストリームを復号し、モード情報b0、動きベクトル情報b1、縮小・拡大率情報b2、スキャン方向情報b3、2値画像符号化情報b4に分離する回路であり、モード再生回路2200はこの分離されたモード情報b0を受けて、“allW”,“allB”,“copy”,“coded”の4種のモードのうちのいずれのモードであるかを再生する回路である。   Among these, the VLC (variable length coding) / separation circuit 2100 decodes the encoded bit stream of the alpha map that has been multiplexed and sent, and mode information b0, motion vector information b1, reduction / enlargement rate This is a circuit that separates information b2, scan direction information b3, and binary image encoding information b4. The mode reproduction circuit 2200 receives the separated mode information b0 and receives “allW”, “allB”, “copy”, This is a circuit that reproduces which one of the four modes of “coded”.

2値画像復号化回路2800は前記VLC(可変長符号化)・分離化回路2100により分離された2値画像符号化情報b4を、前記分離された縮小・拡大率情報b2およびモード再生回路2200からの再生されたモード情報および転置回路2850の情報とを用いて2値画像に復号化して出力する回路であり、拡大回路2810は前記分離された縮小・拡大率情報b2の情報を用いて前記復号された2値画像を拡大処理する回路であり、転置回路2820はこの拡大処理された画像を、前記分離されたスキャン方向情報b3に従って転置処理し、再生信号m3として出力する回路である。   The binary image decoding circuit 2800 receives the binary image coding information b4 separated by the VLC (variable length coding) / separation circuit 2100 from the separated reduction / enlargement ratio information b2 and mode reproduction circuit 2200. Is a circuit that decodes and outputs a binary image using the reproduced mode information and information of the transposition circuit 2850, and the enlargement circuit 2810 uses the information of the separated reduction / enlargement ratio information b2 to perform the decoding. The transposed circuit 2820 is a circuit that transposes the enlarged image according to the separated scan direction information b3 and outputs it as a reproduction signal m3.

また、マクロブロック内画素値設定回路2400は,マクロブロック内画素値が全て白にされた再生信号m0を発生する回路であり、マクロブロック内画素値設定回路2500は,マクロブロック内画素値が全て黒にされた再生信号m1を発生する回路である。   The macroblock pixel value setting circuit 2400 is a circuit that generates a reproduction signal m0 in which all macroblock pixel values are white. The macroblock pixel value setting circuit 2500 includes all macroblock pixel values. This is a circuit for generating a black reproduction signal m1.

動きベクトル再生回路2900は、前記VLC(可変長符号化)・分離化回路2100により分離された動きベクトル情報b1を用いてマクロブロックの動きベクトルを再生する回路であり、動き補償予測回路2600はこの再生された動きベクトルを用いてフレームメモリ2700の蓄積参照フレームを再生画像から動き補償予測値m2を生成する回路であり、縮小回路2840は前記分離された縮小・拡大率情報b2の情報を用いて前記動き補償予測値m2を縮小処理するものであり、縮小回路2830は前記分離された縮小・拡大率情報b2の情報を用いて前記フレームメモリ2700の蓄積参照フレームの画像を縮小処理するものであり、転置回路2850は前記VLC(可変長符号化)・分離化回路2100により分離されたスキャン方向情報b3を基に、縮小回路2830,2840の出力する縮小画像を転置処理して2値画像復号化回路2800に出力する回路である。   The motion vector reproduction circuit 2900 is a circuit that reproduces the motion vector of the macroblock using the motion vector information b1 separated by the VLC (variable length coding) / separation circuit 2100. The motion compensation prediction circuit 2600 This is a circuit for generating a motion compensated prediction value m2 from a reproduced image by using a reconstructed motion vector and a reference frame stored in the frame memory 2700, and a reduction circuit 2840 uses the information of the separated reduction / enlargement ratio information b2. The motion compensation prediction value m2 is reduced, and the reduction circuit 2830 reduces the image of the stored reference frame in the frame memory 2700 using the separated reduction / enlargement ratio information b2. The transposition circuit 2850 is a circuit separated by the VLC (variable length coding) / separation circuit 2100. Based on the emission direction information b3, a circuit for outputting a reduced image permutation to the binary image decoding circuit 2800 outputs to the reduction circuit 2830,2840.

また、セレクタ2300は、モード再生回路2200の出力するモード情報に応じて、マクロブロック内画素値設定回路2400,2500の再生信号m0,m1、動き補償予測回路2600の動き補償予測値m2、転置回路2820の再生信号m3のうち、いずれかを選択して出力するものであり、フレームメモリ2700はこのセレクタ2300の出力した画像信号をフレーム単位で保持するメモリである。   In addition, the selector 2300 generates reproduction signals m0 and m1 from the intra-macroblock pixel value setting circuits 2400 and 2500, a motion compensation prediction value m2 from the motion compensation prediction circuit 2600, and a transposition circuit according to mode information output from the mode reproduction circuit 2200. One of the 2820 reproduction signals m3 is selected and output, and the frame memory 2700 is a memory that holds the image signal output from the selector 2300 in units of frames.

このような構成のアルファマップ復号化回路400は、信号線80を介してアルファマップの符号化ビットストリームが供給される。そして、このビットストリームはVLD(可変長復号化)・分離化回路2100に供給される。   The alpha map decoding circuit 400 having such a configuration is supplied with the encoded bit stream of the alpha map via the signal line 80. This bit stream is supplied to a VLD (variable length decoding) / separation circuit 2100.

すると、VLD(可変長復号化)・分離化回路2100では、このビットストリームを復号し、かつ、モード情報b0、動きベクトル情報b1、縮小・拡大率情報b2、スキャン方向情報b3、2値画像符号化情報b4に分離する。これら分離された情報はマクロブロック単位で管理される。   Then, the VLD (variable length decoding) / separation circuit 2100 decodes this bit stream, and mode information b0, motion vector information b1, reduction / enlargement ratio information b2, scan direction information b3, binary image code. The information is separated into conversion information b4. The separated information is managed in units of macro blocks.

そして、この分離された情報のうち、モード情報b0は、モード再生回跨2200に供給され、該マクロブロックが以下のモードの何れに属するかを分類する。   Of the separated information, the mode information b0 is supplied to the mode reproduction crossover 2200, and classifies to which of the following modes the macroblock belongs.

(1)“allW”
(2)“allB”
(3)“copy”
(4)“coded”
ここで、“coded”には、図21の符号化回路の具体例で述べたとおり“intra”のモードと“inter”のモードとがある。すなわち、フレーム内の参照画素を用いるのが“intra”符号化モードであり、動き補償予測信号を参照するのが“inter”符号化モードである。
(1) “allW”
(2) “allB”
(3) “copy”
(4) “coded”
Here, “coded” has an “intra” mode and an “inter” mode as described in the specific example of the encoding circuit of FIG. That is, the “intra” coding mode uses the reference pixels in the frame, and the “inter” coding mode refers to the motion compensated prediction signal.

セレクタ2300では、信号線2010を介して供給される上記の符号化モードに応じて、該マクロブロックのモードが“allW”の場合は、ブロック内画素値設定回路2400においてマクロブロック内画素値が全て白にされた再生信号m0が選択され、信号線90を介してフレームメモリ2700に供給され、該フレームメモリ2700の当該マクロブロックが属する画像フレームの記憶領域に蓄えられると共に、アルファマップ復号化回路400から復号化されたアルファマップの画像として出力される。   In the selector 2300, when the macroblock mode is “allW” in accordance with the encoding mode supplied via the signal line 2010, all the pixel values in the macroblock are set in the pixel value setting circuit 2400 in the block. The reproduction signal m0 made white is selected, supplied to the frame memory 2700 via the signal line 90, stored in the storage area of the image frame to which the macroblock belongs, and the alpha map decoding circuit 400. Is output as an alpha map image decoded.

同様に、該マクロブロックのモードが“allB”の場合は、マクロブロック内画素値設定回路2500において、ブロック内画素値が全て黒にされた再生信号m1が選択され、また、該ブロックのモードが“copy”の場合は、信号線2020を介して供給される動き補償予測回路2600において生成された動き補償予測信号m2が選択され、また、該ブロックのモードが゛“coded”の場合には、拡大回路2810、転置回路2820を経て供給される再生信号m3が選択され、信号線90を介してフレームメモリ2700に供給され、該フレームメモリ2700の当該マクロブロックが属する画像フレームの記憶領域に蓄えられると共に、アルファマップ復号化回路400から復号化されたアルファマップの画像として出力される。   Similarly, when the mode of the macroblock is “allB”, the reproduction signal m1 in which the pixel values in the block are all black is selected in the pixel value setting circuit 2500 in the macroblock, and the mode of the block is In the case of “copy”, the motion compensation prediction signal m2 generated in the motion compensation prediction circuit 2600 supplied via the signal line 2020 is selected, and when the mode of the block is “coded”, A reproduction signal m3 supplied through the enlargement circuit 2810 and the transposition circuit 2820 is selected, supplied to the frame memory 2700 via the signal line 90, and stored in the storage area of the image frame to which the macroblock belongs in the frame memory 2700. At the same time, the image is output as a decoded alpha map image from the alpha map decoding circuit 400. That.

一方、分離された動きベクトル情報b1は、動きベクトル再生回路2900に供給され、該マクロブロックの動きベクトルが再生される。ここで、再生された動きベクトルは、信号線2030を介して動き補償予測回路2600に供給され、動き補償予測回路2600ではこの動きベクトルに基づいて、フレームメモリ2700に蓄積されている参照フレームの再生面像から動き補償予測値を生成する。そして、信号線2020を介して縮小回路2840とセレクタ2300とに出力する。   On the other hand, the separated motion vector information b1 is supplied to the motion vector reproduction circuit 2900, and the motion vector of the macroblock is reproduced. Here, the reproduced motion vector is supplied to the motion compensation prediction circuit 2600 via the signal line 2030, and the motion compensation prediction circuit 2600 reproduces the reference frame stored in the frame memory 2700 based on the motion vector. A motion compensated prediction value is generated from the surface image. Then, the signal is output to the reduction circuit 2840 and the selector 2300 via the signal line 2020.

また、分離された縮小・拡大率情報b2は、縮小回路2830および拡大回路2810に供給されると共に、2値画像復号化回路2800に供給され、スキャン方向情報b3は、転置回路2820,2850に供給される。   The separated reduction / enlargement ratio information b2 is supplied to the reduction circuit 2830 and the enlargement circuit 2810, and is also supplied to the binary image decoding circuit 2800, and the scan direction information b3 is supplied to the transposition circuits 2820 and 2850. Is done.

そして、スキャン方向情報b3を受けた転置回路2820では、拡大回路2810より供給される、元のサイズに戻された該マクロブロックの再生信号の位置が転置される(水平方向のアドレスと垂直方向のアドレスが入れ替えられる)。また、スキャン方向情報b3を受けた転置回路2850では、縮小回路2830により縮小された該ブロック近傍の再生画素値と、縮小回路2840により縮小された動き補償予測信号とで、それぞれの信号の位置が転置される。   The transposition circuit 2820 that has received the scan direction information b3 transposes the position of the reproduction signal of the macroblock supplied from the enlargement circuit 2810 and returned to the original size (the horizontal address and the vertical direction). Addresses are swapped). Also, in the transposition circuit 2850 that has received the scan direction information b3, the position of each of the reproduced pixel values near the block reduced by the reduction circuit 2830 and the motion compensation prediction signal reduced by the reduction circuit 2840 are the positions of the signals. Transposed.

縮小・拡大率情報b2を受けた2値画像復号化回路2800では、分離化回路2100により分離された該マクロブロックの2値画像符号化情報b4を、転置回路2850より供給される参照信号を用いて復号化する。   In the binary image decoding circuit 2800 that has received the reduction / enlargement ratio information b2, the binary image encoding information b4 of the macroblock separated by the separation circuit 2100 is used as a reference signal supplied from the transposition circuit 2850. To decrypt.

ところで、先行技術として本発明者らが提案した特願平8−237053号の第4の具体例に記載したように、拡大回路1720,2810の出力には斜め方向の不連続性に起因する画質劣化が発生する場合があるが、この問題を解決するために拡大回路1720,2810には、斜め方向の不連続性を抑えるフィルタを備えるようにしても良い。   By the way, as described in the fourth specific example of Japanese Patent Application No. 8-237053 proposed by the present inventors as the prior art, the output of the enlargement circuits 1720 and 2810 has an image quality caused by oblique discontinuity. Although deterioration may occur, in order to solve this problem, the expansion circuits 1720 and 2810 may be provided with a filter that suppresses the discontinuity in the oblique direction.

なお、2値画像符号化回路1700と同様に、用いる2値画像復号化回路2800の構成は上述の第3の具体例に示した構成例に限らない。   Similar to the binary image encoding circuit 1700, the configuration of the binary image decoding circuit 2800 to be used is not limited to the configuration example shown in the third specific example.

<複数の2値画像符号化法を切り換える具体例>
上記の具体例の中で、2値画像符号化回路1700および2値画像復号化回路2800の具体例は、上述の第3の具体例に限らないと記述した。そこで、これ以外の例を示しておく。
<Specific example of switching a plurality of binary image encoding methods>
In the above specific examples, the specific examples of the binary image encoding circuit 1700 and the binary image decoding circuit 2800 are described as not limited to the third specific example. Therefore, other examples will be shown.

別の2値画像符号化法として、例えば、マルコフモデル符号化法がある(参照:テレビジョン学会編、“画像情報圧縮”、pp.171 〜176 )。図23がマルコフモデル符号化法の一例を説明する図である。図中の画素xが符号化の対象となる着目画素であり、画素a〜fが画素xを符号化する際に参照される参照画素である。
ここで、画素a〜fは画素xを符号化する際に既に符号化が終了している画素とする。着目画素xは、参照画素a〜fの状態によって、VLC(可変長符号化)を使用する場合には可変長符号テーブルが、そして、算術符号を使用する場合には確率テーブルが、適応的に切り換えられて符号化される。
As another binary image encoding method, for example, there is a Markov model encoding method (see: Television Society, “Image Information Compression”, pp. 171 to 176). FIG. 23 is a diagram for explaining an example of the Markov model encoding method. A pixel x in the drawing is a target pixel to be encoded, and pixels a to f are reference pixels that are referred to when encoding the pixel x.
Here, the pixels a to f are pixels that have already been encoded when the pixel x is encoded. For the pixel of interest x, depending on the states of the reference pixels a to f, a variable length code table is adaptively used when VLC (variable length coding) is used, and a probability table is adaptively used when arithmetic code is used. It is switched and encoded.

この具体例を本発明に適用する場合、“intra”符号化は、現在処理しようとしているマクロブロック内で、着目画素より先に符号化された画素を参照画素とし、“inter”符号化は現在処理しようとしているマクロブロック内で、着目画素より先に符号化された画素だけでなく、動き補償予測誤差信号内の画素も参照画素として用いればよい。   When this specific example is applied to the present invention, “intra” encoding uses a pixel encoded before the target pixel in a macroblock to be processed as a reference pixel, and “inter” encoding is In the macroblock to be processed, not only the pixel encoded before the target pixel but also the pixel in the motion compensation prediction error signal may be used as the reference pixel.

本具体例では、例えば、
[方式1]第3の具体例の方式(MMRに基づいた符号化方式)
と、
[方式2]マルコフモデル符号化を適応的に切り換えて符号化する方式
の両方式を備え、これらを適応的に選択して使用する形態を採用することを特徴としている。
In this example, for example,
[Method 1] Method of the third specific example (encoding method based on MMR)
When,
[Method 2] It is characterized in that both methods of the method of adaptively switching the Markov model encoding are provided, and a mode in which these are adaptively selected and used is adopted.

図24(a)は、本具体例で用いられる、2値画像符号化回路1700のブロック図である。図に示すように、2値画像符号化回路1700は、一対のセレクタ4110,4140と、一対の2値画像符号化回路から構成されている。これらのうち、セレクタ4101は入力側の選択回路であり、セレクタ4102は出力側の選択回路である。2値画像符号化回路4120は上記[方式1]で符号化する第1の2値画像符号化回路であり、2値画像符号化回路4130は上記[方式2]で符号化する第2の2値画像符号化回路である。   FIG. 24A is a block diagram of a binary image encoding circuit 1700 used in this specific example. As illustrated, the binary image encoding circuit 1700 includes a pair of selectors 4110 and 4140 and a pair of binary image encoding circuits. Among these, the selector 4101 is an input side selection circuit, and the selector 4102 is an output side selection circuit. The binary image encoding circuit 4120 is a first binary image encoding circuit that encodes according to the [Method 1], and the binary image encoding circuit 4130 is a second 2 that encodes according to the [Method 2]. It is a value image encoding circuit.

2値画像符号化回路1700では、信号線4101を介して転置回路1750から供給される処理対象マクロブロックの信号を、信号線4103を介して供給される切り換え信号に応じて選択切換えするセレクタ4110,4140により、第1の2値画像符号化回路4120と第2の2値画像符号化回路4130に適応的に振り分け、この振り分けられたマクロブロックの信号を符号化する。   In the binary image encoding circuit 1700, a selector 4110, which selectively switches the signal of the processing target macroblock supplied from the transposition circuit 1750 via the signal line 4101 according to the switching signal supplied via the signal line 4103. By 4140, the first binary image encoding circuit 4120 and the second binary image encoding circuit 4130 are adaptively allocated, and the allocated macroblock signal is encoded.

符号化された情報は、信号線4102を介して出力される。なお、図24(a)では2値画像符号化回路1700に供給される信号の信号線1030,1050、転置回路1760からの信号線は、省略されている。   The encoded information is output via the signal line 4102. In FIG. 24A, signal lines 1030 and 1050 for signals supplied to the binary image encoding circuit 1700 and signal lines from the transposition circuit 1760 are omitted.

ここで、信号線4103を介して供給される切り換え情報は、予め設定されたデフォルト値でも良いし、画像内容に基づいて適切な切り換え情報を求めて、サイド情報として別途符号化し、復号側に伝送するようにしてもよい。   Here, the switching information supplied via the signal line 4103 may be a preset default value, or appropriate switching information is obtained based on the image content, separately encoded as side information, and transmitted to the decoding side. You may make it do.

これにより、画像内容に基づいた最適処理が可能になり、また、アプリケーションに応じて複数の符号化方式の中から適切なものを選択して使用することも可能になる。   As a result, it is possible to perform optimum processing based on the image content, and it is also possible to select and use an appropriate one from a plurality of encoding methods according to the application.

同様に、図24(b)は、本具体例で用いられる2値画像復号化回路2800のブロック図である。図に示すように、2値画像復号化回路2800は一対のセレクタ4210,4240、一対の2値画像復号化回路4220,4230とから構成されている。これらのうち、セレクタ4210は入力側の選択回路であり、セレクタ4240は出力側の選択回路である。また、2値画像復号化回路4220は上記[方式1]で符号化した画像を復号化する第1の2値画像復号化回路であり、2値画像復号化回路4230は上記[方式2]符号化した画像を復号する第2の2値画像復号化回路である。   Similarly, FIG. 24B is a block diagram of a binary image decoding circuit 2800 used in this specific example. As shown, the binary image decoding circuit 2800 includes a pair of selectors 4210 and 4240 and a pair of binary image decoding circuits 4220 and 4230. Among these, the selector 4210 is an input side selection circuit, and the selector 4240 is an output side selection circuit. The binary image decoding circuit 4220 is a first binary image decoding circuit that decodes the image encoded by the [Method 1]. The binary image decoding circuit 4230 is the above [Method 2] code. 2 is a second binary image decoding circuit for decoding the converted image.

このような構成の2値画像復号化回路2800では、信号線4201を介して供絵される処理対象マクロブロックの2値画像符号化情報b4を、信号線4203を介して供給される切り換え信号に応じてセレクタ4210,4240により、第1の2値画像復号化回路4220と第2の2値画像復号化回路4230に適応的に振り分けて復号化する。   In the binary image decoding circuit 2800 having such a configuration, the binary image encoding information b4 of the processing target macroblock supplied via the signal line 4201 is used as the switching signal supplied via the signal line 4203. Accordingly, the selectors 4210 and 4240 adaptively distribute the data to the first binary image decoding circuit 4220 and the second binary image decoding circuit 4230 for decoding.

復号化された信号は、信号線4202を介して出力される。なお、図24(b)では2値画像復号化回路2800に対する分離化回路2100からの信号供給用の信号線,モード再生回路2200からの信号線,転置回路2850からの信号線は省略されている。   The decoded signal is output via a signal line 4202. In FIG. 24B, the signal line for signal supply from the separation circuit 2100 to the binary image decoding circuit 2800, the signal line from the mode reproduction circuit 2200, and the signal line from the transposition circuit 2850 are omitted. .

ここで、信号線4203を介して供給される切り換え情報は、デフォルト値でも良いし、符号化されて送られてきたビットストリームから当該切換情報を得るエンコーダから送られてきた情報でも良い。   Here, the switching information supplied via the signal line 4203 may be a default value, or may be information sent from an encoder that obtains the switching information from an encoded bit stream.

次に縮小・拡大を行うための回路例を具体的に示す。   Next, a specific example of a circuit for performing reduction / enlargement will be described.

<<縮小・拡大回路に関わる具体例>>
[拡大処理の例]
本発明は、符号化領域単位あるいはブロック単位(マクロブロック単位)で縮小・拡大処理を施すことでレート制御を行っている。この縮小・拡大処理に利用する技術の例として、本願発明者等が特願平8−237053号に開示した“双一次内挿”がある。この技術について触れておく。当該双一次内挿は、参考文献“尾上編:画像処理ハンドブック,p.630,昭晃堂”を基に説明すると図35の如きである。
<< Specific examples of reduction / enlargement circuit >>
[Example of enlargement processing]
In the present invention, rate control is performed by performing reduction / enlargement processing in units of coding regions or blocks (macroblock units). As an example of a technique used for the reduction / enlargement processing, there is “bilinear interpolation” disclosed in Japanese Patent Application No. 8-237053 by the inventors of the present application. Let me touch on this technology. The bilinear interpolation is illustrated in FIG. 35 based on the reference document “Onoe: Image Processing Handbook, p.630, Shosodo”.

図35(a)において、Pexは変換後の画素位置であり、当該Pexは図35(a)のように実数画素位置を指し示す。   In FIG. 35A, Pex is a pixel position after conversion, and the Pex indicates a real pixel position as shown in FIG.

そこで、入力信号の整数画素位置A,B,C,Dとの距離関係から、8つの領域に分けて図35(b)に示す論理式により、A〜Dの画素値Ia〜IdからPexの画素値Ipを求める。   Therefore, from the distance relationship with the integer pixel positions A, B, C, and D of the input signal, the pixel values Ia to Id of A to D are changed from Pex to Pex according to the logical expression shown in FIG. A pixel value Ip is obtained.

このようなものが“双一次内挿”という処理であり、A〜Dの画素値Ia〜IdからPexの画素値Ipを簡易に求めることができるものである。   Such a process is called “bilinear interpolation”, and the pixel value Ip of Pex can be easily obtained from the pixel values Ia to Id of A to D.

ところで、この双一次内挿処理は周囲の4画素のみを用いて処理を行っているため、広い範囲での変化が反映されず、特に斜め方向の不連続性が発生し易くなっている。この問題を解決するための一例として、拡大処理を行った後にスムーシングフィルタ処理(平滑化処理)を施す例を、先願の発明(特願平8−237053号)に提示している。   By the way, since this bilinear interpolation process is performed using only the surrounding four pixels, a change in a wide range is not reflected, and discontinuity in an oblique direction is particularly likely to occur. As an example for solving this problem, an example in which smoothing filter processing (smoothing processing) is performed after performing enlargement processing is presented in the invention of the prior application (Japanese Patent Application No. 8-237053).

具体的に説明する。図36は、スムーシング処理(平滑化処理)を説明するための図である。ここで、図36の(a)は元のサイズの2値画像、図36の(b)はこれを縮小して得た2値画像である。図36においては、オブジェクト領域は黒丸印で、また、バックグラウンド(背景)領域は白丸印で示してある。   This will be specifically described. FIG. 36 is a diagram for explaining the smoothing process (smoothing process). Here, FIG. 36A shows a binary image of the original size, and FIG. 36B shows a binary image obtained by reducing this. In FIG. 36, the object area is indicated by a black circle, and the background area is indicated by a white circle.

この例では、サンプリング変換(拡大・縮小変換)がなされることにより発生する斜め方向の不連続性を滑らかにするために、バックグラウンド領域の画素(白丸)一つ一つについて、それを中心にして、その上下左右の画素、つまり、隣接画素を調べ、そのうち、2画素以上がオブジェクト領域の画素(黒丸)であったときは、そのバックグラウンド領域の画素を、オブジェクト領域に含める処理を行う。   In this example, in order to smooth the discontinuity in the diagonal direction caused by sampling conversion (enlargement / reduction conversion), each pixel (white circle) in the background area is centered on it. Then, the top, bottom, left and right pixels, that is, adjacent pixels are examined. If two or more pixels are pixels (black circles) in the object area, processing for including the pixels in the background area in the object area is performed.

すなわち、今、バックグラウンド領域にある一つの画素である検査対象画素が図36(b)における二重丸印で示す位置の画素である場合のように、その隣接画素に、2画素以上、オブジェクト領域の画素(黒丸)があったときは、その二重丸印で示す位置の画素(つまり、検査対象画素)を黒丸印の画素にしてオブジェクト領域の画素にする。黒丸印の画素が例えば、“1”、白丸印が“0”であるとすると、二重丸印で示す位置の画素(画素値“0”)を、画素値“1”に置き換える処理をする。このような処理により、斜め方向の不連続性を解消できるようになる。   That is, two or more pixels are adjacent to the adjacent pixel as in the case where the pixel to be inspected that is one pixel in the background area is a pixel at a position indicated by a double circle in FIG. When there is an area pixel (black circle), the pixel at the position indicated by the double circle (that is, the pixel to be inspected) is changed to a black circle pixel to be a pixel in the object area. For example, assuming that the black circle is “1” and the white circle is “0”, the pixel at the position indicated by the double circle (pixel value “0”) is replaced with the pixel value “1”. . By such processing, the discontinuity in the oblique direction can be eliminated.

図37は、スムーシングフィルタ(平滑化処理フィルタ)の別の例である。図37に示される、3×3画素のマスクの中心の画素をCとして、Cに対して左上の画素をTL、右上の画素をTR、左下の画素をBL、右下の画素をBRとすると、下記の式により、画素Cのフィルタリングされた値が求められる。ここで、オブジェクトの値を“1”、背景の値を“0”で表わしている。

Figure 2008011564
FIG. 37 shows another example of the smoothing filter (smoothing process filter). If the center pixel of the 3 × 3 pixel mask shown in FIG. 37 is C, the upper left pixel is TL, the upper right pixel is TR, the lower left pixel is BL, and the lower right pixel is BR. The filtered value of the pixel C is obtained by the following equation. Here, the value of the object is represented by “1” and the background value is represented by “0”.
Figure 2008011564

すなわち、このフィルタ演算処理は、もし画素Cが“0”であれば、画素TL,TR,BL,BRを加算した値が“2”より大きいか否かを調べ、大きい場合は画素Cの値を“1”とし、大きくない場合は画素Cを“0”とし、また、もし画素Cが“0”でなければ、画素TL,TR,BL,BRを加算した値が“2”より小さいか否かを調べ、小さい場合は画素Cの値を“1”とし、大きくない場合は画素Cを“0”とするというものである。   That is, this filter calculation process checks whether the value obtained by adding the pixels TL, TR, BL, BR is greater than “2” if the pixel C is “0”, and if it is greater, the value of the pixel C If the pixel C is not “0”, the sum of the pixels TL, TR, BL, BR is less than “2”. If not, the value of the pixel C is set to “1”, and if not, the pixel C is set to “0”.

このフィルタによれば、対象となる画素Cに対して斜め方向に位置する画素値の変化を考慮して画素Cの値を修正するため、斜め方向の不連続性が解消される。なお、スムーシングフィルタの構成は上記例に限ったものではなく、メディアンフィルタ等の非線形フィルタを用いても良い。   According to this filter, since the value of the pixel C is corrected in consideration of the change in the pixel value located in the diagonal direction with respect to the target pixel C, the discontinuity in the diagonal direction is eliminated. The configuration of the smoothing filter is not limited to the above example, and a non-linear filter such as a median filter may be used.

図58(a)は、双一次内挿により水平・垂直共に2倍に拡大する処理を表す図である。図58(a)において、縮小ブロックの画素は白丸印すなわち“O”印で表され、内挿される画素はバツ印すなわち、“×”印で表されており、それぞれの画素値は“0”あるいは“1”の何れかである。   FIG. 58A is a diagram illustrating a process of enlarging the horizontal and vertical by a factor of two by bilinear interpolation. In FIG. 58A, the pixels of the reduced block are represented by white circles, that is, “O” marks, the pixels to be interpolated are represented by crosses, ie, “x” marks, and each pixel value is “0”. Alternatively, it is either “1”.

この場合、図35(b)の論理式で内挿される画素(再生画素)の値を求めると、
Ip1=Ia,Ip2=Ib,Ip3=Ic,Ip4=Id
となる。
従って、画素Aの周りの4つの内挿画素の画素値は全てIaとなるために、拡大画像は2×2画素が同じ値となり、滑らかさが失われる。そこで、双一次内挿の重み付けを以下の様に変更することで、上記の問題は解決される。
In this case, when the value of the pixel (reproduced pixel) to be interpolated with the logical expression of FIG.
Ip1 = Ia, Ip2 = Ib, Ip3 = Ic, Ip4 = Id
It becomes.
Accordingly, since the pixel values of the four interpolated pixels around the pixel A are all Ia, the enlarged image has the same value of 2 × 2 pixels, and the smoothness is lost. Therefore, the above problem can be solved by changing the weight of bilinear interpolation as follows.

Ip1:if(2*Ia +Ib +Ic +Id >2)then“1”else“0”
Ip2:if(Ia +2*Ib +Ic +Id >2)then“1”else“0”
Ip3:if(Ia +Ib +2*Ic+Id >2)then“1”else“0”
Ip4:if(Ia +Ib +Ic +2*Id >2)then“1”else“0”
ここで、Pi(i=1,2,3,4)は、図58(a)に示される“×”位置に対応した内挿される画素であり、Ipi(i=l,2,3,4)は画素Pi(i=1,2,3,4)の画素値(“1”または“0”)である。また、A,B,C,Dは縮小ブロックの画素、Ia ,Ib ,Ic ,Id はこれら画素A,B,C,Dの画素値である。
Ip1: if (2 * Ia + Ib + Ic + Id> 2) then “1” else “0”
Ip2: if (Ia + 2 * Ib + Ic + Id> 2) then “1” else “0”
Ip3: if (Ia + Ib + 2 * Ic + Id> 2) then “1” else “0”
Ip4: if (Ia + Ib + Ic + 2 * Id> 2) then “1” else “0”
Here, Pi (i = 1, 2, 3, 4) is a pixel to be interpolated corresponding to the “x” position shown in FIG. 58 (a), and Ipi (i = 1, 2, 3, 4). ) Is the pixel value (“1” or “0”) of the pixel Pi (i = 1, 2, 3, 4). A, B, C, and D are the pixels of the reduced block, and Ia, Ib, Ic, and Id are the pixel values of these pixels A, B, C, and D.

『Ip1:if(2*Ia +Ib +Ic +Id >2)then“1”else“0”』の意味は、画素p1の画素値Ip1は、もし、Ia の2倍値と、Ibと、Ic と、Id との和が2より大きければ“1”とし、そうでなければ“0”とするということを示しており、
『Ip2:if(Ia +2*Ib +Ic +Id >2)then“1”else“0”』の意味は、
画素p2の画素値Ip2は、もし、Ib の2倍値と、Ia と、Ic と、Id との和が2より大きければ、“1”とし、そうでなければ“0”とすると云うことを示しており、
『Ip3:if(Ia +Ib +2*Ic+Id >2)then“1”else“0”』の意味は、
画素p3の画素値Ip3は、もし、Ic の2倍値と、Ia と、Ib と、Id との和が2より大きければ、“1”とし、そうでなければ“0”とすると云うことを示しており、
『Ip4:if(Ia +Ib +Ic +2*Id >2)then“1”else“0”』の意味は、
画素p4の画素値Ip4は、もし、Id の2倍値と、Ia と、Ib と、Ic との和が2以上ならば、“1”とし、そうでなければ“0”とすると云うことを示している。
なお、水平・垂直共に4倍に拡大する場合は、上記の処理を2回繰り返せばよい。
“Ip1: if (2 * Ia + Ib + Ic + Id> 2) then“ 1 ”else“ 0 ”” means that the pixel value Ip1 of the pixel p1 is the double value of Ia, Ib, Ic, "1" if the sum of Id is greater than 2, otherwise "0".
“Ip2: if (Ia + 2 * Ib + Ic + Id> 2) then“ 1 ”else“ 0 ”” means
The pixel value Ip2 of the pixel p2 is “1” if the sum of the double value of Ib and Ia, Ic, and Id is greater than 2, otherwise it is “0”. Shows,
“Ip3: if (Ia + Ib + 2 * Ic + Id> 2) then“ 1 ”else“ 0 ”” means
The pixel value Ip3 of the pixel p3 is “1” if the sum of the double value of Ic, Ia, Ib, and Id is greater than 2, and “0” otherwise. Shows,
“Ip4: if (Ia + Ib + Ic + 2 * Id> 2) then“ 1 ”else“ 0 ”” means
The pixel value Ip4 of the pixel p4 is “1” if the sum of the double value of Id, Ia, Ib, and Ic is 2 or more, and “0” otherwise. Show.
In addition, when enlarging 4 times horizontally and vertically, the above process may be repeated twice.

以上は、演算により拡大処理する例であるが、演算によらずとも拡大処理することはできる。その例を次に説明する。   The above is an example of performing enlargement processing by computation, but enlargement processing can be performed without using computation. An example of this will be described next.

<演算によらない拡大処理の例>
ここでは、テーブルを用意してこれをメモリに保持させ、このテーブルに従って一義的に画素を置き換えるようにするものである。
<Example of enlargement processing without calculation>
Here, a table is prepared and held in a memory, and pixels are uniquely replaced according to this table.

具体的に説明する。まず、例えばメモリのアドレスを4ビットとし、Ia,Ib,Ic,Idを並べて得られるアドレスに、その、Ia,Ib,Ic,Idのパターンによって得られるIp1,Ip2,Ip3,Ip4を下表の様に予め記録しておく。

Figure 2008011564
This will be specifically described. First, for example, the memory address is 4 bits, and Ip1, Ip2, Ip3, Ip4 obtained by the pattern of Ia, Ib, Ic, Id are assigned to the addresses obtained by arranging Ia, Ib, Ic, Id in the table below. Record in advance.
Figure 2008011564

この例は、“Ia,Ib,Ic,Id”が“0,0,0,0”の時は、“Ip1,Ip2,Ip3,Ip4”が“0,0,0,0”であることを、“Ia,Ib,Ic,Id”が“0,0,0,1”の時は、“Ip1,Ip2,Ip3,Ip4”が“0,0,0,0”であることを、“Ia,Ib,Ic,Id”が“0,0,1,1”の時は、“Ip1,Ip2,Ip3,Ip4”が“0,0,1,1”であることを、“Ia,Ib,Ic,Id”が“0,1,0,1”の時は、“Ip1,Ip2,Ip3,Ip4”が“0,1,0,1”であることを、そして、“Ia,Ib,Ic,Id”が“0,1,1,0”の時は、“Ip1,Ip2,Ip3,Ip4”が“0,1,1,0”であることを、…と云う具合にIa,Ib,Ic,Idの内容の組み合わせが決まれば、Ip1,Ip2,Ip3,Ip4が一義的に定まるテーブルを表している。   In this example, when “Ia, Ib, Ic, Id” is “0, 0, 0, 0”, “Ip1, Ip2, Ip3, Ip4” is “0, 0, 0, 0”. , “Ia, Ib, Ic, Id” is “0, 0, 0, 1”, “Ip1, Ip2, Ip3, Ip4” is “0, 0, 0, 0”. , Ib, Ic, Id ”is“ 0, 0, 1, 1 ”,“ Ip1, Ip2, Ip3, Ip4 ”is“ 0, 0, 1, 1 ”. When “Ic, Id” is “0, 1, 0, 1”, “Ip1, Ip2, Ip3, Ip4” is “0, 1, 0, 1” and “Ia, Ib, Ic” , Id ”is“ 0, 1, 1, 0 ”,“ Ip1, Ip2, Ip3, Ip4 ”is“ 0, 1, 1, 0 ”, and so on. If the combination of the contents of Ic and Id is determined, Ip1, Ip2, Ip3, and Ip4 are unambiguous. It represents a table that is determined by.

このようなテーブルをIa,Ib,Ic,Idの内容がアドレス、そのアドレスの格納データがIp1,Ip2,Ip3,Ip4となるようにメモリに設定保持させ手おくと、内挿処理を行う時には、メモリにIa,Ib,Ic,Idのアドレスを入力して、それに対応するIp1,Ip2,Ip3,Ip4を読み出すだけで、内挿値を求めることができる。ここで、Ip1,Ip2,Ip3,Ip4の並びは2進数であるが、これを10進数に変換した数値をコンテキストと呼ぶこととすると、この手法は、Ip1,Ip2,Ip3,Ip4によって求まるコンテキストによって、内挿値Ip1,Ip2,Ip3,Ip4を決める実施例と言える。   If such a table is set and held in the memory so that the contents of Ia, Ib, Ic, and Id are addresses and the stored data at those addresses are Ip1, Ip2, Ip3, and Ip4, An interpolation value can be obtained simply by inputting the addresses Ia, Ib, Ic, and Id into the memory and reading out the corresponding Ip1, Ip2, Ip3, and Ip4. Here, the sequence of Ip1, Ip2, Ip3, and Ip4 is a binary number. If a numerical value obtained by converting this into a decimal number is called a context, this technique is based on the context determined by Ip1, Ip2, Ip3, and Ip4. It can be said that the interpolation values Ip1, Ip2, Ip3, and Ip4 are determined.

なお、コンテキストは
コンテキスト=2*2*2*Ia+2*2*Ib+2*Ic+Id
で求まる。
The context is
Context = 2 * 2 * 2 * Ia + 2 * 2 * Ib + 2 * Ic + Id
It is obtained by.

コンテキストによって内挿値を求める手法は、上述の例の場合、参照する画素数を4つとしたが、これに限らず、以下で説明する12個等、いくつの場合でも実現できる。   In the above example, the method for obtaining the interpolated value depending on the context is referred to as four pixels. However, the number of pixels to be referred to is not limited to this, and can be realized in any number of cases such as 12 described below.

また、参照画素と内挿画素の配置についても、例えば、図64(a)のように内挿画素P1に対しては点線で囲んだ領域の9画素分を参照画素としてコンテキスト(=0〜511)を求め、そのコンテキストによって、内挿画素P1を“0”か“1”かに決定する方法もある。   Also, with respect to the arrangement of the reference pixels and the interpolation pixels, for example, as shown in FIG. 64A, for the interpolation pixel P1, nine pixels in a region surrounded by a dotted line are used as contexts (= 0 to 511). ) And determining the interpolated pixel P1 to be “0” or “1” depending on the context.

内挿画素P2、P3、P4についても、それぞれの内挿位置とその位置を囲む直近の4個の参照画素の位置関係に応じて、図64(b),(c),(d)の点線で囲んだ画素を参照画素とする。   Also for the interpolated pixels P2, P3, and P4, the dotted lines in FIGS. 64B, 64C, and 64D correspond to the positions of the respective interpolated positions and the four reference pixels closest to the interpolated positions. A pixel surrounded by is used as a reference pixel.

この際、図のように参照画素A〜Iの、内挿画素Pに対する相対的な位置が同じになるように配置(例えば、(b)は(a)を時計回りに90度回転した配置になっている)しておけば、同じ画素パターンを回転しただけのものは、同じコンデキストになるので、内挿画素P1〜P4で共通の内容のテーブルとしたメモリを用いることができる。   At this time, the reference pixels A to I are arranged so that the relative positions of the reference pixels A to I with respect to the interpolation pixel P are the same (for example, (b) is an arrangement obtained by rotating (a) 90 degrees clockwise). If the same pixel pattern is rotated, the same index is used, so that a memory having a table of contents common to the interpolation pixels P1 to P4 can be used.

次に、4×4画素のマクロブロックを16×16画素に拡大する場合の例を説明する。
4×4画素のマクロブロックを16×16画素に拡大するには、まず、4×4のサイズのマクロブロックMBを8×8のサイズに拡大し、次に8×8のサイズのマクロブロックMBから16×16のサイズのマクロブロックMBに拡大すると云う手順を踏むことになる。
Next, an example in which a macroblock of 4 × 4 pixels is enlarged to 16 × 16 pixels will be described.
To expand a 4 × 4 pixel macroblock to 16 × 16 pixels, first, the 4 × 4 size macroblock MB is expanded to 8 × 8 size, and then the 8 × 8 size macroblock MB. The procedure for enlarging the macroblock MB to a 16 × 16 macroblock MB is taken.

この4×4のサイズのマクロブロックMBから8×8のサイズに拡大する時の外部参照画素ATとALを図65(a)に示し、8×8のサイズのマクロブロックMBから拡大する時の外部参照画素BTとBLを図65(b)に示す。   FIG. 65A shows external reference pixels AT and AL when the macro block MB of 4 × 4 size is expanded to a size of 8 × 8, and when the macro block MB of 8 × 8 size is expanded. External reference pixels BT and BL are shown in FIG.

外部参照画素ATは2行8列、外部参照画素ALは4行2列、外部参照画素BTは2行12列、外部参照画素BLは8行2列の配列である。   The external reference pixel AT is arranged in 2 rows and 8 columns, the external reference pixel AL is arranged in 4 rows and 2 columns, the external reference pixel BT is arranged in 2 rows and 12 columns, and the external reference pixel BL is arranged in 8 rows and 2 columns.

これらの外部参照画素の値は図42を用いて説明したように、既に再生したマクロブロックの所定の位置の画素の平均値として求める必要がある。しかし、2値画像符号化回路1700と2値画像復号化回路2800では、4×4画素のサイズで符号化する際には、外部参照画素ATとALを参照し、8×8画素のサイズで符号化する際には、外部参照画素BTとBLを参照するため、これを転用すれば拡大処理のためだけにわざわざ外部参照画素を求めると云った無駄は回避できる。   As described with reference to FIG. 42, the values of these external reference pixels need to be obtained as an average value of pixels at predetermined positions of the already reproduced macroblock. However, in the binary image encoding circuit 1700 and the binary image decoding circuit 2800, when encoding with the size of 4 × 4 pixels, the external reference pixels AT and AL are referred to and the size of 8 × 8 pixels is used. When encoding, reference is made to the external reference pixels BT and BL, and if this is diverted, it is possible to avoid the waste of obtaining the external reference pixel only for the enlargement process.

ここで、外部参照BTとBLについては、平均値を求めずに、外部参照画素ATとALから、コンピュータプログラミング用の言語であるC言語で記述すれば、

Figure 2008011564
Here, the external references BT and BL can be described in C language, which is a language for computer programming, from the external reference pixels AT and AL without obtaining an average value.
Figure 2008011564

という処理によって求めると、平均値を求める場合と多少結果は異なるが、平均値演算を省くことができる。 However, the average value calculation can be omitted although the result is somewhat different from the case of obtaining the average value.

上述の処理は、図65の例えば、画素p1を画素p2と画素p3にコピーし、画素p4を画素p5と画素p6にコピーするというように、ATやALの値を繰り返して画素を追加処理していくことで、BTやBLを生成するものである。なお、C言語プログラム中の“[ ][ ]”は配列を示し、[ ]中の数字は10進数を示す。   In the above-described processing, for example, the pixel p1 is copied to the pixel p2 and the pixel p3, and the pixel p4 is copied to the pixel p5 and the pixel p6. By doing so, BT and BL are generated. Note that “[] []” in the C language program indicates an array, and the numbers in [] indicate decimal numbers.

以上は、拡大処理の具体的手法を説明した。次に、縮小処理の具体的手法を説明する。   The specific method of enlargement processing has been described above. Next, a specific method of the reduction process will be described.

[縮小処理]
図38は、ブロック(マクロブロック)を縦横“1/2”のサイズに縮小する縮小処理の一例である。この例では、点線枠内領域一つ一つを単位縮小ブロック領域とすると、当該単位縮小ブロック領域内の2×2画素(各点線枠内における“O”で示した計4画素)毎の平均値(図38の“×”)を、その単位縮小ブロック領域での画素値としている。つまり、マクロブロックを縦横“1/4”のサイズに縮小する場合には、単位縮小ブロック領域毎に、その領域内の4×4画素毎の平均値を求めて、当該単位縮小ブロック領域での画素値とすればよいわけである。
[Reduction processing]
FIG. 38 is an example of a reduction process for reducing a block (macroblock) to a size of “½” in length and breadth. In this example, assuming that each area within the dotted line frame is a unit reduced block area, the average for every 2 × 2 pixels in the unit reduced block area (a total of 4 pixels indicated by “O” in each dotted line frame). The value (“×” in FIG. 38) is the pixel value in the unit reduced block area. That is, when a macroblock is reduced to a size of “¼” in the vertical and horizontal directions, an average value for every 4 × 4 pixels in the unit reduced block area is obtained for each unit reduced block area. The pixel value may be used.

また図39のように、画素A,B,C,Dからなる、ある単位縮小ブロック領域を考えた場合、当該単位縮小ブロック領域の画素Xの値を求めて当該単位縮小ブロック領域の値とするにあたり、画素A〜Dの平均値を求めるのではなく、これよりも広い範囲の画素位置の画素E,F,G,H,I,J,K,L,M,N,O,Pを含めて、これらA〜Pの平均値を求めるようにしてもよい。つまり、隣接の単位縮小ブロック領域の画素のうち、画素A〜Dに隣接する画素を含めてこれらの平均値を採用する方式とするわけである。   Further, as shown in FIG. 39, when a certain unit reduced block area composed of pixels A, B, C, and D is considered, the value of the pixel X of the unit reduced block area is obtained and set as the value of the unit reduced block area. In this case, the average values of the pixels A to D are not calculated, but the pixels E, F, G, H, I, J, K, L, M, N, O, and P in a wider range of pixels are included. Thus, an average value of these A to P may be obtained. In other words, among the pixels in the adjacent unit reduced block area, the average value of these pixels including the pixels adjacent to the pixels A to D is adopted.

以上は、現存する画素の値の平均値を単位縮小ブロック領域の画素値とすることで、その単位縮小ブロック領域の画素数を減らすようにし、マクロブロックのサイズ縮小を図るようにした例であった。このような、計算を伴わずに、機械的な間引き処理でもマクロブロックを縮小処理することができる。
その例を次に説明する。はじめに、マクロブロック内で閉じた処理を説明する。
The above is an example in which the average value of the existing pixel values is used as the pixel value of the unit reduced block area, thereby reducing the number of pixels in the unit reduced block area and reducing the size of the macroblock. It was. Without such calculation, the macroblock can be reduced by mechanical thinning processing.
An example of this will be described next. First, the process closed in the macro block will be described.

図40は、画素間引きによる縮小処理の例である。16×16画素構成のマクロブロックMBは画素間引きによる縮小処理を施した結果、8×8画素構成のブロックに縮小された様子を示している。すなわち、図中で点線の白丸印で示された画素が間引かれた画素であり、実線の白丸印で示された画素が単位縮小ブロック領域の画素値(図40の“×”)となる。この場合、縮小率(CR)は間引かれる画素の割合を表すことになる。なお、画素間引きの方法は図40で説明した方法に限らず、例えば、五の目格子状に画素を間引いても良い。また、この場合、拡大処理とは、間引かれた画素を内挿することに相当する。   FIG. 40 shows an example of reduction processing by pixel thinning. A macro block MB having a 16 × 16 pixel configuration is shown as being reduced to a block having an 8 × 8 pixel configuration as a result of reduction processing by pixel thinning. That is, the pixels indicated by the dotted white circles in the figure are thinned out pixels, and the pixels indicated by the solid white circles are the pixel values of the unit reduced block area (“×” in FIG. 40). . In this case, the reduction ratio (CR) represents the ratio of pixels to be thinned out. Note that the pixel thinning method is not limited to the method described with reference to FIG. 40. For example, the pixels may be thinned in a five-cell lattice shape. In this case, the enlargement process corresponds to interpolating the thinned pixels.

以上、種々の縮小処理の具体的手法を説明した。次に拡大処理について説明する。   The specific methods for various reduction processes have been described above. Next, the enlargement process will be described.

図41は、拡大処理を表す図である。図において、実線方形枠はマクロブロックを示しており、点線枠表示された部分の升目一つ一つが単位縮小ブロック領域を示している。単位縮小ブロック領域内の白丸印は現存画素を表わしており、内挿により画素数を増やしてマクロブロックの拡大を図るようにする。内挿される画素は“×”で表されており、内挿後は“O”の画素は不要画素となる。   FIG. 41 is a diagram illustrating the enlargement process. In the figure, a solid square frame indicates a macro block, and each square of the portion displayed by a dotted frame indicates a unit reduced block area. White circles in the unit reduced block area represent existing pixels, and the number of pixels is increased by interpolation to enlarge the macroblock. The interpolated pixel is represented by “x”, and after the interpolation, the “O” pixel becomes an unnecessary pixel.

マクロブロック境界部の画素を内挿する際に、マクロブロック外の画素値が必要になる。この場合、図の矢印で示されているように、マクロブロック内の最も近くの画素値を割り当てればよい。
すなわち、ある単位縮小ブロック領域の画素内挿をする場合、自己及び自己と隣接する各単位縮小ブロック領域である周囲8ブロックの画素値の計9画素分の画素値が、処理に必要である。しかし、マクロブロック内における当該ある単位縮小ブロック領域が、マクロブロック境界部に位置していると、前記の周囲8ブロックのいくつかは自己の所属外のマクロブロック所属のものとなることから、当該自己所属マクロブロック外の画素値を別途、もらってくる必要があるということになる。この場合は、図の矢印で示されているように、自己の所属マクロブロック内の最も近くの画素値をそれぞれ割り当てて便宜的にその処理に必要な近隣の単位縮小ブロック領域での画素値とし、利用すればよい。
When interpolating the pixels at the macroblock boundary, pixel values outside the macroblock are required. In this case, as indicated by the arrows in the figure, the nearest pixel value in the macroblock may be assigned.
That is, when performing pixel interpolation of a certain unit reduced block area, a total of 9 pixel values of the pixel values of the surrounding 8 blocks which are each of the unit reduced block areas adjacent to itself are necessary for processing. However, if the certain unit reduced block area in the macroblock is located at the macroblock boundary part, some of the surrounding 8 blocks belong to the macroblocks other than their own. This means that it is necessary to separately obtain pixel values outside the self-affiliated macroblock. In this case, as indicated by the arrows in the figure, the nearest pixel value in its own macroblock is assigned and used as the pixel value in the neighboring unit reduced block area necessary for the processing for convenience. , You can use.

なお、マクロブロック毎の縮小・拡大処理は、そのマクロブロック内で閉じている必要はなく、図42に示されるように、該ブロック近傍の再生値(左・上・左上・右上に隣接するブロック内の画素値)を用いるようにしても良い。
このことを具体的に説明する。
図42において、実線方形枠はあるブロック(マクロブロック)を示し、“×”印は倍率1倍のときの画像(標準倍率画像)の各画素を示している。マクロブロックは通常、16×16画素構成であり、フレームを1/2に圧縮した場合にブロック内の画素は8×8画素構成になり、先の16×16画素構成はそれぞれ2×2画素分の画像が1画素で表現されることになるので、この場合の2×2画素分の画像を代表点の情報を1画素表現形式にして表したのが図42における“O”印である。点線で示した枠内が、単位縮小ブロック領域であって、標準倍率画像での4画素構成(2×2)の領域を示しており、1/2縮小の場合はこの点線枠内領域毎に1画素で表現される。
Note that the reduction / enlargement processing for each macroblock does not need to be closed within the macroblock, and as shown in FIG. 42, the reproduction values near the block (blocks adjacent to the left, upper, upper left, and upper right) May be used.
This will be specifically described.
In FIG. 42, a solid-line rectangular frame indicates a certain block (macro block), and an “x” mark indicates each pixel of an image (standard magnification image) when the magnification is 1 ×. A macroblock usually has a 16 × 16 pixel configuration, and when the frame is compressed to 1/2, the pixels in the block have an 8 × 8 pixel configuration, and the previous 16 × 16 pixel configuration has 2 × 2 pixels each. 42 is represented by one pixel. In this case, the image of 2 × 2 pixels is represented by “O” in FIG. 42 in which the representative point information is represented in the one-pixel representation format. The inside of the frame indicated by the dotted line is a unit reduced block area, which shows a 4-pixel configuration (2 × 2) area in the standard magnification image. It is expressed by one pixel.

1/2縮小画像を元の画像サイズに復元する場合(標準倍率画像に復元する場合)、1/2縮小画像の1画素の領域は4画素構成に戻すが、それをマクロブロック内で閉じずに内挿により行うには次のようにする。
例えば、図42において、あるマクロブロックの、ある単位縮小ブロック領域(点線枠内領域)の画素1や画素2を内挿により再生する場合を考えてみる。この場合、その処理時点で現存するのは“O”印の画素情報である。従って、内挿しようとする画素1や画素2の周囲にある現存画素は画素3,4,5,6であるから、これら画素3,4,5,6を用いて双一次内挿を行う。ただし、“画素3”や“画素4”は隣接ブロック(隣接するマクロブロック)に所属する画素で、しかも、拡大前の画素(1/2縮小画像の画素)であり、当該隣接ブロックは時間的に前の時点で処理される位置にあるブロックであるので、このマクロブロックの拡大処理後には、不要となるデータであるから、メモリリソースの節約の観点から、既に廃棄してしまっていることがある。
When restoring a 1/2 reduced image to the original image size (when restoring to a standard magnification image), the 1 pixel area of the 1/2 reduced image is restored to the 4-pixel configuration, but it is not closed within the macroblock. To do this by interpolation:
For example, in FIG. 42, consider a case where a pixel 1 and a pixel 2 in a unit reduced block region (dotted frame region) of a macroblock are reproduced by interpolation. In this case, the pixel information of “O” is present at the time of processing. Accordingly, since the existing pixels around the pixel 1 and the pixel 2 to be interpolated are the pixels 3, 4, 5, and 6, bilinear interpolation is performed using these pixels 3, 4, 5, and 6. However, “pixel 3” and “pixel 4” are pixels belonging to an adjacent block (adjacent macroblock), and are pixels before enlargement (pixels of a 1/2 reduced image), and the adjacent blocks are temporally related. Since the block is in the position to be processed at the previous time point, it is unnecessary data after the macroblock enlargement process, so it may be discarded from the viewpoint of saving memory resources. is there.

そのようなシステムの場合には、例えば、“画素3”で云えばそのマクロブロックでの内挿済みで現存する隣接画素である画素7,8,9,10の平均値を求めて、前記廃棄してしまった“画素3”の値とするのも一つの方法であるが、その平均値を求める演算を少なくしたい場合には、画素7,8,9,10の計4画素のうち、内挿しようとする画素1,2に近い、画素9,10の平均値を、前記廃棄してしまった“画素3”の値として用いるようにしてもよい。   In the case of such a system, for example, in the case of “pixel 3”, an average value of pixels 7, 8, 9, and 10 that are existing pixels that have been interpolated in the macroblock is obtained, and the discarding is performed. Although it is one method to set the value of the “pixel 3” that has been reduced, if it is desired to reduce the calculation for obtaining the average value, out of the total of four pixels of the pixels 7, 8, 9, and 10, The average value of the pixels 9 and 10 close to the pixels 1 and 2 to be inserted may be used as the value of the discarded “pixel 3”.

また、画素10をそのまま流用して“画素3”の値とするようにすると、さらに演算を省ける。“画素4”についても、同様に、その近くの画素値で代用する。また、同様なケースで、“画素11”の内挿には、例えば、“画素12”の代わりに画素14と画素15の平均値、“画素13”の代わりに画素16、画素18の代わりに画素17を用いる。   Further, if the pixel 10 is used as it is to obtain the value of “pixel 3”, further calculation can be omitted. Similarly, “pixel 4” is substituted with a pixel value in the vicinity thereof. In the same case, the interpolation of “pixel 11” includes, for example, an average value of pixels 14 and 15 instead of “pixel 12”, and instead of pixel 16 and pixel 18 instead of “pixel 13”. Pixel 17 is used.

フレーム画像Pfは通常、オブジェクト部分を主体とした最小の矩形範囲、例えば、図59(a)に示される符号化領域CA内をブロック(マクロブロック)に分割して符号化するため、符号化領域の境界部に位置するブロックでは、該ブロックの左・上・左上・右上に隣接するブロックが、符号化領域CAの外部に位置することとなってしまう場合がある。
この場合、図42のように、該ブロック近傍の再生画素値(再生した画素の値)を利用する場合でも、符号化領域CAの外部に位置するマクロブロックである場合には再生両素値を参照せずに、図41のように自己所属マクロブロック内の最も近くの画素値を便宜的に割り当てて用いればよい。
Since the frame image Pf is usually encoded by dividing the minimum rectangular range mainly including the object portion, for example, the coding area CA shown in FIG. 59A into blocks (macroblocks), the coding area In the block located at the boundary portion, the blocks adjacent to the left, upper, upper left, and upper right of the block may be located outside the coding area CA.
In this case, as shown in FIG. 42, even when the reproduced pixel value (reproduced pixel value) in the vicinity of the block is used, if the macroblock is located outside the coding area CA, the reproduced binary value is set. Without reference, the nearest pixel value in the self-affiliated macroblock may be assigned and used for convenience as shown in FIG.

更に、誤りの影響を受ける伝送路でデータの授受を行う場合には、誤りの影響を受け難くするために、前記の符号化領域CAよりも小さい単位(これを“同期回復単位”呼ぶ)で符号化処理を閉じる場合がある。   Further, when data is exchanged on a transmission path that is affected by an error, in order to make it less susceptible to an error, the unit is smaller than the coding area CA (this is called a “synchronization recovery unit”). The encoding process may be closed.

これにより、誤りの影響をこの“同期回復単位”で断ち切ることが可能となり、誤りの影響を受け難くなる。ここで、“同期回復単位”とは、図59(b)にUnなる符号を付して示した点線で囲まれる各領域を指す。“同期回復単位”は符号化領域CAを小さく区切った領域であるが、複数のマクロブロックで構成されることは変わりない。   Thereby, it becomes possible to cut off the influence of the error by this “synchronization recovery unit”, and it becomes difficult to be affected by the error. Here, the “synchronization recovery unit” refers to each area surrounded by a dotted line indicated by the symbol Un in FIG. 59 (b). The “synchronization recovery unit” is an area obtained by dividing the coding area CA into small parts, but it is not different from being composed of a plurality of macroblocks.

この方式の場合、“同期回復単位”内で符号化処理を閉じるため、ある“同期回復単位”で使用するデータに伝送誤りがあるものが含まれていたとしても、その誤りのあるデータを参照して処理するのは当該ある“同期回復単位”内だけであり、隣接の“同期回復単位”は当該誤りのあるデータを参照して処理することはないから、伝送誤りが波及しにくい処理方式となる訳である。   In this method, since the encoding process is closed within the “synchronization recovery unit”, even if the data used in a certain “synchronization recovery unit” includes transmission errors, refer to the erroneous data. Processing is performed only within a certain “synchronization recovery unit”, and adjacent “synchronization recovery unit” is not processed with reference to the erroneous data, so that a transmission error is not easily propagated. That is why.

この場合でも、図42のように、該ブロック近傍の再生画素値を利用する際に、該ブロックが含まれる“同期回復単位”以外の同期回復単位に属するマクロブロックの再生画素値を参照せずに、図41の様にマクロブロック内の最も近くの画素値を割り当てる。   Even in this case, as shown in FIG. 42, when the reproduction pixel values near the block are used, the reproduction pixel values of the macroblocks belonging to the synchronization recovery unit other than the “synchronization recovery unit” including the block are not referred to. As shown in FIG. 41, the nearest pixel value in the macroblock is assigned.

上述したような、“マクロブロックや同期回復単位の外側を参照するか、しないか”は、符号に切り換えビットを用意し、これを用いて切り換えるようにすると伝送エラーの頻度や、許容される演算量、メモリ量などの様々な状況に対応することができる。   As described above, “whether or not to refer to the outside of the macroblock or the synchronization recovery unit” indicates that a switching bit is prepared in the code, and if switching is performed using this bit, the frequency of transmission errors and allowable operations It is possible to deal with various situations such as the amount and the amount of memory.

ところで、先に述べたように双一次内挿では、周囲の4画素のみを用いて処理を行っている。そのため、再生された画素による画像には、特に斜め方向の不連続性が発生し、視覚的劣化が起き易い傾向が避けられない。これを回避するには例えば、図41の内挿対象画素を内挿する例を取り上げてみると、その内挿の際に、双一次内挿の参照範囲よりも広い拡大参照範囲に含まれる画素を用いて内挿する。   By the way, as described above, in bilinear interpolation, processing is performed using only the surrounding four pixels. For this reason, discontinuity in the oblique direction occurs particularly in the image of the reproduced pixels, and the tendency for visual deterioration to occur is unavoidable. To avoid this, for example, taking the example of interpolation of the interpolation target pixel in FIG. 41, pixels included in an enlarged reference range wider than the reference range of bilinear interpolation at the time of the interpolation. Interpolate using.

すなわち、双一次内挿の参照範囲よりも広い拡大参照範囲に含まれる画素を用いて内挿することで、より広い範囲の画素の傾向が反映されることになり、不連続性の問題が回避される。また、内挿に用いる画素の数が“4画素”のように偶数個であるよりも、“9画素”のように奇数個の方が、多数決効果が得られ、不連続性の回避効果がより一層顕著に得られる場合がある。   In other words, by interpolating using pixels included in the expanded reference range that is wider than the bilinear interpolation reference range, the tendency of pixels in a wider range is reflected, and the problem of discontinuity is avoided. Is done. In addition, the odd number of pixels such as “9 pixels” can obtain the majority effect and the effect of avoiding discontinuity than the even number of pixels used for the interpolation such as “4 pixels”. It may be obtained even more significantly.

図58(b)に、12個の画素を用いて内挿を行う例を示す。先に図58(a)を用いて説明した実施例の表記を用いると、あるマクロブロックの1/2縮小画像におけるマクロブロック内ある位置での再生画素をp1,p2,p3,p4、そして、それらの値(画素値)をIp1,Ip2,Ip3,Ip4とした場合に、これらIp1,Ip2,Ip3,Ip4は、
Ip1:if(4*Ia +2*(Ib +Ic +Id )+Ie +If +Ig +Ih +Ii +Ij +Ik +Il )>8 then “1” else “0”
Ip2:if(4*Ib +2*(Ia +Ic +Id )+Ie +If +Ig +Ih +Ii +Ij +Ik +Il )>8 then “1” else “0”
Ip3:if(4*Ic +2*(Ib +Ia +Id )+Ie +If +Ig +Ih +Ii +Ij +Ik +Il )>8 then “1” else “0”
Ip4:if(4*Id +2*(Ib +Ic +Ia )+Ie +If +Ig +Ih +Ii +Ij +Ik +Il )>8 then “1” else “0”
で表せる。ただし、aは画素A、bは画素B、cは画素C、dは画素D、eは画素E、fは画素F、gは画素G、hは画素H、iは画素I、jは画素J、kは画素K、lは画素Lを示す。
FIG. 58B shows an example in which interpolation is performed using 12 pixels. Using the notation of the embodiment described above with reference to FIG. 58 (a), reproduced pixels at certain positions in a macroblock in a 1/2 reduced image of a macroblock are represented by p1, p2, p3, p4, and When those values (pixel values) are Ip1, Ip2, Ip3, Ip4, these Ip1, Ip2, Ip3, Ip4 are:
Ip1: if (4 * Ia + 2 * (Ib + Ic + Id) + Ie + If + Ig + Ih + Ii + Ij + Ik + Il)> 8 then “1” else “0”
Ip2: if (4 * Ib + 2 * (Ia + Ic + Id) + Ie + If + Ig + Ih + Ii + Ij + Ik + Il)> 8 then “1” else “0”
Ip3: if (4 * Ic + 2 * (Ib + Ia + Id) + Ie + If + Ig + Ih + Ii + Ij + Ik + Il)> 8 then “1” else “0”
Ip4: if (4 * Id + 2 * (Ib + Ic + Ia) + Ie + If + Ig + Ih + Ii + Ij + Ik + Il)> 8 then “1” else “0”
It can be expressed as However, a is pixel A, b is pixel B, c is pixel C, d is pixel D, e is pixel E, f is pixel F, g is pixel G, h is pixel H, i is pixel I, and j is pixel J and k are pixels K, and l is a pixel L.

また、“1/4”サイズの縮小拡大処理は、“l/2”サイズの縮小拡大処理を2回施すことで実現しても良い。   Further, the “1/4” size reduction / enlargement processing may be realized by performing the “l / 2” size reduction / enlargement processing twice.

次に、フレーム単位の拡大・縮小処理との組み合わせの例を、第5の具体例として説明する。   Next, an example of a combination with enlargement / reduction processing in units of frames will be described as a fifth specific example.

(第5の具体例)
本発明者らが特願平8−237053号で示した先行技術には、フレーム単位(実際にはオブジェクトを含む方形領域)で縮小・拡大を施すことでレート制御する実施例と、ブロックのような小領域単位で縮小・拡大を施すことでレート制御する実施例とを提示している。また、上述の第1乃至第3の具体例には、さらに具体的な小領域単位で縮小・拡大を施すことにより、レート制御するようにした例を示した。
(Fifth example)
The prior art disclosed by the present inventors in Japanese Patent Application No. 8-237053 includes an embodiment in which rate control is performed by reducing / enlarging in units of frames (actually, a square area including an object), and a block And an embodiment in which rate control is performed by performing reduction and enlargement in units of small areas. Further, in the first to third specific examples described above, examples in which rate control is performed by performing reduction / enlargement in units of more specific small areas are shown.

ここに説明する本具体例においては、フレーム単位での縮小・拡大処理と、小領域単位での縮小・拡大処理を組み合わせて使用する例を示すものである。   The specific example described here shows an example in which the reduction / enlargement processing in units of frames and the reduction / enlargement processing in units of small areas are used in combination.

<アルファマップ符号化装置>
図25は、本具体例のアルファマップ符号化装置を説明する図である。この装置は縮小回路5300,5210,5260、2値画像符号化回路5220、拡大回路5230,5400、動き補償予測回路5250、多重化回路5240,5500とより構成される。
<Alpha map encoding device>
FIG. 25 is a diagram illustrating an alpha map encoding apparatus according to this specific example. This apparatus includes reduction circuits 5300, 5210, 5260, binary image encoding circuit 5220, enlargement circuits 5230, 5400, motion compensation prediction circuit 5250, and multiplexing circuits 5240, 5500.

このような構成において、アルファマップ信号入力線20を介して供給される2値化されたアルファマップ画像は、縮小回路5300において縮小・拡大率CRに基づいてフレーム単位に縮小される。フレーム単位に縮小された信号は、信号線5020を介してアルファマップ符号化回路5200に供給され、小領域に分割された後、符号化される。   In such a configuration, the binarized alpha map image supplied via the alpha map signal input line 20 is reduced in frame units in the reduction circuit 5300 based on the reduction / enlargement ratio CR. The signal reduced in frame units is supplied to the alpha map encoding circuit 5200 via the signal line 5020, and is divided into small areas and then encoded.

ここで、アルファマップ符号化回路5200は、図12のアルファマップ符号化回路200と等価であり、アルファマップ符号化回路5200の構成要素5210〜5260は、それぞれ図12のアルファマップ符号化回路200の構成要素210〜260と同じ機能を有するので、アルファマップ符号化回路5200の説明はここでは省略する。また、図12のアルファマップ符号化回路200の構成は、図1のアルファマップ符号化回路200の構成を簡略化して表現したものであるため、アルファマップ符号化回路5200の構成は、図1のアルファマップ符号化回路200と等価な構成でも良い。   Here, the alpha map encoding circuit 5200 is equivalent to the alpha map encoding circuit 200 of FIG. 12, and the components 5210 to 5260 of the alpha map encoding circuit 5200 are the same as those of the alpha map encoding circuit 200 of FIG. Since it has the same function as the components 210 to 260, the description of the alpha map encoding circuit 5200 is omitted here. Further, the configuration of the alpha map encoding circuit 200 in FIG. 12 is a simplified representation of the configuration of the alpha map encoding circuit 200 in FIG. A configuration equivalent to the alpha map encoding circuit 200 may be used.

アルファマップ符号化回路5200で符号化された符号化情報には、小領域毎の縮小・拡大率CRbが多重化されており、信号線5030を介して多重化回路5500に供給され、フレーム単位の縮小・拡大率CRの符号化情報と多重化され、信号線30を介して出力される。   In the encoded information encoded by the alpha map encoding circuit 5200, the reduction / enlargement ratio CRb for each small region is multiplexed and supplied to the multiplexing circuit 5500 via the signal line 5030, and is supplied in frame units. The data is multiplexed with the encoded information of the reduction / enlargement ratio CR and output via the signal line 30.

また、アルファマップ符号化回路5200の再生画像は信号線5040を介して拡大回路5400に供給され、フレーム単位の縮小・拡大率CRに基づいて拡大された後、信号線40を介して出力される。   Further, the reproduced image of the alpha map encoding circuit 5200 is supplied to the enlargement circuit 5400 via the signal line 5040, is enlarged based on the reduction / enlargement ratio CR in frame units, and then output via the signal line 40. .

<アルファマップ復号化装置>
図26は、本具体例の復号化装置を説明する図である。このアルファマップ復号化装置は、分離化回路6500,6430、2値画像復号化回路6410、縮小回路6450、動き補償予測回路6440、拡大回路6420,6600とから構成されている。
<Alpha map decoding device>
FIG. 26 is a diagram for explaining a decoding device according to this example. This alpha map decoding apparatus includes separation circuits 6500 and 6430, a binary image decoding circuit 6410, a reduction circuit 6450, a motion compensation prediction circuit 6440, and an expansion circuit 6420 and 6600.

このような構成において、信号線80を介して供給される符号化情報は、分離化回路6500でフレーム単位の縮小・拡大率CRと、小領域単位の符号化情報に分離される。そして、小領域単位の符号化情報は、信号線6080を介してアルファマップ復号化回路6400に供給され、小領域単位の再生信号が信号線6090を介して拡大回路6600に供給される。   In such a configuration, the encoded information supplied via the signal line 80 is separated into a frame unit reduction / enlargement ratio CR and small region unit encoded information by the separation circuit 6500. Then, the small area unit encoding information is supplied to the alpha map decoding circuit 6400 via the signal line 6080, and the small area unit reproduction signal is supplied to the enlargement circuit 6600 via the signal line 6090.

アルファマップ復号化回路6400は、図13のアルファマップ復号化回路400と等価なため、ここでは説明を省略する。また、図13のアルファマップ復号化回路400の構成は、図2のアルファマップ復号化回路400の構成を簡略化して表現したものであるため、アルファマップ復号化回路6400の構成は、図2のアルファマップ復号化回路400と等価な構成でも良い。   Since the alpha map decoding circuit 6400 is equivalent to the alpha map decoding circuit 400 of FIG. 13, description thereof is omitted here. Further, since the configuration of the alpha map decoding circuit 400 in FIG. 13 is a simplified representation of the configuration of the alpha map decoding circuit 400 in FIG. 2, the configuration of the alpha map decoding circuit 6400 is as shown in FIG. A configuration equivalent to the alpha map decoding circuit 400 may be used.

拡大回路6600では、フレーム単位の縮小率CRの情報に基づいて、信号線6090を介して供給される再生信号を拡大処理して、信号線90より出力させる。   The enlargement circuit 6600 enlarges the reproduction signal supplied via the signal line 6090 based on the information on the reduction rate CR in units of frames, and outputs it from the signal line 90.

このように、ここではアルファマップ信号をフレーム単位で縮小・拡大処理し、かつ、小領域単位で縮小・拡大処理するようにした。このフレーム単位での縮小・拡大と、小領域単位での縮小・拡大とを組み合わせることで、縮小・拡大率情報のようなサイド情報が削減されるため、特に、低い符号化レートで符号化する場合に効果的となる。   As described above, the alpha map signal is reduced / enlarged in units of frames and reduced / enlarged in units of small areas. By combining the reduction / enlargement in units of frames and the reduction / enlargement in units of small areas, side information such as reduction / enlargement ratio information is reduced, so encoding is performed at a particularly low encoding rate. Effective in cases.

次にフレームメモリについて、触れておく。
図25、図26には明示していないが、符号化装置と復号化装置にはいずれも再生画像を蓄積するためのフレームメモリが必要である。図52は、フレーム毎の解像度の例を表した図である。本発明では、動き補償予測を用いているため、例えば、時刻nのフレームを符号化する際には、時刻n−1のフレームの解像度を時刻nのフレームでの解像度(この場合、縮小・拡大率)に一致させなければならない。ここで、フレームメモリに蓄積する再生画像が、アルファマップ符号化回路5200によって図52に示されるようにフレーム単位の解像度(この例の場合、時刻nのフレームならばCR=1/2(図52の(a))、時刻nのフレームならばCR=1(図52の(c)))で蓄積される場合と、元の解像度(時刻に関わらず、常に縮小・拡大率CR=1)で蓄積される場合の2通りが考えられる。
Next, let's touch on the frame memory.
Although not explicitly shown in FIG. 25 and FIG. 26, both the encoding device and the decoding device require a frame memory for storing a reproduced image. FIG. 52 is a diagram illustrating an example of the resolution for each frame. In the present invention, since motion compensation prediction is used, for example, when encoding a frame at time n, the resolution of the frame at time n-1 is changed to the resolution at the frame at time n (in this case, reduced / enlarged). Rate). Here, as shown in FIG. 52, the reproduced image to be stored in the frame memory has a frame unit resolution (in this example, CR = 1/2 if it is a frame at time n (FIG. 52). (A)), the frame at time n is stored with CR = 1 (FIG. 52 (c))) and the original resolution (always the reduction / enlargement ratio CR = 1 regardless of the time). Two cases of accumulation are conceivable.

前者においては、フレームメモリは信号線5040および信号線6090を介して供給されるフレーム単位の解像度の再生画像を蓄積することになり、後者におけるフレームメモリは、信号線40および信号線90を介して供給される元の解像度の再生画像を蓄積することになる。   In the former, the frame memory stores a reproduction image having a resolution in units of frames supplied via the signal line 5040 and the signal line 6090, and the frame memory in the latter is stored via the signal line 40 and the signal line 90. The reproduced image having the original resolution to be supplied is accumulated.

従って、図25の符号化装置および図26の復号化装置においてフレームメモリを明示すると、前者のフレームメモリ(これをFM1(符号化装置用)、FM3(復号化装置用)と表すこととする)の場合は、図53および図54のようになり、後者のフレームメモリ(これをFM2(符号化装置用)、FM4(復号化装置用)と表すこととする)の場合は、図55および図56のようになる。   Therefore, when the frame memory is clearly shown in the encoding device of FIG. 25 and the decoding device of FIG. 26, the former frame memory (this is expressed as FM1 (for the encoding device) and FM3 (for the decoding device)). 53 and 54, the latter frame memory (referred to as FM2 (for the encoding device) and FM4 (for the decoding device)) is shown in FIG. 55 and FIG. 56.

つまり、図53の符号化装置は、縮小・拡大率CRの情報と拡大回路5230の出力情報をFM1なるフレームメモリに保持し、この保持情報をMC(動き補償予測回路)5250に与えるように構成したものであり、図54の復号化装置は、CRの情報と拡大回路6420からの出力をFM3なるフレームメモリに保存し、この保存出力を動き補償予測回路6440に与えるように構成したものである。   That is, the encoding apparatus of FIG. 53 is configured to hold the information of the reduction / enlargement ratio CR and the output information of the enlargement circuit 5230 in the frame memory of FM1, and give this hold information to the MC (motion compensation prediction circuit) 5250 54, the decoding apparatus of FIG. 54 is configured to store the CR information and the output from the expansion circuit 6420 in a frame memory such as FM3, and to provide the stored output to the motion compensation prediction circuit 6440. .

また、図55の符号化装置は、縮小・拡大率CRの情報と拡大回路5400の出力情報をFM2なるフレームメモリに保持し、この保持情報をMC(動き補償予測回路)5250に与えるように構成したものであり、図56の復号化装置は、CRの情報と拡大回路6600からの出力を保存し、この保存出力を動き補償予測回路6440に与えるように構成したものである。   55 is configured to hold the information of the reduction / enlargement ratio CR and the output information of the enlargement circuit 5400 in a frame memory such as FM2, and supply this hold information to the MC (motion compensation prediction circuit) 5250. The decoding apparatus of FIG. 56 is configured to store the CR information and the output from the expansion circuit 6600 and to provide the stored output to the motion compensation prediction circuit 6440.

フレームメモリFM1,FM3の具体的な構成例は、図57(a)に示した如きものとなり、フレームメモリFM2,FM4の具体的な構成例は、図57(b)に示した如きのものとなる。   A specific configuration example of the frame memories FM1 and FM3 is as shown in FIG. 57 (a), and a specific configuration example of the frame memories FM2 and FM4 is as shown in FIG. 57 (b). Become.

フレームメモリFM1,FM3は、図57(a)に示すように、現フレームの画像を保存するフレームメモリm11と、このフレームメモリm11の保持画像を別途与えられる拡大・縮小率CRの情報対応に縮小・拡大処理する縮小・拡大回路m12、この縮小・拡大回路m12で縮小・拡大処理された出力を保存するフレームメモリm13とからなり、また、フレームメモリFM2,FM4は、図57(b)に示すように、現フレームの画像を保存するフレームメモリm21と、このフレームメモリm21の保持画像を、別途与えられる拡大・縮小率CRの情報対応に縮小処理する縮小回路m22、この縮小回路m22で縮小処理された出力を保存するフレームメモリm12とからなる。   As shown in FIG. 57 (a), the frame memories FM1 and FM3 reduce the frame memory m11 that stores the image of the current frame and the image held in the frame memory m11 to the information corresponding to the enlargement / reduction ratio CR separately given. A reduction / enlargement circuit m12 for enlargement processing and a frame memory m13 for saving the output reduced / enlarged by the reduction / enlargement circuit m12. The frame memories FM2 and FM4 are shown in FIG. 57 (b). As described above, the frame memory m21 that stores the image of the current frame, the reduction circuit m22 that reduces the image held in the frame memory m21 in correspondence with the information of the enlargement / reduction ratio CR given separately, and the reduction processing by the reduction circuit m22 And a frame memory m12 for storing the output output.

このような構成のフレームメモリにおける動作を説明する。
まずフレームメモリFM1,FM3の場合、これらには信号線5040および信号線6090を介してフレーム単位でそのフレームの対応する解像度の再生画像が供給され、現フレーム保存用のフレームメモリm11に蓄積される。フレームメモリm11は、現フレームの符号化(例えば、時刻n)が終了した時点で現フレームの再生画像が全て蓄積されている。
The operation of the frame memory having such a configuration will be described.
First, in the case of the frame memories FM1 and FM3, a reproduction image having a resolution corresponding to the frame is supplied to each of the frames via the signal line 5040 and the signal line 6090 and stored in the frame memory m11 for storing the current frame. . In the frame memory m11, all the reproduced images of the current frame are stored when the encoding of the current frame (for example, time n) is completed.

次に、縮小・拡大回路m12では、時刻n+1におけるフレームの符号化が開始される時点で、時刻nにおけるフレームの再生画像をフレームメモリm11から読み込み、時刻n+1におけるフレームのフレーム単位での縮小・拡大率CRと一致するように、縮小・拡大処理(解像度変換)を行う。   Next, the reduction / enlargement circuit m12 reads the reproduced image of the frame at the time n from the frame memory m11 when the encoding of the frame at the time n + 1 is started, and reduces / enlarges the frame at the time n + 1 in units of frames. Reduction / enlargement processing (resolution conversion) is performed so as to match the rate CR.

図52の例において、(a)に示すように時刻nにおけるフレームの縮小・拡大率CRは“1/2”であり、また、(b)に示すようにその次フレームである時刻n+1におけるフレームの縮小・拡大率CRは“1”であるので、この場合、縮小・拡大回路m12では縮小・拡大率CRを“1/2”から“1”に変換する処理を行うことになる。   In the example of FIG. 52, the frame reduction / enlargement ratio CR at time n is “1/2” as shown in (a), and the frame at time n + 1, which is the next frame, as shown in (b). Since the reduction / enlargement ratio CR is “1”, the reduction / enlargement circuit m12 performs processing for converting the reduction / enlargement ratio CR from “1/2” to “1”.

縮小・拡大回路m12で解像度変換された時刻nにおける再生画像は、前フレームのフレームメモリm13に蓄積され、時刻n+1におけるフレームの動き補償予測の参照画像となる。   The reconstructed image at time n subjected to resolution conversion by the reduction / enlargement circuit m12 is stored in the frame memory m13 of the previous frame, and becomes a reference image for motion compensation prediction of the frame at time n + 1.

フレームメモリFM2,FM4の場合、これらには信号線40および信号線90を介して元の解像度(CR=1)の再生画像が供給され、現フレームのフレームメモリm21に蓄積される。フレームメモリm21には、現フレームの符号化(例えば、時刻n)が終了した時点で現フレームの再生画像が全て蓄積されている。   In the case of the frame memories FM2 and FM4, a reproduced image having the original resolution (CR = 1) is supplied to the frame memories FM2 and FM4 via the signal line 40 and the signal line 90, and stored in the frame memory m21 of the current frame. The frame memory m21 stores all the reproduced images of the current frame at the time when the encoding of the current frame (for example, time n) is completed.

次に、縮小回路m22では、時刻n+1におけるフレームの符号化が開始される時点で、時刻nにおけるフレームの再生画像をフレームメモリm21から銃み込み、時刻n+1におけるフレームのフレーム単位での縮小・拡大率CRと一致するように、縮小処理(解像度変換)を行う。   Next, at the time when the encoding of the frame at time n + 1 is started, the reduction circuit m22 inserts the reproduced image of the frame at time n from the frame memory m21, and reduces or enlarges the frame at time n + 1 in frame units. Reduction processing (resolution conversion) is performed so as to match the rate CR.

フレームメモリm21に蓄積される再生画像は常に縮小・拡大率CR=1であるので、図52の例では、時刻n+1における縮小・拡大率CRは“1”であるから、この場合、縮小回路m22では解像度変換処理を行わない。なお、図52の例の場合、現フレームが時刻n+1の場合、時刻n+2におけるフレームの解像度は“1/2”であるから、縮小回路m22では縮小・拡大率CRを“l”から“1/2”にする解像度変換処理を行うことになる。   Since the reproduced image stored in the frame memory m21 always has the reduction / enlargement ratio CR = 1, in the example of FIG. 52, the reduction / enlargement ratio CR at time n + 1 is “1”. In this case, the reduction circuit m22 Then, resolution conversion processing is not performed. In the case of the example in FIG. 52, when the current frame is time n + 1, the resolution of the frame at time n + 2 is “1/2”. Therefore, in the reduction circuit m22, the reduction / enlargement ratio CR is changed from “l” to “1 /”. The resolution conversion process to 2 "is performed.

縮小回路m22で解像度変換された時刻nにおけるフレームの再生画像は、前フレームのフレームメモリm33に蓄積され、時刻n+1におけるフレームの動き捕償予測の参照画像となる。   The playback image of the frame at time n, whose resolution has been converted by the reduction circuit m22, is stored in the frame memory m33 of the previous frame, and becomes a reference image for motion compensation prediction of the frame at time n + 1.

以上、フレームメモリFM1,FM2,FM3,FM4の具体的な構成と作用を述べたが、フレームメモリFM1,FM3は、信号線5040および信号線6090を介して供給されるフレーム単位の解像度の再生画像が蓄積されることが特徴であり、また、フレームメモリFM2,FM4は、信号線40および信号線90を介して供給されるフレーム単位での解像度の再生画像が蓄積されることが特徴であるため、それぞれ、他に種々の構成が考えられる。   The specific configuration and operation of the frame memories FM1, FM2, FM3, and FM4 have been described above. However, the frame memories FM1 and FM3 are reconstructed images with resolution in units of frames supplied via the signal line 5040 and the signal line 6090. In addition, the frame memories FM2 and FM4 are characterized in that a reproduced image having a resolution in units of frames supplied via the signal line 40 and the signal line 90 is accumulated. In addition, various other configurations can be considered.

(第6の具体例)
次に、マクロブロックの属性情報を符号化する方式の例を第6の具体例として説明する。まず、先行技術である特願平8−237053号にて、提案した方式の説明をする。
(Sixth specific example)
Next, an example of a method of encoding macroblock attribute information will be described as a sixth specific example. First, the proposed method will be described in Japanese Patent Application No. 8-237053, which is a prior art.

図29は、時刻nと時刻n−1におけるあるマクロブロックの属性情報の一例を表している。但し、ここで云う属性情報とは、“allW”(そのマクロブロックの構成画素全てが白)、“allB”(そのマクロブロックの構成画素全てが黒)、“Multi”(そのマクロブロックの構成画素は白黒混在)といったマクロブロックの中味の状態を示した情報である。
そして、例えば、“allW”を符号“0”で、“allB”を符号“3”で、そして、“Multi”を符号“1”でラベル付けして示した例である。
FIG. 29 shows an example of attribute information of a certain macroblock at time n and time n-1. However, the attribute information here is “allW” (all the constituent pixels of the macroblock are white), “allB” (the constituent pixels of the macroblock are all black), “Multi” (the constituent pixels of the macroblock) Is information indicating the contents of the contents of the macroblock, such as black and white.
For example, “allW” is labeled “0”, “allB” is labeled “3”, and “Multi” is labeled “1”.

フレームにおけるオブジェクト部分を含む最小矩形領域に着目し、その左上を、領域の境界部に接するように、方形領域を設定すると、当該設定した方形領域に含まれる各マクロブロックの属性情報の分布(ラベルの分布)は、例えば、図29の如きとなる。   Focusing on the smallest rectangular area including the object part in the frame and setting a rectangular area so that the upper left of the rectangular area touches the boundary of the area, distribution of attribute information (label) of each macroblock included in the set rectangular area For example, as shown in FIG.

そして、図29における(a)に示した時刻nのフレームでのマクロブロックの構成画素属性情報の分布例と、(b)に示した時刻n−1のフレームでのマクロブロックの構成画素属性情報の分布例のように、時間的に近いフレームのアルファマップ間では、非常に似たラベル付けが行われる。
従って、このような場合には、フレーム間においてラベルの相関が高いため、既に符号化済みのフレームのラベルを利用して、現フレームのラベルを符号化することで、大幅に符号化効率が改善されることになる。
Then, a distribution example of the constituent pixel attribute information of the macroblock in the frame at time n shown in (a) in FIG. 29 and the constituent pixel attribute information of the macroblock in the frame at time n-1 shown in (b). As in the distribution example of FIG. 5, very similar labeling is performed between alpha maps of frames close in time.
Therefore, in such a case, since the correlation of labels between frames is high, encoding efficiency is greatly improved by encoding the label of the current frame using the label of the already encoded frame. Will be.

また、一般に、時刻nのフレームにおける符号化領域(オブジェクト部分を主体とした最小の矩形範囲、例えば、図59(a)に示される符号化領域CA)と、時刻n−1のフレームにおける符号化領域のサイズが異なる場合がある。この場合、一例として、図30に示す手順で、時刻n−1のフレームでの符号化領域サイズを時刻nのフレームでのサイズに合わせる。例えば、時刻nのフレームにおける符号化領域サイズが、時刻n−1のフレームにおける符号化領域サイズに比べて行が1行分長く、列が1列分短い場合は、図30(a)のように、行の短い時刻n−1のフレームにおける符号化領域について、その領域内右端の1列分のマクロブロック列をカットし、その後、下部の1行分のマクロブロック列をその下にコピーして行を増やす。
この状態が図46(b)である。
In general, the encoding area in the frame at time n (minimum rectangular range mainly including the object portion, for example, the encoding area CA shown in FIG. 59A) and the encoding in the frame at time n−1. The region size may be different. In this case, as an example, the encoding area size in the frame at time n−1 is matched with the size in the frame at time n by the procedure shown in FIG. For example, when the coding area size in the frame at time n is one row longer and the column is shorter by one column than the coding area size in the frame at time n−1, as shown in FIG. Next, for the encoding region in the frame at the time n−1 with a short row, the macro block column for one column at the right end in the region is cut, and then the macro block column for one row at the bottom is copied below it. Increase the line.
This state is shown in FIG.

また、時刻n−1のフレームにおける符号化領域サイズが、時刻nのフレームにおける符号化領域サイズより列については1列分短く、行については1行分長い場合は、符号化領域内の下端の1行分のマクロブロック列をカットし、その後、その符号化領域内の右端の1列分のマクロブロック列をその隣りにコピーして1列増やす。   In addition, when the coding area size in the frame at time n−1 is shorter by one column for the column and longer by one line than the coding area size in the frame at time n, The macroblock sequence for one row is cut, and then the macroblock sequence for the rightmost one column in the coding area is copied adjacently to increase it by one column.

サイズが合わないときは、このようにしてサイズを合わせる。なお、サイズの合わせ方は前記の方法に限ったものではない。そして、最終的に、図30(b)の様に、時刻nのフレームでのサイズに合わせられた、時刻n−1のフレームでのラベルを、ここでは便宜上、時刻n−1’のラベルと表記して以下の説明に用いることにする。   If the size does not match, adjust the size in this way. Note that the method of adjusting the size is not limited to the above method. Finally, as shown in FIG. 30 (b), the label in the frame at time n-1 adjusted to the size in the frame at time n is referred to as the label at time n-1 ′ for convenience. This will be used for the following explanation.

図31(a)は、時刻nでの上述のマクロブロックの属性情報と、時刻n−1’での上述のマクロブロックの属性情報の差分、つまり各マクロブロック位置での各ラベルの差分を、同一位置のもの同士でとった結果を示している。   FIG. 31A shows the difference between the above-described macroblock attribute information at time n and the above-described macroblock attribute information at time n−1 ′, that is, the difference between each label at each macroblock position. The result taken by the thing of the same position is shown.

ここで、“S”は“ラベルが一致している”ことを示し、“D”は“ラベルが不一致である”ことを示す。   Here, “S” indicates “labels match”, and “D” indicates “labels do not match”.

一方、図31(b)は、時刻nでの上述のマクロブロックの属性情報における隣接画素位置のラベルの差分をとった結果を示している。ここで、左端のラベルは、1ライン上の右端の画素位置でのラベルとの差を取り、左上端の画素位量でのラベルは、“0”との差を取ることにしている。以後、便宜的に図31(a)をフレーム間符号化、図31(b)をフレーム内符号化と呼ぶことにする。   On the other hand, FIG. 31 (b) shows the result of taking the difference between the labels of adjacent pixel positions in the above-described macroblock attribute information at time n. Here, the label at the left end takes a difference from the label at the pixel position at the right end on one line, and the label at the pixel position at the upper left end takes a difference from “0”. Hereinafter, for convenience, FIG. 31A is referred to as interframe coding, and FIG. 31B is referred to as intraframe coding.

図31より、フレーム間符号化の方がフレーム内符号化に比べて“S”の割合が多く、フレーム間符号化の方が予測が当たるため、符号量の削減を図ることができる。   As shown in FIG. 31, since the inter-frame coding has a higher ratio of “S” than the intra-frame coding and the inter-frame coding is more predictive, the amount of codes can be reduced.

なお、フレーム間での相関が極端に小さい場合、フレーム内符号化に比べて符号化効率が低下するおそれがある。この場合は、1ビットの符号でフレーム内符号化を行うか、フレーム間符号化を行うかを切り換えられるようにしておき、フレーム内符号化で符号化できるようにする。当然のことながら、最初に符号化するフレームは、参照するラベルが無いため、フレーム内符号化を行う。この際、フレーム間/フレーム内を切り換える符号は必要ない。   In addition, when the correlation between frames is extremely small, there is a possibility that the coding efficiency may be reduced as compared with intra-frame coding. In this case, it is possible to switch between intra-frame encoding with 1-bit code or inter-frame encoding so that encoding can be performed with intra-frame encoding. As a matter of course, since the frame to be encoded first has no reference label, intra-frame encoding is performed. At this time, a code for switching between frames / within frames is not necessary.

幾種類かの予測の方法を切り替える例を、さらに具体的に説明する。
上述の例では、フレーム間の相関が小さい場合に、フレーム内符号化を行う場合を示した。しかし、この他にも、例えば本発明を画像伝送に用いる場合などで、伝送誤りが問題となる時にも、フレーム内符号化は有効である。
An example of switching between several types of prediction methods will be described more specifically.
In the above-described example, the case where intra-frame encoding is performed when the correlation between frames is small is shown. However, in addition to this, for example, when the present invention is used for image transmission, and when transmission errors become a problem, intra-frame coding is effective.

例えば、伝送誤りが発生し、前のフレームが正しく再生されていない場合に、フレーム間符号化を用いると、現フレームも正しく再生されないが、フレーム内符号化を用いると、正しく再生することができる。   For example, when a transmission error occurs and the previous frame is not reproduced correctly, if the inter-frame coding is used, the current frame is not reproduced correctly, but if the intra-frame coding is used, it can be reproduced correctly. .

また、フレーム内符号化であっても、多くのマクロブロックを参照していると、伝送誤りには弱くなる。つまり、参照するマクロブロックを多くすると、符号量は少なくできるが、参照したマクロブロックの数が多くなれば、それだけ伝送誤りを含んだマクロブロックを参照する可能性が高くなり、その参照したマクロブロックに含まれる誤りが取り込まれて処理結果に反映されてしまうことになるから、伝送誤りには弱くなると云え、逆に参照するマクロブロックを少なくすると、符号量は多くなるが、上記理由から伝送誤りには強くなると云える。   Even with intra-frame coding, if many macroblocks are referenced, they are vulnerable to transmission errors. In other words, if the number of referenced macroblocks is increased, the amount of code can be reduced, but if the number of referenced macroblocks is increased, the possibility of referring to macroblocks containing transmission errors increases. If the number of macroblocks to be referred to is reduced, the amount of code increases. It can be said that it will become stronger.

そこで、伝送誤りに強く、符号量も少なくする工夫が必要なる。それには次のようすると良い。   Therefore, it is necessary to devise a technique that is resistant to transmission errors and reduces the amount of codes. You can do this as follows:

一例として、伝送誤りに強く、符号量も少なくするためには、幾つかの予測モードを用意しておき、それらを切り替えて用いる方法が有効である。
予測モードとしては、例えば、
(A)フレーム間符号化モード
(B)フレーム内符号化モード
(C)同期回復単位内符号化モード
(D)予測なしのモード
がある。
As an example, in order to be resistant to transmission errors and reduce the amount of codes, it is effective to prepare several prediction modes and switch between them.
As a prediction mode, for example,
(A) Inter-frame coding mode (B) Intra-frame coding mode (C) Synchronization recovery intra-unit coding mode (D) There is a mode without prediction.

ここで、“同期回復単位”とは、既に説明したように、オブジェクトの矩形領域をさらに分割したもの、すなわち、矩形の符号化領域CAをさらに所要のマクロブロック単位で分割したものを意味し、例えば、各同期回復単位の符号量が等しくなるように分割したり、あるいは、所定の数のマクロブロックをまとめて同期回復単位としたりする。   Here, as already described, the “synchronization recovery unit” means that the rectangular area of the object is further divided, that is, the rectangular coding area CA is further divided in a required macroblock unit, For example, it is divided so that the code amount of each synchronization recovery unit becomes equal, or a predetermined number of macroblocks are combined into a synchronization recovery unit.

“同期回復単位内符号化モード”では、参照ブロック(参照するマクロブロックのことで、自己の所属マクロブロックの隣接マクロブロック)が、たとえフレーム内であっても、“同期回復単位”の外側にある場合は、参照せずに、例えば予め定めるラベルを予測値とする。   In “Synchronous recovery unit coding mode”, the reference block (the macroblock to be referenced, that is, the adjacent macroblock of its own macroblock) is outside the “synchronous recovery unit” even in the frame. In some cases, for example, a predetermined label is used as a predicted value without reference.

これにより、フレーム内で伝送誤りが発生したとしても、それが、“同期回復単位”の外であれば、その“同期回復単位”は正しく再生することができる。   As a result, even if a transmission error occurs in the frame, if it is outside the “synchronization recovery unit”, the “synchronization recovery unit” can be correctly reproduced.

また、予測なしとは、他のマクロブロックは全く参照せずに、該マクロブロックのラベルを符号化するものであり、誤りにはこのモードが最も強い。   “No prediction” means that the label of the macroblock is encoded without referring to other macroblocks at all, and this mode is strongest against errors.

これら複数種のモードを用意して、誤りが発生する頻度によっていずれか最適な一つを選択切り替えして使用する。そして、その切り替えは、“同期回復単位”毎に行っても良いし、フレーム毎に行っても良いし、シーケンス毎に行っても良い。どのモードで符号化されたかという情報は符号化装置から復号化装置に送られるようにする。   These multiple modes are prepared, and one of the optimum modes is selected and used depending on the frequency of occurrence of errors. The switching may be performed for each “synchronization unit”, for each frame, or for each sequence. Information on which mode is used for encoding is sent from the encoding device to the decoding device.

また、別のモードとして、符号化しようとしている対象の領域の、フレーム内における占有位置如何によって、符号化テーブルを切り替える方法もある。   As another mode, there is a method of switching the encoding table depending on the occupied position in the frame of the target region to be encoded.

すなわち、画像は一般的な傾向として、例えば、図20のようにフレームの中心部分では、オブジェクトが存在する確率が高く、フレームの端ではオブジェクトが存在しない確率が高い。
このことに着目して、フレームの端に接するマクロブロックでは“allW”に短い符号を割り当てたテーブルを用い、それ以外のマクロブロックでは、“allB”に短い符号を割り当てたテーブルを用いるようにすると、予測を用いなくても、符号量を減らすことができる。これが予測なしモードである。
That is, as a general tendency of an image, for example, as shown in FIG. 20, there is a high probability that an object exists at the center of the frame, and a high probability that no object exists at the end of the frame.
Focusing on this, if a macroblock that touches the end of the frame uses a table that assigns a short code to “allW”, and other macroblocks use a table that assigns a short code to “allB”. The amount of code can be reduced without using prediction. This is the no prediction mode.

また、より単純に、複数の符号化テーブルを用意し、その符号化テーブルを切り替えて用いる方法もある。これの切り替え情報は、例えば、“同期回復単位”毎、あるいは、フレーム毎、シーケンス毎に符号化する。   There is also a method of preparing a plurality of encoding tables more simply and switching the encoding tables for use. The switching information is encoded, for example, for each “synchronization recovery unit”, for each frame, or for each sequence.

図32は、上述した処理を実現するための本具体例のシステム構成を示すブロック図であり、このブロック図を参照して処理の流れを説明する。   FIG. 32 is a block diagram showing a system configuration of this example for realizing the above-described processing, and the flow of processing will be described with reference to this block diagram.

この図32の構成において、破線で囲まれた部分が前述した処理を実現する本具体例に係わる部分である。図32(a)はアルファマップ符号化装置であり、オブジェクト領域検出回路3100、ブロック化回路3110、ラベル付け回路3120、ブロック符号化回路3130、ラベルメモリ3140、サイズ変更回路3150、ラベル符号化回路3160、多重化回路(MUX)3170とより構成されている。   In the configuration of FIG. 32, a portion surrounded by a broken line is a portion related to this specific example for realizing the processing described above. FIG. 32A shows an alpha map encoding apparatus, which includes an object area detection circuit 3100, a blocking circuit 3110, a labeling circuit 3120, a block encoding circuit 3130, a label memory 3140, a size changing circuit 3150, and a label encoding circuit 3160. , And a multiplexing circuit (MUX) 3170.

これらのうち、オブジェクト領域検出回路3100は、入力されたアルファマップ信号を元に、そのアルファマップ信号においてオブジェクトを含んでいる部分についての方形領域を検出して、その方形領域のサイズに関する情報と共に当該方形領域のアルファマップ信号を出力するものである。ブロック化回路3110は、この方形領域のアルファマップ信号をマクロブロック化する回路であり、ラベル付け回路3120は、このマクロブロック化されたアルファマップ信号に,ついてそのブロック毎に、そのマクロブロックでのアルファマップ信号内容の属性(allW(白のみ)、Multi(白と黒の混合)、allB(黒のみ))を判定し、各属性に対応するラベル(“0”、“1”、“3”)を割り当てる回路である。   Among these, the object area detection circuit 3100 detects a square area of a portion including the object in the alpha map signal based on the input alpha map signal, and includes the information about the size of the square area. This outputs an alpha map signal of a rectangular area. The blocking circuit 3110 is a circuit that converts the alpha map signal in the rectangular region into a macro block, and the labeling circuit 3120 applies the macro block converted alpha map signal for each block in the macro block. The attributes (allW (white only), Multi (mixed white and black), allB (black only)) of the alpha map signal contents are determined, and labels ("0", "1", "3") corresponding to the respective attributes ).

ブロック符号化回路3130は、ラベルが“1”(Multi)のもののマクロブロックについて、そのマクロブロック内のアルファマップ信号を符号化する回路であり、ラベルメモリ3140は、ラベル付け回路3120より供給されるラベル情報とラベルメモリ出力線3020を介してオブジェクト領域検出回路3100から与えられる領域のサイズ情報を蓄積すると共に、この蓄積したラベル情報とサイズ情報を併せてサイズ変更回路3150に供給するためのメモリである。   The block encoding circuit 3130 is a circuit that encodes an alpha map signal in a macroblock having a label of “1” (Multi), and the label memory 3140 is supplied from the labeling circuit 3120. A memory for storing label information and area size information given from the object area detection circuit 3100 via the label memory output line 3020 and supplying the accumulated label information and size information to the size changing circuit 3150 together. is there.

サイズ変更回路3150は、ラベルメモリ3140より供給される、時刻n−1のフレームのラベル情報とサイズ情報と、オブジェクト領域検出回路3100から与えられる、時刻nのフレームのサイズ情報とから、時刻n−1のラベル情報を時刻nのサイズに相当する様にサイズを変吏する回路であり、ラベル符号化回路3160は、このサイズ変更されたラベル情報を予測値として、ラベル付け回路3120より供給されるラベル情報を符号化する回路である。   The size changing circuit 3150 uses the label information and size information of the frame at time n−1 supplied from the label memory 3140 and the size information of the frame at time n given from the object area detection circuit 3100 to generate a time n−. 1 is a circuit that changes the size of the label information so as to correspond to the size of the time n, and the label encoding circuit 3160 is supplied from the labeling circuit 3120 with the size-changed label information as a predicted value. It is a circuit that encodes label information.

また、多重化回路3170は、ラベル符号化回路3160の得た符号化情報と、ブロック符号化回路3130より供給される符号化情報と、オブジェクト領域検出回路3100から与えられるサイズ情報とを多重化して出力する回路である。   The multiplexing circuit 3170 multiplexes the encoding information obtained by the label encoding circuit 3160, the encoding information supplied from the block encoding circuit 3130, and the size information given from the object area detection circuit 3100. It is a circuit to output.

このような構成の符号化装置において、信号線3010を介して供給されるアルファマップ信号は、オブジェクト領域検出回路3100に与えられ、このオブジェクト領域検出回路3100は、このアルファマップ信号からオブジェクトを含む方形領域を検出する。この方形領域のサイズに関する情報は信号線3020を介して出力され、領域内部のアルファマップ信号は、ブロック化回路3110に供給される。   In the encoding apparatus having such a configuration, the alpha map signal supplied via the signal line 3010 is supplied to the object area detection circuit 3100, and the object area detection circuit 3100 includes a square including an object from the alpha map signal. Detect areas. Information regarding the size of the rectangular area is output via a signal line 3020, and the alpha map signal inside the area is supplied to the blocking circuit 3110.

ブロック化回路3110は、この領域内部のアルファマップ信号についてマクロブロック化する。マクロブロック化されたアルファマップ信号はラベル付け回路3120とブロック符号化回路3130に供給される。   The blocking circuit 3110 converts the alpha map signal inside this area into a macro block. The alpha block signal that has been macroblocked is supplied to a labeling circuit 3120 and a block coding circuit 3130.

ラベル付け回路3120では、マクロブロック毎の属性(“allW”、“Muti”、“allB”)を判定し、各属性に対応するラベル(“0”、“1”、“3”)を割り当てる。そして、この割り当てられたラベル情報は、ブロック符号化回路3130、ラベルメモリ3140、ラベル符号化回路3160に供給される。   The labeling circuit 3120 determines attributes (“allW”, “Muti”, “allB”) for each macroblock, and assigns labels (“0”, “1”, “3”) corresponding to the attributes. The assigned label information is supplied to a block encoding circuit 3130, a label memory 3140, and a label encoding circuit 3160.

ブロック符号化回路3130では、ラベルが“1”(Multi)のとき、マクロブロック内のアルファマップ信号が符号化され、その符号化情報は多重化回路3170に供給される。ラベルメモリ3140には、ラベル付け回路3120より供給されるラベル情報とラベルメモリ出力線3020を介する領域のサイズ情報が蓄積され、ラベル情報とサイズ情報を併せてラベルメモリ出力線3030よりサイズ変更回路3150へと供給される。   In the block encoding circuit 3130, when the label is “1” (Multi), the alpha map signal in the macroblock is encoded, and the encoded information is supplied to the multiplexing circuit 3170. In the label memory 3140, label information supplied from the labeling circuit 3120 and area size information via the label memory output line 3020 are accumulated, and the label information and the size information are combined from the label memory output line 3030 to the size changing circuit 3150. Supplied to.

サイズ変更回路3150では、ラベルメモリ出力線3030を介して供給される、時刻n−1のフレームのラベル情報とサイズ情報と、信号線3020を介して供給される時刻nのサイズ情報とから、時刻n−1のラベル情報を時刻nのサイズに相当する様にサイズを変更したラベル情報をラベル符号化回路3160に供給する。   In the size changing circuit 3150, the time information is obtained from the label information and size information of the frame at time n−1 supplied through the label memory output line 3030 and the size information at time n supplied through the signal line 3020. The label information whose size is changed so that the label information of n−1 corresponds to the size of time n is supplied to the label encoding circuit 3160.

ラベル符号化回路3160では、サイズ変更回路3150より供給されるラベル情報を予測値として、ラベル付け回路3120に供給されるラベル情報を符号化し、その符号化情報は多重回路3170に供給される。多重化回路3170では、ブロック符号化回路3130とラベル符号化回路3130とラベル符号化回路3160より供給される符号化情報と、ラベルメモリ出力線3020を介して供給されるサイズ情報とを多重化した後、信号線3040を介して出力する。   The label encoding circuit 3160 encodes the label information supplied to the labeling circuit 3120 using the label information supplied from the size changing circuit 3150 as a predicted value, and the encoded information is supplied to the multiplexing circuit 3170. In the multiplexing circuit 3170, the encoding information supplied from the block encoding circuit 3130, the label encoding circuit 3130, and the label encoding circuit 3160 and the size information supplied via the label memory output line 3020 are multiplexed. Thereafter, the signal is output via the signal line 3040.

以上が符号化装置の構成と作用である。次に復号化装置の構成と作用を説明する。   The above is the configuration and operation of the encoding apparatus. Next, the configuration and operation of the decoding apparatus will be described.

図32(b)に示すアルファマップ符号化装置は、分離化回路(DMUX)3200、ラベル複合化回路3210、サイズ変更回路3220、ラベルメモリ3230、ブロック複合化回路3240より構成される。   The alpha map encoding apparatus shown in FIG. 32B includes a separation circuit (DMUX) 3200, a label composite circuit 3210, a size change circuit 3220, a label memory 3230, and a block composite circuit 3240.

これらのうち、分離化回路3200は、信号線3050を介して供給される符号化情報を分離する回路であり、ラベル複合化回路3210は、サイズ変更回路3220より供給される、時刻n−1のラベル情報のサイズを変更した情報を予測値として、時刻nのラベル情報を再生する回路である。   Among these, the separation circuit 3200 is a circuit that separates encoded information supplied via the signal line 3050, and the label composite circuit 3210 is supplied from the size changing circuit 3220 at the time n-1. This is a circuit that reproduces label information at time n using information obtained by changing the size of label information as a predicted value.

また、サイズ変更回路3220は、サイズ変更回路3150と同様の働きをする回路であって、ラベルメモリ3230より供給される、時刻n−1のフレームでのラベル情報とサイズ情報と、分離化回路3200から分離して与えられる、時刻nのフレームのサイズ情報とから、時刻n−1のフレームでのラベル情報を時刻nのサイズに相当する様にサイズを変更する回路であり、ラベルメモリ3230は、ラベルメモリ3140と同様の働きをする回路であって、ラベル複合化回路3210より復号化されて供給されるラベル情報と、分離化回路3200から与えられる領域のサイズ情報を蓄積すると共に、この蓄積したラベル情報とサイズ情報を併せてサイズ変更回路3220に供給するためのメモリである。   The size changing circuit 3220 is a circuit that functions in the same manner as the size changing circuit 3150, and is supplied from the label memory 3230 and includes label information and size information in the frame at time n−1, and a separation circuit 3200. Is a circuit that changes the size of the label information in the frame at time n-1 so as to correspond to the size at time n from the size information of the frame at time n given separately from the label n. This is a circuit having the same function as that of the label memory 3140. The label information decoded and supplied from the label combination circuit 3210 and the size information of the area given from the separation circuit 3200 are accumulated and stored. This is a memory for supplying label information and size information to the size changing circuit 3220 together.

また、ブロック復号化回路3240は、ラベル復号化回路3210より供給される、再生されたラベル情報にしたがって、ブロック毎にアルファマップ信号を再生する回路である。   The block decoding circuit 3240 is a circuit that reproduces an alpha map signal for each block in accordance with the reproduced label information supplied from the label decoding circuit 3210.

このような構成の復号化装置の作用を説明する。
分離化回路3200では、信号線3050を介して供給される符号化情報を分離して、ブロック複合化回路3240とラベル復号化回路3210に供給すると共に、信号線3060を介してサイズ情報を出力する。ラベル復号化回路3210では、サイズ変更回路3220より供給される時刻n−1のフレームでのラベル情報のサイズを変更した情報を予測値として、時刻nのフレームでのラベル情報を再生する。
The operation of the decoding apparatus having such a configuration will be described.
The demultiplexing circuit 3200 demultiplexes the encoded information supplied via the signal line 3050, supplies the encoded information to the block decoding circuit 3240 and the label decoding circuit 3210, and outputs size information via the signal line 3060. . The label decoding circuit 3210 reproduces the label information in the frame at time n using the information obtained by changing the size of the label information in the frame at time n−1 supplied from the size changing circuit 3220 as a predicted value.

再生されたラベル情報はブロック復号化回路3240とラベルメモリ3230に供給される。ブロック復号化回路3240では、ラベル復号化回路3210より供給される、再生されたラベル情報にしたがって、ブロック毎にアルファマップ信号を再生する。なお、サイズ変更回路3220はサイズ変更回路3150と、ラベルメモリ3230は、ラベルメモリ3140と、各々同一の動作をするため、ここでは深く説明しない。   The reproduced label information is supplied to the block decoding circuit 3240 and the label memory 3230. The block decoding circuit 3240 reproduces the alpha map signal for each block according to the reproduced label information supplied from the label decoding circuit 3210. The size changing circuit 3220 and the label memory 3230 operate in the same manner as the size changing circuit 3150 and the label memory 3140, respectively, and thus will not be described in detail here.

以上、マクロブロック単位にしたアルファマップをラベル付けし、既に符号化済みのフレームのマクロブロックのラベルを利用して、現フレームのマクロブロックのラベルを符号化するようにした符号化装置と複合化装置の例を説明した。時間的に近いフレームのアルファマップ間では、そのマクロブロックは非常に似たラベル付けが行われる。従って、このような場合には、フレーム間においてラベルの相関が高いため、既に符号化済みのフレームのラベルを利用して、現フレームのラベルを符号化することで、大幅に符号化効率を図ることができるようになる。   As described above, it is combined with an encoding device that labels the alpha map in units of macro blocks and uses the macro block label of the already encoded frame to encode the macro block label of the current frame. An example of an apparatus has been described. The macroblocks are labeled very similar between alphamaps in near temporal frames. Therefore, in such a case, since the correlation between the labels is high between the frames, encoding of the label of the current frame by using the label of the already encoded frame greatly improves the encoding efficiency. Will be able to.

ところで、このような先行技術としての発明では、フレーム内あるいはフレーム間において隣接する1ブロック(1マクロブロック)を参照してVLC(可変長符号化)テーブルを切り換えていた。この場合、フレーム間相関が高い場合には、“フレーム間の隣接ブロック”を参照し、フレーム間相関が低い場合には、“フレーム内の隣接ブロック”を参照して、VLCテーブルを切り換えていた。しかし、実際の応用では、フレーム間相関とフレーム内相関両方を利用した方が良い場合が多い。   By the way, in the invention as such a prior art, the VLC (variable length coding) table is switched with reference to adjacent one block (one macro block) within a frame or between frames. In this case, when the inter-frame correlation is high, the “adjacent block between frames” is referred to, and when the inter-frame correlation is low, the “adjacent block in the frame” is referred to switch the VLC table. . However, in actual applications, it is often better to use both interframe correlation and intraframe correlation.

そこで、ある画素位置のモードを“M(h、v、t)”(h、v、tは各々、水平、垂直、時間方向の座標軸を表す)とすると、モード“M(x、y、n)”を符号化する際に、例えば、“M(x−1、y、n)”、“M(x、y−1、n)”、“M(x、y、n−1)”を参照してVLCテーブルを選択することにする。ここで、図29のようにモードの数が3通りの場合、参照ブロック数が3ブロック(3マクロブロック)ならば、VLCテーブルの数は3の3乗(=27)個となる。また、参照ブロック数をこれ以上多くすることも可能である(例えば、“M(x−1、y−1、n)”、“M(x、y、n−2)”)。   Therefore, if the mode at a certain pixel position is “M (h, v, t)” (h, v, and t represent coordinate axes in the horizontal, vertical, and time directions, respectively), the mode “M (x, y, n ) ", For example," M (x-1, y, n) "," M (x, y-1, n) "," M (x, y, n-1) " The VLC table is selected by referring to it. Here, when the number of modes is three as shown in FIG. 29, if the number of reference blocks is three (3 macroblocks), the number of VLC tables is 3 to the third power (= 27). It is also possible to increase the number of reference blocks further (for example, “M (x−1, y−1, n)”, “M (x, y, n−2)”).

この場合、VLCテーブルの数が多くなるだけでなく、新たに追加する参照ブロック間とのブロック間相関も低下するため、参照ブロック数を増やしても符号化効率はあまり向上しない。従って、VLCテーブルの数と、符号化効率とのトレードオフを図る必要がある。   In this case, not only the number of VLC tables increases, but also the inter-block correlation with newly added reference blocks decreases, so that the coding efficiency does not improve much even if the number of reference blocks is increased. Therefore, it is necessary to make a trade-off between the number of VLC tables and encoding efficiency.

次に、ブロックの属性情報を符号化する別方式の具体例を説明する。   Next, a specific example of another method for encoding block attribute information will be described.

ここでは、前のフレームのラベルを予測に用いてブロックの属性情報を符号化する方式を説明する。   Here, a method of encoding block attribute information using the label of the previous frame for prediction will be described.

<前のフレームのラベルを予測に用いる符号化装置の具体例>
図43は本発明の一具体例としての符号化回路のブロック図である。図に示すように、この符号化回路はオブジェクト領域検出回路502、ブロック化回路504、ラベル付け回路506、ラベル符号化回路508、ラベルメモリ509、参照ブロック決定回路510、予測回路512とから構成される。
<Specific Example of Encoding Device that Uses Previous Frame Label for Prediction>
FIG. 43 is a block diagram of an encoding circuit as a specific example of the present invention. As shown in the figure, this encoding circuit includes an object area detection circuit 502, a blocking circuit 504, a labeling circuit 506, a label encoding circuit 508, a label memory 509, a reference block determination circuit 510, and a prediction circuit 512. The

これらのうち、オブジェクト領域検出回路502は、アルファマップの信号501からオブジェクトを含む、ブロックサイズの倍数で表される領域を符号化領域として設定すると共に、当該符号化領域のアルファマップ信号503を切り出す回路であり、ブロック化回路504は、この切り出されたアルファマップ信号503を16×16画素構成のブロック単位(マクロブロック単位)に分割(ブロック化)して出力するものであり、ラベル付け回路506は、ブロック化されたアルファマップ信号505について、オブジェクトの含み具合に応じた所定のラベルを付与し、ラベル情報507として出力するものである。   Among these, the object area detection circuit 502 sets an area represented by a multiple of the block size including the object from the alpha map signal 501 as an encoding area, and cuts out the alpha map signal 503 of the encoding area. A blocking circuit 504 divides (blocks) the extracted alpha map signal 503 into block units (macroblock units) having a 16 × 16 pixel configuration, and outputs a labeling circuit 506. In this case, a predetermined label corresponding to the degree of inclusion of the object is assigned to the blocked alpha map signal 505 and output as label information 507.

ラベル符号化回路508は、与えられる予測値514によって符号化テーブルを切り替えてラベル情報507を符号化し、出力するものであり、ラベルメモリ509は、ラベル付け回路506によってブロック毎に付与された上記のラベル情報507を記憶するものであり、参照ブロック決定回路510は、前フレームにおいて符号化ブロックと同じ位置にあるブロックを参照ブロック511として決定するといった処理を行うものであり、予測回路512はラベルメモリ509に保持されている前フレームのラベル513を参照し、参照ブロック511の位置のラベルを予測してこれを予測値514としてラベル符号化回路508に送るものである。   The label encoding circuit 508 encodes and outputs the label information 507 by switching the encoding table according to the given predicted value 514, and the label memory 509 is the above-described label assigned to each block by the labeling circuit 506. Label information 507 is stored, and the reference block determination circuit 510 performs processing such as determining a block at the same position as the encoded block in the previous frame as the reference block 511, and the prediction circuit 512 includes a label memory. The label 513 of the previous frame held in 509 is referenced, the label at the position of the reference block 511 is predicted, and this is sent as a predicted value 514 to the label encoding circuit 508.

このような構成の符号化装置において、アルファマップの信号501は、オブジェクト領域検出回路502に入力される。オブジェクト領域検出回路502では、オブジェクトを含む、ブロックサイズの倍数で表される領域が符号化領域として設定され、符号化領域で切り出されたアルファマップ503がブロック化回路504に送られる。ブロック化回路504では、アルファマップ503が16×16画素構成のブロック単位(マクロブロック単位)に分割され、ブロック化されたアルファマップ505は、ラベル付け回路506に送られる。ラベル付け回路506では、例えば、
・ブロック内にオブジェクトが含まれない :“ラベル0”
・ブロック内の一部にオブジェクトが含まれる:“ラベル1”
・ブロック内の全てがオブジェクトである :“ラベル3”
といったラベル情報507(モード情報)がブロック毎に付与される。ラベル情報507はラベル符号化回路508に送られ、またラベルメモリ509に記憶される。このラベルメモリ509にはそれまでに符号化されたラベルが記憶されている。
In the encoding apparatus having such a configuration, the alpha map signal 501 is input to the object region detection circuit 502. In the object area detection circuit 502, an area including an object and represented by a multiple of the block size is set as an encoding area, and an alpha map 503 cut out in the encoding area is sent to the blocking circuit 504. In the blocking circuit 504, the alpha map 503 is divided into block units (macro block units) having a 16 × 16 pixel configuration, and the blocked alpha map 505 is sent to the labeling circuit 506. In the labeling circuit 506, for example,
-Object is not included in the block: “Label 0”
-The object is included in a part of the block: "Label 1"
-Everything in the block is an object: "Label 3"
The label information 507 (mode information) is given for each block. The label information 507 is sent to the label encoding circuit 508 and stored in the label memory 509. The label memory 509 stores labels that have been encoded so far.

一方、参照ブロック決定回路510では、例えば前フレームにおいて符号化ブロックと同じ位置にあるブロックが参照ブロック511として決定され、予測回路512に送られる。予測回路512には、ラベルメモリ509から前フレームのラベル513も入力され、そのうちの参照ブロック511の位置のラベルが予測値514としてラベル符号化回路508に送られる。ラベル符号化回路508では、予測値514によって符号化テーブルを切り替えてラベル情報507を符号化し、符号515が出力される。   On the other hand, in the reference block determination circuit 510, for example, a block at the same position as the encoded block in the previous frame is determined as the reference block 511 and sent to the prediction circuit 512. The prediction circuit 512 also receives the label 513 of the previous frame from the label memory 509 and sends the label at the position of the reference block 511 to the label encoding circuit 508 as the prediction value 514. In the label encoding circuit 508, the encoding table is switched by the predicted value 514, the label information 507 is encoded, and the code 515 is output.

ここで、符号化領域が常にフレームと等しい時は、参照ブロックは一つに決まる。しかし、符号化領域がフレームよりも小さく、かつ、前フレームと現フレームでその符号化額域の位置が異なる場合は、フレームの角を原点とする座標軸を用いるか、符号化領域の角を原点とする座標軸を用いるかで参照ブロックは異なってくる。   Here, when the coding area is always equal to the frame, one reference block is determined. However, if the coding area is smaller than the frame and the position of the coding frame is different between the previous frame and the current frame, use the coordinate axis with the corner of the frame as the origin, or use the corner of the coding area as the origin. The reference block differs depending on the coordinate axis.

この座標軸の取り扱いについて詳しく説明する。   The handling of the coordinate axes will be described in detail.

図44(a),(b)は、時刻n−1と時刻nにおけるフレーム画像Fn-1 ,FnとそれぞれのフレームFn-1 ,Fnにおける符号化領域CAの各マクロブロックのモード情報MDの例である。   44 (a) and 44 (b) show examples of mode information MD of frame images Fn-1 and Fn at time n-1 and time n and each macroblock of the coding area CA in the respective frames Fn-1 and Fn. It is.

先願の発明(特願平8−237053号)では、一例として、現フレーム(時刻n)内の符号化領域の原点Vc0と、前フレーム(時刻n−1)内の符号化領域の原点Vp0を一致させて、該ブロックのモード情報を符号化する際に参照とするブロックを決定する具体例を提示した。これは、符号化領域の座標軸に基づいてブロックの対応付けを行うものである。   In the invention of the prior application (Japanese Patent Application No. 8-237053), as an example, the origin Vc0 of the coding area in the current frame (time n) and the origin Vp0 of the coding area in the previous frame (time n-1). A specific example of determining a block to be used as a reference when coding mode information of the block is presented. In this method, the blocks are associated based on the coordinate axes of the coding area.

この場合、図45(a)のように、前フレームの符号化領域の右端あるいは下端を“cut”または“copy”することで、現フレームの符号化領域のサイズに一致させている。   In this case, as shown in FIG. 45A, the right end or lower end of the encoding area of the previous frame is “cut” or “copyed” to match the encoding area size of the current frame.

図44の例では、符号化領域の左端および上端が変化している。このような場合、現フレームのモード情報に対応するブロックは、図45(a)に示されるように斜線部のブロック(21個)が一致していないため、この値を用いて符号化すると符号化効率が低下する恐れがある。   In the example of FIG. 44, the left end and the upper end of the encoding area are changed. In such a case, the blocks corresponding to the mode information of the current frame do not match the shaded blocks (21 blocks) as shown in FIG. 45 (a). There is a risk that the conversion efficiency will decrease.

図44のような例では、現フレームの原点Fc0と前フレームの原点Fp0を一致させて、フレームの座標軸上で最も近いブロック位置のブロックを参照ブロックとした方がよい。   In the example as shown in FIG. 44, it is better to match the origin Fc0 of the current frame with the origin Fp0 of the previous frame and use the block at the closest block position on the coordinate axis of the frame as the reference block.

図44の場合、フレームの座標軸に基づいて参照ブロックを求めると図45 (b)の様になる。つまり、図44の例では、左端と上端で変化があるため、図45(b)のように左端と上端を“cut”または“copy”することで、現フレームの符号化領域のサイズに一致させることになる。この場合、現フレームのモード情報に対応するブロックは、図45(b)に示されるように、一致していないブロックは、斜線部のブロック(3個)だけになる。   In the case of FIG. 44, when the reference block is obtained based on the coordinate axis of the frame, it is as shown in FIG. That is, in the example of FIG. 44, there is a change between the left end and the upper end, so that the left end and the upper end are “cut” or “copy” as shown in FIG. 45B to match the size of the current frame coding area. I will let you. In this case, as shown in FIG. 45B, the blocks corresponding to the mode information of the current frame are only the hatched blocks (three) as shown in FIG.

即ち、状況に応じて前フレームのラベルを、符号化領域の座標軸に基づいて変更するか、フレームの座標軸に基づいて変更するかを切り替えることにより、符号化効率の改善が図れる。座標軸の決定法は、符号化装置側で最適な方を選択して切り替え情報を送つても良いし、符号化装置と復号化装置とで共に既知の情報を用いて決定してもよい。   That is, the coding efficiency can be improved by switching whether the label of the previous frame is changed based on the coordinate axis of the coding area or the coordinate axis of the frame depending on the situation. As a method for determining the coordinate axis, the optimum information may be selected on the encoding device side and switching information may be sent, or both the encoding device and the decoding device may use known information.

図46は、符号化領域の座標軸を用いた方が良い例である。この例はカメラを右方向に振った場合のように、(a)のフレームFn-1 から(b)のフレームFnのようにフレームが大きく移り変わったことを示している。この例の場合、図から明らかなように、フレーム内での符号化領域の位置が大きくずれているため、フレームの座標軸に基づいて参照ブロックを決定するのは得策ではない。   FIG. 46 is an example in which it is better to use the coordinate axes of the coding area. This example shows that the frame has changed significantly from the frame Fn-1 in (a) to the frame Fn in (b), as in the case where the camera is shaken to the right. In the case of this example, as apparent from the figure, the position of the coding area in the frame is greatly shifted, so it is not a good idea to determine the reference block based on the coordinate axis of the frame.

即ち、現フレーム(時刻n時点のフレームFn)と前フレーム(時刻n−1時点のフレームFn-1 )とでフレーム内での符号化領域CAの位置が大きくずれている場合には符号化領域の座標軸を用いた方がよく、フレーム内での符号化領域の位置があまりずれていない場合にはフレームの座標軸を用いた方がよい。   That is, if the position of the coding area CA in the frame is greatly deviated between the current frame (frame Fn at time n) and the previous frame (frame Fn-1 at time n-1), the coding area It is better to use the coordinate axis of the frame, and when the position of the coding area in the frame is not so shifted, it is better to use the coordinate axis of the frame.

現フレームFn と前フレームFn-1 とでフレーム内での符号化領域の位置が大きくずれでいるか否かは、フレーム内における符号化領域の位置を表す情報(ベクトル)prev_refscurr_refと符号化領域の大きさから判断できる。
すなわち、アルファマップを併用する動画像符号化装置における符号化データ構成は規格により図47に示す如きとなっている。すなわち、符号化データは符号化領域のレイヤ、マクロブロックMBのレイヤ、2値形状のレイヤを含み、符号化領域のレイヤは符号化領域サイズ情報、符号化領域位置情報、符号化領域縮小・拡大率情報などを含む。そして、MBのレイヤは、2値形状情報,texture MV情報、多値形状情報、texture情報からなり、2値形状情報はモード情報、動きベクトル情報、縮小・拡大率情報、スキャン方向情報、2値符号化情報を含む。
Whether or not the position of the coding area in the frame between the current frame Fn and the previous frame Fn-1 is greatly deviated depends on information (vector) prev_refscurr_ref indicating the position of the coding area in the frame and the size of the coding area. You can judge from that.
That is, the encoded data structure in the moving image encoding apparatus that uses the alpha map is as shown in FIG. 47 according to the standard. That is, the encoded data includes an encoding area layer, a macroblock MB layer, and a binary shape layer. The encoding area layer includes encoding area size information, encoding area position information, and encoding area reduction / enlargement. Includes rate information. The MB layer is composed of binary shape information, texture MV information, multi-value shape information, and texture information. The binary shape information is mode information, motion vector information, reduction / enlargement ratio information, scan direction information, binary. Contains encoding information.

これらのうち、符号化領域サイズ情報は符号化領域のサイズ(縦横の大きさ)を表す情報を指し、符号化領域位置情報は符号化領域の位置(Vp0、Vc0の位置)を表す情報を指し、符号化領域縮小・拡大率情報は符号化領域単位での2値画像の縮小・拡大率(CR)情報を指す。   Among these, the coding area size information indicates information indicating the size (vertical and horizontal size) of the encoding area, and the coding area position information indicates information indicating the position of the encoding area (the positions of Vp0 and Vc0). The encoding area reduction / enlargement ratio information refers to reduction / enlargement ratio (CR) information of a binary image in units of encoding areas.

また、MB符号化情報はMB内のオブジェクトを再生するための情報を指す。 MBのレイヤにおける2値形状情報はMB内の各画素がオブジェクト内部か否かを表す情報を指し、texture MV情報はMB内の輝度信号や色差信号を動き捕償予測するための動きベクトル情報を指し、多値形状情報はオブジェクトを他のオブジェクトと合成する際の重みづけ情報を指し、texture情報はMB内の輝度信号や色差信号の符号化情報を指す。   The MB encoded information indicates information for reproducing an object in the MB. The binary shape information in the MB layer indicates information indicating whether each pixel in the MB is inside the object, and the texture MV information is motion vector information for motion compensation prediction of the luminance signal and color difference signal in the MB. The multi-value shape information indicates weighting information when the object is combined with another object, and the texture information indicates the encoding information of the luminance signal and color difference signal in the MB.

また、2値形状のレイヤにおけるモード情報はMB内の2値画像の属性を表す情報を指し、動きベクトル情報はMB内の2値の画像を動き補償予測するための動きベクトル情報を指し、縮小・拡大率情報はMB単位での2値画像の縮小・拡大率(CR)情報を指し、スキャン方向情報は符号化の順序が水平方向か垂直方向かを示す情報を指し、2値符号化情報は2値画像の符号化情報を指す。   The mode information in the binary shape layer indicates information representing the attribute of the binary image in the MB, and the motion vector information indicates motion vector information for motion compensation prediction of the binary image in the MB. The enlargement rate information indicates the reduction / enlargement rate (CR) information of the binary image in MB units, and the scan direction information indicates information indicating whether the encoding order is the horizontal direction or the vertical direction. Indicates encoding information of a binary image.

符号化領域の位置(Vp0、Vc0の位置)を表す情報は、符号化領域位置情報に納められており、従って、この情報を用いることで符号化領域の位置(Vp0、Vc0の位置)を知ることができる。この情報を用いてフレームFn-1 とフレームFnを比較する。この比較はフレームのホームポジションから符号化領域のホームポジション位置までのベクトルをそれぞれ求めてこのベクトルによって行う。   Information indicating the position of the coding area (positions of Vp0 and Vc0) is stored in the coding area position information. Therefore, the position of the coding area (positions of Vp0 and Vc0) is known by using this information. be able to. The frame Fn-1 and the frame Fn are compared using this information. This comparison is performed by obtaining vectors from the home position of the frame to the home position of the coding area.

その結果、例えば、図46の様に“prev_refとcurr_ref”の差が大きく、現フレームと前フレームとで符号化領域の大きさがほとんど変化がない場合には、符号化領域の座標軸に基づいてた方が良いことが分かる。ここで、“prev_refとcurr_ref”および符号化領域の大きさの情報は、符号化領域の符号化に先立って符号化されており、復号装置側でも既知の情報であるため、どちらの座標軸を用いたかを識別する付加情報は必要ない。   As a result, for example, as shown in FIG. 46, when the difference between “prev_ref and curr_ref” is large and there is almost no change in the size of the encoding region between the current frame and the previous frame, the difference is based on the coordinate axis of the encoding region. You can see that it is better. Here, “prev_ref and curr_ref” and the information on the size of the coding area are coded prior to coding of the coding area, and are known information on the decoding device side, so which coordinate axis is used. No additional information for identifying

また、図48(a)に示すようにフレーム530の一部分として符号化領域531が設定された場合、符号化領域531の外側はラベルが決まらない。しかし、次のフレームの符号化の際には、符号化領域531の外側が参照ブロックとなる事があるので、何らかのラベルを挿入しておく必要がある。   In addition, as shown in FIG. 48A, when the encoding area 531 is set as a part of the frame 530, the label is not determined outside the encoding area 531. However, when encoding the next frame, the outside of the encoding area 531 may be a reference block, so it is necessary to insert some label.

図48(d)は、図48(a)におけるラベル未定の部分に所定の値、この場合は“0”を挿入した例である。図48(c)は、図48(a)におけるラベル未定部分について、符号化領域から外挿した例であり、これは、オブジェクトの動きが大きかったり、形状が激しく変化するなどして、前フレームではオブジェクトが無かった部分に次のフレームではオブジェクトが現れる確率が高い場合に有効である。   FIG. 48 (d) shows an example in which a predetermined value, in this case “0”, is inserted into the unlabeled portion in FIG. 48 (a). FIG. 48 (c) is an example in which the label undetermined portion in FIG. 48 (a) is extrapolated from the encoding area. This is because the movement of the object is large or the shape changes drastically. This is effective when there is a high probability that an object will appear in the next frame in a part where there was no object.

図48(b)は、図48(a)のラベル未定部分について、ラベルメモリ509のメモリ空間のうち、次のフレームの符号化領域532の部分だけを外挿し、その他の部分は上書きしない例であり、このようにすると、2フレーム以上前のフレームのラベルを予測に用いることができる。   FIG. 48B shows an example in which only the portion of the coding area 532 of the next frame is extrapolated and the other portions are not overwritten in the memory space of the label memory 509 with respect to the label undetermined portion of FIG. Yes, in this way, the labels of two or more previous frames can be used for prediction.

以前のフレームのラベルを予測に用いたい場合は、他に、例えば外挿や所定値の挿入は全く行わずに、メモリ空間のうち、符号化領域だけを更新していく方法もある。   When it is desired to use the label of the previous frame for prediction, there is another method of updating only the coding area in the memory space without performing extrapolation or insertion of a predetermined value at all.

次に、図52を用いて説明した、フレームの縮小・拡大率(CR)がフレーム毎に切り替わる場合のラベルの予測方法について説明する。
図60は、縮小処理の例であって、前フレームが“CR=1”で現フレームが“CR=1/2”の例であり、この場合、縮小して得ようとする現フレームの対象ブロックである例えばマクロブロックMB1に対応する前フレームのブロックは、図に示したように、MB2〜MB5の4つある(図61参照)。つまり、前フレームのマクロブロックMB2,MB3,MB4,MB5が縮小後のマクロブロックMB1になる。
Next, the label prediction method when the frame reduction / enlargement ratio (CR) described with reference to FIG. 52 is switched for each frame will be described.
FIG. 60 shows an example of reduction processing, in which the previous frame is “CR = 1” and the current frame is “CR = 1/2”. In this case, the target of the current frame to be obtained by reduction As shown in the figure, there are four blocks of MB2 to MB5 corresponding to the block, for example, the macroblock MB1 (see FIG. 61). That is, the macroblocks MB2, MB3, MB4, and MB5 of the previous frame become the reduced macroblock MB1.

今、現フレームのマクロブロックMB1のアドレスを(x,y)とすると、前フレームのブロックMB2〜MB5のアドレスは(2x,2y)、(2x+1,2y)、(2x,2y+1)、(2x+1、2y+1)で得られる。   Now, assuming that the address of the macroblock MB1 of the current frame is (x, y), the addresses of the blocks MB2 to MB5 of the previous frame are (2x, 2y), (2x + 1, 2y), (2x, 2y + 1), (2x + 1, 2y + 1).

ここでの係数“2”は、前フレームと現フレームの縮小・拡大率CRの値の比として与えられる。   The coefficient “2” here is given as a ratio of the value of the reduction / enlargement ratio CR between the previous frame and the current frame.

ブロックMB1のラベルの符号化の予測には、ブロックMB2、MB3、MB4、MB5のいずれかのラベルを用いるのが適当であるが、その決め方にはいくつか方法がある。
まず、最も簡単で演算量が少ないのは、4つのうちの所定の位置(例えば左上)にあるブロックのラベルを用いる方法である。あるいは、4つのラベルに同じものがある時は、その数が最も多いラベルを予測値として用いるようにすれば、予測が当たる確率は高くなる。
In order to predict the encoding of the label of the block MB1, it is appropriate to use any of the labels of the blocks MB2, MB3, MB4, and MB5, but there are several methods for determining the label.
First, the simplest and the least amount of calculation is a method using a label of a block at a predetermined position (for example, upper left) among the four. Alternatively, when there are four labels that are the same, if the label with the largest number is used as the predicted value, the probability that the prediction is successful will increase.

同じ内容を持つラベルの数が等しい場合、つまり、二組ずつに分かれてしまった場合には、出現頻度が高い順に予めラベルに順序を付けておき、その順序で上位のラベルを予測値として選択する。フレーム内に矩形の符号化領域CAを設定する場合、符号化領域CAの角を原点とする座標軸を用いると、図61のように、現フレームのブロック(符号化対象のマクロブロック)の境界は参照フレームのマクロブロックの境界に重なる。   If the number of labels with the same content is equal, that is, if they are divided into two sets, order the labels in advance in descending order of appearance frequency, and select the upper label as the predicted value in that order. To do. When a rectangular coding area CA is set in a frame, using a coordinate axis whose origin is the corner of the coding area CA, the boundary of the block (macroblock to be coded) of the current frame is as shown in FIG. Overlaps the macroblock boundary of the reference frame.

しかし、符号化対象の領域はマクロブロックの幅よりも小さなステップで位置設定可能とし、フレームの角を原点とする座標軸を用いると、図62のように、一般にブロックの境界は重ならず、MB6〜MB14の計9つのマクロブロックが参照される。   However, if the region to be encoded can be set in steps smaller than the width of the macroblock and the coordinate axis with the frame corner as the origin is used, generally the block boundaries do not overlap as shown in FIG. A total of nine macroblocks of ~ MB14 are referenced.

この場合は、全体が参照されているマクロブロックMB10のラベルを用いる。   In this case, the label of the macro block MB10 that is referred to as a whole is used.

図63は、前フレームが縮小・拡大率CR=1/2で現フレームが縮小・拡大率CR=1の例であり、この場合、マクロブロックMB19は縮小フレーム中のマクロブロックMB15の右下の部分を参照することになる。この時は、ブロックMB15のラベルを予測値とするか、あるいは、参照部分がブロックMB16〜MB18とも近いことから、これらのブロックのラベルを考慮に入れて、例えば前述したように多数決などで予測値を決めてもよい。   FIG. 63 shows an example in which the previous frame has a reduction / enlargement ratio CR = 1/2 and the current frame has a reduction / enlargement ratio CR = 1. In this case, the macroblock MB19 has Will refer to the part. At this time, the label of the block MB15 is used as a predicted value, or since the reference portion is also close to the blocks MB16 to MB18, the predicted value is determined by, for example, majority voting as described above in consideration of the labels of these blocks. You may decide.

<ラベルを予測に用いる復号化装置の構成例>
図49にラベルを予測に用いるようにした本発明の復号化装置の構成例をブロック図で示す。
<Configuration Example of Decoding Device Using Label for Prediction>
FIG. 49 is a block diagram showing a configuration example of the decoding apparatus according to the present invention in which labels are used for prediction.

この復号化装置は、ラベル復号化回路516、ラベルメモリ517、参照ブロック決定回路518、予測回路520とから構成される。   This decoding apparatus includes a label decoding circuit 516, a label memory 517, a reference block determination circuit 518, and a prediction circuit 520.

これらのうち、ラベル復号化回路516は、入力された復号対象の符号データからラベルのデータを復号化するものであり、ラベルメモリ517は、この復号化されたラベルのデータを記憶するものであり、参照ブロック決定回路518は、前フレームにおいて符号化ブロックと同じ位置にあるブロックを参照ブロック519として決定するといった処理を行うものである。   Among these, the label decoding circuit 516 decodes the label data from the input code data to be decoded, and the label memory 517 stores the decoded label data. The reference block determination circuit 518 performs processing such as determining a block at the same position as the encoded block in the previous frame as the reference block 519.

また、予測回路520は前フレームのラベル521と参照ブロック519から予測値522を求め、ラベル復号化回路516に与える機能を有する。   Further, the prediction circuit 520 has a function of obtaining a prediction value 522 from the label 521 and the reference block 519 of the previous frame, and giving the prediction value 522 to the label decoding circuit 516.

このような構成の復号化装置において、復号対象である符号化データのストリーム515はラベル復号化回路516に入力され、ラベルが復号化される。
一方、ラベルメモリ517には、それまでに復号化されたラベルが記憶されている。また、参照ブロック決定回路518では、符号化装置で説明したものと同じように参照ブロック519が決定され予測回路520に送られる。予測回路520でも符号化装置と同様に前フレームのラベル521と参照ブロック519から予測値522が求められ、ラベル復号化回路516に送られる。ラベル復号化回路516では、予測値522によって復号化テーブルを切り替えてラベル523を復号化し出力する。
In the decoding apparatus having such a configuration, the encoded data stream 515 to be decoded is input to the label decoding circuit 516, and the label is decoded.
On the other hand, the label memory 517 stores labels that have been decoded so far. In the reference block determination circuit 518, the reference block 519 is determined and sent to the prediction circuit 520 in the same manner as described in the encoding apparatus. Also in the prediction circuit 520, the prediction value 522 is obtained from the label 521 and the reference block 519 of the previous frame, and sent to the label decoding circuit 516, similarly to the encoding device. The label decoding circuit 516 decodes and outputs the label 523 by switching the decoding table according to the predicted value 522.

また、あるブロックのモード“M(h、v、t)”(h、v、tは各々、水平、垂直、時間方向の座標軸を表す)を符号化する際に、例えば、“M(x−1、y、n)”、“M(x、y−1、n)”、“M(x、y、n−1)”などを参照して符号化テーブルを切り替えるのであるが、ここで用いるモードに、動き補償に用いる動きベクトルの情報の一部を含め、以下に示すモードの集合(これをモード集合Aと呼ぶことにする。)を用いることもできる。   Further, when encoding a mode “M (h, v, t)” (h, v, and t respectively represent horizontal, vertical, and time coordinate axes) of a certain block, for example, “M (x− 1, y, n) ”,“ M (x, y−1, n) ”,“ M (x, y, n−1) ”, and the like are used to switch the encoding table. A mode set shown below (hereinafter referred to as mode set A) including a part of motion vector information used for motion compensation can also be used in the mode.

[モード集合A]
(1) “a11W”
(2) “a11B”
(3) “copy(動きベクトル==0)”
(4) “copy(動きベクトル!=0)”
(5) “coded”
ここで、モード集合Aの(3)と(4)はいずれもcopyモードであるが、モード集合Aの(3)は、動きベクトルがゼロであることを意味し、モード集合Aの(4)は、動きベクトルがゼロ以外であることを意味する。モード集合Aの(4)の場合は動きベクトルの値を別途符号化する必要があるが、モード集合Aの(3)の場合は、動きベクトルを符号化する必要はない。動きベクトルがゼロである確率が高い場合に、モード集合Aを用いると、モードの符号量と動きベクトルの符号量の合計を削減できる。
[Mode Set A]
(1) “a11W”
(2) “a11B”
(3) “copy (motion vector == 0)”
(4) “copy (motion vector! = 0)”
(5) “coded”
Here, (3) and (4) of mode set A are both copy modes, but (3) of mode set A means that the motion vector is zero, and (4) of mode set A Means that the motion vector is non-zero. In the case of mode set A (4), it is necessary to separately encode the value of the motion vector. In the case of mode set A (3), it is not necessary to encode the motion vector. When mode set A is used when the probability that the motion vector is zero is high, the sum of the code amount of the mode and the code amount of the motion vector can be reduced.

この例において、“copy(動きベクトル==0)”として得られるブロックの全ての画素が例えば黒の場合、上記(2)と(3)はどちらのモードでも同じ再生画像が得られる。つまり、これら2つのモードを分ける必要はない。同様に、“copy(動きベクトル==0)”として得られるブロックの全ての画素が白の場合、上記(1)と(3)は分ける必要はない。そこで、
[モード集合B」
(1) “a11W”
(2) “a11B”
(3) “copy(動きベクトル!=0)”
(4) “coded”
として、
ステップA1:“copy(動きベクトル==0)″”とした時に得られる動き補償予測画像が全て黒である場合は、ステップA3へ、そうでない場合は、ステップA2へ進む。
In this example, when all the pixels of the block obtained as “copy (motion vector == 0)” are, for example, black, the same reproduced image can be obtained in both modes (2) and (3). That is, there is no need to separate these two modes. Similarly, when all the pixels of the block obtained as “copy (motion vector == 0)” are white, it is not necessary to separate (1) and (3). Therefore,
[Mode Set B]
(1) “a11W”
(2) “a11B”
(3) “copy (motion vector! = 0)”
(4) “coded”
As
Step A1: If the motion compensated prediction image obtained when “copy (motion vector == 0)” is all black, the process proceeds to step A3. Otherwise, the process proceeds to step A2.

ステップA2: “copy(動きベクトル==0)”とした時に得られる動き補償予測画像が全て白である場合は、ステップA4へ、そうでない場合は、ステップA5へ進む。   Step A2: If the motion compensated prediction image obtained when “copy (motion vector == 0)” is all white, the process proceeds to Step A4. Otherwise, the process proceeds to Step A5.

ステップA3: 参照する““M(*、*、*)”が、“copy(動きベクトル==0)”の場合には“M(*、*、*)”を““a11B”に置き換える。ステップA6に進む。   Step A3: If “M (*, *, *)” to be referred to is “copy (motion vector == 0)”, “M (*, *, *)” is replaced with “a11B”. Proceed to step A6.

ステップA4: 参照する“M(*、*、*)”が、“copy(動きベクトル==0)”の場合には“M(*、*、*)゛”を“a11W”に置き換える。ステップA6に進む。   Step A4: When “M (*, *, *)” to be referred to is “copy (motion vector == 0)”, “M (*, *, *)” is replaced with “a11W”. Proceed to step A6.

ステップA5: “M(x、y、n)”をモード集合Aの符号化テーブルを用いて符号化する。符号化終了。   Step A5: “M (x, y, n)” is encoded using the encoding table of mode set A. End of encoding.

ステップA6: “M(x、ysn)”をモード集合Aの符号化テーブルを用いて符号化する。符号化終了。   Step A6: “M (x, ysn)” is encoded using the encoding table of mode set A. End of encoding.

以上のA0からA6の手順を踏むアルゴリズム(図50)を用いれば、同じ結果となるものに複数のモードが用意されるという無駄が無くなり、ブロックの属性情報の符号量を削減できる。なぜなら、4つのモード(モード集合B)を切り替える符号の平均符号長は、5つのモード(モード集合A)を切り替える符号の平均符号長よりも短くできるからである。但し、モード集合Aのみをブロック毎に切り替える方式は、モード集合Aのみを用いる場合と比較して、演算量とメモリ量が多少増加するので、この増加が問題にならない場合に用いる。   By using the algorithm (FIG. 50) that takes the above steps A0 to A6, there is no waste that a plurality of modes are prepared for the same result, and the code amount of block attribute information can be reduced. This is because the average code length of a code that switches four modes (mode set B) can be shorter than the average code length of a code that switches five modes (mode set A). However, the method of switching only the mode set A on a block-by-block basis is used when the increase in the amount of calculation and memory increases slightly compared to the case of using only the mode set A, and this increase is not a problem.

復号化処理は図50のフローチャートと全く同じアルゴリズムで符号化テーブルをモード集合A用あるいはモード集合B用のいずれかに決定し、そのテーブルを用いて復号化する。   In the decoding process, the coding table is determined to be either for mode set A or mode set B with the same algorithm as in the flowchart of FIG. 50, and decoding is performed using that table.

上述のアルゴリズムと同じ効果が得られる別のアルゴリズムを図51に示す。ここで、
[モード集合C]
(1) “a11W”
(2) “copy(動きベクトル==0)”
(3) “copy(動きベクトル!=0)”
(4) “coded”
[モード集合D]
(1) “a11B”
(2) “copy(動きベクトル==0)”
(3) “copy(動きベクトル!=0)”
(4) “coded”
である。
FIG. 51 shows another algorithm that can obtain the same effect as the above-described algorithm. here,
[Mode Set C]
(1) “a11W”
(2) “copy (motion vector == 0)”
(3) “copy (motion vector! = 0)”
(4) “coded”
[Mode set D]
(1) “a11B”
(2) “copy (motion vector == 0)”
(3) “copy (motion vector! = 0)”
(4) “coded”
It is.

図51のフローチャートを説明する。   The flowchart of FIG. 51 will be described.

ステップB1:“copy(動きベクトル==0)”とした時に得られる動き補償予測画像が全て黒である場合は、ステップB3へ、そうでない場合は、ステップB2へ進む。   Step B1: If the motion compensated prediction image obtained when “copy (motion vector == 0)” is all black, the process proceeds to Step B3. Otherwise, the process proceeds to Step B2.

ステップB2:“copy(動きベクトル==0)”とした時に得られる動き補償予測画像が全て白である場合は、ステップB4へ、そうでない場合は、ステップB5へ進む。   Step B2: If the motion compensated prediction image obtained when “copy (motion vector == 0)” is all white, the process proceeds to Step B4. Otherwise, the process proceeds to Step B5.

ステップB3:参照する“M(*、*、*)””が、“allB”の場合には“M(*、*、*)”を“copy(動きベクトル==0)”に置き換える。ステップB6に進む。   Step B3: When “M (*, *, *)” to be referred to is “allB”, “M (*, *, *)” is replaced with “copy (motion vector == 0)”. Proceed to B6.

ステップB4:参照する“M(*、*、*)”が、“a11W”の場合には “M(*、*、*)”を““copy(動きベクトル==0)”に置き換える。stepb7に進む。   Step B4: When “M (*, *, *)” to be referred to is “a11W”, “M (*, *, *)” is replaced with ““ copy (motion vector == 0) ”. Proceed to

ステップB5:“M(x.y.n)”をモード集合Aの符号化テーブルを用いて符号化する。符号化終了。   Step B5: “M (x.y.n)” is encoded using the encoding table of mode set A. End of encoding.

ステップB6:“M(xsysn)”をモード集合Cの符号化テーブルを用いて符号化する。符号化終了。   Step B6: “M (xsysn)” is encoded using the encoding table of mode set C. End of encoding.

ステップB7:“M(x.y.n)”をモード集合Dの符号化テーブルを用いて符号化する。符号化終了。   Step B7: “M (x.y.n)” is encoded using the encoding table of the mode set D. End of encoding.

また、ブロックの属性としては、符号化のパラメータ、例えばブロックサイズやブロックの縮小率、符号化スキャンの方向、動きベクトルの値なども必要に応じて含めることもできる。スキャン方向を含めた例を示す。   As the block attributes, coding parameters such as block size, block reduction rate, coding scan direction, motion vector value, and the like can be included as necessary. An example including the scan direction is shown.

[モード集合E]
(1) “a11W”
(2) “a11B”
(3) “copy(動きベクトル==0)”
(4) “copy(動きベクトル!=0)”
(5) “codedかつ水平スキャン”
(6) “codedかつ垂直スキャン”
なお、“==”は左辺は右辺の値と等しい、“!=”は左辺は右辺の値と等しくないことを示す。
[Mode set E]
(1) “a11W”
(2) “a11B”
(3) “copy (motion vector == 0)”
(4) “copy (motion vector! = 0)”
(5) “Coded and horizontal scan”
(6) “Coded and vertical scan”
“==” indicates that the left side is equal to the value on the right side, and “! =” Indicates that the left side is not equal to the value on the right side.

以上、述べてきたように、本発明では、前のフレームの参照ブロックを予測に用いるのであるが、この参照ブロックのラベルではなく、アルファマップそのものを予測に用いても構わない。すなわち、アルファマップをメモリに記億しておき、各ブロックの属性を符号化する度に、その参照ブロックの属性(“allW”、“Multi”、“allB”など)を判定し、その属性によって符号化テーブルを切り替える。   As described above, in the present invention, the reference block of the previous frame is used for prediction. However, instead of the label of this reference block, the alpha map itself may be used for prediction. In other words, the alpha map is stored in the memory, and each time the attribute of each block is encoded, the attribute of the reference block (“allW”, “Multi”, “allB”, etc.) is determined, and Switch coding table.

このようにすると、前のフレームを符号化した時に用いたブロックとは、位置が数画素ずれたものも参照ブロックとすることができる。つまり、参照ブロックが前のフレームを符号化した時に用いたブロックとピッタリと重ならなくてもかまわなくなり、より精度の高い予測が可能となる。   In this way, the block used when the previous frame was encoded can be a reference block even if its position is shifted by several pixels. That is, the reference block does not have to overlap with the block used when the previous frame is encoded, and prediction with higher accuracy is possible.

また、参照ブロックのアルファマップを用いた予測と、ラベルを用いた予測を組み合わせることも可能である。
例えば、まず、参照ブロックのアルファマップを用いて、“allW”、“Multi”、“allB”によって符号化テーブルを切り替え、さらに、“Multi”のものについては、参照ブロックのラベルを用いて符号化テーブルを切り替えるようにする。
It is also possible to combine prediction using an alpha map of a reference block and prediction using a label.
For example, first, using the alpha map of the reference block, the encoding table is switched by “allW”, “Multi”, “allB”, and for “Multi”, encoding is performed using the reference block label. Switch between tables.

前のフレームの参照する部分については、ブロック毎に与えられる動きベクトルを利用する方法もある。つまり、既に符号化の終わった、符号化ブロックに隣接するマクロブロックの動きベクトルによって指し示される部分を前のフレームから切り出し、それが、“allW″か、“Multi”か、“allB”かによって符号化テーブルを切り替える。   There is also a method of using a motion vector given for each block for a part to be referred to in the previous frame. That is, the part indicated by the motion vector of the macroblock adjacent to the encoded block that has already been encoded is cut out from the previous frame, and whether it is “allW”, “Multi”, or “allB”. Switch coding table.

(第7の具体例)
本発明は画像を符号化する場合に、画面内を背景とオブジェクトとに分割して符号化する方式において、背景とオブジェクトを分けるために、オブジェクト形状や画面内の位置を表すアルファマップ信号を使用する。そして、このアルファマップ信号を画像の符号化情報と共に符号化してビットストリーム化し、伝送するようにしたり蓄積したりするが、前者は放送やパソコン通信に、そして、後者はミュージックCDなどのように、コンテンツを納めた商品として取り引きされることになる。
(Seventh specific example)
The present invention uses an alpha map signal representing an object shape and a position in a screen in order to separate the background and the object in the method of encoding the image by dividing the screen into a background and an object when encoding the image. To do. Then, this alpha map signal is encoded with the encoded information of the image and converted into a bit stream, which is transmitted and stored. The former is for broadcasting and personal computer communication, the latter is for music CD, etc. It will be traded as a product containing the content.

そして、商品として記憶媒体に記録した動画像コンテンツを提供する場合に、蓄積媒体に画像の符号化情報とこのアルファマップ信号の圧縮符号化したものとを合わせたビットストリームで蓄積して、一つの媒体で長時間に亘るコンテンツを納めて映画などを鑑賞できるようにするが、このようなアルファマップの画像を含む圧縮符号化したビットストリームを格納した蓄積媒体を対象とする再生システムの例を次に第7の具体例として説明する。   Then, when providing moving image content recorded as a product on a storage medium, a storage medium is stored as a bitstream that combines the encoded information of the image and the compression encoded version of the alpha map signal. An example of a playback system for a storage medium that stores a compression-encoded bitstream including an alpha map image, while allowing movies to be watched by storing content over a long period of time on the medium. This will be described as a seventh specific example.

<本発明による情報を蓄積する媒体に関する具体例>
図27、図28を用いて本具体例を説明する。図27は、図21のVLC・多重化回路1800において多重化された、モード情報b0、動きベクトル情報b1、縮小・拡大率情報b2、スキャン方向情報b3、2値画像符号化情報b4の符号列のフォーマット例を示している。本発明では、2値画像符号化情報b4を復号する際に、b0〜b3までの情報が復号されている必要がある。また、モード情報b0は他の全ての情報bl〜b4に先だって復号されていないと、他の情報を復号することは出来ない。従って、各情報b0〜b4は、図27のように、先頭にモード情報、最後に2値面像符号化情報が配置される構成でなければならない。
<Specific examples of a medium for storing information according to the present invention>
This specific example will be described with reference to FIGS. FIG. 27 shows code sequences of mode information b0, motion vector information b1, reduction / enlargement ratio information b2, scan direction information b3, and binary image encoding information b4 multiplexed in the VLC / multiplexing circuit 1800 of FIG. An example format is shown. In the present invention, when decoding the binary image encoded information b4, information from b0 to b3 needs to be decoded. Further, if the mode information b0 is not decoded prior to all other information bl to b4, the other information cannot be decoded. Therefore, each information b0 to b4 must have a configuration in which mode information is arranged at the beginning and binary plane image coding information is arranged at the end as shown in FIG.

図28は、図27で示される符号列が蓄積される記録媒体8100を用いて画像信号を再生するシステムを示す図である。記録媒体8100には、図27で示された符号列を含む符号列が蓄積されている。8200はこの蓄積媒体8100に蓄積されている符号列から、画像信号を再生するデコーダであり、8300は再生画像を出力する画像情報出力装置である。   FIG. 28 is a diagram showing a system for reproducing an image signal using the recording medium 8100 in which the code string shown in FIG. 27 is stored. The recording medium 8100 stores a code string including the code string shown in FIG. Reference numeral 8200 denotes a decoder for reproducing an image signal from a code string stored in the storage medium 8100, and 8300 is an image information output device for outputting a reproduced image.

このような構成の本システムは、蓄積媒体8100に図27に示す如きのフォーマットの符号列を蓄積してある。デコーダ8300はこの蓄積媒体8100に蓄積されている符号列から、画像信号を再生する。すなわち、デコーダ8200は、蓄積媒体8100より信号線8010を介して符号列を読み込み、図33および図34に示す手順により再生画像を生成する。ここで、図34は図33の“2値画像再生”のステップ(S5)のフローチャートである。   In this system having such a configuration, a code string having a format as shown in FIG. The decoder 8300 reproduces an image signal from the code string stored in the storage medium 8100. That is, the decoder 8200 reads a code string from the storage medium 8100 via the signal line 8010, and generates a reproduced image by the procedure shown in FIGS. FIG. 34 is a flowchart of the “binary image reproduction” step (S5) in FIG.

図33,図34に従って、デコーダ8200での処理を内容を説明する。すなわち、まずはじめにモード情報が復号され(ステップS1)、その復号されたモード情報が“allW”,“allB”,“copy”のいずれかに該当するか否かを調べる(ステップS2,S3,S4)。   The contents of the processing in the decoder 8200 will be described with reference to FIGS. That is, first, mode information is decoded (step S1), and it is checked whether or not the decoded mode information corresponds to any of “allW”, “allB”, and “copy” (steps S2, S3, S4). ).

その結果、“allW”であればマクロブロック内の画素値を全て白にして処理を終え(ステップS6)、また、“allW”でなく、“allB”であればマクロブロック内の画素値を全て黒にして処理を終え(ステップS7)、また、“allW”でもなく、“allB”でもなく、“copy”であったとすれば動きベクトルを情報を復号し(ステップS8)、動き補償予測し(ステップS9)、マクロブロック内をこの求めた動き補償予測値でコピーする(ステップS10)。そして、処理を終了する。   As a result, if “allW”, all the pixel values in the macroblock are set to white (step S6), and if “allW” is not “allW”, all the pixel values in the macroblock are all processed. The processing is finished in black (step S7), and if it is not “allW”, “allB”, or “copy”, the motion vector is decoded (step S8), and motion compensation prediction is performed (step S8). In step S9), the macro block is copied with the calculated motion compensation prediction value (step S10). Then, the process ends.

一方、ステップS2,S3,S4において“allW”でもなく、“allB”でもなく、“copy”でもなかった場合には2値画像再生の処理に移る(ステップS5)。   On the other hand, if it is not “allW”, “allB”, or “copy” in steps S2, S3, S4, the process proceeds to binary image reproduction processing (step S5).

このS5での処理は図34に示す如きであり、まずはじめに“inter”符号化であるか否かを調べる(ステップS21)。その結果、“inter”符号化であれば動きベクトル情報を復号し(ステップS25)、動き補償予測し(ステップS26)、次に縮小・拡大率情報を復号し(ステップS22)、スキャン方向情報を復号する(ステップS23)。そして、2値符号化情報を復号し(ステップS24)、処理を終了する。   The process in S5 is as shown in FIG. 34. First, it is checked whether or not the "inter" encoding is performed (step S21). As a result, if it is “inter” encoding, motion vector information is decoded (step S25), motion compensation prediction is performed (step S26), then reduction / enlargement ratio information is decoded (step S22), and scan direction information is obtained. Decoding is performed (step S23). Then, the binary encoded information is decoded (step S24), and the process ends.

一方、ステップS21での判断の結果、“inter”符号化でなかったときは縮小・拡大率情報を復号し(ステップS22)、スキャン方向情報を復号する(ステップS23)。そして、2値符号化情報を復号し(ステップS24)、処理を終了する。   On the other hand, if the result of determination in step S21 is not “inter” encoding, the reduction / enlargement ratio information is decoded (step S22), and the scan direction information is decoded (step S23). Then, the binary encoded information is decoded (step S24), and the process ends.

このようにしてデコーダ8200では画像を再生し、この再生した面像を信号線8020を介して画像情報出力装置8300に供給することにより、当該再生面像がこの画像情報出力装置8300に表示される。   In this way, the decoder 8200 reproduces an image, and supplies the reproduced plane image to the image information output device 8300 via the signal line 8020, whereby the reproduction plane image is displayed on the image information output device 8300. .

ここで、画像情報出力装置とは、例えばディスプレイやプリンタ等を指す。なお、先の具体例にあるように、フレーム単位の縮小・拡大と、小領域単位の縮小・拡大を組み合わせた符号化・復号化装置の場合、フレーム単位縮小・拡大率の情報は、図27に示される小領域単位の符号列に先だって再生されていなければならないため、フレーム単位縮小・拡大率の符号は該フレームにおける全ての小領域単位の符号列の前に位置する。   Here, the image information output device refers to, for example, a display or a printer. As in the previous specific example, in the case of an encoding / decoding device that combines reduction / enlargement in units of frames and reduction / enlargement in units of small areas, information on the reduction / enlargement ratio of frame units is shown in FIG. Therefore, the code of the frame unit reduction / enlargement ratio is positioned before the code sequence of all the small region units in the frame.

このように、蓄積媒体にコンテンツとしての動画像とアルファマップ信号とを、圧縮符号化してビットストリームとして格納した場合に、その蓄積媒体の再生システムを提供できる。   As described above, when a moving image and an alpha map signal as contents are compressed and encoded and stored as a bit stream in the storage medium, a playback system for the storage medium can be provided.

(第8の具体例)
動きベクトルの予測符号化に関する具体例を第8の具体例として説明する。
(Eighth specific example)
A specific example regarding motion vector predictive coding will be described as an eighth specific example.

図21、図22は、本発明のフレームワークを表す図である。図21において、動きベクトル検出回路1780で検出された動きベクトルは、信号線1070を介してMV符号化回路1790に供給され、符号化された後、VLC・多重化回路1800に供給され、他の符号化情報と多重化されて線30を介して出力される。   21 and 22 are diagrams showing the framework of the present invention. In FIG. 21, the motion vector detected by the motion vector detection circuit 1780 is supplied to the MV encoding circuit 1790 via the signal line 1070, encoded, and then supplied to the VLC / multiplexing circuit 1800. It is multiplexed with the encoded information and output via line 30.

図22において、VLD・分離化回路2100によって、信号線80を介して供給された符号化情報から分離された動きベクトル情報b1は、動きベクトル再生回路2900にて動きベクトル信号に再生される。   In FIG. 22, the motion vector information b 1 separated from the encoded information supplied via the signal line 80 by the VLD / separation circuit 2100 is reproduced as a motion vector signal by the motion vector reproduction circuit 2900.

本具体例は、上記のMV符号化回路1790および動きベクトル再生回路2900に関わるものである。   This specific example relates to the MV encoding circuit 1790 and the motion vector reproduction circuit 2900 described above.

一般的に、動きベクトル信号の相関が隣接ブロック間で強いため、この相関を除去するために予測符号化により動きベクトルは符号化される。   In general, since the correlation of a motion vector signal is strong between adjacent blocks, a motion vector is encoded by predictive encoding in order to remove this correlation.

図66は、動きベクトルの予測符号化の一例を説明するための図である。
図66において、方形の各枠はマクロブロックを示しており、下地がドットパターンで示された方形枠は、符号化対象ブロックである。この符号化対象ブロックの動きベクトルをMVsとすると、当該符号化対象ブロックのMVsに対する予測ベクトルMVPsを求めるには、当該符号化対象ブロックの直前のマクロブロック(図66における符号化対象ブロックの左隣)のブロックの動きベクトルMVs1と、当該符号化対象ブロックの直上のマクロブロック(図66における符号化対象ブロックの上隣)のブロックの動きベクトルMVs2、そして、当該直上のマクロブロックの右隣のブロックの動きベクトルMVsを用いる。
FIG. 66 is a diagram for explaining an example of motion vector predictive coding.
In FIG. 66, each square frame indicates a macroblock, and a square frame whose background is indicated by a dot pattern is a block to be encoded. If the motion vector of the encoding target block is MVs, the prediction vector MVPs for the MVs of the encoding target block can be obtained by the macroblock immediately before the encoding target block (next to the left of the encoding target block in FIG. 66). ), The motion vector MVs2 of the block immediately above the current block to be encoded (next to the top of the current block in FIG. 66), and the block immediately to the right of the immediately preceding macroblock Motion vectors MVs are used.

このように、符号化対象ブロックの動きベクトルMVsに対する予測ベクトルMVPsは、一般的に、符号化対象ブロック周辺のブロックの動きベクトルMVs1、MVs2、MVs3を用いて求められる。   As described above, the prediction vector MVPs for the motion vector MVs of the encoding target block is generally obtained using the motion vectors MVs1, MVs2, and MVs3 of the blocks around the encoding target block.

例えば、MVPsの水平・垂直成分MVPs_hおよびMVPs_vは、以下のように求められる。   For example, horizontal and vertical components MVPs_h and MVPs_v of MVPs are obtained as follows.

MVPs_h=Median(MVs1_h、MVs2_h、MVs3_h)
MVPs_v=Median(MVs1_v 、MVs2_v 、MVs3_v )
ここで、“Median()”とは“()”内の値の中央値を求める処理であり、動きベクトルMVsn(n=1,2,3)の水平・垂直成分をそれぞれ、
MVsn_h、MVsn_v
と表記している。
MVPs_h = Median (MVs1_h, MVs2_h, MVs3_h)
MVPs_v = Median (MVs1_v, MVs2_v, MVs3_v)
Here, “Median ()” is a process for obtaining the median of the values in “()”, and the horizontal and vertical components of the motion vector MVsn (n = 1, 2, 3) are respectively
MVsn_h, MVsn_v
It is written.

また、予測ベクトルMVPsを求める別の例として、MVs1、MVs2、MVs3の順にそれぞれのブロックに動きベクトルが存在するか否かをチェックし、最初に動きベクトルが存在するブロックの動きベクトルをMVPsとする方法もある。   As another example of obtaining the prediction vector MVPs, it is checked whether or not there is a motion vector in each block in the order of MVs1, MVs2, and MVs3, and the motion vector of the block in which the motion vector exists first is set as MVPs. There is also a method.

図67(a),(b)は、時刻n−1と時刻nにおけるフレーム画像Fn−1、Fnとそれぞれのフレームにおける符号化領域CAn−1、CAnの例である。ここで、符号化対象ブロック周辺のブロックがオブジェクトを含まないブロックの場合、そのブロックには動きベクトルが存在しない。また、フレーム内符号化されたブロックの場合にも、そのブロックには動きベクトルが存在しない。   FIGS. 67A and 67B are examples of frame images Fn−1 and Fn at time n−1 and time n and encoding regions CAn−1 and CAn in the respective frames. Here, when the block around the encoding target block is a block that does not include an object, there is no motion vector in the block. Also, in the case of a block that has been intra-coded, there is no motion vector in that block.

例えば、MVs1,MVs2,MVs3の全てが存在しない場合、予測ベクトルMVPsにはデフォルト値(ベクトル)を用いることになる。
オブジェクトの動きが小さい場合は、このデフォルト値を零なる動きベクトルである“ゼロベクトル”としても問題ないが、図67(a)のフレームから図67(b)のフレームへの遷移のように、フレーム内でのオブジェクトの位置の動きが大きい場合には、動きベクトルの予測が当たらなくなり、符号化効率が低下する。
For example, when all of MVs1, MVs2, and MVs3 do not exist, a default value (vector) is used as the prediction vector MVPs.
When the motion of the object is small, there is no problem even if this default value is set to “zero vector”, which is a motion vector that is zero, but as in the transition from the frame of FIG. 67 (a) to the frame of FIG. 67 (b), When the movement of the position of the object in the frame is large, the motion vector is not predicted and the encoding efficiency is lowered.

本発明ではこのデフォルト値として、図67(a)に示されたベクトル“prev_ref”と図67(b)に示されたベクトル“curr_ref”との差分ベクトル“offset”と、“ゼロベクトル”とを適応的に切り換えて用いることを特徴とする。   In the present invention, as this default value, the difference vector “offset” between the vector “prev_ref” shown in FIG. 67A and the vector “curr_ref” shown in FIG. It is characterized by being switched adaptively.

ここで、“offset”は以下の式で求められる。   Here, “offset” is obtained by the following equation.

offset=prev_ref−curr_ref
デフォルト値“offset”と“ゼロベクトル”の切り替えは、例えば、フレームの座標軸に基づいて求められた時刻nのオブジェクトと時刻n−1のオプジェクトの誤差値と、符号化領域の座標軸に基づいて求められた時刻n時点でのオブジェクトと時刻n−1時点でのオブジェクトの誤差値を比較して、前者が大きい場合は“offset”を、また、後者が大きい場合は“ゼロベクトル”を、デフォルト値として用いるようにすればよい。
offset = prev_ref-curr_ref
The switching between the default value “offset” and “zero vector” is obtained, for example, based on the error value of the object at time n and the object at time n−1 obtained based on the coordinate axis of the frame and the coordinate axis of the encoding area. When the error value of the object at time n and the object at time n−1 is compared, the default value is “offset” when the former is large, and “zero vector” when the latter is large. It may be used as.

この場合、切り替え情報として1ビットのサイド情報を送る必要がある。また、このような動きベクトルの予測値のデフォルト値として、“offset”と“ゼロベクトル”を切り替えることは、テクスチャ情報の動きベクトルの予測符号化にも同様に適用できる。   In this case, it is necessary to send 1-bit side information as switching information. In addition, switching between “offset” and “zero vector” as the default value of the predicted value of the motion vector can be similarly applied to the prediction coding of the motion vector of the texture information.

次に、図21に示したMV符号化回路1790の具体的構成例と、図22に示すMV再生回路2900の具体的構成例を、第9の具体例として説明する。   Next, a specific configuration example of the MV encoding circuit 1790 illustrated in FIG. 21 and a specific configuration example of the MV reproduction circuit 2900 illustrated in FIG. 22 will be described as a ninth specific example.

(第9の具体例)
[MV符号化回路1790の構成]
図68は、図21に示したシステムにおけるMV符号化回路1790及びその付帯回路の具体例を示すブロック図であり、(a)は付帯回路としてのデフォルト値演算回路、(b)はMV符号化回路1790である。
(Ninth example)
[Configuration of MV Encoding Circuit 1790]
68 is a block diagram showing a specific example of the MV encoding circuit 1790 and its auxiliary circuit in the system shown in FIG. 21, where (a) is a default value arithmetic circuit as an auxiliary circuit, and (b) is MV encoding. Circuit 1790.

図68(a)に示す付帯回路としてのデフォルト値演算回路は、オブジェクト領域について、現時点での処理フレームと、前時点での処理フレームとから、前時点から見た現時点でのフレームのオブジェクトの位置移動を、フレーム間での動きベクトル値として求めるためのものであり、図68(a)において、e10は符号化領域検出回路、e11はデフォルト値決定回路、e12は領域情報メモリ、e13はオフセット算出回路、e14はセレクタである。   The default value calculation circuit as an auxiliary circuit shown in FIG. 68A is the object position of the current frame as viewed from the previous time point from the current processing frame and the previous processing frame for the object area. The movement is obtained as a motion vector value between frames. In FIG. 68 (a), e10 is an encoding area detection circuit, e11 is a default value determination circuit, e12 is an area information memory, and e13 is an offset calculation. A circuit, e14, is a selector.

また、e1は現時点でのフレームデータを入力するための信号線であり、図21におけるシステムの信号線20に該当するもので、当該信号線20から入力される現時点のフレームデータを入力として受けるためのものである。また、図68(a)におけるe2は、フレームメモリ1300に保持された前時点フレームデータを供給するための信号線であり、この信号線e2を介して、フレームメモリ1300から前時点のフレームデータの供給を受ける。また、e3はデフォルト値決定回路e11からのフラグの情報を出力する信号線であり、e4は符号化領域検出回路e10からの符号化領域CAnの情報を供給する信号線であり、e6は領域情報メモリe12から読み出される符号化領域CAn−1の位置情報を供給する信号線である。   Further, e1 is a signal line for inputting the current frame data and corresponds to the signal line 20 of the system in FIG. 21, and receives the current frame data input from the signal line 20 as an input. belongs to. Further, e2 in FIG. 68A is a signal line for supplying the previous time point frame data held in the frame memory 1300, and the frame data of the previous time point is sent from the frame memory 1300 via this signal line e2. Receive supply. Further, e3 is a signal line for outputting flag information from the default value determination circuit e11, e4 is a signal line for supplying information on the coding area CAn from the coding area detection circuit e10, and e6 is area information. This is a signal line for supplying position information of the coding area CAn-1 read from the memory e12.

また、前記符号化領域検出回路e10は、信号線e1を介して供給される現時点フレームFn−1の画像信号をもとに、符号化領域CAnのサイズおよび位置情報VC0 を検出するものであり、その検出結果は信号線e4を介して、デフォルト値決定回路e11、領域情報メモリe12およびオフセット算出回路e13に供給するようにしてある。   The coding area detection circuit e10 detects the size and position information VC0 of the coding area CAn based on the image signal of the current frame Fn-1 supplied via the signal line e1. The detection result is supplied to the default value determination circuit e11, the area information memory e12, and the offset calculation circuit e13 via the signal line e4.

また、領域情報メモリe12は、符号化領域CAn−1のサイズおよび位置の情報を蓄積するメモリであり、時刻nの時点でのフレームの符号化が終了後、符号化領域CAnのサイズおよび位置情報を蓄積することになる。   The area information memory e12 is a memory for accumulating the size and position information of the coding area CAn-1, and after the encoding of the frame at time n is completed, the size and position information of the coding area CAn. Will be accumulated.

オフセット算出回路e13は、信号線e4を介して供給される符号化領域CAnと、信号線e6を介して供給される符号化領域CAn−1の位置情報を用いて、ベクトル値“offset”を求め、それをセレクタe14に与えるものである。   The offset calculation circuit e13 obtains the vector value “offset” using the position information of the coding area CAn supplied via the signal line e4 and the coding area CAn−1 supplied via the signal line e6. , It is given to the selector e14.

また、セレクタe14は、零の動きベクトル値である“ゼロベクトル”とオフセット算出回路e13から与えられる“offset”とを入力とし、これらのいずれか一方を信号線e3を介してデフォルト値決定回路e11から供給されるフラグに従って選択する回路であり、このセレクタe14の選択したベクトル値をデフォルト値として信号線e5を介してMV符号化回路1790のセレクタ1793に出力する回路である。   Further, the selector e14 receives “zero vector” which is a zero motion vector value and “offset” given from the offset calculation circuit e13, and either one of them is set as a default value determination circuit e11 via the signal line e3. Is a circuit that selects the vector value selected by the selector e14 as a default value to the selector 1793 of the MV encoding circuit 1790 via the signal line e5.

以上が、デフォルト値演算回路の構成である。
次に、MV符号化回路1790の構成を説明する。
The above is the configuration of the default value arithmetic circuit.
Next, the configuration of the MV encoding circuit 1790 will be described.

MV符号化回路1790は、図68(b)に示すように、MVメモリ1791、MV予測回路1792、セレクタ1793、差分回路1794より構成される。   As shown in FIG. 68B, the MV encoding circuit 1790 includes an MV memory 1791, an MV prediction circuit 1792, a selector 1793, and a difference circuit 1794.

これらのうち、MVメモリ1791は図21における信号線1070を介して供給される動きベクトル検出回路1780からの動きベクトル情報を保存するメモリであり、符号化対象ブロックの周囲の動きベクトルMVsn(n−1,2,3)がこのMVメモリ1790に保持される。   Among these, the MV memory 1791 is a memory for storing the motion vector information from the motion vector detection circuit 1780 supplied via the signal line 1070 in FIG. 21, and the motion vector MVsn (n−) around the encoding target block. 1, 2, 3) are held in the MV memory 1790.

MV予測回路1792は、MVメモリ1791から供給される符号化対象ブロックの周囲の動きベクトルMVsn(n−1,2,3)をもとに、予測ベクトルMVPsを求める回路である。ここで、MVsn(n−1,2,3)が存在しない場合は、予測ベクトルMVPsが正常に求められないため、当該MV予測回路1792は、予測ベクトルMVPsが正常に求められたか否かを識別する信号を出力する機能を備えており、この識別信号を信号線1795を介してセレクタ1793に供給する仕組みとしてある。   The MV prediction circuit 1792 is a circuit for obtaining a prediction vector MVPs based on the motion vector MVsn (n−1, 2, 3) around the encoding target block supplied from the MV memory 1791. Here, when MVsn (n-1, 2, 3) does not exist, the prediction vector MVPs is not normally obtained, and therefore the MV prediction circuit 1792 identifies whether or not the prediction vector MVPs has been normally obtained. The identification signal is supplied to the selector 1793 through the signal line 1795.

セレクタ1793は、MV予測回路1792より供給されるMVPsと、信号線e5を介して与えられるデフォルト値とを入力とし、前記信号線1795を介して供給される信号に従って、両者のうちの一方を選択して、差分回路1794に供給するものである。   The selector 1793 receives the MVPs supplied from the MV prediction circuit 1792 and the default value given via the signal line e5, and selects one of them according to the signal supplied via the signal line 1795. Then, it is supplied to the difference circuit 1794.

差分回路1794は、動きベクトルの予測誤差信号を求める回路であって、信号線1070を介して供給される動きベクトル検出回路1780からの動きベクトル情報と、セレクタ1793を介して与えられるMVPsまたはデフォルト値との差を求めて、その結果を動きベクトル情報b1としてMV符号化回路1790から出力するものである。   The difference circuit 1794 is a circuit for obtaining a motion vector prediction error signal. The difference circuit 1794 receives the motion vector information from the motion vector detection circuit 1780 supplied via the signal line 1070 and the MVPs or default value supplied via the selector 1793. And the result is output from the MV encoding circuit 1790 as motion vector information b1.

次にこのような構成の符号化回路の作用を説明する。
図68(a)において、信号線e1にはフレームメモリ1300に保存された前時点での画像信号(前時点でのフレームのフレームデータ)であるフレームFnの画像信号が供給され、信号線e2には現時点での画像信号(現時点でのフレームのフレームデータ)であるフレームFn−1の画像信号が供給される。
Next, the operation of the coding circuit having such a configuration will be described.
In FIG. 68A, the image signal of the frame Fn which is the image signal at the previous time point (frame data of the frame at the previous time point) stored in the frame memory 1300 is supplied to the signal line e1, and the signal line e2 is supplied to the signal line e2. Is supplied with the image signal of the frame Fn−1, which is the current image signal (frame data of the current frame).

そして、フレームFnの画像信号はデフォルト値決定回路e11に入力され、フレームFn−1の画像信号はデフォルト値決定回路e11と符号化領域検出回路e10に入力される。   Then, the image signal of the frame Fn is input to the default value determining circuit e11, and the image signal of the frame Fn-1 is input to the default value determining circuit e11 and the coding area detecting circuit e10.

符号化領域検出回路e10では、フレームFn−1の画像信号をもとに、符号化領域CAnのサイズおよび位置情報VC0 が検出され、その検出結果は信号線e4を介して、デフォルト値決定回路e11、領域情報メモリe12およびオフセット算出回路e13に供給される。   In the coding area detection circuit e10, the size and position information VC0 of the coding area CAn is detected based on the image signal of the frame Fn-1, and the detection result is a default value determination circuit e11 via the signal line e4. Are supplied to the area information memory e12 and the offset calculation circuit e13.

一方、デフォルト値決定回路e11では、信号線e4を介して供給される符号化領域検出回路e10からの符号化領域CAnの情報と、信号線e6を介して領域情報メモリe12から供給される符号化領域CAn−1のサイズおよび位置情報を用いて、フレームFnとフレームFn−1との誤差量と、符号化領域CAnとCAn−1との誤差量との比較を行う。そして、その比較の結果、前者が大きい場合にはデフォルト値として“offset”を用い、それ以外の場合はデフォルト値としてゼロベクトルを用いるように決定し、デフォルト値として“offset”を用いるか、ゼロベクトルを用いるか、を識別するフラグの情報を信号線e3を介して出力する。   On the other hand, in the default value determination circuit e11, the information on the encoding area CAn from the encoding area detection circuit e10 supplied via the signal line e4 and the encoding supplied from the area information memory e12 via the signal line e6. Using the size and position information of region CAn-1, the error amount between frame Fn and frame Fn-1 is compared with the error amount between coding regions CAn and CAn-1. Then, as a result of the comparison, if the former is large, it is decided to use “offset” as the default value, otherwise use the zero vector as the default value, and use “offset” as the default value, or zero Information on a flag for identifying whether to use a vector is output via a signal line e3.

信号線e3を介してデフォルト値決定回路e11から出力されたフラグの情報は、信号線e4を介して符号化領域検出回路e10から出力された符号化領域CAnのサイズおよび位置の情報と共に、図47のデータフォーマットにおける符号化領域のレイヤに多重化される。そして、伝送あるいは記録媒体への保存に供される。   The flag information output from the default value determination circuit e11 via the signal line e3 is shown in FIG. 47 together with the size and position information of the coding area CAn output from the coding area detection circuit e10 via the signal line e4. Are multiplexed in the layer of the coding area in the data format. Then, it is used for transmission or storage in a recording medium.

一方、領域情報メモリe12は、符号化領域CAn−1のサイズおよび位置情報を蓄積するメモリであり、時刻nの符号化が終了後、符号化領域CAnのサイズおよび位置情報を蓄積することになる。   On the other hand, the area information memory e12 is a memory for storing the size and position information of the coding area CAn-1, and after the encoding at time n is completed, the size and position information of the coding area CAn is stored. .

オフセット算出回路e13では、信号線e4を介して供給される符号化領域CAnと、信号線e6を介して供給される符号化領域CAn−1の位置情報を用いて、ベクトル値“offset”を求めた後、セレクタe14に供給する。   The offset calculation circuit e13 obtains the vector value “offset” using the position information of the coding area CAn supplied via the signal line e4 and the coding area CAn−1 supplied via the signal line e6. Is supplied to the selector e14.

セレクタe14では、信号線e3を介してデフォルト値決定回路e11から供給されるフラグに従って、“offset”とゼロベクトルとの何れかが選択され、これをデフォルト値とする。そして、このデフォルト値は信号線e5を介してMV符号化回路1790のセレクタ1793に出力される。   In the selector e14, either “offset” or zero vector is selected according to the flag supplied from the default value determination circuit e11 via the signal line e3, and this is set as the default value. This default value is output to the selector 1793 of the MV encoding circuit 1790 via the signal line e5.

図68(b)のMV符号化回路1790には、符号化対象ブロックの動きベクトルMVsが信号線1070を介して供給され、MVメモリ1791および差分回路1794に供給される。   The motion vector MVs of the block to be encoded is supplied to the MV encoding circuit 1790 in FIG. 68B via the signal line 1070 and is supplied to the MV memory 1791 and the difference circuit 1794.

MV予測回路1792には、MVメモリ1791から符号化対象ブロックの周囲の動きベクトルMVsn(n−1,2,3)が供給され、予測ベクトルMVPsが求められる。ここで、MVsn(n−1,2,3)が存在しない場合は、予測ベクトルMVPsが正常に求められないため、予測ベクトルMVPsが正常に求められたか否かを識別する信号を生成してこれを信号線1795を介し、セレクタ1793に供給する。   The MV prediction circuit 1792 is supplied with the motion vector MVsn (n−1, 2, 3) around the encoding target block from the MV memory 1791, and the prediction vector MVPs is obtained. Here, when MVsn (n-1, 2, 3) does not exist, the prediction vector MVPs is not normally obtained. Therefore, a signal for identifying whether or not the prediction vector MVPs has been normally obtained is generated. Is supplied to the selector 1793 through the signal line 1795.

セレクタ1793では、信号線1795を介して供給される識別信号に従って、MV予測回路1792より供給されるMVPsか、または、信号線e5の出力であるデフォルト値かが選択され、差分回路1794に供給される。   The selector 1793 selects MVPs supplied from the MV prediction circuit 1792 or a default value output from the signal line e5 in accordance with the identification signal supplied via the signal line 1795, and supplies the selected value to the difference circuit 1794. The

差分回路1794では、動きベクトルの予測誤差信号が計算され、その計算結果は動きベクトル情報b1としてMV符号化回路1790から出力される。   The difference circuit 1794 calculates a motion vector prediction error signal, and the calculation result is output from the MV encoding circuit 1790 as motion vector information b1.

以上は動きベクトル符号化の処理内容であった。次にこのようにして符号化された動きベクトルの復号化処理について説明する。   The above is the processing content of motion vector encoding. Next, the decoding process of the motion vector encoded in this way will be described.

[復号化回路]
図69は、本発明を実現するための復号化回路の具体例を示すブロック図であり、MV符号化されたデータの再生をするための要部構成を示したブロック図であって、図22に示したシステムにおけるMV再生回路2900及びその付帯回路の具体例を示すブロック図である。図69における(a)は付帯回路としてのデフォルト値演算回路、(b)はMV再生回路2900である。
[Decoding circuit]
69 is a block diagram showing a specific example of a decoding circuit for realizing the present invention, and is a block diagram showing a main configuration for reproducing MV-encoded data. It is a block diagram which shows the specific example of the MV reproduction | regeneration circuit 2900 and its incidental circuit in the system shown in FIG. In FIG. 69, (a) is a default value arithmetic circuit as an auxiliary circuit, and (b) is an MV reproduction circuit 2900.

図69(a)に示す付帯回路としてのデフォルト値演算回路は、領域情報メモリd10、オフセット算出回路d11、セレクタd12とから構成される。また、d1は符号化されて伝送されてきたデータあるいは記憶媒体に記憶されて読み出されたデータの上位レイヤに含まれているデフォルト値選択識別用のフラグの情報を与える信号線、d2は符号化されて伝送されてきたデータの上位レイヤに含まれている領域CAnの位置情報を与える信号線であり、これらは符号化回路側におけるe3,e4に対応する。   The default value arithmetic circuit as an auxiliary circuit shown in FIG. 69 (a) includes an area information memory d10, an offset calculation circuit d11, and a selector d12. Further, d1 is a signal line for giving information on a flag for identifying a default value selection included in an upper layer of encoded data transmitted or stored in a storage medium and read out, and d2 is a code. These are signal lines that give position information of the area CAn included in the upper layer of the data that has been converted and transmitted, and these correspond to e3 and e4 on the encoding circuit side.

また、d3は領域CAn−1の位置情報を与える信号線、d4はデフォルト値を出力する信号線である。   Further, d3 is a signal line that gives position information of the area CAn-1, and d4 is a signal line that outputs a default value.

上記領域情報メモリd10は、領域CAn−1の位置情報を蓄積するメモリであり、オフセット算出回路d11は、信号線d2を介して供給される領域CAnの位置情報と、信号線d3を介して供給される領域CAn−1の位置情報とを用いてベクトル値“offset”を求めるものであって、この求めたベクトル値“offset”はセレクタd12に供給する構成としてある。   The area information memory d10 is a memory for accumulating position information of the area CAn-1, and the offset calculation circuit d11 is supplied via the position information of the area CAn supplied via the signal line d2 and the signal line d3. The vector value “offset” is obtained using the position information of the area CAn−1, and the obtained vector value “offset” is supplied to the selector d12.

また、セレクタd12は予め与えられた零の動きベクトル値と、オフセット算出回路d11から与えられるベクトル値“offset”とのうちの一方を、信号線e1を介して与えられるデフォルト値選択識別用のフラグの情報対応に選択して出力するものであり、このセレクタd12の出力がデフォルト値として信号線d4に出力され、MV再生回路2900に与えられる構成である。   In addition, the selector d12 uses one of the zero motion vector value given in advance and the vector value “offset” given from the offset calculation circuit d11 as a default value selection identification flag given via the signal line e1. The output of the selector d12 is output to the signal line d4 as a default value and is supplied to the MV reproduction circuit 2900.

以上が復号側におけるデフォルト値演算回路の構成である。
次にMV再生回路2900の構成を説明する。
The above is the configuration of the default value arithmetic circuit on the decoding side.
Next, the configuration of the MV playback circuit 2900 will be described.

MV再生回路2900は、図69(b)に示すように、加算回路2901、セレクタ2902、MV予測回路2903、MVメモリ2904とからなる。
これらのうち、加算回路2901は、復号化対象ブロックの動きベクトルの予測誤差信号である動きベクトル情報b1とセレクタ2902を介して与えられるデフォルト値とを受けて、両者を加算して出力する回路であり、この加算出力はMVメモリ2904並びに図22の構成における信号線2030に出力される構成である。
As shown in FIG. 69B, the MV reproduction circuit 2900 includes an adder circuit 2901, a selector 2902, an MV prediction circuit 2903, and an MV memory 2904.
Among these, the addition circuit 2901 is a circuit that receives the motion vector information b1 which is a prediction error signal of the motion vector of the decoding target block and the default value given through the selector 2902, and adds and outputs them. The added output is output to the MV memory 2904 and the signal line 2030 in the configuration of FIG.

また、MVメモリ2904は、前記加算回路2910の加算出力を保持して復号化対象ブロックの周囲の動きベクトルMVsn(n=1,2,3)を供給するためのものであり、また、MV予測回路2903は、MVメモリ2904から供給される復号化対象ブロックの周囲の動きベクトルMVsn(n=1,2,3)から予測ベクトルMVPsを求め、セレクタ2902に与えるものである。なお、MVsn(n=1,2,3)が存在しない場合は、予測ベクトルMVPsが正常に求められないため、MV予測回路2903には、予測ベクトルMVPsが正常に求められたか否かを識別する信号を発生する機能を持たせてあり、この識別信号は、信号線2905を介してセレクタ2902に供給する構成としてある。   The MV memory 2904 is for holding the addition output of the addition circuit 2910 and supplying a motion vector MVsn (n = 1, 2, 3) around the block to be decoded. The circuit 2903 obtains a prediction vector MVPs from the motion vectors MVsn (n = 1, 2, 3) around the decoding target block supplied from the MV memory 2904 and supplies the prediction vector MVPs to the selector 2902. When MVsn (n = 1, 2, 3) does not exist, the prediction vector MVPs is not normally obtained, so the MV prediction circuit 2903 identifies whether or not the prediction vector MVPs has been normally obtained. A function for generating a signal is provided, and this identification signal is supplied to the selector 2902 through a signal line 2905.

セレクタ2902は、信号線e4を介して与えられるデフォルト値と、MV予測回路2903から与えられる予測ベクトルMVPsを入力とし、これらの一方を、信号線2905を介して供給される識別信号に従って、選択して加算回路2901に与える回路である。   The selector 2902 receives the default value given via the signal line e4 and the prediction vector MVPs given from the MV prediction circuit 2903, and selects one of them according to the identification signal supplied via the signal line 2905. This is a circuit to be given to the adding circuit 2901.

次に、このような構成の復号化側システムの作用を説明する。
図69(a)において、信号線d1にはデフォルト値として“offset”を用いるか、ゼロベクトルを用いるかを識別するフラグが供給され、信号線d2には領域CAnの位置情報が供給される。
Next, the operation of the decoding side system having such a configuration will be described.
In FIG. 69A, a flag for identifying whether “offset” or zero vector is used as a default value is supplied to the signal line d1, and position information of the region CAn is supplied to the signal line d2.

信号線d2を介して供給された領域CAnの位置情報は、領域情報メモリd10とオフセット算出回路d11に供給される。領域情報メモリd10は、領域CAn−1の位置情報を蓄積するメモリであり、時刻nの復号化が終了後、領域CAnの位置情報を蓄積することになる。   The position information of the area CAn supplied via the signal line d2 is supplied to the area information memory d10 and the offset calculation circuit d11. The area information memory d10 is a memory that accumulates position information of the area CAn-1, and accumulates position information of the area CAn after decoding at time n.

オフセット算出回路d11では、信号線d2を介して供給される領域CAnの位置情報と、信号線d3を介して供給される領域CAn−1の位置情報とを用いてベクトル値“offset”を求めた後、ベクトル値“offset”をセレクタd12に供給する。   In the offset calculation circuit d11, the vector value “offset” is obtained using the position information of the area CAn supplied via the signal line d2 and the position information of the area CAn−1 supplied via the signal line d3. Thereafter, the vector value “offset” is supplied to the selector d12.

セレクタe12では、信号線d1を介して供給されるフラグに従って、“offset”と“ゼロベクトル”のうちの何れか一方が選択され、デフォルト値として信号線e4を介してMV再生回路2900へと出力する。   In the selector e12, either “offset” or “zero vector” is selected in accordance with the flag supplied via the signal line d1, and the default value is output to the MV regeneration circuit 2900 via the signal line e4. To do.

次に図69(b)のMV再生回路2900においては、復号化対象ブロックの動きベクトルの予測誤差信号である“動きベクトル情報b1”が供給され、加算回路2901に供給される。   Next, in the MV reproduction circuit 2900 of FIG. 69B, “motion vector information b1”, which is a prediction error signal of the motion vector of the decoding target block, is supplied to the addition circuit 2901.

また、MV予測回路2903には、MVメモリ2904から復号化対象ブロックの周囲の動きベクトルMVsn(n=1,2,3)が供給され、予測ベクトルMVPsが求められる。ここで、MVsn(n=1,2,3)が存在しない場合は、予測ベクトルMVPsが正常に求められないため、予測ベクトルMVPsが正常に求められたか否かを識別する信号を信号線2905を介してセレクタ2902に供給する。   Also, the motion vector MVsn (n = 1, 2, 3) around the decoding target block is supplied from the MV memory 2904 to the MV prediction circuit 2903, and the prediction vector MVPs is obtained. Here, when MVsn (n = 1, 2, 3) does not exist, the prediction vector MVPs is not normally obtained. Therefore, a signal for identifying whether or not the prediction vector MVPs has been normally obtained is displayed on the signal line 2905. To the selector 2902.

セレクタ2902では、信号線2905を介して供給される当該識別信号に従って、MV予測回路2903より供給されるMVPsか、または信号線d4の出力であるデフォルト値のいずれかが選択され、加算回路2901に供給される。   The selector 2902 selects either MVPs supplied from the MV prediction circuit 2903 or a default value output from the signal line d4 in accordance with the identification signal supplied via the signal line 2905, and sends it to the adder circuit 2901. Supplied.

加算回路2901では、動きベクトルの予測誤差信号(“動きベクトル情報b1”)と予測信号MVPsとが加算され、これによって復号化対象ブロックの動きベクトルMVsが再生される。そして、この復号化対象ブロックの動きベクトルMVsは信号線2030を介してMV再生回路2900から出力されると共に、MVメモリ2904に蓄積される。   The addition circuit 2901 adds the motion vector prediction error signal (“motion vector information b1”) and the prediction signal MVPs, thereby reproducing the motion vector MVs of the decoding target block. The motion vector MVs of the block to be decoded is output from the MV playback circuit 2900 via the signal line 2030 and stored in the MV memory 2904.

このようにして、図21に示す構成での必要なMV符号化処理と、図22に示す構成での必要なMV再生処理が実現できる。   In this manner, the necessary MV encoding process with the configuration shown in FIG. 21 and the necessary MV reproduction process with the configuration shown in FIG. 22 can be realized.

以上、種々の実施例を説明したが、本発明によれば、オブジェクトの形状や画面内の位置などを表す副画像情報であるアルファマップの情報を効率よく符号化できると共に、その復号を行うことができるようにした画像符号化装置および復号化装置が得られる。   Although various embodiments have been described above, according to the present invention, it is possible to efficiently encode and decode the alpha map information, which is sub-image information representing the shape of the object, the position in the screen, and the like. Thus, an image encoding device and a decoding device that can perform the above are obtained.

また、本発明によれば、アルファマップの符号量を低減することができるため、フレーム単位で符号化する従来の符号化法と比べて、大幅な符号化効率の低下なしにオブジェクト毎に別々に符号化することができるようになる。   In addition, according to the present invention, since the amount of alpha map code can be reduced, it is possible to separate each object separately without significant reduction in coding efficiency as compared with the conventional coding method in which coding is performed in units of frames. It becomes possible to encode.

なお、本発明は上述した具体例に限定することなく種々変形して実施し得る。   The present invention is not limited to the specific examples described above, and can be implemented with various modifications.

本発明を適用する前提となる符号化装置の全体の概略的な構成を示すブロック図。1 is a block diagram showing an overall schematic configuration of an encoding apparatus as a premise to which the present invention is applied. 本発明を適用する前提となる復号化装置の全体の概略的な構成を示すブロック図。The block diagram which shows the schematic structure of the whole decoding apparatus used as the premise to which this invention is applied. 本発明を適用する前提となる符号化装置におけるアルファマップ符号化回路の構成を示すブロック図。The block diagram which shows the structure of the alpha map encoding circuit in the encoding apparatus used as the premise to which this invention is applied. 本発明を適用する前提となるアルファマップ復号化回路の構成を示すブロック図。The block diagram which shows the structure of the alpha map decoding circuit used as the premise to which this invention is applied. 本発明の第1の具体例にかかる符号化回路の一具体例を示すブロック図。The block diagram which shows one specific example of the encoding circuit concerning the 1st specific example of this invention. 本発明の第1の具体例にかかる復号化回路の一具体例を示すブロック図。The block diagram which shows one specific example of the decoding circuit concerning the 1st specific example of this invention. 本発明の第1の具体例を説明するための図であって、変化画素b1の周囲の様子の例を示す図。It is a figure for demonstrating the 1st specific example of this invention, Comprising: The figure which shows the example of the mode around the change pixel b1. 本発明の第1の具体例を説明するための図であって、参照画素の例を示す図。It is a figure for demonstrating the 1st specific example of this invention, Comprising: The figure which shows the example of a reference pixel. 本発明の第1の具体例を説明するための図であって、コンテキスト番号の決定方法を説明するための図。It is a figure for demonstrating the 1st specific example of this invention, Comprising: The figure for demonstrating the determination method of a context number. 本発明の第2の具体例にかかる符号化回路例を示すブロック図。The block diagram which shows the example of an encoding circuit concerning the 2nd specific example of this invention. 本発明の第2の具体例にかかる復号化回路の具体例を示すブロック図。The block diagram which shows the specific example of the decoding circuit concerning the 2nd specific example of this invention. 本発明の第3の具体例にかかる符号化回路の具体例を示すブロック図。The block diagram which shows the specific example of the encoding circuit concerning the 3rd specific example of this invention. 本発明の第3の具体例にかかる復号化回路の具体例を示すブロック図。The block diagram which shows the specific example of the decoding circuit concerning the 3rd specific example of this invention. 本発明の第3の具体例を説明するための図であって、フレーム間符号化における変化画素の検出手段を説明する図。It is a figure for demonstrating the 3rd example of this invention, Comprising: The figure explaining the detection means of the change pixel in inter-frame coding. スキャン方向切り替えを説明する図。The figure explaining scan direction switching. アルファマップを説明する図。The figure explaining an alpha map. 先行技術を説明するための図であって、VLCテーブル(可変長符号化テーブル)の例を示す図。It is a figure for demonstrating a prior art, Comprising: The figure which shows the example of a VLC table (variable length encoding table). 先行技術を説明するための図であって、ブロック単位で符号化する場合の変化画素の関係を表す図およびb1を検出する為の参照領域を表す図(ブロックベース符号化の変化画素の関係と参照領域を表す図)。It is a figure for demonstrating a prior art, Comprising: The figure showing the relationship of the change pixel at the time of encoding in a block unit, and the figure showing the reference area for detecting b1 (the relationship of the change pixel of block-based encoding) A diagram showing a reference area). 先行技術を説明するための図であって、MMRをブロックベースで符号化する場合のフローチャート。It is a figure for demonstrating a prior art, Comprising: The flowchart in the case of encoding MMR on a block basis. 本発明で用いるアルファマップの画面内を所定の複数画素構成によるマクロブロック(MB)単位に分割した様子を示す図。The figure which shows a mode that the screen of the alpha map used by this invention was divided | segmented into the macroblock (MB) unit by predetermined multiple pixel structure. 本発明の第4の具体例におけるアルファマップ符号化回路の構成例を示すブロック図。The block diagram which shows the structural example of the alpha map encoding circuit in the 4th example of this invention. 本発明の第4の具体例におけるアルファマップ復号化回路の構成例を示すブロック図。The block diagram which shows the structural example of the alpha map decoding circuit in the 4th example of this invention. マルコフモデル符号化を説明するための図。The figure for demonstrating Markov model encoding. 複数の2値面像符号化法を切り換えて使用する2値画像符号化回路および2値画像復号化回路の構成例を示すブロック図。The block diagram which shows the structural example of the binary image encoding circuit and binary image decoding circuit which switch and use several binary surface image encoding methods. 本発明の第5の具体例におけるフレーム単位の縮小・拡大と、小領域単位の縮小・拡大を組み合わせたアルファマップ符号化回路の構成を示すブロツク図。The block diagram which shows the structure of the alpha map encoding circuit which combined reduction / enlargement of the frame unit and reduction / enlargement of the small area unit in the 5th example of this invention. 本発明の第5の具体例におけるフレーム単位の縮小・拡大と、小領域単位の縮小・拡大を組み合わせたアルファマップ復号化回路の構成を示すブロック図。The block diagram which shows the structure of the alpha map decoding circuit which combined reduction / enlargement of the frame unit and reduction / enlargement of the small area unit in the 5th example of this invention. 本発明のアルファマップ符号化回路から出力されるビット列の並び順を説明する図。The figure explaining the arrangement | sequence order of the bit sequence output from the alpha map encoding circuit of this invention. 本発明の第6の具体例のシステム構成例を示すブロック図。The block diagram which shows the system structural example of the 6th specific example of this invention. 本発明の第6の具体例における先行技術の説明をするための図。The figure for demonstrating the prior art in the 6th specific example of this invention. 本発明の第6の具体例における先行技術の説明をするための図。The figure for demonstrating the prior art in the 6th specific example of this invention. 本発明の第6の具体例における先行技術の説明をするための図。The figure for demonstrating the prior art in the 6th specific example of this invention. 本発明の第6の具体例における先行技術の説明をするための図。The figure for demonstrating the prior art in the 6th specific example of this invention. 本発明の第6の具体例における処理手順を説明をするためのフローチャート。The flowchart for demonstrating the process sequence in the 6th specific example of this invention. 本発明の第6の具体例における処理手順を説明をするためのフローチャート。The flowchart for demonstrating the process sequence in the 6th specific example of this invention. 縮小・拡大処理に利用する双一次内挿を説明するための図。The figure for demonstrating the bilinear interpolation utilized for a reduction / enlargement process. スムーシング処理(平滑化処理)を説明するための図。The figure for demonstrating a smoothing process (smoothing process). 本発明で用いるスムーシングフィルタ(平滑化処理フィルタ)の別の例を説明するための図。The figure for demonstrating another example of the smoothing filter (smoothing process filter) used by this invention. ブロック(マクロブロック)を縦横“1/2”のサイズに縮小する縮小処理の一例を説明するための図。The figure for demonstrating an example of the reduction process which reduces a block (macroblock) to the size of length and width "1/2". 縮小ブロックの画素値を求める手法の例を説明するための図。The figure for demonstrating the example of the method of calculating | requiring the pixel value of a reduction | decrease block. 画素間引きによる縮小処理の例を説明するための図。The figure for demonstrating the example of the reduction process by pixel thinning. 本発明で用いる拡大処理の例を説明するための図。The figure for demonstrating the example of the expansion process used by this invention. ブロック毎の縮小・拡大処理の別の例を説明するための図。The figure for demonstrating another example of the reduction / enlargement process for every block. 本発明の第6の具体例における符号化回路の構成例を示すブロック図。The block diagram which shows the structural example of the encoding circuit in the 6th specific example of this invention. 時刻n−1と時刻nにおけるフレーム画像Fn-1 ,FnとそれぞれのフレームFn-1 ,Fnにおける符号化領域CAの各マクロブロックのモード情報MDの例を説明するための図。The figure for demonstrating the example of mode information MD of each macroblock of the encoding area CA in the frame images Fn-1 and Fn in each of the time n-1 and the time n, and each frame Fn-1. 符号化領域の変化とモード情報の対応するブロックの位置の変化の様子を説明するための図。The figure for demonstrating the mode of the change of the position of the block corresponding to the change of an encoding area | region, and mode information. 本発明の時刻n−1と時刻nにおけるフレーム画像Fn-1 ,FnとそれぞれのフレームFn-1 ,Fnにおける符号化領域CAの各マクロブロックのモード情報MDの例を説明するための図。The figure for demonstrating the example of the mode information MD of each macroblock of the encoding area CA in the frame images Fn-1 and Fn and the each frame Fn-1 and Fn in the time n-1 and the time n of this invention. アルファマップを併用する動画像符号化装置における符号化データ構成を説明するための図。The figure for demonstrating the encoding data structure in the moving image encoder which uses an alpha map together. 符号化領域が占める対象部分がフレームの一部分である場合に生じるラベル未定部分の対処法を説明するための図。The figure for demonstrating the coping method of the label undetermined part produced when the object part which an encoding area occupies is a part of frame. ラベルを予測に用いるようにした本発明の復号化装置の構成例を示すブロック図。The block diagram which shows the structural example of the decoding apparatus of this invention made to use a label for prediction. 本発明の符号化装置で用いる符号化処理手順の例を示すフローチャート。The flowchart which shows the example of the encoding process procedure used with the encoding apparatus of this invention. 本発明の符号化装置で用いる符号化処理手順の別の例を示すフローチャート。The flowchart which shows another example of the encoding process procedure used with the encoding apparatus of this invention. フレーム毎の解像度の例を表した図。The figure showing the example of the resolution for every flame | frame. 図25の符号化装置に必要なフレームメモリを明示的に含めて表した場合の符号化装置の構成例を示すブロック図。The block diagram which shows the structural example of an encoding apparatus at the time of expressing explicitly including the frame memory required for the encoding apparatus of FIG. 図26の復号化装置に必要なフレームメモリを明示的に含めて表した場合の復号化装置の構成例を示すブロック図。The block diagram which shows the structural example of a decoding apparatus at the time of explicitly including the frame memory required for the decoding apparatus of FIG. 図25の符号化装置に必要なフレームメモリを明示的に含めて表した場合の符号化装置の別の構成例を示すブロック図。The block diagram which shows another structural example of an encoding apparatus at the time of expressing explicitly including the frame memory required for the encoding apparatus of FIG. 図26の復号化装置に必要なフレームメモリを明示的に含めて表した場合の別の復号化装置の構成例を示すブロック図。The block diagram which shows the structural example of another decoding apparatus at the time of explicitly including the frame memory required for the decoding apparatus of FIG. 本発明の符号化装置および復号化装置で用いるフレームメモリの構成例を示すブロック図。The block diagram which shows the structural example of the frame memory used with the encoding apparatus and decoding apparatus of this invention. 双一次内挿により水平・垂直共に2倍に拡大する処理の例を説明するための図。The figure for demonstrating the example of the process expanded to 2 times both horizontal and vertical by bilinear interpolation. 本発明で使用する双一次内挿処理により水平・垂直共に2倍に拡大する処理内容を説明するための図。The figure for demonstrating the processing content expanded twice horizontally and vertically by the bilinear interpolation process used by this invention. 本発明で使用する縮小処理の例を説明するための図。The figure for demonstrating the example of the reduction process used by this invention. 本発明で使用する縮小処理を説明するための図。The figure for demonstrating the reduction process used by this invention. 本発明で用いるラベル予測方法を説明するための図。The figure for demonstrating the label prediction method used by this invention. 本発明で使用する縮小フレームから拡大処理によりフレームを復元する処理の説明をするための図。The figure for demonstrating the process which decompress | restores a flame | frame by the expansion process from the reduction | decrease frame used by this invention. 本発明で適用する拡大処理における内挿画素位置と参照画素の利用範囲を説明する図。The figure explaining the utilization range of the interpolation pixel position and reference pixel in the expansion process applied by this invention. 本発明で適用する拡大処理における参照画素の追加処理の例を説明する図。The figure explaining the example of the addition process of the reference pixel in the expansion process applied by this invention. 本発明にて用いる動きベクトルの予測符号化の一例を説明するための図。The figure for demonstrating an example of the prediction encoding of the motion vector used by this invention. フレーム内でのオブジェクトの位置の動きが大きい場合での、動きベクトルの予測の不都合を説明するための図。The figure for demonstrating the inconvenience of the prediction of a motion vector in case the motion of the position of the object in a flame | frame is large. 本発明システムにおけるMV符号化回路1790とその周辺回路の具体的構成例を示すブロック図。The block diagram which shows the specific structural example of the MV encoding circuit 1790 and its peripheral circuit in this invention system. 本発明システムにおけるMV再生回路2900とその周辺回路の具体的構成例を示すブロック図。The block diagram which shows the specific structural example of the MV reproduction circuit 2900 and its peripheral circuit in this invention system.

符号の説明Explanation of symbols

2…a1検出回路
3,14…メモリ
5…モード決定回路
8…符号化回路
1−10…テーブル決定回路
13…復号化回路
16…テーブル決定回路
17,26…テーブル
19…a1再生回路
22,27…カウンタ
23,28…ハフマンテーブル生成回路
100…差分回路
110,350…動き補償予測回路
120…直交変換回路
130…量子化回路
140…可変長符号化回路
150,320…逆量子化回路
160,330…逆直交変換回路
170,340…加算回路
180,240…多重化回路
200…アルファマップ符号化回路
210,230,260,420…解像度変換回路
220…2値画像符号化回路
300,430,520…分離化回路
310…可変長復号化回路
400…アルファマップ復号化回路
410…2値画像復号化回路
502…オブジェクト領域検出回路
504…ブロック化回路
506…ラベル付け回路
508…ラベル符号化回路
509…ラベルメモリ
510…参照ブロック決定回路
512…予測回路
516…ラベル復号化回路
517…ラベルメモリ
518…参照ブロック決定回路
520…予測回路
1100…モード判定回路
1110…CR(縮小・拡大率)判定回路
1200,2300…セレクタ
1300…フレームメモリ
1400,1500…ブロック内画素値設定回路
1600…動き補償予測回路
1700…2値画像符号化回路
1710,1730,1740,2830,2840…縮小回路
1720…拡大回路
1750,1760,2820,2850…転置回路
1770…スキャンタイプ(ST)判定回路
1780…動きベクトル検出回路(MVE)
1791…MVメモリ
1792…MV予測回路
1793…セレクタ
1794…差分回路
1800…VLC(可変長符号化)・多重化回路
1900…動きベクトル再生回路
2100…VLC(可変長符号化)・分離化回路
2400,2500…マクロブロック内画素値設定回路
2600…動き補償予測回路
2700…フレームメモリ
2800…2値画像復号化回路
2810…拡大回路
2800…2値画像復号化回路
2901…加算回路
2902…セレクタ
2903…MV予測回路
2904…MVメモリ
8100…蓄積媒体
8200…デコーダ
8300…画像情報出力装置
e10…符号化領域検出回路
e11…デフォルト値決定回路
e12…領域情報メモリ
e13…オフセット算出回路
e14…セレクタ
d10…領域情報メモリ
d11…オフセット算出回路
d12…セレクタ。
DESCRIPTION OF SYMBOLS 2 ... a1 detection circuit 3,14 ... Memory 5 ... Mode determination circuit 8 ... Encoding circuit 1-10 ... Table determination circuit 13 ... Decoding circuit 16 ... Table determination circuit 17, 26 ... Table 19 ... a1 reproduction circuit 22, 27 ... Counter 23, 28 ... Huffman table generation circuit 100 ... Difference circuit 110, 350 ... Motion compensation prediction circuit 120 ... Orthogonal transformation circuit 130 ... Quantization circuit 140 ... Variable length encoding circuit 150, 320 ... Inverse quantization circuit 160, 330 ... inverse orthogonal transform circuit 170, 340 ... adder circuit 180, 240 ... multiplexing circuit 200 ... alpha map encoding circuit 210, 230, 260, 420 ... resolution conversion circuit 220 ... binary image encoding circuit 300, 430, 520 ... Separation circuit 310... Variable length decoding circuit 400... Alpha map decoding circuit 410. Decoding circuit 502 ... Object region detection circuit 504 ... Blocking circuit 506 ... Labeling circuit 508 ... Label encoding circuit 509 ... Label memory 510 ... Reference block determination circuit 512 ... Prediction circuit 516 ... Label decoding circuit 517 ... Label memory 518 Reference block determination circuit 520 Prediction circuit 1100 Mode determination circuit 1110 CR (reduction / enlargement ratio) determination circuit 1200, 2300 Selector 1300 Frame memory 1400, 1500 ... In-block pixel value setting circuit 1600 Motion compensation prediction circuit DESCRIPTION OF SYMBOLS 1700 ... Binary image encoding circuit 1710, 1730, 1740, 2830, 2840 ... Reduction circuit 1720 ... Expansion circuit 1750, 1760, 2820, 2850 ... Transposition circuit 1770 ... Scan type (ST) determination circuit 1780 ... Motion Vector detection circuit (MVE)
1791 ... MV memory 1792 ... MV prediction circuit 1793 ... selector 1794 ... difference circuit 1800 ... VLC (variable length coding) / multiplexing circuit 1900 ... motion vector reproduction circuit 2100 ... VLC (variable length coding) / separation circuit 2400, 2500 ... Pixel value setting circuit in macroblock 2600 ... Motion compensation prediction circuit 2700 ... Frame memory 2800 ... Binary image decoding circuit 2810 ... Enlargement circuit 2800 ... Binary image decoding circuit 2901 ... Addition circuit 2902 ... Selector 2903 ... MV prediction Circuit 2904 ... MV memory 8100 ... Storage medium 8200 ... Decoder 8300 ... Image information output device e10 ... Encoding area detection circuit e11 ... Default value determination circuit e12 ... Area information memory e13 ... Offset calculation circuit e14 ... Selector d10 ... Area information memory d11: Offset calculation circuit d12: Selector.

Claims (4)

時系列データとして得られる複数フレームの動画像信号を任意形状のオブジェクト単位で符号化する動画像符号化装置において、
前記オブジェクトを含む方形領域をM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に分割する手段と、
前記オブジェクトの形状を表す2値画像であるアルファマップ信号について前記各ブロックを水平・垂直方向共に1/2N(N=1,2,3,…)に縮小する縮小処理手段と、
前記ブロックの近傍再生値を保持するメモリと、
前記メモリに保持された再生値を1/2Nに縮小することで参照画素値を求める手段と、
水平・垂直方向共に2倍に拡大する処理をN回繰り返すことで元のサイズに拡大する拡大処理手段と、
を備えて構成し、
上記拡大処理手段においては、常に1/2N に縮小された参照画素値を用いるように
縮小処理されたブロックを拡大処理する拡大回路とを有し、符号化にあたってはレート制御のために上記縮小処理されたブロックと拡大処理されたブロックとを選択的に利用するようにした画像符号化装置において、
上記拡大回路は、
上記ブロックの近傍再生値を保持するメモリと、
該ブロックの縮小率に応じて上記メモリに保持された再生値を1/2N に縮小することで参照画素値を求める手段と、
水平・垂直方向共に2倍に拡大する処理をN回繰り返すことで元のサイズに拡大する拡大処理手段と、
を備えて構成し、
上記拡大処理手段においては、常に1/2N に縮小された参照画素値を用いるようにすることを特徴とする画像符号化装置。
In a moving image encoding apparatus that encodes a plurality of frames of moving image signals obtained as time-series data in units of arbitrary shapes,
Means for dividing the rectangular region including the object into blocks each composed of M × N pixels (M: number of pixels in the horizontal direction, N: number of pixels in the vertical direction);
Reduction processing means for reducing each block to 1 / 2N (N = 1, 2, 3,...) In both the horizontal and vertical directions for an alpha map signal that is a binary image representing the shape of the object;
A memory for holding neighborhood reproduction values of the block;
Means for obtaining a reference pixel value by reducing the reproduction value held in the memory to 1 / 2N;
An enlargement processing means for enlarging to the original size by repeating the process of enlarging twice in the horizontal and vertical directions N times;
Configured with
The enlarging processing means includes an enlarging circuit for enlarging the reduced block so as to always use the reference pixel value reduced to 1 / 2N, and the encoding process is performed for rate control in encoding. In an image encoding device that selectively uses a block subjected to enlargement and a block subjected to enlargement processing,
The expansion circuit is
A memory for holding neighborhood reproduction values of the block;
Means for obtaining a reference pixel value by reducing the reproduction value held in the memory to 1 / 2N according to the reduction ratio of the block;
An enlargement processing means for enlarging to the original size by repeating the process of enlarging twice in the horizontal and vertical directions N times;
Configured with
An image encoding apparatus characterized in that the enlargement processing means always uses a reference pixel value reduced to 1 / 2N.
水平・垂直共に1/2N (N=1,2,3,…)に縮小された2値画像のブロックを拡大する拡大回路であって、
該ブロック近傍再生値を保持するメモリと、
該ブロックの縮小率に応じて上記メモリに保持された再生値を1/2N に縮小することで参照画素値を求める手段と、
水平・垂直共に2倍に拡大する処理をN回繰り返すことで元のサイズに拡大すると共に、この拡大処理においては、常に1/2N に縮小された参照画素値を用いる拡大処理手段と、
を具備することを特徴とする画像符号化装置。
An enlargement circuit for enlarging a block of a binary image reduced to 1 / 2N (N = 1, 2, 3,...) Both horizontally and vertically,
A memory for holding a reproduction value near the block;
Means for obtaining a reference pixel value by reducing the reproduction value held in the memory to 1 / 2N according to the reduction ratio of the block;
Enlarging to the original size by repeating the process of enlarging both horizontally and vertically N times N times, and in this enlarging process, an enlarging processing means that always uses a reference pixel value reduced to 1 / 2N;
An image encoding apparatus comprising:
時系列データとして得られる複数フレームの動画像信号を任意形状のオブジェクト毎に符号化する動画像符号化装置であって、オブジェクトを含む方形領域をM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に分割すると共に、この分割されて得られた上記ブロック毎に、前記方形領域内を一定規則により順次、符号化する画像符号化装置であって、
上記フレーム内において、オブジェクトを含むブロックサイズの倍数で表される領域を設定する設定手段と、この設定手段により設定された領域内をブロックに分割する分割手段と、分割された上記ブロック内を動き補償予測するために必要な動きベクトルを予測符号化する手段とを有する画像符号化装置において、
参照フレーム内の領域のフレーム内における位置を表す第1の位置ベクトルを保持するメモリと、
該参照フレーム内領域のフレーム内での位置を表す第2の位置ベクトルを符号化する符号化手段と、
符号化対象ブロック近傍の再生済みのブロックの動きベクトルを保持する
動きベクトル
動きベクトルメモリと、
上記動きベクトルメモリに蓄えられている動きベクトルを用いて、符号化対象ブロックの動きベクトルを予測する手段とを備えてなり、
上記予測手段において使用する動きベクトルが、前記動きベクトルメモリに存在しない場合にはデフォルトの動きベクトルを予測値とし、このデフォルトの動きベクトルは第1の位置ベクトルと第2の位置ベクトルとの差分ベクトルと、ゼロベクトルを切り換えて用いるようにすることを特徴とする画像符号化装置。
A moving image encoding apparatus that encodes a plurality of frames of moving image signals obtained as time-series data for each object having an arbitrary shape, wherein a rectangular region including the object is represented by M × N pixels (M: number of pixels in the horizontal direction, N: the number of pixels in the vertical direction), and an image encoding device that sequentially encodes the inside of the rectangular area according to a certain rule for each of the blocks obtained by the division. And
Setting means for setting an area represented by a multiple of the block size including the object in the frame, a dividing means for dividing the area set by the setting means into blocks, and a motion in the divided block In an image coding apparatus having means for predictively coding a motion vector necessary for compensated prediction,
A memory that holds a first position vector that represents the position in the frame of the region in the reference frame;
Encoding means for encoding a second position vector representing a position in the frame of the reference frame region;
A motion vector motion vector memory that holds a motion vector of a reproduced block near the encoding target block;
Means for predicting the motion vector of the block to be encoded using the motion vector stored in the motion vector memory,
When the motion vector used in the prediction means does not exist in the motion vector memory, a default motion vector is used as a predicted value, and the default motion vector is a difference vector between the first position vector and the second position vector. And an image encoding device characterized in that the zero vector is switched and used.
時系列データとして得られる複数フレームの動画像信号を任意形状のオブジェクト毎に復号化する動画像復号化装置であって、オブジェクトを含むM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に、その方形領域内を一定規則により順次、復号化する画像復号化装置であって、該フレーム内において、オブジェクトを含むブロックサイズの倍数で表される領域をブロック毎に再生する画像復号化装置において、
上記ブロック内を動き補償予測するために必要な、予測符号化された動きベクトルを復号する手段と、
参照フレーム内を動き補償予測するために必要な、予測符号化された動きベクトルを復号する手段と、
参照フレーム内の領域のフレーム内での位置を表す第1の位置ベクトルを保持するメモリと、
該フレーム内の領域のフレーム内での位置を表す第2の位置ベクトルを復号化する手段と、
復号化対象ブロック近傍の補正済みのブロックの動きベクトルを保持する動きベクトルメモリと、
上記動きベクトルメモリに保持された動きベクトルを用いて、復号化対象ブロックの動きベクトルを予測する予測手段とを有し、
上記予測手段で使用するための動きベクトルが、上記動きベクトルメモリに存在しない場合にはデフォルトの動きベクトルを予測値とし、このデフォルトの動きベクトルは第1の位置ベクトルと第2の位置ベクトルとの差分ベクトルと、ゼロベクトルのいずれかとすることを特徴とする画像復号化装置。
A moving image decoding apparatus that decodes a plurality of frames of moving image signals obtained as time series data for each object having an arbitrary shape, and includes M × N pixels (M: number of pixels in the horizontal direction, N: vertical) An image decoding apparatus that sequentially decodes a rectangular area according to a certain rule for each block composed of the number of pixels in the direction), and is represented by a multiple of the block size including the object in the frame In an image decoding apparatus that reproduces an area for each block,
Means for decoding a motion vector encoded by predictive coding necessary for motion compensation prediction in the block;
Means for decoding a prediction-encoded motion vector required for motion compensated prediction in a reference frame;
A memory that holds a first position vector that represents the position of the region in the reference frame in the frame;
Means for decoding a second position vector representing a position within a frame of an area within the frame;
A motion vector memory that holds a motion vector of a corrected block near the decoding target block;
Predicting means for predicting a motion vector of a decoding target block using a motion vector held in the motion vector memory,
If a motion vector to be used by the prediction means does not exist in the motion vector memory, a default motion vector is used as a predicted value, and the default motion vector is a combination of the first position vector and the second position vector. An image decoding apparatus characterized in that a difference vector or a zero vector is used.
JP2007220412A 1996-10-31 2007-08-27 Image encoding device and image decoding device Abandoned JP2008011564A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007220412A JP2008011564A (en) 1996-10-31 2007-08-27 Image encoding device and image decoding device

Applications Claiming Priority (5)

Application Number Priority Date Filing Date Title
JP29003396 1996-10-31
JP9243297 1997-04-10
JP11615797 1997-04-18
JP14423997 1997-06-02
JP2007220412A JP2008011564A (en) 1996-10-31 2007-08-27 Image encoding device and image decoding device

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2004180820A Division JP2004350307A (en) 1996-10-31 2004-06-18 Image encoding device and image decoding device

Related Child Applications (3)

Application Number Title Priority Date Filing Date
JP2008118997A Division JP2008228337A (en) 1996-10-31 2008-04-30 Image encoder
JP2008118996A Division JP2008228336A (en) 1996-10-31 2008-04-30 Image encoding method and device
JP2008118995A Division JP2008245311A (en) 1996-10-31 2008-04-30 Method and apparatus for decoding image

Publications (2)

Publication Number Publication Date
JP2008011564A true JP2008011564A (en) 2008-01-17
JP2008011564A5 JP2008011564A5 (en) 2008-06-19

Family

ID=39069255

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007220412A Abandoned JP2008011564A (en) 1996-10-31 2007-08-27 Image encoding device and image decoding device

Country Status (1)

Country Link
JP (1) JP2008011564A (en)

Similar Documents

Publication Publication Date Title
JP4034380B2 (en) Image encoding / decoding method and apparatus
US7184600B2 (en) Video coding and video decoding apparatus
US6330364B1 (en) Video coding and video decoding apparatus
US6259738B1 (en) Video encoding apparatus and video decoding apparatus
JP2008228336A (en) Image encoding method and device
JP2008011564A (en) Image encoding device and image decoding device
US6754268B1 (en) Video coding and video decoding apparatus
JP2004343788A (en) Video encoding apparatus, video decoding apparatus and recording medium with video encoded data recorded thereon
JP2004350307A (en) Image encoding device and image decoding device
JP2004320807A (en) Image coding and apparatuses decoding
JP2004320808A (en) Image coding apparatus

Legal Events

Date Code Title Description
A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080430

A762 Written abandonment of application

Free format text: JAPANESE INTERMEDIATE CODE: A762

Effective date: 20090520