JP2013042304A - Image decoding apparatus, image decoding method and image decoding program - Google Patents

Image decoding apparatus, image decoding method and image decoding program Download PDF

Info

Publication number
JP2013042304A
JP2013042304A JP2011177180A JP2011177180A JP2013042304A JP 2013042304 A JP2013042304 A JP 2013042304A JP 2011177180 A JP2011177180 A JP 2011177180A JP 2011177180 A JP2011177180 A JP 2011177180A JP 2013042304 A JP2013042304 A JP 2013042304A
Authority
JP
Japan
Prior art keywords
prediction
vector
motion
information
block
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
JP2011177180A
Other languages
Japanese (ja)
Inventor
Hideki Takehara
英樹 竹原
Motoharu Ueda
基晴 上田
Katsuyoshi Nishitani
勝義 西谷
Hiroya Nakamura
博哉 中村
Shigeru Fukushima
茂 福島
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.)
JVCKenwood Corp
Original Assignee
JVCKenwood 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 JVCKenwood Corp filed Critical JVCKenwood Corp
Priority to JP2011177180A priority Critical patent/JP2013042304A/en
Publication of JP2013042304A publication Critical patent/JP2013042304A/en
Withdrawn legal-status Critical Current

Links

Images

Abstract

PROBLEM TO BE SOLVED: To improve encoding efficiency of motion information including a motion vector while suppressing an increases in encoding time.SOLUTION: A code string analysis section 201 acquires, from an encoded stream, information for specifying a reference image for use in motion compensation of a block to be decoded. A prediction vector candidate generation section generates a prediction vector candidate for a motion vector of the block to be decoded. A reference vector decision section decides a reference motion vector from motion vectors of decoded blocks adjacent to the block to be decoded. A reference image information setting section sets information for specifying a reference image for scaling. A scaling section scales the reference motion vector on the basis of the information for specifying the reference image for scaling. The reference image information setting section decides the reference image for scaling independently of the reference image for use in motion compensation of the block to be decoded.

Description

本発明は、動き補償予測を用いた動画像符号化技術に関し、特に動き補償予測で利用する動き情報を符号化する画像復号装置、画像復号方法および画像復号プログラムに関する。   The present invention relates to a moving image encoding technique using motion compensated prediction, and more particularly to an image decoding apparatus, an image decoding method, and an image decoding program for encoding motion information used in motion compensated prediction.

一般的な動画像圧縮符号化では動き補償予測が利用される。動き補償予測は、対象画像を細かいブロックに分割し、復号済みの画像を参照画像として、動きベクトルで示される動き量に基づいて、対象画像の対象ブロックから参照画像の参照ブロックに移動した位置の信号を予測信号として生成する技術である。動き補償予測には1本の動きベクトルを利用して単予測に行うものと、2本の動きベクトルを利用して双予測に行うものがある。   In general video compression coding, motion compensation prediction is used. The motion compensated prediction divides the target image into fine blocks, uses the decoded image as a reference image, and based on the amount of motion indicated by the motion vector, the position of the position moved from the target block of the target image to the reference block of the reference image This is a technique for generating a signal as a prediction signal. There are two types of motion compensated prediction, one for single prediction using one motion vector and the other for bi-prediction using two motion vectors.

また、動きベクトルについても、処理対象ブロックに隣接する符号化済みのブロックの動きベクトルを予測動きベクトル(単に「予測ベクトル」ともいう)とし、処理対象ブロックの動きベクトルと予測ベクトルとの差分を求め、差分ベクトルを符号化ベクトルとして伝送することで圧縮効率を向上させている。   As for the motion vector, the motion vector of the encoded block adjacent to the processing target block is used as a prediction motion vector (also simply referred to as “prediction vector”), and the difference between the motion vector of the processing target block and the prediction vector is obtained. The compression efficiency is improved by transmitting the difference vector as an encoded vector.

MPEG−4AVCでは、MPEG−2よりも動き補償予測のブロックサイズを細かく且つ多様にすることで動き補償予測の効率を向上させている。一方、ブロックサイズを細かくしたことで動きベクトル数が増加するため、符号化ベクトルの符号量が問題となる。   MPEG-4AVC improves the efficiency of motion compensation prediction by making the block size of motion compensation prediction finer and more diversified than MPEG-2. On the other hand, since the number of motion vectors increases by making the block size finer, the code amount of the encoded vector becomes a problem.

そのため、MPEG−2では単純に処理対象ブロックの左隣のブロックの動きベクトルを予測ベクトルとしていた(例えば、非特許文献1参照)が、MPEG−4AVCでは複数の隣接ブロックの動きベクトルの中央値を予測ベクトルとすることで予測ベクトルの精度を向上させ、符号化ベクトルの符号量の増加を抑制している(例えば、非特許文献2参照)。   Therefore, in MPEG-2, the motion vector of the block adjacent to the left of the block to be processed is simply used as a prediction vector (see, for example, Non-Patent Document 1), but in MPEG-4 AVC, the median of the motion vectors of a plurality of adjacent blocks is used. By using the prediction vector, the accuracy of the prediction vector is improved, and an increase in the code amount of the encoded vector is suppressed (for example, see Non-Patent Document 2).

ISO/IEC 13818-2 Information technology -- Generic coding of moving pictures and associated audio information: VideoISO / IEC 13818-2 Information technology-Generic coding of moving pictures and associated audio information: Video ISO/IEC 14496-10 Information technology -- Coding of audio-visual objects -- Part 10: Advanced Video CodingISO / IEC 14496-10 Information technology-Coding of audio-visual objects-Part 10: Advanced Video Coding

非特許文献1および2のいずれに記載された方法においても、予測ベクトルは一つしか得られないため、予測精度が十分でなく、符号化効率が十分に向上しない場合がある。本発明者らは参照画像を用いて生成した予測ベクトルの候補を含む予測ベクトルの候補を複数用いて符号化効率を向上させる方法を取ることを考えた。その場合、参照画像を識別するためのインデックスを復号することが必要になり、予測ベクトルの候補を生成する時間が遅延するという課題があることを認識するに至った。   In any of the methods described in Non-Patent Documents 1 and 2, since only one prediction vector is obtained, the prediction accuracy is not sufficient and the encoding efficiency may not be sufficiently improved. The present inventors considered taking a method of improving the coding efficiency by using a plurality of prediction vector candidates including a prediction vector candidate generated using a reference image. In that case, it is necessary to decode an index for identifying a reference image, and it has been recognized that there is a problem that the time for generating prediction vector candidates is delayed.

本発明はこうした状況に鑑みてなされたものであり、その目的は、予測ベクトルの候補の生成に要する遅延時間を抑制しつつ、動きベクトルの予測精度を向上させることのできる動画像復号技術を提供することにある。   The present invention has been made in view of such circumstances, and an object of the present invention is to provide a video decoding technique capable of improving the accuracy of motion vector prediction while suppressing the delay time required to generate prediction vector candidates. There is to do.

上記課題を解決するために、本発明のある態様の画像復号装置は、動き補償予測を行う画像復号装置であって、復号対象ブロックの動き補償で使用する参照画像を特定するための情報を符号化ストリームから取得する符号列解析部(201)と、前記復号対象ブロックの動きベクトルの予測ベクトル候補を生成するための予測ベクトル候補生成部(151、152)と、を備える。前記予測ベクトル候補生成部(151、152)は、前記復号対象ブロックに隣接する復号済みのブロックの動きベクトルの中から基準動きベクトルを決定する基準ベクトル決定部(170、175)と、スケーリング用の参照画像を特定するための情報を設定する参照画像情報設定部(171、176)と、前記スケーリング用の参照画像を特定するための情報に基づいて前記基準動きベクトルをスケーリングするスケーリング部(172、177)と、を含む。前記参照画像情報設定部(171、176)は、前記スケーリング用の参照画像を、前記復号対象ブロックの動き補償で使用する参照画像に依存せずに決定する。「前記復号対象ブロックに隣接する符号化済みのブロック」は、前記符号化対象ブロックに空間的に隣接するブロックでもよいし、時間的に隣接するブロックでもよい。   In order to solve the above-described problem, an image decoding apparatus according to an aspect of the present invention is an image decoding apparatus that performs motion compensation prediction, and encodes information for specifying a reference image used in motion compensation of a decoding target block. A code string analysis unit (201) that is obtained from the stream, and a prediction vector candidate generation unit (151 and 152) for generating a prediction vector candidate of the motion vector of the decoding target block. The prediction vector candidate generation unit (151 and 152) includes a reference vector determination unit (170 and 175) that determines a reference motion vector from among motion vectors of decoded blocks adjacent to the decoding target block, and a scaling Reference image information setting units (171 and 176) for setting information for specifying a reference image, and scaling units (172, 172) for scaling the reference motion vector based on information for specifying the scaling reference image 177). The reference image information setting unit (171, 176) determines the scaling reference image without depending on the reference image used for motion compensation of the decoding target block. The “encoded block adjacent to the decoding target block” may be a block spatially adjacent to the encoding target block or a temporally adjacent block.

前記参照画像情報設定部(171、176)は、前記スケーリング用の参照画像を、前記復号対象ブロックに隣接する復号済みのブロックの動き補償に使用された参照画像をもとに決定してもよい。   The reference image information setting unit (171 or 176) may determine the scaling reference image based on a reference image used for motion compensation of a decoded block adjacent to the decoding target block. .

本発明の別の態様もまた、画像復号装置である。この装置は、動き補償予測を行う画像復号装置であって、復号対象ブロックに隣接する複数のブロックから動きベクトルを含むブロックを選択して予測ベクトル候補リストを生成する予測ベクトル候補リスト生成部(220)と、前記復号対象ブロックに隣接する複数のブロックから少なくとも参照画像情報と動きベクトルを含む動き情報を含むブロックを選択して結合動き情報候補リストを生成する結合動き情報候補リスト生成部(230)と、前記予測ベクトル候補リストを利用する第1予測モードと前記結合動き情報候補リストを利用する第2予測モードのどちらの予測モードを利用するかを選択する予測モード選択部(210)と、符号化ストリームから予測モードを特定するための情報を取得し、前記予測モードが第1予測モードの場合には、前記符号化ストリームから前記予測ベクトル候補リスト内における予測ベクトルの位置を示す予測ベクトルを特定するための情報、差分ベクトル、および前記復号対象ブロックの参照画像を特定するための情報を取得し、前記予測モードが第2予測モードの場合には、前記符号化ストリームから前記結合動き情報候補リスト内における動き情報の位置を示す動き情報を特定するための情報を取得する符号列解析部(201)と、前記予測ベクトルを特定するための情報をもとに、前記予測ベクトル候補リストに含まれる予測ベクトル候補の中から前記復号対象ブロックの予測ベクトルを選択する予測ベクトル選択部(221)と、前記予測ベクトルと前記差分ベクトルを加算して前記復号対象ブロックの動きベクトルを再生する動きベクトル再生部(222)と、前記動き情報を特定するための情報をもとに、前記結合動き情報候補リストに含まれる動き情報候補の中から前記復号対象ブロックの動き情報を選択する結合動き情報選択部(231)と、前記予測モードが第1予測モードの場合には前記参照画像を特定するための情報によって特定される参照画像と前記再生された動きベクトルを用いて予測信号を生成し、前記予測モードが第2予測モードである場合には前記選択された動き情報に含まれる参照画像情報で特定される参照画像と前記選択された動き情報に含まれる動きベクトルを用いて予測信号を生成する動き補償部(205)と、復号対象ブロックに隣接する復号済みのブロックであって、前記復号対象ブロックを含む画像と時間的に異なる画像に含まれるブロックの動きベクトルをスケーリングするスケーリング部(172)と、を備える。前記スケーリング部(172)によりスケーリングされた動きベクトルは、前記第1予測モードおよび前記第2予測モードで共用される。   Another aspect of the present invention is also an image decoding device. This apparatus is an image decoding apparatus that performs motion compensation prediction, and selects a block including a motion vector from a plurality of blocks adjacent to a decoding target block to generate a prediction vector candidate list generation unit (220). And a combined motion information candidate list generation unit (230) that generates a combined motion information candidate list by selecting a block including motion information including at least reference image information and a motion vector from a plurality of blocks adjacent to the decoding target block. A prediction mode selection unit (210) that selects which one of the first prediction mode using the prediction vector candidate list and the second prediction mode using the combined motion information candidate list is used; Information for specifying the prediction mode from the stream, and the prediction mode is the first prediction mode In this case, information for specifying a prediction vector indicating a position of a prediction vector in the prediction vector candidate list, a difference vector, and information for specifying a reference image of the decoding target block are acquired from the encoded stream. When the prediction mode is the second prediction mode, a code string analysis unit that acquires information for specifying motion information indicating the position of motion information in the combined motion information candidate list from the encoded stream ( 201), and a prediction vector selection unit (221) that selects a prediction vector of the decoding target block from prediction vector candidates included in the prediction vector candidate list based on information for specifying the prediction vector; , Adding the prediction vector and the difference vector to reproduce the motion vector of the decoding target block Combined motion for selecting motion information of the decoding target block from motion information candidates included in the combined motion information candidate list based on information for specifying the motion information When the prediction mode is the first prediction mode, the information selection unit (231) generates a prediction signal using the reference image specified by the information for specifying the reference image and the reproduced motion vector. When the prediction mode is the second prediction mode, a prediction signal is generated using a reference image specified by reference image information included in the selected motion information and a motion vector included in the selected motion information. The generated motion compensation unit (205) and a decoded block adjacent to the decoding target block, which are included in images temporally different from the image including the decoding target block And a scaling unit (172) for scaling the motion vector of the block to be processed. The motion vector scaled by the scaling unit (172) is shared by the first prediction mode and the second prediction mode.

本発明のさらに別の態様もまた、画像復号装置である。この装置は、動き補償予測を行う画像復号装置であって、符号化ストリームから予測ベクトルを特定するための情報を取得する符号列解析部(201)と、復号対象ブロックに隣接する複数のブロックを第1の順序で検査して、動きベクトルを含むブロックの動きベクトルを空間予測ベクトル候補とする空間予測ベクトル候補生成部(150)と、前記復号対象ブロックに隣接する複数のブロックを第2の順序で検査して、動きベクトルを含むブロックの動きベクトルをスケーリングしたスケーリング動きベクトルを空間スケーリング予測ベクトル候補とする空間スケーリング予測ベクトル候補生成部(152)と、少なくとも前記空間予測ベクトル候補と前記空間スケーリング予測ベクトル候補を含む候補リストを生成する候補リスト生成部(220)と、前記符号化ストリームから取得された予測ベクトルを特定するための情報をもとに、前記候補リストに含まれる予測ベクトル候補の中から前記復号対象ブロックの予測ベクトルを選択する予測ベクトル選択部(221)と、を備える。   Yet another embodiment of the present invention is also an image decoding device. This apparatus is an image decoding apparatus that performs motion compensation prediction, and includes a code string analysis unit (201) that acquires information for specifying a prediction vector from an encoded stream, and a plurality of blocks adjacent to a decoding target block. A spatial prediction vector candidate generation unit (150) that checks a motion vector of a block including a motion vector as a spatial prediction vector candidate by checking in the first order, and a plurality of blocks adjacent to the decoding target block in a second order A spatial scaling prediction vector candidate generation unit (152) that uses a scaling motion vector obtained by scaling the motion vector of the block including the motion vector as a spatial scaling prediction vector candidate, and at least the spatial prediction vector candidate and the spatial scaling prediction Candidate list generation to generate a candidate list containing vector candidates (220) and a prediction vector for selecting a prediction vector of the decoding target block from prediction vector candidates included in the candidate list based on information for specifying the prediction vector acquired from the encoded stream And a selection unit (221).

本発明のさらに別の態様もまた、画像復号装置である。この装置は、動き補償予測を行う画像復号装置であって、復号対象ブロックに隣接する複数のブロックから動きベクトルを含むブロックを選択して候補リストを生成する候補リスト生成部(220)と、符号化ストリームから前記候補リスト内における予測ベクトルの位置を示す予測ベクトルを特定するための情報、差分ベクトル、および前記復号対象ブロックの参照画像を特定するための情報を取得する符号列解析部(201)と、前記予測ベクトルを特定するための情報をもとに、前記候補リストに含まれる予測ベクトル候補の中から前記復号対象ブロックの予測ベクトルを選択する予測ベクトル選択部(221)と、前記予測ベクトルと前記差分ベクトルを加算して前記復号対象ブロックの動きベクトルを算出する動きベクトル再生部(222)と、を備える。前記予測ベクトルを特定するための情報が所定値である場合、前記参照画像を特定するための情報が省略されている。   Yet another embodiment of the present invention is also an image decoding device. This apparatus is an image decoding apparatus that performs motion compensation prediction, a candidate list generation unit (220) that generates a candidate list by selecting a block including a motion vector from a plurality of blocks adjacent to a decoding target block, A code string analysis unit (201) for acquiring information for specifying a prediction vector indicating a position of a prediction vector in the candidate list, a difference vector, and information for specifying a reference image of the decoding target block from a stream A prediction vector selection unit (221) that selects a prediction vector of the decoding target block from prediction vector candidates included in the candidate list based on information for specifying the prediction vector; and the prediction vector And the difference vector to calculate a motion vector of the decoding target block Includes a 222), the. When the information for specifying the prediction vector is a predetermined value, the information for specifying the reference image is omitted.

本発明のさらに別の態様は、画像復号方法である。この方法は、動き補償予測を行う画像復号方法であって、復号対象ブロックの動き補償で使用する参照画像を特定するための情報を符号化ストリームから取得するステップと、前記復号対象ブロックの動きベクトルの予測ベクトル候補を生成するステップと、を備える。前記予測ベクトル候補を生成するステップは、前記復号対象ブロックに隣接する復号済みのブロックの動きベクトルの中から基準動きベクトルを決定するステップと、スケーリング用の参照画像を特定するための情報を設定するステップと、前記スケーリング用の参照画像を特定するための情報に基づいて前記基準動きベクトルをスケーリングするステップと、を含む。前記スケーリング用の参照画像を特定するための情報を設定するステップは、前記スケーリング用の参照画像を、前記復号対象ブロックの動き補償で使用する参照画像に依存せずに決定する。   Yet another aspect of the present invention is an image decoding method. This method is an image decoding method for performing motion compensation prediction, the step of obtaining information for specifying a reference image used for motion compensation of a decoding target block from an encoded stream, and a motion vector of the decoding target block Generating a predicted vector candidate. The step of generating the prediction vector candidate sets a step of determining a reference motion vector from motion vectors of decoded blocks adjacent to the decoding target block, and information for specifying a reference image for scaling And scaling the reference motion vector based on information for identifying the reference image for scaling. In the step of setting information for specifying the reference image for scaling, the reference image for scaling is determined without depending on the reference image used for motion compensation of the decoding target block.

本発明のさらに別の態様もまた、画像復号方法である。この方法は、動き補償予測を行う画像復号方法であって、復号対象ブロックに隣接する複数のブロックから動きベクトルを含むブロックを選択して予測ベクトル候補リストを生成するステップと、前記復号対象ブロックに隣接する複数のブロックから少なくとも参照画像情報と動きベクトルを含む動き情報を含むブロックを選択して結合動き情報候補リストを生成するステップと、前記予測ベクトル候補リストを利用する第1予測モードと前記結合動き情報候補リストを利用する第2予測モードのどちらの予測モードを利用するかを選択するステップと、符号化ストリームから予測モードを特定するための情報を取得し、前記予測モードが第1予測モードの場合には、前記符号化ストリームから前記予測ベクトル候補リスト内における予測ベクトルの位置を示す予測ベクトルを特定するための情報、差分ベクトル、および前記復号対象ブロックの参照画像を特定するための情報を取得し、前記予測モードが第2予測モードの場合には、前記符号化ストリームから前記結合動き情報候補リスト内における動き情報の位置を示す動き情報を特定するための情報を取得するステップと、前記予測ベクトルを特定するための情報をもとに、前記予測ベクトル候補リストに含まれる予測ベクトル候補の中から前記復号対象ブロックの予測ベクトルを選択するステップと、前記予測ベクトルと前記差分ベクトルを加算して前記復号対象ブロックの動きベクトルを再生するステップと、前記動き情報を特定するための情報をもとに、前記結合動き情報候補リストに含まれる動き情報候補の中から前記復号対象ブロックの動き情報を選択するステップと、前記予測モードが第1予測モードの場合には前記参照画像を特定するための情報によって特定される参照画像と前記再生された動きベクトルを用いて予測信号を生成し、前記予測モードが第2予測モードである場合には前記選択された動き情報に含まれる参照画像情報で特定される参照画像と前記選択された動き情報に含まれる動きベクトルを用いて予測信号を生成するステップと、復号対象ブロックに隣接する復号済みのブロックであって、前記復号対象ブロックを含む画像と時間的に異なる画像に含まれるブロックの動きベクトルをスケーリングするステップと、を備える。スケーリングされた動きベクトルは、前記第1予測モードおよび前記第2予測モードで共用される。   Yet another embodiment of the present invention is also an image decoding method. This method is an image decoding method for performing motion compensation prediction, wherein a block including a motion vector is selected from a plurality of blocks adjacent to a decoding target block to generate a prediction vector candidate list; and Selecting a block including motion information including at least reference image information and a motion vector from a plurality of adjacent blocks to generate a combined motion information candidate list; a first prediction mode using the prediction vector candidate list; and the combining A step of selecting which prediction mode of the second prediction mode using the motion information candidate list is to be used; and information for specifying the prediction mode from the encoded stream is acquired, and the prediction mode is the first prediction mode. In this case, the prediction vector in the prediction vector candidate list is encoded from the encoded stream. Information for specifying a prediction vector indicating the position of the toll, a difference vector, and information for specifying a reference image of the decoding target block, and when the prediction mode is the second prediction mode, the code The prediction vector candidate list based on information for specifying motion information indicating the position of motion information in the combined motion information candidate list from the stream, and information for specifying the prediction vector Selecting a prediction vector of the decoding target block from prediction vector candidates included in the block, adding the prediction vector and the difference vector to reproduce the motion vector of the decoding target block, and the motion information Based on the information for specifying, from the motion information candidates included in the combined motion information candidate list, A step of selecting motion information of a block to be decoded; and, when the prediction mode is the first prediction mode, prediction is performed using a reference image specified by information for specifying the reference image and the reproduced motion vector A signal is generated, and when the prediction mode is the second prediction mode, a reference image specified by reference image information included in the selected motion information and a motion vector included in the selected motion information are used. Generating a prediction signal, and scaling a motion vector of a block that is a decoded block adjacent to the decoding target block and is included in an image temporally different from the image including the decoding target block, and Prepare. The scaled motion vector is shared by the first prediction mode and the second prediction mode.

本発明のさらに別の態様は、画像符号化装置である。その装置は、動き補償予測を行う画像符号化装置であって、符号化対象ブロックの予測信号を取得するための動きベクトルを検出する動きベクトル検出部(108)と、前記予測信号を含む参照画像を特定するための情報を符号化する符号列生成部(104)と、前記動きベクトルの予測ベクトル候補を生成するための予測ベクトル候補生成部(151、152)と、を備える。前記予測ベクトル候補生成部(151、152)は、前記符号化対象ブロックに隣接する符号化済みのブロックの動きベクトルの中から基準動きベクトルを決定する基準ベクトル決定部(170、175)と、スケーリング用の参照画像を特定するための情報を設定する参照画像情報設定部(171、176)と、前記スケーリング用の参照画像を特定するための情報に基づいて前記基準動きベクトルをスケーリングするスケーリング部(172、177)と、を含む。前記参照画像情報設定部(171、176)は、前記スケーリング用の参照画像を、前記予測信号を含む参照画像に依存せずに決定する。「前記符号化対象ブロックに隣接する符号化済みのブロック」は、前記符号化対象ブロックに空間的に隣接するブロックでもよいし、時間的に隣接するブロックでもよい。   Yet another embodiment of the present invention is an image encoding device. The apparatus is an image encoding apparatus that performs motion compensated prediction, and includes a motion vector detection unit (108) that detects a motion vector for obtaining a prediction signal of an encoding target block, and a reference image including the prediction signal A code string generation unit (104) that encodes information for specifying a motion vector and a prediction vector candidate generation unit (151 and 152) for generating a motion vector prediction vector candidate. The prediction vector candidate generation unit (151 and 152) includes a reference vector determination unit (170 and 175) that determines a reference motion vector from motion vectors of an encoded block adjacent to the encoding target block, and scaling. A reference image information setting unit (171 and 176) for setting information for specifying a reference image for scaling, and a scaling unit for scaling the reference motion vector based on the information for specifying the reference image for scaling ( 172, 177). The reference image information setting unit (171 and 176) determines the reference image for scaling without depending on the reference image including the prediction signal. The “encoded block adjacent to the encoding target block” may be a block spatially adjacent to the encoding target block or a temporally adjacent block.

本発明のさらに別の態様もまた、画像符号化装置である。その装置は、動き補償予測を行う画像符号化装置であって、符号化対象ブロックの予測信号を取得するための動きベクトルを生成し、当該動きベクトルの予測ベクトルを、前記符号化対象ブロックに隣接する符号化済みのブロックの動きベクトルの中から選択した動きベクトルに基づき、得る第1予測モードと、前記符号化対象ブロックに隣接する符号化済みのブロックの動きベクトルの中から選択した動きベクトルに基づき動き補償に使用する動きベクトルを得て、当該動きベクトルを使用して前記符号化対象ブロックの予測信号を生成する第2予測モードとのいずれかを選択する予測モード決定部(122)と、前記符号化対象ブロックに隣接する符号化済みのブロックであって、前記符号化対象ブロックを含む画像と時間的に異なる画像に含まれるブロックの動きベクトルをスケーリングするスケーリング部(172)と、を備える。前記スケーリング部によりスケーリングされた動きベクトルは、前記第1予測モードおよび前記第2予測モードで共用される。   Yet another embodiment of the present invention is also an image encoding device. The apparatus is an image encoding apparatus that performs motion compensation prediction, generates a motion vector for obtaining a prediction signal of an encoding target block, and makes the prediction vector of the motion vector adjacent to the encoding target block A first prediction mode to be obtained based on a motion vector selected from motion vectors of encoded blocks to be encoded and a motion vector selected from motion vectors of encoded blocks adjacent to the encoding target block. A prediction mode determination unit (122) that obtains a motion vector to be used for motion compensation based on the motion vector and selects one of the second prediction modes for generating a prediction signal of the coding target block using the motion vector; An encoded block adjacent to the encoding target block that is temporally different from an image including the encoding target block. It comprises a scaling unit (172) for scaling the motion vectors of blocks included in the. The motion vector scaled by the scaling unit is shared by the first prediction mode and the second prediction mode.

なお、以上の構成要素の任意の組み合わせ、本発明の表現を方法、装置、システム、記録媒体、コンピュータプログラムなどの間で変換したものもまた、本発明の態様として有効である。   It should be noted that any combination of the above-described constituent elements and a conversion of the expression of the present invention between a method, an apparatus, a system, a recording medium, a computer program, and the like are also effective as an aspect of the present invention.

本発明によれば、予測ベクトルの候補の生成に要する遅延時間を抑制しつつ、動きベクトルの予測精度を向上させることのできる動画像復号技術を提供することができる。   ADVANTAGE OF THE INVENTION According to this invention, the moving image decoding technique which can improve the prediction precision of a motion vector can be provided, suppressing the delay time required for the production | generation of the candidate of a prediction vector.

