JP2017228827A - Intra-prediction device, image coding device, image decoding device, and program - Google Patents

Intra-prediction device, image coding device, image decoding device, and program Download PDF

Info

Publication number
JP2017228827A
JP2017228827A JP2016121542A JP2016121542A JP2017228827A JP 2017228827 A JP2017228827 A JP 2017228827A JP 2016121542 A JP2016121542 A JP 2016121542A JP 2016121542 A JP2016121542 A JP 2016121542A JP 2017228827 A JP2017228827 A JP 2017228827A
Authority
JP
Japan
Prior art keywords
intra prediction
prediction mode
error index
mpm
unit
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.)
Granted
Application number
JP2016121542A
Other languages
Japanese (ja)
Other versions
JP6796405B2 (en
Inventor
井口 和久
Kazuhisa Iguchi
和久 井口
和博 千田
Kazuhiro Senda
和博 千田
市ヶ谷 敦郎
Atsuro Ichigaya
敦郎 市ヶ谷
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.)
Japan Broadcasting Corp
Original Assignee
Nippon Hoso Kyokai NHK
Japan Broadcasting 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 Nippon Hoso Kyokai NHK, Japan Broadcasting Corp filed Critical Nippon Hoso Kyokai NHK
Priority to JP2016121542A priority Critical patent/JP6796405B2/en
Publication of JP2017228827A publication Critical patent/JP2017228827A/en
Application granted granted Critical
Publication of JP6796405B2 publication Critical patent/JP6796405B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

PROBLEM TO BE SOLVED: To improve the encoding efficiency of an intra-prediction mode.SOLUTION: An error index acquisition unit acquires an error index between a predicted image obtained by using an intra-prediction mode determining about a reference block around an object block and an input image. An order determination unit determines an ascending order of error indexes as the order of intra-prediction mode candidates, when using the intra-prediction mode determining the reference block as the intra-prediction mode of the object block.SELECTED DRAWING: Figure 1

Description

本発明は、イントラ予測器、画像符号化装置、画像復号装置およびプログラムに関する。   The present invention relates to an intra predictor, an image encoding device, an image decoding device, and a program.

