JP2005117680A - Image signal coding method and device, image signal transmission method and decoding method and device - Google Patents

Image signal coding method and device, image signal transmission method and decoding method and device Download PDF

Info

Publication number
JP2005117680A
JP2005117680A JP2004338022A JP2004338022A JP2005117680A JP 2005117680 A JP2005117680 A JP 2005117680A JP 2004338022 A JP2004338022 A JP 2004338022A JP 2004338022 A JP2004338022 A JP 2004338022A JP 2005117680 A JP2005117680 A JP 2005117680A
Authority
JP
Japan
Prior art keywords
data
image signal
signal
image
circuit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Abandoned
Application number
JP2004338022A
Other languages
Japanese (ja)
Inventor
Teruhiko Suzuki
輝彦 鈴木
Yoichi Yagasaki
陽一 矢ヶ崎
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.)
Sony Corp
Original Assignee
Sony 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 Sony Corp filed Critical Sony Corp
Priority to JP2004338022A priority Critical patent/JP2005117680A/en
Publication of JP2005117680A publication Critical patent/JP2005117680A/en
Abandoned legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To remove error of DCT (Discrete Cosine Transformation) process or the like due to real number calculation and enable reversible encoding. <P>SOLUTION: An input picture signal is predictively coded with a calculation section 53, is applied with a DCT process in a DCT circuit 56, is quantized in a quantization circuit 57, and is variable-length-coded in a variable-length coding circuit 58 to extract an output bit stream. And a signal S2 obtained by reverse-quantizing the output from the quantization circuit 57 in a reverse-quantization circuit 60 and by reverse-DCT processing it with an IDCT circuit 61 is subtracted from a signal S1 before the DCT process, and the obtained subtraction output is variable-length-coded in a variable-length coding circuit 71 to be extracted as a subtraction bit stream. When decoding, a signal decoded from the output bit stream is added with a signal decoded from the subtraction bit stream to obtain a highly accurate original image picture signal to realize the reversible encoding. <P>COPYRIGHT: (C)2005,JPO&NCIPI

Description

本発明は、画像信号符号化方法及び装置、画像信号伝送方法、画像信号復号方法及び装置並びに記録媒体に関し、特に、動画像信号を、例えば光磁気ディスクや磁気テープなどの記録媒体に記録し、若しくはこの動画像信号を伝送路を介して伝送し、この動画像信号を再生する場合などに用いて好適な画像信号符号化方法及び装置、画像信号伝送方法、画像信号復号方法及び装置並びに記録媒体に関する。   The present invention relates to an image signal encoding method and apparatus, an image signal transmission method, an image signal decoding method and apparatus, and a recording medium, and in particular, records a moving image signal on a recording medium such as a magneto-optical disk or a magnetic tape, Alternatively, an image signal encoding method and apparatus, an image signal transmission method, an image signal decoding method and apparatus, and a recording medium that are suitable for use when the moving image signal is transmitted through a transmission path and the moving image signal is reproduced. About.

例えば、テレビ会議システム、テレビ電話システムなどのように、動画像信号を遠隔地に伝送するシステムにおいては、伝送路を効率良く利用するため、映像信号のライン相関やフレーム間相関を利用して、画像信号を圧縮符号化するようになされている。   For example, in a system that transmits a moving image signal to a remote place such as a video conference system and a video phone system, in order to efficiently use a transmission path, the line correlation of video signals and the correlation between frames are used. An image signal is compressed and encoded.

ライン相関(2次元相関性)を利用すると、画像信号を、例えばDCT(離散コサイン変換)処理するなどして、特定の周波数成分に信号電力を集中させることができ、これにより圧縮することができる。   When line correlation (two-dimensional correlation) is used, signal power can be concentrated on a specific frequency component by, for example, DCT (Discrete Cosine Transform) processing of an image signal, and can be compressed thereby. .

また、フレーム(またはフィールド)間相関を利用すると、画像信号をさらに圧縮して符号化することが可能となる。即ち、通常、時間的に隣接するフレームの画像は、それ程大きな変化を有していないため、両者の差を演算すると、その差分信号は小さな値のものとなる。そこで、この差分信号を符号化すれば、符号量を圧縮することができる。   In addition, when the correlation between frames (or fields) is used, the image signal can be further compressed and encoded. That is, since images of frames that are temporally adjacent do not have such a large change, when the difference between them is calculated, the difference signal has a small value. Therefore, if this difference signal is encoded, the code amount can be compressed.

しかしながら、差分信号のみを伝送したのでは、元の画像を復元することができない。そこで、各フレームの画像を、Iピクチャ、PピクチャまたはBピクチャの3種類のピクチャのいずれかのピクチャとし、画像信号を圧縮符号化するようにしている。   However, if only the differential signal is transmitted, the original image cannot be restored. Therefore, the image of each frame is set to any one of three types of pictures of I picture, P picture, and B picture, and the image signal is compressed and encoded.

このような圧縮技術は、MPEG(Moving Picture Image Coding Experts Group )の符号化規格として使用されている。MPEGとは、ISO−IEC/JTC1/SC2/WG11にて議論され、標準案として提案されたものであり、動き補償予測符号化と離散コサイン変換(DCT:Discrete Cosine Transform)符号化とを組み合わせたハイブリッド方式である。例えば、本出願人による米国出願USP5,155,593(DATE OF PATENT : October 13, 1992)の明細書及び図面において提案されている。   Such a compression technique is used as an MPEG (Moving Picture Image Coding Experts Group) encoding standard. MPEG is discussed in ISO-IEC / JTC1 / SC2 / WG11 and proposed as a standard proposal, which combines motion-compensated prediction coding and discrete cosine transform (DCT) coding. It is a hybrid system. For example, it is proposed in the specification and drawings of US application USP 5,155,593 (DATE OF PATENT: October 13, 1992) by the present applicant.

例えば、フレームF1乃至F17までの17フレームの画像信号をグループオブピクチャ(Group Of Picture、以下GOPと記載する)とし、これを処理の1単位とする。そして、その先頭のフレームF1の画像信号はIピクチャとして符号化し、第2番目のフレームF2はBピクチャとして、また第3番目のフレームF3はPピクチャとして、それぞれ符号化する。以下、第4番目以降のフレームF4乃至F17は、BピクチャまたはPピクチャとして交互に処理する。   For example, an image signal of 17 frames from frames F1 to F17 is a group of picture (hereinafter referred to as GOP), and this is a unit of processing. The image signal of the first frame F1 is encoded as an I picture, the second frame F2 is encoded as a B picture, and the third frame F3 is encoded as a P picture. Hereinafter, the fourth and subsequent frames F4 to F17 are alternately processed as a B picture or a P picture.

Iピクチャとして符号化された画像信号としては、その1フレーム(またはフィールド)分の画像信号をそのまま伝送する。これに対して、Pピクチャとして符号化された画像信号は、基本的には、それより時間的に先行するIピクチャまたはPピクチャの画像信号からの差分を伝送する。さらに、Bピクチャとして符号化された画像信号は、基本的には、時間的に先行するフレームまたは後行するフレームの両方の平均値からの差分を求め、その差分を符号化する。   As an image signal encoded as an I picture, the image signal for one frame (or field) is transmitted as it is. On the other hand, an image signal encoded as a P picture basically transmits a difference from an image signal of an I picture or P picture preceding in time. Further, for an image signal encoded as a B picture, basically, a difference from an average value of both a temporally preceding frame and a succeeding frame is obtained, and the difference is encoded.

以上のようにして、動画像信号を符号化する場合、最初のフレームF1はIピクチャとして処理されるため、そのまま伝送データとして伝送路に伝送される(画像内符号化)。これに対して、第2のフレームF2は、Bピクチャとして処理されるため、基本的には、時間的に先行するフレームF1と、時間的に後行するフレームF3の平均値との差分が演算され、その差分が伝送データとして伝送される。   As described above, when a moving image signal is encoded, the first frame F1 is processed as an I picture, and thus is transmitted as transmission data to a transmission path as it is (intra-image encoding). In contrast, since the second frame F2 is processed as a B picture, basically, the difference between the temporally preceding frame F1 and the average value of the temporally following frame F3 is calculated. The difference is transmitted as transmission data.

但し、このBピクチャとしての符号化処理は、さらに細かく説明すると、4種類存在する。その第1の処理は、元のフレームF2のデータをそのまま伝送データとして伝送するものであり(イントラ符号化、画像内予測符号化)、Iピクチャにおける場合と同様の処理となる。第2の処理は、時間的に後のフレームF3からの差分を演算し、その差分を伝送するものである(後方予測符号化)。第3の処理は、時間的に先行するフレームF1との差分を伝送するものである(前方予測符号化)。さらに第4の処理は、時間的に先行するフレームF1と後行するフレームF3の平均値との差分を生成し、これを伝送データとして伝送するものである(両方向予測符号化)。   However, there are four types of encoding processing as a B picture in more detail. The first process is to transmit the original frame F2 data as it is as transmission data (intra coding, intra-picture prediction coding), and is the same process as in the case of an I picture. The second process is to calculate a difference from a temporally subsequent frame F3 and transmit the difference (backward predictive coding). The third process is to transmit a difference from the temporally preceding frame F1 (forward predictive coding). Further, the fourth process is to generate a difference between the average value of the temporally preceding frame F1 and the succeeding frame F3 and transmit this as transmission data (bidirectional predictive coding).

この4つの方法のうち、伝送データが最も少なくなる方法が採用される。   Of these four methods, the method with the least amount of transmission data is employed.

なお、差分データを伝送するとき、差分を演算する対象となるフレームの画像(予測画像)との間の動きベクトルx1(前方予測の場合、フレームF1とF2の間の動きベクトル)、もしくはx2(後方予測の場合、フレームF3とF2の間の動きベクトル)、またはx1とx2の両方(両方向予測の場合)が、差分データとともに伝送される。   When the difference data is transmitted, the motion vector x1 (the motion vector between the frames F1 and F2 in the case of forward prediction) between the frame image (predicted image) whose difference is to be calculated, or x2 ( In the case of backward prediction, the motion vector between frames F3 and F2) or both x1 and x2 (in the case of bidirectional prediction) are transmitted along with the difference data.

また、PピクチャのフレームF3は、基本的には時間的に先行するフレームF1を予測画像として、このフレームとの差分信号と、動きベクトルx3が演算され、これが伝送データとして伝送される(前方予測符号化)。   Also, a frame F3 of a P picture basically uses a temporally preceding frame F1 as a predicted image, a difference signal from this frame, and a motion vector x3 are calculated and transmitted as transmission data (forward prediction) Coding).

但し、このPピクチャとしての符号化処理は、さらに細かく説明すると、2種類存在する。第1の処理は、上述したような、時間的に先行するフレームF1との差分を伝送するものである(前方予測符号化)。第2の処理は、元のフレームF3のデータがそのまま伝送データとして伝送される(イントラ符号化、画像内予測符号化)。いずれの方法により伝送されるかは、Bピクチャにおける場合と同様に、伝送データがより少なくなる方が選択される。   However, there are two types of encoding processing as the P picture. The first process is to transmit a difference from the temporally preceding frame F1 as described above (forward prediction coding). In the second process, the data of the original frame F3 is transmitted as transmission data as it is (intra coding, intra-picture prediction coding). Which method is used for transmission is selected, as in the case of a B picture, where transmission data is smaller.

特開昭63−045684号公報JP 63-045684 A 特開平01−305666号公報Japanese Patent Laid-Open No. 01-305666 特開平06−343171号公報Japanese Patent Laid-Open No. 06-343171

ところで、従来の画像信号符号化および復号の方法及び装置によれば、DCT(離散余弦変換)などの変換を符号化時に用いる変換符号化を行なっている。このDCT処理は実数の演算であるが、現実のDCT回路を用いる場合には、演算を有限語長で打ち切ることになる。したがって、DCT回路及びIDCT(逆離散余弦変換)回路において、DCT処理後、IDCT処理を行なった場合、原信号の情報が一部失われることになる。   By the way, according to the conventional image signal encoding and decoding method and apparatus, transform coding using transform such as DCT (Discrete Cosine Transform) is performed. This DCT process is a real number calculation, but when an actual DCT circuit is used, the calculation is terminated with a finite word length. Therefore, in the DCT circuit and the IDCT (Inverse Discrete Cosine Transform) circuit, when the IDCT process is performed after the DCT process, part of the original signal information is lost.

したがって、DCTなどの実数演算を符号化/復号装置に用いた場合、可逆符号化を実現することができない。可逆符号化は高精度な画像信号を要求される際に、必要となる技術である。   Therefore, when real number arithmetic such as DCT is used in the encoding / decoding device, lossless encoding cannot be realized. Lossless encoding is a technique required when a highly accurate image signal is required.

本発明はこのような実情に鑑みてなされたものであり、DCTなどの実数演算を用いる画像信号符号化/復号においても可逆符号化を実現することができるようにするものである。   The present invention has been made in view of such a situation, and makes it possible to realize lossless encoding even in image signal encoding / decoding using real number arithmetic such as DCT.

本発明によれば、上述した課題を解決するために、画像信号に実数演算を伴う符号化処理を施して得られた信号を量子化し、量子化された信号を出力する画像信号符号化方法において、符号化データの局所復号データと上記実数演算を行なう前のデータとを比較し、その差分を取り出すことを特徴としている。   According to the present invention, in order to solve the above-described problem, in an image signal encoding method for quantizing a signal obtained by performing an encoding process with real number operation on an image signal and outputting the quantized signal The feature is that the locally decoded data of the encoded data is compared with the data before the real number calculation and the difference is extracted.

すなわち、本発明に係る画像信号符号化方法は、画像信号に実数演算を伴う符号化処理を施して得られた信号を出力する画像信号符号化方法において、入力画像信号に対して実数演算を伴う符号化処理を行い、符号化データを生成する工程と、上記符号化データを局所復号し局所復号でデータを生成する工程と、上記局所復号データと上記実数演算を行なう前の画像データとを比較し、その差分を演算する工程とを有することを特徴としている。   That is, the image signal encoding method according to the present invention involves a real number operation for an input image signal in an image signal encoding method for outputting a signal obtained by performing an encoding process with a real number operation on an image signal. Comparing the step of performing encoding processing and generating encoded data, the step of locally decoding the encoded data and generating data by local decoding, and the local decoded data and the image data before performing the real number operation And a step of calculating the difference.

また、本発明に係る画像信号符号化装置は、画像信号に実数演算を伴う符号化処理を施して得られた信号を出力する画像信号符号化装置において、入力画像信号に対して実数演算を伴う符号化処理を行い、符号化データを生成する手段と、上記符号化データを局所復号し局所復号でデータを生成する手段と、上記局所復号データと上記実数演算を行なう前の画像データとを比較し、その差分を演算する手段とを有することを特徴としている。   An image signal encoding apparatus according to the present invention is an image signal encoding apparatus that outputs a signal obtained by performing an encoding process with a real number operation on an image signal. Comparing means for performing encoding processing and generating encoded data, means for locally decoding the encoded data and generating data by local decoding, and the local decoded data and the image data before performing the real number operation And means for calculating the difference.

また、本発明に係る画像信号伝送方法は、画像信号に実数演算を伴う符号化処理を施して得られた信号を伝送する画像信号伝送方法において、入力画像信号に対して実数演算を伴う符号化処理を行い、符号化データを生成する工程と、上記符号化データを局所復号し局所復号でデータを生成する工程と、上記局所復号データと上記実数演算を行なう前の画像データとを比較し、その差分を演算し、差分データを伝送する工程とを有することを特徴としている。   In addition, an image signal transmission method according to the present invention is an image signal transmission method for transmitting a signal obtained by performing an encoding process with a real number operation on an image signal, and encoding an input image signal with a real number operation. Performing a process to generate encoded data, comparing the step of locally decoding the encoded data and generating data by local decoding, and comparing the local decoded data and the image data before performing the real number operation, A step of calculating the difference and transmitting difference data.

また、本発明に係る記録媒体は、復号装置によって復号可能な記録媒体において、上記記録媒体は上記復号装置によって復号可能な記録信号が記録され、該記録信号は、入力画像信号に対して実数演算を伴う符号化処理を行い符号化データを生成する工程と、上記符号化データを局所復号し局所復号でデータを生成する工程と、上記局所復号データと上記実数演算を行なう前のデータとを比較してその差分を演算して差分データを生成する工程とにより得られた符号化データと差分データとを含んで成ることを特徴としている。   The recording medium according to the present invention is a recording medium decodable by a decoding device, wherein the recording medium records a recording signal decodable by the decoding device, and the recording signal is a real number operation on an input image signal. A process of generating encoded data by performing an encoding process, a process of locally decoding the encoded data and generating data by local decoding, and comparing the local decoded data with the data before the real number operation is performed And the difference data is obtained by calculating the difference and generating difference data.

また、本発明に係る画像信号復号方法は、画像信号に実数演算を伴う符号化処理を施して得られた符号化データと、上記符号化データの局所復号データと上記実数演算を行なう前の画像データとの差分演算によって得られた差分データ信号とが供給され、上記符号化データと上記差分データとから元の画像データを復号する画像信号復号方法において、上記符号化データを上記符号化処理に対応する復号処理に従って復号し、復号データを生成する工程と上記差分データと上記復号データを加算する工程とを有することを特徴としている。   In addition, the image signal decoding method according to the present invention includes encoded data obtained by performing an encoding process with real number operation on an image signal, local decoded data of the encoded data, and an image before the real number operation is performed. In an image signal decoding method for decoding original image data from the encoded data and the difference data, a difference data signal obtained by a difference operation with data is supplied, and the encoded data is subjected to the encoding process. The method includes a step of decoding according to a corresponding decoding process to generate decoded data, and a step of adding the difference data and the decoded data.

また、本発明に係る画像信号復号装置は、画像信号に実数演算を伴う符号化処理を施して得られた符号化データと、上記符号化データの局所復号データと上記実数演算を行なう前の画像データとの差分演算によって得られた差分データ信号とが供給され、上記符号化データと上記差分データとから元の画像データを復号する画像信号復号装置において、上記符号化データを上記符号化処理に対応する復号処理に従って復号し、復号データを生成する手段と、上記差分データと上記復号データを加算する手段とを有することを特徴としている。   In addition, the image signal decoding apparatus according to the present invention provides encoded data obtained by performing an encoding process involving real number operation on an image signal, local decoded data of the encoded data, and an image before performing the real number operation. In the image signal decoding apparatus for decoding the original image data from the encoded data and the difference data, the difference data signal obtained by the difference calculation with the data is supplied, and the encoded data is subjected to the encoding process. It has a means for decoding according to a corresponding decoding process and generating decoded data, and means for adding the difference data and the decoded data.

すなわち、離散余弦変換(DCT)処理などの実数演算を行なう画像信号符号化において、局所復号時に、局所復号データと実数演算を行なう前の所定のデータを比較し差分を求め、伝送し、画像信号復号装置において上記伝送された差分信号を復号データに加算し、信号を補正することにより可逆符号化を実現することが可能となる。   That is, in image signal coding for performing a real number operation such as discrete cosine transform (DCT) processing, at the time of local decoding, the local decoded data is compared with predetermined data before performing the real number operation, a difference is obtained, transmitted, and an image signal In the decoding device, the transmitted difference signal is added to the decoded data, and the signal is corrected, whereby lossless encoding can be realized.

本発明によれば、画像信号に実数演算を伴う符号化処理を施して得られた信号を量子化し、量子化された信号を出力する画像信号符号化方法において、符号化データの局所復号データと上記実数演算を行なう前のデータとを比較し、その差分を取り出しているため、この差分信号を復号データに加算し、信号を補正することにより、可逆符号化を実現することが可能となる。この可逆符号化が可能となることにより、高精度の画像信号の符号化/復号が実現できる。   According to the present invention, in an image signal encoding method for quantizing a signal obtained by performing an encoding process with a real number operation on an image signal and outputting the quantized signal, local decoding data of encoded data and Since the difference is extracted by comparing the data before the real number calculation, lossless encoding can be realized by adding the difference signal to the decoded data and correcting the signal. By enabling this lossless encoding, it is possible to realize encoding / decoding of a highly accurate image signal.

また、所定のブロックごとに、画像データの代表値データおよび量子化幅を決定し、画像データと代表値データの差分を算出して、差分を量子化幅に基づいて量子化し、第1の量子化データを生成する。そして、第1の量子化データに所定の変換処理を施し、その変換係数を量子化して、第2の量子化データを生成し、代表値データ、量子化幅、および第2の量子化データを符号化する。従って、画像を、そのビット精度を変換して符号化し、また復号することができる。   Further, for each predetermined block, the representative value data and the quantization width of the image data are determined, the difference between the image data and the representative value data is calculated, the difference is quantized based on the quantization width, and the first quantum Generate data. Then, a predetermined conversion process is performed on the first quantized data, the conversion coefficient is quantized to generate second quantized data, and the representative value data, the quantized width, and the second quantized data are Encode. Therefore, an image can be encoded and decoded by converting its bit precision.

