JP2008306413A - Image encoder, and image encoding method - Google Patents

Image encoder, and image encoding method Download PDF

Info

Publication number
JP2008306413A
JP2008306413A JP2007151014A JP2007151014A JP2008306413A JP 2008306413 A JP2008306413 A JP 2008306413A JP 2007151014 A JP2007151014 A JP 2007151014A JP 2007151014 A JP2007151014 A JP 2007151014A JP 2008306413 A JP2008306413 A JP 2008306413A
Authority
JP
Japan
Prior art keywords
block
intra prediction
prediction mode
blocks
intra
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.)
Pending
Application number
JP2007151014A
Other languages
Japanese (ja)
Inventor
Kazuhiro Wake
一博 和気
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.)
Panasonic Corp
Original Assignee
Panasonic 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 Panasonic Corp filed Critical Panasonic Corp
Priority to JP2007151014A priority Critical patent/JP2008306413A/en
Publication of JP2008306413A publication Critical patent/JP2008306413A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide an image encoder and an image encoding method capable of accelerating a processing speed by reducing an operation amount required for the selection of an intra-prediction mode, and also preventing the efficiency decline of intra-prediction. <P>SOLUTION: The image encoder includes: a block division part 501 for dividing an encoding object frame into a plurality of M×M (M is an integer expressed by power of 2) first blocks, calculating an evaluation value for deciding whether or not the boundary of the object of images is present within the block for the first blocks, recursively executing block division until the evaluation value of the block becomes equal to or smaller than a prescribed threshold or the size of the block becomes equal to the size of an intra-prediction block, and determining intra-prediction information indicating the candidate of the intra-prediction mode corresponding to division conditions for each intra-prediction block after the block division is completed; and an intra-prediction part 503 for executing an intra-prediction operation on the basis of the intra-prediction information and determining the optimum prediction mode. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、高能率符号化技術を用いた画像符号化装置および画像符号化方法に関するものである。より詳しくは、動画像のH.264符号化において、複数種類のイントラ予測モードの候補から、一つのイントラ予測モードを選択する画像符号化装置および画像符号化方法に関するものである。   The present invention relates to an image encoding device and an image encoding method using a high-efficiency encoding technique. More specifically, H.264 of moving images. The present invention relates to an image encoding apparatus and an image encoding method for selecting one intra prediction mode from a plurality of types of intra prediction mode candidates in H.264 encoding.

近年、AV情報のデジタル化が進み、映像信号をデジタル化して取り扱うことのできる機器が広く普及しつつある。映像信号は膨大な情報量を有するので、記録容量や伝送効率を考慮して情報量を削減しつつ符号化することが一般的である。映像信号の符号化技術として、H.264という国際規格が定められており、実験結果によると、H.264規格は他の既存の符号化技術に比べ、約2倍の圧縮効率をもたらす。従って、H.264規格は、レコーダ記録、インターネットストリーミング等に非常に適した符号化方式である。   In recent years, digitalization of AV information has progressed and devices capable of digitizing and handling video signals are becoming widespread. Since a video signal has an enormous amount of information, encoding is generally performed while reducing the amount of information in consideration of recording capacity and transmission efficiency. As a video signal encoding technique, H.264 is used. An international standard called H.264 has been established. The H.264 standard provides approximately twice the compression efficiency compared to other existing coding technologies. Therefore, H.I. The H.264 standard is an encoding method that is very suitable for recorder recording, Internet streaming, and the like.

H.264では、フレーム内での予測を行うイントラ予測が導入されている。イントラ予測方式のうち、4×4画素のブロック(以下、4×4ブロックという)のイントラ予測では、16×16画素のマクロブロック701を縦横それぞれに4分割して16個の4×4ブロック702に分割し、分割されたブロックごとにイントラ予測を行なう。図8は、マクロブロック内における各4×4ブロックの位置関係を示す図である。   H. In H.264, intra prediction for performing prediction within a frame is introduced. In the intra prediction method, in the intra prediction of a 4 × 4 pixel block (hereinafter referred to as 4 × 4 block), a 16 × 16 pixel macroblock 701 is divided into four in each of vertical and horizontal directions, and 16 4 × 4 blocks 702 are obtained. And intra prediction is performed for each of the divided blocks. FIG. 8 is a diagram showing the positional relationship of each 4 × 4 block in the macroblock.

図9は、4×4ブロックのイントラ予測符号化を説明するための図であり、(a)イントラ予測対象ブロックと周辺画素との位置関係を示す図、(b)〜(j)9つのイントラ予測モードを示す図である。図9(a)に示すように画素A、B、C、D、E、F、G、H、I、J、K、L、Xは符号化済みの周辺画素であり、イントラ予測対象ブロック801のイントラ予測を行う際に使用される。各4×4ブロックの候補となるイントラ予測モードには、予測方向に対応した9つの種類(モード)があり、この中からひとつのモードを選択して符号化を行う。   FIG. 9 is a diagram for describing intra prediction encoding of 4 × 4 blocks, (a) a diagram illustrating a positional relationship between an intra prediction target block and peripheral pixels, and (b) to (j) nine intras. It is a figure which shows prediction mode. As shown in FIG. 9A, pixels A, B, C, D, E, F, G, H, I, J, K, L, and X are encoded peripheral pixels, and are the intra prediction target block 801. Used when performing intra prediction. There are nine types (modes) corresponding to the prediction directions in the intra prediction modes that are candidates for each 4 × 4 block, and one mode is selected from these, and encoding is performed.

図9(b)に示すモード0は「垂直予測」と定義され、予測対象である4×4ブロックの上部に隣接する符号化済みブロックの画素A〜Dの輝度を、それぞれ垂直下方の画素の輝度から減算して、差分の絶対値を求め、輝度の絶対差分値和を算出する。すなわち、画素Aの下方にある4画素の輝度から画素Aの輝度をそれぞれ減算し、画素Bの下方にある4画素の輝度から画素Bの輝度をそれぞれ減算する。同様に、画素Cおよび画素Dの下方にある各4画素の輝度から、それぞれ画素Cおよび画素Dの輝度を減算する。このように減算結果として得られた輝度の絶対差分値和が、予測対象の4×4ブロックの予測モード0の予測誤差となる。   Mode 0 shown in FIG. 9B is defined as “vertical prediction”, and the luminance of the pixels A to D of the encoded block adjacent to the upper part of the 4 × 4 block to be predicted is set to the pixel of the lower vertical pixel. The absolute value of the difference is obtained by subtracting from the luminance, and the absolute difference sum of luminance is calculated. That is, the luminance of the pixel A is subtracted from the luminance of the four pixels below the pixel A, and the luminance of the pixel B is subtracted from the luminance of the four pixels below the pixel B. Similarly, the luminances of the pixels C and D are subtracted from the luminances of the four pixels below the pixels C and D, respectively. Thus, the sum of absolute difference values of luminance obtained as a subtraction result becomes a prediction error in the prediction mode 0 of the 4 × 4 block to be predicted.

次に、図9(c)に示すモード1は「水平予測」と定義され、予測対象ブロックの左部に隣接する符号化済みブロックの画素I〜Lの輝度を、それぞれ水平右方の画素の輝度から減算して、差分の絶対値を求め、輝度の絶対差分値和を算出する。この減算結果として得られた輝度の絶対差分値和が、予測対象ブロックの予測モード1の予測誤差となる。   Next, mode 1 shown in FIG. 9C is defined as “horizontal prediction”, and the luminance of the pixels I to L of the encoded block adjacent to the left part of the prediction target block is set to the horizontal right pixel. The absolute value of the difference is obtained by subtracting from the luminance, and the absolute difference sum of luminance is calculated. The sum of absolute difference values of luminance obtained as a result of this subtraction becomes a prediction error in prediction mode 1 of the prediction target block.

次に、図9(d)に示すモード2は「DC予測」と定義され、予測対象ブロックに隣接する符号化済みブロックの画素A〜Dと画素I〜Lの輝度の平均値を、予測対象ブロック内の各画素の輝度から減算して、差分の絶対値を求め、輝度の差分の絶対値和を算出する。この減算結果として得られた輝度の絶対差分値和が、予測対象ブロックの予測モード2の予測誤差となる。   Next, mode 2 shown in FIG. 9D is defined as “DC prediction”, and average values of luminance of pixels A to D and pixels I to L of the encoded block adjacent to the prediction target block are set as prediction targets. The absolute value of the difference is obtained by subtracting from the luminance of each pixel in the block, and the absolute value sum of the luminance difference is calculated. The sum of absolute difference values of luminance obtained as a result of this subtraction becomes a prediction error in prediction mode 2 of the prediction target block.

以降、図9(e)に示すモード3「対角左下予測」、図9(f)に示すモード4「対角右下予測」、図9(g)に示すモード5「垂直右予測」、図9(h)に示すモード6「水平下予測」、図9(i)に示すモード7「垂直左予測」、図9(j)に示すモード8「水平上予測」に対しても同様の処理を行い、各モードにおける予測誤差を算出する。予測誤差算出後、9つのモードの中で、最も予測誤差の小さいモードを、予測対象ブロックの最適予測モードに決定する。   Thereafter, mode 3 “diagonal lower left prediction” shown in FIG. 9 (e), mode 4 “diagonal lower right prediction” shown in FIG. 9 (f), mode 5 “vertical right prediction” shown in FIG. 9 (g), The same applies to mode 6 “horizontal prediction” shown in FIG. 9 (h), mode 7 “vertical left prediction” shown in FIG. 9 (i), and mode 8 “horizontal prediction” shown in FIG. 9 (j). Processing is performed to calculate a prediction error in each mode. After calculating the prediction error, the mode with the smallest prediction error among the nine modes is determined as the optimum prediction mode of the prediction target block.

イントラ予測後、予測対象ブロックと最適予測モードに従って形成された予測ブロックとの差分演算を行い、差分信号に対し、変換処理、量子化、及びエントロピー符号化を行い、圧縮ビットストリームを生成する。   After the intra prediction, a difference calculation between the prediction target block and the prediction block formed according to the optimal prediction mode is performed, and conversion processing, quantization, and entropy coding are performed on the difference signal to generate a compressed bitstream.

イントラ予測は、符号化の対象となるブロックの情報量を大きく低減することができ、圧縮性能を向上させることができる有効な方法である。   Intra prediction is an effective method that can greatly reduce the amount of information of a block to be encoded and can improve compression performance.

しかしながら、最適なイントラ予測モードを選択するためには、予測対象の4×4ブロック毎に9種類のイントラ予測モード毎の予測誤差を算出して比較する必要があり、膨大な演算量が必要で、符号化処理の速度向上が困難であった。そのため、イントラ予測に要する演算量を削減する方法が提案されている。   However, in order to select an optimal intra prediction mode, it is necessary to calculate and compare prediction errors for each of nine types of intra prediction modes for each 4 × 4 block to be predicted, which requires a large amount of calculation. It was difficult to improve the speed of the encoding process. Therefore, a method for reducing the amount of calculation required for intra prediction has been proposed.

このような方法として、イントラ予測を行うブロックを、強限定ブロック、弱限定ブロックと呼ばれる2つのグループに分類し、強限定ブロックの予測モード数をA、弱限定ブロックの予測モード数をBと表現するとき、1≦B<A≦9なる条件を設定することで、イントラ予測の候補数を削減する方法が提案されている(例えば、特許文献1参照。)。   As such a method, blocks that perform intra prediction are classified into two groups called strongly limited blocks and weakly limited blocks, and the number of prediction modes of strongly limited blocks is expressed as A, and the number of prediction modes of weakly limited blocks is expressed as B. Then, a method of reducing the number of intra prediction candidates by setting a condition of 1 ≦ B <A ≦ 9 has been proposed (see, for example, Patent Document 1).