画像を最大符号化ブロックに分割する例を説明するための図である。It is a figure for demonstrating the example which divides | segments an image into the largest encoding block. 図2(a)、(b)は、符号化ブロックを説明するための図である。2A and 2B are diagrams for explaining an encoded block. 図3(a)〜(d)は、予測ブロックを説明するための図である。3A to 3D are diagrams for explaining a prediction block. 予測ブロックサイズを説明するための図である。It is a figure for demonstrating a prediction block size. 予測符号化モードを説明するための図である。It is a figure for demonstrating prediction encoding mode. 予測ブロックのシンタックスの一例を説明するための図である。It is a figure for demonstrating an example of the syntax of a prediction block. 図7(a)、(b)は、本発明の実施の形態によるマージインデックスと予測ベクトルインデックスの符号列を説明する図である。FIGS. 7A and 7B are diagrams illustrating code strings of the merge index and the prediction vector index according to the embodiment of the present invention. 本発明の実施の形態1に係る動画像符号化装置の構成を示す図である。It is a figure which shows the structure of the moving image encoder which concerns on Embodiment 1 of this invention. 動画像符号化装置の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a moving image encoder. 処理対象の予測ブロックサイズが16画素×16画素である場合の様子を示す図である。It is a figure which shows a mode in case the prediction block size of a process target is 16 pixels x 16 pixels. 動き情報生成部の構成を示す図である。It is a figure which shows the structure of a motion information generation part. 動き情報生成部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a motion information generation part. 予測ベクトルモード決定部の構成を示す図である。It is a figure which shows the structure of a prediction vector mode determination part. 予測ベクトルモード決定部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a prediction vector mode determination part. 処理対象の予測ブロックサイズが16画素×16画素である場合の処理対象の予測ブロックの隣接ブロックを示す図である。It is a figure which shows the adjacent block of the prediction block of a process target in case the prediction block size of a process target is 16 pixels x 16 pixels. 処理対象の予測ブロックサイズが16画素×16画素である場合の処理対象の予測ブロックと同一位置にあるColPic上の予測ブロック内のブロックとその周辺ブロックを示す図である。It is a figure which shows the block in the prediction block on ColPic in the same position as the prediction block of a process target in case the prediction block size of a process target is 16 pixels x 16 pixels, and its peripheral block. 予測ベクトル候補リスト生成部の構成を説明するための図である。It is a figure for demonstrating the structure of a prediction vector candidate list production | generation part. 予測ベクトル候補リスト生成部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a prediction vector candidate list production | generation part. 空間予測ベクトル候補生成部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a spatial prediction vector candidate production | generation part. 時間予測ベクトル候補生成部の構成を説明するための図である。It is a figure for demonstrating the structure of a time prediction vector candidate production | generation part. 時間予測ベクトル候補生成部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a time prediction vector candidate production | generation part. 時間予測ベクトル候補の算出手法を説明するための図である。It is a figure for demonstrating the calculation method of a time prediction vector candidate. 空間スケーリング予測ベクトル候補生成部の構成を説明するための図である。It is a figure for demonstrating the structure of a spatial scaling prediction vector candidate production | generation part. 空間スケーリング予測ベクトル候補生成部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a spatial scaling prediction vector candidate production | generation part. 空間スケーリング予測ベクトル候補の算出手法を説明するための図である。It is a figure for demonstrating the calculation method of a spatial scaling prediction vector candidate. 予測ベクトル候補リストの確定の動作を説明するためのフローチャートである。It is a flowchart for demonstrating the operation | movement of determination of a prediction vector candidate list. マージモード決定部の構成を説明するための図である。It is a figure for demonstrating the structure of a merge mode determination part. マージモード決定部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a merge mode determination part. 結合動き情報候補リスト生成部の構成を説明するための図である。It is a figure for demonstrating the structure of a joint motion information candidate list production | generation part. 結合動き情報候補リスト生成部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a joint motion information candidate list production | generation part. 空間結合動き情報候補生成部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a space joint motion information candidate production | generation part. 時間結合動き情報候補生成部の構成を説明するための図である。It is a figure for demonstrating the structure of a time combination motion information candidate production | generation part. 時間結合動き情報候補生成部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a time combination motion information candidate production | generation part. 空間スケーリング結合動き情報候補生成部の構成を説明するための図である。It is a figure for demonstrating the structure of a spatial scaling joint motion information candidate production | generation part. 空間スケーリング結合動き情報候補生成部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a spatial scaling joint motion information candidate production | generation part. 結合動き情報候補リストの確定の動作を説明するためのフローチャートである。It is a flowchart for demonstrating the operation | movement of the determination of a joint motion information candidate list. 実施の形態1の動画像復号装置を示す図である。1 is a diagram illustrating a moving image decoding apparatus according to Embodiment 1. FIG. 動画像復号装置の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a moving image decoding apparatus. 動き情報再生部の構成を示す図である。It is a figure which shows the structure of a motion information reproduction part. 動きベクトル再生部の構成を示す図である。It is a figure which shows the structure of a motion vector reproduction | regeneration part. 動きベクトル再生部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a motion vector reproduction | regeneration part. 結合動き情報再生部の構成を示す図である。It is a figure which shows the structure of a joint motion information reproduction part. 結合動き情報再生部の動作を説明するためのフローチャートである。It is a flowchart for demonstrating operation | movement of a joint motion information reproduction | regeneration part. 実施の形態1の変形例1における予測ベクトル候補リスト生成部の動作を説明するためのフローチャートである。10 is a flowchart for explaining an operation of a prediction vector candidate list generation unit in Modification 1 of Embodiment 1. 実施の形態2の予測ブロックのシンタックスの一例を説明するための図である。10 is a diagram for describing an example of a syntax of a prediction block according to Embodiment 2. FIG. 実施の形態2の予測ベクトルモード決定部の動作を説明するためのフローチャートである。12 is a flowchart for explaining an operation of a prediction vector mode determination unit according to the second embodiment. 実施の形態2の予測ベクトル候補リスト確定部の動作を説明するためのフローチャートである。10 is a flowchart for explaining an operation of a prediction vector candidate list determination unit according to the second embodiment.

まず、本発明の実施の形態の前提となる技術を説明する。   First, a technique that is a premise of the embodiment of the present invention will be described.

現在、MPEG(Moving Picture Experts Group)などの符号化方式に準拠した装置およびシステムが普及している。そのような符号化方式では、時間軸上に連続する複数の画像をデジタル信号の情報として取り扱う。その際、効率の高い情報の放送、伝送または蓄積などを目的とし、時間方向の冗長性を利用した動き補償予測、および空間方向の冗長性を利用した離散コサイン変換などの直交変換を用いて圧縮符号化する。   Currently, apparatuses and systems that comply with an encoding method such as MPEG (Moving Picture Experts Group) are widely used. In such an encoding method, a plurality of images that are continuous on the time axis are handled as digital signal information. At that time, for the purpose of broadcasting, transmitting or storing highly efficient information, compression using motion compensation prediction using temporal redundancy and orthogonal transform such as discrete cosine transform using spatial redundancy Encode.

1995年にはMPEG−2ビデオ(ISO/IEC 13818−2)符号化方式が、汎用の映像圧縮符号化方式として制定され、DVDおよびD−VHS(登録商標)規格のデジタルVTRによる磁気テープなどの蓄積メディア、ならびにデジタル放送などのアプリケーションとして広く用いられている。   In 1995, the MPEG-2 video (ISO / IEC 13818-2) encoding method was established as a general-purpose video compression encoding method, such as a magnetic tape based on DVD and D-VHS (registered trademark) digital VTR. It is widely used as an application for storage media and digital broadcasting.

さらに、2003年に、国際標準化機構(ISO)と国際電気標準会議(IEC)のジョイント技術委員会(ISO/IEC)と、国際電気通信連合電気通信標準化部門(ITU−T)の共同作業によってMPEG−4 AVC/H.264と呼ばれる符号化方式(ISO/IECでは14496−10、ITU−TではH.264の規格番号がつけられている。以下、これをMPEG−4AVCと呼ぶ)が国際標準として制定された。   Furthermore, in 2003, joint work of the International Technical Organization (ISO) and the International Electrotechnical Commission (IEC) Joint Technical Committee (ISO / IEC) and the International Telecommunication Union Telecommunication Standardization Sector (ITU-T) -4 AVC / H. An encoding method called H.264 (the ISO / IEC has a standard number of 14496-10 and ITU-T has an H.264 standard number, hereinafter referred to as MPEG-4AVC) has been established as an international standard.

現在、国際標準化機構(ISO)と国際電気標準会議(IEC)のジョイント技術委員会(ISO/IEC)と、国際電気通信連合電気通信標準化部門(ITU−T)の共同作業によってHEVCと呼ばれる符号化方式の標準化が検討されている。   Coding currently called HEVC by the joint work of the International Technical Organization (ISO) and the International Electrotechnical Commission (IEC) Joint Technical Committee (ISO / IEC) and the International Telecommunication Union Telecommunication Standardization Sector (ITU-T) Standardization of the method is being studied.

HEVCの標準化では、複数の隣接ブロックと復号済みの別の画像のブロックを候補ブロック群として、これら候補ブロック群から予測ブロックとして最適な候補ブロックが選択されて、選択された候補ブロックの情報が符号化および復号される技術が検討されている。   In the standardization of HEVC, a plurality of adjacent blocks and another decoded block of images are used as a candidate block group, and an optimal candidate block is selected as a prediction block from these candidate block groups, and information on the selected candidate block is encoded. Techniques for converting and decoding are being studied.

HEVCでは予測ベクトルモード(動き検出モードともいう)、マージモードの導入が検討されている。予測ベクトルモード時には、選択された候補ブロックの動きベクトルがから予測ベクトルが生成され、その予測ベクトルと処理対象ブロックの差分ベクトルとが加算されて、処理対象ブロックの動きベクトルが再生される。マージモード時には、選択された候補ブロックの動き補償予測の予測方向、参照画像情報、および動きベクトル情報を含む動き情報が、処理対象ブロックの動き情報として利用される。   In HEVC, introduction of a prediction vector mode (also referred to as a motion detection mode) and a merge mode are being studied. In the prediction vector mode, a prediction vector is generated from the motion vector of the selected candidate block, and the prediction vector and the difference vector of the processing target block are added to reproduce the motion vector of the processing target block. In the merge mode, motion information including the prediction direction of motion compensation prediction of the selected candidate block, reference image information, and motion vector information is used as motion information of the processing target block.

予測ベクトルモードとマージモードでは、復号済みの別の画像の候補ブロックが予測ブロックとして選択された場合、動きベクトルの再生において、処理対象画像と参照画像との画像間距離に応じたスケーリングと呼ばれる演算が行われる。しかしながら、予測ベクトルモードとマージモードではスケーリングの演算対象とする参照画像が異なっているため、予測ベクトルモードとマージモードで、異なる動きベクトルの再生が必要となり、スケーリングの演算部の共用を困難にしている。   In prediction vector mode and merge mode, when a candidate block of another decoded image is selected as a prediction block, an operation called scaling according to the inter-image distance between the processing target image and the reference image in motion vector reproduction Is done. However, since the reference images to be scaled are different in the prediction vector mode and the merge mode, it is necessary to reproduce different motion vectors in the prediction vector mode and the merge mode, which makes it difficult to share the scaling calculation unit. Yes.

また、マージモードでは予測ブロックサイズが決定した直後にスケーリングを実行できるが、予測ベクトルモードでは参照画像情報の復号が完了するまでスケーリングを実行できないため、マージモードと予測ベクトルモードのいずれかのモードが確定するまでスケーリングを実行できない制約がある。   In the merge mode, scaling can be performed immediately after the prediction block size is determined, but in the prediction vector mode, scaling cannot be performed until the decoding of the reference image information is completed. Therefore, either the merge mode or the prediction vector mode is selected. There is a restriction that scaling cannot be performed until it is fixed.

さらに、予測ベクトルモードでは、隣接ブロックの、ある予測方向の動きベクトルが不足した場合に、同じ候補ブロック群から予測方向が反対方向の動きベクトルをスケーリングした動きベクトルを新たな予測ベクトル候補として利用することができる。ところが、スケーリングした動きベクトルを隣接ブロックの動きベクトルの代替候補として利用しているため、スケーリングした動きベクトルを有効に利用できていない問題がある。   Further, in the prediction vector mode, when a motion vector in a certain prediction direction of an adjacent block is insufficient, a motion vector obtained by scaling a motion vector in the opposite direction from the same candidate block group is used as a new prediction vector candidate. be able to. However, since the scaled motion vector is used as an alternative candidate for the motion vector of the adjacent block, there is a problem that the scaled motion vector cannot be used effectively.

(符号化ブロック)
本発明の実施の形態では、入力された画像信号を図1のように最大符号化ブロック単位に分割し、分割した符号化ブロックをラスタースキャン順序で処理する。図1は、画像を最大符号化ブロックに分割する例を説明するための図である。符号化ブロックは階層構造となっており、符号化効率などを考慮して順次均等に4分割することでより小さい符号化ブロックにすることができる。なお、4分割された符号化ブロックはジグザグスキャン順で符号化される。これ以上小さくすることのできない符号化ブロックを最小符号化ブロックと呼ぶ。符号化ブロックは符号化の単位となり、最大符号化ブロックも分割数が0である場合は符号化ブロックとなる。本実施の形態では、最大符号化ブロックを64画素×64画素、最小符号化ブロックを8画素×8画素とする。
(Encoding block)
In the embodiment of the present invention, an input image signal is divided into maximum coding block units as shown in FIG. 1, and the divided coding blocks are processed in a raster scan order. FIG. 1 is a diagram for explaining an example in which an image is divided into maximum coding blocks. The encoded block has a hierarchical structure, and can be made smaller encoded blocks by sequentially equally dividing into 4 in consideration of the encoding efficiency. Note that the encoded blocks divided into four are encoded in the zigzag scan order. An encoded block that cannot be further reduced is called a minimum encoded block. An encoded block is a unit of encoding, and the maximum encoded block is also an encoded block when the number of divisions is zero. In this embodiment, the maximum coding block is 64 pixels × 64 pixels, and the minimum coding block is 8 pixels × 8 pixels.

図2(a)、(b)は、符号化ブロックを説明するための図である。図2(a)の例では、符号化ブロックが10個に分割されている。CU0、CU1およびCU9は32画素×32画素の符号化ブロック、CU2、CU3およびCU8は16画素×16画素の符号化ブロック、ならびにCU4、CU5、CU6およびCU7は8画素×8画素の符号化ブロックとなっている。図2(b)の例では、符号化ブロックが1個に分割されている。   2A and 2B are diagrams for explaining an encoded block. In the example of FIG. 2A, the encoded block is divided into ten. CU0, CU1 and CU9 are 32 × 32 pixel coding blocks, CU2, CU3 and CU8 are 16 × 16 pixel coding blocks, and CU4, CU5, CU6 and CU7 are 8 × 8 pixel coding blocks. It has become. In the example of FIG. 2B, the encoded block is divided into one.

(予測ブロック)
本発明の実施の形態では、符号化ブロックはさらに予測ブロックに分割される。図3(a)〜(d)は、予測ブロックを説明するための図である。図3(a)は符号化ブロックを分割しない2N×2N、図3(b)は水平に分割する2N×N、図3(c)は垂直に分割するN×2N、および図3(d)は水平と垂直に分割するN×Nを示す。図4は、予測ブロックサイズを説明するための図である。つまり、予測ブロックサイズには、図4に示すように、CU分割数が0であって最大の予測ブロックサイズである64画素×64画素からCU分割数が3であって最小の予測ブロックサイズである4画素×4画素までの13の予測ブロックサイズが存在することになる。
(Prediction block)
In the embodiment of the present invention, the encoded block is further divided into prediction blocks. 3A to 3D are diagrams for explaining a prediction block. 3A is 2N × 2N that does not divide the encoded block, FIG. 3B is 2N × N that is horizontally divided, FIG. 3C is N × 2N that is vertically divided, and FIG. 3D. Indicates N × N divided horizontally and vertically. FIG. 4 is a diagram for explaining the prediction block size. In other words, as shown in FIG. 4, the prediction block size includes a CU division number of 0 and a maximum prediction block size of 64 pixels × 64 pixels to a CU division number of 3 and a minimum prediction block size. There are 13 predicted block sizes up to 4 pixels x 4 pixels.

本発明の実施の形態では、最大符号化ブロックを64画素×64画素、最小符号化ブロックを8画素×8画素とするが、この組み合わせに限定されない。また、予測ブロックの分割のパターンを図3(a)〜(d)としたが、1以上に分割されればよくこれに限定されない。   In the embodiment of the present invention, the maximum coding block is 64 pixels × 64 pixels and the minimum coding block is 8 pixels × 8 pixels, but the present invention is not limited to this combination. Further, although the prediction block division patterns are shown in FIGS. 3A to 3D, the division is not limited to this as long as it is divided into one or more.

(予測符号化モード)
本発明の実施の形態では、動き補償予測や符号化ベクトル数を予測ブロックのブロックサイズで切り替えることが可能となっている。ここで、動き補償予測と符号化ベクトル数を関連付けた予測符号化モードの一例について図5を用いて簡単に説明する。図5は、予測符号化モードを説明するための図である。
(Predictive coding mode)
In the embodiment of the present invention, motion-compensated prediction and the number of encoded vectors can be switched according to the block size of the prediction block. Here, an example of a predictive coding mode in which motion compensation prediction is associated with the number of coding vectors will be briefly described with reference to FIG. FIG. 5 is a diagram for explaining the predictive coding mode.

図5に示す予測符号化モードには、動き補償予測の予測方向が単予測(L0予測)であって符号化ベクトル数が1であるPredL0、動き補償予測の予測方向が単予測(L1予測)であって符号化ベクトル数が1であるPredL1、動き補償予測の予測方向が双予測(BI予測)であって符号化ベクトル数が2であるPredBI、および動き補償予測の予測方向が単予測(L0予測/L1予測)または双予測(BI予測)であって符号化ベクトル数が0であるマージモード(MERGE)がある。また、動き補償予測を実施しない予測符号化モードであるイントラモード(Intra)もある。ここで、PredL0、PredL1、およびPredBIが予測ベクトルモードとなる。   In the predictive coding mode shown in FIG. 5, the prediction direction of motion compensation prediction is single prediction (L0 prediction) and the number of coding vectors is PredL0, and the prediction direction of motion compensation prediction is single prediction (L1 prediction). PredL1 in which the number of encoding vectors is 1, PredBI in which the prediction direction of motion compensation prediction is bi-prediction (BI prediction) and the number of encoding vectors is 2, and the prediction direction in motion compensation prediction is single prediction ( There is a merge mode (MERGE) which is L0 prediction / L1 prediction) or bi-prediction (BI prediction) and the number of encoding vectors is zero. There is also an intra mode (Intra) which is a predictive coding mode in which motion compensation prediction is not performed. Here, PredL0, PredL1, and PredBI are prediction vector modes.

(参照インデックス)
本発明の実施の形態では、動き補償予測の精度向上のために、動き補償予測において複数の参照画像の中から最適な参照画像を選択することを可能とする。そのため、動き補償予測で利用した参照画像を参照画像インデックスとして符号化ベクトルとともに符号化する。動き補償予測で利用される参照画像インデックスは0以上の数値となる。動き補償予測が単予測であれば、参照インデックスは1つ利用され、動き補償予測が双予測であれば、2つの参照インデックスが利用される(図5)。
(Reference index)
In the embodiment of the present invention, it is possible to select an optimal reference image from a plurality of reference images in motion compensation prediction in order to improve the accuracy of motion compensation prediction. Therefore, the reference image used in motion compensation prediction is encoded as a reference image index together with the encoded vector. The reference image index used in motion compensation prediction is a numerical value of 0 or more. If the motion compensation prediction is uni-prediction, one reference index is used, and if the motion compensation prediction is bi-prediction, two reference indexes are used (FIG. 5).

(参照インデックスリスト)
本発明の実施の形態では、動き補償予測で利用できる複数の参照画像を参照インデックスリスト内に登録しておき、参照インデックスリスト内に登録された参照画像を参照インデックスで示すことによって参照画像を確定させて動き補償予測で利用する。参照インデックスリストには、参照インデックスリストL0と参照インデックスリストL1がある。動き補償予測が単予測の場合は、参照インデックスリストL0の中の参照画像を用いたL0予測、または参照インデックスリストL1の中の参照画像を用いたL1予測のいずれかを利用する。双予測の場合は参照インデックスリストL0と参照インデックスリストL1の2つを利用したBI予測を利用する。
(Reference index list)
In the embodiment of the present invention, a plurality of reference images that can be used in motion compensation prediction are registered in the reference index list, and the reference image registered in the reference index list is indicated by the reference index to determine the reference image. And used in motion compensated prediction. The reference index list includes a reference index list L0 and a reference index list L1. When the motion compensation prediction is simple prediction, either L0 prediction using a reference image in the reference index list L0 or L1 prediction using a reference image in the reference index list L1 is used. In the case of bi-prediction, BI prediction using the reference index list L0 and the reference index list L1 is used.

(マージインデックス)
本発明の実施の形態では、符号化効率を向上させるために、複数の隣接ブロックおよび符号化済みの別の画像の処理対象ブロックと同一位置の周辺にあるブロックを候補ブロックとして、候補ブロックの動き情報の中から最適な動き情報を有する候補ブロックを選択し、選択した候補ブロックを示すためのマージインデックスを符号化および復号する。これは、選択されたマージインデックスの示すブロックの動き補償予測の予測方向、動きベクトル情報、参照画像情報を含む動き情報を処理対象ブロックで利用する動き補償予測技術(マージ技術)である。マージインデックスは予測符号化モードがマージモードの場合に1つ利用される(図5)。なお、動き情報が双予測であれば、動き情報にはそれぞれ2つの動きベクトル情報と参照画像情報が含まれる。マージインデックスで選択できる候補ブロックの最大数(以降、マージ候補最大数とする)は5であり、マージインデックスは0から4の整数となる。ここでは、マージ候補最大数を5としたが、2以上であればよく、これに限定されない。
(Merge index)
In the embodiment of the present invention, in order to improve the coding efficiency, the motion of a candidate block is determined by setting a plurality of adjacent blocks and blocks around the same position as the processing target block of another coded image as candidate blocks. A candidate block having optimal motion information is selected from the information, and a merge index for indicating the selected candidate block is encoded and decoded. This is a motion compensation prediction technique (merge technique) that uses motion information including a prediction direction, motion vector information, and reference image information of a block indicated by a selected merge index in a processing target block. One merge index is used when the predictive coding mode is the merge mode (FIG. 5). If the motion information is bi-predicted, the motion information includes two pieces of motion vector information and reference image information. The maximum number of candidate blocks that can be selected by the merge index (hereinafter referred to as the maximum number of merge candidates) is 5, and the merge index is an integer from 0 to 4. Here, although the maximum number of merge candidates is set to 5, it may be 2 or more, and is not limited to this.

以降、マージインデックスの対象となる候補ブロックの持つ動き情報を結合動き情報候補と呼び、結合動き情報候補の集合体を結合動き情報候補リストと呼ぶ。   Hereinafter, the motion information of the candidate block that is the target of the merge index is referred to as a combined motion information candidate, and the aggregate of combined motion information candidates is referred to as a combined motion information candidate list.

(予測ベクトルインデックス)
本発明の実施の形態では、予測ベクトルの精度を向上させるために、複数の隣接ブロックおよび符号化済みの別の画像の処理対象ブロックと同一位置の周辺にあるブロックを候補ブロックとして、候補ブロックの動きベクトルの中から予測ベクトルとして最適な動きベクトルを持つ候補ブロックを選択し、選択した候補ブロックを示すための予測ベクトルインデックスを符号化および復号する。動き補償予測が単予測であれば、予測ベクトルインデックスは1つ利用され、動き補償予測が双予測であれば、2つの予測ベクトルインデックスが利用される(図5)。それぞれの予測ベクトルインデックスで選択できる候補ブロックの最大数(以降、予測ベクトル候補最大数とする)は2であり、予測ベクトルインデックスは0または1の整数となる。ここでは、予測ベクトル候補最大数を2としたが、2以上であればよく、これに限定されない。
(Predicted vector index)
In the embodiment of the present invention, in order to improve the accuracy of a prediction vector, a plurality of adjacent blocks and blocks around the same position as a processing target block of another encoded image are used as candidate blocks. A candidate block having an optimal motion vector as a prediction vector is selected from the motion vectors, and a prediction vector index for indicating the selected candidate block is encoded and decoded. If the motion compensation prediction is uni-prediction, one prediction vector index is used, and if the motion compensation prediction is bi-prediction, two prediction vector indexes are used (FIG. 5). The maximum number of candidate blocks that can be selected with each prediction vector index (hereinafter referred to as the maximum number of prediction vector candidates) is 2, and the prediction vector index is an integer of 0 or 1. Although the maximum number of prediction vector candidates is 2 here, it may be 2 or more, and is not limited to this.

以降、予測ベクトルインデックスの対象となる候補ブロックの動きベクトルを予測ベクトル候補と呼び、予測ベクトル候補の集合体を予測ベクトル候補リストと呼ぶ。   Hereinafter, a motion vector of a candidate block that is a target of a prediction vector index is referred to as a prediction vector candidate, and a set of prediction vector candidates is referred to as a prediction vector candidate list.

本発明の実施の形態では、マージ候補最大数を5、予測ベクトル候補最大数を2としたが、いずれかが2以上であればよく、この組み合わせに限定されない。   In the embodiment of the present invention, the maximum number of merge candidates is set to 5 and the maximum number of prediction vector candidates is set to 2, but any one may be 2 or more and is not limited to this combination.

(シンタックス)
本発明の実施の形態による予測ブロックのシンタックスの一例について図6を用いて説明する。予測ブロックがイントラであるかインターであるかは上位の符号化ブロックによって指定されており、図6は予測ブロックがインターの場合の予測ブロックのシンタックスを示す。予測ブロックには、マージフラグ(merge_flag)、マージインデックス(merge_idx)、インター予測モード(inter_pred_type)、参照インデックス(ref_idx_l0とref_idx_l1)、差分ベクトル(mvd_l0[0]、mvd_l0[1]、mvd_l1[0]、mvd_l1[1])および予測ベクトルインデックス(mvp_idx_l0およびmvp_idx_l1)が設置されている。差分ベクトルの[0]は水平成分、[1]は垂直成分を示す。
(Syntax)
An example of the syntax of the prediction block according to the embodiment of the present invention will be described with reference to FIG. Whether the prediction block is intra or inter is specified by the higher-order encoding block, and FIG. 6 shows the syntax of the prediction block when the prediction block is inter. The prediction block includes a merge flag (merge_flag), a merge index (merge_idx), an inter prediction mode (inter_pred_type), a reference index (ref_idx_l0 and ref_idx_l1), and a difference vector (mvd_l0 [0], mvd_l0 [1], mvd_l mvd_l1 [1]) and prediction vector indexes (mvp_idx_l0 and mvp_idx_l1) are installed. [0] of the difference vector indicates a horizontal component and [1] indicates a vertical component.

ここで、ref_idx_l0とmvd_l0[0]、mvd_l0[1]、mvp_idx_l0はL0予測に関する情報であって、ref_idx_l1とmvd_l1[0]、mvd_l1[1]、mvp_idx_l1はL1予測に関する情報である。inter_pred_typeは動き補償予測の予測方向を示し、Pred_L0(L0予測の単予測)、Pred_L1(L1予測の単予測)およびPred_BI(BIの双予測)の3種類がある。   Here, ref_idx_l0, mvd_l0 [0], mvd_l0 [1], and mvp_idx_l0 are information related to L0 prediction, and ref_idx_l1 and mvd_l1 [0], mvd_l1 [1], and mvp_idx_l1 are information related to L1 prediction. inter_pred_type indicates the prediction direction of motion compensation prediction, and there are three types: Pred_L0 (single prediction of L0 prediction), Pred_L1 (single prediction of L1 prediction) and Pred_BI (bi prediction of BI).

なお、本発明の実施の形態による予測ブロックのシンタックスを図6のように設定したが、本発明の実施の形態によれば予測ベクトルモードの場合に参照インデックスが含まれていればよく、これに限定されない。   Although the syntax of the prediction block according to the embodiment of the present invention is set as shown in FIG. 6, according to the embodiment of the present invention, it is sufficient that the reference index is included in the prediction vector mode. It is not limited to.

(マージインデックスと予測ベクトルインデックスの符号列)
次に、マージインデックスと予測ベクトルインデックスの符号列について説明する。図7(a)、(b)は、本発明の実施の形態によるマージインデックスと予測ベクトルインデックスの符号列を説明する図である。符号列としてTruncated Unary符号列を用いる。図7(a)はマージインデックスの符号列を、図7(b)は予測ベクトルインデックスの符号列を示す。
(Code sequence of merge index and prediction vector index)
Next, the code strings of the merge index and the prediction vector index will be described. FIGS. 7A and 7B are diagrams illustrating code strings of the merge index and the prediction vector index according to the embodiment of the present invention. A Truncated Unary code string is used as the code string. FIG. 7A shows the code sequence of the merge index, and FIG. 7B shows the code sequence of the prediction vector index.

図7(a)、(b)から分かるように、小さいマージインデックスの方が符号列は短い(符号量は少ない)ため、選択率が相対的に高い候補に小さなマージインデックスを割り当てることで符号化効率を向上させることができる。   As can be seen from FIGS. 7 (a) and 7 (b), since the code sequence is shorter in the smaller merge index (the code amount is smaller), encoding is performed by assigning a smaller merge index to a candidate having a relatively high selection rate. Efficiency can be improved.

(POC)
本発明の実施の形態では、画像の時間情報(距離情報)としてPOC(Picture Order Count)を用いる。POCはMPEG−4AVCで定義された画像の表示順序を示すカウンタである。画像の表示順序が1増加するとPOCも1増加する。したがって、画像間のPOC差から画像間の時間差(距離)を取得できる。
(POC)
In the embodiment of the present invention, POC (Picture Order Count) is used as time information (distance information) of an image. POC is a counter indicating the display order of images defined by MPEG-4 AVC. When the image display order is increased by 1, the POC is also increased by 1. Therefore, the time difference (distance) between images can be acquired from the POC difference between images.

以下、図面とともに本発明の好適な実施の形態に係る動画像符号化装置、動画像符号化方法および動画像符号化プログラム、ならびに動画像復号装置、動画像復号方法および動画像復号プログラムの詳細について説明する。なお、図面の説明において同一要素には同一符号を付与して重複する説明を省略する。   Hereinafter, with reference to the drawings, details of a moving image encoding apparatus, a moving image encoding method, a moving image encoding program, a moving image decoding apparatus, a moving image decoding method, and a moving image decoding program according to a preferred embodiment of the present invention will be described. explain. In the description of the drawings, the same elements are denoted by the same reference numerals and redundant description is omitted.

[実施の形態1]
(動画像符号化装置100の構成)
図8は、本発明の実施の形態1に係る動画像符号化装置100の構成を示す。動画像符号化装置100は、動画像信号を、動き補償予測を実施する予測ブロック単位で符号化する装置である。符号化ブロックの分割、予測ブロックサイズの決定、予測符号化モードがイントラであるかの決定は図示しない上位の符号化制御部で決定されているものとし、実施の形態1では予測符号化モードがイントラでない場合について説明する。また、実施の形態1では双予測に対応したBピクチャについて説明するが、双予測に対応しないPピクチャについてはL1予測を省略すればよい。
[Embodiment 1]
(Configuration of moving picture coding apparatus 100)
FIG. 8 shows a configuration of moving picture coding apparatus 100 according to Embodiment 1 of the present invention. The moving image encoding apparatus 100 is an apparatus that encodes a moving image signal in units of prediction blocks for performing motion compensated prediction. It is assumed that the coding block is divided, the prediction block size is determined, and whether the prediction coding mode is intra is determined by an upper coding control unit (not shown). In the first embodiment, the prediction coding mode is A case where it is not an intra will be described. In the first embodiment, a B picture corresponding to bi-prediction will be described, but L1 prediction may be omitted for a P picture not corresponding to bi-prediction.

