JP2010035025A - Encoding device and method therefor - Google Patents

Encoding device and method therefor Download PDF

Info

Publication number
JP2010035025A
JP2010035025A JP2008196845A JP2008196845A JP2010035025A JP 2010035025 A JP2010035025 A JP 2010035025A JP 2008196845 A JP2008196845 A JP 2008196845A JP 2008196845 A JP2008196845 A JP 2008196845A JP 2010035025 A JP2010035025 A JP 2010035025A
Authority
JP
Japan
Prior art keywords
prediction
target image
unit
encoding
image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
JP2008196845A
Other languages
Japanese (ja)
Inventor
Reiko Fujino
玲子 藤野
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2008196845A priority Critical patent/JP2010035025A/en
Publication of JP2010035025A publication Critical patent/JP2010035025A/en
Withdrawn legal-status Critical Current

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To perform encoding which achieves easy packaging and efficient in-frame prediction. <P>SOLUTION: A frame buffer 10 stores an image generated by performing local decoding on a predictively encoded image, and a reference prediction mode memory 102 stores information showing a used prediction mode. An SAD (Sum of Absolute Differences) calculation part 107 calculates SADs of prediction errors of an image to be predicted for respective prediction modes. On the basis of information on the prediction mode used for predictive encoding of an image adjacent to the image to be predicted, a syntax length calculation part 108 calculates a syntax length of the image to be predicted, and a probability calculation part 109 calculates the probability that the prediction mode is selected for the predictive encoding of the image to be predicted. An evaluated value calculation part 110 calculates evaluated values for the respective prediction modes from the SADs, syntax length, probability, and a quantization scale QP. A selection part 111 selects a prediction mode based upon the evaluated values. <P>COPYRIGHT: (C)2010,JPO&INPIT

Description

本発明は、フレーム内予測を行う動画像の符号化に関する。   The present invention relates to coding of a moving image for performing intra-frame prediction.

近年のディジタル信号処理技術の飛躍的な進歩により、従来困難であった記憶メディアへの動画像の記録や、伝送路を介した動画像の伝送が容易になった。このような記録や伝送を行う場合、動画像を構成するそれぞれのピクチャに圧縮符号化処理を施して、符号化ストリームのデータ量を大幅に削減する。動画像の圧縮符号化方式としてH.264/AVCが標準化されている。   Recent dramatic advances in digital signal processing technology have facilitated the recording of moving images to storage media and the transmission of moving images via transmission lines, which were difficult in the past. When such recording and transmission are performed, compression coding processing is performed on each picture constituting the moving image to greatly reduce the data amount of the coded stream. H.264 / AVC is standardized as a moving image compression encoding method.

H.264/AVCは、ピクチャを連続する、分割単位である複数のマクロブロック(MB)で区切ったスライスが符号化の基本単位である。一つのピクチャは、P (predictive)スライス、B (bi-predictive)スライス、I (intra)スライス、並びに、ストリーム切替用の特殊なP、IスライスであるSP、SIスライスの少なくとも一つから構成される。各スライスのMBは、フレーム内の画素および情報を用いて予測符号化するイントラ予測を用いた符号化モードと、フレーム間の画素および情報を用いて予測符号化するインタ予測がサポートされている。   In H.264 / AVC, a slice obtained by dividing a picture by a plurality of macroblocks (MB), which are division units, is a basic unit of encoding. One picture is composed of at least one of P (predictive) slice, B (bi-predictive) slice, I (intra) slice, and special P, I slice SP, SI slice for stream switching. The The MB of each slice supports an encoding mode using intra prediction in which prediction encoding is performed using pixels and information in a frame, and inter prediction in which prediction encoding is performed using pixels and information between frames.

H.264/AVCによれば、輝度情報のイントラ予測には4×4画素、8×8画素、および、16×16画素の予測単位があり、クロマ情報のイントラ予測には8×8画素の予測単位がある。4×4画素のイントラ予測モードを「イントラ4×4」、8×8画素のイントラ予測モードを「イントラ8×8」、16×16画素のイントラ予測モードを「イントラ16×16」、8×8画素のクロマ情報のイントラ予測モードを「イントラクロマ」と呼ぶ。イントラ4×4には九種類の予測モードと対応する九つの予測演算式、イントラ8×8には九種類の予測モードと対応する九つの予測演算式、イントラ16×16には四種類の予測モードと対応する四つの予測演算式がそれぞれ規定されている。また、イントラクロマには四種類の予測モードと対応する四つの予測値演算式が規定されている。   According to H.264 / AVC, there are 4 × 4 pixel, 8 × 8 pixel, and 16 × 16 pixel prediction units for intra prediction of luminance information, and 8 × 8 pixels for intra prediction of chroma information. There is a prediction unit. The intra prediction mode of 4 × 4 pixels is “Intra 4 × 4”, the intra prediction mode of 8 × 8 pixels is “Intra 8 × 8”, the intra prediction mode of 16 × 16 pixels is “Intra 16 × 16”, 8 × The intra prediction mode for chroma information of 8 pixels is called “intra chroma”. Nine prediction formulas corresponding to nine types of prediction modes for intra 4 × 4, nine prediction formulas corresponding to nine types of prediction modes for intra 8 × 8, and four types of prediction for intra 16 × 16 Four prediction formulas corresponding to the mode are defined respectively. In addition, four prediction value arithmetic expressions corresponding to four types of prediction modes are defined for the intra chroma.