以下、本発明に係る画像信号符号化方法及び装置、画像信号伝送方法、画像信号復号化方法及び装置並びに画像信号復号装置又は方法によって復号可能な記録信号が記録された記録媒体の好ましいいくつかの実施の形態について、図面を参照しながら説明する。   Hereinafter, some preferable image signal encoding method and apparatus, image signal transmission method, image signal decoding method and apparatus, and a recording medium on which a recording signal decodable by the image signal decoding apparatus or method is recorded according to the present invention. Embodiments will be described with reference to the drawings.

図1は、本発明の第1の実施の形態としての画像信号符号化装置の構成を示している。   FIG. 1 shows the configuration of an image signal encoding apparatus as a first embodiment of the present invention.

この図1の実施の形態においては、DCT(離散余弦変換)回路56に供給するDCT処理前の信号S1を加算器70に送る。また、DCT回路56、量子化回路57及び逆量子化回路60で処理され、IDCT(逆離散余弦変換)回路61によりIDCT処理されて得られた信号S2を減算器70に送る。そして、このIDCT処理された信号S2を上記DCT処理前の信号S1から減算して差分信号S3を求め、この差分信号S3を可変長符号化回路71で可変長符号化処理し、送信バッファ73を介して差分ビットストリームとして出力している。   In the embodiment of FIG. 1, a signal S <b> 1 before DCT processing supplied to a DCT (Discrete Cosine Transform) circuit 56 is sent to an adder 70. Further, the signal S 2 obtained by the DCT circuit 56, the quantization circuit 57 and the inverse quantization circuit 60 and subjected to the IDCT process by the IDCT (Inverse Discrete Cosine Transform) circuit 61 is sent to the subtractor 70. Then, the signal S2 subjected to the IDCT processing is subtracted from the signal S1 before the DCT processing to obtain a difference signal S3, the difference signal S3 is subjected to variable length encoding processing by the variable length encoding circuit 71, and the transmission buffer 73 is set. Output as a differential bit stream.

この図1に示す画像信号符号化装置において、符号化されるべき画像データは、マクロブロック単位で動きベクトル検出回路50に入力される。動きベクトル検出回路50は、予め設定されている所定のシーケンスに従って、各フレームの画像データを、Iピクチャ、Pピクチャ、またはBピクチャとして処理する。シーケンシャルに入力される各フレームの画像を、I,P,Bのいずれのピクチャとして処理するかは、予め定められている。   In the image signal encoding apparatus shown in FIG. 1, image data to be encoded is input to the motion vector detection circuit 50 in units of macroblocks. The motion vector detection circuit 50 processes the image data of each frame as an I picture, P picture, or B picture according to a predetermined sequence set in advance. It is determined in advance which picture of each frame that is sequentially input is processed as I, P, or B picture.

ここで、上記マクロブロックは、画面上の縦横16×16ドットの輝度信号により構成され、8×8ドットを単位とする4つのブロックY[1]〜Y[4]に区分されている。この16×16ドットの輝度信号には、8×8ドットのCb信号と、8×8ドットのCr信号とが対応する。   Here, the macroblock is composed of vertical and horizontal luminance signals of 16 × 16 dots on the screen, and is divided into four blocks Y [1] to Y [4] having 8 × 8 dots as a unit. The 16 × 16 dot luminance signal corresponds to an 8 × 8 dot Cb signal and an 8 × 8 dot Cr signal.

Iピクチャとして処理されるフレームの画像データは、動きベクトル検出回路50からフレームメモリ51の前方原画像部51aに転送されて記憶される。Bピクチャとして処理されるフレームの画像データは、原画像部51bに転送されて記憶される。Pピクチャとして処理されるフレームの画像データは、後方原画像部51cに転送されて記憶される。   Image data of a frame processed as an I picture is transferred from the motion vector detection circuit 50 to the front original image portion 51a of the frame memory 51 and stored. Image data of a frame processed as a B picture is transferred to and stored in the original image unit 51b. Image data of a frame processed as a P picture is transferred to and stored in the rear original image portion 51c.

また、次のタイミングにおいて、さらにBピクチャまたはPピクチャとして処理すべきフレームの画像が入力されたとき、それまで後方原画像部51cに記憶されていた最初のPピクチャの画像データが、前方原画像部51aに転送される。そして、次のBピクチャの画像データが、原画像部51bに記憶(上書き)され、次のPピクチャの画像データが、後方原画像部51cに記憶(上書き)される。このような動作が順次繰り返される。   Further, when an image of a frame to be processed as a B picture or a P picture is input at the next timing, the image data of the first P picture that has been stored in the rear original image unit 51 c until then is the front original image. Is transferred to the unit 51a. Then, the image data of the next B picture is stored (overwritten) in the original image portion 51b, and the image data of the next P picture is stored (overwritten) in the rear original image portion 51c. Such an operation is sequentially repeated.

フレームメモリ51に記憶された各ピクチャの信号は、そこから読み出され、動きベクトル検出回路50に供給され、また、フレーム/フィールド予測モード切り換え回路52にも供給される。予測モード切り換え回路52において、フレーム予測モード処理、またはフィールド予測モード処理が行なわれる。さらに、予測判定回路54の制御の下に、演算部53において、画像内予測、前方予測、後方予測、または両方向予測の演算が行なわれる。これらの処理のうち、いずれの処理を行なうかは、予測誤差信号(処理の対象とされている参照画像と、これに対する予測画像との差分)に対応して決定される。このため、動きベクトル検出回路50は、この判定に用いられる予測誤差信号の絶対値和(自乗和でもよい)を生成する。   The signal of each picture stored in the frame memory 51 is read from the picture signal, supplied to the motion vector detection circuit 50, and also supplied to the frame / field prediction mode switching circuit 52. In the prediction mode switching circuit 52, frame prediction mode processing or field prediction mode processing is performed. Further, under the control of the prediction determination circuit 54, the calculation unit 53 performs calculation for intra prediction, forward prediction, backward prediction, or bidirectional prediction. Which of these processes is performed is determined corresponding to a prediction error signal (a difference between a reference image to be processed and a predicted image corresponding thereto). For this reason, the motion vector detection circuit 50 generates the absolute value sum (or sum of squares) of the prediction error signal used for this determination.

ここで、予測モード切り換え回路52におけるフレーム予測モードとフィールド予測モードについて説明する。   Here, the frame prediction mode and the field prediction mode in the prediction mode switching circuit 52 will be described.

予測モード切り換え回路52において、フレーム予測モードが設定された場合においては、予測モード切り換え回路52は、動きベクトル検出回路50より供給される4個の輝度ブロックY[1]乃至Y[4]を、そのまま後段の演算部53に出力する。これに対して、フィールド予測モードが設定された場合においては、予測モード切り換え回路52は、4個の輝度ブロックのうち、輝度ブロックY[1]とY[2]を、例えば奇数フィールドのラインのドットによりのみ構成させ、他の2個の輝度ブロックY[3]とY[4]を、偶数フィールドのラインのデータにより構成させて、演算部53に出力する。この場合においては、2個の輝度ブロックY[1]とY[2]に対して、1個の動きベクトルが対応され、他の2個の輝度ブロックY[3]とY[4]に対して、他の1個の動きベクトルが対応される。   When the frame prediction mode is set in the prediction mode switching circuit 52, the prediction mode switching circuit 52 converts the four luminance blocks Y [1] to Y [4] supplied from the motion vector detection circuit 50, The data is output as it is to the calculation unit 53 in the subsequent stage. On the other hand, when the field prediction mode is set, the prediction mode switching circuit 52 selects the luminance blocks Y [1] and Y [2] out of the four luminance blocks, for example, for the odd field lines. The other two luminance blocks Y [3] and Y [4] are constituted by even-numbered line data and output to the calculation unit 53. In this case, one motion vector corresponds to the two luminance blocks Y [1] and Y [2], and the other two luminance blocks Y [3] and Y [4]. Thus, one other motion vector is associated.

動きベクトル検出回路50は、フレーム予測モードにおける予測誤差の絶対値和と、フィールド予測モードにおける予測誤差の絶対値和を、予測モード切り換え回路52に出力する。予測モード切り換え回路52は、フレーム予測モードとフィールド予測モードにおける予測誤差の絶対値和を比較し、その値が小さい予測モードに対応する処理を施して、データを演算部53に出力する。   The motion vector detection circuit 50 outputs the sum of absolute values of prediction errors in the frame prediction mode and the sum of absolute values of prediction errors in the field prediction mode to the prediction mode switching circuit 52. The prediction mode switching circuit 52 compares the absolute value sum of the prediction errors in the frame prediction mode and the field prediction mode, performs a process corresponding to the prediction mode having a small value, and outputs the data to the calculation unit 53.

但し、このような処理は、動きベクトル検出回路50で行うようにしてもよい。即ち、動きベクトル検出回路50は、フレーム予測モードとフィールド予測モードにおける予測誤差の絶対値和を比較し、その値が小さいモードに対応する構成の信号を予測モード切り換え回路52に出力し、予測モード切り換え回路52は、その信号を、そのまま後段の演算部53に出力する。実際には、この処理は、後者、つまり動きベクトル検出回路50で行われる。   However, such processing may be performed by the motion vector detection circuit 50. That is, the motion vector detection circuit 50 compares the absolute value sum of the prediction errors in the frame prediction mode and the field prediction mode, and outputs a signal having a configuration corresponding to the mode having a small value to the prediction mode switching circuit 52. The switching circuit 52 outputs the signal as it is to the calculation unit 53 in the subsequent stage. Actually, this processing is performed by the latter, that is, the motion vector detection circuit 50.

尚、色差信号は、フレーム予測モードの場合、奇数フィールドのラインのデータと偶数フィールドのラインのデータとが混在する状態で、演算部53に供給される。また、フィールド予測モードの場合、各色差ブロックCb,Crの上半分(4ライン)が、輝度ブロックY[1],Y[2]に対応する奇数フィールドの色差信号とされ、下半分(4ライン)が、輝度ブロックY[3],Y[4]に対応する偶数フィールドの色差信号とされる。   Note that, in the frame prediction mode, the color difference signal is supplied to the arithmetic unit 53 in a state where the odd field line data and the even field line data coexist. In the field prediction mode, the upper half (four lines) of the color difference blocks Cb and Cr is used as the odd-field color difference signal corresponding to the luminance blocks Y [1] and Y [2], and the lower half (four lines). ) Is the color difference signal of the even field corresponding to the luminance blocks Y [3], Y [4].

また、動きベクトル検出回路50は、次のようにして、予測判定回路54において、画像内予測、前方予測、後方予測、または両方向予測のいずれの予測を行なうかを決定するための予測誤差の絶対値和を生成する。   In addition, the motion vector detection circuit 50 calculates the absolute value of the prediction error for determining whether the prediction determination circuit 54 performs prediction in the image, forward prediction, backward prediction, or bidirectional prediction as follows. Generate a value sum.

即ち、画像内予測の予測誤差の絶対値和として、参照画像のマクロブロックの信号Aijの和ΣAijの絶対値|ΣAij|と、マクロブロックの信号Aijの絶対値|Aij|の和Σ|Aij|の差を求める。また、前方予測の予測誤差の絶対値和として、参照画像のマクロブロックの信号Aijと、予測画像のマクロブロックの信号Bijの差Aij−Bijの絶対値|Aij−Bij|の和Σ|Aij−Bij|を求める。また、後方予測と両方向予測の予測誤差の絶対値和も、前方予測における場合と同様に(その予測画像を前方予測における場合と異なる予測画像に変更して)求める。   That is, as the sum of the absolute values of the prediction errors of the intra-picture prediction, the sum Σ | Aij | of the absolute value | ΣAij | of the sum ΣAij of the macroblock signal Aij of the reference picture and the absolute value | Aij | of the macroblock signal Aij Find the difference. Also, as the sum of the absolute values of the prediction errors of the forward prediction, the sum Σ | Aij− of the absolute value | Aij−Bij | of the difference Aij−Bij between the macroblock signal Aij of the reference image and the macroblock signal Bij of the predicted image Bij | is obtained. Also, the absolute value sum of the prediction errors of the backward prediction and the bidirectional prediction is obtained in the same manner as in the forward prediction (by changing the prediction image to a prediction image different from that in the forward prediction).

これらの絶対値和は、予測判定回路54に供給される。予測判定回路54は、前方予測、後方予測および両方向予測の予測誤差の絶対値和のうち、最も小さいものを、インター予測の予測誤差の絶対値和として選択する。さらに、このインター予測の予測誤差の絶対値和と、画像内予測の予測誤差の絶対値和とを比較し、その小さい方を選択し、この選択した絶対値和に対応するモードを予測モードとして選択する。即ち、画像内予測の予測誤差の絶対値和の方が小さければ、画像内予測モードが設定される。インター予測の予測誤差の絶対値和の方が小さければ、前方予測、後方予測または両方向予測モードのうち、対応する絶対値和が最も小さかったモードが設定される。   These sums of absolute values are supplied to the prediction determination circuit 54. The prediction determination circuit 54 selects the smallest one of the absolute value sums of the prediction errors of the forward prediction, the backward prediction and the bidirectional prediction as the absolute value sum of the prediction errors of the inter prediction. Further, the absolute value sum of the prediction error of the inter prediction and the absolute value sum of the prediction error of the intra prediction are compared, and the smaller one is selected, and the mode corresponding to the selected absolute value sum is set as the prediction mode. select. That is, if the sum of the absolute values of the prediction errors of intra prediction is smaller, the intra prediction mode is set. If the absolute value sum of the prediction errors of inter prediction is smaller, the mode in which the corresponding absolute value sum is the smallest is set among the forward prediction, backward prediction, and bidirectional prediction modes.

また、動きベクトル検出回路50は、上述した予測判定回路54と同様に動作を実行し、4つの予測モードのうち、各モードの予測誤差の絶対値和が最も小さかったモードを選択し、その選択されたモードに対応する動きベクトルを出力する。   In addition, the motion vector detection circuit 50 performs the same operation as the prediction determination circuit 54 described above, and selects the mode in which the absolute value sum of the prediction errors in each mode is the smallest among the four prediction modes, and selects the selected mode. A motion vector corresponding to the selected mode is output.

このように、動きベクトル検出回路50は、参照画像のマクロブロックの信号を、フレームまたはフィールド予測モードのうち、予測モード切り換え回路52により選択されたモードに対応する構成で、予測モード切り換え回路52を介して演算部53に供給するとともに、4つの予測モードのうち、予測判定回路54により選択された予測モードに対応する予測画像と参照画像の間の動きベクトルを検出し、可変長符号化回路58と動き補償回路64に出力する。上述したように、この動きベクトルとしては、対応する予測誤差の絶対値和が最小となるものが選択される。   In this way, the motion vector detection circuit 50 has the configuration corresponding to the mode selected by the prediction mode switching circuit 52 out of the frame or field prediction mode, as the macro block signal of the reference image, and the prediction mode switching circuit 52 And the motion vector between the prediction image corresponding to the prediction mode selected by the prediction determination circuit 54 and the reference image among the four prediction modes is detected, and the variable-length encoding circuit 58 is detected. And output to the motion compensation circuit 64. As described above, the motion vector having the minimum absolute value sum of the corresponding prediction errors is selected.

予測判定回路54は、動きベクトル検出回路50が前方原画像部51aよりIピクチャの画像データを読み出しているとき、予測モードとして、フレーム(画像)内予測モード(動き補償を行わないモード)を設定し、演算部53のスイッチ53dを接点a側に切り換える。これにより、Iピクチャの画像データがDCTモード切り換え回路55に入力される。   The prediction determination circuit 54 sets an intra-frame (image) prediction mode (a mode in which motion compensation is not performed) as a prediction mode when the motion vector detection circuit 50 reads image data of an I picture from the front original image portion 51a. Then, the switch 53d of the calculation unit 53 is switched to the contact a side. As a result, the image data of the I picture is input to the DCT mode switching circuit 55.

このDCTモード切り換え回路55は、4個の輝度ブロックのデータを、奇数フィールドのラインと偶数フィールドのラインが混在する状態(フレームDCTモード)、または、分離された状態(フィールドDCTモード)、のいずれかの状態にして、DCT回路56に出力する。   This DCT mode switching circuit 55 has the data of the four luminance blocks in either a state where odd-numbered field lines and even-numbered field lines are mixed (frame DCT mode) or separated (field DCT mode). In this state, the signal is output to the DCT circuit 56.

即ち、DCTモード切り換え回路55は、奇数フィールドと偶数フィールドのデータを混在してDCT処理した場合における符号化効率と、分離した状態においてDCT処理した場合の符号化効率とを比較し、符号化効率の良好なモードを選択する。   In other words, the DCT mode switching circuit 55 compares the coding efficiency when DCT processing is performed with mixed odd-numbered field data and even-numbered field data, and the coding efficiency when DCT processing is performed in a separated state. Choose a good mode.

例えば、入力された信号を、奇数フィールドと偶数フィールドのラインが混在する構成とし、上下に隣接する奇数フィールドのラインの信号と偶数フィールドのラインの信号の差を演算し、さらにその絶対値の和(または自乗和)を求める。また、入力された信号を、奇数フィールドと偶数フィールドのラインが分離した構成とし、上下に隣接する奇数フィールドのライン同士の信号の差と、偶数フィールドのライン同士の信号の差を演算し、それぞれの絶対値の和(または自乗和)を求める。さらに、両者(絶対値和)を比較し、小さい値に対応するDCTモードを設定する。即ち、前者の方が小さければ、フレームDCTモードを設定し、後者の方が小さければ、フィールドDCTモードを設定する。   For example, the input signal has a configuration in which odd-numbered field and even-numbered field lines coexist, and the difference between the odd-numbered and even-numbered adjacent-field signal is calculated, and the sum of the absolute values (Or sum of squares). In addition, the input signal has a configuration in which the odd field and even field lines are separated, and the difference between the signals of the odd field lines adjacent to each other and the signal difference between the even field lines are calculated. Find the sum (or sum of squares) of the absolute values of. Furthermore, both (absolute value sum) are compared, and a DCT mode corresponding to a small value is set. That is, if the former is smaller, the frame DCT mode is set, and if the latter is smaller, the field DCT mode is set.

そして、選択したDCTモードに対応する構成のデータをDCT回路56に出力するとともに、選択したDCTモードを示すDCTフラグを、可変長符号化回路58と動き補償回路64に出力する。また、DCTモード切り換え回路55からのデータ(信号S1)を、上記差分取り出し用の加算器70に送っている。   Then, data having a configuration corresponding to the selected DCT mode is output to the DCT circuit 56, and a DCT flag indicating the selected DCT mode is output to the variable length coding circuit 58 and the motion compensation circuit 64. Further, data (signal S1) from the DCT mode switching circuit 55 is sent to the adder 70 for taking out the difference.

予測モード切り換え回路52における予測モードと、このDCTモード切り換え回路55におけるDCTモードを比較して明らかなように、輝度ブロックに関しては、両者の各モードにおけるデータ構造は実質的に同一である。   As is apparent from a comparison between the prediction mode in the prediction mode switching circuit 52 and the DCT mode in the DCT mode switching circuit 55, regarding the luminance block, the data structures in both modes are substantially the same.

また、予測モード切り換え回路52において、フレーム予測モード(奇数ラインと偶数ラインが混在するモード)が選択された場合、DCTモード切り換え回路55においても、フレームDCTモード(奇数ラインと偶数ラインが混在するモード)が選択される可能性が高く、また、予測モード切り換え回路52において、フィールド予測モード(奇数フィールドと偶数フィールドのデータが分離されたモード)が選択された場合、DCTモード切り換え回路55において、フィールドDCTモード(奇数フィールドと偶数フィールドのデータが分離されたモード)が選択される可能性が高い。   Further, when the frame prediction mode (mode in which odd lines and even lines are mixed) is selected in the prediction mode switching circuit 52, the frame DCT mode (mode in which odd lines and even lines are mixed) also in the DCT mode switching circuit 55. ) Is selected, and when the field prediction mode (the mode in which the data of the odd field and the even field are separated) is selected in the prediction mode switching circuit 52, the field in the DCT mode switching circuit 55 is selected. There is a high possibility that a DCT mode (a mode in which data of odd and even fields are separated) is selected.

しかしながら、必ずしも常にそのようになされるわけではなく、予測モード切り換え回路52においては、予測誤差の絶対値和が小さくなるようにモードが決定され、DCTモード切り換え回路55においては、符号化効率が良好となるようにモードが決定される。   However, this is not always the case. In the prediction mode switching circuit 52, the mode is determined so that the absolute value sum of the prediction errors is small, and in the DCT mode switching circuit 55, the coding efficiency is good. The mode is determined so that

DCTモード切り換え回路55より出力されたIピクチャの画像データは、DCT回路56に入力され、DCT(離散コサイン変換)処理され、DCT係数に変換される。このDCT係数は、量子化回路57に入力され、所定の量子化ステップ(量子化スケール)で量子化された後、可変長符号化回路58に入力される。本実施の形態の場合、後述するように、入力データは、量子化スケール1で量子化される。   The I-picture image data output from the DCT mode switching circuit 55 is input to the DCT circuit 56, subjected to DCT (discrete cosine transform) processing, and converted to DCT coefficients. The DCT coefficients are input to the quantization circuit 57, quantized at a predetermined quantization step (quantization scale), and then input to the variable length encoding circuit 58. In the case of the present embodiment, as will be described later, the input data is quantized with a quantization scale 1.