また、イントラ予測対象ブロックを、最大9つの予測モードを用いて予測演算を行う予測誤差算出ブロックと、予測演算を行わない非予測誤差算出ブロックに分類し、イントラ予測部の演算負荷に応じて、予測誤差算出ブロックと非予測誤差算出ブロックの決定を行うことで、イントラ予測の候補数を削減する方法が提案されている(例えば、特許文献2参照。)。
特開2006−148419号公報 特開2006−246431号公報
Further, the intra prediction target blocks are classified into a prediction error calculation block that performs prediction calculation using a maximum of nine prediction modes and a non-prediction error calculation block that does not perform prediction calculation, and according to the calculation load of the intra prediction unit, A method of reducing the number of intra prediction candidates by determining a prediction error calculation block and a non-prediction error calculation block has been proposed (see, for example, Patent Document 2).
JP 2006-148419 A JP 2006-246431 A

しかしながら、特許文献1で提案された方法では、予測モードの数が変化する強限定ブロック、弱限定ブロックのパターンがあらかじめ決定されており、これらのパターン決定においては、画像の特徴をなんら考慮していない。また、特許文献2で提案された方法では、イントラ予測部の演算負荷に応じて予測モードの数を制限することを特徴としており、モード数の制限に画像の特徴をなんら考慮していない。   However, in the method proposed in Patent Document 1, patterns of strongly limited blocks and weakly limited blocks in which the number of prediction modes changes are determined in advance, and these pattern determinations take into account the characteristics of the image. Absent. In addition, the method proposed in Patent Document 2 is characterized in that the number of prediction modes is limited according to the calculation load of the intra prediction unit, and image characteristics are not considered at all in limiting the number of modes.

そのため、本来、最大9つの予測モード判定が必要なブロックに対しても、より少ない予測モードでの判定しか行わない状況が発生する。このため、適切なイントラ予測モードを選択することができず、イントラ予測の効率を大きく低下させることになる。   For this reason, a situation occurs in which only a determination in fewer prediction modes is performed even for blocks that originally require a maximum of nine prediction mode determinations. For this reason, an appropriate intra prediction mode cannot be selected, and the efficiency of intra prediction is greatly reduced.

イントラ予測において、予測ブロックが予測対象ブロックに似ていれば似ているほど得られる差分が小さくなるため、適切なイントラ予測モードを選択することが圧縮性能にとって重要である。その結果、圧縮する必要のある情報量が大きく低減され、圧縮性能を向上させることができる。   In intra prediction, the more similar a prediction block is to the prediction target block, the smaller the difference that is obtained, and therefore selecting an appropriate intra prediction mode is important for compression performance. As a result, the amount of information that needs to be compressed is greatly reduced, and the compression performance can be improved.

そこで、本発明は上記課題に鑑みてなされたものであり、イントラ予測モードの選択に必要な演算量を削減することで処理速度の向上を実現し、かつ、イントラ予測の効率低下を抑制することができる画像符号化装置および画像符号化方法を提供することを目的とする。   Therefore, the present invention has been made in view of the above problems, and realizes an improvement in processing speed by reducing the amount of calculation required for selecting an intra prediction mode and suppresses a decrease in efficiency of intra prediction. An object of the present invention is to provide an image encoding apparatus and an image encoding method capable of performing the above.

上記目的を達成するため、本発明に係る画像符号化装置は、画素間の予測方向に応じて異なる複数のイントラ予測モードの中から一つのイントラ予測モードを選択し、選択したイントラ予測モードを用いてフレーム内予測符号化を行う画像符号化装置であって、入力画像をM×M(Mは2のべき乗で表現される整数)画素から構成される第一ブロックに分割し、前記第一ブロックに対してブロック内に画像のオブジェクトの境界が存在するか否かを判定するための評価値を算出し、算出した前記評価値が所定の閾値より大きければ、前記第一ブロックを(M/2)×(M/2)画素から構成される4つの第二ブロックに分割し、さらに、前記第二ブロックに対して同ブロック内の前記評価値を算出し、算出した前記評価値が所定の閾値より大きければ、前記第二ブロックを(M/4)×(M/4)画素から構成される4つの第三ブロックに分割し、以下、再帰的に前記評価値の算出、所定の閾値との判定、およびブロック分割を繰り返し、ブロック内の前記評価値が所定の閾値以下、または、ブロックのサイズがイントラ予測モードを算出するブロックのサイズと等しくなった場合、ブロック分割を終了し、最終分割ブロックとするブロック分割手段と、前記最終分割ブロック内に複数のイントラ予測モード算出ブロックが含まれる場合、複数の前記イントラ予測モード算出ブロックの中で、前記最終分割ブロック内の左上隅に位置する前記イントラ予測モード算出ブロックに対しては、最大9つの予測モードを候補として用いてイントラ予測を行い、前記最終分割ブロック内の前記左上隅のイントラ予測モード算出ブロック以外のイントラ予測モード算出ブロックに対しては、最大8つの予測モードを候補として用いてイントラ予測を行うイントラ予測手段とを備えることを特徴とする。   In order to achieve the above object, the image coding apparatus according to the present invention selects one intra prediction mode from a plurality of different intra prediction modes depending on the prediction direction between pixels, and uses the selected intra prediction mode. An image encoding apparatus that performs intra-frame predictive encoding, and divides an input image into first blocks composed of M × M (M is an integer expressed by a power of 2) pixels, and the first block An evaluation value for determining whether or not an image object boundary exists in the block is calculated. If the calculated evaluation value is greater than a predetermined threshold, the first block is determined as (M / 2). ) × (M / 2) pixels are divided into four second blocks, the evaluation value in the second block is calculated for the second block, and the calculated evaluation value is a predetermined threshold value. Larger If so, the second block is divided into four third blocks composed of (M / 4) × (M / 4) pixels, and thereafter, the evaluation value is recursively calculated and determined as a predetermined threshold value. And the block division is repeated, and when the evaluation value in the block is equal to or smaller than a predetermined threshold value, or the block size becomes equal to the block size for calculating the intra prediction mode, the block division is finished, and the final divided block And the intra-prediction mode calculation block includes a plurality of intra-prediction mode calculation blocks, and the intra-prediction mode calculation block includes a plurality of intra-prediction mode calculation blocks. For the mode calculation block, intra prediction is performed using a maximum of nine prediction modes as candidates, and the mode in the final divided block is For intra prediction mode calculation block other than intra prediction mode calculating block corner, characterized in that it comprises the intra prediction means for performing intra prediction using up to eight prediction modes as candidates.

これによって、複数のイントラ予測モードの候補を制限し、候補の中から一つのイントラ予測モードを選択するのに必要な演算量を削減することでき、処理速度の向上を実現することができる。また、イントラ予測モードを選択するのに必要な演算量の削減に伴うイントラ予測の効率低下を抑制することができる。   Thereby, a plurality of intra prediction mode candidates can be limited, the amount of calculation required to select one intra prediction mode from the candidates can be reduced, and the processing speed can be improved. In addition, it is possible to suppress a decrease in the efficiency of intra prediction that accompanies a reduction in the amount of computation required to select an intra prediction mode.

ここで、前記イントラ予測手段は、前記最終分割ブロック内の前記左上隅のイントラ予測モード算出ブロック以外のイントラ予測モード算出ブロックに対しては、水平予測モード、垂直予測モード、およびDC予測モードの中で少なくとも1つの予測モードを候補として用いてイントラ予測を行ってもよい。   Here, the intra-prediction unit is configured to select an intra prediction mode calculation block other than the intra prediction mode calculation block at the upper left corner in the final divided block, among a horizontal prediction mode, a vertical prediction mode, and a DC prediction mode. The intra prediction may be performed using at least one prediction mode as a candidate.

また、前記イントラ予測手段は、前記最終分割ブロック内の前記左上隅のイントラ予測モード算出ブロック以外のイントラ予測モード算出ブロックに対しては、水平予測モードのみ、垂直予測モードのみ、または、水平予測および垂直予測モードの2モード、を候補として用いてイントラ予測を行ってもよい。   In addition, the intra prediction means, for the intra prediction mode calculation blocks other than the intra prediction mode calculation block in the upper left corner in the final divided block, only the horizontal prediction mode, only the vertical prediction mode, or horizontal prediction and Intra prediction may be performed using two modes of the vertical prediction mode as candidates.

これによって、さらに、複数のイントラ予測モードの候補を制限し、候補の中から一つのイントラ予測モードを選択するのに必要な演算量を削減することでき、処理速度の向上を実現することができる。また、イントラ予測モードを選択するのに必要な演算量の削減に伴うイントラ予測の効率低下を抑制することができる。   As a result, a plurality of intra prediction mode candidates can be limited, and the amount of calculation required to select one intra prediction mode from the candidates can be reduced, thereby improving the processing speed. . In addition, it is possible to suppress a decrease in the efficiency of intra prediction that accompanies a reduction in the amount of computation required to select an intra prediction mode.

また、前記ブロック分割手段は、前記評価値として、ブロック内に含まれる画素値のダイナミックレンジを算出してもよい。   The block dividing unit may calculate a dynamic range of pixel values included in the block as the evaluation value.

これによって、ブロック内に画像のオブジェクトの境界が存在するか否かを判定を容易に行うことができる。   As a result, it is possible to easily determine whether or not an image object boundary exists in the block.

なお、本発明は、このような画像符号化装置として実現することができるだけでなく、このような画像符号化装置が備える特徴的な手段をステップとする画像符号化方法として実現したり、それらのステップをコンピュータに実行させるプログラムとして実現したりすることもできる。そして、そのようなプログラムは、CD−ROM等の記録媒体やインターネット等の伝送媒体を介して配信することができるのは言うまでもない。   Note that the present invention can be realized not only as such an image encoding apparatus, but also as an image encoding method including steps characteristic of the image encoding apparatus, It can also be realized as a program for causing a computer to execute steps. Needless to say, such a program can be distributed via a recording medium such as a CD-ROM or a transmission medium such as the Internet.

以上の説明から明らかなように、本発明に係る画像符号化装置および画像符号化方法によれば、イントラ予測モードを用いた画像符号化にあたり、符号化対象ブロックのイントラ予測モードの選択にかかる処理演算量削減が可能であり、処理速度の向上が実現できる。また、イントラ予測モードを選択するのに必要な演算量の削減に伴うイントラ予測の効率低下を抑制することができる。   As is clear from the above description, according to the image coding apparatus and the image coding method according to the present invention, the processing related to the selection of the intra prediction mode of the block to be coded in image coding using the intra prediction mode. The amount of calculation can be reduced, and the processing speed can be improved. In addition, it is possible to suppress a decrease in the efficiency of intra prediction that accompanies a reduction in the amount of computation required to select an intra prediction mode.