動画像符号化装置100は、CPU(Central Processing Unit)、フレームメモリ、ハードディスクなどを備える情報処理装置などのハードウェアにより実現される。動画像符号化装置100は、上記の構成要素が動作することにより、以下に説明する機能的な構成要素を実現する。なお、処理対象の予測ブロックの位置情報、予測ブロックサイズおよび動き補償予測の予測方向に関しては動画像符号化装置100内で共有していることとし、図示しない。   The moving image encoding apparatus 100 is realized by hardware such as an information processing apparatus including a CPU (Central Processing Unit), a frame memory, and a hard disk. The moving image encoding apparatus 100 realizes functional components described below by operating the above components. Note that the position information of the prediction block to be processed, the prediction block size, and the prediction direction of motion compensated prediction are assumed to be shared in the video encoding device 100 and are not shown.

実施の形態1の動画像符号化装置100は、予測ブロック画像取得部101、減算部102、予測誤差符号化部103、符号列生成部104、予測誤差復号部105、動き補償部106、加算部107、動きベクトル検出部108、動き情報生成部109、フレームメモリ110、および動き情報メモリ111を含む。   The moving image encoding apparatus 100 according to Embodiment 1 includes a prediction block image acquisition unit 101, a subtraction unit 102, a prediction error encoding unit 103, a code string generation unit 104, a prediction error decoding unit 105, a motion compensation unit 106, and an addition unit. 107, a motion vector detection unit 108, a motion information generation unit 109, a frame memory 110, and a motion information memory 111.

(動画像符号化装置100の動作)
以下、各部の機能と動作について説明する。図9は、動画像符号化装置100の動作を説明するためのフローチャートである。予測ブロック画像取得部101は、予測ブロックの位置情報と予測ブロックサイズに基づいて、端子10より供給される画像信号から処理対象の予測ブロックの画像信号を取得し(S100)、予測ブロックの画像信号を減算部102、動きベクトル検出部108および動き情報生成部109に供給する。
(Operation of moving picture coding apparatus 100)
Hereinafter, the function and operation of each unit will be described. FIG. 9 is a flowchart for explaining the operation of the moving picture coding apparatus 100. The prediction block image acquisition unit 101 acquires the image signal of the prediction block to be processed from the image signal supplied from the terminal 10 based on the position information and the prediction block size of the prediction block (S100), and the image signal of the prediction block Is supplied to the subtraction unit 102, the motion vector detection unit 108, and the motion information generation unit 109.

動きベクトル検出部108は、予測ブロック画像取得部101より供給される画像信号および内部に記憶している複数の参照画像に相当する画像信号から、L0予測とL1予測それぞれの動きベクトルと参照画像を示す参照インデックスを検出する(S101)。当該L0予測とL1予測の動きベクトル、および当該L0予測とL1予測の参照インデックスを動き情報生成部109に供給する。ここでは、L0予測とL1予測の参照画像の数をそれぞれ3とする。実施の形態1では、L0予測とL1予測の参照画像の数をそれぞれ3としたが、L0予測とL1予測の参照画像の数はそれぞれ1以上であればよく、これに限定されない。   The motion vector detection unit 108 obtains motion vectors and reference images of the L0 prediction and the L1 prediction from the image signal supplied from the prediction block image acquisition unit 101 and image signals corresponding to a plurality of reference images stored therein. The indicated reference index is detected (S101). The motion vector of the L0 prediction and the L1 prediction and the reference index of the L0 prediction and the L1 prediction are supplied to the motion information generation unit 109. Here, the number of reference images for L0 prediction and L1 prediction is 3 respectively. In the first embodiment, the number of reference images for L0 prediction and L1 prediction is three, but the number of reference images for L0 prediction and L1 prediction only needs to be one or more, and is not limited thereto.

一般的な動きベクトルの検出方法は、対象画像の画像信号と、同一位置より所定の移動量だけ移動させた参照画像の予測信号について誤差評価値を算出し、誤差評価値が最小となる移動量を動きベクトルとする。参照画像が複数ある場合には各参照画像について動きベクトルを検出し、誤差評価値が最小となる参照画像を選択する。誤差評価値としては、絶対差分和を示すSAD(Sum of Absolute Difference)や二乗誤差平均を示すMSE(Mean Square Error)などを利用することが可能である。   A general motion vector detection method calculates an error evaluation value for an image signal of a target image and a prediction signal of a reference image moved by a predetermined movement amount from the same position, and a movement amount that minimizes the error evaluation value. Is a motion vector. When there are a plurality of reference images, a motion vector is detected for each reference image, and a reference image having a minimum error evaluation value is selected. As the error evaluation value, SAD (Sum of Absolute Difference) indicating the sum of absolute differences, MSE (Mean Square Error) indicating the mean square error, or the like can be used.

動き情報生成部109は、動きベクトル検出部108より供給されるL0予測とL1予測の動きベクトルおよびL0予測とL1予測の参照インデックス、動き情報メモリ111より供給される候補ブロック群、フレームメモリ110内の参照インデックスで示される参照画像、および予測ブロック画像取得部101より供給される画像信号から、予測符号化モードを決定する(S102)。   The motion information generation unit 109 includes the motion vectors of the L0 prediction and the L1 prediction supplied from the motion vector detection unit 108, the reference index of the L0 prediction and the L1 prediction, the candidate block group supplied from the motion information memory 111, and the frame memory 110. The predictive coding mode is determined from the reference image indicated by the reference index and the image signal supplied from the prediction block image acquisition unit 101 (S102).

決定された予測符号化モードに基づいて、マージフラグ、マージインデックス、動き補償予測の予測方向、L0予測とL1予測の参照インデックス、L0予測とL1予測の差分ベクトルおよびL0予測とL1予測の予測ベクトルインデックスを必要に応じて、符号列生成部104に供給する。動き補償予測の予測方向、L0予測とL1予測の参照インデックス、およびL0予測とL1予測の動きベクトルを動き補償部106および動き情報メモリ111に供給する。動き情報生成部109の詳細については後述する。   Based on the determined predictive coding mode, the merge flag, the merge index, the prediction direction of motion compensation prediction, the reference index of L0 prediction and L1 prediction, the difference vector of L0 prediction and L1 prediction, and the prediction vector of L0 prediction and L1 prediction The index is supplied to the code string generation unit 104 as necessary. The motion compensation prediction direction, the reference index of L0 prediction and L1 prediction, and the motion vector of L0 prediction and L1 prediction are supplied to the motion compensation unit 106 and the motion information memory 111. Details of the motion information generation unit 109 will be described later.

動き補償部106は、動き情報生成部109より供給される動き補償予測の予測方向がLN予測であれば、動き情報生成部109より供給されるLN予測の参照インデックスで示されるフレームメモリ110内の参照画像を、動き情報生成部109より供給されるLN予測の動きベクトルに基づき動き補償してLN予測の予測信号を生成する(S103)。Nは0または1である。なお、動き補償予測の予測方向が双予測であれば、L0予測とL1予測の予測信号の平均値が予測信号となる。動き補償部106は、当該予測信号を減算部102に供給する。   If the prediction direction of the motion compensation prediction supplied from the motion information generation unit 109 is LN prediction, the motion compensation unit 106 stores the frame compensation information in the frame memory 110 indicated by the LN prediction reference index supplied from the motion information generation unit 109. The reference image is motion-compensated based on the LN prediction motion vector supplied from the motion information generation unit 109 to generate a prediction signal for LN prediction (S103). N is 0 or 1. If the prediction direction of motion compensation prediction is bi-prediction, the average value of the prediction signals of L0 prediction and L1 prediction is the prediction signal. The motion compensation unit 106 supplies the prediction signal to the subtraction unit 102.

減算部102は、予測ブロック画像取得部101より供給される画像信号と動き補償部106より供給される予測信号を減算して予測誤差信号を算出し(S104)、当該予測誤差信号を予測誤差符号化部103に供給する。   The subtraction unit 102 calculates a prediction error signal by subtracting the image signal supplied from the prediction block image acquisition unit 101 and the prediction signal supplied from the motion compensation unit 106 (S104), and calculates the prediction error signal as a prediction error code. To the conversion unit 103.

予測誤差符号化部103は、減算部102より供給される予測誤差信号に対して、量子化や直交変換などの処理を行って予測誤差符号化データを生成し(S105)、当該予測誤差符号化データを符号列生成部104および予測誤差復号部105に供給する。   The prediction error encoding unit 103 performs processing such as quantization and orthogonal transformation on the prediction error signal supplied from the subtraction unit 102 to generate prediction error encoded data (S105), and the prediction error encoding Data is supplied to the code string generation unit 104 and the prediction error decoding unit 105.

符号列生成部104は、予測誤差符号化部103より供給される予測誤差符号化データ、ならびに動き情報生成部109より供給されるマージフラグ、マージインデックス、動き補償予測の予測方向(インター予測モード)、L0予測とL1予測の参照インデックス、L0予測とL1予測の差分ベクトルおよびL0予測とL1予測の予測ベクトルインデックスをシンタックスに従ってエントロピー符号化して符号列を生成し(S106)、当該符号列を端子11に供給する。エントロピー符号化は算術符号化やハフマン符号化などの可変長符号化を含む方法によって実施される。   The code string generation unit 104 includes prediction error encoded data supplied from the prediction error encoding unit 103, a merge flag, a merge index, and a motion compensation prediction prediction direction (inter prediction mode) supplied from the motion information generation unit 109. , L0 prediction and L1 prediction reference index, L0 prediction and L1 prediction difference vector and L0 prediction and L1 prediction prediction vector index are entropy-coded according to the syntax to generate a code string (S106), and the code string is a terminal 11 is supplied. Entropy coding is performed by a method including variable length coding such as arithmetic coding or Huffman coding.

予測誤差復号部105は、予測誤差符号化部103より供給される予測誤差符号化データに対して、逆量子化や逆直交変換などの処理を行って予測誤差信号を生成し、当該予測誤差信号を加算部107に供給する。加算部107は、予測誤差復号部105より供給される予測誤差信号と、動き補償部106より供給される予測信号を加算して復号画像信号を生成し(S107)、当該復号画像信号をフレームメモリ110に供給する。   The prediction error decoding unit 105 performs a process such as inverse quantization or inverse orthogonal transform on the prediction error encoded data supplied from the prediction error encoding unit 103 to generate a prediction error signal, and the prediction error signal Is supplied to the adder 107. The addition unit 107 adds the prediction error signal supplied from the prediction error decoding unit 105 and the prediction signal supplied from the motion compensation unit 106 to generate a decoded image signal (S107), and the decoded image signal is stored in the frame memory. 110.

フレームメモリ110は、加算部107より供給される復号画像信号を記憶する(S108)。また、画像全体の復号が完了した復号画像については参照画像として、1以上の所定の画像数を記憶する。フレームメモリ110は、記憶した参照画像信号を動き補償部106および動き情報生成部109に供給する。参照画像を記憶する記憶領域はFIFO(First In First Out)方式で制御される。   The frame memory 110 stores the decoded image signal supplied from the adding unit 107 (S108). In addition, for a decoded image in which decoding of the entire image is completed, a predetermined number of images of 1 or more is stored as a reference image. The frame memory 110 supplies the stored reference image signal to the motion compensation unit 106 and the motion information generation unit 109. A storage area for storing the reference image is controlled by a FIFO (First In First Out) method.

動き情報メモリ111は、動き情報生成部109より供給される動き情報を最小の予測ブロックサイズ単位で所定の画像数、記憶する(S109)。処理対象の予測ブロックの隣接ブロックの動き情報を空間候補ブロック群とする。   The motion information memory 111 stores the motion information supplied from the motion information generation unit 109 for a predetermined number of images in units of the minimum predicted block size (S109). The motion information of the adjacent block of the prediction block to be processed is set as a space candidate block group.

また、動き情報メモリ111は、処理対象の予測ブロックと同一位置にあるColPic上のブロックとその周辺ブロックの動き情報を時間候補ブロック群とする。動き情報メモリ111は、空間候補ブロック群と時間候補ブロック群を候補ブロック群として動き情報生成部109に供給する。動き情報メモリ111は、フレームメモリ110と同期しており、FIFO(First In First Out)方式で制御される。   In addition, the motion information memory 111 sets the motion information of the block on the ColPic located in the same position as the prediction block to be processed and its neighboring blocks as a time candidate block group. The motion information memory 111 supplies the spatial candidate block group and the temporal candidate block group to the motion information generation unit 109 as candidate block groups. The motion information memory 111 is synchronized with the frame memory 110 and is controlled by a FIFO (First In First Out) method.

ここで、ColPicとは、処理対象の予測ブロックとは別の復号済みの画像であって、フレームメモリ110に参照画像として記憶されている画像を指す。実施の形態1では、ColPicは直前に復号した参照画像とする。なお、実施の形態1では、ColPicは直前に復号した参照画像としたが、符号化済みの画像であればよく、例えば、表示順で直前の参照画像や表示順で直後の参照画像でもよく、符号化ストリーム中で指定することも可能である。   Here, ColPic refers to a decoded image different from the prediction block to be processed and stored in the frame memory 110 as a reference image. In Embodiment 1, ColPic is a reference image decoded immediately before. In Embodiment 1, ColPic is a reference image decoded immediately before. However, it may be an encoded image, for example, a reference image immediately before in display order or a reference image immediately after in display order may be used. It can also be specified in the encoded stream.

ここで、動き情報メモリ111における動き情報の管理方法について図10を用いて説明する。動き情報は最小の予測ブロック単位で各メモリエリアに記憶される。図10は、処理対象の予測ブロックサイズが16画素×16画素である場合の様子を示している。この場合、この予測ブロックの動き情報は図10の斜線部の16個のメモリエリアに格納される。   Here, a method of managing motion information in the motion information memory 111 will be described with reference to FIG. The motion information is stored in each memory area in units of the smallest prediction block. FIG. 10 shows a state where the predicted block size to be processed is 16 pixels × 16 pixels. In this case, the motion information of the prediction block is stored in 16 memory areas indicated by hatching in FIG.

なお、予測符号化モードがイントラモードである場合、L0予測とL1予測の動きベクトルとして(0,0)が記憶され、L0予測とL予測の参照インデックスとして「−1」が記憶される。これ以降、動きベクトルの(H、V)は、Hが水平成分、Vが垂直成分を表すこととする。なお、参照インデックスの「−1」は動き補償予測を実施しないモードであることが判定できればどのような値でもよい。これ以降は特に断らない限り単にブロックと表現する場合には、最小の予測ブロック単位のことを示すこととする。また、領域外のブロックである場合もイントラモードと同様に、L0予測とL1予測の動きベクトルとして(0,0)が記憶され、L0予測とL1予測の参照インデックスとして「−1」が記憶される。LX方向(Xは0または1)が有効であるとはLX方向の参照インデックスが0以上であることで、LX方向が無効である(有効でない)とはLX方向の参照インデックスが「−1」であることである。   When the predictive coding mode is the intra mode, (0, 0) is stored as a motion vector for L0 prediction and L1 prediction, and “−1” is stored as a reference index for L0 prediction and L prediction. Hereinafter, in the motion vector (H, V), H represents a horizontal component and V represents a vertical component. The reference index “−1” may be any value as long as it can be determined that the mode in which motion compensation prediction is not performed. From this point onward, unless expressed otherwise, the term “block” refers to the smallest predicted block unit when expressed simply as a block. Also, in the case of a block outside the area, (0, 0) is stored as a motion vector for L0 prediction and L1 prediction, and “−1” is stored as a reference index for L0 prediction and L1 prediction, as in the intra mode. The When the LX direction (X is 0 or 1) is valid, the reference index in the LX direction is 0 or more, and when the LX direction is invalid (not valid), the reference index in the LX direction is “−1”. It is to be.

(動き情報生成部109の構成)
続いて、動き情報生成部109の詳細な構成について説明する。図11は、動き情報生成部109の構成を示す。動き情報生成部109は、予測ベクトルモード決定部120、マージモード決定部121および予測符号化モード決定部122を含む。端子12は動き情報メモリ111に、端子13は動きベクトル検出部108に、端子14はフレームメモリ110に、端子15は予測ブロック画像取得部101に、端子16は符号列生成部104に、端子50は動き補償部106に、および端子51は動き情報メモリ111にそれぞれ接続されている。
(Configuration of the motion information generation unit 109)
Next, a detailed configuration of the motion information generation unit 109 will be described. FIG. 11 shows the configuration of the motion information generation unit 109. The motion information generation unit 109 includes a prediction vector mode determination unit 120, a merge mode determination unit 121, and a prediction encoding mode determination unit 122. The terminal 12 is in the motion information memory 111, the terminal 13 is in the motion vector detection unit 108, the terminal 14 is in the frame memory 110, the terminal 15 is in the prediction block image acquisition unit 101, the terminal 16 is in the code string generation unit 104, and the terminal 50 Are connected to the motion compensation unit 106, and the terminal 51 is connected to the motion information memory 111, respectively.

(動き情報生成部109の動作)
以下、各部の機能と動作について説明する。図12は、動き情報生成部109の動作を説明するためのフローチャートである。予測ベクトルモード決定部120は、端子12より供給される候補ブロック群、端子13より供給されるL0予測とL1予測の動きベクトルおよびL0予測とL1予測の参照インデックス、端子14より供給される参照インデックスで示される参照画像、および端子15より供給される画像信号から、各予測符号化モード(予測ベクトルモードPredL0、PredL1、およびPredBi)から1つの予測符号化モードを決定し(S110)、レート歪み評価値を算出する。そして、予測符号化モードに基づいた動き情報、差分ベクトル、予測ベクトルインデックス、およびレート歪み評価値を予測符号化モード決定部122に供給する。予測ベクトルモード決定部120の詳細については後述する。
(Operation of the motion information generation unit 109)
Hereinafter, the function and operation of each unit will be described. FIG. 12 is a flowchart for explaining the operation of the motion information generation unit 109. The prediction vector mode determination unit 120 includes a candidate block group supplied from the terminal 12, a motion vector for L0 prediction and L1 prediction supplied from the terminal 13, a reference index for L0 prediction and L1 prediction, and a reference index supplied from the terminal 14. One prediction encoding mode is determined from each prediction encoding mode (prediction vector modes PredL0, PredL1, and PredBi) from the reference image indicated by (2) and the image signal supplied from the terminal 15 (S110), and rate distortion evaluation is performed. Calculate the value. Then, motion information, a difference vector, a prediction vector index, and a rate distortion evaluation value based on the prediction coding mode are supplied to the prediction coding mode determination unit 122. Details of the prediction vector mode determination unit 120 will be described later.

マージモード決定部121は、端子12より供給される候補ブロック群、端子14より供給される参照画像、および端子15より供給される画像信号から、結合動き情報候補リストを生成し、当該結合動き情報候補リストの中から1つの結合動き情報候補を選択してマージインデックスを決定し(S111)、レート歪み評価値を算出する。そして、当該結合動き情報候補の動き情報、当該マージインデックスおよび当該レート歪み評価値を予測符号化モード決定部122に供給する。マージモード決定部121の詳細については後述する。   The merge mode determination unit 121 generates a combined motion information candidate list from the candidate block group supplied from the terminal 12, the reference image supplied from the terminal 14, and the image signal supplied from the terminal 15, and the combined motion information One merged motion information candidate is selected from the candidate list to determine a merge index (S111), and a rate distortion evaluation value is calculated. Then, the motion information of the combined motion information candidate, the merge index, and the rate distortion evaluation value are supplied to the predictive coding mode determination unit 122. Details of the merge mode determination unit 121 will be described later.

予測符号化モード決定部122は、予測ベクトルモード決定部120より供給されるレート歪み評価値と、マージモード決定部121より供給されるレート歪み評価値とを比較してマージフラグを決定する(S112)。   The predictive coding mode determination unit 122 compares the rate distortion evaluation value supplied from the prediction vector mode determination unit 120 with the rate distortion evaluation value supplied from the merge mode determination unit 121 to determine a merge flag (S112). ).

前者が後者未満の場合は、マージフラグを「0」に設定する。予測符号化モード決定部122は、当該マージフラグ、各予測符号化モードに基づく動き補償予測の予測方向、予測ベクトルモード決定部120より供給される参照インデックス、差分ベクトルと予測ベクトルインデックスを端子16に供給し、予測ベクトルモード決定部120より供給される動き情報を端子50および端子51に供給する。   If the former is less than the latter, the merge flag is set to “0”. The prediction coding mode determination unit 122 inputs the merge flag, the prediction direction of motion compensation prediction based on each prediction coding mode, the reference index supplied from the prediction vector mode determination unit 120, the difference vector, and the prediction vector index to the terminal 16. The motion information supplied from the prediction vector mode determination unit 120 is supplied to the terminal 50 and the terminal 51.

後者が前者以下の場合は、マージフラグを「1」に設定する。予測符号化モード決定部122は、当該マージフラグおよびマージモード決定部121より供給されるマージインデックスを端子16に供給し、マージモード決定部121より供給される動き情報を端子50および端子51に供給する。なお、レート歪み評価値の具体的な算出方法は本発明の主眼ではないため詳細は省略するが、レート歪み評価値が小さいほど符号化効率は高くなる特性を持つ評価値である。   If the latter is less than or equal to the former, the merge flag is set to “1”. The predictive coding mode determination unit 122 supplies the merge flag and the merge index supplied from the merge mode determination unit 121 to the terminal 16, and supplies the motion information supplied from the merge mode determination unit 121 to the terminal 50 and the terminal 51. To do. Although a specific calculation method of the rate distortion evaluation value is not the main point of the present invention, the details thereof will be omitted. However, the evaluation value has a characteristic that the encoding efficiency increases as the rate distortion evaluation value decreases.

(予測ベクトルモード決定部120の構成)
続いて、予測ベクトルモード決定部120の詳細な構成について説明する。図13は、予測ベクトルモード決定部120の構成を示す。予測ベクトルモード決定部120は、予測ベクトル候補リスト生成部130、予測ベクトル決定部131および減算部132を含む。端子17は予測符号化モード決定部122に接続されている。
(Configuration of Predictive Vector Mode Determination Unit 120)
Subsequently, a detailed configuration of the prediction vector mode determination unit 120 will be described. FIG. 13 shows the configuration of the prediction vector mode determination unit 120. The prediction vector mode determination unit 120 includes a prediction vector candidate list generation unit 130, a prediction vector determination unit 131, and a subtraction unit 132. The terminal 17 is connected to the predictive coding mode determination unit 122.

予測ベクトル候補リスト生成部130は、実施の形態1に係る動画像符号化装置100により生成された符号列を復号する動画像復号装置200にも同様に設置されて、動画像符号化装置100と動画像復号装置200にて矛盾のない予測ベクトル候補リストが生成される。   The prediction vector candidate list generation unit 130 is also installed in the video decoding apparatus 200 that decodes the code sequence generated by the video encoding apparatus 100 according to Embodiment 1 in the same manner as the video encoding apparatus 100. The motion picture decoding apparatus 200 generates a prediction vector candidate list having no contradiction.

(予測ベクトルモード決定部120の動作)
以下、各部の機能と動作について説明する。図14は、予測ベクトルモード決定部120の動作を説明するためのフローチャートである。
(Operation of prediction vector mode determination unit 120)
Hereinafter, the function and operation of each unit will be described. FIG. 14 is a flowchart for explaining the operation of the prediction vector mode determination unit 120.

予測ベクトル候補リスト生成部130は、端子12より供給される候補ブロック群から予測ベクトル候補最大数の予測ベクトル候補を含むL0予測の予測ベクトル候補リストを生成する(S120)。予測ベクトル候補リスト生成部130は、当該L0予測の予測ベクトル候補リストを予測ベクトル決定部131に供給する。   The prediction vector candidate list generation unit 130 generates a prediction vector candidate list for L0 prediction including the maximum number of prediction vector candidates from the candidate block group supplied from the terminal 12 (S120). The prediction vector candidate list generation unit 130 supplies the prediction vector candidate list for the L0 prediction to the prediction vector determination unit 131.

予測ベクトル決定部131は、予測ベクトル候補リスト生成部130より供給されるL0予測の予測ベクトル候補リストから1つの予測ベクトル候補をL0予測の予測ベクトルとして選択して、L0予測の予測ベクトルインデックを決定し(S121)、当該L0予測の予測ベクトルを減算部132に供給する。   The prediction vector determination unit 131 selects one prediction vector candidate as a prediction vector for L0 prediction from the prediction vector candidate list for L0 prediction supplied from the prediction vector candidate list generation unit 130, and determines a prediction vector index for L0 prediction. Then, the prediction vector of the L0 prediction is supplied to the subtraction unit 132 (S121).

減算部132は、端子13より供給されるL0予測の動きベクトルから予測ベクトル決定部131より供給されるL0予測の予測ベクトルを減算してL0予測の差分ベクトルを算出し(S122)、当該L0予測の差分ベクトルを予測ベクトル決定部131に供給する。   The subtraction unit 132 subtracts the L0 prediction prediction vector supplied from the prediction vector determination unit 131 from the L0 prediction motion vector supplied from the terminal 13 to calculate an L0 prediction difference vector (S122). Are supplied to the prediction vector determination unit 131.

予測ベクトル決定部131は、端子15より供給される画像信号と、端子14より供給される参照画像を端子13より供給されるL0予測の動きベクトルおよびL0予測の参照インデックスに基づいて動き補償予測したL0予測の予測信号とから予測誤差量を算出し、当該予測誤差量と、L0予測の差分ベクトル、L0予測の参照インデックス、およびL0予測の予測ベクトルインデックスの符号量とからPred_L0のレート歪評価値を算出する(S123)。   The prediction vector determination unit 131 motion-predicted the image signal supplied from the terminal 15 and the reference image supplied from the terminal 14 based on the L0 prediction motion vector and the L0 prediction reference index supplied from the terminal 13. Pred_L0 rate distortion evaluation value is calculated from the prediction error amount from the prediction signal of the L0 prediction, and from the prediction error amount, the difference vector of the L0 prediction, the reference index of the L0 prediction, and the code amount of the prediction vector index of the L0 prediction Is calculated (S123).

予測ベクトル候補リスト生成部130は、端子12より供給される候補ブロック群から予測ベクトル候補最大数の予測ベクトル候補を含むL1予測の予測ベクトル候補リストを生成する(S124)。予測ベクトル候補リスト生成部130は、当該L1予測の予測ベクトル候補リストを予測ベクトル決定部131に供給する。   The prediction vector candidate list generation unit 130 generates a prediction vector candidate list for L1 prediction including the maximum number of prediction vector candidates from the candidate block group supplied from the terminal 12 (S124). The prediction vector candidate list generation unit 130 supplies the prediction vector candidate list for the L1 prediction to the prediction vector determination unit 131.

予測ベクトル決定部131は、予測ベクトル候補リスト生成部130より供給されるL1予測の予測ベクトル候補リストから1つの予測ベクトル候補をL1予測の予測ベクトルとして選択してL1予測の予測ベクトルインデックを決定し(S125)、当該L1予測の予測ベクトルを減算部132に供給する。   The prediction vector determination unit 131 selects one prediction vector candidate from the prediction vector candidate list for L1 prediction supplied from the prediction vector candidate list generation unit 130 as a prediction vector for L1 prediction, and determines a prediction vector index for L1 prediction. (S125), the prediction vector of the L1 prediction is supplied to the subtraction unit 132.

減算部132は、端子13より供給されるL1予測の動きベクトルから予測ベクトル決定部131より供給されるL1予測の予測ベクトルを減算してL1予測の差分ベクトルを算出し(S126)、当該L1予測の差分ベクトルを予測ベクトル決定部131に供給する。   The subtraction unit 132 subtracts the L1 prediction prediction vector supplied from the prediction vector determination unit 131 from the L1 prediction motion vector supplied from the terminal 13 to calculate an L1 prediction difference vector (S126). Are supplied to the prediction vector determination unit 131.

予測ベクトル決定部131は、端子15より供給される画像信号と、端子14より供給される参照画像を端子13より供給されるL1予測の動きベクトル及びL1予測の参照インデックスに基づいて動き補償予測したL1予測の予測信号とから予測誤差量を算出し、当該予測誤差量と、L1予測の差分ベクトル、L1予測の参照インデックス、およびL1予測の予測ベクトルインデックスの符号量とからPred_L1のレート歪評価値を算出する(S127)。   The prediction vector determination unit 131 motion-predicted the image signal supplied from the terminal 15 and the reference image supplied from the terminal 14 based on the L1 prediction motion vector and the L1 prediction reference index supplied from the terminal 13. Pred_L1 rate distortion evaluation value is calculated from the prediction error amount from the prediction signal of the L1 prediction, and the prediction error amount, the difference vector of the L1 prediction, the reference index of the L1 prediction, and the code amount of the prediction vector index of the L1 prediction Is calculated (S127).

