JP2004320808A - Image coding apparatus - Google Patents

Image coding apparatus Download PDF

Info

Publication number
JP2004320808A
JP2004320808A JP2004180819A JP2004180819A JP2004320808A JP 2004320808 A JP2004320808 A JP 2004320808A JP 2004180819 A JP2004180819 A JP 2004180819A JP 2004180819 A JP2004180819 A JP 2004180819A JP 2004320808 A JP2004320808 A JP 2004320808A
Authority
JP
Japan
Prior art keywords
circuit
frame
block
encoding
reduction
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.)
Withdrawn
Application number
JP2004180819A
Other languages
Japanese (ja)
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 JP2004180819A priority Critical patent/JP2004320808A/en
Publication of JP2004320808A publication Critical patent/JP2004320808A/en
Withdrawn legal-status Critical Current

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression Of Band Width Or Redundancy In Fax (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide an apparatus fore efficiently coding the shape information of an object. <P>SOLUTION: A binary image coding apparatus includes a means for dividing a rectangular region including the object at each block (BL) constituted of M×N pixels, and a means 220 for sequentially coding the BL according to a predetermined rule in the rectangular region, in a coding circuit of an alpha map displaying the shape of the object in a dynamic image coding apparatus for coding a plurality of frames of dynamic image signals obtained as time series data at each object of an arbitrary shape. The relative address coding is applied to the entirely or the part of the BL. This binary image coding apparatus includes a means for storing the regenerated value near the BL, a regenerated signal holding means FM for storing the regenerated signal of already coded frame (FM), a predicting means 250 for generating a motion compensation predicted value using the regenerated signal in the holding means, and a means for detecting a changed pixel including the regenerated value near the BL. The referred changed pixel of relative address coding is obtained not from the pixel value in the BL but from the motion compensation predicted signal. <P>COPYRIGHT: (C)2005,JPO&NCIPI

Description

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

画像信号は膨大な情報量を持つため、伝送や蓄積に供する場合には圧縮符号化するのが一般的である。そして、画像信号を高能率に符号化するには、フレーム単位の画像を、所要画素数単位(例えば、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. To encode an image signal with high efficiency, an image in a frame unit is converted into a required number of pixels (for example, M × N pixels (M: the number of pixels in the horizontal direction, N: the number of pixels in the vertical direction)). The image is divided into blocks, and an orthogonal transform is performed for each of the divided blocks to separate the spatial frequency of the image into frequency components, which are obtained 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, in “JYAWang et.al.“ Applying Mid-level Vision Techniques for Video Data Compression and Manipulation ”, MITMedia Lab.Tech.Report No.263, Feb.1994,” An image coding method belonging to a category called mid-level coding 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. Are encoded separately.

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

ところで、このアルファマップ信号を効率的に符号化する方法として、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 the like) or a line figure encoding method (chain encoding or the like). 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 code amount of the alpha map, a method of approximating the outline of the shape by polygon and smoothing it with a spline curve (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 a method of approximating a curve when reducing and encoding an alpha map and enlarging it (Japanese Patent Application No. Hei 5- 297133).

ここで、アルファマップを縮小して符号化し、拡大する際に曲線近似する方法の例を説明する。   Here, an example of a method of approximating a curve when reducing, encoding, and enlarging an alpha map 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 between changed pixels when encoding is performed in block units (for example, in a block unit having an M × N pixel configuration (M: the number of pixels in the horizontal direction, N: the 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 the block-based encoding, the encoding of the changed pixel may be simplified and encoded as follows. The following processing may be performed by switching the order of scanning, or may be applied to reduced blocks.

単純化した変化画素の符号化は、次のようにして行う。
今、変化画素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 coding of the simplified changed pixel is performed as follows.
Now, for the changed pixel ai (i = 0 to 1) and the reference changed pixel b1, the addresses (or pixel order) obtained in raster order from the upper left of the screen are abs_ai (i = 0 to 1) and abs_b1, respectively. When the line to which the changed pixel a0 belongs is denoted 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 equation, * indicates multiplication, (int) (X) indicates truncation of X below the decimal point, and WIDTH indicates the number of pixels in the block in the horizontal direction.

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

図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 with reference to the flowchart. In this process, first, the position of the starting point change pixel is initialized (S501), and the pixel value at the initial position (upper left pixel of the block) is encoded with one bit (S502). The pixel b1 is detected (S503).

ここで、参照変化画素b1が検出されなかった場合には、参照領域に変化画素が存在しないことから垂直モードが使えないため、垂直パスモードの状態を“TRUE”(真)とし、b1が検出された場合は垂直モードが使えるため、垂直パスモードの状態を“FALSE”(偽)とする。   Here, when the reference change pixel b1 is not detected, the vertical mode cannot be used because no change pixel exists in the reference area. 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 pass mode is set to “FALSE” (false).

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

また、S506での判定の結果、変化画素a1が検出された場合には、垂直パスモード(Vertical pass mode)の状態を判定する(S508)。ここで、垂直パスモードの状態が“TRUE”ならば、垂直パスモードの符号化処理(S516)を行い、垂直パスモードの状態が“FALSE”ならば、b1を検出する (S509)。   Also, as a result of the determination in S506, when the changed pixel a1 is detected, the state of the vertical pass mode (Vertical pass mode) is determined (S508). Here, if the state of the vertical path mode is “TRUE”, the encoding processing of the vertical path mode (S516) is performed, and if the state of the vertical path mode 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 is detected (S510). If the reference change pixel b1 is not detected, the process proceeds to the horizontal mode step (S513), and if the reference change pixel b1 is detected, Determines whether the absolute value of “r_a1−r_b1” is greater than a threshold value (VTH) (S511). As a result, if the absolute value is less than the threshold value (VTH), Proceeding to S512), if it is larger than the threshold value (VTH), proceeding to the horizontal mode step (S513).

水平モードのステップ(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 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), and proceeds to the vertical pass mode step (S516). When the vertical pass mode step (S516) ends, 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 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”, since only three types of codes occur: V0 (mode V0), H (horizontal mode), and EOMB (encoding process end code), 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” in 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 of encoding by dividing the screen into a background and an object. In this case, in order to separate the background from 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 is also encoded together with the encoded information of the image into a bit stream, which is transmitted and stored.

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

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

上記目的を達成するため、本発明は次のように構成する。   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 between an object area and a background area of the image, and the alpha map is encoded using relative address encoding.
Means for coding a changed pixel which has already been coded as a reference changed pixel, and coding the reference changed pixel and a symbol representing the relative position of the changed pixel to be coded next using a variable length coding table; Means for holding two or more long encoding tables and switching the variable length encoding table in accordance with the already encoded alpha map pattern.

第2には、この符号化装置により符号化されて得られた符号化ビットストリームを復号する復号化装置であって、
前記シンボルを可変長符号化テーブルを用いて復号する手段と、前記可変長符号化テーブルを2つ以上保持し、既に復号した前記アルファマップのパターンによって、前記可変長符号化テーブルを切り替える手段とを備えることを特徴とする。
Second, a decoding device for decoding an encoded bit stream obtained by encoding by the encoding device,
Means for decoding the symbol 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 having.

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

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

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

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

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

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

また、アルファマップ復号化回路において、M×N画素で構成されるブロック毎に、オブジェクトを含む方形領域内を一定規則で順次復号化する手段と、ブロック近傍の再生値を蓄える手段と、すでに符号化されたフレーム(画像フレーム)の再生信号を蓄える画像保持手段(フレームメモリ)と、画像保持手段(フレームメモリ)内の再生信号を用いて、動き補償予測値を生成する動き補償予測回路と、ブロック近傍の再生値も含めて変化画素を検出する手段とを有し、上記ブロック内の再生画素値から求められた、相対アドレス符号化の参照変化画素と、動き補償予測信号から求められた、相対アドレス符号化の参照変化画素を切り替える手段を有し、切り替え情報にしたがって参照変化画素を求めるようにしたものである。   Further, in the alpha map decoding circuit, for each block composed of M × N pixels, a means for sequentially decoding a rectangular area including an object according to a certain rule, a means for storing a reproduction value in the vicinity of the block, An image holding means (frame memory) for storing a reproduced signal of the converted frame (image frame), a motion compensation prediction circuit for generating a motion compensation predicted value using the reproduced signal in the image holding means (frame memory), Means for detecting a changed pixel including a reproduced value in the vicinity of the block, and obtained from a reproduced pixel value in the block, a reference changed pixel of relative address encoding, and obtained from a motion compensation prediction signal, There is provided a means for switching the reference change pixel in the relative address encoding, 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 the relative address encoding, whether to detect the reference change pixel b1 from the "current block" which is the block of the image currently being processed or from the "compensated block" which is the block of the image processed last time Can be processed by switching on a block basis, and the encoding side also encodes the information for this switching, and the decoding side decodes this, and converts it to the information for switching at the time of decoding processing. Based on this, it is possible to switch between detecting the reference change pixel b1 from within the “current block” and detecting from the “compensated block” on a block basis. Optimal processing can be performed based on the image content, and more efficient encoding can be performed.

また本発明は、時系列データとして得られる複数フレームの動画像信号を任意形状のオブジェクト毎に符号化する動画像符号化装置であって、オブジェクトを含む方形領域をM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に分割すると共に、この分割されて得られた上記ブロック毎に、前記方形領域内を一定規則により順次、符号化する画像符号化装置において、
オブジェクトの形状を表すアルファマップ信号について、ブロック近傍の再生信号を含む該フレームの再生信号と、符号化が終了したフレームの再生信号を蓄えるフレームメモリと、
ブロック内の画素値を2値の何れか一方の値で全て置き換える手段と、
フレームメモリ内のすでに符号化が終了したフレームの再生信号を用いて、動き補償予測値を生成する動き補償予測手段と、
ブロック毎に2値画像を縮小・拡大する手段と、
その縮小・拡大率をサイド情報として符号化する手段と、
ブロック毎に縮小された2値画像を符号化する2値画像符号化手段とからなるアルファマップ符号化手段を備えて構成した。
The present invention also relates to a moving picture coding apparatus that codes moving picture signals of a plurality of frames obtained as time-series data for each object having an arbitrary shape, wherein a rectangular area including the object is M × N pixels (M: horizontal (The number of pixels in the vertical direction, N: the number of pixels in the vertical direction), and an image to be sequentially coded according to a certain rule in the rectangular area 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 for storing a playback signal of the frame including a playback signal in the vicinity of the block and a playback signal of a frame for which encoding has been completed;
Means for replacing all pixel values in the block with one of two values;
A motion compensation prediction unit that generates a motion compensation 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 including a binary image encoding means for encoding a binary image reduced for each block is provided.

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

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

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

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

また、アルファマップのブロック毎の属性を再生する復号化装置として、
復号化したラベルをフレーム毎に保持する記憶手段と、
現フレームの復号ブロックに対応する前フレームの参照ブロックを決定する決定手段と、
少なくとも上記記億手段に保持された前フレームのラベルと上記参照ブロックによつて予測値を決定する予測手段と、
上記復号ブロックのラベル情報を、上記予測値を用いて復号化する復号化手段を備えて構成するようにした。
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 the previous frame corresponding to the decoded block of the current frame;
Prediction means for determining a prediction value based on at least the label of the previous frame stored in the storage means and the reference block;
A decoding unit for decoding the label information of the decoded block using the predicted value is provided.

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

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

さらには、フレーム単位での縮小・拡大率を保持する記憶手段を設けると共に、上記符号化手段は、フレーム単位でフレームの縮小・拡大率が可変であり、上記縮小・拡大縮率対応に符号化する手段を備え、また、上記決定手段は、現フレームの縮小・拡大率と、上記記億手段から得た前フレームの縮小・拡大率を用いて現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する手段を備えるようにする。   Further, storage means for holding the reduction / enlargement ratio in units of frames is provided, and the encoding unit has a variable reduction / expansion ratio of the frame in units of frames, and performs encoding corresponding to the reduction / expansion ratio. Means for determining the size of the previous frame corresponding to the coding block of the current frame by using the reduction / enlargement rate of the current frame and the reduction / enlargement rate of the previous frame obtained from the storage means. 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 unit has a variable reduction / expansion ratio of the frame in units of frames, and performs encoding corresponding to the reduction / expansion ratio. Means for determining a reference to a previous frame corresponding to an encoded block of the current frame by using the reduction / enlargement rate of the current frame and the reduction / enlargement rate of the previous frame obtained from the storage means. When there are a plurality of reference blocks, the prediction means includes means for determining a label having a large number of labels among the labels of the plurality of reference blocks as a predicted value.

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

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

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

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

また、水平・垂直方向共に1/2N (N=1,2,3,…)に縮小された2値画像のブロックを拡大する拡大回路として、
該ブロック近傍再生値を保持するメモリと、該ブロックの縮小率に応じて上記メモリに保持された再生値を1/2N に縮小することで参照画素値を求める手段と、水平・垂直共に2倍に拡大する処理をN回繰り返すことで元のサイズに拡大する手段とを備え、上記拡大手段においては、常に1/2N に縮小された参照画素値を用いることを特徴とする。
Further, 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, means for obtaining a reference pixel value by reducing the reproduction value stored in the memory to 1 / 2N according to the reduction ratio of the block, Means for enlarging the original size by repeating the processing for enlarging N times N times, wherein the enlarging means always uses a reference pixel value reduced to 1 / 2N.

また、時系列データとして得られる複数フレームの動画像信号を任意形状のオブジェクト毎に符号化する動画像符号化装置であって、オブジェクトを含む方形領域をM×N画素(M:水平方向の画素数、N:垂直方向の画素数)で構成されるブロック毎に分割すると共に、この分割されて得られた上記ブロック毎に、前記方形領域内を一定規則により順次、符号化する画像符号化装置であって、
上記フレーム内において、オブジェクトを含むブロックサイズの倍数で表される領域を設定する設定手段と、この設定手段により設定された領域内をブロックに分割する分割手段と、分割された上記ブロック内を動き補償予測するために必要な動きベクトルを予測符号化する手段とを有する画像符号化装置において、
参照フレーム内の領域のフレーム内における位置を表す第1の位置べクトルを保持するメモリと、該参照フレーム内領域のフレーム内での位置を表す第2の位置ベクトルを符号化する符号化手段と、符号化対象ブロック近傍の再生済みのブロックの動きベクトルを保持する動きべクトルメモリと、上記動きベクトルメモリに蓄えられている動きべクトルを用いて、符号化対象ブロックの動きベクトルを予測する手段とを備えてなり、
上記予測手段において使用する動きベクトルが、前記動きベクトルメモリに存在しない場合にはデフォルトの動きベクトルを予測値とし、このデフォルトの動きベクトルは第1の位置ベクトルと第2の位置べクトルとの差分べクトルと、ゼロベクトルを切り換えて用いるようにすることを特徴とする。
Also, the present invention is a moving picture coding apparatus that codes moving picture signals of a plurality of frames obtained as time-series data for each object having an arbitrary shape, wherein a rectangular area including an object is represented by M × N pixels (M: horizontal pixels). Number, N: the number of pixels in the vertical direction), and an image coding apparatus that sequentially codes 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, dividing means for dividing the area set by the setting means into blocks, and moving in the divided block. Means for predictive coding of a motion vector required for compensated prediction,
A memory for holding a first position vector representing the position of the region in the reference frame in the frame, and 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 a unit that predicts a motion vector of the encoding target block using the motion vector stored in the motion vector memory. Equipped with
If 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 between the first position vector and the second position vector. It is characterized in that the vector and the zero vector are switched and used.

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

本発明によれば、アルファマップの符号量を低減することができるため、フレーム単位で符号化する従来の符号化法と比べて、大幅な符号化効率の低下なしにオブジェクト毎に別々に符号化することができるようになる。   According to the present invention, since the code amount of an alpha map can be reduced, encoding can be performed separately for each object without a significant decrease in encoding efficiency, as compared with a conventional encoding method in which encoding is performed in frame units. 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 by dividing the inside of a screen into a background and an object when encoding an image. 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, It comprises a quantization circuit (IQ) 150, an inverse orthogonal transformation circuit 160, an addition circuit 170, a multiplexing circuit 180, and an alpha map encoding circuit 200.

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

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

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

逆量子化回路150は量子化回路130の出力を逆量子化するものであり、逆直交変換回路160はこの逆量子化回路150の出力を前記アルファマップに基いて逆直交変換するものであり、加算回路170はこの逆直交変換回路160の出力と動き補償予測回路110から与えられる予測信号(動き補償予測信号)とを加算して差分回路100に出力するものである。   The inverse quantization circuit 150 is for inversely quantizing the output of the quantization circuit 130, and the inverse orthogonal transform circuit 160 is for inversely orthogonally transforming the output of the inverse quantization circuit 150 based on the alpha map. The addition 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 operating based on a local decoded signal provided from the alpha map decoding circuit 200 and accumulating a signal of an object area and a signal of a background area. Further, the motion compensation prediction circuit 110 predicts a motion compensation value from the accumulated image of the object area and outputs the predicted value, and also predicts a motion compensation value from the accumulated image of the background area and outputs the predicted value. Having.

このような構成の本装置の作用を説明する。本装置には、画像信号とその画像信号のアルファマップが入力される。   The operation of the present device having such a configuration will be described. This 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 of a predetermined pixel size (for example, M × N pixels (M: the number of pixels in the horizontal direction, N: the number of pixels in the vertical direction)) for each frame, and The signals are supplied to the difference circuit 100 via the signal line 10 in the position order. Then, the difference circuit 100 calculates a difference signal between the input (image signal) and the prediction signal (the 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に供給される。   The orthogonal transform circuit 120 converts the supplied difference signal into an orthogonal transform coefficient according to the information of the alpha map supplied from the alpha map encoding circuit 200 via the signal line 40, and then supplies the orthogonal signal to the quantization circuit 130. I do. And it is quantized here. The transform coefficients obtained by the quantization by the quantization circuit 130 are 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 inversely transformed by the inverse orthogonal transform circuit 160. Then, the sum is added to the motion compensation prediction value supplied from the motion compensation prediction circuit 110 in the addition circuit 170, output as a locally decoded image, and input to the motion compensation prediction circuit 110 again.

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

一方、この動き補償予測回路110は、アルファマップ復号化回路200から与えられる局部復号信号に基づいてオブジェクトの領域のブロックの処理のタイミングでは“オブジェクトの動き補償予測値”を、また、それ以外のタイミングでは“背景部分の動き補償予測値”を出力して差分回路100に与える。   On the other hand, the motion compensation prediction circuit 110 outputs the “object motion compensation prediction value” at the processing timing of the block of the object area based on the local decoded signal given from the alpha map decoding circuit 200, At the timing, “the motion compensation prediction value of the background portion” is output and given 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 100, the motion compensation prediction signal of the object is input during the image signal input period of the block corresponding portion of the object, and the image signal is input during the image signal input period of the block corresponding portion of the background portion. For example, a background motion compensation prediction signal is provided 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 area of the image. As a result, if the input image is in the area corresponding to the object, the corresponding position of the object is determined. In the case where the difference signal from the predicted value in the above is an input image of a background area, a 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にて量子化される。   The orthogonal transform circuit 120 converts the supplied difference signal into an orthogonal transform coefficient according to the information of the alpha map supplied via the signal line 40, and then supplies the orthogonal transform coefficient to the quantization circuit 130. Then, the orthogonal transform coefficients are quantized by the quantization circuit 130.

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

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

そして、これにより、オブジェクト用のフレームメモリにはオブジェクト画像のみが、また、背景用のメモリには背景画像のみの画像が得られることになる。これにより、動き補償予測回路110はオブジェクト画像を利用してオブジェクト画像の予測値を求めることができ、また、背景部分の画像を利用して背景画像の予測値を求めることができる。   As a result, only the object image is obtained in the object frame memory, and only the background image is obtained in the background memory. Thus, 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 the 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 multiplexing circuit 180 is supplied with the transform coefficient output from the variable length coding circuit 140 via a line 40. Then, the multiplexing circuit 180 multiplexes the supplied alpha map signal and the encoded value of the transform coefficient with side information such as motion vector information, and then outputs the multiplexed signal via the signal line 50 to output the main image code. Bit stream as the final output of the encoding device.

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

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

一方、図2は本発明が用いられる復号化装置のブロック図である。復号化装置は、図2に示すように、分離化回路300、可変長復号化回路310、逆量子化回路320、逆直交変換回路330、加算回路340、動き補償予測回路350、アルファマップ復号化回路400とより構成される。   FIG. 2 is a block diagram of a decoding apparatus to which the present invention is applied. As shown in FIG. 2, the decoding device includes a demultiplexing 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, and alpha map decoding. And a circuit 400.

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

可変長復号化回路310は、分離化回路300にて分離された画像の符号化信号を復号するものであり、逆量子化回路320はこの復号されたものを逆量子化して元の係数に戻すものであり、逆直交変換回路330はこの係数をアルファマップにしたがって逆直交変換して予測誤差信号に戻すものであり、加算回路340は、この予測誤差信号に動き補償予測回路350からの動き補償予測値を加算して再生画像信号として出力するものである。この再生画像信号が復号化装置の最終出力となる。   The variable length decoding circuit 310 decodes the coded 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 an inverse orthogonal transform of the coefficient according to the alpha map and returns the result to a prediction error signal, and the addition circuit 340 applies the motion compensation from the motion compensation prediction circuit 350 to the prediction error signal. The prediction value is added and output as a reproduced image signal. This reproduced image signal is the final output of the decoding device.

動き補償予測回路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 addition circuit 340 in the frame memory according to the alpha map, and obtains an object image from the accumulated image. The motion compensation prediction signal and the background motion compensation prediction are obtained.

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

そして、アルファマップ信号に関する符号は、信号線80を介してアルファマップ復号化回路400に供給され、また、画像信号の可変長符号は可変長復号化回路310にそれぞれ供給される。   Then, 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 related to the alpha map signal is reproduced into an alpha map signal in 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 dequantizing circuit 320, where it is dequantized. The inversely quantized transform coefficients are inversely transformed by the inverse orthogonal transform circuit 330 according to the alpha map supplied via the line 90, and supplied to the adding circuit 340. The addition circuit 340 adds the signal subjected to the inverse orthogonal transformation from the inverse orthogonal transformation 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 encoding device and the image decoding device to which the present invention is applied. The present invention relates to an alpha map encoding circuit 200 which is a component of the encoding device shown in FIG. 1 and an alpha map decoding circuit 400 which is a component of the decoding device shown in FIG. 1 shows an embodiment.

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

解像度変換回路230は解像度変換回路210が解像度縮小変換したものを元のサイズに戻すために設けてあり、この解像度変換回路230により元のサイズに戻されたアルファマップが、信号線40を介して直交変換回路120,逆直交変換回路160に与えられるアルファマップ局部復号信号となる。   The resolution conversion circuit 230 is provided in order to return the size reduced by the resolution conversion circuit 210 to the original size. The alpha map returned 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 provided to the orthogonal transform circuit 120 and the inverse orthogonal transform circuit 160.

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

このような構成のアルファマップ符号化回路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-encoded by the resolution conversion circuit 210 at a specified enlargement ratio, and the encoded alpha map is encoded. A map signal is output via a signal line 30, and a locally decoded signal obtained by decoding the reduced-encoded alpha map signal to the original resolution by a resolution conversion circuit 230 is output via a signal line 40 to an orthogonal transform circuit. 120, and outputs the result to the inverse orthogonal transform circuit 160.

すなわち、信号線60を介してアルファマップ符号化回路200に所望とする縮小・拡大率の設定情報を供給することで、上記トレードオフを図ることが可能となる。   That is, by supplying setting information of a desired reduction / enlargement ratio to the alpha map encoding circuit 200 via the signal line 60, the above-mentioned 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 to control the generated code amount of the alpha map signal. It becomes. The code (setting information signal) of the reduction / enlargement rate 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 to the multiplexing circuit 180 which is the final output stage of the image encoding device as an encoded signal of the alpha map.

次に先行技術としてのアルファマップ復号化回路400に触れておく。図4は先行技術(特願平8−237053号)における具体的なアルファマップ復号化回路400である。   Next, the alpha map decoding circuit 400 as the prior art will be described. 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 separating circuit 430 converts the sign of the alpha map signal and the reduction / enlargement rate from the alpha map signal separated by the separating 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 a code of the reduction / enlargement ratio which is given separately from the separation circuit 430. Therefore, this is a circuit for returning to a binary image, and the resolution conversion circuit 420 performs resolution expansion conversion on this binary image in accordance with the sign of the reduction / enlargement ratio given separately from the separation circuit 430, and outputs it.

図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, and the signal line 81 and the signal Output via line 82.

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

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

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

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

本発明の第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”を出力する。   The binary image encoding circuit 220 in FIG. 3 encodes the symbol (Mode) representing the position of the changing pixel using the variable length encoding table (VLC table) shown in FIG. For example, when the vertical pass mode is “FALSE” and “V0 (r_a1−r_b1 = 0 in vertical mode)”, “1” is output as a code. Alternatively, when “V1 (| r_a1−r_b1 | = 1 in vertical mode)”, “01s” (“0” or “1” depending on whether s: r_a1−r_b1 is positive or negative) is output, and “EOMB (encoding end) )), "0001" is output.

一方、図4の2値画像復号化回路410では、符号化に利用したもの同じ図17のVLCテーブルを用いて、例えば、入力された符号が“1”である場合には“V0を再”生し、入力された符号が“0001”である場合には“EOMB”を再生する。   On the other hand, the binary image decoding circuit 410 of FIG. 4 uses the same VLC table of FIG. 17 used for encoding and, for example, when the input code is “1”, “resets V0”. 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テーブル)を適応的に切り替えることで、さらに符号量を削減するものである。   According to the present invention, the code amount is further reduced by adaptively switching a variable length coding table (VLC table) according to a pixel pattern of an already encoded / decoded alpha map.

<第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. The a1 detection circuit 2 detects the position 4 of the changed pixel a1 described with reference to FIG. At the same time, the memory 3 sends the position 6 of the reference change pixel b1 to the mode determination circuit 5.

モード決定回路5では、図19を用いて説明したアルゴリズムにより、モードが決定され、そのモードが、符号化されるシンボル7として符号化回路8に送られる。   The mode determination circuit 5 determines a mode according to the algorithm described with reference to FIG. 19, and sends the mode 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. In the table determination circuit 1-10, one of the plurality of variable length coding tables is selected and output.

ここで、例えば、図7に示すように、参照変化画素b1の上方において、右上から左下向きのエッジがある場合は、参照変化画素b1の下方にも同じエッジが直線的に延びる場合が多いので、画素x1、x2、x3の中ではx1にa1がある確率が高い。   Here, for example, as shown in FIG. 7, if 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 pixels x1, x2, and x3, there is a high probability that x1 has a1.

そこで、参照変化画素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進数に変換したものをコンテキスト番号と呼ぶ。
<A more detailed example of the table determination method>
8 and 9 show more detailed specific examples of the table determination method. Here, attention is paid to c0 to c5 in the upper two lines of the reference change pixel b1 shown in FIG. Assuming that these pixels have the same value as the reference change pixel b1 as "1" and different values as "0", "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 encoding table is prepared so as to be 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 upper VL1 can be encoded with one bit is selected.

再び図5に戻り、説明を続ける。符号化回路8ではテーブル決定回路1−10から送られてくる選択されたテーブル11を用いて符号12が決定される。そして、その決定した符号12を出力する。   Returning to FIG. 5 again, the description will be continued. In the encoding circuit 8, the code 12 is determined 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 an alpha map decoding circuit 400 as a component of the decoding device shown in FIG. 2 or a binary image decoding circuit 410 as a component of the decoding device shown in FIG. 4 in more detail. FIG. This is for decoding the code 12 generated in 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 the plurality of variable length coding tables is sent to the decoding circuit 13 as a selected table 17. The algorithm of the table determination 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 reproducing circuit 19 finds the position of a1 from 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 is for switching a plurality of predetermined variable length coding tables. FIG. 10 shows a specific example of dynamically modifying the table according to the frequency of actually generated symbols. 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 modified according to the frequency of actually generated symbols. . 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 coding table 26 is generated by Huffman coding (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. The generation and replacement of the Huffman table are performed 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 device for decoding the code generated in the specific example of FIG. The decoding device as the first specific example shown in FIG. 11 also has a configuration in which a counter 27 and a Huffman table generation circuit 28 are added 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, the encoding / decoding in which the code amount is reduced by encoding the symbol specifying the position of the changing pixel using the variable length encoding table. In the present invention, a plurality of types of variable length coding tables are prepared, and the variable length coding tables are switched according to the already coded alpha map pattern. According to the above, the effect that the code amount of the alpha map can be further reduced can be obtained.

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

(第3の具体例)
第3の具体例は、相対アドレス符号化の参照変化画素を、上記ブロック内の画素値からだけでなく、動き補償予測信号からも求められることを特徴とするものである。
(Third specific example)
The third specific example is characterized in that the reference change pixel of the relative address coding is obtained not only from the pixel value in the block but also from the 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 according to the present invention will be described with reference to FIG. 12, FIG. 13 and FIG.

第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 them, the resolution conversion circuit 210 is a conversion circuit for resolution reduction conversion, and encodes an alpha map at a reduction rate according to a given reduction / enlargement rate setting information signal. A conversion circuit for enlargement conversion, which has a function of encoding an alpha map at an enlargement ratio according to a given enlargement ratio.

解像度変換回路230は解像度変換回路210が解像度縮小変換したものを元のサイズに戻すために設けてあり、この解像度変換回路230により元のサイズに戻されたアルファマップが、信号線40を介して直交変換回路120,逆直交変換回路160に与えられるアルファマップ局部復号信号となる。   The resolution conversion circuit 230 is provided in order to return the size reduced by the resolution conversion circuit 210 to the original size. The alpha map returned 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 provided to the orthogonal transform circuit 120 and the inverse orthogonal transform circuit 160.

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

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

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

なお、2値画像符号化回路220として構成する場合では、信号線21を介して供給される解像度変換回路210からの解像度縮小変換されたアルファマップ信号を2値画像符号化して出力する。   When configured as the binary image encoding circuit 220, the resolution-reduced and converted alpha map signal from the resolution conversion circuit 210 supplied via the signal line 21 is encoded into a binary image 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 through the signal line 60 is supplied to the resolution conversion circuits 210, 230, 260 and the binary image encoding circuit 220. To control the generated code amount of the alpha map signal. The code (setting information signal) of the reduction / enlargement rate 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 to the multiplexing circuit 180 shown in FIG. 1, which is the final output stage of the image encoding device, as an encoded signal of the alpha map.

本装置では、アルファマップ信号入力線20を介して入力されるアルファマップを、信号線60を介して与えられる所望の縮小・拡大率の設定情報に従って解像度変換回路210は縮小符号化し、2値画像符号化回路220に与える。   In the present apparatus, the resolution conversion circuit 210 performs reduction coding on an alpha map input via the alpha map signal input line 20 in accordance with setting information of a desired reduction / enlargement ratio provided via the signal line 60, and performs binary coding. This is given 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 converted alpha map signal obtained from the resolution conversion circuit 210 from the resolution-reduced converted alpha map supplied by the signal line 42 from the resolution conversion circuit 260 for reduction processing. , And is supplied to the multiplexing circuit 240 and the resolution conversion circuit 230 as a binary image encoded output. Then, the multiplexing circuit 240 multiplexes the coded alpha map signal, which is the coded output of the binary image, with the information of the enlargement rate given via 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, in the resolution conversion circuit 230, the reduced / encoded alpha map signal (binary image encoded output) given from the binary image encoding circuit 220 is reduced / enlarged via the signal line 60. In accordance with the rate setting information signal, decoding is performed to the original resolution to obtain a local decoded signal, and the obtained local decoded signal is transmitted via the signal line 40 to the motion compensation prediction circuit 250 and the orthogonal transform circuit 120 of 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 includes a frame memory for storing a reproduced image of the previously encoded frame, and stores a reproduced signal supplied from the resolution conversion circuit 230 for enlargement processing. Then, the motion compensation prediction circuit 250 generates a motion compensation prediction signal of an alpha map according to a separately supplied motion vector signal, and supplies the motion compensation prediction signal to the resolution conversion circuit 260 for reduction processing via the signal line 41. The resolution conversion circuit 260 performs resolution reduction conversion of the supplied motion compensation prediction signal in accordance with a reduction / enlargement ratio setting information signal obtained via the signal line 60, and supplies the signal to the binary image encoding circuit 220.

2値画像符号化回路220は、縮小処理用の解像度変換回路260から与えられた解像度縮小変換されたアルファマップの動き補償予測信号を利用し、解像度変換回路210から得られた解像度縮小変換済みアルファマップ信号を符号化する。   The binary image encoding circuit 220 uses the motion-compensated prediction signal of the resolution-reduced and converted alpha map supplied from the resolution conversion circuit 260 for reduction processing, and uses the resolution-reduced 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 demultiplexing circuit 430, Further, a motion compensation prediction circuit 440 and a resolution conversion circuit (reduction processing circuit) 450 are provided.

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

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

第3の具体例における復号化回路の構成は、動き補償予測回路440および縮小処理用の解像度変換回路450を備えている点が、上述した先行技術の構成 (図4の回路)と異なるものである。そして、動き補償予測回路440は、先に符号化されたフレームの再生画像を蓄積するフレームメモリを有しており、拡大処理用の解像度変換回路420より供給される再生信号を蓄えると共に、動きベクトル信号(図示せず)が供給され、この動きベクトル信号にしたがって動き補償予測信号を生成し、信号線91を介して縮小処理用の解像度変換回路450に供給する構成となっている。   The configuration of the decoding circuit in the third specific example is different from the above-described prior art configuration (the circuit in FIG. 4) in that the decoding circuit includes a motion compensation prediction circuit 440 and a resolution conversion circuit 450 for reduction processing. is there. The motion compensation prediction circuit 440 has a frame memory for storing a reproduced image of a previously encoded frame, stores a reproduction signal supplied from the resolution conversion circuit 420 for enlargement processing, and A signal (not shown) is supplied, a motion compensation prediction signal is generated in accordance with the motion vector signal, and 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 compensation prediction signal in accordance with the reduction / enlargement ratio setting information signal supplied via the signal line 82, and then sends the signal 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 converted by the demultiplexing circuit 430 into the code of the alpha map signal and the code of the reduction / enlargement ratio. And output via signal lines 81 and 82, respectively.

2値画像復号化回路410では、詳細は後述するが、縮小処理用の解像度変換回路450から信号線92にて供給される解像度縮小変換されたアルファマップの動き補償予測信号を利用し、信号線81を介して供給されるアルファマップ信号の符号と信号線82を介して供給される縮小・拡大率の符号(縮小・拡大率の設定情報信号)に従って2値画像に戻す復号化処理を施すことにより、縮小されているアルファマップ信号を再生し、信号線83を介して解像度変換回路420に供給する。   Although the details will be described later, the binary image decoding circuit 410 uses the motion compensated prediction signal of the resolution-converted alpha map supplied from the resolution conversion circuit 450 for reduction processing via the signal line 92 to generate a signal line. Decoding processing for returning to a binary image in accordance with the code of the alpha map signal supplied via 81 and the code of the reduction / enlargement ratio (reduction / enlargement ratio setting information signal) supplied via 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 enlarges 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 rate supplied via the signal line 82. After reproducing the alpha map signal, it is output via a 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 converted alpha map signal obtained from the resolution conversion circuit 210 from the resolution-reduced converted alpha map supplied by the signal line 42 from the resolution conversion circuit 260 for reduction processing. , And is supplied to the multiplexing circuit 240 and the resolution conversion circuit 230 as a binary image encoded output. Then, the multiplexing circuit 240 multiplexes the coded alpha map signal, which is the coded output of the binary image, with the information of the enlargement rate given via the signal line 60, and outputs the multiplexed signal to the signal line 30.

一方、解像度変換回路420では、この2値画像復号化回路410から与えられたこの縮小符号化されたアルファマップ信号(2値画像符号化出力)を、信号線82を介して得た縮小・拡大率の設定情報信号に従って元の解像度に復号し、局部復号信号として得て、この得た局部復号信号を動き補償予測回路440に出力する。   On the other hand, in the resolution conversion circuit 420, the reduced / encoded alpha map signal (binary image encoded output) provided from the binary image decoding circuit 410 is reduced / enlarged via the signal line 82. It decodes to the original resolution according to the rate setting information signal to obtain 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 includes a frame memory for storing a reproduced image of a previously encoded frame, and stores a reproduction signal supplied from a resolution conversion circuit 420 for enlargement processing. Then, the motion compensation prediction circuit 420 generates a motion compensation prediction signal of an alpha map according to a separately supplied motion vector signal, and supplies the motion compensation prediction signal to the resolution conversion circuit 450 for reduction processing via the signal line 91. The resolution conversion circuit 450 performs resolution reduction conversion of the supplied motion compensation prediction signal in accordance with the reduction / enlargement ratio setting information signal obtained via the signal line 82, and supplies it to the binary image decoding circuit 410.

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

以上が、本発明を適用した復号化回路の概要である。   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. ), And the configuration of the decoding circuit is different from the configuration of the prior art (the circuit of FIG. 4) in that a motion compensation prediction circuit 440 and a reduction circuit 450 are provided.

動き補償予測回路250または440には、先に符号化されたフレームの再生画像を蓄積するフレームメモリが具備されており、拡大回路230または420より供給される再生信号が蓄えられる。更に、動き補償予測回路250または440には、ここには図示していない動きベクトル信号が供給され、この動きベクトル信号にしたがって動き補償予測信号を生成し、信号線41および信号線91を介して縮小回路260または450に供給する。   The motion compensation prediction circuit 250 or 440 includes a frame memory for storing a reproduced 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, a motion compensation prediction signal is generated according to the motion vector signal, and the motion compensation prediction signal is generated via the signal line 41 and the signal line 91. It is supplied to the reduction circuit 260 or 450.

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

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

縮小回路260または450においては、信号線41および信号線91を介して供給される動き補償信号を、信号線60および信号線82を介して供給される縮小・拡大率の設定情報信号に応じて縮小した後、信号線42および信号線92を介して出力する。   In the reduction circuit 260 or 450, the motion compensation signal supplied through the signal line 41 and the signal line 91 is changed according to the reduction / enlargement ratio setting information signal supplied through 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値画像符号化して出力する。   When configured as the binary image encoding circuit 220, the resolution-reduced and converted alpha map signal supplied via the signal line 21 is encoded into a binary image and output.

ここで、本具体例にかかる2値画像符号化回路220が上述した先行技術と根本的に異なる点は、信号線42を介して供給される、解像度縮小変換されたアルファマップの動き補償予測信号を利用して符号化する機能を具備していることである。
このことについて、詳しく説明する。
Here, the point that the binary image encoding circuit 220 according to this example is fundamentally different from the above-described prior art is that the motion compensation prediction signal of the resolution-reduced and converted alpha map supplied via the signal line 42 is provided. In that it has a function of encoding 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 image blocks of the N × M pixel configuration in the image of the frame image unit.

図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. “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 a premise of application 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. Was.

一方、本発明では、参照変化画素b1を動き補償予測信号である“compensated block ”内から検出しており、この点が新しい概念である。すなわち、現在の処理対象画像のブロックに対応するアルファマップの該当ブロック上での参照変化画素b1を、動き補償予測信号である“compensated block ”内から検出している。   On the other hand, in the present invention, the reference change pixel b1 is detected from within the "compensated block" which is a motion compensation prediction signal, and this point 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 within the “compensated block” that is the motion compensation prediction signal.

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

図14において、a0 は起点変化画素であり、すでに起点変化画素a0 までは符号化が済んでいる。また、a1 は、起点変化画素a0 の次の変化画素であり、b0 は、“ compensated block”内において、a0 と同じ位置の画素(変化画素とは限らない)である。また、a0 (b0 )が属するラインを“a0 - line”と表記すると、参照変化画素b1は次のように定義される。   In FIG. 14, a0 is a starting-point changing pixel, and encoding has been completed up to the starting-point changing pixel a0. Also, a1 is the next change pixel after the starting point change pixel a0, and b0 is a pixel at the same position as a0 (not necessarily a change pixel) in the "compensated block". When the line to which a0 (b0) belongs is denoted 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 upper left pixel of the block is “0”.

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

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

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

なお、“a0 - line”および“r_ai (i=0 〜1)”、“r_b1 ”の値は、以下の式で求められる。   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 equation, * indicates multiplication, (int) (X) indicates truncation of X below the decimal point, and WIDTH indicates the number of pixels in the block in the horizontal direction.

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

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

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

更に、参照変化画素b1を“current block ”内より検出するか、“ compensated block”内より検出するかを、たとえばブロック単位で切り替えるようにすることもできる。この際、2値画像符号化回路220では切り替え用の情報も併せて符号化し、2値画像復号化回路410では当該切り替え用の情報も復号化して、復号化処理の際には当該切り替え用の情報に基づいて、参照変化画素b1を“current block ”内より検出するか、“ compensated block”内より検出するかを、たとえばブロック単位で切り替えるようにする。   Furthermore, whether to detect the reference change pixel b1 from within the “current block” or from within the “compensated block” can be switched, for example, in block units. 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. On the basis of the information, whether to detect the reference change pixel b1 from within the “current block” or from within the “compensated block” is switched, for example, in block units.

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

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

以上、第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 device that encodes a plurality of frames of moving image signals obtained as time-series data for each object having an arbitrary shape. Means for dividing a rectangular area including an object into blocks each including M × N pixels (M: the number of pixels in the horizontal direction, N: the number of pixels in the vertical direction). Means for sequentially encoding the blocks in the rectangular area according to a predetermined rule, wherein the binary image encoding apparatus applies relative address encoding to all or a part of the blocks.
Means for storing a reproduction value of a block vicinity, a 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 a means for detecting a changed pixel including the reproduced value of the reference address. The reference changed pixel for relative address coding is obtained not from the pixel value in the block but from the motion compensation prediction signal.

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

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

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

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

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

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

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

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

図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 multiple pixel configuration of, for example, 16 × 16 pixels, and the squares indicate division boundaries. Each cell is a macroblock (MB).

2値で表現されたアルファマップの場合(オブジェクトを合成する際の重み係数も含めて多値で表現される場合もある)、オブジェクトの形状情報は画素毎に白か黒かのいずれかで表される。従って、図20に示されるように、アルファマップの画面における各マクロブロック(MB)の中身の状態は、“allW”(全て白)、“allB”(全て黒)、“Multi”(その他)の3種類のいずれかに分類される。   In the case of an alpha map represented by a binary value (there may be represented by a multi-value including a weight coefficient when combining objects), the shape information of the object is represented by either white or black for each pixel. Is done. Therefore, as shown in FIG. 20, the state of the contents of each macro block (MB) on the alpha map screen is “allW” (all white), “allB” (all black), and “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 person image, the background is “white” and the person part is “black”, so that the macro block (MB) including the boundary part of the object classified as “Multi” ) May be binary-coded. Also, among the blocks (MB) classified as “Multi”, when the motion compensation prediction error value is equal to or smaller than a set value (threshold), the block (MB) is copied with the motion compensation prediction value. As described above, when the mode of the macro block (MB) to be copied is expressed as “copy” and the mode of the macro block (MB) to be binary-plane image encoded is expressed as “coded”, the code of the macro block (MB) is expressed. 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 or decoding method in 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, the mode determination circuit 1100, the CR (reduction / enlargement ratio) determination circuit 1110, the selector 1200, the intra-block pixel value setting circuits 1400 and 1500, the motion compensation prediction circuit 1600, the binary image encoding circuit 1700, Reduction circuits 1710, 1730, 1740, enlargement circuit 1720, frame memory 1300, transposition circuits 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 intra-block pixel value setting circuit 1400 is a circuit that generates pixel data that makes all the pixel values in the macroblock white, and the intra-block pixel value setting circuit 1500 sets all the pixel values in the macroblock to black. This is a circuit that generates pixel data.

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