以下、本発明の実施の形態について、図面を参照しながら説明する。
図1は、本発明の画像符号化装置の全体の構成を示すブロック図である。画像符号化装置は、本発明のイントラ予測を行う画像符号化装置であり、入力部500、ブロック分割部501、マクロブロック構成部502、イントラ予測部503、予測ブロック生成部504、周辺画素記憶部505、減算部506、直交変換部507、量子化部508、エントロピー符号化部509、逆量子化部510、逆変換部511、加算部512、および出力部513を備える。
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
FIG. 1 is a block diagram showing the overall configuration of an image encoding apparatus according to the present invention. The image encoding device is an image encoding device that performs intra prediction according to the present invention, and includes an input unit 500, a block division unit 501, a macroblock configuration unit 502, an intra prediction unit 503, a prediction block generation unit 504, and a neighboring pixel storage unit. 505, a subtraction unit 506, an orthogonal transformation unit 507, a quantization unit 508, an entropy coding unit 509, an inverse quantization unit 510, an inverse transformation unit 511, an addition unit 512, and an output unit 513.

入力部500より入力された入力画像信号は、ブロック分割部501およびマクロブロック構成部502に入力される。ブロック分割部501は、入力画像信号に対しブロック分割を行い、4×4画素から構成されるイントラ予測算出ブロック毎にイントラ予測情報を算出する。算出されたイントラ予測情報はイントラ予測部503に入力される。   The input image signal input from the input unit 500 is input to the block division unit 501 and the macroblock configuration unit 502. The block division unit 501 performs block division on the input image signal and calculates intra prediction information for each intra prediction calculation block including 4 × 4 pixels. The calculated intra prediction information is input to the intra prediction unit 503.

マクロブロック構成部502は、入力画像信号に対し、8×8画素から構成されるブロックに分割し、複数のブロックを集めてマクロブロックを構成する。マクロブロックはイントラ予測部503および減算部506に入力される。   The macro block configuration unit 502 divides an input image signal into blocks each composed of 8 × 8 pixels, and collects a plurality of blocks to configure a macro block. The macroblock is input to the intra prediction unit 503 and the subtraction unit 506.

イントラ予測部503は、入力されたマクロブロックに対し、マクロブロック内のイントラ予測ブロック毎に、イントラ予測情報と、周辺画素記憶部505より入力される周辺画素を用いてイントラ予測を行い、最適な予測モードを決定する。決定された最適予測モードは、予測ブロック生成部504に入力される。   The intra prediction unit 503 performs intra prediction on the input macroblock using the intra prediction information and the peripheral pixels input from the peripheral pixel storage unit 505 for each intra prediction block in the macroblock. Determine the prediction mode. The determined optimal prediction mode is input to the prediction block generation unit 504.

予測ブロック生成部504は、入力された最適予測モードと、周辺画素とを用いて予測ブロックを生成する。生成された予測ブロックは減算部506に入力される。   The prediction block generation unit 504 generates a prediction block using the input optimal prediction mode and surrounding pixels. The generated prediction block is input to the subtraction unit 506.

減算部506は、入力された予測ブロックとイントラ予測ブロックとの差分を取ることによって、予測残差信号を算出する。算出された予測残差信号は直交変換部507に入力される。   The subtraction unit 506 calculates a prediction residual signal by taking the difference between the input prediction block and the intra prediction block. The calculated prediction residual signal is input to the orthogonal transform unit 507.

直交変換部507は、入力された予測残差信号に対し周波数変換を行い、周波数変換係数を出力する。周波数変換係数は量子化部508に入力される。   The orthogonal transform unit 507 performs frequency transform on the input prediction residual signal and outputs a frequency transform coefficient. The frequency conversion coefficient is input to the quantization unit 508.

量子化部508は、入力された周波数変換係数に対して量子化処理を行い、量子化係数を出力する。量子化係数はエントロピー符号化部509、及び逆量子化部510に入力される。   The quantization unit 508 performs a quantization process on the input frequency conversion coefficient and outputs the quantization coefficient. The quantization coefficient is input to the entropy encoding unit 509 and the inverse quantization unit 510.

エントロピー符号化部509は、入力された量子化係数に対し可変長符号化を行い、ビットストリームを出力する。ビットストリームは出力部513に入力される。   The entropy encoding unit 509 performs variable length encoding on the input quantization coefficient and outputs a bit stream. The bit stream is input to the output unit 513.

出力部513は入力されたビットストリームを任意の媒体に出力する。
逆量子化部510は、入力された量子化係数に対し逆量子化を行い、逆量子化係数を出力する。逆量子化係数は逆変換部511に入力される。
The output unit 513 outputs the input bit stream to an arbitrary medium.
The inverse quantization unit 510 performs inverse quantization on the input quantization coefficient and outputs an inverse quantization coefficient. The inverse quantization coefficient is input to the inverse transform unit 511.

逆変換部511は、入力された逆量子化係数に対し逆周波数変換を行い、復号残差信号を出力する。復号残差信号は加算部512に入力される。   The inverse transform unit 511 performs inverse frequency transform on the input inverse quantization coefficient and outputs a decoded residual signal. The decoded residual signal is input to the adding unit 512.

加算部512は、入力された予測ブロックと復号残差信号との加算を取ることによって、復号画像信号を生成する。生成された復号画像信号は周辺画素記憶部505に入力される。   The adder 512 generates a decoded image signal by adding the input prediction block and the decoded residual signal. The generated decoded image signal is input to the peripheral pixel storage unit 505.

ここで、ブロック分割部501における、ブロック分割について、図2〜図6を用いて詳しく説明する。図2は入力画像全体およびM×M画素から構成される第一ブロックを示す図であり、図3はブロック分割処理の動作の流れを示すフローチャートであり、図4〜図6は第一ブロックに対してブロック分割を行う手順を示す図である。図2において、入力画像550はブロック分割処理を行う入力画像全体を示している。   Here, block division in the block division unit 501 will be described in detail with reference to FIGS. 2 is a diagram showing a first block composed of the entire input image and M × M pixels, FIG. 3 is a flowchart showing an operation flow of block division processing, and FIGS. 4 to 6 are diagrams showing the first block. It is a figure which shows the procedure which performs block division with respect to. In FIG. 2, an input image 550 shows the entire input image on which block division processing is performed.

ブロック分割部501は、ブロック分割においては、入力画像を予め設定される所定のM×M画素からなる第一ブロックに分割し(ステップS101)、第一ブロックに対してブロック分割処理を行う。本実施の形態では、第一ブロックのサイズを32×32(M=32)画素とし、図2に示す第一ブロック551に対してブロック分割を行ったときの処理について図4を用いて説明する。   In block division, the block division unit 501 divides an input image into first blocks each having predetermined M × M pixels set in advance (step S101), and performs block division processing on the first block. In the present embodiment, the processing when the size of the first block is 32 × 32 (M = 32) pixels and the first block 551 shown in FIG. 2 is divided into blocks will be described with reference to FIG. .

図4(a)は、分割前の第一ブロックを示している。まず、第一ブロックに対し、ブロック分割を行うか否かをブロック内に画像のオブジェクトの境界が存在するか否かに基づいて判定する。ブロック内に画像のオブジェクトの境界が存在する場合には、ブロック分割を行い、一方、ブロック内に画像のオブジェクトの境界が存在しない場合には、ブロック分割を行わないものとする。ここで、ブロック内に画像のオブジェクトの境界が存在するか否かの判断指標として評価値を定義する。本実施の形態では、評価値としてブロック内に含まれる画素値のダイナミックレンジを用いている。なお、ダイナミックレンジ以外にも、分散などを用いても構わない。また、ブロック内の画像からオブジェクトの境界を検出し、オブジェクトの境界が存在するか否か決定しても構わない。ブロック内の評価値が閾値より大きければ、そのブロックを分割し、閾値以下であればブロック分割は行わず、そのブロックの処理を終了する。本実施の形態では、閾値を32に設定する。   FIG. 4A shows the first block before division. First, it is determined whether or not to perform block division on the first block based on whether or not an object boundary of an image exists in the block. If there is an image object boundary in the block, block division is performed. On the other hand, if there is no image object boundary in the block, block division is not performed. Here, an evaluation value is defined as a determination index as to whether or not there is a boundary between image objects in the block. In the present embodiment, the dynamic range of the pixel values included in the block is used as the evaluation value. In addition to the dynamic range, dispersion or the like may be used. Further, the boundary of the object may be detected from the image in the block, and it may be determined whether or not the boundary of the object exists. If the evaluation value in the block is larger than the threshold value, the block is divided. If the evaluation value is equal to or less than the threshold value, the block division is not performed and the processing of the block is terminated. In the present embodiment, the threshold is set to 32.

すなわち、ブロック分割部501は、第一ブロックのダイナミックレンジを算出する(ステップS102)。次に、ブロック分割部501は、算出した第一ブロックのダイナミックレンジが閾値より大きいか否かを判定する(ステップS103)。判定の結果、第一ブロックのダイナミックレンジが閾値より大きい場合(ステップS103でYes)、第一ブロックを4つの第二ブロックに分割する(ステップS104)。一方、第一ブロックのダイナミックレンジが閾値以下の場合(ステップS103でNo)、第一ブロックの分割は行わず、その第一ブロックの処理を終了する。   That is, the block dividing unit 501 calculates the dynamic range of the first block (step S102). Next, the block dividing unit 501 determines whether or not the calculated dynamic range of the first block is larger than the threshold (step S103). As a result of the determination, if the dynamic range of the first block is larger than the threshold (Yes in step S103), the first block is divided into four second blocks (step S104). On the other hand, when the dynamic range of the first block is less than or equal to the threshold (No in step S103), the first block is not divided and the processing of the first block is terminated.

図4(a)に示す例では、第一ブロックはオブジェクト(木)と背景の境界を含んでおり、ダイナミックレンジが閾値より大きくなるので、図4(b)に示すように第一ブロックを4つの第二ブロックに分割する。ここで、第二ブロックは16×16画素から構成されるブロックであり、同図において、第一ブロック分割後の左上の第二ブロックを第二ブロック0、右上の第二ブロックを第二ブロック1、左下の第二ブロックを第二ブロック2、右下の第二ブロックを第二ブロック3と呼ぶ。   In the example shown in FIG. 4A, the first block includes the boundary between the object (tree) and the background, and the dynamic range becomes larger than the threshold value. Therefore, as shown in FIG. Divide into two second blocks. Here, the second block is a block composed of 16 × 16 pixels, and in the same figure, the second block at the upper left after the first block division is the second block 0, and the second block at the upper right is the second block 1. The second block at the lower left is called the second block 2, and the second block at the lower right is called the second block 3.

第一ブロックを4つの第二ブロックに分割した場合(ステップS104)には、ブロック分割部501は、対象とする第二ブロックを決定し(ステップS105)、この第二ブロックのダイナミックレンジを算出する(ステップS106)。次に、ブロック分割部501は、算出した第二ブロックのダイナミックレンジが閾値より大きいか否かを判定する(ステップS107)。判定の結果、第二ブロックのダイナミックレンジが閾値より大きい場合(ステップS107でYes)、第二ブロックを4つの第三ブロックに分割する(ステップS108)。   When the first block is divided into four second blocks (step S104), the block dividing unit 501 determines a target second block (step S105) and calculates the dynamic range of the second block. (Step S106). Next, the block dividing unit 501 determines whether or not the calculated dynamic range of the second block is larger than a threshold value (step S107). If the result of determination is that the dynamic range of the second block is greater than the threshold (Yes in step S107), the second block is divided into four third blocks (step S108).