予測ベクトル決定部131は、端子15より供給される画像信号と、L0予測の予測信号およびL1予測の予測信号を平均したBI予測の予測信号とから予測誤差量を算出し、当該予測誤差量と、L0予測とL1予測の差分ベクトル、L0予測とL1予測の参照インデックス、およびL0予測とL1予測の予測ベクトルインデックスの符号量とからPred_BIのレート歪評価値を算出する(S128)。   The prediction vector determination unit 131 calculates a prediction error amount from the image signal supplied from the terminal 15 and the prediction signal of BI prediction obtained by averaging the prediction signal of L0 prediction and the prediction signal of L1 prediction, and the prediction error amount The Pred_BI rate distortion evaluation value is calculated from the difference vector between the L0 prediction and the L1 prediction, the reference index of the L0 prediction and the L1 prediction, and the code amount of the prediction vector index of the L0 prediction and the L1 prediction (S128).

予測ベクトル決定部131は、Pred_L0のレート歪評価値、Pred_L1のレート歪評価値、およびPred_BIのレート歪評価値を比較して、最小のレート歪評価値である予測符号化モードを1つ選択する(S129)。そして、予測符号化モードに基づいた動き情報、差分ベクトル、予測ベクトルインデックス、およびレート歪み評価値を予測符号化モード決定部122に供給する。なお、予測符号化モードがPred_L0であれば、L1予測の動きベクトルは(0,0)、L1予測の参照インデックスは「−1」となり、予測符号化モードがPred_L1であれば、L0予測の動きベクトルは(0,0)、L0予測の参照インデックスは「−1」となる。   The prediction vector determination unit 131 compares the rate distortion evaluation value of Pred_L0, the rate distortion evaluation value of Pred_L1, and the rate distortion evaluation value of Pred_BI, and selects one prediction coding mode that is the minimum rate distortion evaluation value. (S129). Then, motion information, a difference vector, a prediction vector index, and a rate distortion evaluation value based on the prediction coding mode are supplied to the prediction coding mode determination unit 122. If the predictive coding mode is Pred_L0, the motion vector for L1 prediction is (0, 0), the reference index for L1 prediction is “−1”, and if the predictive coding mode is Pred_L1, the motion for L0 prediction. The vector is (0,0), and the reference index for L0 prediction is “−1”.

(予測ベクトル候補リスト生成部130に供給される候補ブロック群)
ここで、予測ベクトル候補リスト生成部130に供給される候補ブロック群について図15と図16を用いて説明する。候補ブロック群には空間候補ブロック群と時間候補ブロック群が含まれる。
(Candidate block group supplied to prediction vector candidate list generation unit 130)
Here, the candidate block group supplied to the prediction vector candidate list production | generation part 130 is demonstrated using FIG. 15 and FIG. The candidate block group includes a spatial candidate block group and a temporal candidate block group.

図15は、処理対象の予測ブロックサイズが16画素×16画素である場合の処理対象の予測ブロックの隣接ブロックを示す。実施の形態1では、空間候補ブロック群として、図15に示すブロックA1、ブロックC、ブロックD、ブロックB1およびブロックEの5ブロックとする。ここでは、空間候補ブロック群をブロックA1、ブロックC、ブロックD、ブロックB1およびブロックEの5ブロックとしたが、空間候補ブロック群は、処理対象の予測ブロックに隣接する少なくとも1以上の処理済みのブロックであればよく、これらに限定されない。例えば、ブロックA1、ブロックA2、ブロックA3、ブロックA4、ブロックB1、ブロックB2、ブロックB3、ブロックB4、ブロックC、ブロックDおよびブロックEの全てを空間候補ブロックとしてもよい。   FIG. 15 shows adjacent blocks of a prediction block to be processed when the prediction block size to be processed is 16 pixels × 16 pixels. In the first embodiment, the space candidate block group is assumed to be five blocks of block A1, block C, block D, block B1, and block E shown in FIG. Here, the spatial candidate block group is five blocks of block A1, block C, block D, block B1, and block E, but the spatial candidate block group is at least one or more processed adjacent to the prediction block to be processed. Any block may be used, and the present invention is not limited to these. For example, all of block A1, block A2, block A3, block A4, block B1, block B2, block B3, block B4, block C, block D, and block E may be spatial candidate blocks.

次に、時間候補ブロック群について図16を用いて説明する。図16は、処理対象の予測ブロックサイズが16画素×16画素である場合の処理対象の予測ブロックと同一位置にあるColPic上の予測ブロック内のブロックとその周辺ブロックを示す。実施の形態1では、時間候補ブロック群として、図16に示すブロックHとブロックI6の2ブロックとする。   Next, the time candidate block group will be described with reference to FIG. FIG. 16 shows a block in a prediction block on ColPic and its peripheral blocks at the same position as the prediction block to be processed when the prediction block size to be processed is 16 pixels × 16 pixels. In the first embodiment, the time candidate block group includes two blocks, block H and block I6 shown in FIG.

ここでは、時間候補ブロック群をColPic上のブロックHとブロックI6の2ブロックとしたが、時間候補ブロック群は、処理対象の予測ブロックとは別の復号済みの画像上の少なくとも1以上のブロックであればよく、これらに限定されない。例えば、ColPic上のブロックI1からブロックI16、ブロックA1からブロックA4、ブロックB1からブロックB4、ブロックC、ブロックD、ブロックE、ブロックF1からブロックF4、ブロックG1からブロックG4およびブロックHの全てを時間候補ブロックとしてもよい。また、ブロックHのみとしてもよい。以降特に断らない限り、ブロックA4をブロックA、ブロックB4をブロックBと表記する。以降特に断らない限り、ブロックHとブロックI6のブロックを時間ブロックと表記する。   Here, the time candidate block group is two blocks of block H and block I6 on ColPic, but the time candidate block group is at least one block on a decoded image different from the prediction block to be processed. There is no limitation to these. For example, all of block I1 to block I16, block A1 to block A4, block B1 to block B4, block C, block D, block E, block F1 to block F4, block G1 to block G4 and block H on ColPic It may be a candidate block. Further, only the block H may be used. Hereinafter, unless otherwise specified, block A4 is referred to as block A, and block B4 is referred to as block B. Hereinafter, unless otherwise specified, blocks H and I6 are referred to as time blocks.

(予測ベクトル候補リスト生成部130の構成)
続いて、予測ベクトル候補リスト生成部130の詳細な構成について説明する。図17は、予測ベクトル候補リスト生成部130の構成を説明するための図である。端子18は予測ベクトル決定部131に接続されている。予測ベクトル候補リスト生成部130は、空間予測ベクトル候補生成部150、時間予測ベクトル候補生成部151、空間スケーリング予測ベクトル候補生成部152、予測ベクトル候補補充部153、および予測ベクトル候補リスト確定部154を含む。
(Configuration of Predictive Vector Candidate List Generation Unit 130)
Next, a detailed configuration of the prediction vector candidate list generation unit 130 will be described. FIG. 17 is a diagram for explaining the configuration of the prediction vector candidate list generation unit 130. The terminal 18 is connected to the prediction vector determination unit 131. The prediction vector candidate list generation unit 130 includes a spatial prediction vector candidate generation unit 150, a temporal prediction vector candidate generation unit 151, a spatial scaling prediction vector candidate generation unit 152, a prediction vector candidate supplement unit 153, and a prediction vector candidate list determination unit 154. Including.

時間予測ベクトル候補生成部151と空間スケーリング予測ベクトル候補生成部152は、実施の形態1による結合動き情報候補リスト生成部140にも設置される。   The temporal prediction vector candidate generation unit 151 and the spatial scaling prediction vector candidate generation unit 152 are also installed in the combined motion information candidate list generation unit 140 according to the first embodiment.

(予測ベクトル候補リスト生成部130の動作)
以下、各部の機能と動作について説明する。図18は、予測ベクトル候補リスト生成部130の動作を説明するためのフローチャートである。空間予測ベクトル候補生成部150は、端子12より供給される候補ブロック群から空間予測ベクトル候補を0個から2個生成し(S140)、当該空間予測ベクトル候補を予測ベクトル候補リスト確定部154に供給する。空間予測ベクトル候補生成部150の詳細な動作については後述する。
(Operation of prediction vector candidate list generation unit 130)
Hereinafter, the function and operation of each unit will be described. FIG. 18 is a flowchart for explaining the operation of the prediction vector candidate list generation unit 130. The spatial prediction vector candidate generation unit 150 generates 0 to 2 spatial prediction vector candidates from the candidate block group supplied from the terminal 12 (S140), and supplies the spatial prediction vector candidates to the prediction vector candidate list determination unit 154. To do. The detailed operation of the spatial prediction vector candidate generation unit 150 will be described later.

時間予測ベクトル候補生成部151は、端子12より供給される候補ブロック群から時間予測ベクトル候補を0個または1個生成し(S141)、当該時間予測ベクトル候補を予測ベクトル候補リスト確定部154に供給する。時間予測ベクトル候補生成部151の詳細な動作については後述する。   The temporal prediction vector candidate generation unit 151 generates zero or one temporal prediction vector candidate from the candidate block group supplied from the terminal 12 (S141), and supplies the temporal prediction vector candidate to the prediction vector candidate list determination unit 154. To do. Detailed operation of the temporal prediction vector candidate generation unit 151 will be described later.

空間スケーリング予測ベクトル候補生成部152は、端子12より供給される候補ブロック群から空間スケーリング予測ベクトル候補を0個または1個生成し(S142)、当該空間スケーリング予測ベクトル候補を予測ベクトル候補リスト確定部154に供給する。空間スケーリング予測ベクトル候補生成部152の詳細な動作については後述する。   The spatial scaling prediction vector candidate generation unit 152 generates zero or one spatial scaling prediction vector candidate from the candidate block group supplied from the terminal 12 (S142), and the spatial scaling prediction vector candidate is a prediction vector candidate list determination unit. 154. The detailed operation of the spatial scaling prediction vector candidate generation unit 152 will be described later.

予測ベクトル候補リスト確定部154は、予測ベクトル候補最大数から空間予測ベクトル候補、時間予測ベクトル候補、および空間スケーリング予測ベクトル候補を合計した予測ベクトル候補数を減算して予測ベクトル補充候補数を算出し(S143)、当該予測ベクトル補充候補数を予測ベクトル候補補充部153に供給する。なお、算出された予測ベクトル補充候補数が0未満の場合には、予測ベクトル補充候補数は0とする。   The prediction vector candidate list determination unit 154 calculates the number of prediction vector supplements by subtracting the number of prediction vector candidates obtained by adding the spatial prediction vector candidates, temporal prediction vector candidates, and spatial scaling prediction vector candidates from the maximum number of prediction vector candidates. (S143) The prediction vector supplement candidate number is supplied to the prediction vector candidate supplement unit 153. Note that if the calculated number of prediction vector supplement candidates is less than zero, the number of prediction vector supplement candidates is zero.

予測ベクトル候補補充部153は、予測ベクトル候補リスト確定部154より供給される予測ベクトル補充候補数だけ予測ベクトル補充候補を生成し(S144)、当該予測ベクトル補充候補を予測ベクトル候補リスト確定部154に供給する。予測ベクトル補充候補は動きベクトル(0,0)とする。ここでは、予測ベクトル補充候補を動きベクトル(0,0)としたが、空間予測ベクトル候補、時間予測ベクトル候補、空間スケーリング予測ベクトル候補と異なる動きベクトルであればよく、これに限定されない。例えば、空間予測ベクトル候補の水平成分や垂直成分を+1や−1などした動きベクトルでもよい。   The prediction vector candidate supplementation unit 153 generates prediction vector supplementation candidates by the number of prediction vector supplementation candidates supplied from the prediction vector candidate list determination unit 154 (S144), and the prediction vector supplementation candidates are supplied to the prediction vector candidate list determination unit 154. Supply. The prediction vector supplement candidate is a motion vector (0, 0). Here, although the motion vector (0, 0) is used as the prediction vector supplement candidate, it may be a motion vector different from the spatial prediction vector candidate, temporal prediction vector candidate, and spatial scaling prediction vector candidate, and is not limited to this. For example, a motion vector in which the horizontal component and the vertical component of the spatial prediction vector candidate are +1 or −1 may be used.

予測ベクトル候補リスト確定部154は、予測ベクトル候補リストの予測ベクトル候補数が予測ベクトル候補最大数に達するまで、空間予測ベクトル候補、時間予測ベクトル候補、空間スケーリング予測ベクトル候補、予測ベクトル補充候補を順次、予測ベクトル候補リストに追加して予測ベクトル候補リストを確定する(S145)。予測ベクトル候補リストの確定の詳細な動作については後述する。   The prediction vector candidate list determination unit 154 sequentially selects the spatial prediction vector candidate, the temporal prediction vector candidate, the spatial scaling prediction vector candidate, and the prediction vector supplement candidate until the number of prediction vector candidates in the prediction vector candidate list reaches the maximum number of prediction vector candidates. Then, the prediction vector candidate list is confirmed by adding to the prediction vector candidate list (S145). The detailed operation for determining the prediction vector candidate list will be described later.

(空間予測ベクトル候補生成部150の詳細な動作)
引き続いて、空間予測ベクトル候補生成部150の詳細な動作について説明する。図19は、空間予測ベクトル候補生成部150の動作を説明するためのフローチャートである。空間予測ベクトル候補生成部150は、動き補償予測の予測方向が単予測であれば、L0予測またはL1予測の空間予測ベクトル候補を0個から2個生成し、動き補償予測の予測方向が双予測であれば、L0予測およびL1予測のそれぞれについて空間予測ベクトル候補を0個から2個生成する。以降、空間予測ベクトル候補を生成する対象の動き補償予測の予測方向をLXとして説明する(Xは0または1)。空間予測ベクトル候補生成部150は、端子12より供給される空間候補ブロック群に含まれる候補ブロックをブロックE、ブロックA1、ブロックC、ブロックB1、ブロックDの順に以下の処理を繰り返し行う(S150からS155)。ここでは、処理の順序をブロックE、ブロックA1、ブロックC、ブロックB1、ブロックDとしたが、空間候補ブロック群に含まれる候補ブロックが多くとも1回処理されればよく、これに限定されない。
(Detailed operation of spatial prediction vector candidate generation unit 150)
Subsequently, a detailed operation of the spatial prediction vector candidate generation unit 150 will be described. FIG. 19 is a flowchart for explaining the operation of the spatial prediction vector candidate generation unit 150. If the prediction direction of the motion compensation prediction is uni-prediction, the spatial prediction vector candidate generation unit 150 generates zero to two spatial prediction vector candidates for L0 prediction or L1 prediction, and the prediction direction of motion compensation prediction is bi-prediction. If so, 0 to 2 spatial prediction vector candidates are generated for each of the L0 prediction and the L1 prediction. Hereinafter, the prediction direction of motion compensated prediction of a target for generating a spatial prediction vector candidate will be described as LX (X is 0 or 1). The spatial prediction vector candidate generation unit 150 repeatedly performs the following processing in the order of block E, block A1, block C, block B1, and block D on candidate blocks included in the spatial candidate block group supplied from the terminal 12 (from S150). S155). Here, the processing order is block E, block A1, block C, block B1, and block D, but the candidate blocks included in the spatial candidate block group only need to be processed at most once, and the present invention is not limited to this.

候補ブロックのLX予測がスケーリング不要であるかどうか検査する(S151)。候補ブロックのLX予測がスケーリング不要であるとは候補ブロックのLX予測の参照インデックスが0以上であることである。候補ブロックのLX予測がスケーリング不要であれば(S151のY)、候補ブロックのLX予測の動きベクトルが既に決定された空間予測ベクトル候補と同一でないことを検査する(S152)。候補ブロックのLX予測がスケーリング不要でなければ(S151のN)、ステップS152からステップS154をスキップして次の候補ブロックを検査する(S155)。候補ブロックのLX予測の動きベクトルが既に決定された空間予測ベクトル候補と同一でなければ(S152のY)、候補ブロックのLX予測の動きベクトルを空間予測ベクトル候補として決定する(S153)。候補ブロックのLX予測の動きベクトルが既に決定された空間予測ベクトル候補と同一であれば(S152のN)、ステップS153とステップS154をスキップして次の候補ブロックを検査する(S155)。ステップS153に続いて、空間予測ベクトル候補数が所定数であるか検査する(S154)。ここでは、所定数を2とする。実施の形態1では、所定数を予測ベクトル候補最大数と同じ2としたが、所定数は1以上で空間候補ブロック群に含まれる候補ブロック数以下であればよく、これに限定されない。また、L0予測とL1予測の所定数を異なる値に設定することもできる。決定された空間予測ベクトル候補数が所定数でなければ(S154のN)、次の候補ブロックを検査する(S155)。決定された空間予測ベクトル候補数が所定数であれば(S154のY)、処理を終了する。   It is checked whether the LX prediction of the candidate block does not require scaling (S151). That the LX prediction of the candidate block does not require scaling means that the reference index of the LX prediction of the candidate block is 0 or more. If the LX prediction of the candidate block does not require scaling (Y in S151), it is checked that the LX prediction motion vector of the candidate block is not the same as the already determined spatial prediction vector candidate (S152). If the LX prediction of the candidate block does not require scaling (N in S151), step S152 to step S154 are skipped and the next candidate block is inspected (S155). If the motion vector of the LX prediction of the candidate block is not the same as the already determined spatial prediction vector candidate (Y in S152), the LX prediction motion vector of the candidate block is determined as a spatial prediction vector candidate (S153). If the motion vector of the LX prediction of the candidate block is the same as the determined spatial prediction vector candidate (N in S152), step S153 and step S154 are skipped and the next candidate block is examined (S155). Following step S153, it is checked whether the number of spatial prediction vector candidates is a predetermined number (S154). Here, the predetermined number is 2. In the first embodiment, the predetermined number is set to 2, which is the same as the maximum number of prediction vector candidates. However, the predetermined number may be 1 or more and the number of candidate blocks included in the spatial candidate block group, and is not limited thereto. Moreover, the predetermined number of L0 prediction and L1 prediction can also be set to a different value. If the determined number of spatial prediction vector candidates is not a predetermined number (N in S154), the next candidate block is examined (S155). If the determined number of spatial prediction vector candidates is a predetermined number (Y in S154), the process ends.

ここでは、候補ブロックのLX予測がスケーリング不要である条件を候補ブロックのLX予測の参照インデックスが0以上であることとしたが、スケーリング不要であればよく、これに限定されない。例えば、空間予測ベクトル候補の精度を向上させるために、端子13より供給される符号化対象ブロックのLX予測の参照インデックスを予測ベクトル候補リスト生成部130にも供給し、候補ブロックのLX予測の参照インデックスが0以上で且つ、当該符号化対象ブロックのLX予測の参照インデックスと候補ブロックのLX予測の参照インデックスが同一である場合などとしてもよい。空間予測ベクトル候補の生成ではスケーリング処理が不要であり、空間スケーリング予測ベクトル候補や時間予測ベクトル候補と比較して処理が簡易である。そのため、空間予測ベクトル候補の生成において、符号化対象ブロックのLX予測の参照インデックスを利用しても遅延時間を抑制することができる。また、ここでは、動き補償予測の予測方向がLX予測である空間予測ベクトル候補は、候補ブロックのLX予測の動きベクトルとなるようにしたが、スケーリング不要であればよく、これに限定されない。例えば、候補ブロックのLY予測の参照インデックスが0以上で且つ、当該符号化対象ブロックのLX予測の参照インデックスと候補ブロックのLY予測の参照インデックスが同一である場合に、候補ブロックのLY予測の動きベクトルが空間予測ベクトル候補となるようにしてもよい。   Here, the condition that the LX prediction of the candidate block does not need to be scaled is that the reference index of the LX prediction of the candidate block is 0 or more. However, the scaling is not limited to this as long as the scaling is unnecessary. For example, in order to improve the accuracy of the spatial prediction vector candidate, the LX prediction reference index of the encoding target block supplied from the terminal 13 is also supplied to the prediction vector candidate list generation unit 130 to refer to the LX prediction of the candidate block. For example, the index may be 0 or more, and the reference index for LX prediction of the current block and the reference index for LX prediction of the candidate block may be the same. The generation of the spatial prediction vector candidate does not require a scaling process, and the process is simple compared to the spatial scaling prediction vector candidate and the temporal prediction vector candidate. Therefore, in the generation of spatial prediction vector candidates, the delay time can be suppressed even when the LX prediction reference index of the encoding target block is used. In addition, here, the spatial prediction vector candidate whose prediction direction of motion compensation prediction is LX prediction is the motion vector of LX prediction of the candidate block, but it is sufficient that scaling is not necessary, and the present invention is not limited to this. For example, when the reference index of LY prediction of a candidate block is 0 or more and the reference index of LX prediction of the current block is the same as the reference index of LY prediction of the candidate block, the LY prediction motion of the candidate block The vector may be a spatial prediction vector candidate.

(時間予測ベクトル候補生成部151の構成)
続いて、時間予測ベクトル候補生成部151の詳細な構成について説明する。図20は、時間予測ベクトル候補生成部151の構成を説明するための図である。時間予測ベクトル候補生成部151は、基準ベクトル決定部170、参照インデックス設定部171、およびスケーリング部172を含む。端子20は予測ベクトル候補リスト確定部154に接続されている。
(Configuration of Temporal Prediction Vector Candidate Generation Unit 151)
Subsequently, a detailed configuration of the temporal prediction vector candidate generation unit 151 will be described. FIG. 20 is a diagram for explaining the configuration of the temporal prediction vector candidate generation unit 151. The temporal prediction vector candidate generation unit 151 includes a reference vector determination unit 170, a reference index setting unit 171, and a scaling unit 172. The terminal 20 is connected to the prediction vector candidate list determination unit 154.

(時間予測ベクトル候補生成部151の詳細な動作)
以下、各部の機能と動作について説明する。図21は、時間予測ベクトル候補生成部151の動作を説明するためのフローチャートである。時間予測ベクトル候補生成部151は、動き補償予測の予測方向が単予測であれば、L0予測またはL1予測の時間予測ベクトル候補を0個または1個生成し、動き補償予測の予測方向が双予測であれば、L0予測およびL1予測のそれぞれについて時間予測ベクトル候補を0個または1個生成する。以降、時間予測ベクトル候補を生成する対象の動き補償予測の予測方向をLXとして説明する(Xは0または1)。時間予測ベクトル候補生成部151は、端子12より供給される時間候補ブロック群に含まれる候補ブロックをブロックH、ブロックI6の順に以下の処理を繰り返し行う(S160からS166)。ここでは、処理の順序をブロックH、ブロックI6としたが、時間候補ブロック群に含まれる候補ブロックが1度処理されればよく、これに限定されない。
(Detailed operation of temporal prediction vector candidate generation unit 151)
Hereinafter, the function and operation of each unit will be described. FIG. 21 is a flowchart for explaining the operation of the temporal prediction vector candidate generation unit 151. If the prediction direction of the motion compensation prediction is a single prediction, the temporal prediction vector candidate generation unit 151 generates zero or one temporal prediction vector candidate for the L0 prediction or the L1 prediction, and the prediction direction of the motion compensation prediction is a bi-prediction. If so, zero or one temporal prediction vector candidate is generated for each of the L0 prediction and the L1 prediction. Hereinafter, the prediction direction of motion compensated prediction for generating a temporal prediction vector candidate is described as LX (X is 0 or 1). The temporal prediction vector candidate generation unit 151 repeatedly performs the following processing in the order of block H and block I6 on candidate blocks included in the temporal candidate block group supplied from the terminal 12 (S160 to S166). Here, the processing order is block H and block I6, but the candidate blocks included in the time candidate block group only need to be processed once, and the present invention is not limited to this.

候補ブロックが有効であるかどうか検査する(S161)。候補ブロックが有効であるとは候補ブロックのL0予測とL1予測の参照インデックスの少なくとも一方が0以上であることである。候補ブロックが有効であれば(S161のY)、基準ベクトル決定部170は、基準動きベクトルを決定する(S162)。候補ブロックが有効でなければ(S161のN)、ステップS162からステップS165をスキップして次の候補ブロックを検査する(S166)。   It is checked whether the candidate block is valid (S161). The candidate block is valid when at least one of the reference index of the L0 prediction and the L1 prediction of the candidate block is 0 or more. If the candidate block is valid (Y in S161), the reference vector determination unit 170 determines a reference motion vector (S162). If the candidate block is not valid (N in S161), step S162 to step S165 are skipped and the next candidate block is inspected (S166).

ここで、基準動きベクトルの決定について説明する。候補ブロックの動き補償予測の予測方向がL0予測もしくはL1予測の場合には、その動き補償予測の予測方向の動きベクトルを基準動きベクトルとして選択する。候補ブロックの動き補償予測の予測方向が双予測の場合には、L0予測或いはL1予測のいずれか一方の動きベクトルを基準動きベクトルとして選択する。例えば、候補ブロックのL0予測或いはL1予測のいずれかの動きベクトルが処理対象画像と交差する方を基準動きベクトルとして選択してもよいし、ColPicと同じ時間方向の動きベクトルを基準動きベクトルとして選択してもよいし、候補ブロックのL0予測或いはL1予測の参照画像のいずれかと、処理対象画像の距離が近い方の動きベクトルを基準動きベクトルとして選択してもよい。   Here, the determination of the reference motion vector will be described. When the prediction direction of the motion compensation prediction of the candidate block is L0 prediction or L1 prediction, the motion vector in the prediction direction of the motion compensation prediction is selected as the reference motion vector. When the prediction direction of the motion compensated prediction of the candidate block is bi-prediction, either the L0 prediction or the L1 prediction is selected as the reference motion vector. For example, the direction where the motion vector of either the L0 prediction or the L1 prediction of the candidate block intersects the processing target image may be selected as the reference motion vector, or the motion vector in the same time direction as ColPic is selected as the reference motion vector Alternatively, a motion vector that is closer to the processing target image than either the L0 prediction or the L1 prediction reference image of the candidate block may be selected as the reference motion vector.

ステップS162に続いて、参照インデックス設定部171は、LX予測の時間予測ベクトル候補を算出するための参照画像を示す参照インデックスを所定値Ref_idx_TScaleに設定する(S163)。所定値Ref_idx_TScaleは、空間候補ブロックであるブロックC、ブロックD、およびブロックEのLX予測において最も多く利用される参照インデックスとする。ここでは、Ref_idx_TScaleとして、空間候補ブロックであるブロックC、ブロックD、およびブロックEのLX予測において最も多く利用される参照インデックスとしたが、符号化ストリームに符号化する参照インデックスでなければよく、これに限定されない。例えば、0や1のような固定値としてもよく、空間候補ブロック群のいずれかの候補ブロック(例えば、ブロックE)において利用される参照インデックスとしてもよい。   Subsequent to step S162, the reference index setting unit 171 sets a reference index indicating a reference image for calculating a temporal prediction vector candidate for LX prediction to a predetermined value Ref_idx_TSscale (S163). The predetermined value Ref_idx_TSscale is a reference index that is most frequently used in LX prediction of block C, block D, and block E, which are spatial candidate blocks. Here, Ref_idx_TSscale is a reference index that is most frequently used in LX prediction of block C, block D, and block E, which are spatial candidate blocks. However, it may be a reference index that is not encoded into an encoded stream. It is not limited to. For example, a fixed value such as 0 or 1 may be used, or a reference index used in any candidate block (for example, block E) in the space candidate block group.

ステップS163に続いて、スケーリング部172は、基準動きベクトルをスケーリングした動きベクトルを時間予測ベクトル候補として決定する(S164)。ステップS164に続いて、決定された時間予測ベクトル候補数が所定数であるか検査する(S165)。ここでは、所定数を1とする。実施の形態1では、所定数を1としたが、所定数は1以上で時間候補ブロック群に含まれる候補ブロック数以下であればよく、これに限定されない。また、L0予測とL1予測の所定数を異なる値に設定することもできる。決定された時間予測ベクトル候補数が所定数でなければ(S165のN)、次の候補ブロックを検査する(S166)。決定された空間予測ベクトル候補数が所定数であれば(S165のY)、処理を終了する。   Subsequent to step S163, the scaling unit 172 determines a motion vector obtained by scaling the reference motion vector as a temporal prediction vector candidate (S164). Following step S164, it is checked whether the determined number of temporal prediction vector candidates is a predetermined number (S165). Here, the predetermined number is 1. In the first embodiment, the predetermined number is 1. However, the predetermined number may be 1 or more and not more than the number of candidate blocks included in the time candidate block group, and is not limited thereto. Moreover, the predetermined number of L0 prediction and L1 prediction can also be set to a different value. If the determined number of temporal prediction vector candidates is not a predetermined number (N in S165), the next candidate block is examined (S166). If the determined number of spatial prediction vector candidates is a predetermined number (Y in S165), the process ends.

ここで、基準動きベクトルをスケーリングして時間予測ベクトル候補を算出する方法について説明する。図22は、時間予測ベクトル候補の算出手法を説明するための図である。ColPicと基準動きベクトルの参照画像ColRefPicとの画像間距離をColDistとし、L0予測の時間予測ベクトル候補を算出するための参照画像RefPicL0と処理対象画像CurPicとの画像間距離をCurL0Dist、およびL1予測の時間予測ベクトル候補を算出するための参照画像RefPicL1と処理対象画像CurPicとの画像間距離をCurL1Distとする。   Here, a method for calculating a temporal prediction vector candidate by scaling the reference motion vector will be described. FIG. 22 is a diagram for explaining a method of calculating temporal prediction vector candidates. The inter-image distance between ColPic and the reference image ColRefPic of the standard motion vector is ColDist, and the inter-image distance between the reference image RefPicL0 and the processing target image CurPic for calculating the L0 prediction temporal prediction vector candidate is CurL0Dist and L1 prediction. The inter-image distance between the reference image RefPicL1 and the processing target image CurPic for calculating the temporal prediction vector candidate is assumed to be CurL1Dist.