予測対象画像に応じて、輝度情報のイントラ予測にイントラ4×4、イントラ8×8またはイントラ16×16を選択、言い換えれば予測単位(画像サイズ)を選択する。さらに、選択した画像サイズに対応する予測モードを一つ選択する。同様に、クロマ情報のイントラ予測に一つの予測モードを選択する。   Depending on the prediction target image, intra 4 × 4, intra 8 × 8 or intra 16 × 16 is selected for intra prediction of luminance information, in other words, a prediction unit (image size) is selected. Further, one prediction mode corresponding to the selected image size is selected. Similarly, one prediction mode is selected for intra prediction of chroma information.

輝度情報、クロマ情報の各イントラ予測モードの予測値演算式には、予測値演算式を示す番号が与えられている。これは、H.264の規格化段階において、発生頻度が高い順に番号を割り当てたものである。   A number indicating the prediction value calculation formula is given to the prediction value calculation formula in each intra prediction mode of luminance information and chroma information. In the standardization stage of H.264, numbers are assigned in descending order of occurrence frequency.

輝度情報のイントラ予測においてイントラ16×16が選択された場合の予測値演算式は、図7に示すように、5ビットのシンタックス(mb_type)で表現される。   The prediction value calculation formula when intra 16 × 16 is selected in the intra prediction of luminance information is represented by a 5-bit syntax (mb_type) as shown in FIG.

一方、輝度情報のイントラ予測においてイントラ4×4が選択された場合は、一つの4×4ブロックのシンタックスが1ビットまたは4ビットで表現され、1マクロブロック(MB)当たり16の画像についてそれぞれ設定される。   On the other hand, when intra 4 × 4 is selected in the intra prediction of luminance information, the syntax of one 4 × 4 block is expressed by 1 bit or 4 bits, and each of 16 images per 1 macroblock (MB) Is set.

イントラ4×4の予測値演算式のシンタックスは、上、または、左に隣接する符号化済み4×4ブロックにおいて選択した予測値演算式の番号のうち、小さい値と一致するか否かを1ビットで表現する。不一致の場合は、さらに3ビットで予測値演算式の番号を示す。その際、隣接する符号化済み4×4ブロックにおいて選択した最小の予測値演算式の番号より小さい場合は、選択した予測値演算式の番号で表現する。また、隣接する符号化済み4×4ブロックにおいて選択した最小の予測値演算式の番号より大きい場合は、選択した予測値演算式の番号から1を減算した番号で表現する。   The syntax of the intra 4 × 4 prediction value calculation formula indicates whether or not the prediction value calculation formula number selected in the encoded 4 × 4 block adjacent to the top or the left matches the smaller value. Expressed with 1 bit. In the case of mismatch, the number of the predicted value calculation expression is further indicated by 3 bits. At this time, if it is smaller than the number of the minimum predicted value calculation formula selected in the adjacent encoded 4 × 4 block, it is expressed by the number of the selected predicted value calculation formula. In addition, when it is larger than the number of the minimum predicted value calculation formula selected in the adjacent encoded 4 × 4 block, it is expressed by a number obtained by subtracting 1 from the number of the selected predicted value calculation formula.

しかし、H.264には、予測モードの決定方法が規格化されていない。そこで、H.264の基本ソフトウェアであるJM (Joint Model)には、選択方式として、差分絶対値和(SAD: sum of absolute differences)方式とRDO(rate distortion optimization)方式が実装されている。SAD方式は、JMの外部入力パラメータRDOptimization=‘0’のときに使用され、RDO方式は、RDOptimization=‘1’のときに使用される。   However, H.264 does not standardize the prediction mode determination method. Therefore, JM (Joint Model), which is the basic software of H.264, implements a sum of absolute differences (SAD) method and a rate distortion optimization (RDO) method as selection methods. The SAD method is used when the external input parameter RDOptimization = “0” of JM, and the RDO method is used when RDOptimization = “1”.

図1はSAD方式により予測モードを決定する構成を説明するブロック図である。   FIG. 1 is a block diagram illustrating a configuration for determining a prediction mode by the SAD method.

予測値算出部11〜13は、予め定められた予測モードにより、フレームバッファ10に格納された参照画像を参照して、予測単位の予測対象画像の予測値を算出する。なお、参照画像は符号化済みのフレーム画像をローカルデコードした復号画像(再構成画像)である。減算器14〜16は、予測単位の予測対象画像(入力画像)と予測値から予測誤差を算出し、予測誤差をメモリ17〜19に格納する。   The prediction value calculation units 11 to 13 calculate the prediction value of the prediction target image of the prediction unit with reference to the reference image stored in the frame buffer 10 in a predetermined prediction mode. The reference image is a decoded image (reconstructed image) obtained by locally decoding an encoded frame image. The subtractors 14 to 16 calculate a prediction error from the prediction target image (input image) of the prediction unit and the prediction value, and store the prediction error in the memories 17 to 19.

SAD算出部20〜22は、メモリ17〜19に格納された予測誤差のSADを評価値として計算する。ここまでの処理は、予測モードの数分、並列に行われ、予測モードの数分のSADが算出される。   The SAD calculation units 20 to 22 calculate the prediction error SAD stored in the memories 17 to 19 as an evaluation value. The processing so far is performed in parallel for the number of prediction modes, and SADs for the number of prediction modes are calculated.

選択部23は、算出されたSADの中で最小の値を示すSADに対応する予測モードを選択する。予測誤差選択部24は、選択部23が選択した予測モードに対応する予測誤差をメモリ17、18または19から読み出して出力する。   The selection unit 23 selects a prediction mode corresponding to the SAD indicating the minimum value among the calculated SADs. The prediction error selection unit 24 reads out the prediction error corresponding to the prediction mode selected by the selection unit 23 from the memory 17, 18 or 19, and outputs it.