可変長符号化回路58は、量子化回路57より供給される量子化ステップ(スケール)に対応して、量子化回路57より供給される画像データ(いまの場合、Iピクチャのデータ)を、例えばハフマン符号などの可変長符号に変換し、送信バッファ59に出力する。   The variable length encoding circuit 58 corresponds to the quantization step (scale) supplied from the quantization circuit 57, and converts the image data supplied from the quantization circuit 57 (in this case, I picture data), for example, It is converted into a variable length code such as a Huffman code and output to the transmission buffer 59.

可変長符号化回路58には、また、量子化回路57より量子化ステップ(スケール)、予測判定回路54より予測モード(画像内予測、前方予測、後方予測、または両方向予測のいずれが設定されたかを示すモード)、動きベクトル検出回路50より動きベクトル、予測モード切り換え回路52より予測フラグ(フレーム予測モードまたはフィールド予測モードのいずれが設定されたかを示すフラグ)、およびDCTモード切り換え回路55が出力するDCTフラグ(フレームDCTモードまたはフィールドDCTモードのいずれが設定されたかを示すフラグ)が入力されており、これらも可変長符号化される。   The variable-length encoding circuit 58 also has a quantization step (scale) set by the quantization circuit 57 and a prediction mode (intra-picture prediction, forward prediction, backward prediction, or bidirectional prediction) set by the prediction determination circuit 54. ), A motion vector from the motion vector detection circuit 50, a prediction flag (a flag indicating whether the frame prediction mode or the field prediction mode is set) from the prediction mode switching circuit 52, and a DCT mode switching circuit 55. A DCT flag (a flag indicating whether the frame DCT mode or the field DCT mode is set) is input, and these are also variable-length encoded.

送信バッファ59は、入力されたデータを一時蓄積し、送信バッファ59に蓄積されたデータは、所定のタイミングで読み出され、伝送データとして出力される。伝送データは、その後、例えば伝送路74に供給され、伝送路74を介して受信側に伝送されるか、もしくは記録伝送系を介して記録媒体75に記録される。   The transmission buffer 59 temporarily stores the input data, and the data stored in the transmission buffer 59 is read at a predetermined timing and output as transmission data. The transmission data is then supplied to, for example, the transmission path 74 and transmitted to the receiving side via the transmission path 74 or recorded on the recording medium 75 via the recording transmission system.

一方、量子化回路57より出力されたIピクチャのデータは、逆量子化回路60に入力され、量子化回路57より供給される量子化ステップに対応して逆量子化される。逆量子化回路60の出力は、IDCT(逆DCT)回路61に入力され、逆DCT処理された後、加算器72、DCTブロック並び替え回路66を介し、加算器62に供給される。この加算器62の出力は、フレームメモリ63に供給され、前方予測画像部63aに記憶される。また、IDCT回路61からの出力(信号S2)は、減算器70に送られ、そのIDCT回路61からの出力(信号S2)と上記DCTモード切り換え回路55からの出力(信号S1)との差分が演算され、差分データが可変長符号化回路71に供給される。また、この差分データは、加算器72に供給されるが、この詳細については後述する。   On the other hand, the I picture data output from the quantization circuit 57 is input to the inverse quantization circuit 60 and inversely quantized corresponding to the quantization step supplied from the quantization circuit 57. The output of the inverse quantization circuit 60 is input to an IDCT (inverse DCT) circuit 61, subjected to inverse DCT processing, and then supplied to an adder 62 via an adder 72 and a DCT block rearrangement circuit 66. The output of the adder 62 is supplied to the frame memory 63 and stored in the forward predicted image unit 63a. The output from the IDCT circuit 61 (signal S2) is sent to the subtractor 70, and the difference between the output from the IDCT circuit 61 (signal S2) and the output from the DCT mode switching circuit 55 (signal S1) is calculated. The difference data is supplied to the variable length coding circuit 71. The difference data is supplied to the adder 72, details of which will be described later.

動きベクトル検出回路50は、シーケンシャルに入力される各フレームの画像データを、たとえば、I,B,P,B,P,B・・・のピクチャとしてそれぞれ処理する場合、最初に入力されたフレームの画像データをIピクチャとして処理した後、次に入力されたフレームの画像をBピクチャとして処理する前に、さらにその次に入力されたフレームの画像データをPピクチャとして処理する。Bピクチャは、後方予測を伴うため、後方予測画像としてのPピクチャが先に用意されていないと、復号することができないからである。   The motion vector detection circuit 50, when processing the image data of each frame sequentially input as, for example, pictures of I, B, P, B, P, B. After the image data is processed as an I picture, the image data of the next input frame is further processed as a P picture before the image of the next input frame is processed as a B picture. This is because a B picture is accompanied by backward prediction, and therefore cannot be decoded unless a P picture as a backward predicted image is prepared first.

そこで動きベクトル検出回路50は、Iピクチャの処理の次に、後方原画像部51cに記憶されているPピクチャの画像データの処理を開始する。そして、上述した場合と同様に、マクロブロック単位でのフレーム間差分(予測誤差)の絶対値和が、動きベクトル検出回路50から予測モード切り換え回路52と予測判定回路54に供給される。予測モード切り換え回路52は、このPピクチャのマクロブロックの予測誤差の絶対値和に対応して、フレーム/フィールド予測モードを設定する。また、予測判定回路54は、このPピクチャのマクロブロックの予測誤差の絶対値和に対応して、画像内予測、前方予測、後方予測、もしくは両方向予測の予測モードを設定する。   Therefore, the motion vector detection circuit 50 starts processing the image data of the P picture stored in the rear original image portion 51c after the processing of the I picture. As in the case described above, the absolute value sum of the inter-frame difference (prediction error) in units of macroblocks is supplied from the motion vector detection circuit 50 to the prediction mode switching circuit 52 and the prediction determination circuit 54. The prediction mode switching circuit 52 sets the frame / field prediction mode corresponding to the absolute value sum of the prediction errors of the macroblock of the P picture. Further, the prediction determination circuit 54 sets a prediction mode for intra-picture prediction, forward prediction, backward prediction, or bidirectional prediction, corresponding to the sum of the absolute values of the prediction errors of the macroblock of the P picture.

演算部53は画像内予測モードが設定されたとき、スイッチ53dを上述したように接点a側に切り換える。従って、このデータは、Iピクチャのデータと同様に、DCTモード切り換え回路55、DCT回路56、量子化回路57、可変長符号化回路58、送信バッファ59を介して出力される。また、このデータは、逆量子化回路60、IDCT回路61、加算器72、DCTブロック並び替え回路66、加算器62を介して、フレームメモリ63に供給され、後方予測画像部63bに記憶される。   When the in-picture prediction mode is set, the calculation unit 53 switches the switch 53d to the contact a side as described above. Accordingly, this data is output via the DCT mode switching circuit 55, the DCT circuit 56, the quantization circuit 57, the variable length coding circuit 58, and the transmission buffer 59, similarly to the I picture data. The data is supplied to the frame memory 63 via the inverse quantization circuit 60, the IDCT circuit 61, the adder 72, the DCT block rearrangement circuit 66, and the adder 62, and is stored in the backward predicted image unit 63b. .

また、前方予測モードが設定された時、スイッチ53dが接点bに切り換えられるとともに、フレームメモリ63の前方予測画像部63aに記憶されている画像(いまの場合Iピクチャの画像)データが読み出される。この読み出された画像データは、動き補償回路64により、動きベクトル検出回路50が出力する動きベクトルに対応して動き補償される。すなわち、動き補償回路64は、予測判定回路54より前方予測モードの設定が指令されたとき、前方予測画像部63aの読み出しアドレスを、動きベクトル検出回路50がいま出力しているマクロブロックの位置に対応する位置から動きベクトルに対応する分だけずらしてデータを読み出し、予測画像データを生成する。   In addition, when the forward prediction mode is set, the switch 53d is switched to the contact point b, and image (I-picture image in this case) data stored in the forward prediction image portion 63a of the frame memory 63 is read. The read image data is motion-compensated by the motion compensation circuit 64 corresponding to the motion vector output from the motion vector detection circuit 50. That is, when the setting of the forward prediction mode is instructed by the prediction determination circuit 54, the motion compensation circuit 64 sets the read address of the forward prediction image unit 63a to the position of the macro block currently output by the motion vector detection circuit 50. Data is read out from the corresponding position by the amount corresponding to the motion vector, and predicted image data is generated.

動き補償回路64より出力された予測画像データは、減算器53aに供給される。減算器53aは、予測モード切り換え回路52より供給された参照画像のマクロブロックのデータから、動き補償回路64より供給された、このマクロブロックに対応する予測画像データを減算し、その差分(予測誤差)を出力する。この差分データは、DCTモード切り換え回路55、DCT回路56、量子化回路57、可変長符号化回路58、送信バッファ59を介して出力される。また、この差分データは、逆量子化回路60、IDCT回路61により局所的に復号され、加算器72、DCTブロック並び替え回路66を介して加算器62に入力される。   The predicted image data output from the motion compensation circuit 64 is supplied to the subtractor 53a. The subtractor 53a subtracts the prediction image data corresponding to the macroblock supplied from the motion compensation circuit 64 from the macroblock data of the reference image supplied from the prediction mode switching circuit 52, and the difference (prediction error). ) Is output. The difference data is output via the DCT mode switching circuit 55, the DCT circuit 56, the quantization circuit 57, the variable length coding circuit 58, and the transmission buffer 59. The difference data is locally decoded by the inverse quantization circuit 60 and the IDCT circuit 61 and input to the adder 62 via the adder 72 and the DCT block rearrangement circuit 66.

この加算器62にはまた、上記減算器53aに供給されている予測画像データと同一のデータが供給されている。加算器62は、IDCT回路61が出力する差分データに、動き補償回路64が出力する予測画像データを加算する。これにより、元の(復号した)Pピクチャの画像データが得られる。このPピクチャの画像データは、フレームメモリ63の後方予測画像部63bに供給され、記憶される。   The adder 62 is also supplied with the same data as the predicted image data supplied to the subtractor 53a. The adder 62 adds the predicted image data output from the motion compensation circuit 64 to the difference data output from the IDCT circuit 61. As a result, image data of the original (decoded) P picture is obtained. The image data of the P picture is supplied to and stored in the backward predicted image unit 63b of the frame memory 63.

動きベクトル検出回路50は、このように、IピクチャとPピクチャのデータが前方予測画像部63aと後方予測画像部63bにそれぞれ記憶された後、次にBピクチャの処理を実行する。予測モード切り換え回路52は、マクロブロック単位でのフレーム間差分の絶対値和の大きさに対応して、フレーム/フィールドモードを設定し、また、予測判定回路54は、予測モードを画像内予測モード、前方予測モード、後方予測モード、または両方向予測モードのいずれかに設定する。   As described above, the motion vector detection circuit 50 stores the data of the I picture and the P picture in the forward predicted image unit 63a and the backward predicted image unit 63b, respectively, and then executes the process of the B picture. The prediction mode switching circuit 52 sets the frame / field mode corresponding to the magnitude of the sum of absolute values of inter-frame differences in units of macroblocks, and the prediction determination circuit 54 sets the prediction mode to the intra-picture prediction mode. , Forward prediction mode, backward prediction mode, or bidirectional prediction mode.

上述したように、画像内予測モードまたは前方予測モードの時、スイッチ53dは、それぞれ接点aまたはbに切り換えられる。このとき、Pピクチャにおける場合と同様の処理が行われ、データが伝送される。   As described above, in the intra prediction mode or the forward prediction mode, the switch 53d is switched to the contact point a or b, respectively. At this time, the same processing as in the case of the P picture is performed, and data is transmitted.

これに対して、後方予測モードまたは両方向予測モードが設定された時、スイッチ53dは、接点cまたはdにそれぞれ切り換えられる。   On the other hand, when the backward prediction mode or the bidirectional prediction mode is set, the switch 53d is switched to the contact c or d, respectively.

スイッチ53dが接点cに切り換えられている後方予測モードの時、後方予測画像部63bに記憶されている画像(いまの場合、Pピクチャの画像)データが読み出される。この読み出された画像データは、動き補償回路64により、動きベクトル検出回路50が出力する動きベクトルに対応して動き補償される。すなわち、動き補償回路64は、予測判定回路54より後方予測モードの設定が指令されたとき、後方予測画像部63bの読み出しアドレスを、動きベクトル検出回路50がいま出力しているマクロブロックの位置に対応する位置から動きベクトルに対応する分だけずらしてデータを読み出し、予測画像データを生成する。   In the backward prediction mode in which the switch 53d is switched to the contact c, image (in this case, P picture image) data stored in the backward predicted image unit 63b is read. The read image data is motion-compensated by the motion compensation circuit 64 corresponding to the motion vector output from the motion vector detection circuit 50. That is, when the setting of the backward prediction mode is instructed by the prediction determination circuit 54, the motion compensation circuit 64 sets the read address of the backward prediction image unit 63b to the position of the macroblock currently output by the motion vector detection circuit 50. Data is read out from the corresponding position by the amount corresponding to the motion vector, and predicted image data is generated.

動き補償回路64より出力された予測画像データは、減算器53bに供給される。減算器53bは、予測モード切り換え回路52より供給された参照画像のマクロブロックのデータから、動き補償回路64より供給された予測画像データを減算し、その差分を出力する。この差分データは、DCTモード切り換え回路55、DCT回路56、量子化回路57、可変長符号化回路58、送信バッファ59を介して出力される。   The predicted image data output from the motion compensation circuit 64 is supplied to the subtractor 53b. The subtractor 53b subtracts the predicted image data supplied from the motion compensation circuit 64 from the macroblock data of the reference image supplied from the prediction mode switching circuit 52, and outputs the difference. The difference data is output via the DCT mode switching circuit 55, the DCT circuit 56, the quantization circuit 57, the variable length coding circuit 58, and the transmission buffer 59.

スイッチ53dが接点dに切り換えられている両方向予測モードの時、前方予測画像部63aに記憶されている画像(いまの場合、Iピクチャの画像)データと、後方予測画像部63bに記憶されている画像(いまの場合、Pピクチャの画像)データが読み出される。そして、これらの画像データが、動き補償回路64により、動きベクトル検出回路50が出力する動きベクトルに対応して動き補償される。すなわち、動き補償回路64は、予測判定回路54より両方向予測モードの設定が指令されたとき、前方予測画像部63aと後方予測画像部63bの読み出しアドレスを、動きベクトル検出回路50がいま出力しているマクロブロックの位置に対応する位置から動きベクトル(この場合の動きベクトルは、前方予測画像用と後方予測画像用の2つとなる)に対応する分だけずらしてデータを読み出し、予測画像データを生成する。   In the bidirectional prediction mode in which the switch 53d is switched to the contact point d, the image (in this case, the image of I picture) data stored in the forward predicted image unit 63a and the backward predicted image unit 63b are stored. Image (in this case, P picture image) data is read out. These image data are motion-compensated by the motion compensation circuit 64 corresponding to the motion vector output from the motion vector detection circuit 50. That is, in the motion compensation circuit 64, when the setting of the bidirectional prediction mode is instructed by the prediction determination circuit 54, the motion vector detection circuit 50 now outputs the read addresses of the forward prediction image unit 63a and the backward prediction image unit 63b. The data is read out from the position corresponding to the position of the macroblock being read by shifting the motion vector by the amount corresponding to the motion vector (in this case, the motion vector is for the forward prediction image and the backward prediction image), and prediction image data is generated. To do.

動き補償回路64より出力された予測画像データは、減算器53cに供給される。減算器53cは、動きベクトル検出回路50より供給された参照画像のマクロブロックのデータから、動き補償回路64より供給された予測画像データの平均値を減算し、その差分を出力する。この差分データは、DCTモード切り換え回路55、DCT回路56、量子化回路57、可変長符号化回路58、送信バッファ59を介して出力される。   The predicted image data output from the motion compensation circuit 64 is supplied to the subtractor 53c. The subtractor 53c subtracts the average value of the predicted image data supplied from the motion compensation circuit 64 from the macroblock data of the reference image supplied from the motion vector detection circuit 50, and outputs the difference. The difference data is output via the DCT mode switching circuit 55, the DCT circuit 56, the quantization circuit 57, the variable length coding circuit 58, and the transmission buffer 59.

Bピクチャの画像は、他の画像の予測画像とされることがないため、フレームメモリ63には記憶されない。   The B picture image is not stored in the frame memory 63 because it is not a predicted image of another image.

尚、フレームメモリ63において、前方予測画像部63aと後方予測画像部63bは、必要に応じてバンク切り替えが行われ、所定の参照画像に対して、一方または他方に記憶されているものを、前方予測画像あるいは後方予測画像として切り換えて出力することができる。   Note that, in the frame memory 63, the forward predicted image unit 63a and the backward predicted image unit 63b are subjected to bank switching as necessary, and those stored in one or the other with respect to a predetermined reference image It can be switched and output as a predicted image or a backward predicted image.

以上においては、輝度ブロックを中心として説明をしたが、色差ブロックについても同様に、マクロブロックを単位として処理され、伝送される。尚、色差ブロックを処理する場合の動きベクトルは、対応する輝度ブロックの動きベクトルを垂直方向と水平方向に、それぞれ1/2にしたものが用いられる。   In the above description, the luminance block is mainly described, but the color difference block is similarly processed and transmitted in units of macroblocks. As the motion vector for processing the color difference block, the motion vector of the corresponding luminance block is halved in the vertical direction and the horizontal direction.

次に、本発明の実施の形態の要部となるDCT処理時の誤差分の取り出しに関する構成及び動作について詳細に説明する。   Next, a detailed description will be given of the configuration and operation related to the extraction of error during DCT processing, which is the main part of the embodiment of the present invention.

このための構成として、上述した減算器70、加算器72、可変長符号化回路71、及び送信バッファ73が設けられている。   As a configuration for this purpose, the above-described subtractor 70, adder 72, variable length coding circuit 71, and transmission buffer 73 are provided.

Frame/Field DCTモード切り換え回路55から出力される画像信号(Iピクチャの場合)および差分信号(B、Pピクチャの場合)は、DCT回路56および加算器70に出力される。DCT回路56に入力された信号は従来と同様にDCT処理される。   The image signal (in the case of I picture) and the difference signal (in the case of B and P pictures) output from the Frame / Field DCT mode switching circuit 55 are output to the DCT circuit 56 and the adder 70. The signal input to the DCT circuit 56 is subjected to DCT processing as in the prior art.

DCT回路56で、DCT処理された信号は量子化回路57に入力される。量子化回路57においては量子化スケールが1で量子化される。すなわち、量子化回路57は何の処理も加えず入力信号をそのまま出力する。そして、この出力信号が、可変長符号化回路58及び逆量子化回路60に供給される。逆量子化回路60は、同様に量子化スケール1で逆量子化を行なう。   The signal subjected to DCT processing by the DCT circuit 56 is input to the quantization circuit 57. The quantization circuit 57 quantizes the quantization scale at 1. That is, the quantization circuit 57 outputs the input signal as it is without performing any processing. Then, this output signal is supplied to the variable length coding circuit 58 and the inverse quantization circuit 60. Similarly, the inverse quantization circuit 60 performs inverse quantization at the quantization scale 1.

IDCT回路61から出力される信号S2は、減算器70および加算器72に出力される。減算器70では、Frame/Field DCTモード切り換え回路55からの信号S1およびIDCT回路61からの信号S2の差分S3を演算する。即ち、以下の演算
S3=S1−S2
を行ない可変長符号化回路71および加算器72に出力する。
The signal S2 output from the IDCT circuit 61 is output to the subtracter 70 and the adder 72. The subtractor 70 calculates a difference S3 between the signal S1 from the Frame / Field DCT mode switching circuit 55 and the signal S2 from the IDCT circuit 61. That is, the following calculation S3 = S1-S2
Is output to the variable length encoding circuit 71 and the adder 72.

可変長符号化回路71は加算器70からの差分信号S3を可変長符号化し、その出力ビットストリーム(差分ビットストリーム)を、送信バッファ73を介して出力する。送信バッファ73から出力されたデータは、伝送データとして、その後、例えば伝送路74に供給され、伝送路74を介して受信側に伝送されるか、もしくは記録伝送系を介して記録媒体75に記録される。   The variable length coding circuit 71 performs variable length coding on the difference signal S3 from the adder 70 and outputs the output bit stream (difference bit stream) via the transmission buffer 73. The data output from the transmission buffer 73 is then supplied as transmission data, for example, to the transmission path 74 and transmitted to the receiving side via the transmission path 74 or recorded on the recording medium 75 via the recording transmission system. Is done.

加算器72は、IDCT回路61からの信号S2および加算器70からの信号S3を加算して、信号S4として加算器62に出力する。   The adder 72 adds the signal S2 from the IDCT circuit 61 and the signal S3 from the adder 70, and outputs the result to the adder 62 as a signal S4.

ここで、この画像信号符号化装置で、可逆符号化を実現する原理を説明する。信号S1は、DCT処理や量子化処理を行なっていない原信号である。即ち、原画像の情報を全て保存する信号である。この信号に対してDCT処理を行なう場合、量子化処理を行なわない場合(量子化スケールを1で量子化)においても原信号の一部の情報が失われる。これは、DCT処理が実数演算であるのに対して、DCT回路およびIDCT回路は、演算を有限語長に打ち切るためである。   Here, the principle of realizing lossless encoding with this image signal encoding device will be described. The signal S1 is an original signal not subjected to DCT processing or quantization processing. That is, it is a signal for storing all information of the original image. When DCT processing is performed on this signal, some information of the original signal is lost even when quantization processing is not performed (quantization scale is 1). This is because the DCT processing is a real number operation, whereas the DCT circuit and the IDCT circuit abort the operation to a finite word length.