下記式1に従って、mvColをColDistとCurL0Dist、CurL1Distの距離比率でスケーリングした動きベクトルを時間予測ベクトル候補とする。mvL0tはL0予測の時間予測ベクトル候補、mvL1tはL1予測の時間予測ベクトル候補である。ここで、画像間距離の算出はPOCを用いて行われ、正負の符号を有する。なお、除算は四捨五入で行われる。
mvL0t=mvCol×CurL0Dist/ColDist
mvL1t=mvCol×CurL1Dist/ColDist ・・・(式1)
A motion vector obtained by scaling mvCol with the distance ratio of ColDist, CurL0Dist, and CurL1Dist according to the following Equation 1 is set as a temporal prediction vector candidate. mvL0t is a temporal prediction vector candidate for L0 prediction, and mvL1t is a temporal prediction vector candidate for L1 prediction. Here, the calculation of the inter-image distance is performed using the POC, and has a positive and negative sign. Division is rounded off.
mvL0t = mvCol × CurL0Dist / ColDist
mvL1t = mvCol × CurL1Dist / ColDist (Formula 1)

なお、図22のColPic、ColRefPic、RefPicL0、およびRefPicL1の時間関係は一例であってこれ以外の時間関係であってもよい。   Note that the time relationships of ColPic, ColRefPic, RefPicL0, and RefPicL1 in FIG. 22 are merely examples, and other time relationships may be used.

以上のように、時間予測ベクトル候補を算出するための参照画像として、符号化ストリーム中に符号化する参照インデックスに依存しない参照画像を設定することで、復号側において、参照インデックスを復号する前、より具体的には予測ブロックサイズが決定した直後に時間予測ベクトル候補を生成することが可能となる。一方、従来の技術では、特にL1予測に関しては、マージフラグ、マージインデックス、インター予測モード、L0予測の参照インデックス、L0予測の差分ベクトル、L0予測の予測ベクトルインデックス、L1予測の参照インデックスを全て復号してからでなければ、時間予測ベクトル候補を生成することができなかった。さらに、これらシンタックス要素が可変長符号化を含む場合には、シンタックス要素の復号を並列処理することは困難であるため、L1予測の予測ベクトル候補の生成遅延を短縮することが困難であった。なお、動き補償予測において利用される参照画像は、符号化ストリーム中に符号化する参照インデックスで示される参照画像となる。   As described above, by setting a reference image that does not depend on the reference index to be encoded in the encoded stream as a reference image for calculating the temporal prediction vector candidate, before decoding the reference index on the decoding side, More specifically, a temporal prediction vector candidate can be generated immediately after the prediction block size is determined. On the other hand, in the related art, particularly for L1 prediction, all of the merge flag, merge index, inter prediction mode, L0 prediction reference index, L0 prediction difference vector, L0 prediction prediction vector index, and L1 prediction reference index are all decoded. Otherwise, the temporal prediction vector candidate could not be generated. Furthermore, when these syntax elements include variable-length coding, it is difficult to perform parallel decoding of the syntax elements, and thus it is difficult to reduce the generation delay of the prediction vector candidate for L1 prediction. It was. Note that the reference image used in motion compensation prediction is a reference image indicated by a reference index to be encoded in the encoded stream.

(空間スケーリング予測ベクトル候補生成部152の構成)
続いて、空間スケーリング予測ベクトル候補生成部152の詳細な構成について説明する。図23は、空間スケーリング予測ベクトル候補生成部152の構成を説明するための図である。空間スケーリング予測ベクトル候補生成部152は、基準ベクトル決定部175、参照インデックス設定部176、およびスケーリング部177を含む。
(Configuration of Spatial Scaling Prediction Vector Candidate Generation Unit 152)
Next, a detailed configuration of the spatial scaling prediction vector candidate generation unit 152 will be described. FIG. 23 is a diagram for explaining the configuration of the spatial scaling prediction vector candidate generation unit 152. The spatial scaling prediction vector candidate generation unit 152 includes a reference vector determination unit 175, a reference index setting unit 176, and a scaling unit 177.

(空間スケーリング予測ベクトル候補生成部152の詳細な動作)
引き続いて、空間スケーリング予測ベクトル候補生成部152の詳細な動作について説明する。図24は、空間スケーリング予測ベクトル候補生成部152の動作を説明するためのフローチャートである。空間スケーリング予測ベクトル候補生成部152は、動き補償予測の予測方向が単予測であれば、L0予測またはL1予測の空間スケーリング予測ベクトル候補を0個から1個生成し、動き補償予測の予測方向が双予測であれば、L0予測およびL1予測のそれぞれについて空間スケーリング予測ベクトル候補を0個から1個生成する。以降、空間スケーリング予測ベクトル候補を生成する対象の動き補償予測の予測方向をLXとして説明する(Xは0または1)。空間スケーリング予測ベクトル候補生成部152は、端子12より供給される空間候補ブロック群に含まれる候補ブロックをブロックA1、ブロックB1、ブロックC、ブロックE、ブロックDの順に以下の処理を繰り返し行う(S170からS176)。ここでは、処理の順序を後述する空間結合動き情報候補生成部160と同じ処理の順序であるブロックA1、ブロックB1、ブロックC、ブロックE、ブロックDとしたが、空間予測ベクトル候補生成部150の処理の順序と異なっていればよく、これに限定されない。例えば、空間予測ベクトル候補生成部150の処理の順序の逆順としてもよい。
(Detailed Operation of Spatial Scaling Prediction Vector Candidate Generation Unit 152)
Subsequently, a detailed operation of the spatial scaling prediction vector candidate generation unit 152 will be described. FIG. 24 is a flowchart for explaining the operation of the spatial scaling prediction vector candidate generation unit 152. If the prediction direction of motion compensation prediction is single prediction, the spatial scaling prediction vector candidate generation unit 152 generates one to zero spatial scaling prediction vector candidates for L0 prediction or L1 prediction, and the prediction direction of motion compensation prediction is In the case of bi-prediction, 0 to 1 spatial scaling prediction vector candidates are generated for each of the L0 prediction and the L1 prediction. Hereinafter, the prediction direction of motion compensated prediction for generating a spatial scaling prediction vector candidate will be described as LX (X is 0 or 1). The spatial scaling prediction vector candidate generation unit 152 repeatedly performs the following processing in the order of block A1, block B1, block C, block E, and block D on candidate blocks included in the spatial candidate block group supplied from the terminal 12 (S170). To S176). Here, the processing order is block A1, block B1, block C, block E, and block D, which are the same processing order as the spatially coupled motion information candidate generation unit 160 described later. The order of processing is not limited to this as long as it is different from the order of processing. For example, the order of processing of the spatial prediction vector candidate generation unit 150 may be reversed.

候補ブロックのLY予測がスケーリング必要であるかどうか検査する(S171)。Yは1−Xである。候補ブロックのLY予測がスケーリング必要であるとは候補ブロックのLY予測の参照インデックスが0以上であることである。候補ブロックのLY予測がスケーリング必要であれば(S171のY)、基準ベクトル決定部175は、基準動きベクトルを決定する(S172)。基準動きベクトルは候補ブロックのLY予測の動きベクトルとする。候補ブロックがスケーリング必要でなければ(S171のN)、ステップS172からステップS175をスキップして次の候補ブロックを検査する(S176)。   It is checked whether the LY prediction of the candidate block needs to be scaled (S171). Y is 1-X. That the LY prediction of the candidate block needs to be scaled means that the reference index of the LY prediction of the candidate block is 0 or more. If the LY prediction of the candidate block requires scaling (Y in S171), the reference vector determination unit 175 determines a reference motion vector (S172). The reference motion vector is a motion vector for LY prediction of the candidate block. If the candidate block does not need scaling (N of S171), the process skips Steps S172 to S175 and inspects the next candidate block (S176).

ステップS172に続いて、参照インデックス設定部176は、LX予測の空間予測ベクトル候補を算出するための参照画像を示す参照インデックスを所定値Ref_idx_SScaleに設定する(S173)。所定値Ref_idx_SScaleは、空間候補ブロックであるブロックC、ブロックD、およびブロックEのLX予測において最も多く利用される参照インデックスとする。ここでは、Ref_idx_SScaleとして、空間候補ブロックであるブロックC、ブロックD、およびブロックEのLX予測において最も多く利用される参照インデックスとしたが、符号化ストリームに符号化する参照インデックスでなければよく、これに限定されない。例えば、0や1のような固定値としてもよく、空間候補ブロック群のいずれかの候補ブロック(例えば、ブロックE)において利用される参照インデックスとしてもよい。   Subsequent to step S172, the reference index setting unit 176 sets a reference index indicating a reference image for calculating a spatial prediction vector candidate for LX prediction to a predetermined value Ref_idx_SSscale (S173). The predetermined value Ref_idx_SSscale is a reference index that is most frequently used in LX prediction of block C, block D, and block E, which are spatial candidate blocks. Here, as Ref_idx_SSscale, a reference index that is most frequently used in LX prediction of block C, block D, and block E, which are spatial candidate blocks, may be a reference index that is not encoded into an encoded stream. It is not limited to. For example, a fixed value such as 0 or 1 may be used, or a reference index used in any candidate block (for example, block E) in the space candidate block group.

ステップS173に続いて、スケーリング部177は、基準動きベクトルをスケーリングした動きベクトルを空間スケーリング予測ベクトル候補として決定する(S174)。ステップS174に続いて、決定された空間スケーリング予測ベクトル候補数が所定数であるか検査する(S175)。ここでは、所定数を1とする。実施の形態1では、所定数を1としたが、所定数は1以上で空間候補ブロック群に含まれる候補ブロック数以下であればよく、これに限定されない。また、L0予測とL1予測の所定数を異なる値に設定することもできる。決定された空間スケーリング予測ベクトル候補数が所定数でなければ(S175のN)、次の候補ブロックを検査する(S176)。決定された空間スケーリング予測ベクトル候補数が所定数であれば(S175のY)、処理を終了する。   Subsequent to step S173, the scaling unit 177 determines a motion vector obtained by scaling the reference motion vector as a spatial scaling prediction vector candidate (S174). Following step S174, it is checked whether the determined number of spatial scaling prediction vector candidates is a predetermined number (S175). Here, the predetermined number is 1. In Embodiment 1, the predetermined number is 1. However, the predetermined number may be 1 or more and not more than the number of candidate blocks included in the spatial candidate block group, and is not limited thereto. Moreover, the predetermined number of L0 prediction and L1 prediction can also be set to a different value. If the determined number of spatial scaling prediction vector candidates is not a predetermined number (N in S175), the next candidate block is inspected (S176). If the determined number of spatial scaling prediction vector candidates is a predetermined number (Y in S175), the process ends.

ここでは、動き補償予測の予測方向がLX予測である空間スケーリング予測ベクトル候補は、候補ブロックのLY予測の動きベクトルが基準動きベクトルとなるようにしたが、基準ベクトルを決定できればよく、これに限定されない。例えば、候補ブロックのLX予測の動きベクトルが基準動きベクトルとなるようにしてもよい。   Here, the spatial scaling prediction vector candidate whose prediction direction of motion compensation prediction is LX prediction is such that the motion vector of LY prediction of the candidate block becomes the reference motion vector, but it is only necessary to be able to determine the reference vector. Not. For example, the LX prediction motion vector of the candidate block may be the reference motion vector.

ここで、基準動きベクトルをスケーリングして空間スケーリング予測ベクトル候補を算出する方法について説明する。図25は、空間スケーリング予測ベクトル候補の算出手法を説明するための図である。L0予測の基準動きベクトルmvL0bの参照画像RefPicL0bと処理対象画像CurPicとの画像間距離をcurL0bDist、L0予測の空間スケーリング予測ベクトル候補を算出するための参照画像RefPicL0sと処理対象画像CurPicとの画像間距離をCurL0sDistとし、L1予測の基準動きベクトルmvL1bの参照画像RefPicL1bと処理対象画像CurPicとの画像間距離をcurL1bDist、L1予測の空間スケーリング予測ベクトル候補を算出するための参照画像RefPicL1sと処理対象画像CurPicとの画像間距離をCurL1sDistとする。   Here, a method for scaling the reference motion vector and calculating a spatial scaling prediction vector candidate will be described. FIG. 25 is a diagram for explaining a method of calculating a spatial scaling prediction vector candidate. The inter-image distance between the reference image RefPicL0b of the base motion vector mvL0b for L0 prediction and the processing target image CurPic is curL0bDist, and the inter-image distance between the reference image RefPicL0s and the processing target image CurPic for calculating a spatial scaling prediction vector candidate for L0 prediction Is CurL0sDist, the inter-image distance between the reference image RefPicL1b of the base motion vector mvL1b of L1 prediction and the processing target image CurPic is curL1bDist, the reference image RefPicL1s and the processing target image CurPic for calculating the spatial scaling prediction vector candidate of L1 prediction The inter-image distance is CurL1sDist.

下記式2に従って、mvL0bをcurL0bDistとCurL0sDistとの距離比率でスケーリングした動きベクトルmvL0sを、L0予測の空間スケーリング予測ベクトル候補とし、mvL1bをcurL1bDistとCurL1sDistとの距離比率でスケーリングした動きベクトルmvL1sを、L1予測の空間スケーリング予測ベクトル候補とする。ここで、画像間距離の算出はPOCを用いて行われ、正負の符号を有する。なお、除算は四捨五入で行われる。
mvL0s=mvL0b×CurL0sDist/CurL0bDist
mvL1s=mvL1b×CurL1sDist/CurL1bDist ・・・(式2)
A motion vector mvL0s obtained by scaling mvL0b with a distance ratio between curL0bDist and CurL0sDist is set as a spatial scaling prediction vector candidate for L0 prediction, and mvL1b is scaled with a distance ratio between curL1bDist and CurL1sDist according to Equation 2 below. Let it be a spatial scaling prediction vector candidate for prediction. Here, the calculation of the inter-image distance is performed using the POC, and has a positive and negative sign. Division is rounded off.
mvL0s = mvL0b × CurL0sDist / CurL0bDist
mvL1s = mvL1b × CurL1sDist / CurL1bDist (Expression 2)

なお、図25のCurPic、RefPicL0b、RefPicL0s、RefPicL1b、およびRefPicL1sの時間関係は一例であってこれ以外の時間関係であってもよい。   Note that the time relationship among CurPic, RefPicL0b, RefPicL0s, RefPicL1b, and RefPicL1s in FIG. 25 is an example, and other time relationships may be used.

以上のように、空間スケーリング予測ベクトル候補を算出するための参照画像として、符号化ストリーム中に符号化する参照インデックスに依存しない参照画像を設定することで、復号側において、参照インデックスを復号する前、より具体的には予測ブロックサイズが決定した直後に空間スケーリング予測ベクトル候補を生成することが可能となる。一方、従来の技術では、特にL1予測に関しては、マージフラグ、マージインデックス、インター予測モード、L0予測の参照インデックス、L0予測の差分ベクトル、L0予測の予測ベクトルインデックス、L1予測の参照インデックスを全て復号してからでなければ、空間予測ベクトル候補を生成することができなかった。さらに、これらシンタックス要素が可変長符号化を含む場合には、シンタックス要素の復号を並列処理することは困難であるため、L1予測の予測ベクトル候補の生成遅延を短縮することが困難であった。なお、動き補償予測において利用される参照画像は、符号化ストリーム中に符号化する参照インデックスで示される参照画像となる。   As described above, by setting a reference image that does not depend on a reference index to be encoded in the encoded stream as a reference image for calculating a spatial scaling prediction vector candidate, before decoding the reference index on the decoding side More specifically, it is possible to generate a spatial scaling prediction vector candidate immediately after the prediction block size is determined. On the other hand, in the related art, particularly for L1 prediction, all of the merge flag, merge index, inter prediction mode, L0 prediction reference index, L0 prediction difference vector, L0 prediction prediction vector index, and L1 prediction reference index are all decoded. Otherwise, the spatial prediction vector candidate could not be generated. Furthermore, when these syntax elements include variable-length coding, it is difficult to perform parallel decoding of the syntax elements, and thus it is difficult to reduce the generation delay of the prediction vector candidate for L1 prediction. It was. Note that the reference image used in motion compensation prediction is a reference image indicated by a reference index to be encoded in the encoded stream.

以上のように、空間予測ベクトル候補生成部150の候補ブロックの処理順序と空間スケーリング予測ベクトル候補生成部152の候補ブロックの処理順序を異なる順序とすることで、空間スケーリング予測ベクトル候補の対象となる候補ブロックが、空間予測ベクトル候補の対象となる候補ブロックとは異なる候補ブロックとなる確率を上げることできる。そのため、例えば、等速運動しているような動画像で、予測方向が双方向である候補ブロックのL0予測とL1予測の動きベクトルが対称性を有するような場合に、空間スケーリング予測ベクトル候補と空間予測ベクトル候補が重複するのを回避して空間スケーリング予測ベクトル候補の有効性を高めることができる。一方、従来の技術では、空間予測ベクトル候補生成部150の候補ブロックの処理順序と空間スケーリング予測ベクトル候補生成部152の候補ブロックの処理順序を同一とし、空間予測ベクトル候補を空間予測ベクトル候補の代替候補として利用している。そのため一般的な動画像に見られるような等速運動の場合に、空間スケーリング予測ベクトル候補は空間予測ベクトル候補と重複する可能性があるため、図19のステップS152を設置するなどして、空間スケーリング予測ベクトル候補と空間予測ベクトル候補が重複するのを回避する必要があった。   As described above, the processing order of the candidate blocks of the spatial prediction vector candidate generation unit 150 and the processing order of the candidate blocks of the spatial scaling prediction vector candidate generation unit 152 are different from each other, so that it becomes a target of the spatial scaling prediction vector candidate. The probability that the candidate block becomes a candidate block different from the candidate block that is the target of the spatial prediction vector candidate can be increased. Therefore, for example, in the case of a moving image that is moving at a constant speed and the motion vectors of the L0 prediction and the L1 prediction of a candidate block whose prediction directions are bidirectional are symmetrical, the spatial scaling prediction vector candidate and It is possible to avoid the overlap of the spatial prediction vector candidates and to increase the effectiveness of the spatial scaling prediction vector candidates. On the other hand, in the conventional technique, the processing order of candidate blocks in the spatial prediction vector candidate generation unit 150 and the processing order of candidate blocks in the spatial scaling prediction vector candidate generation unit 152 are the same, and the spatial prediction vector candidate is substituted for the spatial prediction vector candidate. It is used as a candidate. Therefore, in the case of constant velocity motion as seen in a general moving image, the spatial scaling prediction vector candidate may overlap with the spatial prediction vector candidate. Therefore, by installing step S152 in FIG. It was necessary to avoid the overlap of the scaling prediction vector candidate and the spatial prediction vector candidate.

(予測ベクトル候補リストの確定の詳細な動作)
引き続いて、予測ベクトル候補リストの確定の詳細な動作について説明する。図26は、予測ベクトル候補リストの確定の動作を説明するためのフローチャートである。予測ベクトル候補リスト確定部154は、空間予測ベクトル候補を予測ベクトル候補リストに追加する(S180)。予測ベクトル候補リストの予測ベクトル候補数が予測ベクトル候補最大数であるか検査する(S181)。予測ベクトル候補リストの予測ベクトル候補数が予測ベクトル候補最大数であれば(S181のY)、予測ベクトル候補リストを確定し、ステップS182からステップS188をスキップして処理を終了する。予測ベクトル候補リストの予測ベクトル候補数が予測ベクトル候補最大数でなければ(S181のN)、時間予測ベクトル候補を予測ベクトル候補リストに追加する(S182)。ステップS182に続いて、予測ベクトル候補リストに同一の予測ベクトル候補が複数存在するか検査し、複数存在する場合には最初の予測ベクトル候補を残して残りを削除する(S183)。
(Detailed operation for determining the prediction vector candidate list)
Subsequently, a detailed operation for determining the prediction vector candidate list will be described. FIG. 26 is a flowchart for explaining the operation of determining the prediction vector candidate list. The prediction vector candidate list determination unit 154 adds the spatial prediction vector candidate to the prediction vector candidate list (S180). It is checked whether the number of prediction vector candidates in the prediction vector candidate list is the maximum number of prediction vector candidates (S181). If the number of prediction vector candidates in the prediction vector candidate list is the maximum number of prediction vector candidates (Y in S181), the prediction vector candidate list is confirmed, and the process is terminated by skipping steps S182 to S188. If the number of prediction vector candidates in the prediction vector candidate list is not the maximum number of prediction vector candidates (N in S181), the temporal prediction vector candidate is added to the prediction vector candidate list (S182). Subsequent to step S182, it is checked whether or not there are a plurality of identical prediction vector candidates in the prediction vector candidate list. If there are a plurality of prediction vector candidates, the first prediction vector candidate is left and the rest is deleted (S183).

ステップS183に続いて、予測ベクトル候補リストの予測ベクトル候補数が予測ベクトル候補最大数であるか検査する(S184)。予測ベクトル候補リストの予測ベクトル候補数が予測ベクトル候補最大数であれば(S184のY)、予測ベクトル候補リストを確定し、ステップS185からステップS188をスキップして処理を終了する。予測ベクトル候補リストの予測ベクトル候補数が予測ベクトル候補最大数でなければ(S184のN)、空間スケーリング予測ベクトル候補を予測ベクトル候補リストに追加する(S185)。ステップS185に続いて、予測ベクトル候補リストに同一の予測ベクトル候補が複数存在するか検査し、複数存在する場合には最初の予測ベクトル候補を残して残りを削除する(S186)。   Following step S183, it is checked whether the number of prediction vector candidates in the prediction vector candidate list is the maximum number of prediction vector candidates (S184). If the number of prediction vector candidates in the prediction vector candidate list is the maximum number of prediction vector candidates (Y in S184), the prediction vector candidate list is confirmed, and the process is terminated by skipping steps S185 to S188. If the number of prediction vector candidates in the prediction vector candidate list is not the maximum number of prediction vector candidates (N in S184), the spatial scaling prediction vector candidate is added to the prediction vector candidate list (S185). Following step S185, it is checked whether there are a plurality of identical prediction vector candidates in the prediction vector candidate list. If there are a plurality of prediction vector candidates, the first prediction vector candidate is left and the rest is deleted (S186).

ステップS186に続いて、予測ベクトル候補リストの予測ベクトル候補数が予測ベクトル候補最大数であるか検査する(S187)。予測ベクトル候補リストの予測ベクトル候補数が予測ベクトル候補最大数であれば(S187のY)、予測ベクトル候補リストを確定し、ステップS188をスキップして処理を終了する。予測ベクトル候補リストの予測ベクトル候補数が予測ベクトル候補最大数でなければ(S187のN)、予測ベクトル補充候補を予測ベクトル候補リストに追加して(S188)、予測ベクトル候補リストを確定して処理を終了する。   Following step S186, it is checked whether the number of prediction vector candidates in the prediction vector candidate list is the maximum number of prediction vector candidates (S187). If the number of prediction vector candidates in the prediction vector candidate list is the maximum number of prediction vector candidates (Y in S187), the prediction vector candidate list is confirmed, and step S188 is skipped and the process is terminated. If the number of prediction vector candidates in the prediction vector candidate list is not the maximum number of prediction vector candidates (N in S187), the prediction vector supplement candidate is added to the prediction vector candidate list (S188), and the prediction vector candidate list is confirmed and processed. Exit.

一般的に空間予測ベクトル候補が有効となるのは、処理対象ブロックと空間候補ブロックが同じ動きをしている場合である。また、時間予測ベクトル候補が有効となるのは、処理対象ブロックと時間候補ブロックが静止状態に近い状態にある場合である。なお、空間スケーリング予測ベクトル候補が有効となるのは、予測方向が反対の動きベクトルの精度が高い場合に限られる。よって、一般的な動画像においては、予測ベクトル候補として信頼度の高い順序は空間予測ベクトル候補、時間予測ベクトル候補、空間スケーリング予測ベクトル候補、予測ベクトル補充候補の順となる。ところが、従来の技術では、空間予測ベクトル候補と空間スケーリング予測ベクトル候補に依存関係があるため、空間予測ベクトル候補と空間スケーリング予測ベクトル候補の順序が順不同になっていた。   In general, a spatial prediction vector candidate is valid when the processing target block and the spatial candidate block are moving in the same manner. The temporal prediction vector candidate is valid when the processing target block and the temporal candidate block are in a state close to a stationary state. The spatial scaling prediction vector candidate is effective only when the accuracy of the motion vector having the opposite prediction direction is high. Therefore, in a general moving image, the order of high reliability as a prediction vector candidate is the order of a spatial prediction vector candidate, a temporal prediction vector candidate, a spatial scaling prediction vector candidate, and a prediction vector supplement candidate. However, in the conventional technique, since the spatial prediction vector candidate and the spatial scaling prediction vector candidate have a dependency, the order of the spatial prediction vector candidate and the spatial scaling prediction vector candidate is out of order.

以上のように、空間予測ベクトル候補と空間スケーリング予測ベクトル候補の依存関係をなくし、予測ベクトル候補として相対的に選択率の高い順序である空間予測ベクトル候補、時間予測ベクトル候補、空間スケーリング予測ベクトル候補、予測ベクトル補充候補の順に予測ベクトル候補リストに追加することで、予測ベクトルインデックスの符号量を抑制することができる。   As described above, the spatial prediction vector candidate and the spatial scaling prediction vector candidate are eliminated, and the spatial prediction vector candidate, temporal prediction vector candidate, and spatial scaling prediction vector candidate that are in the order of relatively high selectivity as the prediction vector candidate. By adding to the prediction vector candidate list in the order of prediction vector supplementation candidates, the code amount of the prediction vector index can be suppressed.

(マージモード決定部121の構成)
続いて、マージモード決定部121の詳細な構成について説明する。図27は、マージモード決定部121の構成を説明するための図である。マージモード決定部121は、結合動き情報候補リスト生成部140および結合動き情報選択部141を含む。結合動き情報候補リスト生成部140は、実施の形態1に係る動画像符号化装置100により生成された符号列を復号する動画像復号装置200にも同様に設置されて、動画像符号化装置100と動画像復号装置200にて矛盾のない結合動き情報リストが生成される。
(Configuration of merge mode determination unit 121)
Next, a detailed configuration of the merge mode determination unit 121 will be described. FIG. 27 is a diagram for explaining the configuration of the merge mode determination unit 121. The merge mode determination unit 121 includes a combined motion information candidate list generation unit 140 and a combined motion information selection unit 141. The combined motion information candidate list generation unit 140 is also installed in the video decoding device 200 that decodes the code sequence generated by the video encoding device 100 according to Embodiment 1 in the same manner. The moving image decoding apparatus 200 generates a combined motion information list that is consistent.

(マージモード決定部121の動作)
以下、各部の機能と動作について説明する。図28は、マージモード決定部121の動作を説明するためのフローチャートである。結合動き情報候補リスト生成部140は、端子12より供給される候補ブロック群からマージ候補最大数の結合動き情報候補を含む結合動き情報候補リストを生成し(S130)、当該結合動き情報候補リストを結合動き情報選択部141に供給する。結合動き情報候補リスト生成部140の詳細な構成については後述する。
(Operation of merge mode determination unit 121)
Hereinafter, the function and operation of each unit will be described. FIG. 28 is a flowchart for explaining the operation of the merge mode determination unit 121. The combined motion information candidate list generation unit 140 generates a combined motion information candidate list including the maximum number of merge candidate motion information candidates from the candidate block group supplied from the terminal 12 (S130), and generates the combined motion information candidate list. This is supplied to the combined motion information selection unit 141. A detailed configuration of the combined motion information candidate list generation unit 140 will be described later.

結合動き情報選択部141は、結合動き情報候補リスト生成部140より供給される結合動き情報候補リストの中から、最適な結合動き情報候補を選択し、選択された結合動き情報候補を示す情報であるマージインデックスを決定して(S131)、当該マージインデックスを端子17に供給する。   The combined motion information selection unit 141 selects the optimum combined motion information candidate from the combined motion information candidate list supplied from the combined motion information candidate list generation unit 140, and is information indicating the selected combined motion information candidate. A certain merge index is determined (S131), and the merge index is supplied to the terminal 17.

ここで、最適な結合動き情報候補の選択方法について説明する。結合動き情報候補の予測方向、動きベクトルおよび参照インデックスに基づいて得られる端子14より供給される参照画像と、端子15より供給される画像信号とから予測誤差量が算出される。マージインデックスの符号量と、当該予測誤差量とからレート歪み評価値が算出されて、レート歪み評価値が最小となる結合動き情報候補が最適な結合動き情報候補として選択される。   Here, a method for selecting an optimal combined motion information candidate will be described. A prediction error amount is calculated from the reference image supplied from the terminal 14 obtained based on the prediction direction, the motion vector, and the reference index of the combined motion information candidate, and the image signal supplied from the terminal 15. A rate distortion evaluation value is calculated from the code amount of the merge index and the prediction error amount, and a combined motion information candidate that minimizes the rate distortion evaluation value is selected as an optimal combined motion information candidate.