つまり、SAD方式は、予測モードの数分のSADを計算し、SADに基づき、予測モードを決定する。なお、上述したように、イントラ4×4の予測モードは九種類、イントラ16×16の予測モードは四種類ある。言い換えれば、輝度情報を予測する場合、予測モードは13種類あることになる。図1は、説明を簡単にするために、予測モードが三種類の場合を示している。以下でも、予測モードが三種類の場合を説明する。   That is, in the SAD scheme, SADs corresponding to the number of prediction modes are calculated, and the prediction mode is determined based on the SAD. As described above, there are nine types of intra 4 × 4 prediction modes and four types of intra 16 × 16 prediction modes. In other words, when predicting luminance information, there are 13 types of prediction modes. FIG. 1 shows a case where there are three types of prediction modes for the sake of simplicity. Hereinafter, the case where there are three types of prediction modes will be described.

図2はRDO方式により予測モードを決定する構成を説明するブロック図である。なお、図1に示すSAD方式と略同様の構成には同一符号を付して、その詳細説明は省略する。   FIG. 2 is a block diagram illustrating a configuration for determining a prediction mode by the RDO method. Note that components substantially the same as those in the SAD scheme shown in FIG. 1 are denoted by the same reference numerals, and detailed description thereof is omitted.

評価値算出部25〜27は、メモリ17〜19に格納された予測誤差に基づき、式(1)を用いて評価値Jを算出する。
J = D + λ(QP)×R …(1)
ここで、Dは符号化歪、
Rは予測対象画像の符号長、
QPは量子化スケール、
λはQPをパラメータとするラグランジェ乗数。
The evaluation value calculation units 25 to 27 calculate the evaluation value J using Expression (1) based on the prediction errors stored in the memories 17 to 19.
J = D + λ (QP) × R (1)
Where D is the coding distortion,
R is the code length of the prediction target image,
QP is the quantization scale,
λ is a Lagrange multiplier with QP as a parameter.

なお、式(1)において、符号化歪Dは、予測対象画像を符号化した後にローカルデコードした復号画像と予測対象画像の差分二乗和として計算する。また、量子化スケールQPが大きくなると(高ビットレートでは)、ラグランジェ乗数λの値もべき乗で大きくなる。   In Equation (1), the encoding distortion D is calculated as the sum of squares of the difference between the decoded image that has been locally decoded after encoding the prediction target image and the prediction target image. As the quantization scale QP increases (at a high bit rate), the value of the Lagrange multiplier λ also increases with a power.

選択部23は、SAD方式と同様に、算出された評価値の中で最小の値を示す評価値に対応する予測モードを選択する。予測誤差選択部24は、選択部23が選択した予測モードに対応する予測誤差をメモリ17、18または19から読み出して出力する。   Similar to the SAD method, the selection unit 23 selects a prediction mode corresponding to the evaluation value indicating the minimum value among the calculated evaluation values. The prediction error selection unit 24 reads out the prediction error corresponding to the prediction mode selected by the selection unit 23 from the memory 17, 18 or 19, and outputs it.

RDO方式とSAD方式を比較すると、符号長Rと符号化歪Dから最適な予測モードを選択するRDO方式はより高い符号化効率を示す。しかし、式(1)に示すように、符号化歪Dと符号長Rの演算量が非常に多く、実装コストは非常に高い。一方、SAD方式は、実装の容易性が高いが、符号量を考慮しないためRDO方式に比べて5%以上、符号化効率が悪化する傾向がある。   Comparing the RDO scheme and the SAD scheme, the RDO scheme that selects the optimal prediction mode from the code length R and the coding distortion D shows higher coding efficiency. However, as shown in Expression (1), the amount of calculation of the coding distortion D and the code length R is very large, and the implementation cost is very high. On the other hand, the SAD method is easy to implement, but the coding efficiency tends to deteriorate by 5% or more compared to the RDO method because the code amount is not considered.

特開2003-299102公報JP 2003-299102 JP

本発明は、実装が容易で、効率的なフレーム内予測が可能な符号化を目的とする。   An object of the present invention is to provide an encoding that is easy to implement and enables efficient intra-frame prediction.

本発明は、前記の目的を達成する一手段として、以下の構成を備える。   The present invention has the following configuration as one means for achieving the above object.

本発明は、フレーム内予測を行う動画像の符号化方法であって、予測単位の予測対象画像に隣接する、符号化済みの前記予測単位の復号画像を参照して、予測モードそれぞれに対する前記予測対象画像の予測誤差を計算し、前記予測モードそれぞれに対する前記予測対象画像の予測誤差の絶対値和を算出し、前記予測対象画像に隣接する復号画像の符号化に使用した予測モードの情報に基づき、前記予測対象画像のシンタクス長を算出し、前記予測対象画像に隣接する復号画像の符号化に使用した予測モードの情報に基づき、前記予測対象画像の予測符号化に前記予測モードが選択される確率を算出し、前記絶対値和、前記シンタクス長、前記確率、および、前記予測対象画像に対応する量子化スケールから、前記予測モードそれぞれに対する評価値を算出し、前記予測モードそれぞれに対する評価値に基づき、前記予測モードを選択し、前記選択の結果に基づき、前記予測誤差を選択的に出力することを特徴とする。   The present invention is an encoding method of a moving image that performs intra-frame prediction, wherein the prediction for each prediction mode is performed with reference to the encoded decoded image of the prediction unit adjacent to the prediction target image of the prediction unit. Calculate the prediction error of the target image, calculate the absolute value sum of the prediction errors of the prediction target image for each of the prediction modes, and based on the prediction mode information used for encoding the decoded image adjacent to the prediction target image The syntax length of the prediction target image is calculated, and the prediction mode is selected for the prediction encoding of the prediction target image based on the prediction mode information used for encoding the decoded image adjacent to the prediction target image. Probability is calculated, and each of the prediction modes is calculated from the absolute value sum, the syntax length, the probability, and the quantization scale corresponding to the prediction target image. Calculating an evaluation value based on the evaluation value of the prediction mode, respectively, and selects the prediction mode, based on the result of the selection, and outputs the prediction error selectively.