代表的な動画圧縮方式の一つとして、MPEG−H HEVC/ITU−T H.265方式(Moving Picture Expert Group−H ISO/IEC 23008 High Efficiency Video Coding/International Telecommunication Union−Telecommunication Standardization Sector−T Recommendation H.265;以下、HEVC方式と呼ぶ)がある。HEVC方式では、イントラ予測においてMPM(Most Probable Mode)と呼ばれるイントラ予測モード候補のグループが用いられている。   As one of the typical video compression methods, MPEG-H HEVC / ITU-TH. H265 (Moving Picture Expert Group-H ISO / IEC 23008 High Efficiency Video Coding / International Telecommunication Union-Telecommunication Sect. In the HEVC scheme, a group of intra prediction mode candidates called MPM (Most Probable Mode) is used in intra prediction.

HEVC方式のMPMは、イントラ予測の対象ブロックごとに構成され、それぞれ3つのイントラ予測モードの候補(以下、イントラ予測モード候補と呼ぶ)を含む。原則として、MPM内の3つのイントラ予測モード候補の0番目が対象ブロックの左の参照ブロック(以下、左ブロックと呼ぶ)のイントラ予測モード、1番目が対象ブロックの上の参照ブロック(以下、右ブロックと呼ぶ)のイントラ予測モード、2番目がプレーナモード、として定められている。但し、左ブロックや上ブロックが利用できない場合、左ブロックのイントラ予測モードと右ブロックのイントラ予測モードが一致している場合などの例外についても、MPM内のイントラ予測モード候補とその順位が定められている。   The HEVC MPM is configured for each intra prediction target block, and includes three intra prediction mode candidates (hereinafter referred to as intra prediction mode candidates). In principle, the 0th of the three intra prediction mode candidates in the MPM is the intra prediction mode of the left reference block (hereinafter referred to as the left block) of the target block, and the first is the reference block above the target block (hereinafter, the right block). Intra prediction mode (referred to as a block), and the second is defined as a planar mode. However, in cases where the left block or the upper block cannot be used or the intra prediction mode of the left block matches the intra prediction mode of the right block, the intra prediction mode candidates in the MPM and their ranks are determined. ing.

また、HEVC方式では、イントラ予測モードの符号化ストリームには、(a)MPM内のイントラ予測モードの使用の有無を示すフラグ、(b)MPM内の0番目のイントラ予測モード候補の使用の有無を示すフラグおよび(c)MPM内の1番目のイントラ予測モード候補の使用の有無を示すフラグが含まれる。符号化ストリームにおいて、フラグ(a)−(c)が、その順序で配列される。フラグ(b)およびフラグ(c)は、フラグ(a)の値がtrueである場合のみ存在し、フラグ(c)は、フラグ(b)の値がfalseである場合のみ存在する。従って、MPM内のイントラ予測モード候補のうちMPM内の順位が0番目のイントラ予測モード候補が使用される場合には、フラグ(a)とフラグ(b)が符号化ストリームに含まれる。つまり、イントラ予測モードの情報量は2ビットで済む。他方、1番目または2番目のイントラ予測モード候補が使用される場合には、符号化ストリームに含まれるフラグは、フラグ(a)、フラグ(b)およびフラグ(c)がいずれも符号化ストリームに含まれる。つまり、イントラ予測モードの符号化には3ビットの情報量が必要になる。従って、MPMを用いてイントラ予測モードを符号化する際、イントラ予測モード候補のMPM内の順位(以下、MPM内順位、と呼ぶ)が符号化によって発生する符号化ストリームの発生情報量に影響する。   In the HEVC scheme, the intra prediction mode encoded stream includes (a) a flag indicating whether or not the intra prediction mode in the MPM is used, and (b) whether or not the 0th intra prediction mode candidate in the MPM is used. And (c) a flag indicating whether or not the first intra prediction mode candidate in the MPM is used. In the encoded stream, flags (a) to (c) are arranged in that order. The flag (b) and the flag (c) exist only when the value of the flag (a) is true, and the flag (c) exists only when the value of the flag (b) is false. Therefore, when the intra prediction mode candidate with the rank 0 in the MPM is used among the intra prediction mode candidates in the MPM, the flag (a) and the flag (b) are included in the encoded stream. That is, the information amount in the intra prediction mode is 2 bits. On the other hand, when the first or second intra prediction mode candidate is used, flags (a), (b), and (c) are all included in the encoded stream. included. That is, 3 bits of information is required for encoding in the intra prediction mode. Therefore, when the intra prediction mode is encoded using the MPM, the rank in the MPM of the intra prediction mode candidate (hereinafter referred to as MPM rank) affects the amount of information generated in the encoded stream generated by the encoding. .

特開2013−081100号公報JP2013-081100A

従来の符号化方式、例えば、HEVC方式や特許文献1に記載の符号化処理では、MPMの順位がイントラ予測モード候補の空間的な位置関係に基づいて定められていた。そのため、従来の符号化方式ではイントラ予測モードの符号化効率が必ずしも高くならないという課題が生じていた。   In the conventional encoding method, for example, the HEVC method or the encoding process described in Patent Document 1, the rank of the MPM is determined based on the spatial positional relationship of the intra prediction mode candidates. Therefore, the conventional coding method has a problem that the coding efficiency of the intra prediction mode is not necessarily increased.

本発明は上記の点に鑑みてなされたものであり、イントラ予測モードの符号化効率を向上することができるイントラ予測器、画像符号化装置、画像復号装置およびプログラムを提供することを目的とする。   The present invention has been made in view of the above points, and an object thereof is to provide an intra predictor, an image encoding device, an image decoding device, and a program capable of improving the encoding efficiency of the intra prediction mode. .

本発明は上記の課題を解決するためになされたものであり、[1]本発明の一態様は、対象ブロックの周囲の参照ブロックについて定めたイントラ予測モードを用いて得られた予測画像と入力画像との誤差指標を取得する誤差指標取得部と、前記対象ブロックのイントラ予測モード候補として、前記参照ブロックについて定めたイントラ予測モードを用いるとき、前記イントラ予測モード候補の順位を前記誤差指標の昇順に定める順位決定部と、を備えるイントラ予測器である。
[1]の構成によれば、入力画像との誤差量が最も小さくなる予測画像を与える代表イントラ予測モードが、順位が高いイントラ予測モード候補と一致する可能性が高くなる。そのため、イントラ予測モードの符号化に係るイントラ予測モード候補の数、即ちその符号化ビット数を少なくすることができる。
The present invention has been made to solve the above problems. [1] According to one aspect of the present invention, a prediction image obtained by using an intra prediction mode defined for reference blocks around a target block and an input are input. When using an error index acquisition unit for acquiring an error index with respect to an image and an intra prediction mode defined for the reference block as an intra prediction mode candidate of the target block, the rank of the intra prediction mode candidates is increased in ascending order of the error index. An intra predictor comprising:
According to the configuration of [1], there is a high possibility that the representative intra prediction mode that gives the predicted image with the smallest amount of error from the input image matches the intra prediction mode candidate with the higher rank. Therefore, it is possible to reduce the number of intra prediction mode candidates related to encoding in the intra prediction mode, that is, the number of encoded bits.

[2]本発明の一態様は、上述のイントラ予測器であって、前記順位決定部は、前記イントラ予測モード候補として、所定の誤差指標の閾値よりも大きい前記誤差指標を与える前記参照ブロックのイントラ予測モードの順位を、所定のイントラ予測モード候補の順位よりも低くすることを特徴とする。
[2]の構成によれば、所定の誤差指標の閾値より大きい誤差指標を与える参照画素に係るイントラ予測モードのイントラ予測モード候補の順位が、所定のイントラ予測モード候補よりも低くなる。そのため、イントラ予測モードの符号化において、より誤差指標が小さいイントラ予測モード候補が優先して利用される。そのため、参照ブロックに係るイントラ予測モードのみよりも、対象ブロックに係るイントラ予測モードの符号化において用いるイントラ予測モード候補の数、即ち符号化ビット数を少なくすることができる。
[2] One aspect of the present invention is the intra predictor described above, wherein the rank determination unit includes the reference block that gives the error index larger than a predetermined error index threshold as the intra prediction mode candidate. The intra-prediction mode rank is lower than a predetermined intra-prediction mode candidate rank.
According to the configuration of [2], the rank of the intra prediction mode candidate in the intra prediction mode related to the reference pixel that gives an error index larger than the predetermined error index threshold is lower than that of the predetermined intra prediction mode candidate. Therefore, in the intra prediction mode encoding, the intra prediction mode candidate having a smaller error index is preferentially used. Therefore, it is possible to reduce the number of intra prediction mode candidates used in encoding the intra prediction mode related to the target block, that is, the number of encoded bits, rather than only the intra prediction mode related to the reference block.

[3]本発明の一態様は、上述のイントラ予測器であって、前記誤差指標取得部は、前記参照ブロックについて定めたイントラ予測モードに係る誤差指標の範囲に基づいて前記誤差指標の閾値を定めることを特徴とする。
[3]の構成によれば、イントラ予測モードの符号化において、定めた誤差指標の閾値に基づいて、参照画素に係るイントラ予測モードよりも誤差指標が小さい所定のイントラ予測モード候補を優先して利用するか否かが判定される。よって、常に一定の誤差指標の閾値よりも大きい誤差指標を与える参照ブロックのイントラ予測モードの順位を所定のイントラ予測モード候補の順位よりも低くするよりも、イントラ予測モードの符号化ビット数を少なくすることができる。
[3] One aspect of the present invention is the intra predictor described above, wherein the error index acquisition unit sets a threshold value of the error index based on a range of an error index related to an intra prediction mode determined for the reference block. It is characterized by defining.
According to the configuration of [3], in encoding of the intra prediction mode, a predetermined intra prediction mode candidate having a smaller error index than the intra prediction mode related to the reference pixel is prioritized based on a predetermined error index threshold. It is determined whether or not to use. Therefore, the number of encoded bits in the intra prediction mode is smaller than the order of the intra prediction mode of the reference block that always gives an error index larger than a certain error index threshold than the rank of the predetermined intra prediction mode candidate. can do.

[4]本発明の一態様は、上述のイントラ予測器であって、前記誤差指標取得部は、前記誤差指標として前記予測画像に基づく予測残差の量子化変換係数を可変長符号化して得られるビット列のビット数を取得することを特徴とする。
[4]の構成によれば、イントラ予測モード候補の順位が、それぞれのイントラ予測モード候補を用いて生成されたイントラ予測画像に基づく予測残差のビット列のビット数の昇順に定められる。予測残差の大きさとしてそのビット数が少ないイントラ予測モード候補が、対象ブロックに係るイントラ予測モードと一致する可能性が高くなるため、イントラ予測モードの符号化に係る符号化ビット数を少なくすることができる。
[4] One aspect of the present invention is the intra predictor described above, wherein the error index acquisition unit obtains a quantization transform coefficient of a prediction residual based on the prediction image as the error index by variable length encoding. The number of bits of the bit string to be obtained is obtained.
According to the configuration of [4], the ranking of the intra prediction mode candidates is determined in ascending order of the number of bits of the bit string of the prediction residual based on the intra prediction image generated using each intra prediction mode candidate. Intra prediction mode candidates with a small number of bits as the size of the prediction residual are more likely to match the intra prediction mode related to the target block, so the number of coding bits related to the coding of the intra prediction mode is reduced. be able to.

[5]本発明の一態様は、上述のイントラ予測器であって、前記誤差指標取得部は、前記誤差指標として前記予測画像に基づく予測残差の量子化変換係数のうち零以外の値を有する非零変換係数の数を取得することを特徴とする。
この構成によれば、イントラ予測モード候補の順位が、それぞれのイントラ予測モード候補を用いて生成されたイントラ予測画像に基づく予測残差の非零変換係数の数が少ないイントラ予測モード候補が、対象ブロックに係るイントラ予測モードと一致する可能性が高くなる。そのため、イントラ予測モードの符号化に係る符号化ビット数を少なくすることができる。
[5] One aspect of the present invention is the above-described intra predictor, wherein the error index acquisition unit sets a value other than zero among the quantized transform coefficients of a prediction residual based on the predicted image as the error index. The number of non-zero transform coefficients is obtained.
According to this configuration, the intra prediction mode candidates are ranked with a small number of non-zero transform coefficients of the prediction residual based on the intra prediction image generated using each intra prediction mode candidate. There is a high possibility of matching with the intra prediction mode related to the block. Therefore, it is possible to reduce the number of encoded bits related to the intra prediction mode encoding.

[6]本発明の一態様は、上述のイントラ予測器であって、前記誤差指標取得部は、前記誤差指標として前記予測画像に基づく予測残差の量子化変換係数の二乗和を取得する。
[6]の構成によれば、イントラ予測モード候補の順位が、それぞれのイントラ予測モード候補を用いて生成されたイントラ予測画像に基づく予測残差の量子化変換係数の二乗和が小さいイントラ予測モード候補が、対象ブロックに係るイントラ予測モードと一致する可能性が高くなる。よって、イントラ予測モードの符号化に係る符号化ビット数を少なくすることができる。
[6] One aspect of the present invention is the intra predictor described above, wherein the error index acquisition unit acquires a square sum of the quantized transform coefficients of a prediction residual based on the predicted image as the error index.
According to the configuration of [6], an intra prediction mode in which the ranks of intra prediction mode candidates are small in the sum of squares of quantized transform coefficients of prediction residuals based on intra prediction images generated using the respective intra prediction mode candidates. There is a high possibility that the candidate matches the intra prediction mode related to the target block. Therefore, it is possible to reduce the number of encoded bits related to encoding in the intra prediction mode.

[7]本発明の一態様は、上述のイントラ予測器であって、前記誤差指標取得部は、前記誤差指標として前記予測画像に基づく予測残差の量子化変換係数の絶対値和を取得する。
[7]の構成によれば、イントラ予測モード候補の順位が、それぞれのイントラ予測モード候補を用いて生成されたイントラ予測画像に基づく予測残差の量子化変換係数の絶対値和が小さいイントラ予測モード候補が、対象ブロックに係るイントラ予測モードと一致する可能性が高くなる。よって、イントラ予測モードの符号化に係る符号化ビット数を少なくすることができる。
[7] One aspect of the present invention is the intra predictor described above, wherein the error index acquisition unit acquires a sum of absolute values of quantized transform coefficients of a prediction residual based on the predicted image as the error index. .
According to the configuration of [7], the intra prediction mode candidate rank is an intra prediction with a small absolute value sum of quantized transform coefficients of a prediction residual based on an intra prediction image generated using each intra prediction mode candidate. There is a high possibility that the mode candidate matches the intra prediction mode related to the target block. Therefore, it is possible to reduce the number of encoded bits related to encoding in the intra prediction mode.

[8]本発明の一態様は、[1]から[7]のいずれかのイントラ予測器を備え、前記参照ブロックの復号画像を参照して所定の各イントラ予測モードを用いてイントラ予測を行って得られる予測画像と前記対象ブロックの入力画像との誤差量に基づいて、いずれかのイントラ予測モードを選択し、選択したイントラ予測モードと同一の前記イントラ予測モード候補の順位を判定する候補判定部と、を備える画像符号化装置である。
[8]の構成によれば、予測画像と入力画像との誤差量に基づいて選択されたイントラ予測モードと同一のイントラ予測モード候補の順位が高くなる。符号化に係るイントラ予測モード候補の数を少なくても済むので、イントラ予測モードの符号化ビット数を少なくすることができる。
[8] One aspect of the present invention includes the intra predictor according to any one of [1] to [7], and performs intra prediction using each predetermined intra prediction mode with reference to a decoded image of the reference block. Candidate determination that selects one of the intra prediction modes based on an error amount between the predicted image obtained in this way and the input image of the target block, and determines the rank of the same intra prediction mode candidate as the selected intra prediction mode And an image encoding device.
According to the configuration of [8], the ranking of the same intra prediction mode candidate as the intra prediction mode selected based on the error amount between the predicted image and the input image becomes higher. Since the number of intra prediction mode candidates for encoding can be reduced, the number of encoded bits in the intra prediction mode can be reduced.

[9]本発明の一態様は、[1]から[7]のいずれかのイントラ予測器を備え、入力された順位の前記イントラ予測モード候補と同一のイントラ予測モードを用いて得られる予測画像を用いて前記対象ブロックの復号画像を生成することを特徴とする画像復号装置である。
[9]の構成によれば、誤差指標の昇順に順序付けられたイントラ予測モード候補のうち、入力された順位のイントラ予測モード候補と同一のイントラ予測モードに基づく予測画像を用いて復号画像が生成される。そのため、より高い順位で符号化されたイントラ予測モードを、より少ない符号化ビット数で復号することができる。
[9] An aspect of the present invention includes an intra predictor according to any one of [1] to [7], and a predicted image obtained using the same intra prediction mode as the intra prediction mode candidate of the input rank The image decoding apparatus is characterized in that a decoded image of the target block is generated using.
According to the configuration of [9], a decoded image is generated using a prediction image based on the same intra prediction mode as the intra prediction mode candidate of the input rank among the intra prediction mode candidates ordered in ascending order of the error index. Is done. Therefore, it is possible to decode intra prediction modes encoded in a higher order with a smaller number of encoded bits.

[10]本発明の一態様は、コンピュータに対象ブロックの周囲の参照ブロックについて定めたイントラ予測モードを用いて得られた予測画像と入力画像との誤差指標を取得する誤差指標取得部と、前記対象ブロックのイントラ予測モード候補として、前記参照ブロックについて定めたイントラ予測モードを用いるとき、前記イントラ予測モード候補の順位を前記誤差指標の昇順に定める順位決定部と、を備えるイントラ予測器として機能させるためのプログラムである。
[10]の構成によれば、入力画像との誤差量が最も小さくなる予測画像を与える代表イントラ予測モードが、順位が高いイントラ予測モード候補と一致する可能性が高くなる。そのため、イントラ予測モードの符号化に係るイントラ予測モード候補の数、即ちその符号化ビット数を少なくすることができる。
[10] One aspect of the present invention is an error index acquisition unit that acquires an error index between a predicted image and an input image obtained using an intra prediction mode determined for reference blocks around a target block in a computer, When the intra prediction mode defined for the reference block is used as the intra prediction mode candidate of the target block, the intra block predictor is made to function as an intra predictor including a rank determining unit that ranks the intra prediction mode candidates in ascending order of the error index. It is a program for.
According to the configuration of [10], there is a high possibility that the representative intra prediction mode that gives the predicted image with the smallest amount of error from the input image matches the intra prediction mode candidate with the higher rank. Therefore, it is possible to reduce the number of intra prediction mode candidates related to encoding in the intra prediction mode, that is, the number of encoded bits.

本発明によれば、イントラ予測モードの符号化効率を向上することができる。   According to the present invention, it is possible to improve the encoding efficiency of the intra prediction mode.

第1の実施形態に係る画像符号化装置の構成を示す概略ブロック図である。It is a schematic block diagram which shows the structure of the image coding apparatus which concerns on 1st Embodiment. 第1の実施形態に係る画像復号装置の構成を示す概略ブロック図である。It is a schematic block diagram which shows the structure of the image decoding apparatus which concerns on 1st Embodiment. 第1の実施形態に係るイントラ予測部の構成を示す概略ブロック図である。It is a schematic block diagram which shows the structure of the intra estimation part which concerns on 1st Embodiment. 対象ブロックとその参照ブロックの例を示す図である。It is a figure which shows the example of an object block and its reference block. イントラ予測モードの例を示す図である。It is a figure which shows the example of intra prediction mode. 第1の実施形態に係るイントラ予測部の構成を示す概略ブロック図である。It is a schematic block diagram which shows the structure of the intra estimation part which concerns on 1st Embodiment. 第1の実施形態に係るMPM決定処理を示すフローチャートである。It is a flowchart which shows the MPM determination process which concerns on 1st Embodiment. 第2の実施形態に係るMPM決定処理を示すフローチャートである。It is a flowchart which shows the MPM determination process which concerns on 2nd Embodiment.

(第1の実施形態)
以下、図面を参照しながら本発明の第1の実施形態について説明する。
本実施形態に係る画像符号化装置1の構成について説明する。図1は、本実施形態に係る画像符号化装置1の構成を示す概略ブロック図である。図1に示す例では、画像符号化装置1は、HEVC方式に係る画像符号化処理を行う画像符号化装置に、本実施形態に係るイントラ予測器の一例としてイントラ予測部110(後述)を適用してなる。
(First embodiment)
Hereinafter, a first embodiment of the present invention will be described with reference to the drawings.
A configuration of the image encoding device 1 according to the present embodiment will be described. FIG. 1 is a schematic block diagram illustrating a configuration of an image encoding device 1 according to the present embodiment. In the example illustrated in FIG. 1, the image encoding device 1 applies an intra prediction unit 110 (described later) as an example of an intra predictor according to the present embodiment to an image encoding device that performs image encoding processing according to the HEVC scheme. Do it.

画像符号化装置1は、減算部101、直交変換部102、量子化部103、可変長符号化部104、逆量子化部105、逆直交変換部106、加算部107、ループフィルタ108、参照メモリ109、イントラ予測部110、インター予測部111および選択部112を含んで構成される。   The image encoding device 1 includes a subtraction unit 101, an orthogonal transformation unit 102, a quantization unit 103, a variable length coding unit 104, an inverse quantization unit 105, an inverse orthogonal transformation unit 106, an addition unit 107, a loop filter 108, and a reference memory. 109, an intra prediction unit 110, an inter prediction unit 111, and a selection unit 112.

減算部101には、ピクチャごとの入力画像が画像符号化装置1の外部から入力される。ピクチャとは、1枚の画像を意味し、フレームとも呼ばれる。減算部101には、その時点における処理対象として着目される各対象ブロック内の予測画像が選択部112から入力される。以下、対象ブロック内の予測画像を予測画像ブロックと呼ぶ。対象ブロックは、その時点における処理対象として着目されるピクチャである対象ピクチャを分割してなる所定の大きさを有する領域である。ブロックの大きさは、ブロックサイズと呼ばれる。ブロックサイズは、例えば、32×32画素、16×16画素、8×8画素、4×4画素のいずれかである。減算部101は、ブロックごとに対象ブロック内の入力画像である入力画像ブロックから予測画像ブロックを減算して残差画像ブロックを生成し、生成した残差画像ブロックを直交変換部102に出力する。   An input image for each picture is input to the subtraction unit 101 from the outside of the image encoding device 1. A picture means one image and is also called a frame. A prediction image in each target block focused on as a processing target at that time is input from the selection unit 112 to the subtraction unit 101. Hereinafter, the predicted image in the target block is referred to as a predicted image block. The target block is an area having a predetermined size obtained by dividing a target picture that is a picture of interest as a processing target at that time. The size of the block is called the block size. The block size is, for example, any of 32 × 32 pixels, 16 × 16 pixels, 8 × 8 pixels, and 4 × 4 pixels. The subtraction unit 101 generates a residual image block by subtracting a predicted image block from an input image block that is an input image in the target block for each block, and outputs the generated residual image block to the orthogonal transform unit 102.

直交変換部102は、減算部101から入力される残差画像ブロックについて直交変換を行って直交変換係数を算出し、算出した直交変換係数を量子化部103に出力する。直交変換として、例えば、離散コサイン変換(DCT:Discrete Cosine Transform)または離散サイン変換(DST:Discrete Sine transform)が用いられる。   The orthogonal transform unit 102 performs orthogonal transform on the residual image block input from the subtraction unit 101 to calculate an orthogonal transform coefficient, and outputs the calculated orthogonal transform coefficient to the quantization unit 103. As the orthogonal transform, for example, a discrete cosine transform (DCT) or a discrete sine transform (DST) is used.

量子化部103は、直交変換部102から入力される直交変換係数について所定の量子化パラメータを用いて量子化し、量子化直交変換係数を算出する。量子化部103は、算出した量子化直交変換係数を示す符号を可変長符号化部104と逆量子化部105に出力する。   The quantization unit 103 quantizes the orthogonal transform coefficient input from the orthogonal transform unit 102 using a predetermined quantization parameter, and calculates a quantized orthogonal transform coefficient. The quantization unit 103 outputs a code indicating the calculated quantized orthogonal transform coefficient to the variable length coding unit 104 and the inverse quantization unit 105.

可変長符号化部104は、量子化部103から入力される量子化直交変換係数の符号、イントラ予測部110から入力される代表イントラ予測モード情報およびインター予測部111から入力される動き情報を集約してデータ列を生成する。可変長符号化部104は、生成したデータ列について可変長符号化処理を行う。可変長符号化処理は、エントロピー符号化とも呼ばれる。可変長符号化処理により、入力される各種データの情報量が圧縮される。可変長符号化処理として、例えば、コンテキスト適応型2値算術符号化方式(CABAC:Context−based Adaptive Binary Arithmetic Coding)が用いられる。可変長符号化部104は、可変長符号化処理を行って得られたビット列からなる符号化データを画像符号化装置1の外部に出力する。イントラ予測部110からの予測モード情報については、後述する。   The variable length coding unit 104 aggregates the quantization orthogonal transform coefficient code input from the quantization unit 103, representative intra prediction mode information input from the intra prediction unit 110, and motion information input from the inter prediction unit 111. To generate a data string. The variable length coding unit 104 performs variable length coding processing on the generated data string. The variable length coding process is also called entropy coding. The amount of information of various types of input data is compressed by the variable length encoding process. For example, a context-adaptive binary arithmetic coding (CABAC) is used as the variable-length coding process. The variable length encoding unit 104 outputs encoded data including a bit string obtained by performing variable length encoding processing to the outside of the image encoding device 1. The prediction mode information from the intra prediction unit 110 will be described later.

逆量子化部105は、量子化部103から入力される量子化直交変換係数の符号について所定の量子化パラメータを用いて逆量子化を行って逆量子化直交変換係数を算出する。逆量子化部105は、算出した逆量子化直交変換係数を逆直交変換部106に出力する。   The inverse quantization unit 105 performs inverse quantization on the code of the quantized orthogonal transform coefficient input from the quantization unit 103 using a predetermined quantization parameter to calculate an inverse quantized orthogonal transform coefficient. The inverse quantization unit 105 outputs the calculated inverse quantization orthogonal transform coefficient to the inverse orthogonal transform unit 106.

逆直交変換部106は、逆量子化部105から入力される逆量子化直交変換係数について逆直交変換を行い、対象ブロック内の復号残差画像である復号残差画像ブロックを生成する。逆直交変換は、直交変換部102が行った直交変換との逆演算である。逆直交変換部106は、復号残差画像ブロックを加算部107に出力する。   The inverse orthogonal transform unit 106 performs inverse orthogonal transform on the inverse quantized orthogonal transform coefficient input from the inverse quantization unit 105, and generates a decoded residual image block that is a decoded residual image in the target block. The inverse orthogonal transform is an inverse operation with the orthogonal transform performed by the orthogonal transform unit 102. The inverse orthogonal transform unit 106 outputs the decoded residual image block to the addition unit 107.

加算部107は、選択部112から入力される対象ブロックの予測画像ブロックに復号残差画像ブロックを加算して対象ブロック内の復号画像である復号画像ブロックを生成する。加算部107は、生成した復号画像ブロックをループフィルタ108とイントラ予測部110に出力する。復号画像ブロックは、符号化の処理を行って得られた復号済みの画像ブロックに相当する。   The addition unit 107 adds the decoded residual image block to the prediction image block of the target block input from the selection unit 112, and generates a decoded image block that is a decoded image in the target block. The addition unit 107 outputs the generated decoded image block to the loop filter 108 and the intra prediction unit 110. The decoded image block corresponds to a decoded image block obtained by performing the encoding process.

ループフィルタ108は、加算部107から入力される復号画像ブロックについて所定のフィルタ処理を行う要素フィルタを備え、フィルタ処理によって得られた復号画像ブロックを参照メモリ109に順次記憶する。よって、参照メモリ109には、対象ピクチャを含め、対象ピクチャから所定時間内における各時点のピクチャの復号画像が記憶される。
ループフィルタ108は、要素フィルタとしてデブロッキングフィルタ(DF:Deblocking Filter)と画素適応オフセット(SAO:Sample Adaptive Offset)を含んで構成される。
The loop filter 108 includes an element filter that performs a predetermined filter process on the decoded image block input from the adding unit 107, and sequentially stores the decoded image block obtained by the filter process in the reference memory 109. Therefore, the reference memory 109 stores a decoded image of a picture at each time point within a predetermined time from the target picture including the target picture.
The loop filter 108 includes a deblocking filter (DF: Deblocking Filter) and a pixel adaptive offset (SAO) as element filters.

イントラ予測部110には、ブロックごとに加算部107から復号画像ブロックが入力される。イントラ予測部110は、対象ピクチャの周囲の参照ブロック内の復号画像を参照して、複数の所定のイントラ予測モードのそれぞれについてイントラ予測を行う。参照ブロックとして、対象ブロックから所定範囲内の復号済みの復号画像ブロックが用いられる。イントラ予測部110は、各イントラ予測モードについてイントラ予測を行って対象ブロック内の予測画像を生成する。以下、対象ブロック内の予測画像をイントラ予測ブロックと呼ぶ。イントラ予測部110は、生成したイントラ予測ブロックを選択部112に出力する。   The intra prediction unit 110 receives a decoded image block from the addition unit 107 for each block. The intra prediction unit 110 performs intra prediction for each of a plurality of predetermined intra prediction modes with reference to a decoded image in a reference block around the target picture. As the reference block, a decoded image block that has been decoded within a predetermined range from the target block is used. The intra prediction unit 110 performs intra prediction for each intra prediction mode to generate a predicted image in the target block. Hereinafter, the prediction image in the target block is referred to as an intra prediction block. The intra prediction unit 110 outputs the generated intra prediction block to the selection unit 112.

イントラ予測部110は、各イントラ予測モードについて生成されたイントラ予測画像ブロックと入力画像ブロックとの誤差量を算出する。イントラ予測部110は、複数のイントラ予測モードから取得した誤差量が最も小さいイントラ予測モードを代表イントラ予測モードとして定める。また、イントラ予測部110は、参照ブロックについて定めた代表イントラ予測モードとその誤差指標を取得する。ここで、誤差指標とは、参照ブロックにおける入力画像ブロックと予測画像ブロックとの差分である残差の大きさを示す指標値である。誤差指標は、対象ブロックにおける入力画像ブロックと予測画像ブロックとの差分である残差の大きさを示す誤差量と区別される。イントラ予測部110は、対象ブロックのイントラ予測モード候補として、参照ブロックについて定めた代表イントラ予測モードを用いるとき、イントラ予測モード候補の順位を誤差指標の昇順に定める。そして、イントラ予測部110は、対象ブロックに係る代表イントラ予測モードと一致するイントラ予測モード候補の有無を判定する。イントラ予測部110は、一致すると判定したイントラ予測モード候補の順位の情報を含む代表イントラ予測モード情報を生成し、生成した代表イントラ予測モード情報を可変長符号化部104に出力する。イントラ予測部110の構成については、後述する。   The intra prediction unit 110 calculates an error amount between the intra prediction image block generated for each intra prediction mode and the input image block. The intra prediction unit 110 determines an intra prediction mode having the smallest error amount acquired from a plurality of intra prediction modes as a representative intra prediction mode. In addition, the intra prediction unit 110 acquires a representative intra prediction mode determined for the reference block and its error index. Here, the error index is an index value indicating the magnitude of the residual that is the difference between the input image block and the predicted image block in the reference block. The error index is distinguished from an error amount indicating the magnitude of the residual that is the difference between the input image block and the predicted image block in the target block. When using the representative intra prediction mode defined for the reference block as the intra prediction mode candidate of the target block, the intra prediction unit 110 determines the rank of the intra prediction mode candidates in ascending order of the error index. Then, the intra prediction unit 110 determines whether or not there is an intra prediction mode candidate that matches the representative intra prediction mode related to the target block. The intra prediction unit 110 generates representative intra prediction mode information including information on the ranks of intra prediction mode candidates determined to match, and outputs the generated representative intra prediction mode information to the variable-length encoding unit 104. The configuration of the intra prediction unit 110 will be described later.

インター予測部111には、外部から入力される入力画像の対象ブロックについて、参照メモリ109に記憶された所定の期間内のピクチャの復号画像を参照してブロックマッチングを行って動きベクトルを定める。所定の期間内におけるピクチャには、対象ピクチャよりも過去のピクチャと未来のピクチャが含まれる。ブロックマッチングにおいて、インター予測部111は、対象ブロックから所定範囲内の復号済みの復号画像に基づいて得られるインター予測画像ブロックの入力画像ブロックに対する誤差量を変位量ごとに算出する。インター予測部111は、誤差量が最も小さい変位量を動きベクトルとして定める。インター予測部111は、定めた動きベクトルを用いて参照ブロック内の復号画像について動き補償を行って対象ブロック内の予測画像を生成する。以下、対象ブロック内の予測画像をインター予測画像ブロックと呼ぶ。インター予測部111は、生成したインター予測画像ブロックを選択部112に出力する。インター予測部111は、定めた動きベクトルの情報を含む動き情報を可変長符号化部104に出力する。なお、対象ブロックについて定めた動きベクトルが、符号化済みの参照ブロックのいずれかについて定めた動きベクトルに等しい場合がある。その場合には、インター予測部111は、対象ブロックについて定めた動きベクトルと等しい動きベクトルを与える参照ブロックを特定する。そして、インター予測部111は、動きベクトルの情報に代えて、特定した参照ブロックの位置情報を動き情報に含める。   The inter prediction unit 111 determines a motion vector by performing block matching on a target block of an input image input from the outside with reference to a decoded image of a picture within a predetermined period stored in the reference memory 109. Pictures within a predetermined period include past and future pictures than the target picture. In block matching, the inter prediction unit 111 calculates, for each displacement amount, an error amount with respect to an input image block of an inter prediction image block obtained based on a decoded image within a predetermined range from the target block. The inter prediction unit 111 determines a displacement amount having the smallest error amount as a motion vector. The inter prediction unit 111 performs motion compensation on the decoded image in the reference block using the determined motion vector, and generates a predicted image in the target block. Hereinafter, the prediction image in the target block is referred to as an inter prediction image block. The inter prediction unit 111 outputs the generated inter prediction image block to the selection unit 112. The inter prediction unit 111 outputs motion information including information on the determined motion vector to the variable length coding unit 104. Note that the motion vector defined for the target block may be equal to the motion vector defined for any of the encoded reference blocks. In that case, the inter prediction unit 111 identifies a reference block that gives a motion vector equal to the motion vector determined for the target block. Then, the inter prediction unit 111 includes the position information of the identified reference block in the motion information instead of the motion vector information.

選択部112は、イントラ予測部110から入力されるイントラ予測画像ブロックとインター予測部111から入力されるインター予測画像ブロックを切り替え、切り替えによって選択された予測画像ブロックを減算部101と加算部107に出力する。   The selection unit 112 switches between the intra prediction image block input from the intra prediction unit 110 and the inter prediction image block input from the inter prediction unit 111, and the prediction image block selected by switching is switched to the subtraction unit 101 and the addition unit 107. Output.

次に、本実施形態に係る画像復号装置2の構成について説明する。図2は、本実施形態に係る画像復号装置2の構成を示す概略ブロック図である。図1に示す例では、画像復号装置2は、HEVC方式に係る画像復号装置に、本実施形態に係るイントラ予測器の他の例としてイントラ予測部207(後述)を適用してなる。   Next, the configuration of the image decoding device 2 according to the present embodiment will be described. FIG. 2 is a schematic block diagram illustrating a configuration of the image decoding device 2 according to the present embodiment. In the example illustrated in FIG. 1, the image decoding device 2 is configured by applying an intra prediction unit 207 (described later) as another example of the intra predictor according to the present embodiment to the image decoding device according to the HEVC scheme.

画像復号装置2は、可変長復号部201、逆量子化部202、逆直交変換部203、加算部204、ループフィルタ205、参照メモリ206、イントラ予測部207およびインター予測部208を含んで構成される。逆量子化部202、逆直交変換部203および加算部204が行う処理は、画像符号化装置1の逆量子化部105、逆直交変換部106および加算部107とそれぞれ同様である。   The image decoding device 2 includes a variable length decoding unit 201, an inverse quantization unit 202, an inverse orthogonal transform unit 203, an addition unit 204, a loop filter 205, a reference memory 206, an intra prediction unit 207, and an inter prediction unit 208. The The processes performed by the inverse quantization unit 202, the inverse orthogonal transform unit 203, and the addition unit 204 are the same as those performed by the inverse quantization unit 105, the inverse orthogonal transform unit 106, and the addition unit 107 of the image encoding device 1, respectively.

可変長復号部201には、画像復号装置2の外部から画像符号化装置1が生成した符号化データが入力される。可変長復号部201は、入力される符号化データに含まれるビット列を可変長復号してブロックごとの量子化直交変換係数の符号、代表イントラ予測モード情報および動き情報を取得する。可変長復号方式は、符号化データの生成に用いられた可変長符号化方式に対応する可変長復号方式である。可変長復号部201は、各対象ブロックに係る量子化直交変換係数の符号、代表イントラ予測モード情報および動き情報を、それぞれ逆量子化部202、イントラ予測部207およびインター予測部208に出力する。   The variable length decoding unit 201 receives encoded data generated by the image encoding device 1 from the outside of the image decoding device 2. The variable length decoding unit 201 performs variable length decoding on a bit string included in input encoded data, and obtains a code of a quantized orthogonal transform coefficient, representative intra prediction mode information, and motion information for each block. The variable length decoding method is a variable length decoding method corresponding to the variable length coding method used for generating encoded data. The variable length decoding unit 201 outputs the code of the quantized orthogonal transform coefficient, the representative intra prediction mode information, and the motion information related to each target block to the inverse quantization unit 202, the intra prediction unit 207, and the inter prediction unit 208, respectively.

逆量子化部202には、可変長復号部201から入力される対象ブロックの量子化直交変換係数の符号を所定の量子化パラメータを用いて逆量子化を行い、逆量子化直交変換係数を算出する。逆量子化部202は、算出した逆量子化直交変換係数を逆直交変換部203に出力する。   The inverse quantization unit 202 inversely quantizes the quantization orthogonal transform coefficient code of the target block input from the variable length decoding unit 201 using a predetermined quantization parameter, and calculates the inverse quantization orthogonal transform coefficient. To do. The inverse quantization unit 202 outputs the calculated inverse quantization orthogonal transform coefficient to the inverse orthogonal transform unit 203.

逆直交変換部203は、逆量子化部202から入力される対象ブロックの逆量子化直交変換係数について逆直交変換を行い、復号残差画像ブロックを生成する。逆直交変換部203は、復号残差画像ブロックを加算部204に出力する。   The inverse orthogonal transform unit 203 performs inverse orthogonal transform on the inverse quantized orthogonal transform coefficient of the target block input from the inverse quantization unit 202 to generate a decoded residual image block. The inverse orthogonal transform unit 203 outputs the decoded residual image block to the addition unit 204.

加算部204には、イントラ予測部207から対象ブロックに係るイントラ予測画像ブロックまたはインター予測部208から対象ブロックに係るインター予測画像ブロックが予測画像ブロックとして入力される。加算部204は、予測画像ブロックと逆直交変換部203から入力される復号残差画像ブロックとを加算して復号画像ブロックを生成する。加算部204は、生成した復号画像ブロックをループフィルタ205と画像復号装置2の外部に出力する。   The intra prediction image block related to the target block from the intra prediction unit 207 or the inter predicted image block related to the target block from the inter prediction unit 208 is input to the addition unit 204 as a predicted image block. The adding unit 204 adds the predicted image block and the decoded residual image block input from the inverse orthogonal transform unit 203 to generate a decoded image block. The adding unit 204 outputs the generated decoded image block to the outside of the loop filter 205 and the image decoding device 2.

ループフィルタ205は、加算部204から入力される対象ブロックに係る復号画像ブロックについて所定のフィルタ処理を行う要素フィルタとしてDFとSAOを備え、フィルタ処理によって得られた復号画像ブロックを参照メモリ206に順次記憶する。よって、参照メモリ206には、対象ピクチャを含め、各時点のピクチャの復号画像が記憶される。
イントラ予測部207には、可変長復号部201から対象ブロックの代表イントラ予測モード情報が入力され、加算部204から復号画像ブロックが入力される。
The loop filter 205 includes DF and SAO as element filters for performing predetermined filter processing on the decoded image block related to the target block input from the adding unit 204, and sequentially stores the decoded image blocks obtained by the filter processing in the reference memory 206. Remember. Therefore, the reference memory 206 stores the decoded image of the picture at each time point including the target picture.
The intra prediction unit 207 receives the representative intra prediction mode information of the target block from the variable length decoding unit 201 and the decoded image block from the addition unit 204.

イントラ予測部207は、対象ピクチャから所定範囲内の復号済みの参照ブロックについて定めた代表イントラ予測モードとその誤差指標を取得する。イントラ予測部207は、
対象ブロックのイントラ予測モード候補として、参照ブロックについて定めた代表イントラ予測モードを用いるとき、イントラ予測モード候補の順位を誤差指標の昇順に定める。
イントラ予測部207は、イントラ予測モード候補のうち、可変長復号部201から入力された代表イントラ予測モード情報が示す順位のイントラ予測モード候補を代表イントラ予測モードとして特定する。イントラ予測部207は、加算部204から入力された参照ブロックの復号画像ブロックを参照し、特定したイントラ予測モードを用いてイントラ予測を行って生成されるイントラ予測画像ブロックを加算部204に出力する。イントラ予測部207の構成については、後述する。
The intra prediction unit 207 acquires a representative intra prediction mode and its error index determined for a decoded reference block within a predetermined range from the target picture. The intra prediction unit 207
When the representative intra prediction mode defined for the reference block is used as the intra prediction mode candidate of the target block, the ranking of the intra prediction mode candidates is determined in ascending order of the error index.
Of the intra prediction mode candidates, the intra prediction unit 207 identifies the intra prediction mode candidates of the rank indicated by the representative intra prediction mode information input from the variable length decoding unit 201 as the representative intra prediction mode. The intra prediction unit 207 refers to the decoded image block of the reference block input from the addition unit 204, and outputs an intra prediction image block generated by performing intra prediction using the identified intra prediction mode to the addition unit 204. . The configuration of the intra prediction unit 207 will be described later.

インター予測部208には、可変長復号部201から対象ブロックに係る動き情報が入力される。入力される動き情報が動きベクトルを示している場合には、インター予測部208は、その動きベクトルを用いて対象ブロックから所定範囲内の復号済みの復号画像について動き補償を行う。入力される動き情報が参照ブロックの位置情報を示している場合には、インター予測部208は、その位置情報で指定される参照ブロックの動きベクトルを用いて動き補償を行う。インター予測部208は、動き補償を行って得られるインター予測画像ブロックを加算部204に出力する。   The inter prediction unit 208 receives motion information related to the target block from the variable length decoding unit 201. When the input motion information indicates a motion vector, the inter prediction unit 208 performs motion compensation on the decoded image within the predetermined range from the target block using the motion vector. When the input motion information indicates the position information of the reference block, the inter prediction unit 208 performs motion compensation using the motion vector of the reference block specified by the position information. The inter prediction unit 208 outputs an inter prediction image block obtained by performing motion compensation to the addition unit 204.

(イントラ予測部)
次に、本実施形態に係る画像符号化装置1のイントラ予測部110の構成について説明する。図3は、本実施形態に係るイントラ予測部110の構成を示す概略ブロック図である。イントラ予測部110は、イントラ予測器1100および候補判定部1107を含んで構成される。イントラ予測器1100は、イントラ予測画像生成部1101、減算部1102、MPM決定部1103およびイントラ予測モード情報生成部1106を含んで構成される。
(Intra prediction unit)
Next, the configuration of the intra prediction unit 110 of the image encoding device 1 according to the present embodiment will be described. FIG. 3 is a schematic block diagram illustrating a configuration of the intra prediction unit 110 according to the present embodiment. The intra prediction unit 110 includes an intra predictor 1100 and a candidate determination unit 1107. The intra predictor 1100 includes an intra predicted image generation unit 1101, a subtraction unit 1102, an MPM determination unit 1103, and an intra prediction mode information generation unit 1106.

イントラ予測画像生成部1101は、対象ブロックから所定の範囲内にある参照ブロック内の復号画像を参照して所定の複数のイントラ予測モードのそれぞれについてイントラ予測を行う。HEVC方式では、イントラ予測の処理単位となるブロックは、直交変換ならびに逆直交変換が行われる処理単位(TU:Transform Unit;変換単位)に相当する。イントラ予測モードの数は、35モードである。イントラ予測モードの具体例については後述する。イントラ予測画像生成部1101は、イントラ予測によって得られたイントラ予測画像ブロックを減算部1102と候補判定部1107に出力する。   The intra prediction image generation unit 1101 performs intra prediction for each of a plurality of predetermined intra prediction modes with reference to a decoded image in a reference block within a predetermined range from the target block. In the HEVC scheme, a block that is a processing unit of intra prediction corresponds to a processing unit (TU: Transform Unit) in which orthogonal transformation and inverse orthogonal transformation are performed. The number of intra prediction modes is 35 modes. A specific example of the intra prediction mode will be described later. The intra predicted image generation unit 1101 outputs the intra predicted image block obtained by the intra prediction to the subtraction unit 1102 and the candidate determination unit 1107.

減算部1102は、イントラ予測画像生成部1101から入力されたイントラ予測画像ブロックを入力画像ブロックから減算してイントラ予測モードごとの残差画像ブロックを生成する。減算部1102は、生成した残差画像ブロックを候補判定部1107に出力する。   The subtraction unit 1102 subtracts the intra prediction image block input from the intra prediction image generation unit 1101 from the input image block, and generates a residual image block for each intra prediction mode. The subtraction unit 1102 outputs the generated residual image block to the candidate determination unit 1107.

MPM決定部1103は、復号済みの各参照ブロックの誤差指標と代表イントラ予測モードに基づいてMPMとMPM内順位を定める。MPMとは、複数のイントラ予測モードの一部のモードであるイントラ予測モード候補からなるグループである。MPM内順位は、MPMに属するイントラ予測モード候補の順位である。HEVC方式では、図4に示すようにMPMを決定する際に、対象ブロックTの左隣のブロックAと対象ブロックの上隣のブロックBが用いられる。MPM決定部1103は、誤差指標取得部1104とMPM順位決定部1105を含んで構成される。   The MPM determination unit 1103 determines the MPM and MPM rank based on the error index of each decoded reference block and the representative intra prediction mode. The MPM is a group of intra prediction mode candidates that are a part of a plurality of intra prediction modes. The MPM rank is a rank of intra prediction mode candidates belonging to the MPM. In the HEVC method, as shown in FIG. 4, when determining the MPM, the block A on the left side of the target block T and the block B on the upper side of the target block are used. The MPM determination unit 1103 includes an error index acquisition unit 1104 and an MPM rank determination unit 1105.

誤差指標取得部1104は、参照ブロックA、Bそれぞれの誤差指標Da、Dbをイントラ予測器1100が備える記憶部(図示せず)から取得する。参照ブロックA、Bは、対象ブロックTの左隣、上隣のブロックである。誤差指標は、対象ブロックに係る残差画像の誤差量に類似した傾向を示すと推測される指標値である。本実施形態では、誤差指標として対象ブロックに隣接する復号済みの各参照ブロックにおける残差の大きさを定量的に表す指標値が用いられる。誤差指標は、復号済みの残差画像ブロックから導出されるので画像符号化装置1のイントラ予測部110と画像復号装置2のイントラ予測部207のいずれにおいても取得可能である。残差画像ブロックは、参照ブロックA、Bのそれぞれについて、代表イントラ予測モードPa、Pbを用いてイントラ予測を行って得られる。参照ブロックにおいて最も小さい誤差指標を与える代表イントラ予測モードは、参照ブロックに隣接している対象ブロックにおいても入力画像をより忠実に再現することができる信頼性の高いイントラ予測モードであると推測されるためである。   The error index acquisition unit 1104 acquires the error indexes Da and Db of the reference blocks A and B from a storage unit (not shown) included in the intra predictor 1100. The reference blocks A and B are blocks adjacent to the left and top of the target block T. The error index is an index value estimated to show a tendency similar to the error amount of the residual image related to the target block. In this embodiment, an index value that quantitatively represents the magnitude of the residual in each decoded reference block adjacent to the target block is used as an error index. Since the error index is derived from the decoded residual image block, it can be acquired by both the intra prediction unit 110 of the image encoding device 1 and the intra prediction unit 207 of the image decoding device 2. The residual image block is obtained by performing intra prediction for each of the reference blocks A and B using the representative intra prediction modes Pa and Pb. The representative intra prediction mode that gives the smallest error index in the reference block is presumed to be a highly reliable intra prediction mode that can faithfully reproduce the input image even in the target block adjacent to the reference block. Because.

誤差指標として、例えば、次のいずれの種類の指標値が利用されてもよい。(1)量子化直交変換係数を示す符号を可変長符号化して得られるビット列のビット数、(2)量子化直交変換係数のうち零以外の値を有する非零変換係数の数、(3)量子化直交変換係数の直流成分、(4)量子化直交変換係数の二乗和、(5)量子化直交変換係数の絶対値和。画像符号化装置1では、(1)、(2)は、それぞれ可変長符号化部104、逆量子化部105から取得可能である。(3)−(5)は、いずれも逆直交変換部106から取得可能である。   As the error index, for example, any of the following types of index values may be used. (1) Number of bits of a bit string obtained by variable length coding a code indicating a quantized orthogonal transform coefficient, (2) Number of non-zero transform coefficients having a non-zero value among quantized orthogonal transform coefficients, (3) DC component of quantized orthogonal transform coefficient, (4) sum of squares of quantized orthogonal transform coefficient, and (5) absolute value sum of quantized orthogonal transform coefficient. In the image encoding device 1, (1) and (2) can be acquired from the variable length encoding unit 104 and the inverse quantization unit 105, respectively. Any of (3) to (5) can be acquired from the inverse orthogonal transform unit 106.

(1)について、直交変換係数が小さくなると量子化直交変換係数は0または0に近似した整数値となり、二値化により0の値をとるビットが主となる。そのため、(1)の値が小さいほど、対象ブロックにおける当該代表イントラ予測モードと同一のイントラ予測モードによる予測残差が小さくなることが推測される。
(2)について、符号化対象となる直交変換係数が小さくなると量子化直交変換係数は0または0に近似した整数値となる。そのため、計数される(2)の値が小さいほど対象ブロックにおける予測残差が小さいことが推測される。
(3)は、画素ごとの画素値の対象ブロック内の平均値に相当する。(3)の値が小さいほど対象ブロックにおける当該代表イントラ予測モードと同一のイントラ予測モードによる予測残差が小さいことが推測される。
(4)は、空間周波数ごとの量子化直交変換係数の二乗値の対象ブロック内の総和に相当する。(4)の値が小さいほど対象ブロックにおける当該代表イントラ予測モードと同一のイントラ予測モードによる予測残差が小さいことが推測される。
(5)は、空間周波数ごとの量子化直交変換係数の絶対値の対象ブロック内の総和に相当する。(5)の値が小さいほど対象ブロックにおける当該代表イントラ予測モードと同一のイントラ予測モードによる予測残差が小さいことを示す。
As for (1), when the orthogonal transform coefficient becomes smaller, the quantized orthogonal transform coefficient becomes 0 or an integer value approximated to 0, and the bits that take a value of 0 by binarization are mainly used. Therefore, it is estimated that the smaller the value of (1), the smaller the prediction residual due to the same intra prediction mode as the representative intra prediction mode in the target block.
Regarding (2), when the orthogonal transform coefficient to be encoded becomes smaller, the quantized orthogonal transform coefficient becomes 0 or an integer value approximated to 0. Therefore, it is estimated that the smaller the value of (2) counted, the smaller the prediction residual in the target block.
(3) corresponds to the average value within the target block of pixel values for each pixel. It is estimated that the smaller the value of (3), the smaller the prediction residual in the same intra prediction mode as that of the representative intra prediction mode in the target block.
(4) corresponds to the sum in the target block of the square value of the quantized orthogonal transform coefficient for each spatial frequency. It is presumed that the smaller the value of (4), the smaller the prediction residual due to the same intra prediction mode as the representative intra prediction mode in the target block.
(5) corresponds to the sum in the target block of the absolute value of the quantized orthogonal transform coefficient for each spatial frequency. It shows that the prediction residual by the intra prediction mode same as the said representative intra prediction mode in the object block is so small that the value of (5) is small.

誤差指標取得部1104は、候補判定部1107が過去の対象ブロック、つまり参照ブロックについて代表イントラ予測モードを定める過程で取得した誤差量またはその誤差量の算出過程で取得される指標値を誤差指標として採用してもよい。従って、参照ブロックの代表イントラ予測モードに係る誤差指標を算出するための処理を追加して行う必要がない。なお、無効なブロックの代表イントラ予測モードについては、誤差指標取得部1104は、算出されうる誤差指標の最大値よりも十分に大きい値Zを、当該代表イントラ予測モードに係る誤差指標として定める。例えば、誤差指標として非零変換係数の数を用いる場合には、誤差指標取得部1104は、誤差量Zとしてブロックサイズ内の画素数の2倍と設定してもよい。誤差指標取得部1104は、代表イントラ予測モードPa、Pbそれぞれの誤差指標Da、DbをMPM順位決定部1105に出力する。   The error index acquisition unit 1104 uses, as an error index, the error amount acquired by the candidate determination unit 1107 in the process of determining the representative intra prediction mode for the past target block, that is, the reference block, or the index value acquired in the process of calculating the error amount. It may be adopted. Therefore, it is not necessary to perform an additional process for calculating an error index related to the representative intra prediction mode of the reference block. Note that for the representative intra prediction mode of an invalid block, the error index acquisition unit 1104 determines a value Z sufficiently larger than the maximum value of the error index that can be calculated as an error index related to the representative intra prediction mode. For example, when the number of non-zero transform coefficients is used as the error index, the error index acquisition unit 1104 may set the error amount Z to be twice the number of pixels in the block size. The error index acquisition unit 1104 outputs the error indexes Da and Db of the representative intra prediction modes Pa and Pb to the MPM rank determination unit 1105, respectively.

MPM順位決定部1105は、誤差指標取得部1104から入力されたブロックAの代表イントラ予測モードPaに係る誤差指標Da、ブロックBの代表イントラ予測モードPbに係る誤差指標Dbおよび所定のデフォルトMPMに基づいて、MPMに属するイントラ予測モード候補とそれらの順位を定める。デフォルトMPMとは、参照ブロックが無効である場合に設定されるイントラ予測モード候補、その他、参照ブロックのイントラ予測モード以外のイントラ予測モード候補として設定される所定のイントラ予測モード候補である。MPM順位決定部1105は、定めたイントラ予測モード候補とそれらの順位の情報をイントラ予測モード情報生成部1106に出力する。   The MPM rank determination unit 1105 is based on the error indicator Da related to the representative intra prediction mode Pa of the block A, the error indicator Db related to the representative intra prediction mode Pb of the block B, and a predetermined default MPM input from the error indicator acquisition unit 1104. Thus, the intra prediction mode candidates belonging to the MPM and their ranks are determined. The default MPM is a predetermined intra prediction mode candidate set as an intra prediction mode candidate set when the reference block is invalid, and other intra prediction mode candidates other than the intra prediction mode of the reference block. The MPM rank determination unit 1105 outputs the determined intra prediction mode candidates and information on their ranks to the intra prediction mode information generation unit 1106.

HEVC方式では、デフォルトMPMとして、プレーナ(Planar)予測、DC(Direct Current;直流)予測および垂直方向参照、のいずれかもしくは組み合わせが用いられる。参照ブロックが無効である場合に設定されるイントラ予測モード候補は、DC予測である。参照ブロックが無効とは、参照ブロックについて利用可能な代表イントラ予測モードが存在しないことを意味する。参照ブロックが無効とは、例えば、当該参照ブロックが対象ピクチャ内に存在しないこと、当該参照ブロックがイントラ予測で符号化されていないこと、復号済みではないこと、当該参照ブロックが対象ブロックが属するスライスとは異なるスライスに存在すること、当該参照ブロックが対象ブロックが属するタイルとは異なるタイルに存在すること、または所定の特殊符号化モードとしてI_PCMモードを用いて符号化されていること、が該当する。I_PCMモードとは、画素毎の信号値を示す符号をそのまま出力する符号化モードである。   In the HEVC scheme, any one or a combination of planar prediction, DC (Direct Current) prediction and vertical reference is used as the default MPM. The intra prediction mode candidate set when the reference block is invalid is DC prediction. The reference block is invalid means that there is no representative intra prediction mode available for the reference block. The reference block is invalid, for example, that the reference block does not exist in the target picture, that the reference block has not been encoded by intra prediction, has not been decoded, or a slice to which the reference block belongs. The reference block exists in a different tile from the tile to which the target block belongs, or is encoded using the I_PCM mode as a predetermined special encoding mode. . The I_PCM mode is an encoding mode in which a code indicating a signal value for each pixel is output as it is.

代表イントラ予測モードPaと代表イントラ予測モードPbが異なり、かつ誤差指標Daが誤差指標Db以下であるとき、MPM順位決定部1105は、MPMの0番目のイントラ予測モード候補を代表イントラ予測モードPaと定め、MPMの1番目のイントラ予測候補を代表イントラ予測モードPbと定める。また、代表イントラ予測モードPaと代表イントラ予測モードPbが異なる場合であって、誤差指標Daが誤差指標Dbより大きいとき、MPM順位決定部1105は、MPMの0番目のイントラ予測モード候補を代表イントラ予測モードPbと定め、MPMの1番目のイントラ予測モード候補を代表イントラ予測モードPaと定める。   When the representative intra prediction mode Pa and the representative intra prediction mode Pb are different and the error index Da is equal to or less than the error index Db, the MPM rank determination unit 1105 sets the MPM 0th intra prediction mode candidate as the representative intra prediction mode Pa. The MPM first intra prediction candidate is defined as the representative intra prediction mode Pb. When the representative intra prediction mode Pa and the representative intra prediction mode Pb are different and the error index Da is larger than the error index Db, the MPM rank determination unit 1105 selects the MPM 0th intra prediction mode candidate as the representative intra prediction mode. The prediction mode Pb is determined, and the MPM first intra prediction mode candidate is determined as the representative intra prediction mode Pa.

なお、代表イントラ予測モードPaと代表イントラ予測モードPbが異なる場合、MPM順位決定部1105は、MPMの2番目のイントラ予測モード候補を、HEVC方式と同様の手順を用いて定める。即ち、代表イントラ予測モードPaと代表イントラ予測モードPbのいずれもプレーナ予測ではないとき、MPM順位決定部1105は、MPMの2番目のイントラ予測モード候補としてプレーナ予測と定める。さらに、代表イントラ予測モードPaと代表イントラ予測モードPbのいずれもDC予測ではないとき、MPM順位決定部1105は、MPMの2番目のイントラ予測モード候補としてプレーナ予測と定める。それ以外のとき、MPM順位決定部1105は、MPMの2番目のイントラ予測候補を垂直方向参照と定める。   When the representative intra prediction mode Pa and the representative intra prediction mode Pb are different, the MPM order determination unit 1105 determines the second intra prediction mode candidate of the MPM using the same procedure as that of the HEVC scheme. That is, when neither the representative intra prediction mode Pa nor the representative intra prediction mode Pb is the planar prediction, the MPM rank determination unit 1105 determines the planar prediction as the second intra prediction mode candidate of the MPM. Furthermore, when neither the representative intra prediction mode Pa nor the representative intra prediction mode Pb is DC prediction, the MPM rank determination unit 1105 determines planar prediction as the second intra prediction mode candidate of the MPM. In other cases, the MPM rank determination unit 1105 determines the second intra prediction candidate of the MPM as the vertical direction reference.

代表イントラ予測モードPaと代表イントラ予測モードPbが等しい場合において、MPM順位決定部1105は、MPMの各イントラ予測モード候補を、HEVC方式と同様の手順を用いて定める。即ち、代表イントラ予測モードPaと代表イントラ予測モードPbがプレーナ予測もしくはDC予測である場合には、MPM順位決定部1105は、MPMの0、1、2番目のイントラ予測モード候補を、それぞれプレーナ予測、DC予測、垂直方向参照と定める。また、代表イントラ予測モードPaと代表イントラ予測モードPbが方向性予測である場合には、MPM順位決定部1105は、MPMの0、1、2番目のイントラ予測モード候補を、それぞれ代表イントラ予測モードPa、Pbと同じ参照方向のイントラ予測モード、代表イントラ予測モードPa、Pbの参照方向とは左回りに隣接するイントラ予測モード、代表イントラ予測モードPa、Pbの参照方向とは右回りに隣接するイントラ予測モード候補と定める。   When the representative intra prediction mode Pa and the representative intra prediction mode Pb are equal, the MPM order determination unit 1105 determines each MPM intra prediction mode candidate using the same procedure as in the HEVC scheme. That is, when the representative intra prediction mode Pa and the representative intra prediction mode Pb are planar prediction or DC prediction, the MPM rank determination unit 1105 determines the MPM 0, 1, and 2 intra prediction mode candidates as the planar prediction, respectively. , DC prediction, vertical reference. When the representative intra prediction mode Pa and the representative intra prediction mode Pb are directional predictions, the MPM rank determining unit 1105 sets the MPM 0, 1, and 2 intra prediction mode candidates as representative intra prediction modes, respectively. The intra prediction mode in the same reference direction as Pa and Pb, the reference directions of the representative intra prediction modes Pa and Pb are adjacent to the counterclockwise intra prediction mode, and the reference directions of the representative intra prediction modes Pa and Pb are adjacent to the clockwise direction. It is determined as an intra prediction mode candidate.

無効な参照ブロックについては、MPM順位決定部1105は、HEVC方式と同様に、その代表イントラ予測モードをDC予測と定める。即ち、ブロックAが無効である場合には、MPM順位決定部1105は、代表イントラ予測モードPaとしてDC予測と定める。ブロックBが無効である場合には、MPM順位決定部1105は、代表イントラ予測モードPbとしてDC予測と定める。   For invalid reference blocks, the MPM order determination unit 1105 determines the representative intra prediction mode as DC prediction, as in the HEVC scheme. That is, when the block A is invalid, the MPM rank determination unit 1105 determines the DC prediction as the representative intra prediction mode Pa. When the block B is invalid, the MPM rank determination unit 1105 determines DC prediction as the representative intra prediction mode Pb.

イントラ予測モード情報生成部1106は、MPM順位決定部1105から入力されるMPMのイントラ予測モード候補とそれらの順位を示すイントラ予測モード情報を生成する。イントラ予測モード情報生成部1106は、生成したイントラ予測モード情報を候補判定部1107に出力する。   The intra prediction mode information generation unit 1106 generates intra prediction mode information indicating the MPM intra prediction mode candidates input from the MPM rank determination unit 1105 and their ranks. The intra prediction mode information generation unit 1106 outputs the generated intra prediction mode information to the candidate determination unit 1107.

候補判定部1107には、イントラ予測モード情報生成部1106からイントラ予測モード情報が入力され、イントラ予測モードごとにイントラ予測画像生成部1101からイントラ予測画像ブロックと、減算部1102から残差画像ブロックとが入力される。候補判定部1107は、イントラ予測モードごとの残差の大きさを示す誤差量を算出し、算出した誤差量が最も小さいイントラ予測モードを対象ブロックの代表イントラ予測モードとして定める。候補判定部1107は、例えば、代表イントラ予測モードを定める際、レート−歪み最適化を行ってもよい。レート−歪み最適化とは、誤差量Jとして残差画像ブロックの量子化変換係数の二乗和または絶対値和と、その量子化変換係数のビット長と所定の定数λとの乗算値の和が最小となるイントラ予測モードを定める手法である。定数λは、量子化パラメータに基づいて定められる。量子化パラメータとして、直交変換係数の量子化幅が用いられる。候補判定部1107は、定めた代表イントラ予測モードに係る予測画像ブロックを、減算部101に選択部112を介して出力する。また、候補判定部1107は、その対象ブロックのインデックスと、定めた代表イントラ予測モードおよび誤差指標とを対応付けてイントラ予測器1100の記憶部(図示せず)に記憶する。記憶されたイントラ予測モードと誤差指標は、対象ブロックが変更された後で、参照ブロックのイントラ予測モードと誤差指標として用いられる。   Intra prediction mode information is input from the intra prediction mode information generation unit 1106 to the candidate determination unit 1107, and an intra prediction image block from the intra prediction image generation unit 1101 and a residual image block from the subtraction unit 1102 for each intra prediction mode. Is entered. The candidate determination unit 1107 calculates an error amount indicating the magnitude of the residual for each intra prediction mode, and determines the intra prediction mode with the smallest calculated error amount as the representative intra prediction mode of the target block. For example, the candidate determination unit 1107 may perform rate-distortion optimization when determining the representative intra prediction mode. In the rate-distortion optimization, an error amount J is a sum of squares or absolute value sums of quantized transform coefficients of a residual image block, and a multiplication value of a bit length of the quantized transform coefficients and a predetermined constant λ. This is a method for determining the minimum intra prediction mode. The constant λ is determined based on the quantization parameter. As the quantization parameter, the quantization width of the orthogonal transform coefficient is used. The candidate determination unit 1107 outputs the predicted image block related to the determined representative intra prediction mode to the subtraction unit 101 via the selection unit 112. Further, the candidate determination unit 1107 stores the index of the target block in association with the determined representative intra prediction mode and error index in a storage unit (not shown) of the intra predictor 1100. The stored intra prediction mode and error index are used as the intra prediction mode and error index of the reference block after the target block is changed.

候補判定部1107は、イントラ予測モード情報生成部1106から入力されるイントラ予測モード情報が示すMPMのイントラ予測モード候補に、定めた代表イントラ予測モードが含まれているか否かを判定する。含まれていると判定するとき、候補判定部1107は、代表イントラ予測モードと同一のイントラ予測モード候補の順位を特定する。そして、候補判定部1107は、代表イントラ予測モードがMPMのイントラ予測モード候補に含まれていることを示すイントラ予測フラグと、特定した順位の番号とを示すビット列を代表イントラ予測モード情報として可変長符号化部104に出力する。   The candidate determination unit 1107 determines whether or not the determined representative intra prediction mode is included in the MPM intra prediction mode candidates indicated by the intra prediction mode information input from the intra prediction mode information generation unit 1106. When determining that it is included, the candidate determination unit 1107 identifies the rank of the same intra prediction mode candidate as the representative intra prediction mode. Then, the candidate determination unit 1107 uses the intra prediction flag indicating that the representative intra prediction mode is included in the MPM intra prediction mode candidates and the bit sequence indicating the identified rank number as the representative intra prediction mode information, and has a variable length. The data is output to the encoding unit 104.

代表イントラ予測モードが、MPMのイントラ予測モード候補に含まれていないと判定するとき、候補判定部1107は、MPMのイントラ予測モード候補のモード番号を昇順に並び替える。複数のイントラ予測モードには、それぞれを識別するためのモード番号として0〜34の整数値が設定されている。候補判定部1107は、代表イントラ予測モードのモード番号がMPMの0番目のイントラ予測モード候補のモード番号以上であるとき、代表イントラ予測モードのモード番号を1減少させる。候補判定部1107は、減少させた代表イントラ予測モードのモード番号がMPMの1番目のイントラ予測モード候補のモード番号以上であるとき、代表イントラ予測モードのモード番号をさらに1減少させる。候補判定部1107は、さらに減少させた代表イントラ予測モードのモード番号がMPMの2番目のイントラ予測モード候補のモード番号以上であるとき、代表イントラ予測モードのモード番号をまたさらに1減少させる。そして、候補判定部1107は、代表イントラ予測モードのモード番号を採用予測モード番号として定める。これらの手順により、採用予測モード番号は、0〜31のいずれかの値として表されるので、その情報量が5ビットに収まる。候補判定部1107は、代表イントラ予測モードがMPMのイントラ予測モード候補に含まれないことを示すイントラ予測フラグと、採用予測モード番号とを示すビット列を代表イントラ予測モード情報として可変長符号化部104に出力する。   When determining that the representative intra prediction mode is not included in the MPM intra prediction mode candidates, the candidate determination unit 1107 rearranges the mode numbers of the MPM intra prediction mode candidates in ascending order. An integer value of 0 to 34 is set as a mode number for identifying each of the plurality of intra prediction modes. The candidate determination unit 1107 decrements the mode number of the representative intra prediction mode by 1 when the mode number of the representative intra prediction mode is greater than or equal to the mode number of the 0th intra prediction mode candidate of the MPM. The candidate determination unit 1107 further decreases the mode number of the representative intra prediction mode by 1 when the mode number of the reduced representative intra prediction mode is greater than or equal to the mode number of the first intra prediction mode candidate of the MPM. The candidate determination unit 1107 further decreases the mode number of the representative intra prediction mode by 1 when the mode number of the representative intra prediction mode further decreased is equal to or greater than the mode number of the second intra prediction mode candidate of the MPM. Then, the candidate determination unit 1107 determines the mode number of the representative intra prediction mode as the adopted prediction mode number. With these procedures, the adoption prediction mode number is expressed as any value from 0 to 31, so that the amount of information fits in 5 bits. The candidate determination unit 1107 is a variable-length encoding unit 104 using, as representative intra prediction mode information, a bit string indicating an intra prediction flag indicating that the representative intra prediction mode is not included in the MPM intra prediction mode candidates and the adopted prediction mode number. Output to.

HEVC方式では、MPMのイントラ予測モード候補の番号を可変長符号化処理する際、二値化処理において切断ライス二値化(TR:Truncated Rice Binarization)方式が採用されている。TR方式は、0から最大値cMaxまでのいずれかの整数である入力値を二値化する一つの手法である。TR方式は、入力値と等しい数だけ冒頭に「1」の値を順次並べ、末尾に「0」を付加してなるビット列に変換する手法である。但し、入力値が最大値cMaxと等しい場合には、末尾の「0」が省略される。そのため、入力値が0からcMax−1までのいずれかの値である場合には、入力値が小さいほどTR方式によって生成されるビット列の符号量が少なくなる。MPMのイントラ予測モードの候補の数が3個である場合、最大値cMaxが2となるので、入力値となるイントラ予測モード候補の番号は0〜2のいずれかの値で表される。   In the HEVC scheme, a truncated rice binarization (TR) scheme is employed in binarization processing when variable-length encoding processing is performed on MPM intra prediction mode candidate numbers. The TR method is one method for binarizing an input value that is any integer from 0 to the maximum value cMax. The TR method is a method of converting a bit string formed by sequentially arranging “1” values at the beginning of the number equal to the input value and adding “0” at the end. However, if the input value is equal to the maximum value cMax, the trailing “0” is omitted. Therefore, when the input value is any value from 0 to cMax-1, the smaller the input value, the smaller the code amount of the bit string generated by the TR method. When the number of MPM intra prediction mode candidates is 3, the maximum value cMax is 2, and therefore the number of intra prediction mode candidates as an input value is represented by one of 0 to 2.

従来のHEVC方式では、代表イントラ予測モードPaと代表イントラ予測モードPbが異なる場合、誤差指標に関わらず代表イントラ予測モードPa、PbがMPMの1番目、2番目のイントラ予測モード候補として定められていた。
これに対し、本実施形態に係るMPM順位決定部1105は、誤差指標が小さい参照ブロックごとの代表イントラ予測モードほど、より順位が高い(番号の値が少ない)イントラ予測モード候補として定める。そのため、入力画像との誤差量が最も小さい予測画像ブロックを与える対象ブロックの代表イントラ予測モードが、順位が高いイントラ予測モード候補に一致する可能性が高くなる。つまり、代表イントラ予測モードと一致するイントラ予測モード候補の番号が小さくなるので二値化後の符号量が少なくなる。代表イントラ予測モードは、画像復号装置2において対象ブロック内の予測画像の生成に用いられる。
In the conventional HEVC scheme, when the representative intra prediction mode Pa and the representative intra prediction mode Pb are different, the representative intra prediction modes Pa and Pb are determined as the first and second intra prediction mode candidates of the MPM regardless of the error index. It was.
On the other hand, the MPM rank determination unit 1105 according to the present embodiment determines the intra prediction mode candidate having a higher rank (a smaller number value) as the representative intra prediction mode for each reference block having a smaller error index. Therefore, there is a high possibility that the representative intra prediction mode of the target block that gives the predicted image block having the smallest error amount from the input image matches the intra prediction mode candidate with the higher rank. That is, since the number of intra prediction mode candidates that match the representative intra prediction mode is reduced, the code amount after binarization is reduced. The representative intra prediction mode is used in the image decoding apparatus 2 to generate a predicted image in the target block.

(イントラ予測モード)
次に、イントラ予測モードの例について説明する。HEVC方式では、35種類のイントラ予測モードがある。イントラ予測モードは、それぞれ0〜34のいずれかのモード番号を有する。35種類のイントラ予測モードは、方向性予測、DC予測およびプレーナ予測に分類される。方向性予測は、参照ブロック内の所定の参照画素のうち参照方向の線分の左右両側にそれぞれ最も近い方向の画素の画素値を補間して対象ブロック内の各画素の画素値を算出するイントラ予測モードである。参照方向は、図5(a)に示すように左斜め下から右斜め上までの33方向であり、各方向について2から34のいずれかのモード番号が右回りに昇順に付されている。参照方向は水平方向に近いほど密に分布し、対象ブロックの対角方向に近いほど疎らに分布している。図5(a)に示す例では、参照方向を示す矢印の起点は、対象ブロックの中心に設定されている。
(Intra prediction mode)
Next, an example of the intra prediction mode will be described. In the HEVC scheme, there are 35 types of intra prediction modes. Each intra prediction mode has a mode number of 0 to 34. The 35 kinds of intra prediction modes are classified into directionality prediction, DC prediction, and planar prediction. The directionality prediction is an intra that calculates the pixel value of each pixel in the target block by interpolating the pixel values of the pixels closest to the left and right sides of the reference direction line segment among the predetermined reference pixels in the reference block. Prediction mode. As shown in FIG. 5A, the reference directions are 33 directions from the diagonally lower left to the diagonally upper right, and any one of the mode numbers 2 to 34 is assigned in ascending order clockwise in each direction. The closer the reference direction is to the horizontal direction, the denser the distribution is. In the example shown in FIG. 5A, the starting point of the arrow indicating the reference direction is set at the center of the target block.

DC予測は、参照ブロック内の所定の参照画素間の画素値の平均値を対象ブロックBk内の各画素の画素値として算出するイントラ予測モードである。図5(b)に示す例では、DC予測において参照される参照画素は黒丸で示されている2N個の参照画素である。Nは、対象ブロックの一辺の長さに相当する画素数を示す。参照画素として、参照ブロック内の対象ブロックの上辺および左辺に最も近接している画素が用いられる。但し、ブロックサイズが32×32画素以下のブロックでは、例外処理として、対象ブロックの最上行および最左列の各画素の画素値を、最近傍の参照画素の画素値との平均値をもって更新される。図5(b)において網掛けで塗りつぶされた領域Epは、対象ブロックの最上行および最左列を示す。DC予測のモード番号は、1である。   DC prediction is an intra prediction mode in which an average value of pixel values between predetermined reference pixels in the reference block is calculated as a pixel value of each pixel in the target block Bk. In the example shown in FIG. 5B, the reference pixels referred in the DC prediction are 2N reference pixels indicated by black circles. N indicates the number of pixels corresponding to the length of one side of the target block. As the reference pixel, a pixel closest to the upper side and the left side of the target block in the reference block is used. However, in a block having a block size of 32 × 32 pixels or less, as an exception process, the pixel value of each pixel in the uppermost row and the leftmost column of the target block is updated with the average value of the pixel value of the nearest reference pixel. The In FIG. 5B, the area Ep filled with shading indicates the uppermost row and the leftmost column of the target block. The mode number for DC prediction is 1.

プレーナ予測は、4個の参照画素それぞれの画素値を補間して対象ブロック内の各画素の画素値を算出するイントラ予測モードである。参照画素として、対象ブロック内の画素(x,y)の左方(−1,y)、上方(x,−1)ならびに対象画素の右斜め上(N,−1)、左斜め下(−1,N)の画素が用いられる。(x,y)等は、対象ブロックの左上端の画素の位置を原点とする各画素の座標値を示す。対象画素の画素値の算出に用いられる4個の参照画素は、図5(b)において、一点破線の円で囲まれた黒丸で示されている。   Planar prediction is an intra prediction mode in which pixel values of each of four reference pixels are interpolated to calculate the pixel value of each pixel in the target block. As reference pixels, the left (-1, y), the upper (x, -1) of the pixel (x, y) in the target block, the upper right (N, -1), and the lower left (- 1, N) pixels are used. (X, y) and the like indicate the coordinate value of each pixel with the position of the upper left pixel of the target block as the origin. The four reference pixels used for calculation of the pixel value of the target pixel are indicated by black circles surrounded by a dashed-dotted circle in FIG.

(イントラ予測部)
次に、本実施形態に係る画像復号装置2のイントラ予測部207の構成について説明する。図6は、本実施形態に係るイントラ予測部207の構成を示す概略ブロック図である。イントラ予測部207は、イントラ予測器2070を含んで構成される。イントラ予測器2070は、MPM決定部2071、イントラ予測モード情報生成部2074、候補判定部2075およびイントラ予測画像生成部2076を含んで構成される。
(Intra prediction unit)
Next, the configuration of the intra prediction unit 207 of the image decoding device 2 according to the present embodiment will be described. FIG. 6 is a schematic block diagram illustrating a configuration of the intra prediction unit 207 according to the present embodiment. The intra prediction unit 207 includes an intra predictor 2070. The intra predictor 2070 includes an MPM determination unit 2071, an intra prediction mode information generation unit 2074, a candidate determination unit 2075, and an intra prediction image generation unit 2076.

MPM決定部2071は、MPM決定部1103と同様に、復号済みの各参照ブロックの誤差指標と代表イントラ予測モードに基づいてMPMとMPM内順位を定める。MPM決定部2071は、誤差指標取得部2072とMPM順位決定部2073を含んで構成される。   Similar to the MPM determination unit 1103, the MPM determination unit 2071 determines the MPM and the MPM in-order based on the error index of each decoded reference block and the representative intra prediction mode. The MPM determination unit 2071 includes an error index acquisition unit 2072 and an MPM rank determination unit 2073.

誤差指標取得部2072は、対象ブロックに隣接する参照ブロックA、Bそれぞれの代表イントラ予測モードPa、Pbと誤差指標Da、Dbとをイントラ予測器2070が備える記憶部(図示せず)から取得する。誤差指標取得部2072は、誤差指標取得部1104が取得した誤差指標と同一の種類の誤差指標を取得する。なお、無効な参照ブロックの代表イントラ予測モードについては、誤差指標取得部2072は、誤差指標取得部1104と同様に、その誤差指標として算出されうる誤差指標の最大値よりも十分に大きい値Zに定める。誤差指標取得部2072は、代表イントラ予測モードPa、Pbとそれぞれの誤差指標Da、DbをMPM順位決定部2073に出力する。   The error index acquisition unit 2072 acquires the representative intra prediction modes Pa and Pb and the error indexes Da and Db of the reference blocks A and B adjacent to the target block from a storage unit (not shown) included in the intra predictor 2070. . The error index acquisition unit 2072 acquires the same type of error index as the error index acquired by the error index acquisition unit 1104. For the representative intra prediction mode of the invalid reference block, the error index acquisition unit 2072 has a value Z sufficiently larger than the maximum value of the error index that can be calculated as the error index, similarly to the error index acquisition unit 1104. Determine. The error index acquisition unit 2072 outputs the representative intra prediction modes Pa and Pb and the respective error indexes Da and Db to the MPM rank determination unit 2073.

MPM順位決定部2073は、MPM順位決定部1105と同様な手法で、誤差指標取得部2072から入力された代表イントラ予測モードPaに係る誤差指標Da、代表イントラ予測モードPbに係る誤差指標Dbおよび所定のデフォルトMPMに基づいて、MPMに属するイントラ予測モード候補とそれらの順位を定める。MPM順位決定部2073は、定めたイントラ予測モード候補とそれらの順位の情報をイントラ予測モード情報生成部2074に出力する。   The MPM rank determining unit 2073 uses the same method as the MPM rank determining unit 1105 to input the error index Da related to the representative intra prediction mode Pa, the error index Db related to the representative intra prediction mode Pb, and a predetermined value input from the error index acquiring unit 2072. Intra prediction mode candidates belonging to the MPM and their rank are determined based on the default MPM. The MPM rank determination unit 2073 outputs the determined intra prediction mode candidates and information on their ranks to the intra prediction mode information generation unit 2074.

ここで、MPM順位決定部2073は、代表イントラ予測モードPaと代表イントラ予測モードPbが異なり、かつ誤差指標Daが誤差指標Db以下であるとき、MPMの0番目のイントラ予測モード候補として代表イントラ予測モードPaに定め、MPMの1番目のイントラ予測候補として代表イントラ予測モードPbに定める。また、代表イントラ予測モードPaと代表イントラ予測モードPbが異なる場合であって、誤差指標Daが誤差指標Dbより大きいとき、MPM順位決定部2073は、MPMの0番目のイントラ予測モード候補として代表イントラ予測モードPbに定め、MPMの1番目のイントラ予測モード候補として代表イントラ予測モードPaに定める。   Here, when the representative intra prediction mode Pa and the representative intra prediction mode Pb are different and the error index Da is equal to or less than the error index Db, the MPM order determination unit 2073 represents the representative intra prediction as the MPM 0th intra prediction mode candidate. The mode Pa is set and the representative intra prediction mode Pb is set as the first MPM intra prediction candidate. When the representative intra prediction mode Pa and the representative intra prediction mode Pb are different and the error index Da is larger than the error index Db, the MPM rank determination unit 2073 displays the representative intra as a 0th intra prediction mode candidate of MPM. The prediction mode Pb is set, and the MPM first intra prediction mode candidate is set as the representative intra prediction mode Pa.

なお、代表イントラ予測モードPaと代表イントラ予測モードPbが異なる場合、MPM順位決定部2073は、MPMの2番目のイントラ予測モード候補を、HEVC方式と同様の手順を用いて定める。また、代表イントラ予測モードPaと代表イントラ予測モードPbが等しい場合も、MPM順位決定部2073は、MPMの各イントラ予測モード候補を、HEVC方式と同様の手順を用いて定める。無効な参照ブロックについて、MPM順位決定部2073は、代表イントラ予測モードをDC予測と定める。   When the representative intra prediction mode Pa and the representative intra prediction mode Pb are different, the MPM order determination unit 2073 determines the second intra prediction mode candidate of the MPM using the same procedure as in the HEVC scheme. Also, when the representative intra prediction mode Pa and the representative intra prediction mode Pb are equal, the MPM order determination unit 2073 determines each intra prediction mode candidate of the MPM using the same procedure as in the HEVC scheme. For invalid reference blocks, the MPM rank determination unit 2073 determines the representative intra prediction mode as DC prediction.

イントラ予測モード情報生成部2074は、MPM順位決定部2073から入力されるMPMのイントラ予測モード候補とそれらの順位を示すイントラ予測モード情報として生成する。イントラ予測モード情報生成部2074は、生成したイントラ予測モード情報を候補判定部2075に出力する。   The intra prediction mode information generation unit 2074 generates MPM intra prediction mode candidates input from the MPM order determination unit 2073 and intra prediction mode information indicating their ranks. The intra prediction mode information generation unit 2074 outputs the generated intra prediction mode information to the candidate determination unit 2075.

候補判定部2075には、可変長復号部201から対象ブロックの代表イントラ予測モード情報としてイントラ予測フラグとイントラ予測モードの候補の順位の番号もしくは採用予測モードの番号を示すビット列が入力される。また、候補判定部2075には、MPM順位決定部2073からイントラ予測モード情報が入力される。候補判定部2075は、イントラ予測フラグに基づき代表イントラ予測モードがMPMのイントラ予測モード候補に含まれていることを示すか否かを判定する。含まれていると判定するとき、候補判定部2075は、代表イントラ予測モード情報に含まれる番号が示す順位のイントラ予測モード候補を、イントラ予測モード情報が示すMPMから選択する。候補判定部2075は、選択したイントラ予測モード候補を対象ブロックの代表イントラ予測モードであると判定する。   The candidate determination unit 2075 receives the intra prediction flag and the bit number indicating the number of the rank of the candidate of the intra prediction mode or the number of the adopted prediction mode as the representative intra prediction mode information of the target block from the variable length decoding unit 201. In addition, intra prediction mode information is input from the MPM rank determination unit 2073 to the candidate determination unit 2075. The candidate determination unit 2075 determines whether or not the representative intra prediction mode is included in the MPM intra prediction mode candidates based on the intra prediction flag. When determining that it is included, the candidate determination unit 2075 selects an intra prediction mode candidate having a rank indicated by the number included in the representative intra prediction mode information from the MPM indicated by the intra prediction mode information. The candidate determination unit 2075 determines that the selected intra prediction mode candidate is the representative intra prediction mode of the target block.

代表イントラ予測モードがMPMのイントラ予測モード候補に含まれていないと判定するとき、候補判定部2075は、MPMのイントラ予測モード候補のモード番号を昇順に並び替える。候補判定部2075は、イントラ予測モード情報に含まれる採用予測モード番号がMPMの0番目のイントラ予測モード候補のモード番号以上であるとき、採用予測モード番号を1増加させる。候補判定部2075は、増加させた採用予測モード番号がMPMの1番目のイントラ予測モード候補のモード番号以上であるとき、採用予測モード番号をさらに1増加させる。候補判定部2075は、さらに増加させた採用予測モード番号がMPMの2番目のイントラ予測モード候補のモード番号以上であるとき、採用予測モード番号をまたさらに1増加させる。そして、候補判定部2075は、採用予測モード番号対象ブロックの代表イントラ予測モードとして定める。候補判定部2075は、定めた代表イントラ予測モードの情報をイントラ予測画像生成部2076に出力する。   When determining that the representative intra prediction mode is not included in the MPM intra prediction mode candidates, the candidate determination unit 2075 rearranges the mode numbers of the MPM intra prediction mode candidates in ascending order. The candidate determination unit 2075 increments the adoption prediction mode number by 1 when the adoption prediction mode number included in the intra prediction mode information is greater than or equal to the mode number of the MPM 0th intra prediction mode candidate. When the increased adoption prediction mode number is equal to or greater than the mode number of the first intra prediction mode candidate of MPM, the candidate determination unit 2075 further increases the adoption prediction mode number by one. The candidate determination unit 2075 further increases the adoption prediction mode number by 1 when the adopted prediction mode number further increased is equal to or greater than the mode number of the second intra prediction mode candidate of the MPM. Then, the candidate determination unit 2075 determines the representative prediction mode of the adoption prediction mode number target block. The candidate determination unit 2075 outputs the information on the determined representative intra prediction mode to the intra predicted image generation unit 2076.

イントラ予測画像生成部2076は、参照ブロック内の復号画像を参照し、候補判定部2075から入力された情報が示す代表イントラ予測モードを用いてイントラ予測を行う。イントラ予測画像生成部2076は、イントラ予測により生成されたイントラ予測画像ブロックを加算部204に出力する。   The intra predicted image generation unit 2076 refers to the decoded image in the reference block, and performs intra prediction using the representative intra prediction mode indicated by the information input from the candidate determination unit 2075. The intra predicted image generation unit 2076 outputs the intra predicted image block generated by the intra prediction to the adding unit 204.

(MPM決定処理)
次に、本実施形態に係るMPM決定処理について説明する。図7は、本実施形態に係るMPM決定処理を示すフローチャートである。以下の説明では、MPM決定部1103がMPM決定処理の動作主体である場合を例にするが、MPM決定部2071も図7に示す処理を行う。
(MPM decision processing)
Next, the MPM determination process according to the present embodiment will be described. FIG. 7 is a flowchart showing MPM determination processing according to the present embodiment. In the following description, the case where the MPM determination unit 1103 is the main subject of the MPM determination process is taken as an example, but the MPM determination unit 2071 also performs the process shown in FIG.

(ステップS101)MPM決定部1103の誤差指標取得部1104は、ブロックAが無効であるか否かを判定する。無効であると判定するとき(ステップS101 YES)、ステップS102の処理に進む。有効であると判定するとき(ステップS101 NO)、誤差指標取得部1104は、ブロックAの代表イントラ予測モードPaに係る誤差指標を取得し、ステップS103の処理に進む。
(ステップS102)MPM順位決定部1105は、ブロックAの代表イントラ予測モードPaをDC予測と定める。誤差指標取得部1104は、ブロックAの誤差指標Daを誤差指標の最大値Zと定める。その後、ステップS103の処理に進む。
(Step S101) The error index acquisition unit 1104 of the MPM determination unit 1103 determines whether or not the block A is invalid. When it is determined to be invalid (YES in step S101), the process proceeds to step S102. When it determines with it being effective (step S101 NO), the error parameter | index acquisition part 1104 acquires the error parameter | index which concerns on the representative intra prediction mode Pa of the block A, and progresses to the process of step S103.
(Step S102) The MPM order determination unit 1105 determines the representative intra prediction mode Pa of the block A as DC prediction. The error index acquisition unit 1104 determines the error index Da of the block A as the maximum value Z of the error index. Thereafter, the process proceeds to step S103.

(ステップS103)誤差指標取得部1104は、ブロックBが無効であるか否かを判定する。無効であると判定するとき(ステップS103 YES)、ステップS104の処理に進む。有効であると判定するとき(ステップS103 NO)、誤差指標取得部1104は、ブロックBの代表イントラ予測モードPbに係る誤差指標を取得し、ステップS105の処理に進む。
(ステップS104)MPM順位決定部1105は、ブロックBの代表イントラ予測モードPbをDC予測と定める。誤差指標取得部1104は、ブロックBの誤差指標Dbを誤差指標の最大値Zと定める。その後、ステップS105の処理に進む。
(Step S103) The error index acquisition unit 1104 determines whether or not the block B is invalid. When it is determined to be invalid (YES in step S103), the process proceeds to step S104. When it determines with it being effective (step S103 NO), the error parameter | index acquisition part 1104 acquires the error parameter | index which concerns on the representative intra prediction mode Pb of the block B, and progresses to the process of step S105.
(Step S104) The MPM order determination unit 1105 determines the representative intra prediction mode Pb of the block B as DC prediction. The error index acquisition unit 1104 determines the error index Db of the block B as the maximum error index value Z. Thereafter, the process proceeds to step S105.

(ステップS105)MPM順位決定部1105は、ブロックAの代表イントラ予測モードPaとブロックBの代表イントラ予測モードPbが異なるか否かを判定する。異なると判定するとき(ステップS105 YES)、ステップS106の処理に進む。異ならないと判定するとき(ステップS105 NO)、ステップS109の処理に進む。 (Step S105) The MPM order determination unit 1105 determines whether the representative intra prediction mode Pa of the block A and the representative intra prediction mode Pb of the block B are different. When it is determined that they are different (YES in step S105), the process proceeds to step S106. When it is determined that they are not different (NO in step S105), the process proceeds to step S109.

(ステップS106)MPM順位決定部1105は、代表イントラ予測モードPaに係る誤差指標Daが代表イントラ予測モードPbに係る誤差指標Db以下であるか否かを判定する。誤差指標Daが誤差指標Db以下であると判定するとき(ステップS106 YES)、ステップS107の処理に進む。誤差指標Daが誤差指標Dbより大きいと判定するとき(ステップS106 NO)、ステップS108の処理に進む。 (Step S106) The MPM rank determination unit 1105 determines whether or not the error index Da related to the representative intra prediction mode Pa is equal to or less than the error index Db related to the representative intra prediction mode Pb. When it is determined that the error index Da is equal to or less than the error index Db (YES in step S106), the process proceeds to step S107. When it is determined that the error index Da is larger than the error index Db (NO in step S106), the process proceeds to step S108.

(ステップS107)MPM順位決定部1105は、MPMの0番目のイントラ予測モード候補MPM[0]として代表イントラ予測モードPaに定め、MPMの1番目のイントラ予測モード候補MPM[1]として代表イントラ予測モードPbに定める。MPM順位決定部1105は、MPMの2番目のイントラ予測モード候補MPM[2]をHEVC方式と同様の処理を行って定める。その後、図7の処理を終了する。 (Step S107) The MPM order determination unit 1105 determines the representative intra prediction mode Pa as the MPM 0th intra prediction mode candidate MPM [0], and sets the representative intra prediction as the MPM first intra prediction mode candidate MPM [1]. Set to mode Pb. The MPM order determination unit 1105 determines the second intra prediction mode candidate MPM [2] of the MPM by performing the same process as in the HEVC scheme. Thereafter, the process of FIG.

(ステップS108)MPM順位決定部1105は、MPMの0番目のイントラ予測モード候補MPM[0]として代表イントラ予測モードPbに定め、MPMの1番目のイントラ予測モード候補MPM[1]として代表イントラ予測モードPaに定める。MPM順位決定部1105は、MPMの2番目のイントラ予測モード候補MPM[2]をHEVC方式と同様の処理を行って定める。その後、図7の処理を終了する。 (Step S108) The MPM rank determination unit 1105 determines the representative intra prediction mode Pb as the MPM 0th intra prediction mode candidate MPM [0] and the representative intra prediction as the MPM first intra prediction mode candidate MPM [1]. Set to mode Pa. The MPM order determination unit 1105 determines the second intra prediction mode candidate MPM [2] of the MPM by performing the same process as in the HEVC scheme. Thereafter, the process of FIG.

(ステップS109)MPM順位決定部1105は、MPMの0番目から2番目までのイントラ予測モード候補MPM[0]〜MPM[2]をHEVC方式と同様の処理を行って定める。その後、図7の処理を終了する。 (Step S109) The MPM order determination unit 1105 determines the MPM 0th to 2nd intra prediction mode candidates MPM [0] to MPM [2] by performing the same process as in the HEVC scheme. Thereafter, the process of FIG.

以上に説明したように、本実施形態に係る画像符号化装置1、画像復号装置2は、イントラ予測器1100、2070を備える。イントラ予測器1100、2070は、誤差指標取得部1104、2072と、MPM順位決定部1105、2073とを備える。誤差指標取得部1104、2072は、対象ブロックの周囲の参照ブロックの代表イントラ予測モードを用いたイントラ予測によって得られた予測画像の誤差指標を取得する。MPM順位決定部1105、2073は、参照ブロックの代表イントラ予測モードをイントラ予測モード候補として採用するとき、そのイントラ予測モード候補の順位を誤差指標の昇順に定める。
この構成によれば、入力画像ブロックとの誤差量が最も小さくなるイントラ予測画像を与える代表イントラ予測モードが、順位が高いイントラ予測モード候補と一致する可能性
が高くなる。代表イントラ予測モードの符号化に係るイントラ予測モード候補の数、即ちその符号化ビット数を少なくすることができる。
As described above, the image encoding device 1 and the image decoding device 2 according to this embodiment include the intra predictors 1100 and 2070. The intra predictors 1100 and 2070 include error index acquisition units 1104 and 2072 and MPM rank determination units 1105 and 2073. The error index acquisition units 1104 and 2072 acquire the error index of the predicted image obtained by the intra prediction using the representative intra prediction mode of the reference blocks around the target block. When adopting the representative intra prediction mode of the reference block as an intra prediction mode candidate, the MPM rank determination units 1105 and 2073 determine the rank of the intra prediction mode candidate in ascending order of the error index.
According to this configuration, there is a high possibility that the representative intra prediction mode that gives the intra prediction image that minimizes the amount of error from the input image block matches the intra prediction mode candidate with the higher rank. The number of intra prediction mode candidates related to encoding of the representative intra prediction mode, that is, the number of encoded bits can be reduced.

また、誤差指標取得部1104、2072は、誤差指標としてイントラ予測画像に基づく予測残差の量子化変換係数のデータを可変長符号化して得られるビット列のビット数を取得する。
この構成によれば、イントラ予測モード候補の順位が、それぞれのイントラ予測モード候補を用いて生成されたイントラ予測画像に基づく予測残差のビット列のビット数の昇順に定められる。予測残差の大きさとしてそのビット数が少ないイントラ予測モード候補が、対象ブロックに係る代表イントラ予測モードと一致する可能性が高くなる。そのため、代表イントラ予測モードの符号化に係る符号化ビット数を少なくすることができる。
Further, the error index acquisition units 1104 and 2072 acquire the number of bits of a bit string obtained by variable-length encoding the data of the prediction residual quantization transform coefficient based on the intra prediction image as an error index.
According to this configuration, the ranking of the intra prediction mode candidates is determined in ascending order of the number of bits of the bit string of the prediction residual based on the intra prediction image generated using each intra prediction mode candidate. There is a high possibility that an intra prediction mode candidate having a small number of bits as the size of the prediction residual matches the representative intra prediction mode related to the target block. Therefore, it is possible to reduce the number of encoded bits related to encoding in the representative intra prediction mode.

また、誤差指標取得部1104、2072は、誤差指標としてイントラ予測画像に基づく予測残差の量子化変換係数のうち零以外の値を有する非零変換係数の数を取得する。
この構成によれば、イントラ予測モード候補の順位が、それぞれのイントラ予測モード候補を用いて生成されたイントラ予測画像に基づく予測残差の非零変換係数の数が少ないイントラ予測モード候補が、対象ブロックに係る代表イントラ予測モードと一致する可能性が高くなる。そのため、代表イントラ予測モードの符号化に係る符号化ビット数を少なくすることができる。
Further, the error index acquisition units 1104 and 2072 acquire the number of non-zero transform coefficients having a value other than zero among the quantized transform coefficients of the prediction residual based on the intra prediction image as the error index.
According to this configuration, the intra prediction mode candidates are ranked with a small number of non-zero transform coefficients of the prediction residual based on the intra prediction image generated using each intra prediction mode candidate. The possibility of matching with the representative intra prediction mode related to the block increases. Therefore, it is possible to reduce the number of encoded bits related to encoding in the representative intra prediction mode.

また、誤差指標取得部1104、2072は、誤差指標としてイントラ予測画像に基づく予測残差の量子化変換係数の二乗和を取得する。
この構成によれば、イントラ予測モード候補の順位が、それぞれのイントラ予測モード候補を用いて生成されたイントラ予測画像に基づく予測残差の量子化変換係数の二乗和が小さいイントラ予測モード候補が、対象ブロックに係る代表イントラ予測モードと一致する可能性が高くなる。よって、代表イントラ予測モードの符号化に係る符号化ビット数を少なくすることができる。
Further, the error index acquisition units 1104 and 2072 acquire the sum of squares of the quantized transform coefficients of the prediction residual based on the intra prediction image as the error index.
According to this configuration, the intra prediction mode candidates whose ranks of the quantized transform coefficients of the prediction residuals based on the intra prediction images generated using the respective intra prediction mode candidates are small are the ranks of the intra prediction mode candidates. The possibility of matching with the representative intra prediction mode related to the target block increases. Therefore, it is possible to reduce the number of encoded bits related to encoding in the representative intra prediction mode.

また、誤差指標取得部1104、2072は、誤差指標として前記イントラ予測画像に基づく予測残差の量子化変換係数の絶対値和を取得する。
この構成によれば、イントラ予測モード候補の順位が、それぞれのイントラ予測モード候補を用いて生成されたイントラ予測画像に基づく予測残差の量子化変換係数の絶対値和が小さいイントラ予測モード候補が、対象ブロックに係る代表イントラ予測モードと一致する可能性が高くなる。よって、代表イントラ予測モードの符号化に係る符号化ビット数を少なくすることができる。
Further, the error index acquisition units 1104 and 2072 acquire the absolute value sum of the quantized transform coefficients of the prediction residual based on the intra prediction image as an error index.
According to this configuration, the intra prediction mode candidates having a small absolute value sum of the quantized transform coefficients of the prediction residuals based on the intra prediction images generated using the respective intra prediction mode candidates. There is a high possibility that it matches the representative intra prediction mode related to the target block. Therefore, it is possible to reduce the number of encoded bits related to encoding in the representative intra prediction mode.

(第2の実施形態)
次に、図面を参照しながら本発明の第2の実施形態について説明する。上述の実施形態と同一の構成については同一の符号を付してその説明を援用する。本実施形態に係るイントラ予測器1100、2070は、図7に示すHEVC方式に基づくMPM決定処理をよりも一般化したイントラ予測モード候補グループ決定処理を実行する。本実施形態に係る本実施形態に係る画像符号化装置1および画像復号装置2は、それぞれ当該イントラ予測器1100、2070を含んで構成される。なお、本実施形態でもイントラ予測モード候補からなるグループをMPMと呼ぶ。
(Second Embodiment)
Next, a second embodiment of the present invention will be described with reference to the drawings. About the same structure as the above-mentioned embodiment, the same code | symbol is attached | subjected and the description is used. The intra predictors 1100 and 2070 according to the present embodiment execute an intra prediction mode candidate group determination process that is a more generalized MPM determination process based on the HEVC scheme shown in FIG. The image encoding device 1 and the image decoding device 2 according to the present embodiment according to the present embodiment are configured to include the intra predictors 1100 and 2070, respectively. Note that a group of intra prediction mode candidates is also referred to as MPM in this embodiment.

(MPM決定処理)
次に、本実施形態に係るMPM決定処理について説明する。以下に説明する例では、参照ブロックの数をMに一般化する。Mは、2以上の整数である。また、MPMの数をNと表す。MPMの順位として、0番目〜N−1番目が存在する。Nは、Mよりも大きい整数である。M個の参照ブロック1〜Mの代表イントラ予測モードをP[1]〜P[M]と表す。例えば、MPMとして用いられる代表イントラ予測モードに係る参照ブロックとして、HEVC方式のように対象ブロックの上方もしくは左方のブロックに限られず、例えば、対象ブロックの左上のブロック、右上のブロックなどもさらに用いられてもよい。参照ブロック1〜Mのそれぞれについての誤差指標をD[1]〜D[M]と表す。デフォルトMPMを、L[1]、L[2]、…と表す。但し、無効な参照ブロックについて設定される代表イントラ予測モードをXと表す。
(MPM decision processing)
Next, the MPM determination process according to the present embodiment will be described. In the example described below, the number of reference blocks is generalized to M. M is an integer of 2 or more. The number of MPMs is represented as N. MPM ranks 0 to N-1 are present. N is an integer larger than M. The representative intra prediction modes of M reference blocks 1 to M are represented as P [1] to P [M]. For example, the reference block related to the representative intra prediction mode used as the MPM is not limited to the block above or to the left of the target block as in the HEVC method, and for example, the upper left block and the upper right block of the target block are also used. May be. The error index for each of the reference blocks 1 to M is represented as D [1] to D [M]. The default MPM is represented as L [1], L [2],. However, the representative intra prediction mode set for an invalid reference block is represented by X.

図8は、本実施形態に係るMPM決定処理を示すフローチャートである。以下の説明では、MPM決定部1103が動作主体である場合を例にするが、MPM決定部2071も動作主体になりうる。また、図8に示す処理では、閾値D[0]が導入される。閾値D[0]は、デフォルトMPMが選択される度合いを調整するための調整パラメータである。   FIG. 8 is a flowchart showing MPM determination processing according to the present embodiment. In the following description, a case where the MPM determination unit 1103 is an operation subject is taken as an example, but the MPM determination unit 2071 can also be an operation subject. In the process shown in FIG. 8, a threshold value D [0] is introduced. The threshold value D [0] is an adjustment parameter for adjusting the degree to which the default MPM is selected.

(ステップS121)MPM決定部1103の誤差指標取得部1104は、M個の参照ブロックのうち有効な参照ブロックの代表イントラ予測モードP[1]〜P[M]のそれぞれと同一のイントラ予測モードに係る誤差指標を取得する。また、誤差指標取得部1104は、M個の参照ブロックのうち無効な参照ブロックそれぞれについて誤差指標をその最大値Zと定める。その後、ステップS122の処理に進む。 (Step S121) The error index acquisition unit 1104 of the MPM determination unit 1103 sets the intra prediction mode that is the same as each of the representative intra prediction modes P [1] to P [M] of valid reference blocks among the M reference blocks. Such an error index is obtained. Further, the error index acquisition unit 1104 determines the error index as the maximum value Z for each invalid reference block among the M reference blocks. Thereafter, the process proceeds to step S122.

(ステップS122)MPM順位決定部1105は、M個の誤差指標D[1]〜D[M]と閾値D[0]とを昇順にソートする。ソートによって得られる閾値D[0]ならびに参照ブロック1〜Mのインデックスをi[0]〜i[M]と表す。インデックスi[0]〜i[M]は、1以上の整数値をとる。インデックスi[0]〜i[M]からなるリストは、並び替えられた参照ブロックならびに閾値の順位を示す。但し、MPM順位決定部1105は、無効な参照ブロックの代表イントラ予測モードをイントラ予測モードXと定め、それらの参照ブロックのインデックスを0と設定する。その後、ステップS123の処理に進む。 (Step S122) The MPM order determination unit 1105 sorts the M error indexes D [1] to D [M] and the threshold value D [0] in ascending order. The threshold value D [0] obtained by sorting and the indexes of the reference blocks 1 to M are represented as i [0] to i [M]. The indexes i [0] to i [M] take integer values of 1 or more. The list composed of the indexes i [0] to i [M] indicates the rearranged reference blocks and threshold rankings. However, the MPM order determination unit 1105 determines the representative intra prediction mode of invalid reference blocks as the intra prediction mode X, and sets the indexes of those reference blocks to 0. Thereafter, the process proceeds to step S123.

(ステップS123)MPM順位決定部1105は、インデックスx、yの初期値をそれぞれ0、1と設定する。インデックスxは、MPMのイントラ予測モード候補として採用される参照ブロックの代表イントラ予測モードの順位を、誤差指標の昇順に計数するためのインデックスである。インデックスyは、MPMのイントラ予測モード候補として採用されるデフォルトMPMの順位を計数するためのインデックスである。その後、ステップS124に進む。 (Step S123) The MPM order determination unit 1105 sets the initial values of the indexes x and y to 0 and 1, respectively. The index x is an index for counting the rank of the representative intra prediction mode of the reference block adopted as the MPM intra prediction mode candidate in ascending order of the error index. The index y is an index for counting the rank of the default MPM employed as an MPM intra prediction mode candidate. Thereafter, the process proceeds to step S124.

(ステップS124)MPM順位決定部1105は、x番目のインデックスi[x]が0であるか否かを判定する。この判定により、x番目の参照ブロックが無効であるか否かが判定される。0であると判定されるとき(ステップS124 YES)、ステップS129の処理に進む。0でないと判定されるとき(ステップS124 NO)、ステップS125の処理に進む。 (Step S124) The MPM order determination unit 1105 determines whether or not the x-th index i [x] is 0. By this determination, it is determined whether or not the xth reference block is invalid. When it is determined that the value is 0 (YES in step S124), the process proceeds to step S129. When it is determined that it is not 0 (NO in step S124), the process proceeds to step S125.

(ステップS125)MPM順位決定部1105は、MPMにi[x]番目のイントラ予測モードP[i[x]]が含まれているか否かを判定する。含まれていると判定されるとき(ステップS125 YES)、ステップS128の処理に進む。含まれていないと判定されるとき(ステップS125 NO)、ステップS126の処理に進む。 (Step S125) The MPM order determination unit 1105 determines whether or not the i [x] -th intra prediction mode P [i [x]] is included in the MPM. When it is determined that it is included (step S125 YES), the process proceeds to step S128. When it is determined that it is not included (NO in step S125), the process proceeds to step S126.

(ステップS126)MPM順位決定部1105は、MPMにi[x]番目のイントラ予測モードP[i[x]]を加える。加えられるイントラ予測モードP[i[x]]のMPM内の順位は、その時点において最下位である。従って、初めてMPMに加えられるイントラ予測モードP[i[x]]の順位は0番目となる。その後、ステップS127の処理に進む。
(ステップS127)MPM順位決定部1105は、インデックスxの値に1を加える(インクリメント)。その後、ステップS128の処理に進む。
(ステップS128)MPM順位決定部1105は、MPMに含まれるイントラ予測モードの総数がN未満であるかを判定する。N未満であると判定されるとき(ステップS128 YES)、ステップS124の処理に進む。N以上であると判定されるとき(ステップS128 NO)、図8に示す処理を終了する。
(Step S126) The MPM order determination unit 1105 adds the i [x] -th intra prediction mode P [i [x]] to the MPM. The rank in the MPM of the intra prediction mode P [i [x]] to be added is the lowest at that time. Therefore, the rank of the intra prediction mode P [i [x]] added to the MPM for the first time is 0th. Thereafter, the process proceeds to step S127.
(Step S127) The MPM order determination unit 1105 adds 1 to the value of the index x (increment). Thereafter, the process proceeds to step S128.
(Step S128) The MPM order determination unit 1105 determines whether the total number of intra prediction modes included in the MPM is less than N. When it is determined that the number is less than N (YES in step S128), the process proceeds to step S124. When it is determined that the number is greater than or equal to N (NO in step S128), the process illustrated in FIG.

(ステップS129)MPM順位決定部1105は、MPMにy番目のデフォルトMPM L[y]が含まれているか否かを判定する。含まれていると判定されるとき(ステップS129 YES)、ステップS128の処理に進む。含まれていないと判定されるとき(ステップS129 NO)、ステップS130の処理に進む。 (Step S129) The MPM order determination unit 1105 determines whether or not the y-th default MPM L [y] is included in the MPM. If it is determined that it is included (YES in step S129), the process proceeds to step S128. When it is determined that it is not included (NO in step S129), the process proceeds to step S130.

(ステップS130)MPM順位決定部1105は、MPMにy番目のデフォルトMPM L[y]を加える。加えられるデフォルトMPM L[y]のMPM内の順位は、その時点において最下位になる。その後、ステップS131の処理に進む。
(ステップS131)MPM順位決定部1105は、インデックスyの値に1を加える(インクリメント)。その後、ステップS128の処理に進む。
(Step S130) The MPM order determination unit 1105 adds the y-th default MPM L [y] to the MPM. The rank in the MPM of the default MPM L [y] added is the lowest at that time. Thereafter, the process proceeds to step S131.
(Step S131) The MPM order determination unit 1105 adds 1 to the value of the index y (increment). Thereafter, the process proceeds to step S128.

なお、ステップS122において、M個のうちの一部の2個以上の参照ブロックの代表イントラ予測モードについて誤差指標が互いに等しくなる場合がある。誤差指標が等しい参照ブロック間では、誤差指標取得部1104は、例えば、参照ブロックごとの順位を参照ブロックのインデックスの昇順に定める。誤差指標取得部1104は、他の種類の誤差指標をさらに取得し、参照ブロックごとの順位をさらに取得した誤差指標の昇順に定めてもよい。   Note that, in step S122, the error indices may be equal to each other for representative intra prediction modes of a part of two or more reference blocks out of M. For example, between the reference blocks having the same error index, the error index acquisition unit 1104 determines the rank of each reference block in ascending order of the index of the reference block. The error index acquisition unit 1104 may further acquire other types of error indexes, and may determine the rank for each reference block in ascending order of the acquired error indexes.

また、ステップS122において、M個のうちの一部の2個以上(例えば、K個)の参照ブロックの代表イントラ予測モードが互いに同一になる場合がある。互いに同一の代表イントラ予測モードが非方向性予測である場合には、誤差指標取得部1104は、K−1個の参照ブロックごとの順位を設けなくてもよい。その場合には、MPM順位決定部1105は、ステップS130の処理においてK−1個のデフォルトMPMをMPMに追加する。また、互いに同一の代表イントラ予測モードが方向性予測である場合もある。その場合には、誤差指標取得部1104は、その代表イントラ予測モードの参照方向から参照方向が近い順にK−1個の方向性予測に係るイントラ予測モードをK−1個のイントラ予測モード候補として選択してもよい。また、誤差指標取得部1104は、K−1個の方向性予測に係るイントラ予測モードについても誤差指標に基づくソートの対象としてもよい。これにより、誤差指標が閾値D[0]よりも大きいイントラ予測モードが、信頼性が低いイントラ予測モードとしてMPMから除外される。   In step S122, the representative intra prediction modes of some of the M reference blocks of two or more (eg, K) may be the same. When the same representative intra prediction modes are non-directional predictions, the error index acquisition unit 1104 does not have to provide a rank for each of the K−1 reference blocks. In that case, the MPM order determination unit 1105 adds K-1 default MPMs to the MPM in the process of step S130. In addition, the same representative intra prediction mode may be directional prediction. In that case, the error index acquisition unit 1104 sets the K-1 intra prediction modes related to the directional prediction in the order from the reference direction closer to the reference direction of the representative intra prediction mode as K-1 intra prediction mode candidates. You may choose. The error index acquisition unit 1104 may also sort the intra prediction modes related to K−1 directional predictions based on the error index. Thereby, the intra prediction mode whose error index is larger than the threshold value D [0] is excluded from the MPM as an intra prediction mode with low reliability.

図8に示す処理によれば、閾値D[0]が小さいほど、デフォルトMPMがMPMのイントラ予測モード候補として選択される度合いが高くなる。例えば、閾値D[0]が最大値Zよりも大きい値としてZ+1に設定されるとき、参照ブロックの代表イントラ予測モードがデフォルトMPMよりも優先される。閾値D[0]が誤差指標として出現する可能性がある範囲内の値に設定されるとき、参照ブロックの代表イントラ予測モードよりもデフォルトMPMの方が優先して選択されることがある。   According to the processing shown in FIG. 8, the smaller the threshold D [0], the higher the degree to which the default MPM is selected as the MPM intra prediction mode candidate. For example, when the threshold value D [0] is set to Z + 1 as a value larger than the maximum value Z, the representative intra prediction mode of the reference block has priority over the default MPM. When the threshold value D [0] is set to a value within a range that may appear as an error index, the default MPM may be selected in preference to the representative intra prediction mode of the reference block.

そこで、誤差指標取得部1104は、参照ブロックに係る誤差指標の範囲に基づいて閾値D[0]を可変に設定してもよい。例えば、誤差指標取得部1104は、各参照ブロックに係る誤差指標の範囲内の値に閾値D[0]を設定する。その場合、閾値D[0]よりも大きい誤差指標に係る参照ブロックの代表イントラ予測モードと同一のイントラ予測モードよりもデフォルトMPMの方が優先して選択される。このようなイントラ予測モードは、予測残差の大きさを示す誤差指標が高いのでデフォルトMPMよりも信頼性が低いと考えられるためである。   Therefore, the error index acquisition unit 1104 may variably set the threshold value D [0] based on the error index range related to the reference block. For example, the error index acquisition unit 1104 sets the threshold value D [0] to a value within the range of the error index related to each reference block. In this case, the default MPM is selected with priority over the same intra prediction mode as the representative intra prediction mode of the reference block related to the error index larger than the threshold value D [0]. This is because such an intra prediction mode is considered to be less reliable than the default MPM because the error index indicating the magnitude of the prediction residual is high.

誤差指標取得部1104は、いずれかの参照ブロックに係る誤差指標よりも小さい誤差指標を与えるデフォルトMPMがあるとき、閾値D[0]を、そのデフォルトMPMに係る誤差指標とその参照ブロックに係る誤差指標との間の値に設定してもよい。その場合、閾値D[0]よりも大きい誤差指標に係る参照ブロックの代表イントラ予測モードよりも、閾値D[0]よりも小さい誤差指標に係るデフォルトMPMの方がMPMとして優先して選択される。   When there is a default MPM that gives an error index smaller than the error index related to any reference block, the error index acquisition unit 1104 sets the threshold D [0] as the error index related to the default MPM and the error related to the reference block. You may set to the value between indicators. In that case, the default MPM related to the error index smaller than the threshold D [0] is selected as the MPM with priority over the representative intra prediction mode of the reference block related to the error index larger than the threshold D [0]. .

閾値D[0]の設定において、誤差指標取得部1104は、誤差指標として量子化直交変換係数を示す符号を可変長符号化して得られるビット列のビット数を用いてもよい。そのため、より少ない符号量でイントラ予測モードを符号化するためのMPMが選択される。
誤差指標取得部1104は、必ずしもピクチャごとに閾値D[0]を変更しなくてもよい。閾値D[0]の設定周期は、より長い周期、例えば、所定のピクチャ数、アクセスユニット、シーケンスのいずれであってもよい。そのため、ピクチャごとに閾値D[0]を変更する場合よりも処理量が減少する。
誤差指標取得部1104は、設定した閾値D[0]を可変長符号化部104に出力する。
In setting the threshold value D [0], the error index acquisition unit 1104 may use the number of bits of a bit string obtained by variable length encoding a code indicating a quantized orthogonal transform coefficient as an error index. Therefore, an MPM for encoding the intra prediction mode with a smaller code amount is selected.
The error index acquisition unit 1104 does not necessarily have to change the threshold value D [0] for each picture. The set period of the threshold value D [0] may be a longer period, for example, a predetermined number of pictures, an access unit, or a sequence. Therefore, the processing amount is reduced as compared with the case where the threshold value D [0] is changed for each picture.
The error index acquisition unit 1104 outputs the set threshold value D [0] to the variable length encoding unit 104.

可変長符号化部104は、符号化データを形成するビットストリームのヘッダ(例えば、HEVC方式のSPS[Sequence Parameter Set]ヘッダ、PPS[Picture Parameter Set]ヘッダ等)に閾値D[0]を含める。
可変長復号部201は、入力される符号化データを形成するビットストリームのヘッダから閾値D[0]を抽出し、抽出した閾値D[0]を誤差指標取得部2072に出力する。誤差指標取得部2072は、可変長復号部201から入力される閾値D[0]を取得し、誤差指標取得部2072とMPM順位決定部2073は、可変長復号部201から入力される閾値[0]を図8の処理に用いる。
The variable length coding unit 104 includes a threshold value D [0] in the header of the bit stream forming the coded data (for example, HEVC SPS [Sequence Parameter Set] header, PPS [Picture Parameter Set] header, etc.).
The variable length decoding unit 201 extracts the threshold value D [0] from the header of the bit stream that forms the input encoded data, and outputs the extracted threshold value D [0] to the error index acquisition unit 2072. The error index acquisition unit 2072 acquires the threshold value D [0] input from the variable length decoding unit 201, and the error index acquisition unit 2072 and the MPM rank determination unit 2073 receive the threshold value [0] input from the variable length decoding unit 201. ] Is used in the process of FIG.