そこで、可逆符号化を実現するためには、このDCT処理によって失われた情報を別途伝送する必要がある。   Therefore, in order to realize lossless encoding, it is necessary to separately transmit information lost by this DCT processing.

IDCT回路61の出力信号S2は、DCTおよびIDCT処理によって一部の情報が失われている。減算器70は信号S1およびS2の差分を演算し、DCT処理によって失われた情報を抽出する。これが信号S3である。加算器72において、信号S2に信号S3を加算することにより、原信号S1を復元することが可能となる。   Some information is lost in the output signal S2 of the IDCT circuit 61 by the DCT and IDCT processing. The subtractor 70 calculates the difference between the signals S1 and S2 and extracts information lost by the DCT process. This is signal S3. By adding the signal S3 to the signal S2 in the adder 72, the original signal S1 can be restored.

次に、上述したような図1に示す画像信号符号化装置から得られた信号を復号するための画像信号復号装置について、図2を参照しながら説明する。   Next, an image signal decoding apparatus for decoding the signal obtained from the image signal encoding apparatus shown in FIG. 1 as described above will be described with reference to FIG.

図2は、本発明の第1の実施の形態の画像信号符号化装置に対応する画像信号復号装置の構成を示すブロック図である。   FIG. 2 is a block diagram showing a configuration of an image signal decoding apparatus corresponding to the image signal encoding apparatus according to the first embodiment of the present invention.

この図2において、上記図1に示す符号化装置から出力され、伝送路74を介して伝送されたか、もしくは記録媒体75に記録されている符号化された画像データは、図示せぬ受信回路で受信されたり、再生装置で再生され、受信バッファ81に一時記憶された後、復号回路90の可変長復号化回路82に供給される。可変長復号化回路82は、受信バッファ81より供給されたデータを可変長復号化し、動きベクトル、予測モード、予測フラグおよびDCTフラグを動き補償回路87に、また、量子化ステップを逆量子化回路83に、それぞれ出力するとともに、復号された画像データを逆量子化回路83に出力する。   In FIG. 2, the encoded image data output from the encoding apparatus shown in FIG. 1 and transmitted via the transmission path 74 or recorded on the recording medium 75 is received by a receiving circuit (not shown). The data is received or reproduced by a reproduction device, temporarily stored in the reception buffer 81, and then supplied to the variable length decoding circuit 82 of the decoding circuit 90. The variable length decoding circuit 82 performs variable length decoding on the data supplied from the reception buffer 81, and the motion vector, prediction mode, prediction flag, and DCT flag are supplied to the motion compensation circuit 87, and the quantization step is an inverse quantization circuit. The decoded image data is output to the inverse quantization circuit 83.

逆量子化回路83は、可変長復号化回路82より供給された画像データを、同じく可変長復号化回路82より供給された量子化ステップ(この場合、量子化ステップ(量子化スケール)は1である)に従って逆量子化し、IDCT回路84に出力する。逆量子化回路83より出力されたデータ(DCT係数)は、IDCT回路84で逆DCT処理され、加算器93、DCTブロック並び替え回路89を介して、加算器85に供給される。加算器93は、上述したDCT処理時の演算語長制限による誤差分を加算するためのものであり、その詳細は後述する。   The inverse quantization circuit 83 converts the image data supplied from the variable length decoding circuit 82 into a quantization step (in this case, the quantization step (quantization scale) is 1) also supplied from the variable length decoding circuit 82. Inverse quantization is performed according to (1), and the result is output to the IDCT circuit 84. The data (DCT coefficient) output from the inverse quantization circuit 83 is subjected to inverse DCT processing by the IDCT circuit 84 and supplied to the adder 85 via the adder 93 and the DCT block rearrangement circuit 89. The adder 93 is for adding an error due to the operation word length limitation during the above-described DCT processing, and details thereof will be described later.

IDCT回路84より供給された画像データが、Iピクチャのデータである場合、そのデータは加算器85より出力され、演算器85に後に入力される画像データ(PまたはBピクチャのデータ)の予測画像データ生成のために、フレームメモリ86に供給され、前方予測画像部86aに記憶される。また、この加算器からの出力データは、出力再生画像として取り出され、後段の例えばフォーマット変換回路(図示せず)等に出力される。   When the image data supplied from the IDCT circuit 84 is I picture data, the data is output from the adder 85, and the predicted image of the image data (P or B picture data) input to the calculator 85 later. For data generation, the data is supplied to the frame memory 86 and stored in the forward predicted image unit 86a. The output data from the adder is taken out as an output reproduction image, and is output to a subsequent stage, for example, a format conversion circuit (not shown).

IDCT回路84より供給された画像データが、その1フレーム前の画像データを予測画像データとするPピクチャのデータであって、前方予測モードのデータである場合、フレームメモリ86の前方予測画像部86aに記憶されている、1フレーム前の画像データ(Iピクチャのデータ)が読み出される。そして、この読み出された画像データが、動き補償回路87で可変長復号化回路82より出力された動きベクトルに対応する動き補償が施される。そして、加算器85において、この動き補償後の画像データとIDCT回路84より供給された画像データ(差分のデータ)とが加算されて、加算されたデータが出力再生画像として出力される。この加算されたデータ、即ち、復号されたPピクチャのデータは、加算器85に後に入力される画像データ(BピクチャまたはPピクチャのデータ)の予測画像データ生成のために、フレームメモリ86に供給され、後方予測画像部86bに記憶される。   When the image data supplied from the IDCT circuit 84 is P picture data having the image data of the previous frame as predicted image data and is data in the forward prediction mode, the forward predicted image portion 86a of the frame memory 86 is used. The image data of one frame before (I picture data) stored in is read out. The read image data is subjected to motion compensation corresponding to the motion vector output from the variable length decoding circuit 82 by the motion compensation circuit 87. The adder 85 adds the image data after the motion compensation and the image data (difference data) supplied from the IDCT circuit 84, and outputs the added data as an output reproduction image. This added data, that is, decoded P picture data, is supplied to the frame memory 86 in order to generate predicted picture data of picture data (B picture or P picture data) to be input to the adder 85 later. And stored in the backward predicted image unit 86b.

Pピクチャのデータであっても、画像内予測モードのデータは、Iピクチャのデータと同様に、加算器85で特に処理は行わず、そのまま後方予測画像部86bに記憶される。   Even in the case of P picture data, the data in the intra prediction mode is stored in the backward predicted image unit 86b as it is without any particular processing in the adder 85, like the I picture data.

このPピクチャは、次のBピクチャの次に表示されるべき画像であるため、この時点では、まだ図示せぬフォーマット変換回路へ出力されない(上述したように、Bピクチャの後に入力されたPピクチャが、Bピクチャより先に処理され、伝送されている)。   Since this P picture is an image to be displayed next to the next B picture, at this point of time, it is not yet output to a format conversion circuit (not shown) (as described above, the P picture input after the B picture) Are processed and transmitted before the B picture).

IDCT回路84より供給された画像データが、Bピクチャのデータである場合、可変長復号化回路82より供給された予測モードに対応して、フレームメモリ86の前方予測画像部86aに記憶されているIピクチャの画像データ(前方予測モードの場合)、後方予測画像部86bに記憶されているPピクチャの画像データ(後方予測モードの場合)、または、その両方の画像データ(両方向予測モードの場合)が読み出される。この読み出された画像データは、動き補償回路87において、可変長復号化回路82より出力された動きベクトルに対応する動き補償が施されて、予測画像が生成される。但し、動き補償を必要としない場合(画像内予測モードの場合)、予測画像は生成されない。   When the image data supplied from the IDCT circuit 84 is B picture data, it is stored in the forward predicted image unit 86a of the frame memory 86 corresponding to the prediction mode supplied from the variable length decoding circuit 82. I-picture image data (in the forward prediction mode), P-picture image data stored in the backward prediction image portion 86b (in the backward prediction mode), or both image data (in the bidirectional prediction mode) Is read out. The read image data is subjected to motion compensation corresponding to the motion vector output from the variable length decoding circuit 82 in the motion compensation circuit 87, and a predicted image is generated. However, when motion compensation is not required (in the case of intra-picture prediction mode), a predicted image is not generated.

このようにして、動き補償回路87で動き補償が施されたデータは、加算器85において、IDCT回路84の出力と加算される。この加算出力は、その後、図示せぬフォーマット変換回路に出力される。   Thus, the data subjected to motion compensation in the motion compensation circuit 87 is added to the output of the IDCT circuit 84 in the adder 85. This added output is then output to a format conversion circuit (not shown).

ただし、この加算出力は、Bピクチャのデータであり、他の画像の予測画像生成のために利用されることがないため、フレームメモリ86には記憶されない。   However, since this addition output is B picture data and is not used for generating a predicted image of another image, it is not stored in the frame memory 86.

Bピクチャの画像が出力された後、後方予測画像部86bに記憶されているPピクチャの画像データが読み出され、動き補償回路87を介して加算器85に供給される。ただし、このとき、動き補償は行われない。   After the B picture image is output, the P picture image data stored in the backward predicted image unit 86 b is read out and supplied to the adder 85 through the motion compensation circuit 87. However, motion compensation is not performed at this time.

なお、このデコーダ31には、図1のエンコーダにおける予測モード切り替え回路52とDCTモード切り替え回路55に対応する回路が図示されていないが、これらの回路に対応する処理、即ち、奇数フィールドと偶数フィールドのラインの信号が分離された構成を、元の混在する構成に必要に応じて戻す処理は、動き補償回路87が実行する。   The decoder 31 does not show circuits corresponding to the prediction mode switching circuit 52 and the DCT mode switching circuit 55 in the encoder of FIG. 1, but processes corresponding to these circuits, that is, an odd field and an even field. The motion compensation circuit 87 executes a process of returning the configuration in which the signals of the first line are separated to the original mixed configuration as necessary.

また、以上においては、輝度信号の処理について説明したが、色差信号の処理も同様に行われる。但し、この場合、動きベクトルは、輝度信号用のものを、垂直方向および水平方向に1/2にしたものが用いられる。   In the above description, the processing of the luminance signal has been described, but the processing of the color difference signal is similarly performed. However, in this case, the motion vector used is a luminance signal halved in the vertical and horizontal directions.

次に、上述した図1の画像信号符号化装置の可変長符号化回路71において可変長符号化された差分ビットストリームの復号処理について説明する。   Next, the decoding process of the differential bit stream that has been variable-length encoded in the variable-length encoding circuit 71 of the image signal encoding device of FIG. 1 described above will be described.

図1の可変長符号化回路71で可変長符号化されて送信バッファ73を介して取り出された差分ビットストリームは、伝送路74から伝送されるかもしくは記録媒体75から再生されて、図2の受信バッファ91に入力される。可変長復号回路92は受信バッファから補正ビットストリームを読みだし、そのビットストリームを可変長符号を復号する。可変長復号回路92は上記画像信号符号化装置における可変長符号化回路71と対をなし、その逆の操作を行なうものである。
可変長復号回路92の出力信号S3’は、上記符号化装置における信号S3と一致する。IDCT回路84の出力信号S2’は、上記符号化装置における信号S2と一致する。
The differential bit stream that has been variable-length encoded by the variable-length encoding circuit 71 of FIG. 1 and extracted through the transmission buffer 73 is transmitted from the transmission path 74 or reproduced from the recording medium 75 to obtain the difference bit stream of FIG. Input to the reception buffer 91. The variable length decoding circuit 92 reads the corrected bit stream from the reception buffer and decodes the variable length code from the bit stream. The variable length decoding circuit 92 is paired with the variable length encoding circuit 71 in the image signal encoding apparatus and performs the reverse operation.
The output signal S3 ′ of the variable length decoding circuit 92 matches the signal S3 in the encoding device. The output signal S2 ′ of the IDCT circuit 84 coincides with the signal S2 in the encoding device.

加算器93は可変長復号回路92の出力S3’およびIDCT回路84の出力信号S2’を加算し、信号S1’を出力する。これは上記符号化装置における信号S1に相当する。   The adder 93 adds the output S3 'of the variable length decoding circuit 92 and the output signal S2' of the IDCT circuit 84, and outputs a signal S1 '. This corresponds to the signal S1 in the encoding device.

以上により、DCT処理を用いた画像信号符号化/復号化装置において可逆符号化を実現することが可能となる。   As described above, lossless encoding can be realized in an image signal encoding / decoding device using DCT processing.

次に、本発明の第2の実施の形態の画像信号符号化装置の形態について図3を参照しながら、また第2の実施の形態の画像符号化装置に対応する画像信号復号装置の形態について図4を参照しながら説明する。   Next, referring to FIG. 3 regarding the form of the image signal encoding apparatus according to the second embodiment of the present invention, and also about the form of the image signal decoding apparatus corresponding to the image encoding apparatus according to the second embodiment. This will be described with reference to FIG.

図3は、本発明の第2の実施の形態の画像信号符号化装置を示すものである。   FIG. 3 shows an image signal encoding apparatus according to the second embodiment of the present invention.

この図3に示す画像信号符号化装置は、減算器70、加算器72および可変長符号化
回路71の動作を除き、上記図1の例における画像信号符号化装置と同様であるため、同様の部分については説明を省略する。
The image signal encoding apparatus shown in FIG. 3 is the same as the image signal encoding apparatus in the example of FIG. 1 except for the operations of the subtractor 70, the adder 72, and the variable length encoding circuit 71. Description of the portion is omitted.

図3の動きベクトル検出回路50は、その出力S1を Frame/Field予測モード切替回路52および加算器70に出力する。Frame/Field 予測モード切替回路52に入力された信号は上記図1の例と同様の処理が行なわれる。   The motion vector detection circuit 50 of FIG. 3 outputs the output S1 to the Frame / Field prediction mode switching circuit 52 and the adder 70. The signal input to the Frame / Field prediction mode switching circuit 52 is processed in the same manner as in the example of FIG.

量子化回路57においては量子化スケールが1で量子化される。すなわち、量子化回路57は何の処理も加えず入力信号をそのまま出力する。そして、この出力信号は、可変長符号化回路58及び逆量子化回路60に供給される。逆量子化回路60は同様に量子化スケール1で逆量子化を行なう。   The quantization circuit 57 quantizes the quantization scale at 1. That is, the quantization circuit 57 outputs the input signal as it is without performing any processing. This output signal is supplied to the variable length coding circuit 58 and the inverse quantization circuit 60. Similarly, the inverse quantization circuit 60 performs inverse quantization at the quantization scale 1.

加算器62から出力される信号S2は、減算器70および加算器72に出力される。減算器70では動きベクトル検出回路50からの信号S1および加算器62からの信号S2の差分S3を計算する。即ち、以下の演算
S3=S1−S2
を行ない可変長符号化回路71および加算器72に出力する。
The signal S2 output from the adder 62 is output to the subtractor 70 and the adder 72. The subtracter 70 calculates a difference S3 between the signal S1 from the motion vector detection circuit 50 and the signal S2 from the adder 62. That is, the following calculation S3 = S1-S2
Is output to the variable length encoding circuit 71 and the adder 72.

可変長符号化回路71は減算器70からの差分信号S3を可変長符号化し、その出力ビットストリーム(補正ビットストリーム)を送信バッファ73を介してに出力する。   The variable length coding circuit 71 performs variable length coding on the difference signal S3 from the subtractor 70 and outputs the output bit stream (correction bit stream) via the transmission buffer 73.

加算器72は、加算器62からの信号S2および減算器70からの信号S3を加算して出力する。   The adder 72 adds the signal S2 from the adder 62 and the signal S3 from the subtractor 70 and outputs the result.

ここで、この画像信号符号化装置で、可逆符号化を実現する原理を説明する。信号S1はDCT処理や量子化処理を行なっていない原信号である。即ち、原画像の情報を全て保存する信号である。この信号に対してDCT処理を行なう場合、量子化処理を行なわない場合(量子化スケールを1で量子化)においても原信号の一部の情報が失われる。これはDCT処理が実数演算であるのに対して、DCT回路およびIDCT回路は演算を有限語長に打ち切るためである。   Here, the principle of realizing lossless encoding with this image signal encoding device will be described. The signal S1 is an original signal that has not been subjected to DCT processing or quantization processing. That is, it is a signal for storing all information of the original image. When DCT processing is performed on this signal, some information of the original signal is lost even when quantization processing is not performed (quantization scale is 1). This is because the DCT processing is a real number operation, whereas the DCT circuit and the IDCT circuit abort the operation to a finite word length.

そこで、可逆符号化を実現するためには、このDCT処理によって失われた情報を別途伝送する必要がある。   Therefore, in order to realize lossless encoding, it is necessary to separately transmit information lost by this DCT processing.

加算器62の出力信号S2は、DCTおよびIDCT処理によって一部の情報が失われている。減算器70はS1およびS2の差分を演算し、DCT処理によって失われた情報を抽出する。これが信号S3である。   Some information is lost in the output signal S2 of the adder 62 by the DCT and IDCT processing. The subtractor 70 calculates the difference between S1 and S2 and extracts information lost by the DCT process. This is signal S3.

加算器72において、信号S2に信号S3を加算し、原信号S1を復元することが可能となる。   In the adder 72, the signal S3 can be added to the signal S2 to restore the original signal S1.

画像信号符号化装置におけるその他の動作は上記図1の例における画像信号符号化装置と同様である。   Other operations in the image signal encoding apparatus are the same as those of the image signal encoding apparatus in the example of FIG.

図4に、第2の実施の形態の画像符号化装置に対応する画像信号復号化装置を示す。   FIG. 4 shows an image signal decoding apparatus corresponding to the image encoding apparatus of the second embodiment.

この図4においては、受信バッファ91、可変長復号回路92および加算器93を除き、上記図2に示した画像信号復号化装置と同様であるため、同様の部分については説明を省略する。   4 is the same as the image signal decoding apparatus shown in FIG. 2 except for the reception buffer 91, the variable length decoding circuit 92, and the adder 93. Therefore, the description of the same parts is omitted.

画像信号符号化装置の可変長符号化回路71において可変長符号された補正ビットストリームは、伝送路から伝送されるかもしくは記録媒体から再生されて、受信バッファ91に入力される。可変長復号回路92は受信バッファから補正ビットストリームを読みだし、そのビットストリームを可変長符号を復号する。可変長復号回路92は画像信号符号化装置における可変長符号化回路71と対をなし、その逆の操作を行なうものである。   The corrected bit stream variable-length encoded in the variable-length encoding circuit 71 of the image signal encoding device is transmitted from the transmission path or reproduced from the recording medium and input to the reception buffer 91. The variable length decoding circuit 92 reads the corrected bit stream from the reception buffer and decodes the variable length code from the bit stream. The variable length decoding circuit 92 is paired with the variable length coding circuit 71 in the image signal coding apparatus, and performs the reverse operation.

可変長復号回路92の出力信号S3’は画像信号符号化装置におけるS3と一致する。加算器85の出力信号S2’は符号化装置におけるS2と一致する。加算器93は可変長復号回路92の出力S3’および加算器85の出力信号S’2を加算して、出力信号S1’として出力する。これは画像信号符号化装置におけるS1に相当する。   The output signal S3 'of the variable length decoding circuit 92 coincides with S3 in the image signal encoding device. The output signal S2 'of the adder 85 coincides with S2 in the encoding device. The adder 93 adds the output S3 'of the variable length decoding circuit 92 and the output signal S'2 of the adder 85, and outputs the result as an output signal S1'. This corresponds to S1 in the image signal encoding device.

以上のような図3、図4の構成により、DCT処理を用いた画像信号符号化/復号化装置において可逆符号化を実現することが可能となる。   3 and 4 as described above, it is possible to realize lossless encoding in an image signal encoding / decoding apparatus using DCT processing.

次に、本発明の第3の実施の形態の画像信号符号化装置の形態について、図5〜図7を参照しながら説明する。   Next, the form of the image signal encoding apparatus according to the third embodiment of the present invention will be described with reference to FIGS.