本発明によれば、実装が容易で、効率的なフレーム内予測が可能な符号化が得られる。   According to the present invention, it is possible to obtain coding that is easy to implement and enables efficient intra-frame prediction.

以下、本発明にかかる実施例の動画像処理を図面を参照して詳細に説明する。   Hereinafter, the moving image processing of the embodiment according to the present invention will be described in detail with reference to the drawings.

[装置の構成]
図3は実施例の動画像符号化装置の基本的な構成例を示すブロック図である。なお、図1、2と略同様の構成には同一符号を付して、その詳細説明を省略する。
[Device configuration]
FIG. 3 is a block diagram illustrating a basic configuration example of the moving image encoding apparatus according to the embodiment. 1 and 2 are denoted by the same reference numerals, and detailed description thereof is omitted.

イントラ予測部31は、フレームバッファ10に格納されたローカルデコード画像を参照して、予測単位ごとに、予測対象画像のフレーム内予測を行い、予測対象画像の予測誤差を出力する。インタ予測部32は、ローカルデコードしたフレーム画像33を参照して、フレーム単位ごとに、予測対象画像のフレーム間予測を行い、予測対象画像の予測誤差を出力する。なお、参照するフレーム画像33はフレームバッファに格納されている。   The intra prediction unit 31 refers to the local decoded image stored in the frame buffer 10, performs intra-frame prediction of the prediction target image for each prediction unit, and outputs a prediction error of the prediction target image. The inter prediction unit 32 refers to the locally decoded frame image 33, performs inter-frame prediction of the prediction target image for each frame unit, and outputs a prediction error of the prediction target image. The frame image 33 to be referenced is stored in the frame buffer.

整数変換部34は、予測誤差を入力して整数変換を行い、変換係数を出力する。量子化部(Q)35は、変換係数を量子化する。エントロピ符号化部36は、量子化された変換係数をエントロピ符号化する。バッファ37は、エントロピ符号化部36が出力する符号をバッファして、符号ストリームとして装置外に出力する。   The integer conversion unit 34 receives the prediction error, performs integer conversion, and outputs a conversion coefficient. The quantization unit (Q) 35 quantizes the transform coefficient. The entropy encoding unit 36 entropy encodes the quantized transform coefficient. The buffer 37 buffers the code output from the entropy encoding unit 36 and outputs it as a code stream outside the apparatus.

逆量子化部(Q-1)38は、量子化された変換係数を逆量子化する。逆整数変換部39は、逆量子化された変換係数に逆整数変換を施す。再構成画素算出部40は、イントラ予測部31の予測値またはインタ予測部32の予測値と、逆整数変換によって復元された予測誤差を加算して復号画素を算出する。復号画素は、フレームバッファ10に格納され、参照画像として利用される。また、デブロッキングフィルタ41は、ブロックノイズを低減するフィルタである。 The inverse quantization unit (Q −1 ) 38 inversely quantizes the quantized transform coefficient. The inverse integer transform unit 39 performs inverse integer transform on the inversely quantized transform coefficient. The reconstructed pixel calculation unit 40 calculates the decoded pixel by adding the prediction value of the intra prediction unit 31 or the prediction value of the inter prediction unit 32 and the prediction error restored by inverse integer transformation. The decoded pixel is stored in the frame buffer 10 and used as a reference image. The deblocking filter 41 is a filter that reduces block noise.

[イントラ予測部]
図4はイントラ予測部31の一部の構成例を示すブロック図である。なお、図1〜3と略同様の構成には同一符号を付して、その詳細説明を省略する。また、後述するが、イントラ予測部31は、図4に示す構成をイントラ4×4、イントラ16×16、イントラクロマごとに備える。
[Intra prediction section]
FIG. 4 is a block diagram illustrating a configuration example of a part of the intra prediction unit 31. In addition, the same code | symbol is attached | subjected to the structure substantially the same as FIGS. 1-3, and the detailed description is abbreviate | omitted. As will be described later, the intra prediction unit 31 includes the configuration illustrated in FIG. 4 for each intra 4 × 4, intra 16 × 16, and intra chroma.

絶対値和算出部(SAD算出部)107a〜107cは、メモリ17〜19に格納された予測誤差のSADを計算する。なお、本実施例においては、メモリ17〜19を介さずに処理を行っても構わず、その場合、メモリ17〜19は不要である。   The absolute value sum calculation units (SAD calculation units) 107a to 107c calculate SADs of prediction errors stored in the memories 17 to 19. In the present embodiment, the processing may be performed without using the memories 17 to 19, and in this case, the memories 17 to 19 are unnecessary.

シンタクス長算出部108a〜108cは、参照予測モードメモリ102に格納された、予測対象画像に隣接する符号化済みの画像ブロックに適用した予測モードの情報から、予測モードの番号に対応するシンタクス長を算出する。   The syntax length calculation units 108a to 108c calculate the syntax length corresponding to the prediction mode number from the prediction mode information stored in the reference prediction mode memory 102 and applied to the encoded image block adjacent to the prediction target image. calculate.