(結合動き情報候補リスト生成部140に供給される候補ブロック群)
ここで、結合動き情報候補リスト生成部140に供給される候補ブロック群は、予測ベクトル候補リスト生成部130に供給される候補ブロック群と同じとする。ここでは、結合動き情報候補リスト生成部140に供給される候補ブロック群は、予測ベクトル候補リスト生成部130に供給される候補ブロック群と同じとしたが、結合動き情報候補リスト生成部140に供給される空間候補ブロック群は予測ベクトル候補リスト生成部130に供給される空間候補ブロック群と少なくとも1以上の同じ候補ブロックを含んでいればよく、ブロックの数や位置はこれらに限定されない。また、結合動き情報候補リスト生成部140に供給される時間候補ブロック群は、予測ベクトル候補リスト生成部130に供給される時間候補ブロック群と少なくとも1以上の同じ候補ブロックを含んでいればよく、ブロックの数や位置はこれらに限定されない。
(Candidate block group supplied to combined motion information candidate list generation unit 140)
Here, the candidate block group supplied to the combined motion information candidate list generation unit 140 is the same as the candidate block group supplied to the prediction vector candidate list generation unit 130. Here, the candidate block group supplied to the combined motion information candidate list generation unit 140 is the same as the candidate block group supplied to the prediction vector candidate list generation unit 130, but is supplied to the combined motion information candidate list generation unit 140. The spatial candidate block group to be included only needs to include at least one or more of the same candidate blocks as the spatial candidate block group supplied to the prediction vector candidate list generation unit 130, and the number and position of the blocks are not limited thereto. The temporal candidate block group supplied to the combined motion information candidate list generation unit 140 only needs to include at least one or more same candidate blocks as the temporal candidate block group supplied to the prediction vector candidate list generation unit 130. The number and position of blocks are not limited to these.

(結合動き情報候補リスト生成部140の構成)
続いて、結合動き情報候補リスト生成部140の詳細な構成について説明する。図29は、結合動き情報候補リスト生成部140の構成を説明するための図である。端子19は結合動き情報選択部141に接続されている。結合動き情報候補リスト生成部140は、空間結合動き情報候補生成部160、時間結合動き情報候補生成部161、空間スケーリング結合動き情報候補生成部162、結合動き情報候補補充部163、および結合動き情報候補リスト確定部164を含む。
(Configuration of combined motion information candidate list generation unit 140)
Next, a detailed configuration of the combined motion information candidate list generation unit 140 will be described. FIG. 29 is a diagram for explaining the configuration of the combined motion information candidate list generation unit 140. The terminal 19 is connected to the combined motion information selection unit 141. The combined motion information candidate list generating unit 140 includes a spatial combined motion information candidate generating unit 160, a temporal combined motion information candidate generating unit 161, a spatial scaling combined motion information candidate generating unit 162, a combined motion information candidate supplementing unit 163, and combined motion information. A candidate list confirmation unit 164 is included.

(結合動き情報候補リスト生成部140の動作)
以下、各部の機能と動作について説明する。図30は、結合動き情報候補リスト生成部140の動作を説明するためのフローチャートである。空間結合動き情報候補生成部160は、端子12より供給される候補ブロック群から空間結合動き情報候補を0個から2個生成し(S190)、当該空間結合動き情報候補を結合動き情報候補リスト確定部164に供給する。空間結合動き情報候補生成部160の詳細な動作については後述する。
(Operation of Combined Motion Information Candidate List Generation Unit 140)
Hereinafter, the function and operation of each unit will be described. FIG. 30 is a flowchart for explaining the operation of the combined motion information candidate list generation unit 140. The spatially coupled motion information candidate generation unit 160 generates 0 to 2 spatially coupled motion information candidates from the candidate block group supplied from the terminal 12 (S190), and confirms the spatially coupled motion information candidate as a coupled motion information candidate list. To the unit 164. The detailed operation of the spatially coupled motion information candidate generation unit 160 will be described later.

時間結合動き情報候補生成部161は、端子12より供給される候補ブロック群から時間結合動き情報候補を0個または1個生成し(S191)、当該時間結合動き情報候補を結合動き情報候補リスト確定部164に供給する。時間結合動き情報候補生成部161の詳細な動作については後述する。   The temporally combined motion information candidate generation unit 161 generates zero or one temporally combined motion information candidate from the candidate block group supplied from the terminal 12 (S191), and determines the temporally combined motion information candidate as a combined motion information candidate list. To the unit 164. The detailed operation of the time combination motion information candidate generation unit 161 will be described later.

空間スケーリング結合動き情報候補生成部162は、端子12より供給される候補ブロック群から空間スケーリング結合動き情報候補を0個または1個生成し(S192)、当該空間スケーリング結合動き情報候補を結合動き情報候補リスト確定部164に供給する。空間スケーリング結合動き情報候補生成部162の詳細な動作については後述する。   The spatial scaling combined motion information candidate generating unit 162 generates 0 or 1 spatial scaling combined motion information candidate from the candidate block group supplied from the terminal 12 (S192), and the spatial scaling combined motion information candidate is combined motion information. The data is supplied to the candidate list confirmation unit 164. The detailed operation of the spatial scaling combined motion information candidate generation unit 162 will be described later.

結合動き情報候補リスト確定部164は、マージ候補最大数から、空間結合動き情報候補および時間結合動き情報候補を合計した結合動き情報候補数を減算して結合動き情報補充候補数を算出し(S193)、当該結合動き情報補充候補数、ならびに空間結合動き情報候補、時間結合動き情報候補、および空間スケーリング動き情報候補を結合動き情報候補補充部163に供給する。なお、算出された結合動き情報補充候補数が0未満の場合には、結合動き情報補充候補数は0とする。   The combined motion information candidate list determination unit 164 calculates the combined motion information supplement candidate number by subtracting the combined motion information candidate number obtained by adding the spatial combined motion information candidate and the temporal combined motion information candidate from the maximum merge candidate number (S193). ), The combined motion information supplement candidate number, the spatially coupled motion information candidate, the temporally coupled motion information candidate, and the spatial scaling motion information candidate are supplied to the coupled motion information candidate supplementing unit 163. When the calculated combined motion information supplement candidate number is less than 0, the combined motion information supplement candidate number is set to zero.

結合動き情報候補補充部163は、結合動き情報候補リスト確定部164より供給される空間結合動き情報候補、時間結合動き情報候補、および空間スケーリング動き情報候補から結合動き情報補充候補数だけ結合動き情報補充候補を生成し(S194)、当該結合動き情報補充候補を結合動き情報候補リスト確定部164に供給する。結合動き情報補充候補は、動き補償予測の方向が双方向、L0予測およびL1予測の動きベクトルが(0,0)、L0予測およびL1予測の参照インデックスが0である動き情報とする。ここでは、結合動き情報補充候補を動き補償予測の方向が双方向、L0予測およびL1予測の動きベクトルが(0,0)、L0予測およびL1予測の参照インデックスが0である動き情報としたが、空間結合動き情報候補、時間結合動き情報候補、空間スケーリング結合動き情報候補と異なる動き情報であればよく、これに限定されない。例えば、異なる2つの候補ブロックのL0予測の動き情報とL1予測の動き情報を組み合わせた双結合動き情報候補を追加することもできる。   The combined motion information candidate supplementing unit 163 combines the combined motion information from the spatially coupled motion information candidates, the temporally coupled motion information candidates, and the spatial scaling motion information candidates supplied from the combined motion information candidate list determining unit 164 by the number of combined motion information supplement candidates. A supplement candidate is generated (S194), and the combined motion information supplement candidate is supplied to the combined motion information candidate list determination unit 164. The combined motion information supplement candidate is motion information in which the direction of motion compensation prediction is bidirectional, the motion vector of L0 prediction and L1 prediction is (0, 0), and the reference index of L0 prediction and L1 prediction is 0. Here, the combined motion information supplement candidate is motion information in which the direction of motion compensation prediction is bidirectional, the motion vector of L0 prediction and L1 prediction is (0, 0), and the reference index of L0 prediction and L1 prediction is 0. The motion information may be different from the spatially combined motion information candidate, the temporally combined motion information candidate, and the spatially scaled combined motion information candidate, and is not limited thereto. For example, a bi-join motion information candidate combining the motion information of L0 prediction and the motion information of L1 prediction of two different candidate blocks may be added.

結合動き情報候補リスト確定部164は、結合動き情報候補リストの結合動き情報候補数がマージ候補最大数に達するまで、空間結合動き情報候補、時間結合動き情報候補、空間スケーリング結合動き情報候補、結合動き情報補充候補を順次、結合動き情報候補リストに追加して結合動き情報候補リストを確定する(S195)。結合動き情報候補リストの確定の詳細な動作については後述する。   The combined motion information candidate list determination unit 164 performs spatial combined motion information candidates, temporal combined motion information candidates, spatial scaling combined motion information candidates, combined until the combined motion information candidate number in the combined motion information candidate list reaches the maximum number of merge candidates. The motion information supplement candidates are sequentially added to the combined motion information candidate list to determine the combined motion information candidate list (S195). The detailed operation of determining the combined motion information candidate list will be described later.

(空間結合動き情報候補生成部160の詳細な動作)
引き続いて、空間結合動き情報候補生成部160の詳細な動作について説明する。図31は、空間結合動き情報候補生成部160の動作を説明するためのフローチャートである。空間結合動き情報候補生成部160は、空間結合動き情報候補を0個から2個生成する。空間結合動き情報候補生成部160は、端子12より供給される空間候補ブロック群に含まれる候補ブロックをブロックA1、ブロックB1、ブロックC、ブロックE、ブロックDの順に以下の処理を繰り返し行う(S200からS204)。ここでは、処理の順序をブロックA1、ブロックB1、ブロックC、ブロックE、ブロックDとしたが、空間候補ブロック群に含まれる候補ブロックが多くとも1回処理されればよく、これに限定されない。例えば、空間予測ベクトル候補生成部150の処理の順序と同一にすることもできる。
(Detailed operation of spatially coupled motion information candidate generation unit 160)
Subsequently, a detailed operation of the spatially coupled motion information candidate generation unit 160 will be described. FIG. 31 is a flowchart for explaining the operation of the spatially coupled motion information candidate generation unit 160. The spatially coupled motion information candidate generation unit 160 generates 0 to 2 spatially coupled motion information candidates. The spatially coupled motion information candidate generation unit 160 repeatedly performs the following processing in the order of block A1, block B1, block C, block E, and block D on candidate blocks included in the spatial candidate block group supplied from the terminal 12 (S200). To S204). Here, the processing order is block A1, block B1, block C, block E, and block D, but the candidate blocks included in the spatial candidate block group only need to be processed at most once, and the present invention is not limited to this. For example, the processing order of the spatial prediction vector candidate generation unit 150 may be the same.

候補ブロックが有効であるかどうか検査する(S201)。候補ブロックが有効であるとは候補ブロックのL0予測とL1予測の参照インデックスの少なくとも一方が0以上であることである。候補ブロックが有効であれば(S201のY)、候補ブロックの動き情報を空間結合動き情報候補として決定する(S202)。候補ブロックが有効でなければ(S201のN)、ステップS202とステップS203をスキップして次の候補ブロックを検査する(S204)。ステップS202に続いて、空間結合動き情報候補数が所定数であるか検査する(S203)。ここでは、所定数を4とする。実施の形態1では、所定数を4としたが、所定数は1以上で空間候補ブロック群に含まれる候補ブロック数以下であればよく、これに限定されない。決定された空間結合動き情報候補数が所定数でなければ(S203のN)、次の候補ブロックを検査する(S204)。決定された空間結合動き情報候補数が所定数であれば(S203のY)、処理を終了する。   It is checked whether the candidate block is valid (S201). The candidate block is valid when at least one of the reference index of the L0 prediction and the L1 prediction of the candidate block is 0 or more. If the candidate block is valid (Y in S201), the motion information of the candidate block is determined as a spatially combined motion information candidate (S202). If the candidate block is not valid (N in S201), step S202 and step S203 are skipped and the next candidate block is inspected (S204). Following step S202, it is checked whether the number of spatially coupled motion information candidates is a predetermined number (S203). Here, the predetermined number is four. In the first embodiment, the predetermined number is four, but the predetermined number may be one or more and the number of candidate blocks included in the spatial candidate block group, and is not limited to this. If the determined number of spatially coupled motion information candidates is not a predetermined number (N in S203), the next candidate block is examined (S204). If the determined number of spatially coupled motion information candidates is a predetermined number (Y in S203), the process ends.

(時間結合動き情報候補生成部161の構成)
続いて、時間結合動き情報候補生成部161の詳細な構成について説明する。図32は、時間結合動き情報候補生成部161の構成を説明するための図である。時間結合動き情報候補生成部161は、予測方向設定部180、時間予測ベクトル候補生成部151、および時間結合動き情報候補確定部181を含む。端子21は結合動き情報候補リスト確定部164に接続されている。
(Configuration of time combination motion information candidate generation unit 161)
Next, a detailed configuration of the time combination motion information candidate generation unit 161 will be described. FIG. 32 is a diagram for explaining the configuration of the time-coupled motion information candidate generation unit 161. The temporal combination motion information candidate generation unit 161 includes a prediction direction setting unit 180, a temporal prediction vector candidate generation unit 151, and a temporal combination motion information candidate determination unit 181. The terminal 21 is connected to the combined motion information candidate list determination unit 164.

(時間結合動き情報候補生成部161の詳細な動作)
以下、各部の機能と動作について説明する。図33は、時間結合動き情報候補生成部161の動作を説明するためのフローチャートである。予測方向設定部180は、時間結合動き情報候補の予測方向を双予測に設定する(S210)。次に、時間予測ベクトル候補生成部151は、時間結合動き情報候補のL0予測の動きベクトルを算出する(S211)。次に、時間予測ベクトル候補生成部151は、時間結合動き情報候補のL1予測の動きベクトルを算出する(S212)。次に、時間結合動き情報候補確定部181は、L0予測の参照インデックスを所定値Ref_idx_TScale、L1予測の参照インデックスを所定値Ref_idx_TScaleに設定して、双方向の予測方向、当該L0予測の動きベクトル、当該L1予測の動きベクトル、当該L0予測の参照インデックス、当該L1予測の参照インデックスである時間結合動き情報候補を確定し(S213)、当該時間結合動き情報候補を端子21に供給する。
(Detailed operation of time combination motion information candidate generation unit 161)
Hereinafter, the function and operation of each unit will be described. FIG. 33 is a flowchart for explaining the operation of the time combination motion information candidate generation unit 161. The prediction direction setting unit 180 sets the prediction direction of the temporally combined motion information candidate to bi-prediction (S210). Next, the temporal prediction vector candidate generation unit 151 calculates an L0 prediction motion vector of the temporally coupled motion information candidate (S211). Next, the temporal prediction vector candidate generation unit 151 calculates an L1 prediction motion vector of the temporally combined motion information candidate (S212). Next, the temporally combined motion information candidate determination unit 181 sets the reference index for L0 prediction to the predetermined value Ref_idx_TSscale and the reference index for L1 prediction to the predetermined value Ref_idx_TSscale, and sets the bidirectional prediction direction, the motion vector for the L0 prediction, The motion vector for the L1 prediction, the reference index for the L0 prediction, and the temporally coupled motion information candidate that is the reference index for the L1 prediction are determined (S213), and the temporally coupled motion information candidate is supplied to the terminal 21.

以上のように、時間結合動き情報候補の動きベクトルの算出と時間予測ベクトル候補の動きベクトルの算出を同一にすることで、マージモードと予測ベクトルモードのスケーリングの演算部の共用を容易にすることが可能となる。スケーリングの演算部を共用した場合であっても、算出されたL0予測の動きベクトルとL1予測の動きベクトルの両方を利用するか、L0予測の動きベクトルとL1予測の動きベクトルのいずれか一方を利用するかによって、マージモードと予測ベクトルモードの符号化効率の高い方を選択することができる。   As described above, by making the calculation of the motion vector of the temporally combined motion information candidate and the motion vector of the temporal prediction vector candidate the same, it becomes easy to share the arithmetic unit for scaling between the merge mode and the prediction vector mode. Is possible. Even when the calculation unit for scaling is shared, either the calculated motion vector of the L0 prediction and the motion vector of the L1 prediction are used, or one of the motion vector of the L0 prediction and the motion vector of the L1 prediction is used. Depending on the use, the higher one of the encoding efficiency of the merge mode and the prediction vector mode can be selected.

(空間スケーリング結合動き情報候補生成部162の構成)
続いて、空間スケーリング結合動き情報候補生成部162の詳細な構成について説明する。図34は、空間スケーリング結合動き情報候補生成部162の構成を説明するための図である。空間スケーリング結合動き情報候補生成部162は、予測方向設定部185、空間スケーリング予測ベクトル候補生成部152、および空間スケーリング結合動き情報候補確定部186を含む。
(Configuration of Spatial Scaling Combined Motion Information Candidate Generation Unit 162)
Next, a detailed configuration of the spatial scaling combined motion information candidate generation unit 162 will be described. FIG. 34 is a diagram for explaining the configuration of the spatial scaling combined motion information candidate generation unit 162. The spatial scaling combined motion information candidate generation unit 162 includes a prediction direction setting unit 185, a spatial scaling prediction vector candidate generation unit 152, and a spatial scaling combined motion information candidate determination unit 186.

(空間スケーリング結合動き情報候補生成部162の詳細な動作)
以下、各部の機能と動作について説明する。図35は、空間スケーリング結合動き情報候補生成部162の動作を説明するためのフローチャートである。予測方向設定部185は、空間スケーリング結合動き情報候補の予測方向を双予測に設定する(S220)。次に、空間スケーリング予測ベクトル候補生成部152は、空間スケーリング結合動き情報候補のL0予測の動きベクトルを算出する(S221)。次に、空間スケーリング予測ベクトル候補生成部152は、空間スケーリング結合動き情報候補のL1予測の動きベクトルを算出する(S222)。次に、空間スケーリング結合動き情報候補確定部186は、L0予測の参照インデックスを所定値Ref_idx_SScale、L1予測の参照インデックスを所定値Ref_idx_SScaleに設定して、双方向の予測方向、当該L0予測の動きベクトル、当該L1予測の動きベクトル、当該L0予測の参照インデックス、当該L1予測の参照インデックスである空間スケーリング結合動き情報候補を確定し(S223)、当該空間スケーリング結合動き情報候補を端子21に供給する。
(Detailed Operation of Spatial Scaling Combined Motion Information Candidate Generation Unit 162)
Hereinafter, the function and operation of each unit will be described. FIG. 35 is a flowchart for explaining the operation of the spatial scaling combined motion information candidate generation unit 162. The prediction direction setting unit 185 sets the prediction direction of the spatial scaling combined motion information candidate to bi-prediction (S220). Next, the spatial scaling prediction vector candidate generation unit 152 calculates an L0 prediction motion vector of the spatial scaling combined motion information candidate (S221). Next, the spatial scaling prediction vector candidate generation unit 152 calculates the L1 prediction motion vector of the spatial scaling combined motion information candidate (S222). Next, the spatial scaling combined motion information candidate determination unit 186 sets the reference index for L0 prediction to the predetermined value Ref_idx_SSscale and the reference index for L1 prediction to the predetermined value Ref_idx_SSscale, and sets the bidirectional prediction direction and the motion vector for the L0 prediction. Then, the motion vector of the L1 prediction, the reference index of the L0 prediction, and the spatial scaling combined motion information candidate that is the reference index of the L1 prediction are determined (S223), and the spatial scaling combined motion information candidate is supplied to the terminal 21.

以上のように、空間スケーリング結合動き情報候補の動きベクトルの算出と空間スケーリング予測ベクトル候補の動きベクトルの算出を同一にすることで、マージモードと予測ベクトルモードのスケーリングの演算部の共用を容易にすることが可能となる。スケーリングの演算部を共用した場合であっても、算出されたL0予測の動きベクトルとL1予測の動きベクトルの両方を利用するか、L0予測の動きベクトルとL1予測の動きベクトルのいずれか一方を利用するかによって、マージモードと予測ベクトルモードの符号化効率の高い方を選択することができる。   As described above, the motion vector calculation of the spatial scaling combined motion information candidate and the motion vector calculation of the spatial scaling prediction vector candidate are made the same, thereby making it easy to share the arithmetic unit for the merge mode and the prediction vector mode scaling. It becomes possible to do. Even when the calculation unit for scaling is shared, either the calculated motion vector of the L0 prediction and the motion vector of the L1 prediction are used, or one of the motion vector of the L0 prediction and the motion vector of the L1 prediction is used. Depending on the use, the higher one of the encoding efficiency of the merge mode and the prediction vector mode can be selected.

(結合動き情報候補リストの確定の詳細な動作)
引き続いて、結合動き情報候補リストの確定の詳細な動作について説明する。図36は、結合動き情報候補リストの確定の動作を説明するためのフローチャートである。結合動き情報候補リスト確定部164は、空間結合動き情報候補を結合動き情報候補リストに追加する(S230)。次に、時間結合動き情報候補を結合動き情報候補リストに追加する(S231)。次に、結合動き情報候補リストに同一の結合動き情報候補が複数存在するか検査し、複数存在する場合には最初の結合動き情報候補を残して残りを削除する(S232)。次に、結合動き情報候補リストの結合動き情報候補数がマージ候補最大数であるか検査する(S233)。結合動き情報候補リストの結合動き情報候補数がマージ候補最大数であれば(S233のY)、結合動き情報候補リストを確定し、ステップS234からステップS237をスキップして処理を終了する。結合動き情報候補リストの結合動き情報候補数がマージ候補最大数でなければ(S233のN)、空間スケーリング結合動き情報候補を結合動き情報候補リストに追加する(S234)。ステップS234に続いて、結合動き情報候補リストに同一の結合動き情報候補が複数存在するか検査し、複数存在する場合には最初の結合動き情報候補を残して残りを削除する(S235)。ステップS235に続いて、結合動き情報候補リストの結合動き情報候補数がマージ候補最大数であるか検査する(S236)。結合動き情報候補リストの結合動き情報候補数がマージ候補最大数であれば(S236のY)、結合動き情報候補リストを確定し、ステップS237をスキップして処理を終了する。結合動き情報候補リストの結合動き情報候補数がマージ候補最大数でなければ(S236のN)、結合動き情報補充候補を結合動き情報候補リストに追加して(S237)、結合動き情報候補リストを確定して処理を終了する。
(Detailed operation for determining the combined motion information candidate list)
Subsequently, a detailed operation for determining the combined motion information candidate list will be described. FIG. 36 is a flowchart for explaining the operation of determining the combined motion information candidate list. The combined motion information candidate list determination unit 164 adds the spatial combined motion information candidate to the combined motion information candidate list (S230). Next, the temporally combined motion information candidate is added to the combined motion information candidate list (S231). Next, it is checked whether there are a plurality of the same combined motion information candidates in the combined motion information candidate list. If there are a plurality of combined motion information candidates, the first combined motion information candidate is left and the rest is deleted (S232). Next, it is checked whether the number of combined motion information candidates in the combined motion information candidate list is the maximum number of merge candidates (S233). If the number of combined motion information candidates in the combined motion information candidate list is the maximum number of merge candidates (Y in S233), the combined motion information candidate list is determined, and the process is terminated by skipping steps S234 to S237. If the number of combined motion information candidates in the combined motion information candidate list is not the maximum number of merge candidates (N in S233), the spatial scaling combined motion information candidate is added to the combined motion information candidate list (S234). Subsequent to step S234, it is checked whether there are a plurality of the same combined motion information candidates in the combined motion information candidate list. If there are a plurality of combined motion information candidates, the first combined motion information candidate is left and the rest is deleted (S235). Following step S235, it is checked whether the combined motion information candidate number in the combined motion information candidate list is the maximum number of merge candidates (S236). If the number of combined motion information candidates in the combined motion information candidate list is the maximum number of merge candidates (Y in S236), the combined motion information candidate list is confirmed, and the process is terminated by skipping step S237. If the number of combined motion information candidates in the combined motion information candidate list is not the maximum number of merge candidates (N in S236), the combined motion information supplement candidate is added to the combined motion information candidate list (S237), and the combined motion information candidate list is displayed. Confirm and end the process.

(動画像復号装置200の構成)
次に、実施の形態1の動画像復号装置を説明する。図37は、実施の形態1の動画像復号装置200を示す。動画像復号装置200は、動画像符号化装置100により符号化された符号列を復号して再生画像を生成する装置である。
(Configuration of moving picture decoding apparatus 200)
Next, the moving picture decoding apparatus according to the first embodiment will be described. FIG. 37 shows the moving picture decoding apparatus 200 according to the first embodiment. The video decoding device 200 is a device that generates a playback image by decoding the code string encoded by the video encoding device 100.

動画像復号装置200は、CPU(Central Processing Unit)、フレームメモリ、ハードディスクなどを備える情報処理装置などのハードウェアにより実現される。動画像復号装置200は、上記の構成要素が動作することにより、以下に説明する機能的な構成要素を実現する。なお、復号対象の予測ブロックの位置情報、予測ブロックサイズに関しては動画像復号装置200内で共有していることとし、図示しない。   The moving picture decoding apparatus 200 is realized by hardware such as an information processing apparatus including a CPU (Central Processing Unit), a frame memory, and a hard disk. The moving picture decoding apparatus 200 realizes functional components described below by operating the above components. Note that the position information and the prediction block size of the prediction block to be decoded are shared in the video decoding device 200 and are not shown.

実施の形態1の動画像復号装置200は、符号列解析部201、予測誤差復号部202、加算部203、動き情報再生部204、動き補償部205、フレームメモリ206および動き情報メモリ207を備える。   The moving picture decoding apparatus 200 according to Embodiment 1 includes a code string analysis unit 201, a prediction error decoding unit 202, an addition unit 203, a motion information reproduction unit 204, a motion compensation unit 205, a frame memory 206, and a motion information memory 207.

(動画像復号装置200の動作)
以下、各部の機能と動作について説明する。図38は、動画像復号装置200の動作を説明するためのフローチャートである。符号列解析部201は、端子30より供給された符号列を解析して予測誤差符号化データ、マージフラグ、マージインデックス、動き補償予測の予測方向、参照インデックス、差分ベクトル、および予測ベクトルインデックスをシンタックスに従ってエントロピー復号する(S290)。エントロピー復号は算術符号化やハフマン符号化などの可変長符号化を含む方法によって実施される。そして、当該予測誤差符号化データを予測誤差復号部202に、当該マージフラグ、当該マージインデックス、当該動き補償予測の予測方向、当該参照インデックス、当該差分ベクトル、および当該予測ベクトルインデックスを動き情報再生部204に供給する。
(Operation of the video decoding device 200)
Hereinafter, the function and operation of each unit will be described. FIG. 38 is a flowchart for explaining the operation of the moving picture decoding apparatus 200. The code string analysis unit 201 analyzes the code string supplied from the terminal 30 and compares the prediction error encoded data, the merge flag, the merge index, the prediction direction of motion compensation prediction, the reference index, the difference vector, and the prediction vector index. Entropy decoding is performed according to the tax (S290). Entropy decoding is performed by a method including variable length coding such as arithmetic coding or Huffman coding. Then, the prediction error encoded data is transferred to the prediction error decoding unit 202, and the merge flag, the merge index, the prediction direction of the motion compensated prediction, the reference index, the difference vector, and the prediction vector index are transferred to the motion information reproducing unit. 204.

動き情報再生部204は、符号列解析部201より供給されるマージフラグ、マージインデックス、動き補償予測の予測方向、参照インデックス、差分ベクトル、および予測ベクトルインデックスと、動き情報メモリ207より供給される候補ブロック群から、動き情報を再生し(S291)、当該動き情報を動き補償部205および動き情報メモリ207に供給する。動き情報再生部204の詳細な構成については後述する。   The motion information reproduction unit 204 includes a merge flag, a merge index, a prediction direction of motion compensation prediction, a reference index, a difference vector, and a prediction vector index supplied from the code string analysis unit 201, and candidates supplied from the motion information memory 207. Motion information is reproduced from the block group (S291), and the motion information is supplied to the motion compensation unit 205 and the motion information memory 207. A detailed configuration of the motion information reproducing unit 204 will be described later.

動き補償部205は、動き情報再生部204より供給される動き情報に基づいて、フレームメモリ206内の参照インデックスが示す参照画像を、動きベクトルに基づき動き補償して予測信号を生成する(S292)。予測方向が双予測であれば、L0予測とL1予測の予測信号を平均したものを予測信号として生成し、当該予測信号を加算部203に供給する。   The motion compensation unit 205 generates a prediction signal by performing motion compensation on the reference image indicated by the reference index in the frame memory 206 based on the motion vector based on the motion information supplied from the motion information reproducing unit 204 (S292). . If the prediction direction is bi-prediction, an average of the prediction signals of the L0 prediction and the L1 prediction is generated as a prediction signal, and the prediction signal is supplied to the adding unit 203.

予測誤差復号部202は、符号列解析部201より供給される予測誤差符号化データに対して、逆量子化や逆直交変換などの処理を行って予測誤差信号を生成し(S293)、当該予測誤差信号を加算部203に供給する。   The prediction error decoding unit 202 performs a process such as inverse quantization or inverse orthogonal transform on the prediction error encoded data supplied from the code string analysis unit 201 to generate a prediction error signal (S293). The error signal is supplied to the adding unit 203.

加算部203は、予測誤差復号部202より供給される予測誤差信号と、動き補償部205より供給される予測信号とを加算して復号画像信号を生成し(S294)、当該復号画像信号をフレームメモリ206および端子31に供給する。   The adding unit 203 adds the prediction error signal supplied from the prediction error decoding unit 202 and the prediction signal supplied from the motion compensation unit 205 to generate a decoded image signal (S294), and the decoded image signal is framed. This is supplied to the memory 206 and the terminal 31.

