JP6362370B2 - Image encoding device, image decoding device, image encoding method, and image decoding method - Google Patents

Image encoding device, image decoding device, image encoding method, and image decoding method Download PDF

Info

Publication number
JP6362370B2
JP6362370B2 JP2014052219A JP2014052219A JP6362370B2 JP 6362370 B2 JP6362370 B2 JP 6362370B2 JP 2014052219 A JP2014052219 A JP 2014052219A JP 2014052219 A JP2014052219 A JP 2014052219A JP 6362370 B2 JP6362370 B2 JP 6362370B2
Authority
JP
Japan
Prior art keywords
prediction
block
signal
image
inter
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.)
Active
Application number
JP2014052219A
Other languages
Japanese (ja)
Other versions
JP2015177343A (en
Inventor
彰 峯澤
彰 峯澤
関口 俊一
俊一 関口
守屋 芳美
芳美 守屋
亮史 服部
亮史 服部
一之 宮澤
一之 宮澤
村上 篤道
篤道 村上
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.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric 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 Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Priority to JP2014052219A priority Critical patent/JP6362370B2/en
Publication of JP2015177343A publication Critical patent/JP2015177343A/en
Application granted granted Critical
Publication of JP6362370B2 publication Critical patent/JP6362370B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

この発明は、画像を高効率で符号化を行う画像符号化装置及び画像符号化方法と、高効率で符号化されている画像を復号する画像復号装置及び画像復号方法に関するものである。   The present invention relates to an image encoding device and an image encoding method for encoding an image with high efficiency, and an image decoding device and an image decoding method for decoding an image encoded with high efficiency.

例えば、以下の非特許文献1に記載されている画像符号化装置では、入力されたカラー画像を所定の大きさの最大符号化ブロックに分割し、さらに、最大符号化ブロックをより細かい符号化ブロックに階層分割する。
また、その符号化ブロックをさらに細かい予測ブロック(予測処理単位のブロック)に分割し、その予測ブロックに対する画面内予測や動き補償予測を実施することで予測画像(予測誤差)を生成する。
また、その予測画像を符号化ブロック内で階層的に変換ブロックに分割し、それぞれの変換ブロックの変換係数をエントロピー符号化することで高い圧縮率を達成している。
For example, in the image encoding device described in Non-Patent Document 1 below, an input color image is divided into maximum encoding blocks of a predetermined size, and the maximum encoding block is further divided into finer encoding blocks. Divide into hierarchies.
In addition, the encoded block is divided into finer prediction blocks (blocks of prediction processing units), and prediction images (prediction errors) are generated by performing intra prediction and motion compensation prediction on the prediction blocks.
Further, the prediction image is hierarchically divided into transform blocks in the coding block, and the transform coefficient of each transform block is entropy coded to achieve a high compression rate.

非特許文献1では、画面内の符号化済み画素を用いる予測としてイントラ予測を用いている。
このイントラ予測には、予測ブロックに隣接している画素を参照画素として、一定の方向にコピーする方向性予測、予測ブロック内の画素の予測値を参照画素の平均値とする平均値(DC)予測や、参照画素から予測ブロック内を内挿する平面(Planar)予測がある。
画像信号は一般に空間的相関が高いため、隣接する画素を用いた様々なバリエーションの予測を適切に切り替えることで高い予測効率を実現することができる。
In Non-Patent Document 1, intra prediction is used as prediction using encoded pixels in a screen.
In this intra prediction, a pixel adjacent to a prediction block is used as a reference pixel, directional prediction is copied in a certain direction, and an average value (DC) in which a prediction value of a pixel in the prediction block is an average value of reference pixels. There are prediction and planar prediction in which a prediction block is interpolated from a reference pixel.
Since image signals generally have high spatial correlation, high prediction efficiency can be realized by appropriately switching prediction of various variations using adjacent pixels.

B.Bross,W.-J. Han,J.-R. Ohm,G. J. Sullivan,Y.-K. Wang and T. Wiegand,“High Efficiency Video Coding(HEVC)text specification draft 10(for FDIS & Consent)”,doc. JCTVC-L1003,Joint Collaborative Team on Video Coding(JCT-VC)of ITU-T SG16 WP3 and ISO/IEC JTC1/SC29/WG11,12th Meeting,2013B. Bross, W.-J. Han, J.-R. Ohm, GJ Sullivan, Y.-K. Wang and T. Wiegand, “High Efficiency Video Coding (HEVC) text specification draft 10 (for FDIS & Consent)”, doc. JCTVC-L1003, Joint Collaborative Team on Video Coding (JCT-VC) of ITU-T SG16 WP3 and ISO / IEC JTC1 / SC29 / WG11, 12th Meeting, 2013

従来の画像符号化装置は以上のように構成されているので、予測ブロックに対するイントラ予測を適正に選択することができれば、予測精度を高めて、高い符号化効率を実現することができる。しかし、予測ブロック内の絵柄が、例えば、特定の非直線な模様や文字である場合など、予測ブロック内の絵柄によっては、予め用意されているどのイントラ予測を選択しても、精度良く予測できない場合がある。このような場合には、予測精度が低下して、高い符号化効率を実現することができない課題があった。   Since the conventional image coding apparatus is configured as described above, if the intra prediction for the prediction block can be appropriately selected, the prediction accuracy can be improved and high coding efficiency can be realized. However, depending on the pattern in the prediction block, for example, when the pattern in the prediction block is a specific non-linear pattern or character, it cannot be predicted accurately even if any intra prediction prepared in advance is selected. There is a case. In such a case, there is a problem that prediction accuracy is lowered and high encoding efficiency cannot be realized.

この発明は上記のような課題を解決するためになされたもので、予測ブロック内の絵柄が特定の非直線な模様や文字などであっても、予測精度を高めて、高い符号化効率を実現することができる画像符号化装置及び画像符号化方法を得ることを目的とする。
また、この発明は、上記のような画像符号化装置及び画像符号化方法により生成された符号化ビットストリームを正しく復号することができる画像復号装置及び画像復号方法を得ることを目的とする。
The present invention has been made to solve the above-described problems. Even when the pattern in the prediction block is a specific non-linear pattern or character, the prediction accuracy is improved and high encoding efficiency is realized. An object of the present invention is to obtain an image encoding device and an image encoding method that can be used.
Another object of the present invention is to provide an image decoding apparatus and an image decoding method that can correctly decode an encoded bitstream generated by the image encoding apparatus and the image encoding method described above.

この発明に係る画像符号化装置は、予測処理単位のブロックである予測ブロック毎に、当該予測ブロックにおける輝度信号のイントラ予測パラメータを用いて、その輝度信号の予測画像を生成するイントラ予測処理を実施するイントラ予測手段と、ブロックシフトベクトルを生成するイントラブロックコピー予測パラメータを可変長符号化する可変長符号化手段とを備え、そのイントラ予測手段が、当該予測ブロックの色差信号に対するフラグが色信号間予測処理の非実施を明示していれば、輝度信号と同一の色差信号のイントラ予測パラメータを用いて、その色差信号の予測画像を生成するイントラ予測処理を実施し、上記フラグが色信号間予測処理の実施を明示していれば、符号化済みの色差信号を参照して、当該予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施するようにしたものである。 The image encoding device according to the present invention performs intra prediction processing for generating a prediction image of a luminance signal for each prediction block, which is a block of a prediction processing unit, using an intra prediction parameter of the luminance signal in the prediction block. And an intra-block copy prediction parameter for generating a block shift vector. The intra-prediction unit includes a flag for the color difference signal of the prediction block between color signals. If the non-execution of the prediction process is clearly indicated, the intra prediction process for generating a prediction image of the color difference signal is performed using the intra prediction parameter of the same color difference signal as the luminance signal, and the flag is used for the inter-color signal prediction. if explicit implementation of a process, with reference to the color difference signals encoded, in the prediction block The prediction processing between the color signal to generate a prediction image of the difference signal is obtained so as to implement.

この発明によれば、イントラ予測手段が、当該予測ブロックの色差信号に対するフラグが色信号間予測処理の非実施を明示していれば、輝度信号と同一の色差信号のイントラ予測パラメータを用いて、その色差信号の予測画像を生成するイントラ予測処理を実施し、上記フラグが色信号間予測処理の実施を明示していれば、符号化済みの色差信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施するように構成したので、予測ブロック内の絵柄が特定の非直線な模様や文字などであっても、予測精度を高めて、高い符号化効率を実現することができる効果がある。 According to this invention, if the flag for the color difference signal of the prediction block clearly indicates that the inter-color signal prediction process is not performed, the intra prediction unit uses the intra prediction parameter of the same color difference signal as the luminance signal, If intra prediction processing for generating a prediction image of the color difference signal is performed and the flag clearly indicates the execution of inter-color signal prediction processing, the encoded color difference signal is referred to and the color difference signal in the prediction block is referred to. Since it is configured to perform inter-color signal prediction processing that generates a prediction image, even if the pattern in the prediction block is a specific non-linear pattern or character, the prediction accuracy is improved and high coding efficiency is achieved. There is an effect that can be realized.

この発明の実施の形態1による画像符号化装置を示す構成図である。It is a block diagram which shows the image coding apparatus by Embodiment 1 of this invention. この発明の実施の形態1による画像符号化装置の処理内容(画像符号化方法)を示すフローチャートである。It is a flowchart which shows the processing content (image coding method) of the image coding apparatus by Embodiment 1 of this invention. この発明の実施の形態1による画像復号装置を示す構成図である。It is a block diagram which shows the image decoding apparatus by Embodiment 1 of this invention. この発明の実施の形態1による画像復号装置の処理内容(画像復号方法)を示すフローチャートである。It is a flowchart which shows the processing content (image decoding method) of the image decoding apparatus by Embodiment 1 of this invention. 最大符号化ブロックが階層的に複数の符号化ブロックに分割される例を示す説明図である。It is explanatory drawing which shows the example by which the largest encoding block is divided | segmented into a some encoding block hierarchically. (a)は分割後の符号化ブロック及び予測ブロックの分布を示し、(b)は階層分割によって符号化モードm(B)が割り当てられる状況を示す説明図である。(A) shows the distribution of the encoding block and prediction block after a division | segmentation, (b) is explanatory drawing which shows the condition where encoding mode m ( Bn ) is allocated by hierarchy division | segmentation. 符号化ブロックB内の各予測ブロックP が選択可能なイントラ予測モードの一例を示す説明図である。Each prediction block P i n the coded block B n is an explanatory diagram showing an example of a selectable intra prediction modes. =m =4の場合の予測画像生成ブロック内の画素の予測値を生成する際に用いる画素の一例を示す説明図である。It is explanatory drawing which shows an example of the pixel used when producing | generating the predicted value of the pixel in the prediction image production | generation block in the case of l i n = m i n = 4. 予測画像生成ブロック内の左上画素を原点とする相対座標を示す説明図である。It is explanatory drawing which shows the relative coordinate which makes the upper left pixel in a prediction image generation block the origin. 量子化マトリクスの一例を示す説明図である。It is explanatory drawing which shows an example of a quantization matrix. この発明の実施の形態1による画像符号化装置のループフィルタ部で複数のループフィルタ処理を用いる場合の構成例を示す説明図である。It is explanatory drawing which shows the structural example in the case of using a several loop filter process in the loop filter part of the image coding apparatus by Embodiment 1 of this invention. この発明の実施の形態1による画像復号装置のループフィルタ部で複数のループフィルタ処理を用いる場合の構成例を示す説明図である。It is explanatory drawing which shows the structural example in the case of using a several loop filter process in the loop filter part of the image decoding apparatus by Embodiment 1 of this invention. 符号化ビットストリームの一例を示す説明図である。It is explanatory drawing which shows an example of an encoding bit stream. 画素適応オフセット処理のクラス分類手法のインデックスを示す説明図である。It is explanatory drawing which shows the index of the class classification method of a pixel adaptive offset process. 16×16画素のサイズの直交変換における変換係数の符号化順を示す説明図である。It is explanatory drawing which shows the encoding order of the conversion factor in the orthogonal transformation of the size of 16x16 pixels. 16×16画素のサイズの直交変換における変換係数の分布の一例を示す説明図である。It is explanatory drawing which shows an example of distribution of the transformation coefficient in the orthogonal transformation of the size of 16x16 pixels. 平均値予測時のフィルタ処理におけるフィルタの切り替え領域を示す説明図である。It is explanatory drawing which shows the switching area | region of the filter in the filter process at the time of average value prediction. 平均値予測時のフィルタ処理の参照画素配置を示す説明図である。It is explanatory drawing which shows the reference pixel arrangement | positioning of the filter process at the time of average value prediction. 4×4画素と8×8画素のサイズの直交変換における変換係数の符号化順の一例を示す説明図である。It is explanatory drawing which shows an example of the encoding order of the transform coefficient in the orthogonal transformation of the size of 4x4 pixel and 8x8 pixel. YUV4:2:0フォーマットの信号における輝度信号及び色差信号の圧縮処理を実施する際の変換ブロックサイズを示す説明図である。It is explanatory drawing which shows the conversion block size at the time of implementing the compression process of the luminance signal and color-difference signal in the signal of YUV4: 2: 0 format. YUV4:2:2フォーマットの信号における輝度信号及び色差信号の圧縮処理を実施する際の変換ブロックサイズを示す説明図である。It is explanatory drawing which shows the conversion block size at the time of implementing the compression process of the luminance signal and color difference signal in the signal of YUV4: 2: 2 format. YUV4:4:4フォーマットの信号における輝度信号及び色差信号の圧縮処理を実施する際の変換ブロックサイズを示す説明図である。It is explanatory drawing which shows the conversion block size at the time of implementing the compression process of the luminance signal and color difference signal in the signal of YUV4: 4: 4 format. 色差信号のイントラ予測パラメータと色差イントラ予測モードの対応例を示す説明図である。It is explanatory drawing which shows the example of a response | compatibility of the intra prediction parameter of a color difference signal, and a color difference intra prediction mode. YUV4:2:0フォーマットの信号において輝度信号と色差信号で同一の方向性予測を用いた場合を示す説明図である。It is explanatory drawing which shows the case where the same directionality prediction is used with a luminance signal and a color difference signal in the signal of YUV4: 2: 0 format. YUV4:2:2フォーマットの信号において輝度信号と色差信号で同一の方向性予測を用いた場合を示す説明図である。It is explanatory drawing which shows the case where the same directionality prediction is used with a luminance signal and a color difference signal in the signal of YUV4: 2: 2 format. YUV4:4:4フォーマットとYUV4:2:2フォーマットの関係を示す説明図である。It is explanatory drawing which shows the relationship between YUV4: 4: 4 format and YUV4: 2: 2 format. YUV4:4:4フォーマットの信号において輝度信号と色差信号で同一の方向性予測を用いることと等価となるYUV4:2:2フォーマットでの方向性予測の例を示す説明図である。It is explanatory drawing which shows the example of the directionality prediction in YUV4: 2: 2 format equivalent to using the same directionality prediction with a luminance signal and a color difference signal in the signal of YUV4: 4: 4 format. YUV4:2:2フォーマットの信号での方向性予測の予測方向ベクトルを示す説明図である。It is explanatory drawing which shows the prediction direction vector of directionality prediction with the signal of YUV4: 2: 2 format. 方向性予測と角度の関係を示す説明図である。It is explanatory drawing which shows the relationship between directionality prediction and an angle. YUV4:2:2フォーマットの信号において輝度信号のイントラ予測モードインデックスと色差信号のイントラ予測モードインデックスの関係を示す説明図である。It is explanatory drawing which shows the relationship between the intra prediction mode index of a luminance signal, and the intra prediction mode index of a color difference signal in the signal of YUV4: 2: 2 format. イントラ予測モードインデックスとtanθの関係を示す説明図である。It is explanatory drawing which shows the relationship between an intra prediction mode index and tan (theta). イントラブロックコピーの一例を示す説明図である。It is explanatory drawing which shows an example of an intra block copy. イントラブロックコピーにおいて未符号化領域の画素に特定の画素値を埋めた場合の効果を示す説明図である。It is explanatory drawing which shows the effect at the time of embedding a specific pixel value in the pixel of an unencoded area | region in intra block copy. イントラブロックコピーにおける画素埋め処理の一例を示す説明図である。It is explanatory drawing which shows an example of the pixel pad process in an intra block copy. イントラブロックコピーにおける画素埋め処理に用いるMove−To−Front法の説明図である。It is explanatory drawing of the Move-To-Front method used for the pixel pad process in an intra block copy. イントラブロックコピーにおける画素埋め処理として実施する水平方向又は垂直方向のフィルタ処理の参照画素の一例を示す説明図である。It is explanatory drawing which shows an example of the reference pixel of the filter process of the horizontal direction or the vertical direction implemented as a pixel filling process in an intra block copy. イントラブロックコピーにおける参照ブロックの一例を示す説明図である。It is explanatory drawing which shows an example of the reference block in intra block copy. イントラブロックコピーにおける画素埋め処理として実施するL字型のフィルタ処理の説明図である。It is explanatory drawing of the L-shaped filter process implemented as a pixel pad process in an intra block copy. イントラブロックコピーにおける画素埋め処理として実施する水平方向フィルタ処理に対して参照画素を拡張した場合の一例を示す説明図である。It is explanatory drawing which shows an example at the time of expanding a reference pixel with respect to the horizontal direction filter process implemented as a pixel pad process in an intra block copy. イントラブロックコピーにおける画素埋め処理として実施する垂直方向フィルタ処理に対して参照画素を拡張した場合の一例を示す説明図である。It is explanatory drawing which shows an example at the time of extending a reference pixel with respect to the vertical direction filter process implemented as a pixel pad process in an intra block copy. イントラブロックコピーにおける画素埋め処理として実施するL字型のフィルタ処理に対して参照画素を拡張した場合の説明図である。It is explanatory drawing at the time of extending a reference pixel with respect to the L-shaped filter process implemented as a pixel pad process in an intra block copy. イントラブロックコピー予測処理において、ブロックシフトベクトルが指し示す参照ブロックが、予測対象符号化ブロック内の未符号化領域を含む例を示す説明図である。In an intra block copy prediction process, it is explanatory drawing which shows the example in which the reference block which a block shift vector points out includes the uncoded area | region in a prediction object encoding block. イントラブロックコピー予測処理において、未符号化領域の画素を埋める画素値を求める処理の処理手順の例を示すフローチャートである。It is a flowchart which shows the example of the process sequence of the process which calculates | requires the pixel value which fills the pixel of an unencoded area | region in an intra block copy prediction process. 図43のフローチャートにおける「Lmax判定及びSmax更新」処理の処理手順の例を示すフローチャートである。 44 is a flowchart illustrating an example of a processing procedure of “L max determination and S max update” processing in the flowchart of FIG. 43. 入力信号フォーマットがYUV4:4:4フォーマットの信号での色信号間予測の例を示す説明図である。It is explanatory drawing which shows the example of the prediction between color signals in the signal whose input signal format is YUV4: 4: 4 format. 予測画像生成対象ブロックが8×8画素の場合の色信号間予測の相関パラメータを算出する際に参照する画素位置の例を示す説明図である。It is explanatory drawing which shows the example of the pixel position referred when calculating the correlation parameter of the prediction between color signals in case a prediction image production | generation target block is 8x8 pixel. 符号化ブロックが8×8画素において、予測画像生成対象ブロックが予測ブロックである場合の色信号間予測の相関パラメータを算出する際に参照する画素位置の例を示す説明図である。It is explanatory drawing which shows the example of the pixel position referred when calculating the correlation parameter of the prediction between color signals in case an encoding block is 8x8 pixel and a prediction image generation target block is a prediction block. 色信号間予測を含めた色差信号のイントラ予測パラメータの例を示す説明図である。It is explanatory drawing which shows the example of the intra prediction parameter of the color difference signal including the prediction between color signals.

実施の形態1.
図1はこの発明の実施の形態1による画像符号化装置を示す構成図である。
この実施の形態1の画像符号化装置が処理対象とする映像信号は、輝度信号と2つの色差信号からなるYUV信号や、ディジタル撮像素子から出力されるRGB信号等の任意の色空間のカラー映像信号のほか、モノクロ画像信号や赤外線画像信号など、映像フレームが水平・垂直2次元のディジタルサンプル(画素)列から構成される任意の映像信号である。
各画素の階調は8ビットでもよいし、10ビット、12ビットなどの階調であってもよい。
また、入力信号は映像信号ではなく静止画像信号でもよいことは、静止画像信号を1フレームのみで構成される映像信号と解釈できることから当然である。
Embodiment 1 FIG.
FIG. 1 is a block diagram showing an image coding apparatus according to Embodiment 1 of the present invention.
The video signal to be processed by the image coding apparatus according to the first embodiment is a color video in an arbitrary color space such as a YUV signal composed of a luminance signal and two color difference signals, or an RGB signal output from a digital image sensor. In addition to signals, the video frame is an arbitrary video signal such as a monochrome image signal or an infrared image signal, in which a video frame is composed of a horizontal / vertical two-dimensional digital sample (pixel) sequence.
The gradation of each pixel may be 8 bits, or a gradation of 10 bits, 12 bits, or the like.
Further, it is natural that the input signal may be a still image signal instead of a video signal because the still image signal can be interpreted as a video signal composed of only one frame.

以下の説明においては、便宜上、特に断らない限り、入力される映像信号が、2つの色差成分U,Vが輝度成分Yに対して、縦横ともに2分の1にサブサンプルされたYUV4:2:0フォーマット、2つの色差成分U,Vが輝度成分Yに対して、横方向に2分の1にサブサンプルされたYUV4:2:2フォーマット、あるいは、2つの色差成分U,Vが輝度成分Yと同じサンプル数であるYUV4:4:4フォーマットの信号であるものとする。また、赤色(R)、緑色(G)、青色(B)の三原色の信号からなるRGB4:4:4フォーマットの色信号については、それぞれの色信号をYUV4:4:4フォーマットの色信号とみなしてYUV4:4:4フォーマットと同一の符号化を行う。ただし、RGB4:4:4フォーマットの各色信号(RGB)のYUV4:4:4フォーマットの各色信号(YUV)への対応付けについては限定しない(任意に設定できる)。
この対応付けはインデックス情報として上位ヘッダで符号化して画像復号装置側で認識できるようにしてもよい。このようにすることで、画像復号装置によって復号した復号画像の色を復号された符号化データのみから認識することができ、正しく表示することができる。また、YUV4:4:4フォーマット信号やRGB4:4:4フォーマット信号の場合、各色信号をモノクローム画像信号とみなしてそれぞれ独立にモノクローム(YUV4:0:0)符号化してビットストリームを生成するようにしてもよい。
このようにすることで各信号並列に符号化処理を実施することができる。その際、各モノクローム信号がどの色信号であるかを示す情報をインデックス情報として上位ヘッダで符号化して画像復号装置側で認識できるようにしてもよい。このようにすることで、画像復号装置によって復号した復号画像の色を正しく表示することができる。
なお、上記では4:4:4フォーマット信号の各色信号をモノクローム画像信号とみなしてそれぞれ独立にモノクローム(YUV4:0:0)符号化する場合について説明したが、実際にモノクローム画像信号を対象としてモノクローム符号化することも当然可能である。
また、上記ではYUV信号フォーマットやRGB信号フォーマットの場合について説明したが、その他の色信号のフォーマット(YCbCrや、XYZ等)においても同様に4:2:0、4:2:2、4:4:4フォーマットのいずれかであれば、YUVフォーマットと同様に符号化できる。ただし、対象とするフォーマットの各色信号がYUVフォーマットにおいていずれの色信号に対応するかについては限定しない(任意に設定できる)。もちろん、RGBフォーマットの場合について上記で説明したように、色信号の対応付けはインデックス情報として上位ヘッダで符号化して画像復号装置側で認識できるようにしてもよい。
なお、映像の各フレームに対応する処理データ単位を「ピクチャ」と称し、この実施の形態1では、「ピクチャ」は順次走査(プログレッシブスキャン)された映像フレームの信号として説明を行う。ただし、映像信号がインタレース信号である場合、「ピクチャ」は映像フレームを構成する単位であるフィールド画像信号であってもよい。
In the following description, for convenience, unless otherwise specified, the input video signal is YUV4: 2 in which the two color difference components U and V are subsampled in half both vertically and horizontally with respect to the luminance component Y: 0 format, YUV4: 2: 2 format in which two color difference components U and V are subsampled in half in the horizontal direction with respect to luminance component Y, or two color difference components U and V are luminance component Y And YUV 4: 4: 4 format signal having the same number of samples. In addition, regarding RGB 4: 4: 4 format color signals composed of signals of the three primary colors of red (R), green (G), and blue (B), each color signal is regarded as a color signal of YUV 4: 4: 4 format. The same encoding as in the YUV 4: 4: 4 format is performed. However, associating each color signal (RGB) of RGB 4: 4: 4 format with each color signal (YUV) of YUV 4: 4: 4 format is not limited (can be arbitrarily set).
This association may be encoded as an index information with a high-order header so that the image decoding apparatus can recognize it. In this way, the color of the decoded image decoded by the image decoding device can be recognized only from the decoded encoded data, and can be displayed correctly. In the case of a YUV 4: 4: 4 format signal or an RGB 4: 4: 4 format signal, each color signal is regarded as a monochrome image signal and is independently encoded in monochrome (YUV4: 0: 0) to generate a bitstream. May be.
In this way, encoding processing can be performed in parallel with each signal. At this time, information indicating which color signal each monochrome signal is may be encoded as index information in the upper header so that the image decoding apparatus can recognize it. By doing in this way, the color of the decoded image decoded by the image decoding apparatus can be correctly displayed.
In the above description, a case has been described in which each color signal of the 4: 4: 4 format signal is regarded as a monochrome image signal and is independently encoded in monochrome (YUV4: 0: 0). However, the monochrome image is actually targeted for the monochrome image signal. It is of course possible to encode.
In the above description, the YUV signal format and the RGB signal format have been described. However, other color signal formats (YCbCr, XYZ, etc.) are similarly 4: 2: 0, 4: 2: 2, 4: 4. : Any of the four formats can be encoded in the same manner as the YUV format. However, it is not limited (which can be arbitrarily set) which color signal in the target format corresponds to which color signal in the YUV format. Of course, as described above in the case of the RGB format, the color signal association may be encoded as index information in the upper header so that the image decoding apparatus can recognize it.
The processing data unit corresponding to each frame of the video is referred to as “picture”. In the first embodiment, “picture” is described as a signal of a video frame that has been sequentially scanned (progressive scan). However, when the video signal is an interlace signal, the “picture” may be a field image signal which is a unit constituting a video frame.

図1において、符号化制御部1は符号化処理が実施される際の処理単位となる符号化ブロックの最大サイズを決定するとともに、最大サイズの符号化ブロックが階層的に分割される際の上限の階層数を決定することで、各々の符号化ブロックのサイズを決定する処理を実施する。
また、符号化制御部1は選択可能な1以上の符号化モード(予測処理単位を示す予測ブロックのサイズなどが異なる1以上のイントラ符号化モード、予測処理単位を示す予測ブロックのサイズなどが異なる1以上のイントラブロックコピー符号化モード、予測ブロックのサイズなどが異なる1以上のインター符号化モード)の中から、ブロック分割部3から出力される符号化ブロックに適用する符号化モードを選択する処理を実施する。
選択手法の例としては、選択可能な1以上の符号化モードの中から、ブロック分割部3から出力される符号化ブロックに対する符号化効率が最も高い符号化モードを選択する手法がある。
In FIG. 1, the encoding control unit 1 determines the maximum size of an encoding block that is a processing unit when the encoding process is performed, and the upper limit when the encoding block of the maximum size is hierarchically divided. By determining the number of layers, the process of determining the size of each encoded block is performed.
The encoding control unit 1 also has one or more selectable encoding modes (one or more intra encoding modes having different prediction block sizes indicating prediction processing units, etc., and different prediction block sizes indicating prediction processing units). Processing for selecting a coding mode to be applied to a coding block output from the block division unit 3 from one or more intra block copy coding modes and one or more inter coding modes having different prediction block sizes. To implement.
As an example of the selection method, there is a method of selecting a coding mode having the highest coding efficiency for the coding block output from the block dividing unit 3 from one or more selectable coding modes.

また、符号化制御部1は符号化効率が最も高い符号化モードがイントラ符号化モードである場合、そのイントラ符号化モードで符号化ブロックに対するイントラ予測処理を実施する際に用いるイントラ予測パラメータを上記イントラ符号化モードが示す予測処理単位である予測ブロック毎に決定し、符号化効率が最も高い符号化モードがイントラブロックコピー符号化モードである場合、そのイントラブロックコピー符号化モードで符号化ブロックに対するイントラブロックコピー予測処理を実施する際に用いるイントラブロックコピー予測パラメータを上記イントラブロックコピー符号化モードが示す予測処理単位である予測ブロック毎に決定し、符号化効率が最も高い符号化モードがインター符号化モードである場合、そのインター符号化モードで符号化ブロックに対する動き補償予測処理を実施する際に用いるインター予測パラメータを上記インター符号化モードが示す予測処理単位である予測ブロック毎に決定する処理を実施する。
なお、符号化制御部1は、色差信号については、予測ブロックに対して、イントラ予測処理、イントラブロックコピー予測処理、動き補償予測処理よりも、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する色信号間予測処理を実施する方が符号化効率が高くなるような場合、ブロック分割部3から出力される符号化ブロックに適用する符号化モード(イントラ符号化モード、イントラブロックコピー符号化モード、インター符号化モード)にかかわらず、予測処理として色信号間予測を実施するように、当該符号化ブロックに関わる後述する色信号間予測フラグをONに設定する。
また、色信号間予測処理を実施するか否かの選択単位を符号化ブロック単位として、色信号間予測処理を実施する符号化モードとして色信号間予測モードを定義するようにしてもよい。このようにすることで、予測ブロック単位に色信号間予測フラグを設定する場合より、色信号間予測の選択に関する情報の符号量を削減することができる。
In addition, when the coding mode with the highest coding efficiency is the intra coding mode, the coding control unit 1 sets the intra prediction parameters used when performing the intra prediction process on the coding block in the intra coding mode. It is determined for each prediction block that is a prediction processing unit indicated by the intra coding mode, and when the coding mode having the highest coding efficiency is the intra block copy coding mode, the intra block copy coding mode is used for the coding block. An intra block copy prediction parameter used when performing the intra block copy prediction process is determined for each prediction block which is a prediction processing unit indicated by the intra block copy coding mode, and the coding mode having the highest coding efficiency is an inter code. The inter code The inter prediction parameters used in practicing the motion compensation prediction process on the coded blocks to implement the process of determining for each prediction block is a prediction processing unit indicated by the inter coding mode in the mode.
Note that, for the color difference signal, the encoding control unit 1 refers to the encoded color signal with respect to the prediction block, rather than the intra prediction process, the intra block copy prediction process, and the motion compensation prediction process. In the case where the encoding efficiency is higher when the inter-color-signal prediction process for performing the inter-color-signal prediction process for generating the predicted image of the color difference signal is applied to the encoded block output from the block dividing unit 3 Regardless of the encoding mode (intra encoding mode, intra block copy encoding mode, inter encoding mode) to be performed, the inter-color signal between the encoding blocks to be described later is performed so that inter-color signal prediction is performed as a prediction process. Set the prediction flag to ON.
Further, the inter-color-signal prediction mode may be defined as an encoding mode for executing the inter-color-signal prediction process, with the selection unit for determining whether or not the inter-color-signal prediction process is performed as an encoding block unit. By doing in this way, the code amount of the information regarding the selection of the prediction between color signals can be reduced rather than the case where the prediction signal between color signals is set per prediction block.

さらに、符号化制御部1は変換・量子化部9及び逆量子化・逆変換部10に与える予測差分符号化パラメータを決定する処理を実施する。予測差分符号化パラメータには、符号化ブロックにおける直交変換処理単位となる変換ブロックの分割情報を示す変換ブロック分割情報や、変換係数の量子化を行う際の量子化ステップサイズを規定する量子化パラメータなどが含まれる。   Furthermore, the encoding control unit 1 performs a process of determining a prediction difference encoding parameter to be given to the transform / quantization unit 9 and the inverse quantization / inverse transform unit 10. The prediction difference coding parameter includes transform block partition information indicating transform block partition information that is a unit of orthogonal transform processing in the coded block, and a quantization parameter that specifies a quantization step size when transform coefficients are quantized. Etc. are included.

ここで、図20はYUV4:2:0フォーマットの信号における輝度信号及び色差信号の圧縮処理(変換処理、量子化処理)を実施する際の変換ブロックサイズを示す説明図である。
変換ブロックサイズは、図20に示すように、符号化ブロックを四分木状に階層分割することによって決定される。
例えば、変換ブロックを分割する場合と変換ブロックを分割しない場合での符号量や、符号化誤差を加味した評価尺度などに基づいて、評価値が最小になるように変換ブロックを分割するか否かを決定することで、符号量と符号化誤差のトレードオフの観点から最適な変換ブロックの分割形状を決定することができる。
Here, FIG. 20 is an explanatory diagram showing a conversion block size when performing compression processing (conversion processing and quantization processing) of a luminance signal and a color difference signal in a YUV 4: 2: 0 format signal.
As shown in FIG. 20, the transform block size is determined by hierarchically dividing the encoded block into a quadtree.
For example, whether or not to divide the transform block so that the evaluation value is minimized based on the amount of code when the transform block is divided and when the transform block is not divided, the evaluation scale that takes into account the coding error, etc. By determining, it is possible to determine the optimal division shape of the transform block from the viewpoint of the trade-off between the code amount and the coding error.

輝度信号については、例えば、図20に示すように、符号化ブロックが1つ又は複数の正方形の変換ブロックに階層的に分割されるように構成する。
色差信号については、図20に示すように、入力信号フォーマットがYUV4:2:0信号である場合、輝度信号と同様に、符号化ブロックが1つ又は複数の正方形の変換ブロックに階層的に分割されるように構成する。
この場合、色差信号の変換ブロックサイズは、対応する輝度信号の変換ブロックの縦横ともに半分のサイズとなる。
For example, as shown in FIG. 20, the luminance signal is configured so that the coding block is hierarchically divided into one or a plurality of square transform blocks.
For the color difference signal, as shown in FIG. 20, when the input signal format is a YUV 4: 2: 0 signal, the encoding block is hierarchically divided into one or a plurality of square transform blocks in the same manner as the luminance signal. To be configured.
In this case, the conversion block size of the color difference signal is half the vertical and horizontal sizes of the corresponding luminance signal conversion block.

入力信号フォーマットがYUV4:2:2信号である場合、図21に示すように、輝度信号と同様の四分木状の階層分割を行う。また、分割したブロックの形状が、垂直方向の画素数が水平方向の画素数の2倍になる長方形となるため、さらに、分割したブロックを上下に二分することで、YUV4:2:0信号での色差信号と同じブロックサイズ(輝度信号の変換ブロックの縦横ともに半分のサイズ)の変換ブロック2つで構成するようにする。   When the input signal format is a YUV 4: 2: 2 signal, quadtree-like hierarchical division similar to the luminance signal is performed as shown in FIG. Further, since the shape of the divided block is a rectangle in which the number of pixels in the vertical direction is twice the number of pixels in the horizontal direction, the divided block is further divided into two parts in the vertical direction, so that the YUV 4: 2: 0 signal The color difference signal is composed of two conversion blocks having the same block size (half the vertical and horizontal sizes of the luminance signal conversion block).

また、入力信号フォーマットがYUV4:4:4信号である場合、図22に示すように、色差信号の変換ブロックは、常に輝度信号の変換ブロックと同様の分割を行い、同じサイズの変換ブロックとなるように構成する。
輝度信号の変換ブロックの分割情報は、例えば、階層毎に分割するか否かを示す変換ブロック分割フラグとして可変長符号化部15に出力する。
Further, when the input signal format is YUV 4: 4: 4 signal, as shown in FIG. 22, the color difference signal conversion block is always divided in the same manner as the luminance signal conversion block to be the same size conversion block. Configure as follows.
The division information of the conversion block of the luminance signal is output to the variable length encoding unit 15 as a conversion block division flag indicating whether or not to divide for each layer, for example.

スライス分割部2は入力画像として映像信号を入力すると、その入力画像を符号化制御部1により決定されたスライス分割情報にしたがって1以上の“スライス”という部分画像に分割する処理を実施する。スライスの分割単位は、上述した符号化ブロック単位まで細かくすることができる。   When a video signal is input as an input image, the slice division unit 2 performs a process of dividing the input image into one or more partial images called “slices” according to the slice division information determined by the encoding control unit 1. The slice division unit can be finely divided to the above-described coding block unit.

ブロック分割部3はスライス分割部2により分割されたスライスを入力する毎に、そのスライスを符号化制御部1により決定された最大サイズの符号化ブロックである最大符号化ブロックに分割するとともに、符号化制御部1により決定された上限の階層数に至るまで、その最大符号化ブロックを階層的に各符号化ブロックへ分割する処理を実施する。
即ち、ブロック分割部3はスライスを符号化制御部1により決定された分割に応じて各符号化ブロックに分割して、その符号化ブロックを出力する処理を実施する。また、各符号化ブロックは予測処理単位となる1つないし複数の予測ブロックに分割される。
Each time the block dividing unit 3 inputs the slice divided by the slice dividing unit 2, the slice dividing unit 3 divides the slice into maximum coding blocks that are coding blocks of the maximum size determined by the coding control unit 1, and Until the maximum number of hierarchies determined by the coding control unit 1 is reached, a process of dividing the maximum coding block hierarchically into each coding block is performed.
That is, the block division unit 3 divides the slice into each coding block according to the division determined by the coding control unit 1, and performs a process of outputting the coding block. Each coding block is divided into one or a plurality of prediction blocks which are prediction processing units.

切換スイッチ4は符号化制御部1により決定された符号化モードがイントラ符号化モードであれば、ブロック分割部3から出力された符号化ブロックをイントラ予測部5に出力し、符号化制御部1により決定された符号化モードがイントラブロックコピー符号化モードであれば、ブロック分割部3から出力された符号化ブロックをイントラブロックコピー予測部6に出力し、符号化制御部1により決定された符号化モードがインター符号化モードであれば、ブロック分割部3から出力された符号化ブロックを動き補償予測部7に出力する処理を実施する。   If the coding mode determined by the coding control unit 1 is the intra coding mode, the changeover switch 4 outputs the coded block output from the block dividing unit 3 to the intra prediction unit 5, and the coding control unit 1 If the coding mode determined by is the intra block copy coding mode, the coding block output from the block division unit 3 is output to the intra block copy prediction unit 6, and the code determined by the coding control unit 1 is output. If the encoding mode is the inter encoding mode, a process of outputting the encoded block output from the block dividing unit 3 to the motion compensation prediction unit 7 is performed.

イントラ予測部5は切換スイッチ4から出力された符号化ブロックに対応する符号化モードとして、符号化制御部1によりイントラ符号化モードが選択された場合、イントラ用メモリ12に格納されている局所復号画像を参照しながら、符号化制御部1により決定されたイントラ予測パラメータを用いたイントラ予測処理(フレーム内予測処理)を実施してイントラ予測画像を生成する処理を実施する。   When the intra control mode is selected by the encoding control unit 1 as the encoding mode corresponding to the encoded block output from the changeover switch 4, the intra prediction unit 5 performs local decoding stored in the intra memory 12. With reference to the image, an intra prediction process (intraframe prediction process) using the intra prediction parameter determined by the encoding control unit 1 is performed to generate an intra predicted image.

即ち、イントラ予測部5は、輝度信号については、輝度信号のイントラ予測パラメータを用いたイントラ予測処理(フレーム内予測処理)を実施して、輝度信号の予測画像を生成する。
一方、色差信号については、色差信号のイントラ予測パラメータが、輝度信号に対するイントラ予測モードと同じイントラ予測モードを用いる旨を示している場合(イントラ予測パラメータが輝度色差共通イントラ予測モード(DMモード)を示している場合)、輝度信号と同じフレーム内予測を実施して、色差信号の予測画像を生成する。
図24はYUV4:2:0フォーマットの信号において輝度信号と色差信号で同一の方向性予測を用いた場合を示し、図25はYUV4:2:2フォーマットの信号において輝度信号と色差信号で同一の方向性予測を用いた場合を示している。
また、色差信号のイントラ予測パラメータが、垂直方向予測モード又は水平方向予測モードを示している場合、色差信号に対する方向性予測を実施して、色差信号の予測画像を生成する。
That is, for the luminance signal, the intra prediction unit 5 performs an intra prediction process (intraframe prediction process) using an intra prediction parameter of the luminance signal, and generates a prediction image of the luminance signal.
On the other hand, for the color difference signal, when the intra prediction parameter of the color difference signal indicates that the same intra prediction mode as the intra prediction mode for the luminance signal is used (the intra prediction parameter indicates the luminance color difference common intra prediction mode (DM mode)). When it is shown), the same intra-frame prediction as the luminance signal is performed to generate a predicted image of the color difference signal.
FIG. 24 shows a case where the same directionality prediction is used for the luminance signal and the color difference signal in the YUV 4: 2: 0 format signal, and FIG. 25 shows the same luminance signal and color difference signal in the YUV 4: 2: 2 format signal. The case where directionality prediction is used is shown.
Further, when the intra prediction parameter of the color difference signal indicates the vertical direction prediction mode or the horizontal direction prediction mode, the directionality prediction for the color difference signal is performed to generate a prediction image of the color difference signal.

入力信号フォーマットがYUV4:2:2信号である場合、図26に示すように、輝度信号が正方ブロックであれば、色差信号は輝度信号と比較して水平方向の画素数が1/2となる長方形のブロックとなる。したがって、図27に示すように、YUV4:4:4信号をYUV4:2:2信号に変換した際に、輝度信号と色差信号で同一方向の予測となるようにするためには、YUV4:2:2信号上では、垂直方向予測と水平方向予測以外の方向性予測の場合には、色差信号の予測方向が輝度信号の予測方向と異なることとなる。
具体的には、図28に示すように、輝度信号の予測方向ベクトルをv=(dx,dy)とした場合、色差信号の予測方向ベクトルは、v=(dx/2,dy)となる。即ち、図29に示すように、予測方向の角度をθとした場合、輝度信号の予測方向の角度をθ、色差信号の予測方向の角度をθとして、tanθ=2tanθの関係となる予測方向で予測する必要がある。
When the input signal format is a YUV 4: 2: 2 signal, as shown in FIG. 26, if the luminance signal is a square block, the color difference signal has half the number of pixels in the horizontal direction compared to the luminance signal. It becomes a rectangular block. Therefore, as shown in FIG. 27, when a YUV4: 4: 4 signal is converted into a YUV4: 2: 2 signal, YUV4: 2 is used to predict the luminance signal and the color difference signal in the same direction. : On two signals, in the case of directional prediction other than the vertical prediction and the horizontal prediction, the prediction direction of the color difference signal is different from the prediction direction of the luminance signal.
Specifically, as illustrated in FIG. 28, when the prediction direction vector of the luminance signal is v L = (dx L , dy L ), the prediction direction vector of the color difference signal is v C = (dx L / 2, dy L ). That is, as shown in FIG. 29, assuming that the angle of the prediction direction is θ, the angle of the prediction direction of the luminance signal is θ L , the angle of the prediction direction of the color difference signal is θ C , and tan θ C = 2tan θ L It is necessary to predict in the prediction direction.

したがって、輝度信号と色差信号で同一方向の予測を行う上記DMモードを正しく実施できるようにするために、入力信号フォーマットがYUV4:2:2信号である場合、輝度信号に使用したイントラ予測モードのインデックスを色差信号の予測に用いるイントラ予測モードのインデックスに変換し、変換後のインデックスに対応するイントラ予測モードによる色差信号の予測処理を実施する。具体的には、インデックスの変換テーブルを用意し、その変換テーブルを参照することで、インデックスを変換するように構成してもよいし、予め変換式を用意して、その変換式に従ってインデックスを変換するように構成してもよい。
このように構成することで、方向性予測処理自体を変更することなく、インデックスの変換のみで、YUV4:2:2信号のフォーマットに応じた色差信号の適切な予測を実施することができる。
Therefore, when the input signal format is a YUV 4: 2: 2 signal in order to correctly implement the DM mode in which the prediction in the same direction is performed with the luminance signal and the color difference signal, the intra prediction mode used for the luminance signal is used. The index is converted into an intra prediction mode index used for prediction of the color difference signal, and the color difference signal prediction process is performed in the intra prediction mode corresponding to the converted index. Specifically, an index conversion table may be prepared, and the index may be converted by referring to the conversion table. Alternatively, a conversion formula is prepared in advance, and the index is converted according to the conversion formula. You may comprise.
With this configuration, it is possible to perform appropriate prediction of the color difference signal according to the format of the YUV 4: 2: 2 signal only by converting the index without changing the directionality prediction process itself.

イントラ予測部5は、輝度信号の予測画像の生成については常にイントラ予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、符号化制御部1により当該予測ブロックで色信号間予測を実施するか否かを示すフラグ(色信号間予測フラグ)が有効(ON)に設定されている場合、イントラ予測処理を実施せずに、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。なお、イントラ予測部5はイントラ予測手段を構成している。   The intra prediction unit 5 always performs an intra prediction process for the generation of a prediction image of a luminance signal, but for the generation of a prediction image of a color difference signal, the encoding control unit 1 performs the prediction block on each prediction block. When the flag indicating whether or not to perform inter-color signal prediction (inter-color signal prediction flag) is set to valid (ON), the encoded color signal is referred to without performing intra prediction processing. Then, the inter-color signal prediction process for generating the predicted image of the color difference signal in the prediction block is performed. The intra prediction unit 5 constitutes an intra prediction unit.

イントラブロックコピー予測部6は切換スイッチ4から出力された符号化ブロックに対応する符号化モードとして、符号化制御部1によりイントラブロックコピー符号化モードが選択された場合、その符号化ブロック内の予測ブロック(予測処理単位のブロック)が属している最大サイズの符号化ブロック(最大符号化ブロック)の中で、未だ局所復号が済んでいない領域内の各画素の画素値を所定の方法で仮定する処理を実施する。
また、イントラブロックコピー予測部6は符号化ブロック内の予測ブロック毎に、同一のピクチャ内で既に符号化が行われて局所復号が済んでいる領域の中から、当該予測ブロックと最も近似しているブロックである参照ブロックを探索して、その参照ブロックを当該予測ブロックの予測画像に決定する処理を実施する。
イントラブロックコピー予測部6は、輝度信号の予測画像の生成については常にイントラブロックコピー予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、符号化制御部1により当該予測ブロックの色信号間予測フラグがONに設定されている場合、イントラブロックコピー予測処理を実施せずに、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。なお、イントラブロックコピー予測部6はイントラブロックコピー予測手段を構成している。
When the intra block copy encoding mode is selected by the encoding control unit 1 as the encoding mode corresponding to the encoded block output from the changeover switch 4, the intra block copy predicting unit 6 predicts the encoded block. The pixel value of each pixel in an area that has not been subjected to local decoding is assumed in a predetermined method among the maximum size encoded block (maximum encoded block) to which the block (prediction processing unit block) belongs. Perform the process.
In addition, the intra block copy prediction unit 6 approximates the prediction block for each prediction block in the encoded block most closely to the prediction block from the regions that have already been encoded and locally decoded in the same picture. A process is performed for searching for a reference block that is an existing block and determining the reference block as a prediction image of the prediction block.
The intra block copy prediction unit 6 always performs the intra block copy prediction process for the generation of the prediction image of the luminance signal, but the encoding control unit 1 for each prediction block for the generation of the prediction image of the color difference signal. When the inter-color-signal prediction flag of the prediction block is set to ON by referring to the encoded color signal without performing the intra-block copy prediction process, the prediction image of the color difference signal in the prediction block is obtained. The prediction process between the color signals to be generated is performed. The intra block copy prediction unit 6 constitutes an intra block copy prediction unit.

動き補償予測部7は切換スイッチ4から出力された符号化ブロックに対応する符号化モードとして、符号化制御部1によりインター符号化モードが選択された場合、符号化ブロックと動き補償予測フレームメモリ14に格納されている1フレーム以上の局所復号画像を比較して動きベクトルを探索し、その動きベクトルと符号化制御部1により決定された参照するフレーム番号などのインター予測パラメータを用いて、その符号化ブロックに対するインター予測処理(動き補償予測処理)を実施してインター予測画像を生成する処理を実施する。
動き補償予測部7は、輝度信号の予測画像の生成については常に動き補償予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、符号化制御部1により当該予測ブロックの色信号間予測フラグがONに設定されている場合、動き補償予測処理を実施せずに、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。なお、動き補償予測部7は動き補償予測手段を構成している。
When the inter coding mode is selected by the coding control unit 1 as the coding mode corresponding to the coding block output from the changeover switch 4, the motion compensated prediction unit 7 and the motion compensated prediction frame memory 14 A motion vector is searched by comparing locally decoded images of one frame or more stored in the image, and the motion vector and an inter prediction parameter such as a frame number to be determined determined by the encoding control unit 1 are used to encode the code. A process for generating an inter-predicted image by performing an inter prediction process (motion-compensated prediction process) on a block is performed.
The motion compensation prediction unit 7 always performs motion compensation prediction processing for the generation of a prediction image of a luminance signal, but the generation of a prediction image of a color difference signal is performed by the encoding control unit 1 for each prediction block. When the inter-color signal prediction flag of the prediction block is set to ON, the color that generates the prediction image of the color difference signal in the prediction block with reference to the encoded color signal without performing the motion compensation prediction process Perform inter-signal prediction processing. The motion compensation prediction unit 7 constitutes a motion compensation prediction unit.

この実施の形態1では、各予測ブロックに対して、符号化制御部1により当該予測ブロックの色信号間予測フラグがONに設定されている場合、イントラ予測部5、イントラブロックコピー予測部6又は動き補償予測部7のいずれかが色信号間予測処理を実施することを想定しているが、色信号間予測処理を実施する予測部を別途設けるようにしてもよい。
イントラ予測部5、イントラブロックコピー予測部6又は動き補償予測部7が色信号間予測処理を実施するか否かの判断は、例えば、符号化制御部1から出力される色信号間予測パラメータに含まれている色信号間予測フラグ(色信号間予測処理を実施するか否かを示す予測ブロック単位のON/OFF情報であり、ONであれば色信号間予測処理の実施を明示し、OFFであれば色信号間予測処理の非実施を明示している)を参照することで行う。
In the first embodiment, for each prediction block, when the inter-color signal prediction flag of the prediction block is set to ON by the encoding control unit 1, the intra prediction unit 5, the intra block copy prediction unit 6 or Although it is assumed that any one of the motion compensation prediction units 7 performs the inter-color signal prediction process, a prediction unit that performs the inter-color signal prediction process may be provided separately.
Whether the intra prediction unit 5, the intra block copy prediction unit 6 or the motion compensation prediction unit 7 performs the inter-color signal prediction process is determined by, for example, using the inter-color signal prediction parameter output from the encoding control unit 1. Included inter-color signal prediction flag (ON / OFF information for each prediction block indicating whether or not to perform inter-color signal prediction processing. If ON, the execution of inter-color signal prediction processing is clearly indicated, and OFF. If so, the non-implementation of the inter-color signal prediction process is clearly indicated).

したがって、イントラ予測部5は、色信号間予測パラメータに含まれている色信号間予測フラグがONであれば色信号間予測処理を実施し、そのフラグがOFFであればイントラ予測処理を実施する。
また、イントラブロックコピー予測部6は、色信号間予測パラメータに含まれている色信号間予測フラグがONであれば色信号間予測処理を実施し、そのフラグがOFFであればイントラブロックコピー予測処理を実施する。
また、動き補償予測部7は、色信号間予測パラメータに含まれている色信号間予測フラグがONであれば色信号間予測処理を実施し、そのフラグがOFFであれば動き補償予測処理を実施する。
色信号間予測パラメータは、符号化制御部1がイントラ予測パラメータ、イントラブロックコピー予測パラメータ又はインター予測パラメータを出力する際、これらの予測パラメータに含めるようにしてもよいし、これらの予測パラメータと別途に出力するようにしてもよい。
Therefore, the intra prediction unit 5 performs the inter-color signal prediction process if the inter-color signal prediction flag included in the inter-color signal prediction parameter is ON, and performs the intra prediction process if the flag is OFF. .
The intra block copy prediction unit 6 performs inter-color signal prediction processing if the inter-color signal prediction flag included in the inter-color signal prediction parameter is ON, and intra block copy prediction if the flag is OFF. Perform the process.
The motion compensation prediction unit 7 performs the inter-color signal prediction process if the inter-color signal prediction flag included in the inter-color signal prediction parameter is ON, and performs the motion compensation prediction process if the flag is OFF. carry out.
The inter-color signal prediction parameters may be included in these prediction parameters when the encoding control unit 1 outputs the intra prediction parameters, the intra block copy prediction parameters, or the inter prediction parameters, or separately from these prediction parameters. May be output.

後述する可変長符号化部15では、符号化制御部1から出力される色信号間予測パラメータを符号化して、可変長符号化して符号化データを生成する。
また、色差信号のイントラ予測パラメータ、イントラブロックコピー予測パラメータ及びインター予測パラメータについては、色信号間予測パラメータに含まれている色信号間予測フラグがOFFである場合に限り、可変長符号化して符号化データを生成する。あるいは、色差信号のイントラ予測パラメータ、イントラブロックコピー予測パラメータ及びインター予測パラメータは輝度信号と同じとしても良い。すなわち、上記色信号間予測フラグがOFFである場合、輝度信号のイントラ予測パラメータ、イントラブロックコピー予測パラメータ、インター予測パラメータを用いて色差信号の予測処理を実施する。このようにすることで、色差信号の予測に必要なパラメータを別途符号化しないで済むため、符号量を削減することができる。特にイントラブロックコピー予測及び動き補償予測については、一般に画像の絵柄や動きは色信号間で高い相関を有することから、色差信号の予測パラメータと輝度信号の予測パラメータを共通化することで符号量を削減しつつ高い予測効率が実現できる。
ここでは、予測ブロック単位に色信号間予測処理の実施の有無を選択しているが、符号化ブロック単位あるいは最大サイズの符号化ブロック単位に、色信号間予測処理の実施の有無を選択するようにしてもよい。このようにすることで色信号間予測処理の切り替え単位が大きくなって予測効率が低下するが、色信号間予測フラグの符号化に要する符号量を削減することができる。あるいは、変換ブロック単位に選択しても良い。このようにすることで符号化ブロックより細かい単位で制御ができるため、予測性能が向上する。このとき、予測ブロックの中に複数の変換ブロックが存在する場合は上記色信号間予測フラグがONの変換ブロックのみ色信号間予測を実施し、上記色信号間予測フラグがOFFの変換ブロックでは色差信号に対するイントラ予測、イントラブロックコピー予測あるいは動き補償予測を行う。
あるいは、色信号間予測フラグを切り替えるブロックサイズを最大サイズの符号化ブロック、符号化ブロック、予測ブロック、変換ブロックとは独立に設定しても良い。このようにすることで、色信号間予測処理に最適なブロックサイズを設定することができる。独立に設定するブロックサイズは四分木によって表現される分割情報で定めるようにしても良く、このようにすることで、画像の局所性質に応じてブロックサイズを変更することができる。本ブロックサイズ情報は符号化して、画像復号装置で復号することでわかるようにしても良いし、画像符号化装置と画像復号装置共通のサイズを予め固定サイズとして設定しても良い。
また、色信号間予測フラグは、2つの色差信号(U、V信号)で共通でもよいし、U信号とV信号で独立にフラグを持つようにしてもよい。U信号とV信号で相関の高い色信号(輝度信号または色差信号)が同じ場合は共通とすることで、色信号間予測フラグの符号量を削減しながら、高精度な予測を実現することができる。一方、U信号とV信号で相関の高い色信号(輝度信号または色差信号)が異なる場合には、U信号とV信号で独立にフラグを持つようにすることで、より適応的に色信号間予測処理の切り替えが可能になり、予測精度を改善することができる。
The variable length encoding unit 15 described later encodes the inter-color signal prediction parameter output from the encoding control unit 1 and performs variable length encoding to generate encoded data.
Also, the intra prediction parameter, intra block copy prediction parameter, and inter prediction parameter of the color difference signal are encoded by variable length coding only when the inter-color signal prediction flag included in the inter-color signal prediction parameter is OFF. Generate data. Alternatively, the intra prediction parameter, intra block copy prediction parameter, and inter prediction parameter of the color difference signal may be the same as the luminance signal. That is, when the inter-color signal prediction flag is OFF, the color difference signal prediction process is performed using the intra prediction parameter, the intra block copy prediction parameter, and the inter prediction parameter of the luminance signal. By doing so, it is not necessary to separately encode the parameters necessary for predicting the color difference signal, so that the code amount can be reduced. In particular, for intra block copy prediction and motion compensation prediction, since the picture pattern and motion generally have a high correlation between color signals, the code amount can be increased by sharing the prediction parameters of the color difference signal and the prediction parameter of the luminance signal. High prediction efficiency can be realized while reducing.
Here, whether or not to perform the inter-color signal prediction process is selected for each prediction block, but whether or not to perform the inter-color signal prediction process is selected for each coding block unit or for each coding block of the maximum size. It may be. By doing so, the switching unit of the inter-color signal prediction process is increased and the prediction efficiency is lowered, but the code amount required for encoding the inter-color signal prediction flag can be reduced. Or you may select per conversion block. By doing so, control can be performed in units smaller than the encoded block, so that prediction performance is improved. At this time, when there are a plurality of conversion blocks in the prediction block, the inter-color signal prediction is performed only for the conversion block in which the inter-color signal prediction flag is ON, and the color difference is calculated in the conversion block in which the inter-color signal prediction flag is OFF Intra prediction, intra block copy prediction, or motion compensation prediction is performed on the signal.
Alternatively, the block size for switching the inter-color signal prediction flag may be set independently of the maximum size encoding block, encoding block, prediction block, and transform block. In this way, an optimal block size can be set for the inter-color signal prediction process. The block size set independently may be determined by the division information expressed by the quadtree, and in this way, the block size can be changed according to the local property of the image. The block size information may be encoded and decoded by an image decoding device, or a size common to the image encoding device and the image decoding device may be set as a fixed size in advance.
Further, the inter-color signal prediction flag may be common to the two color difference signals (U and V signals), or the U signal and the V signal may have flags independently. If the U signal and the V signal have the same highly correlated color signal (luminance signal or color difference signal), they can be used in common to realize high-precision prediction while reducing the code amount of the inter-color signal prediction flag. it can. On the other hand, when color signals (luminance signal or color difference signal) with high correlation are different between the U signal and the V signal, the U signal and the V signal have flags independently so that the color signals are more adaptively provided. The prediction process can be switched, and the prediction accuracy can be improved.

減算部8はブロック分割部3より出力された符号化ブロックから、イントラ予測部5により生成されたイントラ予測画像、イントラブロックコピー予測部6により生成されたイントラブロックコピー予測画像、又は、動き補償予測部7により生成されたインター予測画像を減算して、その減算結果である差分画像を示す予測差分信号を変換・量子化部9に出力する処理を実施する。
変換・量子化部9は符号化制御部1により決定された予測差分符号化パラメータに含まれる変換ブロック分割情報を参照して、減算部8から出力された予測差分信号に対する直交変換処理(例えば、DCT(離散コサイン変換)やDST(離散サイン変換)、予め特定の学習系列に対して基底設計がなされているKL変換等の直交変換処理)を変換ブロック単位に実施して変換係数を算出するとともに、その予測差分符号化パラメータに含まれる量子化パラメータを参照して、その変換ブロック単位の変換係数を量子化し、量子化後の変換係数である圧縮データを逆量子化・逆変換部10及び可変長符号化部15に出力する処理を実施する。
The subtracting unit 8 is an intra prediction image generated by the intra prediction unit 5, an intra block copy prediction image generated by the intra block copy prediction unit 6, or motion compensated prediction from the encoded block output from the block dividing unit 3. A process of subtracting the inter prediction image generated by the unit 7 and outputting a prediction difference signal indicating the difference image as a subtraction result to the transform / quantization unit 9 is performed.
The transform / quantization unit 9 refers to the transform block division information included in the prediction difference coding parameter determined by the coding control unit 1 and performs orthogonal transform processing on the prediction difference signal output from the subtraction unit 8 (for example, DCT (Discrete Cosine Transform), DST (Discrete Sine Transform), orthogonal transform processing such as KL transform, which is previously designed for a specific learning sequence, is performed for each transform block, and transform coefficients are calculated. Then, referring to the quantization parameter included in the prediction differential encoding parameter, the transform coefficient of the transform block unit is quantized, and the compressed data that is the transform coefficient after quantization is dequantized / inverse transform unit 10 and variable A process of outputting to the long encoding unit 15 is performed.

変換・量子化部9は変換係数を量子化する際、上記量子化パラメータから算出される量子化ステップサイズを変換係数毎にスケーリングする量子化マトリクスを用いて、変換係数の量子化処理を実施するようにしてもよい。
ここで、図10は4×4DCTの量子化マトリクスの一例を示す説明図である。
図中の数字は、各変換係数の量子化ステップサイズのスケーリング値を示している。
例えば、符号化ビットレートを抑制するために、図10に示すように、高域の変換係数程、量子化ステップサイズを大きな値にスケーリングすることで、複雑な画像領域等で発生する高域の変換係数を抑制して符号量を抑えつつ、主観品質に大きく影響する低域の係数の情報を落とさずに符号化することができる。
このように、変換係数毎の量子化ステップサイズを制御したい場合には量子化マトリクスを用いればよい。
When the transform / quantization unit 9 quantizes the transform coefficient, the transform / quantization unit 9 performs a transform coefficient quantization process using a quantization matrix that scales the quantization step size calculated from the quantization parameter for each transform coefficient. You may do it.
Here, FIG. 10 is an explanatory diagram illustrating an example of a 4 × 4 DCT quantization matrix.
The numbers in the figure indicate the scaling value of the quantization step size of each transform coefficient.
For example, in order to suppress the encoding bit rate, as shown in FIG. 10, by scaling the quantization step size to a larger value for the higher frequency transform coefficient, the higher frequency generated in a complex image region or the like. Encoding can be performed without dropping information on low-frequency coefficients that greatly affect subjective quality while suppressing the amount of codes by suppressing transform coefficients.
Thus, when it is desired to control the quantization step size for each transform coefficient, a quantization matrix may be used.

また、量子化マトリクスは、各直交変換サイズで色信号や符号化モード(イントラ符号化かインター符号化か)毎に独立したマトリクスを使用することができ、初期値として、画像符号化装置及び画像復号装置で予め共通に用意されている量子化マトリクスや既に符号化された量子化マトリクスの中から選択するか、新しい量子化マトリクスを用いるかをそれぞれ選択することができる。
したがって、変換・量子化部9は、各直交変換サイズに対して色信号や符号化モード毎に、新しい量子化マトリクスを用いるか否かを示すフラグを符号化すべき量子化マトリクスパラメータに設定する。
In addition, the quantization matrix can use an independent matrix for each color signal and coding mode (intra coding or inter coding) with each orthogonal transform size. It is possible to select whether to use a quantization matrix that is commonly prepared in advance by the decoding apparatus or an already encoded quantization matrix or to use a new quantization matrix.
Accordingly, the transform / quantization unit 9 sets a flag indicating whether or not to use a new quantization matrix for each orthogonal transform size for each color signal or coding mode, as a quantization matrix parameter to be encoded.

さらに、新しい量子化マトリクスを用いる場合には、図10に示すような量子化マトリクスの各スケーリング値を符号化すべき量子化マトリクスパラメータに設定する。
一方、新しい量子化マトリクスを用いない場合には、初期値として、画像符号化装置及び画像復号装置で、予め共通に用意されている量子化マトリクス、又は、既に符号化された量子化マトリクスの中から、使用するマトリクスを特定するインデックスを符号化すべき量子化マトリクスパラメータに設定する。ただし、参照可能な既に符号化された量子化マトリクスが存在しない場合、画像符号化装置及び画像復号装置で予め共通に用意されている量子化マトリクスのみ選択可能となる。
Furthermore, when a new quantization matrix is used, each scaling value of the quantization matrix as shown in FIG. 10 is set as a quantization matrix parameter to be encoded.
On the other hand, when a new quantization matrix is not used, as an initial value, a quantization matrix prepared in advance in the image encoding device and the image decoding device, or a quantization matrix that has already been encoded is used. Therefore, an index for specifying a matrix to be used is set as a quantization matrix parameter to be encoded. However, when there is no already-encoded quantization matrix that can be referred to, it is possible to select only the quantization matrix that is prepared in advance by the image encoding device and the image decoding device.

逆量子化・逆変換部10は符号化制御部1により決定された予測差分符号化パラメータに含まれる量子化パラメータ及び変換ブロック分割情報を参照して、変換ブロック単位に変換・量子化部9から出力された圧縮データを逆量子化するとともに、逆量子化後の圧縮データである変換係数に対する逆直交変換処理を実施して、減算部8から出力された予測差分信号に相当する局所復号予測差分信号を算出する処理を実施する。なお、変換・量子化部9が量子化マトリクスを用いて、量子化処理を実施している場合には、逆量子化処理時においても、その量子化マトリクスを参照して、対応する逆量子化処理を実施する。
加算部11は逆量子化・逆変換部10により算出された局所復号予測差分信号と、イントラ予測部5により生成されたイントラ予測画像、イントラブロックコピー予測部6により生成されたイントラブロックコピー予測画像、又は、動き補償予測部7により生成されたインター予測画像とを加算して、ブロック分割部3から出力された符号化ブロックに相当する局所復号画像を算出する処理を実施する。
The inverse quantization / inverse transform unit 10 refers to the quantization parameter and transform block division information included in the prediction difference coding parameter determined by the coding control unit 1, and transforms and transforms the transform block 9 in units of transform blocks. A local decoded prediction difference corresponding to the prediction difference signal output from the subtracting unit 8 is obtained by dequantizing the output compressed data and performing an inverse orthogonal transform process on the transform coefficient that is the compressed data after the inverse quantization. A process of calculating a signal is performed. In addition, when the transform / quantization unit 9 uses the quantization matrix to perform the quantization process, the corresponding inverse quantization can be performed by referring to the quantization matrix even during the inverse quantization process. Perform the process.
The addition unit 11 includes a local decoded prediction difference signal calculated by the inverse quantization / inverse conversion unit 10, an intra prediction image generated by the intra prediction unit 5, and an intra block copy prediction image generated by the intra block copy prediction unit 6. Alternatively, the inter prediction image generated by the motion compensation prediction unit 7 is added to perform a process of calculating a local decoded image corresponding to the encoded block output from the block dividing unit 3.

イントラ用メモリ12は加算部11により算出された局所復号画像を格納する記録媒体である。
ループフィルタ部13は加算部11により算出された局所復号画像に対して、所定のフィルタ処理を実施して、フィルタ処理後の局所復号画像を出力する処理を実施する。
具体的には、変換ブロックの境界や予測ブロックの境界に発生する歪みを低減するフィルタ(デブロッキングフィルタ)処理、画素単位に適応的にオフセットを加算する(画素適応オフセット)処理、ウィーナフィルタ等の線形フィルタを適応的に切り替えてフィルタ処理する適応フィルタ処理などを行う。
The intra memory 12 is a recording medium that stores the locally decoded image calculated by the adding unit 11.
The loop filter unit 13 performs a predetermined filtering process on the local decoded image calculated by the adding unit 11 and outputs a local decoded image after the filter process.
Specifically, filter (deblocking filter) processing that reduces distortion occurring at the boundaries of transform blocks and prediction blocks, processing for adaptively adding an offset (pixel adaptive offset) for each pixel, Wiener filter, etc. Performs adaptive filter processing for adaptively switching linear filters and performing filter processing.

ただし、ループフィルタ部13は、上記のデブロッキングフィルタ処理、画素適応オフセット処理及び適応フィルタ処理のそれぞれについて、処理を行うか否かを決定し、各処理の有効フラグをヘッダ情報として可変長符号化部15に出力する。なお、上記のフィルタ処理を複数使用する際は、各フィルタ処理を順番に実施する。図11は複数のフィルタ処理を用いる場合のループフィルタ部13の構成例を示している。
一般に使用するフィルタ処理の種類が多いほど、画像品質は向上するが、一方で処理負荷は高くなる。即ち、画像品質と処理負荷はトレードオフの関係にある。また、各フィルタ処理の画像品質改善効果はフィルタ処理対象画像の特性によって異なる。したがって、画像符号化装置が許容する処理負荷や符号化処理対象画像の特性にしたがって使用するフィルタ処理を決めればよい。例えば、図11の構成よりも処理負荷を削減したい場合、デブロッキングフィルタ処理と画素適応オフセット処理のみで構成するといったことが考えられる。
However, the loop filter unit 13 determines whether or not to perform each of the deblocking filter process, the pixel adaptive offset process, and the adaptive filter process, and performs variable length coding using the valid flag of each process as header information. To the unit 15. When a plurality of the above filter processes are used, each filter process is performed in order. FIG. 11 shows a configuration example of the loop filter unit 13 when a plurality of filter processes are used.
Generally, the more types of filter processing that are used, the better the image quality, but the higher the processing load. That is, image quality and processing load are in a trade-off relationship. In addition, the image quality improvement effect of each filter process varies depending on the characteristics of the image to be filtered. Therefore, the filter processing to be used may be determined according to the processing load allowed by the image encoding device and the characteristics of the encoding target image. For example, when it is desired to reduce the processing load as compared with the configuration of FIG. 11, it may be configured only by the deblocking filter processing and the pixel adaptive offset processing.

ここで、デブロッキングフィルタ処理では、ブロック境界にかけるフィルタ強度の選択に用いる各種パラメータを初期値から変更することができる。変更する場合には、そのパラメータをヘッダ情報として可変長符号化部15に出力する。
画素適応オフセット処理では、最初に、画像を複数のブロックに分割し、そのブロック単位に、オフセット処理を行わない場合もクラス分類手法の一つとして定義して、予め用意されている複数のクラス分類手法の中から、1つのクラス分類手法を選択する。
次に、選択したクラス分類手法によって、ブロック内の各画素をクラス分類し、クラス毎に符号化歪みを補償するオフセット値を算出する。
最後に、局所復号画像の画素値に対して、そのオフセット値を加算する処理を行うことで局所復号画像の画像品質を改善する。
したがって、画素適応オフセット処理では、ブロック分割情報、各ブロックのクラス分類手法を示すインデックス、ブロック単位の各クラスのオフセット値を特定するオフセット情報をヘッダ情報として可変長符号化部15に出力する。
なお、画素適応オフセット処理において、例えば、最大符号化ブロックといった固定サイズのブロック単位に常に分割して、そのブロック毎にクラス分類手法を選択して、クラス毎の適応オフセット処理を行ってもよい。この場合、上記ブロック分割情報が不要となり、ブロック分割情報に要する符号量分だけ符号量が削減され、符号化効率を高めることができる。
Here, in the deblocking filter process, various parameters used for selecting the filter strength applied to the block boundary can be changed from the initial values. When changing, the parameter is output to the variable length coding unit 15 as header information.
In the pixel adaptive offset process, first, an image is divided into a plurality of blocks, and when the offset process is not performed for each block, it is defined as one of the class classification methods, and a plurality of class classifications prepared in advance are used. One classification method is selected from the methods.
Next, each pixel in the block is classified by the selected class classification method, and an offset value for compensating the coding distortion is calculated for each class.
Finally, the image quality of the locally decoded image is improved by performing a process of adding the offset value to the pixel value of the locally decoded image.
Therefore, in the pixel adaptive offset processing, block division information, an index indicating a class classification method for each block, and offset information for specifying an offset value of each class in block units are output to the variable length coding unit 15 as header information.
In the pixel adaptive offset processing, for example, it may be always divided into fixed-size block units such as a maximum coding block, and a class classification method may be selected for each block to perform adaptive offset processing for each class. In this case, the block division information becomes unnecessary, the code amount is reduced by the amount of code required for the block division information, and the coding efficiency can be improved.

適応フィルタ処理では、局所復号画像を所定の手法でクラス分類し、各クラスに属する領域(局所復号画像)毎に、重畳されている歪みを補償するフィルタを設計し、そのフィルタを用いて、当該局所復号画像のフィルタ処理を実施する。
そして、クラス毎に設計したフィルタをヘッダ情報として可変長符号化部15に出力する。
クラス分類手法としては、画像を空間的に等間隔に区切る簡易な手法や、ブロック単位に画像の局所的な特性(分散など)に応じて分類する手法がある。
また、適応フィルタ処理で使用するクラス数は、予め画像符号化装置及び画像復号装置に共通の値として設定してもよいし、符号化すべきパラメータとしてもよい。
前者と比較して後者の方が、使用するクラス数を自由に設定することができるため、画像品質改善効果が上がるが、一方でクラス数を符号化するために、その分の符号量が増加する。
In adaptive filter processing, local decoded images are classified by a predetermined method, and a filter that compensates for the distortion that is superimposed is designed for each region (local decoded image) belonging to each class. Filter the local decoded image.
Then, the filter designed for each class is output to the variable length encoding unit 15 as header information.
As the class classification method, there are a simple method for spatially dividing an image at equal intervals, and a method for classifying an image according to local characteristics (dispersion, etc.) of each block.
Further, the number of classes used in the adaptive filter processing may be set in advance as a value common to the image encoding device and the image decoding device, or may be a parameter to be encoded.
Compared to the former, the latter can set the number of classes to be used freely, so the image quality improvement effect will be improved, but on the other hand, the amount of code will be increased to encode the number of classes. To do.

なお、画素適応オフセット処理及び適応フィルタ処理を行う場合には、図11に示すように、映像信号をループフィルタ部13で参照する必要があるため、映像信号がループフィルタ部13に入力されるように、図1の画像符号化装置を変更する必要がある。   When performing the pixel adaptive offset process and the adaptive filter process, as shown in FIG. 11, the video signal needs to be referred to by the loop filter unit 13, so that the video signal is input to the loop filter unit 13. In addition, it is necessary to change the image encoding apparatus of FIG.

動き補償予測フレームメモリ14はループフィルタ部13のフィルタ処理後の局所復号画像を格納する記録媒体である。
可変長符号化部15は変換・量子化部9から出力された圧縮データと、符号化制御部1の出力信号(最大符号化ブロック内のブロック分割情報、符号化モード、予測差分符号化パラメータ、イントラ予測パラメータ、イントラブロックコピー予測パラメータ、インター予測パラメータ、色信号間予測フラグを含む色信号間予測パラメータ)と、動き補償予測部7から出力された動きベクトル(符号化モードがインター符号化モードである場合)とを可変長符号化して符号化データを生成する処理を実施する。
また、可変長符号化部15は、図13に例示するように、符号化ビットストリームのヘッダ情報として、シーケンスレベルヘッダ、ピクチャレベルヘッダを符号化し、ピクチャデータと共に符号化ビットストリームを生成する処理を実施する。なお、可変長符号化部15は符号化手段を構成している。
The motion compensated prediction frame memory 14 is a recording medium that stores a locally decoded image after the filter processing of the loop filter unit 13.
The variable length encoding unit 15 and the compressed data output from the transform / quantization unit 9 and the output signal of the encoding control unit 1 (block division information in the maximum encoding block, encoding mode, prediction difference encoding parameter, Intra-prediction parameters, intra-block copy prediction parameters, inter-prediction parameters, inter-color signal prediction parameters including inter-color signal prediction flags) and motion vectors output from the motion compensation prediction unit 7 (the encoding mode is the inter encoding mode) And a process of generating encoded data by variable length encoding.
Further, as illustrated in FIG. 13, the variable length encoding unit 15 encodes a sequence level header and a picture level header as header information of the encoded bit stream, and generates an encoded bit stream together with the picture data. carry out. Note that the variable length coding unit 15 constitutes coding means.

ただし、ピクチャデータは1以上のスライスデータから構成され、各スライスデータはスライスレベルヘッダと当該スライス内にある上記符号化データをまとめたものである。ピクチャデータはスライスデータの他に補足情報を示すヘッダ情報を含む場合もある。
シーケンスレベルヘッダは、画像サイズ、色信号フォーマット、輝度信号や色差信号の信号値のビット深度、シーケンス単位でのループフィルタ部13における各フィルタ処理(適応フィルタ処理、画素適応オフセット処理、デブロッキングフィルタ処理)の有効フラグ、量子化マトリクスの有効フラグなど、一般的にシーケンス単位に共通となるヘッダ情報をまとめたものである。
ピクチャレベルヘッダは、参照するシーケンスレベルヘッダのインデックスや動き補償時の参照ピクチャ数、エントロピー符号化の確率テーブル初期化フラグ、対象ピクチャに対する有効フラグを含めた量子化マトリクスパラメータなど、ピクチャ単位で設定するヘッダ情報をまとめたものである。
However, picture data is composed of one or more slice data, and each slice data is a combination of a slice level header and the encoded data in the slice. The picture data may include header information indicating supplementary information in addition to the slice data.
The sequence level header includes the image size, the color signal format, the bit depth of the signal value of the luminance signal and the color difference signal, and each filter process (adaptive filter process, pixel adaptive offset process, deblocking filter process) in the loop filter unit 13 in sequence units. In general, header information that is common to each sequence unit, such as a valid flag of () and a valid flag of a quantization matrix, is collected.
The picture level header is set on a picture-by-picture basis, such as the index of the sequence level header to be referenced, the number of reference pictures at the time of motion compensation, the entropy coding probability table initialization flag, and the quantization matrix parameter including the valid flag for the target picture. This is a summary of header information.

スライスレベルヘッダは、当該スライスがピクチャのどの位置にあるかを示す位置情報、どのピクチャレベルヘッダを参照するかを示すインデックス、スライスの符号化タイプ(オールイントラ符号化、インター符号化など)、ループフィルタ部13における各フィルタ処理(適応フィルタ処理、画素適応オフセット処理、デブロッキングフィルタ処理)を行うか否かを示すフラグなどのスライス単位のパラメータをまとめたものである。   The slice level header includes position information indicating where the slice is located in the picture, an index indicating which picture level header is referred to, a slice coding type (all-intra coding, inter coding, etc.), and a loop. This is a summary of parameters in units of slices such as flags indicating whether or not to perform each filter process (adaptive filter process, pixel adaptive offset process, deblocking filter process) in the filter unit 13.

ここでは、可変長符号化部15が色信号間予測フラグを含む色信号間予測パラメータを可変長符号化する例を示しているが、シーケンスレベルヘッダ、ピクチャレベルヘッダ及びスライスレベルヘッダのうち、少なくとも1つのヘッダに色信号間予測処理を実施するか否かを示すフラグ(上位ヘッダ色信号間予測有効フラグ)を含めて符号化するようにしてもよい。このようにすることで、シーケンス、ピクチャ、あるいはスライス単位で、色信号間予測処理による高精度な予測が可能な領域(色信号間の相関が高い領域)である場合のみ有効とすることができる一方、色信号間予測処理の予測精度が低い領域は無効とすることで、色信号間予測処理に関する符号化パラメータを符号化せずに済み、符号量を削減することができる。上記上位ヘッダ色信号間予測有効フラグはイントラ予測、イントラブロックコピー予測、動き補償予測それぞれに用意しても良いし、共通としても良い。
例えば、イントラ予測部5で輝度信号のイントラ予測処理を行う場合のみ色信号間予測処理を有効とすることで、輝度信号について、その他の予測処理(イントラブロックコピー予測処理、動き補償予測処理)を行う場合には、色信号間予測処理に関する符号化パラメータを符号化せずに済み、符号量を削減することができると共に、イントラブロックコピー予測部6及び動き補償予測部7の構成を簡易化することができる。あるいは、上記上位ヘッダ色信号間予測有効フラグをイントラ予測、イントラブロックコピー予測、動き補償予測共通の情報として、色信号間予測の予測効率が高いスライスのみ有効とすることで、色信号間予測の予測効率が低い領域でのブロック単位の色信号間予測パラメータの符号化による符号量増加を回避することができる。
Here, an example is shown in which the variable length coding unit 15 performs variable length coding on the inter-color signal prediction parameter including the inter-color signal prediction flag, but at least of the sequence level header, the picture level header, and the slice level header. One header may be encoded including a flag indicating whether or not to perform inter-color signal prediction processing (higher header inter-color signal prediction valid flag). In this way, it can be effective only in a region where prediction can be performed with high accuracy by inter-color signal prediction processing (region where correlation between color signals is high) in units of sequences, pictures, or slices. On the other hand, by invalidating the region where the prediction accuracy of the inter-color signal prediction process is low, it is not necessary to encode the encoding parameter related to the inter-color signal prediction process, and the code amount can be reduced. The upper header color signal inter-prediction valid flag may be prepared for each of intra prediction, intra block copy prediction, and motion compensation prediction, or may be common.
For example, by enabling the inter-color signal prediction processing only when the intra prediction unit 5 performs the intra prediction processing of the luminance signal, the other prediction processing (intra block copy prediction processing, motion compensation prediction processing) is performed on the luminance signal. When performing, it is not necessary to encode the encoding parameter regarding the inter-color signal prediction process, the amount of code can be reduced, and the configurations of the intra block copy prediction unit 6 and the motion compensation prediction unit 7 are simplified. be able to. Alternatively, the high-order header color signal prediction valid flag is used as information common to intra prediction, intra block copy prediction, and motion compensation prediction. It is possible to avoid an increase in the amount of code due to the encoding of the inter-color signal prediction parameter for each block in a region where the prediction efficiency is low.

また、上記上位ヘッダ色信号間予測有効フラグについて、シーケンスレベルヘッダ、ピクチャレベルヘッダ及びスライスレベルヘッダのうち、2つ以上のヘッダで符号化する場合、優先度はスライスレベルヘッダ、ピクチャレベルヘッダ、シーケンスレベルヘッダの順となる。即ち、スライスレベルヘッダとピクチャレベルヘッダに上記フラグが存在する場合は、スライスレベルヘッダ内のフラグが優先され、ピクチャレベルヘッダ及びシーケンスレベルヘッダ内にフラグが存在する場合はピクチャレベルヘッダ内のフラグが優先される。
さらに、上記上位ヘッダ色信号間予測有効フラグについて、ピクチャを分割するサブピクチャの単位に設けるようにしても良い。具体的には、非特許文献1記載のTileやWavefront Parallel Processingのサブピクチャの分割単位に上記上位ヘッダ色信号間予測有効フラグを設けることで、色信号間予測が効果的な領域のみ有効とすることが可能となり符号量の増加を抑制しつつ高精度な予測が実現できる。
In addition, when the above-described upper header color signal prediction valid flag is encoded with two or more headers among a sequence level header, a picture level header, and a slice level header, the priority is a slice level header, a picture level header, a sequence Level header order. That is, when the flag is present in the slice level header and the picture level header, the flag in the slice level header has priority, and when the flag is present in the picture level header and sequence level header, the flag in the picture level header is set. have priority.
Furthermore, the upper header color signal inter-prediction valid flag may be provided in units of sub-pictures into which a picture is divided. Specifically, by providing the above-described upper header inter-color signal prediction valid flag in the sub-picture division unit of Tile or Wavefront Parallel Processing described in Non-Patent Document 1, only an area where inter-color signal prediction is effective is enabled. Therefore, it is possible to realize highly accurate prediction while suppressing an increase in code amount.

各ヘッダ情報とピクチャデータはNALユニットによって識別される。具体的には、シーケンスパラメータセット(上記シーケンスレベルヘッダに相当)、ピクチャパラメータヘッダ(上記ピクチャレベルヘッダに相当)、スライスデータはそれぞれ固有のNALユニットタイプとして定義され、NALユニットタイプの識別情報(インデックス)と共に符号化される。補足情報についても、存在する場合には固有のNALユニットとして定義される。また、上記ピクチャデータはアクセスユニットとして定義され、スライスデータを示すNALユニットや補足情報を示すNALユニット等の当該ピクチャに関わるNALユニットをまとめた、各ピクチャのデータアクセスの単位を示している。   Each header information and picture data is identified by a NAL unit. Specifically, a sequence parameter set (corresponding to the above sequence level header), a picture parameter header (corresponding to the above picture level header), and slice data are each defined as a unique NAL unit type, together with identification information (index) of the NAL unit type Encoded. Supplemental information is also defined as a unique NAL unit if it exists. The picture data is defined as an access unit, and indicates a unit of data access of each picture in which NAL units related to the picture such as a NAL unit indicating slice data and a NAL unit indicating supplementary information are collected.

図1の例では、画像符号化装置の構成要素である符号化制御部1、スライス分割部2、ブロック分割部3、切換スイッチ4、イントラ予測部5、イントラブロックコピー予測部6、動き補償予測部7、減算部8、変換・量子化部9、逆量子化・逆変換部10、加算部11、イントラ用メモリ12、ループフィルタ部13、動き補償予測フレームメモリ14及び可変長符号化部15のそれぞれが専用のハードウェアで構成(イントラ用メモリ12及び動き補償予測フレームメモリ14以外の構成要素は、例えば、CPUを実装している半導体集積回路や、ワンチップマイコンなどで構成)されているものを想定しているが、画像符号化装置がコンピュータで構成されていてもよい。
画像符号化装置をコンピュータで構成する場合、イントラ用メモリ12及び動き補償予測フレームメモリ14をコンピュータのメモリ上に構成するとともに、符号化制御部1、スライス分割部2、ブロック分割部3、切換スイッチ4、イントラ予測部5、イントラブロックコピー予測部6、動き補償予測部7、減算部8、変換・量子化部9、逆量子化・逆変換部10、加算部11、ループフィルタ部13及び可変長符号化部15の処理内容を記述しているプログラムをコンピュータのメモリに格納し、当該コンピュータのCPUが当該メモリに格納されているプログラムを実行するようにすればよい。
図2はこの発明の実施の形態1による画像符号化装置の処理内容(画像符号化方法)を示すフローチャートである。
In the example of FIG. 1, a coding control unit 1, a slice division unit 2, a block division unit 3, a changeover switch 4, an intra prediction unit 5, an intra block copy prediction unit 6, and motion compensation prediction, which are components of the image coding apparatus. Unit 7, subtraction unit 8, transform / quantization unit 9, inverse quantization / inverse transform unit 10, addition unit 11, intra memory 12, loop filter unit 13, motion compensated prediction frame memory 14, and variable length coding unit 15 Are configured by dedicated hardware (components other than the intra memory 12 and the motion compensation prediction frame memory 14 are configured by, for example, a semiconductor integrated circuit on which a CPU is mounted, a one-chip microcomputer, or the like). Although the thing is assumed, the image coding apparatus may be configured by a computer.
When the image encoding device is configured by a computer, the intra memory 12 and the motion compensated prediction frame memory 14 are configured on the computer memory, and the encoding control unit 1, the slice dividing unit 2, the block dividing unit 3, and the changeover switch. 4, intra prediction unit 5, intra block copy prediction unit 6, motion compensation prediction unit 7, subtraction unit 8, transformation / quantization unit 9, inverse quantization / inverse transformation unit 10, addition unit 11, loop filter unit 13 and variable A program describing the processing contents of the long encoding unit 15 may be stored in a memory of a computer so that the CPU of the computer executes the program stored in the memory.
FIG. 2 is a flowchart showing the processing contents (image coding method) of the image coding apparatus according to Embodiment 1 of the present invention.

図3はこの発明の実施の形態1による画像復号装置を示す構成図である。
図3において、可変長復号部31は図1の画像符号化装置により生成された符号化ビットストリームを入力すると、そのビットストリームからシーケンスレベルヘッダ、ピクチャレベルヘッダ、スライスレベルヘッダなどの各ヘッダ情報とピクチャデータを復号する処理を実施する。
ただし、ピクチャデータは1以上のスライスデータから構成されており、各スライスデータはスライスレベルヘッダと当該スライス内にある符号化データがまとめられているものである。ピクチャデータはスライスデータの他に補足情報を示すヘッダ情報を含む場合もある。このとき、YUV4:4:4フォーマット信号やRGB4:4:4フォーマット信号の各信号をモノクローム画像信号とみなしてそれぞれ独立にモノクローム(YUV4:0:0)符号化していることを示す情報がヘッダ情報に含まれる場合、各色信号の符号化ビットストリームに対してそれぞれ独立に復号処理を実施することができる。
3 is a block diagram showing an image decoding apparatus according to Embodiment 1 of the present invention.
In FIG. 3, when the variable length decoding unit 31 receives the encoded bit stream generated by the image encoding apparatus of FIG. 1, each header information such as a sequence level header, a picture level header, a slice level header, and the like is extracted from the bit stream. A process of decoding picture data is performed.
However, picture data is composed of one or more slice data, and each slice data is a collection of a slice level header and encoded data in the slice. The picture data may include header information indicating supplementary information in addition to the slice data. At this time, the header information includes information indicating that each of the YUV 4: 4: 4 format signal and the RGB 4: 4: 4 format signal is regarded as a monochrome image signal and is independently encoded in monochrome (YUV 4: 0: 0). In the case where it is included, the decoding process can be performed independently on the encoded bit stream of each color signal.

各ヘッダ情報とピクチャデータはNALユニットによって識別される。具体的には、シーケンスパラメータセット(上記シーケンスレベルヘッダに相当)、ピクチャパラメータヘッダ(上記ピクチャレベルヘッダに相当)、スライスデータはそれぞれ固有のNALユニットタイプとして定義され、NALユニットタイプの識別情報(インデックス)を復号することで識別される。補足情報についても、存在する場合には固有のNALユニットとして識別される。また、ピクチャデータはスライスデータを示すNALユニットや補足情報を示すNALユニット等の当該ピクチャに関わるNALユニットをまとめたアクセスユニットとして識別される。   Each header information and picture data is identified by a NAL unit. Specifically, a sequence parameter set (corresponding to the sequence level header), a picture parameter header (corresponding to the picture level header), and slice data are defined as unique NAL unit types, respectively, and identification information (index) of the NAL unit type is used. It is identified by decoding. The supplemental information is also identified as a unique NAL unit if it exists. Further, picture data is identified as an access unit in which NAL units related to the picture such as a NAL unit indicating slice data and a NAL unit indicating supplementary information are collected.

上記ヘッダ情報に含まれる量子化マトリクスの有効フラグが“有効”を示す場合、可変長復号部31は量子化マトリクスパラメータを可変長復号し、量子化マトリクスを特定する。具体的には、各直交変換サイズの色信号や符号化モード毎に、量子化マトリクスパラメータが初期値として、画像符号化装置及び画像復号装置で予め共通に用意されている量子化マトリクス、又は、既に復号された量子化マトリクスである(新しい量子化マトリクスでない)ことを示す場合は、上記マトリクスの内のどの量子化マトリクスであるかを特定するインデックス情報を参照して量子化マトリクスを特定し、量子化マトリクスパラメータが新しい量子化マトリクスを用いることを示す場合は、量子化マトリクスパラメータに含まれる量子化マトリクスを使用する量子化マトリクスとして特定する。   When the valid flag of the quantization matrix included in the header information indicates “valid”, the variable length decoding unit 31 performs variable length decoding of the quantization matrix parameter to identify the quantization matrix. Specifically, for each color signal or encoding mode of each orthogonal transform size, the quantization matrix parameter is set as an initial value, a quantization matrix prepared in advance in the image encoding device and the image decoding device, or When indicating that the quantization matrix has already been decoded (not a new quantization matrix), the quantization matrix is identified with reference to the index information identifying which quantization matrix of the matrix, When the quantization matrix parameter indicates that a new quantization matrix is used, the quantization matrix is specified as a quantization matrix that uses the quantization matrix included in the quantization matrix parameter.

また、可変長復号部31は、スライスレベルヘッダを参照して、スライス分割状態を特定するとともに、各スライスのスライスデータを復号して、最大符号化ブロックの符号化データを特定すると共に、スライスデータに含まれるブロック分割情報を復号して、最大符号化ブロックを階層的に分割して復号処理を行う単位である符号化ブロックを特定し、各々の符号化ブロックに係る圧縮データ、符号化モード、イントラ予測パラメータ(符号化モードがイントラ符号化モードである場合)、イントラブロックコピー予測パラメータ(符号化モードがイントラブロックコピー符号化モードである場合)、インター予測パラメータ(符号化モードがインター符号化モードである場合)、動きベクトル(符号化モードがインター符号化モードである場合)、色信号間予測を実施するか否かのフラグ(色信号間予測フラグ)を含む色信号間予測パラメータ及び予測差分符号化パラメータを可変長復号する処理を実施する。   In addition, the variable length decoding unit 31 refers to the slice level header, specifies the slice division state, decodes the slice data of each slice, specifies the encoded data of the maximum encoded block, and slice data The block division information included in the block, the encoding block that is a unit for performing decoding processing by hierarchically dividing the maximum encoding block, and specifying the compressed data, the encoding mode, Intra prediction parameters (when the encoding mode is the intra encoding mode), intra block copy prediction parameters (when the encoding mode is the intra block copy encoding mode), inter prediction parameters (the encoding mode is the inter encoding mode) ) Motion vector (if the coding mode is inter coding mode) If), carries out a process of variable length decoding the predictive parameters and predictive differential coding parameters between the color signal including a flag indicating whether or not to implement the inter-color signal prediction (between the color signal prediction flag).

ここでは、可変長復号部31が、各符号化ブロックに関わる色信号間予測パラメータを可変長復号する例を示したが、図1の画像符号化装置が、シーケンスレベルヘッダ、ピクチャレベルヘッダ、スライスレベルヘッダの内、少なくとも1つのヘッダに色信号間予測処理を実施するか否かを示すフラグ(上位ヘッダ色信号間予測有効フラグ)を含めて符号化している場合、可変長復号部31が上記上位ヘッダ色信号間予測有効フラグを復号し、そのフラグがONである場合(色信号間予測処理を実施する場合)のみ、対応するイントラ予測部34、イントラブロックコピー予測部35、動き補償予測部36で色信号間予測処理を有効とし、色信号間予測処理が有効である符号化モードを示す符号化ブロックのみ当該符号化ブロックに関わる上記色信号間予測パラメータを可変長復号する。色信号間予測処理が有効でない符号化モードを示す符号化ブロックについては、この符号化ブロックに関わる上記色信号間予測パラメータは可変長復号されず、対応する上記色信号間予測フラグはOFF(色信号間予測を実施しない)に設定される。
ここで、上記上位ヘッダ色信号間予測有効フラグは、図1の画像符号化装置がイントラ予測、イントラブロックコピー予測、動き補償予測それぞれに用意している場合、対応する画像復号装置はそれぞれ個別に用意されたフラグを復号するように構成し、一方、図1の画像符号化装置がイントラ予測、イントラブロックコピー予測、動き補償予測共通で用意している場合、対応する画像復号装置はその共通のフラグを復号するように構成する。
ただし、図1の画像符号化装置が、色信号間予測処理の有効化に関する各フラグを、シーケンスレベルヘッダ、ピクチャレベルヘッダ、スライスレベルヘッダのうち、2つ以上のヘッダで符号化している場合、可変長復号部31によって復号されたフラグについて、スライスレベルヘッダ、ピクチャレベルヘッダ、シーケンスレベルヘッダの順に優先度を設定する。
即ち、スライスレベルヘッダとピクチャレベルヘッダ内にフラグが存在する場合はスライスレベルヘッダ内のフラグが優先され、ピクチャレベルヘッダとシーケンスレベルヘッダ内にフラグが存在する場合はピクチャレベルヘッダ内のフラグが優先される。
また、上記上位ヘッダ色信号間予測有効フラグについて、図1の画像符号化装置がピクチャを分割するサブピクチャの単位に上記上位ヘッダ色信号間予測有効フラグを設けるように構成している場合、対応する画像復号装置はサブピクチャの単位に復号するように構成する。このようにすることで、サブピクチャ単位の色信号間予測の有効・無効制御を行っている画像符号化装置の符号化ビットストリームを正しく復号することができる。
Here, an example has been shown in which the variable length decoding unit 31 performs variable length decoding on the inter-color signal prediction parameters related to each coding block. However, the image coding apparatus in FIG. 1 includes a sequence level header, a picture level header, and a slice. In the case of encoding including a flag indicating whether or not to perform inter-color signal prediction processing (higher-header inter-color signal prediction valid flag) in at least one of the level headers, the variable length decoding unit 31 The corresponding intra prediction unit 34, intra block copy prediction unit 35, motion compensation prediction unit only when the upper header color signal inter prediction prediction flag is decoded and the flag is ON (when the inter color signal prediction process is performed). In 36, the inter-color signal prediction process is validated, and only the coding block indicating the coding mode in which the inter-color signal prediction process is valid is related to the coding block. Variable-length decoding prediction parameters between color signals. For a coding block indicating a coding mode in which inter-color signal prediction processing is not effective, the inter-color signal prediction parameter related to this coding block is not variable-length decoded, and the corresponding inter-color signal prediction flag is OFF (color Do not perform inter-signal prediction).
Here, when the image coding apparatus in FIG. 1 prepares the upper header color signal inter-prediction prediction valid flag for each of intra prediction, intra block copy prediction, and motion compensation prediction, the corresponding image decoding apparatuses are individually provided. If the prepared flag is configured to be decoded, and the image encoding device of FIG. 1 is prepared for intra prediction, intra block copy prediction, and motion compensation prediction, the corresponding image decoding device is the common Configure to decode the flag.
However, when the image encoding apparatus in FIG. 1 encodes each flag related to the validation of the inter-color signal prediction process with two or more headers among a sequence level header, a picture level header, and a slice level header, For the flag decoded by the variable length decoding unit 31, priority is set in the order of slice level header, picture level header, and sequence level header.
That is, if a flag exists in the slice level header and the picture level header, the flag in the slice level header takes precedence. If a flag exists in the picture level header and the sequence level header, the flag in the picture level header takes precedence. Is done.
In addition, regarding the above-described upper header color signal inter-prediction valid flag, when the image encoding apparatus of FIG. The image decoding apparatus that performs decoding is configured to decode in units of sub-pictures. In this way, it is possible to correctly decode the encoded bitstream of the image encoding apparatus that performs the validity / invalidity control of the inter-color signal prediction in units of sub-pictures.

逆量子化・逆変換部32は可変長復号部31により可変長復号された予測差分符号化パラメータに含まれる量子化パラメータ及び変換ブロック分割情報を参照して、可変長復号部31により可変長復号された圧縮データを変換ブロック単位に逆量子化するとともに、逆量子化後の圧縮データである変換係数に対する逆直交変換処理を実施して、図1の逆量子化・逆変換部10から出力された局所復号予測差分信号と同一の復号予測差分信号を算出する処理を実施する。
ここで、上記変換ブロック分割情報から、符号化ブロックにおける変換ブロックの分割状態を特定する。例えば、YUV4:2:0フォーマットの信号の場合、変換ブロックサイズは、図20に示すように、符号化ブロックを四分木状に階層分割することによって決定される。
The inverse quantization / inverse transform unit 32 refers to the quantization parameter and transform block division information included in the prediction difference encoding parameter variable length decoded by the variable length decoding unit 31, and the variable length decoding unit 31 performs variable length decoding. 1 is inversely quantized on a transform block basis, and inverse orthogonal transform processing is performed on transform coefficients that are compressed data after inverse quantization, and output from the inverse quantization / inverse transform unit 10 in FIG. A process of calculating the same decoded prediction difference signal as the local decoding prediction difference signal is performed.
Here, the division state of the transform block in the coding block is specified from the transform block partition information. For example, in the case of a YUV 4: 2: 0 format signal, the transform block size is determined by hierarchically dividing the encoded block into quadtrees as shown in FIG.

輝度信号については、例えば、図20に示すように、符号化ブロックが1つ又は複数の正方形の変換ブロックに階層的に分割されるように構成する。
色差信号については、図20に示すように、入力信号フォーマットがYUV4:2:0信号である場合、輝度信号と同様に、符号化ブロックが1つ又は複数の正方形の変換ブロックに階層的に分割されるように構成する。この場合、色差信号の変換ブロックサイズは、対応する輝度信号の変換ブロックの縦横ともに半分のサイズとなる。
For example, as shown in FIG. 20, the luminance signal is configured so that the coding block is hierarchically divided into one or a plurality of square transform blocks.
For the color difference signal, as shown in FIG. 20, when the input signal format is a YUV 4: 2: 0 signal, the encoding block is hierarchically divided into one or a plurality of square transform blocks in the same manner as the luminance signal. To be configured. In this case, the conversion block size of the color difference signal is half the vertical and horizontal sizes of the corresponding luminance signal conversion block.

入力信号フォーマットがYUV4:2:2信号である場合、図21に示すように、輝度信号と同様の四分木状の階層分割を行う。また、分割したブロックの形状が、垂直方向の画素数が水平方向の画素数の2倍になる長方形となるため、さらに、分割したブロックを上下に二分することで、YUV4:2:0信号での色差信号と同じブロックサイズ(輝度信号の変換ブロックの縦横ともに半分のサイズ)の変換ブロック2つで構成するようにする。
入力信号フォーマットがYUV4:4:4信号である場合、図22に示すように、色差信号の変換ブロックは、常に輝度信号の変換ブロックと同様の分割を行い、同じサイズの変換ブロックとなるように構成する。
When the input signal format is a YUV 4: 2: 2 signal, quadtree-like hierarchical division similar to the luminance signal is performed as shown in FIG. In addition, the shape of the divided block is a rectangle in which the number of pixels in the vertical direction is twice the number of pixels in the horizontal direction. The color difference signal is composed of two conversion blocks having the same block size (half the vertical and horizontal sizes of the luminance signal conversion block).
When the input signal format is a YUV 4: 4: 4 signal, as shown in FIG. 22, the color difference signal conversion block is always divided in the same manner as the luminance signal conversion block so as to be a conversion block of the same size. Configure.

また、可変長復号部31により可変長復号された各ヘッダ情報が、当該スライスで量子化マトリクスを用いて、逆量子化処理を実施することを示している場合、量子化マトリクスを用いて逆量子化処理を行う。
具体的には、各ヘッダ情報から特定される量子化マトリクスを用いて逆量子化処理を行う。
In addition, when each header information variable-length decoded by the variable-length decoding unit 31 indicates that inverse quantization processing is to be performed using the quantization matrix in the slice, the inverse quantization is performed using the quantization matrix. Process.
Specifically, inverse quantization processing is performed using a quantization matrix specified from each header information.

切換スイッチ33は可変長復号部31により可変長復号された符号化モードがイントラ符号化モードであれば、可変長復号部31により可変長復号されたイントラ予測パラメータをイントラ予測部34に出力し、可変長復号部31により可変長復号された符号化モードがイントラブロックコピー符号化モードであれば、可変長復号部31により可変長復号されたイントラブロックコピー予測パラメータをイントラブロックコピー予測部35に出力し、可変長復号部31により可変長復号された符号化モードがインター符号化モードであれば、可変長復号部31により可変長復号されたインター予測パラメータ及び動きベクトルを動き補償予測部36に出力する処理を実施する。   The changeover switch 33 outputs the intra-prediction parameter variable-length decoded by the variable-length decoding unit 31 to the intra-prediction unit 34 if the coding mode variable-length decoded by the variable-length decoding unit 31 is the intra-coding mode. If the encoding mode variable length decoded by the variable length decoding unit 31 is the intra block copy encoding mode, the intra block copy prediction parameters variable length decoded by the variable length decoding unit 31 are output to the intra block copy prediction unit 35. If the coding mode variable length decoded by the variable length decoding unit 31 is the inter coding mode, the inter prediction parameter and the motion vector variable length decoded by the variable length decoding unit 31 are output to the motion compensation prediction unit 36. Perform the process.

イントラ予測部34は可変長復号部31により可変長復号されたブロック分割情報から特定される符号化ブロックに係る符号化モードがイントラ符号化モードである場合、イントラ用メモリ38に格納されている復号画像を参照しながら、切換スイッチ33から出力されたイントラ予測パラメータを用いたイントラ予測処理(フレーム内予測処理)を実施してイントラ予測画像を生成する処理を実施する。   The intra prediction unit 34, when the coding mode related to the coding block identified from the block division information variable-length decoded by the variable-length decoding unit 31 is the intra-coding mode, the decoding stored in the intra memory 38 With reference to the image, an intra prediction process (intraframe prediction process) using the intra prediction parameter output from the changeover switch 33 is performed to generate an intra predicted image.

即ち、イントラ予測部34は、輝度信号については、輝度信号に対する上記イントラ予測パラメータを用いたイントラ予測処理(フレーム内予測処理)を実施して、輝度信号の予測画像を生成する。
一方、色差信号については、各予測ブロックに対して、当該予測ブロックの上記色信号間予測フラグがOFFである(色信号間予測処理の非実施を明示している)場合、イントラ予測処理を実施する。
このとき、色差信号のイントラ予測パラメータが、輝度信号に対するイントラ予測モードと同じ予測モードを用いる旨を示している場合(イントラ予測パラメータが輝度色差共通イントラ予測モード(DMモード)を示している場合)、輝度信号と同じフレーム内予測を実施して、色差信号の予測画像を生成する。
また、色差信号のイントラ予測パラメータが、垂直方向予測モード又は水平方向予測モードを示している場合、色差信号に対する方向性予測を実施して、色差信号の予測画像を生成する。
That is, for the luminance signal, the intra prediction unit 34 performs an intra prediction process (intra-frame prediction process) using the intra prediction parameter for the luminance signal, and generates a prediction image of the luminance signal.
On the other hand, for the color difference signal, if the inter-color signal prediction flag of the prediction block is OFF for each prediction block (indicating that the inter-color signal prediction process is not performed), intra prediction processing is performed. To do.
At this time, when the intra prediction parameter of the color difference signal indicates that the same prediction mode as the intra prediction mode for the luminance signal is used (when the intra prediction parameter indicates the luminance color difference common intra prediction mode (DM mode)). The same intra-frame prediction as that of the luminance signal is performed to generate a predicted image of the color difference signal.
Further, when the intra prediction parameter of the color difference signal indicates the vertical direction prediction mode or the horizontal direction prediction mode, the directionality prediction for the color difference signal is performed to generate a prediction image of the color difference signal.

入力信号フォーマットがYUV4:2:2信号である場合、図26に示すように、輝度信号が正方ブロックであれば、色差信号は輝度信号と比較して水平方向の画素数が1/2となる長方形のブロックとなる。したがって、図27に示すように、YUV4:4:4信号をYUV4:2:2信号に変換した際に、輝度信号と色差信号で同一方向の予測となるようにするためには、YUV4:2:2信号上では、垂直方向予測と水平方向予測以外の方向性予測の場合には、色差信号の予測方向が輝度信号の予測方向と異なることとなる。
具体的には、図28に示すように、輝度信号の予測方向ベクトルをv=(dx,dy)とした場合、色差信号の予測方向ベクトルは、v=(dx/2,dy)となる。即ち、図29に示すように、予測方向の角度をθとした場合、輝度信号の予測方向の角度をθ、色差信号の予測方向の角度をθとして、tanθ=2tanθの関係となる予測方向で予測する必要がある。
When the input signal format is a YUV 4: 2: 2 signal, as shown in FIG. 26, if the luminance signal is a square block, the color difference signal has half the number of pixels in the horizontal direction compared to the luminance signal. It becomes a rectangular block. Therefore, as shown in FIG. 27, when a YUV4: 4: 4 signal is converted into a YUV4: 2: 2 signal, YUV4: 2 is used to predict the luminance signal and the color difference signal in the same direction. : On two signals, in the case of directional prediction other than the vertical prediction and the horizontal prediction, the prediction direction of the color difference signal is different from the prediction direction of the luminance signal.
Specifically, as illustrated in FIG. 28, when the prediction direction vector of the luminance signal is v L = (dx L , dy L ), the prediction direction vector of the color difference signal is v C = (dx L / 2, dy L ). That is, as shown in FIG. 29, assuming that the angle of the prediction direction is θ, the angle of the prediction direction of the luminance signal is θ L , the angle of the prediction direction of the color difference signal is θ C , and tan θ C = 2tan θ L It is necessary to predict in the prediction direction.

したがって、輝度信号と色差信号で同一方向の予測を行う上記DMモードを正しく実施できるようにするために、入力信号フォーマットがYUV4:2:2信号である場合、輝度信号に使用したイントラ予測モードのインデックスを色差信号の予測に用いるイントラ予測モードのインデックスに変換し、変換後のインデックスに対応するイントラ予測モードによる色差信号の予測処理を実施する。具体的には、インデックスの変換テーブルを用意し、その変換テーブルを参照することで、インデックスを変換するように構成してもよいし、予め変換式を用意して、その変換式に従ってインデックスを変換するように構成してもよい。
このように構成することで、方向性予測処理自体を変更することなく、インデックスの変換のみで、YUV4:2:2信号のフォーマットに応じた色差信号の適切な予測を実施することができる。
Therefore, when the input signal format is a YUV 4: 2: 2 signal in order to correctly implement the DM mode in which the prediction in the same direction is performed with the luminance signal and the color difference signal, the intra prediction mode used for the luminance signal is used. The index is converted into an intra prediction mode index used for prediction of the color difference signal, and the color difference signal prediction process is performed in the intra prediction mode corresponding to the converted index. Specifically, an index conversion table may be prepared, and the index may be converted by referring to the conversion table. Alternatively, a conversion formula is prepared in advance, and the index is converted according to the conversion formula. You may comprise.
With this configuration, it is possible to perform appropriate prediction of the color difference signal according to the format of the YUV 4: 2: 2 signal only by converting the index without changing the directionality prediction process itself.

イントラ予測部34は、輝度信号の予測画像の生成については常にイントラ予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、当該予測ブロックの色信号間予測フラグがONである場合(色信号間予測処理の実施を明示している場合)、イントラ予測処理を実施せずに、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。なお、イントラ予測部34はイントラ予測手段を構成している。   The intra prediction unit 34 always performs an intra prediction process for generating a predicted image of a luminance signal, but for generating a predicted image of a chrominance signal, for each predicted block, an inter-color signal prediction flag of the predicted block. Is ON (when the execution of the inter-color signal prediction process is specified), the intra-prediction process is not performed, the encoded color signal is referred to, and the prediction image of the color difference signal in the prediction block is obtained. The prediction process between the color signals to be generated is performed. The intra prediction unit 34 constitutes an intra prediction unit.

イントラブロックコピー予測部35は可変長復号部31により可変長復号されたブロック分割情報から特定される符号化ブロックに係る符号化モードがイントラブロックコピー符号化モードである場合、その符号化ブロック内の予測ブロックが属している最大符号化ブロックの中で、未だ復号が済んでいない領域内の各画素の画素値を所定の方法で仮定する処理を実施する。
また、イントラブロックコピー予測部35は符号化ブロック内の予測ブロック毎に、同一のピクチャ内で既に復号が済んでいる領域の中から、当該予測ブロックと最も近似しているブロックである参照ブロックを探索して、その参照ブロックを当該予測ブロックの予測画像に決定する処理を実施する。
イントラブロックコピー予測部35は、輝度信号の予測画像の生成については常にイントラブロックコピー予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、当該予測ブロックの色信号間予測フラグがONである場合(色信号間予測処理の実施を明示している場合)、イントラブロックコピー予測処理を実施せずに、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。なお、イントラブロックコピー予測部35はイントラブロックコピー予測手段を構成している。
The intra block copy prediction unit 35, when the coding mode related to the coding block specified from the block division information variable-length decoded by the variable length decoding unit 31 is the intra block copy coding mode, In the maximum coding block to which the prediction block belongs, a process of assuming a pixel value of each pixel in a region not yet decoded by a predetermined method is performed.
In addition, the intra block copy prediction unit 35 selects, for each prediction block in the encoded block, a reference block that is a block that is closest to the prediction block from among regions that have already been decoded in the same picture. A process of searching and determining the reference block as a prediction image of the prediction block is performed.
The intra block copy prediction unit 35 always performs an intra block copy prediction process for the generation of a prediction image of a luminance signal, but for the generation of a prediction image of a color difference signal, the color of the prediction block is generated for each prediction block. When the inter-signal prediction flag is ON (when the execution of the inter-color signal prediction process is specified), the intra-block copy prediction process is not performed and the encoded color signal is referred to and An inter-color signal prediction process for generating a predicted image of the color difference signal is performed. The intra block copy prediction unit 35 constitutes an intra block copy prediction unit.

動き補償予測部36は可変長復号部31により可変長復号されたブロック分割情報から特定される符号化ブロックに係る符号化モードがインター符号化モードである場合、動き補償予測フレームメモリ40に格納されている復号画像を参照しながら、切換スイッチ33から出力された動きベクトルとインター予測パラメータを用いたインター予測処理(動き補償予測処理)を実施してインター予測画像を生成する処理を実施する。
動き補償予測部36は、輝度信号の予測画像の生成については常に動き補償予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、当該予測ブロックの色信号間予測フラグがONである場合(色信号間予測処理の実施を明示している場合)、動き補償予測処理を実施せずに、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。なお、動き補償予測部36は動き補償予測手段を構成している。
The motion compensation prediction unit 36 is stored in the motion compensation prediction frame memory 40 when the coding mode related to the coding block specified from the block division information variable-length decoded by the variable length decoding unit 31 is the inter coding mode. The inter prediction process (motion compensation prediction process) using the motion vector output from the changeover switch 33 and the inter prediction parameter is performed while referring to the decoded image, and the process of generating the inter prediction image is performed.
The motion compensation prediction unit 36 always performs motion compensation prediction processing for generating a prediction image of a luminance signal, but for generating a prediction image of a color difference signal, for each prediction block, between the color signals of the prediction block. When the prediction flag is ON (when the execution of the inter-color signal prediction process is clearly specified), the color difference signal in the prediction block is referred to by referring to the encoded color signal without performing the motion compensation prediction process. An inter-color signal prediction process for generating a predicted image is performed. The motion compensation prediction unit 36 constitutes a motion compensation prediction unit.

この実施の形態1では、可変長復号部31により可変長復号された色信号間予測パラメータに含まれている色信号間予測フラグがONである場合、イントラ予測部34、イントラブロックコピー予測部35又は動き補償予測部36のいずれかが色信号間予測処理を実施することを想定しているが、色信号間予測処理を実施する予測部を別途設けるようにしてもよい。
また、この実施の形態1では、色信号間予測パラメータに含まれている色信号間予測フラグを参照して、色信号間予測処理の実施の有無を選択しているが、図1の画像符号化装置が、符号化ブロック単位あるいは最大サイズの符号化ブロック単位でフラグを符号化している場合、対応する画像復号装置では、図1の画像符号化装置と同じ単位でフラグを復号することで、図1の画像符号化装置と同じ単位に、色信号間予測処理の実施の有無を識別する。このようにすることで、正しく符号化パラメータを復号することができる。
あるいは、図1の画像符号化装置が、変換ブロック単位に色信号間予測フラグを符号化するように構成している場合、対応する画像復号装置も変換ブロック単位の色信号間予測フラグを復号するように構成する。このとき、予測ブロックの中に複数の変換ブロックが存在する場合は上記色信号間予測フラグがONの変換ブロックのみ色信号間予測を実施し、上記色信号間予測フラグがOFFの変換ブロックでは色差信号に対するイントラ予測、イントラブロックコピー予測あるいは動き補償予測を行う。
また、色信号間予測フラグは、図1の画像符号化装置が2つの色差信号(U、V信号)で共通とするように構成する場合、画像復号装置では、可変長復号部31により2つの色差信号(U、V信号)で共通のフラグを復号する。
一方、図1の画像符号化装置がU信号とV信号で独立に色信号間予測フラグを持つように構成する場合、画像復号装置では、可変長復号部31によりU信号のフラグとV信号のフラグを別々に復号する。このようにすることで正しく符号化パラメータを復号することができる。
In the first embodiment, when the inter-color signal prediction flag included in the inter-color signal prediction parameter subjected to variable length decoding by the variable length decoding unit 31 is ON, the intra prediction unit 34 and the intra block copy prediction unit 35. Alternatively, it is assumed that one of the motion compensation prediction units 36 performs the inter-color signal prediction process, but a prediction unit that performs the inter-color signal prediction process may be separately provided.
In the first embodiment, whether or not the inter-color signal prediction process is performed is selected with reference to the inter-color signal prediction flag included in the inter-color signal prediction parameter. When the encoding device encodes the flag in units of the encoding block or the encoding block of the maximum size, the corresponding image decoding device decodes the flag in the same unit as the image encoding device in FIG. Whether or not the inter-color signal prediction process is performed is identified in the same unit as that of the image encoding device in FIG. In this way, it is possible to correctly decode the encoding parameter.
Alternatively, when the image encoding device in FIG. 1 is configured to encode the inter-color signal prediction flag in units of transform blocks, the corresponding image decoding device also decodes the inter-color signal prediction flag in units of transform blocks. Configure as follows. At this time, when there are a plurality of conversion blocks in the prediction block, the inter-color signal prediction is performed only for the conversion block in which the inter-color signal prediction flag is ON, and the color difference is calculated in the conversion block in which the inter-color signal prediction flag is OFF Intra prediction, intra block copy prediction, or motion compensation prediction is performed on the signal.
Further, when the image coding apparatus in FIG. 1 is configured to be common to two color difference signals (U and V signals), the image decoding apparatus uses two variable-length decoding units 31 to generate two inter-color signal prediction flags. The common flag is decoded with the color difference signals (U and V signals).
On the other hand, when the image coding apparatus of FIG. 1 is configured to have the inter-color signal prediction flag independently for the U signal and the V signal, in the image decoding apparatus, the variable length decoding unit 31 causes the U signal flag and the V signal Decrypt flags separately. In this way, the encoding parameter can be correctly decoded.

加算部37は逆量子化・逆変換部32により算出された復号予測差分信号と、イントラ予測部34により生成されたイントラ予測画像、イントラブロックコピー予測部35により生成されたイントラブロックコピー予測画像、又は、動き補償予測部36により生成されたインター予測画像とを加算して、図1の加算部11から出力された局所復号画像と同一の復号画像を算出する処理を実施する。   The addition unit 37 includes a decoded prediction difference signal calculated by the inverse quantization / inverse conversion unit 32, an intra prediction image generated by the intra prediction unit 34, an intra block copy prediction image generated by the intra block copy prediction unit 35, Or the inter prediction image produced | generated by the motion compensation prediction part 36 is added, and the process which calculates the decoding image same as the local decoding image output from the addition part 11 of FIG. 1 is implemented.

イントラ用メモリ38は加算部37により算出された復号画像をイントラ予測処理及びイントラブロックコピー予測処理で用いる参照画像として格納する記録媒体である。
ループフィルタ部39は加算部37により算出された復号画像に対して、所定のフィルタ処理を実施して、フィルタ処理後の復号画像を出力する処理を実施する。
具体的には、変換ブロックの境界や予測ブロックの境界に発生する歪みを低減するフィルタ(デブロッキングフィルタ)処理、画素単位に適応的にオフセットを加算する(画素適応オフセット)処理、ウィーナフィルタ等の線形フィルタを適応的に切り替えてフィルタ処理する適応フィルタ処理などを行う。
ただし、ループフィルタ部39は、上記のデブロッキングフィルタ処理、画素適応オフセット処理、適応フィルタ処理のそれぞれについて、可変長復号部31により可変長復号された各ヘッダ情報を参照して、当該スライスで行うか否かを特定する。
このとき、2つ以上のフィルタ処理を行う場合において、例えば、画像符号化装置のループフィルタ部13が図11のように構成されていれば、図12に示すようにループフィルタ部39が構成される。当然、画像符号化装置のループフィルタ部13がデブロッキングフィルタ処理と画素適応オフセット処理から構成されていれば、ループフィルタ部39もデブロッキングフィルタ処理と画素適応オフセット処理で構成される。
The intra memory 38 is a recording medium that stores the decoded image calculated by the adding unit 37 as a reference image used in the intra prediction process and the intra block copy prediction process.
The loop filter unit 39 performs a predetermined filter process on the decoded image calculated by the adder unit 37 and performs a process of outputting the decoded image after the filter process.
Specifically, filter (deblocking filter) processing that reduces distortion occurring at the boundaries of transform blocks and prediction blocks, processing for adaptively adding an offset (pixel adaptive offset) for each pixel, Wiener filter, etc. Performs adaptive filter processing for adaptively switching linear filters and performing filter processing.
However, the loop filter unit 39 performs each of the above deblocking filter processing, pixel adaptive offset processing, and adaptive filter processing with reference to each header information variable-length decoded by the variable-length decoding unit 31 in the corresponding slice. Specify whether or not.
At this time, when two or more filter processes are performed, for example, if the loop filter unit 13 of the image encoding device is configured as shown in FIG. 11, a loop filter unit 39 is configured as shown in FIG. The Naturally, if the loop filter unit 13 of the image encoding device is configured by deblocking filter processing and pixel adaptive offset processing, the loop filter unit 39 is also configured by deblocking filter processing and pixel adaptive offset processing.

ここで、デブロッキングフィルタ処理では、可変長復号部31により可変長復号されたヘッダ情報を参照し、ブロック境界にかけるフィルタ強度の選択に用いる各種パラメータを初期値から変更する情報が存在する場合、その変更情報に基づいて、デブロッキングフィルタ処理を実施する。変更情報がない場合は、予め定められた手法に従って行う。   Here, in the deblocking filter processing, with reference to the header information that has been subjected to variable length decoding by the variable length decoding unit 31, there is information for changing various parameters used for selecting the filter strength applied to the block boundary from the initial value. Based on the change information, deblocking filter processing is performed. When there is no change information, it is performed according to a predetermined method.

画素適応オフセット処理では、可変長復号部31により可変長復号された画素適応オフセット処理のブロック分割情報に基づいて復号画像を分割し、そのブロック単位に、可変長復号部31により可変長復号されたブロック単位のクラス分類手法を示すインデックスを参照して、そのインデックスが“オフセット処理を行わない”ことを示すインデックスでない場合、ブロック単位にブロック内の各画素を上記インデックスが示すクラス分類手法に従ってクラス分類する。
なお、クラス分類手法の候補として、ループフィルタ部13の画素適応オフセット処理のクラス分類手法の候補と同一のものが予め用意されている。
そして、ブロック単位の各クラスのオフセット値を特定するオフセット情報を参照して、復号画像の画素値にオフセットを加算する処理を行う。
In the pixel adaptive offset processing, the decoded image is divided based on the block division information of the pixel adaptive offset processing variable-length decoded by the variable-length decoding unit 31, and the variable-length decoding unit 31 performs variable-length decoding on the block basis. If the index indicating the block classification method is not an index indicating that “offset processing is not performed”, each pixel in the block is classified according to the class classification method indicated by the index. To do.
Note that the same class classification method candidates as those for the pixel adaptive offset processing class classification method of the loop filter unit 13 are prepared in advance.
Then, a process of adding the offset to the pixel value of the decoded image is performed with reference to the offset information specifying the offset value of each class in block units.

ただし、画像符号化装置のループフィルタ部13の画素適応オフセット処理において、ブロック分割情報は符号化せずに、常に画像を固定サイズのブロック単位(例えば、最大符号化ブロック単位)に分割し、そのブロック毎にクラス分類手法を選択して、クラス毎の適応オフセット処理を行うように構成されている場合、ループフィルタ部39においても、ループフィルタ部13と同一の固定サイズのブロック単位に画素適応オフセット処理を実施する。   However, in the pixel adaptive offset processing of the loop filter unit 13 of the image encoding device, the block division information is not encoded, and the image is always divided into fixed-size block units (for example, the maximum encoded block unit). When a class classification method is selected for each block and adaptive offset processing for each class is performed, the loop filter unit 39 also has a pixel adaptive offset in units of blocks having the same fixed size as the loop filter unit 13. Perform the process.

適応フィルタ処理では、可変長復号部31により可変長復号されたクラス毎のフィルタを用いて、図1の画像符号化装置と同一の手法でクラス分類した後に、そのクラス分類情報に基づいてフィルタ処理を行う。
動き補償予測フレームメモリ40はループフィルタ部39のフィルタ処理後の復号画像をインター予測処理(動き補償予測処理)で用いる参照画像として格納する記録媒体である。
In the adaptive filter process, after classifying by the same method as the image encoding apparatus of FIG. 1 using the filter for each class variable-length decoded by the variable-length decoding unit 31, the filter process is performed based on the class classification information. I do.
The motion compensation prediction frame memory 40 is a recording medium that stores the decoded image after the filter processing of the loop filter unit 39 as a reference image used in the inter prediction processing (motion compensation prediction processing).

図3の例では、画像復号装置の構成要素である可変長復号部31、逆量子化・逆変換部32、切換スイッチ33、イントラ予測部34、イントラブロックコピー予測部35、動き補償予測部36、加算部37、イントラ用メモリ38、ループフィルタ部39及び動き補償予測フレームメモリ40のそれぞれが専用のハードウェアで構成(イントラ用メモリ38及び動き補償予測フレームメモリ40以外の構成要素は、例えば、CPUを実装している半導体集積回路や、ワンチップマイコンなどで構成)されているものを想定しているが、画像復号装置がコンピュータで構成されていてもよい。
画像復号装置をコンピュータで構成する場合、イントラ用メモリ38及び動き補償予測フレームメモリ40をコンピュータのメモリ上に構成するとともに、可変長復号部31、逆量子化・逆変換部32、切換スイッチ33、イントラ予測部34、イントラブロックコピー予測部35、動き補償予測部36、加算部37及びループフィルタ部39の処理内容を記述しているプログラムをコンピュータのメモリに格納し、当該コンピュータのCPUが当該メモリに格納されているプログラムを実行するようにすればよい。
図4はこの発明の実施の形態1による画像復号装置の処理内容(画像復号方法)を示すフローチャートである。
In the example of FIG. 3, a variable length decoding unit 31, an inverse quantization / inverse conversion unit 32, a changeover switch 33, an intra prediction unit 34, an intra block copy prediction unit 35, and a motion compensation prediction unit 36 that are components of the image decoding device. Each of the adder 37, the intra memory 38, the loop filter unit 39, and the motion compensated prediction frame memory 40 is configured by dedicated hardware (components other than the intra memory 38 and the motion compensated prediction frame memory 40 are, for example, It is assumed that the CPU is mounted on a semiconductor integrated circuit or a one-chip microcomputer), but the image decoding apparatus may be configured by a computer.
When the image decoding device is configured by a computer, the intra memory 38 and the motion compensated prediction frame memory 40 are configured on the computer memory, and a variable length decoding unit 31, an inverse quantization / inverse conversion unit 32, a changeover switch 33, A program describing the processing contents of the intra prediction unit 34, the intra block copy prediction unit 35, the motion compensation prediction unit 36, the addition unit 37, and the loop filter unit 39 is stored in the memory of the computer, and the CPU of the computer stores the memory. The program stored in the program may be executed.
FIG. 4 is a flowchart showing the processing contents (image decoding method) of the image decoding apparatus according to Embodiment 1 of the present invention.

次に動作について説明する。
この実施の形態1では、映像の各フレーム画像を入力画像として、符号化済みの近傍画素からのイントラ予測又は近接フレーム間での動き補償予測を実施して、得られた予測差分信号に対して直交変換・量子化による圧縮処理を施し、その後、可変長符号化を行って符号化ビットストリームを生成する画像符号化装置と、その画像符号化装置から出力される符号化ビットストリームを復号する画像復号装置について説明する。
Next, the operation will be described.
In the first embodiment, each frame image of a video is used as an input image, intra prediction from encoded neighboring pixels or motion compensation prediction between adjacent frames is performed, and an obtained prediction difference signal is obtained. An image encoding device that performs compression processing by orthogonal transform / quantization and then performs variable length encoding to generate an encoded bitstream, and an image that decodes the encoded bitstream output from the image encoding device A decoding apparatus will be described.

図1の画像符号化装置は、映像信号の空間・時間方向の局所的な変化に適応して、映像信号を多様なサイズのブロックに分割して、フレーム内・フレーム間適応符号化を行うことを特徴としている。
一般的に、映像信号は、空間・時間的に信号の複雑さが局所的に変化する特性を有している。空間的に見ると、ある映像フレーム上では、例えば、空や壁などのような比較的広い画像領域中で均一な信号特性を有する絵柄もあれば、人物や細かいテクスチャを含む絵画など、小さい画像領域内で複雑なテクスチャパターンを有する絵柄も混在することがある。
時間的に見ても、空や壁は局所的に時間方向の絵柄の変化は小さいが、動く人物や物体は、その輪郭が時間的に剛体・非剛体の運動をするため、時間的な変化が大きい。
The image encoding apparatus in FIG. 1 performs intra-frame and inter-frame adaptive encoding by dividing a video signal into blocks of various sizes in response to local changes in the spatial and temporal directions of the video signal. It is characterized by.
In general, a video signal has a characteristic that the complexity of the signal changes locally in space and time. When viewed spatially, a small image, such as a picture with a uniform signal characteristic in a relatively wide image area such as the sky or a wall, or a picture containing a person or fine texture, on a video frame. A pattern having a complicated texture pattern in the region may be mixed.
Even when viewed temporally, the change in the pattern of the sky and the wall locally in the time direction is small, but because the outline of the moving person or object moves rigidly or non-rigidly in time, the temporal change Is big.

符号化処理は、時間・空間的な予測によって、信号電力やエントロピーの小さい予測差分信号を生成して、全体の符号量を削減する処理を行うが、予測に用いるパラメータをできるだけ大きな画像信号領域に均一に適用できれば、当該パラメータの符号量を小さくすることができる。
一方、時間的・空間的に変化の大きい画像信号パターンに対して、同一の予測パラメータを大きな画像領域に適用すると、予測の誤りが増えてしまうため、予測差分信号の符号量が増加してしまう。
したがって、時間的・空間的に変化が大きい領域では、同一の予測パラメータを適用して予測処理を行うブロックサイズを小さくして、予測に用いるパラメータのデータ量を増やし、予測差分信号の電力・エントロピーを低減する方が望ましい。
In the encoding process, a prediction difference signal with small signal power and entropy is generated by temporal and spatial prediction to reduce the overall code amount. However, the parameters used for the prediction are set as large as possible in the image signal region. If it can be applied uniformly, the code amount of the parameter can be reduced.
On the other hand, if the same prediction parameter is applied to a large image region with respect to an image signal pattern having a large temporal and spatial change, the number of prediction differential signals increases because prediction errors increase. .
Therefore, in a region where the temporal and spatial changes are large, the block size for performing the prediction process by applying the same prediction parameter is reduced, the amount of parameter data used for prediction is increased, and the power and entropy of the prediction difference signal are increased. It is desirable to reduce

この実施の形態1では、このような映像信号の一般的な性質に適応した符号化を行うため、最初に所定の最大ブロックサイズから予測処理等を開始し、階層的に映像信号の領域を分割し、分割した領域毎に予測処理や、その予測差分の符号化処理を適応化させる構成をとるようにしている。   In the first embodiment, in order to perform coding adapted to the general characteristics of such a video signal, first, prediction processing or the like is started from a predetermined maximum block size, and the video signal region is divided hierarchically. In addition, the prediction process and the encoding process of the prediction difference are adapted for each divided area.

最初に、図1の画像符号化装置の処理内容を説明する。
まず、符号化制御部1は、符号化対象となるピクチャ(カレントピクチャ)のスライス分割状態を決めると共に、ピクチャの符号化に用いる最大符号化ブロックのサイズと、最大符号化ブロックを階層分割する階層数の上限を決定する(図2のステップST1)。
最大符号化ブロックのサイズの決め方としては、例えば、入力画像の映像信号の解像度に応じて、全てのピクチャに対して同一のサイズを定めてもよいし、入力画像の映像信号の局所的な動きの複雑さの違いをパラメータとして定量化して、動きの激しいピクチャには、小さいサイズを定める一方、動きが少ないピクチャには、大きいサイズを定めるようにしてもよい。
First, the processing contents of the image encoding device in FIG. 1 will be described.
First, the encoding control unit 1 determines the slice division state of a picture to be encoded (current picture), and the size of the maximum encoding block used for encoding the picture and the hierarchy for dividing the maximum encoding block into layers. The upper limit of the number is determined (step ST1 in FIG. 2).
As a method of determining the size of the maximum coding block, for example, the same size may be determined for all the pictures according to the resolution of the video signal of the input image, or the local motion of the video signal of the input image The size difference may be quantified as a parameter, and a small size may be determined for a picture with high motion, while a large size may be determined for a picture with little motion.

分割階層数の上限の決め方としては、例えば、入力画像の映像信号の解像度に応じて、全てのピクチャに対して同一の階層数を定める方法や、入力画像の映像信号の動きが激しい場合には、階層数を深くして、より細かい動きが検出できるように設定し、動きが少ない場合には、階層数を抑えるように設定する方法などがある。
なお、上記最大符号化ブロックのサイズと、最大符号化ブロックを階層分割する階層数の上限は、シーケンスレベルヘッダなどで符号化する。その場合、分割階層数の上限の代わりに、符号化ブロックの最小ブロックサイズを符号化するようにしてもよい。即ち、最大符号化ブロックを分割階層数の上限まで分割したときのブロックのサイズが、符号化ブロックの最小ブロックサイズであるため、画像復号装置側において、最大符号化ブロックのサイズと符号化ブロックの最小ブロックサイズから分割階層数の上限を特定することができる。
Examples of how to determine the upper limit of the number of division layers include, for example, a method of determining the same number of layers for all pictures according to the resolution of the video signal of the input image, or when the motion of the video signal of the input image is severe There is a method in which the number of hierarchies is increased so that finer movements can be detected, and when there are few movements, the number of hierarchies is set to be suppressed.
Note that the size of the maximum coding block and the upper limit of the number of hierarchies for dividing the maximum coding block into layers are coded by a sequence level header or the like. In that case, the minimum block size of the encoded block may be encoded instead of the upper limit of the number of division layers. That is, since the size of the block when the maximum encoded block is divided up to the upper limit of the number of division layers is the minimum block size of the encoded block, the size of the maximum encoded block and the size of the encoded block are determined on the image decoding device side. The upper limit of the number of divided hierarchies can be specified from the minimum block size.

また、符号化制御部1は、利用可能な1以上の符号化モードの中から、階層的に分割される各々の符号化ブロックに対応する符号化モードを選択する(ステップST2)。
即ち、符号化制御部1は、最大符号化ブロックサイズの画像領域毎に、先に定めた分割階層数の上限に至るまで、階層的に符号化ブロックサイズを有する符号化ブロックに分割して、各々の符号化ブロックに対する符号化モードを決定する。
符号化モードには、1つないし複数のイントラ符号化モード(総称して「INTRA」と称する)と、1つないし複数のイントラブロックコピー符号化モード(総称して「ICOPY」と称する)と、1つないし複数のインター符号化モード(総称して、「INTER」と称する)とがあり、符号化制御部1は、当該ピクチャで利用可能な全ての符号化モード、又は、そのサブセットの中から、各々の符号化ブロックに対応する符号化モードを選択する。
Also, the encoding control unit 1 selects an encoding mode corresponding to each encoding block divided hierarchically from one or more available encoding modes (step ST2).
That is, the encoding control unit 1 divides the image area of the maximum encoding block size into encoded blocks having the encoding block size hierarchically until reaching the upper limit of the number of division layers defined above. A coding mode for each coding block is determined.
The coding modes include one or more intra coding modes (collectively referred to as “INTRA”), one or more intra block copy coding modes (collectively referred to as “ICOPY”), There are one or a plurality of inter coding modes (collectively referred to as “INTER”), and the coding control unit 1 can select from all the coding modes available in the picture or a subset thereof. The encoding mode corresponding to each encoding block is selected.

ただし、後述するブロック分割部3により階層的に分割される各々の符号化ブロックは、さらに予測処理を行う単位である1つないし複数の予測ブロックに分割され、予測ブロックの分割状態も符号化モードの中に情報として含まれる。即ち、符号化モードは、どのような予測ブロック分割を持つイントラ符号化モード、イントラブロックコピー符号化モード又はインター符号化モードかを識別するインデックスである。
符号化制御部1による符号化モードの選択方法は、公知の技術であるため詳細な説明を省略するが、例えば、利用可能な任意の符号化モードを用いて、符号化ブロックに対する符号化処理を実施して符号化効率を検証し、利用可能な複数の符号化モードの中で、最も符号化効率がよい符号化モードを選択する方法などがある。
However, each coding block that is hierarchically divided by the block division unit 3 to be described later is further divided into one or a plurality of prediction blocks, which are units for performing prediction processing, and the division state of the prediction block is also coded mode. Is included as information. That is, the coding mode is an index for identifying what kind of prediction block division the intra coding mode, intra block copy coding mode, or inter coding mode is.
Since the encoding mode selection method by the encoding control unit 1 is a known technique, a detailed description thereof will be omitted. For example, an encoding process for an encoding block is performed using any available encoding mode. There is a method in which coding efficiency is verified by performing and a coding mode having the best coding efficiency is selected from among a plurality of available coding modes.

また、符号化制御部1は、各々の符号化ブロック毎に、差分画像が圧縮される際に用いられる量子化パラメータ及び変換ブロック分割状態を決定するとともに、予測処理が実施される際に用いられる予測パラメータ(イントラ予測パラメータ、イントラブロックコピー予測パラメータ、インター予測パラメータ又は色信号間予測パラメータ)を決定する。
ただし、符号化ブロックがさらに予測処理を行う予測ブロック単位に分割される場合は、予測ブロック毎に予測パラメータ(イントラ予測パラメータ、イントラブロックコピー予測パラメータ、インター予測パラメータ又は色信号間予測パラメータ)を選択する。
The encoding control unit 1 determines a quantization parameter and a transform block division state used when the differential image is compressed for each encoding block, and is used when the prediction process is performed. A prediction parameter (intra prediction parameter, intra block copy prediction parameter, inter prediction parameter, or inter-color signal prediction parameter) is determined.
However, when the encoded block is further divided into prediction block units for further prediction processing, a prediction parameter (intra prediction parameter, intra block copy prediction parameter, inter prediction parameter, or inter-color signal prediction parameter) is selected for each prediction block. To do.

ここで、図20は4:2:0フォーマットの信号における輝度信号及び色差信号の圧縮処理(変換処理、量子化処理)を実施する際の変換ブロックサイズを示す説明図である。
変換ブロックサイズは、図20に示すように、符号化ブロックを四分木状に階層分割することによって決定される。
例えば、変換ブロックを分割する場合と変換ブロックを分割しない場合での符号量や、符号化誤差を加味した評価尺度などに基づいて、評価値が最小になるように変換ブロックを分割するか否かを決定することで、符号量と符号化誤差のトレードオフの観点から最適な変換ブロックの分割形状を決定することができる。
Here, FIG. 20 is an explanatory diagram showing a conversion block size when performing compression processing (conversion processing, quantization processing) of luminance signals and color difference signals in a 4: 2: 0 format signal.
As shown in FIG. 20, the transform block size is determined by hierarchically dividing the encoded block into a quadtree.
For example, whether or not to divide the transform block so that the evaluation value is minimized based on the amount of code when the transform block is divided and when the transform block is not divided, the evaluation scale that takes into account the coding error, etc. By determining, it is possible to determine the optimal division shape of the transform block from the viewpoint of the trade-off between the code amount and the coding error.

輝度信号については、例えば、図20に示すように、符号化ブロックが1つ又は複数の正方形の変換ブロックに階層的に分割されるように構成する。
色差信号については、図20に示すように、入力信号フォーマットがYUV4:2:0信号である場合、輝度信号と同様に、符号化ブロックが1つ又は複数の正方形の変換ブロックに階層的に分割されるように構成する。この場合、色差信号の変換ブロックサイズは、対応する輝度信号の変換ブロックの縦横ともに半分のサイズとなる。
For example, as shown in FIG. 20, the luminance signal is configured so that the coding block is hierarchically divided into one or a plurality of square transform blocks.
For the color difference signal, as shown in FIG. 20, when the input signal format is a YUV 4: 2: 0 signal, the encoding block is hierarchically divided into one or a plurality of square transform blocks in the same manner as the luminance signal. To be configured. In this case, the conversion block size of the color difference signal is half the vertical and horizontal sizes of the corresponding luminance signal conversion block.

入力信号フォーマットがYUV4:2:2信号である場合、図21に示すように、輝度信号と同様の四分木状の階層分割を行う。また、分割したブロックの形状が、垂直方向の画素数が水平方向の画素数の2倍になる長方形となるため、さらに、分割したブロックを上下に二分することで、YUV4:2:0信号での色差信号と同じブロックサイズ(輝度信号の変換ブロックの縦横ともに半分のサイズ)の変換ブロック2つで構成するようにする。
また、入力信号フォーマットがYUV4:4:4信号である場合、図22に示すように、色差信号の変換ブロックは、常に輝度信号の変換ブロックと同様の分割を行い、同じサイズの変換ブロックとなるように構成する。
When the input signal format is a YUV 4: 2: 2 signal, quadtree-like hierarchical division similar to the luminance signal is performed as shown in FIG. In addition, the shape of the divided block is a rectangle in which the number of pixels in the vertical direction is twice the number of pixels in the horizontal direction. The color difference signal is composed of two conversion blocks having the same block size (half the vertical and horizontal sizes of the luminance signal conversion block).
Further, when the input signal format is YUV 4: 4: 4 signal, as shown in FIG. 22, the color difference signal conversion block is always divided in the same manner as the luminance signal conversion block to be the same size conversion block. Configure as follows.

符号化制御部1は、符号化ブロックにおける変換ブロックの分割情報を示す変換ブロック分割情報や、変換係数の量子化を行う際の量子化ステップサイズを規定する量子化パラメータなどを含む予測差分符号化パラメータを変換・量子化部9、逆量子化・逆変換部10及び可変長符号化部15に出力する。
また、符号化制御部1は、符号化モードとして、イントラ予測モードを選択している場合、輝度信号については輝度信号のイントラ予測パラメータをイントラ予測部5に出力し、色差信号については、色信号間予測処理を実施するか否かの色信号間予測フラグを含む色信号間予測パラメータをイントラ予測部5に出力する。さらに、上記色信号間予測フラグがOFFである場合、色差信号のイントラ予測パラメータをイントラ予測部5に出力する。
ただし、常に輝度信号と色差信号で共通のイントラ予測パラメータを用いるように画像符号化装置を構成する場合、色差信号のイントラ予測パラメータはイントラ予測部5に出力する必要はない。
The encoding control unit 1 includes predictive differential encoding including transform block partition information indicating transform block partition information in a block to be encoded, a quantization parameter that defines a quantization step size when transform coefficients are quantized, and the like. The parameter is output to the transform / quantization unit 9, the inverse quantization / inverse transform unit 10, and the variable length coding unit 15.
Further, when the intra prediction mode is selected as the encoding mode, the encoding control unit 1 outputs the intra prediction parameters of the luminance signal to the intra prediction unit 5 for the luminance signal, and the color signal for the color difference signal. An inter-color signal prediction parameter including an inter-color signal prediction flag indicating whether or not to perform inter prediction processing is output to the intra prediction unit 5. Further, when the inter-color signal prediction flag is OFF, the intra prediction parameter of the color difference signal is output to the intra prediction unit 5.
However, when the image coding apparatus is configured to always use a common intra prediction parameter for the luminance signal and the color difference signal, it is not necessary to output the intra prediction parameter of the color difference signal to the intra prediction unit 5.

また、符号化制御部1は、符号化モードとして、イントラブロックコピー予測モードを選択している場合、輝度信号については輝度信号のイントラブロックコピー予測パラメータをイントラブロックコピー予測部6に出力し、色差信号については、色信号間予測を実施するか否かの色信号間予測フラグを含む色信号間予測パラメータをイントラブロックコピー予測部6に出力する。さらに、上記色信号間予測フラグがOFFである場合、色差信号のイントラブロックコピー予測パラメータをイントラブロックコピー予測部6に出力する。
ただし、常に輝度信号と色差信号で共通のイントラブロックコピー予測パラメータを用いるように画像符号化装置を構成する場合、色差信号のイントラブロックコピー予測パラメータはイントラブロックコピー予測部6に出力する必要はない。
In addition, when the intra block copy prediction mode is selected as the encoding mode, the encoding control unit 1 outputs the intra block copy prediction parameter of the luminance signal to the intra block copy prediction unit 6 for the luminance signal, and the color difference For signals, the inter-color signal prediction parameters including the inter-color signal prediction flag indicating whether or not to perform inter-color signal prediction are output to the intra block copy prediction unit 6. Further, when the inter-color signal prediction flag is OFF, the intra block copy prediction parameter of the color difference signal is output to the intra block copy prediction unit 6.
However, when the image coding apparatus is configured to always use a common intra block copy prediction parameter for the luminance signal and the color difference signal, it is not necessary to output the intra block copy prediction parameter of the color difference signal to the intra block copy prediction unit 6. .

また、符号化制御部1は、符号化モードとして、インター予測モードを選択している場合、輝度信号については輝度信号のインター予測パラメータを動き補償予測部7に出力し、色差信号については、色信号間予測を実施するか否かの色信号間予測フラグを含む色信号間予測パラメータを動き補償予測部7に出力する。さらに、上記色信号間予測フラグがOFFである場合、色差信号のインター予測パラメータを動き補償予測部7に出力する。
ただし、常に輝度信号と色差信号で共通のインター予測パラメータを用いるように画像符号化装置を構成する場合、色差信号のインター予測パラメータは動き補償部7に出力する必要はない。
Also, when the inter prediction mode is selected as the encoding mode, the encoding control unit 1 outputs the inter prediction parameters of the luminance signal to the motion compensation prediction unit 7 for the luminance signal, and the color difference signal for the color difference signal. An inter-color signal prediction parameter including an inter-color signal prediction flag indicating whether or not to perform inter-signal prediction is output to the motion compensation prediction unit 7. Further, when the inter-color signal prediction flag is OFF, the inter prediction parameter of the color difference signal is output to the motion compensation prediction unit 7.
However, when the image coding apparatus is configured to always use a common inter prediction parameter for the luminance signal and the color difference signal, it is not necessary to output the inter prediction parameter of the color difference signal to the motion compensation unit 7.

スライス分割部2は、入力画像として映像信号を入力すると、その入力画像を符号化制御部1により決定されたスライス分割情報にしたがって1以上の部分画像であるスライスに分割する。
ブロック分割部3は、スライス分割部2から各スライスを入力する毎に、そのスライスを符号化制御部1により決定された最大符号化ブロックサイズに分割し、さらに、分割した最大符号化ブロックを符号化制御部1により決定された符号化ブロックへ階層的に分割して、その符号化ブロックを出力する。
When a video signal is input as an input image, the slice division unit 2 divides the input image into slices that are one or more partial images according to the slice division information determined by the encoding control unit 1.
Each time each slice is input from the slice dividing unit 2, the block dividing unit 3 divides the slice into the maximum encoded block size determined by the encoding control unit 1, and further encodes the divided maximum encoded block. The coding block is hierarchically divided into coding blocks determined by the coding control unit 1, and the coding blocks are output.

ここで、図5は最大符号化ブロックが階層的に複数の符号化ブロックに分割される例を示す説明図である。
図5において、最大符号化ブロックは、「第0階層」と記されている輝度成分が(L,M)のサイズを有する符号化ブロックである。
最大符号化ブロックを出発点として、4分木構造で別途定める所定の深さまで、階層的に分割を行うことによって符号化ブロックを得るようにしている。
深さnにおいては、符号化ブロックはサイズ(L,M)の画像領域である。
ただし、LとMは、同じであってもよいし、異なっていてもよいが、図5では、L=Mのケースを示している。
Here, FIG. 5 is an explanatory diagram showing an example in which the maximum coding block is hierarchically divided into a plurality of coding blocks.
In FIG. 5, the maximum coding block is a coding block whose luminance component described as “0th layer” has a size of (L 0 , M 0 ).
Starting from the maximum encoding block, the encoding block is obtained by performing hierarchical division to a predetermined depth separately defined by a quadtree structure.
At depth n, the coding block is an image area of size (L n , M n ).
However, L n and M n may be the same or different, but FIG. 5 shows a case of L n = M n .

以降、符号化制御部1により決定される符号化ブロックサイズは、符号化ブロックの輝度成分におけるサイズ(L,M)と定義する。
4分木分割を行うため、常に、(Ln+1,Mn+1)=(L/2,M/2)が成立する。
なお、RGB信号など、全ての色成分が同一サンプル数を有するカラー映像信号(4:4:4フォーマット)では、全ての色成分のサイズが(L,M)になるが、4:2:0フォーマットを扱う場合、対応する色差成分の符号化ブロックサイズは(L/2,M/2)になる。
Hereinafter, the coding block size determined by the coding control unit 1 is defined as the size (L n , M n ) in the luminance component of the coding block.
Since quadtree partitioning is performed, (L n + 1 , M n + 1 ) = (L n / 2, M n / 2) always holds.
Note that in a color video signal (4: 4: 4 format) in which all color components have the same number of samples, such as RGB signals, the size of all color components is (L n , M n ), but 4: 2. : When the 0 format is handled, the encoding block size of the corresponding color difference component is (L n / 2, M n / 2).

以降、第n階層の符号化ブロックをBで表し、符号化ブロックBで選択可能な符号化モードをm(B)で表すものとする。
複数の色成分からなるカラー映像信号の場合、符号化モードm(B)は、色成分毎に、それぞれ個別のモードを用いるように構成されてもよいし、全ての色成分に対し共通のモードを用いるように構成されてもよい。以降、特に断らない限り、YUV信号、4:2:0フォーマットの符号化ブロックの輝度成分に対する符号化モードを指すものとして説明を行う。
Hereinafter, the coding block of the n hierarchy expressed in B n, denote the encoding modes selectable by the coding block B n with m (B n).
In the case of a color video signal composed of a plurality of color components, the encoding mode m (B n ) may be configured to use an individual mode for each color component, or common to all color components. It may be configured to use a mode. Hereinafter, unless otherwise specified, description will be made assuming that it indicates a coding mode for a luminance component of a coding block of a YUV signal and 4: 2: 0 format.

符号化ブロックBは、図5に示すように、ブロック分割部3によって、予測処理単位を表す1つないし複数の予測ブロックに分割される。
以降、符号化ブロックBに属する予測ブロックをP (iは、第n階層における予測ブロック番号)と表記する。図5にはP とP の例を示している。
符号化ブロックB内の予測ブロックの分割が、どのようになされているかは、符号化モードm(B)の中に情報として含まれる。
予測ブロックP は、全て符号化モードm(B)に従って予測処理が行われるが、予測ブロックP 毎に、個別の予測パラメータ(イントラ予測パラメータ、イントラブロックコピー予測パラメータ又はインター予測パラメータ)を選択することができる。
As shown in FIG. 5, the encoded block B n is divided by the block dividing unit 3 into one or a plurality of prediction blocks representing a prediction processing unit.
Hereinafter, a prediction block belonging to the coding block B n is denoted as P i n (i is a prediction block number in the n-th layer). FIG. 5 shows an example of P 0 0 and P 1 0 .
How the prediction block is divided in the coding block Bn is included as information in the coding mode m ( Bn ).
All prediction blocks P i n are subjected to prediction processing according to the encoding mode m (B n ), but for each prediction block P i n , individual prediction parameters (intra prediction parameters, intra block copy prediction parameters, or inter prediction parameters) are used. ) Can be selected.

符号化制御部1は、最大符号化ブロックに対して、例えば、図6に示すようなブロック分割状態を生成して、符号化ブロックを特定する。
図6(a)の点線で囲まれた矩形が各符号化ブロックを表し、各符号化ブロック内にある斜線で塗られたブロックが各予測ブロックの分割状態を表している。
図6(b)は、図6(a)の例について、階層分割によって符号化モードm(B)が割り当てられる状況を4分木グラフで示したものである。図6(b)の□で囲まれているノードは、符号化モードm(B)が割り当てられたノード(符号化ブロック)である。
この4分木グラフの情報は符号化モードm(B)と共に符号化制御部1から可変長符号化部15に出力されて、ビットストリームに多重化される。
For example, the encoding control unit 1 generates a block division state as illustrated in FIG. 6 for the maximum encoding block, and identifies the encoding block.
A rectangle surrounded by a dotted line in FIG. 6A represents each coding block, and a block painted with diagonal lines in each coding block represents a division state of each prediction block.
FIG. 6B shows, in a quadtree graph, a situation in which the encoding mode m (B n ) is assigned by hierarchical division in the example of FIG. 6A. Nodes surrounded by squares in FIG. 6B are nodes (encoding blocks) to which the encoding mode m (B n ) is assigned.
Information of the quadtree graph is output from the encoding control unit 1 to the variable length encoding unit 15 together with the encoding mode m (B n ), and is multiplexed into the bit stream.

切換スイッチ4は、符号化制御部1により決定された符号化モードm(B)がイントラ符号化モードである場合(m(B)∈INTRAの場合)、ブロック分割部3から出力された符号化ブロックBをイントラ予測部5に出力し、符号化制御部1により決定された符号化モードm(B)がイントラブロックコピー符号化モードである場合(m(B)∈ICOPYの場合)、ブロック分割部3から出力された符号化ブロックBをイントラブロックコピー予測部6に出力し、符号化制御部1により決定された符号化モードm(B)がインター符号化モードである場合(m(B)∈INTERの場合)、ブロック分割部3から出力された符号化ブロックBを動き補償予測部7に出力する。 The changeover switch 4 is output from the block dividing unit 3 when the coding mode m (B n ) determined by the coding control unit 1 is an intra coding mode (when m (B n ) ∈INTRA). When the coding block B n is output to the intra prediction unit 5 and the coding mode m (B n ) determined by the coding control unit 1 is the intra block copy coding mode (m (B n ) ∈ICOPY The encoding block B n output from the block division unit 3 is output to the intra block copy prediction unit 6, and the encoding mode m (B n ) determined by the encoding control unit 1 is the inter encoding mode. In some cases (when m (B n ) εINTER), the encoded block B n output from the block dividing unit 3 is output to the motion compensation prediction unit 7.

イントラ予測部5は、符号化制御部1により決定された符号化モードm(B)がイントラ符号化モードであり(m(B)∈INTRAの場合)、切換スイッチ4から符号化ブロックBを受けると(ステップST3)、イントラ用メモリ12に格納されている局所復号画像を参照しながら、符号化制御部1により決定されたイントラ予測パラメータを用いて、その符号化ブロックB内の各予測ブロックP に対するイントラ予測処理を実施して、イントラ予測画像PINTRAi を生成する(ステップST4)。 In the intra prediction unit 5, the coding mode m (B n ) determined by the coding control unit 1 is an intra coding mode (when m (B n ) ∈INTRA), and the coding block B is changed from the changeover switch 4 to the coding block B. n (step ST3), using the intra prediction parameters determined by the encoding control unit 1 while referring to the local decoded image stored in the intra memory 12, the encoding block Bn and implementing intra prediction process for each of the prediction block P i n, generates an intra prediction image P INTRAi n (step ST4).

ただし、詳細は後述するが、イントラ予測画像を生成する処理を行う際に、予測ブロックに隣接する符号化済みの画素を用いることから、イントラ予測画像を生成する処理は、予測処理に用いる予測ブロックに隣接する画素が既に符号化済みとなるように常に変換ブロック単位に行われなくてはならない。
したがって、符号化モードがイントラ符号化モードである符号化ブロックでは、選択可能な変換ブロックのブロックサイズは、予測ブロックのサイズ以下に制限され、さらに、変換ブロックが予測ブロックより小さい場合(予測ブロック内に複数の変換ブロックが存在する場合)には、変換ブロック単位に、当該予測ブロックで定められたイントラ予測パラメータを用いたイントラ予測処理を実施してイントラ予測画像を生成する処理を実施する。
なお、画像復号装置がイントラ予測画像PINTRAi と全く同じイントラ予測画像を生成する必要があるため、イントラ予測画像PINTRAi の生成に用いられたイントラ予測パラメータは、符号化制御部1から可変長符号化部15に出力されて、ビットストリームに多重化される。
イントラ予測部5におけるイントラ予測処理の詳細は後述する。
However, although details will be described later, since the encoded pixel adjacent to the prediction block is used when performing the process of generating the intra prediction image, the process of generating the intra prediction image is the prediction block used for the prediction process. Must always be performed in units of transform blocks so that pixels adjacent to are already encoded.
Therefore, in a coding block in which the coding mode is the intra coding mode, the block size of the selectable transform block is limited to the size of the prediction block or smaller and the transform block is smaller than the prediction block (in the prediction block). In the case where there are a plurality of transform blocks, the intra prediction process using the intra prediction parameters defined in the prediction block is performed for each transform block to generate an intra predicted image.
Since the image decoding apparatus needs to generate exactly the same intra prediction image and the intra prediction image P INTRAi n, intra prediction parameters used for generating the intra prediction image P INTRAi n is a variable from the coding controller 1 The data is output to the long encoding unit 15 and multiplexed into a bit stream.
Details of the intra prediction processing in the intra prediction unit 5 will be described later.

イントラ予測部5は、輝度信号の予測画像の生成については常にイントラ予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、符号化制御部1により当該予測ブロックの色信号間予測フラグがONに設定されている場合、イントラ予測処理を実施せずに、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。一方、符号化制御部1により当該予測ブロックの色信号間予測フラグがOFFに設定されている場合は、色差信号もイントラ予測処理を実施する。   The intra prediction unit 5 always performs an intra prediction process for the generation of a prediction image of a luminance signal, but for the generation of a prediction image of a color difference signal, the encoding control unit 1 performs the prediction block on each prediction block. When the inter-color signal prediction flag is set to ON, the intra-color signal prediction that generates the prediction image of the color difference signal in the prediction block with reference to the encoded color signal without performing the intra prediction process Perform the process. On the other hand, when the inter-color signal prediction flag of the prediction block is set to OFF by the encoding control unit 1, the color difference signal is also subjected to the intra prediction process.

イントラブロックコピー予測部6は、符号化制御部1により決定された符号化モードm(B)がイントラブロックコピー符号化モードであり(m(B)∈ICOPYの場合)、切換スイッチ4から符号化ブロックBを受けると(ステップST3)、その符号化ブロックB内の各予測ブロックP とイントラ用メモリ12に格納されている局所復号画像を比較してブロックシフトベクトルを探索する。
即ち、イントラブロックコピー予測部6は、イントラ用メモリ12に格納されている局所復号画像の中で、予測ブロックP と最も近似している領域のブロック(参照ブロック)を特定して、その参照ブロックを指し示すブロックシフトベクトルを探索する。
イントラブロックコピー予測部6は、参照ブロックを指し示すブロックシフトベクトルを探索すると、そのブロックシフトベクトルが指し示す参照ブロックを予測ブロックP の予測画像として、イントラブロックコピー予測画像PICOPYi を生成する(ステップST5)。
The intra block copy prediction unit 6 is the intra block copy encoding mode when the encoding mode m (B n ) determined by the encoding control unit 1 is m (B n ) ∈ICOPY, and When the encoded block B n is received (step ST3), each prediction block P i n in the encoded block B n is compared with the locally decoded image stored in the intra memory 12 to search for a block shift vector. .
That is, the intra block copy prediction unit 6, in the local decoded image stored in the intra-memory 12, to identify the block (reference block) in the region which is the most approximate to the prediction block P i n, that Search for a block shift vector pointing to the reference block.
Intra block copy prediction unit 6, when searching for a block shift vector pointing to the reference block, the reference block whose block shift vector is pointing as the predicted image of the prediction block P i n, generates an intra block copy predicted image P ICOPYi n ( Step ST5).

ただし、図32に示すように、予測ブロックP と最も近似している領域が未符号化領域(未だ符号化が行われておらず、局所復号が済んでいない領域であり、図32では斜線の領域及び予測ブロックP が該当する)を跨ぐ位置に存在しているような場合には、予測ブロックP と同じサイズの参照ブロックが、局所復号が済んでいない画素を含んでしまうため、通常のイントラブロックコピー予測処理では、当該参照ブロックを指し示すブロックシフトベクトルを選択することができない。
そこで、この実施の形態1では、予測ブロックPinと最も近似している参照ブロックが未符号化領域の一部を含んでしまう場合でも、その参照ブロックを指し示すブロックシフトベクトルを探索することができるようにするために、図33に示すように、事前に、予測ブロックが属している符号化対象の最大符号化ブロック(当該最大符号化ブロック)の中で、未符号化領域内の各画素の画素値を所定の方法で仮定する処理を実施する(所定の手法で定まる画素値で未符号化領域内の画素を埋める処理を実施する)。
However, as shown in FIG. 32, the prediction block P i n a not closest to that region is performed is unencoded area (still encoding an area have not yet locally decoded, in FIG. 32 If shaded areas and the prediction block P i n is as present in a position straddling the applicable), the reference blocks of the same size as the prediction block P i n is, contains pixels which have not yet locally decoded Therefore, in the normal intra block copy prediction process, a block shift vector indicating the reference block cannot be selected.
Therefore, in the first embodiment, even when the reference block closest to the prediction block Pin includes a part of the uncoded region, it is possible to search for a block shift vector indicating the reference block. In order to achieve this, as shown in FIG. 33, the pixels of each pixel in the unencoded area in the maximum encoding block to be encoded to which the prediction block belongs (the maximum encoding block) in advance. A process of assuming a value by a predetermined method is performed (a process of filling a pixel in an unencoded area with a pixel value determined by a predetermined method).

具体的には、以下の(1)から(3)のいずれかの手法によって、未符号化領域内の各画素の画素値を仮定する。なお、下記では画素値の取り得る範囲を8ビット精度である0〜255として説明するが、10ビットや12ビット等、8ビット精度でない場合も同様の手法で処理を行う。即ち、10ビット精度であれば、画素値の取り得る範囲を0〜1023、12ビット精度であれば、画素値の取り得る範囲を0〜4095として扱う。さらに、画素値の取り得る値が符号付きである場合も同様の処理を行う(例えば、8ビット精度で取り得る値が−123〜122である場合)。
また、以下の手法は、各色信号(輝度信号(Y)、色差信号(U、V)あるいはその他の色信号(赤色(R)、緑色(G)、青色(B)の信号等))それぞれで実施して未符号化領域内の各画素を埋める画素値を決定する。
Specifically, the pixel value of each pixel in the uncoded area is assumed by any one of the following methods (1) to (3). In the following description, the possible range of the pixel value is described as 0 to 255 having an 8-bit accuracy. However, the processing is performed in the same manner even when the 8-bit accuracy is not 10 bits or 12 bits. That is, if the accuracy is 10 bits, the possible range of pixel values is 0-1023, and if the accuracy is 12 bits, the possible range of pixel values is 0-4095. Further, the same processing is performed when the pixel value that can be taken is signed (for example, the value that can be taken with 8-bit accuracy is −123 to 122).
Further, the following method is used for each color signal (luminance signal (Y), color difference signal (U, V) or other color signal (red (R), green (G), blue (B) signal, etc.)). This is carried out to determine a pixel value for filling each pixel in the uncoded area.

(1)図34に示すように、予測ブロックが属している最大符号化ブロック(当該最大符号化ブロック)の左に隣接している複数の画素(図中、縦方向に並んでいる一列の画素)の画素値(画素値)の中で最も画素数の多い画素値を特定し、その画素値の画素を未符号化領域内に埋める。
図34の例では、“0”の画素値を有する画素と、“64”の画素値を有する画素とが、当該最大符号化ブロックの左に隣接しており、“64”の画素値を有する画素の数が、“0”の画素値を有する画素の数より多いので、“64”の画素値で未符号化領域内の画素を埋める。
一般的に、最も画素数の多い画素値は背景色となる可能性が高いため、画素埋めを行った未符号化領域と、符号化済み領域の背景との間に、不自然な輝度変化が発生せず、予測効率の低下を抑えることができる。
(1) As shown in FIG. 34, a plurality of pixels adjacent to the left of the maximum coding block to which the prediction block belongs (the maximum coding block) (a column of pixels arranged in the vertical direction in the figure) The pixel value having the largest number of pixels among the pixel values (pixel values) is specified, and the pixel having the pixel value is embedded in the uncoded area.
In the example of FIG. 34, a pixel having a pixel value of “0” and a pixel having a pixel value of “64” are adjacent to the left of the maximum coding block and have a pixel value of “64”. Since the number of pixels is larger than the number of pixels having a pixel value of “0”, the pixels in the uncoded area are filled with a pixel value of “64”.
In general, since the pixel value with the largest number of pixels is likely to be the background color, there is an unnatural luminance change between the uncoded area where the pixels are filled and the background of the encoded area. It does not occur, and the decrease in prediction efficiency can be suppressed.

上記例では、当該最大符号化ブロックの左に隣接している複数の画素の画素値の中で、画素数の最も多い画素値で未符号化領域を埋めるようにしているが、当該最大符号化ブロックの上に隣接している複数の画素の画素値の中で、画素数の最も多い画素値で未符号化領域を埋めるようにしてもよい。この場合、垂直方向に相関の高い画像において未符号化領域を埋める画素値を高精度に算出することができる。さらに、当該最大符号化ブロックの左及び上に隣接している複数の画素の画素値の中で、画素数の最も多い画素値で未符号化領域を埋めるようにしてもよい。このようにすることで、演算量は増加するものの参照する画素数の増加により、予測精度の改善を期待することができる。このとき、当該最大符号化ブロックの左上の画素も合わせて参照するようにしてもよい。
あるいは、図37に示すブロックシフトベクトルが指す参照ブロック内の未符号化領域の形状によって、当該最大符号化ブロックの左に隣接している複数の画素を用いるか、上に隣接している複数の画素を用いるかを適応的に切り替えてもよい。
In the above example, the unencoded area is filled with the pixel value having the largest number of pixels among the pixel values of a plurality of pixels adjacent to the left of the maximum encoded block. You may make it fill an uncoded area | region with the pixel value with the largest number of pixels among the pixel values of the several pixel adjacent on a block. In this case, the pixel value that fills the uncoded region in the image having a high correlation in the vertical direction can be calculated with high accuracy. Furthermore, the unencoded area may be filled with the pixel value having the largest number of pixels among the pixel values of a plurality of pixels adjacent to the left and above the maximum encoded block. In this way, although the amount of calculation increases, an improvement in prediction accuracy can be expected due to an increase in the number of pixels to be referred to. At this time, the upper left pixel of the maximum coding block may also be referred to.
Alternatively, depending on the shape of the uncoded area in the reference block indicated by the block shift vector shown in FIG. 37, a plurality of pixels adjacent to the left of the maximum encoded block are used, or a plurality of adjacent pixels Whether to use pixels may be switched adaptively.

具体的には、垂直方向の未符号化部分が短くなるdh<dwのときは当該最大符号化ブロックの上に隣接している複数の画素から未符号化領域を埋める画素値を求め、その他(dh≧dw)のときは当該最大符号化ブロックの左に隣接している複数の画素から未符号化領域を埋める画素値を求めるようにする。このようにすることで、常に当該最大符号化ブロックに隣接する符号化済み画素と、当該最大符号化ブロックの右端又は下端の画素との距離(dh、dw)が短い方の符号化済み隣接画素を選択することができるため、画像の空間的相関を精度良く利用することができる。
また、参照する隣接画素の一部の画素が存在しない場合、予め定めた手法によって参照する画素を生成する。例えば、予め定めた固定値で代替する方法や、存在する別の位置の隣接画素の画素値で代替する方法等がある。さらに、参照する隣接画素が一つも存在しない場合については、予め定めた固定値で未符号化領域の画素を埋めるようにする。なお、予め定める固定値としては、取り得る画素値の中間値等が挙げられる。
Specifically, when dh <dw where the uncoded portion in the vertical direction becomes shorter, a pixel value for filling the uncoded region is obtained from a plurality of adjacent pixels on the maximum coded block, and the other ( When dh ≧ dw), a pixel value that fills the uncoded region is obtained from a plurality of pixels adjacent to the left of the maximum coded block. By doing in this way, the encoded adjacent pixel whose distance (dh, dw) between the encoded pixel adjacent to the maximum encoded block and the right end or lower end pixel of the maximum encoded block is always shorter Therefore, the spatial correlation of the image can be used with high accuracy.
In addition, when some of the adjacent pixels to be referenced do not exist, a pixel to be referred to is generated by a predetermined method. For example, there are a method of substituting with a predetermined fixed value and a method of substituting with a pixel value of an adjacent pixel at another existing position. Further, when there is no adjacent pixel to be referred to, the pixels in the uncoded area are filled with a predetermined fixed value. The predetermined fixed value includes an intermediate value of possible pixel values.

(2)予め設定された画素値(固定値)で未符号化領域内の画素を埋める。
イントラブロックコピー予測処理は、一般的に、テキスト画像やCAD画像などのグラフィックス描画された文字や線分等に効果が高い予測処理であるが、例えば、テキスト画像は、一般的に白地の背景が多いため、例えば、白色の画素(画素値が0〜255を取り得る場合、“255”の画素値を有する画素)をテキスト画像の未符号化領域内に埋めると、イントラブロックコピー予測処理が効果的となり、多くの画像で性能改善効果を期待することができる。その他、取り得る画素値の中間値(画素値が0〜255を取り得る場合、“128”の画素値を有する画素)とする等、設定する画素値は上記以外でも良い。
予め設定された画素値(固定値)で未符号化領域内の画素を埋める手法は、コンテンツによっては予測精度が低下してしまう可能性があるが、処理負荷が非常に小さいメリットがある。
(2) Fill the pixels in the uncoded area with a preset pixel value (fixed value).
The intra block copy prediction process is generally a prediction process that is highly effective for characters or lines drawn in graphics such as text images and CAD images. For example, a text image generally has a white background. For example, when a white pixel (a pixel having a pixel value of “255” when the pixel value can take 0 to 255) is embedded in an uncoded area of the text image, the intra block copy prediction process is performed. It becomes effective, and a performance improvement effect can be expected for many images. In addition, the pixel value to be set may be other than the above, such as an intermediate value of possible pixel values (a pixel having a pixel value of “128” when the pixel value can be 0 to 255).
The method of filling the pixels in the unencoded area with a preset pixel value (fixed value) may reduce the prediction accuracy depending on the content, but has an advantage that the processing load is very small.

上記の手法を拡張する手法として、最大符号化ブロック単位に最適な画素値を選択し、その画素値を符号化する方法が考えられる。
このとき、選択可能な画素値の候補としては、存在している全ての画素値でもよいし、選択可能な画素値の代表値を決めて、その代表値だけを選択できるようにしてもよい。
代表値を定める場合には、可変長符号化部15が代表値自体を符号化するのではなく、その代表値を示すインデックスを符号化するようにすれば、符号化ビットストリームの符号量を抑制することができる。
具体的には、代表値が、例えば、0、64、128、192、256である場合、その順番にインデックスを0、1、2、3、4と定義し、選択した代表値を示すインデックスを可変長符号化する。
このような代表値を定める例として、白(最大値)、グレー(中間値)、黒(最小値)等の固定的な値を代表値として定めて、これらの代表値の中から任意の代表値を選択する方法や、図35に示すようなMove−To−Front法を用いて、適応的に代表値を変える方法がある。
As a method of extending the above method, a method of selecting an optimal pixel value for each maximum encoding block and encoding the pixel value can be considered.
At this time, the pixel value candidates that can be selected may be all existing pixel values, or a representative value of selectable pixel values may be determined so that only the representative value can be selected.
When the representative value is determined, if the variable length encoding unit 15 does not encode the representative value itself but encodes an index indicating the representative value, the code amount of the encoded bit stream is suppressed. can do.
Specifically, if the representative value is, for example, 0, 64, 128, 192, 256, the index is defined as 0, 1, 2, 3, 4 in that order, and the index indicating the selected representative value is Variable length coding.
As an example of determining such a representative value, a fixed value such as white (maximum value), gray (intermediate value), black (minimum value), etc. is determined as a representative value, and an arbitrary representative can be selected from these representative values. There are a method of selecting a value and a method of adaptively changing the representative value using a Move-To-Front method as shown in FIG.

Move−To−Front法は、インデックスを出現頻度に応じて並べ替える手法である。
本例の場合、初期テーブルとして、画素値を例えば白(最大値)から黒(最小値)の順番に並べたのち、図35のように、例えば、“255”の画素値が選択されれば、“255”の画素値を示す“6”のインデックスを符号化する一方、“255”の画素値がテーブルの一番上にくるように並び替える(“255”の画素値を示すインデックスが“1”になるようにテーブルを並び替える)ものである。
各最大符号化ブロックにおいて、テーブル上位の1つ以上の画素値(例えば、上位8つ)を代表値として、これらの代表値から任意の代表値を選択するようにする。
The Move-To-Front method is a method of rearranging indexes according to the appearance frequency.
In the case of this example, as an initial table, if pixel values are arranged in the order of white (maximum value) to black (minimum value), for example, a pixel value of “255” is selected as shown in FIG. , The index of “6” indicating the pixel value of “255” is encoded, and rearranged so that the pixel value of “255” is at the top of the table (the index indicating the pixel value of “255” is “ The table is rearranged to be 1 ").
In each maximum coding block, one or more pixel values (for example, the upper eight) in the upper table are used as representative values, and an arbitrary representative value is selected from these representative values.

(3)フィルタ処理によって未符号化領域内の画素を生成する。
具体的には、図36に示すような画素を参照するフィルタ処理を実施する(実線の円は参照画素を示し、点線の円はフィルタ処理対象画素を示している)。
S(x,y)を座標(x,y)における符号化済み画素の画素値(復号された画素値)又はフィルタ生成画素値(未符号化領域の場合)とすると、フィルタ処理対象画素の座標を(x,y)とした場合、下記の式でフィルタ処理が実行される。
水平方向フィルタ:

Figure 0006362370
垂直方向フィルタ:
Figure 0006362370
ここで、c(n=0、1、・・・、2Nh+1),c’(m=0、1、・・・、2Nv+1)はフィルタ係数、Nh,Nvはフィルタの参照画素数を決める定数である。
即ち、水平方向フィルタはフィルタ処理対象画素の左に位置する隣接画素群によるフィルタ処理を示し、垂直方向フィルタはフィルタ処理対象画素の上に位置する隣接画素群によるフィルタ処理を示している。 (3) Generate pixels in the unencoded area by filtering.
Specifically, a filtering process referring to pixels as shown in FIG. 36 is performed (a solid circle indicates a reference pixel, and a dotted circle indicates a filtering target pixel).
If S (x, y) is the pixel value of the encoded pixel at the coordinate (x, y) (decoded pixel value) or the filter generation pixel value (in the case of an unencoded area), the coordinates of the pixel to be filtered Is set to (x, y), the filter processing is executed by the following equation.
Horizontal filter:
Figure 0006362370
Vertical filter:
Figure 0006362370
Here, c n (n = 0, 1,..., 2Nh + 1), c ′ m (m = 0, 1,..., 2Nv + 1) are filter coefficients, and Nh and Nv determine the number of reference pixels of the filter. It is a constant.
That is, the horizontal direction filter indicates a filter process by an adjacent pixel group located on the left side of the filter processing target pixel, and the vertical direction filter indicates a filter process by an adjacent pixel group positioned on the filter process target pixel.

このとき、c+c+・・・+c2Nh=1、c’+c’+・・・+c’2Nv=1となるとき、平滑化フィルタであることを示す。また、c2Nh+1、c’2Nv+1はオフセット値を表している。上記フィルタの例としては下記が挙げられる。
水平方向フィルタ:
Nh=1、c=1/4、c=1/2、c=1/4、c=0
(cはオフセット値、本例ではオフセットなしとしている)
垂直方向フィルタ:
Nv=1、c’=1/4、c’=1/2、c’=1/4、c’=0
(c’はオフセット値、本例ではオフセットなしとしている)
In this case, c 0 + c 1 + ··· + c 2Nh = 1, c '0 + c' 1 + ··· + c '2Nv = 1 and when made, indicating the smoothing filter. Further, c 2Nh + 1 and c ′ 2Nv + 1 represent offset values. Examples of the filter include the following.
Horizontal filter:
Nh = 1, c 0 = 1 /4, c 1 = 1/2, c 2 = 1/4, c 3 = 0
(C 3 are offset, in the present embodiment is that there is no offset)
Vertical filter:
Nv = 1, c ′ 0 = 1/4, c ′ 1 = 1/2, c ′ 2 = 1/4, c ′ 3 = 0
(C ′ 3 is an offset value, and in this example, there is no offset)

Nh,Nvやフィルタ係数は予め画像符号化装置及び画像復号装置の共通の値として定義する。本例ではフィルタ処理対象画素に近い画素のフィルタ係数ほど大きい値としている。これは、一般にフィルタ処理対象画素に近い画素程、フィルタ処理対象画素との相関が高いためである。このようにすることで、未符号化領域内の画素として精度の高い画素を生成することができる。   Nh, Nv and filter coefficients are defined in advance as values common to the image encoding device and the image decoding device. In this example, the filter coefficient of the pixel closer to the filter processing target pixel is set to a larger value. This is because, generally, the closer to the filter processing target pixel, the higher the correlation with the filter processing target pixel. By doing in this way, a highly accurate pixel can be produced | generated as a pixel in an unencoded area | region.

なお、フィルタ処理の手順としては、水平方向フィルタ処理の場合は未符号化領域の左端の列から右端の列に向かって一列ずつフィルタ処理を行い、垂直方向フィルタ処理の場合は未符号化領域の上端の行から下端の行に向かって一行ずつフィルタ処理を行う。その際、参照不可能な画素がフィルタの参照画素として含まれる場合、参照可能な画素のうち、最も近い画素のフィルタ係数に参照不可能な画素のフィルタ係数を加算する(ただし、最も近い画素が複数ある場合は、フィルタ処理対象画素の座標(x,y)に最も近い画素を対象とする)。例えば、水平方向フィルタ処理において、座標(x−1,y+1)以下の画素が参照できない場合、下記の式となる。

Figure 0006362370
したがって、上記の例(Nh=1、c=1/4、c=1/2、c=1/4、c=0の例)の場合、
=1/4、c=3/4、c=0、c=0
となる。なお、このような参照不可能な画素が生じるフィルタ処理については、別途フィルタ係数やNh,Nvを定義するようにしてもよい。例えば、上記の水平方向フィルタの例では、Nh=1のままとして、
=1/2、c=1/2、c=0、c=0
としてもよい。この場合、フィルタ演算が2画素の単純平均となり、処理が簡易になるメリットがある。 Note that the filter processing procedure is as follows: in the case of horizontal filter processing, filter processing is performed one column at a time from the leftmost column to the rightmost column of the uncoded region, and in the case of vertical direction filter processing, Filtering is performed line by line from the top line to the bottom line. At this time, when a pixel that cannot be referred to is included as a reference pixel of the filter, the filter coefficient of the pixel that cannot be referred to is added to the filter coefficient of the closest pixel among the referenceable pixels (however, the closest pixel is When there are a plurality of pixels, the pixel closest to the coordinates (x, y) of the pixel to be filtered is targeted). For example, in the horizontal direction filter processing, when a pixel having coordinates (x−1, y + 1) or less cannot be referred to, the following expression is obtained.
Figure 0006362370
Therefore, in the case of the above example (example of Nh = 1, c 0 = 1/4, c 1 = 1/2, c 2 = 1/4, c 3 = 0),
c 0 = 1/4, c 1 = 3/4, c 2 = 0, c 3 = 0
It becomes. In addition, about the filter process which produces the pixel which cannot be referred to, you may make it define a filter coefficient, Nh, and Nv separately. For example, in the above example of the horizontal filter, Nh = 1 remains
c 0 = 1/2, c 1 = 1/2, c 2 = 0, c 3 = 0
It is good. In this case, the filter operation is a simple average of two pixels, and there is an advantage that the processing is simplified.

上記で説明したフィルタ例以外のフィルタの例として、
水平方向フィルタ:
Nh=0、c=1、c=0
(cはオフセット値、本例ではオフセットなしとしている)
垂直方向フィルタ:
Nv=0、c’=1、c’=0
(c’はオフセット値、本例ではオフセットなしとしている)
も挙げられる。
この例の場合、水平方向フィルタは対象画素の左の画素の画素値、垂直方向フィルタは対象画素の上の画素の画素値をコピーすることとなる。即ち、水平方向フィルタは水平方向に、垂直方向フィルタは垂直方向に当該最大符号化ブロックに隣接する画素の画素値が一様にコピーされることと等価であり、フィルタ処理に要する演算量を削減できると共に、当該最大符号化ブロック内の画素全てを同時に生成することができる(当該最大符号化ブロック内の画素全てを並列に処理して生成することができる)。
As examples of filters other than the filter examples described above,
Horizontal filter:
Nh = 0, c 0 = 1, c 1 = 0
(C 1 is an offset value, and in this example, there is no offset)
Vertical filter:
Nv = 0, c ′ 0 = 1, c ′ 1 = 0
(C ′ 1 is an offset value, in this example, no offset)
Also mentioned.
In this example, the horizontal filter copies the pixel value of the pixel to the left of the target pixel, and the vertical filter copies the pixel value of the pixel above the target pixel. In other words, the horizontal filter is equivalent to copying the pixel value of the pixel adjacent to the maximum coding block in the horizontal direction and the vertical filter in the vertical direction, reducing the amount of calculation required for the filter processing. In addition, all the pixels in the maximum coding block can be generated at the same time (all the pixels in the maximum coding block can be generated in parallel).

水平方向フィルタと垂直方向フィルタのどちらを用いるのかについては、予め画像符号化装置と画像復号装置共通で決めておくようにする。例えば、テキスト画像では水平方向に文字が並ぶことが多いため、常に水平方向フィルタを用いるものとして画像符号化装置及び画像復号装置を構成する。
あるいは、図37に示すブロックシフトベクトルが指す参照ブロック内の未符号化領域の形状によって、水平方向フィルタと垂直方向フィルタのどちらを用いるかを適応的に切り替えてもよい。具体的には、垂直方向の未符号化部分が短くなるdh<dwのときは垂直方向フィルタを用い、その他(dh≧dw)のときは水平方向フィルタを用いるようにする。このようにすることで、常にフィルタ対象画素と符号化済み画素との距離(dh、dw)が短くなるフィルタを選択できるため、画像の空間的相関を精度良く利用することができる。
Which of the horizontal direction filter and the vertical direction filter is used is determined in advance for both the image encoding device and the image decoding device. For example, in a text image, since characters are often arranged in the horizontal direction, the image encoding device and the image decoding device are configured to always use a horizontal filter.
Alternatively, whether to use the horizontal filter or the vertical filter may be adaptively switched according to the shape of the uncoded region in the reference block indicated by the block shift vector shown in FIG. Specifically, a vertical filter is used when dh <dw when the uncoded portion in the vertical direction becomes shorter, and a horizontal filter is used when the other (dh ≧ dw). In this way, a filter that always shortens the distance (dh, dw) between the pixel to be filtered and the encoded pixel can be selected, so that the spatial correlation of the image can be used with high accuracy.

(3)のその他の例として、図38に示す参照画素配置のフィルタ処理を行うように画像符号化装置を構成してもよい(実線の円は参照画素を示し、点線の円はフィルタ処理対象画素を示している)。フィルタ処理対象画素の座標を(x,y)とした場合、下記の式でフィルタ処理が実行される。

Figure 0006362370
ここで、c”(l=0、1、・・・、3)はフィルタ係数を示している。また、c”+c”+c”=1となるとき、平滑化フィルタであることを示している。また、c”はオフセット値を表している。上記フィルタの例としては下記が挙げられる。
c”=1/4、c”=3/8、c”=3/8、c”=0
(c”はオフセット値、本例ではオフセットなしとしている)
本例ではフィルタ処理対象画素に近い画素程フィルタ係数が大きくなっており、これは一般にフィルタ処理対象画素に近い画素程、フィルタ処理対象画素との相関が高いためである。なお、フィルタ処理の手順としては、未符号化領域の左上の画素からフィルタ処理を実施し、隣接する未符号化領域の画素を順にフィルタ処理していくことで、常に参照画素S(x−1,y−1)、S(x,y−1)、S(x−1,y)が存在するようにフィルタ処理を行うことができる。 As another example of (3), the image encoding apparatus may be configured to perform the filtering process of the reference pixel arrangement shown in FIG. 38 (the solid circle indicates the reference pixel, and the dotted circle indicates the filtering target) Pixel). When the coordinates of the pixel to be filtered are (x, y), the filtering process is executed according to the following formula.
Figure 0006362370
Here, c ″ l (l = 0, 1,..., 3) indicates a filter coefficient. When c ″ 0 + c ″ 1 + c ″ 2 = 1, the filter is a smoothing filter. Is shown. Also, c ″ 3 represents an offset value. Examples of the filter include the following.
c ″ 0 = 1/4, c ″ 1 = 3/8, c ″ 2 = 3/8, c ″ 3 = 0
(C ″ 3 is an offset value, and in this example, there is no offset)
In this example, the filter coefficient closer to the pixel to be filtered has a larger filter coefficient. This is because the pixel closer to the filter target pixel generally has a higher correlation with the filter target pixel. As a procedure of the filter process, the reference pixel S (x−1) is always obtained by performing the filter process from the upper left pixel of the uncoded area and sequentially filtering the pixels in the adjacent uncoded area. , Y-1), S (x, y-1), and S (x-1, y) can be filtered.

なお、上記で説明した下記例について、
水平方向フィルタ:
Nh=1、c=1/4、c=1/2、c=1/4、c=0
垂直方向フィルタ:
Nv=1、c’=1/4、c’=1/2、c’=1/4、c’=0
図38のフィルタ:
c”=1/4、c”=3/8、c”=3/8、c”=0
これらのフィルタは、有意なフィルタ係数の分母が全て2のべき乗であるため、計算機による整数演算として実現する場合、下記の式に置き換えることができる。
水平方向フィルタ:

Figure 0006362370
垂直方向フィルタ:
Figure 0006362370
図38のフィルタ:
Figure 0006362370
ここで、“>>”は右ビットシフト演算を示している。これらの計算式は全て整数精度のため、元の式と比べて小数精度の誤差は生じるものの、整数演算とビットシフトのみで実行できるため、高速な計算を実現することができる。 For the following example described above,
Horizontal filter:
Nh = 1, c 0 = 1 /4, c 1 = 1/2, c 2 = 1/4, c 3 = 0
Vertical filter:
Nv = 1, c ′ 0 = 1/4, c ′ 1 = 1/2, c ′ 2 = 1/4, c ′ 3 = 0
The filter of FIG. 38:
c ″ 0 = 1/4, c ″ 1 = 3/8, c ″ 2 = 3/8, c ″ 3 = 0
These filters have significant filter coefficient denominators that are all powers of 2, and can be replaced by the following equations when implemented as integer operations by a computer.
Horizontal filter:
Figure 0006362370
Vertical filter:
Figure 0006362370
The filter of FIG. 38:
Figure 0006362370
Here, “>>” indicates a right bit shift operation. Since these calculation formulas are all integer precision, an error of decimal precision occurs compared to the original formula, but can be executed only by integer arithmetic and bit shift, so that high-speed calculation can be realized.

上記では、フィルタ処理対象画素の座標(x,y)から水平方向又は垂直方向のいずれかが±1となる座標の範囲内の画素を参照してフィルタ処理を行う手法について説明したが、図39、図40、図41に示すようにフィルタ処理対象画素の座標(x,y)から水平方向・垂直方向共に±2以上となる画素も用いたフィルタ処理としてもよい。図39、図40及び図41において、実線の円が参照画素を示し、点線の円がフィルタ処理対象画素を示している。また、Nh,Nvと同様に、Mh,Mv,Nl,Mlは各フィルタの参照画素数を決める定数を示している。
この場合も上記で説明したフィルタと同様に、フィルタ処理を各参照画素に対するフィルタ係数とオフセット値から定式化することができる。このようにフィルタの参照画素を増やすことで、演算量は増加するものの、未符号化領域画素の高精度な生成を実現することができる。
In the above description, the method for performing the filtering process with reference to the pixels within the coordinate range in which either the horizontal direction or the vertical direction is ± 1 from the coordinates (x, y) of the pixel to be filtered has been described. As shown in FIGS. 40 and 41, the filter processing may be performed using pixels that are ± 2 or more in the horizontal and vertical directions from the coordinates (x, y) of the pixel to be filtered. 39, 40, and 41, a solid circle indicates a reference pixel, and a dotted circle indicates a filter processing target pixel. Similarly to Nh and Nv, Mh, Mv, Nl, and Ml indicate constants that determine the number of reference pixels of each filter.
In this case, similarly to the filter described above, the filter processing can be formulated from the filter coefficient and the offset value for each reference pixel. By increasing the reference pixels of the filter in this way, the calculation amount increases, but high-accuracy generation of uncoded area pixels can be realized.

また、上記の例では、未符号化領域内の画素を埋め込む単位が最大符号化ブロックであるものを示したが、これに限るものではなく、例えば、符号化ブロック単位や予測ブロック単位で更新するようにしてもよい。このようにすることで、処理量が増加してしまうが、精度が良い画素埋め処理を実現することができる。   In the above example, the unit in which the pixels in the unencoded area are embedded is the maximum encoded block. However, the present invention is not limited to this. For example, the update is performed in encoded block units or predicted block units. You may do it. By doing so, the processing amount increases, but it is possible to realize pixel filling processing with high accuracy.

例えば、上記(1)〜(3)の手法では最大符号化ブロック単位で未符号化領域の画素を埋める処理について説明したが、符号化ブロック単位で本処理を行うようにしてもよい。
即ち、最大符号化ブロックの未符号化領域のうち、予測対象の符号化ブロック(当該符号化ブロック)内のみ、上記(1)〜(3)の手法で画素を埋めるようにする。具体的には、下記の通りとする。
(1)の手法の場合:
予測対象の符号化ブロック(当該符号化ブロック)の左に隣接している複数の画素の画素値の中で画素数の最も多い画素値で当該符号化ブロック内の未符号化領域の画素を埋めるようにする。
(2)の手法の場合:
予測対象の符号化ブロック(当該符号化ブロック)に対して、当該符号化ブロック内の未符号化領域を埋める代表値を決定する。代表値(あるいは代表値を示すインデックス)は符号化ブロック単位に符号化する。
(3)の手法の場合:
予測対象の符号化ブロック(当該符号化ブロック)に対して、当該符号化ブロック内の未符号化領域をフィルタ処理によって埋めるようにする。
したがって、図42に示す例のように、各符号化ブロックのイントラブロックコピー予測処理において、ブロックシフトベクトルが指し示す参照ブロックが含んでよい未符号化領域は、当該符号化ブロック内のみとなる。したがって、最大符号化ブロック単位で未符号化領域の画素を埋める処理を行う場合と比較して参照可能な領域は狭くなる。しかし、最大符号化ブロックより小さい符号化ブロックの単位で適応的に画素を埋める処理が行えるため、埋める画素の予測精度が向上し、イントラブロックコピー予測の予測効率の改善を期待することができる。
For example, in the methods (1) to (3) described above, the process of filling the pixels in the unencoded area in units of maximum encoded blocks has been described. However, the present process may be performed in units of encoded blocks.
That is, pixels are filled by the above-described methods (1) to (3) only in the prediction target coding block (the coding block) in the uncoded region of the maximum coding block. Specifically, it is as follows.
For method (1):
The pixels in the unencoded area in the coding block are filled with the pixel value having the largest number of pixels among the pixel values of the plurality of pixels adjacent to the left of the coding block to be predicted (the coding block). Like that.
In the case of method (2):
For the prediction target encoding block (the encoding block), a representative value for filling an unencoded area in the encoding block is determined. The representative value (or an index indicating the representative value) is encoded in units of encoded blocks.
In the case of method (3):
For an encoding block to be predicted (the encoding block), an unencoded area in the encoding block is filled by a filter process.
Therefore, as in the example shown in FIG. 42, in the intra block copy prediction process of each encoded block, the unencoded area that may be included in the reference block indicated by the block shift vector is only within the encoded block. Therefore, an area that can be referred to becomes narrower than in the case of performing the process of filling the pixels of the unencoded area in units of maximum encoded blocks. However, since it is possible to adaptively fill pixels in units of encoded blocks smaller than the maximum encoded block, the prediction accuracy of the pixels to be embedded is improved, and improvement in prediction efficiency of intra block copy prediction can be expected.

なお、(1)においては、当該符号化ブロックの左に隣接している複数の画素ではなく、当該符号化ブロックの上に隣接している複数の画素の画素値の中で、画素数の最も多い画素値で当該符号化ブロック内の未符号化領域の画素を埋めるようにしてもよい。この場合、垂直方向に相関の高い画像において未符号化領域を埋める画素値を精度良く得られる。さらに、当該符号化ブロックの左及び上に隣接している複数の画素の画素値の中で、画素数の最も多い画素値で当該符号化ブロック内の未符号化領域を埋めるようにしてもよい。このようにすることで、演算量は増加するものの参照する画素数の増加により、予測精度の改善を期待することができる。このとき、当該符号化ブロックの左上の画素も合わせて参照するようにしてもよい。   In (1), the pixel value of the pixel number of the plurality of pixels adjacent on the encoding block is not the plurality of pixels adjacent to the left of the encoding block, but the pixel number You may make it fill the pixel of the unencoded area | region in the said encoding block with many pixel values. In this case, a pixel value that fills an uncoded area in an image having a high correlation in the vertical direction can be obtained with high accuracy. Furthermore, an unencoded area in the encoded block may be filled with a pixel value having the largest number of pixels among the pixel values of a plurality of pixels adjacent to the left and above the encoded block. . In this way, although the amount of calculation increases, an improvement in prediction accuracy can be expected due to an increase in the number of pixels to be referred to. At this time, the upper left pixel of the coding block may also be referred to.

あるいは、図37に示すブロックシフトベクトルが指す参照ブロック内の未符号化領域の形状によって、当該符号化ブロックの左に隣接している複数の画素を用いるか、上に隣接している複数の画素を用いるかを適応的に切り替えてもよい。具体的には、垂直方向の未符号化部分が短くなるdh<dwのときは当該符号化ブロックの上に隣接している複数の画素から未符号化領域を埋める画素値を求め、その他(dh≧dw)のときは当該符号化ブロックの左に隣接している複数の画素から未符号化領域を埋める画素値を求めるようにする。このようにすることで、常に当該符号化ブロックに隣接する符号化済み画素と当該符号化ブロックの右端又は下端の画素との距離(dh、dw)が短い方の符号化済み隣接画素を選択できるため、画像の空間的相関を精度良く利用することができる。
また、参照する隣接画素の一部の画素が存在しない場合、予め定めた手法によって参照する画素を生成する。例えば、予め定めた固定値で代替する方法や、存在する別の位置の隣接画素の画素値で代替する方法等がある。さらに、参照する隣接画素が一つも存在しない場合については、予め定めた固定値で未符号化領域の画素を埋めるようにする。なお、予め定める固定値としては、取り得る画素値の中間値等が挙げられる。
Alternatively, depending on the shape of the uncoded region in the reference block indicated by the block shift vector shown in FIG. 37, a plurality of pixels adjacent to the left of the encoded block are used, or a plurality of pixels adjacent above It may be switched adaptively whether to use. Specifically, when dh <dw when the uncoded portion in the vertical direction becomes shorter, a pixel value for filling the uncoded region is obtained from a plurality of adjacent pixels on the coded block, and the other (dh When ≧ dw), a pixel value for filling the uncoded area is obtained from a plurality of pixels adjacent to the left of the coded block. By doing so, it is possible to always select an encoded adjacent pixel having a shorter distance (dh, dw) between the encoded pixel adjacent to the encoded block and the right end or lower end pixel of the encoded block. Therefore, the spatial correlation of images can be used with high accuracy.
In addition, when some of the adjacent pixels to be referenced do not exist, a pixel to be referred to is generated by a predetermined method. For example, there are a method of substituting with a predetermined fixed value and a method of substituting with a pixel value of an adjacent pixel at another existing position. Further, when there is no adjacent pixel to be referred to, the pixels in the uncoded area are filled with a predetermined fixed value. The predetermined fixed value includes an intermediate value of possible pixel values.

なお、最大符号化ブロック単位で未符号化領域の画素を埋める処理の場合においても、ブロックシフトベクトルが指し示す参照ブロックが含んでよい未符号化領域を、予測対象の符号化ブロック内のみとしてもよい。このようにすることで、予測対象の符号化ブロックに近い、すなわち、空間的相関の高い領域のみ、未符号化領域も参照可能として探索可能な領域を拡大するため、最大符号化ブロック内の未符号化領域全体を探索可能とする場合と比較して、ブロックシフトベクトル探索に要する演算の負荷の増加を抑制しつつ予測精度を同様に改善することができる。さらに、探索範囲の抑制により、画像復号装置で必要とする参照可能領域を記憶するメモリのサイズの増加も抑制することができる。   Even in the case of the process of filling the pixels of the unencoded area in units of the maximum encoded block, the unencoded area that may be included in the reference block indicated by the block shift vector may be only within the encoded block to be predicted. . In this way, the search area is expanded so that only the area close to the encoding block to be predicted, that is, the area having a high spatial correlation, and the uncoded area can also be referred to can be searched. Compared with the case where the entire coding region can be searched, the prediction accuracy can be improved in the same manner while suppressing an increase in the calculation load required for the block shift vector search. Furthermore, by suppressing the search range, it is possible to suppress an increase in the size of the memory that stores the referenceable area required by the image decoding apparatus.

(1)の未符号化領域の画素を埋める処理について、画素数を数える画素値を限定してもよい。このようにすることで、画素値が取り得る値の数の分のカウンタが必要な(1)の手法よりも必要なカウンタの個数が減るため、カウンタとして必要なメモリ量を削減することができる。なお、未符号化領域内の画素を埋め込む単位は最大符号化ブロック、符号化ブロック、予測ブロックのいずれの単位であっても各々で設定された参照画素に対して本処理を実施するものとする。
画素数を数える画素値を限定する手法の例を次に述べる。まず、画素値を量子化する例について説明する。本例では、画素値を予め定めた量子化器によって量子化し、その量子化後の代表値の数を数える。そして、最も多い画素数の代表値で未符号化領域の画素を埋めるようにする。ここで、取り得る画素値が0〜2bit_depth−1であり、取り得る画素値をN個の代表値に量子化するとする(bit_depthは0以上の整数、Nは1以上の整数)。この時の量子化処理の例として、整数精度の演算で行う例を下記に示している。
pow=bit_depth−base
(代表値)=(((画素値)+(1<<(pow−1)))>>pow)<<pow
In the process of filling the pixels in the uncoded area (1), the pixel value for counting the number of pixels may be limited. By doing so, the number of necessary counters is reduced as compared with the method (1) in which counters corresponding to the number of values that the pixel values can take are required, so that it is possible to reduce the amount of memory required as a counter. . It should be noted that this processing is performed on the reference pixels set in each of the units of the maximum coding block, coding block, and prediction block as the unit for embedding the pixels in the uncoded region. .
An example of a method for limiting the pixel value for counting the number of pixels will be described below. First, an example of quantizing pixel values will be described. In this example, the pixel value is quantized by a predetermined quantizer, and the number of representative values after the quantization is counted. Then, the pixels in the uncoded area are filled with the representative value having the largest number of pixels. Here, the possible pixel values are 0 to 2 bit_depth −1, and the possible pixel values are quantized into N Q representative values (bit_depth is an integer of 0 or more, and N Q is an integer of 1 or more). As an example of the quantization processing at this time, an example performed by integer precision calculation is shown below.
pow = bit_depth-base
(Representative value) = (((pixel value) + (1 << (pow-1))) >> pow) << pow

ただし、代表値が2bit_depth−1を超える場合、2bit_depth−1に代表値を丸める。“<<”は左ビットシフト演算、“>>”は右ビットシフト演算を示し、baseは0以上の整数とし、N=2base+1の関係が成立する。例えば、bit_depth=8、かつ、base=1の場合、画素値0〜63の代表値が0、画素値64〜191の代表値が128、画素値192〜255の代表値が255となる。なお、画素値の量子化手法については、上記手法に限るものではなく、上記の式において画素値に1<<(pow−1)を加算しない等の等間隔に量子化する手法を用いる等、どのような手法でも良い。
画素数を数える画素値を限定する手法のその他の例として、画素数を数えている画素値の個数が所定の数に達したら、新しく出現する画素値を無効とする手法がある。
具体的には、所定の数N個のカウンタを用意し、隣接画素を順に数えていく中で新しい画素値が出現する度に未使用のカウンタを当該画素値のカウンタとして割り当てていくようにする。そして、所定の数N個のカウンタ全てを使用している状態に達した以降は、これまでに出現していない新しい画素値が出現した際にはその画素値を無効とする。このようにすることで、所定の数N個の画素値のみから未符号化領域を埋める画素値を決定することとなり、画素数を数える画素値を限定することができる。なお、本手法の場合、隣接画素を数える順番が結果に影響する。したがって、隣接画素を数える順番は予め決定しておくようにする。例えば、最大符号化ブロックの左及び上に隣接している画素を参照する場合、左下の画素から左上の画素、そして右上の画素に向かって参照していく、というように予め定める。
なお、画素数を数える画素値を限定する手法については、上記手法に限るものではなく、上記以外の手法でも良い。
However, if the representative value is greater than 2 bit_depth -1, round the representative value to 2 bit_depth -1. “<<” indicates a left bit shift operation, “>>” indicates a right bit shift operation, base is an integer greater than or equal to 0, and a relationship of N Q = 2 base +1 is established. For example, when bit_depth = 8 and base = 1, the representative value of pixel values 0 to 63 is 0, the representative value of pixel values 64 to 191 is 128, and the representative value of pixel values 192 to 255 is 255. Note that the pixel value quantization method is not limited to the above method, and a method of quantizing at equal intervals such as not adding 1 << (pow-1) to the pixel value in the above formula, etc. Any method is acceptable.
As another example of the method of limiting the pixel value for counting the number of pixels, there is a method for invalidating a newly appearing pixel value when the number of pixel values for counting the number of pixels reaches a predetermined number.
Specifically, a predetermined number Nc counters are prepared, and each time a new pixel value appears while counting adjacent pixels in sequence, an unused counter is assigned as a counter for the pixel value. To do. After reaching the state where all the predetermined number Nc counters are used, when a new pixel value that has not appeared so far appears, the pixel value is invalidated. In this way, the pixel value that fills the uncoded region is determined only from the predetermined number Nc of pixel values, and the pixel value for counting the number of pixels can be limited. In the case of this method, the order of counting adjacent pixels affects the result. Therefore, the order in which adjacent pixels are counted is determined in advance. For example, when referring to the pixels adjacent to the left and top of the maximum coding block, it is determined in advance such that the reference is made from the lower left pixel toward the upper left pixel and then the upper right pixel.
Note that the method for limiting the pixel value for counting the number of pixels is not limited to the above method, and other methods may be used.

また、(1)の手法では、画素値毎の画素数を数えるカウンタのためのメモリが必要となる。したがって、各画素値の画素数を覚える必要のない、同一画素値の連続数を用いる手法で未符号化領域を埋める画素値に決定するようにしても良い。具体的には、参照する隣接画素は(1)と同一とし、所定の参照順に同一の画素値が連続する画素数を数える。
そして、連続する画素数が最大となった画素値を未符号化領域の画素を埋める画素値に決定する。なお、未符号化領域内の画素を埋め込む単位は最大符号化ブロック、符号化ブロック、予測ブロックのいずれの単位であっても各々で設定された参照画素に対して本処理を実施するものとする。
本手法の場合、最大の連続画素数Lmaxと、それに対応する画素値Smax、現在連続している画素値Stmpと、その連続画素数Ltmpとを記憶し、所定の参照順に画素を参照していく際に、現在参照している画素の画素値ScurとStmpが同じ場合は連続画素数Ltmpを1増やし、異なる場合は、LtmpとLmaxを比較してLtmpが大きい場合にLmax=Ltmp、Smax=Stmpとした後で、Ltmpを初期化すると共にStmp=Scurとする。これを全ての参照画素に対して行った後のSmaxが連続する画素数が最大となる画素値となる。
In the method (1), a memory for a counter that counts the number of pixels for each pixel value is required. Therefore, it is possible to determine the pixel value that fills the unencoded area by using a continuous number of the same pixel value, which does not require memorizing the number of pixels of each pixel value. Specifically, the adjacent pixel to be referred to is the same as (1), and the number of pixels in which the same pixel value continues in a predetermined reference order is counted.
Then, the pixel value having the maximum number of consecutive pixels is determined as the pixel value that fills the pixels in the uncoded area. It should be noted that this processing is performed on the reference pixels set in each of the units of the maximum coding block, coding block, and prediction block as the unit for embedding the pixels in the uncoded region. .
In the case of this method, the maximum continuous pixel number L max , the corresponding pixel value S max , the currently continuous pixel value S tmp , and the continuous pixel number L tmp are stored, and the pixels are stored in a predetermined reference order. When referencing, if the pixel values S cur and S tmp of the currently referenced pixel are the same, the number of consecutive pixels L tmp is increased by 1, and if they are different, L tmp and L max are compared to determine L tmp If it is larger, after L max = L tmp and S max = S tmp , L tmp is initialized and S tmp = S cur is set. After this is performed for all reference pixels, S max is the pixel value that maximizes the number of consecutive pixels.

図43及び図44は本手法の処理手順の例を示すフローチャートである。
ただし、図44は図43に記載のステップST105及びステップST106の「Lmax判定及びSmax更新」の処理手順例を示している。本例では、ステップST100でLmax及びSmaxを1(連続画素数1)に初期化すると共に、StmpとLtmpを最初に参照する隣接画素の画素値に設定する。そして、残りの参照する隣接画素に対して(ステップST101)、SmaxとLmaxを更新する処理を実施する(ステップST102〜ステップST106)。
まず、これから参照する画素の画素値をScurとし(ステップST102)、ScurとStmpが同じか比較する(ステップST103)。そして、ScurとStmpが同じ場合は連続画素数Ltmpの値を1増加し(ステップST104)、異なる場合は図44記載のLmax判定及びSmax更新処理を行う(ステップST105)。
43 and 44 are flowcharts showing an example of the processing procedure of this method.
However, FIG. 44 shows a processing procedure example of “L max determination and S max update” in step ST 105 and step ST 106 shown in FIG. 43. In this example, in step ST100, L max and S max are initialized to 1 (the number of consecutive pixels is 1), and S tmp and L tmp are set to the pixel values of adjacent pixels to be referred to first. Then, with respect to adjacent pixels remaining references (step ST 101), carries out a process of updating the S max and L max (step ST102~ step ST 106).
First, let the pixel value of the pixel to be referred to be Scur (step ST102), and compare whether Scur and Stmp are the same (step ST103). If S cur and S tmp are the same, the value of the continuous pixel number L tmp is incremented by 1 (step ST104), and if different, the L max determination and S max update processing shown in FIG. 44 is performed (step ST105).

具体的には、LtmpとLmaxを比較して(ステップST200)、LtmpがLmaxより大きい場合にLmax=Ltmp、Smax=Stmpとする(ステップST201)。その後、Ltmp=1に初期化すると共に、Stmp=Scurに設定する(ステップST202)。そして、上記処理を全ての参照する隣接画素に対して完了した後、現在の連続画素数Ltmpに対しても図44記載のLmax判定及びSmax更新処理を行う(ステップST106)。そして、上記処理を終えた時のSmaxを未符号化領域の画素を埋める素値に設定する(ステップST107)。
ただし、ステップST106については、ステップST201の処理の内のLmax=Ltmpとする処理と、ステップST202の処理は不要のため、省略して良い。
Specifically, by comparing L tmp and L max (step ST 200), L tmp is L max = L tmp is larger than L max, and S max = S tmp (Step ST 201). Then, it initializes to L tmp = 1 and sets S tmp = S cur (step ST202). Then, after the above process is completed for all the adjacent pixels to be referred to, the L max determination and the S max update process shown in FIG. 44 are performed for the current continuous pixel number L tmp (step ST106). Then, S max when the above process is completed is set to a prime value that fills the pixels in the uncoded region (step ST107).
However, step ST106 may be omitted because the process of setting L max = L tmp in the process of step ST201 and the process of step ST202 are unnecessary.

以上より、(1)の手法で必要な各画素値の画素数を数えるカウンタのためのメモリは不要となり、メモリ量を削減することができる。さらに、連続する画素数が最も多い画素値は参照する隣接画素の中で最も画素数の多い画素値である可能性が高いため、(1)と同程度の(未符号化領域の画素を埋める画素値の)予測精度を得ることができる。
なお、本手法の参照する隣接画素は(1)と同一とするため、(1)で説明した図37に示すブロックシフトベクトルが指す参照ブロック内の未符号化領域の形状によって、当該符号化ブロックの左に隣接している複数の画素を用いるか、上に隣接している複数の画素を用いるかを適応的に切り替えるようにしてもよい。切り替え手法も(1)と同一である。
As described above, a memory for a counter for counting the number of pixels of each pixel value required by the method (1) is not necessary, and the amount of memory can be reduced. Further, since the pixel value having the largest number of consecutive pixels is likely to be the pixel value having the largest number of pixels among the adjacent pixels to be referred to, the pixel value of the same level as (1) (fill the pixels in the uncoded region) Prediction accuracy (of pixel values) can be obtained.
In addition, since the adjacent pixel to which this technique refers is the same as (1), according to the shape of the uncoded area in the reference block indicated by the block shift vector shown in FIG. It is also possible to adaptively switch between using a plurality of pixels adjacent to the left of the pixel and a plurality of pixels adjacent to the upper side. The switching method is also the same as (1).

後述する画像復号装置では、イントラブロックコピー予測画像PICOPYi と全く同じイントラブロックコピー予測画像を生成する必要があるため、イントラブロックコピー予測画像PICOPYi の生成に用いられたイントラブロックコピー予測パラメータは、符号化制御部1から可変長符号化部15に出力されて、ビットストリームに多重化される。
イントラブロックコピー予測パラメータとしては、イントラブロックコピー予測部6により探索されたブロックシフトベクトルや、未符号化領域の画素値埋め処理で符号化すべきパラメータが存在する場合は対象のパラメータが挙げられる。また、ブロックシフトベクトルは直前の符号化済み予測ブロックのブロックシフトベクトル、あるいは当該予測ブロックの周囲の符号化済み予測ブロックのブロックシフトベクトルとの差分値をイントラブロックコピー予測パラメータの一部として符号化するようにしてもよい。
In the image decoding apparatus described later, it is necessary to generate exactly the same intra block copy predictive image and the intra block copy predicted image P ICOPYi n, intra block copy predicted image P ICOPYi n intra block copy prediction parameters used to generate the Is output from the encoding control unit 1 to the variable length encoding unit 15 and multiplexed into a bit stream.
Examples of the intra block copy prediction parameter include a block shift vector searched by the intra block copy prediction unit 6 and a target parameter when there is a parameter to be encoded by pixel value padding processing in an unencoded area. Also, the block shift vector is encoded by using the block shift vector of the previous encoded prediction block or the difference value with the block shift vector of the encoded prediction block around the prediction block as a part of the intra block copy prediction parameter. You may make it do.

色差信号については、輝度信号と同一のベクトルによる予測を実施する。あるいは、輝度信号のベクトルを基準として探索し、輝度信号のベクトルの差分ベクトルを符号化するようにしてもよい。このようにすることで色差信号の予測精度を改善することができる。
この差分ベクトルはU信号とV信号でそれぞれ独立に決定するようにしてもよい。このようにすることで一層自由度が高まるため、色差信号の予測精度を更に改善することができる。
また、上記の差分ベクトルは、±M画素以内(M:自然数)に限定するようにしてもよい。このように探索する範囲を限定することで探索に要する演算量を削減することができる。また、対応する画像復号装置においても用意する参照画像が限定されることで参照画像のメモリ量を削減することができる。
このとき、小数画素精度を禁止するようにしてもよい。このようにすることで、さらに探索に要する演算量を削減しながら、参照画像に要するメモリ量を削減することができる。
あるいは、±1画素以内の小数画素精度に限定するようにしてもよい。この場合も、探索する範囲を限定することで探索に要する演算量及び参照画像に要するメモリ量を削減することができる。
For the color difference signal, prediction using the same vector as the luminance signal is performed. Alternatively, the search may be performed based on the luminance signal vector, and the difference vector of the luminance signal vector may be encoded. By doing so, the prediction accuracy of the color difference signal can be improved.
This difference vector may be determined independently for each of the U signal and the V signal. By doing so, the degree of freedom is further increased, so that the prediction accuracy of the color difference signal can be further improved.
The difference vector may be limited to within ± M pixels (M: natural number). By limiting the search range in this way, the calculation amount required for the search can be reduced. Moreover, the memory amount of a reference image can be reduced by limiting the reference image prepared also in the corresponding image decoding apparatus.
At this time, decimal pixel accuracy may be prohibited. In this way, it is possible to reduce the amount of memory required for the reference image while further reducing the amount of calculation required for the search.
Alternatively, it may be limited to decimal pixel accuracy within ± 1 pixel. Also in this case, by limiting the search range, it is possible to reduce the amount of calculation required for the search and the amount of memory required for the reference image.

イントラブロックコピー予測部6は、輝度信号の予測画像の生成については常にイントラブロックコピー予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、符号化制御部1により当該予測ブロックの色信号間予測フラグがONに設定されている場合、イントラブロックコピー予測処理を実施せずに、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。一方、符号化制御部1により当該予測ブロックの色信号間予測フラグがOFFに設定されている場合は、色差信号もイントラブロックコピー予測処理を実施する。   The intra block copy prediction unit 6 always performs the intra block copy prediction process for the generation of the prediction image of the luminance signal, but the encoding control unit 1 for each prediction block for the generation of the prediction image of the color difference signal. When the inter-color-signal prediction flag of the prediction block is set to ON by referring to the encoded color signal without performing the intra-block copy prediction process, the prediction image of the color difference signal in the prediction block is obtained. The prediction process between the color signals to be generated is performed. On the other hand, if the inter-color signal prediction flag of the prediction block is set to OFF by the encoding control unit 1, the color difference signal is also subjected to intra block copy prediction processing.

動き補償予測部7は、符号化制御部1により決定された符号化モードm(B)がインター符号化モードであり(m(B)∈INTERの場合)、切換スイッチ4から符号化ブロックBを受けると(ステップST3)、その符号化ブロックB内の各予測ブロックP と動き補償予測フレームメモリ14に格納されているフィルタ処理後の局所復号画像を比較して動きベクトルを探索し、その動きベクトルと符号化制御部1により決定されたインター予測パラメータを用いて、その符号化ブロックB内の各予測ブロックP に対する動き補償予測処理を実施して、インター予測画像PINTERi を生成する(ステップST6)。
なお、画像復号装置がインター予測画像PINTERi と全く同じインター予測画像を生成する必要があるため、インター予測画像PINTERi の生成に用いられたインター予測パラメータは、符号化制御部1から可変長符号化部15に出力されて、ビットストリームに多重化される。
また、動き補償予測部7により探索された動きベクトルも可変長符号化部15に出力されて、ビットストリームに多重化される。
The motion compensated prediction unit 7 uses the encoding switch 4 from the changeover switch 4 when the encoding mode m (B n ) determined by the encoding control unit 1 is the inter encoding mode (when m (B n ) ∈INTER). Upon receiving the B n (step ST3), the motion vector by comparing the locally decoded image after the filtering process stored in the prediction block P i n and the motion compensated prediction frame memory 14 of the encoding block B n Using the motion vector and the inter prediction parameter determined by the encoding control unit 1, the motion compensated prediction process for each prediction block P i n in the encoding block B n is performed, and the inter prediction image generating a P INTERi n (step ST6).
Since the image decoding apparatus must generate an identical inter prediction image and the inter-predicted image P INTERi n, inter prediction parameters used for generating the inter prediction image P INTERi n is a variable from the coding controller 1 The data is output to the long encoding unit 15 and multiplexed into a bit stream.
The motion vector searched by the motion compensation prediction unit 7 is also output to the variable length encoding unit 15 and multiplexed into the bit stream.

色差信号については、輝度信号と同一のベクトルによる予測を実施する。あるいは、輝度信号のベクトルを基準として探索し、輝度信号のベクトルの差分ベクトルを符号化するようにしてもよい。このようにすることで色差信号の予測精度を改善することができる。
この差分ベクトルはU信号とV信号でそれぞれ独立に決定するようにしてもよい。このようにすることで一層自由度が高まるため、色差信号の予測精度を更に改善することができる。
また、上記の差分ベクトルは、±M画素以内(M:自然数)に限定するようにしてもよい。このように探索する範囲を限定することで探索に要する演算量を削減することができる。また、対応する画像復号装置においても用意する参照画像が限定されることで参照画像のメモリ量を削減することができる。
このとき、小数画素精度を禁止するようにしてもよい。このようにすることで、さらに探索に要する演算量を削減しながら、参照画像に要するメモリ量を削減することができる。
あるいは、小数画素精度の画素のみに限定するようにしてもよい。例えば、±1画素以内の小数画素精度の画素に限定することで、小数画素精度の高精度な予測を実現しつつ、探索に要する演算量及び参照画像に要するメモリ量を削減することができる。
For the color difference signal, prediction using the same vector as the luminance signal is performed. Alternatively, the search may be performed based on the luminance signal vector, and the difference vector of the luminance signal vector may be encoded. By doing so, the prediction accuracy of the color difference signal can be improved.
This difference vector may be determined independently for each of the U signal and the V signal. By doing so, the degree of freedom is further increased, so that the prediction accuracy of the color difference signal can be further improved.
The difference vector may be limited to within ± M pixels (M: natural number). By limiting the search range in this way, the calculation amount required for the search can be reduced. Moreover, the memory amount of a reference image can be reduced by limiting the reference image prepared also in the corresponding image decoding apparatus.
At this time, decimal pixel accuracy may be prohibited. In this way, it is possible to reduce the amount of memory required for the reference image while further reducing the amount of calculation required for the search.
Alternatively, it may be limited to only pixels with decimal pixel accuracy. For example, by limiting to pixels with decimal pixel accuracy within ± 1 pixel, it is possible to reduce the calculation amount required for search and the memory amount required for the reference image while realizing high-precision prediction with decimal pixel accuracy.

動き補償予測部7は、輝度信号の予測画像の生成については常に動き補償予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、符号化制御部1により当該予測ブロックの色信号間予測フラグがONに設定されている場合、動き補償予測処理を実施せずに、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。一方、符号化制御部1により当該予測ブロックの色信号間予測フラグがOFFに設定されている場合は、色差信号も動き補償予測処理を実施する。   The motion compensation prediction unit 7 always performs motion compensation prediction processing for the generation of a prediction image of a luminance signal, but the generation of a prediction image of a color difference signal is performed by the encoding control unit 1 for each prediction block. When the inter-color signal prediction flag of the prediction block is set to ON, the color that generates the prediction image of the color difference signal in the prediction block with reference to the encoded color signal without performing the motion compensation prediction process Perform inter-signal prediction processing. On the other hand, if the inter-color signal prediction flag of the prediction block is set to OFF by the encoding control unit 1, the color difference signal is also subjected to motion compensation prediction processing.

ここで、イントラ予測部5、イントラブロックコピー予測部6又は動き補償予測部7が、色信号間予測処理を実施して、色差信号の予測画像を生成する際の処理内容を具体的に説明する。
色信号間予測パラメータに含まれているフラグがONである場合、色差信号では、イントラ予測処理、イントラブロックコピー予測処理、動き補償予測処理を行わず、図45に示すように、色信号間ベクトルが指し示す符号化済みの色差信号のブロックを参照して予測画像を生成する。
Here, the processing contents when the intra prediction unit 5, the intra block copy prediction unit 6, or the motion compensation prediction unit 7 performs the inter-color signal prediction process and generates the predicted image of the color difference signal will be specifically described. .
When the flag included in the inter-color signal prediction parameter is ON, the intra-color signal vector is not performed on the color difference signal without performing the intra prediction process, the intra block copy prediction process, and the motion compensation prediction process, as shown in FIG. The prediction image is generated with reference to the block of the encoded color difference signal indicated by.

図46は入力信号フォーマットがYUV4:4:4フォーマットの信号であり、予測画像の生成対象ブロックが8×8画素である場合の色信号間予測の一例を示す説明図である。
図46の灰色の画素で示す予測画像生成対象ブロックと、参照する符号化済み色信号のブロックの上及び左に隣接している複数の画素を用いて、参照する符号化済み色信号のブロックの画素値と、予測対象の色差信号の予測画像の画素値との相関を示す相関パラメータを算出し、その相関パラメータによって補正された対応する符号化済み色差信号のブロックの画素値を色差信号の予測画像の画素値とする。相関パラメータによる画素値の補正式は下記の通りである。
補正式: (予測画像の画素値)=α×(参照ブロックの画素値)+β
補正式において、α、βは相関パラメータを示し、α、βのうち、どちらか一方のみで補正するものとしても良い。具体的には、以下の通りである。
(予測画像の画素値)=α×(参照ブロックの画素値)
あるいは、
(予測画像の画素値)=(参照ブロックの画素値)+β
このようにすることで、相関パラメータの算出に要する演算量を削減することができる。
FIG. 46 is an explanatory diagram showing an example of inter-color signal prediction when the input signal format is a YUV 4: 4: 4 format signal and the predicted image generation target block is 8 × 8 pixels.
The prediction image generation target block indicated by gray pixels in FIG. 46 and a plurality of pixels adjacent to the upper side and the left side of the encoded color signal block to be referred to A correlation parameter indicating the correlation between the pixel value and the pixel value of the predicted image of the color difference signal to be predicted is calculated, and the pixel value of the corresponding encoded color difference signal block corrected by the correlation parameter is predicted for the color difference signal. The pixel value of the image. The correction formula of the pixel value by the correlation parameter is as follows.
Correction formula: (pixel value of predicted image) = α × (pixel value of reference block) + β
In the correction formula, α and β indicate correlation parameters, and correction may be made with only one of α and β. Specifically, it is as follows.
(Pixel value of predicted image) = α × (pixel value of reference block)
Or
(Pixel value of predicted image) = (Pixel value of reference block) + β
By doing so, it is possible to reduce the amount of calculation required for calculating the correlation parameter.

ただし、予測画像生成対象ブロックの単位は、符号化ブロック単位、予測ブロック単位、変換ブロック単位のいずれでもよい。一般に、小さいブロック単位で予測を行うことで予測精度は向上するが、相関パラメータの算出処理に要する演算量が増加するため、構成する画像符号化装置の演算性能等に応じて構成すればよい。例えば、演算時間の制約がなく複雑な計算を許容できる場合は、符号化ブロックのブロックサイズ以下のブロックサイズとなる予測ブロックや変換ブロック単位で予測画像生成処理を行うように構成することで高精度な予測を実現することができる。例えば、イントラ予測部5では予測画像を生成する単位である変換ブロック、イントラブロックコピー予測部6及び動き補償予測部7では予測ブロックとすることで高精度な予測を実現することができる。
なお、イントラブロックコピー予測部6及び動き補償予測部7において、予測画像生成対象ブロックの単位を予測ブロック単位とする場合、当該符号化ブロック内の画素は符号化されていないため、各予測ブロックの相関パラメータは、各予測ブロックが属する符号化ブロックに隣接する画素を参照して算出する。図47に符号化ブロックを左右に2分割している予測ブロックの例を示す。このとき、灰色の画素で示す当該符号化ブロックに隣接する画素を用いて予測ブロックの相関パラメータを算出する。したがって、予測ブロックの分割状態に関わらず、符号化ブロック内の各予測ブロックの相関パラメータは同一となる。
あるいは、図47の灰色の画素の内、当該予測ブロック(予測画像生成対象ブロック)に隣接する画素のみを用いて相関パラメータを算出するようにしても良い。このようにすることで、当該予測ブロックに隣接した、当該予測ブロック内の画素との相関の高い画素のみから相関パラメータが算出されるため、パラメータ算出精度を高めることができる。さらに、パラメータ算出処理で参照する灰色の画素数を常に2のべき乗としてもよい。このようにすることで、相関パラメータの算出式を簡易化でき、演算量を削減することができる。なお、上述した相関パラメータの算出例は全て2のべき乗となる。
However, the unit of the prediction image generation target block may be any of an encoding block unit, a prediction block unit, and a transform block unit. In general, prediction accuracy is improved by performing prediction in units of small blocks. However, since the amount of calculation required for correlation parameter calculation processing increases, it may be configured according to the calculation performance of the image encoding device to be configured. For example, when there is no constraint on the calculation time and complex calculations can be tolerated, high accuracy can be achieved by performing prediction image generation processing in units of prediction blocks or transform blocks that have a block size that is smaller than the block size of the coding block. Can be realized. For example, the intra prediction unit 5 can realize a highly accurate prediction by using a transform block as a unit for generating a predicted image, the intra block copy prediction unit 6 and the motion compensation prediction unit 7 as a prediction block.
In addition, in the intra block copy prediction unit 6 and the motion compensation prediction unit 7, when the unit of the prediction image generation target block is a prediction block unit, the pixels in the coding block are not coded. The correlation parameter is calculated with reference to pixels adjacent to the coding block to which each prediction block belongs. FIG. 47 shows an example of a prediction block in which an encoded block is divided into left and right parts. At this time, the correlation parameter of the prediction block is calculated using pixels adjacent to the encoded block indicated by gray pixels. Therefore, the correlation parameter of each prediction block in the encoded block is the same regardless of the division state of the prediction block.
Or you may make it calculate a correlation parameter using only the pixel adjacent to the said prediction block (prediction image production | generation object block) among the gray pixels of FIG. By doing in this way, since the correlation parameter is calculated only from the pixel adjacent to the prediction block and having high correlation with the pixel in the prediction block, the parameter calculation accuracy can be improved. Further, the number of gray pixels referred to in the parameter calculation process may always be a power of two. By doing in this way, the calculation formula of a correlation parameter can be simplified and the amount of calculation can be reduced. Note that all of the above-described correlation parameter calculation examples are powers of 2.

上記の例では、相関パラメータを算出して符号化済み色差信号のブロックの画素値を補正するとしているが、相関パラメータを算出せずに、符号化済み色差信号のブロックの画素値をそのまま予測画像の画素値とするように画像符号化装置を構成してもよい。このようにすることで、相関パラメータを算出する演算処理が不要となり、演算量を削減することができる。
なお、入力信号フォーマットがYUV4:2:0フォーマットあるいはYUV4:2:2フォーマットの場合は、参照する符号化済み色信号を予測画像生成対象ブロックと同一のサイズとなるようにブロックサイズをスケーリングして参照する。
具体的には、YUV4:2:0フォーマットの場合、輝度(Y)信号を参照する際には縦及び横のサイズを1/2に縮小した輝度信号を用いる。同様に、YUV4:2:2フォーマットの場合、輝度(Y)信号を参照する際には横のサイズを1/2に縮小した輝度信号を用いる。
また、色信号間ベクトルは±M画素以内(M:自然数)に限定するようにしてもよい。このように探索する範囲を限定することで探索に要する演算量を削減することができる。
また、対応する画像復号装置においても用意する参照画像が限定されることで参照画像のメモリ量を削減することができる。このとき、小数画素精度を禁止するようにしてもよい。このようにすることで、さらに探索に要する演算量を削減しながら、参照画像に要するメモリ量を削減することができる。
あるいは、小数画素精度の画素のみに限定するようにしてもよい。例えば、±1画素以内の小数画素精度の画素に限定することで、小数画素精度の高精度な予測を実現しつつ、探索に要する演算量及び参照画像に要するメモリ量を削減することができる。
In the above example, the correlation parameter is calculated to correct the pixel value of the block of the encoded chrominance signal, but the pixel value of the block of the encoded chrominance signal is directly used as the predicted image without calculating the correlation parameter. The image encoding device may be configured to have a pixel value of. By doing in this way, the calculation process which calculates a correlation parameter becomes unnecessary, and the amount of calculations can be reduced.
When the input signal format is YUV4: 2: 0 format or YUV4: 2: 2 format, the block size is scaled so that the encoded color signal to be referenced has the same size as the prediction image generation target block. refer.
Specifically, in the YUV 4: 2: 0 format, when referring to the luminance (Y) signal, a luminance signal in which the vertical and horizontal sizes are reduced to ½ is used. Similarly, in the case of the YUV 4: 2: 2 format, when referring to the luminance (Y) signal, a luminance signal in which the horizontal size is reduced to ½ is used.
Further, the color signal vector may be limited to within ± M pixels (M: natural number). By limiting the search range in this way, the calculation amount required for the search can be reduced.
Moreover, the memory amount of a reference image can be reduced by limiting the reference image prepared also in the corresponding image decoding apparatus. At this time, decimal pixel accuracy may be prohibited. In this way, it is possible to reduce the amount of memory required for the reference image while further reducing the amount of calculation required for the search.
Alternatively, it may be limited to only pixels with decimal pixel accuracy. For example, by limiting to pixels with decimal pixel accuracy within ± 1 pixel, it is possible to reduce the calculation amount required for search and the memory amount required for the reference image while realizing high-precision prediction with decimal pixel accuracy.

上記の例では、色信号間予測処理として、色信号間ベクトルが指し示す符号化済み色信号のブロックを参照して予測画像を生成するようにしているが、常に、予測画像生成対象ブロックと同一位置のブロックを参照するように構成してもよい。一般に、同一位置の符号化済み色信号のブロックは絵柄が一致する可能性が高いため、このようにすることで、予測精度の低下を抑制しながら、色信号間ベクトルを符号化せずに済むため符号量を削減することができる。
また、参照する符号化済み色信号について、Y(輝度)信号、U信号、V信号の順番で符号化する場合、U信号はY信号、V信号はY信号又はU信号を参照する。このとき、V信号については、Y信号とU信号のどちらを参照するかを画像符号化装置と画像復号装置共通で固定的に構成してもよいし(例えば、常にU信号を参照するように構成する)、どちらを参照するかを切り替え可能として、その切り替え単位毎に参照信号情報を符号化するようにしてもよい。
切り替えの単位は、シーケンス、ピクチャ、スライス単位としてもよいし、符号化ブロック、予測ブロック、変換ブロック等のブロック単位としてもよい。一般に、切り替え単位が細かい程予測効率は高くなる。一方、切り替え単位を大まかにすることで符号化する参照信号情報を符号化する際に発生する符号量を抑えることができる。
In the above example, as the inter-color signal prediction process, the prediction image is generated with reference to the block of the encoded color signal indicated by the inter-color signal vector, but is always at the same position as the prediction image generation target block. You may comprise so that the block of this may be referred. In general, the blocks of the encoded color signal at the same position are likely to have the same pattern, and thus, it is not necessary to encode the inter-color signal vector while suppressing a decrease in prediction accuracy. Therefore, the code amount can be reduced.
When the encoded color signal to be referenced is encoded in the order of Y (luminance) signal, U signal, and V signal, the U signal refers to the Y signal, and the V signal refers to the Y signal or U signal. At this time, with respect to the V signal, it may be fixedly configured to refer to either the Y signal or the U signal in common to the image encoding device and the image decoding device (for example, the U signal is always referred to). The reference signal information may be encoded for each switching unit.
The unit of switching may be a sequence, a picture, a slice unit, or a block unit such as an encoded block, a prediction block, or a transform block. In general, the smaller the switching unit, the higher the prediction efficiency. On the other hand, the amount of code generated when encoding the reference signal information to be encoded can be suppressed by roughly setting the switching unit.

さらに、ブロック単位に参照信号を切り替え可能とする場合、シーケンスレベルヘッダ、ピクチャレベルヘッダ、スライスレベルヘッダに上記ブロック単位の切り替え処理を有効とするか否かを示すフラグを持つようにしてもよい。このようにすることで、本切り替え処理が効果的な場合のみ有効とするようにして、本切り替え処理が効果的でない場合に上記ブロック単位の参照信号情報を符号化せずに済み、符号化効率を高めることができる。
上記の例では、上記の参照信号情報について、Y信号とU信号のどちらを参照するかを決定する情報として説明したが、さらにY信号とU信号を共に参照して重み付き平均によって参照ブロックを生成する場合も含めるようにしてもよい。即ち、設定した切り替え単位毎に、Y信号のみを参照して予測画像を生成するか、U信号のみを参照して予測画像を生成するか、Y信号とU信号を共に参照して予測画像を生成するかを選択するようにする。このようにすることで、より高精度な予測を実現することができる。
Further, when the reference signal can be switched in units of blocks, a flag indicating whether or not the switching processing in units of blocks is valid may be included in the sequence level header, picture level header, and slice level header. In this way, only when this switching process is effective, it is effective. When this switching process is not effective, it is not necessary to encode the reference signal information for each block, and the encoding efficiency is improved. Can be increased.
In the above example, the reference signal information has been described as information for determining whether to refer to the Y signal or the U signal, but the reference block is further determined by weighted averaging with reference to both the Y signal and the U signal. You may make it also include the case where it produces | generates. That is, for each set switching unit, a predicted image is generated with reference to only the Y signal, a predicted image is generated with reference to only the U signal, or a predicted image is referred to with reference to both the Y signal and the U signal. Select whether to generate. In this way, more accurate prediction can be realized.

色信号間予測処理は、予測ブロック単位に実施の有無を選択し、その実施の有無を示すフラグを色信号間予測パラメータとして符号化する。色信号間予測処理がOFFの予測ブロックは、輝度信号と同一の予測部(イントラ予測部5、イントラブロックコピー予測部6あるいは動き補償予測部7)で予測を実施する。したがって、イントラ予測部5の色差信号のイントラ予測パラメータのうち、色信号間予測を行わない予測ブロックのイントラ予測パラメータだけを符号化する。
同様に、イントラブロックコピー予測部6あるいは動き補償予測部7で色差信号用の差分ベクトルを符号化するように構成している場合、上記のフラグがOFFの予測ブロックのみの色差信号用の差分ベクトルを符号化する。ただし、輝度信号と色差信号でイントラブロックコピー予測パラメータあるいはインター予測パラメータを共通とするように画像符号化装置を構成する場合、上記ブロックシフトベクトルあるいは動きベクトルは常に輝度信号と色差信号で同一であるため、差分ベクトルは符号化しない。対応する画像復号装置は、輝度信号のイントラブロックコピー予測パラメータあるいはインター予測パラメータを色差信号でも用いるように構成する。もしくは、色差信号の差分ベクトルは常に0と解釈するように構成する。
また、イントラ予測部5の色差信号のイントラ予測パラメータと色信号間予測フラグを組み合わせて、図48に示すような色差信号のイントラ予測パラメータとして符号化するようにしてもよい。この場合、イントラ予測パラメータが色信号間予測処理を示す場合に色信号間予測処理を行うものとし、それ以外の場合は、イントラ予測パラメータに従ってイントラ予測を実施する。
In the inter-color signal prediction process, the presence or absence of execution is selected for each prediction block, and a flag indicating the presence or absence of the execution is encoded as an inter-color signal prediction parameter. The prediction block in which the inter-color signal prediction process is OFF is predicted by the same prediction unit (intra prediction unit 5, intra block copy prediction unit 6 or motion compensation prediction unit 7) as the luminance signal. Therefore, among the intra prediction parameters of the color difference signal of the intra prediction unit 5, only the intra prediction parameters of the prediction block that does not perform inter-color signal prediction are encoded.
Similarly, when the intra block copy prediction unit 6 or the motion compensation prediction unit 7 is configured to encode the difference vector for the color difference signal, the difference vector for the color difference signal of only the prediction block whose flag is OFF. Is encoded. However, when the image coding apparatus is configured so that the intra block copy prediction parameter or the inter prediction parameter is shared between the luminance signal and the color difference signal, the block shift vector or the motion vector is always the same for the luminance signal and the color difference signal. Therefore, the difference vector is not encoded. The corresponding image decoding apparatus is configured to use the intra block copy prediction parameter or the inter prediction parameter of the luminance signal also for the color difference signal. Alternatively, the color difference signal difference vector is always interpreted as zero.
Further, the intra prediction parameter of the color difference signal of the intra prediction unit 5 and the inter-color signal prediction flag may be combined and encoded as the intra prediction parameter of the color difference signal as shown in FIG. In this case, when the intra prediction parameter indicates the inter-color signal prediction process, the inter-color signal prediction process is performed. In other cases, the intra prediction is performed according to the intra prediction parameter.

上記の例では、予測ブロック単位に色信号間予測処理の実施の有無を選択しているが、符号化ブロック単位あるいは最大サイズの符号化ブロック単位に実施の有無を選択するようにしてもよい。このようにすることで色信号間予測の切り替え単位が大きくなって予測効率は低下するが、色信号間予測フラグの符号化に要する符号量を削減することができる。
さらに、符号化済み色信号の参照信号情報と色信号間予測フラグを一つの情報としてもよい。即ち、参照信号情報に、色信号間予測処理を行わない(符号化済み色信号を参照しない)場合も含めるようにしてもよい。
In the above example, the presence / absence of execution of the inter-color signal prediction process is selected for each prediction block. However, the presence / absence of the execution may be selected for each coding block or each coding block having the maximum size. By doing so, the switching unit of the inter-color signal prediction becomes large and the prediction efficiency decreases, but the amount of code required for encoding the inter-color signal prediction flag can be reduced.
Further, the reference signal information of the encoded color signal and the inter-color signal prediction flag may be one information. That is, the reference signal information may include a case where the inter-color signal prediction process is not performed (the encoded color signal is not referred to).

減算部8は、ブロック分割部3から符号化ブロックBを受けると、その符号化ブロックB内の予測ブロックP から、イントラ予測部5により生成されたイントラ予測画像PINTRAi 、イントラブロックコピー予測部6により生成されたイントラブロックコピー予測画像PICOPYi 、又は、動き補償予測部7により生成されたインター予測画像PINTERi のいずれかを減算して、その減算結果である差分画像を示す予測差分信号e を変換・量子化部9に出力する(ステップST7)。 Subtracting unit 8 receives the encoded block B n from the block dividing unit 3, from its prediction block P i n the coded block B n, the intra prediction image P INTRAi n generated by the intra prediction unit 5, the intra block copy prediction unit 6 intra block copy predicted image P ICOPYi n generated by, or subtracts one of the inter-prediction image P INTERi n generated by the motion compensation prediction unit 7, which is the subtraction result difference image the prediction difference signal e i n that indicates the output to transform and quantization unit 9 (step ST7).

変換・量子化部9は、減算部8から予測差分信号e を受けると、符号化制御部1により決定された予測差分符号化パラメータに含まれる変換ブロック分割情報を参照して、その予測差分信号e に対する直交変換処理(例えば、DCT(離散コサイン変換)やDST(離散サイン変換)、予め特定の学習系列に対して基底設計がなされているKL変換等の直交変換処理)を変換ブロック単位に実施して、変換係数を算出する。
また、変換・量子化部9は、その予測差分符号化パラメータに含まれる量子化パラメータを参照して、その変換ブロック単位の変換係数を量子化し、量子化後の変換係数である圧縮データを逆量子化・逆変換部10及び可変長符号化部15に出力する(ステップST8)。このとき、上記量子化パラメータから算出される量子化ステップサイズを変換係数毎にスケーリングする量子化マトリクスを用いて量子化処理を実施するようにしてもよい。
When the transform / quantization unit 9 receives the prediction difference signal e i n from the subtraction unit 8, the transform / quantization unit 9 refers to the transform block division information included in the prediction difference encoding parameter determined by the encoding control unit 1, and performs the prediction. orthogonal transform processing with respect to the difference signal e i n (e.g., DCT (discrete cosine transform) or DST (discrete sine transform), the orthogonal transform for KL conversion and the base design have been made in advance to the particular learning sequence) to transform This is performed for each block, and a conversion coefficient is calculated.
Further, the transform / quantization unit 9 refers to the quantization parameter included in the prediction differential encoding parameter, quantizes the transform coefficient of the transform block unit, and reverses the compressed data that is the transform coefficient after quantization. It outputs to the quantization / inverse transform unit 10 and the variable length coding unit 15 (step ST8). At this time, the quantization process may be performed using a quantization matrix that scales the quantization step size calculated from the quantization parameter for each transform coefficient.

量子化マトリクスは、各直交変換サイズで色信号や符号化モード(イントラ符号化かインター符号化か)毎に独立しているマトリクスを使用することができ、初期値として、画像符号化装置及び画像復号装置で、予め共通に用意されている量子化マトリクスや既に符号化された量子化マトリクスの中から選択するか、新しい量子化マトリクスを用いるかをそれぞれ選択することができる。
したがって、変換・量子化部9は、各直交変換サイズに対して色信号や符号化モード毎に、新しい量子化マトリクスを用いるか否かを示すフラグを符号化すべき量子化マトリクスパラメータに設定する。
さらに、新しい量子化マトリクスを用いる場合には、図10に示すような量子化マトリクスの各スケーリング値を符号化すべき量子化マトリクスパラメータに設定する。
一方、新しい量子化マトリクスを用いない場合には、初期値として、画像符号化装置及び画像復号装置で、予め共通に用意されている量子化マトリクス、又は、既に符号化された量子化マトリクスの中から、使用するマトリクスを特定するインデックスを符号化すべき量子化マトリクスパラメータに設定する。ただし、参照可能な既に符号化された量子化マトリクスが存在しない場合、画像符号化装置及び画像復号装置で、予め共通に用意されている量子化マトリクスのみ選択可能となる。
そして、変換・量子化部9は、設定した量子化マトリクスパラメータを可変長符号化部15に出力する。
As the quantization matrix, an independent matrix can be used for each color signal and coding mode (intra coding or inter coding) at each orthogonal transform size. As an initial value, an image coding device and an image are used. In the decoding apparatus, it is possible to select whether to use a previously prepared quantization matrix or an already encoded quantization matrix or to use a new quantization matrix.
Accordingly, the transform / quantization unit 9 sets a flag indicating whether or not to use a new quantization matrix for each orthogonal transform size for each color signal or coding mode, as a quantization matrix parameter to be encoded.
Furthermore, when a new quantization matrix is used, each scaling value of the quantization matrix as shown in FIG. 10 is set as a quantization matrix parameter to be encoded.
On the other hand, when a new quantization matrix is not used, as an initial value, a quantization matrix prepared in advance in the image encoding device and the image decoding device, or a quantization matrix that has already been encoded is used. Therefore, an index for specifying a matrix to be used is set as a quantization matrix parameter to be encoded. However, when there is no already-encoded quantization matrix that can be referred to, only the quantization matrix prepared in advance can be selected in advance in the image encoding device and the image decoding device.
Then, the transform / quantization unit 9 outputs the set quantization matrix parameter to the variable length coding unit 15.

逆量子化・逆変換部10は、変換・量子化部9から圧縮データを受けると、符号化制御部1により決定された予測差分符号化パラメータに含まれる量子化パラメータ及び変換ブロック分割情報を参照して、変換ブロック単位にその圧縮データを逆量子化する。
変換・量子化部9が量子化処理に量子化マトリクスを用いている場合には、逆量子化処理時においても、その量子化マトリクスを参照して、対応した逆量子化処理を実施する。
また、逆量子化・逆変換部10は、変換ブロック単位に逆量子化後の圧縮データである変換係数に対する逆直交変換処理(例えば、逆DCT、逆DST、逆KL変換など)を実施して、減算部8から出力された予測差分信号e に相当する局所復号予測差分信号を算出して加算部11に出力する(ステップST9)。
When the inverse quantization / inverse transform unit 10 receives the compressed data from the transform / quantization unit 9, the inverse quantization / inverse transform unit 10 refers to the quantization parameter and transform block division information included in the prediction difference coding parameter determined by the coding control unit 1 Then, the compressed data is inversely quantized for each transform block.
When the transform / quantization unit 9 uses a quantization matrix for the quantization process, the corresponding inverse quantization process is performed with reference to the quantization matrix even during the inverse quantization process.
Further, the inverse quantization / inverse transform unit 10 performs inverse orthogonal transform processing (for example, inverse DCT, inverse DST, inverse KL transform, etc.) on transform coefficients that are compressed data after inverse quantization for each transform block. Then, a local decoded prediction difference signal corresponding to the prediction difference signal e i n output from the subtraction unit 8 is calculated and output to the addition unit 11 (step ST9).

加算部11は、逆量子化・逆変換部10から局所復号予測差分信号を受けると、その局所復号予測差分信号と、イントラ予測部5により生成されたイントラ予測画像PINTRAi 、イントラブロックコピー予測部6により生成されたイントラブロックコピー予測画像PICOPYi 、又は、動き補償予測部7により生成されたインター予測画像PINTERi のいずれかを加算することで、局所復号画像を算出する(ステップST10)。
なお、加算部11は、その局所復号画像をループフィルタ部13に出力するとともに、その局所復号画像をイントラ用メモリ12に格納する。
この局所復号画像が、以降のイントラ予測処理及びイントラブロックコピー予測処理の際に用いられる符号化済みの画像信号になる。
Addition unit 11, when the inverse quantization and inverse transform unit 10 receives the local decoded prediction difference signal, and the local decoded prediction difference signal, an intra prediction image P INTRAi n generated by the intra prediction unit 5, the intra block copy prediction part 6 intra block copy predicted image P ICOPYi n generated by, or by adding one of the inter-prediction image P INTERi n generated by the motion compensation prediction unit 7 calculates a local decoded image (step ST10 ).
The adding unit 11 outputs the locally decoded image to the loop filter unit 13 and stores the locally decoded image in the intra memory 12.
This locally decoded image becomes an encoded image signal used in the subsequent intra prediction process and intra block copy prediction process.

ループフィルタ部13は、加算部11から局所復号画像を受けると、その局所復号画像に対して、所定のフィルタ処理を実施して、フィルタ処理後の局所復号画像を動き補償予測フレームメモリ14に格納する(ステップST11)。
具体的には、変換ブロックの境界や予測ブロックの境界に発生する歪みを低減するフィルタ(デブロッキングフィルタ)処理、画素単位に適応的にオフセットを加算する(画素適応オフセット)処理、ウィーナフィルタ等の線形フィルタを適応的に切り替えてフィルタ処理する適応フィルタ処理などを行う。
When the loop filter unit 13 receives the local decoded image from the adder unit 11, the loop filter unit 13 performs a predetermined filter process on the local decoded image, and stores the filtered local decoded image in the motion compensated prediction frame memory 14. (Step ST11).
Specifically, filter (deblocking filter) processing that reduces distortion occurring at the boundaries of transform blocks and prediction blocks, processing for adaptively adding an offset (pixel adaptive offset) for each pixel, Wiener filter, etc. Performs adaptive filter processing for adaptively switching linear filters and performing filter processing.

ただし、ループフィルタ部13は、上記のデブロッキングフィルタ処理、画素適応オフセット処理、適応フィルタ処理のそれぞれについて、処理を行うか否かを決定し、各処理の有効フラグをシーケンスレベルヘッダの一部及びスライスレベルヘッダの一部として可変長符号化部15に出力する。なお、上記のフィルタ処理を複数使用する際は、各フィルタ処理を順番に実施する。図11は複数のフィルタ処理を用いる場合のループフィルタ部13の構成例を示している。
一般に使用するフィルタ処理の種類が多いほど、画像品質は向上するが、一方で処理負荷は高くなる。即ち、画像品質と処理負荷はトレードオフの関係にある。また、各フィルタ処理の画像品質改善効果はフィルタ処理対象画像の特性によって異なる。したがって、画像符号化装置が許容する処理負荷や符号化処理対象画像の特性にしたがって使用するフィルタ処理を決めればよい。
However, the loop filter unit 13 determines whether or not to perform processing for each of the above deblocking filter processing, pixel adaptive offset processing, and adaptive filter processing, and sets a valid flag of each processing as a part of the sequence level header and It outputs to the variable length encoding part 15 as a part of slice level header. When a plurality of the above filter processes are used, each filter process is performed in order. FIG. 11 shows a configuration example of the loop filter unit 13 when a plurality of filter processes are used.
Generally, the more types of filter processing that are used, the better the image quality, but the higher the processing load. That is, image quality and processing load are in a trade-off relationship. In addition, the image quality improvement effect of each filter process varies depending on the characteristics of the image to be filtered. Therefore, the filter processing to be used may be determined according to the processing load allowed by the image encoding device and the characteristics of the encoding target image.

ここで、デブロッキングフィルタ処理では、ブロック境界にかけるフィルタ強度の選択に用いる各種パラメータを初期値から変更することができる。変更する場合には、そのパラメータをヘッダ情報として可変長符号化部15に出力する。   Here, in the deblocking filter process, various parameters used for selecting the filter strength applied to the block boundary can be changed from the initial values. When changing, the parameter is output to the variable length coding unit 15 as header information.

画素適応オフセット処理では、最初に、画像を複数のブロックに分割し、そのブロック単位に、オフセット処理を行わない場合もクラス分類手法の一つとして定義して、予め用意している複数のクラス分類手法の中から、1つのクラス分類手法を選択する。
次に、選択したクラス分類手法によってブロック内の各画素をクラス分類し、クラス毎に符号化歪みを補償するオフセット値を算出する。
最後に、局所復号画像の画素値に対して、そのオフセット値を加算する処理を行うことで局所復号画像の画像品質を改善する。
In the pixel adaptive offset process, first, an image is divided into a plurality of blocks, and when the offset process is not performed for each block, it is defined as one of the class classification methods, and a plurality of class classifications prepared in advance are provided. One classification method is selected from the methods.
Next, each pixel in the block is classified by the selected class classification method, and an offset value for compensating for the coding distortion is calculated for each class.
Finally, the image quality of the locally decoded image is improved by performing a process of adding the offset value to the pixel value of the locally decoded image.

クラス分類手法としては、局所復号画像の画素値の大きさで分類する手法(BO手法と呼ぶ)や、エッジの方向毎に各画素の周囲の状況(エッジ部か否か等)に応じて分類する手法(EO手法と呼ぶ)がある。
これらの手法は、予め画像符号化装置及び画像復号装置で共通に用意されており、例えば図14に示すように、オフセット処理を行わない場合もクラス分類手法の一つとして定義して、これらの手法のうち、どの手法でクラス分類を行うかを示すインデックスを上記ブロック単位に選択する。
As a classifying method, a method of classifying by the size of a pixel value of a locally decoded image (referred to as a BO method), or a classification according to a situation around each pixel (whether it is an edge portion or the like) for each edge direction. There is a technique (referred to as EO technique).
These methods are prepared in advance by the image encoding device and the image decoding device in advance. For example, as shown in FIG. 14, when no offset processing is performed, these methods are defined as one of the class classification methods. Of the methods, an index indicating which method is used for class classification is selected for each block.

したがって、画素適応オフセット処理は、ブロックの分割情報、ブロック単位のクラス分類手法を示すインデックス、ブロック単位のオフセット情報をヘッダ情報として可変長符号化部15に出力する。
なお、画素適応オフセット処理において、例えば最大符号化ブロックといった固定サイズのブロック単位に常に分割して、そのブロック毎にクラス分類手法を選択して、クラス毎の適応オフセット処理を行ってもよい。この場合、上記ブロック分割情報が不要となり、ブロック分割情報に要する符号量分だけ符号量が削減され、符号化効率を高めることができる。
Therefore, the pixel adaptive offset processing outputs the block division information, the index indicating the class classification method for each block, and the offset information for each block to the variable length encoding unit 15 as header information.
In the pixel adaptive offset processing, the adaptive offset processing may be performed for each class by always dividing the block into fixed-size blocks such as a maximum coding block and selecting a class classification method for each block. In this case, the block division information becomes unnecessary, the code amount is reduced by the amount of code required for the block division information, and the coding efficiency can be improved.

また、適応フィルタ処理では、局所復号画像を所定の手法でクラス分類し、各クラスに属する領域(局所復号画像)毎に、重畳されている歪みを補償するフィルタを設計し、そのフィルタを用いて、当該局所復号画像のフィルタ処理を実施する。
そして、クラス毎に設計したフィルタをヘッダ情報として可変長符号化部15に出力する。
ここで、クラス分類手法としては、画像を空間的に等間隔に区切る簡易な手法や、ブロック単位に画像の局所的な特性(分散など)に応じて分類する手法がある。また、適応フィルタ処理で使用するクラス数は、予め画像符号化装置及び画像復号装置で共通の値に設定してもよいし、符号化すべきパラメータの一つとしてもよい。
前者と比較して後者の方が、使用するクラス数を自由に設定することができるため、画像品質改善効果が上がるが、一方でクラス数を符号化するために、その分の符号量が増加する。
Also, in adaptive filter processing, local decoded images are classified by a predetermined method, and a filter that compensates for superimposed distortion is designed for each region (local decoded image) belonging to each class. Then, the local decoded image is filtered.
Then, the filter designed for each class is output to the variable length encoding unit 15 as header information.
Here, as a class classification method, there are a simple method for spatially dividing an image at equal intervals, and a method for classifying an image according to local characteristics (dispersion, etc.) of the image in units of blocks. Further, the number of classes used in the adaptive filter process may be set in advance to a common value in the image encoding device and the image decoding device, or may be one of the parameters to be encoded.
Compared to the former, the latter can set the number of classes to be used freely, so the image quality improvement effect will be improved, but on the other hand, the amount of code will be increased to encode the number of classes. To do.

ステップST3〜ST10の処理は、階層的に分割された全ての符号化ブロックBに対する処理が完了するまで繰り返し実施され、全ての符号化ブロックBに対する処理が完了すると、ステップST14の処理に移行する(ステップST12,ST13)。 The processes of steps ST3 to ST10 are repeatedly performed until the processes for all the coding blocks Bn divided hierarchically are completed, and when the processes for all the coding blocks Bn are completed, the process proceeds to the process of step ST14. (Steps ST12 and ST13).

可変長符号化部15は、変換・量子化部9から出力された圧縮データと、符号化制御部1から出力された最大符号化ブロック内のブロック分割情報(図6(b)を例とする4分木情報)、符号化モードm(B)及び予測差分符号化パラメータと、符号化制御部1から出力されたイントラ予測パラメータ(符号化モードがイントラ符号化モードである場合)、イントラブロックコピー予測パラメータ(符号化モードがイントラブロックコピー符号化モードである場合)又はインター予測パラメータ(符号化モードがインター符号化モードである場合)と、色信号間予測フラグを含む色信号間予測パラメータと、動き補償予測部7から出力された動きベクトル(符号化モードがインター符号化モードである場合)とを可変長符号化し、それらの符号化結果を示す符号化データを生成する(ステップST14)。 The variable length encoding unit 15 uses the compressed data output from the transform / quantization unit 9 and the block division information (FIG. 6B) in the maximum encoded block output from the encoding control unit 1 as an example. (Quadrant tree information), coding mode m (B n ), prediction differential coding parameter, intra prediction parameter output from coding control unit 1 (when coding mode is intra coding mode), intra block A copy prediction parameter (when the coding mode is an intra block copy coding mode) or an inter prediction parameter (when the coding mode is an inter coding mode), and an inter-color signal prediction parameter including an inter-color signal prediction flag; , Variable-length coding the motion vector output from the motion compensation prediction unit 7 (when the coding mode is the inter coding mode) Generating encoded data indicating the encoding result (step ST14).

その際、量子化された直交変換係数である圧縮データの符号化手法として、変換ブロックをさらにCoefficient Group(CG)と呼ばれる4×4画素単位のブロック(符号化サブブロック)に分割して、CG単位に係数の符号化処理を実施する。
図15は16×16画素の変換ブロックにおける係数の符号化順(スキャン順)を示している。
このように、4×4画素単位の16個のCGを右下のCGから順に符号化処理し、さらに、各CGはCG内の16個の係数を右下の係数から順に符号化する。
At this time, as a method of encoding compressed data that is a quantized orthogonal transform coefficient, the transform block is further divided into blocks of 4 × 4 pixel units (encoding sub-blocks) called Coefficient Group (CG), and CG Coding of coefficients is performed for each unit.
FIG. 15 shows the coding order (scan order) of coefficients in a 16 × 16 pixel transform block.
In this way, 16 CGs in units of 4 × 4 pixels are encoded in order from the lower right CG, and each CG encodes 16 coefficients in the CG in order from the lower right coefficient.

具体的には、まず、CG内の16個の係数の中に有意(非零)係数が存在するか否かのフラグを符号化し、次に、CG内に有意(非零)係数が存在する場合のみ、CG内の各係数が有意(非零)係数であるかを上記順に符号化し、最後に有意(非零)係数に対して、その係数値情報を順に符号化する。これをCG単位に上記順に行う。
その際、有意(非零)係数がなるべく連続で発生するように偏るスキャン順とした方がエントロピー符号化による符号化効率を高めることができる。
直交変換後の係数は、左上に位置する直流成分をはじめとして、左上に近い程、低い周波数成分の低い係数を表すことから、図16に示す例のように、一般的に左上に近いほど有意(非零)係数が多く発生するために、図15に示すように、右下から順に符号化することで効率的に符号化することができる。
なお、上記では16×16画素の変換ブロックについて説明したが、8×8画素や32×32画素の変換ブロック等、16×16画素以外のブロックサイズにおいてもCG(符号化サブブロック)単位の符号化処理を実施するものとする。
また、イントラ予測が選択されている4×4画素と8×8画素の変換ブロックについては、イントラ予測モードのインデックスに応じて、図15のスキャン順ではなく図19に示すスキャン順で処理を行う。これはイントラ予測の方向によって予測差分信号の周波数成分の分布が異なる傾向があるためである。
Specifically, first, a flag indicating whether or not a significant (nonzero) coefficient exists in 16 coefficients in the CG is encoded, and then a significant (nonzero) coefficient exists in the CG. Only in the case, whether each coefficient in the CG is a significant (non-zero) coefficient is encoded in the above order, and finally, the coefficient value information is encoded in order for the significant (non-zero) coefficient. This is performed in the above order in units of CG.
In this case, the encoding efficiency by entropy encoding can be increased by using a biased scan order so that significant (non-zero) coefficients are generated as continuously as possible.
Since the coefficient after orthogonal transformation represents the lower coefficient of the lower frequency component as it is closer to the upper left, starting with the DC component located at the upper left, generally, the closer to the upper left, the more significant as the example is shown in FIG. Since many (non-zero) coefficients are generated, as shown in FIG. 15, encoding can be performed efficiently by encoding sequentially from the lower right.
In the above description, a 16 × 16 pixel conversion block has been described. However, in a block size other than 16 × 16 pixels, such as an 8 × 8 pixel conversion block or a 32 × 32 pixel conversion block, a code in CG (encoding sub-block) unit is used. It shall be implemented.
Further, the 4 × 4 pixel and 8 × 8 pixel conversion blocks for which intra prediction is selected are processed in the scan order shown in FIG. 19 instead of the scan order shown in FIG. 15 according to the intra prediction mode index. . This is because the frequency component distribution of the prediction difference signal tends to be different depending on the direction of intra prediction.

また、可変長符号化部15は、図13に例示するように、符号化ビットストリームのヘッダ情報として、シーケンスレベルヘッダ、ピクチャレベルヘッダを符号化し、ピクチャデータと共に符号化ビットストリームを生成する。
ただし、ピクチャデータは1以上のスライスデータから構成され、各スライスデータはスライスレベルヘッダと当該スライス内にある上記符号化データをまとめたものである。ピクチャデータはスライスデータの他に補足情報を示すヘッダ情報を含む場合もある。
Further, as illustrated in FIG. 13, the variable length encoding unit 15 encodes a sequence level header and a picture level header as header information of the encoded bit stream, and generates an encoded bit stream together with the picture data.
However, picture data is composed of one or more slice data, and each slice data is a combination of a slice level header and the encoded data in the slice. The picture data may include header information indicating supplementary information in addition to the slice data.

シーケンスレベルヘッダは、画像サイズ、色信号フォーマット、輝度信号や色差信号の信号値のビット深度、シーケンス単位でのループフィルタ部13における各フィルタ処理(適応フィルタ処理、画素適応オフセット処理、デブロッキングフィルタ処理)の有効フラグ、量子化マトリクスの有効フラグなど、一般的にシーケンス単位に共通となるヘッダ情報をまとめたものである。
ピクチャレベルヘッダは、参照するシーケンスレベルヘッダのインデックスや動き補償時の参照ピクチャ数、エントロピー符号化の確率テーブル初期化フラグ等のピクチャ単位で設定するヘッダ情報をまとめたものである。
スライスレベルヘッダは、当該スライスがピクチャのどの位置にあるかを示す位置情報、どのピクチャレベルヘッダを参照するかを示すインデックス、スライスの符号化タイプ(オールイントラ符号化、インター符号化など)、ループフィルタ部13における各フィルタ処理(適応フィルタ処理、画素適応オフセット処理、デブロッキングフィルタ処理)を行うか否かを示すフラグなどといったスライス単位のパラメータをまとめたものである。
The sequence level header includes the image size, the color signal format, the bit depth of the signal value of the luminance signal and the color difference signal, and each filter process (adaptive filter process, pixel adaptive offset process, deblocking filter process) in the loop filter unit 13 in sequence units. In general, header information that is common to each sequence unit, such as a valid flag of () and a valid flag of a quantization matrix, is collected.
The picture level header is a collection of header information set in units of pictures such as an index of a sequence level header to be referenced, the number of reference pictures at the time of motion compensation, an entropy encoding probability table initialization flag, and the like.
The slice level header includes position information indicating where the slice is located in the picture, an index indicating which picture level header is referred to, a slice coding type (all-intra coding, inter coding, etc.), and a loop. This is a summary of parameters in units of slices such as a flag indicating whether or not each filter process (adaptive filter process, pixel adaptive offset process, deblocking filter process) in the filter unit 13 is performed.

各ヘッダ情報とピクチャデータはNALユニットによって識別される。
具体的には、シーケンスパラメータセット(上記シーケンスレベルヘッダに相当)、ピクチャパラメータヘッダ(上記ピクチャレベルヘッダに相当)、スライスデータはそれぞれ固有のNALユニットタイプとして定義され、NALユニットタイプの識別情報(インデックス)と共に符号化される。
補足情報についても存在する場合には、固有のNALユニットとして定義される。また、上記ピクチャデータはアクセスユニットとして定義され、スライスデータを示すNALユニットや補足情報を示すNALユニット等の当該ピクチャに関わるNALユニットをまとめた、各ピクチャのデータアクセスの単位を示している。
Each header information and picture data is identified by a NAL unit.
Specifically, a sequence parameter set (corresponding to the above sequence level header), a picture parameter header (corresponding to the above picture level header), and slice data are each defined as a unique NAL unit type, together with identification information (index) of the NAL unit type Encoded.
If supplementary information also exists, it is defined as a unique NAL unit. The picture data is defined as an access unit, and indicates a unit of data access of each picture in which NAL units related to the picture such as a NAL unit indicating slice data and a NAL unit indicating supplementary information are collected.

次に、イントラ予測部5におけるイントラ予測処理を詳細に説明する。
イントラ予測部5は、上述したように、予測ブロックP のイントラ予測パラメータを参照して、その予測ブロックP に対するイントラ予測処理を実施して、イントラ予測画像PINTRAi を生成するが、ここでは、輝度信号における予測ブロックP のイントラ予測画像を生成するイントラ処理について説明する。
Next, the intra prediction process in the intra prediction unit 5 will be described in detail.
The intra prediction unit 5, as described above, with reference to the intra prediction parameters of the prediction block P i n, to implement intra prediction processing for the prediction block P i n, but to generate an intra prediction image P INTRAi n , will be described here intra process for generating an intra prediction image predicted block P i n in the luminance signal.

図7は符号化ブロックB内の各予測ブロックP が選択可能なイントラ予測モードの一例を示す説明図であり、イントラ予測モードのインデックス値と、そのイントラ予測モードが示す予測方向ベクトルを示している。上記イントラ予測モードのインデックス値がイントラ予測パラメータを示している。
なお、イントラ予測モード数は、処理対象となるブロックのサイズに応じて異なるように構成してもよい。
大きいサイズのブロックでは、イントラ予測の効率が低下するため、選択できるイントラ予測方向数を少なくし、小さいサイズのブロックでは、選択できるイントラ予測方向数を多くするように構成することで演算量を抑制することができる。
Figure 7 is an explanatory diagram showing an example of the prediction block P i n-selectable intra prediction modes for intra-coded blocks B n, and the index value of the intra prediction mode, the prediction direction vector indicated by the intra-prediction mode Show. The index value of the intra prediction mode indicates the intra prediction parameter.
In addition, you may comprise so that the number of intra prediction modes may differ according to the size of the block used as a process target.
Intra-prediction efficiency decreases for large-sized blocks, so the number of selectable intra-prediction directions is reduced, and for small-sized blocks, the number of selectable intra-prediction directions is increased to reduce the amount of computation. can do.

まず、イントラ予測画像を生成する処理は、処理対象のブロックに隣接する符号化済みの画素を用いることから、上述した通り、変換ブロック単位に行われなくてはならない。
ここで、イントラ予測画像を生成する変換ブロックを予測画像生成ブロックと呼ぶこととする。したがって、イントラ予測部5は、予測画像生成ブロック単位に下記に述べるイントラ予測画像生成処理を実施して、予測ブロックP のイントラ予測画像を生成する。
予測画像生成ブロックのサイズをl ×m 画素とする。
図8はl =m =4の場合の予測画像生成ブロック内の画素の予測値を生成する際に用いる画素の一例を示す説明図である。
図8では、予測画像生成ブロックの上の符号化済みの画素(2×l +1)個と、左の符号化済みの画素(2×m )個を予測に用いる画素としているが、予測に用いる画素は、図8に示す画素より多くても少なくてもよい。
また、図8では、予測画像生成ブロックの近傍の1行又は1列分の画素を予測に用いているが、2行又は2列、あるいは、それ以上の画素を予測に用いてもよい。
First, since the process which produces | generates an intra estimated image uses the encoded pixel adjacent to the block of a process target, as above-mentioned, it must be performed per conversion block.
Here, the transform block that generates the intra predicted image is referred to as a predicted image generation block. Therefore, the intra prediction unit 5 may implement an intra-prediction image generation processing described below to the predicted image generation block generates an intra prediction image predicted block P i n.
The size of the predicted image generation block is assumed to be l i n × m i n pixels.
FIG. 8 is an explanatory diagram illustrating an example of a pixel used when generating a predicted value of a pixel in a predicted image generation block in the case of l i n = m i n = 4.
In FIG. 8, the encoded pixels (2 × l i n +1) and the left encoded pixels (2 × m i n ) on the predicted image generation block are used as pixels for prediction. The number of pixels used for prediction may be more or less than the pixels shown in FIG.
Further, in FIG. 8, pixels for one row or one column in the vicinity of the predicted image generation block are used for prediction, but two or two or more pixels may be used for prediction.

予測画像生成ブロックが属する予測ブロックP に対するイントラ予測モードのインデックス値が0(平面(Planar)予測)の場合には、予測画像生成ブロックの上に隣接する符号化済み画素と、予測画像生成ブロックの左に隣接する符号化済み画素を用いて、これら画素と予測画像生成ブロック内の予測対象画素との距離に応じて内挿した値を予測値として予測画像を生成する。 If the index value of the intra prediction mode for prediction block P i n that the predicted image generation block belongs is 0 (plane (Planar) prediction) includes a coded pixels adjacent to the top of the predicted image generation block, the predicted image generation Using the encoded pixels adjacent to the left of the block, a predicted image is generated using a value interpolated according to the distance between these pixels and the prediction target pixel in the predicted image generation block as a predicted value.

予測画像生成ブロックが属する予測ブロックP に対するイントラ予測モードのインデックス値が1(平均値(DC)予測)の場合には、予測画像生成ブロックの上に隣接する符号化済み画素と、予測画像生成ブロックの左に隣接する符号化済み画素の平均値を予測画像生成ブロック内の画素の予測値として予測画像を生成する。
さらに、予測画像生成ブロックの上端及び左端に位置する図17の領域A,B,Cに対して、ブロック境界を平滑化するフィルタ処理を行って最終的な予測画像とする。例えば、下記の式(1)にしたがって、図18のフィルタの参照画素配置で、下記のフィルタ係数を用いてフィルタ処理を実施する。

Figure 0006362370
・領域A(P の左上の画素)
=1/2,a=1/4,a=1/4
・領域B(領域A以外のP の上端の画素)
=3/4,a=1/4,(a=0)
・領域C(領域A以外のP の左端の画素)
=3/4,a=1/4,(a=0) When the index value of the intra prediction mode for the prediction block P i n to which the prediction image generation block belongs is 1 (average (DC) prediction), encoded pixels adjacent to the prediction image generation block and the prediction image A predicted image is generated using the average value of the encoded pixels adjacent to the left of the generated block as the predicted value of the pixels in the predicted image generating block.
Further, the region A, B, C in FIG. 17 located at the upper end and the left end of the predicted image generation block is subjected to filter processing for smoothing the block boundary to obtain a final predicted image. For example, according to the following formula (1), the filter processing is performed using the following filter coefficients in the reference pixel arrangement of the filter of FIG.
Figure 0006362370
· Area A (the upper left pixel of the P i n)
a 0 = 1/2, a 1 = ¼, a 2 = ¼
- region B (the upper end of the pixel of P i n other than the region A)
a 0 = 3/4, a 2 = ¼, (a 1 = 0)
· Area C (the leftmost pixel of the P i n other than the region A)
a 0 = 3/4, a 1 = ¼, (a 2 = 0)

ただし、式(1)において、a(n=0,1,2)は参照画素にかかるフィルタ係数、p(n=0,1,2)はフィルタ処理対象画素pを含むフィルタの参照画素、S’(p)はフィルタ処理対象画素pにおけるフィルタ処理後の予測値、S(p)(n=0,1,2)はフィルタ処理対象画素pを含む参照画素のフィルタ処理前の予測値を表している。 In equation (1), a n (n = 0, 1, 2) is a filter coefficient applied to the reference pixel, and p n (n = 0, 1, 2) is a reference to a filter including the pixel to be filtered p 0 . The pixel, S ′ (p 0 ) is the predicted value after the filtering process in the filtering target pixel p 0 , and S (p n ) (n = 0, 1, 2) is the filter of the reference pixel including the filtering target pixel p 0 It represents the predicted value before processing.

さらに、上記フィルタ処理を行う予測画像生成ブロックのブロックサイズは限定してもよい。
一般にブロック端のみフィルタ処理を行って予測値を変化させる場合、大きなブロックサイズのブロックでは、フィルタ処理により予測値が変化する領域の占める割合が小さいために、この予測値の変化によって生じた予測差分信号の変化を非常に高い周波数成分で表されることになり、この高周波数成分を符号化するために符号化効率の悪化を生じさせてしまう傾向がある。また、符号化効率を優先して、この高周波数成分を符号化しないようにすることで、ブロック端の予測差分信号の変化を復元できずに、ブロック境界に歪みが生じてしまう傾向がある。
Furthermore, the block size of the predicted image generation block that performs the filtering process may be limited.
In general, when the prediction value is changed by filtering only at the block edge, the prediction difference caused by this change in the prediction value is small because the proportion of the area where the prediction value changes due to the filter processing is small in the block having a large block size. The change in the signal is represented by a very high frequency component, and the encoding efficiency tends to be deteriorated in order to encode the high frequency component. Also, by giving priority to encoding efficiency and not encoding this high-frequency component, the change in the prediction difference signal at the block end cannot be restored, and there is a tendency that the block boundary is distorted.

一方、小さなブロックサイズのブロックでは、フィルタ処理により予測値が変化する領域の占める割合が大きいために、この予測値の変化によって生じた予測差分信号の変化が大きなブロックサイズのブロックの時のような高い周波数成分で表されることはなく、適切に予測差分信号を符号化することができ、本フィルタ処理によって、ブロック境界の連続性を高めた分、復号画像の品質を高めることができる。
したがって、例えば、32×32画素以上のブロックサイズの予測画像生成ブロックでは、上記フィルタ処理を適用せずに、32×32画素より小さいブロックのみに上記フィルタ処理を適用することで、従来の平均値予測よりも予測性能を向上させながら、演算量の増加を抑えることができる。
On the other hand, in a block having a small block size, since the ratio of the area where the prediction value changes due to the filter processing is large, the change in the prediction difference signal caused by the change in the prediction value is as in the case of a block having a large block size. The prediction difference signal can be appropriately encoded without being represented by a high frequency component, and the quality of the decoded image can be improved by the increase in the continuity of the block boundary by this filter processing.
Therefore, for example, in a predicted image generation block having a block size of 32 × 32 pixels or more, the above-described filter processing is not applied, and the above-described filter processing is applied only to blocks smaller than 32 × 32 pixels, thereby obtaining a conventional average value. It is possible to suppress an increase in the calculation amount while improving the prediction performance rather than the prediction.

予測画像生成ブロックに属する予測ブロックP に対するイントラ予測モードのインデックス値が26(垂直方向予測)の場合、下記の式(2)から予測画像生成ブロック内の画素の予測値を算出して予測画像を生成する。

Figure 0006362370
ただし、座標(x,y)は予測画像生成ブロック内の左上画素を原点とする相対座標(図9を参照)であり、S’(x,y)は座標(x,y)における予測値、S(x,y)は座標(x,y)における符号化済み画素の画素値(復号された画素値)である。また、算出した予測値が画素値の取り得る値の範囲を超えている場合、予測値がその範囲内に収まるように値を丸めるようにする。 If the index value of the intra prediction mode for prediction block P i n belonging to the prediction image generation block 26 (vertical prediction), the prediction calculates the prediction value of the pixel of the predicted image generation block according to the following formula (2) Generate an image.
Figure 0006362370
However, the coordinates (x, y) are relative coordinates (see FIG. 9) with the upper left pixel in the predicted image generation block as the origin, and S ′ (x, y) is the predicted value at the coordinates (x, y), S (x, y) is a pixel value (decoded pixel value) of an encoded pixel at coordinates (x, y). Further, when the calculated predicted value exceeds the range of values that the pixel value can take, the value is rounded so that the predicted value falls within the range.

なお、式(2)の1行目の式は、MPEG−4 AVC/H.264における垂直方向予測の予測値であるS(x,−1)に対し、隣接する符号化済み画素の垂直方向の画素値の変化量S(−1,y)−S(−1,−1)を1/2にした値を加算することで、ブロック境界が平滑化されるようにフィルタ処理したものを予測値とすることを意味しており、式(2)の2行目の式は、MPEG−4 AVC/H.264における垂直方向予測と同じ予測式を示している。   Note that the equation in the first line of equation (2) is MPEG-4 AVC / H. The amount of change S (−1, y) −S (−1, −1) in the vertical direction of adjacent encoded pixels with respect to S (x, −1), which is the predicted value of the vertical direction prediction in H.264. ) Is added to the value obtained by halving, and the result of filtering so that the block boundary is smoothed is used as the predicted value. The expression in the second row of Expression (2) is , MPEG-4 AVC / H. The same prediction formula as the vertical direction prediction in H.264 is shown.

予測画像生成ブロックが属する予測ブロックP に対するイントラ予測モードのインデックス値が10(水平方向予測)の場合、下記の式(3)から予測画像生成ブロック内の画素の予測値を算出して予測画像を生成する。

Figure 0006362370
ただし、座標(x,y)は予測画像生成ブロック内の左上画素を原点とする相対座標(図9を参照)であり、S’(x,y)は座標(x,y)における予測値、S(x,y)は座標(x,y)における符号化済み画素の画素値(復号された画素値)である。また、算出した予測値が画素値の取り得る値の範囲を超えている場合、予測値がその範囲内に収まるように値を丸めるようにする。 If the index value of the intra prediction mode for prediction block P i n that the predicted image generation block belongs 10 (horizontal prediction), the prediction calculates the prediction value of the pixel of the predicted image generation block according to the following formula (3) Generate an image.
Figure 0006362370
However, the coordinates (x, y) are relative coordinates (see FIG. 9) with the upper left pixel in the predicted image generation block as the origin, and S ′ (x, y) is the predicted value at the coordinates (x, y), S (x, y) is a pixel value (decoded pixel value) of an encoded pixel at coordinates (x, y). Further, when the calculated predicted value exceeds the range of values that the pixel value can take, the value is rounded so that the predicted value falls within the range.

なお、式(3)の1行目の式は、MPEG−4 AVC/H.264における水平方向予測の予測値であるS(−1,y)に対し、隣接する符号化済み画素の水平方向の画素値の変化量S(x,−1)−S(−1,−1)を1/2にした値を加算することで、ブロック境界が平滑化されるようにフィルタ処理したものを予測値とすることを意味しており、式(3)の2行目の式は、MPEG−4 AVC/H.264における水平方向予測と同じ予測式を示している。   Note that the expression on the first line of Expression (3) is MPEG-4 AVC / H. The amount of change S (x, −1) −S (−1, −1) in the horizontal direction of adjacent encoded pixels with respect to S (−1, y), which is the predicted value of the horizontal direction prediction in H.264. ) Is added to the value obtained by halving, and the result of filtering so that the block boundary is smoothed is used as the predicted value. The expression in the second row of Expression (3) is , MPEG-4 AVC / H. The same prediction formula as the horizontal prediction in H.264 is shown.

ただし、式(2)の垂直方向予測、式(3)の水平方向予測を行う予測画像生成ブロックのブロックサイズを限定してもよい。
一般にブロック端のみ予測方向の画素値の変化量に比例する値を加算するフィルタ処理を行うことで予測値を変化させる場合、大きなブロックサイズのブロックでは、上述した予測画像生成ブロックのブロック端のフィルタ処理により予測値が変化する領域の占める割合が小さいために、この予測値の変化によって生じた予測差分信号の変化を非常に高い周波数成分で表されることになり、この高周波数成分を符号化するために符号化効率の悪化を生じさせてしまう傾向がある。また、符号化効率を優先して、この高周波数成分を符号化しないようにすることで、ブロック端の予測差分信号の変化を復元できずにブロック境界に歪みが生じてしまう傾向がある。
However, the block size of the predicted image generation block that performs the vertical direction prediction of Expression (2) and the horizontal direction prediction of Expression (3) may be limited.
In general, when the prediction value is changed by performing a filter process that adds a value proportional to the amount of change in the pixel value in the prediction direction only at the block edge, the block edge filter of the predicted image generation block described above is used in a large block size block. Since the ratio of the region where the predicted value changes due to processing is small, the change in the prediction difference signal caused by the change in the predicted value is represented by a very high frequency component, and this high frequency component is encoded. Therefore, there is a tendency that the encoding efficiency is deteriorated. Also, by giving priority to encoding efficiency and not encoding this high-frequency component, there is a tendency that the change in the prediction difference signal at the block end cannot be restored and distortion occurs at the block boundary.

一方、小さなブロックサイズのブロックでは、上記フィルタ処理により予測値が変化する領域の占める割合が大きいために、この予測値の変化によって生じた予測差分信号の変化が大きなブロックサイズのブロックの時のような高い周波数成分で表されることはなく、適切に予測差分信号を符号化することができ、本フィルタ処理によってブロック境界の連続性を高めた分、復号画像の品質を高めることができる。
したがって、例えば、32×32画素以上のブロックサイズの予測画像生成ブロックでは、予測対象画素の座標によらず、式(2)及び式(3)の2行目の式を常に用いるようにし(予測画像生成ブロックのブロック端のフィルタ処理を行わないことにする)、32×32画素より小さいブロックのみに、上記フィルタ処理を行う式(2)及び式(3)を適用することで、従来の垂直方向予測、水平方向予測よりも予測性能を向上させながら、演算量の増加を抑えることができる。
On the other hand, in a block with a small block size, since the ratio of the region where the prediction value changes due to the above filter processing is large, the change in the prediction difference signal caused by the change in the prediction value is as in the case of a block with a large block size. Therefore, the prediction difference signal can be appropriately encoded, and the quality of the decoded image can be improved by increasing the continuity of the block boundary by this filter processing.
Therefore, for example, in a prediction image generation block having a block size of 32 × 32 pixels or more, the expressions in the second row of Expression (2) and Expression (3) are always used regardless of the coordinates of the prediction target pixel (prediction). By applying the equations (2) and (3) for performing the above-described filter processing only to blocks smaller than 32 × 32 pixels, the filter edge of the image generation block is not performed. It is possible to suppress an increase in the calculation amount while improving the prediction performance compared to the direction prediction and the horizontal direction prediction.

イントラ予測モードのインデックス値が0(平面予測)、1(平均値予測)、26(垂直方向予測)、10(水平方向予測)以外の場合には、インデックス値が示す予測方向ベクトルυ=(dx,dy)に基づいて、予測画像生成ブロック内の画素の予測値を生成する。
図9に示すように、予測画像生成ブロックの左上画素を原点として、予測画像生成ブロック内の相対座標を(x,y)と設定すると、予測に用いる参照画素の位置は、下記のLと隣接画素の交点になる。

Figure 0006362370
ただし、kは負の実数である。 When the index value in the intra prediction mode is other than 0 (plane prediction), 1 (average value prediction), 26 (vertical direction prediction), and 10 (horizontal direction prediction), the prediction direction vector υ p = ( Based on (dx, dy), a predicted value of a pixel in the predicted image generation block is generated.
As shown in FIG. 9, when the upper left pixel of the predicted image generation block is the origin and the relative coordinates in the predicted image generation block are set to (x, y), the position of the reference pixel used for prediction is adjacent to the following L This is the intersection of pixels.
Figure 0006362370
However, k is a negative real number.

参照画素が整数画素位置にある場合には、その整数画素を予測対象画素の予測値とし、参照画素が整数画素位置にない場合には、参照画素に隣接する整数画素から生成される補間画素を予測値とする。
図8の例では、参照画素は整数画素位置にないので、参照画素に隣接する2画素から内挿したものを予測値とする。なお、隣接する2画素のみではなく、隣接する2画素以上の画素から補間画素を生成して予測値としてもよい。
補間処理に用いる画素を多くすることで補間画素の補間精度を向上させる効果がある一方、補間処理に要する演算の複雑度が増加することから、演算負荷が大きくても高い符号化性能を要求する画像符号化装置の場合には、より多くの画素から補間画素を生成するようにした方がよい。
When the reference pixel is at the integer pixel position, the integer pixel is set as the prediction value of the prediction target pixel. When the reference pixel is not at the integer pixel position, an interpolation pixel generated from the integer pixel adjacent to the reference pixel is selected. Estimated value.
In the example of FIG. 8, since the reference pixel is not located at the integer pixel position, a value interpolated from two pixels adjacent to the reference pixel is set as the predicted value. Note that an interpolation pixel may be generated not only from two adjacent pixels but also from two or more adjacent pixels, and used as a predicted value.
While increasing the number of pixels used in the interpolation process has the effect of improving the interpolation accuracy of the interpolated pixels, it increases the complexity of the calculation required for the interpolation process, requiring high coding performance even when the calculation load is large. In the case of an image encoding device, it is better to generate interpolation pixels from a larger number of pixels.

以上に述べた処理によって、予測画像生成ブロック単位に予測ブロックP 内の輝度信号の全ての画素に対する予測画素を生成して、イントラ予測画像PINTRAi を出力する。
なお、イントラ予測画像PINTRAi の生成に用いられたイントラ予測パラメータ(イントラ予測モード)は、ビットストリームに多重化するために可変長符号化部15に出力される。
The processing described above, to generate a predicted pixel for all the pixels of the luminance signals of the prediction block P i n in the predicted image generation block, and outputs an intra prediction image P INTRAi n.
Incidentally, the intra prediction parameters used for generating the intra prediction image P INTRAi n (intra prediction mode) is output to the variable length coding unit 15 for multiplexing the bitstream.

なお、先に説明したMPEG−4 AVC/H.264における8×8画素のブロックのイントラ予測時に参照画素に対して施される平滑化処理と同様に、イントラ予測部5において、予測画像生成ブロックの予測画像を生成する際の参照画素を、予測画像生成ブロックに隣接する符号化済み画素を平滑化処理した画素とするように構成した場合であっても、上述の例と同様の予測画像に対するフィルタ処理を行うことができる。このようにすることで参照画素へのフィルタ処理による参照画素のノイズが除去され、これを用いて予測を行うことで予測の精度高めることができる。
あるいは、上記参照画素へのフィルタ処理は予測画像へのフィルタ処理を行う平均値予測、垂直方向予測、水平方向予測以外の予測の際のみ実施するようにしてもよい。このようにすることで、各予測モードに対して最大で1つのフィルタ処理しか行わずに済み、演算量の増加を抑えることができる。
Note that the MPEG-4 AVC / H. Similarly to the smoothing process performed on the reference pixels at the time of intra prediction of the 8 × 8 pixel block in H.264, the intra prediction unit 5 predicts the reference pixels when generating the predicted image of the predicted image generation block. Even when the encoded pixels adjacent to the image generation block are configured to be the smoothed pixels, it is possible to perform the same filtering process on the predicted image as in the above example. By doing in this way, the noise of the reference pixel by the filter process to a reference pixel is removed, and prediction accuracy can be improved by performing prediction using this.
Alternatively, the filtering process on the reference pixel may be performed only in the prediction other than the average value prediction, the vertical direction prediction, and the horizontal direction prediction for performing the filtering process on the predicted image. By doing in this way, it is only necessary to perform at most one filter process for each prediction mode, and an increase in the amount of calculation can be suppressed.

上記では、輝度信号の予測画像生成処理について説明したが、色差成分に対する予測画像は次のように生成する。
予測ブロックP の色差信号に対して、色差信号のイントラ予測パラメータ(イントラ予測モード)に基づくイントラ予測処理を実施し、イントラ予測画像の生成に用いられたイントラ予測パラメータを可変長符号化部15に出力する。
In the above description, the predicted image generation process of the luminance signal has been described, but the predicted image for the color difference component is generated as follows.
The color difference signal of the prediction block P i n, conduct intra prediction processing based on the intra prediction parameter of the color difference signal (intra prediction mode), the variable length coding unit intra prediction parameter used to generate the intra-prediction image 15 is output.

図23は色差信号のイントラ予測パラメータ(インデックス値)と色差イントラ予測モードの対応例を示す説明図である。
色差信号のイントラ予測パラメータが、輝度信号に対するイントラ予測モードと同じ予測モードを用いる旨を示している場合(イントラ予測パラメータが輝度色差共通イントラ予測モード(DMモード)を示している場合)、輝度信号と同じフレーム内予測を実施して、色差信号の予測画像を生成する。
FIG. 23 is an explanatory diagram showing an example of correspondence between intra prediction parameters (index values) of color difference signals and color difference intra prediction modes.
When the intra prediction parameter of the chrominance signal indicates that the same prediction mode as the intra prediction mode for the luminance signal is used (when the intra prediction parameter indicates the luminance / chrominance common intra prediction mode (DM mode)), the luminance signal The same intra-frame prediction is performed to generate a prediction image of the color difference signal.

また、色差信号のイントラ予測パラメータが、垂直方向予測モード又は水平方向予測モードを示している場合、色差信号に対する方向性予測を実施して、色差信号の予測画像を生成する。   Further, when the intra prediction parameter of the color difference signal indicates the vertical direction prediction mode or the horizontal direction prediction mode, the directionality prediction for the color difference signal is performed to generate a prediction image of the color difference signal.

入力信号フォーマットがYUV4:2:2信号である場合、図26に示すように、輝度信号が正方ブロックであれば、色差信号は輝度信号と比較して水平方向の画素数が1/2となる長方形のブロックとなる。したがって、図27に示すように、YUV4:4:4信号をYUV4:2:2信号に変換した際に、輝度信号と色差信号で同一方向の予測となるようにするためには、YUV4:2:2信号上では、垂直方向予測と水平方向予測以外の方向性予測の場合には、色差信号の予測方向が輝度信号の予測方向と異なることとなる。
具体的には、図28に示すように、輝度信号の予測方向ベクトルをv=(dx,dy)とした場合、色差信号の予測方向ベクトルは、v=(dx/2,dy)となる。即ち、図29に示すように、予測方向の角度をθとした場合、輝度信号の予測方向の角度をθ、色差信号の予測方向の角度をθとして、tanθ=2tanθの関係となる予測方向で予測する必要がある。
When the input signal format is a YUV 4: 2: 2 signal, as shown in FIG. 26, if the luminance signal is a square block, the color difference signal has half the number of pixels in the horizontal direction compared to the luminance signal. It becomes a rectangular block. Therefore, as shown in FIG. 27, when a YUV4: 4: 4 signal is converted into a YUV4: 2: 2 signal, YUV4: 2 is used to predict the luminance signal and the color difference signal in the same direction. : On two signals, in the case of directional prediction other than the vertical prediction and the horizontal prediction, the prediction direction of the color difference signal is different from the prediction direction of the luminance signal.
Specifically, as illustrated in FIG. 28, when the prediction direction vector of the luminance signal is v L = (dx L , dy L ), the prediction direction vector of the color difference signal is v C = (dx L / 2, dy L ). That is, as shown in FIG. 29, assuming that the angle of the prediction direction is θ, the angle of the prediction direction of the luminance signal is θ L , the angle of the prediction direction of the color difference signal is θ C , and tan θ C = 2tan θ L It is necessary to predict in the prediction direction.

したがって、輝度信号と色差信号で同一方向の予測を行う上記DMモードを正しく実施できるようにするために、入力信号フォーマットがYUV4:2:2信号である場合、輝度信号に使用したイントラ予測モードのインデックスを色差信号の予測に用いるイントラ予測モードのインデックスに変換し、変換後のインデックスに対応するイントラ予測モードによる色差信号の予測処理を実施する。
図30は図7のイントラ予測モードにおけるイントラ予測モードインデックスの変換例を示している。
図30の変換テーブルは、予測方向の角度がθであるとき(図29を参照)、イントラ予測モードの方向性予測が図31に示すtanθとなる角度である場合、tanθ=2tanθの関係に最も近い角度θに変換するテーブルの例である。
変換処理の実現は、上記のように、インデックスの変換テーブルを用意し、その変換テーブルを参照することでインデックスを変換するように構成してもよいし、変換式を用意し、その変換式に従ってインデックスを変換するように構成してもよい。
このように構成することで、方向性予測処理自体を変更することなく、インデックスの変換のみでYUV4:2:2信号のフォーマットに応じた色差信号の適切な予測を実施することができる。
Therefore, when the input signal format is a YUV 4: 2: 2 signal in order to correctly implement the DM mode in which the prediction in the same direction is performed with the luminance signal and the color difference signal, the intra prediction mode used for the luminance signal is used. The index is converted into an intra prediction mode index used for prediction of the color difference signal, and the color difference signal prediction process is performed in the intra prediction mode corresponding to the converted index.
FIG. 30 shows an example of conversion of the intra prediction mode index in the intra prediction mode of FIG.
In the conversion table of FIG. 30, when the angle of the prediction direction is θ (see FIG. 29), the relationship of tan θ C = 2 tan θ L when the direction prediction of the intra prediction mode is tan θ shown in FIG. It is an example of the table converted into the angle θ C closest to.
As described above, the conversion process may be realized by preparing an index conversion table and converting the index by referring to the conversion table, or by preparing a conversion formula and according to the conversion formula. You may comprise so that an index may be converted.
With this configuration, it is possible to perform appropriate prediction of the color difference signal according to the format of the YUV 4: 2: 2 signal only by converting the index without changing the directionality prediction process itself.

さらに、色差信号では、平均値(DC)予測、垂直方向予測、水平方向予測について、輝度信号の場合で説明したブロック境界のフィルタ処理を行わずに、MPEG−4 AVC/H.264と同様の予測手法としてもよい。このようにフィルタ処理を行わないことで、予測処理の低演算化を図ることができる。   Further, in the color difference signal, the average value (DC) prediction, the vertical direction prediction, and the horizontal direction prediction are performed without performing the block boundary filtering process described in the case of the luminance signal, and the MPEG-4 AVC / H. It is good also as the prediction method similar to H.264. By not performing the filtering process in this way, it is possible to reduce the prediction process.

次に、図3の画像復号装置の処理内容を具体的に説明する。
可変長復号部31は、図1の画像符号化装置により生成された符号化ビットストリームを入力すると、そのビットストリームに対する可変長復号処理を実施して(図4のステップST21)、1フレーム以上のピクチャから構成されるシーケンス単位のヘッダ情報(シーケンスレベルヘッダ)及びピクチャ単位のヘッダ情報(ピクチャレベルヘッダ)などの各ヘッダ情報とピクチャデータを復号する。ただし、ピクチャデータは1以上のスライスデータから構成され、各スライスデータはスライスレベルヘッダと当該スライス内にある符号化データがまとめられているものである。ピクチャデータはスライスデータの他に補足情報を示すヘッダ情報を含む場合もある。
Next, the processing content of the image decoding apparatus in FIG. 3 will be specifically described.
When the encoded bit stream generated by the image encoding device in FIG. 1 is input, the variable length decoding unit 31 performs a variable length decoding process on the bit stream (step ST21 in FIG. 4), and more than one frame. Each header information and picture data such as header information (sequence level header) in units of a sequence composed of pictures and header information (picture level header) in units of pictures are decoded. However, picture data is composed of one or more slice data, and each slice data is a collection of a slice level header and encoded data in the slice. The picture data may include header information indicating supplementary information in addition to the slice data.

このとき、上記ヘッダ情報に含まれる量子化マトリクスの有効フラグが“有効”を示す場合、可変長復号部31は量子化マトリクスパラメータを可変長復号し、量子化マトリクスを特定する。
具体的には、各直交変換サイズの色信号や符号化モード毎に、量子化マトリクスパラメータが初期値として、画像符号化装置及び画像復号装置で、予め共通に用意されている量子化マトリクス、又は、既に復号された量子化マトリクスである(新しい量子化マトリクスでない)ことを示す場合は、量子化マトリクスパラメータに含まれる上記マトリクスの内のどの量子化マトリクスであるかを特定するインデックス情報を参照して量子化マトリクスを特定し、量子化マトリクスパラメータが新しい量子化マトリクスを用いることを示す場合は、量子化マトリクスパラメータに含まれる量子化マトリクスを使用する量子化マトリクスとして特定する。
そして、ピクチャ単位のデータを構成するスライスデータから、スライス分割情報等のスライス単位のヘッダ情報(スライスレベルヘッダ)を復号し、各スライスの符号化データを復号する。
At this time, when the valid flag of the quantization matrix included in the header information indicates “valid”, the variable length decoding unit 31 performs variable length decoding on the quantization matrix parameter to identify the quantization matrix.
Specifically, for each color signal or encoding mode of each orthogonal transform size, the quantization matrix parameter is set as an initial value, and a quantization matrix prepared in advance by the image encoding device and the image decoding device, or When indicating that the quantization matrix is already decoded (not a new quantization matrix), refer to the index information for specifying which quantization matrix among the matrices included in the quantization matrix parameter. When the quantization matrix is specified, and the quantization matrix parameter indicates that a new quantization matrix is to be used, it is specified as a quantization matrix that uses the quantization matrix included in the quantization matrix parameter.
Then, slice unit header information (slice level header) such as slice division information is decoded from slice data constituting picture unit data, and encoded data of each slice is decoded.

また、可変長復号部31は、上記ヘッダ情報から、最大符号化ブロックサイズ及び分割階層数の上限を特定する(ステップST22)。
ただし、分割階層数の上限の代わりに、符号化ブロックの最小ブロックサイズが符号化されている場合、これを復号することで分割階層数の上限を決定する。即ち、最大符号化ブロックを上記最小ブロックサイズまで分割した場合が分割階層数の上限となる。
可変長復号部31は、決定された最大符号化ブロック単位に、図6で示されるような最大符号化ブロックの分割状態を復号する。復号された分割状態に基づき、階層的に符号化ブロックを特定する(ステップST23)。
In addition, the variable length decoding unit 31 specifies the maximum encoding block size and the upper limit of the number of division layers from the header information (step ST22).
However, when the minimum block size of the encoded block is encoded instead of the upper limit of the number of division layers, the upper limit of the number of division layers is determined by decoding this. That is, the upper limit of the number of division layers is obtained when the maximum encoded block is divided to the minimum block size.
The variable length decoding unit 31 decodes the division state of the maximum encoded block as shown in FIG. 6 for each determined maximum encoded block. Based on the decoded division state, coding blocks are identified hierarchically (step ST23).

次に、可変長復号部31は、符号化ブロックに割り当てられている符号化モードを復号する。復号した符号化モードに含まれる情報に基づき、符号化ブロックをさらに1つないし複数の予測処理単位である予測ブロックに分割し、予測ブロック単位に割り当てられている予測パラメータを復号する(ステップST24)。   Next, the variable length decoding unit 31 decodes the encoding mode assigned to the encoding block. Based on the information included in the decoded coding mode, the coded block is further divided into one or more prediction blocks which are prediction processing units, and the prediction parameters assigned to the prediction block units are decoded (step ST24). .

即ち、可変長復号部31は、符号化ブロックに割り当てられている符号化モードがイントラ符号化モードである場合、符号化ブロックに含まれており、予測処理単位となる1つ以上の予測ブロック毎にイントラ予測パラメータを復号し、符号化ブロックに割り当てられている符号化モードがイントラブロックコピー符号化モードである場合、符号化ブロックに含まれており、予測処理単位となる1つ以上の予測ブロック毎にイントラブロックコピー予測パラメータを復号する。また、符号化ブロックに割り当てられている符号化モードがインター符号化モードである場合、符号化ブロックに含まれており、予測処理単位となる1つ以上の予測ブロック毎にインター予測パラメータ及び動きベクトルを復号する。また、色信号間予測フラグを含む色信号間予測パラメータを復号する(ステップST24)。   That is, when the encoding mode assigned to the encoding block is the intra encoding mode, the variable length decoding unit 31 is included in the encoding block, and each of one or more prediction blocks serving as a prediction processing unit When the intra prediction parameter is decoded and the coding mode assigned to the coding block is the intra block copy coding mode, one or more prediction blocks included in the coding block and serving as a prediction processing unit The intra block copy prediction parameter is decoded every time. Further, when the coding mode assigned to the coding block is the inter coding mode, the inter prediction parameter and the motion vector are included in the coding block and each of one or more prediction blocks serving as a prediction processing unit. Is decrypted. Further, the inter-color signal prediction parameters including the inter-color signal prediction flag are decoded (step ST24).

さらに、可変長復号部31は、予測差分符号化パラメータに含まれる変換ブロック分割情報に基づき、変換ブロック毎に圧縮データ(変換・量子化後の変換係数)を復号する(ステップST24)。
その際、図1の画像符号化装置の可変長符号化部15での圧縮データの符号化処理と同様に、CG単位の係数の復号処理を実施する。
したがって、図15に示すように、4×4画素単位の16個のCGを右下のCGから順に復号処理し、さらに、各CGはCG内の16個の係数を右下の係数から順に復号していくことになる。
Further, the variable length decoding unit 31 decodes the compressed data (transformed / transformed transform coefficients) for each transform block based on the transform block division information included in the prediction difference coding parameter (step ST24).
At that time, similarly to the encoding process of the compressed data in the variable length encoding unit 15 of the image encoding apparatus of FIG.
Therefore, as shown in FIG. 15, 16 CGs in units of 4 × 4 pixels are decoded in order from the lower right CG, and each CG decodes 16 coefficients in the CG in order from the lower right coefficient. Will do.

具体的には、まず、CG内の16個の係数の中に有意(非零)係数が存在するか否かのフラグを復号し、次に復号したフラグがCG内に有意(非零)係数が存在することを示す場合のみCG内の各係数が有意(非零)係数であるかを上記順に復号し、最後に有意(非零)係数を示す係数に対して、その係数値情報を順に復号する。これをCG単位に上記順に行う。
ただし、スキャン順については、イントラ予測が選択されている4×4画素と8×8画素の変換ブロックの場合、イントラ予測モードのインデックスに応じて、図15のスキャン順ではなく図19に示すスキャン順で処理を行う。
Specifically, first, a flag indicating whether or not a significant (non-zero) coefficient exists in 16 coefficients in the CG is decoded, and then the decoded flag is a significant (non-zero) coefficient in the CG. Only when it is shown that the coefficient is present, whether each coefficient in the CG is a significant (non-zero) coefficient is decoded in the above order, and finally, the coefficient value information for the coefficient indicating the significant (non-zero) coefficient is sequentially Decrypt. This is performed in the above order in units of CG.
However, with regard to the scan order, in the case of a 4 × 4 pixel and 8 × 8 pixel conversion block for which intra prediction is selected, the scan shown in FIG. 19 is used instead of the scan order of FIG. 15 according to the index of the intra prediction mode. Process in order.

切換スイッチ33は、可変長復号部31により可変長復号された符号化モードm(B)がイントラ符号化モードであれば(m(B)∈INTRAの場合)、可変長復号部31により可変長復号された予測ブロック単位のイントラ予測パラメータをイントラ予測部34に出力し、可変長復号部31により可変長復号された符号化モードm(B)がイントラブロックコピー符号化モードであれば(m(B)∈ICOPYの場合)、可変長復号部31により可変長復号された予測ブロック単位のイントラブロックコピー予測パラメータをイントラブロックコピー予測部35に出力し、可変長復号部31により可変長復号された符号化モードm(B)がインター符号化モードであれば(m(B)∈INTERの場合)、可変長復号部31により可変長復号された予測ブロック単位のインター予測パラメータ及び動きベクトルを動き補償予測部36に出力する。 If the encoding mode m (B n ) variable-length decoded by the variable-length decoding unit 31 is an intra-encoding mode (when m (B n ) ∈INTRA), the changeover switch 33 is changed by the variable-length decoding unit 31. The intra-prediction parameter for each prediction block subjected to variable-length decoding is output to the intra-prediction unit 34, and the coding mode m (B n ) subjected to variable-length decoding by the variable-length decoding unit 31 is the intra-block copy coding mode. (In the case of m (B n ) εICOPY), the intra block copy prediction parameter of the prediction block unit variable length decoded by the variable length decoding unit 31 is output to the intra block copy prediction unit 35 and variable by the variable length decoding unit 31 If the length decoded coding mode m (B n) is an inter coding mode (m (the case of B n) ∈INTER), variable recovery And it outputs the inter prediction parameter and the motion vector variable length decoding prediction block to the motion compensation prediction unit 36 by the part 31.

イントラ予測部34は、可変長復号部31により可変長復号された符号化モードm(B)がイントラ符号化モード(m(B)∈INTRA)である場合(ステップST25)、切換スイッチ33から出力された予測ブロック単位のイントラ予測パラメータを受け取って、図1のイントラ予測部5と同様の手順で、イントラ用メモリ38に格納されている復号画像を参照しながら、上記イントラ予測パラメータを用いた符号化ブロックB内の各予測ブロックP に対するイントラ予測処理を実施して、イントラ予測画像PINTRAi を生成する(ステップST26)。 When the coding mode m (B n ) variable-length decoded by the variable-length decoding unit 31 is the intra coding mode (m (B n ) ∈INTRA) (step ST25), the intra prediction unit 34 selects the changeover switch 33. 1 is received, and the intra prediction parameter is used while referring to the decoded image stored in the intra memory 38 in the same procedure as the intra prediction unit 5 in FIG. intra prediction processing for each of the prediction block P i n the stomach coded block B n to implement, generates an intra prediction image P INTRAi n (step ST26).

また、イントラ予測部34は、輝度信号については、輝度信号に対する上記イントラ予測パラメータを用いたイントラ予測処理(フレーム内予測処理)を実施して、輝度信号の予測画像を生成する。
一方、色差信号については、色信号間予測フラグがOFFである場合(色信号間予測処理の非実施を示している場合)、色差信号のイントラ予測パラメータに基づくイントラ予測処理を実施して、色差信号の予測画像を生成する。
In addition, for the luminance signal, the intra prediction unit 34 performs an intra prediction process (intra-frame prediction process) using the intra prediction parameter for the luminance signal to generate a prediction image of the luminance signal.
On the other hand, for the color difference signal, if the inter-color signal prediction flag is OFF (indicating non-execution of the inter-color signal prediction process), the intra-prediction process based on the intra prediction parameter of the color difference signal is performed. A predicted image of the signal is generated.

図23は色差信号のイントラ予測パラメータ(インデックス値)と色差イントラ予測モードの対応例を示す説明図である。
色差信号のイントラ予測パラメータが、輝度信号に対するイントラ予測モードと同じ予測モードを用いる旨を示している場合(イントラ予測パラメータが輝度色差共通イントラ予測モード(DMモード)を示している場合)、輝度信号と同じフレーム内予測を実施して、色差信号の予測画像を生成する。
FIG. 23 is an explanatory diagram showing an example of correspondence between intra prediction parameters (index values) of color difference signals and color difference intra prediction modes.
When the intra prediction parameter of the chrominance signal indicates that the same prediction mode as the intra prediction mode for the luminance signal is used (when the intra prediction parameter indicates the luminance / chrominance common intra prediction mode (DM mode)), the luminance signal The same intra-frame prediction is performed to generate a prediction image of the color difference signal.

また、色差信号のイントラ予測パラメータが、垂直方向予測モード又は水平方向予測モードを示している場合、色差信号に対する方向性予測を実施して、色差信号の予測画像を生成する。   Further, when the intra prediction parameter of the color difference signal indicates the vertical direction prediction mode or the horizontal direction prediction mode, the directionality prediction for the color difference signal is performed to generate a prediction image of the color difference signal.

入力信号フォーマットがYUV4:2:2信号である場合、図26に示すように、輝度信号が正方ブロックであれば、色差信号は輝度信号と比較して水平方向の画素数が1/2となる長方形のブロックとなる。したがって、図27に示すように、YUV4:4:4信号をYUV4:2:2信号に変換した際に、輝度信号と色差信号で同一方向の予測となるようにするためには、YUV4:2:2信号上では、垂直方向予測と水平方向予測以外の方向性予測の場合には、色差信号の予測方向が輝度信号の予測方向と異なることとなる。
具体的には、図28に示すように、輝度信号の予測方向ベクトルをv=(dx,dy)とした場合、色差信号の予測方向ベクトルは、v=(dx/2,dy)となる。即ち、図29に示すように、予測方向の角度をθとした場合、輝度信号の予測方向の角度をθ、色差信号の予測方向の角度をθとして、tanθ=2tanθの関係となる予測方向で予測する必要がある。
When the input signal format is a YUV 4: 2: 2 signal, as shown in FIG. 26, if the luminance signal is a square block, the color difference signal has half the number of pixels in the horizontal direction compared to the luminance signal. It becomes a rectangular block. Therefore, as shown in FIG. 27, when a YUV4: 4: 4 signal is converted into a YUV4: 2: 2 signal, YUV4: 2 is used to predict the luminance signal and the color difference signal in the same direction. : On two signals, in the case of directional prediction other than the vertical prediction and the horizontal prediction, the prediction direction of the color difference signal is different from the prediction direction of the luminance signal.
Specifically, as illustrated in FIG. 28, when the prediction direction vector of the luminance signal is v L = (dx L , dy L ), the prediction direction vector of the color difference signal is v C = (dx L / 2, dy L ). That is, as shown in FIG. 29, assuming that the angle of the prediction direction is θ, the angle of the prediction direction of the luminance signal is θ L , the angle of the prediction direction of the color difference signal is θ C , and tan θ C = 2tan θ L It is necessary to predict in the prediction direction.

したがって、輝度信号と色差信号で同一方向の予測を行う上記DMモードを正しく実施できるようにするために、入力信号フォーマットがYUV4:2:2信号である場合、輝度信号に使用したイントラ予測モードのインデックスを色差信号の予測に用いるイントラ予測モードのインデックスに変換し、変換後のインデックスに対応するイントラ予測モードによる色差信号の予測処理を実施する。
図30は図7のイントラ予測モードにおけるイントラ予測モードインデックスの変換例を示している。
図30の変換テーブルは、予測方向の角度がθであるとき(図29を参照)、イントラ予測モードの方向性予測が図31に示すtanθとなる角度である場合、tanθ=2tanθの関係に最も近い角度θに変換するテーブルの例である。
変換処理の実現は、上記のように、インデックスの変換テーブルを用意し、その変換テーブルを参照することでインデックスを変換するように構成してもよいし、変換式を用意し、その変換式に従ってインデックスを変換するように構成してもよい。
このように構成することで、方向性予測処理自体を変更することなく、インデックスの変換のみでYUV4:2:2信号のフォーマットに応じた色差信号の適切な予測を実施することができる。
Therefore, when the input signal format is a YUV 4: 2: 2 signal in order to correctly implement the DM mode in which the prediction in the same direction is performed with the luminance signal and the color difference signal, the intra prediction mode used for the luminance signal is used. The index is converted into an intra prediction mode index used for prediction of the color difference signal, and the color difference signal prediction process is performed in the intra prediction mode corresponding to the converted index.
FIG. 30 shows an example of conversion of the intra prediction mode index in the intra prediction mode of FIG.
In the conversion table of FIG. 30, when the angle of the prediction direction is θ (see FIG. 29), the relationship of tan θ C = 2 tan θ L when the direction prediction of the intra prediction mode is tan θ shown in FIG. It is an example of the table converted into the angle θ C closest to.
As described above, the conversion process may be realized by preparing an index conversion table and converting the index by referring to the conversion table, or by preparing a conversion formula and according to the conversion formula. You may comprise so that an index may be converted.
With this configuration, it is possible to perform appropriate prediction of the color difference signal according to the format of the YUV 4: 2: 2 signal only by converting the index without changing the directionality prediction process itself.

さらに、色差信号では、平均値(DC)予測、垂直方向予測、水平方向予測について、輝度信号の場合で説明したブロック境界のフィルタ処理を行わずに、MPEG−4 AVC/H.264と同様の予測手法として画像符号化装置が構成されている場合、その画像符号化装置から生成される符号化ビットストリームが復号できるように画像復号装置も同様の構成とする。
このようにフィルタ処理を行わないことで、予測処理の低演算化を図ることができる。
Further, in the color difference signal, the average value (DC) prediction, the vertical direction prediction, and the horizontal direction prediction are performed without performing the block boundary filtering process described in the case of the luminance signal, and the MPEG-4 AVC / H. When an image encoding apparatus is configured as a prediction method similar to H.264, the image decoding apparatus has the same configuration so that an encoded bit stream generated from the image encoding apparatus can be decoded.
By not performing the filtering process in this way, it is possible to reduce the prediction process.

イントラ予測部34は、輝度信号の予測画像の生成については常にイントラ予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、当該予測ブロックの色信号間予測フラグがONである場合(色信号間予測処理の実施を明示している場合)、イントラ予測処理を実施せずに、復号済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。   The intra prediction unit 34 always performs an intra prediction process for generating a predicted image of a luminance signal, but for generating a predicted image of a chrominance signal, for each predicted block, an inter-color signal prediction flag of the predicted block. Is ON (when the execution of inter-color signal prediction processing is clearly specified), the prediction image of the color difference signal in the prediction block is generated by referring to the decoded color signal without performing the intra prediction processing. The inter-color signal prediction process is performed.

イントラブロックコピー予測部35は、可変長復号部31により可変長復号された符号化モードm(B)がイントラブロックコピー符号化モード(m(B)∈ICOPY)である場合(ステップST25)、切換スイッチ33から出力された予測ブロック単位のブロックシフトベクトルを含むイントラブロックコピー予測パラメータを受け取って、イントラ用メモリ38に格納されている復号画像を参照しながら、上記イントラブロックコピー予測パラメータを用いた符号化ブロックB内の各予測ブロックP に対するイントラブロックコピー予測処理を実施して、イントラブロックコピー予測画像PICOPYi を生成する(ステップST27)。 The intra block copy prediction unit 35, when the encoding mode m (B n ) that has been variable length decoded by the variable length decoding unit 31 is the intra block copy encoding mode (m (B n ) εICOPY) (step ST25). The intra block copy prediction parameter including the block shift vector of the prediction block unit output from the changeover switch 33 is received, and the intra block copy prediction parameter is used while referring to the decoded image stored in the intra memory 38. There was then conducted intra block copy prediction processing for each of the prediction block P i n the coded block B n, generates an intra block copy predicted image P ICOPYi n (step ST27).

図1の画像符号化装置において、ブロックシフトベクトルは直前の符号化(復号)済み予測ブロックのブロックシフトベクトル、あるいは当該予測ブロックの周囲の符号化(復号)済み予測ブロックのブロックシフトベクトルとの差分値をイントラブロックコピー予測パラメータの一部として符号化するようにしている場合、イントラブロックコピー予測パラメータに含む差分値と上記ブロックシフトベクトルとを加算して、当該予測ブロックのブロックシフトベクトルを算出する。
このとき、ブロックシフトベクトルが指すブロックが復号済み領域を超えるような参照を可能とするように、復号対象の最大符号化ブロック内の復号前の領域(未復号領域)の画素を図1の画像符号化装置におけるイントラブロックコピー予測部6と同一の手法で定まる画素値で埋める処理を行う。このとき、未復号領域を上記画素値で埋める処理に必要なパラメータがイントラブロックコピー予測パラメータの一部としてビットストリームに含まれる場合は、可変長復号部31により可変長復号された上記パラメータを用いて未復号領域を上記画素値で埋める処理を行う。
色差信号については、輝度信号と同一のベクトルによる予測を実施する。あるいは、輝度信号のベクトルを基準として探索し、輝度信号のベクトルの差分ベクトルを符号化するように図1の画像符号化装置が構成されている場合、可変長復号部31は差分ベクトルを復号して色差信号のベクトルを算出する。
In the image encoding device of FIG. 1, the block shift vector is the difference between the block shift vector of the previous encoded (decoded) predicted block or the block shift vector of the encoded (decoded) predicted block around the predicted block. When the value is encoded as a part of the intra block copy prediction parameter, the difference value included in the intra block copy prediction parameter and the block shift vector are added to calculate the block shift vector of the prediction block. .
At this time, the pixels in the region before decoding (undecoded region) in the maximum coding block to be decoded are set to the image of FIG. 1 so that the block indicated by the block shift vector can be referred to beyond the decoded region. A process of filling with pixel values determined by the same method as the intra block copy prediction unit 6 in the encoding apparatus is performed. At this time, when a parameter necessary for the process of filling the undecoded area with the pixel value is included in the bitstream as a part of the intra block copy prediction parameter, the parameter decoded by the variable length decoding unit 31 is used. Then, a process of filling the undecoded area with the pixel value is performed.
For the color difference signal, prediction using the same vector as the luminance signal is performed. Alternatively, when the image encoding apparatus of FIG. 1 is configured to search based on the luminance signal vector and encode the difference vector of the luminance signal vector, the variable length decoding unit 31 decodes the difference vector. To calculate a color difference signal vector.

イントラブロックコピー予測部35は、輝度信号の予測画像の生成については常にイントラブロックコピー予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、当該予測ブロックの色信号間予測フラグがONである場合(色信号間予測処理の実施を明示している場合)、イントラブロックコピー予測処理を実施せずに、復号済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。   The intra block copy prediction unit 35 always performs an intra block copy prediction process for the generation of a prediction image of a luminance signal, but for the generation of a prediction image of a color difference signal, the color of the prediction block is generated for each prediction block. When the inter-signal prediction flag is ON (when the execution of the inter-color signal prediction process is specified), the color difference in the prediction block is referred to by referring to the decoded color signal without performing the intra block copy prediction process. An inter-color signal prediction process for generating a predicted image of the signal is performed.

動き補償予測部36は、可変長復号部31により可変長復号された符号化モードm(B)がインター符号化モード(m(B)∈INTER)である場合(ステップST25)、切換スイッチ33から出力された予測ブロック単位の動きベクトルとインター予測パラメータを受け取って、動き補償予測フレームメモリ40に格納されているフィルタ処理後の復号画像を参照しながら、その動きベクトルとインター予測パラメータを用いた符号化ブロックB内の各予測ブロックP に対する動き補償予測処理を実施してインター予測画像PINTERi を生成する(ステップST28)。
色差信号については、輝度信号と同一のベクトルによる予測を実施する。あるいは、輝度信号のベクトルを基準として探索し、輝度信号のベクトルの差分ベクトルを符号化するように図1の画像符号化装置が構成されている場合、可変長復号部31は差分ベクトルを復号して色差信号のベクトルを算出する。
When the coding mode m (B n ) variable-length decoded by the variable-length decoding unit 31 is the inter coding mode (m (B n ) εINTER) (step ST25), the motion compensation prediction unit 36 performs the changeover switch. The motion vector and the inter prediction parameter of the prediction block unit output from 33 are received, and the motion vector and the inter prediction parameter are used while referring to the decoded image stored in the motion compensated prediction frame memory 40. and performing motion compensation prediction process generates an inter prediction image P INTERi n for each of the prediction block P i n the stomach coded block B n (step ST28).
For the color difference signal, prediction using the same vector as the luminance signal is performed. Alternatively, when the image encoding apparatus of FIG. 1 is configured to search based on the luminance signal vector and encode the difference vector of the luminance signal vector, the variable length decoding unit 31 decodes the difference vector. To calculate a color difference signal vector.

動き補償予測部36は、輝度信号の予測画像の生成については常に動き補償予測処理を実施するが、色差信号の予測画像の生成については、各予測ブロックに対して、当該予測ブロックの色信号間予測フラグがONである場合(色信号間予測処理の実施を明示している場合)、動き補償予測処理を実施せずに、復号済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施する。   The motion compensation prediction unit 36 always performs motion compensation prediction processing for generating a prediction image of a luminance signal, but for generating a prediction image of a color difference signal, for each prediction block, between the color signals of the prediction block. When the prediction flag is ON (when the execution of the inter-color signal prediction process is clearly specified), the prediction of the color difference signal in the prediction block is performed by referring to the decoded color signal without performing the motion compensation prediction process. An inter-color signal prediction process for generating an image is performed.

ここで、イントラ予測部34、イントラブロックコピー予測部35又は動き補償予測部36が、色信号間予測処理を実施して、色差信号の予測画像を生成する際の処理内容を具体的に説明する。
色信号間予測パラメータに含まれている色信号間予測フラグがONである場合、色差信号では、イントラ予測処理、イントラブロックコピー予測処理、動き補償予測処理を行わず、図45に示すように、色信号間ベクトルが指し示す復号済み色信号のブロックを参照して予測画像を生成する。
このとき、図1の画像符号化装置と同一の手法で、参照する復号済み色信号のブロックの画素値と予測対象の色差信号の予測画像の画素値との相関を示す相関パラメータを算出し、その相関パラメータによって補正された対応する復号済み色信号のブロックの画素値を予測対象である色差信号の予測画像の画素値とする。予測画像生成対象ブロックの単位は画像符号化装置と同一の単位(符号化ブロック単位、予測ブロック単位、変換ブロック単位のいずれか)である。
Here, the processing contents when the intra prediction unit 34, the intra block copy prediction unit 35, or the motion compensation prediction unit 36 performs the inter-color signal prediction process to generate the prediction image of the color difference signal will be specifically described. .
When the inter-color signal prediction flag included in the inter-color signal prediction parameter is ON, the color difference signal does not perform the intra prediction process, the intra block copy prediction process, and the motion compensation prediction process, as shown in FIG. A predicted image is generated with reference to the block of the decoded color signal indicated by the inter-color signal vector.
At this time, the correlation parameter indicating the correlation between the pixel value of the block of the decoded color signal to be referenced and the pixel value of the prediction image of the color difference signal to be predicted is calculated by the same method as the image encoding device of FIG. The pixel value of the block of the corresponding decoded color signal corrected by the correlation parameter is set as the pixel value of the predicted image of the color difference signal to be predicted. The unit of the prediction image generation target block is the same unit as the image encoding device (any one of the encoding block unit, the prediction block unit, and the transform block unit).

上記の例では、相関パラメータを算出して復号済み色信号のブロックの画素値を補正するとしているが、図1の画像符号化装置が相関パラメータを算出せずに符号化済み色信号のブロックの画素値をそのまま予測画像の画素値とする場合、画像復号装置では、相関パラメータを算出せずに復号済み色信号のブロックの画素値をそのまま予測画像の画素値とする。
なお、入力信号フォーマットがYUV4:2:0フォーマットあるいはYUV4:2:2フォーマットの場合は、図1の画像符号化装置と同様に、参照する復号済み色信号を予測画像生成対象ブロックと同一のサイズとなるようにブロックサイズをスケーリングして参照する。
In the above example, the correlation parameter is calculated and the pixel value of the block of the decoded color signal is corrected. However, the image encoding apparatus in FIG. When the pixel value is used as the pixel value of the predicted image as it is, the image decoding apparatus directly uses the pixel value of the block of the decoded color signal as the pixel value of the predicted image without calculating the correlation parameter.
When the input signal format is YUV4: 2: 0 format or YUV4: 2: 2 format, the decoded color signal to be referenced is the same size as the predicted image generation target block, as in the image encoding device of FIG. The block size is scaled so that

可変長復号部31により可変長復号された色信号間予測パラメータは、色信号間予測が有効か否かを示すシーケンス、ピクチャ、スライスレベルの情報、予測ブロック単位の色信号間予測処理の実施の有無を示す色信号間予測フラグを含んでいる。
色信号間予測処理がOFFのブロックは、輝度信号と同一の予測部(イントラ予測部34、イントラブロックコピー予測部35あるいは動き補償予測部36)で予測を実施する。したがって、イントラ予測部34の色差信号のイントラ予測パラメータのうち、色信号間予測を行わない予測ブロックのイントラ予測パラメータだけが復号され、そのイントラ予測パラメータにしたがってイントラ予測処理が実施される。
同様に、図1の画像符号化装置が色差信号用の差分ベクトルを符号化するように構成している場合、色信号間予測フラグがOFFである場合に限り、イントラブロックコピー予測部35あるいは動き補償予測部36が用いる色差信号用の差分ベクトルが復号される。
The inter-color signal prediction parameters that have been variable-length decoded by the variable-length decoding unit 31 include information indicating whether or not inter-color signal prediction is effective, information on a sequence, a picture, and a slice level, and execution of inter-color signal prediction processing in units of prediction blocks. It includes an inter-color signal prediction flag indicating the presence or absence.
A block for which the inter-color signal prediction process is OFF is predicted by the same prediction unit (intra prediction unit 34, intra block copy prediction unit 35, or motion compensation prediction unit 36) as the luminance signal. Therefore, only the intra prediction parameters of the prediction block that does not perform inter-color signal prediction among the intra prediction parameters of the color difference signal of the intra prediction unit 34 are decoded, and the intra prediction process is performed according to the intra prediction parameters.
Similarly, when the image encoding apparatus in FIG. 1 is configured to encode the difference vector for the color difference signal, the intra block copy prediction unit 35 or the motion only when the inter-color signal prediction flag is OFF. The difference vector for the color difference signal used by the compensation prediction unit 36 is decoded.

また、図1の画像符号化装置が、イントラ予測部34の色差信号のイントラ予測パラメータと色信号間予測フラグを組み合わせて、図48の色差信号のイントラ予測パラメータとして符号化している場合、画像復号装置のイントラ予測部34では、可変長復号部31により可変長復号された色差信号のイントラ予測パラメータから、色信号間予測を実施するか、イントラ予測を行うかを判断する。
上記の例では、予測ブロック単位に色信号間予測処理の実施の有無を選択する場合について説明しているが、図1の画像符号化装置が符号化ブロック単位あるいは最大サイズの符号化ブロック単位に選択を実施するように構成されている場合、画像復号装置では、同一のブロック単位の色信号間予測フラグを復号するように構成する。このようにすることで正しく符号化パラメータを復号することができる。
さらに、可変長復号部31により可変長復号された色信号間予測パラメータとして、色信号間予測フラグがONの場合には、可変長復号部31は参照信号のブロックの位置を示す色信号間ベクトルやどの色信号を参照するかを示す参照信号情報を復号する。ただし、図1の画像符号化装置で上記色信号間ベクトルや上記参照信号情報を用いないように構成している場合、画像復号装置でも、これらパラメータは復号せずに、画像符号化装置と同一の参照信号の、同一の位置のブロックを参照して予測画像を生成する。
In addition, when the image coding apparatus in FIG. 1 combines the intra prediction parameter of the color difference signal and the inter-color signal prediction flag of the intra prediction unit 34 and encodes it as the intra prediction parameter of the color difference signal in FIG. The intra prediction unit 34 of the apparatus determines whether to perform inter-color signal prediction or intra prediction from the intra prediction parameters of the color difference signals variable-length decoded by the variable-length decoding unit 31.
In the above example, the case where the presence / absence of the execution of the inter-color signal prediction process is selected for each prediction block has been described. However, the image coding apparatus in FIG. 1 performs the coding block unit or the maximum size coding block unit. When configured to perform selection, the image decoding apparatus is configured to decode the inter-color signal prediction flag in the same block unit. In this way, the encoding parameter can be correctly decoded.
Further, when the inter-color signal prediction flag is ON as the inter-color signal prediction parameter that has been variable-length decoded by the variable-length decoding unit 31, the variable-length decoding unit 31 uses the inter-color signal vector indicating the block position of the reference signal. The reference signal information indicating which color signal is referred to is decoded. However, when the image encoding apparatus of FIG. 1 is configured not to use the inter-color signal vector and the reference signal information, the image decoding apparatus does not decode these parameters and is the same as the image encoding apparatus. The prediction image is generated with reference to the block at the same position of the reference signal.

逆量子化・逆変換部32は、可変長復号部31から圧縮データ及び予測差分符号化パラメータを受けると、図1の逆量子化・逆変換部10と同様の手順で、その予測差分符号化パラメータに含まれる量子化パラメータ及び変換ブロック分割情報を参照して、変換ブロック単位にその圧縮データを逆量子化する。
このとき、可変長復号部31により可変長復号された各ヘッダ情報を参照し、各ヘッダ情報が、当該スライスで量子化マトリクスを用いて、逆量子化処理を実施することを示している場合は、量子化マトリクスを用いて逆量子化処理を行う。
When receiving the compressed data and the prediction difference encoding parameter from the variable length decoding unit 31, the inverse quantization / inverse conversion unit 32 performs the prediction difference encoding in the same procedure as the inverse quantization / inverse conversion unit 10 of FIG. With reference to the quantization parameter and transform block division information included in the parameters, the compressed data is inversely quantized in transform block units.
At this time, when referring to each header information variable-length decoded by the variable-length decoding unit 31, each header information indicates that the inverse quantization process is performed using the quantization matrix in the slice. Inverse quantization processing is performed using a quantization matrix.

この際、可変長復号部31により可変長復号された各ヘッダ情報を参照して、各直交変換サイズで色信号や符号化モード(イントラ符号化、イントラブロックコピー符号化、インター符号化)毎に使用する量子化マトリクスを特定する。
また、逆量子化・逆変換部32は、変換ブロック単位に逆量子化後の圧縮データである変換係数に対する逆直交変換処理を実施して、図1の逆量子化・逆変換部10から出力された局所復号予測差分信号と同一の復号予測差分信号を算出する(ステップST29)。
At this time, referring to each header information variable length decoded by the variable length decoding unit 31, for each color signal and coding mode (intra coding, intra block copy coding, inter coding) with each orthogonal transform size Specify the quantization matrix to be used.
Further, the inverse quantization / inverse transform unit 32 performs inverse orthogonal transform processing on transform coefficients that are compressed data after inverse quantization in units of transform blocks, and outputs from the inverse quantization / inverse transform unit 10 in FIG. The same decoded prediction difference signal as the local decoding prediction difference signal thus obtained is calculated (step ST29).

加算部37は、逆量子化・逆変換部32により算出された復号予測差分信号と、イントラ予測部34により生成されたイントラ予測画像PINTRAi 、イントラブロックコピー予測部35により生成されたイントラブロックコピー予測画像PICOPYi 、又は、動き補償予測部36により生成されたインター予測画像PINTERi のいずれかを加算して復号画像を算出し、その復号画像をループフィルタ部39に出力するとともに、その復号画像をイントラ用メモリ38に格納する(ステップST30)。
この復号画像が、以降のイントラ予測処理及びイントラブロックコピー予測処理の際に用いられる復号済みの画像信号になる。
Addition unit 37, an intra block generated by the decoded prediction difference signal calculated by the inverse quantization and inverse transform unit 32, an intra prediction image P INTRAi n, intra block copy prediction unit 35 generated by the intra prediction unit 34 copy predicted image P ICOPYi n, or, together with by adding one of generated by the motion compensation prediction unit 36 inter-prediction image P INTERi n calculates a decoded image, and outputs the decoded image to the loop filter unit 39, The decoded image is stored in the intra memory 38 (step ST30).
This decoded image becomes a decoded image signal used in the subsequent intra prediction processing and intra block copy prediction processing.

ループフィルタ部39は、全ての符号化ブロックBに対するステップST23〜ST30の処理が完了すると(ステップST31)、加算部37から出力された復号画像に対して、所定のフィルタ処理を実施して、フィルタ処理後の復号画像を動き補償予測フレームメモリ40に格納する(ステップST32)。
具体的には、変換ブロックの境界や予測ブロックの境界に発生する歪みを低減するフィルタ(デブロッキングフィルタ)処理、画素単位に適応的にオフセットを加算する(画素適応オフセット)処理、ウィーナフィルタ等の線形フィルタを適応的に切り替えてフィルタ処理する適応フィルタ処理などを行う。
ただし、ループフィルタ部39は、上記のデブロッキングフィルタ処理、画素適応オフセット処理、適応フィルタ処理のそれぞれについて、可変長復号部31により可変長復号された各ヘッダ情報を参照して、当該スライスで処理を行うか否かを特定する。
このとき、2つ以上のフィルタ処理を行う場合に、例えば、画像符号化装置のループフィルタ部13が図11のように構成されている場合には、図12に示すようにループフィルタ部39が構成される。
Loop filter unit 39, the process of step ST23~ST30 of all the coding blocks B n is completed (step ST31), the output has been decoded image from the adder 37, and performs a predetermined filtering process, The decoded image after the filter process is stored in the motion compensated prediction frame memory 40 (step ST32).
Specifically, filter (deblocking filter) processing that reduces distortion occurring at the boundaries of transform blocks and prediction blocks, processing for adaptively adding an offset (pixel adaptive offset) for each pixel, Wiener filter, etc. Performs adaptive filter processing for adaptively switching linear filters and performing filter processing.
However, the loop filter unit 39 refers to each header information variable-length decoded by the variable-length decoding unit 31 for each of the above-described deblocking filter processing, pixel adaptive offset processing, and adaptive filter processing, and performs processing in the corresponding slice. Specify whether or not to perform.
At this time, when two or more filter processes are performed, for example, when the loop filter unit 13 of the image encoding device is configured as shown in FIG. 11, the loop filter unit 39 as shown in FIG. Composed.

ここで、デブロッキングフィルタ処理では、可変長復号部31により可変長復号されたヘッダ情報を参照し、ブロック境界にかけるフィルタ強度の選択に用いる各種パラメータを初期値から変更する情報が存在する場合には、その変更情報に基づいて、デブロッキングフィルタ処理を実施する。変更情報がない場合は、予め定められた手法に従って行う。   Here, in the deblocking filter processing, when there is information for referring to the header information that has been variable-length decoded by the variable-length decoding unit 31 and changing various parameters used for selecting the filter strength applied to the block boundary from the initial value. Performs a deblocking filter process based on the change information. When there is no change information, it is performed according to a predetermined method.

画素適応オフセット処理では、可変長復号部31により可変長復号された画素適応オフセット処理のブロック分割情報に基づいて分割し、そのブロック単位に、可変長復号部31により可変長復号されたブロック単位のクラス分類手法を示すインデックスを参照して、そのインデックスが“オフセット処理を行わない”ことを示すインデックスでない場合、ブロック単位にブロック内の各画素を上記インデックスが示すクラス分類手法に従ってクラス分類する。
なお、クラス分類手法の候補として、ループフィルタ部13の画素適応オフセット処理のクラス分類手法の候補と同一のものが予め用意されている。
In the pixel adaptive offset processing, the block is divided based on the block division information of the pixel adaptive offset processing variable-length decoded by the variable-length decoding unit 31, and the block unit of variable-length decoded by the variable-length decoding unit 31 is divided into the blocks. When an index indicating a class classification method is referred to and the index is not an index indicating that “offset processing is not performed”, each pixel in the block is classified into blocks in accordance with the class classification method indicated by the index.
Note that the same class classification method candidates as those for the pixel adaptive offset processing class classification method of the loop filter unit 13 are prepared in advance.

そして、ループフィルタ部39は、ブロック単位の各クラスのオフセット値を特定する可変長復号部31により可変長復号されたオフセット情報を参照して、復号画像の画素値にオフセットを加算する処理を行う。   Then, the loop filter unit 39 performs processing for adding the offset to the pixel value of the decoded image with reference to the offset information that has been variable-length decoded by the variable-length decoding unit 31 that identifies the offset value of each class in block units. .

適応フィルタ処理では、可変長復号部31により可変長復号されたクラス毎のフィルタを用いて、図1の画像符号化装置と同一の手法でクラス分類した後に、そのクラス分類情報に基づいてフィルタ処理を行う。
このループフィルタ部39によるフィルタ処理後の復号画像が、動き補償予測用の参照画像となり、また、再生画像となる。
In the adaptive filter process, after classifying by the same method as the image encoding apparatus of FIG. 1 using the filter for each class variable-length decoded by the variable-length decoding unit 31, the filter process is performed based on the class classification information. I do.
The decoded image after the filter processing by the loop filter unit 39 becomes a reference image for motion compensation prediction and also becomes a reproduced image.

以上で明らかなように、この実施の形態1によれば、画像符号化装置のイントラ予測部5、イントラブロックコピー予測部6又は動き補償予測部7が、各予測ブロックに対して、当該予測ブロックの色信号間予測フラグが色信号間予測処理の実施を明示していれば、イントラ予測処理、イントラブロックコピー予測処理、動き補償予測処理を実施せずに、符号化済みの色信号を参照して、予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施するように構成したので、予測ブロック内の絵柄が特定の非直線な模様や文字などであっても、予測精度を高めて、高い符号化効率を実現することができる効果を奏する。   As is apparent from the above, according to the first embodiment, the intra prediction unit 5, the intra block copy prediction unit 6 or the motion compensated prediction unit 7 of the image coding apparatus performs the prediction block for each prediction block. If the inter-color signal prediction flag clearly indicates that the inter-color signal prediction process is performed, the encoded color signal is referred to without performing the intra prediction process, intra block copy prediction process, and motion compensation prediction process. Therefore, even if the pattern in the prediction block is a specific non-linear pattern or character, the prediction accuracy is improved. There is an effect that it is possible to achieve high encoding efficiency.

また、この実施の形態1によれば、上記効果を持つ画像符号化装置及び画像符号化方法が生成する符号化ビットストリームを正しく復号することができる画像復号装置及び画像復号方法が得られる効果を奏する。   In addition, according to the first embodiment, the image decoding apparatus and the image decoding method that can correctly decode the encoded bitstream generated by the image encoding apparatus and the image encoding method having the above effects can be obtained. Play.

実施の形態2.
この実施の形態2では、予測差分信号の色信号間相関除去処理を実施する画像符号化装置及び画像復号装置について説明する。
即ち、上記実施の形態1の画像符号化装置における色差信号の予測差分信号に対して、符号化済み色信号の局所復号予測差分信号との差分値を変換・量子化部9に入力すると共に、逆量子化・逆変換部10で得られる色差信号の局所復号予測差分信号に対して上記符号化済み信号の予測差分信号を加算して最終的な局所復号予測差分信号を得る画像符号化装置を構成する。
また、上記実施の形態1の画像復号装置における逆量子化・逆変換部32で得られる色差信号の復号予測差分信号に対して、この実施の形態2の画像符号化装置と同一の符号化済み色信号の復号予測差分信号を加算して最終的な復号予測差分信号を得る画像復号装置を構成する。
このようにすることで色信号間の予測差分の相関を低減し、色差信号の予測差分信号の符号化に要する符号量を削減することができる。
Embodiment 2. FIG.
In the second embodiment, an image encoding device and an image decoding device that perform a correlation removal process between color signals of a prediction difference signal will be described.
That is, for the prediction difference signal of the chrominance signal in the image coding apparatus of the first embodiment, a difference value between the encoded chrominance signal and the locally decoded prediction difference signal is input to the transform / quantization unit 9; An image coding apparatus that obtains a final locally decoded prediction difference signal by adding the prediction difference signal of the encoded signal to the local decoded prediction difference signal of the color difference signal obtained by the inverse quantization / inverse transform unit 10 Configure.
Also, the decoded prediction difference signal of the chrominance signal obtained by the inverse quantization / inverse transform unit 32 in the image decoding apparatus of the first embodiment is encoded in the same way as the image coding apparatus of the second embodiment. An image decoding apparatus that obtains a final decoded prediction difference signal by adding the decoded prediction difference signals of color signals is configured.
By doing in this way, the correlation of the prediction difference between color signals can be reduced, and the code amount required for encoding the prediction difference signal of a color difference signal can be reduced.

このとき、画像符号化装置における参照する局所復号予測差分信号は、上記実施の形態1の色信号間予測処理と同様に、周囲の符号化済み画素を用いて相関パラメータを算出して、本相関パラメータにて加工された局所復号予測差分信号を参照するようにしてもよい。このようにすることで、色信号間の予測差分の相関除去精度を改善することができ、符号化効率を高めることができる。この場合、画像復号装置における参照する復号予測差分信号も周囲の復号済み画素を用いて相関パラメータを算出して、本相関パラメータにて加工された復号予測差分信号を参照する。   At this time, the local decoded prediction difference signal to be referred to in the image coding apparatus calculates the correlation parameter using the surrounding coded pixels in the same manner as in the inter-color signal prediction process of the first embodiment, and performs the main correlation. You may make it refer to the local decoding prediction difference signal processed with the parameter. By doing in this way, the correlation removal precision of the prediction difference between color signals can be improved, and encoding efficiency can be improved. In this case, the decoded prediction difference signal to be referred to in the image decoding apparatus also calculates a correlation parameter using surrounding decoded pixels, and refers to the decoded prediction difference signal processed with this correlation parameter.

上記の例では、相関パラメータは周囲の符号化(復号)済み画素を用いて算出するとしているが、相関パラメータは複数の候補を予め用意し、変換ブロック単位に選択して符号化するようにしてもよい。このようにすることで、変換ブロック単位に最適な相関パラメータを利用することができ、符号化効率を高めることができる。この場合、画像復号装置は上記相関パラメータを変換ブロック単位に復号する。
さらに、変換ブロック単位に、上記予測差分信号の色信号間相関除去処理を行うか否かを示すON/OFF情報をフラグ情報として符号化するようにしてもよい。このようにすることで、変換ブロック単位に色信号間相関除去処理を行う場合と行わない場合の2つの中から符号化効率が高い方を選択することができるため、符号化効率を高めることができる。
なお、上記ON/OFF情報は、上記相関パラメータの一部として符号化するようにしてもよい。具体的には、相関パラメータが特定の値の場合(例えば、0)は、上記色信号間相関除去処理を行わないことを示すものとすればよい。
In the above example, the correlation parameter is calculated using surrounding encoded (decoded) pixels. However, for the correlation parameter, a plurality of candidates are prepared in advance, and selected and encoded for each transform block. Also good. In this way, the optimum correlation parameter can be used for each transform block, and the coding efficiency can be improved. In this case, the image decoding apparatus decodes the correlation parameter in units of transform blocks.
Further, ON / OFF information indicating whether or not to perform the correlation removal processing between color signals of the prediction difference signal may be encoded as flag information for each transform block. By doing in this way, since the one where encoding efficiency is higher can be selected from the two cases where the inter-color signal correlation removal processing is performed in units of transform blocks and when it is not performed, the encoding efficiency can be improved. it can.
The ON / OFF information may be encoded as part of the correlation parameter. Specifically, when the correlation parameter is a specific value (for example, 0), it may be indicated that the correlation removal process between color signals is not performed.

また、上記実施の形態1の色信号間予測処理と同様に、色信号間ベクトルを用意して、本ベクトルの指すブロックを参照するようにしても良い。このとき、色信号間ベクトルは上記実施の形態1の色信号間予測処理と共通でも良いし、独立に持つようにしても良い。独立に用意する場合は、より適応的な制御ができるため予測差分信号の値を一層小さくすることができるが、上記実施の形態1の色信号間予測処理の色信号間ベクトルとは別に符号化する必要があり、画像の特性によって独立にした場合と共通にした場合のどちらが符号化効率が高いのかは異なる。したがって、シーケンスレベルヘッダ、ピクチャレベルヘッダ、スライスレベルヘッダの少なくとも一箇所に色信号間ベクトルを用いるか否かのフラグと上記実施の形態1の色信号間予測処理と独立とするか共通とするかのフラグを用意し、画像符号化装置にて上記フラグを符号化するように構成してもよい。このとき、画像復号装置はこれらフラグを復号することで、予測差分信号の色信号間相関除去処理における色信号間ベクトルの有無とその値を識別する。   Further, similarly to the inter-color signal prediction process of the first embodiment, an inter-color signal vector may be prepared and a block indicated by this vector may be referred to. At this time, the inter-color signal vector may be common to the inter-color signal prediction process of the first embodiment, or may be provided independently. When prepared independently, the value of the prediction difference signal can be further reduced because more adaptive control can be performed, but encoding is performed separately from the inter-color signal vector of the inter-color signal prediction process of the first embodiment. Depending on the characteristics of the image, it is different whether the coding efficiency is higher when it is independent or when it is shared. Therefore, whether the inter-color signal vector is used in at least one of the sequence level header, the picture level header, and the slice level header and whether the inter-color signal prediction process of the first embodiment is independent or common. May be prepared, and the above-described flag may be encoded by the image encoding device. At this time, the image decoding apparatus decodes these flags, thereby identifying the presence / absence and the value of the inter-color signal vector in the inter-color signal correlation removal process of the prediction difference signal.

さらに、上記実施の形態1の色信号間予測処理と同様に、参照する符号化済み色信号を静的、あるいは動的に切り替えるようにしても良い。具体的には、Y(輝度)信号、U信号、V信号の順番で符号化する場合、U信号はY信号、V信号はY信号又はU信号を参照する。このとき、V信号については、Y信号とU信号のどちらを参照するかを画像符号化装置と画像復号装置共通で固定的に構成してもよいし(例えば、常にU信号を参照するように構成する)、どちらを参照するかを切り替え可能として、その切り替え単位毎に参照信号情報を符号化するようにしてもよい。
切り替えの単位は、シーケンス、ピクチャ、スライス単位としてもよいし、符号化ブロック、予測ブロック、変換ブロック等のブロック単位としてもよい。一般に、切り替え単位が細かい程予測効率は高くなる。一方、切り替え単位を大まかにすることで符号化する参照信号情報を符号化する際に発生する符号量を抑えることができる。
さらに、ブロック単位に参照信号を切り替え可能とする場合、シーケンスレベルヘッダ、ピクチャレベルヘッダ、スライスレベルヘッダに上記ブロック単位の切り替え処理を有効とするか否かを示すフラグを持つようにしてもよい。このようにすることで、本切り替え処理が効果的な場合のみ有効とするようにして、本切り替え処理が効果的でない場合に上記ブロック単位の参照信号情報を符号化せずに済み、符号化効率を高めることができる。
Furthermore, the encoded color signal to be referred to may be switched statically or dynamically, similarly to the inter-color signal prediction process of the first embodiment. Specifically, when encoding in the order of Y (luminance) signal, U signal, and V signal, the U signal refers to the Y signal, and the V signal refers to the Y signal or U signal. At this time, with respect to the V signal, it may be fixedly configured to refer to either the Y signal or the U signal in common to the image encoding device and the image decoding device (for example, the U signal is always referred to). The reference signal information may be encoded for each switching unit.
The unit of switching may be a sequence, a picture, a slice unit, or a block unit such as an encoded block, a prediction block, or a transform block. In general, the smaller the switching unit, the higher the prediction efficiency. On the other hand, the amount of code generated when encoding the reference signal information to be encoded can be suppressed by roughly setting the switching unit.
Further, when the reference signal can be switched in units of blocks, a flag indicating whether or not the switching processing in units of blocks is valid may be included in the sequence level header, picture level header, and slice level header. In this way, only when this switching process is effective, it is effective. When this switching process is not effective, it is not necessary to encode the reference signal information for each block, and the encoding efficiency is improved. Can be increased.

上記の例では、上記の参照信号情報について、Y信号とU信号のどちらを参照するかを決定する情報として説明したが、さらにY信号とU信号を共に参照して重み付き平均によって参照ブロックを生成する場合も含めるようにしてもよい。即ち、設定した切り替え単位毎に、Y信号のみを参照して予測画像を生成するか、U信号のみを参照して予測画像を生成するか、Y信号とU信号を共に参照して予測画像を生成するかを選択するようにする。このようにすることで、より予測差分信号を小さくすることができ、符号化効率を高めることができる。   In the above example, the reference signal information has been described as information for determining whether to refer to the Y signal or the U signal, but the reference block is further determined by weighted averaging with reference to both the Y signal and the U signal. You may make it also include the case where it produces | generates. That is, for each set switching unit, a predicted image is generated with reference to only the Y signal, a predicted image is generated with reference to only the U signal, or a predicted image is referred to with reference to both the Y signal and the U signal. Select whether to generate. By doing in this way, a prediction difference signal can be made smaller and encoding efficiency can be improved.

また、画像符号化装置と画像復号装置共通で固定的に参照色信号を設定するように構成する場合でも、上記参照信号情報を符号化するように構成する場合でも、上記実施の形態1の色信号間予測処理と共通としても良いし、独立に設定するようにしても良い。独立に用意する場合は、より適応的な制御ができるため予測差分信号の値を一層小さくすることができる。ただし、上記参照信号情報を符号化するように構成する場合では、上記実施の形態1の色信号間予測処理の参照信号情報とは別に参照信号情報を符号化する必要があり、画像の特性によって独立にした場合と共通にした場合のどちらが符号化効率が高いのかは異なる。したがって、シーケンスレベルヘッダ、ピクチャレベルヘッダ、スライスレベルヘッダの少なくとも一箇所に上記実施の形態1の色信号間予測処理と独立とするか共通とするかのフラグを用意し、画像符号化装置にて上記フラグを符号化するように構成してもよい。このとき、画像復号装置は本フラグを復号することで、予測差分信号の色信号間相関除去処理における参照信号情報を識別する。   The color of the first embodiment is used regardless of whether the reference color signal is fixedly set in common with the image encoding device and the image decoding device, or when the reference signal information is encoded. It may be common with the inter-signal prediction process or may be set independently. When prepared independently, since the adaptive control can be performed, the value of the prediction difference signal can be further reduced. However, when the reference signal information is configured to be encoded, it is necessary to encode the reference signal information separately from the reference signal information of the inter-color signal prediction process of the first embodiment. Which of the independent case and the common case has higher encoding efficiency is different. Therefore, a flag indicating whether to be independent or common to the inter-color signal prediction process of the first embodiment is prepared in at least one place of the sequence level header, the picture level header, and the slice level header. You may comprise so that the said flag may be encoded. At this time, the image decoding apparatus identifies the reference signal information in the color signal correlation removal processing of the prediction difference signal by decoding this flag.

また、上記実施の形態1の色信号間予測処理と、上記予測差分信号の色信号間相関除去処理との組み合わせとして、上記実施の形態1の色信号間予測処理を実施するブロックでは、上記予測差分信号の色信号間相関除去処理を実施しないものとしてもよい。このようにすることで、色信号間予測処理を実施するブロックでは、予測差分信号の色信号間相関除去処理に関わる符号化パラメータ(相関パラメータ、ON/OFF情報など)を符号化する必要がないため、符号化量を削減することができる。この場合、画像復号装置では、可変長復号部31により可変長復号された色信号間予測パラメータが色信号間予測処理を行わないことを示している場合のみ、可変長復号部31が予測差分信号の色信号間相関除去処理に関わる符号化パラメータを復号する。
この場合、上記実施の形態1の色信号間予測処理のブロック単位のON/OFF情報と上記予測差分信号の色信号間相関除去処理のブロック単位のON/OFF情報を統合してもよい。具体的には、上記実施の形態1の色信号間予測処理を行う場合、上記予測差分信号の色信号間相関除去処理を行う場合、両処理共に実施しない場合をインデックス情報とする(たとえば順に、インデックス2、1、0とする)。このとき、両処理のON/OFF情報の切り替え単位は統一しなくてはならない。すなわち、この場合、ON/OFF処理は符号化ブロック、予測ブロック、変換ブロック単位のいずれかに統一する。あるいは独自のブロック単位としても良い。このようにすることで、両処理に最適なブロックサイズを設定することができる。
In addition, in the block that performs the inter-color signal prediction process of the first embodiment as a combination of the inter-color signal prediction process of the first embodiment and the inter-color signal correlation removal process of the prediction difference signal, the prediction The difference signal intercolor signal correlation removal processing may not be performed. In this way, in the block that performs the inter-color signal prediction process, it is not necessary to encode the encoding parameters (correlation parameters, ON / OFF information, etc.) related to the inter-color signal correlation removal process of the prediction difference signal. Therefore, the encoding amount can be reduced. In this case, in the image decoding apparatus, only when the inter-color signal prediction parameter variable-length decoded by the variable-length decoding unit 31 indicates that the inter-color signal prediction process is not performed, the variable-length decoding unit 31 performs the prediction difference signal. The coding parameters related to the correlation removal process between color signals are decoded.
In this case, the ON / OFF information in units of blocks of the inter-color signal prediction process of Embodiment 1 and the ON / OFF information in units of blocks of the inter-color signal correlation removal process of the prediction difference signal may be integrated. Specifically, when performing the inter-color signal prediction process of the first embodiment, performing the inter-color signal correlation removal process of the prediction difference signal, and not performing both processes as index information (for example, in order, Index 2, 1, 0). At this time, the unit for switching ON / OFF information for both processes must be unified. That is, in this case, the ON / OFF processing is unified to any one of a coding block, a prediction block, and a transform block. Or it is good also as an original block unit. In this way, an optimal block size can be set for both processes.

上記予測差分信号の色信号間相関除去処理を制御するパラメータとして、本処理の有効フラグ(上位ヘッダ残差色信号間予測有効フラグ)をシーケンスレベルヘッダ、ピクチャレベルヘッダ、スライスレベルヘッダのうち、少なくとも1つのヘッダで符号化するようにしてもよい。このようにすることで、予測差分信号の色信号間相関除去処理が効果的でない場合に無効とすることができ、符号化効率の低下を抑制することができる。この場合、画像復号装置では、可変長復号部31が上記上位ヘッダ残差色信号間予測有効フラグを復号し、上記上位ヘッダ残差色信号間予測有効フラグが有効を示す場合のみ、予測差分信号の色信号間相関除去処理を有効とし、変換ブロック単位の上記ON/OFF情報を復号する。
さらに、上記上位ヘッダ残差色信号間予測有効フラグについて、ピクチャを分割するサブピクチャの単位に設けるようにしても良い。具体的には、非特許文献1記載のTileやWavefront Parallel Processingのサブピクチャの分割単位に上記上位ヘッダ残差色信号間予測有効フラグを設けることで、色信号間予測が効果的な領域のみ有効とすることが可能となり符号量の増加を抑制しつつ高精度な予測が実現できる。
As a parameter for controlling the inter-color signal correlation removal processing of the prediction difference signal, an effective flag (higher header residual color signal inter-prediction effective flag) of this processing is set as at least one of a sequence level header, a picture level header, and a slice level header. You may make it encode with one header. By doing in this way, when the correlation removal process between color signals of a prediction difference signal is not effective, it can be made invalid, and the fall of encoding efficiency can be suppressed. In this case, in the image decoding apparatus, only when the variable length decoding unit 31 decodes the upper header residual color signal inter-prediction valid flag and the upper header residual color signal inter-prediction valid flag indicates valid, the prediction difference signal The color signal correlation removal processing is enabled, and the ON / OFF information in units of transform blocks is decoded.
Furthermore, the upper header residual color signal inter-prediction valid flag may be provided in units of sub-pictures that divide a picture. Specifically, by providing the upper header residual color signal prediction effective flag in the division unit of the Tile or Wavefront Parallel Processing sub-picture described in Non-Patent Document 1, only the region where the color signal prediction is effective is effective. Therefore, highly accurate prediction can be realized while suppressing an increase in the code amount.

さらに、予測差分信号の色信号間相関除去処理を有効とするか否かを示すシーケンスレベル、ピクチャレベル、スライスレベル、サブピクチャレベルのフラグと、上記実施の形態1の色信号間予測処理を有効とするか否かを示すシーケンスレベル、ピクチャレベル、スライスレベル、サブピクチャレベルのフラグを組み合わせてもよい。具体的には、予測差分信号の色信号間相関除去処理と色信号間予測処理の有効・無効の組み合わせ(有効・有効、有効・無効、無効・有効、無効・無効の全4種類)を示すインデックスとして符号化する。この場合、画像復号装置では、可変長復号部31が上記のインデックスを復号し、そのインデックスに基づいて、予測差分信号の色信号間相関除去処理と色信号間予測処理の有効・無効を決定する。   Further, the sequence level, picture level, slice level, and sub-picture level flags indicating whether or not to enable the inter-color signal correlation removal processing of the prediction difference signal and the inter-color signal prediction processing of the first embodiment are enabled. Sequence level, picture level, slice level, and sub-picture level flags indicating whether or not to be used may be combined. Specifically, it shows the combination of valid / invalid of the inter-color signal correlation removal processing of the prediction difference signal and the inter-color signal prediction processing (valid / valid, valid / invalid, invalid / valid, invalid / invalid) Encode as an index. In this case, in the image decoding apparatus, the variable length decoding unit 31 decodes the above-described index, and determines whether the inter-color signal correlation removal process and the inter-color signal prediction process of the prediction difference signal are valid / invalid based on the index. .

また、上記予測差分信号の色信号間相関除去処理を実施する変換ブロックの直交変換処理を常にDSTとするようにしても良い。予測差分信号の色信号間相関除去処理を実施した変換ブロックの予測差分信号は信号間の相関が非常に低くなるため、DCTよりもDSTの方が効率的である可能性が高く、DCTを用いるよりも符号化効率を高めることができる。
あるいは、DCTとDSTをブロックサイズ、符号化モード、イントラ予測パラメータ、イントラブロックコピー予測パラメータ、動き補償予測パラメータ等に応じて切り替えるようにしても良い。例えば、対象とする変換ブロックのサイズが特定のブロックサイズ(しきい値)より小さい場合、DSTを行うようにする、等が考えられる。このようにすることで、対象とする変換ブロックの特性に応じた変換が実現でき、符号化効率を高めることができる。他にも、DCTとDSTのうち符号化効率が高くなる方を選択し、その選択情報を符号化するようにしても良い。このようにすることで、変換ブロック毎にDCTとDSTから適切な方を用いて変換することができ、符号化効率を高めることができる。
上記以外の構成として、予測差分信号の色信号間相関除去処理を実施した変換ブロックの予測差分信号に適切なKL変換を予め設計する、または動的に学習して設計するようにしても良い。このようにすることで、予測差分信号の色信号間相関除去処理を実施した変換ブロックの予測差分信号に一層適した基底による変換が実現でき、符号化効率を高めることができる。
なお、上記で説明した事項以外、この実施の形態2は、上記実施の形態1と同じ構成、処理を実施する。
Further, the orthogonal transform process of the transform block that performs the inter-color signal correlation removal process of the prediction difference signal may be always DST. The prediction difference signal of the transform block that has been subjected to the process of removing the correlation between the color signals of the prediction difference signal has a very low correlation between the signals. Therefore, it is highly likely that DST is more efficient than DCT, and DCT is used. Thus, the encoding efficiency can be increased.
Alternatively, DCT and DST may be switched according to the block size, coding mode, intra prediction parameter, intra block copy prediction parameter, motion compensation prediction parameter, and the like. For example, when the size of the target conversion block is smaller than a specific block size (threshold value), DST may be performed. By doing in this way, the conversion according to the characteristic of the conversion block made into object can be realized, and coding efficiency can be improved. In addition, the DCT and DST that have higher encoding efficiency may be selected, and the selection information may be encoded. By doing in this way, it can convert using DCT and DST for every conversion block, and can improve encoding efficiency.
As a configuration other than the above, an appropriate KL transform may be designed in advance for the prediction difference signal of the transform block that has been subjected to the inter-color signal correlation removal processing of the prediction difference signal, or may be designed by learning dynamically. By doing in this way, the conversion by the base more suitable for the prediction difference signal of the conversion block which performed the correlation removal process between color signals of a prediction difference signal can be implement | achieved, and encoding efficiency can be improved.
In addition to the matters described above, the second embodiment implements the same configuration and processing as the first embodiment.

実施の形態3.
この実施の形態3では、上記実施の形態1または上記実施の形態2に対して、色信号間予測処理の相関パラメータを複数の候補から選択するように構成する。選択の単位は、シーケンス、ピクチャ、スライス単位としてもよいし、符号化ブロック、予測ブロック、変換ブロック等のブロック単位としてもよい。一般に、切り替え単位が細かい程予測効率は高くなる。一方、切り替え単位を大まかにすることで符号化する参照信号情報を符号化する際に発生する符号量を抑えることができる。
さらに、相関パラメータを上記実施の形態2の予測差分信号の色信号間相関除去処理の相関パラメータと共通化してもよい。このようにすることで、相関パラメータに関する符号量を削減することができる。
なお、上記で説明した事項以外、この実施の形態3は上記実施の形態1,2と同じ構成、処理を実施する。
Embodiment 3 FIG.
In the third embodiment, the correlation parameter of the inter-color signal prediction process is selected from a plurality of candidates as compared with the first embodiment or the second embodiment. The unit of selection may be a sequence, a picture, a slice unit, or a block unit such as an encoded block, a prediction block, or a transform block. In general, the smaller the switching unit, the higher the prediction efficiency. On the other hand, the amount of code generated when encoding the reference signal information to be encoded can be suppressed by roughly setting the switching unit.
Further, the correlation parameter may be shared with the correlation parameter of the inter-color signal correlation removal process of the prediction difference signal of the second embodiment. By doing in this way, the code amount regarding a correlation parameter can be reduced.
Except for the matters described above, the third embodiment performs the same configuration and processing as the first and second embodiments.

なお、本願発明はその発明の範囲内において、各実施の形態の自由な組み合わせ、あるいは各実施の形態の任意の構成要素の変形、もしくは各実施の形態において任意の構成要素の省略が可能である。   In the present invention, within the scope of the invention, any combination of the embodiments, or any modification of any component in each embodiment, or omission of any component in each embodiment is possible. .

1 符号化制御部、2 スライス分割部、3 ブロック分割部、4 切換スイッチ、5 イントラ予測部(イントラ予測手段)、6 イントラブロックコピー予測部(イントラブロックコピー予測手段)、7 動き補償予測部(動き補償予測手段)、8 減算部、9 変換・量子化部、10 逆量子化・逆変換部、11 加算部、12 イントラ用メモリ、13 ループフィルタ部、14 動き補償予測フレームメモリ、15 可変長符号化部(符号化手段)、31 可変長復号部、32 逆量子化・逆変換部、33 切換スイッチ、34 イントラ予測部(イントラ予測手段)、35 イントラブロックコピー予測部(イントラブロックコピー予測手段)、36 動き補償予測部(動き補償予測手段)、37 加算部、38 イントラ用メモリ、39 ループフィルタ部、40 動き補償予測フレームメモリ。   DESCRIPTION OF SYMBOLS 1 Encoding control part, 2 slice division part, 3 block division part, 4 changeover switch, 5 intra prediction part (intra prediction means), 6 intra block copy prediction part (intra block copy prediction means), 7 motion compensation prediction part ( Motion compensation prediction means), 8 subtraction unit, 9 transformation / quantization unit, 10 inverse quantization / inverse transformation unit, 11 addition unit, 12 intra memory, 13 loop filter unit, 14 motion compensation prediction frame memory, 15 variable length Encoding unit (encoding unit), 31 variable length decoding unit, 32 inverse quantization / inverse conversion unit, 33 changeover switch, 34 intra prediction unit (intra prediction unit), 35 intra block copy prediction unit (intra block copy prediction unit) ), 36 motion compensation prediction unit (motion compensation prediction means), 37 addition unit, 38 intra memory, 39 loops Filter unit, 40 motion-compensated prediction frame memory.

Claims (9)

予測処理単位のブロックである予測ブロック毎に、当該予測ブロックにおける輝度信号のブロックシフトベクトルを用いて、前記輝度信号の予測画像を生成するイントラブロックコピー予測処理を実施するイントラブロックコピー予測手段と、上記ブロックシフトベクトルを生成するイントラブロックコピー予測パラメータを可変長符号化する可変長符号化手段とを備え、
前記イントラブロックコピー予測手段は、当該予測ブロックの色差信号に対するフラグが色信号間予測処理の非実施を明示していれば、当該予測ブロックにおける輝度信号と同一のブロックシフトベクトルを用いて、前記色差信号の予測画像を生成するイントラブロックコピー予測処理を実施し、前記フラグが色信号間予測処理の実施を明示していれば、符号化済みの色差信号を参照して、当該予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施することを特徴とする画像符号化装置。
Intra block copy prediction means for performing an intra block copy prediction process for generating a prediction image of the luminance signal using a block shift vector of the luminance signal in the prediction block for each prediction block that is a block of a prediction processing unit; Variable length encoding means for variable length encoding intra block copy prediction parameters for generating the block shift vector,
If the flag for the color difference signal of the prediction block clearly indicates that inter-color signal prediction processing is not performed, the intra block copy prediction means uses the same block shift vector as the luminance signal in the prediction block, and uses the color difference signal. If intra block copy prediction processing for generating a prediction image of a signal is performed and the flag clearly indicates execution of inter-color signal prediction processing, the color difference signal in the prediction block is referred to by referring to the encoded color difference signal An image encoding device that performs inter-color signal prediction processing for generating a predicted image of the image.
予測処理単位のブロックである予測ブロック毎に、当該予測ブロックにおける輝度信号の動きベクトルを用いて、前記輝度信号の予測画像を生成する動き補償予測処理を実施する動き補償予測手段と、上記動きベクトルを生成するインター予測パラメータを可変長符号化する可変長符号化手段とを備え、
前記動き補償予測手段は、当該予測ブロックの色差信号に対するフラグが色信号間予測処理の非実施を明示していれば、当該予測ブロックにおける輝度信号と同一の動きベクトルを用いて、前記色差信号の予測画像を生成する動き補償予測処理を実施し、前記フラグが色信号間予測処理の実施を明示していれば、符号化済みの色差信号を参照して、当該予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施することを特徴とする画像符号化装置。
For each prediction block that is a block of a prediction processing unit, using the motion vector of the luminance signal in the prediction block, a motion compensation prediction unit that performs motion compensation prediction processing for generating a prediction image of the luminance signal, and the motion vector Variable length coding means for variable length coding inter prediction parameters for generating
If the flag for the color difference signal of the prediction block clearly indicates that the inter-color signal prediction process is not performed, the motion compensation prediction means uses the same motion vector as the luminance signal in the prediction block, and and performing motion compensation prediction process for generating a predicted image, if the flag if explicitly the implementation of inter-color signal prediction processing with reference to the color difference signals encoded, predictive image of the color difference signal in the prediction block An image encoding device that performs inter-color signal prediction processing for generating a color signal.
前記色差信号の予測画像を生成する際、前記色信号間予測処理を実施するか否かを示すフラグを符号化する符号化手段を備えたことを特徴とする請求項1または請求項2記載の画像符号化装置。   3. The encoding device according to claim 1, further comprising: an encoding unit configured to encode a flag indicating whether or not to perform the inter-color signal prediction process when generating the predicted image of the color difference signal. 4. Image encoding device. 予測処理単位のブロックである予測ブロック毎にブロックシフトベクトルを生成するイントラブロックコピー予測パラメータを可変長復号する可変長復号手段と、上記予測ブロック毎のイントラブロックコピー予測パラメータから生成される輝度信号のブロックシフトベクトルを用いて、前記輝度信号の予測画像を生成するイントラブロックコピー予測処理を実施するイントラブロックコピー予測手段を備え、
前記イントラブロックコピー予測手段は、当該予測ブロックの色差信号に対するフラグが色信号間予測処理の非実施を明示していれば、上記イントラブロックコピー予測パラメータから生成される輝度信号と同一のブロックシフトベクトルを用いて、前記色差信号の予測画像を生成するイントラブロックコピー予測処理を実施し、前記フラグが色信号間予測処理の実施を明示していれば、復号済みの色差信号を参照して、当該予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施することを特徴とする画像復号装置。
Variable length decoding means for variable length decoding intra block copy prediction parameters for generating a block shift vector for each prediction block which is a block of a prediction processing unit; and a luminance signal generated from the intra block copy prediction parameters for each prediction block Intra block copy prediction means for performing intra block copy prediction processing for generating a prediction image of the luminance signal using a block shift vector,
If the flag for the color difference signal of the prediction block clearly indicates that the inter-color signal prediction process is not performed, the intra block copy prediction means has the same block shift vector as the luminance signal generated from the intra block copy prediction parameter. Is used to perform an intra block copy prediction process for generating a prediction image of the color difference signal, and if the flag clearly indicates the execution of the inter-color signal prediction process, the decoded color difference signal is referred to An image decoding apparatus that performs inter-color signal prediction processing for generating a prediction image of a color difference signal in a prediction block.
予測処理単位のブロックである予測ブロック毎に動きベクトルを生成するインター予測パラメータを可変長復号する可変長復号手段と、上記予測ブロック毎のインター予測パラメータから生成される輝度信号の動きベクトルを用いて、前記輝度信号の予測画像を生成する動き補償予測処理を実施する動き補償予測手段を備え、
前記動き補償予測手段は、当該予測ブロックの色差信号に対するフラグが色信号間予測処理の非実施を明示していれば、上記インター予測パラメータから生成される輝度信号と同一の動きベクトルを用いて、前記色差信号の予測画像を生成する動き補償予測処理を実施し、前記フラグが色信号間予測処理の実施を明示していれば、復号済みの色差信号を参照して、当該予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施することを特徴とする画像復号装置。
Using variable-length decoding means for variable-length decoding inter prediction parameters for generating a motion vector for each prediction block, which is a block of a prediction processing unit, and a motion vector of a luminance signal generated from the inter-prediction parameters for each prediction block A motion compensation prediction means for performing a motion compensation prediction process for generating a prediction image of the luminance signal,
If the flag for the color difference signal of the prediction block clearly indicates that the inter-color signal prediction process is not performed, the motion compensation prediction unit uses the same motion vector as the luminance signal generated from the inter prediction parameter, If a motion compensation prediction process for generating a prediction image of the color difference signal is performed and the flag clearly indicates the execution of the inter-color signal prediction process, the color difference signal in the prediction block is referred to with reference to the decoded color difference signal An image decoding apparatus that performs an inter-color signal prediction process for generating a predicted image of the image.
イントラブロックコピー予測手段が、予測処理単位のブロックである予測ブロック毎に、当該予測ブロックにおける輝度信号のブロックシフトベクトルを用いて、前記輝度信号の予測画像を生成するイントラブロックコピー予測処理を実施するイントラブロックコピー予測処理ステップと、可変長符号化手段が、上記ブロックシフトベクトルを生成するイントラブロックコピー予測パラメータを可変長符号化する可変長符号化ステップとを備え、
前記イントラブロックコピー予測処理ステップでは、当該予測ブロックの色差信号に対するフラグが色信号間予測処理の非実施を明示していれば、当該予測ブロックにおける輝度信号と同一のブロックシフトベクトルを用いて、前記色差信号の予測画像を生成するイントラブロックコピー予測処理を実施し、前記フラグが色信号間予測処理の実施を明示していれば、符号化済みの色差信号を参照して、当該予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施することを特徴とする画像符号化方法。
An intra block copy prediction unit performs an intra block copy prediction process for generating a prediction image of the luminance signal, using a block shift vector of the luminance signal in the prediction block, for each prediction block that is a block of a prediction processing unit. An intra-block copy prediction processing step, and a variable-length encoding means, wherein the variable-length encoding means variable-length encodes an intra-block copy prediction parameter for generating the block shift vector,
In the intra block copy prediction processing step, if the flag for the color difference signal of the prediction block clearly indicates that inter-color signal prediction processing is not performed, the same block shift vector as the luminance signal in the prediction block is used. If intra block copy prediction processing for generating a prediction image of a color difference signal is performed, and the flag clearly indicates execution of the inter-color signal prediction processing, the color difference in the prediction block is referred to by referring to the encoded color difference signal. An image coding method, comprising: performing inter-color signal prediction processing for generating a predicted image of a signal.
動き補償予測手段が、予測処理単位のブロックである予測ブロック毎に、当該予測ブロックにおける輝度信号の動きベクトルを用いて、前記輝度信号の予測画像を生成する動き補償予測処理を実施する動き補償予測処理ステップと、可変長符号化手段が、上記動きベクトルを生成するインター予測パラメータを可変長符号化する可変長符号化ステップとを備え、
前記動き補償予測処理ステップでは、当該予測ブロックの色差信号に対するフラグが色信号間予測処理の非実施を明示していれば、当該予測ブロックにおける輝度信号と同一の動きベクトルを用いて、前記色差信号の予測画像を生成する動き補償予測処理を実施し、前記フラグが色信号間予測処理の実施を明示していれば、符号化済みの色差信号を参照して、当該予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施することを特徴とする画像符号化方法。
Motion compensation prediction means for performing motion compensation prediction processing for generating a prediction image of the luminance signal by using a motion vector of the luminance signal in the prediction block for each prediction block which is a block of a prediction processing unit. A processing step, and a variable-length coding means, a variable-length coding step for variable-length coding an inter prediction parameter for generating the motion vector,
In the motion compensation prediction processing step, if the flag for the color difference signal of the prediction block clearly indicates that the inter-color signal prediction processing is not performed, the color difference signal is calculated using the same motion vector as the luminance signal in the prediction block. When the motion compensated prediction process for generating the predicted image is performed and the flag clearly indicates the execution of the inter-color signal prediction process, the encoded color difference signal is referred to and the prediction of the color difference signal in the prediction block is performed. An image encoding method comprising performing inter-color signal prediction processing for generating an image.
可変長復号手段が、予測処理単位のブロックである予測ブロック毎にブロックシフトベクトルを生成するイントラブロックコピー予測パラメータを可変長復号する可変長復号ステップと、
イントラブロックコピー予測手段が、上記予測ブロック毎に、上記予測ブロック毎のイントラブロックコピー予測パラメータから生成される輝度信号のブロックシフトベクトルを用いて、前記輝度信号の予測画像を生成するイントラブロックコピー予測処理を実施するイントラブロックコピー予測処理ステップを備え、
前記イントラブロックコピー予測処理ステップでは、当該予測ブロックの色差信号に対するフラグが色信号間予測処理の非実施を明示していれば、上記イントラブロックコピー予測パラメータから生成される輝度信号と同一のブロックシフトベクトルを用いて、前記色差信号の予測画像を生成するイントラブロックコピー予測処理を実施し、前記フラグが色信号間予測処理の実施を明示していれば、復号済みの色差信号を参照して、当該予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施することを特徴とする画像復号方法。
A variable length decoding step, wherein the variable length decoding means variable length decodes an intra block copy prediction parameter for generating a block shift vector for each prediction block which is a block of a prediction processing unit;
Intra block copy prediction means for generating a prediction image of the luminance signal by using a block shift vector of the luminance signal generated from an intra block copy prediction parameter for each prediction block for each prediction block. An intra block copy prediction processing step for performing the processing;
In the intra block copy prediction processing step, if the flag for the color difference signal of the prediction block clearly indicates that inter-color signal prediction processing is not performed, the same block shift as the luminance signal generated from the intra block copy prediction parameter Perform intra block copy prediction processing for generating a prediction image of the color difference signal using a vector, and if the flag clearly indicates the execution of the inter-color signal prediction processing, refer to the decoded color difference signal, An image decoding method comprising: performing inter-color signal prediction processing for generating a predicted image of a color difference signal in the prediction block.
可変長復号手段が、予測処理単位のブロックである予測ブロック毎に動きベクトルを生成するインター予測パラメータを可変長復号する可変長復号ステップと、
動き補償予測手段が、上記予測ブロック毎に、上記予測ブロック毎のインター予測パラメータから生成される輝度信号の動きベクトルを用いて、前記輝度信号の予測画像を生成する動き補償予測処理を実施する動き補償予測処理ステップを備え、
前記動き補償予測処理ステップでは、当該予測ブロックの色差信号に対するフラグが色信号間予測処理の非実施を明示していれば、上記インター予測パラメータから生成される輝度信号と同一の動きベクトルを用いて、前記色差信号の予測画像を生成する動き補償予測処理を実施し、前記フラグが色信号間予測処理の実施を明示していれば、復号済みの色差信号を参照して、当該予測ブロックにおける色差信号の予測画像を生成する色信号間予測処理を実施することを特徴とする画像復号方法。
A variable length decoding step, wherein the variable length decoding means variable length decodes an inter prediction parameter for generating a motion vector for each prediction block which is a block of a prediction processing unit;
Motion in which motion compensation prediction means performs motion compensation prediction processing for generating a prediction image of the luminance signal using a motion vector of the luminance signal generated from the inter prediction parameter for each prediction block for each prediction block. A compensation prediction processing step,
In the motion compensation prediction processing step, if the flag for the color difference signal of the prediction block clearly indicates that the inter-color signal prediction processing is not performed, the same motion vector as the luminance signal generated from the inter prediction parameter is used. If the motion compensation prediction process for generating the predicted image of the color difference signal is performed and the flag clearly indicates the execution of the inter-color signal prediction process, the color difference in the prediction block is referred to by referring to the decoded color difference signal An image decoding method comprising: performing inter-color signal prediction processing for generating a predicted image of a signal.
JP2014052219A 2014-03-14 2014-03-14 Image encoding device, image decoding device, image encoding method, and image decoding method Active JP6362370B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2014052219A JP6362370B2 (en) 2014-03-14 2014-03-14 Image encoding device, image decoding device, image encoding method, and image decoding method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2014052219A JP6362370B2 (en) 2014-03-14 2014-03-14 Image encoding device, image decoding device, image encoding method, and image decoding method

Related Child Applications (1)

Application Number Title Priority Date Filing Date
JP2018120981A Division JP2018166329A (en) 2018-06-26 2018-06-26 Image encoder and image decoder

Publications (2)

Publication Number Publication Date
JP2015177343A JP2015177343A (en) 2015-10-05
JP6362370B2 true JP6362370B2 (en) 2018-07-25

Family

ID=54256109

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2014052219A Active JP6362370B2 (en) 2014-03-14 2014-03-14 Image encoding device, image decoding device, image encoding method, and image decoding method

Country Status (1)

Country Link
JP (1) JP6362370B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017139937A1 (en) * 2016-02-18 2017-08-24 Mediatek Singapore Pte. Ltd. Advanced linear model prediction for chroma coding
JP2020031252A (en) * 2016-12-22 2020-02-27 シャープ株式会社 Image decoding device and image encoding device
EP4351135A2 (en) * 2019-03-24 2024-04-10 Huawei Technologies Co., Ltd. Method and apparatus for chroma intra prediction in video coding

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101037855B1 (en) * 2005-07-22 2011-05-31 미쓰비시덴키 가부시키가이샤 Image encoding device, image decoding device, image encoding method, and image decoding method
JP5137532B2 (en) * 2007-11-16 2013-02-06 キヤノン株式会社 Image coding apparatus and image coding method
JP5227989B2 (en) * 2010-03-16 2013-07-03 日本放送協会 Encoding device, decoding device, and program
JP5872929B2 (en) * 2012-03-06 2016-03-01 Kddi株式会社 Moving picture encoding apparatus, moving picture decoding apparatus, moving picture encoding method, moving picture decoding method, and program
US20150016522A1 (en) * 2012-04-05 2015-01-15 Sony Corporation Image processing apparatus and image processing method
JP2014007643A (en) * 2012-06-26 2014-01-16 Mitsubishi Electric Corp Moving picture encoder, moving picture decoder, moving picture encoding method, and moving picture decoding method
JP2015167267A (en) * 2012-07-03 2015-09-24 シャープ株式会社 Image decoder and image encoder
US8811735B2 (en) * 2012-07-14 2014-08-19 Sigma Designs, Inc. System and method for scalar quantization error reduction

Also Published As

Publication number Publication date
JP2015177343A (en) 2015-10-05

Similar Documents

Publication Publication Date Title
JP6573689B2 (en) Image coding apparatus and image coding method
JP6835448B2 (en) A recording medium on which an image coding device, an image decoding device, an image coding method, an image decoding method, and a coded bit stream are recorded.
JP6863669B2 (en) Image coding device, image coding method, image decoding device and image decoding method
JP6082073B2 (en) Image decoding apparatus, image decoding method, image encoding apparatus, image encoding method, and bit stream
JP6147368B2 (en) Image encoding device, image decoding device, encoded stream conversion device, image encoding method, and image decoding method
JP2017077036A (en) Encoded data
JP2017017736A (en) Image decoding apparatus, image decoding method, image coding apparatus, image coding method, and data structure of coded data
WO2014163200A1 (en) Color image encoding apparatus, color image decoding apparatus, color image encoding method, and color image decoding method
WO2014049981A1 (en) Video encoding device, video decoding device, video encoding method and video decoding method
JP6373008B2 (en) Image encoding device, image decoding device, image encoding method, and image decoding method
JP6362370B2 (en) Image encoding device, image decoding device, image encoding method, and image decoding method
JP2014204311A (en) Color image encoding device, color image decoding device, color image encoding method and color image decoding method
JP2014090327A (en) Moving image encoder, moving image decoder, moving image encoding method and moving image decoding method
JP2014090326A (en) Moving image encoder, moving image decoder, moving image encoding method and moving image decoding method
WO2013108882A1 (en) Video encoding apparatus, video decoding apparatus, video encoding method, and video decoding method
JP2018166329A (en) Image encoder and image decoder
JP6555856B2 (en) Image encoding device, image decoding device, image encoding method, and image decoding method
WO2014049982A1 (en) Video encoding device, video decoding device, video encoding method and video decoding method
JP2015177295A (en) Terminal apparatus and data management apparatus
JP2016005210A (en) Terminal and data management device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20161114

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20170922

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20171003

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20171130

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20180220

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20180420

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: 20180529

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20180626

R150 Certificate of patent or registration of utility model

Ref document number: 6362370

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250