なお、図8に示す処理は、M=2、N=3、閾値D[0]=Z+1、無効な参照ブロックに係るイントラ予測モードXがDC予測、デフォルトMPM L[1]、L[2]、L[3]がそれぞれプレーナ予測、DC予測、垂直方向参照である場合、HEVC方式に基づく図7に示す処理と同様になる。   In the process shown in FIG. 8, M = 2, N = 3, threshold D [0] = Z + 1, intra prediction mode X related to an invalid reference block is DC prediction, default MPM L [1], L [2] , L [3] are planar prediction, DC prediction, and vertical reference, respectively, the processing is the same as that shown in FIG. 7 based on the HEVC scheme.

以上に説明したように、本実施形態に係るイントラ予測器1100、2070において、MPM順位決定部1105、2073は、イントラ予測モード候補として、所定の誤差指標の閾値よりも大きい誤差指標を与える参照ブロックの代表イントラ予測モードの順位を、所定のデフォルトMPMの順位よりも低くすることを特徴とする。
この構成により、所定の誤差指標の閾値より大きい誤差指標を与える参照画素に係る代表イントラ予測モードのイントラ予測モード候補の順位が、所定のデフォルトMPMよりも低くなる。そのため、代表イントラ予測モードの符号化において、より誤差指標が小さいデフォルトMPMが優先してイントラ予測モード候補として利用される。よって、参照ブロックに係る代表イントラ予測モードのみよりも、対象ブロックに係る代表イントラ予測モードの符号化において用いるイントラ予測モード候補の数、即ち符号化ビット数を少なくすることができる。
As described above, in the intra predictors 1100 and 2070 according to the present embodiment, the MPM rank determination units 1105 and 2073 give reference error blocks that are larger than a predetermined error index threshold as intra prediction mode candidates. The rank of the representative intra prediction mode is made lower than the rank of a predetermined default MPM.
With this configuration, the rank of the intra prediction mode candidate of the representative intra prediction mode related to the reference pixel that gives an error index larger than the predetermined error index threshold is lower than the predetermined default MPM. Therefore, in encoding of the representative intra prediction mode, a default MPM having a smaller error index is preferentially used as an intra prediction mode candidate. Therefore, it is possible to reduce the number of intra prediction mode candidates used in encoding the representative intra prediction mode related to the target block, that is, the number of encoded bits, rather than only the representative intra prediction mode related to the reference block.