また、転置回路1750はこのスキャンタイプ(ST)判定回路1770の出力するスキャン方向情報b4を基に、前記縮小回路1710の縮小処理した1フレーム分のアルファマップ信号について各マクロブロックの位置を、転置処理する回路であり、転置回路1760はスキャンタイプ判定回路1770の出力するスキャン方向情報b4を基に、前記縮小回路1710,1720,1730の出力を転置処理して出力する回路であり、2値画像符号化回路1700はこれらの転置回路1750、1760を介して与えられた縮小アルファマップ信号を符号化処理して出力するものである。   In addition, the transposition circuit 1750 transposes the position of each macro block for one frame of the alpha map signal reduced 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 transposes 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 transposed data. The encoding circuit 1700 encodes and outputs the reduced alpha map signal provided through these transposition circuits 1750 and 1760.

また、拡大回路1720は縮小回路1710を介して与えられるアルファマップ信号を前記CR判定回路1110の出力する縮小・拡大率で拡大処理する回路であり、動き補償予測回路1600はフレームメモリ1300に蓄積されている参照フレームの再生画像を用いて動き補償予測信号を生成し、モード判定回路1100および縮小回路1740に出力するものであり、縮小回路1740は前記動き補償予測信号を前記CR判定回路1110の出力する縮小・拡大率で縮小処理する回路であり、縮小回路1730は前記フレームメモリ1300に蓄積されている参照フレームの再生画像を前記CR判定回路1110の出力する縮小・拡大率で縮小処理する回路である。   The enlargement circuit 1720 is a circuit that performs an enlargement process on the alpha map signal supplied via 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 compensation 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 for reducing the reproduction image of the reference frame stored in the frame memory 1300 at 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の出力をフレーム単位で記憶するメモリである。   The selector 1200 also controls the reproduction signal m0 from the intra-block pixel value setting circuit 1400, the reproduction signal m1 from the intra-block pixel value setting circuit 1500, and the motion compensation from the motion compensation prediction circuit 1600 according to the classification information output from the mode determination circuit 1100. The circuit selects and outputs a required signal from the prediction signal m2 and the reproduction signal m3 from the enlargement circuit 1720. The frame memory 1300 is a memory for storing the output of the selector 1200 in frame units.