この第3の実施の形態の形態においては、所定のブロック毎に、mビット、例えば10ビットの画像データの代表値データおよび量子化幅を決定し、前記画像データと前記代表値データの差分を算出する。そして、その差分データを前記量子化幅に基づいて量子化し、第1の量子化データを生成する。さらに、その第1の量子化データに所定の変換処理を施し、変換係数を生成し、その変換係数を量子化し、第2の量子化データを生成する。そして、代表値データ、量子化幅、および第2の量子化データを符号化するものであって、第1の量子化の際に量子化幅の中央に代表値がくるようにして量子化誤差を減少させている。また、mビット、例えば10ビット画像の動き補償をnビット、例えば8ビットで行なうことによりメモリを減少させることができる。これは、動き予測のあたらない下位ビットはイントラで送ることに相当する。また、mビット、例えば10ビット画像の符号化の際に、可逆圧縮符号化と非可逆圧縮符号化とを適応的に切り換えることにより、高精細な画像を可逆圧縮することを可能にする。さらに、第1の量子化における量子化幅に基づいて第2の量子化を行ない、均一な画質の画像を得ることを可能にする。   In the third embodiment, for each predetermined block, m-bit, for example, 10-bit representative value data and quantization width of 10-bit image data are determined, and the difference between the image data and the representative value data is determined. calculate. Then, the difference data is quantized based on the quantization width to generate first quantized data. Furthermore, a predetermined conversion process is performed on the first quantized data, a conversion coefficient is generated, the conversion coefficient is quantized, and second quantized data is generated. Then, the representative value data, the quantization width, and the second quantization data are encoded, and the quantization error is set so that the representative value comes to the center of the quantization width at the time of the first quantization. Is decreasing. Further, the memory can be reduced by performing motion compensation of m bits, for example, 10-bit images, by n bits, for example, 8 bits. This is equivalent to sending the lower bits not subjected to motion prediction by intra. In addition, when encoding an m-bit image, for example, a 10-bit image, high-definition images can be losslessly compressed by adaptively switching between lossless compression encoding and lossy compression encoding. Further, the second quantization is performed based on the quantization width in the first quantization, and an image with uniform image quality can be obtained.

図5は、本発明の第3の実施の形態の形態としての画像信号符号化装置を示すブロック図である。   FIG. 5 is a block diagram showing an image signal encoding apparatus as a third embodiment of the present invention.

この図5に示す画像信号符号化装置においては、ビット精度が8ビット精度より高精度な、例えば10ビット精度の画像データが装置に入力されるものとして説明をする。本例では10ビット画像信号についての具体例を示すが、これは10ビット以上のビット精度の画像信号にも同様に適用できる。   The image signal encoding apparatus shown in FIG. 5 will be described on the assumption that image data having a bit accuracy higher than 8-bit accuracy, for example, 10-bit accuracy, is input to the apparatus. In this example, a specific example of a 10-bit image signal is shown, but this can be similarly applied to an image signal having a bit accuracy of 10 bits or more.

フィールドメモリ群1は、10ビット精度の画像データを記憶することができるようになされている。例えば、フィールドメモリ群1は、16×16画素などのブロックに分割されたディジタル画像データ(画像の画素データ)を一時記憶し、フィールドメモリコントローラ16により入力画像の同期信号に対応して生成されたタイミング制御信号に基づいて、演算器3に10ビット精度の画像データのブロックを出力する。   The field memory group 1 can store 10-bit precision image data. For example, the field memory group 1 temporarily stores digital image data (image pixel data) divided into blocks of 16 × 16 pixels or the like, and is generated by the field memory controller 16 corresponding to the synchronization signal of the input image. Based on the timing control signal, a block of image data with 10-bit accuracy is output to the arithmetic unit 3.

動き予測回路2は、前述したようにして、フィールドメモリ群1に記憶された参照画像としての画像データのブロックに対する動き補償モード(画像内予測モード、または前方予測、後方予測もしくは両方向予測モードのいずれか)を設定し、設定した動き補償モードに対応する予測画像と参照画像の間の動きベクトルを検出して、動き補償回路14とVLC回路15に出力する。さらに、動き予測回路2は、動き補償モードを動き補償回路14およびVLC回路(可変長符号化回路)15の他、動き補償回路14を介してブロック内代表値計算回路5およびブロック量子化幅計算回路6に供給する。   As described above, the motion prediction circuit 2 uses a motion compensation mode (intra-picture prediction mode, forward prediction, backward prediction, or bidirectional prediction mode) for a block of image data as a reference image stored in the field memory group 1. And a motion vector between the predicted image and the reference image corresponding to the set motion compensation mode is detected and output to the motion compensation circuit 14 and the VLC circuit 15. Further, the motion prediction circuit 2 sets the motion compensation mode to the intra-block representative value calculation circuit 5 and the block quantization width calculation via the motion compensation circuit 14 in addition to the motion compensation circuit 14 and the VLC circuit (variable length coding circuit) 15. Supply to circuit 6.

なお、図5における動き予測回路2は、図1における場合と同様に構成されているものであり、従って、動き予測回路2には8ビット精度の画像データを入力することができるように構成されているので、フィールドメモリ群1からの接続線をすべて接続することができない。   Note that the motion prediction circuit 2 in FIG. 5 is configured in the same manner as in FIG. 1, and thus is configured so that 8-bit precision image data can be input to the motion prediction circuit 2. Therefore, all the connection lines from the field memory group 1 cannot be connected.

そこで、動き予測回路2には、フィールドメモリ群1からの10ビット精度の画像データに対応する接続線のうち、下位2ビットの接続線を除く接続線が接続されている。   Therefore, among the connection lines corresponding to the 10-bit precision image data from the field memory group 1, connection lines other than the lower 2 bits are connected to the motion prediction circuit 2.

即ち、動き予測回路2には、10ビット精度の画像データの、下位2ビットを切り捨てた8ビット精度の画像データが入力されるようになされている。   In other words, the motion prediction circuit 2 is inputted with 8-bit precision image data obtained by discarding the lower 2 bits of the 10-bit precision image data.

フィールドメモリ群1に記憶された参照画像としての10ビット精度の画像データのブロックが、そこから読み出され、演算器3に供給されると、さらに演算器3に、動き予測回路2で設定された動き補償モードに対応する予測画像が、フィールドメモリ群13を介して動き補償回路14より供給される。   When a block of 10-bit precision image data as a reference image stored in the field memory group 1 is read from the block and supplied to the computing unit 3, it is further set in the computing unit 3 by the motion prediction circuit 2. A predicted image corresponding to the motion compensation mode is supplied from the motion compensation circuit 14 via the field memory group 13.

演算器3において、前述したようにして、動き補償モードに対応する減算処理が行われ(動き補償モードが画像内予測モードである場合には、フィールドメモリ群1からの10ビット精度の画像データのブロックがそのまま出力され、動き補償モードが画像間予測モード(前方予測、後方予測もしくは両方向予測モードのいずれか)である場合には、フィールドメモリ群1からの10ビット精度の画像データのブロックと、動き補償回路14からの予測画像との差分(予測誤差)が算出される)、10ビット精度の演算出力が信号S1として、演算器4、ブロック内代表値計算回路5、ブロック量子化幅計算回路5、および減算器70に供給される。   The arithmetic unit 3 performs the subtraction process corresponding to the motion compensation mode as described above (when the motion compensation mode is the intra-picture prediction mode, the 10-bit precision image data from the field memory group 1 is processed. If the block is output as it is and the motion compensation mode is an inter-picture prediction mode (either forward prediction, backward prediction or bidirectional prediction mode), a block of 10-bit precision image data from the field memory group 1; The difference (prediction error) from the predicted image from the motion compensation circuit 14 is calculated), and a 10-bit precision calculation output is the signal S1, the calculator 4, the intra-block representative value calculation circuit 5, and the block quantization width calculation circuit 5 and the subtractor 70.

ブロック内代表値計算回路(以下、代表値計算回路と記載する)5は、動き補償回路4を介して動き予測回路2より供給された動き補償モードに対応して、演算器3の演算出力の代表値データを、後述するようにして算出し、減算器4に出力する。ブロック量子化幅計算回路(以下、量子化幅計算回路と記載する)6は、動き補償回路4を介して動き予測回路2より供給された動き補償モードに対応して、演算器3の演算出力を、ブロック量子化器7で量子化する量子化幅Qを、後述するようにして算出し、ブロック量子化器7およびブロック逆量子化器10に出力する。   An intra-block representative value calculation circuit (hereinafter referred to as a representative value calculation circuit) 5 outputs the calculation output of the calculator 3 in accordance with the motion compensation mode supplied from the motion prediction circuit 2 via the motion compensation circuit 4. The representative value data is calculated as described later and output to the subtracter 4. A block quantization width calculation circuit (hereinafter referred to as a quantization width calculation circuit) 6 corresponds to the motion compensation mode supplied from the motion prediction circuit 2 via the motion compensation circuit 4 and outputs the computation output of the computing unit 3. The quantization width Q to be quantized by the block quantizer 7 is calculated as described later, and is output to the block quantizer 7 and the block inverse quantizer 10.

ここで、本明細書中においては、量子化幅計算回路6により決定される量子化幅と、差分信号符号化器8、差分信号復号化器9及び図8における差分信号復号化器22における量子化幅をそれぞれを量子化幅Q,Sと記載して区別する。   Here, in this specification, the quantization width determined by the quantization width calculation circuit 6, the quantum in the differential signal encoder 8, the differential signal decoder 9, and the differential signal decoder 22 in FIG. The quantization widths are distinguished by describing them as quantization widths Q and S, respectively.

演算器3の演算出力は、減算器4において代表値計算回路5より出力された代表値データとの差分が演算され、差分データがブロック量子化器7に出力される。ブロック量子化器7において、減算器4の演算出力が量子化幅Qで量子化され、即ち量子化幅Qで除算され、差分信号符号化器8に出力される。   The difference between the calculation output of the calculator 3 and the representative value data output from the representative value calculation circuit 5 in the subtractor 4 is calculated, and the difference data is output to the block quantizer 7. In the block quantizer 7, the operation output of the subtractor 4 is quantized by the quantization width Q, that is, divided by the quantization width Q and output to the differential signal encoder 8.

差分信号符号化器8は、DCT回路111および量子化器112より構成されている。DCT回路111は、ブロック量子化器7からの量子化データを、DCT(離散コサイン変換)処理し、DCT係数に変換する。このDCT係数は、量子化器112に入力され、所定の量子化幅Sで量子化された後、VLC回路15に入力される。なお本実施の形態においては、量子化幅Sは1に設定される。   The differential signal encoder 8 includes a DCT circuit 111 and a quantizer 112. The DCT circuit 111 performs DCT (Discrete Cosine Transform) processing on the quantized data from the block quantizer 7 and converts it into DCT coefficients. The DCT coefficient is input to the quantizer 112, quantized with a predetermined quantization width S, and then input to the VLC circuit 15. In the present embodiment, the quantization width S is set to 1.

ここで、前述したように、差分信号符号化器8のDCT回路111には、8ビット精度の画像データ、即ち動き補償モードが画像内予測モードの場合、0乃至255の8ビットで表すことのできる画像データを、動き補償モードが画像間予測モード(前方予測、後方予測もしくは両方向予測モードのいずれか)の場合、8ビットに符号ビットを加えた−255乃至255の9ビットで表すことのできる画像データを入力する必要がある。   Here, as described above, the DCT circuit 111 of the differential signal encoder 8 indicates that 8-bit precision image data, that is, 8 bits from 0 to 255 when the motion compensation mode is the intra-picture prediction mode. When the motion compensation mode is an inter-picture prediction mode (forward prediction, backward prediction, or bidirectional prediction mode), the image data that can be represented can be represented by 9 bits from −255 to 255, which is 8 bits plus a sign bit. It is necessary to input image data.

つまり、画像信号符号化装置に入力された画像データのブロックのビット精度を10ビット精度から8ビット精度に変換して、差分信号符号化器8に入力する必要がある。   That is, it is necessary to convert the bit accuracy of the block of image data input to the image signal encoding device from 10-bit accuracy to 8-bit accuracy, and input to the differential signal encoder 8.

そこで、動き補償モードが画像内予測モードである場合、代表値計算回路5においては、演算器3の演算出力(この場合、フィールドメモリ群1からの10ビット精度の画像データのブロック)の最大値および最小値が検出され、そのうちの、例えば最小値が、演算器3から出力された10ビット精度の画像データのブロックの代表値データとされて演算器4および11に出力される。   Therefore, when the motion compensation mode is the intra-picture prediction mode, the representative value calculation circuit 5 has the maximum value of the calculation output of the calculator 3 (in this case, a block of 10-bit precision image data from the field memory group 1). The minimum value is detected and, for example, the minimum value is output to the calculators 4 and 11 as representative value data of a block of 10-bit precision image data output from the calculator 3.

なお、この場合、ブロックの代表値データは、ブロックの最小値でなくとも良い。但し、動き補償モードが画像内予測モードである場合においては、画像データを0乃至255の8ビットで表す必要があるので、ブロックの代表値データを、ブロックの最小値としたときが、後述するブロックのダイナミックレンジを最も大きくとれるようになる。   In this case, the representative value data of the block may not be the minimum value of the block. However, when the motion compensation mode is the intra prediction mode, it is necessary to represent the image data with 8 bits from 0 to 255. Therefore, when the block representative value data is set to the minimum value of the block, it will be described later. The dynamic range of the block can be maximized.

そして、演算器4において、演算器3から出力された10ビット精度の画像データのブロック(ブロックにおける画素データそれぞれ)と、代表値計算回路5から出力されたブロックの代表値データ、即ちブロックの最小値との差分が演算され、ブロック量子化器7に出力される。   Then, in the computing unit 4, the block of 10-bit precision image data output from the computing unit 3 (each pixel data in the block) and the representative value data of the block output from the representative value calculation circuit 5, that is, the minimum of the block The difference from the value is calculated and output to the block quantizer 7.

従って、この場合、ブロック量子化器7には、0を最小値とする画像データのブロックがブロック量子化器7に出力されることになる。   Therefore, in this case, the block quantizer 7 outputs a block of image data having a minimum value of 0 to the block quantizer 7.

即ち、動き補償モードが画像内予測モードである場合、例えば図6(a)に示すように、演算器3から出力された10ビット精度の画像データのブロックの最大値または最小値が、それぞれ500または300であれば、その画像データのブロックから代表値データとしての最小値300を減算した0(=300−300)乃至200(=500−300)の範囲の値を有する画像データのブロックが演算器4からブロック量子化器7に出力される。また、例えば図7(a)に示すように、演算器3から出力された10ビット精度の画像データのブロックの最大値または最小値が、それぞれ1000または300であれば、その画像データのブロックから代表値データとしての最小値300減算した0(=300−300)乃至700(=1000−300)の範囲の値を有する画像データのブロックが
演算器4からブロック量子化器7に出力されることになる。
That is, when the motion compensation mode is the intra prediction mode, for example, as shown in FIG. 6A, the maximum value or the minimum value of the block of 10-bit precision image data output from the computing unit 3 is 500 respectively. If 300, the block of image data having a value in the range of 0 (= 300-300) to 200 (= 500-300) obtained by subtracting the minimum value 300 as representative value data from the block of image data is calculated. Is output from the unit 4 to the block quantizer 7. For example, as shown in FIG. 7A, if the maximum value or the minimum value of the block of 10-bit precision image data output from the computing unit 3 is 1000 or 300, respectively, the block of the image data A block of image data having a value in the range of 0 (= 300-300) to 700 (= 1000-300) obtained by subtracting the minimum value 300 as representative value data is output from the computing unit 4 to the block quantizer 7. become.

同時に、この場合、量子化幅計算回路6において、演算器3の演算出力(この場合、フィールドメモリ群1からの10ビット精度の画像データのブロック)の最大値および最小値が検出され、その差としてのダイナミックレンジが算出される。   At the same time, in this case, the quantization width calculation circuit 6 detects the maximum value and the minimum value of the arithmetic output of the arithmetic unit 3 (in this case, a block of 10-bit precision image data from the field memory group 1), and the difference between them is detected. The dynamic range is calculated.

ここで、本明細書中においては、信号のダイナミックレンジとは、その信号の最大値と最小値の差を意味するものとする。   In this specification, the dynamic range of a signal means the difference between the maximum value and the minimum value of the signal.

そして、量子化幅計算回路6において、フィールドメモリ群1からの10ビット精度の画像データのブロックのダイナミックレンジが、0乃至255の範囲で表すことのできる8ビット以内であるか否かが判定され、そのダイナミックレンジが8ビット以内であると判定された場合、量子化幅Qが1に決定され、ブロック量子化器7に出力される。   Then, the quantization width calculation circuit 6 determines whether or not the dynamic range of the block of 10-bit precision image data from the field memory group 1 is within 8 bits that can be expressed in the range of 0 to 255. When it is determined that the dynamic range is within 8 bits, the quantization width Q is determined to be 1 and output to the block quantizer 7.