また、誤差指標取得部1104、2072は、各イントラ予測モード候補に係る誤差指標の範囲に基づいて誤差指標の閾値を定める。
この構成により、代表イントラ予測モードの符号化において、定めた誤差指標の閾値に基づいて、参照画素に係る代表イントラ予測モードよりも誤差指標が小さいデフォルトMPMを優先して利用するか否かが判定される。よって、常に一定の誤差指標の閾値よりも大きい誤差指標を与える参照ブロックの代表イントラ予測モードの順位を所定のデフォルトMPMの順位よりも低くするよりも、代表イントラ予測モードの符号化ビット数を少なくすることができる。
Further, the error index acquisition units 1104 and 2072 determine a threshold value of the error index based on the range of the error index related to each intra prediction mode candidate.
With this configuration, in encoding of the representative intra prediction mode, it is determined whether or not the default MPM having a smaller error index than the representative intra prediction mode related to the reference pixel is used preferentially based on a predetermined threshold value of the error index. Is done. Therefore, the number of encoded bits in the representative intra prediction mode is less than that of the reference block representing the representative intra prediction mode that always gives an error index larger than a certain error index threshold than the predetermined default MPM order. can do.

以上、図面を参照してこの発明の一実施形態について詳しく説明してきたが、具体的な構成は上述のものに限られることはなく、この発明の要旨を逸脱しない範囲内において様々な設計変更等をすることが可能である。   As described above, the embodiment of the present invention has been described in detail with reference to the drawings. However, the specific configuration is not limited to the above, and various design changes and the like can be made without departing from the scope of the present invention. It is possible to