一方、第二ブロックのダイナミックレンジが閾値以下の場合(ステップS107でNo)、第二ブロックの分割は行わず、その第二ブロックの処理を終了し、第二ブロックのすべてを対象として処理を行ったか否かを判定する(ステップS115)。判定の結果、第二ブロックのすべてを対象として処理を行った場合(ステップS115でYes)、その第一ブロックの処理を終了する。一方、第二ブロックのすべてを対象として処理を行っていない場合(ステップS115でNo)、対象とする第二ブロックを変更し(ステップS116)、第二ブロックのダイナミックレンジの算出処理(ステップS106)に戻る。   On the other hand, if the dynamic range of the second block is equal to or smaller than the threshold (No in step S107), the second block is not divided, the processing of the second block is terminated, and the processing is performed for all the second blocks. It is determined whether or not (step S115). As a result of the determination, when processing is performed for all of the second blocks (Yes in step S115), the processing of the first block is terminated. On the other hand, when the process is not performed on all of the second blocks (No in step S115), the target second block is changed (step S116), and the dynamic range calculation process of the second block (step S106). Return to.

図4(b)に示す例では、第二ブロック0は平坦領域であり、ダイナミックレンジが閾値以下である。そのため、第二ブロック0に対しては、これ以降のブロック分割は行わない。次に、第二ブロック1はオブジェクトと背景の境界を含んでおり、ダイナミックレンジが閾値より大きくなるので、図4(c)に示すように第二ブロック1を4つの第三ブロックに分割する。第三ブロックは8×8画素から構成されるブロックであり、同図において、第二ブロック1分割後の左上の第三ブロックを第三ブロック10、右上の第三ブロックを第三ブロック11、左下の第三ブロックを第三ブロック12、右下の第三ブロックを第三ブロック13と呼ぶ。   In the example shown in FIG. 4B, the second block 0 is a flat region, and the dynamic range is equal to or less than the threshold value. Therefore, subsequent block division is not performed for the second block 0. Next, since the second block 1 includes the boundary between the object and the background, and the dynamic range becomes larger than the threshold value, the second block 1 is divided into four third blocks as shown in FIG. The third block is composed of 8 × 8 pixels. In the figure, the third block 10 is the upper left third block after dividing the second block, the third block 11 is the upper right third block, and the lower left is the third block. The third block is called the third block 12, and the lower right third block is called the third block 13.

第二ブロックを4つの第三ブロックに分割した場合(ステップS108)には、ブロック分割部501は、対象とする第三ブロックを決定し(ステップS109)、この第三ブロックのダイナミックレンジを算出する(ステップS110)。次に、ブロック分割部501は、算出した第三ブロックのダイナミックレンジが閾値より大きいか否かを判定する(ステップS111)。判定の結果、第三ブロックのダイナミックレンジが閾値より大きい場合(ステップS111でYes)、第三ブロックを4つの第四ブロックに分割する(ステップS112)。本実施の形態では、第四ブロックは4×4画素から構成されるブロックであり、これはイントラ予測を行うブロックのサイズと一致する。そのため、第四ブロック以降はブロック内のダイナミックレンジに関わらず、ブロック分割を行わない。   When the second block is divided into four third blocks (step S108), the block dividing unit 501 determines a target third block (step S109) and calculates the dynamic range of the third block. (Step S110). Next, the block division unit 501 determines whether or not the calculated dynamic range of the third block is larger than the threshold (step S111). If the result of determination is that the dynamic range of the third block is greater than the threshold (Yes in step S111), the third block is divided into four fourth blocks (step S112). In the present embodiment, the fourth block is a block composed of 4 × 4 pixels, which matches the size of the block that performs intra prediction. Therefore, after the fourth block, block division is not performed regardless of the dynamic range in the block.

一方、第三ブロックのダイナミックレンジが閾値以下の場合(ステップS111でNo)、第三ブロックの分割は行わず、その第三ブロックの処理を終了し、第三ブロックのすべてを対象として処理を行ったか否かを判定する(ステップS114)。判定の結果、第三ブロックのすべてを対象として処理を行った場合(ステップS114でYes)、その第二ブロックの処理を終了し、第二ブロックのすべてを対象として処理を行ったか否かの判定処理(ステップS115)に戻る。一方、第三ブロックのすべてを対象として処理を行っていない場合(ステップS114でNo)、対象とする第三ブロックを変更し(ステップS113)、第三ブロックのダイナミックレンジの算出処理(ステップS110)に戻る。   On the other hand, when the dynamic range of the third block is equal to or less than the threshold (No in step S111), the third block is not divided, the processing of the third block is terminated, and the processing is performed for all the third blocks. It is determined whether or not (step S114). As a result of the determination, when processing is performed for all of the third blocks (Yes in step S114), determination of whether the processing of the second block is finished and processing is performed for all of the second blocks The process returns to the process (step S115). On the other hand, when the process is not performed on all the third blocks (No in step S114), the target third block is changed (step S113), and the dynamic range calculation process of the third block (step S110). Return to.

図4(c)に示す例では、第三ブロック10はオブジェクトと背景の境界を含んでおり、ダイナミックレンジが閾値より大きくなるので、図4(d)に示すように第三ブロック10を4つの第四ブロックに分割する。   In the example shown in FIG. 4C, the third block 10 includes the boundary between the object and the background, and the dynamic range becomes larger than the threshold value. Therefore, as shown in FIG. Divide into fourth blocks.

第四ブロックは4×4画素から構成されるブロックであり、同図において、第三ブロック10分割後の左上の第四ブロックを第四ブロック100、右上の第四ブロックを第四ブロック101、左下の第四ブロックを第四ブロック102、右下の第四ブロックを第四ブロック103と呼ぶ。   The fourth block is a block composed of 4 × 4 pixels. In the figure, the fourth block 100 is the upper left fourth block after dividing the third block 10, the fourth block 101 is the fourth block on the upper right, and the lower left is the fourth block 101. The fourth block is referred to as a fourth block 102, and the lower right fourth block is referred to as a fourth block 103.

また、第三ブロック11は平坦領域であり、ダイナミックレンジが閾値以下である。そのため、ブロック分割は行わない。   The third block 11 is a flat area, and the dynamic range is equal to or less than the threshold value. Therefore, block division is not performed.

続いて、第三ブロック12はオブジェクトと背景の境界を含んでおり、ダイナミックレンジが閾値より大きくなるので、図5(a)に示すように第三ブロック12を4つの第四ブロックに分割する。同図において、第三ブロック12分割後の左上の第四ブロックを第四ブロック120、右上の第四ブロックを第四ブロック121、左下の第四ブロックを第四ブロック122、右下の第四ブロックを第四ブロック123と呼ぶ。   Subsequently, since the third block 12 includes the boundary between the object and the background and the dynamic range becomes larger than the threshold value, the third block 12 is divided into four fourth blocks as shown in FIG. In the figure, the fourth block 120 is the fourth block at the upper left after the third block 12 is divided, the fourth block 121 is the fourth block at the upper right, the fourth block 122 is the fourth block at the lower left, and the fourth block at the lower right. Is referred to as a fourth block 123.

また、第三ブロック13は平坦領域であり、ダイナミックレンジが閾値以下である。そのため、ブロック分割は行わない。   The third block 13 is a flat area, and the dynamic range is equal to or less than the threshold value. Therefore, block division is not performed.

第四ブロック100、101、102、103、120、121、122、123は4×4画素から構成されるブロックであり、これはイントラ予測を行うブロックのサイズと一致する。そのため、第四ブロック以降はブロック内のダイナミックレンジに関わらず、ブロック分割を行わない。   The fourth blocks 100, 101, 102, 103, 120, 121, 122, and 123 are blocks composed of 4 × 4 pixels, which match the size of the block that performs intra prediction. Therefore, after the fourth block, block division is not performed regardless of the dynamic range in the block.

次に、図4(b)に示す例では、第二ブロック2は平坦領域であり、ダイナミックレンジが閾値以下である。そのため、ブロック分割は行わない。   Next, in the example illustrated in FIG. 4B, the second block 2 is a flat region, and the dynamic range is equal to or less than the threshold value. Therefore, block division is not performed.

続いて、第二ブロック3はオブジェクトと背景の境界を含んでおり、ダイナミックレンジが閾値より大きくなるので、図5(b)に示すように第二ブロック3を4つの第三ブロックに分割する。同図において、第二ブロック3分割後の左上の第三ブロックを第三ブロック30、右上の第三ブロックを第三ブロック31、左下の第三ブロックを第三ブロック32、右下の第三ブロックを第三ブロック33と呼ぶ。   Subsequently, since the second block 3 includes the boundary between the object and the background and the dynamic range becomes larger than the threshold value, the second block 3 is divided into four third blocks as shown in FIG. In the same figure, the upper left third block after dividing the second block into three blocks is the third block 30, the upper right third block is the third block 31, the lower left third block is the third block 32, and the lower right third block. Is called the third block 33.

ここで、第三ブロック30はオブジェクトと背景の境界を含んでおり、ダイナミックレンジが閾値より大きいので、図5(c)に示すように第三ブロック30を4つの第四ブロックに分割する。   Here, since the third block 30 includes the boundary between the object and the background and the dynamic range is larger than the threshold value, the third block 30 is divided into four fourth blocks as shown in FIG.

第四ブロックは4×4画素から構成されるブロックであり、同図において、第三ブロック30分割後の左上の第四ブロックを第四ブロック300、右上の第四ブロックを第四ブロック301、左下の第四ブロックを第四ブロック302、右下の第四ブロックを第四ブロック303と呼ぶ。   The fourth block is a block composed of 4 × 4 pixels. In the figure, the fourth block 300 is the upper left fourth block after the division of the third block 30, the fourth block 301 is the fourth block on the upper right, and the lower left is the fourth block 301. The fourth block is called a fourth block 302, and the lower right fourth block is called a fourth block 303.

また、第三ブロック31は平坦領域であり、ダイナミックレンジが閾値以下である。そのため、ブロック分割は行わない。   The third block 31 is a flat region, and the dynamic range is equal to or less than a threshold value. Therefore, block division is not performed.

続いて、第三ブロック32はオブジェクトと背景の境界を含んでおり、ダイナミックレンジが閾値より大きくなるので、図5(d)に示すように第三ブロック32を4つの第四ブロックに分割する。同図において、第三ブロック32分割後の左上の第四ブロックを第四ブロック320、右上の第四ブロックを第四ブロック321、左下の第四ブロックを第四ブロック322、右下の第四ブロックを第四ブロック323と呼ぶ。   Subsequently, since the third block 32 includes the boundary between the object and the background and the dynamic range becomes larger than the threshold value, the third block 32 is divided into four fourth blocks as shown in FIG. In the figure, the fourth block 320 is the fourth block at the upper left after the third block 32 is divided, the fourth block 321 is the fourth block at the upper right, the fourth block 322 is the fourth block at the lower left, and the fourth block at the lower right. Is called a fourth block 323.

また、第三ブロック33は平坦領域であり、ダイナミックレンジが閾値以下である。そのため、ブロック分割は行わない。   The third block 33 is a flat area, and the dynamic range is equal to or less than the threshold value. Therefore, block division is not performed.

第四ブロック300、301、302、303、320、321、322、323は、イントラ予測を行うブロックのサイズと一致する。そのため、第四ブロック以降はブロック内のダイナミックレンジに関わらず、ブロック分割を行わない。   The fourth blocks 300, 301, 302, 303, 320, 321, 322, and 323 match the size of the block for which intra prediction is performed. Therefore, after the fourth block, block division is not performed regardless of the dynamic range in the block.

以上で、図4(a)に示す例における全てのブロックに対する分割処理が終了したため、この第一ブロックに対するブロック分割処理を終了する。これは、図3に示すフローチャートにおける第二ブロックのすべてを対象として処理を行った場合(ステップS115でYes)に相当する。   Since the division process for all the blocks in the example shown in FIG. 4A is completed, the block division process for the first block is completed. This corresponds to the case where processing is performed on all the second blocks in the flowchart shown in FIG. 3 (Yes in step S115).