確率算出部109a〜109cは、参照予測モードメモリ102に格納された、予測対象画像に隣接する符号化済みの画像ブロックに適用した予測モードの情報から、当該予測モードが選択される確率を算出する。   The probability calculation units 109a to 109c calculate the probability that the prediction mode is selected from the prediction mode information applied to the encoded image block adjacent to the prediction target image stored in the reference prediction mode memory 102. .

評価値算出部110a〜110cは、下式を用いて当該予測値演算式の評価値を算出する。
Cost = [{λ(QP)×SAD + 1} ≪ Rh] + Costth …(2)
ここで、SADは対応するSAD算出部から入力されるSAD、
Rhは対応するシンタクス長算出部から入力されるシンタクス長、
Costthは対応する確率算出部から入力される選択確率に応じたオフセット、
λ(QP)は量子化スケールQPをパラメータとするラグランジェ乗数。
The evaluation value calculation units 110a to 110c calculate the evaluation value of the prediction value calculation formula using the following formula.
Cost = [{λ (QP) × SAD + 1} ≪ Rh] + Cost th … (2)
Here, SAD is SAD input from the corresponding SAD calculation unit,
Rh is the syntax length input from the corresponding syntax length calculation unit,
Cost th is an offset according to the selection probability input from the corresponding probability calculation unit,
λ (QP) is a Lagrange multiplier with the quantization scale QP as a parameter.

なお、式(2)において「≪」はビットシフトを表し、「y ≪ x」はyをxビット左シフトする、言い換えればyを2x倍することを意味する。 In Expression (2), “<<” represents a bit shift, and “y << x” means that y is shifted left by x bits, in other words, y is multiplied by 2 × .

選択部111は、算出された評価値の中で最小の値を示す評価値に対応する予測モードを選択し、選択結果を示す情報(予測値演算式の番号)を参照予測モードメモリ102に格納する。また、評価値算出部110a〜110cが算出した評価値の和を出力する。予測誤差選択部24は、選択部111が選択した予測モードに対応する予測誤差をメモリ17、18または19から読み出して選択的に出力する。   The selection unit 111 selects a prediction mode corresponding to the evaluation value indicating the minimum value among the calculated evaluation values, and stores information indicating the selection result (number of the prediction value arithmetic expression) in the reference prediction mode memory 102. To do. Also, the sum of the evaluation values calculated by the evaluation value calculation units 110a to 110c is output. The prediction error selection unit 24 reads the prediction error corresponding to the prediction mode selected by the selection unit 111 from the memory 17, 18 or 19, and selectively outputs it.

図5はイントラ予測部31の構成例を示すブロック図である。   FIG. 5 is a block diagram illustrating a configuration example of the intra prediction unit 31.

選択部124は、イントラ4×4予測部121から出力される評価値和を16の画像ブロック分入力し、イントラ16×16予測部122から出力される評価値和を一つの画像ブロック(MB)分入力する。そして、16画像ブロック分の評価値和の合計ΣA(総和)と、1MB分の評価値和Aを比較する。そして、ΣA>Aならばイントラ16×16予測部122が出力する予測誤差を、ΣA≦Aならばイントラ4×4予測部121が出力する予測誤差を選択するように、予測誤差選択部125を制御する。つまり、16×16画素ブロック単位に輝度情報の予測単位が選択される。   The selection unit 124 inputs the evaluation value sum output from the intra 4 × 4 prediction unit 121 for 16 image blocks, and the evaluation value sum output from the intra 16 × 16 prediction unit 122 as one image block (MB). Enter minutes. Then, the sum ΣA (sum) of the evaluation value sums for 16 image blocks is compared with the evaluation value sum A for 1 MB. Then, if ΣA> A, the prediction error selection unit 125 is selected so that the prediction error output by the intra 16 × 16 prediction unit 122 is selected, and if ΣA ≦ A, the prediction error output by the intra 4 × 4 prediction unit 121 is selected. Control. That is, a prediction unit for luminance information is selected in units of 16 × 16 pixel blocks.

そして、予測誤差選択部125は、輝度情報の予測誤差を出力する。また、イントラクロマ予測部123は、クロマ情報の予測誤差を出力する。   Then, the prediction error selection unit 125 outputs a prediction error of luminance information. Further, the intra chroma prediction unit 123 outputs a prediction error of chroma information.

以下、本発明にかかる実施例2の動画像処理を説明する。なお、実施例2において、実施例1と略同様の構成については、同一符号を付して、その詳細説明を省略する。   The moving image processing according to the second embodiment of the present invention will be described below. Note that the same reference numerals in the second embodiment denote the same parts as in the first embodiment, and a detailed description thereof will be omitted.

図6は実施例2のイントラ予測部31の一部の構成例を示すブロック図である。なお、図1〜4と略同様の構成には同一符号を付して、その詳細説明を省略する。また、イントラ予測部31は、図6に示す構成をイントラ4×4、イントラ16×16、イントラクロマごとに備える。   FIG. 6 is a block diagram illustrating a partial configuration example of the intra prediction unit 31 according to the second embodiment. In addition, the same code | symbol is attached | subjected to the structure substantially the same as FIGS. 1-4, and the detailed description is abbreviate | omitted. Further, the intra prediction unit 31 has the configuration shown in FIG. 6 for each intra 4 × 4, intra 16 × 16, and intra chroma.

符号長算出部112a〜112cは、対応するSAD算出部107a〜107cが算出したSADに基づき、SADをインデックスとする符号長テーブルから符号長Recs[SAD]を導出する。 Based on the SAD calculated by the corresponding SAD calculation units 107a to 107c, the code length calculation units 112a to 112c derive the code length R ecs [SAD] from the code length table using the SAD as an index.