例えば、上述した実施形態に係る画像符号化装置1、画像復号装置2およびイントラ予測器が、それぞれ単体で実施されてもよいし、イントラ予測器を備える画像符号化装置1と画像復号装置2とを含む画像処理システムとして実施されてもよい。   For example, the image encoding device 1, the image decoding device 2, and the intra predictor according to the above-described embodiments may each be implemented alone, or the image encoding device 1 and the image decoding device 2 including the intra predictor, May be implemented as an image processing system.

なお、上述した画像符号化装置1もしくは画像復号装置2の一部、イントラ予測器1100、2070として構成されたイントラ予測器の一部をコンピュータで実現するようにしてもよい。その場合、この制御機能を実現するためのプログラムをコンピュータ読み取り可能な記録媒体に記録して、この記録媒体に記録されたプログラムをコンピュータシステムに読み込ませ、実行することによって実現してもよい。なお、ここでいう「コンピュータシステム」とは、画像符号化装置1、画像復号装置2もしくはイントラ予測器1100、2070に内蔵されたコンピュータシステムであって、OSや周辺機器等のハードウェアを含むものとする。また、「コンピュータ読み取り可能な記録媒体」とは、フレキシブルディスク、光磁気ディスク、ROM、CD−ROM等の可搬媒体、コンピュータシステムに内蔵されるハードディスク等の記憶装置のことをいう。さらに「コンピュータ読み取り可能な記録媒体」とは、インターネット等のネットワークや電話回線等の通信回線を介してプログラムを送信する場合の通信線のように、短時間、動的にプログラムを保持するもの、その場合のサーバやクライアントとなるコンピュータシステム内部の揮発性メモリのように、一定時間プログラムを保持しているものも含んでもよい。また上記プログラムは、前述した機能の一部を実現するためのものであってもよく、さらに前述した機能をコンピュータシステムにすでに記録されているプログラムとの組み合わせで実現できるものであってもよい。
また、上述した実施形態における画像符号化装置1、画像復号装置2もしくはイントラ予測器1100、2070の一部、または全部をLSI(Large Scale Integration)等の集積回路として実現してもよい。画像符号化装置1、画像復号装置2もしくはイントラ予測器1100、2070の各機能ブロックは個別にプロセッサ化してもよいし、一部、または全部を集積してプロセッサ化してもよい。また、集積回路化の手法はLSIに限らず専用回路、または汎用プロセッサで実現してもよい。また、半導体技術の進歩によりLSIに代替する集積回路化の技術が出現した場合、当該技術による集積回路を用いてもよい。
Note that a part of the image encoding device 1 or the image decoding device 2 described above and a part of the intra predictors configured as the intra predictors 1100 and 2070 may be realized by a computer. In that case, the program for realizing the control function may be recorded on a computer-readable recording medium, and the program recorded on the recording medium may be read by the computer system and executed. Here, the “computer system” is a computer system built in the image encoding device 1, the image decoding device 2, or the intra predictors 1100 and 2070, and includes hardware such as an OS and peripheral devices. . The “computer-readable recording medium” refers to a storage device such as a flexible medium, a magneto-optical disk, a portable medium such as a ROM and a CD-ROM, and a hard disk incorporated in a computer system. Furthermore, the “computer-readable recording medium” is a medium that dynamically holds a program for a short time, such as a communication line when transmitting a program via a network such as the Internet or a communication line such as a telephone line, In this case, a volatile memory inside a computer system that serves as a server or a client may be included that holds a program for a certain period of time. The program may be a program for realizing a part of the functions described above, and may be a program capable of realizing the functions described above in combination with a program already recorded in a computer system.
Moreover, you may implement | achieve part or all of the image coding apparatus 1, the image decoding apparatus 2, or the intra predictors 1100 and 2070 in the above-described embodiments as an integrated circuit such as an LSI (Large Scale Integration). Each functional block of the image encoding device 1, the image decoding device 2, or the intra predictors 1100 and 2070 may be individually made into a processor, or a part or all of them may be integrated into a processor. Further, the method of circuit integration is not limited to LSI, and may be realized by a dedicated circuit or a general-purpose processor. In addition, when an integrated circuit technology that replaces LSI appears due to the advancement of semiconductor technology, an integrated circuit based on the technology may be used.