図6(a)は、図4(a)に示す例における第一ブロックの最終的に分割されたブロックを示す図である。同図に示すように、オブジェクトと背景との境界領域は小さなブロック、平坦領域は大きなブロックに分割されており、画像の特徴に応じたブロック分割が行われていることがわかる。   FIG. 6A is a diagram illustrating a finally divided block of the first block in the example illustrated in FIG. As shown in the figure, the boundary area between the object and the background is divided into small blocks, and the flat area is divided into large blocks, and it can be seen that block division according to image characteristics is performed.

次に、ブロック分割部501における、イントラ予測情報の決定について、図6(b)、図7(a)〜(c)を用いて詳しく説明する。イントラ予測は4×4画素から構成されるブロック単位で行う。図6(b)は、評価値を用いて分割したブロックを、さらにイントラ予測ブロック単位に分割したものである。図7は、ブロック分割を完了した第一ブロックについて説明するための図であり、(a)イントラ予測ブロック番号、(b)イントラ予測情報、(c)イントラ予測演算の回数を示す図である。   Next, determination of intra prediction information in the block dividing unit 501 will be described in detail with reference to FIGS. 6B and 7A to 7C. Intra prediction is performed in units of blocks composed of 4 × 4 pixels. FIG. 6B is a diagram in which the block divided using the evaluation value is further divided into intra prediction block units. FIG. 7 is a diagram for explaining the first block for which block division has been completed, and is a diagram illustrating (a) intra prediction block number, (b) intra prediction information, and (c) the number of intra prediction calculations.

各イントラ予測ブロック702は、図7(a)に示すように左上のブロックをイントラ予測ブロック0、イントラ予測ブロック0の右のブロックをイントラ予測ブロック1、イントラ予測ブロック1の右のブロックをイントラ予測ブロック2と呼ぶ。以下、図7(a)に示すように各イントラ予測ブロック3〜63を定義する。   As shown in FIG. 7A, each intra prediction block 702 has an intra prediction block 0 for the upper left block, an intra prediction block 1 for the right block of the intra prediction block 0, and an intra prediction for the right block of the intra prediction block 1. This is called block 2. Hereinafter, the intra prediction blocks 3 to 63 are defined as shown in FIG.

図6(b)と図7(a)とを対応付けると、第二ブロック0は、イントラ予測ブロック0〜3、8〜11、16〜19、24〜27の全16個のイントラ予測ブロックで構成されている。第二ブロック0はブロック内の評価値が閾値以下であったため、以降のブロック分割を終了したブロックである。これは、第二ブロック0はブロック内にオブジェクトの境界を含まない、すなわち同一のオブジェクトであることを示している。そのため、第二ブロック0に属する16個のイントラ予測ブロックは、予測モードの候補を制限することができる。   If FIG.6 (b) and FIG.7 (a) are matched, the 2nd block 0 will be comprised by all the 16 intra prediction blocks of intra prediction blocks 0-3, 8-11, 16-19, 24-27. Has been. The second block 0 is a block in which the subsequent block division is completed because the evaluation value in the block is equal to or less than the threshold value. This indicates that the second block 0 does not include an object boundary in the block, that is, is the same object. Therefore, the 16 intra prediction blocks belonging to the second block 0 can limit prediction mode candidates.

図6(b)、図7(a)を用いて、イントラ予測ブロック0〜3、8〜11、16〜19、24〜27の予測モードの候補の決定について説明する。   The determination of prediction mode candidates for intra prediction blocks 0 to 3, 8 to 11, 16 to 19, and 24 to 27 will be described with reference to FIGS. 6B and 7A.

左上に位置するイントラ予測ブロック0は、起点のブロックであるため、9つの予測モードを候補とする。   Since the intra prediction block 0 located in the upper left is a starting block, nine prediction modes are candidates.

イントラ予測ブロック1〜3は水平予測モードのみを候補とする。イントラ予測ブロック8、16,24は垂直予測モードのみを候補とする。それ以外のイントラ予測ブロック9〜11、17〜19、25〜27は水平予測モード、垂直予測モードの2つの予測モードを候補とする。なお、本実施の形態では、それ以外のイントラ予測ブロック9〜11、17〜19、25〜27について、水平予測モード、垂直予測モードの2つの予測モードを候補としているが、これに限られるものではない。例えば、水平予測モード、垂直予測モード、およびDC予測モードの3つの予測モードを候補としても構わない。さらに、その他の予測モードを含め8つ以下の予測モードを候補としても構わない。   Intra prediction blocks 1 to 3 use only the horizontal prediction mode as candidates. Intra prediction blocks 8, 16, and 24 use only the vertical prediction mode as candidates. The other intra prediction blocks 9 to 11, 17 to 19, and 25 to 27 have two prediction modes, a horizontal prediction mode and a vertical prediction mode, as candidates. In the present embodiment, the other prediction modes 9-11, 17-19, 25-27 are candidates for two prediction modes of the horizontal prediction mode and the vertical prediction mode. However, the present invention is not limited to this. is not. For example, three prediction modes of the horizontal prediction mode, the vertical prediction mode, and the DC prediction mode may be used as candidates. Furthermore, eight or less prediction modes including other prediction modes may be used as candidates.

ブロック分割部501は、イントラ予測ブロック毎に、イントラ予測の候補となる予測モードを示すイントラ予測情報を設定する。イントラ予測情報において、「0」は9つの予測モードがイントラ予測の候補であることを示す。「1」は垂直モードのみがイントラ予測の候補であることを示す。「2」は水平モードのみがイントラ予測の候補であることを示す。「3」は水平、垂直の2モードがイントラ予測の候補であることを示す。   The block division unit 501 sets intra prediction information indicating a prediction mode that is a candidate for intra prediction for each intra prediction block. In the intra prediction information, “0” indicates that nine prediction modes are candidates for intra prediction. “1” indicates that only the vertical mode is a candidate for intra prediction. “2” indicates that only the horizontal mode is a candidate for intra prediction. “3” indicates that the horizontal and vertical modes are candidates for intra prediction.

上述の第二ブロック0において、各イントラ予測ブロックのイントラ予測情報は、図7(b)に示すようにイントラ予測ブロック0は、9つの予測モードが候補であることを示す「0」、イントラ予測ブロック1〜3は水平モードのみが候補であることを示す「1」、イントラ予測ブロック8、16、24は垂直モードのみが候補であることを示す「2」、それ以外のイントラ予測ブロック9〜11、17〜19、25〜27は水平モード、垂直モードの2モードが候補であることを示す「3」が設定される。   In the second block 0 described above, the intra prediction information of each intra prediction block is “0” indicating that nine prediction modes are candidates as shown in FIG. Blocks 1 to 3 indicate “1” indicating that only the horizontal mode is a candidate, intra prediction blocks 8, 16 and 24 indicate “2” indicating that only the vertical mode is a candidate, and other intra prediction blocks 9 to 9 11, 17 to 19, and 25 to 27 are set to “3” indicating that two modes of the horizontal mode and the vertical mode are candidates.

第四ブロック100は、イントラ予測ブロック4のみにより構成されている。イントラ予測ブロック4のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 100 includes only the intra prediction block 4. In the intra prediction information of the intra prediction block 4, “0” indicating that nine prediction modes are candidates is set.

第四ブロック101は、イントラ予測ブロック5のみにより構成されている。イントラ予測ブロック5のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 101 includes only the intra prediction block 5. In the intra prediction information of the intra prediction block 5, “0” indicating that nine prediction modes are candidates is set.

第四ブロック102は、イントラ予測ブロック12のみにより構成されている。イントラ予測ブロック12のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 102 includes only the intra prediction block 12. In the intra prediction information of the intra prediction block 12, “0” indicating that nine prediction modes are candidates is set.

第四ブロック103は、イントラ予測ブロック13のみにより構成されている。イントラ予測ブロック13のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 103 includes only the intra prediction block 13. In the intra prediction information of the intra prediction block 13, “0” indicating that nine prediction modes are candidates is set.

第三ブロック11は、イントラ予測ブロック6、7、14、15の全4個のイントラ予測ブロックで構成されている。   The third block 11 is composed of a total of four intra prediction blocks, that is, intra prediction blocks 6, 7, 14, and 15.

第三ブロック11はブロック内の評価値が閾値以下であったため、以降のブロック分割を終了したブロックである。これは、第三ブロック11はブロック内にオブジェクトの境界を含まない、すなわち同一のオブジェクトであることを示している。そのため、第三ブロック11に属する4個のイントラ予測ブロックは、予測モードの候補を制限することができる。   The third block 11 is a block in which the subsequent block division is completed because the evaluation value in the block is equal to or less than the threshold value. This indicates that the third block 11 does not include an object boundary in the block, that is, is the same object. Therefore, the four intra prediction blocks belonging to the third block 11 can limit prediction mode candidates.

イントラ予測ブロック6は、起点のブロックであるため、9つの予測モードが候補であることを示す「0」、イントラ予測ブロック7は、水平モードのみが候補であることを示す「1」、イントラ予測ブロック14は、垂直モードのみが候補であることを示す「2」、イントラ予測ブロック15は、水平モード、垂直モードの2モードが候補であることを示す「3」が設定される。   Since the intra prediction block 6 is a starting block, “0” indicating that nine prediction modes are candidates, and the intra prediction block 7 is “1” indicating that only the horizontal mode is a candidate, and intra prediction. The block 14 is set to “2” indicating that only the vertical mode is a candidate, and the intra prediction block 15 is set to “3” indicating that two modes of the horizontal mode and the vertical mode are candidates.

第四ブロック120は、イントラ予測ブロック20のみにより構成されている。イントラ予測ブロック20のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 120 includes only the intra prediction block 20. In the intra prediction information of the intra prediction block 20, “0” indicating that nine prediction modes are candidates is set.

第四ブロック121は、イントラ予測ブロック21のみにより構成されている。イントラ予測ブロック21のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。
第四ブロック122は、イントラ予測ブロック28のみにより構成されている。イントラ予測ブロック28のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。
The fourth block 121 is configured only by the intra prediction block 21. In the intra prediction information of the intra prediction block 21, “0” indicating that nine prediction modes are candidates is set.
The fourth block 122 is configured only by the intra prediction block 28. In the intra prediction information of the intra prediction block 28, “0” indicating that nine prediction modes are candidates is set.

第四ブロック123は、イントラ予測ブロック29のみにより構成されている。イントラ予測ブロック29のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 123 includes only the intra prediction block 29. In the intra prediction information of the intra prediction block 29, “0” indicating that nine prediction modes are candidates is set.

第三ブロック13は、イントラ予測ブロック22、23、30、31の全4個のイントラ予測ブロックで構成されている。   The third block 13 is composed of a total of four intra prediction blocks 22, 23, 30, and 31.

第三ブロック13はブロック内の評価値が閾値以下であったため、以降のブロック分割を終了したブロックである。これは、第三ブロック13はブロック内にオブジェクトの境界を含まない、すなわち同一のオブジェクトであることを示している。そのため、第三ブロック13に属する4個のイントラ予測ブロックは、予測モードの候補を制限することができる。   The third block 13 is a block in which the subsequent block division is completed because the evaluation value in the block is equal to or less than the threshold value. This indicates that the third block 13 does not include an object boundary in the block, that is, is the same object. Therefore, the four intra prediction blocks belonging to the third block 13 can limit prediction mode candidates.