評価値算出部110a〜110cは、下式を用いて当該予測値演算式の評価値を算出する。
Cost = λ(QP)×Recs[SAD] + Rh + Costth …(3)
ここで、Recs[SAD]は対応する符号長算出部から入力される符号長、
Rhは対応するシンタクス長算出部から入力されるシンタクス長、
Costthは対応する確率算出部から入力される選択確率に応じたオフセット、
λ(QP)は量子化スケールQPをパラメータとするラグランジェ乗数。
The evaluation value calculation units 110a to 110c calculate the evaluation value of the prediction value calculation formula using the following formula.
Cost = λ (QP) × R ecs [SAD] + Rh + Cost th … (3)
Here, R ecs [SAD] is the code length input from the corresponding code length calculation unit,
Rh is the syntax length input from the corresponding syntax length calculation unit,
Cost th is an offset according to the selection probability input from the corresponding probability calculation unit,
λ (QP) is a Lagrange multiplier with the quantization scale QP as a parameter.

なお、イントラ予測部31全体の構成は、図5に示した実施例1の構成と同様である。   Note that the overall configuration of the intra prediction unit 31 is the same as the configuration of the first embodiment illustrated in FIG.

実施例1、2に示すイントラ予測部31の構成によれば、H.264に準拠するイントラ予測において、イントラ4×4は隣接する符号化済みの画像ブロックと同一の予測値演算式(予測方向)の選択率を上げて符号量を削減する。また、量子化スケールQPが大きいときはイントラ16×16の選択率を上げて、画質を劣化させることなく符号量を削減することができる。言い換えれば、画像全体の特徴を捉えて、高い符号化効率でイントラ予測符号化を行うことができる。   According to the configuration of the intra prediction unit 31 shown in the first and second embodiments, in intra prediction compliant with H.264, intra 4 × 4 is the same prediction value calculation formula (prediction direction) as the adjacent encoded image block. ) To reduce the code amount. Also, when the quantization scale QP is large, the intra 16 × 16 selection rate can be increased to reduce the code amount without degrading the image quality. In other words, it is possible to capture intra-image characteristics and perform intra prediction encoding with high encoding efficiency.

本実施例では、説明を簡単にするため、輝度のイントラ予測にイントラ4×4とイントラ16×16のみを用いて説明したが、イントラ4×4とイントラ16×16のほかにイントラ8×8を用いても構わない。また、予測単位はマクロブロックを均等に分割することができるサイズであればよく、4×4画素、8×8画素、16×16画素に限らない。   In this embodiment, in order to simplify the description, the intra 4 × 4 and the intra 16 × 16 are used for the luminance intra prediction. However, in addition to the intra 4 × 4 and the intra 16 × 16, the intra 8 × 8 is used. May be used. The prediction unit is not limited to 4 × 4 pixels, 8 × 8 pixels, and 16 × 16 pixels, as long as the size can divide the macroblock equally.

[他の実施例]
なお、本発明は、複数の機器(例えばコンピュータ、インタフェイス機器、リーダ、プリンタなど)から構成されるシステムに適用しても、一つの機器からなる装置(例えば、複写機、ファクシミリ装置、制御装置など)に適用してもよい。
[Other embodiments]
Note that the present invention can be applied to a system constituted by a plurality of devices (for example, a computer, an interface device, a reader, a printer, etc.), but an apparatus (for example, a copier, a facsimile machine, a control device) composed of a single device. Etc.).

また、本発明の目的は、上記実施例の機能を実現するコンピュータプログラムを記録した記録媒体または記憶媒体をシステムまたは装置に供給する。そして、そのシステムまたは装置のコンピュータ(CPUやMPU)が前記コンピュータプログラムを実行することでも達成される。この場合、記録媒体から読み出されたソフトウェア自体が上記実施例の機能を実現することになり、そのコンピュータプログラムと、そのコンピュータプログラムを記憶する、コンピュータが読み取り可能な記録媒体は本発明を構成する。   Another object of the present invention is to supply a recording medium or a recording medium recording a computer program for realizing the functions of the above embodiments to a system or apparatus. This can also be achieved by the computer (CPU or MPU) of the system or apparatus executing the computer program. In this case, the software read from the recording medium itself realizes the functions of the above embodiments, and the computer program and the computer-readable recording medium storing the computer program constitute the present invention. .

また、前記コンピュータプログラムの実行により上記機能が実現されるだけではない。つまり、そのコンピュータプログラムの指示により、コンピュータ上で稼働するオペレーティングシステム(OS)および/または第一の、第二の、第三の、…プログラムなどが実際の処理の一部または全部を行い、それによって上記機能が実現される場合も含む。   Further, the above functions are not only realized by the execution of the computer program. That is, according to the instruction of the computer program, the operating system (OS) and / or the first, second, third,... This includes the case where the above function is realized.

また、前記コンピュータプログラムがコンピュータに接続された機能拡張カードやユニットなどのデバイスのメモリに書き込まれていてもよい。つまり、そのコンピュータプログラムの指示により、第一の、第二の、第三の、…デバイスのCPUなどが実際の処理の一部または全部を行い、それによって上記機能が実現される場合も含む。   The computer program may be written in a memory of a device such as a function expansion card or unit connected to the computer. That is, it includes the case where the CPU of the first, second, third,... Device performs part or all of the actual processing according to the instructions of the computer program, thereby realizing the above functions.

本発明を前記記録媒体に適用する場合、その記録媒体には、先に説明したフローチャートに対応または関連するコンピュータプログラムが格納される。   When the present invention is applied to the recording medium, the recording medium stores a computer program corresponding to or related to the flowchart described above.