1…画像符号化装置、2…画像復号装置、101…減算部、102…直交変換部、103…量子化部、104…可変長符号化部、105…逆量子化部、106…逆直交変換部、107…加算部、108…ループフィルタ、109…参照メモリ、110…イントラ予測部、111…インター予測部、112…選択部、201…可変長復号部、202…逆量子化部、203…逆直交変換部、204…加算部、205…ループフィルタ、206…参照メモリ、207…イントラ予測部、208…インター予測部、1100…イントラ予測器、1101…イントラ予測画像生成部、1102…減算部、1103…MPM決定部、1104…誤差指標取得部、1105…MPM順位決定部、1106…イントラ予測モード情報生成部、1107…候補判定部、2070…イントラ予測器、2071…MPM決定部、2072…誤差指標取得部、2073…MPM順位決定部、2074…イントラ予測モード情報生成部、2075…候補判定部、2076…イントラ予測画像生成部 DESCRIPTION OF SYMBOLS 1 ... Image coding apparatus, 2 ... Image decoding apparatus, 101 ... Subtraction part, 102 ... Orthogonal transformation part, 103 ... Quantization part, 104 ... Variable length coding part, 105 ... Dequantization part, 106 ... Inverse orthogonal transformation 107: Adder, 108 ... Loop filter, 109 ... Reference memory, 110 ... Intra prediction unit, 111 ... Inter prediction unit, 112 ... Selection unit, 201 ... Variable length decoding unit, 202 ... Inverse quantization unit, 203 ... Inverse orthogonal transform unit, 204 ... addition unit, 205 ... loop filter, 206 ... reference memory, 207 ... intra prediction unit, 208 ... inter prediction unit, 1100 ... intra prediction unit, 1101 ... intra prediction image generation unit, 1102 ... subtraction unit DESCRIPTION OF SYMBOLS 1103 ... MPM determination part, 1104 ... Error parameter | index acquisition part, 1105 ... MPM ranking determination part, 1106 ... Intra prediction mode information generation part, 1107 ... Candidate judgment Department, 2070 ... intra-predictor, 2071 ... MPM determining unit, 2072 ... error indicator acquiring unit, 2073 ... MPM order determination unit, 2074 ... intra-prediction mode information generation unit, 2075 ... candidate determination unit, 2076 ... intra-prediction image generation unit