フレームメモリ206および動き情報メモリ207は、動画像符号化装置100のフレームメモリ110および動き情報メモリ111と同一の機能を有する。フレームメモリ206は、加算部203より供給される復号画像信号を記憶する(S295)。動き情報メモリ207は、動き情報再生部204より供給される動き情報を最小の予測ブロックサイズ単位で記憶する(S296)。   The frame memory 206 and the motion information memory 207 have the same functions as the frame memory 110 and the motion information memory 111 of the video encoding device 100. The frame memory 206 stores the decoded image signal supplied from the adding unit 203 (S295). The motion information memory 207 stores the motion information supplied from the motion information reproducing unit 204 in units of the minimum predicted block size (S296).

(動き情報再生部204の詳細な構成)
続いて、動き情報再生部204の詳細な構成について説明する。図39は、動き情報再生部204の構成を示す。動き情報再生部204は、符号化モード判定部210、動きベクトル再生部211および結合動き情報再生部212を含む。端子32は符号列解析部201に、端子33は動き情報メモリ207に、端子34は動き補償部205にそれぞれ接続されている。
(Detailed configuration of the motion information playback unit 204)
Next, a detailed configuration of the motion information reproducing unit 204 will be described. FIG. 39 shows the configuration of the motion information playback unit 204. The motion information playback unit 204 includes an encoding mode determination unit 210, a motion vector playback unit 211, and a combined motion information playback unit 212. The terminal 32 is connected to the code string analysis unit 201, the terminal 33 is connected to the motion information memory 207, and the terminal 34 is connected to the motion compensation unit 205.

(動き情報再生部204の詳細な動作)
以下、各部の機能と動作について説明する。符号化モード判定部210は、符号列解析部201より供給されるマージフラグが「0」であれるか「1」であるか判定する。マージフラグが「0」であれば、符号列解析部201より供給される動き補償予測の予測方向、参照インデックス、差分ベクトル、および予測ベクトルインデックスを動きベクトル再生部211に供給する。マージフラグが「1」であれば、符号列解析部201より供給されるマージインデックスを結合動き情報再生部212に供給する。
(Detailed operation of the motion information playback unit 204)
Hereinafter, the function and operation of each unit will be described. The encoding mode determination unit 210 determines whether the merge flag supplied from the code string analysis unit 201 is “0” or “1”. If the merge flag is “0”, the motion compensation prediction direction, the reference index, the difference vector, and the prediction vector index supplied from the code string analysis unit 201 are supplied to the motion vector reproduction unit 211. If the merge flag is “1”, the merge index supplied from the code string analysis unit 201 is supplied to the combined motion information reproduction unit 212.

動きベクトル再生部211は、符号化モード判定部210より供給される動き補償予測の予測方向、参照インデックス、差分ベクトル、および予測ベクトルインデックスと、端子33より供給される候補ブロック群から、動き情報を再生して端子34に供給する。動きベクトル再生部211の詳細については後述する。   The motion vector reproduction unit 211 obtains motion information from the prediction direction, the reference index, the difference vector, and the prediction vector index of the motion compensated prediction supplied from the coding mode determination unit 210 and the candidate block group supplied from the terminal 33. Reproduce and supply to terminal 34. Details of the motion vector reproducing unit 211 will be described later.

結合動き情報再生部212は、符号化モード判定部210より供給されるマージインデックスと、端子33より供給される候補ブロック群から、動き情報を再生して端子34に供給する。結合動き情報再生部212の詳細な構成については後述する。   The combined motion information reproduction unit 212 reproduces the motion information from the merge index supplied from the encoding mode determination unit 210 and the candidate block group supplied from the terminal 33 and supplies the motion information to the terminal 34. A detailed configuration of the combined motion information reproducing unit 212 will be described later.

(動きベクトル再生部211の詳細な構成)
続いて、動きベクトル再生部211の詳細な構成について説明する。図40は、動きベクトル再生部211の構成を示す。動きベクトル再生部211は、予測ベクトル候補リスト生成部220、予測ベクトル決定部221および加算部222を含む。端子35は符号化モード判定部210に接続されている。
(Detailed Configuration of Motion Vector Reproducing Unit 211)
Next, a detailed configuration of the motion vector reproduction unit 211 will be described. FIG. 40 shows the configuration of the motion vector playback unit 211. The motion vector reproduction unit 211 includes a prediction vector candidate list generation unit 220, a prediction vector determination unit 221, and an addition unit 222. The terminal 35 is connected to the encoding mode determination unit 210.

(動きベクトル再生部211の詳細な動作)
以下、各部の機能と動作について説明する。図41は、動きベクトル再生部211の動作を説明するためのフローチャートである。動きベクトル再生部211は、動き補償予測の予測方向がL0予測であれば、L0予測について以下の処理を行い、動き補償予測の予測方向がL1予測であれば、L1予測について以下の処理を行い、動き補償予測の予測方向がBI予測であれば、L0予測とL1予測について以下の処理を行う。
(Detailed operation of the motion vector reproduction unit 211)
Hereinafter, the function and operation of each unit will be described. FIG. 41 is a flowchart for explaining the operation of the motion vector reproducing unit 211. The motion vector reproduction unit 211 performs the following processing for L0 prediction if the prediction direction of motion compensation prediction is L0 prediction, and performs the following processing for L1 prediction if the prediction direction of motion compensation prediction is L1 prediction. If the prediction direction of motion compensation prediction is BI prediction, the following processing is performed for L0 prediction and L1 prediction.

予測ベクトル候補リスト生成部220は、動画像符号化装置100の予測ベクトル候補リスト生成部130と同一の機能を有し、動画像符号化装置100の予測ベクトル候補リスト生成部130と同一の動作によって予測ベクトル候補リストを生成し(S300)、当該予測ベクトル候補リストを予測ベクトル決定部221に供給する。   The prediction vector candidate list generation unit 220 has the same function as the prediction vector candidate list generation unit 130 of the video encoding device 100 and performs the same operation as the prediction vector candidate list generation unit 130 of the video encoding device 100. A prediction vector candidate list is generated (S300), and the prediction vector candidate list is supplied to the prediction vector determination unit 221.

予測ベクトル決定部221は、予測ベクトル候補リスト生成部220より供給される予測ベクトル候補リストの中から、端子35より供給される予測ベクトルインデックスで示される予測ベクトル候補を選択して予測ベクトルを決定し(S301)、当該予測ベクトルを加算部222に供給する。   The prediction vector determination unit 221 selects a prediction vector candidate indicated by the prediction vector index supplied from the terminal 35 from the prediction vector candidate list supplied from the prediction vector candidate list generation unit 220 and determines a prediction vector. (S301), the prediction vector is supplied to the adding unit 222.

加算部222は、端子35より供給される差分ベクトルと、予測ベクトル決定部221より供給される予測ベクトルとを加算して動きベクトルを算出し(S302)、当該動きベクトルを端子34に供給する。   The addition unit 222 adds the difference vector supplied from the terminal 35 and the prediction vector supplied from the prediction vector determination unit 221 to calculate a motion vector (S302), and supplies the motion vector to the terminal 34.

(結合動き情報再生部212の詳細な構成)
続いて、結合動き情報再生部212の詳細な構成について説明する。図42は、結合動き情報再生部212の構成を示す。結合動き情報再生部212は、結合動き情報候補生成部230および結合動き情報選択部231を含む。
(Detailed Configuration of Combined Motion Information Reproducing Unit 212)
Next, a detailed configuration of the combined motion information reproduction unit 212 will be described. FIG. 42 shows the configuration of the combined motion information playback unit 212. The combined motion information reproduction unit 212 includes a combined motion information candidate generation unit 230 and a combined motion information selection unit 231.

(結合動き情報再生部212の詳細な動作)
以下、各部の機能と動作について説明する。図43は、結合動き情報再生部212の動作を説明するためのフローチャートである。結合動き情報候補生成部230は動画像符号化装置100の結合動き情報候補リスト生成部140と同一の機能を有し、動画像符号化装置100の結合動き情報候補リスト生成部140と同一の動作によって結合動き情報候補リストを生成し(S310)、当該結合動き情報候補リストを結合動き情報選択部231に供給する。
(Detailed operation of the combined motion information reproduction unit 212)
Hereinafter, the function and operation of each unit will be described. FIG. 43 is a flowchart for explaining the operation of the combined motion information reproducing unit 212. The combined motion information candidate generation unit 230 has the same function as the combined motion information candidate list generation unit 140 of the video encoding device 100, and the same operation as the combined motion information candidate list generation unit 140 of the video encoding device 100. To generate a combined motion information candidate list (S310), and supplies the combined motion information candidate list to the combined motion information selection unit 231.

結合動き情報選択部231は、結合動き情報候補生成部230より供給される結合動き情報候補リストの中から、端子35より供給されるマージインデックスで示される結合動き情報候補を選択して結合動き情報を決定し(S311)、当該結合動き情報を端子34に供給する。   The combined motion information selection unit 231 selects the combined motion information candidate indicated by the merge index supplied from the terminal 35 from the combined motion information candidate list supplied from the combined motion information candidate generation unit 230, and combines motion information (S311), and the combined motion information is supplied to the terminal 34.

(実施の形態1の変形例)
なお、実施の形態1は以下のように変形できる。
(Modification of Embodiment 1)
The first embodiment can be modified as follows.

実施の形態1の変形例1では、予測ベクトル候補リスト生成部130の動作が実施の形態1の基本例と異なる。図44は、実施の形態1の変形例1における予測ベクトル候補リスト生成部130の動作を説明するためのフローチャートである。図44のフローチャートは、図18のフローチャートに対して、ステップS320からステップS322が追加されている。以下、ステップS320からステップS322について説明する。   In the first modification of the first embodiment, the operation of the prediction vector candidate list generation unit 130 is different from the basic example of the first embodiment. FIG. 44 is a flowchart for explaining the operation of the prediction vector candidate list generation unit 130 in the first modification of the first embodiment. In the flowchart of FIG. 44, steps S320 to S322 are added to the flowchart of FIG. Hereinafter, step S320 to step S322 will be described.

ステップS140に続いて、予測ベクトル候補リスト生成部130は、予測ブロックサイズが所定サイズより大きいか検査する(S320)。所定サイズを16画素×16画素とする。ここでは、所定サイズを16画素×16画素としたが、最大符号化ブロック未満であればよく、これに限定されない。予測ブロックサイズが所定サイズより大きければ(S320のY)、時間予測ベクトル候補の最大数を2とし、空間スケーリング予測ベクトル候補の最大数を0とする(S321)。予測ブロックサイズが所定サイズより大きくなければ(S320のN)、時間予測ベクトル候補の最大数を1とし、空間スケーリング予測ベクトル候補の最大数を1とする(S322)。   Following step S140, the prediction vector candidate list generation unit 130 checks whether the prediction block size is larger than a predetermined size (S320). The predetermined size is 16 pixels × 16 pixels. Here, the predetermined size is set to 16 pixels × 16 pixels, but it may be less than the maximum coding block, and is not limited to this. If the prediction block size is larger than the predetermined size (Y in S320), the maximum number of temporal prediction vector candidates is set to 2, and the maximum number of spatial scaling prediction vector candidates is set to 0 (S321). If the prediction block size is not larger than the predetermined size (N in S320), the maximum number of temporal prediction vector candidates is set to 1, and the maximum number of spatial scaling prediction vector candidates is set to 1 (S322).

また、予測ブロックサイズが所定サイズ以上であれば、時間予測ベクトル候補生成部151の動作が実施の形態1の基本例と異なり、図21のステップS165は省略されて、時間予測ベクトル候補を2個生成する。   If the predicted block size is equal to or larger than the predetermined size, the operation of the temporal prediction vector candidate generation unit 151 is different from the basic example of the first embodiment, and step S165 in FIG. Generate.

一般的に、予測ブロックサイズが大きい場合には処理対象ブロックは空間候補ブロックまたは時間候補ブロックと相関性が高くなるため、相対的に空間スケーリング予測ベクトル候補の有効性は低下する。したがって、予測ブロックサイズが大きい場合には時間予測ベクトル候補数を増加させて、空間スケーリング予測ベクトル候補数を減少させることで、相対的に信頼度の高い空間予測ベクトル候補を予測ベクトル候補リストに追加することでき、予測ベクトルインデックスの符号化効率を向上させることができる。   In general, when the prediction block size is large, the processing target block has a high correlation with the spatial candidate block or the temporal candidate block, so that the effectiveness of the spatial scaling prediction vector candidate is relatively lowered. Therefore, when the prediction block size is large, the number of temporal prediction vector candidates is increased, and the number of spatial scaling prediction vector candidates is decreased, so that relatively reliable spatial prediction vector candidates are added to the prediction vector candidate list. Thus, the encoding efficiency of the prediction vector index can be improved.

[実施の形態2]
最初に、実施の形態2のシンタックスについて説明する。図45は、実施の形態2の予測ブロックのシンタックスの一例を説明するための図である。実施の形態1の予測ブロックのシンタックスとは、予測ベクトルインデックス(mvp_idx_l0およびmvp_idx_l1)、差分ベクトル(mvd_l0[0]、mvd_l0[1]、mvd_l1[0]、mvd_l1[1])、および参照インデックス(ref_idx_l0とref_idx_l1)の並びが異なる。また、予測ベクトルインデックスが予測ベクトルインデックスの最大値の場合には参照インデックスを符号化および復号しないことが異なる。図45のMAX_MVP_IDXは予測ベクトルインデックスの最大値を示す。なお、予測ベクトル候補最大数が2である場合の予測ベクトルインデックスの最大値は1となる。
[Embodiment 2]
First, the syntax of the second embodiment will be described. FIG. 45 is a diagram for describing an example of the syntax of the prediction block according to the second embodiment. The syntax of the prediction block in Embodiment 1 includes the prediction vector index (mvp_idx_l0 and mvp_idx_l1), the difference vector (mvd_l0 [0], mvd_l0 [1], mvd_l1 [0], mvd_l1 [1]), and the reference index ( The order of ref_idx_l0 and ref_idx_l1) is different. Further, when the prediction vector index is the maximum value of the prediction vector index, the reference index is not encoded and decoded. MAX_MVP_IDX in FIG. 45 indicates the maximum value of the prediction vector index. When the maximum number of prediction vector candidates is 2, the maximum value of the prediction vector index is 1.

次に、実施の形態2における制約について説明する。時間予測ベクトル候補生成部151において利用する所定値Ref_idx_TScaleと、空間スケーリング予測ベクトル候補生成部152において利用する所定値Ref_idx_SScaleは同一の値とする。以降、所定値をRef_idx_CScaleとする。   Next, restrictions in the second embodiment will be described. The predetermined value Ref_idx_TSscale used in the temporal prediction vector candidate generation unit 151 and the predetermined value Ref_idx_SSscale used in the spatial scaling prediction vector candidate generation unit 152 are the same value. Hereinafter, the predetermined value is referred to as Ref_idx_CSscale.

(実施の形態2の動画像符号化装置)
実施の形態2の動画像符号化装置の構成は、実施の形態1の動画像符号化装置100の構成と同一である。実施の形態1の動画像符号化装置100とは、符号列生成部104、予測ベクトルモード決定部120、および予測ベクトル候補リスト確定部154の機能と動作が異なる。以下、実施の形態2における符号列生成部104、予測ベクトルモード決定部120、および予測ベクトル候補リスト確定部154の機能と動作について実施の形態1と異なる点を説明する。
(Moving picture encoding apparatus according to Embodiment 2)
The configuration of the moving picture encoding apparatus according to the second embodiment is the same as that of the moving picture encoding apparatus 100 according to the first embodiment. The functions and operations of the code sequence generation unit 104, the prediction vector mode determination unit 120, and the prediction vector candidate list determination unit 154 are different from those of the moving image encoding apparatus 100 according to the first embodiment. Hereinafter, differences from Embodiment 1 in the functions and operations of code string generation section 104, prediction vector mode determination section 120, and prediction vector candidate list determination section 154 in Embodiment 2 will be described.

(符号列生成部104)
符号列生成部104は、L0予測とL1予測それぞれについて予測ベクトルインデックス、差分ベクトル、および参照インデックスの順に符号列を生成する。また、予測ベクトルインデックスが予測ベクトルインデックスの最大値の場合には参照インデックスを符号化しない。
(Code string generation unit 104)
The code string generation unit 104 generates a code string in the order of the prediction vector index, the difference vector, and the reference index for each of the L0 prediction and the L1 prediction. Further, when the prediction vector index is the maximum value of the prediction vector index, the reference index is not encoded.

(予測ベクトルモード決定部120)
予測ベクトルモード決定部120の動作について説明する。図46は、実施の形態2の予測ベクトルモード決定部120の動作を説明するためのフローチャートである。図46のフローチャートは、図12のフローチャートに対して、ステップS250からステップS253が追加されている。
(Predicted vector mode determination unit 120)
The operation of the prediction vector mode determination unit 120 will be described. FIG. 46 is a flowchart for explaining the operation of the prediction vector mode determination unit 120 according to the second embodiment. In the flowchart of FIG. 46, steps S250 to S253 are added to the flowchart of FIG.

ステップS120に続いて、予測ベクトル決定部131は、端子13より供給されるL0予測の参照インデックスが所定値Ref_idx_CScaleであるか検査する(S250)。L0予測の参照インデックスが所定値Ref_idx_CScaleであれば(S250のY)、予測ベクトル決定部131は、予測ベクトル候補リスト生成部130より供給されるL0予測の予測ベクトル候補リストから1つの予測ベクトル候補をL0予測の予測ベクトルとして選択して、L0予測の予測ベクトルインデックを決定し(S121)、当該L0予測の予測ベクトルを減算部132に供給する。   Subsequent to step S120, the prediction vector determination unit 131 checks whether the reference index of the L0 prediction supplied from the terminal 13 is a predetermined value Ref_idx_CSscale (S250). If the L0 prediction reference index is the predetermined value Ref_idx_CSscale (Y in S250), the prediction vector determination unit 131 selects one prediction vector candidate from the prediction vector candidate list of the L0 prediction supplied from the prediction vector candidate list generation unit 130. It selects as a prediction vector of L0 prediction, determines the prediction vector index of L0 prediction (S121), and supplies the prediction vector of the said L0 prediction to the subtraction part 132.

L0予測の参照インデックスが所定値Ref_idx_CScaleでなければ(S250のN)、予測ベクトル決定部131は、予測ベクトル候補リスト生成部130より供給されるL0予測の予測ベクトル候補リストから時間予測ベクトル候補と空間スケーリング予測ベクトル候補を除いた予測ベクトル候補の中から1つの予測ベクトル候補をL0予測の予測ベクトルとして選択して、L0予測の予測ベクトルインデックを決定し(S251)、当該L0予測の予測ベクトルを減算部132に供給する。   If the reference index of the L0 prediction is not the predetermined value Ref_idx_CSscale (N in S250), the prediction vector determining unit 131 uses the temporal prediction vector candidate and the space from the prediction vector candidate list of the L0 prediction supplied from the prediction vector candidate list generation unit 130. One prediction vector candidate is selected as a prediction vector for L0 prediction from prediction vector candidates excluding the scaling prediction vector candidate, a prediction vector index for L0 prediction is determined (S251), and the prediction vector for the L0 prediction is subtracted. To the unit 132.

ステップS124に続いて、予測ベクトル決定部131は、端子13より供給されるL1予測の参照インデックスが所定値Ref_idx_CScaleであるか検査する(S252)。L1予測の参照インデックスが所定値Ref_idx_CScaleであれば(S252のY)、予測ベクトル決定部131は、予測ベクトル候補リスト生成部130より供給されるL1予測の予測ベクトル候補リストから1つの予測ベクトル候補をL1予測の予測ベクトルとして選択して、L1予測の予測ベクトルインデックを決定し(S125)、当該L1予測の予測ベクトルを減算部132に供給する。   Subsequent to step S124, the prediction vector determination unit 131 checks whether the reference index of the L1 prediction supplied from the terminal 13 is the predetermined value Ref_idx_CSscale (S252). If the reference index of L1 prediction is the predetermined value Ref_idx_CSscale (Y in S252), the prediction vector determination unit 131 selects one prediction vector candidate from the prediction vector candidate list of L1 prediction supplied from the prediction vector candidate list generation unit 130. It selects as a prediction vector of L1 prediction, determines the prediction vector index of L1 prediction (S125), and supplies the prediction vector of the said L1 prediction to the subtraction part 132.

L1予測の参照インデックスが所定値Ref_idx_CScaleでなければ(S252のN)、予測ベクトル決定部131は、予測ベクトル候補リスト生成部130より供給されるL1予測の予測ベクトル候補リストから時間予測ベクトル候補と空間スケーリング予測ベクトル候補を除いた予測ベクトル候補の中から1つの予測ベクトル候補をL1予測の予測ベクトルとして選択して、L1予測の予測ベクトルインデックを決定し(S253)、当該L1予測の予測ベクトルを減算部132に供給する。   If the reference index of the L1 prediction is not the predetermined value Ref_idx_CSscale (N in S252), the prediction vector determination unit 131 determines the temporal prediction vector candidate and the space from the prediction vector candidate list of the L1 prediction supplied from the prediction vector candidate list generation unit 130. One prediction vector candidate is selected as a prediction vector for L1 prediction from prediction vector candidates excluding the scaling prediction vector candidate, a prediction vector index for L1 prediction is determined (S253), and the prediction vector for the L1 prediction is subtracted. To the unit 132.

以上のように、端子13より供給される参照インデックスが所定値Ref_idx_CScaleでない場合には、端子13より供給されて動き補償で利用される参照インデックスが示す参照画像とスケーリングの算出に利用する参照画像の不一致による差分ベクトルの符号量の増加から、スケーリング処理を伴う予測ベクトル候補の選択率が低下する。そのため、端子13より供給される参照インデックスが0でない場合には、スケーリング処理を伴う時間予測ベクトル候補と空間スケーリング予測ベクトル候補を候補外とすることで、候補選択に係る処理を削減することができる。   As described above, when the reference index supplied from the terminal 13 is not the predetermined value Ref_idx_CSscale, the reference image supplied from the terminal 13 and indicated by the reference index used for motion compensation and the reference image used for calculating the scaling are used. From the increase in the code amount of the difference vector due to the mismatch, the selection rate of the prediction vector candidate accompanied by the scaling process decreases. Therefore, when the reference index supplied from the terminal 13 is not 0, the processing related to candidate selection can be reduced by excluding the temporal prediction vector candidate accompanied by the scaling process and the spatial scaling prediction vector candidate. .

(予測ベクトル候補リスト確定部154)
予測ベクトル候補リスト確定部154の動作について説明する。図47は、実施の形態2の予測ベクトル候補リスト確定部154の動作を説明するためのフローチャートである。図47のフローチャートは、図26のフローチャートに対して、ステップS260とステップS261が追加されている点が異なる。
(Predicted vector candidate list determination unit 154)
The operation of the prediction vector candidate list determination unit 154 will be described. FIG. 47 is a flowchart for explaining the operation of the prediction vector candidate list determination unit 154 according to the second embodiment. The flowchart in FIG. 47 is different from the flowchart in FIG. 26 in that step S260 and step S261 are added.

ステップS181に続いて、予測ベクトル候補リストの予測ベクトル候補数が「予測ベクトル候補最大数−1」であるか検査する(S260)。予測ベクトル候補リストの予測ベクトル候補数が「予測ベクトル候補最大数−1」であれば(S260のY)、時間予測ベクトル候補を予測ベクトル候補リストに追加する(S182)。予測ベクトル候補リストの予測ベクトル候補数が「予測ベクトル候補最大数−1」でなければ(S260のN)、予測ベクトル候補リストの予測ベクトル候補数が「予測ベクトル候補最大数−1」に達するまで予測ベクトル補充候補を予測ベクトル候補リストに追加する(S261)。   Subsequent to step S181, it is checked whether the number of prediction vector candidates in the prediction vector candidate list is “maximum number of prediction vector candidates−1” (S260). If the number of prediction vector candidates in the prediction vector candidate list is “maximum number of prediction vector candidates−1” (Y in S260), the temporal prediction vector candidate is added to the prediction vector candidate list (S182). If the number of prediction vector candidates in the prediction vector candidate list is not “maximum number of prediction vector candidates−1” (N in S260), until the number of prediction vector candidates in the prediction vector candidate list reaches “maximum number of prediction vector candidates−1”. The prediction vector supplement candidate is added to the prediction vector candidate list (S261).

以上のように、予測ベクトル候補リストの予測ベクトル候補数が「予測ベクトル候補最大数−1」でなければ、予測ベクトル候補リストの予測ベクトル候補数が「予測ベクトル候補最大数−1」に達するまで予測ベクトル補充候補を予測ベクトル候補リストに追加することで、スケーリング処理を伴う予測ベクトル候補の予測ベクトルインデックスを予測ベクトルインデックスの最大値に固定することができる。ここでは、スケーリング処理を伴う予測ベクトル候補の予測ベクトルインデックスを予測ベクトルインデックスの最大値に固定したが、所定値に固定化できればよく、これに限定されない。   As described above, if the number of prediction vector candidates in the prediction vector candidate list is not “maximum number of prediction vector candidates−1”, the number of prediction vector candidates in the prediction vector candidate list reaches “maximum number of prediction vector candidates−1”. By adding the prediction vector supplement candidate to the prediction vector candidate list, the prediction vector index of the prediction vector candidate accompanied by the scaling process can be fixed to the maximum value of the prediction vector index. Here, the prediction vector index of the prediction vector candidate accompanied by the scaling process is fixed to the maximum value of the prediction vector index, but it is only necessary to be able to fix it to a predetermined value, and the present invention is not limited to this.

(実施の形態2の動画像復号装置)
実施の形態2の動画像復号装置の構成は、符号列解析部201の機能を除いて実施の形態1の動画像復号装置200の構成と同一である。
(Moving picture decoding apparatus according to Embodiment 2)
The configuration of the moving picture decoding apparatus according to the second embodiment is the same as that of the moving picture decoding apparatus 200 according to the first embodiment except for the function of the code string analysis unit 201.

符号列解析部201は、端子30より供給された符号列を解析して予測誤差符号化データ、マージフラグ、マージインデックス、動き補償予測の予測方向、参照インデックス、差分ベクトル、および予測ベクトルインデックスをシンタックスに従って復号する。当該予測ベクトルインデックスが予測ベクトルインデックスの最大値の場合には、参照インデックスを所定値Ref_idx_CScaleとする。そして、当該予測誤差符号化データを予測誤差復号部202に、当該マージフラグ、当該マージインデックス、当該動き補償予測の予測方向、当該参照インデックス、当該差分ベクトル、および当該予測ベクトルインデックスを動き情報再生部204に供給する。   The code string analysis unit 201 analyzes the code string supplied from the terminal 30 and compares the prediction error encoded data, the merge flag, the merge index, the prediction direction of motion compensation prediction, the reference index, the difference vector, and the prediction vector index. Decrypt according to the tax. When the prediction vector index is the maximum value of the prediction vector index, the reference index is set to a predetermined value Ref_idx_CSscale. Then, the prediction error encoded data is transferred to the prediction error decoding unit 202, and the merge flag, the merge index, the prediction direction of the motion compensated prediction, the reference index, the difference vector, and the prediction vector index are transferred to the motion information reproducing unit. 204.

以上のように、実施の形態2の動画像復号装置において、予測ベクトルインデックスが予測ベクトルインデックスの最大値の場合には、復号されない参照インデックスを所定値Ref_idx_CScaleとみなして動き情報再生部204に供給することで、実施の形態2の動画像符号化装置と矛盾のない再生画像を生成することができる。   As described above, in the video decoding device according to the second embodiment, when the prediction vector index is the maximum value of the prediction vector index, the reference index that is not decoded is regarded as the predetermined value Ref_idx_CSscale and supplied to the motion information reproduction unit 204. Thus, it is possible to generate a reproduced image that is consistent with the moving picture encoding apparatus of the second embodiment.

以上のように、実施の形態2の動画像符号化装置および動画像復号装置では、予測ベクトルインデックスが予測ベクトルインデックスの最大値の場合には、参照インデックスを符号化する必要がないため動き情報の符号量を削減することができる。   As described above, in the video encoding apparatus and video decoding apparatus according to Embodiment 2, when the prediction vector index is the maximum value of the prediction vector index, it is not necessary to encode the reference index, so that the motion information The amount of codes can be reduced.

動画像符号化装置と動画像復号装置の間で符号化ストリームをやりとりするために、有線または無線のネットワークが用いられる場合、符号化ストリームを通信路の伝送形態に適したデータ形式に変換して伝送してもよい。その場合、動画像符号化装置が出力する符号化ストリームを通信路の伝送形態に適したデータ形式の符号化データに変換してネットワークに送信する動画像送信装置と、ネットワークから符号化データを受信して符号化ストリームに復元して動画像復号装置に供給する動画像受信装置とが設けられる。   When a wired or wireless network is used to exchange an encoded stream between a moving image encoding device and a moving image decoding device, the encoded stream is converted into a data format suitable for the transmission form of the communication path. It may be transmitted. In that case, a video transmission apparatus that converts the encoded stream output from the video encoding apparatus into encoded data in a data format suitable for the transmission form of the communication channel and transmits the encoded data to the network, and receives the encoded data from the network Then, a moving image receiving apparatus that restores the encoded stream and supplies the encoded stream to the moving image decoding apparatus is provided.