SAD方式により予測モードを決定する構成を説明するブロック図、A block diagram for explaining a configuration for determining a prediction mode by the SAD method, RDO方式により予測モードを決定する構成を説明するブロック図、Block diagram for explaining the configuration for determining the prediction mode by the RDO method, 実施例の動画像符号化装置の基本的な構成例を示すブロック図、A block diagram showing a basic configuration example of a moving image encoding device of an embodiment, イントラ予測部の一部の構成例を示すブロック図、A block diagram showing a configuration example of a part of the intra prediction unit, イントラ予測部の構成例を示すブロック図、A block diagram showing a configuration example of an intra prediction unit, 実施例2のイントラ予測部の一部の構成例を示すブロック図、Block diagram showing a configuration example of a part of the intra prediction unit of the second embodiment, イントラ16×16が選択された場合の予測値演算式シンタックスを示す図である。It is a figure which shows the predicted value calculation type | formula syntax when intra 16x16 is selected.

Claims (8)

フレーム内予測を行う動画像の符号化装置であって、
予測単位の予測対象画像に隣接する、符号化済みの前記予測単位の復号画像を参照して、予測モードそれぞれに対する前記予測対象画像の予測誤差を計算する計算手段と、
前記予測モードそれぞれに対する前記予測対象画像の予測誤差の絶対値和を算出する絶対値和算出手段と、
前記予測対象画像に隣接する復号画像の符号化に使用した予測モードの情報に基づき、前記予測対象画像のシンタクス長を算出するシンタクス長算出手段と、
前記予測対象画像に隣接する復号画像の符号化に使用した予測モードの情報に基づき、前記予測対象画像の予測符号化に前記予測モードが選択される確率を算出する確率算出手段と、
前記絶対値和、前記シンタクス長、前記確率、および、前記予測対象画像に対応する量子化スケールから、前記予測モードそれぞれに対する評価値を算出する評価値算出手段と、
前記予測モードそれぞれに対する評価値に基づき、前記予測モードを選択する選択手段と、
前記選択の結果に基づき、前記予測誤差を選択的に出力する出力手段とを有することを特徴とする符号化装置。
A video encoding device that performs intra-frame prediction,
A calculation unit that calculates a prediction error of the prediction target image for each prediction mode with reference to the encoded decoded image of the prediction unit adjacent to the prediction target image of the prediction unit;
Absolute value sum calculating means for calculating an absolute value sum of prediction errors of the prediction target image for each of the prediction modes;
Syntax length calculation means for calculating a syntax length of the prediction target image based on information on a prediction mode used for encoding a decoded image adjacent to the prediction target image;
Probability calculating means for calculating a probability that the prediction mode is selected for predictive encoding of the prediction target image based on information on a prediction mode used for encoding a decoded image adjacent to the prediction target image;
Evaluation value calculating means for calculating an evaluation value for each of the prediction modes from the absolute value sum, the syntax length, the probability, and a quantization scale corresponding to the prediction target image;
Selection means for selecting the prediction mode based on the evaluation value for each of the prediction modes;
And an output unit that selectively outputs the prediction error based on the selection result.
前記選択手段は、最小の評価値に対応する前記予測モードを選択することを特徴とする請求項1に記載された符号化装置。   2. The encoding apparatus according to claim 1, wherein the selection unit selects the prediction mode corresponding to a minimum evaluation value. さらに、前記予測モードそれぞれに対する前記絶対値和から、前記予測モードそれぞれに対する符号長を算出する符号長算出手段を有し、
前記評価値算出手段は、前記絶対値和の代わりに、前記符号長を使用することを特徴とする請求項1または請求項2に記載された符号化装置。
Furthermore, from the absolute value sum for each of the prediction modes, the code length calculation means for calculating the code length for each of the prediction modes,
3. The encoding apparatus according to claim 1, wherein the evaluation value calculation unit uses the code length instead of the absolute value sum.
さらに、前記符号長は、テーブルを参照して前記絶対値和から算出することを特徴とする請求項3に記載された符号化装置。   4. The encoding apparatus according to claim 3, wherein the code length is calculated from the sum of absolute values with reference to a table. さらに、前記予測単位のサイズごとに前記評価値の和を計算する計算手段と、
前記計算手段より各予測単位ごとに算出された評価値の総和を比較し、前記予測対象画像の前記予測単位を決定する決定手段を有することを特徴とする請求項1から請求項3の何れか一項に記載された符号化装置。
And calculating means for calculating the sum of the evaluation values for each size of the prediction unit;
4. The method according to claim 1, further comprising a determination unit that compares the sum of evaluation values calculated for each prediction unit by the calculation unit and determines the prediction unit of the prediction target image. The encoding device according to one item.
フレーム内予測を行う動画像の符号化方法であって、
予測単位の予測対象画像に隣接する、符号化済みの前記予測単位の復号画像を参照して、予測モードそれぞれに対する前記予測対象画像の予測誤差を計算し、
前記予測モードそれぞれに対する前記予測対象画像の予測誤差の絶対値和を算出し、
前記予測対象画像に隣接する復号画像の符号化に使用した予測モードの情報に基づき、前記予測対象画像のシンタクス長を算出し、
前記予測対象画像に隣接する復号画像の符号化に使用した予測モードの情報に基づき、前記予測対象画像の予測符号化に前記予測モードが選択される確率を算出し、
前記絶対値和、前記シンタクス長、前記確率、および、前記予測対象画像に対応する量子化スケールから、前記予測モードそれぞれに対する評価値を算出し、
前記予測モードそれぞれに対する評価値に基づき、前記予測モードを選択し、
前記選択の結果に基づき、前記予測誤差を選択的に出力することを特徴とする符号化方法。
A video encoding method for performing intra-frame prediction,
With reference to the encoded decoded image of the prediction unit adjacent to the prediction target image of the prediction unit, the prediction error of the prediction target image for each prediction mode is calculated,
Calculating an absolute value sum of prediction errors of the prediction target image for each of the prediction modes;
Based on the prediction mode information used for encoding the decoded image adjacent to the prediction target image, the syntax length of the prediction target image is calculated,
Based on the prediction mode information used for encoding the decoded image adjacent to the prediction target image, calculating the probability that the prediction mode is selected for prediction encoding of the prediction target image,
From the absolute value sum, the syntax length, the probability, and a quantization scale corresponding to the prediction target image, an evaluation value for each of the prediction modes is calculated,
Based on the evaluation value for each of the prediction modes, select the prediction mode,
An encoding method, wherein the prediction error is selectively output based on the selection result.
コンピュータ装置を制御して、請求項1から請求項5の何れか一項に記載された符号化装置の各手段として機能させることを特徴とするプログラム。   6. A non-transitory computer-readable storage medium storing a program for controlling a computer device to function as each unit of the encoding device according to claim 1. 請求項7に記載されたプログラムが記録されたことを特徴とするコンピュータが読み取り可能な記録媒体。   8. A computer-readable recording medium on which the program according to claim 7 is recorded.
JP2008196845A 2008-07-30 2008-07-30 Encoding device and method therefor Withdrawn JP2010035025A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2008196845A JP2010035025A (en) 2008-07-30 2008-07-30 Encoding device and method therefor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2008196845A JP2010035025A (en) 2008-07-30 2008-07-30 Encoding device and method therefor