また、モード判定回路1100は、動き補償予測回路1600からの動き補償予測信号と2値画像符号化回路1700からの符号化信号b4を参照して、アルファマップ信号入力線20を介して供給されるアルファマップ信号を解析し、マクロブロック毎に“allW”、“allB”、“copy”、“coded”の何れに分類されるかを判定すると共に判定結果をモード情報b0として出力するものである。   Further, 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 the macro block is classified into “allW”, “allB”, “copy”, or “coded”, and to output the determination result 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 an alpha map signal supplied via the alpha map signal input line 20, and the MV encoding circuit 1790 generates a motion vector detection circuit (MVE) 1780. Is encoded, and the encoding result is output as motion vector information b1. For example, when predictive coding is applied to the MV coding 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へと出力するものである。   The VLC (variable-length coding) / multiplexing circuit 1800 includes mode information b0 from the mode determining circuit 1100, motion vector information b1 from the MV coding circuit 1790, and reduction / encoding from the CR (reduction / enlargement ratio) determination circuit 1110. Receiving the enlargement ratio information b2, the scan direction information b3 from the scan type (ST) determination circuit 1770, and the binary coded information b4 from the binary image coding circuit 1700, these are variable-length coded, multiplexed, and multiplexed. 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. Then, in the alpha map encoding circuit 200 receiving this, the mode determination circuit 1100 analyzes the alpha map signal and classifies the macro block into any of “allW”, “allB”, “copy”, and “coded”. Is determined. Here, for example, the number of mismatched pixels is used as a classification evaluation / valuation standard.

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

モード判定回路1100によるこの分類情報b0は、信号線1020を介してセレクタ1200に供給され、セレクタ1200では該ブロックのモードが“allW”の場合は、ブロック内画素値設定回路1400においてブロック内画素値が全て白にされた再生信号m0を選択し、信号線40を介してフレームメモリ1300に供給し、該フレームの記憶領域に蓄えると共に、アルファマップ符号化回路200の出力として出力する。   The classification information b0 from the mode determination circuit 1100 is supplied to the selector 1200 via the signal line 1020. In the selector 1200, when the mode of the block is “allW”, the in-block pixel value setting circuit 1400 outputs the in-block pixel value. Selects the reproduced signal m0, which is all white, supplies it to the frame memory 1300 via the signal line 40, stores it in the storage area of the frame, and outputs it 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 pixel value setting circuit 1500 in the macroblock. When the mode of the block 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 mode of the macroblock 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 It 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(縮小・拡大率)が求められる。   The pixel value of the macroblock classified as “coded” by the mode determination circuit 1110 is reduced by the reduction circuit 1710 and then encoded by 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 (no reduction)”, “1/2 (1/2 for both horizontal and vertical)”, and “1/4 (1/4 for both horizontal and vertical)”, The CR determination circuit 1110 calculates a CR (reduction / enlargement ratio) in the next step.

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

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

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

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

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

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

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

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

“coded”に分類されたブロックの中には、フレーム内の参照画素を用いる“intra”符号化モードと、動き補償予測信号を参照する“inter”符号化モードとがある。ここで、intra/interの切り替えは、例えば、線1040を介して供給される2値画像符号化回路1700からの符号化情報をモード判定回路1100に供給し、符号量の少なくなるモードを選択すればよい。ここで、選択された符号化モード(intra/inter)の情報は、信号線1050を介して2値画像符号化回路1700に供給される。   The blocks classified as “coded” include an “intra” coding mode using a reference pixel in a frame and an “inter” coding mode using a motion compensation prediction signal. Here, for switching between intra and inter, for example, the coding information from the binary image coding circuit 1700 supplied via the line 1040 is supplied to the mode determination circuit 1100, and the mode in which the code amount is reduced is selected. Just 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 optimal 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. Also, information on the optimal mode is supplied from the mode determination circuit 1100 to the VLC / multiplexing circuit 1800 via the signal line 1060, and after being encoded, is multiplexed with other codes. Further, the motion vector detection circuit (MVE) 1780 detects an optimal motion vector. Here, there are various methods for detecting a motion vector, and the method for detecting a motion vector is not a main part of the present invention, and therefore will not be described here. The detected motion vector is supplied to the motion compensation prediction circuit 1600 via the signal line 1070, and after being encoded by the MV encoding circuit 1790, is supplied to the VLC / multiplexing circuit 1800 to be encoded. After that, it is 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 the reproduced image of the reference frame stored in the frame memory 1300 based on the motion vector signal supplied via the signal line 1070, and sets the signal line 1010 to The signal is output to the mode determination circuit 1100 and the reduction circuit 1740 via the output terminal.

以上の処理の結果、画質の良い、しかも、高圧縮率での画像符号化をすることができる。   As a result of the above processing, it is possible to perform image encoding with good image quality and at a 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より構成される。
<Configuration Example of Alpha Map Decoding Circuit>
FIG. 22 is a detailed configuration diagram of the alpha map decoding circuit 400.
As shown in the figure, the alpha map decoding circuit 400 includes a VLC (variable length coding) / separation circuit 2100, a mode reproduction circuit 2200, a selector 2300, pixel value setting circuits 2400 and 2500 in a macro block, and a motion compensation prediction circuit. 2600, a frame memory 2700, a binary image decoding circuit 2800, an enlargement circuit 2810, transposition circuits 2820 and 2850, reduction circuits 2830 and 2840, a binary image decoding circuit 2800, and a 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 coded bit stream of the multiplexed and transmitted alpha map, and outputs the mode information b0, the motion vector information b1, the reduction / enlargement ratio. The mode reproduction circuit 2200 receives the separated mode information b0 and separates it into information b2, scan direction information b3, and binary image coding information b4. The mode reproducing circuit 2200 receives the separated mode information b0, and outputs “allW”, “allB”, “copy”, This is a circuit for reproducing which of the four modes “coded”.

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

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

動きベクトル再生回路2900は、前記VLC(可変長符号化)・分離化回路2100により分離された動きベクトル情報b1を用いてマクロブロックの動きベクトルを再生する回路であり、動き補償予測回路2600はこの再生された動きベクトルを用いてフレームメモリ2700の蓄積参照フレームを再生画像から動き補償予測値m2を生成する回路であり、縮小回路2840は前記分離された縮小・拡大率情報b2の情報を用いて前記動き補償予測値m2を縮小処理するものであり、縮小回路2830は前記分離された縮小・拡大率情報b2の情報を用いて前記フレームメモリ2700の蓄積参照フレームの画像を縮小処理するものであり、転置回路2850は前記VLC(可変長符号化)・分離化回路2100により分離されたスキャン方向情報b3を基に、縮小回路2830,2840の出力する縮小画像を転置処理して2値画像復号化回路2800に出力する回路である。   The motion vector reproducing circuit 2900 is a circuit for reproducing a macroblock motion vector using the motion vector information b1 separated by the VLC (variable length coding) / separating circuit 2100, and the motion compensation prediction circuit 2600 A circuit for generating a motion-compensated predicted value m2 from a reproduced image using the reproduced reference frame in the frame memory 2700 using the reproduced motion vector. The reduction circuit 2840 uses the information of the separated reduction / enlargement ratio information b2. The reduction circuit 2830 performs reduction processing on the motion compensation prediction value m2, and performs reduction processing on the image of the reference frame stored in the frame memory 2700 using the information of the separated reduction / enlargement ratio information b2. , A transposition circuit 2850 is a scheme 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の出力した画像信号をフレーム単位で保持するメモリである。   The selector 2300 also controls the reproduction signals m0 and m1 of the intra-macroblock pixel value setting circuits 2400 and 2500, the motion compensation prediction value m2 of the motion compensation prediction circuit 2600, and the transposition circuit according to the mode information output from the mode reproduction circuit 2200. One of the reproduced signals m3 of 2820 is selected and output, and the frame memory 2700 is a memory for holding the image signal output from the selector 2300 in frame units.