従って、動き補償モードが画像内予測モードである場合、演算器3から出力された10ビット精度の画像データのブロックのダイナミックレンジが8ビット以内であれば(例えば、図6(a)、ブロック量子化器7からは、演算器4からの画像データがそのまま差分信号符号化器8に出力されることになる。   Therefore, when the motion compensation mode is the intra prediction mode, if the dynamic range of the block of 10-bit precision image data output from the computing unit 3 is within 8 bits (for example, FIG. From the encoder 7, the image data from the arithmetic unit 4 is output to the differential signal encoder 8 as it is.

つまり、動き補償モードが画像内予測モードである場合、演算器3から出力された10ビット精度の画像データのブロックのダイナミックレンジが8ビット以内であるとき、演算器3から出力された画像データのブロックのビット精度は実質的に8ビットであり、この8ビット精度の画像データのブロックが差分信号符号化器8に出力されることになる。   That is, when the motion compensation mode is the intra prediction mode, when the dynamic range of the block of 10-bit precision image data output from the calculator 3 is within 8 bits, the image data output from the calculator 3 The bit accuracy of the block is substantially 8 bits, and this block of image data with an 8-bit accuracy is output to the differential signal encoder 8.

さらに、動き補償モードが画像内予測モードである場合、量子化幅計算回路6において、フィールドメモリ群1からの10ビット精度の画像データのブロックのダイナミックレンジが、8ビットを越える(256以上である)と判定されたとき、ブロック量子化器7の量子化出力のダイナミックレンジが8ビット(255)以内になるように量子化幅Qが決定され、ブロック量子化器7に出力される。   Further, when the motion compensation mode is the intra-picture prediction mode, the dynamic range of the block of 10-bit precision image data from the field memory group 1 exceeds 8 bits in the quantization width calculation circuit 6 (256 or more). ), The quantization width Q is determined so that the dynamic range of the quantization output of the block quantizer 7 is within 8 bits (255), and is output to the block quantizer 7.

即ち、フィールドメモリ群1からの10ビット精度の画像データのブロックのダイナミックレンジが、例えば256以上512未満である場合、量子化幅Qは2に決定される。さらに、そのダイナミックレンジが、例えば512以上768未満である場合、量子化幅Qは3に決定され、またダイナミックレンジが、例えば768以上1024未満である場合、量子化幅Qは4に決定される。   That is, when the dynamic range of the block of 10-bit precision image data from the field memory group 1 is, for example, 256 or more and less than 512, the quantization width Q is determined to be 2. Further, when the dynamic range is, for example, 512 or more and less than 768, the quantization width Q is determined to be 3, and when the dynamic range is, for example, 768 or more and less than 1024, the quantization width Q is determined to be 4. .

次にブロック量子化器7における量子化方法について説明する。量子化幅Qが1の場合、ブロック量子化器7は何も処理を行なわず、演算器4からの画像データがそのまま差分信号符号化器8に出力される。   Next, a quantization method in the block quantizer 7 will be described. When the quantization width Q is 1, the block quantizer 7 does not perform any processing and the image data from the arithmetic unit 4 is output to the differential signal encoder 8 as it is.

量子化幅Qが2であるとき、演算器4からの画像データは量子化幅4で除算される。ただし、このとき少数点以下は切り捨てられる。   When the quantization width Q is 2, the image data from the computing unit 4 is divided by the quantization width 4. However, at this time, the decimal point is rounded down.

量子化幅Qが3であるとき、演算器4からの画像データxは量子化幅3で以下の式にしたがい量子化される(X)。ただし、このとき少数点以下は切り捨てられる。
(x≧0 のとき) X=(x+1)/3
(x<0 のとき) X=(x−1)/3
量子化幅Qが4であるとき、演算器4からの画像データxは量子化幅4で以下の式に従い量子化出力Xに量子化される。ただし、このとき少数点以下は切り捨てられる。
(x≧0 のとき) X=(x+1)/4
(x<0 のとき) X=(x−1)/4
また量子化幅Qが4の時、この変形として、以下のように量子化することもできる。
(x≧0 のとき) X=(x+2)/4
(x<0 のとき) X=(x−2)/4
ただし、これらを混在させて使用することは出来ない。
When the quantization width Q is 3, the image data x from the computing unit 4 is quantized with the quantization width 3 according to the following equation (X). However, at this time, the decimal point is rounded down.
(When x ≧ 0) X = (x + 1) / 3
(When x <0) X = (x−1) / 3
When the quantization width Q is 4, the image data x from the computing unit 4 is quantized to a quantization output X with the quantization width 4 according to the following expression. However, at this time, the decimal point is rounded down.
(When x ≧ 0) X = (x + 1) / 4
(When x <0) X = (x−1) / 4
When the quantization width Q is 4, as a modification, the quantization can be performed as follows.
(When x ≧ 0) X = (x + 2) / 4
(When x <0) X = (x−2) / 4
However, these cannot be used together.

以上のようにして、動き補償モードが画像内予測モードである場合、演算器4からの10ビット精度の画像データのブロックのダイナミックレンジが、8ビットを越える(256以上である)とき、ブロック量子化器7において、演算器4からの10ビット精度の画像データのブロックが、8ビット精度の画像データのブロックに変換され、差分信号符号化器8に出力される。   As described above, when the motion compensation mode is the intra-picture prediction mode, when the dynamic range of the block of 10-bit precision image data from the computing unit 4 exceeds 8 bits (256 or more), the block quantum In the coder 7, the block of 10-bit precision image data from the computing unit 4 is converted into a block of 8-bit precision image data and output to the differential signal coder 8.

一方、動き補償モードが画像間予測モード(前方予測、後方予測もしくは両方向予測モードのいずれか)である場合、代表値計算回路5においては、演算器3の演算出力(この場合、フィールドメモリ群1からの10ビット精度の画像データのブロックと予測画像との差分データ)の最大値および最小値が検出され、その、例えば平均値(=(最大値+最小値)/2、但し小数点以下切り捨て)が、演算器3から出力された10ビット精度の画像データのブロックの代表値データとされて演算器4および11に出力される。   On the other hand, when the motion compensation mode is the inter-picture prediction mode (forward prediction, backward prediction, or bidirectional prediction mode), the representative value calculation circuit 5 outputs the calculation output of the calculator 3 (in this case, the field memory group 1 The maximum value and the minimum value of the difference data between the block of 10-bit precision image data from the image and the predicted image) are detected, for example, the average value (= (maximum value + minimum value) / 2, but rounded down to the nearest decimal point) Are output to the calculators 4 and 11 as representative value data of a block of 10-bit precision image data output from the calculator 3.

なお、この場合、ブロックの代表値データは、ブロック(ブロック内の画素)の最大値と最小値の平均値(以下、ブロックの平均値と記載する)ではなく、例えばブロックの最小値や0にすることができる。但し、動き補償モードが画像間予測モードである場合においては、画像データを上述したように−255乃至255の範囲の9ビットで表す必要があるので、ブロックの代表値データを、ブロックの平均値としたときが、ブロックのダイナミックレンジを最も大きくとれるようになる。   In this case, the representative value data of the block is not the average value of the maximum value and the minimum value of the block (pixels in the block) (hereinafter referred to as the average value of the block), for example, the minimum value of the block or 0 can do. However, when the motion compensation mode is the inter-picture prediction mode, it is necessary to represent the image data with 9 bits in the range of −255 to 255 as described above. However, the maximum dynamic range of the block can be obtained.

そして、減算器4において、演算器3から出力された10ビット精度の画像データのブロック(ブロックにおける画素データそれぞれ)と、代表値計算回路5から出力されたブロックの代表値データ、即ちブロックの平均値との差分がとられ、ブロック量子化器7に出力される。   Then, in the subtractor 4, the block of 10-bit precision image data output from the calculator 3 (each pixel data in the block) and the block representative value data output from the representative value calculation circuit 5, that is, the average of the blocks The difference from the value is taken and output to the block quantizer 7.

従って、この場合、ブロック量子化器7には、最大値と最小値の絶対値が等しい画像データのブロックがブロック量子化器7に出力されることになる。   Therefore, in this case, the block quantizer 7 outputs a block of image data having the same absolute value of the maximum value and the minimum value to the block quantizer 7.

即ち、動き補償モードが画像間予測モードである場合、例えば図6(b)に示すように、演算器3から出力された10ビット精度の画像データのブロックの最大値または最小値が、それぞれ−155または355であれば、その画像データブロックから、代表値データとしての平均値100(=(−155+355)/2)を減算した−255(=−155−100)乃至255(=355−100)の範囲の値を有する画像データのブロックが演算器4からブロック量子化器7に出力される。また、例えば図7(b)に示すように、演算器3から出力された10ビット精度の画像データのブロックの最大値または最小値が、それぞれ1000または−1000であれば、平均値0(=(−1000+1000)/2)、−1000(=−1000−0)乃至1000(=1000−0)の範囲の値を有する画像データのブロックがブロック量子化器7に出力されることになる。   That is, when the motion compensation mode is the inter-picture prediction mode, for example, as shown in FIG. 6B, the maximum value or the minimum value of the block of 10-bit precision image data output from the computing unit 3 is − If it is 155 or 355, an average value 100 (= (− 155 + 355) / 2) as representative value data is subtracted from the image data block, −255 (= −155-100) to 255 (= 355-100). A block of image data having a value in the range is output from the computing unit 4 to the block quantizer 7. For example, as shown in FIG. 7B, if the maximum value or the minimum value of the block of 10-bit precision image data output from the computing unit 3 is 1000 or −1000, respectively, the average value 0 (= A block of image data having a value in the range of (−1000 + 1000) / 2), −1000 (= −1000−0) to 1000 (= 1000−0) is output to the block quantizer 7.

同時に、この場合、量子化幅計算回路6において、演算器3の演算出力(この場合、フィールドメモリ群1からの10ビット精度の画像データのブロックと、予測画像との差分データ)の最大値および最小値が検出され、その差としてのダイナミックレンジが算出される。   At the same time, in this case, in the quantization width calculation circuit 6, the maximum value of the calculation output of the calculator 3 (in this case, the difference data between the block of 10-bit precision image data from the field memory group 1 and the predicted image) and The minimum value is detected, and the dynamic range as the difference is calculated.

そして、量子化幅計算回路6において、フィールドメモリ群1からの10ビット精度の画像データのブロックのダイナミックレンジが、−255乃至255の範囲で表すことのできる符号ビット1ビットを含む9ビット以内であるか否かが判定され、そのダイナミックレンジが9ビット以内であると判定された場合、量子化幅Qが1に決定され、ブロック量子化器7に出力される。   In the quantization width calculation circuit 6, the dynamic range of the 10-bit precision image data block from the field memory group 1 is within 9 bits including 1 sign bit that can be expressed in the range of −255 to 255. When it is determined whether or not the dynamic range is within 9 bits, the quantization width Q is determined as 1 and output to the block quantizer 7.

従って、動き補償モードが画像間予測モードである場合、演算器3から出力された10ビット精度の画像データ(差分データ)のブロックのダイナミックレンジが9ビット以内であれば(例えば、図6(a))、ブロック量子化器7からは、演算器4からの画像データがそのまま差分信号符号化器8に出力されることになる。   Therefore, when the motion compensation mode is the inter-picture prediction mode, if the dynamic range of the block of 10-bit precision image data (difference data) output from the computing unit 3 is within 9 bits (for example, FIG. )), The block quantizer 7 outputs the image data from the arithmetic unit 4 to the differential signal encoder 8 as it is.

つまり、動き補償モードが画像間予測モードである場合、演算器3から出力された10ビット精度の画像データのブロックのダイナミックレンジが9ビット以内であるとき、演算器3から出力された画像データのブロックのビット精度は実質的に8ビットであり、この8ビット精度の画像データのブロックが差分信号符号化器8に出力されることになる。   That is, when the motion compensation mode is the inter-picture prediction mode, when the dynamic range of the block of 10-bit precision image data output from the arithmetic unit 3 is within 9 bits, the image data output from the arithmetic unit 3 The bit accuracy of the block is substantially 8 bits, and this block of image data with an 8-bit accuracy is output to the differential signal encoder 8.

さらに、動き補償モードが画像間予測モードである場合、量子化幅計算回路6において、フィールドメモリ群1からの10ビット精度の画像データのブロックのダイナミックレンジが、9ビットを越える(−255乃至255の範囲外である)と判定されたとき、ブロック量子化器7の量子化出力のダイナミックレンジが9ビット以下(511未満)(−255乃至255の範囲内)になるように量子化幅Qが決定され、ブロック量子化器7に出力される。   Further, when the motion compensation mode is the inter-picture prediction mode, the dynamic range of the 10-bit precision image data block from the field memory group 1 exceeds 9 bits in the quantization width calculation circuit 6 (−255 to 255). The quantization width Q is set so that the dynamic range of the quantization output of the block quantizer 7 is 9 bits or less (less than 511) (within the range of -255 to 255). It is determined and output to the block quantizer 7.

即ち、フィールドメモリ群1からの10ビット精度の画像データのブロックのダイナミックレンジが、例えば512以上1024未満である場合、量子化幅Qは2に決定される。さらに、そのダイナミックレンジが、例えば1024以上1536未満である場合、量子化幅Qは3に決定され、またダイナミックレンジが、例えば1536以上2048未満である場合、量子化幅Qは4に決定される。   That is, when the dynamic range of a block of 10-bit precision image data from the field memory group 1 is, for example, 512 or more and less than 1024, the quantization width Q is determined to be 2. Further, when the dynamic range is, for example, 1024 or more and less than 1536, the quantization width Q is determined to be 3, and when the dynamic range is, for example, 1536 or more and less than 2048, the quantization width Q is determined to be 4. .

動き補償モードが画像間予測モードの場合においても、ブロック量子化器7は同一の動作をする。量子化方法は同一である。   Even when the motion compensation mode is the inter-picture prediction mode, the block quantizer 7 performs the same operation. The quantization method is the same.

以上のようにして、動き補償モードが画像間予測モードである場合、減算器4からの10ビット精度の画像データのブロックのダイナミックレンジが、9ビットを越える(512以上である)とき、ブロック量子化器7において、減算器4からの10ビット精度の画像データのブロックが、8ビット精度の画像データのブロックに変換され、差分信号符号化器8に出力される。   As described above, when the motion compensation mode is the inter-picture prediction mode, when the dynamic range of the block of 10-bit precision image data from the subtractor 4 exceeds 9 bits (512 or more), the block quantum In the encoder 7, the block of 10-bit precision image data from the subtractor 4 is converted into a block of 8-bit precision image data and output to the differential signal encoder 8.

以上のように、画像信号符号化装置に10ビット精度の画像データのブロックが入力された場合には、差分信号符号化器8に、8ビット精度の画像データのブロックが入力されるように、減算器4およびブロック量子化器8において、10ビット精度の画像データのブロック、8ビット精度の画像データのブロックに変換される。   As described above, when a block of 10-bit precision image data is input to the image signal encoding apparatus, an 8-bit precision image data block is input to the differential signal encoder 8. In the subtractor 4 and the block quantizer 8, the image data is converted into a block of 10-bit precision image data and a block of 8-bit precision image data.

ところで、ビット精度が8ビット精度より高精度な、例えば10ビット精度の画像を、例えば8×8画素や16×16画素などの小ブロックに分割した場合、各ブロックにおけるダイナミックレンジは、一般的に大きくないこと(動き補償モードが画像内予測モードの場合、ブロックのダイナミックレンジが8ビット以内になり、動き補償モードが画像間予測モードの場合、ブロックのダイナミックレンジが9ビット以内になること)が多い。さらに、動き補償モードが画像間予測モードの場合、画像データのブロックは、演算器3で予測画像との差分がとられるので、その差分のブロックのダイナミックレンジが9ビットを越えることはほとんどない。   By the way, when an image having a bit accuracy higher than an 8-bit accuracy, for example, a 10-bit accuracy, is divided into small blocks such as 8 × 8 pixels and 16 × 16 pixels, the dynamic range in each block is generally Not large (when the motion compensation mode is the intra prediction mode, the block dynamic range is within 8 bits, and when the motion compensation mode is the inter picture prediction mode, the block dynamic range is within 9 bits). Many. Further, when the motion compensation mode is the inter-picture prediction mode, since the difference between the block of the image data and the predicted image is obtained by the computing unit 3, the dynamic range of the block of the difference hardly exceeds 9 bits.

従って、演算器4での画像データのブロックからの代表値データの減算処理により、ほとんどの場合、情報を損なうことなく、10ビット精度の画像データを8ビット精度の画像データに変換することができる。   Therefore, by subtracting the representative value data from the block of image data in the arithmetic unit 4, in most cases, 10-bit precision image data can be converted to 8-bit precision image data without loss of information. .

つまり、量子化幅計算回路6およびブロック量子化器7を設けずに装置を構成するようにしても、画像を損なうことなく、10ビット精度の画像データを8ビット精度の画像データに変換することができる。   That is, even if the apparatus is configured without providing the quantization width calculation circuit 6 and the block quantizer 7, the 10-bit precision image data can be converted into 8-bit precision image data without damaging the image. Can do.