イントラ予測ブロック22は、起点のブロックであるため、9つの予測モードが候補であることを示す「0」、イントラ予測ブロック23は、水平モードのみが候補であることを示す「1」、イントラ予測ブロック30は、垂直モードのみが候補であることを示す「2」、イントラ予測ブロック31は、水平モード、垂直モードの2モードが候補であることを示す「3」が設定される。   Since the intra prediction block 22 is a starting block, “0” indicating that nine prediction modes are candidates, and the intra prediction block 23 is “1” indicating that only the horizontal mode is a candidate, and intra prediction. The block 30 is set to “2” indicating that only the vertical mode is a candidate, and the intra prediction block 31 is set to “3” indicating that two modes of the horizontal mode and the vertical mode are candidates.

第二ブロック2は、イントラ予測ブロック32〜35、40〜43、48〜51、56〜59の全16個のイントラ予測ブロックで構成されている。第二ブロック2はブロック内の評価値が閾値以下であったため、以降のブロック分割を終了したブロックである。これは、第二ブロック2はブロック内にオブジェクトの境界を含まない、すなわち同一のオブジェクトであることを示している。そのため、第二ブロック2に属する16個のイントラ予測ブロックは、予測モードの候補を制限することができる。   The second block 2 is composed of a total of 16 intra prediction blocks of intra prediction blocks 32 to 35, 40 to 43, 48 to 51, and 56 to 59. The second block 2 is a block in which the subsequent block division is completed because the evaluation value in the block is equal to or less than the threshold value. This indicates that the second block 2 does not include an object boundary in the block, that is, is the same object. Therefore, the 16 intra prediction blocks belonging to the second block 2 can limit prediction mode candidates.

上述の第二ブロック2において、各イントラ予測ブロックのイントラ予測情報は、イントラ予測ブロック32は、9つの予測モードが候補であることを示す「0」、イントラ予測ブロック33〜35は水平モードのみが候補であることを示す「1」、イントラ予測ブロック40、48、56は垂直モードのみが候補であることを示す「2」、それ以外のイントラ予測ブロック41〜43、49〜51、57〜59は水平モード、垂直モードの2モードが候補であることを示す「3」が設定される。   In the second block 2 described above, the intra prediction information of each intra prediction block is “0” indicating that the intra prediction block 32 is a candidate for nine prediction modes, and the intra prediction blocks 33 to 35 are only in the horizontal mode. “1” indicating that it is a candidate, “2” indicating that only the vertical mode is a candidate for the intra prediction blocks 40, 48, and 56, and other intra prediction blocks 41 to 43, 49 to 51, and 57 to 59. Is set to “3” indicating that two modes of the horizontal mode and the vertical mode are candidates.

第四ブロック300は、イントラ予測ブロック36のみにより構成されている。イントラ予測ブロック36のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 300 includes only the intra prediction block 36. In the intra prediction information of the intra prediction block 36, “0” indicating that nine prediction modes are candidates is set.

第四ブロック301は、イントラ予測ブロック37のみにより構成されている。イントラ予測ブロック37のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 301 is configured only by the intra prediction block 37. In the intra prediction information of the intra prediction block 37, “0” indicating that nine prediction modes are candidates is set.

第四ブロック302は、イントラ予測ブロック44のみにより構成されている。イントラ予測ブロック44のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 302 includes only the intra prediction block 44. In the intra prediction information of the intra prediction block 44, “0” indicating that nine prediction modes are candidates is set.

第四ブロック303は、イントラ予測ブロック45のみにより構成されている。イントラ予測ブロック45のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 303 is configured only by the intra prediction block 45. In the intra prediction information of the intra prediction block 45, “0” indicating that nine prediction modes are candidates is set.

第三ブロック31は、イントラ予測ブロック38、39、46、47の全4個のイントラ予測ブロックで構成されている。   The third block 31 is composed of a total of four intra prediction blocks, that is, intra prediction blocks 38, 39, 46, and 47.

第三ブロック31はブロック内の評価値が閾値以下であったため、以降のブロック分割を終了したブロックである。これは、第三ブロック31はブロック内にオブジェクトの境界を含まない、すなわち同一のオブジェクトであることを示している。そのため、第三ブロック31に属する4個のイントラ予測ブロックは、予測モードの候補を制限することができる。   The third block 31 is a block in which the subsequent block division is completed because the evaluation value in the block is equal to or less than the threshold value. This indicates that the third block 31 does not include an object boundary in the block, that is, is the same object. Therefore, the four intra prediction blocks belonging to the third block 31 can limit prediction mode candidates.

イントラ予測ブロック38は、起点のブロックであるため、9つの予測モードが候補であることを示す「0」、イントラ予測ブロック39は、水平モードのみが候補であることを示す「1」、イントラ予測ブロック46は、垂直モードのみが候補であることを示す「2」、イントラ予測ブロック47は、水平モード、垂直モードの2モードが候補であることを示す「3」が設定される。   Since the intra prediction block 38 is a starting block, “0” indicating that nine prediction modes are candidates, and the intra prediction block 39 is “1” indicating that only the horizontal mode is a candidate, and intra prediction. The block 46 is set to “2” indicating that only the vertical mode is a candidate, and the intra prediction block 47 is set to “3” indicating that the two modes of the horizontal mode and the vertical mode are candidates.

第四ブロック320は、イントラ予測ブロック52のみにより構成されている。イントラ予測ブロック52のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 320 includes only the intra prediction block 52. In the intra prediction information of the intra prediction block 52, “0” indicating that nine prediction modes are candidates is set.

第四ブロック321は、イントラ予測ブロック53のみにより構成されている。イントラ予測ブロック53のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 321 includes only the intra prediction block 53. In the intra prediction information of the intra prediction block 53, “0” indicating that nine prediction modes are candidates is set.

第四ブロック322は、イントラ予測ブロック60のみにより構成されている。イントラ予測ブロック60のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 322 includes only the intra prediction block 60. In the intra prediction information of the intra prediction block 60, “0” indicating that nine prediction modes are candidates is set.

第四ブロック323は、イントラ予測ブロック61のみにより構成されている。イントラ予測ブロック61のイントラ予測情報は、9つの予測モードが候補であることを示す「0」が設定される。   The fourth block 323 is configured only by the intra prediction block 61. In the intra prediction information of the intra prediction block 61, “0” indicating that nine prediction modes are candidates is set.

第三ブロック33は、イントラ予測ブロック54、55、62、63の全4個のイントラ予測ブロックで構成されている。   The third block 33 includes four intra prediction blocks, that is, intra prediction blocks 54, 55, 62, and 63.

第三ブロック33はブロック内の評価値が閾値以下であったため、以降のブロック分割を終了したブロックである。これは、第三ブロック33はブロック内にオブジェクトの境界を含まない、すなわち同一のオブジェクトであることを示している。そのため、第三ブロック33に属する4個のイントラ予測ブロックは、予測モードの候補を制限することができる。   The third block 33 is a block in which the subsequent block division is completed because the evaluation value in the block is equal to or less than the threshold value. This indicates that the third block 33 does not include an object boundary in the block, that is, is the same object. Therefore, the four intra prediction blocks belonging to the third block 33 can limit prediction mode candidates.

イントラ予測ブロック54は、起点のブロックであるため、9つの予測モードが候補であることを示す「0」、イントラ予測ブロック55は、水平モードのみが候補であることを示す「1」、イントラ予測ブロック62は、垂直モードのみが候補であることを示す「2」、イントラ予測ブロック63は、水平モード、垂直モードの2モードが候補であることを示す「3」が設定される。   Since the intra prediction block 54 is a starting block, “0” indicating that the nine prediction modes are candidates, and the intra prediction block 55 is “1” indicating that only the horizontal mode is a candidate, and intra prediction. The block 62 is set to “2” indicating that only the vertical mode is a candidate, and the intra prediction block 63 is set to “3” indicating that the two modes of the horizontal mode and the vertical mode are candidates.

イントラ予測部503は、イントラ予測ブロックに対し、該当するイントラ予測情報を用いてイントラ予測を行う。イントラ予測情報が「0」の場合、9つの予測モードを候補として用いてイントラ予測を行い、イントラ予測情報が「3」の場合、2つの予測モードを候補として用いてイントラ予測を行って、最適な予測モードを決定する。イントラ予測情報が「1」、または「2」の場合、予測モードの候補は1つしかないため、イントラ予測演算は行わない。   The intra prediction unit 503 performs intra prediction on the intra prediction block using the corresponding intra prediction information. When the intra prediction information is “0”, intra prediction is performed using nine prediction modes as candidates, and when the intra prediction information is “3”, intra prediction is performed using two prediction modes as candidates. The correct prediction mode. When the intra prediction information is “1” or “2”, since there is only one prediction mode candidate, the intra prediction calculation is not performed.

本実施の形態で示した第一ブロックに属する64個のイントラ予測ブロックに対し、必要なイントラ予測演算の回数は以下のようになる。   The required number of intra prediction calculations is as follows for the 64 intra prediction blocks belonging to the first block shown in the present embodiment.

図7(c)に示すように、第二ブロック0では(9+2×9)回、第四ブロック100では9回、第四ブロック101では9回、第四ブロック102では9回、第四ブロック103では9回、第三ブロック11では(9+2)回、第四ブロック120では9回、第四ブロック121では9回、第四ブロック122では9回、第四ブロック123では9回、第三ブロック13では(9+2)回、第二ブロック2では(9+2×9)回、第四ブロック300では9回、第四ブロック301では9回、第四ブロック302では9回、第四ブロック303では9回、第三ブロック31では(9+2)回、第四ブロック320では9回、第四ブロック321では9回、第四ブロック322では9回、第四ブロック323では9回、第三ブロック33では(9+2)回となり、合計で、242回の演算回数となる。従来方式では、各イントラ予測ブロックに対し9回のイントラ予測演算が必要なため、64×9=576回のイントラ予測演算が必要となる。本実施の形態のように、画像の特徴に応じたブロック分割を行い、イントラ予測の候補を制限することで、従来方式と比較して、約2倍以上の演算量の削減を実現することができる。   As shown in FIG. 7C, the second block 0 is (9 + 2 × 9) times, the fourth block 100 is 9 times, the fourth block 101 is 9 times, the fourth block 102 is 9 times, the fourth block 103 is In the third block 11 (9 + 2) times, in the fourth block 120 9 times, in the fourth block 121 9 times, in the fourth block 122 9 times, in the fourth block 123 9 times, in the third block 13 (9 + 2) times, second block 2 (9 + 2 × 9) times, fourth block 300 9 times, fourth block 301 9 times, fourth block 302 9 times, fourth block 303 9 times, The third block 31 is (9 + 2) times, the fourth block 320 is 9 times, the fourth block 321 is 9 times, the fourth block 322 is 9 times, the fourth block 323 is 9 times, and the third block 33 is ( 9 + 2) times, for a total of 242 calculations. In the conventional method, since 9 intra prediction calculations are required for each intra prediction block, 64 × 9 = 576 intra prediction calculations are required. As in the present embodiment, by performing block division according to image characteristics and limiting intra prediction candidates, it is possible to achieve a reduction in calculation amount of about twice or more compared to the conventional method. it can.