このような構成のアルファマップ復号化回路400は、信号線80を介してアルファマップの符号化ビットストリームが供給される。そして、このビットストリームはVLD(可変長復号化)・分離化回路2100に供給される。   The alpha map decoding circuit 400 having such a configuration is supplied with an 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 outputs the mode information b0, the motion vector information b1, the reduction / enlargement ratio information b2, the scan direction information b3, and the binary image code. Separation into the conversion information b4. These separated information are managed in macroblock units.

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

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

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

同様に、該マクロブロックのモードが“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 macroblock pixel value setting circuit 2500, and the mode of the block is changed to “allB”. In the case of “copy”, the motion compensation prediction signal m2 generated by the motion compensation prediction circuit 2600 supplied via the signal line 2020 is selected. When the mode of the block is ゛ “coded”, The 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 memory to which the macro block belongs in the frame memory 2700. Output from the alpha map decoding circuit 400 as a decoded alpha map image. 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 macro block is reproduced. Here, the reproduced motion vector is supplied to a motion compensation prediction circuit 2600 via a signal line 2030. The motion compensation prediction circuit 2600 reproduces a reference frame stored in a frame memory 2700 based on the motion vector. A motion compensation 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に供給される。   Further, the separated reduction / enlargement ratio information b2 is supplied to a reduction circuit 2830 and an enlargement circuit 2810, and is also supplied to a binary image decoding circuit 2800, and the scan direction information b3 is supplied to transposition circuits 2820 and 2850. Is done.

そして、スキャン方向情報b3を受けた転置回路2820では、拡大回路2810より供給される、元のサイズに戻された該マクロブロックの再生信号の位置が転置される(水平方向のアドレスと垂直方向のアドレスが入れ替えられる)。また、スキャン方向情報b3を受けた転置回路2850では、縮小回路2830により縮小された該ブロック近傍の再生画素値と、縮小回路2840により縮小された動き補償予測信号とで、それぞれの信号の位置が転置される。   Then, in the transposition circuit 2820 that has received the scan direction information b3, the position of the reproduction signal of the macro block that has been returned to the original size and supplied from the enlargement circuit 2810 is transposed (the horizontal address and the vertical direction). Addresses are swapped). Further, in the transposition circuit 2850 that has received the scan direction information b3, the position of each signal is determined by the reproduced pixel value in the vicinity of the block reduced by the reduction circuit 2830 and the motion compensation prediction signal reduced by the reduction circuit 2840. Will be 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 coding information b4 of the macroblock separated by the separation circuit 2100 is used by using the 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 prior art, the outputs of the enlargement circuits 1720 and 2810 have image quality due to discontinuity in the oblique direction. Deterioration may occur, but in order to solve this problem, the enlargement circuits 1720 and 2810 may be provided with a filter for suppressing discontinuity in oblique directions.

なお、2値画像符号化回路1700と同様に、用いる2値画像復号化回路2800の構成は上述の第3の具体例に示した構成例に限らない。   Note that, similarly 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 not limited to the third specific example. Therefore, other examples will be described.

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

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

本具体例では、例えば、
[方式1]第3の具体例の方式(MMRに基づいた符号化方式)
と、
[方式2]マルコフモデル符号化を適応的に切り換えて符号化する方式
の両方式を備え、これらを適応的に選択して使用する形態を採用することを特徴としている。
In this specific example, for example,
[Method 1] Method of third specific example (encoding method based on MMR)
When,
[Method 2] A method of adaptively switching and encoding the Markov model coding is provided, and a method of adaptively selecting and using these 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 shown, 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 for encoding according to the above [method 1], and the binary image encoding circuit 4130 is a second binary image encoding circuit for encoding according to the above [method 2]. This 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 that selectively switches a signal of a processing target macroblock supplied from the transposition circuit 1750 via the signal line 4101 in accordance with a switching signal supplied via the signal line 4103. In step 4140, the signal is adaptively distributed to the first binary image encoding circuit 4120 and the second binary image encoding circuit 4130, and the divided macroblock signal is encoded.

符号化された情報は、信号線4102を介して出力される。なお、図24(a)では2値画像符号化回路1700に供給される信号の信号線1030,1050、転置回路1760からの信号線は、省略されている。   The encoded information is output via a 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 may be determined as appropriate switching information based on the image content, separately encoded as side information, and transmitted to the decoding side. You may make it.

これにより、画像内容に基づいた最適処理が可能になり、また、アプリケーションに応じて複数の符号化方式の中から適切なものを選択して使用することも可能になる。   This makes it possible to perform optimal processing based on the image content, and 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 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 for decoding an image encoded by the above [method 1], and the binary image decoding circuit 4230 is a first binary image decoding circuit. 2 is a second binary image decoding circuit that decodes a 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 to be displayed via the signal line 4201 is converted into a switching signal supplied via the signal line 4203. In response, selectors 4210 and 4240 adaptively distribute and decode to first binary image decoding circuit 4220 and second binary image decoding circuit 4230.

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

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

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

図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. 35A.

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

このようなものが“双一次内挿”という処理であり、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 processing is performed using only surrounding four pixels, a change in a wide range is not reflected, and discontinuity particularly in an oblique direction is likely to occur. As an example for solving this problem, an example in which a smoothing filter process (smoothing process) is performed after an enlargement process is performed is proposed in the prior invention (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 the size. In FIG. 36, the object area is indicated by a black circle, and the background (background) area is indicated by a white circle.

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

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

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

Figure 2004320808
FIG. 37 shows another example of the smoothing filter (smoothing processing filter). Assuming that the pixel at the center of the mask of 3 × 3 pixels shown in FIG. 37 is C, the upper left pixel is C, the upper right pixel is TR, the lower left pixel is BL, and the lower right pixel is BR with respect to C. , The filtered value of pixel C is determined by: Here, the value of the object is represented by “1”, and the value of the background is represented by “0”.
Figure 2004320808

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

このフィルタによれば、対象となる画素Cに対して斜め方向に位置する画素値の変化を考慮して画素Cの値を修正するため、斜め方向の不連続性が解消される。なお、スムーシングフィルタの構成は上記例に限ったものではなく、メディアンフィルタ等の非線形フィルタを用いても良い。   According to this filter, the value of the pixel C is corrected in consideration of a change in the pixel value positioned diagonally with respect to the target pixel C, so that 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 both horizontally and vertically two times 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 cross marks, that is, “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 is obtained by the logical expression of FIG.
Ip1 = Ia, Ip2 = Ib, Ip3 = Ic, Ip4 = Id
It becomes.
Therefore, since all the pixel values of the four interpolation pixels around the pixel A are Ia, 2 × 2 pixels of the enlarged image have the same value, and the smoothness is lost. Therefore, the above problem is solved by changing the weight of the 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 an interpolated pixel corresponding to the “x” position shown in FIG. 58A, 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 twice the value of Ia, Ib, Ic, If the sum with Id is greater than 2, it is set to "1", otherwise it is set to "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 Ib, Ia, Ic and Id is greater than 2, and "0" otherwise. 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 Ic and the sum of 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 twice the value of Id and Ia, Ib, and Ic is 2 or more, and "0" otherwise. Is shown.
In the case where the image is enlarged four times both horizontally and vertically, the above processing may be repeated twice.

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

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

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

Figure 2004320808
This will be specifically described. First, for example, a memory address is set to 4 bits, and Ip1, Ip2, Ip3, Ip4 obtained by the patterns of Ia, Ib, Ic, Id are added to the address obtained by arranging Ia, Ib, Ic, Id in the following table. Beforehand.
Figure 2004320808

この例は、“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が一義的に定まるテーブルを表している。   This example shows that when “Ia, Ib, Ic, Id” is “0, 0, 0, 0”, “Ip1, Ip2, Ip3, Ip4” is “0, 0, 0, 0”. When “Ia, Ib, Ic, Id” is “0, 0, 0, 1”, it means that “Ip1, Ip2, Ip3, Ip4” is “0, 0, 0, 0”. , Ib, Ic, Id "are" 0, 0, 1, 1 ", it means that" 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 ", it means that" Ip1, Ip2, Ip3, Ip4 "is" 0, 1, 1, 0 ". 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 data stored at the addresses are Ip1, Ip2, Ip3, and Ip4, when performing interpolation processing, Interpolated values can be obtained simply by inputting the addresses of 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 method is based on the context obtained by Ip1, Ip2, Ip3, and Ip4. It can be said that this embodiment determines the interpolation values Ip1, Ip2, Ip3, and Ip4.

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

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

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

内挿画素P2、P3、P4についても、それぞれの内挿位置とその位置を囲む直近の4個の参照画素の位置関係に応じて、図64(b),(c),(d)の点線で囲んだ画素を参照画素とする。   For the interpolation pixels P2, P3, and P4, the dotted lines in FIGS. 64B, 64C, and 64D correspond to the respective interpolation positions and the positional relationship between the four nearest reference pixels surrounding the positions. The pixels surrounded by are defined as reference pixels.

この際、図のように参照画素A〜Iの、内挿画素Pに対する相対的な位置が同じになるように配置(例えば、(b)は(a)を時計回りに90度回転した配置になっている)しておけば、同じ画素パターンを回転しただけのものは、同じコンデキストになるので、内挿画素P1〜P4で共通の内容のテーブルとしたメモリを用いることができる。   At this time, as shown in the figure, the reference pixels A to I are arranged such that the relative positions with respect to the interpolation pixels P are the same (for example, (b) is an arrangement obtained by rotating (a) clockwise by 90 degrees. If the same pixel pattern is simply rotated, the same context will be 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 macroblock of 4 × 4 pixels to 16 × 16 pixels, first expand a macroblock MB of 4 × 4 size to 8 × 8 size, and then expand a macroblock MB of 8 × 8 size. Is enlarged to a macroblock MB of 16 × 16 in size.

この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 having the size of 4 × 4 is enlarged to the size of 8 × 8. FIG. 65A shows the external reference pixels AT and AL when the macro block MB having the size of 8 × 8 is enlarged. The 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 pixels AT are arranged in 2 rows and 8 columns, the external reference pixels AL are arranged in 4 rows and 2 columns, the external reference pixels BT are arranged in 2 rows and 12 columns, and the external reference pixels BL are 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 the average values of the pixels at predetermined positions in the macro block that has already been reproduced. However, the binary image encoding circuit 1700 and the binary image decoding circuit 2800 refer to the external reference pixels AT and AL when encoding with a size of 4 × 4 pixels and have a size of 8 × 8 pixels. When encoding, since the external reference pixels BT and BL are referred to, the use of the external reference pixels BT and BL can avoid the waste that the external reference pixels are bothersomely obtained only for the enlargement processing.

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

Figure 2004320808
Here, if the external reference BT and BL are described in C language, which is a language for computer programming, from the external reference pixels AT and AL without calculating the average value,
Figure 2004320808

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

上述の処理は、図65の例えば、画素p1を画素p2と画素p3にコピーし、画素p4を画素p5と画素p6にコピーするというように、ATやALの値を繰り返して画素を追加処理していくことで、BTやBLを生成するものである。なお、C言語プログラム中の“[ ][ ]”は配列を示し、[ ]中の数字は10進数を示す。   In the above-described process, 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 numbers in [] indicate decimal numbers.

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

[縮小処理]
図38は、ブロック(マクロブロック)を縦横“1/2”のサイズに縮小する縮小処理の一例である。この例では、点線枠内領域一つ一つを単位縮小ブロック領域とすると、当該単位縮小ブロック領域内の2×2画素(各点線枠内における“O”で示した計4画素)毎の平均値(図38の“×”)を、その単位縮小ブロック領域での画素値としている。つまり、マクロブロックを縦横“1/4”のサイズに縮小する場合には、単位縮小ブロック領域毎に、その領域内の4×4画素毎の平均値を求めて、当該単位縮小ブロック領域での画素値とすればよいわけである。
[Reduction processing]
FIG. 38 shows an example of a reduction process for reducing a block (macroblock) to a size of “1/2” in the vertical and horizontal directions. In this example, assuming that each area within the dotted frame is a unit reduced block area, the average of every 2 × 2 pixels (total 4 pixels indicated by “O” in each dotted frame) within the unit reduced block area The value (“×” in FIG. 38) is a pixel value in the unit reduced block area. That is, when a macroblock is reduced to a size of “1/4” in the vertical and horizontal directions, an average value for each 4 × 4 pixel in the unit reduced block area is obtained, and the average value in the unit reduced block area is calculated. That is, 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 considering a certain unit reduced block area composed of pixels A, B, C, and D, 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. Does not calculate the average value of the pixels A to D, but includes the pixels E, F, G, H, I, J, K, L, M, N, O, and P in a wider range of pixel positions. Thus, an average value of these A to P may be obtained. That is, of the pixels in the adjacent unit reduced block area, a method is adopted in which the average value of the 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 to reduce the number of pixels in the unit reduced block area and reduce the size of the macroblock. Was. A macroblock can be reduced by mechanical thinning-out processing without such calculation.
An example will be described below. First, a process closed in a macro block will be described.

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

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

図41は、拡大処理を表す図である。図において、実線方形枠はマクロブロックを示しており、点線枠表示された部分の升目一つ一つが単位縮小ブロック領域を示している。単位縮小ブロック領域内の白丸印は現存画素を表わしており、内挿により画素数を増やしてマクロブロックの拡大を図るようにする。内挿される画素は“×”で表されており、内挿後は“O”の画素は不要画素となる。   FIG. 41 is a diagram illustrating the enlarging process. In the figure, a solid rectangular frame indicates a macroblock, and each cell in a portion indicated 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 macro block. Pixels to be interpolated are represented by “x”, and after interpolation, “O” pixels are unnecessary pixels.

マクロブロック境界部の画素を内挿する際に、マクロブロック外の画素値が必要になる。この場合、図の矢印で示されているように、マクロブロック内の最も近くの画素値を割り当てればよい。
すなわち、ある単位縮小ブロック領域の画素内挿をする場合、自己及び自己と隣接する各単位縮小ブロック領域である周囲8ブロックの画素値の計9画素分の画素値が、処理に必要である。しかし、マクロブロック内における当該ある単位縮小ブロック領域が、マクロブロック境界部に位置していると、前記の周囲8ブロックのいくつかは自己の所属外のマクロブロック所属のものとなることから、当該自己所属マクロブロック外の画素値を別途、もらってくる必要があるということになる。この場合は、図の矢印で示されているように、自己の所属マクロブロック内の最も近くの画素値をそれぞれ割り当てて便宜的にその処理に必要な近隣の単位縮小ブロック領域での画素値とし、利用すればよい。
When interpolating pixels at the macroblock boundary, pixel values outside the macroblock are required. In this case, as shown by the arrow in the figure, the closest pixel value in the macro block 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 blocks, which are the unit reduced block area and the unit reduced block area adjacent thereto, are necessary for the processing. However, if a certain unit reduced block area in a macroblock is located at a macroblock boundary, some of the surrounding eight blocks belong to a macroblock that does not belong to the own block. This means that it is necessary to separately obtain a pixel value outside the macro block belonging to itself. In this case, as indicated by the arrow in the figure, the nearest pixel value in the macroblock to which the own device belongs is assigned, and the pixel value in the neighboring unit reduced block area necessary for the processing is conveniently assigned. , Just 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 (blocks adjacent to the left, upper, upper left, upper right May be used.
This will be described specifically.
In FIG. 42, a solid rectangular frame indicates a certain block (macro block), and “x” marks indicate pixels of an image (standard magnification image) at a magnification of 1 ×. A macro block usually has a 16 × 16 pixel configuration. When a frame is compressed to 1 /, the pixels in the block have an 8 × 8 pixel configuration, and the previous 16 × 16 pixel configuration has a size of 2 × 2 pixels. Is represented by one pixel, the "O" mark in FIG. 42 represents an image of 2 × 2 pixels in this case in which the information of the representative point is represented by one pixel. The inside of the frame shown by the dotted line is the unit reduced block area, which is a four-pixel configuration (2 × 2) area in the standard magnification image. It is represented 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 the 1/2 reduced image to the original image size (restoring to the standard magnification image), the area of one pixel of the 1/2 reduced image is returned to the 4-pixel configuration, but is not closed within the macroblock. To do this by interpolation:
For example, in FIG. 42, consider a case where a pixel 1 or a pixel 2 in a certain unit reduced block area (an area within a dotted frame) of a certain macroblock is reproduced by interpolation. In this case, what exists at the time of the processing is the pixel information marked with “O”. Therefore, the existing pixels around the pixel 1 or the pixel 2 to be interpolated are the pixels 3, 4, 5, and 6, so that 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 macro block), and are pixels before enlargement (pixels of a 縮小 reduced image). Since this is a block at the position processed at the previous point in time, it is unnecessary data after this macroblock enlargement process, so it may have already been 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", the average value of pixels 7, 8, 9, and 10, which are the existing neighboring pixels in the macro block, is obtained, and the One of the methods is to use the value of “pixel 3” that has been obtained. However, if it is desired to reduce the calculation for calculating the average value, the number of pixels among pixels 7, 8, 9, and 10 out of a total of four pixels is used. The average value of the pixels 9 and 10 that are 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 diverted to the value of “pixel 3”, the calculation can be further omitted. Similarly, for “pixel 4”, a pixel value near the same is substituted. In a similar case, the interpolation of “pixel 11” includes, for example, the average value of pixels 14 and 15 instead of “pixel 12”, the pixel 16 instead of “pixel 13”, and the pixel 18 instead of pixel 18. The pixel 17 is used.

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

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

これにより、誤りの影響をこの“同期回復単位”で断ち切ることが可能となり、誤りの影響を受け難くなる。ここで、“同期回復単位”とは、図59(b)にUnなる符号を付して示した点線で囲まれる各領域を指す。“同期回復単位”は符号化領域CAを小さく区切った領域であるが、複数のマクロブロックで構成されることは変わりない。   As a result, the influence of the error can be cut off in this “synchronization recovery unit”, and the influence of the error is reduced. Here, the “synchronization recovery unit” refers to each area surrounded by a dotted line indicated by the reference symbol Un in FIG. 59B. The “synchronization recovery unit” is an area obtained by dividing the coding area CA into small pieces, but is still 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 a transmission error, the errored data is referred to. The processing method is performed only within a certain "synchronization recovery unit", and the adjacent "synchronization recovery unit" does not process by referring to the erroneous data. That is,

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

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

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

すなわち、双一次内挿の参照範囲よりも広い拡大参照範囲に含まれる画素を用いて内挿することで、より広い範囲の画素の傾向が反映されることになり、不連続性の問題が回避される。また、内挿に用いる画素の数が“4画素”のように偶数個であるよりも、“9画素”のように奇数個の方が、多数決効果が得られ、不連続性の回避効果がより一層顕著に得られる場合がある。   That is, by performing interpolation using pixels included in an enlarged reference range wider than the reference range of bilinear interpolation, the tendency of pixels in a wider range is reflected, and the problem of discontinuity is avoided. Is done. In addition, the majority decision effect is obtained when the number of pixels used for the interpolation is "odd number" such as "9 pixels", and the effect of avoiding discontinuity is smaller than that of "even pixels" such as "4 pixels". In some cases, it can be obtained 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), the reproduced pixels at a certain position in a macroblock in a 1/2 reduced image of a certain macroblock are p1, p2, p3, p4, and When those values (pixel values) are Ip1, Ip2, Ip3, and Ip4, these Ip1, Ip2, Ip3, and 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"
Can be represented by Where 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 indicate the pixel K, and l indicates the pixel L.

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

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

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

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

<アルファマップ符号化装置>
図25は、本具体例のアルファマップ符号化装置を説明する図である。この装置は縮小回路5300,5210,5260、2値画像符号化回路5220、拡大回路5230,5400、動き補償予測回路5250、多重化回路5240,5500とより構成される。
<Alpha map encoding device>
FIG. 25 is a diagram for explaining the alpha map encoding device of this example. This device includes reduction circuits 5300, 5210, 5260, a binary image encoding circuit 5220, enlargement circuits 5230, 5400, a 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 by the reduction circuit 5300 in frame units based on the reduction / enlargement ratio CR. The signal reduced in frame units is supplied to an alpha map encoding circuit 5200 via a 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 constituent elements 5210 to 5260 of the alpha map encoding circuit 5200 are respectively equivalent to those of the alpha map encoding circuit 200 of FIG. Since the components 210 to 260 have the same function, the description of the alpha map encoding circuit 5200 is omitted here. Further, since 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. 1, the configuration of the alpha map encoding circuit 5200 is as shown in FIG. A configuration equivalent to the alpha map encoding circuit 200 may be used.

アルファマップ符号化回路5200で符号化された符号化情報には、小領域毎の縮小・拡大率CRbが多重化されており、信号線5030を介して多重化回路5500に供給され、フレーム単位の縮小・拡大率CRの符号化情報と多重化され、信号線30を介して出力される。   The coded information coded by the alpha map coding circuit 5200 is multiplexed with the reduction / enlargement rate CRb for each small area, and is supplied to the multiplexing circuit 5500 via the signal line 5030, and is transmitted in frame units. It is multiplexed with the encoded information of the reduction / enlargement rate 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, and is enlarged via the signal line 40 after being enlarged based on the reduction / enlargement ratio CR in frame units. .

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

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

アルファマップ復号化回路6400は、図13のアルファマップ復号化回路400と等価なため、ここでは説明を省略する。また、図13のアルファマップ復号化回路400の構成は、図2のアルファマップ復号化回路400の構成を簡略化して表現したものであるため、アルファマップ復号化回路6400の構成は、図2のアルファマップ復号化回路400と等価な構成でも良い。   The alpha map decoding circuit 6400 is equivalent to the alpha map decoding circuit 400 in FIG. 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 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 of the reduction ratio CR in frame units, and outputs the reproduced signal from the signal line 90.

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

次にフレームメモリについて、触れておく。
図25、図26には明示していないが、符号化装置と復号化装置にはいずれも再生画像を蓄積するためのフレームメモリが必要である。図52は、フレーム毎の解像度の例を表した図である。本発明では、動き補償予測を用いているため、例えば、時刻nのフレームを符号化する際には、時刻n−1のフレームの解像度を時刻nのフレームでの解像度(この場合、縮小・拡大率)に一致させなければならない。ここで、フレームメモリに蓄積する再生画像が、アルファマップ符号化回路5200によって図52に示されるようにフレーム単位の解像度(この例の場合、時刻nのフレームならばCR=1/2(図52の(a))、時刻nのフレームならばCR=1(図52の(c)))で蓄積される場合と、元の解像度(時刻に関わらず、常に縮小・拡大率CR=1)で蓄積される場合の2通りが考えられる。
Next, the frame memory will be described.
Although not explicitly shown in FIGS. 25 and 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 the motion compensation prediction is used, for example, when encoding the frame at the time n, the resolution of the frame at the time n-1 is changed to the resolution of the frame at the time n (in this case, reduction / enlargement). Rate). Here, as shown in FIG. 52, the reproduced image stored in the frame memory is converted by the alpha map encoding circuit 5200 in frame unit resolution (in this example, CR = 1 / for a frame at time n (FIG. 52) (A)), if the frame is at time n, the frame is stored at CR = 1 ((c) in FIG. 52), and the frame is stored at the original resolution (reduction / enlargement ratio CR = 1 regardless of the time). There are two cases in which the data is accumulated.

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

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

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