Publications (1)

Publication Number Publication Date
JP2010035025A true JP2010035025A (en) 2010-02-12

Family

ID=41738968

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2008196845A Withdrawn JP2010035025A (en) 2008-07-30 2008-07-30 Encoding device and method therefor

Country Status (1)

Country Link
JP (1) JP2010035025A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130343453A1 (en) * 2011-03-10 2013-12-26 Nippon Telegraph And Telephone Corporation Quantization control apparatus and method, and quantization control program
US9641850B2 (en) 2013-05-13 2017-05-02 Kabushiki Kaisha Toshiba Video compression device
CN107371036A (en) * 2011-03-09 2017-11-21 佳能株式会社 Image encoding apparatus and method and image decoding apparatus and method

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107371036A (en) * 2011-03-09 2017-11-21 佳能株式会社 Image encoding apparatus and method and image decoding apparatus and method
US10554995B2 (en) 2011-03-09 2020-02-04 Canon Kabushiki Kaisha Image coding apparatus, method for coding image, program therefor, image decoding apparatus, method for decoding image, and program therefor
US10567785B2 (en) 2011-03-09 2020-02-18 Canon Kabushiki Kaisha Image coding apparatus, method for coding image, program therefor, image decoding apparatus, method for decoding image, and program therefor
CN107371036B (en) * 2011-03-09 2020-03-10 佳能株式会社 Image encoding apparatus and method, and image decoding apparatus and method
US20130343453A1 (en) * 2011-03-10 2013-12-26 Nippon Telegraph And Telephone Corporation Quantization control apparatus and method, and quantization control program
RU2573279C2 (en) * 2011-03-10 2016-01-20 Ниппон Телеграф Энд Телефон Корпорейшн Quantisation control device and method and quantisation control programme
US9906803B2 (en) 2011-03-10 2018-02-27 Nippon Telegraph And Telephone Corporation Quantization control apparatus and method, and quantization control program
US9641850B2 (en) 2013-05-13 2017-05-02 Kabushiki Kaisha Toshiba Video compression device

Similar Documents

Publication Publication Date Title
RU2722536C1 (en) Output of reference mode values and encoding and decoding of information representing prediction modes
JP6615290B2 (en) Video encoding method, video decoding method, video encoder, and video decoder
JP6074082B2 (en) Video decoding method in intra prediction mode
KR100813963B1 (en) Method and apparatus for loseless encoding and decoding image
US8432964B2 (en) Image processing device, method, and program
US8780994B2 (en) Apparatus, method, and computer program for image encoding with intra-mode prediction
US20120027092A1 (en) Image processing device, system and method
JP2007329693A (en) Image encoding device and method
JP2009094828A (en) Device and method for encoding image, and device and method for decoding image
JP2010251952A (en) Image encoder and method of encoding image, and computer program
KR20100027384A (en) Method and apparatus for determining a prediction mode
KR20050074286A (en) Image encoding device, image encoding method and image encoding program
RU2734616C1 (en) Prediction video decoding method and prediction video decoding device
JP2007013298A (en) Image coding apparatus
JP2010081498A (en) Image compression coding method and apparatus
JP2010035025A (en) Encoding device and method therefor
JP4357560B2 (en) Moving picture coding apparatus, moving picture coding method, and moving picture coding program
JP4708821B2 (en) Moving picture coding apparatus, control method therefor, computer program, and storage medium
JP2009049969A (en) Device and method of coding moving image and device and method of decoding moving image
JPWO2017082304A1 (en) Information compression apparatus, information compression method, information compression program, and encoding apparatus
JP5844969B2 (en) Image decoding module, image encoding device, image decoding device, image decoding method, and program
JP3976975B2 (en) Image processing apparatus and method, and storage medium
JP6646125B2 (en) Video prediction decoding method and video prediction decoding device
JP2008153802A (en) Moving picture encoding device and moving picture encoding program
KR100657274B1 (en) Intra prediction method and video processing apparatus thereof

Legal Events

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

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20111004