また、最適な予測モード決定において、当該イントラ予測ブロックに対し、候補となる全ての予測モード毎に予測ブロックを生成し、イントラ予測ブロックと予測ブロックとの誤差が最小となるモードを最適予測モードとする。このことから、従来方式では9つのモードが対象となるため、例えばノイズの影響等によって画像の特徴から考えて本来正しいモードが選択されない場合がある。これは誤差の算出が、イントラ予測ブロックと予測ブロックとの差分を元に行っているためである。   Further, in determining the optimal prediction mode, a prediction block is generated for each candidate prediction mode for the intra prediction block, and a mode in which an error between the intra prediction block and the prediction block is minimized is referred to as an optimal prediction mode. To do. For this reason, since nine modes are targeted in the conventional method, the correct mode may not be selected in view of the characteristics of the image due to the influence of noise, for example. This is because the error is calculated based on the difference between the intra prediction block and the prediction block.

これに対し、本実施の形態では、画像の特徴に応じたブロック分割を行い、画像の特徴から正しくないと考えられる予測モードは、候補からはずしている。そのため、従来方式よりも正しい予測モードを算出することができる。   On the other hand, in the present embodiment, block division is performed according to the feature of the image, and the prediction mode that is considered incorrect from the feature of the image is excluded from the candidates. Therefore, it is possible to calculate a prediction mode that is more correct than the conventional method.

なお、本実施の形態ではイントラ予測ブロックを4×4の場合のみについて説明したが、本発明はこれに限定されない。例えば8×8イントラ予測についても応用することができるし、さらには16×16イントラ予測にも応用することができる。   In addition, although this Embodiment demonstrated only the case where an intra prediction block was 4x4, this invention is not limited to this. For example, the present invention can be applied to 8 × 8 intra prediction, and further can be applied to 16 × 16 intra prediction.

本発明は、イントラ予測を用いた符号化方式において、選択可能なイントラ予測モードを選択する際の演算量を削減でき、画像符号化装置および画像符号化方法の処理速度向上に有効であり、例えばビデオレコーダ、ノンリニア編集機で動作するソフトエンコーダなどに有用である。   The present invention can reduce the amount of calculation when selecting a selectable intra prediction mode in an encoding method using intra prediction, and is effective in improving the processing speed of an image encoding device and an image encoding method. This is useful for video recorders and soft encoders that operate on non-linear editing machines.

本発明の画像符号化装置の全体の構成を示すブロック図である。It is a block diagram which shows the whole structure of the image coding apparatus of this invention. 本発明の実施の形態における、入力画像全体、及びM×M画素から構成される第一ブロックを示す図である。It is a figure which shows the 1st block comprised from the whole input image and MxM pixel in embodiment of this invention. 本発明の実施の形態のブロック分割部におけるブロック分割処理の動作の流れを示すフローチャートである。It is a flowchart which shows the flow of operation | movement of the block division process in the block division part of embodiment of this invention. 本発明の実施の形態のブロック分割部が、第一ブロックに対し、ブロック内の評価値に応じてブロック分割を行う手順を示す図であり、(a)分割前の第一ブロックを示す図、(b)第一ブロックに対する分割を示す図、(c)第二ブロック1に対する分割を示す図、(d)は第三ブロック10に対する分割を示す図である。The block division part of embodiment of this invention is a figure which shows the procedure which performs a block division according to the evaluation value in a block with respect to a 1st block, (a) The figure which shows the 1st block before a division | segmentation, (B) The figure which shows the division | segmentation with respect to a 1st block, (c) The figure which shows the division | segmentation with respect to the 2nd block 1, (d) is a figure which shows the division | segmentation with respect to the 3rd block 10. FIG. 本発明の実施の形態のブロック分割部が、第一ブロックに対し、ブロック内の評価値に応じてブロック分割を行う手順を示す図であり、(a)第三ブロック12に対する分割を示す図、(b)第二ブロック3に対する分割を示す図、(c)第三ブロック30に対する分割を示す図、(d)第三ブロック32に対する分割を示す図である。The block division part of embodiment of this invention is a figure which shows the procedure which performs block division according to the evaluation value in a block with respect to a 1st block, (a) The figure which shows the division | segmentation with respect to the 3rd block 12, (B) The figure which shows the division | segmentation with respect to the 2nd block 3, (c) The figure which shows the division | segmentation with respect to the 3rd block 30, (d) The figure which shows the division | segmentation with respect to the 3rd block 32. 本発明の実施の形態のブロック分割部が、第一ブロックに対し、ブロック内の評価値に応じてブロック分割を行う手順を示す図であり、(a)ブロック分割を完了した第一ブロックを示す図、(b)ブロック分割を完了した第一ブロック内のイントラ予測ブロックを示す図である。It is a figure which shows the procedure in which the block division part of embodiment of this invention performs block division with respect to a 1st block according to the evaluation value in a block, (a) shows the 1st block which completed block division FIG. 4B is a diagram showing an intra prediction block in the first block after completing the block division. 本発明の実施の形態における、ブロック分割を完了した第一ブロックについて説明するための図であり、(a)イントラ予測ブロック番号、(b)イントラ予測情報、(c)イントラ予測演算の回数を示す図である。It is a figure for demonstrating the 1st block which completed block division in embodiment of this invention, (a) Intra prediction block number, (b) Intra prediction information, (c) The frequency | count of intra prediction calculation are shown. FIG. マクロブロック内における各4×4ブロックの位置関係を示す図である。It is a figure which shows the positional relationship of each 4x4 block within a macroblock. 4×4ブロックのイントラ予測符号化を説明するための図であり、(a)イントラ予測対象ブロックと周辺画素との位置関係を示す図、(b)モード0「垂直予測モード」、(c)モード1「水平予測モード」、(d)モード2「DCモード」、(e)モード3「対角左下予測モード」、(f)モード4「対角右下予測モード」、(g)モード5「垂直右予測モード」、(h)モード6「水平下予測モード」、(i)モード7「垂直左予測モード」、(j)モード8「水平上予測モード」を示す図である。It is a figure for demonstrating intra prediction encoding of 4x4 block, (a) The figure which shows the positional relationship of an intra prediction object block and a surrounding pixel, (b) Mode 0 "vertical prediction mode", (c) Mode 1 “horizontal prediction mode”, (d) mode 2 “DC mode”, (e) mode 3 “diagonal lower left prediction mode”, (f) mode 4 “diagonal lower right prediction mode”, (g) mode 5 It is a figure which shows "vertical right prediction mode", (h) mode 6 "bottom horizontal prediction mode", (i) mode 7 "vertical left prediction mode", and (j) mode 8 "horizontal top prediction mode".

符号の説明Explanation of symbols

500 入力部
501 ブロック分割部
502 マクロブロック構成部
503 イントラ予測部
504 予測ブロック生成部
505 周辺画素記憶部
506 減算部
507 直交変換部
508 量子化部
509 エントロピー符号化部
510 逆量子化部
511 逆変換部
512 加算部
513 出力部
550 入力画像
551 第一ブロック
500 Input unit 501 Block division unit 502 Macroblock configuration unit 503 Intra prediction unit 504 Prediction block generation unit 505 Neighboring pixel storage unit 506 Subtraction unit 507 Orthogonal transformation unit 508 Quantization unit 509 Entropy coding unit 510 Inverse quantization unit 511 Inverse transformation Part 512 addition part 513 output part 550 input image 551 first block

Claims (6)