また、図55の符号化装置は、縮小・拡大率CRの情報と拡大回路5400の出力情報をFM2なるフレームメモリに保持し、この保持情報をMC(動き補償予測回路)5250に与えるように構成したものであり、図56の復号化装置は、CRの情報と拡大回路6600からの出力を保存し、この保存出力を動き補償予測回路6440に与えるように構成したものである。   Further, the encoding apparatus shown in FIG. 55 stores information on the reduction / enlargement ratio CR and output information from the enlargement circuit 5400 in a frame memory of FM2, and supplies the held information to an MC (motion compensation prediction circuit) 5250. The decoding apparatus in FIG. 56 is configured to store the CR information and the output from the enlargement 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. 57A, and a specific configuration example of the frame memories FM2 and FM4 is as shown in FIG. 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. 57A, the frame memories FM1 and FM3 are reduced to correspond to the information of the frame memory m11 for storing the image of the current frame and the enlargement / reduction ratio CR to which the image held in the frame memory m11 is separately given. It comprises a reduction / enlargement circuit m12 for enlargement processing, and a frame memory m13 for storing the output reduced / enlarged by the reduction / enlargement circuit m12. The frame memories FM2 and FM4 are shown in FIG. As described above, the frame memory m21 for storing the image of the current frame, the reduction circuit m22 for reducing the image held in the frame memory m21 according to the information of the separately provided enlargement / reduction ratio CR, and the reduction processing by the reduction circuit m22 And a frame memory m12 for storing the 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 reproduced image of a corresponding resolution of 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. . The frame memory m11 stores all reproduced images of the current frame when the encoding of the current frame (for example, time n) is completed.

次に、縮小・拡大回路m12では、時刻n+1におけるフレームの符号化が開始される時点で、時刻nにおけるフレームの再生画像をフレームメモリm11から読み込み、時刻n+1におけるフレームのフレーム単位での縮小・拡大率CRと一致するように、縮小・拡大処理(解像度変換)を行う。   Next, at the time when the encoding of the frame at the time n + 1 is started, the reduction / enlargement circuit m12 reads the reproduced image of the frame at the time n from the frame memory m11 and reduces / enlarges the frame at the time n + 1 in frame units. 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 reduction / enlargement rate CR of the frame at time n is “1 /” as shown in FIG. 52A, and the frame at time n + 1 which is the next frame as shown in FIG. Since the reduction / enlargement ratio CR is “1”, in this case, the reduction / enlargement circuit m12 performs a process of converting the reduction / enlargement ratio CR from “1 /” to “1”.

縮小・拡大回路m12で解像度変換された時刻nにおける再生画像は、前フレームのフレームメモリm13に蓄積され、時刻n+1におけるフレームの動き補償予測の参照画像となる。   The reproduced image at the time n whose resolution has been converted 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 the time n + 1.

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

次に、縮小回路m22では、時刻n+1におけるフレームの符号化が開始される時点で、時刻nにおけるフレームの再生画像をフレームメモリm21から銃み込み、時刻n+1におけるフレームのフレーム単位での縮小・拡大率CRと一致するように、縮小処理(解像度変換)を行う。   Next, in the reduction circuit m22, at the time when the encoding of the frame at the time n + 1 is started, the reproduced image of the frame at the time n is loaded from the frame memory m21, and the frame at the time n + 1 is reduced and enlarged 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 Does not perform the resolution conversion process. In the case of the example of FIG. 52, when the current frame is at time n + 1, the resolution of the frame at time n + 2 is “1 /”, so the reduction circuit m22 changes the reduction / enlargement ratio CR from “1” to “1/1”. 2 ".

縮小回路m22で解像度変換された時刻nにおけるフレームの再生画像は、前フレームのフレームメモリm33に蓄積され、時刻n+1におけるフレームの動き捕償予測の参照画像となる。   The reproduced 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 serves as 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. The frame memories FM1 and FM3 are used to reproduce reproduced images of frame unit resolution supplied via the signal lines 5040 and 6090. Are stored in the frame memories FM2 and FM4, and the frame memories FM2 and FM4 store reproduced images of a resolution in frame units supplied via the signal lines 40 and 90. Various other configurations are conceivable.

(第6の具体例)
次に、マクロブロックの属性情報を符号化する方式の例を第6の具体例として説明する。まず、先行技術である特願平8−237053号にて、提案した方式の説明をする。
(Sixth specific example)
Next, an example of a method for encoding attribute information of a macroblock 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 illustrates an example of attribute information of a certain macroblock at time n and time n-1. However, the attribute information referred to here is “allW” (all the constituent pixels of the macroblock are white), “allB” (all the constituent pixels of the macroblock are black), “Multi” (the constituent pixels of the macroblock) Is information indicating the state of the contents of the macro block.
For example, "allW" is labeled with a code "0", "allB" is labeled with a code "3", and "Multi" is labeled with a code "1".

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

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

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

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

サイズが合わないときは、このようにしてサイズを合わせる。なお、サイズの合わせ方は前記の方法に限ったものではない。そして、最終的に、図30(b)の様に、時刻nのフレームでのサイズに合わせられた、時刻n−1のフレームでのラベルを、ここでは便宜上、時刻n−1’のラベルと表記して以下の説明に用いることにする。   If the sizes do 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. 30B, the label in the frame at the time n-1 adjusted to the size in the frame at the time n is referred to as a label at the time n-1 'for convenience. Notation will be used in the following description.

図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 results obtained with the same position are shown.

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

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

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

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

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

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

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

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

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

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

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

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

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

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

また、別のモードとして、符号化しようとしている対象の領域の、フレーム内における占有位置如何によって、符号化テーブルを切り替える方法もある。   As another mode, there is a method of switching an encoding table depending on an occupation position in a frame of an area 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 a frame, and there is a high probability that an object does not exist at the end of the frame.
Focusing on this, a table in which a short code is assigned to "allW" is used for a macroblock adjacent to the end of a frame, and a table in which a short code is assigned to "allB" is used for other macroblocks. , The code amount can be reduced without using prediction. This is the no prediction mode.

また、より単純に、複数の符号化テーブルを用意し、その符号化テーブルを切り替えて用いる方法もある。これの切り替え情報は、例えば、“同期回復単位”毎、あるいは、フレーム毎、シーケンス毎に符号化する。   There is also a simpler method in which a plurality of encoding tables are prepared and the encoding tables are switched and used. The switching information is encoded 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 specific example for realizing the above-described processing, and the flow of the 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 the present specific example that realizes the above-described processing. FIG. 32A shows an alpha map encoding device, 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. , A multiplexing circuit (MUX) 3170.

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

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

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

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

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

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

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

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

サイズ変更回路3150では、ラベルメモリ出力線3030を介して供給される、時刻n−1のフレームのラベル情報とサイズ情報と、信号線3020を介して供給される時刻nのサイズ情報とから、時刻n−1のラベル情報を時刻nのサイズに相当する様にサイズを変更したラベル情報をラベル符号化回路3160に供給する。   The size changing circuit 3150 obtains the time from the label information and the size information of the frame at the time n−1 supplied through the label memory output line 3030 and the size information at the time n supplied through the signal line 3020. The label information obtained by changing the size of the n-1 label information so as to correspond to the size of the 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 prediction value, and supplies the encoded information to the multiplexing circuit 3170. The multiplexing circuit 3170 multiplexes the coded information supplied from the block coding circuit 3130, the label coding circuit 3130, and the size information supplied via the label memory output line 3020 with the coded information supplied from the label coding circuit 3160. Thereafter, the signal is output via a signal line 3040.

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

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

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

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

また、ブロック復号化回路3240は、ラベル復号化回路3210より供給される、再生されたラベル情報にしたがって、ブロック毎にアルファマップ信号を再生する回路である。   The block decoding circuit 3240 is a circuit that reproduces an alpha map signal for each block according to 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 device having such a configuration will be described.
The separating circuit 3200 separates the coded information supplied via the signal line 3050 and supplies the coded information to the block combining 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 the time n using the information obtained by changing the size of the label information in the frame at the time n-1 supplied from the size changing circuit 3220 as a prediction 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 an alpha map signal for each block according to the reproduced label information supplied from the label decoding circuit 3210. The size changing circuit 3220 operates the same as the size changing circuit 3150, and the label memory 3230 operates the same as the label memory 3140.

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

ところで、このような先行技術としての発明では、フレーム内あるいはフレーム間において隣接する1ブロック(1マクロブロック)を参照してVLC(可変長符号化)テーブルを切り換えていた。この場合、フレーム間相関が高い場合には、“フレーム間の隣接ブロック”を参照し、フレーム間相関が低い場合には、“フレーム内の隣接ブロック”を参照して、VLCテーブルを切り換えていた。しかし、実際の応用では、フレーム間相関とフレーム内相関両方を利用した方が良い場合が多い。   By the way, in the invention as the prior art, the VLC (variable length coding) table is switched by referring to one adjacent block (one macroblock) within a frame or between frames. In this case, when the inter-frame correlation is high, the VLC table is switched by referring to “adjacent blocks between frames”, and when the inter-frame correlation is low, the “adjacent blocks in frame” is referred to. . However, in actual applications, it is often better to use both inter-frame correlation and intra-frame 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)” (where h, v, and t represent the horizontal, vertical, and time coordinate axes, 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 will be selected by referring to the table. Here, when the number of modes is three as shown in FIG. 29, if the number of reference blocks is three (three macroblocks), the number of VLC tables is three to the third power (= 27). Further, the number of reference blocks can be further increased (for example, “M (x−1, y−1, n)”, “M (x, y, n−2)”).

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

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

ここでは、前のフレームのラベルを予測に用いてブロックの属性情報を符号化する方式を説明する。   Here, a method of encoding the attribute information of the block 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 Using Label of Previous Frame for Prediction>
FIG. 43 is a block diagram of an encoding circuit as one specific example of the present invention. As shown in the figure, the 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. You.

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

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

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

一方、参照ブロック決定回路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 located 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 label 513 of the previous frame is also input to the prediction circuit 512 from the label memory 509, and the label at the position of the reference block 511 is sent to the label encoding circuit 508 as a prediction value 514. The label encoding circuit 508 switches the encoding table according to the predicted value 514, encodes the label information 507, and outputs a code 515.

ここで、符号化領域が常にフレームと等しい時は、参照ブロックは一つに決まる。しかし、符号化領域がフレームよりも小さく、かつ、前フレームと現フレームでその符号化額域の位置が異なる場合は、フレームの角を原点とする座標軸を用いるか、符号化領域の角を原点とする座標軸を用いるかで参照ブロックは異なってくる。   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 area is different between the previous frame and the current frame, use a coordinate axis whose origin is the corner of the frame or set the corner of the coding area to the origin. The reference block differs depending on which coordinate axis is used.

この座標軸の取り扱いについて詳しく説明する。   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の例である。   FIGS. 44A and 44B are examples of frame images Fn-1 and Fn at time n-1 and time n, and mode information MD of each macroblock of the coding area CA in each frame 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) And a specific example of determining a block to be referred to when encoding the mode information of the block is presented. This is to associate blocks based on the coordinate axes of the coding area.

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

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

図44のような例では、現フレームの原点Fc0と前フレームの原点Fp0を一致させて、フレームの座標軸上で最も近いブロック位置のブロックを参照ブロックとした方がよい。   In the example as shown in FIG. 44, it is preferable that the origin Fc0 of the current frame coincides with the origin Fp0 of the previous frame, and the block at the closest block position on the coordinate axis of the frame be 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 axes of the frame, the result is as shown in FIG. 45B. That is, in the example of FIG. 44, since there is a change between the left end and the upper end, the size of the left end and the upper end are set to “cut” or “copy” as shown in FIG. Will be. In this case, the blocks corresponding to the mode information of the current frame are, as shown in FIG. 45B, the only blocks that do not match are the three hatched blocks.