また、画像データのブロックのダイナミックレンジが大きいとき(動き補償モードが画像内予測モードの場合、ブロックのダイナミックレンジが8ビットを越え、動き補償モードが画像間予測モードの場合、ブロックのダイナミックレンジが9ビットを越えるとき)、上述したように、ブロック量子化器7で画像データが量子化され、それが復号されたときの解像度が、多少劣化することになる。   When the dynamic range of the block of image data is large (when the motion compensation mode is the intra prediction mode, the block dynamic range exceeds 8 bits, and when the motion compensation mode is the inter prediction mode, the block dynamic range is As described above, when the image data is quantized by the block quantizer 7 and is decoded, the resolution is somewhat deteriorated.

しかしながら、例えば画像の輪郭部分などのダイナミックレンジが大きい部分では、人間の目の輝度弁別度が低いので、上述の量子化によるレベル方向の解像度の低下(劣化)が、視聴者に与える影響はほとんどないと考えられる。   However, for example, in a portion with a large dynamic range, such as a contour portion of an image, the luminance discrimination degree of the human eye is low. Therefore, the lowering (degradation) of the resolution in the level direction due to the above-mentioned quantization has little influence on the viewer. It is not considered.

10ビット精度から8ビット精度に変換された画像データは、差分信号符号化器8に供給される。そして、差分信号符号化器8において、DCT処理され、さらに量子化されてVLC回路15に供給される。   The image data converted from the 10-bit precision to the 8-bit precision is supplied to the differential signal encoder 8. Then, in the differential signal encoder 8, DCT processing is performed, and the signal is further quantized and supplied to the VLC circuit 15.

VLC回路15には、差分信号符号化器8でDCT処理され、さらに量子化された画像データのブロックの他、そのブロックの代表値データまたは量子化幅Qが代表値計算回路5または量子化幅計算回路6よりそれぞれ供給されるとともに、動きベクトルおよび動き補償モードが動き予測における回路により供給される。さらに、VLC回路15には、差分信号符号化器8での量子化幅Sが供給される。そして、VLC回路15は、ビット精度が10ビット精度から8ビット精度に変換された画像データのブロック、そのブロックの代表値データ、量子化幅Q,S、動きベクトル、および動き補償モードを可変長符号化し、図示せぬ送信バッファを介して出力する。   In the VLC circuit 15, the representative value data or the quantization width Q of the block other than the block of the image data subjected to DCT processing by the differential signal encoder 8 and further quantized is represented by the representative value calculation circuit 5 or the quantization width. The motion vector and motion compensation mode are supplied from the calculation circuit 6 and supplied from the motion prediction circuit. Further, the VLC circuit 15 is supplied with the quantization width S in the differential signal encoder 8. The VLC circuit 15 then changes the block of image data whose bit precision is converted from 10-bit precision to 8-bit precision, the representative value data of the block, the quantization width Q, S, the motion vector, and the motion compensation mode to a variable length. Encode and output via a transmission buffer (not shown).

ここで、この場合、VLC回路15では、符号化された画像データのブロックごとのヘッダに、そのブロックの代表値データまたは量子化幅Qが付加されるようになされている。   Here, in this case, the VLC circuit 15 adds the representative value data or the quantization width Q of the block to the header of each block of the encoded image data.

なお、ブロックの代表値データまたは量子化幅Qを、上述したようにそのブロックのヘッダに付加するのではなく、ブロックより上位のレイヤとしての、例えばマクロブロックレイヤやピクチャレイヤのヘッダに、そのマクロブロックやピクチャレイヤに属する他のブロックの代表値データおよび量子化幅Qとともに付加するようにすることができる。   Note that the representative value data or quantization width Q of a block is not added to the header of the block as described above, but the macro is added to the header of the macroblock layer or the picture layer as a higher layer than the block. It can be added together with representative value data and quantization width Q of other blocks belonging to the block or picture layer.

VLC回路15よりエンコーダ出力信号としてのビットストリームが出力される。   A bit stream as an encoder output signal is output from the VLC circuit 15.

また、差分信号符号化器8でDCT処理され、さらに量子化された画像データは、それがIまたはPピクチャのデータである場合、差分信号復号化器9に供給される。   Further, the image data that has been subjected to DCT processing and further quantized by the differential signal encoder 8 is supplied to the differential signal decoder 9 when it is I or P picture data.

差分信号復号化器9は、逆量子化器113および逆DCT回路114より構成され、そこでは、差分信号符号化器8からのデータ(量子化されたDCTデータ)が、差分信号符号化器8における量子化幅Sと同一の量子化幅で逆量子化され、さらに逆DCT処理される。   The differential signal decoder 9 includes an inverse quantizer 113 and an inverse DCT circuit 114, in which data from the differential signal encoder 8 (quantized DCT data) is converted into the differential signal encoder 8. Inverse quantization is performed with the same quantization width as the quantization width S in FIG.

差分信号復号化器9より出力された画像データは、ブロック逆量子化器10に入力され、そこで、量子化幅計算回路6より出力された、ブロック量子化器7における量子化幅Qと同一の量子化幅で逆量子化される。即ち、ブロック逆量子化器10において、差分信号復号化器9より出力された画像データに、ブロック量子化器7における量子化幅Qと同一の量子化幅が乗算され、演算器11に出力される。   The image data output from the differential signal decoder 9 is input to the block inverse quantizer 10, where it is the same as the quantization width Q in the block quantizer 7 output from the quantization width calculation circuit 6. Inverse quantization with quantization width. That is, in the block inverse quantizer 10, the image data output from the differential signal decoder 9 is multiplied by the same quantization width Q as the quantization width Q in the block quantizer 7 and output to the computing unit 11. The

加算器11においては、ブロック逆量子化器10より出力された画像データに、代表値計算回路5より出力された、減算器4において演算器3の演算出力から減算された代表値データと同一の代表値データが加算され、この加算データが加算器70および加算器72に供給される。   In the adder 11, the image data output from the block inverse quantizer 10 is the same as the representative value data output from the representative value calculation circuit 5 and subtracted from the calculation output of the calculator 3 in the subtractor 4. The representative value data is added, and the added data is supplied to the adder 70 and the adder 72.

これにより、減算器70、加算器72には、減算器4およびブロック量子化器7によって8ビット精度の画像データのブロックに変換される前の10ビット精度の画像データのブロックと同一(正確には、量子化誤差が含まれるので、ほぼ同一)の画像データのブロックが供給されることになる。   As a result, the subtracter 70 and the adder 72 are identical to the block of image data with 10-bit accuracy before being converted into the block of image data with 8-bit accuracy by the subtractor 4 and the block quantizer 7 (exactly). Since a quantization error is included, almost the same block of image data is supplied.

加算器11から出力される信号S2は減算器70および加算器72に出力される。減算器70では、演算器3からの信号S1および加算器11からの信号S2の差分S3を以下のような演算
S3=S1−S2
を行うことにより演算し、この差分信号S3を可変長符号化回路71および加算器72に出力する。
The signal S2 output from the adder 11 is output to the subtracter 70 and the adder 72. In the subtractor 70, the difference S3 between the signal S1 from the calculator 3 and the signal S2 from the adder 11 is calculated as follows: S3 = S1-S2
The difference signal S3 is output to the variable length coding circuit 71 and the adder 72.

可変長符号化回路71は減算器70からの差分信号S3を可変長符号化し、その出力ビットストリーム(補正ビットストリーム)を送信バッファ73を介して伝送データとして出力し、この伝送データが伝送路74を介して受信側に伝送されるか、もしくは記録媒体75に記録される。   The variable length coding circuit 71 performs variable length coding on the difference signal S3 from the subtractor 70, and outputs the output bit stream (correction bit stream) as transmission data via the transmission buffer 73. The transmission data is transmitted through the transmission path 74. Is transmitted to the receiving side through the recording medium or recorded on the recording medium 75.

加算器72は、演算器11からの信号S2および減算器70からの信号S3を加算して、この加算信号を加算器12に出力する。   The adder 72 adds the signal S2 from the computing unit 11 and the signal S3 from the subtractor 70, and outputs this addition signal to the adder 12.

上記の処理により、DCT処理、および10ビット画像信号を8ビット画像信号に変換する処理によって失われた情報を補正し、原信号S1と一致する信号が演算器12に入力される。   Through the above processing, information lost by the DCT processing and the processing of converting the 10-bit image signal into the 8-bit image signal is corrected, and a signal that matches the original signal S1 is input to the arithmetic unit 12.

加算器12には、また、既に復号され、動き補償回路14で動き補償された予測画像が供給され、そこでは、この予測画像と演算器11からの画像データが加算され、元の10ビット精度の画像データ(符号化される前の10ビット精度の画像データ)に復号される。この復号された10ビット精度の画像データは、フィールドメモリ群13に供給されて記憶される。   The adder 12 is also supplied with a predicted image that has already been decoded and motion-compensated by the motion compensation circuit 14, where the predicted image and the image data from the computing unit 11 are added to obtain the original 10-bit accuracy. Image data (image data with 10-bit accuracy before encoding). The decoded 10-bit precision image data is supplied to and stored in the field memory group 13.

フィールドメモリ群13は、10ビット精度の画像データを記憶することができるようになされている。フィールドメモリ群13に記憶された、既に復号された10ビットの画像データは、フィールドメモリコントローラ16により入力画像の同期信号に対応して生成されたタイミング制御信号に基づいて読み出される。そして、この読み出された画像信号は、動き補償回路14において、動き予測回路2からの動きベクトルに対応して動き補償され、演算器3および12に供給される。即ち、予測画像が演算器3および加算器12に供給される。   The field memory group 13 can store 10-bit precision image data. The already decoded 10-bit image data stored in the field memory group 13 is read based on the timing control signal generated by the field memory controller 16 corresponding to the synchronization signal of the input image. The read image signal is motion-compensated in the motion compensation circuit 14 corresponding to the motion vector from the motion prediction circuit 2 and supplied to the computing units 3 and 12. That is, the predicted image is supplied to the calculator 3 and the adder 12.

以上のように、10ビット精度の画像データを8ビット精度の画像データに変換するようにしたので、8ビット精度の画像データ用の動き予測回路2、差分信号符号化器8、および差分信号復号化器9などを使用した画像符号化装置によって、10ビット精度の画像を、その画質を劣化させることなく可逆符号化することができる。   As described above, since the 10-bit precision image data is converted to the 8-bit precision image data, the motion prediction circuit 2, the differential signal encoder 8, and the differential signal decoding for the 8-bit precision image data. An image encoding device using the encoder 9 or the like can losslessly encode a 10-bit precision image without degrading the image quality.

次に、図8は、本発明の第3の実施の形態の画像信号符号化装置に対応する画像信号復号装置の一例の構成を示すブロック図である。   Next, FIG. 8 is a block diagram showing a configuration of an example of an image signal decoding apparatus corresponding to the image signal encoding apparatus of the third embodiment of the present invention.

この図8に示す画像信号復号化装置は、図5に示す画像信号符号化装置で符号化された画像を復号することができるようになされている。   The image signal decoding apparatus shown in FIG. 8 can decode the image encoded by the image signal encoding apparatus shown in FIG.

図5の画像信号符号化装置により符号化され、伝送路74を介して伝送されたか、もしくは記録媒体75に記録されている符号化された画像データは、図示せぬ受信回路で受信されたり、再生装置で記録媒体より再生され、可変長復号化(逆VLC)回路21に供給される。逆VLC回路21は、符号化された画像データのビットストリームを可変長復号化し、画像データの、例えばブロックごとのヘッダに付加されたブロックの代表値データまたは量子化幅Qを加算器24またはブロック逆量子化器23に供給するとともに、動きベクトルおよび動き補償モードを動き補償回路27に供給する。また、逆VLC回路21は、復号された(可変長復号された)画像データのブロック及び量子化幅Sを差分信号復号化器22に供給する。   The encoded image data encoded by the image signal encoding device of FIG. 5 and transmitted via the transmission path 74 or recorded on the recording medium 75 is received by a receiving circuit (not shown), The data is reproduced from the recording medium by the reproduction device and supplied to the variable length decoding (inverse VLC) circuit 21. The inverse VLC circuit 21 performs variable length decoding on the bit stream of the encoded image data, and adds the representative value data or the quantization width Q of the image data added to the header of each block, for example, to the adder 24 or the block The motion vector and motion compensation mode are supplied to the motion compensation circuit 27 while being supplied to the inverse quantizer 23. Further, the inverse VLC circuit 21 supplies the differential signal decoder 22 with the block (quantized width S) of the decoded (variable length decoded) image data.

さらに、逆VLC回路21は、1枚(1画面)の画像に対応するデータの可変長復号化を終了するたびにタイミングパルスをメモリコントローラ28に出力する。メモリコントローラ28においては、このタイミングパルスに対応してタイミング制御信号がフィールドメモリ群26に供給されるようになされており、これにより、フィールドメモリ群26からの画像データの読み出しのタイミングが制御されるようになされている。   Further, the inverse VLC circuit 21 outputs a timing pulse to the memory controller 28 every time the variable length decoding of data corresponding to one image (one screen) is completed. In the memory controller 28, a timing control signal is supplied to the field memory group 26 in response to this timing pulse, whereby the timing of reading image data from the field memory group 26 is controlled. It is made like that.

差分信号復号化器22は、図5の差分信号復号化器9と同様に、逆量子化器121および逆DCT回路122より構成されている。逆量子化器121は、逆VLC回路21より供給された画像データを、同じく逆VLC回路21より供給された量子化幅Sに従って逆量子化し、逆DCT回路122に出力する。逆量子化器121より出力されたデータ(DCT係数)は、逆DCT回路122で、逆DCT処理される。   The differential signal decoder 22 includes an inverse quantizer 121 and an inverse DCT circuit 122, similarly to the differential signal decoder 9 of FIG. The inverse quantizer 121 inversely quantizes the image data supplied from the inverse VLC circuit 21 according to the quantization width S also supplied from the inverse VLC circuit 21, and outputs it to the inverse DCT circuit 122. The data (DCT coefficient) output from the inverse quantizer 121 is subjected to inverse DCT processing by the inverse DCT circuit 122.

ここで、差分信号復号化器22に入出力する画像データは、ビット精度が8ビット精度に変換されたものであるので、差分信号復号化器22では、図5における場合と同様にして、8ビット精度の画像データを逆量子化し、さらに逆DCT処理することができる。   Here, since the image data to be input / output to / from the differential signal decoder 22 has been converted into 8-bit precision, the differential signal decoder 22 uses the same as in FIG. Bit-quantized image data can be inversely quantized and further subjected to inverse DCT processing.

差分信号復号化器22より出力された画像データのブロックは、ブロック逆量子化器23に入力され、そこで、逆VLC回路21より出力された、ブロック量子化器7(図5)で量子化されたときの量子化幅Qと同一の量子化幅で逆量子化される。即ち、ブロック逆量子化器23において、差分信号復号化器22より出力された画像データに、ブロック量子化器7で量子化されたときの量子化幅Qと同一の量子化幅が乗算される。   The block of image data output from the differential signal decoder 22 is input to the block inverse quantizer 23, where it is quantized by the block quantizer 7 (FIG. 5) output from the inverse VLC circuit 21. Inverse quantization is performed with the same quantization width as the quantization width Q. That is, the block inverse quantizer 23 multiplies the image data output from the differential signal decoder 22 by the same quantization width as the quantization width Q when quantized by the block quantizer 7. .

これにより、画像データのブロックのダイナミックレンジが、図5の画像信号符号化装置で符号化される前と同一(ほぼ同一)の値に変換される。   As a result, the dynamic range of the block of image data is converted to the same (substantially the same) value as that before encoding by the image signal encoding device of FIG.

ブロック逆量子化器23で逆量子化された画像データのブロックは、加算器24に供給される。加算器24では、逆VLC回路21からの代表値データと、ブロック逆量子化器23からの画像データのブロック(ブロックにおける画素データそれぞれ)とが加算され、この加算データは加算器93を介して、演算器25に出力される。   The block of image data dequantized by the block dequantizer 23 is supplied to the adder 24. In the adder 24, the representative value data from the inverse VLC circuit 21 and the block of image data (each pixel data in the block) from the block inverse quantizer 23 are added, and this added data is passed through the adder 93. Are output to the arithmetic unit 25.

図5の画像信号符号化装置の可変長符号化回路71において可変長符号され、伝送路74から供給されたもしくは記録媒体75に記録された差分ビットストリームは、受信バッファ91に入力される。可変長復号回路92は受信バッファ91から差分ビットストリームを読み出し、そのビットストリームを可変長符号を復号する。可変長復号回路92は、図5の画像信号符号化装置における可変長符号化回路71と対をなし、その逆の操作を行なうものである。   The differential bit stream that is variable length encoded in the variable length encoding circuit 71 of the image signal encoding device of FIG. 5 and supplied from the transmission path 74 or recorded on the recording medium 75 is input to the reception buffer 91. The variable length decoding circuit 92 reads the differential bit stream from the reception buffer 91 and decodes the variable length code from the bit stream. The variable length decoding circuit 92 is paired with the variable length encoding circuit 71 in the image signal encoding device of FIG. 5 and performs the reverse operation.

可変長復号回路92の出力信号S3’は画像信号符号化装置におけるS3と一致する。加算器24からの出力信号S2’は画像信号符号化装置におけるS2と一致する。加算器93は、可変長復号回路92からの出力S3’および加算器24からの出力信号S2’を加算し、信号S1’として出力する。これは図1の画像信号符号化装置におけるS1に一致する。   The output signal S3 'of the variable length decoding circuit 92 coincides with S3 in the image signal encoding device. The output signal S2 'from the adder 24 matches S2 in the image signal encoding device. The adder 93 adds the output S3 'from the variable length decoding circuit 92 and the output signal S2' from the adder 24, and outputs the result as a signal S1 '. This coincides with S1 in the image signal encoding device of FIG.

加算器25には、また、既に復号されたIまたはPピクチャの画像データが動き補償回路27で動き補償された予測画像が供給され、そこでは、この予測画像と加算器24からの画像データが加算され、元の10ビット精度の画像データ(符号化される前の10ビット精度の画像データ)に復号される。この復号された10ビット精度の画像データは、フィールドメモリ群26に供給されて記憶される。   The adder 25 is also supplied with a predicted image in which image data of an already decoded I or P picture is motion compensated by the motion compensation circuit 27, where the predicted image and the image data from the adder 24 are received. Addition is performed and the original 10-bit precision image data (decoded 10-bit precision image data) is decoded. The decoded 10-bit precision image data is supplied to the field memory group 26 and stored therein.

フィールドメモリ群26は、10ビット精度の画像データを記憶することができるようになされており、演算器25からの復号された10ビット精度の画像データを記憶する。フィールドメモリ群26に記憶された、既に復号された10ビットの画像データのうちIまたはPピクチャの画像データは、フィールドメモリコントローラ28により入力画像の同期信号に対応して生成されたタイミング制御信号に基づいて読み出される。そして、この読み出された画像データは、動き補償回路14において、動き予測回路2からの動きベクトルに対応して動き補償され、演算器25に供給される。即ち、予測画像が演算器25に供給される。   The field memory group 26 can store 10-bit precision image data, and stores the decoded 10-bit precision image data from the computing unit 25. Of the already decoded 10-bit image data stored in the field memory group 26, the image data of the I or P picture is used as a timing control signal generated by the field memory controller 28 corresponding to the synchronization signal of the input image. Read based on. The read image data is motion-compensated in the motion compensation circuit 14 corresponding to the motion vector from the motion prediction circuit 2 and supplied to the calculator 25. That is, the predicted image is supplied to the calculator 25.

また、フィールドメモリ群26に記憶された画像データは、フィールドメモリコントローラ28からのタイミング制御信号に基づいて出力端子に出力される。そして、出力端子に出力された画像データは、例えばD/A変換処理などの所定の処理が施され、図示せぬディスプレイなどに供給されて表示される。   The image data stored in the field memory group 26 is output to the output terminal based on a timing control signal from the field memory controller 28. The image data output to the output terminal is subjected to predetermined processing such as D / A conversion processing, and is supplied to and displayed on a display (not shown).

以上のようにして、8ビット精度の画像データ用の差分信号復号化器22などを使用した画像復号化装置により、図5の画像符号化装置で符号化された、8ビット精度より高精度な10ビット精度の画像を復号することができ、その画像は原画像と完全に一致する。   As described above, the image decoding apparatus using the differential signal decoder 22 for image data with 8-bit accuracy and the like encoded by the image encoding apparatus in FIG. An image with 10-bit accuracy can be decoded, and the image completely matches the original image.

なお、図5に示す画像信号符号化装置及び図8に示す画像信号復号装置においては、ビット精度が10ビット精度の画像だけでなく、例えば9ビット精度や11ビット精度などの画像を符号化(復号化)するようにすることができる。   In the image signal encoding device shown in FIG. 5 and the image signal decoding device shown in FIG. 8, not only an image with a bit accuracy of 10 bits but also an image with an accuracy of 9 bits or 11 bits, for example ( Decryption).

次に、本発明の第4の実施の形態について、図9及び図10を参照しながら説明する。   Next, a fourth embodiment of the present invention will be described with reference to FIGS.

図9は、本発明の第4の実施の形態としての画像信号符号化装置を示すものである。   FIG. 9 shows an image signal encoding apparatus as a fourth embodiment of the present invention.

この図9に示す画像信号符号化装置においては、ビット精度が8ビット精度より高精度な、例えば10ビット精度の画像データが装置に入力されるものとして説明をする。本例では10ビット画像信号についての具体例を示すが、これは10ビット以上のビット精度の画像信号にも同様に適用できる。   The image signal encoding apparatus shown in FIG. 9 will be described on the assumption that image data having a bit accuracy higher than 8-bit accuracy, for example, 10-bit accuracy, is input to the apparatus. In this example, a specific example of a 10-bit image signal is shown, but this can be similarly applied to an image signal having a bit accuracy of 10 bits or more.

この図9に示す画像信号符号化装置は、前述した図5の画像信号符号化装置とほぼ同様な構成を有しており、図8の構成と異なる部分について説明し、他の部分の説明を省略する。   The image signal encoding device shown in FIG. 9 has substantially the same configuration as that of the image signal encoding device shown in FIG. 5 described above. Omitted.

図9のフィールドメモリ群1から読み出された10ビットの画像データは演算器3と共に、信号S1として減算器70に出力される。加算器70には、加算器12からの出力信号S2が供給されている。   The 10-bit image data read from the field memory group 1 in FIG. 9 is output to the subtracter 70 together with the calculator 3 as a signal S1. The adder 70 is supplied with the output signal S2 from the adder 12.

ここで加算器12には、演算器11からの出力信号S2が、前記図5のような加算器72を介すことなく直接供給されており、減算器4およびブロック量子化器7によって8ビット精度の画像データのブロックに変換される前の10ビット精度の画像データのブロックと同一(正確には、量子化誤差が含まれるので、ほぼ同一)の画像データのブロックが供給されることになる。また、加算器12には、既に復号され、動き補償回路14で動き補償された予測画像が供給され、そこでは、この予測画像と演算器11からの画像データが加算され、元の10ビット精度の画像データ(符号化される前の10ビット精度の画像データ)に復号される。   Here, the output signal S2 from the computing unit 11 is directly supplied to the adder 12 without going through the adder 72 as shown in FIG. 5, and the adder 12 receives 8 bits by the subtracter 4 and the block quantizer 7. A block of image data that is the same as the block of image data of 10-bit accuracy before being converted to a block of accurate image data (to be exact, almost the same because a quantization error is included) is supplied. . The adder 12 is supplied with a predicted image that has already been decoded and motion-compensated by the motion compensation circuit 14, where the predicted image and the image data from the computing unit 11 are added to obtain the original 10-bit accuracy. Image data (image data with 10-bit accuracy before encoding).

この復号された10ビット精度の画像データは、図9の例においては、減算器70および加算器72に供給される。   The decoded 10-bit precision image data is supplied to a subtracter 70 and an adder 72 in the example of FIG.

減算器70では、演算器3に入力された信号S1および加算器12からの信号S2の差分S3を、下記の演算を行うことにより計算する。
S3=S1−S2
そして、その差分データS3は、可変長符号化回路71および加算器72に出力される。
The subtractor 70 calculates the difference S3 between the signal S1 input to the calculator 3 and the signal S2 from the adder 12 by performing the following calculation.
S3 = S1-S2
The difference data S3 is output to the variable length encoding circuit 71 and the adder 72.

可変長符号化回路71は加算器70からの差分信号S3を可変長符号化し、その出力ビットストリーム(補正ビットストリーム)を送信バッファ73を介して出力する。   The variable length coding circuit 71 performs variable length coding on the difference signal S3 from the adder 70 and outputs the output bit stream (corrected bit stream) via the transmission buffer 73.

加算器72は、加算器12からの信号S2および減算器70からの信号S3を加算して加算器12に出力する。   The adder 72 adds the signal S2 from the adder 12 and the signal S3 from the subtractor 70 and outputs the result to the adder 12.

上記の処理により、DCT処理、および10ビット画像信号を8ビット画像信号に変換する処理によって失われた情報を補正することができ、その原信号と一致する信号S1が、フィールドメモリ群13に供給されて記憶される。   With the above processing, the information lost by the DCT processing and the processing for converting the 10-bit image signal into the 8-bit image signal can be corrected, and the signal S1 matching the original signal is supplied to the field memory group 13 And memorized.

フィールドメモリ群13は、10ビット精度の画像データを記憶することができるようになされている。フィールドメモリ群13に記憶された、既に復号された10ビットの画像データは、フィールドメモリコントローラ16により入力画像の同期信号に対応して生成されたタイミング制御信号に基づいて読み出される。そして、この読み出された画像データは、動き補償回路14において、動き予測回路2からの動きベクトルに対応して動き補償され、演算器3および12に供給される。即ち、予測画像が演算器3および12に供給される。   The field memory group 13 can store 10-bit precision image data. The already decoded 10-bit image data stored in the field memory group 13 is read based on the timing control signal generated by the field memory controller 16 corresponding to the synchronization signal of the input image. The read image data is motion-compensated in the motion compensation circuit 14 in accordance with the motion vector from the motion prediction circuit 2 and supplied to the calculators 3 and 12. That is, the predicted image is supplied to the calculators 3 and 12.

以上のように、10ビット精度の画像データを8ビット精度の画像データに変換するようにしたので、8ビット精度の画像データ用の動き予測回路2、差分信号符号化器8、および差分信号復号化器9などを使用した画像符号化装置によって、10ビット精度の画像を、その画質を劣化させることなく可逆符号化することができる。   As described above, since the 10-bit precision image data is converted to the 8-bit precision image data, the motion prediction circuit 2, the differential signal encoder 8, and the differential signal decoding for the 8-bit precision image data. An image encoding device using the encoder 9 or the like can losslessly encode a 10-bit precision image without degrading the image quality.

次に、図10は、本発明の第4の実施例の画像信号符号化装置に対応する画像信号復号装置の一例の構成を示すブロック図である。   Next, FIG. 10 is a block diagram showing a configuration of an example of an image signal decoding apparatus corresponding to the image signal encoding apparatus of the fourth embodiment of the present invention.

この図10中で、前記図8における各部と対応する部分については、同一の符号を付して、説明を省略する。この図10に示す画像信号復号装置は、図9に示す画像信号符号化装置で符号化された画像を復号することができるようになされている。   In FIG. 10, portions corresponding to the respective portions in FIG. 8 are given the same reference numerals and description thereof is omitted. The image signal decoding apparatus shown in FIG. 10 can decode an image encoded by the image signal encoding apparatus shown in FIG.

この図10に示す画像信号復号装置において、図8の構成と異なる点は、加算器93の挿入位置であり、加算器24からの出力が直接演算器25に送られ、この演算器25からの出力信号S2’が加算器93に送られてる。そして、加算器93は、逆VLC回路92からの差分信号S3’と演算器25からの出力信号S2‘を加算する。そして、この加算器93からの出力信号S1’は、フィールドメモリ群26に送られている。   In the image signal decoding apparatus shown in FIG. 10, the difference from the configuration of FIG. 8 is the insertion position of the adder 93, and the output from the adder 24 is sent directly to the calculator 25. The output signal S2 ′ is sent to the adder 93. The adder 93 adds the difference signal S3 ′ from the inverse VLC circuit 92 and the output signal S2 ′ from the calculator 25. The output signal S1 'from the adder 93 is sent to the field memory group 26.

すなわち、ブロック逆量子化器23で逆量子化された画像データのブロックは、加算器24に供給される。加算器24は、逆VLC回路21からの代表値データと、ブロック逆量子化器23からの画像データのブロック(ブロックにおける画素データそれぞれ)とが加算し、加算データを演算器25に出力する。   That is, the block of image data inversely quantized by the block inverse quantizer 23 is supplied to the adder 24. The adder 24 adds the representative value data from the inverse VLC circuit 21 and the block of image data from the block inverse quantizer 23 (each pixel data in the block), and outputs the addition data to the calculator 25.

演算器25には、また、既に復号されたIまたはPピクチャの画像データが動き補償回路27で動き補償された予測画像が供給され、そこでは、この予測画像と加算器24からの画像データが加算され、元の10ビット精度の画像データ(符号化される前の10ビット精度の画像データ)に復号される。この復号された10ビット精度の画像データは、加算器93に入力される。   The computing unit 25 is also supplied with a predicted image in which the image data of the already decoded I or P picture is motion compensated by the motion compensation circuit 27, where the predicted image and the image data from the adder 24 are received. Addition is performed and the original 10-bit precision image data (decoded 10-bit precision image data) is decoded. The decoded 10-bit precision image data is input to the adder 93.

上記図9の画像信号符号化装置の可変長符号化回路71において可変長符号され、伝走路74から供給されたもしくは記録媒体75に記録されている差分ビットストリームは、図10の受信バッファ91に入力される。可変長復号回路92は受信バッファ91から差分ビットストリームを読み出し、このビットストリームを可変長符号を復号する。可変長復号回路92は画像信号符号化装置における可変長符号化回路71と対をなし、その逆の操作を行なうものである。   The differential bit stream that is variable length encoded in the variable length encoding circuit 71 of the image signal encoding apparatus of FIG. 9 and supplied from the transmission path 74 or recorded on the recording medium 75 is stored in the reception buffer 91 of FIG. Entered. The variable length decoding circuit 92 reads the differential bit stream from the reception buffer 91 and decodes the variable length code from this bit stream. The variable length decoding circuit 92 is paired with the variable length coding circuit 71 in the image signal coding apparatus, and performs the reverse operation.

ここで、可変長復号回路92の出力信号S3’は、図9の符号化装置における信号S3と一致する。演算器24からの出力信号S2’は、図9の符号化装置における信号S2と一致する。加算器93は、可変長復号回路92の出力S3’および演算器24の出力信号S2’を加算し、信号S1’として出力する。これは、図9の符号化装置における信号S1に一致する。   Here, the output signal S3 'of the variable length decoding circuit 92 coincides with the signal S3 in the encoding device of FIG. The output signal S2 'from the arithmetic unit 24 coincides with the signal S2 in the encoding device of FIG. The adder 93 adds the output S3 'of the variable length decoding circuit 92 and the output signal S2' of the arithmetic unit 24, and outputs the result as a signal S1 '. This coincides with the signal S1 in the encoding device of FIG.

加算器93の出力信号は、フィールドメモリ群26に供給されて記憶される。フィールドメモリ群26は、10ビット精度の画像データを記憶することができるようになされており、演算器25からの復号された10ビット精度の画像データを記憶する。フィールドメモリ群26に記憶された、既に復号された10ビットの画像データのうちIまたはPピクチャの画像データは、フィールドメモリコントローラ28により入力画像の同期信号に対応して生成されたタイミング制御信号に基づいて読み出される。そしてこの読み出されてた画像データは、動き補償回路14において、動き予測回路2からの動きベクトルに対応して動き補償され、演算器25に供給される。即ち、予測画像が演算器25に供給される。   The output signal of the adder 93 is supplied to the field memory group 26 and stored. The field memory group 26 can store 10-bit precision image data, and stores the decoded 10-bit precision image data from the computing unit 25. Of the decoded 10-bit image data stored in the field memory group 26, the image data of the I or P picture is used as the timing control signal generated by the field memory controller 28 corresponding to the synchronization signal of the input image. Read based on. The read image data is motion compensated in the motion compensation circuit 14 in accordance with the motion vector from the motion prediction circuit 2 and supplied to the computing unit 25. That is, the predicted image is supplied to the calculator 25.

また、フィールドメモリ群26に記憶された画像データは、フィールドメモリコントローラ28からのタイミング制御信号に基づいて出力端子に出力される。そして、出力端子に出力された画像データは、例えばD/A変換処理などの所定の処理が施され、図示せぬディスプレイなどに供給されて表示される。   The image data stored in the field memory group 26 is output to the output terminal based on a timing control signal from the field memory controller 28. The image data output to the output terminal is subjected to predetermined processing such as D / A conversion processing, and is supplied to and displayed on a display (not shown).

以上のようにして、8ビット精度の画像データ用の差分信号復号器22などを使用した画像信号復号装置により、図9の画像信号符号化装置で符号化された、8ビット精度より高精度な10ビット精度の画像を復号することができ、その画像は原画像と完全に一致する。   As described above, the image signal decoding apparatus using the differential signal decoder 22 for image data with 8-bit accuracy and the like encoded with the image signal encoding apparatus in FIG. An image with 10-bit accuracy can be decoded, and the image completely matches the original image.

なお、図9に示す画像信号符号化装置及び図10に示す画像信号復号化装置においては、ビット精度が10ビット精度の画像だけでなく、例えば9ビット精度や11ビット精度などの画像を符号化及び復号化するようにすることができる。   Note that the image signal encoding device shown in FIG. 9 and the image signal decoding device shown in FIG. 10 encode not only images with a bit accuracy of 10 bits, but also images with, for example, 9 bits or 11 bits. And decryption.

なお、本発明は上述した実施の形態に限定されるものではなく、例えば、上記各実施の形態においては、DCT処理によって失われた情報を補正する信号を伝送することにより、可逆符号化を実現する画像信号符号化/復号化装置についての例を示しているが、DCT処理以外の劣化要素にも適用できる。また、例えば、実施の形態では量子化スケールは1にしているが、量子化スケールが1以外の場合にも同様に適用できる。この他、本発明の要旨を逸脱しない範囲で種々の変更が可能であることは勿論である。   Note that the present invention is not limited to the above-described embodiment. For example, in each of the above-described embodiments, lossless encoding is realized by transmitting a signal for correcting information lost by DCT processing. Although an example of an image signal encoding / decoding device to be performed is shown, the present invention can also be applied to degradation factors other than DCT processing. For example, although the quantization scale is set to 1 in the embodiment, the present invention can be similarly applied to cases where the quantization scale is other than 1. Of course, various modifications can be made without departing from the scope of the present invention.

本発明の上述したような実施の形態によれば、画像信号に実数演算を伴う符号化処理を施して得られた信号を量子化し、量子化された信号を出力する画像信号符号化方法において、符号化データの局所復号データと上記実数演算を行なう前のデータとを比較し、その差分を取り出しているため、この差分信号を復号データに加算し、信号を補正することにより、可逆符号化を実現することが可能となる。この可逆符号化が可能となることにより、高精度の画像信号の符号化/復号が実現できる。   According to the above-described embodiment of the present invention, in an image signal encoding method for quantizing a signal obtained by performing an encoding process with a real number operation on an image signal and outputting the quantized signal, Since the local decoded data of the encoded data is compared with the data before the real number operation is performed and the difference is extracted, the difference signal is added to the decoded data, and the signal is corrected to perform lossless encoding. It can be realized. By enabling this lossless encoding, it is possible to realize encoding / decoding of a highly accurate image signal.

また、所定のブロックごとに、画像データの代表値データおよび量子化幅を決定し、画像データと代表値データの差分を算出して、差分を量子化幅に基づいて量子化し、第1の量子化データを生成する。そして、第1の量子化データに所定の変換処理を施し、その変換係数を量子化して、第2の量子化データを生成し、代表値データ、量子化幅、および第2の量子化データを符号化する。従って、画像を、そのビット精度を変換して符号化し、また復号することができる。   Further, for each predetermined block, the representative value data and the quantization width of the image data are determined, the difference between the image data and the representative value data is calculated, the difference is quantized based on the quantization width, and the first quantum Generate data. Then, a predetermined conversion process is performed on the first quantized data, the conversion coefficient is quantized to generate second quantized data, and the representative value data, the quantized width, and the second quantized data are Encode. Therefore, an image can be encoded and decoded by converting its bit precision.

本発明の第1の実施の形態としての画像信号符号化装置の構成を示すブロック図である。It is a block diagram which shows the structure of the image signal encoding apparatus as the 1st Embodiment of this invention. 本発明の第1の実施の形態の画像信号符号化装置に対応する画像信号復号装置の構成を示すブロック図である。It is a block diagram which shows the structure of the image signal decoding apparatus corresponding to the image signal encoding apparatus of the 1st Embodiment of this invention. 本発明の第2の実施の形態としての画像信号符号化装置の構成を示すブロック図である。It is a block diagram which shows the structure of the image signal encoding apparatus as the 2nd Embodiment of this invention. 本発明の第2の実施の形態の画像信号符号化装置に対応する画像信号復号装置の構成を示すブロック図である。It is a block diagram which shows the structure of the image signal decoding apparatus corresponding to the image signal encoding apparatus of the 2nd Embodiment of this invention. 本発明の第3の実施の形態としての画像信号符号化装置の構成を示すブロック図である。It is a block diagram which shows the structure of the image signal encoding apparatus as the 3rd Embodiment of this invention. 画像データのブロックのダイナミックレンジの一例を示す図である。It is a figure which shows an example of the dynamic range of the block of image data. 画像データのブロックのダイナミックレンジの他の例を示す図である。It is a figure which shows the other example of the dynamic range of the block of image data. 本発明の第3の実施の形態としての画像信号復号装置の構成を示すブロック図である。It is a block diagram which shows the structure of the image signal decoding apparatus as the 3rd Embodiment of this invention. 本発明の第4の実施の形態としての画像信号符号化装置の構成を示すブロック図である。It is a block diagram which shows the structure of the image signal encoding apparatus as the 4th Embodiment of this invention. 本発明の第4の実施の形態の画像信号符号化装置に対応する画像信号復号装置の構成を示すブロック図である。It is a block diagram which shows the structure of the image signal decoding apparatus corresponding to the image signal encoding apparatus of the 4th Embodiment of this invention.

符号の説明Explanation of symbols

50 動きベクトル検出回路、 52 予測モード切り換え回路、 53 演算部、 55 DCTモード切り換え回路、 56 DCT回路、 57 量子化回路、 58,71 可変長符号化回路、 60,83 逆量子化回路、 61,84 IDCT回路、 70,72,93 加算器、 82,92 可変長復号回路
50 motion vector detection circuit, 52 prediction mode switching circuit, 53 operation unit, 55 DCT mode switching circuit, 56 DCT circuit, 57 quantization circuit, 58, 71 variable length coding circuit, 60, 83 inverse quantization circuit, 61, 84 IDCT circuit, 70, 72, 93 adder, 82, 92 variable length decoding circuit

Claims (20)

画像信号に実数演算を伴う符号化処理を施して得られた信号を出力する画像信号符号化方法において、
入力画像信号に対して実数演算を伴う符号化処理を行い、符号化データを生成する工程と、
上記符号化データを局所復号し局所復号でデータを生成する工程と、
上記局所復号データと上記実数演算を行なう前の画像データとを比較し、その差分を演算する工程とを有すること
を特徴とする画像信号符号化方法。
In an image signal encoding method for outputting a signal obtained by performing an encoding process with a real number operation on an image signal,
Performing an encoding process with a real number operation on the input image signal to generate encoded data;
A step of locally decoding the encoded data and generating data by local decoding;
An image signal encoding method comprising: a step of comparing the local decoded data with image data before the real number calculation and calculating a difference therebetween.
上記実数演算は、離散余弦変換処理であること
を特徴とする請求項1記載の画像信号符号化方法。
The image signal encoding method according to claim 1, wherein the real number calculation is a discrete cosine transform process.
上記局所復号データは、上記実数演算処理の直後のデータとすること
を特徴とする請求項1記載の画像信号符号化方法。
The image signal encoding method according to claim 1, wherein the local decoded data is data immediately after the real number calculation process.
上記符号化処理は、予測符号化した後に実数演算を施す処理であり、
上記局所復号データは、上記予測符号化の予測信号が加算された後の復号後のデータとすること
を特徴とする請求項1記載の画像信号符号化方法。
The encoding process is a process of performing a real number operation after predictive encoding,
The image signal encoding method according to claim 1, wherein the local decoded data is data after decoding after the prediction signal of the prediction encoding is added.
上記符号化処理は、入力画像データの所定ブロック毎に決定された代表値データと、元の入力画像データとの差分に対して、実数演算を施す処理であること
を特徴とする請求項1記載の画像信号符号化方法。
The encoding process is a process of performing a real number operation on a difference between representative value data determined for each predetermined block of input image data and original input image data. An image signal encoding method.
画像信号に実数演算を伴う符号化処理を施して得られた信号を出力する画像信号符号化装置において、
入力画像信号に対して実数演算を伴う符号化処理を行い、符号化データを生成する手段と、
上記符号化データを局所復号し局所復号でデータを生成する手段と、
上記局所復号データと上記実数演算を行なう前の画像データとを比較し、その差分を演算する手段とを有すること
を特徴とする画像信号符号化装置。
In an image signal encoding apparatus that outputs a signal obtained by performing an encoding process with a real number operation on an image signal,
Means for performing encoding processing with real number operation on the input image signal and generating encoded data;
Means for locally decoding the encoded data and generating data by local decoding;
An image signal encoding apparatus comprising: means for comparing the local decoded data and the image data before the real number calculation, and calculating a difference between them.
上記実数演算は、離散余弦変換処理であること
を特徴とする請求項6記載の画像信号符号化装置。
The image signal encoding apparatus according to claim 6, wherein the real number calculation is a discrete cosine transform process.
上記局所復号データは、上記実数演算処理の直後のデータとすること
を特徴とする請求項6記載の画像信号符号化装置。
The image signal encoding apparatus according to claim 6, wherein the local decoded data is data immediately after the real number calculation process.
上記符号化処理は、予測符号化した後に実数演算を施す処理であり、
上記局所復号データは、上記予測符号化の予測信号が加算された後の復号後のデータとすること
を特徴とする請求項6記載の画像信号符号化装置。
The encoding process is a process of performing a real number operation after predictive encoding,
The image signal encoding apparatus according to claim 6, wherein the local decoded data is data after decoding after the prediction signal of the prediction encoding is added.
上記符号化処理は、入力画像データの所定ブロック毎に決定された代表値データと、元の入力画像データとの差分に対して、実数演算を施す処理であること
を特徴とする請求項6記載の画像信号符号化装置。
The encoding process is a process of performing a real number operation on a difference between the representative value data determined for each predetermined block of the input image data and the original input image data. Image signal encoding apparatus.
画像信号に実数演算を伴う符号化処理を施して得られた信号を伝送する画像信号伝送方法において、
入力画像信号に対して実数演算を伴う符号化処理を行い、符号化データを生成する工程と、
上記符号化データを局所復号し局所復号でデータを生成する工程と、
上記局所復号データと上記実数演算を行なう前の画像データとを比較し、その差分を演算し、差分データを伝送する工程とを有すること
を特徴とする画像信号伝送方法。
In an image signal transmission method for transmitting a signal obtained by performing an encoding process with a real number operation on an image signal,
Performing an encoding process with a real number operation on the input image signal to generate encoded data;
A step of locally decoding the encoded data and generating data by local decoding;
A method of transmitting an image signal, comprising: comparing the local decoded data with image data before the real number calculation, calculating a difference thereof, and transmitting the difference data.
上記実数演算は、離散余弦変換処理であること
を特徴とする請求項11記載の画像信号伝送方法。
The image signal transmission method according to claim 11, wherein the real number calculation is discrete cosine transform processing.
上記局所復号データは、上記実数演算処理の直後のデータとすること
を特徴とする請求項11記載の画像信号伝送方法。
The image signal transmission method according to claim 11, wherein the local decoded data is data immediately after the real number calculation process.
上記符号化処理は、予測符号化した後に実数演算を施す処理であり、
上記局所復号データは、上記予測符号化の予測信号が加算された後の復号後のデータとすること
を特徴とする請求項11記載の画像信号伝送方法。
The encoding process is a process of performing a real number operation after predictive encoding,
12. The image signal transmission method according to claim 11, wherein the local decoded data is decoded data after the prediction signal of the predictive encoding is added.
上記符号化処理は、入力画像データの所定ブロック毎に決定された代表値データと、元の入力画像データとの差分に対して、実数演算を施す処理であること
を特徴とする請求項11記載の画像信号伝送方法。
The encoding process is a process of performing a real number operation on a difference between representative value data determined for each predetermined block of input image data and original input image data. Image signal transmission method.
復号装置によって復号可能な記録媒体において、
上記記録媒体は上記復号装置によって復号可能な記録信号が記録され、該記録信号は、
入力画像信号に対して実数演算を伴う符号化処理を行い符号化データを生成する工程と、
上記符号化データを局所復号し局所復号でデータを生成する工程と、
上記局所復号データと上記実数演算を行なう前のデータとを比較してその差分を演算して差分データを生成する工程と
により得られた符号化データと差分データとを含んで成ること
を特徴とする画像信号記録媒体。
In a recording medium decodable by a decoding device,
The recording medium records a recording signal that can be decoded by the decoding device.
A process of performing an encoding process with a real number operation on the input image signal to generate encoded data;
A step of locally decoding the encoded data and generating data by local decoding;
A step of comparing the local decoded data with the data before the real number calculation and calculating the difference to generate difference data, and including the encoded data and the difference data obtained by Image signal recording medium.
画像信号に実数演算を伴う符号化処理を施して得られた符号化データと、上記符号化データの局所復号データと上記実数演算を行なう前の画像データとの差分演算によって得られた差分データ信号とが供給され、上記符号化データと上記差分データとから元の画像データを復号する画像信号復号方法において、
上記符号化データを上記符号化処理に対応する復号処理に従って復号し、復号データを生成する工程と、
上記差分データと上記復号データを加算する工程とを有すること
を特徴とする画像信号復号方法。
A differential data signal obtained by performing a differential operation between encoded data obtained by performing an encoding process with a real number operation on an image signal, and local decoded data of the encoded data and the image data before the real number operation is performed. In an image signal decoding method for decoding original image data from the encoded data and the difference data,
Decoding the encoded data according to a decoding process corresponding to the encoding process to generate decoded data;
An image signal decoding method comprising: adding the difference data and the decoded data.
上記復号処理は、少なくとも逆離散余弦変換処理を含んでいること
を特徴とする請求項17記載の画像信号復号方法。
The image signal decoding method according to claim 17, wherein the decoding process includes at least an inverse discrete cosine transform process.
画像信号に実数演算を伴う符号化処理を施して得られた符号化データと、上記符号化データの局所復号データと上記実数演算を行なう前の画像データとの差分演算によって得られた差分データ信号とが供給され、上記符号化データと上記差分データとから元の画像データを復号する画像信号復号装置において、
上記符号化データを上記符号化処理に対応する復号処理に従って復号し、復号データを生成する手段と、
上記差分データと上記復号データを加算する手段とを有すること
を特徴とする画像信号復号装置。
A differential data signal obtained by performing a differential operation between encoded data obtained by performing an encoding process with a real number operation on an image signal, and local decoded data of the encoded data and the image data before the real number operation is performed. In the image signal decoding apparatus for decoding the original image data from the encoded data and the difference data,
Means for decoding the encoded data according to a decoding process corresponding to the encoding process, and generating decoded data;
An image signal decoding apparatus comprising: means for adding the difference data and the decoded data.
上記復号処理は、少なくとも逆離散余弦変換処理を含んでいること
を特徴とする請求項19記載の画像信号復号装置。

The image signal decoding apparatus according to claim 19, wherein the decoding process includes at least an inverse discrete cosine transform process.

JP2004338022A 1995-12-28 2004-11-22 Image signal coding method and device, image signal transmission method and decoding method and device Abandoned JP2005117680A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004338022A JP2005117680A (en) 1995-12-28 2004-11-22 Image signal coding method and device, image signal transmission method and decoding method and device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP34414695 1995-12-28
JP2004338022A JP2005117680A (en) 1995-12-28 2004-11-22 Image signal coding method and device, image signal transmission method and decoding method and device

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP35172096A Division JPH09238345A (en) 1995-12-28 1996-12-27 Image signal coding method and device therefor, image signal transmission method, image signal decoding method, device therefor and recording medium

Publications (1)

Publication Number Publication Date
JP2005117680A true JP2005117680A (en) 2005-04-28

Family

ID=34553908

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004338022A Abandoned JP2005117680A (en) 1995-12-28 2004-11-22 Image signal coding method and device, image signal transmission method and decoding method and device

Country Status (1)

Country Link
JP (1) JP2005117680A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8929439B2 (en) 2008-07-30 2015-01-06 Hitachi Maxwell, Ltd. Compressed image noise removal device and reproduction device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8929439B2 (en) 2008-07-30 2015-01-06 Hitachi Maxwell, Ltd. Compressed image noise removal device and reproduction device

Similar Documents

Publication Publication Date Title
CA2108704C (en) Picture signal encoding method and apparatus and picture signal decoding method and apparatus
JP3593988B2 (en) Moving picture signal compression apparatus and method
US6415055B1 (en) Moving image encoding method and apparatus, and moving image decoding method and apparatus
JPH08256341A (en) Image signal coding method, image signal coder, image signal recording medium and image signal decoder
JPH0851626A (en) Method and device for quantizing transformation coefficient of moving picture signal and moving picture signal compression device
US6256349B1 (en) Picture signal encoding method and apparatus, picture signal transmitting method, picture signal decoding method and apparatus and recording medium
JP3911035B2 (en) Moving picture coding method and moving picture coding apparatus
US5991445A (en) Image processing apparatus
JP3980659B2 (en) Video encoding method and apparatus, video decoding method and apparatus.
JPH10322696A (en) Signal encoder, signal encoding method, signal recording medium and signal transmitting method
JPH07143494A (en) Coding method for moving image
JP3599942B2 (en) Moving picture coding method and moving picture coding apparatus
JP3689437B2 (en) Image signal encoding method and apparatus
JPH07231449A (en) Encoder and decoder for picture signal
JPH09238345A (en) Image signal coding method and device therefor, image signal transmission method, image signal decoding method, device therefor and recording medium
JP2005117680A (en) Image signal coding method and device, image signal transmission method and decoding method and device
JPH07131793A (en) Video signal high efficiency coding device
JPH06209469A (en) Picture coder, picture coding method, picture decoder, picture decoding method and picture recording medium
JP3240737B2 (en) Image signal encoding method and apparatus, decoding method and apparatus
JPH0795536A (en) Device and method for reversely reproducing moving image
KR100210124B1 (en) Data deformatting circuit of picture encoder
JP3689626B2 (en) Image signal decoding method and apparatus
JP3862479B2 (en) How to prevent drift errors in video downconversion
JP4596277B2 (en) Encoding device, encoding method, decoding device, and decoding method
KR100255793B1 (en) Combine circuit of compensating for p-picture and b-picture in a motion compensator

Legal Events

Date Code Title Description
A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20060704

A762 Written abandonment of application

Free format text: JAPANESE INTERMEDIATE CODE: A762

Effective date: 20060904