動画像送信装置は、動画像符号化装置が出力する符号化ストリームをバッファするメモリと、符号化ストリームをパケット化するパケット処理部と、パケット化された符号化データをネットワークを介して送信する送信部とを含む。動画像受信装置は、パケット化された符号化データをネットワークを介して受信する受信部と、受信された符号化データをバッファするメモリと、符号化データをパケット処理して符号化ストリームを生成し、動画像復号装置に提供するパケット処理部とを含む。   The moving image transmitting apparatus is a memory that buffers the encoded stream output from the moving image encoding apparatus, a packet processing unit that packetizes the encoded stream, and transmission that transmits the packetized encoded data via the network. Part. The moving image receiving apparatus generates a coded stream by packetizing the received data, a receiving unit that receives the packetized coded data via a network, a memory that buffers the received coded data, and packet processing. And a packet processing unit provided to the video decoding device.

以上の符号化および復号に関する処理は、ハードウェアを用いた伝送、蓄積、受信装置として実現することができるのは勿論のこと、ROM(Read Only Memory)やフラッシュメモリなどに記憶されているファームウェアや、コンピュータなどのソフトウェアによっても実現することができる。そのファームウェアプログラム、ソフトウェアプログラムをコンピュータなどで読み取り可能な記録媒体に記録して提供することも、有線あるいは無線のネットワークを通してサーバから提供することも、地上波あるいは衛星ディジタル放送のデータ放送として提供することも可能である。   The above encoding and decoding processes can be realized as a transmission, storage, and reception device using hardware, as well as firmware stored in a ROM (Read Only Memory), flash memory, and the like. It can also be realized by software such as a computer. The firmware program and software program can be recorded and provided on a computer-readable recording medium, provided from a server through a wired or wireless network, or provided as a data broadcast of terrestrial or satellite digital broadcasting. Is also possible.

以上、本発明を実施の形態をもとに説明した。実施の形態は例示であり、それらの各構成要素や各処理プロセスの組合せにいろいろな変形例が可能なこと、またそうした変形例も本発明の範囲にあることは当業者に理解されるところである。   The present invention has been described based on the embodiments. The embodiments are exemplifications, and it will be understood by those skilled in the art that various modifications can be made to combinations of the respective constituent elements and processing processes, and such modifications are within the scope of the present invention. .

100 動画像符号化装置、 101 予測ブロック画像取得部、 102 減算部、 103 予測誤差符号化部、 104 符号列生成部、 105 予測誤差復号部、 106 動き補償部、 107 加算部、 108 動きベクトル検出部、 109 動き情報生成部、 110 フレームメモリ、 111 動き情報メモリ、 120 予測ベクトルモード決定部、 121 マージモード決定部、 122 予測符号化モード決定部、 130 予測ベクトル候補リスト生成部、 131 予測ベクトル決定部、 132 減算部、 140 結合動き情報候補リスト生成部、 141 結合動き情報選択部、 150 空間予測ベクトル候補生成部、 151 時間予測ベクトル候補生成部、 152 空間スケーリング予測ベクトル候補生成部、 153 予測ベクトル候補補充部、 154 予測ベクトル候補リスト確定部、 160 空間結合動き情報候補生成部、 161 時間結合動き情報候補生成部、 162 空間スケーリング結合動き情報候補生成部、 163 結合動き情報候補補充部、 164 結合動き情報候補リスト確定部、 170 基準ベクトル決定部、 171 参照インデックス設定部、 172 スケーリング部、 175 基準ベクトル決定部、 176 参照インデックス設定部、 177 スケーリング部、 180 予測方向設定部、 181 時間結合動き情報候補確定部、 185 予測方向設定部、 186 空間スケーリング結合動き情報候補確定部、 200 動画像復号装置、 201 符号列解析部、 202 予測誤差復号部、 203 加算部、 204 動き情報再生部、 205 動き補償部、 206 フレームメモリ、 207 動き情報メモリ、 210 符号化モード判定部、 211 動きベクトル再生部、 212 結合動き情報再生部、 220 予測ベクトル候補リスト生成部、 221 予測ベクトル決定部、 222 加算部、 230 結合動き情報候補生成部、 231 結合動き情報選択部。   DESCRIPTION OF SYMBOLS 100 moving image encoder, 101 prediction block image acquisition part, 102 subtraction part, 103 prediction error encoding part, 104 code stream production | generation part, 105 prediction error decoding part, 106 motion compensation part, 107 addition part, 108 motion vector detection , 109 motion information generation unit, 110 frame memory, 111 motion information memory, 120 prediction vector mode determination unit, 121 merge mode determination unit, 122 prediction coding mode determination unit, 130 prediction vector candidate list generation unit, 131 prediction vector determination , 132 subtraction unit, 140 combined motion information candidate list generation unit, 141 combined motion information selection unit, 150 spatial prediction vector candidate generation unit, 151 temporal prediction vector candidate generation unit, 152 spatial scaling prediction vector candidate generation unit, 153 Prediction vector candidate supplement unit, 154 Prediction vector candidate list determination unit, 160 Spatial joint motion information candidate generation unit, 161 Temporal joint motion information candidate generation unit, 162 Spatial scaling joint motion information candidate generation unit, 163 Joint motion information candidate supplement unit, 164 combined motion information candidate list determination unit, 170 reference vector determination unit, 171 reference index setting unit, 172 scaling unit, 175 reference vector determination unit, 176 reference index setting unit, 177 scaling unit, 180 prediction direction setting unit, 181 time combination Motion information candidate determination unit, 185 prediction direction setting unit, 186 spatial scaling combined motion information candidate determination unit, 200 video decoding device, 201 code string analysis unit, 202 prediction error decoding unit, 203 addition unit, 204 motion information Playback unit, 205 motion compensation unit, 206 frame memory, 207 motion information memory, 210 encoding mode determination unit, 211 motion vector playback unit, 212 combined motion information playback unit, 220 prediction vector candidate list generation unit, 221 prediction vector determination unit 222 addition unit, 230 combined motion information candidate generation unit, 231 combined motion information selection unit.

Claims (9)

動き補償予測を行う画像復号装置であって、
復号対象ブロックの動き補償で使用する参照画像を特定するための情報を符号化ストリームから取得する符号列解析部と、
前記復号対象ブロックの動きベクトルの予測ベクトル候補を生成するための予測ベクトル候補生成部と、を備え、
前記予測ベクトル候補生成部は、
前記復号対象ブロックに隣接する復号済みのブロックの動きベクトルの中から基準動きベクトルを決定する基準ベクトル決定部と、
スケーリング用の参照画像を特定するための情報を設定する参照画像情報設定部と、
前記スケーリング用の参照画像を特定するための情報に基づいて前記基準動きベクトルをスケーリングするスケーリング部と、を含み、
前記参照画像情報設定部は、前記スケーリング用の参照画像を、前記復号対象ブロックの動き補償で使用する参照画像に依存せずに決定する、
ことを特徴とする画像復号装置。
An image decoding apparatus that performs motion compensation prediction,
A code string analysis unit that acquires information for specifying a reference image to be used in motion compensation of a decoding target block from an encoded stream;
A prediction vector candidate generation unit for generating a prediction vector candidate of a motion vector of the decoding target block,
The prediction vector candidate generation unit
A reference vector determination unit that determines a reference motion vector from among the motion vectors of decoded blocks adjacent to the block to be decoded;
A reference image information setting unit for setting information for specifying a reference image for scaling;
A scaling unit that scales the reference motion vector based on information for specifying the reference image for scaling,
The reference image information setting unit determines the reference image for scaling without depending on a reference image used for motion compensation of the decoding target block.
An image decoding apparatus characterized by that.
前記参照画像情報設定部は、前記スケーリング用の参照画像を、前記復号対象ブロックに隣接する復号済みのブロックの動き補償に使用された参照画像をもとに決定する、
ことを特徴とする請求項1に記載の画像復号装置。
The reference image information setting unit determines the reference image for scaling based on a reference image used for motion compensation of a decoded block adjacent to the decoding target block.
The image decoding apparatus according to claim 1.
動き補償予測を行う画像復号装置であって、
復号対象ブロックに隣接する複数のブロックから動きベクトルを含むブロックを選択して予測ベクトル候補リストを生成する予測ベクトル候補リスト生成部と、
前記復号対象ブロックに隣接する複数のブロックから少なくとも参照画像情報と動きベクトルを含む動き情報を含むブロックを選択して結合動き情報候補リストを生成する結合動き情報候補リスト生成部と、
前記予測ベクトル候補リストを利用する第1予測モードと前記結合動き情報候補リストを利用する第2予測モードのどちらの予測モードを利用するかを選択する予測モード選択部と、
符号化ストリームから予測モードを特定するための情報を取得し、前記予測モードが第1予測モードの場合には、前記符号化ストリームから前記予測ベクトル候補リスト内における予測ベクトルの位置を示す予測ベクトルを特定するための情報、差分ベクトル、および前記復号対象ブロックの参照画像を特定するための情報を取得し、前記予測モードが第2予測モードの場合には、前記符号化ストリームから前記結合動き情報候補リスト内における動き情報の位置を示す動き情報を特定するための情報を取得する符号列解析部と、
前記予測ベクトルを特定するための情報をもとに、前記予測ベクトル候補リストに含まれる予測ベクトル候補の中から前記復号対象ブロックの予測ベクトルを選択する予測ベクトル選択部と、
前記予測ベクトルと前記差分ベクトルを加算して前記復号対象ブロックの動きベクトルを再生する動きベクトル再生部と、
前記動き情報を特定するための情報をもとに、前記結合動き情報候補リストに含まれる動き情報候補の中から前記復号対象ブロックの動き情報を選択する結合動き情報選択部と、
前記予測モードが第1予測モードの場合には前記参照画像を特定するための情報によって特定される参照画像と前記再生された動きベクトルを用いて予測信号を生成し、前記予測モードが第2予測モードである場合には前記選択された動き情報に含まれる参照画像情報で特定される参照画像と前記選択された動き情報に含まれる動きベクトルを用いて予測信号を生成する動き補償部と、
復号対象ブロックに隣接する復号済みのブロックであって、前記復号対象ブロックを含む画像と時間的に異なる画像に含まれるブロックの動きベクトルをスケーリングするスケーリング部と、を備え、
前記スケーリング部によりスケーリングされた動きベクトルは、前記第1予測モードおよび前記第2予測モードで共用される、
ことを特徴とする画像復号装置。
An image decoding apparatus that performs motion compensation prediction,
A prediction vector candidate list generation unit that generates a prediction vector candidate list by selecting a block including a motion vector from a plurality of blocks adjacent to a decoding target block;
A combined motion information candidate list generation unit that generates a combined motion information candidate list by selecting a block including motion information including at least reference image information and a motion vector from a plurality of blocks adjacent to the decoding target block;
A prediction mode selection unit that selects which one of the first prediction mode that uses the prediction vector candidate list and the second prediction mode that uses the combined motion information candidate list;
Information for specifying a prediction mode is obtained from the encoded stream, and when the prediction mode is the first prediction mode, a prediction vector indicating the position of the prediction vector in the prediction vector candidate list is obtained from the encoded stream. Information for specifying, a difference vector, and information for specifying a reference image of the decoding target block are acquired, and when the prediction mode is the second prediction mode, the combined motion information candidate from the encoded stream A code string analyzer that acquires information for specifying motion information indicating the position of the motion information in the list;
Based on information for specifying the prediction vector, a prediction vector selection unit that selects a prediction vector of the block to be decoded from prediction vector candidates included in the prediction vector candidate list;
A motion vector reproduction unit that adds the prediction vector and the difference vector to reproduce the motion vector of the decoding target block;
Based on information for specifying the motion information, a combined motion information selection unit that selects motion information of the decoding target block from among motion information candidates included in the combined motion information candidate list;
When the prediction mode is the first prediction mode, a prediction signal is generated using the reference image specified by the information for specifying the reference image and the reproduced motion vector, and the prediction mode is the second prediction mode. A motion compensation unit that generates a prediction signal using a reference image specified by reference image information included in the selected motion information and a motion vector included in the selected motion information when the mode is selected;
A scaling unit that scales a motion vector of a block that is a decoded block adjacent to the decoding target block and that is included in an image that is temporally different from the image including the decoding target block;
The motion vector scaled by the scaling unit is shared by the first prediction mode and the second prediction mode.
An image decoding apparatus characterized by that.
動き補償予測を行う画像復号装置であって、
符号化ストリームから予測ベクトルを特定するための情報を取得する符号列解析部と、
復号対象ブロックに隣接する複数のブロックを第1の順序で検査して、動きベクトルを含むブロックの動きベクトルを空間予測ベクトル候補とする空間予測ベクトル候補生成部と、
前記復号対象ブロックに隣接する複数のブロックを第2の順序で検査して、動きベクトルを含むブロックの動きベクトルをスケーリングしたスケーリング動きベクトルを空間スケーリング予測ベクトル候補とする空間スケーリング予測ベクトル候補生成部と、
少なくとも前記空間予測ベクトル候補と前記空間スケーリング予測ベクトル候補を含む候補リストを生成する候補リスト生成部と、
前記符号化ストリームから取得された予測ベクトルを特定するための情報をもとに、前記候補リストに含まれる予測ベクトル候補の中から前記復号対象ブロックの予測ベクトルを選択する予測ベクトル選択部と、
を備えることを特徴とする画像復号装置。
An image decoding apparatus that performs motion compensation prediction,
A code string analysis unit that acquires information for specifying a prediction vector from the encoded stream;
A spatial prediction vector candidate generation unit that inspects a plurality of blocks adjacent to a decoding target block in a first order and uses a motion vector of a block including a motion vector as a spatial prediction vector candidate;
A spatial scaling prediction vector candidate generation unit which examines a plurality of blocks adjacent to the decoding target block in a second order and sets a scaling motion vector obtained by scaling a motion vector of a block including a motion vector as a spatial scaling prediction vector candidate; ,
A candidate list generating unit that generates a candidate list including at least the spatial prediction vector candidates and the spatial scaling prediction vector candidates;
Based on information for specifying a prediction vector acquired from the encoded stream, a prediction vector selection unit that selects a prediction vector of the decoding target block from prediction vector candidates included in the candidate list;
An image decoding apparatus comprising:
動き補償予測を行う画像復号装置であって、
復号対象ブロックに隣接する複数のブロックから動きベクトルを含むブロックを選択して候補リストを生成する候補リスト生成部と、
符号化ストリームから前記候補リスト内における予測ベクトルの位置を示す予測ベクトルを特定するための情報、差分ベクトル、および前記復号対象ブロックの参照画像を特定するための情報を取得する符号列解析部と、
前記予測ベクトルを特定するための情報をもとに、前記候補リストに含まれる予測ベクトル候補の中から前記復号対象ブロックの予測ベクトルを選択する予測ベクトル選択部と、
前記予測ベクトルと前記差分ベクトルを加算して前記復号対象ブロックの動きベクトルを算出する動きベクトル再生部と、を備え、
前記予測ベクトルを特定するための情報が所定値である場合、前記参照画像を特定するための情報が省略されている、
ことを特徴とする画像復号装置。
An image decoding apparatus that performs motion compensation prediction,
A candidate list generating unit that generates a candidate list by selecting a block including a motion vector from a plurality of blocks adjacent to a decoding target block;
A code string analysis unit that acquires information for specifying a prediction vector indicating a position of a prediction vector in the candidate list from a coded stream, a difference vector, and information for specifying a reference image of the decoding target block;
Based on information for specifying the prediction vector, a prediction vector selection unit that selects a prediction vector of the decoding target block from prediction vector candidates included in the candidate list;
A motion vector reproducing unit that calculates the motion vector of the block to be decoded by adding the prediction vector and the difference vector;
When the information for specifying the prediction vector is a predetermined value, the information for specifying the reference image is omitted.
An image decoding apparatus characterized by that.
動き補償予測を行う画像復号方法であって、
復号対象ブロックの動き補償で使用する参照画像を特定するための情報を符号化ストリームから取得するステップと、
前記復号対象ブロックの動きベクトルの予測ベクトル候補を生成するステップと、を備え、
前記予測ベクトル候補を生成するステップは、
前記復号対象ブロックに隣接する復号済みのブロックの動きベクトルの中から基準動きベクトルを決定するステップと、
スケーリング用の参照画像を特定するための情報を設定するステップと、
前記スケーリング用の参照画像を特定するための情報に基づいて前記基準動きベクトルをスケーリングするステップと、を含み、
前記スケーリング用の参照画像を特定するための情報を設定するステップは、前記スケーリング用の参照画像を、前記復号対象ブロックの動き補償で使用する参照画像に依存せずに決定する、
ことを特徴とする画像復号方法。
An image decoding method for performing motion compensation prediction,
Obtaining information for identifying a reference image to be used in motion compensation of a decoding target block from an encoded stream;
Generating a prediction vector candidate of a motion vector of the decoding target block, and
The step of generating the prediction vector candidate includes
Determining a reference motion vector from motion vectors of decoded blocks adjacent to the decoding target block;
Setting information for identifying a reference image for scaling;
Scaling the reference motion vector based on information for identifying the reference image for scaling,
The step of setting information for specifying the reference image for scaling determines the reference image for scaling without depending on the reference image used for motion compensation of the decoding target block.
An image decoding method characterized by the above.
動き補償予測を行う画像復号方法であって、
復号対象ブロックに隣接する複数のブロックから動きベクトルを含むブロックを選択して予測ベクトル候補リストを生成するステップと、
前記復号対象ブロックに隣接する複数のブロックから少なくとも参照画像情報と動きベクトルを含む動き情報を含むブロックを選択して結合動き情報候補リストを生成するステップと、
前記予測ベクトル候補リストを利用する第1予測モードと前記結合動き情報候補リストを利用する第2予測モードのどちらの予測モードを利用するかを選択するステップと、
符号化ストリームから予測モードを特定するための情報を取得し、前記予測モードが第1予測モードの場合には、前記符号化ストリームから前記予測ベクトル候補リスト内における予測ベクトルの位置を示す予測ベクトルを特定するための情報、差分ベクトル、および前記復号対象ブロックの参照画像を特定するための情報を取得し、前記予測モードが第2予測モードの場合には、前記符号化ストリームから前記結合動き情報候補リスト内における動き情報の位置を示す動き情報を特定するための情報を取得するステップと、
前記予測ベクトルを特定するための情報をもとに、前記予測ベクトル候補リストに含まれる予測ベクトル候補の中から前記復号対象ブロックの予測ベクトルを選択するステップと、
前記予測ベクトルと前記差分ベクトルを加算して前記復号対象ブロックの動きベクトルを再生するステップと、
前記動き情報を特定するための情報をもとに、前記結合動き情報候補リストに含まれる動き情報候補の中から前記復号対象ブロックの動き情報を選択するステップと、
前記予測モードが第1予測モードの場合には前記参照画像を特定するための情報によって特定される参照画像と前記再生された動きベクトルを用いて予測信号を生成し、前記予測モードが第2予測モードである場合には前記選択された動き情報に含まれる参照画像情報で特定される参照画像と前記選択された動き情報に含まれる動きベクトルを用いて予測信号を生成するステップと、
復号対象ブロックに隣接する復号済みのブロックであって、前記復号対象ブロックを含む画像と時間的に異なる画像に含まれるブロックの動きベクトルをスケーリングするステップと、を備え、
スケーリングされた動きベクトルは、前記第1予測モードおよび前記第2予測モードで共用される、
ことを特徴とする画像復号方法。
An image decoding method for performing motion compensation prediction,
Selecting a block including a motion vector from a plurality of blocks adjacent to the decoding target block to generate a prediction vector candidate list;
Selecting a block including motion information including at least reference image information and a motion vector from a plurality of blocks adjacent to the decoding target block to generate a combined motion information candidate list;
Selecting which prediction mode to use, the first prediction mode using the prediction vector candidate list or the second prediction mode using the combined motion information candidate list;
Information for specifying a prediction mode is obtained from the encoded stream, and when the prediction mode is the first prediction mode, a prediction vector indicating the position of the prediction vector in the prediction vector candidate list is obtained from the encoded stream. Information for specifying, a difference vector, and information for specifying a reference image of the decoding target block are acquired, and when the prediction mode is the second prediction mode, the combined motion information candidate from the encoded stream Obtaining information for identifying motion information indicating the position of motion information in the list;
Selecting a prediction vector of the decoding target block from prediction vector candidates included in the prediction vector candidate list based on information for specifying the prediction vector;
Adding the prediction vector and the difference vector to reproduce the motion vector of the decoding target block;
Selecting motion information of the decoding target block from motion information candidates included in the combined motion information candidate list based on information for specifying the motion information;
When the prediction mode is the first prediction mode, a prediction signal is generated using the reference image specified by the information for specifying the reference image and the reproduced motion vector, and the prediction mode is the second prediction mode. Generating a prediction signal using a reference image specified by reference image information included in the selected motion information and a motion vector included in the selected motion information when the mode is selected;
Scaling a motion vector of a block that is a decoded block adjacent to the decoding target block and is included in an image temporally different from the image including the decoding target block;
The scaled motion vector is shared by the first prediction mode and the second prediction mode.
An image decoding method characterized by the above.
動き補償予測を行う画像復号プログラムであって、
復号対象ブロックの動き補償で使用する参照画像を特定するための情報を符号化ストリームから取得する処理と、
前記復号対象ブロックの動きベクトルの予測ベクトル候補を生成する処理と、コンピュータに実行させ、
前記予測ベクトル候補を生成する処理は、
前記復号対象ブロックに隣接する復号済みのブロックの動きベクトルの中から基準動きベクトルを決定する処理と、
スケーリング用の参照画像を特定するための情報を設定する処理と、
前記スケーリング用の参照画像を特定するための情報に基づいて前記基準動きベクトルをスケーリングする処理と、をコンピュータに実行させ、
前記スケーリング用の参照画像を特定するための情報を設定する処理は、前記スケーリング用の参照画像を、前記復号対象ブロックの動き補償で使用する参照画像に依存せずに決定する、
ことを特徴とする画像復号プログラム。
An image decoding program for performing motion compensation prediction,
Processing for acquiring information for specifying a reference image used in motion compensation of a decoding target block from an encoded stream;
A process of generating motion vector prediction vector candidates of the decoding target block, and causing the computer to execute,
The process of generating the prediction vector candidate is
A process of determining a reference motion vector from motion vectors of decoded blocks adjacent to the decoding target block;
A process for setting information for specifying a reference image for scaling;
Causing the computer to perform a process of scaling the reference motion vector based on information for specifying the scaling reference image,
The process of setting information for identifying the reference image for scaling determines the reference image for scaling without depending on the reference image used for motion compensation of the decoding target block.
An image decoding program characterized by the above.
動き補償予測を行う画像復号プログラムであって、
復号対象ブロックに隣接する複数のブロックから動きベクトルを含むブロックを選択して予測ベクトル候補リストを生成する処理と、
前記復号対象ブロックに隣接する複数のブロックから少なくとも参照画像情報と動きベクトルを含む動き情報を含むブロックを選択して結合動き情報候補リストを生成する処理と、
前記予測ベクトル候補リストを利用する第1予測モードと前記結合動き情報候補リストを利用する第2予測モードのどちらの予測モードを利用するかを選択する処理と、
符号化ストリームから予測モードを特定するための情報を取得し、前記予測モードが第1予測モードの場合には、前記符号化ストリームから前記予測ベクトル候補リスト内における予測ベクトルの位置を示す予測ベクトルを特定するための情報、差分ベクトル、および前記復号対象ブロックの参照画像を特定するための情報を取得し、前記予測モードが第2予測モードの場合には、前記符号化ストリームから前記結合動き情報候補リスト内における動き情報の位置を示す動き情報を特定するための情報を取得する処理と、
前記予測ベクトルを特定するための情報をもとに、前記予測ベクトル候補リストに含まれる予測ベクトル候補の中から前記復号対象ブロックの予測ベクトルを選択する処理と、
前記予測ベクトルと前記差分ベクトルを加算して前記復号対象ブロックの動きベクトルを再生する処理と、
前記動き情報を特定するための情報をもとに、前記結合動き情報候補リストに含まれる動き情報候補の中から前記復号対象ブロックの動き情報を選択する処理と、
前記予測モードが第1予測モードの場合には前記参照画像を特定するための情報によって特定される参照画像と前記再生された動きベクトルを用いて予測信号を生成し、前記予測モードが第2予測モードである場合には前記選択された動き情報に含まれる参照画像情報で特定される参照画像と前記選択された動き情報に含まれる動きベクトルを用いて予測信号を生成する処理と、
復号対象ブロックに隣接する復号済みのブロックであって、前記復号対象ブロックを含む画像と時間的に異なる画像に含まれるブロックの動きベクトルをスケーリングする処理と、をコンピュータに実行させ、
スケーリングされた動きベクトルは、前記第1予測モードおよび前記第2予測モードで共用される、
ことを特徴とする画像復号プログラム。
An image decoding program for performing motion compensation prediction,
A process of selecting a block including a motion vector from a plurality of blocks adjacent to a decoding target block to generate a prediction vector candidate list;
A process of generating a combined motion information candidate list by selecting a block including motion information including at least reference image information and a motion vector from a plurality of blocks adjacent to the decoding target block;
A process of selecting which prediction mode to use, the first prediction mode using the prediction vector candidate list or the second prediction mode using the combined motion information candidate list;
Information for specifying a prediction mode is obtained from the encoded stream, and when the prediction mode is the first prediction mode, a prediction vector indicating the position of the prediction vector in the prediction vector candidate list is obtained from the encoded stream. Information for specifying, a difference vector, and information for specifying a reference image of the decoding target block are acquired, and when the prediction mode is the second prediction mode, the combined motion information candidate from the encoded stream Processing for acquiring information for identifying motion information indicating the position of motion information in the list;
Based on information for specifying the prediction vector, a process of selecting a prediction vector of the decoding target block from prediction vector candidates included in the prediction vector candidate list;
A process of adding the prediction vector and the difference vector to reproduce the motion vector of the decoding target block;
Based on the information for specifying the motion information, a process of selecting motion information of the decoding target block from motion information candidates included in the combined motion information candidate list;
When the prediction mode is the first prediction mode, a prediction signal is generated using the reference image specified by the information for specifying the reference image and the reproduced motion vector, and the prediction mode is the second prediction mode. A process for generating a prediction signal using a reference image specified by reference image information included in the selected motion information and a motion vector included in the selected motion information when the mode is selected;
A process of scaling a motion vector of a block that is a decoded block adjacent to the decoding target block and is included in an image temporally different from the image including the decoding target block;
The scaled motion vector is shared by the first prediction mode and the second prediction mode.
An image decoding program characterized by the above.
JP2011177180A 2011-08-12 2011-08-12 Image decoding apparatus, image decoding method and image decoding program Withdrawn JP2013042304A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2011177180A JP2013042304A (en) 2011-08-12 2011-08-12 Image decoding apparatus, image decoding method and image decoding program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011177180A JP2013042304A (en) 2011-08-12 2011-08-12 Image decoding apparatus, image decoding method and image decoding program

Publications (1)

Publication Number Publication Date
JP2013042304A true JP2013042304A (en) 2013-02-28

Family

ID=47890309

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011177180A Withdrawn JP2013042304A (en) 2011-08-12 2011-08-12 Image decoding apparatus, image decoding method and image decoding program

Country Status (1)

Country Link
JP (1) JP2013042304A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6075898B1 (en) * 2015-08-31 2017-02-08 日本電信電話株式会社 Video encoding apparatus, video encoding method, and program

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6075898B1 (en) * 2015-08-31 2017-02-08 日本電信電話株式会社 Video encoding apparatus, video encoding method, and program
US10034011B2 (en) 2015-08-31 2018-07-24 Nippon Telegraph And Telephone Corporation Video coding apparatus

Similar Documents

Publication Publication Date Title
TWI594624B (en) Video encoding device, video encoding method and recording medium storing video encoding program
WO2013001803A1 (en) Image encoding device, image encoding method, image encoding program, image decoding device, image decoding method, and image decoding program
JP6135750B2 (en) Image encoding device, image encoding method, image encoding program, transmission device, transmission method, and transmission program
JP2013121167A (en) Image encoder, image encoding method, and image encoding program
JP5678924B2 (en) Image decoding apparatus, image decoding method, and image decoding program, and receiving apparatus, receiving method, and receiving program
JP6036972B2 (en) Moving picture decoding apparatus, moving picture decoding method, moving picture decoding program, receiving apparatus, receiving method, and receiving program
JP5846133B2 (en) Moving picture decoding apparatus, moving picture decoding method, moving picture decoding program, receiving apparatus, receiving method, and receiving program
JP2013042304A (en) Image decoding apparatus, image decoding method and image decoding program
JP2013077897A (en) Image decoding device, image decoding method and image decoding program
JP2013042303A (en) Image encoding apparatus, image encoding method and image encoding program
JP2013077896A (en) Image encoding device, image encoding method and image encoding program
JP2013021573A (en) Image decoder, image decoding method, and image decoding program
JP2013121163A (en) Image encoding device, image encoding method, and image encoding program
JP2013121164A (en) Image decoding device, image decoding method, and image decoding program
JP2013121168A (en) Image decoder, image decoding method and image decoding program
JP2013021572A (en) Image encoder, image encoding method, and image encoding program
JP2013121165A (en) Image encoding device, image encoding method, and image encoding program
JP2013021505A (en) Moving image decoding device, moving image decoding method, and moving image decoding program
JP2013021504A (en) Moving image encoding device, moving image encoding method, and moving image encoding program
JP2013121166A (en) Image decoding device, image decoding method, and image decoding program

Legal Events

Date Code Title Description
A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20141104