即ち、状況に応じて前フレームのラベルを、符号化領域の座標軸に基づいて変更するか、フレームの座標軸に基づいて変更するかを切り替えることにより、符号化効率の改善が図れる。座標軸の決定法は、符号化装置側で最適な方を選択して切り替え情報を送つても良いし、符号化装置と復号化装置とで共に既知の情報を用いて決定してもよい。   That is, encoding efficiency can be improved by switching between changing the label of the previous frame based on the coordinate axis of the coding area or changing the label based on the coordinate axis of the frame according to the situation. The method of determining the coordinate axes may be such that the encoding device selects the most appropriate one and sends the switching information, or the encoding device and the decoding device may determine the coordinate axes using 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 changes greatly from the frame Fn-1 in (a) to the frame Fn in (b), as when the camera is swung rightward. In the case of this example, as is apparent from the figure, since the position of the coding area in the frame is largely shifted, it is not advisable to determine the reference block based on the coordinate axes of the frame.

即ち、現フレーム(時刻n時点のフレームFn)と前フレーム(時刻n−1時点のフレームFn-1 )とでフレーム内での符号化領域CAの位置が大きくずれている場合には符号化領域の座標軸を用いた方がよく、フレーム内での符号化領域の位置があまりずれていない場合にはフレームの座標軸を用いた方がよい。   That is, if the position of the coding area CA in the current frame (the frame Fn at the time n) and the previous frame (the frame Fn-1 at the time n-1) is greatly different from each other, 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 current frame Fn and the previous frame Fn-1 is largely shifted is determined by 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 it.
That is, the coded data configuration in the moving picture coding apparatus using the alpha map together is as shown in FIG. 47 according to the standard. In other words, the coded data includes a coding area layer, a macroblock MB layer, and a binary shape layer, and the coding area layer includes coding area size information, coding area position information, coding area reduction / enlargement. Includes rate information. The MB layer includes binary shape information, texture MV information, multi-valued shape information, and texture information. The binary shape information includes mode information, motion vector information, reduction / enlargement rate information, scan direction information, and binary information. 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 coding area, and the coding area position information indicates information indicating the position of the coding area (Vp0, Vc0). The coding area reduction / enlargement rate information indicates reduction / enlargement rate (CR) information of a binary image in units of coding area.

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

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

符号化領域の位置(Vp0、Vc0の位置)を表す情報は、符号化領域位置情報に納められており、従って、この情報を用いることで符号化領域の位置(Vp0、Vc0の位置)を知ることができる。この情報を用いてフレームFn-1 とフレームFnを比較する。この比較はフレームのホームポジションから符号化領域のホームポジション位置までのベクトルをそれぞれ求めてこのベクトルによって行う。   Information indicating the position of the coding region (the position of Vp0, Vc0) is contained in the coding region position information, and therefore, the position of the coding region (the position of Vp0, Vc0) is known by using this information. be able to. The frame Fn-1 is compared with the frame Fn 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 the size of the coding area is hardly changed between the current frame and the previous frame, based on the coordinate axes of the coding area. It turns out 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. No additional information for identifying the

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

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

図48(b)は、図48(a)のラベル未定部分について、ラベルメモリ509のメモリ空間のうち、次のフレームの符号化領域532の部分だけを外挿し、その他の部分は上書きしない例であり、このようにすると、2フレーム以上前のフレームのラベルを予測に用いることができる。   FIG. 48B shows an example of extrapolating only the coding area 532 of the next frame in the memory space of the label memory 509 with respect to the label undetermined part of FIG. In this case, the label of the frame two or more frames earlier 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 any extrapolation or inserting a predetermined value.

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

ブロックMB1のラベルの符号化の予測には、ブロックMB2、MB3、MB4、MB5のいずれかのラベルを用いるのが適当であるが、その決め方にはいくつか方法がある。
まず、最も簡単で演算量が少ないのは、4つのうちの所定の位置(例えば左上)にあるブロックのラベルを用いる方法である。あるいは、4つのラベルに同じものがある時は、その数が最も多いラベルを予測値として用いるようにすれば、予測が当たる確率は高くなる。
It is appropriate to use any one of the labels of the blocks MB2, MB3, MB4, and MB5 for predicting the encoding of the label of the block MB1, but there are several methods for determining the label.
First, the simplest method with 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 the same label is used for the four labels, the probability of the prediction being high increases if the label having the largest number is used as the predicted value.

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

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

この場合は、全体が参照されているマクロブロックMB10のラベルを用いる。   In this case, the label of the macro block MB10 which 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 the reduction / enlargement ratio CR = 1/2 and the current frame has the reduction / enlargement ratio CR = 1. In this case, the macroblock MB19 is located at the lower right of the macroblock MB15 in the reduced frame. Will refer to the part. At this time, the label of the block MB15 is used as the predicted value, or the reference portion is close to the blocks MB16 to MB18. You may decide.

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

この復号化装置は、ラベル復号化回路516、ラベルメモリ517、参照ブロック決定回路518、予測回路520とから構成される。   This decoding device 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 them, 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 a process of 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 predicted value 522 from the label 521 of the previous frame and the reference block 519 and providing the predicted 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 device having such a configuration, the stream 515 of the encoded data to be decoded is input to the label decoding circuit 516, and the label is decoded.
On the other hand, the label that has been decoded so far is stored in the label memory 517. 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 coding device. The prediction circuit 520 also obtains a predicted value 522 from the label 521 of the previous frame and the reference block 519 in the same manner as the encoding device, and sends the predicted value 522 to the label decoding circuit 516. The label decoding circuit 516 switches the decoding table according to the predicted value 522 to decode and output the label 523.