Claims (10)

対象ブロックの周囲の参照ブロックについて定めたイントラ予測モードを用いて得られた予測画像と入力画像との誤差指標を取得する誤差指標取得部と、
前記対象ブロックのイントラ予測モード候補として、前記参照ブロックについて定めたイントラ予測モードを用いるとき、前記イントラ予測モード候補の順位を前記誤差指標の昇順に定める順位決定部と、
を備えるイントラ予測器。
An error index acquisition unit for acquiring an error index between a predicted image and an input image obtained using an intra prediction mode determined for reference blocks around the target block;
When using the intra prediction mode defined for the reference block as the intra prediction mode candidate of the target block, a rank determining unit that determines the rank of the intra prediction mode candidates in ascending order of the error index;
An intra predictor comprising:
前記順位決定部は、前記イントラ予測モード候補として、所定の誤差指標の閾値よりも大きい前記誤差指標を与える前記参照ブロックのイントラ予測モードの順位を、所定のイントラ予測モード候補の順位よりも低くすること
を特徴とする請求項1に記載のイントラ予測器。
The rank determining unit lowers the rank of the intra prediction mode of the reference block that gives the error index larger than a predetermined error index threshold as the intra prediction mode candidate lower than the rank of the predetermined intra prediction mode candidate. The intra predictor according to claim 1, wherein:
前記誤差指標取得部は、前記参照ブロックについて定めたイントラ予測モードに係る誤差指標の範囲に基づいて前記誤差指標の閾値を定めること
を特徴とする請求項2に記載のイントラ予測器。
The intra predictor according to claim 2, wherein the error index acquisition unit determines a threshold of the error index based on an error index range related to an intra prediction mode determined for the reference block.
前記誤差指標取得部は、前記誤差指標として前記予測画像に基づく予測残差の量子化変換係数を可変長符号化して得られるビット列のビット数を取得すること
を特徴とする請求項1から請求項3のいずれか一項に記載のイントラ予測器。
The error index acquisition unit acquires the number of bits of a bit string obtained by variable-length encoding a quantized transform coefficient of a prediction residual based on the prediction image as the error index. 4. The intra predictor according to any one of 3.
前記誤差指標取得部は、前記誤差指標として前記予測画像に基づく予測残差の量子化変換係数のうち零以外の値を有する非零変換係数の数を取得すること
を特徴とする請求項1から請求項3のいずれか一項に記載のイントラ予測器。
The error index acquisition unit acquires the number of non-zero transform coefficients having a non-zero value among the quantized transform coefficients of the prediction residual based on the predicted image as the error index. The intra predictor according to claim 3.
前記誤差指標取得部は、前記誤差指標として前記予測画像に基づく予測残差の量子化変換係数の二乗和を取得する請求項1から請求項3のいずれか一項に記載のイントラ予測器。   The intra predictor according to any one of claims 1 to 3, wherein the error index acquisition unit acquires a square sum of quantized transform coefficients of a prediction residual based on the predicted image as the error index. 前記誤差指標取得部は、前記誤差指標として前記予測画像に基づく予測残差の量子化変換係数の絶対値和を取得する請求項1から請求項3のいずれか一項に記載のイントラ予測器。   The intra predictor according to any one of claims 1 to 3, wherein the error index acquisition unit acquires an absolute value sum of quantization transform coefficients of a prediction residual based on the predicted image as the error index. 請求項1から請求項7のいずれか一項に記載のイントラ予測器と、
前記参照ブロックの復号画像を参照して所定の各イントラ予測モードを用いてイントラ予測を行って得られる予測画像と前記対象ブロックの入力画像との誤差量に基づいて、いずれかのイントラ予測モードを選択し、
選択したイントラ予測モードと同一の前記イントラ予測モード候補の順位を判定する候補判定部と、
を備える画像符号化装置。
The intra predictor according to any one of claims 1 to 7,
Based on the error amount between the prediction image obtained by performing intra prediction using each predetermined intra prediction mode with reference to the decoded image of the reference block and the input image of the target block, one of the intra prediction modes is selected. Selected,
A candidate determination unit that determines the rank of the same intra prediction mode candidate as the selected intra prediction mode;
An image encoding device comprising:
請求項1から請求項7のいずれか一項に記載のイントラ予測器を備え、
入力された順位の前記イントラ予測モード候補と同一のイントラ予測モードを用いて得られる予測画像を用いて前記対象ブロックの復号画像を生成する
ことを特徴とする画像復号装置。
An intra predictor according to any one of claims 1 to 7,
An image decoding apparatus, comprising: generating a decoded image of the target block using a prediction image obtained using the same intra prediction mode as the intra prediction mode candidate of the input rank.
コンピュータに
対象ブロックの周囲の参照ブロックについて定めたイントラ予測モードを用いて得られた予測画像と入力画像との誤差指標を取得する誤差指標取得部と、
前記対象ブロックのイントラ予測モード候補として、前記参照ブロックについて定めたイントラ予測モードを用いるとき、前記イントラ予測モード候補の順位を前記誤差指標の昇順に定める順位決定部と、
を備えるイントラ予測器として機能させるためのプログラム。
An error index acquisition unit for acquiring an error index between a predicted image and an input image obtained using an intra prediction mode determined for reference blocks around the target block in a computer;
When using the intra prediction mode defined for the reference block as the intra prediction mode candidate of the target block, a rank determining unit that determines the rank of the intra prediction mode candidates in ascending order of the error index;
A program for causing a computer to function as an intra predictor.
JP2016121542A 2016-06-20 2016-06-20 Intra Predictor, Image Coding Device, Image Decoding Device and Program Active JP6796405B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2016121542A JP6796405B2 (en) 2016-06-20 2016-06-20 Intra Predictor, Image Coding Device, Image Decoding Device and Program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2016121542A JP6796405B2 (en) 2016-06-20 2016-06-20 Intra Predictor, Image Coding Device, Image Decoding Device and Program