画素間の予測方向に応じて異なる複数のイントラ予測モードの中から一つのイントラ予測モードを選択し、選択したイントラ予測モードを用いてフレーム内予測符号化を行う画像符号化装置であって、
入力画像をM×M(Mは2のべき乗で表現される整数)画素から構成される第一ブロックに分割し、前記第一ブロックに対してブロック内に画像のオブジェクトの境界が存在するか否かを判定するための評価値を算出し、算出した前記評価値が所定の閾値より大きければ、前記第一ブロックを(M/2)×(M/2)画素から構成される4つの第二ブロックに分割し、さらに、前記第二ブロックに対して同ブロック内の前記評価値を算出し、算出した前記評価値が所定の閾値より大きければ、前記第二ブロックを(M/4)×(M/4)画素から構成される4つの第三ブロックに分割し、以下、再帰的に前記評価値の算出、所定の閾値との判定、およびブロック分割を繰り返し、ブロック内の前記評価値が所定の閾値以下、または、ブロックのサイズがイントラ予測モードを算出するブロックのサイズと等しくなった場合、ブロック分割を終了し、最終分割ブロックとするブロック分割手段と、
前記最終分割ブロック内に複数のイントラ予測モード算出ブロックが含まれる場合、複数の前記イントラ予測モード算出ブロックの中で、前記最終分割ブロック内の左上隅に位置する前記イントラ予測モード算出ブロックに対しては、最大9つの予測モードを候補として用いてイントラ予測を行い、前記最終分割ブロック内の前記左上隅のイントラ予測モード算出ブロック以外のイントラ予測モード算出ブロックに対しては、最大8つの予測モードを候補として用いてイントラ予測を行うイントラ予測手段と
を備えることを特徴とする画像符号化装置。
An image encoding device that selects one intra prediction mode from a plurality of different intra prediction modes depending on a prediction direction between pixels, and performs intra-frame prediction encoding using the selected intra prediction mode,
An input image is divided into first blocks each composed of M × M (M is an integer expressed by a power of 2) pixels, and whether or not an object boundary of the image exists in the block with respect to the first block. If an evaluation value for determining whether or not the calculated evaluation value is larger than a predetermined threshold value, the first block is made up of four second elements composed of (M / 2) × (M / 2) pixels. The block is divided into blocks, and the evaluation value in the second block is calculated. If the calculated evaluation value is greater than a predetermined threshold, the second block is (M / 4) × ( M / 4) is divided into four third blocks each composed of pixels, and thereafter the evaluation value is recursively calculated, determined to be a predetermined threshold, and block division is repeated, so that the evaluation value in the block is predetermined. Below the threshold of or the block If the size is equal to the size of the block of calculating the intra prediction mode, a block dividing means for terminating the block division, the final divided blocks,
When a plurality of intra prediction mode calculation blocks are included in the final division block, among the plurality of intra prediction mode calculation blocks, the intra prediction mode calculation block located at the upper left corner in the final division block Performs intra prediction using a maximum of nine prediction modes as candidates, and has a maximum of eight prediction modes for intra prediction mode calculation blocks other than the intra prediction mode calculation block in the upper left corner in the final divided block. An image encoding apparatus comprising: an intra prediction unit that performs intra prediction using the candidate.
前記イントラ予測手段は、前記最終分割ブロック内の前記左上隅のイントラ予測モード算出ブロック以外のイントラ予測モード算出ブロックに対しては、水平予測モード、垂直予測モード、およびDC予測モードの中で少なくとも1つの予測モードを候補として用いてイントラ予測を行う
ことを特徴とする請求項1記載の画像符号化装置。
The intra prediction means has at least one of a horizontal prediction mode, a vertical prediction mode, and a DC prediction mode for an intra prediction mode calculation block other than the intra prediction mode calculation block at the upper left corner in the final divided block. The image coding apparatus according to claim 1, wherein intra prediction is performed using two prediction modes as candidates.
前記イントラ予測手段は、前記最終分割ブロック内の前記左上隅のイントラ予測モード算出ブロック以外のイントラ予測モード算出ブロックに対しては、水平予測モードのみ、垂直予測モードのみ、または、水平予測および垂直予測モードの2モード、を候補として用いてイントラ予測を行う
ことを特徴とする請求項2記載の画像符号化装置。
For the intra prediction mode calculation blocks other than the intra prediction mode calculation block at the upper left corner in the final divided block, the intra prediction means is only a horizontal prediction mode, only a vertical prediction mode, or horizontal prediction and vertical prediction. The image coding apparatus according to claim 2, wherein intra prediction is performed using two modes of the mode as candidates.
前記ブロック分割手段は、前記評価値として、ブロック内に含まれる画素値のダイナミックレンジを算出する
ことを特徴とする請求項1記載の画像符号化装置。
The image coding apparatus according to claim 1, wherein the block dividing unit calculates a dynamic range of pixel values included in the block as the evaluation value.
画素間の予測方向に応じて異なる複数のイントラ予測モードの中から一つのイントラ予測モードを選択し、選択したイントラ予測モードを用いてフレーム内予測符号化を行う画像符号化方法であって、
入力画像をM×M(Mは2のべき乗で表現される整数)画素から構成される第一ブロックに分割し、前記第一ブロックに対してブロック内に画像のオブジェクトの境界が存在するか否かを判定するための評価値を算出し、算出した前記評価値が所定の閾値より大きければ、(M/2)×(M/2)画素から構成される4つの第二ブロックに分割し、さらに、前記第二ブロックに対して同ブロック内の前記評価値を算出し、算出した前記評価値が所定の閾値より大きければ(M/4)×(M/4)画素から構成される4つの第三ブロックに分割し、以下、再帰的に前記評価値の算出、所定の閾値との判定、およびブロック分割を繰り返し、ブロック内の前記評価値が所定の閾値以下、または、ブロックのサイズがイントラ予測モードを算出するブロックのサイズと等しくなった場合、ブロック分割を終了し、最終分割ブロックとするブロック分割ステップと、
前記最終分割ブロック内に複数のイントラ予測モード算出ブロックが含まれる場合、複数の前記イントラ予測モード算出ブロックの中で、前記最終分割ブロック内の左上隅に位置する前記イントラ予測モード算出ブロックに対しては、最大9つの予測モードを候補として用いてイントラ予測を行い、前記最終分割ブロック内の前記左上隅のイントラ予測モード算出ブロック以外のイントラ予測モード算出ブロックに対しては、最大8つの予測モードを候補として用いてイントラ予測を行うイントラ予測ステップと
を含むことを特徴とする画像符号化方法。
An image encoding method for selecting one intra prediction mode from a plurality of different intra prediction modes according to a prediction direction between pixels, and performing intra-frame prediction encoding using the selected intra prediction mode,
An input image is divided into first blocks each composed of M × M (M is an integer expressed by a power of 2) pixels, and whether or not an object boundary of the image exists in the block with respect to the first block. An evaluation value for determining whether or not the calculated evaluation value is larger than a predetermined threshold value, and divided into four second blocks composed of (M / 2) × (M / 2) pixels, Further, the evaluation value in the second block is calculated with respect to the second block, and if the calculated evaluation value is larger than a predetermined threshold, four (M / 4) × (M / 4) pixels are formed. The block is divided into third blocks, and thereafter, the evaluation value is recursively calculated, determined from a predetermined threshold value, and block division is repeated, and the evaluation value in the block is equal to or smaller than the predetermined threshold value, or the block size is intra. The block for calculating the prediction mode Tsu when it becomes equal to the click size, a block dividing step of terminating the block division, the final divided blocks,
When a plurality of intra prediction mode calculation blocks are included in the final division block, among the plurality of intra prediction mode calculation blocks, the intra prediction mode calculation block located at the upper left corner in the final division block Performs intra prediction using a maximum of nine prediction modes as candidates, and has a maximum of eight prediction modes for intra prediction mode calculation blocks other than the intra prediction mode calculation block in the upper left corner in the final divided block. And an intra prediction step for performing intra prediction using the candidate as a candidate.
画素間の予測方向に応じて異なる複数のイントラ予測モードの中から一つのイントラ予測モードを選択し、選択したイントラ予測モードを用いてフレーム内予測符号化を行うためのプログラムであって、
入力画像をM×M(Mは2のべき乗で表現される整数)画素から構成される第一ブロックに分割し、前記第一ブロックに対してブロック内に画像のオブジェクトの境界が存在するか否かを判定するための評価値を算出し、算出した前記評価値が所定の閾値より大きければ、(M/2)×(M/2)画素から構成される4つの第二ブロックに分割し、さらに、前記第二ブロックに対して同ブロック内の前記評価値を算出し、算出した前記評価値が所定の閾値より大きければ(M/4)×(M/4)画素から構成される4つの第三ブロックに分割し、以下、再帰的に前記評価値の算出、所定の閾値との判定、およびブロック分割を繰り返し、ブロック内の前記評価値が所定の閾値以下、または、ブロックのサイズがイントラ予測モードを算出するブロックのサイズと等しくなった場合、ブロック分割を終了し、最終分割ブロックとするブロック分割ステップと、
前記最終分割ブロック内に複数のイントラ予測モード算出ブロックが含まれる場合、複数の前記イントラ予測モード算出ブロックの中で、前記最終分割ブロック内の左上隅に位置する前記イントラ予測モード算出ブロックに対しては、最大9つの予測モードを候補として用いてイントラ予測を行い、前記最終分割ブロック内の前記左上隅のイントラ予測モード算出ブロック以外のイントラ予測モード算出ブロックに対しては、最大8つの予測モードを候補として用いてイントラ予測を行うイントラ予測ステップとをコンピュータに実行させる
ことを特徴とするプログラム。
A program for selecting one intra prediction mode from a plurality of different intra prediction modes depending on the prediction direction between pixels, and performing intra-frame prediction encoding using the selected intra prediction mode,
An input image is divided into first blocks each composed of M × M (M is an integer expressed by a power of 2) pixels, and whether or not an object boundary of the image exists in the block with respect to the first block. An evaluation value for determining whether or not the calculated evaluation value is larger than a predetermined threshold value, and divided into four second blocks composed of (M / 2) × (M / 2) pixels, Further, the evaluation value in the second block is calculated with respect to the second block, and if the calculated evaluation value is larger than a predetermined threshold, four (M / 4) × (M / 4) pixels are formed. The block is divided into third blocks, and thereafter, the evaluation value is recursively calculated, determined from a predetermined threshold value, and block division is repeated, and the evaluation value in the block is equal to or smaller than the predetermined threshold value, or the block size is intra. The block for calculating the prediction mode Tsu when it becomes equal to the click size, a block dividing step of terminating the block division, the final divided blocks,
When a plurality of intra prediction mode calculation blocks are included in the final division block, among the plurality of intra prediction mode calculation blocks, the intra prediction mode calculation block located at the upper left corner in the final division block Performs intra prediction using a maximum of nine prediction modes as candidates, and has a maximum of eight prediction modes for intra prediction mode calculation blocks other than the intra prediction mode calculation block in the upper left corner in the final divided block. A program that causes a computer to execute an intra prediction step of performing intra prediction using a candidate.
JP2007151014A 2007-06-06 2007-06-06 Image encoder, and image encoding method Pending JP2008306413A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007151014A JP2008306413A (en) 2007-06-06 2007-06-06 Image encoder, and image encoding method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007151014A JP2008306413A (en) 2007-06-06 2007-06-06 Image encoder, and image encoding method

Publications (1)

Publication Number Publication Date
JP2008306413A true JP2008306413A (en) 2008-12-18

Family

ID=40234749

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007151014A Pending JP2008306413A (en) 2007-06-06 2007-06-06 Image encoder, and image encoding method

Country Status (1)

Country Link
JP (1) JP2008306413A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8879632B2 (en) 2010-02-18 2014-11-04 Qualcomm Incorporated Fixed point implementation for geometric motion partitioning
JP2017103799A (en) * 2012-04-24 2017-06-08 リリカル ラブズ ビデオ コンプレッション テクノロジー、エルエルシー Video coding system and method of encoding video
US9723326B2 (en) 2014-03-20 2017-08-01 Panasonic Intellectual Property Management Co., Ltd. Image encoding method and image encoding appartaus
CN110213581A (en) * 2019-05-20 2019-09-06 广州市数字视频编解码技术国家工程实验室研究开发与产业化中心 A kind of coding method skipped based on block partition mode, device and storage medium
CN113545043A (en) * 2019-03-11 2021-10-22 Kddi 株式会社 Image decoding device, image decoding method, and program

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8879632B2 (en) 2010-02-18 2014-11-04 Qualcomm Incorporated Fixed point implementation for geometric motion partitioning
US9020030B2 (en) 2010-02-18 2015-04-28 Qualcomm Incorporated Smoothing overlapped regions resulting from geometric motion partitioning
US9654776B2 (en) 2010-02-18 2017-05-16 Qualcomm Incorporated Adaptive transform size selection for geometric motion partitioning
US10250908B2 (en) 2010-02-18 2019-04-02 Qualcomm Incorporated Adaptive transform size selection for geometric motion partitioning
JP2017103799A (en) * 2012-04-24 2017-06-08 リリカル ラブズ ビデオ コンプレッション テクノロジー、エルエルシー Video coding system and method of encoding video
US9723326B2 (en) 2014-03-20 2017-08-01 Panasonic Intellectual Property Management Co., Ltd. Image encoding method and image encoding appartaus
US10038901B2 (en) 2014-03-20 2018-07-31 Panasonic Intellectual Property Management Co., Ltd. Image encoding method and image encoding apparatus
CN113545043A (en) * 2019-03-11 2021-10-22 Kddi 株式会社 Image decoding device, image decoding method, and program
CN110213581A (en) * 2019-05-20 2019-09-06 广州市数字视频编解码技术国家工程实验室研究开发与产业化中心 A kind of coding method skipped based on block partition mode, device and storage medium
CN110213581B (en) * 2019-05-20 2023-03-07 广州市数字视频编解码技术国家工程实验室研究开发与产业化中心 Encoding method, device and storage medium based on block division mode skipping

Similar Documents

Publication Publication Date Title
US9706202B2 (en) Image encoding apparatus, image encoding method, image decoding apparatus, and image decoding method
JP2006246431A (en) Image coding apparatus and method
WO2014054267A1 (en) Image coding device and image coding method
JP5490404B2 (en) Image decoding device
US20150016521A1 (en) Video encoder for images
CN103299637A (en) Dynamic image encoding device, dynamic image decoding device, dynamic image encoding method, and dynamic image decoding method
JP4317814B2 (en) Encoding apparatus and encoding method for moving picture information
JP2005191706A (en) Moving picture coding method and apparatus adopting the same
KR20120006488A (en) Distortion weighing
US20120263237A1 (en) Video encoder and video decoder
US9106917B2 (en) Video encoding apparatus and video encoding method
JP2008306413A (en) Image encoder, and image encoding method
JP5178616B2 (en) Scene change detection device and video recording device
JP2010041191A (en) Image encoding method and image encoding device
JP4957780B2 (en) Motion compensated predictive coding apparatus, motion compensated predictive coding method, and program
JP2010278519A (en) Motion vector detector
JP5339300B2 (en) Image encoding method, image decoding method, image encoding device, image decoding device, and program
US20130322533A1 (en) Encoding device
KR101475286B1 (en) Method and apparatus for intra prediction, and apparatus for processing picture
JP2010010768A (en) Image encoding apparatus and image encoding method
JP2009027762A (en) Movement compensation image encoding device and encoding method
WO2023044916A1 (en) Intra prediction method, encoder, decoder, and encoding and decoding system
WO2023044918A1 (en) Intra prediction method, coder, decoder, and coding/decoding system
WO2023044917A1 (en) Intra prediction method, coder, decoder, and coding and decoding system
JP5637010B2 (en) Motion vector detection apparatus, motion vector detection method, and motion vector detection program