また、あるブロックのモード“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, t respectively represent horizontal, vertical, and time-direction coordinate axes) of a certain block, for example, “M (x− The coding table is switched with reference to "1, (y, n)", "M (x, y-1, n)", "M (x, y, n-1)", etc., which are used here. A mode may include a set of modes described below (this will be referred to as a mode set A) including a part of information of a motion vector used for motion compensation.

[モード集合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, but in the case of mode set A (3), it is not necessary to encode the motion vector. When the probability that the motion vector is zero is high, using the mode set A can reduce the total of the code amount of the mode and the code amount of the motion vector.

この例において、“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 is 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 the above (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 images obtained when “copy (motion vector = 0)” are all black, the process proceeds to step A3; otherwise, the process proceeds to step A2.

ステップA2: “copy(動きベクトル==0)”とした時に得られる動き補償予測画像が全て白である場合は、ステップA4へ、そうでない場合は、ステップA5へ進む。   Step A2: If all motion-compensated predicted images obtained when “copy (motion vector == 0)” are 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: If “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 the mode set A. End of encoding.

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

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

復号化処理は図50のフローチャートと全く同じアルゴリズムで符号化テーブルをモード集合A用あるいはモード集合B用のいずれかに決定し、そのテーブルを用いて復号化する。   In the decoding processing, the encoding table is determined to be either for the mode set A or for the mode set B using exactly the same algorithm as in the flowchart of FIG. 50, and decoding is performed using the 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 predicted images obtained when “copy (motion vector = 0)” are 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 predicted 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: If “M (*, *, *)” to be referred to is “allB”, replace “M (*, *, *)” with “copy (motion vector == 0)”. Proceed to B6.

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

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

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

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

また、ブロックの属性としては、符号化のパラメータ、例えばブロックサイズやブロックの縮小率、符号化スキャンの方向、動きベクトルの値なども必要に応じて含めることもできる。スキャン方向を含めた例を示す。   Further, as the attributes of the block, encoding parameters such as a block size and a block reduction ratio, an encoding scan direction, a motion vector value, and the like can be included as necessary. An example including a 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”
Note that “==” indicates that the left side is equal to the value of the right side, and “! =” Indicates that the left side is not equal to the value of 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. That is, the alpha map is stored in the memory, and each time the attribute of each block is encoded, the attribute (“allW”, “Multi”, “allB”, etc.) of the reference block is determined, and the attribute is determined based on the attribute. Switch the encoding table.

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

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

前のフレームの参照する部分については、ブロック毎に与えられる動きベクトルを利用する方法もある。つまり、既に符号化の終わった、符号化ブロックに隣接するマクロブロックの動きベクトルによって指し示される部分を前のフレームから切り出し、それが、“allW″か、“Multi”か、“allB”かによって符号化テーブルを切り替える。   For a part to be referred to in the previous frame, there is a method using a motion vector given for each block. That is, a portion pointed by the motion vector of the macroblock adjacent to the coded block, which has already been coded, is cut out from the previous frame, and it is determined whether it is “allW”, “Multi”, or “allB”. Switch the encoding 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 a background from an object in a method of coding by dividing the screen into a background and an object when encoding an image. I do. Then, the alpha map signal is encoded together with the encoding information of the image to form a bit stream, which is transmitted or stored. The former is used for broadcasting and personal computer communication, and the latter is used for music CDs and the like. It will be traded as a product with content.

そして、商品として記憶媒体に記録した動画像コンテンツを提供する場合に、蓄積媒体に画像の符号化情報とこのアルファマップ信号の圧縮符号化したものとを合わせたビットストリームで蓄積して、一つの媒体で長時間に亘るコンテンツを納めて映画などを鑑賞できるようにするが、このようなアルファマップの画像を含む圧縮符号化したビットストリームを格納した蓄積媒体を対象とする再生システムの例を次に第7の具体例として説明する。   Then, when providing moving image content recorded on a storage medium as a product, the encoded information of the image and the compressed and encoded version of the alpha map signal are accumulated in a storage medium as a bit stream, and one The following describes an example of a playback system that targets a storage medium storing a compression-encoded bit stream including an image of an alpha map. 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 example of medium for storing information according to the present invention>
This specific example will be described with reference to FIGS. FIG. 27 is a code sequence of mode information b0, motion vector information b1, reduction / enlargement ratio information b2, scan direction information b3, and binary image coding information b4 multiplexed in the VLC / multiplexing circuit 1800 of FIG. Is shown. In the present invention, when decoding the binary image encoding information b4, the information b0 to b3 needs to be decoded. If the mode information b0 has not been decoded prior to all other information bl to b4, other information cannot be decoded. Therefore, the information b0 to b4 must have a configuration in which mode information is arranged at the beginning and binary plane image encoding information is arranged at the end as shown in FIG.

図28は、図27で示される符号列が蓄積される記録媒体8100を用いて画像信号を再生するシステムを示す図である。記録媒体8100には、図27で示された符号列を含む符号列が蓄積されている。8200はこの蓄積媒体8100に蓄積されている符号列から、画像信号を再生するデコーダであり、8300は再生画像を出力する画像情報出力装置である。   FIG. 28 is a diagram illustrating a system that reproduces an image signal using the recording medium 8100 in which the code string illustrated in FIG. 27 is stored. A code sequence including the code sequence shown in FIG. 27 is stored in the recording medium 8100. Reference numeral 8200 denotes a decoder that reproduces an image signal from the code string stored in the storage medium 8100, and reference numeral 8300 denotes an image information output device that outputs 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. 27 is stored in the storage medium 8100. 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 according to the procedures shown in FIGS. Here, FIG. 34 is a flowchart of the step (S5) of “binary image reproduction” in FIG.

図33,図34に従って、デコーダ8200での処理を内容を説明する。すなわち、まずはじめにモード情報が復号され(ステップS1)、その復号されたモード情報が“allW”,“allB”,“copy”のいずれかに該当するか否かを調べる(ステップS2,S3,S4)。   The processing in the decoder 8200 will be described in detail with reference to FIGS. That is, first, the 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, and the processing is completed (step S6). If “allB” instead of “allW”, all the pixel values in the macroblock are changed. If the processing is finished in black (step S7), and if it is neither "allW" nor "allB" but "copy", the motion vector is decoded with information (step S8), and motion compensation prediction is performed (step S8). In step S9), the inside of the macro block is copied with the obtained 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 neither "allW" nor "allB" or "copy" in steps S2, S3 and S4, the process proceeds to the binary image reproduction process (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 coding is “inter” coding (step S21). As a result, if the coding is “inter”, the motion vector information is decoded (step S25), the motion compensation prediction is performed (step S26), and the reduction / enlargement ratio information is decoded (step S22). The decryption is performed (step S23). Then, the binary coded 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 that the encoding is not "inter", the reduction / enlargement ratio information is decoded (step S22), and the scan direction information is decoded (step S23). Then, the binary coded 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, so that the reproduced 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 described in the specific example above, in the case of an encoding / decoding device that combines reduction / enlargement in units of frames and reduction / enlargement in units of small regions, information on the frame unit reduction / enlargement ratio is shown in FIG. Must be reproduced prior to the small area unit code string shown in (1), the code of the frame unit reduction / enlargement ratio is located before all the small area unit code strings in the frame.

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

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

図21、図22は、本発明のフレームワークを表す図である。図21において、動きべクトル検出回路1780で検出された動きベクトルは、信号線1070を介してMV符号化回路1790に供給され、符号化された後、VLC・多重化回路1800に供給され、他の符号化情報と多重化されて線30を介して出力される。   FIG. 21 and FIG. 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 an MV encoding circuit 1790 via a signal line 1070, encoded, and then supplied to a VLC / multiplexing circuit 1800. Multiplexed with the encoded information of

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

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

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

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

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

例えば、MVPsの水平・垂直成分MVPs_hおよびMVPs_vは、以下のように求められる。   For example, the horizontal / 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 of calculating the median of the values in “()”, and the horizontal and vertical components of the motion vector MVsn (n = 1, 2, 3) are
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 a motion vector exists 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 defined as MVPs. There are ways.

図67(a),(b)は、時刻n−1と時刻nにおけるフレーム画像Fn−1、Fnとそれぞれのフレームにおける符号化領域CAn−1、CAnの例である。ここで、符号化対象ブロック周辺のブロックがオブジェクトを含まないブロックの場合、そのブロックには動きべクトルが存在しない。また、フレーム内符号化されたブロックの場合にも、そのブロックには動きべクトルが存在しない。   FIGS. 67A and 67B show examples of frame images Fn-1 and Fn at time n-1 and time n, and coding areas CAn-1 and CAn in each frame. Here, when a block around the current block is a block that does not include an object, the block does not have a motion vector. Also, in the case of an intra-coded block, no motion vector exists in the 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 for the prediction vector MVPs.
When the motion of the object is small, there is no problem if this default value is set to “zero vector” which is a zero motion vector. However, as shown in the transition from the frame of FIG. 67 (a) to the frame of FIG. When the movement of the position of the object in the frame is large, the motion vector cannot be predicted, and the coding efficiency is reduced.

本発明ではこのデフォルト値として、図67(a)に示されたベクトル“prev_ref”と図67(b)に示されたベクトル“curr_ref”との差分ベクトル“offset”と、“ゼロベクトル”とを適応的に切り換えて用いることを特徴とする。   In the present invention, as the default values, a 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 adaptively switched for use.

ここで、“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
Switching between the default values “offset” and “zero vector” is performed based on, for example, the error value of the object at time n and the object at time n−1 obtained based on the coordinate axes of the frame, and the coordinate axis of the coding area. The error value of the object at the time point n and the error value of the object at the time point n-1 are compared. If the former is larger, “offset” is used. If the latter is larger, “zero vector” is used. What is necessary is just to use it.

この場合、切り替え情報として1ビットのサイド情報を送る必要がある。また、このような動きベクトルの予測値のデフォルト値として、“offset”と“ゼロベクトル”を切り替えることは、テクスチャ情報の動きベクトルの予測符号化にも同様に適用できる。   In this case, it is necessary to send 1-bit side information as switching information. 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 encoding 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 shown in FIG. 21 and a specific configuration example of the MV reproduction circuit 2900 shown in FIG. 22 will be described as a ninth specific example.

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

図68(a)に示す付帯回路としてのデフォルト値演算回路は、オブジェクト領域について、現時点での処理フレームと、前時点での処理フレームとから、前時点から見た現時点でのフレームのオブジェクトの位置移動を、フレーム間での動きベクトル値として求めるためのものであり、図68(a)において、e10は符号化領域検出回路、e11はデフォルト値決定回路、e12は領域情報メモリ、e13はオフセット算出回路、e14はセレクタである。   The default value calculation circuit as an additional circuit shown in FIG. 68 (a) calculates the position of the object in the current frame as viewed from the previous time from the processing frame at the current time and the processing frame at the previous time 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. The circuit, e14, is a selector.

また、e1は現時点でのフレームデータを入力するための信号線であり、図21におけるシステムの信号線20に該当するもので、当該信号線20から入力される現時点のフレームデータを入力として受けるためのものである。また、図68(a)におけるe2は、フレームメモリ1300に保持された前時点フレームデータを供給するための信号線であり、この信号線e2を介して、フレームメモリ1300から前時点のフレームデータの供給を受ける。また、e3はデフォルト値決定回路e11からのフラグの情報を出力する信号線であり、e4は符号化領域検出回路e10からの符号化領域CAnの情報を供給する信号線であり、e6は領域情報メモリe12から読み出される符号化領域CAn−1の位置情報を供給する信号線である。   In addition, e1 is a signal line for inputting the current frame data, which corresponds to the signal line 20 of the system in FIG. 21, and is for receiving the current frame data input from the signal line 20 as an input. belongs to. Further, e2 in FIG. 68 (a) is a signal line for supplying the previous frame data held in the frame memory 1300, and the signal of the previous frame data is transmitted 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 storing information on the size and position of the coding area CAn-1, and after the coding of the frame at the time n is completed, the size and position information of the coding area CAn is obtained. Will be accumulated.

オフセット算出回路e13は、信号線e4を介して供給される符号化領域CAnと、信号線e6を介して供給される符号化領域CAn−1の位置情報を用いて、ベクトル値“offset”を求め、それをセレクタe14に与えるものである。   The offset calculation circuit e13 obtains a 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. , To the selector e14.

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

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

これらのうち、MVメモリ1791は図21における信号線1070を介して供給される動きベクトル検出回路1780からの動きベクトル情報を保存するメモリであり、符号化対象ブロックの周囲の動きベクトルMVsn(n−1,2,3)がこのMVメモリ1790に保持される。   Among them, 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− 1, 2, 3) are stored 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 that obtains prediction vectors MVPs based on the motion vectors MVsn (n-1, 2, 3) around the encoding target block supplied from the MV memory 1791. Here, if MVsn (n−1, 2, 3) does not exist, the prediction vector MVPs cannot be obtained normally, and the MV prediction circuit 1792 determines whether the prediction vector MVPs has been obtained normally. And a function of supplying the identification signal to the selector 1793 via 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 a default value provided via the signal line e5 as inputs, and selects one of the two 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 prediction error signal of a motion vector. The difference circuit 1794 is provided with a motion vector information supplied from a motion vector detection circuit 1780 via a signal line 1070 and MVPs or a default value supplied via a selector 1793 , And outputs the result as motion vector information b1 from the MV encoding circuit 1790.

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

符号化領域検出回路e10では、フレーム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 frame Fn-1, and outputs the detection result via a signal line e4 to a default value determination circuit e11. 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 of the coding area CAn from the coding area detection circuit e10 supplied via the signal line e4 and the coding supplied from the area information memory e12 via the signal line e6. Using the size and position information of the area CAn-1, the error amount between the frame Fn and the frame Fn-1 is compared with the error amount between the coding area CAn and CAn-1. As a result of the comparison, if the former is large, it is determined that “offset” is used as a default value, otherwise, a zero vector is used as a default value, and “offset” is used as a default value, or The flag information for identifying whether to use the 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. Is multiplexed on the layer of the coding area in the data format of. Then, the data is transmitted or stored 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 stores the size and position information of the coding area CAn after the coding at the time n is completed. .

オフセット算出回路e13では、信号線e4を介して供給される符号化領域CAnと、信号線e6を介して供給される符号化領域CAn−1の位置情報を用いて、ベクトル値“offset”を求めた後、セレクタe14に供給する。   The offset calculating circuit e13 obtains a 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. After that, the data is supplied to the selector e14.

セレクタe14では、信号線e3を介してデフォルト値決定回路e11から供給されるフラグに従って、“offset”とゼロベクトルとの何れかが選択され、これをデフォルト値とする。そして、このデフォルト値は信号線e5を介してMV符号化回路1790のセレクタ1793に出力される。   In the selector e14, one of “offset” and the zero vector is selected according to a flag supplied from the default value determination circuit e11 via the signal line e3, and this is set as a default value. Then, 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 encoding target block is supplied to the MV encoding circuit 1790 of FIG. 68B via a 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 vectors MVsn (n-1, 2, 3) around the encoding target block from the MV memory 1791, and obtains prediction vectors MVPs. Here, if MVsn (n−1, 2, 3) does not exist, the prediction vector MVPs cannot be obtained normally, and a signal for identifying whether or not the prediction vector MVPs has been obtained normally is generated. Is supplied to the selector 1793 via the signal line 1795.

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

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

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

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

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

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

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

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

MV再生回路2900は、図69(b)に示すように、加算回路2901、セレクタ2902、MV予測回路2903、MVメモリ2904とからなる。
これらのうち、加算回路2901は、復号化対象ブロックの動きベクトルの予測誤差信号である動きベクトル情報b1とセレクタ2902を介して与えられるデフォルト値とを受けて、両者を加算して出力する回路であり、この加算出力はMVメモリ2904並びに図22の構成における信号線2030に出力される構成である。
The MV reproducing circuit 2900 includes an adding circuit 2901, a selector 2902, an MV prediction circuit 2903, and an MV memory 2904, as shown in FIG.
Among these, the addition circuit 2901 receives the motion vector information b1 which is the prediction error signal of the motion vector of the decoding target block and the default value given via the selector 2902, and adds and outputs both. 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 holds the addition output of the addition circuit 2910 and supplies the motion vector MVsn (n = 1, 2, 3) around the block to be decoded. The circuit 2903 obtains the prediction vector MVPs from the motion vector 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. If MVsn (n = 1, 2, 3) does not exist, the prediction vector MVPs cannot be obtained normally, so the MV prediction circuit 2903 identifies whether the prediction vector MVPs has been obtained normally. A signal generation function is provided, and this identification signal is supplied to a selector 2902 via 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 provided to the addition 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 to use “offset” or a zero vector as a default value is supplied to the signal line d1, and positional information of the area 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 for storing the position information of the area CAn-1, and stores the position information of the area CAn after the decoding at the time n is completed.

オフセット算出回路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 region CAn supplied via the signal line d2 and the position information of the region CAn-1 supplied via the signal line d3. After that, the vector value “offset” is supplied to the selector d12.

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

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

また、MV予測回路2903には、MVメモリ2904から復号化対象ブロックの周囲の動きベクトルMVsn(n=1,2,3)が供給され、予測ベクトルMVPsが求められる。ここで、MVsn(n=1,2,3)が存在しない場合は、予測ベクトルMVPsが正常に求められないため、予測ベクトルMVPsが正常に求められたか否かを識別する信号を信号線2905を介してセレクタ2902に供給する。   Further, 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 predicted vector MVPs cannot be obtained normally, and a signal for identifying whether or not the predicted vector MVPs has been obtained normally is sent through the signal line 2905. The signal is supplied to the selector 2902 via the selector.

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

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

このようにして、図21に示す構成での必要なMV符号化処理と、図22に示す構成での必要なMV再生処理が実現できる。   In this way, the necessary MV encoding processing in the configuration shown in FIG. 21 and the required MV reproduction processing in 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 information of an alpha map, which is sub-image information representing the shape of an object, a position in a screen, and the like, and to decode the information. Thus, an image encoding device and a decoding device capable of performing the above are obtained.

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

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

本発明を適用する前提となる符号化装置の全体の概略的な構成を示すブロック図。FIG. 1 is a block diagram illustrating a schematic configuration of an entire encoding device to which the present invention is applied. 本発明を適用する前提となる復号化装置の全体の概略的な構成を示すブロック図。FIG. 1 is a block diagram showing a schematic configuration of an entire decoding device to which the present invention is applied. 本発明を適用する前提となる符号化装置におけるアルファマップ符号化回路の構成を示すブロック図。FIG. 1 is a block diagram showing a configuration of an alpha map encoding circuit in an encoding device to which the present invention is applied. 本発明を適用する前提となるアルファマップ復号化回路の構成を示すブロック図。FIG. 2 is a block diagram showing a configuration of an alpha map decoding circuit to which the present invention is applied. 本発明の第1の具体例にかかる符号化回路の一具体例を示すブロック図。FIG. 2 is a block diagram showing a specific example of an encoding circuit according to a first specific example of the present invention. 本発明の第1の具体例にかかる復号化回路の一具体例を示すブロック図。FIG. 2 is a block diagram showing a specific example of a decoding circuit according to a first specific example of the present invention. 本発明の第1の具体例を説明するための図であって、変化画素b1の周囲の様子の例を示す図。FIG. 9 is a diagram for explaining the first specific example of the present invention, and is a diagram illustrating an example of a state around a change pixel b1. 本発明の第1の具体例を説明するための図であって、参照画素の例を示す図。FIG. 4 is a diagram for describing a first specific example of the present invention, and is a diagram illustrating an example of a reference pixel. 本発明の第1の具体例を説明するための図であって、コンテキスト番号の決定方法を説明するための図。FIG. 6 is a diagram for explaining a first specific example of the present invention, and is a diagram for explaining a method of determining a context number. 本発明の第2の具体例にかかる符号化回路例を示すブロック図。FIG. 9 is a block diagram showing an example of an encoding circuit according to a second specific example of the present invention. 本発明の第2の具体例にかかる復号化回路の具体例を示すブロック図。FIG. 14 is a block diagram showing a specific example of a decoding circuit according to a second specific example of the present invention. 本発明の第3の具体例にかかる符号化回路の具体例を示すブロック図。FIG. 13 is a block diagram showing a specific example of an encoding circuit according to a third specific example of the present invention. 本発明の第3の具体例にかかる復号化回路の具体例を示すブロック図。FIG. 14 is a block diagram showing a specific example of a decoding circuit according to a third specific example of the present invention. 本発明の第3の具体例を説明するための図であって、フレーム間符号化における変化画素の検出手段を説明する図。FIG. 10 is a diagram for explaining a third specific example of the present invention, and is a diagram for explaining a change pixel detecting unit in inter-frame coding. スキャン方向切り替えを説明する図。FIG. 3 is a diagram for explaining switching of a scanning direction. アルファマップを説明する図。The figure explaining an alpha map. 先行技術を説明するための図であって、VLCテーブル(可変長符号化テーブル)の例を示す図。FIG. 9 is a diagram for explaining the prior art, and is a diagram illustrating an example of a VLC table (variable length encoding table). 先行技術を説明するための図であって、ブロック単位で符号化する場合の変化画素の関係を表す図およびb1を検出する為の参照領域を表す図(ブロックベース符号化の変化画素の関係と参照領域を表す図)。7A and 7B are diagrams for explaining the prior art, showing a relationship between changed pixels when encoding is performed in block units and a diagram showing a reference region for detecting b1 (the relationship between the changed pixels in block-based encoding and Diagram showing a reference region). 先行技術を説明するための図であって、MMRをブロックベースで符号化する場合のフローチャート。FIG. 9 is a diagram for explaining the prior art, and is a flowchart in a case where MMR is encoded on a block basis. 本発明で用いるアルファマップの画面内を所定の複数画素構成によるマクロブロック(MB)単位に分割した様子を示す図。FIG. 4 is a diagram showing a state in which a screen of an alpha map used in the present invention is divided into macroblock (MB) units having a predetermined plural pixel configuration. 本発明の第4の具体例におけるアルファマップ符号化回路の構成例を示すブロック図。FIG. 14 is a block diagram illustrating a configuration example of an alpha map encoding circuit according to a fourth specific example of the present invention. 本発明の第4の具体例におけるアルファマップ復号化回路の構成例を示すブロック図。FIG. 14 is a block diagram illustrating a configuration example of an alpha map decoding circuit according to a fourth specific example of the present invention. マルコフモデル符号化を説明するための図。FIG. 3 is a diagram for explaining Markov model coding. 複数の2値面像符号化法を切り換えて使用する2値画像符号化回路および2値画像復号化回路の構成例を示すブロック図。FIG. 2 is a block diagram illustrating a configuration example of a binary image encoding circuit and a binary image decoding circuit that use a plurality of binary surface image encoding methods by switching. 本発明の第5の具体例におけるフレーム単位の縮小・拡大と、小領域単位の縮小・拡大を組み合わせたアルファマップ符号化回路の構成を示すブロツク図。FIG. 18 is a block diagram showing the configuration of an alpha map encoding circuit in which reduction / enlargement in units of frames and reduction / expansion in units of small regions are combined in a fifth specific example of the present invention. 本発明の第5の具体例におけるフレーム単位の縮小・拡大と、小領域単位の縮小・拡大を組み合わせたアルファマップ復号化回路の構成を示すブロック図。FIG. 19 is a block diagram showing a configuration of an alpha map decoding circuit in which reduction / enlargement in units of frames and reduction / expansion in units of small regions are combined in a fifth specific example of the present invention. 本発明のアルファマップ符号化回路から出力されるビット列の並び順を説明する図。FIG. 7 is a diagram for explaining the arrangement order of bit strings output from the alpha map encoding circuit of the present invention. 本発明の第6の具体例のシステム構成例を示すブロック図。FIG. 14 is a block diagram showing a system configuration example of a sixth specific example of the present invention. 本発明の第6の具体例における先行技術の説明をするための図。FIG. 14 is a diagram for explaining a prior art in a sixth specific example of the present invention. 本発明の第6の具体例における先行技術の説明をするための図。FIG. 14 is a diagram for explaining a prior art in a sixth specific example of the present invention. 本発明の第6の具体例における先行技術の説明をするための図。FIG. 14 is a diagram for explaining a prior art in a sixth specific example of the present invention. 本発明の第6の具体例における先行技術の説明をするための図。FIG. 14 is a diagram for explaining a prior art in a sixth specific example of the present invention. 本発明の第6の具体例における処理手順を説明をするためのフローチャート。16 is a flowchart for explaining a processing procedure in a sixth specific example of the present invention. 本発明の第6の具体例における処理手順を説明をするためのフローチャート。16 is a flowchart for explaining a processing procedure in a sixth specific example of the present invention. 縮小・拡大処理に利用する双一次内挿を説明するための図。FIG. 9 is a diagram for explaining bilinear interpolation used for reduction / enlargement processing. スムーシング処理(平滑化処理)を説明するための図。FIG. 4 is a diagram for explaining a smoothing process (smoothing process). 本発明で用いるスムーシングフィルタ(平滑化処理フィルタ)の別の例を説明するための図。FIG. 7 is a diagram for explaining another example of a smoothing filter (smoothing filter) used in the present invention. ブロック(マクロブロック)を縦横“1/2”のサイズに縮小する縮小処理の一例を説明するための図。FIG. 7 is a diagram for explaining an example of a reduction process for reducing a block (macroblock) to a size of “1/2” in the vertical and horizontal directions. 縮小ブロックの画素値を求める手法の例を説明するための図。FIG. 7 is a diagram for explaining an example of a technique for obtaining a pixel value of a reduced block. 画素間引きによる縮小処理の例を説明するための図。FIG. 9 is a diagram for explaining an example of a reduction process by pixel thinning. 本発明で用いる拡大処理の例を説明するための図。FIG. 9 is a diagram for explaining an example of an enlargement process used in the present invention. ブロック毎の縮小・拡大処理の別の例を説明するための図。FIG. 9 is a diagram for explaining another example of the reduction / enlargement processing for each block. 本発明の第6の具体例における符号化回路の構成例を示すブロック図。FIG. 15 is a block diagram illustrating a configuration example of an encoding circuit according to a sixth specific example of the present invention. 時刻n−1と時刻nにおけるフレーム画像Fn-1 ,FnとそれぞれのフレームFn-1 ,Fnにおける符号化領域CAの各マクロブロックのモード情報MDの例を説明するための図。The figure for demonstrating the example of the mode image MD of the frame image Fn-1 at the time n-1 and the time n, Fn, and each macroblock of the coding area | region CA in each frame Fn-1 and Fn. 符号化領域の変化とモード情報の対応するブロックの位置の変化の様子を説明するための図。FIG. 9 is a diagram for explaining a state of a change in a coding area and a change in position of a block corresponding to mode information. 本発明の時刻n−1と時刻nにおけるフレーム画像Fn-1 ,FnとそれぞれのフレームFn-1 ,Fnにおける符号化領域CAの各マクロブロックのモード情報MDの例を説明するための図。FIG. 8 is a diagram for explaining an example of frame images Fn-1 and Fn at time n-1 and time n and mode information MD of each macroblock of the coding area CA in each frame Fn-1 and Fn according to the present invention. アルファマップを併用する動画像符号化装置における符号化データ構成を説明するための図。FIG. 4 is a diagram for describing an encoded data configuration in a moving image encoding device that uses an alpha map together. 符号化領域が占める対象部分がフレームの一部分である場合に生じるラベル未定部分の対処法を説明するための図。FIG. 7 is a diagram for explaining a method of coping with an undetermined label portion that occurs when a target portion occupied by an encoding region is a part of a frame. ラベルを予測に用いるようにした本発明の復号化装置の構成例を示すブロック図。FIG. 3 is a block diagram showing a configuration example of a decoding device of the present invention in which a label is used for prediction. 本発明の符号化装置で用いる符号化処理手順の例を示すフローチャート。9 is a flowchart illustrating an example of an encoding processing procedure used in the encoding device of the present invention. 本発明の符号化装置で用いる符号化処理手順の別の例を示すフローチャート。9 is a flowchart illustrating another example of the encoding processing procedure used in the encoding device of the present invention. フレーム毎の解像度の例を表した図。The figure showing the example of the resolution for every frame. 図25の符号化装置に必要なフレームメモリを明示的に含めて表した場合の符号化装置の構成例を示すブロック図。FIG. 26 is a block diagram illustrating a configuration example of an encoding device when a frame memory required for the encoding device in FIG. 25 is explicitly included and represented. 図26の復号化装置に必要なフレームメモリを明示的に含めて表した場合の復号化装置の構成例を示すブロック図。FIG. 27 is a block diagram illustrating a configuration example of a decoding device when a frame memory required for the decoding device in FIG. 26 is explicitly included and represented. 図25の符号化装置に必要なフレームメモリを明示的に含めて表した場合の符号化装置の別の構成例を示すブロック図。FIG. 26 is a block diagram illustrating another configuration example of the encoding device in a case where a frame memory required for the encoding device in FIG. 25 is explicitly included and represented. 図26の復号化装置に必要なフレームメモリを明示的に含めて表した場合の別の復号化装置の構成例を示すブロック図。FIG. 27 is a block diagram illustrating a configuration example of another decoding device in a case where a frame memory required for the decoding device in FIG. 26 is explicitly included. 本発明の符号化装置および復号化装置で用いるフレームメモリの構成例を示すブロック図。FIG. 2 is a block diagram showing a configuration example of a frame memory used in the encoding device and the decoding device of the present invention. 双一次内挿により水平・垂直共に2倍に拡大する処理の例を説明するための図。FIG. 9 is a diagram for describing an example of processing for enlarging both horizontally and vertically two times by bilinear interpolation. 本発明で使用する双一次内挿処理により水平・垂直共に2倍に拡大する処理内容を説明するための図。FIG. 4 is a diagram for explaining processing contents for enlarging both twice in the horizontal and vertical directions by bilinear interpolation processing used in the present invention. 本発明で使用する縮小処理の例を説明するための図。FIG. 4 is a diagram for explaining an example of a reduction process used in the present invention. 本発明で使用する縮小処理を説明するための図。FIG. 4 is a diagram for explaining a reduction process used in the present invention. 本発明で用いるラベル予測方法を説明するための図。FIG. 4 is a diagram for explaining a label prediction method used in the present invention. 本発明で使用する縮小フレームから拡大処理によりフレームを復元する処理の説明をするための図。FIG. 9 is a diagram for describing a process of restoring a frame by a scaling process from a reduced frame used in the present invention. 本発明で適用する拡大処理における内挿画素位置と参照画素の利用範囲を説明する図。FIG. 4 is a diagram for explaining an interpolation pixel position and a use range of a reference pixel in an enlargement process applied in the present invention. 本発明で適用する拡大処理における参照画素の追加処理の例を説明する図。FIG. 9 is a diagram illustrating an example of a reference pixel addition process in the enlargement process applied in the present invention. 本発明にて用いる動きベクトルの予測符号化の一例を説明するための図。FIG. 4 is a diagram for explaining an example of predictive coding of a motion vector used in the present invention. フレーム内でのオブジェクトの位置の動きが大きい場合での、動きべクトルの予測の不都合を説明するための図。FIG. 9 is a diagram for explaining inconvenience of predicting a motion vector when the movement of the position of an object in a frame is large. 本発明システムにおけるMV符号化回路1790とその周辺回路の具体的構成例を示すブロック図。FIG. 13 is a block diagram showing a specific configuration example of an MV encoding circuit 1790 and its peripheral circuits in the system of the present invention. 本発明システムにおけるMV再生回路2900とその周辺回路の具体的構成例を示すブロック図。FIG. 13 is a block diagram showing a specific configuration example of an MV reproduction circuit 2900 and its peripheral circuits in the system of the present invention.

符号の説明Explanation of reference numerals

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…セレクタ。
2 a1 detecting circuit 3, 14 memory 5 mode determining circuit 8 encoding circuit 1-10 table determining circuit 13 decoding circuit 16 table determining circuit 17, 26 table 19 a1 reproducing circuit 22, 27 ... Counters 23 and 28 Huffman table generation circuit 100 Difference circuit 110 and 350 Motion compensation prediction circuit 120 Orthogonal transformation circuit 130 Quantization circuit 140 Variable length encoding circuit 150 and 320 Inverse quantization circuit 160 and 330 ... Inverse orthogonal transform circuits 170,340 ... Addition circuits 180,240 ... Multiplexing circuits 200 ... Alpha map encoding circuits 210,230,260,420 ... Resolution conversion circuits 220 ... Binary image encoding circuits 300,430,520 ... Separating circuit 310 ... Variable length decoding circuit 400 ... Alpha map decoding circuit 410 ... Binary image Decoding circuit 502 ... Object area 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 ... Pixel pixel value setting circuit 1600 ... Motion compensation prediction circuit 1700 binary image coding circuit 1710, 1730, 1740, 2830, 2840 reduction circuit 1720 expansion circuit 1750, 1760, 2820, 2850 transposition circuit 1770 scan type (ST) determination circuit 1780 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 reproducing circuit 2100 VLC (variable length coding) / separating circuit 2400 2500: macroblock pixel value setting circuit 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 (17)

画像を、その画像のオブジェクト領域と背景領域に区別するための情報であるアルファマップと共に符号化するに当たり、アルファマップをブロック毎に符号化する際に、ブロック毎の属性を符号化するようにした方式の画像符号化装置であって、
オブジェクトを含む、ブロックサイズの倍数で表される符号化領域を設定する手段と、
この領域内をブロックに分割する手段と、
各ブロックに対して、各々の属性に固有のラベルを割り当てるラベル付け手段と、
上記ラベルあるいは上記アルファマップをフレーム毎に保持する記億手段と、
現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する決定手段と、
少なくとも上記記憶手段に保持された前フレームのラベルあるいはアルファマップと、上記参照ブロックによって予測値を決定する予測手段と、
上記符号化ブロックのラベル情報を、上記予測値を用いて符号化する符号化手段と、
を有することを特徴とする画像符号化装置。
When encoding an image together with an alpha map that is information for distinguishing between an object area and a background area of the image, when encoding the alpha map for each block, the attribute of each block is encoded. Image encoding apparatus,
Means for setting an encoding area, including the object, represented by a multiple of the block size;
Means for dividing the area into blocks;
Labeling means for assigning a unique label to each attribute for each block;
A storage means for holding the label or the alpha map for each frame;
Determining means for determining a reference block of the previous frame corresponding to the encoded block of the current frame;
At least a label or an alpha map of a previous frame held in the storage unit, and a prediction unit that determines a prediction value by the reference block;
Encoding means for encoding the label information of the encoded block using the predicted value,
An image encoding device comprising:
請求項1記載の画像符号化装置において、
上記符号化領域はフレーム内の一部分であり、
上記記憶手段は、符号化領域以外のラベルとしては符号化領域のラベルから外挿して得られるものを保持するようにしたことを特徴とする画像符号化装置。
The image encoding device according to claim 1,
The coding area is a part of a frame,
An image coding apparatus according to claim 1, wherein said storage means stores a label obtained by extrapolating from the label of the coding area as a label other than the coding area.
請求項1記載の画像符号化装置において、
上記符号化領域はフレーム内の一部分であり、
上記記憶手段は、保持対象を符号化領域のラベルとし、上記予測手段における上記参照ブロックが、前フレームの符号化領域の外側となった時には、その近くの符号化領域のラベルを予測値として用いることを特徴とする画像符号化装置。
The image encoding device according to claim 1,
The coding area is a part of a frame,
The storage means uses the label of the coding area as a holding target, and when the reference block in the prediction means is outside the coding area of the previous frame, uses the label of the coding area nearby as the prediction value. An image encoding device characterized by the above-mentioned.
請求項1〜請求項3いずれか記載の画像符号化装置において、
上記符号化領域はフレーム内の一部分であり、
上記決定手段は、上記符号化領域の座標軸に基づいて上記参照ブロックを決定するものであることを特徴とする画像符号化装置。
The image encoding device according to any one of claims 1 to 3,
The coding area is a part of a frame,
The image coding apparatus according to claim 1, wherein said determining means determines said reference block based on a coordinate axis of said coding area.
請求項1〜請求項3いずれか記載の画像符号化装置において、
上記符号化領域はフレーム内の一部分であり、
上記決定手段は、上記符号化領域の座標軸に基づいて求まる第1の参照ブロックと、上記フレームの座標軸に基づいて求まる第2の参照ブロックのいずれか一方を選択して上記参照ブロックとする構成であることを特徴とする画像符号化装置。
The image encoding device according to any one of claims 1 to 3,
The coding area is a part of a frame,
The determining means selects one of a first reference block obtained based on a coordinate axis of the coding area and a second reference block obtained based on a coordinate axis of the frame to form the reference block. An image encoding device, comprising:
請求項5記載の画像符号化装置において、
上記決定手段は、上記第1の参照ブロックと上記第2の参照ブロックのうち、符号量が少なくなる方を選択し、その選択結果を識別する情報もあわせて符号化する構成であることを特徴とする画像符号化装置。
The image encoding device according to claim 5,
The determining means is configured to select one of the first reference block and the second reference block that has a smaller code amount, and to encode information for identifying the selection result. Image encoding device.
請求項5記載の画像符号化装置において、
上記決定手段は、前フレームの符号化領域の位置と現フレームの符号化領域の位置によって、上記第1の参照ブロックと上記第2の参照ブロックのうち、いずれか一方を選択する構成であることを特徴とする画像符号化装置。
The image encoding device according to claim 5,
The determination means may be configured to select one of the first reference block and the second reference block according to the position of the coding area of the previous frame and the position of the coding area of the current frame. An image encoding device characterized by the above-mentioned.
請求項1〜請求項7いずれか記載の画像符号化装置において、
複数の符号化テーブルを用意し、
上記予測手段においては、どの符号化テーブルを用いるかを表すインデックスが上記予測値として用いられる構成であることを特徴とする画像符号化装置。
The image encoding device according to any one of claims 1 to 7,
Prepare multiple encoding tables,
An image coding apparatus according to the above-mentioned prediction means, wherein an index indicating which coding table is used is used as the prediction value.
請求項1〜請求項8いずれか記載の画像符号化装置において、
上記予測手段は、既に符号化した現フレームのブロックのラベルも用いて予測値を決定する構成であることを特徴とする画像符号化装置。
The image encoding device according to any one of claims 1 to 8,
An image coding apparatus according to claim 1, wherein said prediction means is configured to determine a prediction value also using a label of a block of a current frame which has already been coded.
請求項1〜請求項9いずれか記載の画像符号化装置において、
上記符号化ブロックの属性として、少なくとも、そのブロックはオブジェクトの内側にあることを意味する第1の属性と、そのブロックはオブジェクトの外側にあることを意味する第2の属性と、そのブロックは2値画像符号化されることを意味する第3の属性と、そのブロックは前のフレームのアルファマップの所定の部分をそのままコピーすることを意味する第4の属性を有し、
上記前のフレームのアルファマップの所定の部分が前のフレームのオブジェクトの内側と外側をまたぐ場合は、上記第1から第4の属性を区別して符号化し、上記前のフレームのアルファマップの所定の部分が前のフレームのオブジェクトの内側にある場合は、上記第1の属性と第4の属性を同一視して符号化し、上記前のフレームのアルファマップの所定の部分が前のフレームのオブジェクトの外側にある場合は、上記第2の属性と第4の属性を同一視して符号化することを特徴とする画像符号化装置。
The image encoding device according to any one of claims 1 to 9,
As the attributes of the coded block, at least a first attribute indicating that the block is inside the object, a second attribute indicating that the block is outside the object, and the block are 2 A third attribute meaning that value image encoding is performed, and a fourth attribute meaning that the block copies a predetermined portion of the alpha map of the previous frame as it is,
When the predetermined portion of the alpha map of the previous frame straddles the inside and outside of the object of the previous frame, the first to fourth attributes are separately encoded, and the predetermined attribute of the alpha map of the previous frame is encoded. If the part is inside the object of the previous frame, the first attribute and the fourth attribute are identified and encoded, and the predetermined part of the alpha map of the previous frame is An image encoding apparatus characterized in that, when it is outside, the second attribute and the fourth attribute are identified and encoded.
請求項1記載の画像符号化装置において、
フレーム単位での縮小・拡大率を保持する記憶手段を設けると共に、
上記符号化手段は、フレーム単位でフレームの縮小・拡大率が可変であり、上記縮小・拡大縮率対応に符号化する手段を備え、
また、上記決定手段は、現フレームの縮小・拡大率と、上記記億手段から得た前フレームの縮小・拡大率を用いて現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する手段を備えることを特徴とする画像符号化装置。
The image encoding device according to claim 1,
In addition to providing storage means for holding the reduction / enlargement ratio in frame units,
The encoding means includes a means for changing the reduction / enlargement ratio of a frame in frame units, and encoding the frame in accordance with the reduction / enlargement / reduction ratio.
The determining means determines the reference block of the previous frame corresponding to the coded block of the current frame using the reduction / enlargement rate of the current frame and the reduction / enlargement rate of the previous frame obtained from the storage means. An image encoding apparatus comprising:
請求項1記載の画像符号化装置において、
フレーム単位での縮小・拡大率を保持する記憶手段を設けると共に、
上記符号化手段は、フレーム単位でフレームの縮小・拡大率が可変であり、上記縮小・拡大縮率対応に符号化する手段を備え、
また、上記決定手段は、現フレームの縮小・拡大率と、上記記億手段から得た前フレームの縮小・拡大率を用いて現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する手段を備え、
また、上記予測手段は、参照ブロックが複数ある場合には、上記複数の参照ブロックのラベルのうち、数が多いラベルを予測値とする手段を備えることを特徴とする画像符号化装置。
The image encoding device according to claim 1,
In addition to providing storage means for holding the reduction / enlargement ratio in frame units,
The encoding means has a variable frame reduction / enlargement ratio for each frame, and includes means for encoding corresponding to the reduction / enlargement / reduction ratio.
The determining means determines the reference block of the previous frame corresponding to the coded block of the current frame using the reduction / enlargement rate of the current frame and the reduction / enlargement rate of the previous frame obtained from the storage means. With means,
Further, the prediction means includes a means for setting, when there are a plurality of reference blocks, a label having a large number among labels of the plurality of reference blocks as a prediction value.
請求項12記載の画像符号化装置において、
上記予測手段は、参照ブロックが複数ある場合には、上記複数の参照ブロックのうち、予め定める位置にあるブロックのラベルを予測値とすることを特徴とする画像符号化装置。
The image encoding device according to claim 12,
An image coding apparatus according to claim 1, wherein, when there are a plurality of reference blocks, the prediction unit sets a label of a block at a predetermined position among the plurality of reference blocks as a prediction value.
請求項1記載の画像符号化装置において、
フレーム単位での縮小・拡大率を保持する記憶手段を設けると共に、
上記符号化手段は、フレーム単位でフレームの縮小・拡大率が可変であり、上記縮小・拡大縮率対応に符号化する手段を備え、
また、上記決定手段は、現フレームの縮小・拡大率と、上記記億手段から得た前フレームの縮小・拡大率を用いて現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する手段を備え、
また、上記予測手段は、予めラベルに優先順位をつけて、参照ブロックが複数ある場合には、これら複数の参照ブロックのラベルうち、上記優先順位の高いラベルを予測値とする手段を備えることを特徴とする画像符号化装置。
The image encoding device according to claim 1,
In addition to providing storage means for holding the reduction / enlargement ratio in frame units,
The encoding means includes a means for changing the reduction / enlargement ratio of a frame in frame units, and encoding the frame in accordance with the reduction / enlargement / reduction ratio.
The determining means determines the reference block of the previous frame corresponding to the coded block of the current frame using the reduction / enlargement rate of the current frame and the reduction / enlargement rate of the previous frame obtained from the storage means. With means,
Further, the prediction means may include a means for assigning priorities to the labels in advance and, when there are a plurality of reference blocks, among the labels of the plurality of reference blocks, a label having the higher priority as a predicted value. An image encoding device characterized by the following.
請求項1記載の画像符号化装置において、
フレーム単位での縮小・拡大率を保持する記憶手段を設けると共に、
上記符号化手段は、フレーム単位でフレームの縮小・拡大率が可変であり、上記縮小・拡大縮率対応に符号化するものであって、前フレームあるいは現フレームあるいはその両方の縮小・拡大率に応じて、複数種のうちから選択した一つの可変長符号化テーブルを用いて符号化ブロックの符号化処理をする手段を備えたものであり、
また、上記決定手段は、現フレームの縮小・拡大率と、上記記億手段から得た前フレームの縮小・拡大率を用いて現フレームの符号化ブロックに対応する前フレームの参照ブロックを決定する手段を備えたことを特徴とする画像符号化装置。
The image encoding device according to claim 1,
In addition to providing storage means for holding the reduction / enlargement ratio in frame units,
The encoding means has a variable frame reduction / enlargement ratio for each frame, and encodes the frame in accordance with the reduction / enlargement / reduction ratio. Accordingly, means for encoding the encoded block using one variable-length encoding table selected from a plurality of types is provided,
The determining means determines the reference block of the previous frame corresponding to the coded block of the current frame using the reduction / enlargement rate of the current frame and the reduction / enlargement rate of the previous frame obtained from the storage means. An image encoding device comprising: means.
請求項1記載の画像符号化装置において、
ブロック毎に動きベクトルが与えられ、上記動きベクトルを保持する手段と、
既に符号化したブロックの動きベクトルを用いて、前のフレームの第2の参照ブロックを決定する手段と、
複数種の符号化テーブルを持ち、上記第2の参照ブロックによってこれら符号化テーブルの一つを選択して上記符号化手段の符号化に処理に供する手段と、
を有することを特徴とする画像符号化装置。
The image encoding device according to claim 1,
Means for holding a motion vector given a motion vector for each block,
Means for determining a second reference block of the previous frame using the motion vector of the already coded block;
Means having a plurality of types of encoding tables, selecting one of these encoding tables by the second reference block, and subjecting the selected encoding table to encoding by the encoding means;
An image encoding device comprising:
請求項1記載の画像符号化装置において、
上記予測手段は、予め定める複数種類の予測方法のうちのいずれかを選択して用いるものであることを特徴とする画像符号化装置。
The image encoding device according to claim 1,
An image coding apparatus according to claim 1, wherein said prediction means selects and uses one of a plurality of types of prediction methods determined in advance.
JP2004180819A 1996-10-31 2004-06-18 Image coding apparatus Withdrawn JP2004320808A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004180819A JP2004320808A (en) 1996-10-31 2004-06-18 Image coding apparatus

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
JP2004180819A JP2004320808A (en) 1996-10-31 2004-06-18 Image coding apparatus

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP17777397A Division JP4034380B2 (en) 1996-10-31 1997-06-18 Image encoding / decoding method and apparatus

Publications (1)

Publication Number Publication Date
JP2004320808A true JP2004320808A (en) 2004-11-11

Family

ID=33479833

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004180819A Withdrawn JP2004320808A (en) 1996-10-31 2004-06-18 Image coding apparatus

Country Status (1)

Country Link
JP (1) JP2004320808A (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
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
JP2007202169A (en) Video decoding method and apparatus
JP2004320808A (en) Image coding apparatus
JP2004320807A (en) Image coding and apparatuses decoding
JPH104549A (en) Image coder and image decoder
JP2008011564A (en) Image encoding device and image decoding device
JP2007195209A (en) Video encoding apparatus and method
JP2007166664A (en) Image encoding method and device
JP2007195210A (en) Video decoding method and apparatus
JP2007166663A (en) Image decoding method and device
JP2007166665A (en) Image decoding method and device
JP2007166662A (en) Image encoding method and device

Legal Events

Date Code Title Description
A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20070619

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20070820

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20080226

A761 Written withdrawal of application

Free format text: JAPANESE INTERMEDIATE CODE: A761

Effective date: 20080430