Publications (2)

Publication Number Publication Date
JP2017228827A true JP2017228827A (en) 2017-12-28
JP6796405B2 JP6796405B2 (en) 2020-12-09

Family

ID=60892004

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2016121542A Active JP6796405B2 (en) 2016-06-20 2016-06-20 Intra Predictor, Image Coding Device, Image Decoding Device and Program

Country Status (1)

Country Link
JP (1) JP6796405B2 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110166777A (en) * 2018-07-04 2019-08-23 腾讯科技(深圳)有限公司 Coding method, device and video data encoding device
WO2019189903A1 (en) * 2018-03-30 2019-10-03 日本放送協会 Image encoding device, image decoding device, and program
US11330256B2 (en) 2018-08-08 2022-05-10 Fujitsu Limited Encoding device, encoding method, and decoding device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009055542A (en) * 2007-08-29 2009-03-12 Toshiba Corp Moving image encoder and moving image encoding method
JP2013081100A (en) * 2011-10-04 2013-05-02 Nippon Hoso Kyokai <Nhk> Intra-prediction device, encoding device, and program
US20150245068A1 (en) * 2014-02-21 2015-08-27 Industry-Academic Cooperation Foundation, Yonsei University Tsm rate-distortion optimizing method, encoding method and device using the same, and apparatus for processing picture

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009055542A (en) * 2007-08-29 2009-03-12 Toshiba Corp Moving image encoder and moving image encoding method
JP2013081100A (en) * 2011-10-04 2013-05-02 Nippon Hoso Kyokai <Nhk> Intra-prediction device, encoding device, and program
US20150245068A1 (en) * 2014-02-21 2015-08-27 Industry-Academic Cooperation Foundation, Yonsei University Tsm rate-distortion optimizing method, encoding method and device using the same, and apparatus for processing picture

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
SHIODERA, TAICHIRO ET AL.: "TE6 subset a: Bidirectional intra prediction", JOINT COLLABORATIVE TEAM ON VIDEO CODING (JCT-VC) OF ITU-T SG16 WP3 AND ISO/IEC JTC1/SC29/WG11 3RD M, vol. JCTVC-C079 (version 1), JPN6020011804, 2 October 2010 (2010-10-02), pages 1 - 10, ISSN: 0004241651 *

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019189903A1 (en) * 2018-03-30 2019-10-03 日本放送協会 Image encoding device, image decoding device, and program
US11388414B2 (en) 2018-03-30 2022-07-12 Nippon Hoso Kyokai Device and method for allocating code amounts to intra prediction modes
JP2022111285A (en) * 2018-03-30 2022-07-29 日本放送協会 Image encoding device, image decoding device, and program
JP7249999B2 (en) 2018-03-30 2023-03-31 日本放送協会 Image encoding device, image decoding device, and program
JP7340658B2 (en) 2018-03-30 2023-09-07 日本放送協会 Image encoding device, image decoding device, and program
US11991367B2 (en) 2018-03-30 2024-05-21 Nippon Hoso Kyokai Device and method for allocating code amounts to intra prediction modes
CN110166777A (en) * 2018-07-04 2019-08-23 腾讯科技(深圳)有限公司 Coding method, device and video data encoding device
CN110166777B (en) * 2018-07-04 2023-11-17 腾讯科技(深圳)有限公司 Encoding method, apparatus and video data encoding device
US11330256B2 (en) 2018-08-08 2022-05-10 Fujitsu Limited Encoding device, encoding method, and decoding device

Also Published As

Publication number Publication date
JP6796405B2 (en) 2020-12-09

Similar Documents

Publication Publication Date Title
TWI759389B (en) Low-complexity sign prediction for video coding
JP7525178B2 (en) Video signal processing method and apparatus using adaptive motion vector resolution - Patents.com
JP6353943B2 (en) Image filter device, decoding device, encoding device, and data structure
CN108028942B (en) Pixel prediction method, encoding method, decoding method, device thereof, and storage medium
CN108366257B (en) Data decoding apparatus and method, data encoding apparatus and method
RU2720975C2 (en) Method of encoding and decoding images, an encoding and decoding device and corresponding computer programs
WO2014054267A1 (en) Image coding device and image coding method
WO2013042888A2 (en) Method for inducing a merge candidate block and device using same
WO2013058473A1 (en) Adaptive transform method based on in-screen prediction and apparatus using the method
CN107810632B (en) Intra prediction processor with reduced cost block segmentation and refined intra mode selection
TW202247652A (en) Extended reference intra-picture prediction
KR20100074137A (en) Video coding method and video decoding method
JP2018519719A (en) Video decoding method and apparatus for performing intra prediction, and video encoding method and apparatus for performing intra prediction
JP6476900B2 (en) Moving picture coding apparatus, moving picture coding method, and computer program for moving picture coding
JP2018520549A (en) Video decoding method and apparatus for performing intra prediction, and video encoding method and apparatus for performing intra prediction
WO2013051794A1 (en) Method for encoding/decoding an intra-picture prediction mode using two intra-prediction mode candidates, and apparatus using such a method
CN110870312B (en) Method and apparatus for intra-frame coding in video compression
JP2019110530A (en) Method and device for encoding video data
JP6796405B2 (en) Intra Predictor, Image Coding Device, Image Decoding Device and Program
JP2018078409A (en) Intra-predictor, image coding device, image decoding device, and program
WO2023055300A9 (en) Improved residual sign prediction of transform coefficients in video coding
JP2019110529A (en) Method and device for encoding video data
JP2012134757A (en) Context adaptation entropy encoding method, context adaptation entropy decoding method, context adaptation entropy encoding apparatus, context adaptation entropy decoding apparatus and program thereof
JP7147145B2 (en) Video encoding device, video encoding method, and video encoding program
JP2017073602A (en) Moving image coding apparatus, moving image coding method, and computer program for moving image coding

Legal Events

Date Code Title Description
RD03 Notification of appointment of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7423

Effective date: 20181026

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20190422

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20200317

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20200327

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20200520

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20201020

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20201116

R150 Certificate of patent or registration of utility model

Ref document number: 6796405

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250