JP4485494B2 - Image decoding method and image decoding apparatus - Google Patents

Image decoding method and image decoding apparatus Download PDF

Info

Publication number
JP4485494B2
JP4485494B2 JP2006188423A JP2006188423A JP4485494B2 JP 4485494 B2 JP4485494 B2 JP 4485494B2 JP 2006188423 A JP2006188423 A JP 2006188423A JP 2006188423 A JP2006188423 A JP 2006188423A JP 4485494 B2 JP4485494 B2 JP 4485494B2
Authority
JP
Japan
Prior art keywords
picture
linear prediction
image
reference index
prediction
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.)
Expired - Lifetime
Application number
JP2006188423A
Other languages
Japanese (ja)
Other versions
JP2006325238A (en
Inventor
清史 安倍
眞也 角野
敏志 近藤
誠 羽飼
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Panasonic Corp
Panasonic Holdings Corp
Original Assignee
Panasonic Corp
Matsushita Electric Industrial Co Ltd
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, Matsushita Electric Industrial Co Ltd filed Critical Panasonic Corp
Priority to JP2006188423A priority Critical patent/JP4485494B2/en
Publication of JP2006325238A publication Critical patent/JP2006325238A/en
Application granted granted Critical
Publication of JP4485494B2 publication Critical patent/JP4485494B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Description

本発明は、動画像の符号化方法および復号化方法に関するものであり、特に既に符号化済みのピクチャを参照して画面間予測を行う符号化方法および復号化方法に関するものである。   The present invention relates to a moving image encoding method and decoding method, and more particularly to an encoding method and a decoding method for performing inter-screen prediction with reference to an already encoded picture.

近年、マルチメディアアプリケーションの発展に伴い、画像・音声・テキストなど、あらゆるメディアの情報を統一的に扱うことが一般的になってきた。この時、全てのメディアをディジタル化することにより統一的にメディアを扱うことが可能になる。しかしながら、ディジタル化された画像は膨大なデータ量を持つため、蓄積・伝送のためには、画像の情報圧縮技術が不可欠である。一方で、圧縮した画像データを相互運用するためには、圧縮技術の標準化も重要である。画像圧縮技術の標準規格としては、ITU−T(国際電気通信連合 電気通信標準化部門)のH.261、H.263、ISO(国際標準化機構)のMPEG−1、MPEG−4などがある。また、ITUでは、現在、最新の画像符号化規格としてH.26Lが標準化中である。   In recent years, with the development of multimedia applications, it has become common to handle all media information such as images, sounds, and texts in a unified manner. At this time, the media can be handled uniformly by digitizing all the media. However, since a digitized image has an enormous amount of data, image information compression technology is indispensable for storage and transmission. On the other hand, in order to interoperate compressed image data, standardization of compression technology is also important. Image compression technology standards include H.264 of ITU-T (International Telecommunication Union Telecommunication Standardization Sector). 261, H.H. H.263, ISO (International Organization for Standardization) MPEG-1, MPEG-4, and the like. In addition, in the ITU, the latest image coding standard is H.264. 26L is being standardized.

一般に動画像の符号化では、時間方向および空間方向の冗長性を削減することによって情報量の圧縮を行う。そこで時間的な冗長性の削減を目的とするピクチャ間予測符号化では、前方または後方のピクチャを参照してブロック単位で動きの検出および予測画像の作成を行い、得られた予測画像と現在のピクチャとの差分値に対して符号化を行う。   In general, in encoding of moving images, the amount of information is compressed by reducing redundancy in the time direction and the spatial direction. Therefore, in inter-picture predictive coding for the purpose of reducing temporal redundancy, motion is detected and a predicted image is created in units of blocks with reference to forward or backward pictures. Encoding is performed on the difference value from the picture.

ここで、ピクチャとは、1枚の画面を表す用語であり、プログレッシブ画像ではフレームを意味し、インタレース画像ではフレームもしくはフィールドを意味する。ここで、インタレース画像とは、1つのフレームが時刻の異なる2つのフィールドから構成される画像である。インタレース画像の符号化や復号化処理においては、1つのフレームをフレームのまま処理したり、2つのフィールドとして処理したり、フレーム内のブロック毎にフレーム構造またはフィールド構造として処理したりすることができる。   Here, a picture is a term representing a single screen, which means a frame in a progressive image and a frame or field in an interlaced image. Here, an interlaced image is an image in which one frame is composed of two fields having different times. In interlaced image encoding and decoding processing, one frame may be processed as a frame, processed as two fields, or processed as a frame structure or a field structure for each block in the frame. it can.

なお、以下で示すピクチャはプログレッシブ画像でのフレームの意味で説明するが、インタレース画像でのフレームもしくはフィールドであっても同様に説明することができる。   In addition, although the picture shown below is demonstrated in the meaning of the frame in a progressive image, it can explain similarly also about the frame or field in an interlaced image.

図30はピクチャの種類とその参照関係を説明するための図である。
ピクチャI1のように参照ピクチャを持たずピクチャ内予測符号化を行うものをIピクチャと呼ぶ。また、ピクチャP10のように1枚のピクチャのみを参照しピクチャ間予測符号化を行うものをPピクチャと呼ぶ。また、同時に2枚のピクチャを参照してピクチャ間予測符号化を行うことのできるものをBピクチャと呼ぶ。
FIG. 30 is a diagram for explaining the types of pictures and their reference relationships.
A picture that does not have a reference picture and performs intra-picture prediction coding, such as picture I1, is called an I picture. Also, a picture that performs inter-picture predictive coding with reference to only one picture, such as picture P10, is called a P picture. A picture that can perform inter-picture prediction coding with reference to two pictures at the same time is called a B picture.

BピクチャはピクチャB6、B12、B18のように時間的に任意の方向にある2枚のピクチャを同時に参照することが可能である。参照ピクチャは動き検出の単位であるブロックごとに指定することができるが、符号化を行った符号列中に先に記述される方の参照ピクチャを第1参照ピクチャ、後に記述される方を第2参照ピクチャとして区別する。   A B picture can simultaneously reference two pictures in any direction in time, such as pictures B6, B12, and B18. The reference picture can be specified for each block which is a unit of motion detection. The reference picture described earlier in the encoded code string is the first reference picture, and the one described later is the second reference picture. Two reference pictures are distinguished.

ただし、これらのピクチャを符号化および復号化する場合の条件として、参照するピクチャが既に符号化および復号化されている必要がある。図31はBピクチャを符号化および復号化する場合の順番の例である。図31(a)は表示される順番、図31(b)は(a)を符号化および復号化する順番に並び替えたものである。ピクチャB3、B6によって参照されるピクチャは全て先に符号化および復号化されているように並び替えられているのが分かる。   However, as a condition for encoding and decoding these pictures, the picture to be referenced needs to be already encoded and decoded. FIG. 31 shows an example of the order in the case of encoding and decoding a B picture. FIG. 31A shows the display order, and FIG. 31B shows the rearrangement in the order of encoding and decoding. It can be seen that all the pictures referenced by the pictures B3 and B6 have been rearranged so that they have been encoded and decoded first.

前記Bピクチャの符号化において、同時に2つのピクチャを参照する場合の予測画像の作成方法について図32を用いて詳しく説明する。なお、復号化の場合の予測画像の作成方法についても全く同様である。   A method of creating a predicted image when referring to two pictures at the same time in the encoding of the B picture will be described in detail with reference to FIG. Note that the same is true for the method of creating a predicted image in the case of decoding.

ピクチャB4は現在符号化の対象としているBピクチャであり、ブロックBL01およびブロックBL02は前記Bピクチャに属する符号化対象のブロックである。BL01は第1参照ピクチャをピクチャP2、第2参照ピクチャをピクチャP3とし、それぞれのピクチャに属するブロックBL11およびBL21を参照して予測画像を作成する。同様にBL02は第1参照ピクチャをピクチャP2、第2参照ピクチャをピクチャP1とし、それぞれのピクチャに属するブロックBL12およびBL22を参照して予測画像を作成する。(非特許文献1参照)   The picture B4 is a B picture currently being encoded, and the block BL01 and the block BL02 are blocks to be encoded belonging to the B picture. In BL01, the first reference picture is the picture P2, the second reference picture is the picture P3, and the prediction picture is created by referring to the blocks BL11 and BL21 belonging to the respective pictures. Similarly, BL02 uses the first reference picture as the picture P2 and the second reference picture as the picture P1, and creates a prediction image by referring to the blocks BL12 and BL22 belonging to the respective pictures. (See Non-Patent Document 1)

図33は参照された2つのブロックBL11およびBL21を用いて符号化対象のブロックBL01の予測画像を作成する方法を説明するための図である。ここでは各ブロックのサイズが4×4画素であると仮定して説明を行う。Q1(i)はBL11の画素値、Q2(i)はBL21の画素値、P(i)は求めるBL01の予測画像の画素値とすると、画素値P(i)は式1のような線形予測式によって算出することができる。iは画素の位置を示すものであり、ここでの例では0から15の値を持つことになる。   FIG. 33 is a diagram for explaining a method of creating a prediction image of the encoding target block BL01 using the two referenced blocks BL11 and BL21. Here, the description will be made assuming that the size of each block is 4 × 4 pixels. When Q1 (i) is the pixel value of BL11, Q2 (i) is the pixel value of BL21, and P (i) is the pixel value of the predicted image of BL01 to be obtained, the pixel value P (i) is a linear prediction as shown in Equation 1. It can be calculated by an equation. i indicates the position of the pixel, and has a value of 0 to 15 in this example.

P(i)=(w1×Q1(i)+w2×Q2(i))/pow(2,d)+c (式1)
(pow(2,d)は2のd乗を示す)
P (i) = (w1 × Q1 (i) + w2 × Q2 (i)) / pow (2, d) + c (Formula 1)
(Pow (2, d) indicates 2 to the power of d)

w1、w2、c、dは線形予測を行うための係数であり、4つで1組の重み付け係数セットとして扱う。これらの重み付け係数セットは各ブロックが参照するピクチャを指定する参照インデックスによって決定されるものであり、例えばBL01の場合はw1_1、w2_1、c_1、d_1、BL02の場合はw1_2、w2_2、c_2、d_2という4つの値を使用する。   w1, w2, c, and d are coefficients for performing linear prediction, and four are treated as one set of weighting coefficients. These weighting coefficient sets are determined by a reference index that designates a picture to be referenced by each block. For example, in the case of BL01, w1_1, w2_1, c_1, d_1, and in the case of BL02, w1_2, w2_2, c_2, and d_2. Four values are used.

次に、参照ピクチャを指定するための参照インデックスについて図34、図35を用いて説明する。各ピクチャにはメモリに蓄積されるごとに1ずつ増加するピクチャ番号という値が割り振られている。つまり、新たに蓄積されるピクチャには既存のピクチャ番号の最大値から1つ増加した値を持つピクチャ番号が付与される。しかし、実際に参照画像を指定するのはこのピクチャ番号ではなく、別に定義された参照インデックスという値を使用することになる。第1参照ピクチャを示すものを第1参照インデックス、第2参照ピクチャを示すものを第2参照インデックスと呼ぶ。   Next, a reference index for designating a reference picture will be described with reference to FIGS. Each picture is assigned a value called a picture number that increases by 1 each time it is stored in the memory. That is, a picture number having a value increased by one from the maximum value of existing picture numbers is assigned to a newly stored picture. However, it is not this picture number that actually designates the reference image, but a value called a reference index defined separately is used. A picture indicating the first reference picture is called a first reference index, and a picture showing the second reference picture is called a second reference index.

図34は、ピクチャ番号に対する2つの参照インデックスの割り当て方法を説明するための図である。図のような表示される順に並べられたピクチャ列があったとき、ピクチャ番号は符号化される順番に割り振られている。参照インデックスをピクチャ番号に割り当てるためのコマンドはピクチャをさらに分割した符号化単位であるスライスのヘッダに記述され、1つのスライスを符号化する毎に割り振り方が更新されることになる。前記コマンドは、直前に参照インデックスに割り当てたピクチャ番号と現在割り当てを行っているピクチャ番号との差分値を参照インデックスの数だけ連続して指示するものである。   FIG. 34 is a diagram for explaining a method of assigning two reference indexes to a picture number. When there are picture sequences arranged in the order of display as shown in the figure, picture numbers are assigned in the order of encoding. A command for assigning a reference index to a picture number is described in the header of a slice, which is an encoding unit obtained by further dividing a picture, and the allocation method is updated every time one slice is encoded. The command sequentially indicates the difference value between the picture number assigned to the reference index immediately before and the picture number currently assigned by the number of reference indexes.

図34の第1参照インデックスの例を用いると、まずコマンドとして"−1"が与えられたので、現在符号化の対象としているピクチャ番号16番から1を引くことにより、ピクチャ番号15番が参照インデックス0番に割り当てられる。次に"−4"が与えられたので、直前に割り当てを行ったピクチャ番号15番から4を引くことにより、ピクチャ番号11番が参照インデックス1番に割り当てられる。以下同様の処理によって各ピクチャ番号の割り当てが行われる。第2参照インデックスの場合も同様である。   When the example of the first reference index in FIG. 34 is used, first, “−1” is given as a command. Therefore, by subtracting 1 from the picture number 16 currently being encoded, the picture number 15 is referred to. Assigned to index number 0. Next, since “−4” is given, the picture number 11 is assigned to the reference index 1 by subtracting 4 from the picture number 15 assigned immediately before. Thereafter, each picture number is assigned by the same process. The same applies to the second reference index.

図35は参照インデックスの割り当てを行った結果を示したものである。各ピクチャ番
号には第1参照インデックスおよび第2参照インデックスがそれぞれ独立に割り当てられているが、それぞれの参照インデックスだけをみると1つのピクチャ番号に対して1つの参照インデックスが割り当てられているのが分かる。
FIG. 35 shows the result of assigning a reference index. A first reference index and a second reference index are independently assigned to each picture number, but only one reference index is assigned to one picture number when only the reference indices are viewed. I understand.

次に図36および図37を用いて使用する重み付け係数セットの決定方法を説明する。
1つのピクチャの符号列は、ピクチャ共通情報領域および複数のスライスデータ領域から構成される。図36はそのうちのスライスデータ領域の構成を示したものである。さらにスライスデータ領域は、スライスヘッダ領域および複数のブロックデータ領域から構成される。ここではブロックデータ領域の例として図32におけるBL01、BL02に対応する各ブロックの領域が示されている。
Next, a method for determining a weighting coefficient set to be used will be described with reference to FIGS.
The code string of one picture is composed of a picture common information area and a plurality of slice data areas. FIG. 36 shows the structure of the slice data area. Furthermore, the slice data area includes a slice header area and a plurality of block data areas. Here, as an example of the block data area, the area of each block corresponding to BL01 and BL02 in FIG. 32 is shown.

BL01に含まれるref1およびref2はこのブロックが参照する2枚のピクチャを指し示す第1参照インデックスおよび第2参照インデックスをそれぞれ指示するものである。またスライスヘッダ領域には前記線形予測を行うための重み付け係数セットを決定するためのデータ(pset0、pset1、pset2、pset3、pset4)がref1用およびref2用それぞれに記述されている。図37は前記スライスヘッダ領域に含まれる前記データの例を表に示したものである。   Ref1 and ref2 included in BL01 respectively indicate a first reference index and a second reference index indicating two pictures referred to by this block. In the slice header area, data (pset0, pset1, pset2, pset3, pset4) for determining a weighting coefficient set for performing the linear prediction is described for each of ref1 and ref2. FIG. 37 is a table showing an example of the data included in the slice header area.

識別子psetで示された各々のデータはw1、w2、c、dの4つ値を持ち、ref1およびref2の値によってダイレクトに参照できるように構成されている。また、スライスヘッダ領域には前記参照インデックスをピクチャ番号に割り当てるためのコマンド列idx_cmd1およびidx_cmd2が記述されている。   Each data indicated by the identifier pset has four values w1, w2, c, and d, and is configured so that it can be directly referred to by the values of ref1 and ref2. In the slice header area, command strings idx_cmd1 and idx_cmd2 for assigning the reference index to the picture number are described.

図36のBL01に記述されたref1およびref2によって図37のref1用およびref2用のテーブルからそれぞれ1組ずつの重み付け係数セットが選択される。各々の重み付け係数セットを用いて式1の線形予測を行うことにより、2つの予測画像が生成される。この2つの予測画像に対してそれぞれ画素ごとに平均を取ることにより求める予測画像を得ることができる。   One set of weighting coefficients is selected from the table for ref1 and ref2 in FIG. 37 by ref1 and ref2 described in BL01 in FIG. By performing linear prediction of Equation 1 using each weighting coefficient set, two predicted images are generated. A predicted image obtained by averaging the two predicted images for each pixel can be obtained.

また、上述したように線形予測係数の重み付け係数セットから求める予測式を用いて予測画像を生成するのではなく、予め決めた固定式を用いて予測画像を求める方法もある。この方法として、第1参照インデックスによって指定されるピクチャが第2参照インデックスによって指定されるピクチャよりも表示順において後にある場合は、固定の係数からなる固定式である式2aを選択し、それ以外は固定の係数からなる固定式である式2bを選択して、予測画像を生成する。   In addition, as described above, there is also a method for obtaining a predicted image using a predetermined fixed expression instead of generating a predicted image using a prediction expression obtained from a weighted coefficient set of linear prediction coefficients. As this method, when the picture specified by the first reference index is later in the display order than the picture specified by the second reference index, the expression 2a which is a fixed expression including a fixed coefficient is selected, and otherwise Selects a formula 2b, which is a fixed formula composed of fixed coefficients, and generates a predicted image.

P(i)=2×Q1(i)−Q2(i) (式2a)
P(i)=(Q1(i)+Q2(i))/2 (式2b)
P (i) = 2 × Q1 (i) −Q2 (i) (Formula 2a)
P (i) = (Q1 (i) + Q2 (i)) / 2 (Formula 2b)

このように、予測式が固定であるため、予測画像を求めるときの重み付け係数セットを符号化して送る必要がないという利点がある。また、ピクチャの位置関係によって固定式の選択が行われるため、線形予測係数の重み付け係数セットを指定するためのフラグを符号化して送る必要がないという利点もある。また、線形予測の計算式が単純であるため、少ない処理量で線形予測を大幅に削減することが可能である。
ITU-T Rec. H.264 | ISO/IEC 14496-10 AVC,Joint Committee Draft (CD)(2002-5-10)(P.34 8.4.3 Re-Mapping of frame numbers indicator,P.105 11.5 Prediction signal generation procedure)
Thus, since the prediction formula is fixed, there is an advantage that it is not necessary to encode and send a weighting coefficient set for obtaining a predicted image. Further, since a fixed type is selected depending on the positional relationship of pictures, there is an advantage that it is not necessary to encode and send a flag for designating a weighting coefficient set of linear prediction coefficients. In addition, since the calculation formula for linear prediction is simple, it is possible to significantly reduce linear prediction with a small amount of processing.
ITU-T Rec. H.264 | ISO / IEC 14496-10 AVC, Joint Committee Draft (CD) (2002-5-10) (P.34 8.4.3 Re-Mapping of frame numbers indicator, P.105 11.5 Prediction signal generation procedure)

式1による重み付け係数セットを用いた予測画像作成方法では、参照ピクチャに参照インデックスを割り当てるコマンドの数が参照ピクチャの枚数と同じ数であるため、1つの参照ピクチャに対して1つの参照インデックスのみしか割り当てられず、同じ参照ピクチャを参照しているブロックでは線形予測に使用される重み付け係数セットは全く同じ値のものとなる。ピクチャ内で一様な画像変化が起こっている場合は問題ないが、部分部分によって画像変化が異なる場合は、最適な予測画像が生成されない可能性が非常に高くなってしまう。また、式中に掛け算を用いた演算が含まれているため、線形予測のための処理量が大きくなってしまうという問題がある。   In the predictive image creation method using the weighting coefficient set according to Equation 1, since the number of commands for assigning reference indexes to reference pictures is the same as the number of reference pictures, there is only one reference index for one reference picture. In blocks that are not assigned and refer to the same reference picture, the weighting coefficient sets used for linear prediction have the same value. There is no problem if a uniform image change occurs in the picture, but if the image change differs depending on the partial portion, there is a very high possibility that an optimal predicted image will not be generated. In addition, there is a problem that the amount of processing for linear prediction becomes large because an operation using multiplication is included in the equation.

そこで本発明の目的は、1つの参照ピクチャに複数の参照ピクチャを割り当ることを可能にするとともに、複数の参照インデックスが割り当てられている場合であっても、1つの参照インデックスが割り当てられている場合であっても、参照インデックスの復号化の効率を向上させる画像符号化方法、画像復号化方法、それらの装置、それらのプログラムを提供することにある。   Therefore, an object of the present invention is to allow a plurality of reference pictures to be assigned to one reference picture, and to assign one reference index even when a plurality of reference indexes are assigned. Even in such a case, an object is to provide an image encoding method, an image decoding method, an apparatus thereof, and a program thereof that improve the efficiency of reference index decoding.

そしてこの目的を達成するために、本発明の画像符号化方法は、ピクチャ番号で識別される符号化済ピクチャを参照ピクチャとして記憶部に格納する参照ピクチャ格納ステップと、予測画像の生成に用いられる係数および前記参照ピクチャを指定する参照インデックスと前記ピクチャ番号とを対応付けるコマンドを生成するコマンド生成ステップと、符号化対象ピクチャ上のブロックに対して動き補償を行うときの参照ピクチャを前記参照インデックスにより指定する参照ピクチャ指定ステップと、前記参照ピクチャ指定ステップで指定された参照ピクチャ内の動き検出により得られたブロックに対して、前記参照インデックスに対応した前記係数を用いた線形予測を施すことにより予測画像を生成する予測画像生成ステップと、入力された符号化対象ピクチャ内のブロックと前記予測画像との差である予測残差と、前記コマンドと、前記参照インデックスと、前記係数とを符号化した符号化信号を含む画像符号化信号を出力する符号化信号出力ステップとを有し、前記符号化信号出力ステップは、前記画像符号化信号中に前記参照インデックスの最大値を示す情報を符号化するように構成されている。   In order to achieve this object, the image coding method of the present invention is used for a reference picture storing step of storing an encoded picture identified by a picture number as a reference picture in a storage unit, and generation of a predicted image. A command generation step for generating a command for associating a coefficient and a reference index for designating the reference picture with the picture number, and a reference picture for performing motion compensation on a block on the encoding target picture is designated by the reference index A prediction picture by performing linear prediction using the coefficient corresponding to the reference index on a block obtained by motion detection in the reference picture designated in the reference picture designation step and the reference picture designation step A predicted image generation step for generating A code that outputs a coded signal including a coded signal obtained by coding a prediction residual that is a difference between a block in a picture to be coded and the predicted image, the command, the reference index, and the coefficient. An encoded signal output step, and the encoded signal output step is configured to encode information indicating a maximum value of the reference index in the image encoded signal.

ここで、前記参照インデックスの最大値を示す情報は、前記画像符号化信号に含まれるピクチャ共通情報領域に置かれている構成としてもよい。   Here, the information indicating the maximum value of the reference index may be placed in a picture common information area included in the encoded image signal.

この構成によれば、復号化装置において、前記コマンドを基に、ピクチャ番号と参照インデックスとを対応付けていくときに、参照インデックスの最大値を示す情報が符号化信号に含まれるので、ピクチャ番号と参照インデックスとをコマンドに従って対応付け処理を前記最大値に達するまで行うことにより、容易に、すべての参照インデックスとピクチャ番号との対応づけを行うことができる。その結果、1つの参照ピクチャに複数の参照ピクチャを割り当ることを可能にするとともに、複数の参照インデックスが割り当てられている場合であっても、1つの参照インデックスが割り当てられている場合であっても、参照インデックスの復号化を効率よく行うことができる。   According to this configuration, when the decoding apparatus associates a picture number with a reference index based on the command, information indicating the maximum value of the reference index is included in the encoded signal. By associating the reference index with the reference index until the maximum value is reached according to the command, it is possible to easily associate all the reference indexes with the picture numbers. As a result, it is possible to assign a plurality of reference pictures to one reference picture, and even when a plurality of reference indexes are assigned, one reference index is assigned. In addition, the reference index can be efficiently decoded.

ここで、前記コマンド生成ステップにおいて、記憶部に格納されている複数の参照ピクチャの中に、複数の参照インデックスが対応付けられたピクチャ番号を有する参照ピクチャが少なくとも1つ以上含まれるようにコマンドを生成する構成としてもよい。   Here, in the command generation step, a command is issued so that at least one reference picture having a picture number associated with a plurality of reference indexes is included in the plurality of reference pictures stored in the storage unit. It is good also as composition to generate.

また、前記参照ピクチャ指定ステップにおいて、前記参照ピクチャのピクチャ番号に対して複数の参照インデックスが対応付けられている場合、当該複数の参照インデックスのそれぞれ対応する係数に基づいて、その中の1つの参照インデックスを選択し、前記予測画像生成ステップにおいて、指定ステップで選択された参照インデックスに対応する係数を用いて線形予測を施す構成としてもよい。   In the reference picture designating step, when a plurality of reference indexes are associated with the picture number of the reference picture, one reference among them is based on the coefficient corresponding to each of the plurality of reference indexes. An index may be selected, and in the predicted image generation step, linear prediction may be performed using a coefficient corresponding to the reference index selected in the designation step.

この構成によれば、1つのピクチャ番号に複数の参照インデックスを対応付けるので、参照ピクチャを指定する前記参照インデックスに対応した前記係数を用いた線形予測を施す際に、当該係数を複数の係数の中から選択することが可能となる。つまり、線形予測に用いられる係数として最適な係数を選択することができる。その結果、符号化効率の向上を図ることができる。   According to this configuration, since a plurality of reference indexes are associated with one picture number, when performing linear prediction using the coefficient corresponding to the reference index that designates a reference picture, the coefficient is selected from among the plurality of coefficients. It becomes possible to select from. That is, an optimum coefficient can be selected as a coefficient used for linear prediction. As a result, the encoding efficiency can be improved.

ここで、前記予測画像生成ステップにおいて、ビットシフト演算、加算および減算のみを使用して前記線形予測を行う構成としてもよい。   Here, in the predicted image generation step, the linear prediction may be performed using only bit shift operation, addition and subtraction.

この構成によれば、処理負荷の重い乗除算を使用せず、処理負荷の軽いビットシフト演算、加算および減算のみを使用するので、線形予測の処理量を少なく抑えることができる。   According to this configuration, multiplication / division with a heavy processing load is not used, and only bit shift calculation, addition and subtraction with a light processing load are used. Therefore, the processing amount of linear prediction can be reduced.

ここで、前記予測画像生成ステップにおける前記線形予測で用いる係数として、線形予測式における直流成分を示す値のみが、前記参照インデックスに対応付けられる構成としてもよい。   Here, as a coefficient used in the linear prediction in the predicted image generation step, only a value indicating a DC component in a linear prediction formula may be associated with the reference index.

この構成によれば、係数として、直流成を示す値以外の値は符号化しなくてよいので、符号化効率を向上させることができる。また、処理負荷の重い乗除算を使用せず、処理負荷の軽い加算および減算のみを使用するので、線形予測の処理量を少なく抑えることができる。   According to this configuration, since it is not necessary to encode a value other than the value indicating the direct current as a coefficient, the encoding efficiency can be improved. In addition, since the multiplication / division with heavy processing load is not used and only addition and subtraction with low processing load are used, the processing amount of linear prediction can be reduced.

ここで、前記参照インデックスは、第1の参照ピクチャを示す第1の参照インデックスと、第2の参照ピクチャを示す第2の参照インデックスとを有し、前記予測画像生成ステップにおける前記線形予測を行う方法として、各参照ピクチャの持つ表示順情報によって係数を生成する方法を使用する場合に、第1の参照インデックスによって指定される参照ピクチャおよび第2の参照インデックスによって指定される参照ピクチャとが同じ表示順情報をもつ時は、予め設定された係数を代わりに用いて線形予測を行う構成としてもよい。また、前記予め設定された係数は、同じ重みを有する構成としてもよい。   Here, the reference index includes a first reference index indicating a first reference picture and a second reference index indicating a second reference picture, and performs the linear prediction in the predicted image generation step. As a method, when using a method of generating coefficients according to display order information of each reference picture, the reference picture specified by the first reference index and the reference picture specified by the second reference index are displayed in the same manner. When there is order information, it may be configured to perform linear prediction using a preset coefficient instead. The preset coefficients may have the same weight.

この構成によれば、2つの参照ピクチャとが同じ表示順情報をもつ場合でも係数を決定し線形予測を行うことが可能となり、符号化効率を向上させることができる。   According to this configuration, even when two reference pictures have the same display order information, it is possible to determine a coefficient and perform linear prediction, thereby improving encoding efficiency.

また、本発明の画像復号化方法、画像符号化装置、画像復号化装置、画像符号化プログラム、画像復号化プログラムおよび画像符号化データについても、上記と同様の構成、作用および効果を有する。   In addition, the image decoding method, the image encoding device, the image decoding device, the image encoding program, the image decoding program, and the image encoded data of the present invention have the same configurations, operations, and effects as described above.

また、本発明の画像符号化方法は、以下の(1)〜(14)の何れかの構成とすることができる。   In addition, the image encoding method of the present invention may have any of the following configurations (1) to (14).

(1)本発明による画像符号化方法は、ピクチャ番号で識別される符号化済ピクチャを記憶部に格納する参照ピクチャ格納ステップと、符号化対象ピクチャ上のブロックに対して動き補償を行うときに参照する、記憶部に格納されている複数の符号化済ピクチャから任意に選択された、参照ピクチャと予測画像を生成するときに用いる係数とを示す参照インデックスと、前記ピクチャ番号とを対応付けるコマンドであって、複数の参照インデックスが同一のピクチャを参照することが可能であるコマンドを生成するコマンド生成ステップと、符号化対象ピクチャ上のブロックに対して動き補償を行うときに参照する参照ピクチャを前記参照インデックスにより指定する参照ピクチャ指定ステップと、前記参照ピクチャ指定ステップで選択された参照ピクチャ上の動き検出により得られたブロックに対して、この参照ピクチャを指定する前記参照インデックスに対応した前記係数を用いた線形予測を施すことにより予測画像を生成する予測画像生成ステップと、入力された符号化対象フレームと前記予測画像との差である予測残差と、前記コマンドと、前記参照インデックスと、前記係数とを符号化した符号化信号を含む画像符号化信号を出力する符号化信号出力ステップとを有する。   (1) An image encoding method according to the present invention includes a reference picture storing step of storing an encoded picture identified by a picture number in a storage unit, and motion compensation for a block on an encoding target picture. A command for associating a reference index indicating a reference picture and a coefficient used when generating a predicted image, arbitrarily selected from a plurality of encoded pictures stored in the storage unit to be referred to, and the picture number A command generation step for generating a command that allows a plurality of reference indexes to refer to the same picture, and a reference picture to be referred to when motion compensation is performed on a block on the encoding target picture. Selected by a reference picture designating step designated by a reference index and the reference picture designating step. A prediction image generation step for generating a prediction image by performing linear prediction using the coefficient corresponding to the reference index for designating the reference picture with respect to a block obtained by motion detection on the reference picture; Coding for outputting an encoded image signal including an encoded signal obtained by encoding a prediction residual that is a difference between the encoded target frame and the predicted image, the command, the reference index, and the coefficient A signal output step.

(2)さらに、本発明による別の画像符号化方法は、前記参照ピクチャが有するピクチャ番号に対し、複数の参照インデックスを割り当てることが可能であり、前記参照ピクチャ指定ステップにおいて各符号化済ピクチャに対応する1つ以上の参照インデックスから1つの参照インデックスを選択し、前記予測画像生成ステップにおける線形予測で用いる係数を決定することができる。   (2) Further, according to another image encoding method of the present invention, a plurality of reference indexes can be assigned to a picture number of the reference picture, and each encoded picture is assigned to the reference picture in the reference picture specifying step. One reference index is selected from one or more corresponding reference indexes, and a coefficient used in linear prediction in the predicted image generation step can be determined.

(3)さらに、本発明による別の画像符号化方法は、1つのスライスによって参照される複数の参照ピクチャの中に、複数の参照インデックスが割り当てられたピクチャ番号を有する参照ピクチャを少なくとも1つ有することができる。   (3) Furthermore, another image coding method according to the present invention has at least one reference picture having a picture number to which a plurality of reference indexes are assigned among a plurality of reference pictures referenced by one slice. be able to.

(4)さらに、本発明による別の画像符号化方法において、前記参照インデックスは、前記複数の符号化済ピクチャから任意に指定された第1の参照ピクチャを示す第1の参照インデックスと、前記複数の符号化済フレームから任意に指定された第2の参照フレームを示す第2の参照インデックスとからなり、前記予測画像生成ステップでは、前記ブロックに対して、前記第1の参照インデックスに対応する係数によって線形予測を施すとともに、前記第2の参照インデックスに対応する係数によって線形予測を施し、それぞれの線形予測で得られた2つの予測画像における画素値の平均を求めることによって、前記ブロックに対する最終的な予測画像を生成する。   (4) Furthermore, in another image encoding method according to the present invention, the reference index includes a first reference index indicating a first reference picture arbitrarily designated from the plurality of encoded pictures, and the plurality of reference indexes. A second reference index indicating a second reference frame arbitrarily specified from the encoded frame of the first frame, and in the predicted image generation step, a coefficient corresponding to the first reference index for the block The linear prediction is performed by the coefficient corresponding to the second reference index, and the average of the pixel values in the two predicted images obtained by the respective linear predictions is obtained. A predictive image is generated.

(5)さらに、本発明による別の画像符号化方法において、前記参照インデックスは、前記複数の符号化済ピクチャから任意に指定された第1の参照ピクチャを示す第1の参照インデックスと、前記複数の符号化済フレームから任意に指定された第2の参照フレームを示す第2の参照インデックスとからなり、前記予測画像生成ステップにおける前記線形予測で用いる係数の決定は、選択された第1の参照インデックスと第2の参照インデックスそれぞれが指示する前記係数の平均によって求められる。   (5) Furthermore, in another image encoding method according to the present invention, the reference index includes a first reference index indicating a first reference picture arbitrarily designated from the plurality of encoded pictures, and the plurality of reference indexes. And a second reference index indicating a second reference frame arbitrarily designated from the encoded frames of the first frame, and the determination of the coefficient used in the linear prediction in the predicted image generation step is performed by the selected first reference It is obtained by averaging the coefficients indicated by the index and the second reference index.

(6)さらに、本発明による別の画像符号化方法において、前記参照インデックスは、前記複数の符号化済ピクチャから任意に指定された第1の参照ピクチャを示す第1の参照インデックスと、前記複数の符号化済フレームから任意に指定された第2の参照フレームを示す第2の参照インデックスとからなり、前記第1及び第2の参照インデックスには、複数の係数からなる組が対応づけられ、前記予測画像生成ステップでは、一方の参照インデックスに対応する係数の組のうちの一部と他方の参照インデックスに対応する係数の組の一部とを用いて前記予測画像を生成する。   (6) Furthermore, in another image encoding method according to the present invention, the reference index includes a first reference index indicating a first reference picture arbitrarily designated from the plurality of encoded pictures, and the plurality of reference indexes. A second reference index indicating a second reference frame arbitrarily designated from the encoded frames of the first and second reference indexes, a set of a plurality of coefficients is associated with the first and second reference indexes, In the predicted image generation step, the predicted image is generated using a part of a set of coefficients corresponding to one reference index and a part of a set of coefficients corresponding to the other reference index.

(7)さらに、本発明による別の画像符号化方法は、前記予測画像生成ステップにおける前記線形予測で用いる計算式は、乗算および除算を使用することなくビットシフト演算および加算および減算のみで構成される。これにより、演算処理の少ない処理のみで線形予測ができる。   (7) Further, in another image encoding method according to the present invention, the calculation formula used in the linear prediction in the predicted image generation step is configured only by bit shift operation and addition and subtraction without using multiplication and division. The As a result, linear prediction can be performed with only a small amount of processing.

(8)さらに、本発明による別の画像符号化方法において、前記参照インデックスは、前記複数の符号化済ピクチャから任意に指定された第1の参照ピクチャを示す第1の参照インデックスと、前記複数の符号化済フレームから任意に指定された第2の参照フレームを示す第2の参照インデックスとからなり、前記予測画像生成ステップでは、前記第1及び第2の参照インデックスに対応する係数の組のうち、前記ビットシフト演算に用いられる係数は前記第1及び第2の参照インデックスのいずれかに対応する係数を選択して使用し、その他の演算に用いられる係数は前記第1及び第2の参照インデックスそれぞれに対応する係数の平均値を使用して前記予測画像を生成する。   (8) Further, in another image encoding method according to the present invention, the reference index includes a first reference index indicating a first reference picture arbitrarily designated from the plurality of encoded pictures, and the plurality of reference indexes. And a second reference index indicating a second reference frame arbitrarily designated from the encoded frames of the encoded frame, and in the predicted image generation step, a set of coefficients corresponding to the first and second reference indexes Of these, the coefficient used for the bit shift operation is selected and used for the coefficient corresponding to one of the first and second reference indexes, and the coefficient used for the other operations is the first and second references. The predicted image is generated using an average value of coefficients corresponding to each index.

(9)さらに、本発明による別の画像符号化方法において、前記参照インデックスは、前記複数の符号化済ピクチャから任意に指定された第1の参照ピクチャを示す第1の参照インデックスと、前記複数の符号化済フレームから任意に指定された第2の参照フレームを示す第2の参照インデックスとからなり、前記予測画像生成ステップにおける前記線形予測で用いる係数として、線形予測式における直流成分を示す値のみを使用し、第1の参照インデックスおよび第2の参照インデックスそれぞれに1つずつ対応付けられる。   (9) Furthermore, in another image encoding method according to the present invention, the reference index includes a first reference index indicating a first reference picture arbitrarily designated from the plurality of encoded pictures, and the plurality of reference indexes. And a second reference index indicating a second reference frame arbitrarily specified from the encoded frame, and a value indicating a DC component in a linear prediction formula as a coefficient used in the linear prediction in the predicted image generation step Only one is associated with each of the first reference index and the second reference index.

(10)さらに、本発明による別の画像符号化方法において、ピクチャ番号で識別される符号化済ピクチャを記憶部に格納する参照ピクチャ格納ステップと、符号化対象ピクチャ上のブロックに対して動き補償を行うときに参照する、記憶部に格納されている複数の符号化済ピクチャから任意に選択された参照ピクチャを示す参照インデックスと、前記ピクチャ番号とを対応付けるコマンドであって、複数の参照インデックスが同一のピクチャを参照することが可能であるコマンドを生成するコマンド生成ステップステップと、符号化対象ピクチャ上のブロックに対して動き補償を行うときに参照する参照ピクチャを前記参照インデックスにより指定する参照ピクチャ指定ステップと、前記参照ピクチャ指定ステップで選択された参照ピクチャ上の動き検出により得られたブロックに対して、各参照ピクチャの持つ表示順情報から係数を生成し、前記係数を用いた線形予測を施すことにより予測画像を生成する予測画像生成ステップと、入力された符号化対象フレームと前記予測画像との差である予測残差と、前記コマンドと、前記参照インデックスと、前記係数とを符号化した符号化信号を含む画像符号化信号を出力する符号化信号出力ステップとを有する。   (10) Furthermore, in another image encoding method according to the present invention, a reference picture storing step for storing an encoded picture identified by a picture number in a storage unit, and motion compensation for a block on the encoding target picture Is a command for associating a reference index indicating a reference picture arbitrarily selected from a plurality of encoded pictures stored in the storage unit and referred to with the picture number. A command generation step for generating a command capable of referring to the same picture, and a reference picture for designating a reference picture to be referred to when motion compensation is performed on a block on the encoding target picture by the reference index The reference picture selected in the designation step and the reference picture designation step A prediction image generation step for generating a prediction image by generating a coefficient from the display order information of each reference picture for the block obtained by the above motion detection, and performing linear prediction using the coefficient, and an input Coding for outputting an encoded image signal including an encoded signal obtained by encoding a prediction residual that is a difference between the encoded target frame and the predicted image, the command, the reference index, and the coefficient A signal output step.

(11)さらに、本発明による別の画像符号化方法において、前記予測画像生成ステップにおける前記線形予測を行う方法として、前記表示順情報によって生成される係数を用いた方法と、予め設定された固定式を用いた方法とを、第1の参照インデックスによって指定される参照ピクチャおよび第2の参照インデックスによって指定される参照ピクチャの各々の持つ表示順情報の前後関係によって切り替えて使用する。   (11) Furthermore, in another image encoding method according to the present invention, as a method of performing the linear prediction in the predicted image generation step, a method using coefficients generated by the display order information, and a preset fixed The method using an expression is switched between the reference picture specified by the first reference index and the reference picture specified by the second reference index depending on the context of the display order information.

(12)さらに、本発明による別の画像符号化方法において、前記予測画像生成ステップにおける前記線形予測を行う方法として、前記表示順情報によって生成される係数を用いた方法を使用した際に、第1の参照インデックスによって指定される参照ピクチャおよび第2の参照インデックスによって指定される参照ピクチャとが同じ表示順情報をもつ場合は、予め設定された係数を代わりに用いて線形予測を行う。   (12) Furthermore, in another image encoding method according to the present invention, when a method using a coefficient generated by the display order information is used as a method of performing the linear prediction in the predicted image generation step, When the reference picture specified by the reference index 1 and the reference picture specified by the second reference index have the same display order information, linear prediction is performed using a preset coefficient instead.

(13)さらに、本発明による別の画像符号化方法において、前記予測画像生成ステップにおいて、前記表示順情報を用いて係数を生成する際に、前記線形予測が乗算および除算を使用することなくビットシフト演算および加算および減算のみで行えるように、前記係数を2のべき乗に近似する。   (13) Furthermore, in another image encoding method according to the present invention, when generating a coefficient using the display order information in the predicted image generation step, the linear prediction uses a bit without using multiplication and division. The coefficient is approximated to a power of 2 so that only shift operation and addition and subtraction can be performed.

(14)さらに、本発明による別の画像符号化方法において、前記近似を行う際に、第1の参照インデックスによって指定される参照ピクチャおよび第2の参照インデックスによって指定される参照ピクチャの各々の持つ表示順情報の前後関係によって、切り上げによる近似と切り下げによる近似とを切り替えて使用する。   (14) Furthermore, in another image encoding method according to the present invention, each of the reference picture specified by the first reference index and the reference picture specified by the second reference index is used when performing the approximation. Depending on the order of display order information, the approximation by rounding up and the approximation by rounding down are used.

(15)本発明のプログラムは、上記(1)〜(14)の何れかに記載の画像符号化方法をコンピュータに実行させる構成としてもよい。   (15) The program of this invention is good also as a structure which makes a computer perform the image coding method in any one of said (1)-(14).

また、本発明のコンピュータ読取可能な記録媒体は、以下の(16)〜(25)の何れかの構成とすることができる。   The computer-readable recording medium of the present invention can have any one of the following configurations (16) to (25).

(16)動画像が符号化された信号である符号化信号が記録されたコンピュータ読み取り可能な記録媒体であって、前記符号化信号は、予測画像を生成するときに用いる係数と、ピクチャ番号で識別される符号化済ピクチャを格納する記憶部に格納されている複数の符号化済ピクチャから任意に選択された、符号化対象ピクチャ上のブロックに対して動き補償を行うときに参照する、参照ピクチャと予測画像を生成するときに用いる前記係数とを示す参照インデックスと、前記ピクチャ番号とを対応付けるコマンドであって、複数の参照インデックスが同一のピクチャ番号に割り当てることが可能であるコマンドと、符号化対象ピクチャ上のブロックに対して動き補償を行うときに参照する参照ピクチャと予測画像を生成するときに用いる係数とを指定する参照インデックスと、選択された参照ピクチャ上の動き検出により得られたブロックに対して、この参照ピクチャを指定する前記参照インデックスに対応した前記係数を用いた線形予測を施すことにより生成される予測画像とが符号化されている。   (16) A computer-readable recording medium on which an encoded signal, which is a signal obtained by encoding a moving image, is recorded. The encoded signal is a coefficient used when generating a predicted image and a picture number. Reference that is referred to when performing motion compensation on a block on an encoding target picture, arbitrarily selected from a plurality of encoded pictures stored in a storage unit that stores an identified encoded picture A command for associating a reference index indicating a picture and the coefficient used when generating a predicted image and the picture number, and a command in which a plurality of reference indexes can be assigned to the same picture number, Used to generate a reference picture and a prediction image to be referred to when motion compensation is performed on a block on a target picture Generated by performing a linear prediction using the coefficient corresponding to the reference index for specifying the reference picture for the block obtained by motion detection on the selected reference picture. The predicted image to be processed is encoded.

(17)前記符号化信号には、前記参照インデックスの最大値が含まれる。   (17) The encoded signal includes the maximum value of the reference index.

(18)前記最大値は、前記符号化信号に含まれるピクチャの共通情報領域に置かれている。   (18) The maximum value is placed in a common information area of a picture included in the encoded signal.

(19)前記符号化信号に含まれるブロックの集まりからなるスライスのヘッダ、もしくはピクチャ共通情報領域、もしくは各ブロックのヘッダには、ブロックの予測画像を線形予測によって生成するための係数が符号化されているか否かを示すフラグが含まれる。   (19) A coefficient for generating a prediction image of a block by linear prediction is encoded in a header of a slice including a group of blocks included in the encoded signal, a picture common information area, or a header of each block. The flag which shows whether it is present is included.

(20)前記符号化信号に含まれるブロックの集まりからなるスライスのヘッダ、もしくはピクチャ共通情報領域、もしくは各ブロックのヘッダには、ブロックの予測画像を、係数を使用せずに予め設定された固定式を用いて生成するか、又は、直流成分を示す係数のみを使用して予め設定された固定式を用いて生成するかを示すフラグが含まれる。   (20) A prediction image of a block is fixed in advance without using a coefficient in a header of a slice including a group of blocks included in the encoded signal, a picture common information area, or a header of each block. A flag indicating whether to generate using an equation or a fixed equation set in advance using only a coefficient indicating a DC component is included.

(21)前記符号化信号に含まれるブロックの集まりからなるスライスのヘッダ、もしくはピクチャ共通情報領域、もしくは各ブロックのヘッダには、ブロックの予測画像を、予め設定された2つの式から構成される固定式を用いて生成する場合に、前記2つの式を切り替えて使用するか、又は、切り替えずに片方の式のみを使用するかを示すフラグが含まれる。   (21) In a header of a slice including a group of blocks included in the encoded signal, a picture common information area, or a header of each block, a predicted image of the block is configured by two preset expressions. When generating using a fixed expression, a flag indicating whether to use the two expressions by switching or using only one expression without switching is included.

(22)前記符号化信号に含まれるブロックの集まりからなるスライスのヘッダ、もしくはピクチャ共通情報領域、もしくは各ブロックのヘッダには、ブロックの予測画像を線形予測によって生成するための係数を参照されるピクチャの表示順情報を用いて作成するか否かを示すフラグが含まれる。   (22) A coefficient for generating a prediction image of a block by linear prediction is referred to in a header of a slice including a group of blocks included in the encoded signal, a picture common information area, or a header of each block. A flag indicating whether or not to create using picture display order information is included.

(23)前記符号化信号に含まれるブロックの集まりからなるスライスのヘッダ、もしくはピクチャ共通情報領域、もしくは各ブロックのヘッダには、ブロックの予測画像を線形予測によって生成するための係数が2のべき乗になるように近似するか否かを示すフラグが含まれる。   (23) A coefficient for generating a prediction image of a block by linear prediction is a power of 2 in a header of a slice including a group of blocks included in the encoded signal, a picture common information area, or a header of each block. A flag indicating whether or not to approximate is included.

(24)前記符号化信号に、乗算および除算を使用することなくビットシフト演算および加算および減算のみで線形予測の計算を行うことができることを示すためのフラグが含まれる。   (24) The encoded signal includes a flag for indicating that calculation of linear prediction can be performed only by bit shift operation and addition and subtraction without using multiplication and division.

(25)前記符号化信号に、直流成分を示す値のみで線形予測の計算を行うことができることを示すためのフラグが含まれる。   (25) The encoded signal includes a flag for indicating that linear prediction calculation can be performed using only a value indicating a DC component.

また、本発明の画像復号化方法は、以下の(26)〜(39)の何れかの構成とすることができる。   In addition, the image decoding method of the present invention can have any one of the following configurations (26) to (39).

(26)本発明による画像復号化方法は、予測画像を生成するときに用いる係数と、符号化対象ピクチャ上のブロックに対して動き補償を行うときに参照する、記憶部に格納されている複数の符号化済ピクチャから任意に選択された、参照ピクチャと前記係数とを示す参照インデックスと、前記ピクチャ番号とを対応付けるコマンドであって、複数の参照インデックスが同一のピクチャを参照することが可能であるコマンドと、前記参照インデックスと、予測残差の符号化信号とを有する画像符号化信号を復号化する画像符号化情報獲得ステップと、復号化された前記コマンドと、復号化された前記参照インデックスとにより、復号化対象ピクチャ上のブロックに対して動き補償を行うときに参照する参照ピクチャを決定する参照ピクチャ指定ステップと、決定された前記参照ピクチャ上の動き検出により得られたブロックに対して、この参照ピクチャを指定する前記参照インデックスに対応する係数を用いた線形予測を施すことにより予測画像を生成する予測画像生成ステップと、前記予測画像と復号化された予測残差とから復号画像を生成する復号画像生成ステップとを有する。   (26) An image decoding method according to the present invention includes a plurality of coefficients stored in a storage unit that are referred to when performing motion compensation on a block on an encoding target picture and coefficients used when generating a predicted image. This is a command for associating a reference index indicating a reference picture and the coefficient, arbitrarily selected from the encoded pictures, and the picture number, and a plurality of reference indexes can refer to the same picture. An encoded image information acquisition step for decoding an encoded image signal having a certain command, the reference index, and an encoded signal of a prediction residual, the decoded command, and the decoded reference index Thus, a reference picture indicator that determines a reference picture to be referred to when motion compensation is performed on a block on a decoding target picture Prediction for generating a prediction image by performing linear prediction using a coefficient corresponding to the reference index designating the reference picture for the block obtained by the motion detection on the reference picture and the determined step An image generation step; and a decoded image generation step of generating a decoded image from the predicted image and the decoded prediction residual.

(27)さらに、本発明による別の画像復号化方法は、前記参照ピクチャが有するピクチャ番号に対し、複数の参照インデックスを割り当てることが可能であり、前記参照ピクチャ指定ステップにおいて復号化された前記参照インデックスを用いて、前記予測画像生成ステップにおける線形予測で用いる係数を決定する。   (27) Further, in another image decoding method according to the present invention, a plurality of reference indexes can be assigned to a picture number of the reference picture, and the reference decoded in the reference picture specifying step A coefficient used in the linear prediction in the predicted image generation step is determined using the index.

(28)さらに、本発明による別の画像復号化方法は、1つのスライスによって参照される複数の参照ピクチャの中に、複数の参照インデックスが割り当てられたピクチャ番号を有する参照ピクチャを少なくとも1つ有することができる。   (28) Furthermore, another image decoding method according to the present invention has at least one reference picture having a picture number to which a plurality of reference indexes are assigned among a plurality of reference pictures referenced by one slice. be able to.

(29)さらに、本発明による別の画像復号化方法における前記参照インデックスは、前記複数の復号化済ピクチャから指定された第1の参照ピクチャを示す第1の参照インデックスと、前記複数の復号化済ピクチャから指定された第2の参照ピクチャを示す第2の参照インデックスとがあり、前記予測画像生成ステップでは、前記ブロックに対して、前記第1の参照インデックスに対応する係数によって線形予測を施すとともに、前記第2の参照インデックスに対応する係数によって線形予測を施し、それぞれの線形予測で得られた2つの予測画像における画素値の平均を求めることによって、前記ブロックに対する最終的な予測画像を生成する。   (29) Furthermore, in another image decoding method according to the present invention, the reference index includes a first reference index indicating a first reference picture designated from the plurality of decoded pictures, and the plurality of decoding And a second reference index indicating a second reference picture designated from the completed picture, and in the predicted image generation step, linear prediction is performed on the block with a coefficient corresponding to the first reference index. In addition, a final prediction image for the block is generated by performing linear prediction using a coefficient corresponding to the second reference index and obtaining an average of pixel values in two prediction images obtained by the respective linear predictions. To do.

(30)さらに、本発明による別の画像復号化方法における前記参照インデックスは、前記複数の復号化済ピクチャから指定された第1の参照ピクチャを示す第1の参照インデックスと、前記複数の復号化済ピクチャから指定された第2の参照ピクチャを示す第2の参照インデックスとがあり、前記予測画像生成ステップにおける前記線形予測で用いる係数の決定は、選択された参照インデックスそれぞれが有する係数の平均によって求められる。   (30) Further, in another image decoding method according to the present invention, the reference index includes a first reference index indicating a first reference picture designated from the plurality of decoded pictures, and the plurality of decoding There is a second reference index indicating a second reference picture designated from the finished picture, and the determination of the coefficient used in the linear prediction in the predicted image generation step is based on the average of the coefficients included in each selected reference index Desired.

(31)さらに、本発明による別の画像復号化方法における前記参照インデックスは、前記複数の復号化済ピクチャから指定された第1の参照ピクチャを示す第1の参照インデックスと、前記複数の復号化済ピクチャから指定された第2の参照ピクチャを示す第2の参照インデックスとがあり、前記第1及び第2の参照インデックスには、複数の係数からなる組が対応づけられ、前記予測画像生成ステップでは、一方の参照インデックスに対応する係数の組のうちの一部と他方の参照インデックスに対応する係数の組の一部とを用いて前記予測画像を生成する。   (31) Further, in another image decoding method according to the present invention, the reference index includes a first reference index indicating a first reference picture designated from the plurality of decoded pictures, and the plurality of decoding There is a second reference index indicating a second reference picture designated from the completed picture, and a set of a plurality of coefficients is associated with the first and second reference indexes, and the predicted image generation step Then, the predicted image is generated by using a part of a set of coefficients corresponding to one reference index and a part of a set of coefficients corresponding to the other reference index.

(32)さらに、本発明による別の画像復号化方法は、前記予測画像生成ステップにおける前記線形予測で用いる計算式は、乗算および除算を使用することなくビットシフト演算および加算および減算のみで構成される。これにより、演算処理の少ない処理のみで線形予測ができる。   (32) Furthermore, in another image decoding method according to the present invention, the calculation formula used in the linear prediction in the predicted image generation step is configured only by bit shift operation and addition and subtraction without using multiplication and division. The As a result, linear prediction can be performed with only a small amount of processing.

(33)さらに、本発明による別の画像復号化方法における前記参照インデックスは、前記複数の復号化済ピクチャから指定された第1の参照ピクチャを示す第1の参照インデックスと、前記複数の復号化済ピクチャから指定された第2の参照ピクチャを示す第2の参照インデックスとがあり、前記予測画像生成ステップでは、前記第1及び第2の参照インデックスに対応する係数の組のうち、前記ビットシフト演算に用いられる係数は前記第1及び第2の参照インデックスのいずれかに対応する係数を選択して使用し、その他の演算に用いられる係数は前記第1及び第2の参照インデックスそれぞれに対応する係数の平均値を使用して前記予測画像を生成する。   (33) Furthermore, in another image decoding method according to the present invention, the reference index includes a first reference index indicating a first reference picture designated from the plurality of decoded pictures, and the plurality of decodings. And a second reference index indicating a second reference picture designated from the completed picture, and in the predicted image generation step, the bit shift is performed among a set of coefficients corresponding to the first and second reference indexes. Coefficients used for calculation select and use coefficients corresponding to one of the first and second reference indexes, and coefficients used for other calculations correspond to the first and second reference indexes, respectively. The predicted image is generated using the average value of the coefficients.

(34)さらに、本発明による別の画像復号化方法において、前記参照インデックスは、前記複数の復号化済ピクチャから指定された第1の参照ピクチャを示す第1の参照インデックスと、前記複数の符号化済フレームから指定された第2の参照フレームを示す第2の参照インデックスとからなり、前記予測画像生成ステップにおける前記線形予測で用いる係数として、線形予測式における直流成分を示す値のみを使用し、第1の参照インデックスおよび第2の参照インデックスそれぞれに1つずつ対応付けられる。   (34) Furthermore, in another image decoding method according to the present invention, the reference index includes a first reference index indicating a first reference picture designated from the plurality of decoded pictures, and the plurality of codes. A second reference index indicating a second reference frame designated from the converted frame, and only a value indicating a DC component in the linear prediction formula is used as a coefficient used in the linear prediction in the predicted image generation step. , One for each of the first reference index and the second reference index.

(35)さらに、本発明による別の画像復号化方法において、符号化対象ピクチャ上のブロックに対して動き補償を行うときに参照する、記憶部に格納されている複数の符号化済ピクチャから任意に選択された、参照ピクチャを示す参照インデックスと、前記ピクチャ番号とを対応付けるコマンドであって、複数の参照インデックスが同一のピクチャを参照することが可能であるコマンドと、前記参照インデックスと、予測残差の符号化信号とを有する画像符号化信号を復号化する第1のステップと、復号化された前記コマンドと、復号化された前記参照インデックスとにより、復号化対象ピクチャ上のブロックに対して動き補償を行うときに参照する参照ピクチャを決定する参照ピクチャ指定ステップと、決定された前記参照ピクチャ上の動き検出により得られたブロックに対して、各参照ピクチャの持つ表示順情報から係数を生成し、前記係数を用いた線形予測を施すことにより予測画像を生成する予測画像生成ステップと、前記予測画像と復号化された予測残差とから復号画像を生成する復号画像生成ステップとを有する。   (35) Furthermore, in another image decoding method according to the present invention, an arbitrary one of a plurality of encoded pictures stored in the storage unit, which is referred to when motion compensation is performed on a block on an encoding target picture. A command for associating a selected reference index indicating a reference picture with the picture number, a command in which a plurality of reference indexes can refer to the same picture, the reference index, and a prediction residual For a block on a picture to be decoded by a first step of decoding an image encoded signal having a difference encoded signal, the decoded command, and the decoded reference index A reference picture designation step for determining a reference picture to be referred to when performing motion compensation, and on the determined reference picture A prediction image generating step for generating a coefficient from the display order information of each reference picture and generating a prediction image by performing linear prediction using the coefficient for the block obtained by the detection, and the prediction image And a decoded image generation step of generating a decoded image from the decoded prediction residual.

(36)前記予測画像生成ステップにおける前記線形予測を行う方法として、前記表示順情報によって生成される係数を用いた方法と、予め設定された固定式を用いた方法とを、第1の参照インデックスによって指定される参照ピクチャおよび第2の参照インデックスによって指定される参照ピクチャの各々の持つ表示順情報の前後関係によって切り替えて使用する。   (36) As a method for performing the linear prediction in the predicted image generation step, a method using a coefficient generated by the display order information and a method using a preset fixed formula are referred to as a first reference index. The reference picture designated by the second reference index and the reference picture designated by the second reference index are used by switching according to the order of display order information.

(37)さらに、本発明による別の画像復号化方法において、前記予測画像生成ステップにおける前記線形予測を行う方法として、前記表示順情報によって生成される係数を用いた方法を使用した際に、第1の参照インデックスによって指定される参照ピクチャおよび第2の参照インデックスによって指定される参照ピクチャとが同じ表示順情報をもつ場合は、予め設定された係数を代わりに用いて線形予測を行う。   (37) Furthermore, in another image decoding method according to the present invention, when a method using coefficients generated by the display order information is used as a method for performing the linear prediction in the predicted image generation step, When the reference picture specified by the reference index 1 and the reference picture specified by the second reference index have the same display order information, linear prediction is performed using a preset coefficient instead.

(38)さらに、本発明による別の画像復号化方法において、前記予測画像生成ステップにおいて、前記表示順情報を用いて係数を生成する際に、前記線形予測が乗算および除算を使用することなくビットシフト演算および加算および減算のみで行えるように、前記係数を2のべき乗に近似する。   (38) Further, in another image decoding method according to the present invention, when generating a coefficient using the display order information in the predicted image generation step, the linear prediction uses a bit without using multiplication and division. The coefficient is approximated to a power of 2 so that only shift operation and addition and subtraction can be performed.

(39)さらに、本発明による別の画像復号化方法において、前記近似を行う際に、第1の参照インデックスによって指定される参照ピクチャおよび第2の参照インデックスによって指定される参照ピクチャの各々の持つ表示順情報の前後関係によって、切り上げによる近似と切り下げによる近似とを切り替えて使用する。   (39) Furthermore, in another image decoding method according to the present invention, each of the reference picture specified by the first reference index and the reference picture specified by the second reference index is used when performing the approximation. Depending on the order of display order information, the approximation by rounding up and the approximation by rounding down are used.

(40)本発明のプログラムは、上記(26)〜(39)の何れかに記載の画像符復号化方法をコンピュータに実行させる構成としてもよい。   (40) The program of the present invention may be configured to cause a computer to execute the image codec decoding method described in any of (26) to (39) above.

以上の様に、本発明の動画像符号化方法および復号化方法により、予測画像を生成する際の線形予測に用いられる重み付け係数セットの候補を複数作成できるようになり、ブロックごとに最適なものを選択することが可能となった。その結果、複数の参照インデックスが割り当てられている場合であっても、1つの参照インデックスが割り当てられている場合であっても、参照インデックスの復号化を効率よく行うことができる。また、大きな符号化効率の向上が実現可能となることから、動画像の符号化および復号化において非常に有効である。   As described above, the moving image encoding method and decoding method according to the present invention can create a plurality of candidates for weighting coefficient sets used for linear prediction when generating a predicted image, which is optimal for each block. It became possible to select. As a result, it is possible to efficiently decode the reference index even when a plurality of reference indexes are assigned or when one reference index is assigned. Further, since a large improvement in encoding efficiency can be realized, it is very effective in encoding and decoding moving images.

以上の様に、本発明の動画像符号化方法および復号化方法により、予測画像を生成する際の線形予測に用いられる重み付け係数セットの候補を複数作成できるようになり、ブロックごとに最適なものを選択することが可能となった。その結果、複数の参照インデックスが割り当てられている場合であっても、1つの参照インデックスが割り当てられている場合であっても、参照インデックスの復号化を効率よく行うことができる。また、大きな符号化効率の向上が実現可能となることから、動画像の符号化および復号化において非常に有効である。   As described above, the moving image encoding method and decoding method according to the present invention can create a plurality of candidates for weighting coefficient sets used for linear prediction when generating a predicted image, which is optimal for each block. It became possible to select. As a result, it is possible to efficiently decode the reference index even when a plurality of reference indexes are assigned or when one reference index is assigned. Further, since a large improvement in encoding efficiency can be realized, it is very effective in encoding and decoding moving images.

(実施の形態1)
図1は、本発明の実施の形態1における動画像符号化装置の構成を示すブロック図である。この動画像符号化装置における動画像符号化方法を図1に示したブロック図を用いて(1)符号化の概要、(2)参照インデックス割り当て方法、(3)予測画像生成方法の順で説明する。
(Embodiment 1)
FIG. 1 is a block diagram showing a configuration of a moving picture coding apparatus according to Embodiment 1 of the present invention. The moving picture coding method in this moving picture coding apparatus will be described in the order of (1) the outline of coding, (2) the reference index assignment method, and (3) the predicted picture generation method, using the block diagram shown in FIG. To do.

(1)符号化の概要
符号化対象となる動画像は表示を行う順にピクチャ単位でピクチャメモリ101に入力され、符号化を行う順にピクチャの並び替えを行う。図31は並び替えの例を示した図である。図31(a)は表示される順に並べられたピクチャであり、図31(b)は符号化を行う順に並び替えたピクチャの例である。ここでのB3、B6は時間的に前方および後方の両方を参照しているため、これらのピクチャを符号化する前に参照の対象となるピクチャを先に符号化する必要があることから、図31(b)ではP4、P7が先に符号化されるように並び替えられている。さらに各々のピクチャはマクロブロックと呼ばれる例えば水平16×垂直16画素のブロックに分割されブロック単位で以降の処理が行われる。
(1) Outline of Encoding A moving image to be encoded is input to the picture memory 101 in picture-by-picture order and rearranged pictures in the order of encoding. FIG. 31 shows an example of rearrangement. FIG. 31A shows pictures arranged in the order of display, and FIG. 31B shows an example of pictures rearranged in the order of encoding. Since B3 and B6 here refer to both forward and backward in time, it is necessary to encode the picture to be referenced first before encoding these pictures. In 31 (b), P4 and P7 are rearranged so that they are encoded first. Further, each picture is divided into blocks each called a macroblock, for example, horizontal 16 × vertical 16 pixels, and subsequent processing is performed in units of blocks.

ピクチャメモリ101から読み出された入力画像信号は差分演算部112に入力され、動き補償符号化部107の出力である予測画像信号との差分を取ることによって得られる差分画像信号を予測残差符号化部102に出力する。予測残差符号化部102では周波数変換、量子化等の画像符号化処理を行い残差符号化信号を出力する。残差符号化信号は予測残差復号化部104に入力され、逆量子化、逆周波数変換等の画像復号化処理を行い残差復号化信号を出力する。加算演算部113では前記残差復号化信号と予測画像信号との加算を行い再構成画像信号を生成し、得られた再構成画像信号の中で以降の画面間予測で参照される可能性がある信号をピクチャメモリ105に格納する。   The input image signal read from the picture memory 101 is input to the difference calculation unit 112, and the difference image signal obtained by taking the difference from the prediction image signal output from the motion compensation encoding unit 107 is converted into a prediction residual code. To the conversion unit 102. The prediction residual encoding unit 102 performs image encoding processing such as frequency conversion and quantization, and outputs a residual encoded signal. The residual encoded signal is input to the prediction residual decoding unit 104, performs image decoding processing such as inverse quantization and inverse frequency transform, and outputs a residual decoded signal. The addition operation unit 113 adds the residual decoded signal and the predicted image signal to generate a reconstructed image signal, and may be referred to in subsequent inter-screen prediction in the obtained reconstructed image signal. A certain signal is stored in the picture memory 105.

一方、ピクチャメモリ101から読み出されたマクロブロック単位の入力画像信号は動
きベクトル検出部106にも入力される。ここでは、ピクチャメモリ105に格納されている再構成画像信号を探索対象とし、最も入力画像信号に近い画像領域を検出することによってその位置を指し示す動きベクトルを決定する。動きベクトル検出はマクロブロックをさらに分割したブロック単位で行われ、得られた動きベクトルは動きベクトル記憶部108に格納される。
On the other hand, the input image signal for each macroblock read from the picture memory 101 is also input to the motion vector detection unit 106. Here, the reconstructed image signal stored in the picture memory 105 is set as a search target, and the motion vector indicating the position is determined by detecting the image region closest to the input image signal. The motion vector detection is performed in units of blocks obtained by further dividing the macroblock, and the obtained motion vector is stored in the motion vector storage unit 108.

このとき、現在標準化中のH.26Lでは複数のピクチャを参照対象として使用することができるため、参照するピクチャを指定するための識別番号がブロックごとに必要となる。その識別番号を参照インデックスと呼び、参照インデックス・ピクチャ番号変換部111において、ピクチャメモリ105中のピクチャの持つピクチャ番号との対応を取ることにより参照ピクチャを指定することが可能となる。参照インデックス・ピクチャ番号変換部111における動作の詳細は(2)において詳しく説明する。   At this time, H. In 26L, a plurality of pictures can be used as reference objects, and therefore an identification number for designating a picture to be referenced is required for each block. The identification number is called a reference index, and the reference index / picture number conversion unit 111 can designate a reference picture by taking a correspondence with a picture number of a picture in the picture memory 105. Details of the operation of the reference index / picture number conversion unit 111 will be described in detail in (2).

動き補償符号化部107では、上記処理によって検出された動きベクトルおよび参照インデックスを用いて、ピクチャメモリ105に格納されている再構成画像信号から予測画像に最適な画像領域を取り出す。得られた画像領域の画素値に対して線形予測による補間処理等の画素値変換処理を施すことによって最終的な予測画像とする。その際に使用する線形予測係数は線形予測係数生成部110によって生成され線形予測係数記憶部109に格納される。この予測画像生成方法については(3)において詳しく説明する。   The motion compensation encoding unit 107 uses the motion vector detected by the above process and the reference index to extract an image region that is optimal for the predicted image from the reconstructed image signal stored in the picture memory 105. The pixel value of the obtained image region is subjected to pixel value conversion processing such as interpolation processing by linear prediction to obtain a final predicted image. The linear prediction coefficient used at that time is generated by the linear prediction coefficient generation unit 110 and stored in the linear prediction coefficient storage unit 109. This predicted image generation method will be described in detail in (3).

上記の一連の処理によって出力された線形予測係数、参照インデックス、動きベクトル、残差符号化信号等の符号化情報に対して符号列生成部103において可変長符号化を施すことにより、この符号化装置が出力する符号列が得られる。   This encoding is performed by performing variable-length encoding in the code sequence generation unit 103 on the encoded information such as the linear prediction coefficient, reference index, motion vector, and residual encoded signal output by the above series of processing. A code string output by the apparatus is obtained.

以上の処理の流れは画面間予測符号化を行った場合の動作であったが、スイッチ114およびスイッチ115によって画面内予測符号化との切り替えがなされる。画面内符号化を行う場合は、動き補償による予測画像の生成は行わず、同一画面内の符号化済み領域から符号化対象領域の予測画像を生成し差分を取ることによって差分画像信号を生成する。差分画像信号は画面間予測符号化の場合と同様に、予測残差符号化部102において残差符号化信号に変換され、符号列生成部103において可変長符号化を施されることにより出力される符号列が得られる。   The above processing flow is an operation in the case of performing inter-screen predictive coding, but switching to intra-screen predictive coding is performed by the switch 114 and the switch 115. When performing intra-screen coding, a prediction image is not generated by motion compensation, and a difference image signal is generated by generating a prediction image of an encoding target region from an encoded region in the same screen and taking a difference. . Similar to the case of inter-picture predictive coding, the difference image signal is converted into a residual coded signal by the prediction residual coding unit 102 and output by being subjected to variable length coding by the code string generating unit 103. A code string is obtained.

(2)参照インデックス割り当て方法
次に、図1の参照インデックス・ピクチャ番号変換部111における参照インデックス割り当て方法について図3、図4を用いて説明する。
(2) Reference Index Assignment Method Next, a reference index assignment method in the reference index / picture number conversion unit 111 of FIG. 1 will be described with reference to FIGS.

図3は、ピクチャ番号に対する2つの参照インデックスの割り当て方法を説明するための図である。図のような表示される順に並べられたピクチャ列があったとき、ピクチャ番号は符号化される順番に割り振られている。参照インデックスをピクチャ番号に割り当てるためのコマンドはピクチャをさらに分割した符号化単位であるスライスのヘッダに記述され、1つのスライスを符号化する毎に割り振り方が更新されることになる。前記コマンドは、直前に参照インデックスに割り当てたピクチャ番号と現在割り当てを行っているピクチャ番号との差分値を参照インデックスの数だけ連続して指示するものである。   FIG. 3 is a diagram for explaining a method of assigning two reference indexes to picture numbers. When there are picture sequences arranged in the order of display as shown in the figure, picture numbers are assigned in the order of encoding. A command for assigning a reference index to a picture number is described in a header of a slice, which is an encoding unit obtained by further dividing a picture, and the allocation method is updated every time one slice is encoded. The command sequentially indicates the difference value between the picture number assigned to the reference index immediately before and the picture number currently assigned by the number of reference indexes.

図3の第1参照インデックスの例を用いると、まずコマンドとして"−1"が与えられたので、現在符号化の対象としているピクチャ番号16番から1を引くことにより、ピクチャ番号15番が参照インデックス0番に割り当てられる。次に"−4"が与えられたので、直前に割り当てを行ったピクチャ番号15番から4を引くことにより、ピクチャ番号11番が参照インデックス1番に割り当てられる。以下同様の処理によって各ピクチャ番号の割り当てが行われる。第2参照インデックスの場合も同様である。   When the example of the first reference index in FIG. 3 is used, since “−1” is first given as a command, picture number 15 is referenced by subtracting 1 from picture number 16 currently being encoded. Assigned to index number 0. Next, since “−4” is given, the picture number 11 is assigned to the reference index 1 by subtracting 4 from the picture number 15 assigned immediately before. Thereafter, each picture number is assigned by the same process. The same applies to the second reference index.

図34に示した従来の方法による参照インデックス割り当て方法では、全ての参照インデックスはそれぞれ別々のピクチャ番号に対応付けられている。一方、図3の例では、割り当て方法は従来のものと全く同じ方法を用いているが、コマンドの値を変更することにより同じピクチャ番号に対して複数の参照インデックス番号が対応付けられている。   In the reference index assignment method according to the conventional method shown in FIG. 34, all reference indexes are associated with different picture numbers. On the other hand, in the example of FIG. 3, although the allocation method is exactly the same as the conventional one, a plurality of reference index numbers are associated with the same picture number by changing the command value.

図4は参照インデックスの割り当てを行った結果を示したものである。各ピクチャ番号には第1参照インデックスおよび第2参照インデックスがそれぞれ独立に割り当てられているが、1つのピクチャ番号に対して複数の参照インデックスが割り当てられているものもあることが分かる。本発明の符号化方法では、この例のように複数の参照インデックスが割り当てられているピクチャ番号が少なくとも1つ以上あるものとする。   FIG. 4 shows the result of assigning a reference index. The first reference index and the second reference index are independently assigned to each picture number, but it can be seen that there are some where a plurality of reference indexes are assigned to one picture number. In the encoding method of the present invention, it is assumed that there are at least one picture number to which a plurality of reference indexes are assigned as in this example.

参照インデックスを参照ピクチャの決定のみに使用する場合であれば、従来の方法のように1つのピクチャ番号に対して1つの参照インデックスを割り当てる方法が最も符号化効率の良い方法である。しかし、参照インデックスを使用して予測画像の生成における線形予測係数の重み付け係数セットを選択する場合は、従来の方法では同じ参照ピクチャを持つブロック全てにおいて同じ線形予測係数を使用しなくてはならないため、最適な予測画像が生成されない可能性が非常に高くなってしまう。   If the reference index is used only for determining the reference picture, a method of assigning one reference index to one picture number as in the conventional method is the method with the highest coding efficiency. However, when using a reference index to select a weighting coefficient set of linear prediction coefficients in generating a predicted image, the conventional method must use the same linear prediction coefficient in all blocks having the same reference picture. Therefore, there is a very high possibility that an optimal predicted image will not be generated.

そこで、本発明のように1つのピクチャ番号に対して複数の参照インデックスが割り当てることを可能とすることにより、同じ参照ピクチャを持つ場合でも、ブロックごとに複数の線形予測係数の重み付け係数セットの候補の中から最適なものを選択することが可能となり、より符号化効率の高い予測画像を生成することが可能となる。   Therefore, by allowing a plurality of reference indexes to be assigned to one picture number as in the present invention, a plurality of linear prediction coefficient weighting coefficient set candidates for each block even when having the same reference picture It is possible to select an optimal image from among the images, and it is possible to generate a predicted image with higher encoding efficiency.

なお、以上の説明では全ての参照ピクチャが参照用メモリに蓄積されるものとしてピクチャ番号が与えられている場合の例を示していたが、ピクチャ番号は符号化を行った直前のピクチャが蓄積された場合のみ、当該ピクチャに値が1つ増加したピクチャ番号が付与されていくものであり、蓄積されないピクチャがあった場合でも参照用メモリ内ではピクチャ番号の連続性は保たれ、前記方法をそのまま使用することが可能である。   In the above description, an example is shown in which a picture number is given assuming that all reference pictures are stored in the reference memory, but the picture number immediately before encoding is stored. Only when the picture number is incremented by one, the picture number continuity is maintained in the reference memory even if there is a picture that is not stored. It is possible to use.

(3)予測画像生成方法
次に、図1の動き補償符号化部107における予測画像生成方法について図5を用いて説明する。線形予測による予測画像生成方法は従来法と全く同様であるが、同じピクチャに対して複数の参照インデックス番号を対応付けることが可能となったため、線形予測係数を選択する際の自由度が高くなっている。
(3) Prediction Image Generation Method Next, a prediction image generation method in the motion compensation encoding unit 107 in FIG. 1 will be described with reference to FIG. The prediction image generation method by linear prediction is exactly the same as the conventional method, but since it is possible to associate a plurality of reference index numbers with the same picture, the degree of freedom in selecting a linear prediction coefficient is increased. Yes.

ピクチャB16は現在符号化の対象としているBピクチャであり、ブロックBL01およびブロックBL02は前記Bピクチャに属する符号化対象のブロックである。BL01は第1参照ピクチャをピクチャP11、第2参照ピクチャをピクチャB15とし、それぞれのピクチャに属するブロックBL11およびBL21を参照して予測画像を作成する。同様にBL02も第1参照ピクチャをピクチャP11、第2参照ピクチャをピクチャB15とし、それぞれのピクチャに属するブロックBL12およびBL22を参照して予測画像を作成する。   A picture B16 is a B picture currently being encoded, and a block BL01 and a block BL02 are blocks to be encoded belonging to the B picture. In BL01, the first reference picture is the picture P11, the second reference picture is the picture B15, and the prediction picture is created by referring to the blocks BL11 and BL21 belonging to the respective pictures. Similarly, BL02 also uses the first reference picture as the picture P11 and the second reference picture as the picture B15, and creates a predicted image by referring to the blocks BL12 and BL22 belonging to the respective pictures.

第1参照ピクチャおよび第2参照ピクチャはBL01、BL02共に同じものを参照しているが、(2)において説明した参照インデックスの割り当て方法を用いることにより、第1参照インデックスref1および第2参照インデックスref2はBL01とBL02とで異なる値を取ることが可能となる。図4を例にとると、ピクチャ番号11に対応する第1参照インデックスは1と3が、ピクチャ番号15に対応する第2参照インデックスは1と6が割り振られている。   The first reference picture and the second reference picture both refer to the same BL01 and BL02, but by using the reference index assignment method described in (2), the first reference index ref1 and the second reference index ref2 Can take different values for BL01 and BL02. Taking FIG. 4 as an example, 1 and 3 are assigned to the first reference index corresponding to picture number 11, and 1 and 6 are assigned to the second reference index corresponding to picture number 15.

その結果、これらの参照インデックスの組み合わせは、(ref1、ref2)=(1、1)、(1、6)、(3、1)、(3、6)の4通りが考えられ、これらの中から最適な重み付け係数セットを導き出す組み合わせをブロックごとに選択することが可能となっている。図5では例としてBL01がref1=1、ref2=1、BL02がref1=3、ref2=6としている。   As a result, there are four possible combinations of these reference indexes: (ref1, ref2) = (1, 1), (1, 6), (3, 1), (3, 6). It is possible to select a combination for deriving an optimal weighting coefficient set from each block. In FIG. 5, for example, BL01 is ref1 = 1, ref2 = 1, and BL02 is ref1 = 3 and ref2 = 6.

図35にあるような従来の方法によって対応付けられた参照インデックスの組み合わせでは、図5のような例ではBL01、BL02共に(ref1、ref2)=(1、1)の組み合わせしか選択できなかったため、選択することのできる線形予測係数の重み付け係数セットも1通りしかなかった。一方、本発明では選択範囲が4通りに拡張されているため、最適な重み付け係数セットが選択できる可能性が高くなると言える。   In the combination of reference indexes associated by the conventional method as shown in FIG. 35, only the combination of (ref1, ref2) = (1, 1) can be selected for both BL01 and BL02 in the example shown in FIG. There was also only one set of linear prediction coefficient weighting coefficients that could be selected. On the other hand, in the present invention, since the selection range is expanded in four ways, it can be said that there is a high possibility that an optimum weighting coefficient set can be selected.

1つのピクチャの符号列は、ピクチャ共通情報領域および複数のスライスデータ領域から構成される。図6はそのうちのスライスデータ領域の構成を示したものである。さらにスライスデータ領域は、スライスヘッダ領域および複数のブロックデータ領域から構成される。ここではブロックデータ領域の例として図5におけるBL01、BL02に対応する各ブロックの領域が示されている。BL01に含まれるref1およびref2はこのブロックが参照する2枚のピクチャを指し示す第1参照インデックスおよび第2参照インデックスをそれぞれ指示するものである。   The code string of one picture is composed of a picture common information area and a plurality of slice data areas. FIG. 6 shows the structure of the slice data area. Furthermore, the slice data area includes a slice header area and a plurality of block data areas. Here, as an example of the block data area, the area of each block corresponding to BL01 and BL02 in FIG. 5 is shown. Ref1 and ref2 included in BL01 respectively indicate a first reference index and a second reference index indicating two pictures referred to by this block.

またスライスヘッダ領域には前記線形予測を行うための重み付け係数セットを与えるためのデータ(pset0、pset1、pset2、・・・・)がref1用およびref2用それぞれに記述されている。このときのpsetは(2)で説明した参照インデックスの個数と同じで数だけ設定することができる。つまり、図3のように第1参照インデックス、第2参照インデックスを共に0から9までの10個を使用した場合は、psetもref1用、ref2用共に0から9までの10個を設定することが可能である。   In the slice header area, data (pset0, pset1, pset2,...) For giving a weighting coefficient set for performing the linear prediction is described for ref1 and ref2. The number of psets at this time is the same as the number of reference indexes described in (2), and can be set by the number. In other words, when 10 of the first reference index and the second reference index are used from 0 to 9 as shown in FIG. 3, 10 is set from 0 to 9 for both ref1 and ref2. Is possible.

図7は前記スライスヘッダ領域に含まれる前記重み付け係数セットの例を表に示したものである。識別子psetで示された各々のデータはw1、w2、c、dの4つ値を持ち、ref1およびref2の値によってダイレクトに参照できるように構成されている。また、スライスヘッダ領域には前記参照インデックスをピクチャ番号に割り当てるためのコマンド列idx_cmd1およびidx_cmd2が記述されている。   FIG. 7 is a table showing an example of the weighting coefficient set included in the slice header area. Each data indicated by the identifier pset has four values w1, w2, c, and d, and is configured so that it can be directly referred to by the values of ref1 and ref2. In the slice header area, command strings idx_cmd1 and idx_cmd2 for assigning the reference index to the picture number are described.

図6のBL01に記述されたref1およびref2によって図7のref1用およびref2用のテーブルからそれぞれ1組の重み付け係数セットが選択される。この2組の重み付け係数セットを用いて参照画像の画素値に対して線形予測を施すことによって予測画像を生成する。   One set of weighting coefficients is selected from the tables for ref1 and ref2 in FIG. 7 by ref1 and ref2 described in BL01 in FIG. A prediction image is generated by performing linear prediction on the pixel value of the reference image using the two sets of weighting coefficient sets.

このように1つのピクチャ番号に対して複数の参照インデックスが割り当てる符号化方法を用いることにより、線形予測係数の重み付け係数セットの候補を複数作成できるようになり、その中から最適なものを選択することが可能となる。たとえば、第1参照インデックスが2つ、第2参照インデックスが2つ割り当てられていた場合は4通りの重み付け係数セットを選択の候補とすることができ、第1参照インデックスが3つ、第2参照インデックスが3つ割り当てられていた場合は9通りの重み付け係数セットを選択の候補とすることができる。   As described above, by using an encoding method in which a plurality of reference indexes are assigned to one picture number, a plurality of weighted coefficient set candidates for linear prediction coefficients can be created, and an optimum one is selected from them. It becomes possible. For example, when two first reference indexes and two second reference indexes are assigned, four weighting coefficient sets can be selected as candidates for selection, three first reference indexes, and second reference When three indexes are allocated, nine weighting coefficient sets can be selected as selection candidates.

この線形予測という方法はフェードやフラッシュのように画面全体もしくは一部分の明度が大きく変化するような場合に特に大きな効果が得られる。多くの場合、その明度の変化の度合いは画面の部分部分によって異なる。そのため、本発明のように複数の重み付け係数セットの中からブロックごとに最適なものを選択できるような構成を持つことは画像の符号化において非常に有効である。   This method of linear prediction is particularly effective when the brightness of the entire screen or a part of the screen changes greatly, such as fade and flash. In many cases, the degree of change in brightness varies depending on the portion of the screen. For this reason, it is very effective in coding an image to have a configuration in which an optimum one can be selected for each block from a plurality of weighting coefficient sets as in the present invention.

ここで、重み付け係数セットを決定し予測画像を生成するまでの処理の流れについて詳細に説明する。   Here, the flow of processing from determination of a weighting coefficient set to generation of a predicted image will be described in detail.

図8は、図1の線形予測係数生成部110、線形予測係数記憶部109、および動き補償符号化部107における予測画像を生成する機能構成を示した機能ブロック図である。   FIG. 8 is a functional block diagram illustrating a functional configuration for generating a prediction image in the linear prediction coefficient generation unit 110, the linear prediction coefficient storage unit 109, and the motion compensation encoding unit 107 in FIG.

線形予測係数生成部110、線形予測係数記憶部109a、線形予測係数記憶部109b、平均値算出部107a、および線形予測演算部107bにより予測画像が生成される。   A prediction image is generated by the linear prediction coefficient generation unit 110, the linear prediction coefficient storage unit 109a, the linear prediction coefficient storage unit 109b, the average value calculation unit 107a, and the linear prediction calculation unit 107b.

線形予測係数生成部110によって生成された重み付け係数セットは線形予測係数記憶部109aおよび線形予測係数記憶部109bに格納されている。平均値算出部107aは、動き検出の処理によって決定された第1参照インデックスref1によって選択される1組の重み付け係数セット(w1_1,w2_1,c_1,d_1)を線形予測係数記憶部109aより獲得し、同様に第2参照インデックスref2によって選択される1組の重み付け係数セット(w1_2,w2_2,c_2,d_2)を線形予測係数記憶部109bより獲得する。   The weighting coefficient set generated by the linear prediction coefficient generation unit 110 is stored in the linear prediction coefficient storage unit 109a and the linear prediction coefficient storage unit 109b. The average value calculation unit 107a obtains a set of weighting coefficients (w1_1, w2_1, c_1, d_1) selected by the first reference index ref1 determined by the motion detection process from the linear prediction coefficient storage unit 109a, Similarly, one set of weighting coefficient sets (w1_2, w2_2, c_2, d_2) selected by the second reference index ref2 is acquired from the linear prediction coefficient storage unit 109b.

そして平均値算出部107aは、線形予測係数記憶部109a、109bより獲得したそれぞれの重み付け係数セットのパラメータごとの平均を取り、実際に線形予測に使用する重み付け係数セット(w1,w2,c,d)とし、線形予測演算部107bに出力する。線形予測演算部107bは、得られた重み付け係数セット(w1,w2,c,d)を基に、式1を用いて予測画像を演算し出力する。   Then, the average value calculation unit 107a takes the average for each parameter of the respective weighting coefficient sets acquired from the linear prediction coefficient storage units 109a and 109b, and actually sets the weighting coefficient sets (w1, w2, c, d) used for the linear prediction. ) And output to the linear prediction calculation unit 107b. Based on the obtained weighting coefficient set (w1, w2, c, d), the linear prediction calculation unit 107b calculates and outputs a prediction image using Expression 1.

また、図9は予測画像を生成する他の機能構成を示す機能ブロック図である。線形予測係数生成部110、線形予測係数記憶部109a、線形予測係数記憶部109b、線形予測演算部107c、線形予測演算部107d、および平均値算出部107eにより、予測画像が生成される。   FIG. 9 is a functional block diagram showing another functional configuration for generating a predicted image. A prediction image is generated by the linear prediction coefficient generation unit 110, the linear prediction coefficient storage unit 109a, the linear prediction coefficient storage unit 109b, the linear prediction calculation unit 107c, the linear prediction calculation unit 107d, and the average value calculation unit 107e.

線形予測係数生成部110によって生成された重み付け係数セットは線形予測係数記憶部109aおよび線形予測係数記憶部109bに格納されている。線形予測演算部107cは、動き検出の処理によって決定された第1参照インデックスref1によって選択される1組の重み付け係数セット(w1_1,w2_1,c_1,d_1)を線形予測係数記憶部109aより獲得し、その重み付け係数セットを基に、式1を用いて予測画像を演算して平均値算出部107eに出力する。   The weighting coefficient set generated by the linear prediction coefficient generation unit 110 is stored in the linear prediction coefficient storage unit 109a and the linear prediction coefficient storage unit 109b. The linear prediction calculation unit 107c acquires from the linear prediction coefficient storage unit 109a one set of weighting coefficient sets (w1_1, w2_1, c_1, d_1) selected by the first reference index ref1 determined by the motion detection process, Based on the weighting coefficient set, a prediction image is calculated using Equation 1 and output to the average value calculation unit 107e.

同様に、線形予測演算部107dは、動き検出の処理によって決定された第2参照インデックスref2を基に選択される1組の重み付け係数セット(w1_2,w2_2,c_2,d_2)を線形予測係数記憶部109bより獲得し、その重み付け係数セットを基に式1を用いて予測画像を演算して平均値算出部107eに出力する。   Similarly, the linear prediction calculation unit 107d generates a set of weighting coefficient sets (w1_2, w2_2, c_2, d_2) selected based on the second reference index ref2 determined by the motion detection process as a linear prediction coefficient storage unit. 109b, and based on the weighting coefficient set, the prediction image is calculated using Equation 1 and output to the average value calculation unit 107e.

平均値算出部107eは、線形予測演算部107c,線形予測演算部107dのそれぞれから出力される予測画像の各画素の平均値をとり、最終的な予測画像を生成し出力する。   The average value calculation unit 107e takes the average value of each pixel of the prediction image output from each of the linear prediction calculation unit 107c and the linear prediction calculation unit 107d, and generates and outputs a final prediction image.

図10(a)は、予測画像を生成する他の機能構成を示す機能ブロック図である。線形予測係数生成部110、線形予測係数記憶部109c、線形予測係数記憶部109d、平均値算出部107f,線形予測演算部107gにより予測画像が生成される。   FIG. 10A is a functional block diagram showing another functional configuration for generating a predicted image. A prediction image is generated by the linear prediction coefficient generation unit 110, the linear prediction coefficient storage unit 109c, the linear prediction coefficient storage unit 109d, the average value calculation unit 107f, and the linear prediction calculation unit 107g.

線形予測係数生成部110によって生成された重み付け係数セットは線形予測係数記憶部109cおよび線形予測係数記憶部109dに格納されている。平均値算出部107fは、動き検出の処理によって決定された第1参照インデックスref1によって選択される1組の重み付け係数セット(w1_1、w2_1,c_1,d_1)のうち、c_1,d_1のパラメータを線形予測係数記憶部109cより獲得し、同様に第2参照インデッ
クスref2によって選択される1組の重み付け係数セット(w1_2、w2_2,c_2,d_2)のうち、c_2,d_2のパラメータを線形予測係数記憶部109dより獲得する。平均値算出部107fは、線形予測係数記憶部109cおよび線形予測係数記憶部109dより獲得したc_1とc_2の平均値と、d_1とd_2の平均値を算出してc、dを求め線形予測演算部107gに出力する。
The weighting coefficient set generated by the linear prediction coefficient generation unit 110 is stored in the linear prediction coefficient storage unit 109c and the linear prediction coefficient storage unit 109d. The average value calculation unit 107f performs linear prediction on the parameters c_1 and d_1 out of one set of weighting coefficient sets (w1_1, w2_1, c_1, d_1) selected by the first reference index ref1 determined by the motion detection process. Of the set of weighting coefficients (w1_2, w2_2, c_2, d_2) obtained from the coefficient storage unit 109c and similarly selected by the second reference index ref2, the parameters c_2 and d_2 are obtained from the linear prediction coefficient storage unit 109d. To win. The average value calculation unit 107f calculates the average value of c_1 and c_2 acquired from the linear prediction coefficient storage unit 109c and the linear prediction coefficient storage unit 109d, and the average value of d_1 and d_2, and obtains c and d. Output to 107g.

また、線形予測演算部107gは、上記重み付け係数セット(w1_1、w2_1,c_1,d_1)のうち、w1_1のパラメータを線形予測係数記憶部109cより獲得し、上記重み付け係数セット(w1_2、w2_2,c_2,d_2)のうち、w2_2のパラメータを線形予測係数記憶部109dより獲得し、平均値算出部107fによりそれぞれの平均を求めてc、dを獲得し、式1を用いて予測画像を演算し出力する。   In addition, the linear prediction calculation unit 107g acquires the parameter of w1_1 from the linear prediction coefficient storage unit 109c among the weighting coefficient sets (w1_1, w2_1, c_1, d_1), and obtains the weighting coefficient sets (w1_2, w2_2, c_2, c_2). Among the parameters d_2), the w2_2 parameter is acquired from the linear prediction coefficient storage unit 109d, the respective averages are obtained by the average value calculation unit 107f, c and d are acquired, and the prediction image is calculated using Equation 1 and output. .

すなわち、線形予測演算部107gは、線形予測係数記憶部109cより得られた重み付け係数セット(w1_1、w2_1,c_1,d_1)と、線形予測係数記憶部109dより得られた重み付け係数セット(w1_2、w2_2,c_2,d_2)のうち、実際に線形予測で使用する重み付け係数セット(w1、w2,c,d)を決定する際に、下記の規則を用いている。   That is, the linear prediction calculation unit 107g includes the weighting coefficient set (w1_1, w2_1, c_1, d_1) obtained from the linear prediction coefficient storage unit 109c and the weighting coefficient set (w1_2, w2_2) obtained from the linear prediction coefficient storage unit 109d. , C_2, d_2), the following rules are used when determining the weighting coefficient set (w1, w2, c, d) actually used in the linear prediction.

w1=w1_1,w2=w2_2,c=(c_1とc_2の平均),d=(d_1とd_2の平均)   w1 = w1_1, w2 = w2_2, c = (average of c_1 and c_2), d = (average of d_1 and d_2)

このように図10(a)で説明した予測画像の生成においては、線形予測係数記憶部109cは重み付け係数セットのうちw2_1を必要としない。そのため、ref1用の重み付け係数セットにw2は必要でない。よって符号列を小さくすることも可能である。   As described above, in the generation of the prediction image described with reference to FIG. 10A, the linear prediction coefficient storage unit 109c does not need w2_1 in the weighting coefficient set. Therefore, w2 is not necessary for the weighting coefficient set for ref1. Therefore, the code string can be reduced.

また、線形予測係数記憶部109dは重み付け係数セットのうちw1_2を必要としない。そのため、ref2用の重み付け係数セットにw1は必要でない。よって符号列を小さくすることも可能である。   Further, the linear prediction coefficient storage unit 109d does not need w1_2 in the weighting coefficient set. Therefore, w1 is not necessary for the weighting coefficient set for ref2. Therefore, the code string can be reduced.

図10(b)は、予測画像を生成する他の機能構成を示す機能ブロック図である。線形予測係数生成部110、線形予測係数記憶部109e、線形予測係数記憶部109f、線形予測演算部107hにより予測画像が生成される。   FIG. 10B is a functional block diagram showing another functional configuration for generating a predicted image. A prediction image is generated by the linear prediction coefficient generation unit 110, the linear prediction coefficient storage unit 109e, the linear prediction coefficient storage unit 109f, and the linear prediction calculation unit 107h.

線形予測係数生成部110によって生成された重み付け係数セットは線形予測係数記憶部109eおよび線形予測係数記憶部109fに格納されている。線形予測演算部107hは、動き検出の処理によって決定された第1参照インデックスref1によって選択される1組の重み付け係数セット(w1_1、w2_1,c_1,d_1)のうちの一部であるw1_1,c_1,d_1のパラメータを線形予測係数記憶部109eより獲得し、同様に第2参照インデックスref2を基に選択される1組の重み付け係数セット(w1_2、w2_2,c_2,d_2)のうちの一部であるw2_2のパラメータを線形予測係数記憶部109fより獲得する。線形予測演算部107hは、線形予測係数記憶部109e,線形予測係数記憶部109fより獲得したw1_1,c_1,d_1,w2_2を基に、式1を用いて、予測画像を演算し出力する。   The weighting coefficient set generated by the linear prediction coefficient generation unit 110 is stored in the linear prediction coefficient storage unit 109e and the linear prediction coefficient storage unit 109f. The linear prediction calculation unit 107h is w1_1, c_1, which is a part of one set of weighting coefficient sets (w1_1, w2_1, c_1, d_1) selected by the first reference index ref1 determined by the motion detection process. The parameter of d_1 is acquired from the linear prediction coefficient storage unit 109e, and w2_2 which is a part of one set of weighting coefficient sets (w1_2, w2_2, c_2, d_2) similarly selected based on the second reference index ref2 Are obtained from the linear prediction coefficient storage unit 109f. The linear prediction calculation unit 107h calculates and outputs a prediction image using Expression 1 based on w1_1, c_1, d_1, and w2_2 acquired from the linear prediction coefficient storage unit 109e and the linear prediction coefficient storage unit 109f.

すなわち、線形予測演算部107hは、線形予測係数記憶部109eより得られた重み付け係数セット(w1_1、w2_1,c_1,d_1)と、線形予測係数記憶部109fより得られた重み付け係数セット(w1_2、w2_2,c_2,d_2)のうち、実際に線形予測で使用する重み付け係数セット(w1、w2,c,d)を決定する際に、下記の規則を用いている。   That is, the linear prediction calculation unit 107h includes the weighting coefficient set (w1_1, w2_1, c_1, d_1) obtained from the linear prediction coefficient storage unit 109e and the weighting coefficient set (w1_2, w2_2) obtained from the linear prediction coefficient storage unit 109f. , C_2, d_2), the following rules are used when determining the weighting coefficient set (w1, w2, c, d) actually used in the linear prediction.

w1=w1_1,w2=w2_2,c=c_1,d=d_1   w1 = w1_1, w2 = w2_2, c = c_1, d = d_1

また、図10(b)で説明した予測画像の生成においては、線形予測係数記憶部109eは重み付け係数セットのうちw2_1を必要としない。そのため、ref1用の重み付け係数セットにw2は必要でない。よって符号列を小さくすることができる。   Further, in the generation of the prediction image described with reference to FIG. 10B, the linear prediction coefficient storage unit 109e does not need w2_1 in the weighting coefficient set. Therefore, w2 is not necessary for the weighting coefficient set for ref1. Therefore, the code string can be reduced.

また、線形予測係数記憶部109fは重み付け係数セットのうちw1_2,c_2,d_2を必要としない。そのため、ref2用の重み付け係数セットにw1,c,dは必要でない。よって符号列を小さくすることができる。   Further, the linear prediction coefficient storage unit 109f does not need w1_2, c_2, and d_2 in the weighting coefficient set. Therefore, w1, c, and d are not necessary for the weighting coefficient set for ref2. Therefore, the code string can be reduced.

また、w1、w2、c、dのパラメータのうちの1つもしくは複数個を固定の値として使用することも可能である。図11は図10(a)における機能構成に対して、dのみを固定の値として使用した場合の機能ブロック図である。線形予測係数生成部110、線形予測係数記憶部109i、線形予測係数記憶部109j、平均値算出部107j、線形予測演算部107kにより予測画像が生成される。   It is also possible to use one or more of the parameters w1, w2, c, and d as fixed values. FIG. 11 is a functional block diagram when only d is used as a fixed value for the functional configuration in FIG. A prediction image is generated by the linear prediction coefficient generation unit 110, the linear prediction coefficient storage unit 109i, the linear prediction coefficient storage unit 109j, the average value calculation unit 107j, and the linear prediction calculation unit 107k.

第1参照インデックスref1によって線形予測係数記憶部109iから選択される係数は(w1_1、c_1)のみであり、第2参照インデックスref2によって線形予測係数記憶部109jから選択される係数は(w2_2、c_2)のみである。平均値算出部107jは、線形予測係数記憶部109iおよび線形予測係数記憶部109jより獲得したc_1とc_2の平均値を算出してcを求め線形予測演算部107kに出力する。   The coefficients selected from the linear prediction coefficient storage unit 109i by the first reference index ref1 are only (w1_1, c_1), and the coefficients selected from the linear prediction coefficient storage unit 109j by the second reference index ref2 are (w2_2, c_2). Only. The average value calculation unit 107j calculates the average value of c_1 and c_2 acquired from the linear prediction coefficient storage unit 109i and the linear prediction coefficient storage unit 109j, obtains c, and outputs the result to the linear prediction calculation unit 107k.

また、線形予測演算部107kは、w1_1のパラメータを線形予測係数記憶部109iより獲得し、w2_2のパラメータを線形予測係数記憶部109jより獲得し、cのパラメータを平均値算出部107jfより獲得し、dのパラメータとして予め決められたある固定の値を使用し、式1を用いて予測画像を算出し出力する。つまり、式1の係数(w1、w2,c,d)には下記の値が入力されることになる。   Further, the linear prediction calculation unit 107k acquires the w1_1 parameter from the linear prediction coefficient storage unit 109i, the w2_2 parameter from the linear prediction coefficient storage unit 109j, the c parameter from the average value calculation unit 107jf, A predetermined fixed value is used as a parameter of d, and a predicted image is calculated and output using Expression 1. That is, the following values are input to the coefficients (w1, w2, c, d) of Equation 1.

w1=w1_1,w2=w2_2,c=(c_1とc_2の平均),d=(固定値)   w1 = w1_1, w2 = w2_2, c = (average of c_1 and c_2), d = (fixed value)

これを式1に代入すると下記の式1aが得られる。   Substituting this into Equation 1, the following Equation 1a is obtained.

P(i)=(w1_1×Q1(i)+w2_2×Q2(i))/pow(2,d)+(c_1+c_2)/2 (式1a)
(pow(2,d)は2のd乗を示す)
P (i) = (w1_1 × Q1 (i) + w2_2 × Q2 (i)) / pow (2, d) + (c_1 + c_2) / 2 (Formula 1a)
(Pow (2, d) indicates 2 to the power of d)

さらに式1aを変形することにより式1bのような式が得られる。線形予測演算部107kにおける線形予測の演算方法は式1bのような形式で用いた場合も式1の形式で用いた場合も全く同様に扱うことが可能である。   Further, by transforming Equation 1a, Equation 1b can be obtained. The linear prediction calculation method in the linear prediction calculation unit 107k can be handled in the same manner whether it is used in the form of Expression 1b or in the form of Expression 1.

P(i)=(w1_1×Q1(i)/pow(2,d−1)+c_1+w2_2×Q2(i)/pow(2,d−1)+c_2)/2 (式1b)
(pow(2,d−1)は2のd−1乗を示す)
P (i) = (w1_1 * Q1 (i) / pow (2, d-1) + c_1 + w2_2 * Q2 (i) / pow (2, d-1) + c_2) / 2 (Formula 1b)
(Pow (2, d-1) indicates 2 to the power of d-1)

なお、式1bではpow(2,d−1)となっているが、dは固定の値であるため、d'=d−1としてd'を線形予測演算部107kへの入力とすることによりpow(2,d')と
してシステムを構成してもよい。
In Expression 1b, pow (2, d-1) is used, but d is a fixed value, so that d '= d-1 and d' is input to the linear prediction calculation unit 107k. The system may be configured as pow (2, d ′).

また、図11で説明した予測画像の生成においては、線形予測係数記憶部109iは重み付け係数セットのうちw1_1とc_1のみを必要とし、線形予測係数記憶部109jは重み付け係数セットのうちw2_2とc_2のみを必要とするため、それ以外のパラメータを符号化する必要がない。よって符号列を小さくすることができる。   In addition, in the generation of the prediction image described with reference to FIG. 11, the linear prediction coefficient storage unit 109i requires only w1_1 and c_1 in the weighting coefficient set, and the linear prediction coefficient storage unit 109j has only w2_2 and c_2 in the weighting coefficient set. Therefore, it is not necessary to encode other parameters. Therefore, the code string can be reduced.

なお、dの値として使用する予め決定された固定の値とは、常に同じ値を使用することも可能であるが、スライスヘッダに前記固定の値を記述することによってスライスごとに切り替えることも可能である。同様に、ピクチャ共通情報領域またはシーケンス共通情報
領域に記述することによりピクチャごとまたはシーケンスごとに切り替えることも可能である。
It is possible to always use the same fixed value as the predetermined fixed value used as the value of d, but it is also possible to switch between slices by describing the fixed value in the slice header. It is. Similarly, it is possible to switch between pictures or sequences by describing them in the picture common information area or sequence common information area.

上記の線形予測方法を用いたときのスライスデータ領域の構成の例を図12に示す。図6と異なる点は、dがスライスヘッダ領域に1つだけ記述されている点と、ref1用のpsetとしてw1_1とc_1のみが記述されている点である。図13は前記スライスヘッダ領域に含まれる前記重み付け係数セットの例を表に示したものである。識別子psetで示された各々のデータはw1_1、c_1もしくはw2_2、c_2の2つの値を持ち、ref1およびref2の値によって直接参照できるように構成されている。   FIG. 12 shows an example of the configuration of the slice data area when the above linear prediction method is used. The difference from FIG. 6 is that only one d is described in the slice header area, and only w1_1 and c_1 are described as psets for ref1. FIG. 13 is a table showing an example of the weighting coefficient set included in the slice header area. Each data indicated by the identifier pset has two values w1_1, c_1 or w2_2, c_2, and is configured so that it can be directly referred to by the values of ref1 and ref2.

なお、線形予測係数生成部110では、ピクチャの特徴を調べることによって重み付け係数セットを生成し、動き補償符号化部107において、図8、図9、図10、図11で説明した方法を用いて予測画像を作成し、最も予測誤差が最小になるような2つの参照インデックスref1およびref2の組み合わせを決定する。なお、図10(a)、(b)、図11のように全てのパラメータを必要としない方法を用いる場合は、符号化装置の線形予測係数生成部110において重み付け係数セット作成する段階で、必要の無いパラメータの作成処理を省略することも可能である。   Note that the linear prediction coefficient generation unit 110 generates a weighting coefficient set by examining the characteristics of the picture, and the motion compensation encoding unit 107 uses the method described with reference to FIGS. 8, 9, 10, and 11. A prediction image is created, and a combination of two reference indexes ref1 and ref2 that minimizes the prediction error is determined. In addition, when using the method which does not require all the parameters like FIG. 10 (a), (b), and FIG. It is also possible to omit the process of creating a parameter without a symbol.

また、図10(a)、(b)、図11のような方法では、線形予測係数生成部110において重み付け係数セット作成する際に、例えばw1_1やw2_2のように、ref1用の重み付け係数セットとref2用の重み付け係数セットをそれぞれ独立に最適なものを探索して作成することが可能である。つまり、この方法を用いると符号化装置において重み付け係数セットを作成するための処理量を削減することが可能となる。   Further, in the methods as shown in FIGS. 10A, 10B, and 11, when the weighted coefficient set is generated in the linear prediction coefficient generation unit 110, for example, a weighting coefficient set for ref1 such as w1_1 and w2_2 is used. It is possible to create a weighting coefficient set for ref2 by searching for an optimum one independently. That is, when this method is used, it is possible to reduce the amount of processing for creating the weighting coefficient set in the encoding device.

なお、上記の符号化方法は2つの参照ピクチャをもつBピクチャに関するものであったが、1つの参照ピクチャしか持たないPピクチャおよびBピクチャにおける単一ピクチャ参照符号化モードにおいても同様の処理を行うことが可能である。この場合は第1参照インデックスもしくは第2参照インデックスのどちらか一方のみを使用し、図6の符号列におけるスライスヘッダ領域中のpsetおよびidx_cmdは、ブロックデータ領域中
に記述される参照インデックスに従って、ref1用もしくはref2用のもののみを記述することになる。
Although the above encoding method is related to a B picture having two reference pictures, the same processing is performed also in a single picture reference encoding mode for a P picture and a B picture having only one reference picture. It is possible. In this case, only one of the first reference index and the second reference index is used, and pset and idx_cmd in the slice header area in the code string of FIG. 6 are ref1 according to the reference index described in the block data area. Only those for ref2 or ref2.

また、線形予測の方法は従来の方法で説明した式1に替えて下記の式3を使用する。このとき、Q1(i)は参照されたブロックの画素値、P(i)は符号化対象ブロックの予測画像の画素値とし、w1、w2、c、dは選択された重み付け係数セットによって与えられる線形予測係数である。   The linear prediction method uses the following formula 3 instead of the formula 1 described in the conventional method. At this time, Q1 (i) is the pixel value of the referenced block, P (i) is the pixel value of the prediction image of the encoding target block, and w1, w2, c, and d are given by the selected weighting coefficient set. Linear prediction coefficient.

P(i)=(w1×Q1(i)+w2×Q1(i))/pow(2,d)+c(式3)
(pow(2,d)は2のd乗を示す)
P (i) = (w1 × Q1 (i) + w2 × Q1 (i)) / pow (2, d) + c (Formula 3)
(Pow (2, d) indicates 2 to the power of d)

なお、線形予測の式として式3の代わりに式4を使用することも可能である。このとき、Q1(i)は参照されたブロックの画素値、P(i)は符号化対象ブロックの予測画像の画素値とし、w1、c、dは選択された重み付け係数セットによって与えられる線形予測係数である。   In addition, it is also possible to use Formula 4 instead of Formula 3 as a linear prediction formula. At this time, Q1 (i) is the pixel value of the referenced block, P (i) is the pixel value of the predicted image of the encoding target block, and w1, c, and d are linear predictions given by the selected weighting coefficient set. It is a coefficient.

P(i)=(w1×Q1(i))/pow(2,d)+c (式4)
(pow(2,d)は2のd乗を示す)
P (i) = (w1 × Q1 (i)) / pow (2, d) + c (Formula 4)
(Pow (2, d) indicates 2 to the power of d)

式1および式3を使用する場合は、w1、w2、c、dの4つのパラメータが必要だったが、式4を使用する場合は、w1、c、dの3つのパラメータのみで線形予測を行うことができる。つまり、Pピクチャのようにピクチャ全体で第1参照インデックスもしくは第2参照インデックスのどちらか一方のみしか使用されない場合は、スライスヘッダ領域に記述する重み付け係数セットのデータの項目数をそれぞれ3つずつに減らすことが可能
となる。
When using Equation 1 and Equation 3, four parameters w1, w2, c, and d were required, but when using Equation 4, linear prediction was performed using only three parameters w1, c, and d. It can be carried out. That is, when only one of the first reference index and the second reference index is used in the entire picture like a P picture, the number of data items of the weighting coefficient set described in the slice header area is set to three each. It becomes possible to reduce.

式3を用いた場合はBピクチャとPピクチャとで構成を変更せずに両方に対応した線形予測を実現することが可能となる。また、式4を用いた場合はPピクチャのヘッダ領域に記述するデータ量を削減することができ、さらに計算が単純化されるため処理量の削減も実現することが可能となる。ただし、いずれの方法においても、本発明において提案する参照インデックスの割り振り方法はそのまま適用することができるため、符号化効率の高い予測画像を作成することが可能であり、画像の符号化において非常に有効である。   When Expression 3 is used, linear prediction corresponding to both can be realized without changing the configuration between the B picture and the P picture. Further, when Expression 4 is used, the amount of data described in the header area of the P picture can be reduced, and the calculation can be simplified, so that the amount of processing can be reduced. However, in any of the methods, since the reference index allocation method proposed in the present invention can be applied as it is, it is possible to create a prediction image with high encoding efficiency. It is valid.

ところで、動き補償において参照するピクチャは、各々のピクチャに割り当てられた参照インデックスを指定することによって決定される。その際に、参照することが可能なピクチャの最大枚数を符号列のピクチャ共通情報部分に記述していた。   By the way, a picture to be referred to in motion compensation is determined by designating a reference index assigned to each picture. At that time, the maximum number of pictures that can be referred to is described in the picture common information portion of the code string.

図38は、参照することが可能なピクチャの最大枚数を記述した符号列の模式図である。図に示すように符号列のピクチャ共通情報にref1用のピクチャの最大数Max_pic1と、ref2用のピクチャの最大数Max_pic2を記述していた。   FIG. 38 is a schematic diagram of a code string describing the maximum number of pictures that can be referred to. As shown in the figure, the maximum number of pictures ref1 Max_pic1 and the maximum number of pictures ref2 Max_pic2 are described in the picture common information of the code string.

符号化において必要とする情報は、実際のピクチャの最大枚数ではなく、ピクチャを指定するために使用する参照インデックスの取り得る最大値である。   The information necessary for encoding is not the actual maximum number of pictures, but the maximum value that can be taken by the reference index used to specify a picture.

従来の方法では、1つのピクチャには1つの参照インデックスしか割り当てられなかったため、前述のピクチャの最大枚数を記述することによって矛盾は生じなかったが、特に本発明のように、ピクチャ番号に複数の参照インデックスが割り当てられる場合には、その違いが大きく影響する。   In the conventional method, since only one reference index is assigned to one picture, there is no contradiction by describing the maximum number of pictures as described above. However, as in the present invention, there are a plurality of picture numbers. When a reference index is assigned, the difference greatly affects.

上述したように、符号列には参照インデックスをピクチャ番号に割り当てるためにコマンド列idx_cmd1、およびidx_cmd2が記述されている。このコマンド列idx_cmd1、およびidx_cmd2の各コマンドを基に、ピクチャ番号と参照インデックスとを対応づけていく。このときに、参照インデックスの最大値を知ることで、すべての参照インデックスとピクチャ番号との対応づけが行われたことがわかり、コマンド列idx_cmd1、およびidx_cmd2におけるコマンドの終端を知ることができる。   As described above, the command strings idx_cmd1 and idx_cmd2 are described in the code string in order to assign the reference index to the picture number. Based on the commands in the command sequences idx_cmd1 and idx_cmd2, the picture number and the reference index are associated with each other. At this time, by knowing the maximum value of the reference index, it can be seen that all the reference indexes are associated with the picture numbers, and the end of the command in the command strings idx_cmd1 and idx_cmd2 can be known.

そこで、本実施の形態では、従来のピクチャの最大枚数の代わりに、利用可能な参照インデックスの最大数をピクチャのヘッダであるピクチャ共通情報部分に記述している。もしくは、ピクチャの最大枚数と参照インデックスの最大数の両者を記述する。   Therefore, in the present embodiment, instead of the conventional maximum number of pictures, the maximum number of reference indexes that can be used is described in the picture common information portion that is the header of the picture. Alternatively, both the maximum number of pictures and the maximum number of reference indexes are described.

図23は、ピクチャの符号列のピクチャ共通情報に参照インデクッスの最大数を記述した状態を示している。ピクチャの共通情報部分には、ref1用の利用可能な参照インデックスの最大数Max_idx1、およびref2用の利用可能な参照インデックスの最大数Max_idx2を記述している。   FIG. 23 shows a state in which the maximum number of reference indexes is described in the picture common information of the picture code string. In the common information portion of the picture, the maximum number of reference indexes Max_idx1 that can be used for ref1 and the maximum number of reference indexes that can be used Max2 for ref2 are described.

なお、図23では、ピクチャ共通情報に参照インデクッスの最大数を記述しているが、これに加えて、スライスデータ領域に参照インデクッスの最大数を記述する構成としてもよい。例えば、ピクチャでの参照インデクッスの最大数が8、当該ピクチャ中のスライス1で必要な参照インデクッスの最大数が8、スライス2で必要な参照インデクッスの最大数が4であるというように、スライスによって必要な参照インデクッスの最大数がピクチャ共通情報領域に記述された最大数と異なる場合に、スライス毎に必要な参照インデクッスの最大数を明示することができる。   In FIG. 23, the maximum number of reference indexes is described in the picture common information. However, in addition to this, the maximum number of reference indexes may be described in the slice data area. For example, the maximum number of reference indexes in a picture is 8, the maximum number of reference indexes required in slice 1 in the picture is 8, and the maximum number of reference indexes required in slice 2 is 4. When the maximum number of required reference indexes is different from the maximum number described in the picture common information area, the maximum number of reference indexes required for each slice can be specified.

すなわち、ピクチャ共通情報に記述された参照インデクッスの最大数をピクチャ中の各スライスに共通するデフォルト値として、必要な参照インデクッスの最大数がデフォルト値と異なるスライスについてはスライスヘッダに記述するようにしてもよい。   In other words, the maximum number of reference indexes described in the picture common information is set as a default value common to each slice in the picture, and a slice in which the required maximum number of reference indexes is different from the default value is described in the slice header. Also good.

なお、図23および図38ではではピクチャ共通情報領域とスライスデータ領域とをひとまとめにして符号列としている例を示したが、ピクチャ共通情報領域とスライスデータ領域はそれぞれ独立した符号列とすることも可能であり、この場合も全く同様に扱うことができる。   In FIGS. 23 and 38, the picture common information area and the slice data area are collectively shown as a code string. However, the picture common information area and the slice data area may be independent code strings. This is possible and can be handled in exactly the same way.

(実施の形態2)
本発明の実施の形態2における動画像符号化方法について説明する。なお、符号化装置の構成および符号化の処理の流れおよび参照インデックスの割り当て方法は実施の形態1と全く同様であるため、ここでは説明を省略する。
(Embodiment 2)
A video encoding method according to Embodiment 2 of the present invention will be described. Note that the configuration of the encoding device, the flow of the encoding process, and the method of assigning the reference index are exactly the same as those in the first embodiment, and thus description thereof is omitted here.

実施の形態1では動き補償において予測画像を生成する際に、式1もしくは式3もしくは式4を用いて画素ごとに線形予測を行っている。しかし、これらの式はいずれも乗算処理を含むものであり、全ての画素に対してこのような演算を行うことを考えると、処理量が非常に大きくなってしまう。   In the first embodiment, when a predicted image is generated in motion compensation, linear prediction is performed for each pixel using Expression 1, 3 or 4. However, all of these equations include multiplication processing, and the processing amount becomes very large considering that such calculation is performed on all pixels.

そこで式1の代わりに式5、式3の代わりに式6、式4の代わりに式7を使用することも可能である。これらの式は乗算を使用することなくビットシフト演算のみで計算を行うことができるため、処理量を少なく抑えることが可能となる。このとき、Q1(i)、Q2(i)は参照されたブロックの画素値、P(i)は符号化対象ブロックの予測画像の画素値とし、m、n、cは選択された重み付け係数セットによって与えられる線形予測係数である。   Therefore, it is also possible to use Formula 5 instead of Formula 1, Formula 6 instead of Formula 3, and Formula 7 instead of Formula 4. Since these equations can be calculated only by a bit shift operation without using multiplication, the amount of processing can be reduced. At this time, Q1 (i) and Q2 (i) are the pixel values of the referenced block, P (i) is the pixel value of the predicted image of the encoding target block, and m, n, and c are the selected weighting coefficient sets. Is a linear prediction coefficient given by

P(i)=±pow(2,m)×Q1(i) ±pow(2,n)×Q2(i)+c (式5)
P(i)=±pow(2,m)×Q1(i) ±pow(2,n)×Q1(i)+c (式6)
P(i)=±pow(2,m)×Q1(i)+c (式7)
(pow(2,m)は2のm乗を、pow(2,n)は2のn乗を示す。)
P (i) = ± pow (2, m) × Q1 (i) ± pow (2, n) × Q2 (i) + c (Formula 5)
P (i) = ± pow (2, m) × Q1 (i) ± pow (2, n) × Q1 (i) + c (Formula 6)
P (i) = ± pow (2, m) × Q1 (i) + c (Formula 7)
(Pow (2, m) represents 2 to the mth power, and pow (2, n) represents 2 to the nth power.)

実施の形態1と同様に、同時に2枚のピクチャを参照して予測画像を生成するときは式5を使用し、1枚のピクチャのみを参照して予測画像を生成するときは式6もしくは式7を使用する。これらの式では正負の符号を表す識別子が必要となるため、予測演算に必要な重み付け係数セットは、式5および式6の場合は(sign1、m、sign2、n、c)、式7の場合は(sign1、m、c)となる。sign1は1つめの正負の符号を、sign2は2つめの正負の符号を識別するパラメータである。パラメータの個数は実施の形態1よりも増加しているが、sign1およびsign2はそれぞれ1ビットで表現することができるため符号量の増加はほとんど無い。   As in the first embodiment, Expression 5 is used when a predicted image is generated with reference to two pictures at the same time, and Expression 6 or Expression is used when a predicted image is generated with reference to only one picture. 7 is used. Since these expressions require identifiers representing positive and negative signs, the weighting coefficient set necessary for the prediction calculation is (sign1, m, sign2, n, c) in the case of Expression 5 and Expression 6, and in the case of Expression 7. Becomes (sign1, m, c). sign1 is a parameter for identifying the first positive / negative sign, and sign2 is a parameter for identifying the second positive / negative sign. Although the number of parameters is greater than that in the first embodiment, sign1 and sign2 can be expressed by 1 bit, respectively, so that the amount of code hardly increases.

ここで、重み付け係数セットを決定し、式5を使用し同時に2枚のピクチャを参照して予測画像を生成するまでの処理の流れについて詳細に説明する。   Here, the flow of processing until the weighted coefficient set is determined and the predicted image is generated with reference to two pictures at the same time using Equation 5 will be described in detail.

まず、予測画像を生成する機能構成が図8である場合について説明する。平均値算出部107aは、線形予測係数記憶部109aより重み付け係数セット(sign1_1,m_1,sign2_1,n_1,c_1)を得る。また、平均値算出部107aは、線形予測係数記憶部109bより重み付け係数セット(sign1_2,m_2,sign2_2,n_2,c_2)を得る。   First, a case where the functional configuration for generating a predicted image is FIG. 8 will be described. The average value calculation unit 107a obtains a weighting coefficient set (sign1_1, m_1, sign2_1, n_1, c_1) from the linear prediction coefficient storage unit 109a. Further, the average value calculation unit 107a obtains a weighting coefficient set (sign1_2, m_2, sign2_2, n_2, c_2) from the linear prediction coefficient storage unit 109b.

平均値算出部107aは、線形予測係数記憶部109a、線形予測係数記憶部109bより得た重み付け係数セットのパラメータ毎の平均値を求め、重み付け係数セット(sign1,m,sign2,n,c)とする。線形予測演算部107bは、平均値算出部107aが出力する重み付け係数セット(sign1,m,sign2,n,c)を基に、式5を用いて予測画像を演算する。   The average value calculation unit 107a obtains an average value for each parameter of the weighting coefficient set obtained from the linear prediction coefficient storage unit 109a and the linear prediction coefficient storage unit 109b, and sets the weighting coefficient set (sign1, m, sign2, n, c) and To do. The linear prediction calculation unit 107b calculates a prediction image using Expression 5 based on the weighting coefficient set (sign1, m, sign2, n, c) output from the average value calculation unit 107a.

なお、図8に記載した線形予測係数記憶部109a等より得られる重み付け係数セット(w1_1,w2_1,c_1,d_1)等は、実施の形態1で説明した式1の場合の例におけるものであり、式5を用いて予測画像を求める場合についてのパラメータについては図示していないが、そのまま置き換えることが可能である。以下に説明する図9、図10の場合も同様である。   Note that the weighting coefficient sets (w1_1, w2_1, c_1, d_1) and the like obtained from the linear prediction coefficient storage unit 109a and the like described in FIG. 8 are in the example in the case of Equation 1 described in the first embodiment. Although parameters for obtaining a predicted image using Expression 5 are not shown, they can be replaced as they are. The same applies to FIGS. 9 and 10 described below.

次に、予測画像を生成する機能構成が図9である場合について説明する。線形予測演算部107cは、線形予測係数記憶部109aより得た重み付け係数セット(sign1_1,m_1,sign2_1,n_1,c_1)を基に予測画像を演算する。線形予測演算部107dは、線形予測係数記憶部109bより得た重み付け係数セット(sign1_2,m_2,sign2_2,n_2,c_2)を基に予測画像を演算する。そして平均値算出部107eは、線形予測演算部107c,107dのそれぞれが演算した予測画像の各画素の平均を求め、予測画像とする。   Next, the case where the functional configuration for generating a predicted image is shown in FIG. 9 will be described. The linear prediction calculation unit 107c calculates a prediction image based on the weighting coefficient set (sign1_1, m_1, sign2_1, n_1, c_1) obtained from the linear prediction coefficient storage unit 109a. The linear prediction calculation unit 107d calculates a prediction image based on the weighting coefficient set (sign1_2, m_2, sign2_2, n_2, c_2) obtained from the linear prediction coefficient storage unit 109b. Then, the average value calculation unit 107e calculates the average of each pixel of the prediction image calculated by each of the linear prediction calculation units 107c and 107d, and sets it as the prediction image.

この場合、線形予測演算部107cは、重み付け係数セット(sign1_1,m_1,sign2_1,n_1,c_1)を基に式5を用いて、最初に予測画像を演算するため、乗算を使用することなく、ビットシフト演算で計算することができる。線形予測演算部107dも同様である。一方、図8の場合であると、最初に重み付け係数セット(sign1_1,m_1,sign2_1,n_1,c_1)と重み付け係数セット(sign1_2,m_2,sign2_2,n_2,c_2)の平均を求めるため、m_1とm_2の平均値あるいはn_1とn_2の平均値が整数にならない場合があり、すなわち2の指数にあたる部分が整数にならないため、処理量が多くなってしまう可能性がある。また、2の指数にあたる部分が整数になるように丸め処理をおこなうと誤差が大きくなってしまう可能性がある。   In this case, the linear prediction calculation unit 107c first calculates a prediction image using Equation 5 based on the weighting coefficient set (sign1_1, m_1, sign2_1, n_1, c_1). It can be calculated by a shift operation. The same applies to the linear prediction calculation unit 107d. On the other hand, in the case of FIG. 8, in order to obtain the average of the weighting coefficient set (sign1_1, m_1, sign2_1, n_1, c_1) and the weighting coefficient set (sign1_2, m_2, sign2_2, n_2, c_2) first, m_1 and m_2 Or the average value of n_1 and n_2 may not be an integer, that is, the portion corresponding to the exponent of 2 does not become an integer, and the amount of processing may increase. In addition, if rounding is performed so that the portion corresponding to the exponent of 2 becomes an integer, there is a possibility that the error will increase.

次に、予測画像を生成する機能構成が図10(a)である場合について説明する。線形予測演算部107gは、線形予測係数記憶部109cより得たビットシフト演算に用いられる係数であるパラメータsign1_1,m_1と、線形予測係数記憶部109cより得たビットシフト演算に用いられる係数であるパラメータsign2_2,n_2と、各線形予測係数記憶部109c,109dより得たパラメータc_1とc_2を平均値算出部107fが平均して求めた平均値cとを基に式5を用いて予測画像を演算する。   Next, the case where the functional configuration for generating a predicted image is shown in FIG. The linear prediction calculation unit 107g is a parameter sign1_1, m_1 that is a coefficient used for the bit shift calculation obtained from the linear prediction coefficient storage unit 109c, and a parameter that is a coefficient used for the bit shift calculation obtained from the linear prediction coefficient storage unit 109c. Based on the sign2_2 and n_2 and the average value c obtained by averaging the parameters c_1 and c_2 obtained from the respective linear prediction coefficient storage units 109c and 109d by the average value calculation unit 107f, a prediction image is calculated using Expression 5. .

この場合においても、ビットシフト演算に用いられる係数は、線形予測係数記憶部109cあるいは線形予測係数記憶部109dよりそのまま得た値であるので、式5における2の指数部分が整数となる。そのため、ビットシフト演算で計算することができ、処理量を少なくすることが可能となる。   Also in this case, since the coefficient used for the bit shift calculation is a value obtained from the linear prediction coefficient storage unit 109c or the linear prediction coefficient storage unit 109d as it is, the exponent part of 2 in Equation 5 is an integer. Therefore, it can be calculated by a bit shift operation, and the processing amount can be reduced.

予測画像を生成する機能構成が図10(b)である場合について説明する。線形予測演算部107hは、線形予測係数記憶部109eより得たパラメータsign1_1,m_1,c_1と、線形予測係数記憶部109fより得たパラメータsign2_2,n_2とを基に式5を用いて予測画像を演算する。   A case where the functional configuration for generating a predicted image is shown in FIG. The linear prediction calculation unit 107h calculates a prediction image using Equation 5 based on the parameters sign1_1, m_1, c_1 obtained from the linear prediction coefficient storage unit 109e and the parameters sign2_2, n_2 obtained from the linear prediction coefficient storage unit 109f. To do.

この場合においても、ビットシフト演算に用いられる係数は、線形予測係数記憶部109e、あるいは線形予測係数記憶部109fよりそのまま得た値であるので、式5における2の指数部分が整数となる。そのため、ビットシフト演算で計算することができ、処理量を少なくすることが可能となる。   Also in this case, since the coefficient used for the bit shift calculation is a value obtained from the linear prediction coefficient storage unit 109e or the linear prediction coefficient storage unit 109f as it is, the exponent part of 2 in Equation 5 is an integer. Therefore, it can be calculated by a bit shift operation, and the processing amount can be reduced.

図10(a)(b)の場合は、実施の形態1における図10(a)(b)の説明と同様に符号列に付加して送らなくてもよいパラメータがあり、符号列を小さくすることが可能である。   In the case of FIGS. 10 (a) and 10 (b), there is a parameter that does not have to be added to the code string and sent as in the description of FIGS. It is possible.

以上、実施の形態2で説明したような線形予測式を用いると、乗算を使用することなくビットシフト演算で計算することができるため実施の形態1に比べて処理量を大幅に削減することが可能となる。   As described above, when the linear prediction formula as described in the second embodiment is used, calculation can be performed by bit shift calculation without using multiplication, so that the processing amount can be significantly reduced as compared with the first embodiment. It becomes possible.

なお、上記実施の形態では式1、式3、式4の代わりに式5、式6、式7を用い、符号化するパラメータセットも(w1、w2、c、d)の代わりに(sign1、m、sign2、n、c)を用いて線形予測を行うことによってビットシフト演算のみでの計算を実現し処理量の削減を図っていたが、別のアプローチとして式1、式3、式4および(w1、w2、c、d)をそのまま用いたまま、w1およびw2をビットシフト演算可能な値のみ選択可能として制限することによってビットシフト演算のみでの計算を実現し処理量の削減を行うことも可能である。   In the above embodiment, Formula 5, Formula 6, and Formula 7 are used instead of Formula 1, Formula 3, and Formula 4, and the parameter set to be encoded is (sign1, m, sign2, n, c) are used to perform linear prediction to achieve calculation only by bit shift operation and reduce the amount of processing. However, as another approach, Equation 1, Equation 3, Equation 4, and By limiting w1 and w2 to be selectable only for values that can be subjected to bit shift operation while using (w1, w2, c, d) as they are, calculation by only bit shift operation is realized and processing amount is reduced. Is also possible.

図1の線形予測係数生成部110において、w1およびw2の各値を決定する際に、その選択肢としてビットシフト演算可能な値のみを選択し図6および図12の符号列中のw1およびw2にそのまま選択された値を記述する。これによって実施の形態1と全く同様の構成のまま線形予測のための処理量の削減を図ることが可能となり、さらに係数の選択肢が制限されることにより係数の決定を容易に行うことが可能となる。   When determining each value of w1 and w2 in the linear prediction coefficient generation unit 110 of FIG. 1, only values that can be subjected to bit shift calculation are selected as the choices, and w1 and w2 in the code strings of FIGS. 6 and 12 are selected. Describe the selected value as it is. As a result, it is possible to reduce the processing amount for linear prediction with the same configuration as in the first embodiment, and it is possible to easily determine the coefficients by limiting the choices of coefficients. Become.

また、さらに限定する方法として、w1およびw2を常に1として選択するように制限し、直流成分であるc1およびc2のみ最適な値を線形予測係数生成部110において生成することも可能である。図11の構成の場合を例にとると、ref1用として(1、c_1)、ref2用として(1、c_2)をパラメータセットとして符号化する。この場合、予測画像の画素値P(i)は、(式1a)中のw1_1およびw2_2を1に置き換えた次式により求められる。   Further, as a further limiting method, it is possible to limit w1 and w2 to be always selected as 1, and to generate an optimal value only for the DC components c1 and c2 in the linear prediction coefficient generation unit 110. Taking the case of the configuration of FIG. 11 as an example, (1, c_1) for ref1 and (1, c_2) for ref2 are encoded as parameter sets. In this case, the pixel value P (i) of the predicted image is obtained by the following expression in which w1_1 and w2_2 in (Expression 1a) are replaced with 1.

P(i)=(Q1(i)+Q2(i))/pow(2,d)+(c_1+c_2)/2
(pow(2,d)は2のd乗を示す)
P (i) = (Q1 (i) + Q2 (i)) / pow (2, d) + (c_1 + c_2) / 2
(Pow (2, d) indicates 2 to the power of d)

これによって実施の形態1と全く同様の構成のまま線形予測のための処理量を大幅に削減することが可能となり、さらに不確定の係数がc_1およびc_2のみとなるため係数の決定方法の大幅な単純化が可能となる。   This makes it possible to significantly reduce the amount of processing for linear prediction with the same configuration as in the first embodiment, and further, since the uncertain coefficients are only c_1 and c_2, the coefficient determination method is greatly increased. Simplification is possible.

図24は、ピクチャの符号列のピクチャ共通情報に、線形予測をビットシフト演算のみで行うことが可能であるかを示すフラグsft_flg、および直流成分であるcのみで線形予測を行うことが可能であるかを示すフラグdc_flgを記述した例を示している。復号化装置ではこれらフラグを参照せずに復号することも可能であるが、これらフラグを参照することにより、ビットシフト演算のみでの線形予測に適した構成での復号を行うことや、直流成分のみでの線形予測に適した構成での復号を行うことが可能となるため、復号化装置の構成によっては非常に重要な情報となる場合がある。   FIG. 24 shows that it is possible to perform linear prediction only on a flag sft_flg indicating whether linear prediction can be performed only by a bit shift operation, and c that is a DC component, in the picture common information of a picture code string. An example in which a flag dc_flg indicating whether or not there is described is shown. The decoding device can also decode without referring to these flags, but by referring to these flags, it is possible to perform decoding with a configuration suitable for linear prediction with only bit shift operation, Since it is possible to perform decoding with a configuration suitable for linear prediction only with this, it may be very important information depending on the configuration of the decoding device.

なお、図24ではピクチャ共通情報領域とスライスデータ領域とをひとまとめにして符号列としている例を示したが、ピクチャ共通情報領域とスライスデータ領域はそれぞれ独立した符号列とすることも可能であり、この場合も全く同様に扱うことができる。また、図24の例ではピクチャ共通情報領域にsft_flgおよびdc_flgを記述しているが、シーケンス共通情報領域やその他の独立した共通情報領域に記述する場合も全く同
様に扱うことができる。また、これらの2つのフラグは両方同時に使用する場合のみでなく、sft_flgのみもしくはdc_flgのみで使用することも可能であり、それらの場合も同様に扱うことができる。
FIG. 24 shows an example in which the picture common information area and the slice data area are collectively used as a code string. However, the picture common information area and the slice data area can also be independent code strings. This case can be handled in exactly the same way. In the example of FIG. 24, sft_flg and dc_flg are described in the picture common information area. However, the description can be handled in the same manner when described in the sequence common information area and other independent common information areas. These two flags can be used not only when both are used at the same time but also with only sft_flg or dc_flg, and these cases can be handled in the same manner.

(実施の形態3)
本発明の実施の形態3における動画像符号化方法について説明する。なお、符号化装置の構成および符号化の処理の流れおよび参照インデックスの割り当て方法は実施の形態1と全く同様であるため、ここでは説明を省略する。
(Embodiment 3)
A video encoding method according to Embodiment 3 of the present invention will be described. Note that the configuration of the encoding device, the flow of the encoding process, and the method of assigning the reference index are exactly the same as those in the first embodiment, and thus description thereof is omitted here.

従来の技術において説明したように、実施の形態1および実施の形態2のように線形予測係数の重み付け係数セットから求める予測式を用いて予測画像を生成するのではなく、式2aおよび式2bのように予め決めた固定式を用いて予測画像を求める方法があった。この方法を用いると、予測画像を求めるときの重み付け係数セットを符号化して送る必要がないため符号量を削減できるという利点があった。また、線形予測の計算式が単純であるため、少ない処理量で線形予測を大幅に削減することが可能であった。しかし、この固定式を用いた方法であると、選択することのできる線形予測式が式2aおよび式2bの2通りしかないため、予測精度が悪くなってしまうという問題があった。   As described in the prior art, the prediction image is not generated by using the prediction expression obtained from the weighting coefficient set of the linear prediction coefficient as in the first and second embodiments, but instead of the expressions 2a and 2b. As described above, there is a method of obtaining a predicted image using a predetermined fixed formula. When this method is used, there is an advantage that the amount of codes can be reduced because it is not necessary to encode and send a weighting coefficient set for obtaining a predicted image. In addition, since the calculation formula for linear prediction is simple, linear prediction can be significantly reduced with a small amount of processing. However, the method using this fixed formula has a problem that the prediction accuracy deteriorates because there are only two types of linear prediction formulas 2a and 2b that can be selected.

そこで本実施の形態では式2a,式2bの代わりに式8a,8bを使用する。これらの式は式2a,式2bにC1およびC2を加えたものである。演算としては加算の回数が増加するだけであるため、元の式と比較しても処理量の増加はほとんど無い。このとき、Q1(i)、Q2(i)は参照されたブロックの画素値、P(i)は符号化対象ブロックの予測画像の画素値とし、C1、C2は選択された重み付け係数セットによって与えられる線形予測係数である。   Therefore, in this embodiment, equations 8a and 8b are used instead of equations 2a and 2b. These equations are obtained by adding C1 and C2 to equations 2a and 2b. As the calculation only increases the number of additions, the amount of processing is hardly increased even when compared with the original expression. At this time, Q1 (i) and Q2 (i) are the pixel values of the referenced block, P (i) is the pixel value of the predicted image of the encoding target block, and C1 and C2 are given by the selected weighting coefficient set. Is a linear prediction coefficient.

P(i)=2×(Q1(i)+C1)−(Q2(i)+C2) (式8a)
P(i)=(Q1(i)+C1+Q2(i)+C2)/2 (式8b)
P (i) = 2 × (Q1 (i) + C1) − (Q2 (i) + C2) (Formula 8a)
P (i) = (Q1 (i) + C1 + Q2 (i) + C2) / 2 (Formula 8b)

式8a,8bは同時に2枚のピクチャを参照して予測画像を生成するときの予測式であるが、1枚のピクチャのみを参照して予測画像を生成するときは実施の形態で説明した式3、式4の代わりに式9を使用する。   Expressions 8a and 8b are prediction expressions when a predicted image is generated by referring to two pictures at the same time. When generating a predicted image by referring to only one picture, the expressions described in the embodiment are used. 3. Instead of equation 4, equation 9 is used.

P(i)=Q1(i)+C1 (式9)   P (i) = Q1 (i) + C1 (Formula 9)

この方法を用いるために必要な重み付け係数セットは、ref1用として(C1)、ref2用として(C2)のみである。そのため、この方法を用いた場合のピクチャの符号列の例は図14にようになり、スライスヘッダ領域には線形予測を行うための重み付け係数セット(pset0、pset1、pset2、・・・・)がref1用およびref2用それぞれに記述され、それぞれの重み付け係数セットの中身はCのみとなる。同様に、図15は前記スライスヘッダ領域に含まれる重み付け係数セットの例を表に示したものであるが、図7とは異なり、各重み付け係数セットの要素はCのみとなっている。   The weighting coefficient sets necessary for using this method are only (C1) for ref1 and (C2) for ref2. Therefore, an example of a picture code string when this method is used is as shown in FIG. 14, and weighting coefficient sets (pset0, pset1, pset2,...) For performing linear prediction are shown in the slice header region. It is described for each of ref1 and ref2, and the content of each weighting coefficient set is C only. Similarly, FIG. 15 is a table showing an example of the weighting coefficient set included in the slice header area. Unlike FIG. 7, the element of each weighting coefficient set is C only.

図16は、図1の線形予測係数生成部110、線形予測係数記憶部109、および動き補償符号化部107における予測画像を生成する機能構成を示した機能ブロック図である。   FIG. 16 is a functional block diagram illustrating a functional configuration for generating a prediction image in the linear prediction coefficient generation unit 110, the linear prediction coefficient storage unit 109, and the motion compensation encoding unit 107 in FIG.

線形予測係数生成部110、線形予測係数記憶部109g、線形予測係数記憶部109h、および線形予測演算部107iにより予測画像が生成される。   A prediction image is generated by the linear prediction coefficient generation unit 110, the linear prediction coefficient storage unit 109g, the linear prediction coefficient storage unit 109h, and the linear prediction calculation unit 107i.

線形予測係数生成部110によって生成された重み付け係数セットは線形予測係数記憶部109gおよび線形予測係数記憶部109hに格納されている。動き検出の処理によって決定された第1参照インデックスref1、および第2参照インデックスref2により線形予測係数記憶部109gおよび109hよりそれぞれ1つの構成要素のみを持つ重み付け係数セット(C1)および(C2)が獲得される。それらの値は線形予測演算部107iに入力され、式8a,式8bを用いて線形予測がなされ、予測画像が生成される。   The weighting coefficient set generated by the linear prediction coefficient generation unit 110 is stored in the linear prediction coefficient storage unit 109g and the linear prediction coefficient storage unit 109h. Weighting coefficient sets (C1) and (C2) each having only one component are obtained from the linear prediction coefficient storage units 109g and 109h by the first reference index ref1 and the second reference index ref2 determined by the motion detection process. Is done. These values are input to the linear prediction calculation unit 107i, and linear prediction is performed using Expressions 8a and 8b, and a predicted image is generated.

同様に、1枚のみを参照して線形予測を行う場合は図16のref1もしくはref2のどちらかのみにより重み付け係数セット(C1)もしくは(C2)が獲得され、式9を用いて線形予測がなされ、予測画像が生成される。   Similarly, when performing linear prediction with reference to only one sheet, the weighting coefficient set (C1) or (C2) is acquired only by either ref1 or ref2 in FIG. 16, and linear prediction is performed using Equation 9. A predicted image is generated.

なお、線形予測係数生成部110では、ピクチャの特徴を調べることによって重み付け係数セット(C1)および(C2)を生成し、図16で説明した方法を用いて予測画像を作成し、最も予測誤差が最小になるような2つの参照インデックスref1およびref2の組み合わせを決定する。   Note that the linear prediction coefficient generation unit 110 generates weighting coefficient sets (C1) and (C2) by examining the characteristics of a picture, creates a prediction image using the method described with reference to FIG. The combination of the two reference indexes ref1 and ref2 that minimizes is determined.

このように、本実施の形態では使用するパラメータの数がref1用、ref2用にそれぞれ1つずつのみでよいため、符号化装置においてパラメータの値を決定する処理が容易に行え、さらに符号列に記述するデータの量を削減することができる。また線形予測式も乗算等の複雑な演算を必要としないため、演算量も最小限に抑えることが可能である。また従来の固定式を用いた方法で欠点とされていた予測精度の悪さも、C1およびC2という係数を用いることにより大幅に改善することが可能である。   As described above, in this embodiment, only one parameter is required for each of ref1 and ref2, so that the process of determining the parameter value can be easily performed in the encoding device, and the code string can be further converted into a code string. The amount of data to be written can be reduced. In addition, since the linear prediction formula does not require complicated operations such as multiplication, the amount of calculation can be minimized. Further, the poor prediction accuracy, which has been regarded as a drawback in the conventional method using the fixed formula, can be significantly improved by using the coefficients C1 and C2.

なお、本実施の形態で説明した線形予測の方法は、複数の参照インデックスが同一のピクチャを参照することが可能であるかどうかに関わらず用いることが可能である。   Note that the linear prediction method described in this embodiment can be used regardless of whether a plurality of reference indexes can refer to the same picture.

(実施の形態4)
本発明の実施の形態4における動画像符号化方法について説明する。なお、符号化装置の構成および符号化の処理の流れおよび参照インデックスの割り当て方法は実施の形態1と全く同様であるため、ここでは説明を省略する。
(Embodiment 4)
A moving picture coding method according to Embodiment 4 of the present invention will be described. Note that the configuration of the encoding device, the flow of the encoding process, and the method of assigning the reference index are exactly the same as those in the first embodiment, and thus description thereof is omitted here.

各々のピクチャはピクチャ番号と共に、表示時間もしくはそれに代わるものを示すための表示順情報というものが割り当てられている。図39は、その1例としてピクチャ番号と表示順情報とを並べて示した図である。表示順情報は表示される順番に従ってある値が割り当てられる。この図の例では、1ピクチャごとに1ずつ増加する値が使用されている。線形予測を行うための式で用いられる係数の値をこれらの表示順情報を用いて生成する方法について実施の形態4において説明する。   Each picture is assigned with a picture number and display order information for indicating a display time or an alternative. FIG. 39 is a diagram showing a picture number and display order information side by side as an example. A certain value is assigned to the display order information according to the display order. In the example of this figure, a value that increases by 1 for each picture is used. A method for generating coefficient values used in an equation for performing linear prediction using the display order information will be described in a fourth embodiment.

実施の形態1では動き補償において予測画像を生成する際に、式1もしくは式3もしくは式4を用いて画素ごとに線形予測を行っている。しかし、これらの線形予測を行うためには係数のデータが必要であり、前記実施の形態では、スライスヘッダ領域に重み付け係数セットとして符号列中に係数のデータを記述し、予測画像の作成に用いていた。しかし、高い符号化効率が得られる反面、重み付け係数セットのデータを作成するための処理が必要となり、また、重み付け係数セットを符号列中に記述することによるビット量の増加も発生する。   In the first embodiment, when a predicted image is generated in motion compensation, linear prediction is performed for each pixel using Expression 1, 3 or 4. However, coefficient data is required to perform these linear predictions. In the above embodiment, coefficient data is described in a code string as a weighting coefficient set in a slice header area, and is used to create a prediction image. It was. However, while high coding efficiency can be obtained, a process for creating weighting coefficient set data is required, and an increase in the bit amount due to the description of the weighting coefficient set in the code string also occurs.

そこで式1の代わりに式10、式11a、式12aを用いて線形予測を行うことも可能である。これらの式は各々の参照ピクチャが持つ表示順情報のみから重み付け係数を決定することができるため、別途重み付け係数セットを符号化する必要がない。   Therefore, it is also possible to perform linear prediction using Formula 10, Formula 11a, and Formula 12a instead of Formula 1. Since these equations can determine the weighting coefficient only from the display order information of each reference picture, it is not necessary to separately encode the weighting coefficient set.

このとき、Q1(i)、Q2(i)は参照されたブロックの画素値、P(i)は符号化対象ブロックの予測画像の画素値とし、V0、V1は重み付け係数、T0は符号化対象ピクチャの表示順情報、T1は第1参照インデックスによって指定されたピクチャの表示順情報、T2は第2参照インデックスによって指定されたピクチャの表示順情報である。   At this time, Q1 (i) and Q2 (i) are the pixel values of the referenced block, P (i) is the pixel value of the predicted image of the encoding target block, V0 and V1 are weighting coefficients, and T0 is the encoding target. The display order information of the picture, T1 is the display order information of the picture designated by the first reference index, and T2 is the display order information of the picture designated by the second reference index.

P(i)=V1×Q1(i)+V2×Q2(i) (式10)
V1=(T2−T0)/(T2−T1) (式11a)
V2=(T0−T1)/(T2−T1) (式12a)
P (i) = V1 * Q1 (i) + V2 * Q2 (i) (Formula 10)
V1 = (T2-T0) / (T2-T1) (Formula 11a)
V2 = (T0-T1) / (T2-T1) (Formula 12a)

例として図39において、符号化対象ピクチャが16番、第1参照インデックスによって指定されたピクチャが11番、第2参照インデックスによって指定されたピクチャが10番とすると、それぞれのピクチャの表示順情報は15、13、10となるため、下記のような線形予測式が決定される。   For example, in FIG. 39, if the encoding target picture is No. 16, the picture specified by the first reference index is No. 11, and the picture specified by the second reference index is No. 10, the display order information of each picture is Since the values are 15, 13, and 10, the following linear prediction formula is determined.

V1=(10−15)/(10−13)=5/3
V2=(15−13)/(10−13)=−2/3
P(i)=5/3×Q1(i)−2/3×Q2(i)
V1 = (10-15) / (10-13) = 5/3
V2 = (15-13) / (10-13) =-2/3
P (i) = 5/3 × Q1 (i) −2 / 3 × Q2 (i)

式1を用いた重み付け係数セットを用いて線形予測を行う方法と比較すると係数の値の自由度が低いため最適な予測画像の作成は困難と言えるが、式2a、式2bを用いた2つの式からなる固定式を2枚の参照ピクチャの位置関係によって切り替える方法と比較すると線形予測式としてより効率の良い式を生成することができる。   Compared with the method of performing linear prediction using the weighting coefficient set using Equation 1, it can be said that it is difficult to create an optimal prediction image because the degree of freedom of the coefficient value is low. However, two methods using Equation 2a and Equation 2b are difficult. A more efficient expression can be generated as a linear prediction expression when compared with a method in which a fixed expression consisting of an expression is switched according to the positional relationship between two reference pictures.

なお、第1参照インデックスおよび第2参照インデックスが同じピクチャを参照している場合は、T1=T2となってしまい、式11a、式12aが成立しない。そこで、参照される2枚のピクチャが同じ表示順情報を持つ場合はV1およびV2の値として1/2を用いて線形予測を行うものとする。その場合の線形予測式は下記のようになる。   When the first reference index and the second reference index refer to the same picture, T1 = T2, and Expressions 11a and 12a are not satisfied. Thus, when two referenced pictures have the same display order information, linear prediction is performed using 1/2 as the values of V1 and V2. In this case, the linear prediction formula is as follows.

V1=1/2
V2=1/2
P(i)=1/2×Q1(i)+1/2×Q2(i)
V1 = 1/2
V2 = 1/2
P (i) = 1/2 * Q1 (i) + 1/2 * Q2 (i)

また、第1参照インデックスおよび第2参照インデックスが異なるピクチャを参照しているが、それらのピクチャが同じ表示順情報を持つ場合にも、T1=T2となってしまい、式11a、式12aが成立しない。このように、参照される2枚のピクチャが同じ表示順情報を持つ場合はV1およびV2の値として1/2を用いて線形予測を行うものとする。   In addition, when the first reference index and the second reference index refer to different pictures, but these pictures have the same display order information, T1 = T2, and Expressions 11a and 12a are satisfied. do not do. In this way, when two referenced pictures have the same display order information, linear prediction is performed using 1/2 as the values of V1 and V2.

このように、参照される2枚のピクチャが同じ表示順情報を持つ場合には、予め設定された値を係数として用いる構成とすればよい。予め設定された値を係数としては、上記の1/2の例のように同じ重みを有する係数としてもよい。   In this way, when two referenced pictures have the same display order information, a configuration may be adopted in which a preset value is used as a coefficient. The preset value may be a coefficient having the same weight as in the above half example.

ところで、上記の実施の形態のように式10を用いると、線形予測を行うために乗算および除算が必要となる。式10による線形予測演算は符号化対象ブロック内の全ての画素に対して演算を行うため、乗算が加わることによる処理量の増加は非常に大きなものとなる。   By the way, when Expression 10 is used as in the above embodiment, multiplication and division are required to perform linear prediction. Since the linear prediction calculation according to Equation 10 is performed on all the pixels in the encoding target block, an increase in processing amount due to the addition of multiplication is very large.

そこで、実施の形態2の考え方と同様にして、V1およびV2を2のべき乗に近似することにより、線形予測の演算をシフト演算のみで行うことを可能とし、処理量の削減を図ることができる。その場合の線形予測式として、式11a、式12aの代わりに式11b、式12bを用いる。ただし、v1およびv2は整数とする。   Therefore, in the same way as the concept of the second embodiment, by approximating V1 and V2 to the power of 2, it is possible to perform the linear prediction operation only by the shift operation and reduce the amount of processing. . As a linear prediction formula in that case, Formula 11b and Formula 12b are used instead of Formula 11a and Formula 12a. However, v1 and v2 are integers.

V1=±pow(2,v1)=apx((T2−T0)/(T2−T1)) (式11b)
V2=±pow(2,v2)=apx((T0−T1)/(T2−T1)) (式12b)
(pow(2,v1)は2のv1乗を、pow(2,v2)は2のv2乗を示す。)
(=apx()は()内の値を左辺の値に近似することを示す。)
V1 = ± pow (2, v1) = apx ((T2-T0) / (T2-T1)) (Formula 11b)
V2 = ± pow (2, v2) = apx ((T0-T1) / (T2-T1)) (Formula 12b)
(Pow (2, v1) indicates 2 to the power of v1, and pow (2, v2) indicates the power of 2 to the power of v2.)
(= Apx () indicates that the value in () is approximated to the value on the left side.)

なお、式11a、式12aの代わりに式11c、式12cを用いることも可能である。
ただし、v1は整数とする。
In addition, it is also possible to use Formula 11c and Formula 12c instead of Formula 11a and Formula 12a.
However, v1 is an integer.

V1=±pow(2,v1)=apx((T2−T0)/(T2−T1)) (式11c)
V2=1−V1 (式12c)
(pow(2,v1)は2のv1乗を示す。)
(=apx()は()内の値を左辺の値に近似することを示す。)
V1 = ± pow (2, v1) = apx ((T2-T0) / (T2-T1)) (Formula 11c)
V2 = 1-V1 (Formula 12c)
(Pow (2, v1) indicates 2 to the power of v1.)
(= Apx () indicates that the value in () is approximated to the value on the left side.)

なお、式11a、式12aの代わりに式11d、式12dを用いることも可能である。ただし、v1は整数とする。   In addition, it is also possible to use Formula 11d and Formula 12d instead of Formula 11a and Formula 12a. However, v1 is an integer.

V1=1−V2 (式11d)
V2=±pow(2,v2)=apx((T0−T1)/(T2−T1)) (式12d)
(pow(2,v2)は2のv2乗を示す。)
(=apx()は()内の値を左辺の値に近似することを示す。)
V1 = 1-V2 (Formula 11d)
V2 = ± pow (2, v2) = apx ((T0-T1) / (T2-T1)) (Formula 12d)
(Pow (2, v2) indicates 2 to the square of v2)
(= Apx () indicates that the value in () is approximated to the value on the left side.)

なお、2のべき乗への近似の方法は、式11bを例にとると、v1の値を1ずつ変化させたとき、±pow(2,v1)と(T2−T0)/(T2−T1)とが最も近くなるときの±pow(2,v1)の値とする。   As an approximation method to the power of 2, taking Expression 11b as an example, when the value of v1 is changed by 1, ± pow (2, v1) and (T2-T0) / (T2-T1) Is the value of ± pow (2, v1) when.

例として図39において、符号化対象ピクチャが16番、第1参照インデックスによって指定されたピクチャが11番、第2参照インデックスによって指定されたピクチャが10番とすると、それぞれのピクチャの表示順情報は15、13、10となるため、(T2−T0)/(T2−T1)および±pow(2,v1)は下記のようになる。   For example, in FIG. 39, if the encoding target picture is No. 16, the picture specified by the first reference index is No. 11, and the picture specified by the second reference index is No. 10, the display order information of each picture is Since it is 15, 13, and 10, (T2-T0) / (T2-T1) and ± pow (2, v1) are as follows.

(T2−T0)/(T2−T1)=(10−15)/(10−13)=5/3
+pow(2,0)=1、+pow(2,1)=2
(T2-T0) / (T2-T1) = (10-15) / (10-13) = 5/3
+ Pow (2,0) = 1, + pow (2,1) = 2

5/3は1よりも2に近いため、近似の結果V1=2となる。   Since 5/3 is closer to 2 than 1, the approximation result V1 = 2.

また、別の近似の方法として、表示順情報T1およびT2の2つの値の関係によって切り上げによる近似、切り下げによる近似を切り替えることも可能である。   As another approximation method, the approximation by rounding up and the approximation by rounding down can be switched according to the relationship between the two values of the display order information T1 and T2.

その場合、T1がT2よりも時間的に後方にある場合は、V1およびV2の両者に対して切り上げによる近似を行い、T1がT2よりも時間的に前方にある場合は、V1およびV2の両者に対して切り下げによる近似を行う。逆に、T1がT2よりも時間的に後方にある場合は、V1およびV2の両者に対して切り下げによる近似を行い、T1がT2よりも時間的に前方にある場合は、V1およびV2の両者に対して切り上げによる近似を行うことも可能である。   In that case, when T1 is temporally behind T2, both V1 and V2 are approximated by rounding up. When T1 is temporally ahead of T2, both V1 and V2 are approximated. Is approximated by rounding down. Conversely, if T1 is behind T2 in time, both V1 and V2 are approximated by rounding down. If T1 is ahead in time from T2, both V1 and V2 are approximated. It is also possible to approximate by rounding up.

また、別の表示順情報を用いた近似の方法として、T1がT2よりも時間的に後方にある場合は、V1に関する式においては切り上げによる近似を行い、V2に関する式においては切り下げによる近似を行う。これにより2つの係数の値が互いに離れるため、外挿補間に適した値が得られやすくなる。逆に、T1がT2よりも時間的に前方にある場合は、V1に関する式とV2に関する式とでその両者の値を比較したときに、値の小さい方は切り上げによる近似を行い、値の大きい方は切り下げによる近似を行う。これにより2つの係数の値が互いに近づくため、内挿補間に適した値が得られやすくなる。   Further, as another approximation method using display order information, when T1 is temporally behind T2, approximation is performed by rounding up in the formula for V1, and approximation by rounding down is performed in the formula for V2. . As a result, the values of the two coefficients are separated from each other, making it easy to obtain a value suitable for extrapolation. Conversely, when T1 is temporally ahead of T2, when the values of V1 and V2 are compared, the smaller value is approximated by rounding up, and the value is larger. The method is approximated by rounding down. As a result, since the values of the two coefficients are close to each other, it is easy to obtain a value suitable for interpolation.

例として図39において、符号化対象ピクチャが16番、第1参照インデックスによって指定されたピクチャが11番、第2参照インデックスによって指定されたピクチャが10番とすると、それぞれのピクチャの表示順情報は15、13、10となり、T1はT2よりも時間的に後方にあるため、V1に関する式においては切り上げによる近似を行い、V2に関する式においては切り下げによる近似を行う。その結果、式11bおよび式12bは下記のように計算される。   For example, in FIG. 39, if the encoding target picture is No. 16, the picture specified by the first reference index is No. 11, and the picture specified by the second reference index is No. 10, the display order information of each picture is 15, 13 and 10, and T1 is behind the time T2, so the approximation for the V1 is approximated by rounding up, and the formula for V2 is approximated by rounding down. As a result, Equations 11b and 12b are calculated as follows.

(1)式11bについて
(T2−T0)/(T2−T1)=(10−15)/(10−13)=5/3
+pow(2,0)=1、+pow(2,1)=2
(1) About Formula 11b
(T2-T0) / (T2-T1) = (10-15) / (10-13) = 5/3
+ Pow (2,0) = 1, + pow (2,1) = 2

切り上げによる近似を行った結果V1=2となる。   As a result of approximation by rounding up, V1 = 2.

(2)式12bについて
(T0−T1)/(T2−T1)=(15−13)/(10−13)=−2/3
−pow(2,0)=−1、−pow(2,−1)=−1/2
(2) About Formula 12b
(T0-T1) / (T2-T1) = (15-13) / (10-13) =-2/3
-Pow (2,0) =-1, -pow (2, -1) =-1/2

切り下げによる近似を行った結果V2=−1となる。なお、上記実施の形態では線形予測の式は式10の1つであったが、従来の技術で説明した式2aおよび式2bの2つの式からなる固定式による線形予測方法と組み合わせて用いることも可能である。その場合、式2aの代わりに式10を使用し、式2bはそのまま使用する。つまり、第1参照インデックスによって指定されるピクチャが第2参照インデックスによって指定されるピクチャよりも表示順において後ろにある場合は式10を使用し、それ以外の場合は式2bを使用する。   As a result of approximation by rounding down, V2 = -1. In the above embodiment, the linear prediction formula is one of the formulas 10. However, the linear prediction formula should be used in combination with the linear prediction method based on the fixed formula composed of the two formulas 2a and 2b described in the prior art. Is also possible. In that case, Equation 10 is used instead of Equation 2a, and Equation 2b is used as it is. That is, Expression 10 is used when the picture specified by the first reference index is behind the picture specified by the second reference index in the display order, and Expression 2b is used otherwise.

また逆に、式2bの代わりに式10を使用し、式2aはそのまま使用することも可能である。つまり、第1参照インデックスによって指定されるピクチャが第2参照インデックスによって指定されるピクチャよりも表示順において後ろにある場合は式2aを使用し、それ以外の場合は式10を使用する。ただし、このとき参照される2枚のピクチャが同じ表示順情報を持つ場合はV1およびV2の値として1/2を用いて線形予測を行う。   On the contrary, it is also possible to use expression 10 instead of expression 2b and use expression 2a as it is. That is, Expression 2a is used when the picture specified by the first reference index is behind the picture specified by the second reference index in the display order, and Expression 10 is used otherwise. However, when two pictures referred to at this time have the same display order information, linear prediction is performed using 1/2 as the values of V1 and V2.

また、実施の形態3の考え方と同様にして、係数Cのみをスライスヘッダ領域に記述して線形予測に使用することも可能である。その場合、式10の代わりに式13を用いる。V1およびV2の求め方は上記実施の形態と同様である。   Similarly to the concept of the third embodiment, it is also possible to describe only the coefficient C in the slice header area and use it for linear prediction. In that case, Equation 13 is used instead of Equation 10. The method for obtaining V1 and V2 is the same as in the above embodiment.

P(i)=V1×(Q1(i)+C1)+V2×(Q2(i)+C2) (式13)   P (i) = V1 × (Q1 (i) + C1) + V2 × (Q2 (i) + C2) (Formula 13)

係数を生成するための処理が必要になり、さらに、スライスヘッダ領域に係数データを符号化する必要があるが、V1およびV2の精度が低い場合でもC1およびC2を用いることによってより高い精度の線形予測を行うことが可能となる。特にV1およびV2を2のべき乗に近似して線形予測を行う場合において有効である。   A process for generating coefficients is required, and further, coefficient data needs to be encoded in the slice header area. Even when the accuracy of V1 and V2 is low, higher accuracy linearity is obtained by using C1 and C2. It is possible to make a prediction. This is particularly effective when linear prediction is performed by approximating V1 and V2 to powers of 2.

なお、式13を用いた場合の線形予測では、1つのピクチャに1つの参照インデックスが割り当てられている場合でも、また、1つのピクチャに複数の参照インデックスが割り当てられている場合でも、同様に扱うことが可能である。   In the linear prediction using Equation 13, even when one reference index is assigned to one picture or when a plurality of reference indexes are assigned to one picture, the same is handled. It is possible.

なお、式11a、式12a、式11b、式12b、式11c、式12c、式11d、式12dの各式の値の計算では、取り得る値の組み合わせがスライスごとにある程度限られているため、スライスを符号化する再に1度だけ演算を行っておけばよく、式10や式13のように符号化対象ブロックのすべての画素に対して演算を行う必要はないため、全体の処理量への影響は小さいと考えられる。   In addition, in the calculation of the values of the equations 11a, 12a, 11b, 12b, 11c, 12c, 11d, and 12d, possible combinations of values are limited to some extent for each slice. It is only necessary to perform the calculation once for encoding the slice, and it is not necessary to perform the calculation for all the pixels of the encoding target block as in Expression 10 and Expression 13, so that the total processing amount is reduced. The effect of is considered to be small.

なお、本発明の実施の形態における表示順情報は、表示の順番に限定されるものではなく、実際の表示時間や、表示時間に伴って値が大きくなる所定のピクチャを基準とした各ピクチャの参照順序であっても良い。   Note that the display order information in the embodiment of the present invention is not limited to the display order, but the actual display time or the predetermined picture whose value increases with the display time is used as a reference. The reference order may be used.

(実施の形態5)
本発明の実施の形態5における動画像符号化方法について説明する。なお、符号化装置の構成および符号化の処理の流れおよび参照インデックスの割り当て方法は実施の形態1と全く同様であるため、ここでは説明を省略する。
(Embodiment 5)
A video encoding method according to Embodiment 5 of the present invention will be described. Note that the configuration of the encoding device, the flow of the encoding process, and the method of assigning the reference index are exactly the same as those in the first embodiment, and thus description thereof is omitted here.

従来の方法では固定式を用いて予測画像の生成を行う場合と、線形予測係数の重み付け係数セットを用いて予測画像の生成を行う場合とを符号列のピクチャ共通情報部分に記述されるフラグを用いることによって必要に応じて切り替えることを可能としていた。   In the conventional method, a flag described in the picture common information portion of the code string is used to generate a predicted image using a fixed formula and to generate a predicted image using a weighted coefficient set of linear prediction coefficients. By using it, it was possible to switch as needed.

本実施の形態では、さらに実施の形態1から実施の形態4で説明した各種の線形予測方法をフラグを用いて切り替える方法について説明する。   In the present embodiment, a method of switching various linear prediction methods described in the first to fourth embodiments using a flag will be described.

図17(a)は、上記切り替えを制御するための5つのフラグ(p_flag、c_flag、d_flag、t_flag、s_flag)を符号列中のスライスヘッダ領域に記述する場合の構成である。   FIG. 17A shows a configuration in which five flags (p_flag, c_flag, d_flag, t_flag, s_flag) for controlling the switching are described in a slice header area in the code string.

図17(b)に示したように、p_flagは重み付け係数が符号化されているかどうかを示すためのフラグである。また、c_flagはref1用およびref2用のパラメータのうち、パラメータC(C1およびC2)に関するデータのみが符号化されているかどうかを示すフラグである。また、t_flagは線形予測を行うための重み付け係数を参照ピクチャの表示順情報を用いて生成するかどうかを示すフラグである。また、s_flagは線形予測を行うための重み付け係数をシフト演算で計算ができるように2のべき乗に近似するかどうかを示すフラグである。   As shown in FIG. 17B, p_flag is a flag for indicating whether or not the weighting coefficient is encoded. C_flag is a flag indicating whether or not only data related to the parameter C (C1 and C2) is encoded among the parameters for ref1 and ref2. Further, t_flag is a flag indicating whether or not a weighting coefficient for performing linear prediction is generated using display order information of reference pictures. Further, s_flag is a flag indicating whether a weighting coefficient for performing linear prediction is approximated to a power of 2 so that it can be calculated by a shift operation.

また、d_flagは式2aおよび式2bで示されたような、予め設定されている2つの固定式を用いて線形予測を行う際に、ref1によって指定されるピクチャとref2によって指定されるピクチャの時間的な位置関係によって2つの式を切り替えるかどうかを示すフラグである。つまり、このフラグによって切り替えるように指定された場合は、従来の方法と同様に、ref1によって指定されるピクチャがref2によって指定されるピクチャよりも表示順において後にある場合は式2aを使用し、それ以外の場合は式2bを使用して線形予測を行う。一方、このフラグによって切り替えを行わないように指定された場合は、ref1によって指定されるピクチャがref2によって指定されるピクチャの位置関係に関係なく、常に式2bを使用して線形予測を行う。   Also, d_flag is the time between the picture specified by ref1 and the picture specified by ref2 when performing linear prediction using two preset fixed expressions as shown in Expression 2a and Expression 2b. It is a flag indicating whether or not two expressions are switched depending on the positional relationship. In other words, if it is specified to switch by this flag, as in the conventional method, if the picture specified by ref1 is later in the display order than the picture specified by ref2, use Equation 2a. Otherwise, linear prediction is performed using Equation 2b. On the other hand, when it is specified not to switch by this flag, linear prediction is always performed using Expression 2b regardless of the positional relationship between the picture specified by ref1 and the picture specified by ref2.

なお、切り替えずに使用する式を式2bの代わりに式2aを用いた場合も同様に扱うことが可能である。   It should be noted that the expression used without switching can be handled in the same manner when the expression 2a is used instead of the expression 2b.

図1に示す符号化装置では動き補償符号化部107において、各スライスごとに、重み付け係数セットに関するデータを符号化するか否かを決定し、それに基づいてフラグp_flagの情報を符号列生成部103に出力し、図17(a)に示すように符号列中に記述する。これによって、処理能力の高い装置では重み付け係数セットを使用して線形予測を行い、処理能力の低い装置では重み付け係数セットを使用せずに線形予測を行うといった使い分けが可能となる。   In the encoding apparatus shown in FIG. 1, the motion compensation encoding unit 107 determines whether or not data related to the weighting coefficient set is encoded for each slice, and based on this, the information of the flag p_flag is stored in the code string generation unit 103. And described in the code string as shown in FIG. As a result, it is possible to selectively use such that a device with high processing capability performs linear prediction using a weighting coefficient set and a device with low processing capability performs linear prediction without using a weighting coefficient set.

同様に、図1に示す符号化装置では動き補償符号化部107において、各スライスごとに、画像データのDC成分に相当するパラメータC(C1およびC2)に関するデータのみ符号化するか否かを決定し、それに基づいてフラグc_flagの情報を符号列生成部103に出力し、図17(a)に示すように符号列中に記述する。これによって、処理能力の高い装置では全ての重み付け係数セットを使用して線形予測を行い、処理能力の低い装置では直流成分のみを使用して線形予測を行うといった使い分けが可能となる。   Similarly, in the encoding apparatus shown in FIG. 1, the motion compensation encoding unit 107 determines whether to encode only data related to the parameter C (C1 and C2) corresponding to the DC component of the image data for each slice. Based on this, information on the flag c_flag is output to the code string generation unit 103 and described in the code string as shown in FIG. As a result, it is possible to selectively use linear prediction using all weighting coefficient sets in a device with high processing capability, and linear prediction using only a DC component in a device with low processing capability.

同様に、図1に示す符号化装置では動き補償符号化部107において、各スライスごとに、固定式を使用して線形予測を行う場合に、2つの式を切り替えて符号化するか否かを決定し、それに基づいてフラグd_flagの情報を符号列生成部103に出力し、図17(a)に示すように符号列中に記述する。これによって、画面の明度が時間的にほとんど変わらないような場合は片方の固定式のみを用いて線形予測を行い、画面の明度が時間的に変化するような場合は2つの固定式を切り替えて使用して線形予測を行うといった使い分けが可能となる。   Similarly, in the encoding apparatus shown in FIG. 1, in the motion compensation encoding unit 107, when linear prediction is performed using a fixed expression for each slice, whether to perform encoding by switching between the two expressions is determined. Based on the determination, the flag d_flag information is output to the code string generation unit 103 and described in the code string as shown in FIG. As a result, when the brightness of the screen hardly changes in time, linear prediction is performed using only one fixed formula, and when the brightness of the screen changes in time, the two fixed formulas are switched. It is possible to selectively use such as performing linear prediction.

同様に、図1に示す符号化装置では動き補償符号化部107において、各スライスごとに、線形予測を行うための係数を参照ピクチャの表示順情報を用いて生成するか否かを決定し、それに基づいてフラグt_flagの情報を符号列生成部103に出力し、図17(a)に示すように符号列中に記述する。これによって、符号量に余裕がある場合は重み付け係数セットを符号化して線形予測を行い、符号量に余裕がない場合は表示順情報から係数を生成して線形予測を行うといった使い分けが可能となる。   Similarly, in the encoding apparatus shown in FIG. 1, the motion compensation encoding unit 107 determines whether to generate a coefficient for performing linear prediction using the display order information of the reference picture for each slice, Based on this, the information of the flag t_flag is output to the code string generation unit 103 and described in the code string as shown in FIG. As a result, when there is a margin in the code amount, linear prediction is performed by encoding the weighting coefficient set, and when there is no margin in the code amount, a coefficient is generated from the display order information and linear prediction is performed. .

同様に、図1に示す符号化装置では動き補償符号化部107において、各スライスごとに、線形予測を行うための係数をシフト演算で計算できるように2のべき乗に近似するか否かを決定し、それに基づいてフラグs_flagの情報を符号列生成部103に出力し、図17(a)に示すように符号列中に記述する。これによって、処理能力の高い装置では重み付け係数を近似しないで使用して線形予測を行い、処理能力の低い装置では重み付け係数を2のべき乗に近似して使用しシフト演算で実現できる線形予測を行うといった使い分けが可能となる。   Similarly, in the encoding apparatus shown in FIG. 1, the motion compensation encoding unit 107 determines, for each slice, whether to approximate a power of 2 so that a coefficient for performing linear prediction can be calculated by a shift operation. Based on this, information on the flag s_flag is output to the code string generation unit 103 and described in the code string as shown in FIG. As a result, a device with high processing capability performs linear prediction using the weighting coefficient without approximation, and a device with low processing capability performs linear prediction that can be realized by a shift operation using the weighting factor approximating a power of 2. It can be used properly.

例えば、(1)(p、c、d、t、s_flag)=(1、0、0、0、1)である場合
は、全ての重み付け係数セットが符号化され、実施の形態2で説明したように、係数を2のべき乗で表すことによりシフト演算のみで線形予測を行い予測画像を生成したことが示される。
For example, when (1) (p, c, d, t, s_flag) = (1, 0, 0, 0, 1), all the weighting coefficient sets are encoded and described in the second embodiment. Thus, by expressing the coefficient as a power of 2, it is indicated that the prediction image is generated by performing the linear prediction only by the shift operation.

また、(2)(p、c、d、t、s_flag)=(1、1、1、0、0)である場合は、パラメータC(C1およびC2)に関するデータのみが符号化され、実施の形態3で説明した固定式に係数Cを加えることによって予測画像を生成する方法を用い、さらに2つの固定式を切り替えて使用したことが示される。   When (2) (p, c, d, t, s_flag) = (1, 1, 1, 0, 0), only data related to the parameter C (C1 and C2) is encoded, and It is shown that the method of generating a prediction image by adding the coefficient C to the fixed formula described in the third embodiment and switching between two fixed formulas are used.

また、(3)(p、c、d、t、s_flag)=(0、0、0、0、0)である場合は、重み付け係数セットは何も符号化されない。つまり、従来の方法である固定式のうち式2bのみを用いた予測画像の生成方法を用いたことが示される。   When (3) (p, c, d, t, s_flag) = (0, 0, 0, 0, 0), no weighting coefficient set is encoded. That is, it is shown that the prediction image generation method using only the equation 2b among the conventional fixed methods is used.

また、(4)(p、c、d、t、s_flag)=(0、0、1、1、1)である場合は、重み付け係数セットは何も符号化されないが、実施の形態4で説明したように、重み付け係数を参照ピクチャの表示順情報から生成し、さらに係数を2のべき乗で近似することによりシフト演算のみで線形予測を行い、さらに2つの固定式を切り替えて使用して予測画像を生成したことが示される。   When (4) (p, c, d, t, s_flag) = (0, 0, 1, 1, 1), no weighting coefficient set is encoded. As described above, the weighting coefficient is generated from the display order information of the reference picture, and further, the coefficient is approximated by a power of 2 to perform linear prediction only by the shift operation, and the two fixed expressions are switched and used as a predicted image. Is generated.

なお、上記実施の形態では各々1ビットからなる5つのフラグ(p_flag、c_flag、d_flag、t_flag、s_flag)を用いて判別を行っているが、5つのフラグの代わりに5ビットからなる1つのフラグのみで表現することも可能である。また、その場合、5ビットで表現するのではなく可変長符号化を用いて符号化することも可能である。   In the above embodiment, the determination is performed using five flags (p_flag, c_flag, d_flag, t_flag, s_flag) each having one bit, but only one flag having five bits is used instead of the five flags. It can also be expressed as In this case, it is also possible to encode using variable length coding instead of expressing with 5 bits.

なお、上記実施の形態では各々1ビットからなる5つのフラグ(p_flag、c_flag、d_flag、t_flag、s_flag)を全て用いているが、そのうちの1部分のフラグのみを用いて線形予測方法の切り替えを行う場合も同様に扱うことが可能である。その場合、図17(a)に示したフラグは必要なもののみを符号化して記述することになる。   In the above embodiment, all five flags (p_flag, c_flag, d_flag, t_flag, and s_flag) each consisting of 1 bit are used, but the linear prediction method is switched using only one of the flags. The case can be handled in the same way. In that case, only the necessary flags shown in FIG. 17A are encoded and described.

従来の方法では、固定式を用いた予測画像の生成と、線形予測係数の重み付け係数セットを用いた予測画像の生成とを切り替えるためのフラグを符号列のピクチャ共通情報部分に設けて、ピクチャ単位で切り替えることを可能としていた。しかし、この方法であると、ピクチャ毎にしか予測画像の生成方法を切り替えることができなかった。   In the conventional method, a flag for switching between generation of a prediction image using a fixed expression and generation of a prediction image using a weighted coefficient set of linear prediction coefficients is provided in the picture common information portion of the code string, and It was possible to switch with. However, with this method, the prediction image generation method can be switched only for each picture.

しかし、本実施の形態で説明したように、この切り替えフラグを符号列のスライスヘッダに設けるようにして、ピクチャを構成するスライスごとにいずれの方法で予測画像を生成するかを切り替えることを可能とすることにより、例えば、複雑な画像を持つスライスでは重み付け係数セットを用いた予測画像の生成を行い、単純な画像を持つスライスでは固定式を用いた予測画像の生成を行うことにより、処理量の増加を最小限に抑えつつ画質の向上を図ることが可能となる。   However, as described in the present embodiment, by providing this switching flag in the slice header of the code string, it is possible to switch which method is used to generate a predicted image for each slice constituting the picture. For example, in a slice having a complex image, a prediction image is generated using a weighting coefficient set, and in a slice having a simple image, a prediction image is generated using a fixed formula, thereby reducing the processing amount. It is possible to improve the image quality while minimizing the increase.

なお、上記実施の形態ではスライスヘッダ領域に5つのフラグ(p_flag、c_flag、d_flag、t_flag、s_flag)を記述してスライスごとに判別を行っているが、ピクチャ共通情報領域にこれらのフラグを記述することにより、ピクチャ単位で切り替えるようにすることも可能である。また、スライスを構成するブロックごとに切り替えフラグを設けることにより、さらにブロック単位で最適な方法で予測画像の生成を行うことも可能である。   In the embodiment described above, five flags (p_flag, c_flag, d_flag, t_flag, s_flag) are described in the slice header area, and discrimination is performed for each slice. However, these flags are described in the picture common information area. Thus, it is also possible to switch in units of pictures. Further, by providing a switching flag for each block constituting the slice, it is possible to generate a predicted image by an optimum method in units of blocks.

なお、本発明の実施の形態における表示順情報は、表示の順番に限定されるものではなく、実際の表示時間や、表示時間に伴って値が大きくなる所定のピクチャを基準とした各ピクチャの参照順序であっても良い。   Note that the display order information in the embodiment of the present invention is not limited to the display order, but the actual display time or the predetermined picture whose value increases with the display time is used as a reference. The reference order may be used.

(実施の形態6)
図2は、本発明の実施の形態6における動画像復号化装置の構成を示すブロック図である。この動画像復号化装置における動画像復号化方法を図2に示したブロック図を用いて(1)復号化の概要、(2)参照インデックス割り当て方法、(3)予測画像生成方法の順で説明する。ただし、以下の説明では実施の形態1の動画像符号化方法で生成された符号列が入力されるものとする。
(Embodiment 6)
FIG. 2 is a block diagram showing a configuration of the moving picture decoding apparatus according to Embodiment 6 of the present invention. The moving picture decoding method in this moving picture decoding apparatus will be described in the order of (1) the outline of decoding, (2) the reference index assignment method, and (3) the predicted picture generation method, using the block diagram shown in FIG. To do. However, in the following description, it is assumed that a code string generated by the moving picture coding method of Embodiment 1 is input.

(1)復号化の概要
まず入力された符号列から符号列解析部201によって、スライスヘッダ領域から線形予測用の重み付け係数セットのデータ列、および参照インデックス割り当て用コマンド列を、さらにブロック符号化情報領域から参照インデックスおよび動きベクトル情報および予測残差符号化データ等の各種の情報が抽出される。図6は前記符号化情報が符号列に含まれている様子を示した図である。
(1) Overview of Decoding First, the code sequence analysis unit 201 from the input code sequence further converts the data sequence of the weighting coefficient set for linear prediction and the command sequence for reference index assignment from the slice header region, and further performs block encoding information. Various information such as a reference index, motion vector information, and prediction residual encoded data is extracted from the region. FIG. 6 is a diagram illustrating a state in which the encoded information is included in a code string.

符号列解析部201で抽出された線形予測用の重み付け係数セットのデータ列は線形予測係数記憶部206に、参照インデックス割り当て用コマンド列は参照インデックス・ピクチャ番号変換部207に、参照インデックスは動き補償復号化部204に、動きベクトル情報は動きベクトル記憶部205に、予測残差符号化信号は予測残差復号化部202にそれぞれ出力される。   The data sequence of the weighting coefficient set for linear prediction extracted by the code sequence analysis unit 201 is stored in the linear prediction coefficient storage unit 206, the command sequence for reference index assignment is stored in the reference index / picture number conversion unit 207, and the reference index is motion compensated. The decoding unit 204 outputs the motion vector information to the motion vector storage unit 205 and the prediction residual encoded signal to the prediction residual decoding unit 202, respectively.

予測残差復号化部202では入力された残差符号化信号に対して、逆量子化、逆周波数変換等の画像復号化処理を施し残差復号化信号を出力する。加算演算部208では前記残差復号化信号と動き補償復号化部204から出力される予測画像信号との加算を行い再構成画像信号を生成し、得られた再構成画像信号は以降の画面間予測での参照に使用するため、および表示用に出力するためにピクチャメモリ203に格納される。   Prediction residual decoding section 202 performs image decoding processing such as inverse quantization and inverse frequency transform on the input residual encoded signal, and outputs a residual decoded signal. The addition operation unit 208 adds the residual decoded signal and the predicted image signal output from the motion compensation decoding unit 204 to generate a reconstructed image signal, and the obtained reconstructed image signal is transmitted between subsequent screens. It is stored in the picture memory 203 for use in reference for prediction and for output for display.

動き補償復号化部204では、動きベクトル記憶部205から入力される動きベクトルおよび符号列解析部201から入力される参照インデックスを用いて、ピクチャメモリ203に格納されている再構成画像信号から予測画像に最適な画像領域を取り出す。このとき、参照インデックス・ピクチャ番号変換部207において、符号列解析部201から与えられた参照インデックスとピクチャ番号との対応を取ることによりピクチャメモリ203中の参照ピクチャを指定する。   The motion compensation decoding unit 204 uses the motion vector input from the motion vector storage unit 205 and the reference index input from the code string analysis unit 201 to predict a predicted image from the reconstructed image signal stored in the picture memory 203. The optimal image area is extracted. At this time, the reference index / picture number conversion unit 207 designates the reference picture in the picture memory 203 by taking the correspondence between the reference index given from the code string analysis unit 201 and the picture number.

参照インデックス・ピクチャ番号変換部207における動作の詳細は(2)において詳しく説明する。さらに、得られた画像領域の画素値に対して動き補償復号化部204において線形予測による補間処理等の画素値変換処理を施すことによって最終的な予測画像を作成する。その際に使用する線形予測係数は線形予測係数記憶部206に格納されているデータから参照インデックスを検索キーとすることによって獲得される。   Details of the operation of the reference index / picture number conversion unit 207 will be described in detail in (2). Furthermore, a final predicted image is created by performing pixel value conversion processing such as interpolation processing by linear prediction in the motion compensation decoding unit 204 on the pixel values of the obtained image region. The linear prediction coefficient used at that time is acquired from the data stored in the linear prediction coefficient storage unit 206 using the reference index as a search key.

この予測画像生成方法については(3)において詳しく説明する。
上記の一連の処理によって生成された復号化画像はピクチャメモリ203に格納され、表示されるタイミングに従って表示用画像信号として出力される。
This predicted image generation method will be described in detail in (3).
The decoded image generated by the above series of processing is stored in the picture memory 203 and output as a display image signal according to the display timing.

以上の処理の流れは画面間予測復号化を行った場合の動作であったが、スイッチ209によって画面内予測復号化との切り替えがなされる。画面内復号化を行う場合は、動き補償による予測画像の生成は行わず、同一画面内の復号化済み領域から復号化対象領域の予測画像を生成し加算を行うことによって復号化画像を生成する。復号化画像は画面間予測復号化の場合と同様に、ピクチャメモリ203に格納され、表示されるタイミングに従って表示用画像信号として出力される。   The above processing flow is the operation when inter-screen predictive decoding is performed, but switching to intra-screen predictive decoding is performed by the switch 209. When intra-screen decoding is performed, a predicted image is not generated by motion compensation, and a decoded image is generated by generating a predicted image of a decoding target region from a decoded region in the same screen and performing addition. . The decoded image is stored in the picture memory 203 as in the case of inter-screen predictive decoding, and is output as a display image signal according to the display timing.

(2)参照インデックス割り当て方法
次に、図2の参照インデックス・ピクチャ番号変換部207における参照インデックス割り当て方法について図3、図4を用いて説明する。
(2) Reference Index Assignment Method Next, a reference index assignment method in the reference index / picture number conversion unit 207 in FIG. 2 will be described with reference to FIGS.

図3は、ピクチャ番号に対する2つの参照インデックスの割り当て方法を説明するための図である。図のような表示される順に並べられたピクチャ列があったとき、ピクチャ番号は復号化される順番に割り振られている。参照インデックスをピクチャ番号に割り当てるためのコマンドはピクチャをさらに分割した復号化単位であるスライスのヘッダに記述され、1つのスライスを復号化する毎に割り振り方が更新されることになる。前記コマンドは、直前に参照インデックスに割り当てたピクチャ番号と現在割り当てを行っているピクチャ番号との差分値を参照インデックスの数だけ連続して指示するものである。   FIG. 3 is a diagram for explaining a method of assigning two reference indexes to picture numbers. When there are picture sequences arranged in the order of display as shown in the figure, picture numbers are assigned in the order of decoding. A command for assigning a reference index to a picture number is described in the header of a slice, which is a decoding unit obtained by further dividing a picture, and the allocation method is updated every time one slice is decoded. The command sequentially indicates the difference value between the picture number assigned to the reference index immediately before and the picture number currently assigned by the number of reference indexes.

図3の第1参照インデックスの例を用いると、まずコマンドとして"−1"が与えられたので、現在復号化の対象としているピクチャ番号16番から1を引くことにより、ピクチャ番号15番が参照インデックス0番に割り当てられる。次に"−4"が与えられたので、直前に割り当てを行ったピクチャ番号15番から4を引くことにより、ピクチャ番号11番が参照インデックス1番に割り当てられる。以下同様の処理によって各ピクチャ番号の割り当てが行われる。第2参照インデックスの場合も同様である。   Using the example of the first reference index in FIG. 3, first, “−1” is given as a command. Therefore, by subtracting 1 from the picture number 16 currently being decoded, the picture number 15 is referred to. Assigned to index number 0. Next, since “−4” is given, the picture number 11 is assigned to the reference index 1 by subtracting 4 from the picture number 15 assigned immediately before. Thereafter, each picture number is assigned by the same process. The same applies to the second reference index.

図34に示した従来の方法による参照インデックス割り当て方法では、全ての参照インデックスはそれぞれ別々のピクチャ番号に対応付けられている。一方、図3の例では、割り当て方法は従来のものと全く同じ方法を用いているが、コマンドの値を変更することに
より同じピクチャ番号に対して複数の参照インデックス番号が対応付けられている。
In the reference index assignment method according to the conventional method shown in FIG. 34, all reference indexes are associated with different picture numbers. On the other hand, in the example of FIG. 3, although the allocation method is exactly the same as the conventional one, a plurality of reference index numbers are associated with the same picture number by changing the command value.

図4は参照インデックスの割り当てを行った結果を示したものである。各ピクチャ番号には第1参照インデックスおよび第2参照インデックスがそれぞれ独立に割り当てられているが、1つのピクチャ番号に対して複数の参照インデックスが割り当てられているものもあることが分かる。本発明の復号化方法では、この例のように複数の参照インデックスが割り当てられているピクチャ番号が少なくとも1つ以上あるものとする。   FIG. 4 shows the result of assigning a reference index. The first reference index and the second reference index are independently assigned to each picture number, but it can be seen that there are some where a plurality of reference indexes are assigned to one picture number. In the decoding method of the present invention, it is assumed that there are at least one picture number to which a plurality of reference indexes are assigned as in this example.

参照インデックスを参照ピクチャの決定のみに使用する場合であれば、従来の方法のように1つのピクチャ番号に対して1つの参照インデックスを割り当てる方法が最も効率の良い方法である。しかし、参照インデックスを使用して予測画像の生成における線形予測係数の重み付け係数セットを選択する場合は、従来の方法では同じ参照ピクチャを持つブロック全てにおいて同じ線形予測係数を使用しなくてはならないため、最適な予測画像が生成されない可能性が非常に高くなってしまう。そこで、本発明のように1つのピクチャ番号に対して複数の参照インデックスが割り当てることを可能とすることにより、同じ参照ピクチャを持つ場合でも、ブロックごとに複数の線形予測係数の重み付け係数セットの候補の中から最適なものを選択することが可能となり、より予測精度の高い予測画像を生成することが可能となる。   If the reference index is used only for determining the reference picture, a method of assigning one reference index to one picture number as in the conventional method is the most efficient method. However, when using a reference index to select a weighting coefficient set of linear prediction coefficients in generating a predicted image, the conventional method must use the same linear prediction coefficient in all blocks having the same reference picture. Therefore, there is a very high possibility that an optimal predicted image will not be generated. Therefore, by allowing a plurality of reference indexes to be assigned to one picture number as in the present invention, a plurality of linear prediction coefficient weighting coefficient set candidates for each block even when having the same reference picture It is possible to select an optimal one from the above, and it is possible to generate a prediction image with higher prediction accuracy.

なお、以上の説明では全ての参照ピクチャが参照用メモリに蓄積されるものとしてピクチャ番号が与えられている場合の例を示していたが、ピクチャ番号は符号化を行った直前のピクチャが蓄積された場合のみ値が1つずつ増加していくものであり、蓄積されないピクチャがあった場合でも参照用メモリ内ではピクチャ番号の連続性は保たれ、前記方法をそのまま使用することが可能である。   In the above description, an example is shown in which a picture number is given assuming that all reference pictures are stored in the reference memory, but the picture number immediately before encoding is stored. In this case, the value is incremented by one, and even if there is a picture that is not stored, the continuity of picture numbers is maintained in the reference memory, and the method can be used as it is.

(3)予測画像生成方法
次に、図2の動き補償復号化部204における予測画像生成方法について図5を用いて説明する。線形予測による予測画像生成方法は従来法と全く同様であるが、同じピクチャに対して複数の参照インデックス番号を対応付けることが可能となったため、線形予測係数を選択する際の自由度が高くなっている。
(3) Predicted Image Generation Method Next, a predicted image generation method in the motion compensation decoding unit 204 in FIG. 2 will be described with reference to FIG. The prediction image generation method by linear prediction is exactly the same as the conventional method, but since it is possible to associate a plurality of reference index numbers with the same picture, the degree of freedom in selecting a linear prediction coefficient is increased. Yes.

ピクチャB16は現在復号化の対象としているBピクチャであり、ブロックBL01およびブロックBL02は前記Bピクチャに属する復号化対象のブロックである。BL01は第1参照ピクチャをピクチャP11、第2参照ピクチャをピクチャB15とし、それぞれのピクチャに属するブロックBL11およびBL21を参照して予測画像を作成する。同様にBL02も第1参照ピクチャをピクチャP11、第2参照ピクチャをピクチャB15とし、それぞれのピクチャに属するブロックBL12およびBL22を参照して予測画像を作成する。   A picture B16 is a B picture that is currently subject to decoding, and a block BL01 and a block BL02 are decoding target blocks belonging to the B picture. In BL01, the first reference picture is the picture P11, the second reference picture is the picture B15, and the prediction picture is created by referring to the blocks BL11 and BL21 belonging to the respective pictures. Similarly, BL02 also uses the first reference picture as the picture P11 and the second reference picture as the picture B15, and creates a predicted image by referring to the blocks BL12 and BL22 belonging to the respective pictures.

第1参照ピクチャおよび第2参照ピクチャはBL01、BL02共に同じものを参照しているが、(2)において説明した参照インデックスの割り当て方法を用いることにより、第1参照インデックスref1および第2参照インデックスref2はBL01とBL02とで異なる値を取ることが可能となる。図4を例にとると、ピクチャ番号11に対応する第1参照インデックスは1と3が、ピクチャ番号15に対応する第2参照インデックスは1と6が割り振られている。その結果、これらの参照インデックスの組み合わせは、(ref1、ref2)=(1、1)、(1、6)、(3、1)、(3、6)の4通りが考えられ、これらの中から最適な重み付け係数セットを導き出す組み合わせをブロックごとに選択することが可能となっている。図5では例としてBL01がref1=1、ref2=1、BL02がref1=3、ref2=6としている。   The first reference picture and the second reference picture both refer to the same BL01 and BL02, but by using the reference index assignment method described in (2), the first reference index ref1 and the second reference index ref2 Can take different values for BL01 and BL02. Taking FIG. 4 as an example, 1 and 3 are assigned to the first reference index corresponding to picture number 11, and 1 and 6 are assigned to the second reference index corresponding to picture number 15. As a result, there are four possible combinations of these reference indexes: (ref1, ref2) = (1, 1), (1, 6), (3, 1), (3, 6). It is possible to select a combination for deriving an optimal weighting coefficient set from each block. In FIG. 5, for example, BL01 is ref1 = 1, ref2 = 1, and BL02 is ref1 = 3 and ref2 = 6.

図35にあるような従来の方法によって対応付けられた参照インデックスの組み合わせでは、図5のような例ではBL01、BL02共に(ref1、ref2)=(1、1)の組み合わせしか選択できなかったため、選択することのできる線形予測係数の重み付け係数セットも1通りしかなかった。一方、本発明では選択範囲が4通りに拡張されているため、最適な重み付け係数セットが選択できる可能性が高くなると言える。   In the combination of reference indexes associated by the conventional method as shown in FIG. 35, only the combination of (ref1, ref2) = (1, 1) can be selected for both BL01 and BL02 in the example shown in FIG. There was also only one set of linear prediction coefficient weighting coefficients that could be selected. On the other hand, in the present invention, since the selection range is expanded in four ways, it can be said that there is a high possibility that an optimum weighting coefficient set can be selected.

1つのピクチャの符号列は、ピクチャ共通情報領域および複数のスライスデータ領域から構成される。図6はそのうちのスライスデータ領域の構成を示したものである。さらにスライスデータ領域は、スライスヘッダ領域および複数のブロックデータ領域から構成される。ここではブロックデータ領域の例として図5におけるBL01、BL02に対応する各ブロックの領域が示されている。   The code string of one picture is composed of a picture common information area and a plurality of slice data areas. FIG. 6 shows the structure of the slice data area. Furthermore, the slice data area includes a slice header area and a plurality of block data areas. Here, as an example of the block data area, the area of each block corresponding to BL01 and BL02 in FIG. 5 is shown.

BL01に含まれるref1およびref2はこのブロックが参照する2枚のピクチャを指し示す第1参照インデックスおよび第2参照インデックスをそれぞれ指示するものである。またスライスヘッダ領域には前記線形予測を行うための重み付け係数セットを与えるためのデータ(pset0、pset1、pset2、・・・・)がref1用およびref2用それぞれに記述されている。このときのpsetは(2)で説明した参照インデックスの個数と同じで数だけ設定することができる。つまり、図3のように第1参照インデックス、第2参照インデックスを共に0から9までの10個を使用した場合は、psetもref1用、ref2用共に0から9までの10個を設定することが可能である。   Ref1 and ref2 included in BL01 respectively indicate a first reference index and a second reference index indicating two pictures referred to by this block. In the slice header area, data (pset0, pset1, pset2,...) For giving a weighting coefficient set for performing the linear prediction is described for ref1 and ref2. The number of psets at this time is the same as the number of reference indexes described in (2), and can be set by the number. In other words, when 10 of the first reference index and the second reference index are used from 0 to 9 as shown in FIG. 3, 10 is set from 0 to 9 for both ref1 and ref2. Is possible.

図7は前記スライスヘッダ領域に含まれる前記重み付け係数セットの例を表に示したものである。識別子psetで示された各々のデータはw1、w2、c、dの4つ値を持ち、ref1およびref2の値によってダイレクトに参照できるように構成されている。また、スライスヘッダ領域には前記参照インデックスをピクチャ番号に割り当てるためのコマンド列idx_cmd1およびidx_cmd2が記述されている。   FIG. 7 is a table showing an example of the weighting coefficient set included in the slice header area. Each data indicated by the identifier pset has four values w1, w2, c, and d, and is configured so that it can be directly referred to by the values of ref1 and ref2. In the slice header area, command strings idx_cmd1 and idx_cmd2 for assigning the reference index to the picture number are described.

図6のBL01に記述されたref1およびref2によって図7のref1用およびref2用のテーブルからそれぞれ1組の重み付け係数セットが選択される。この2組の重み付け係数セットを用いて参照画像の画素値に対して線形予測を施すことによって予測画像を生成する。   One set of weighting coefficients is selected from the tables for ref1 and ref2 in FIG. 7 by ref1 and ref2 described in BL01 in FIG. A prediction image is generated by performing linear prediction on the pixel value of the reference image using the two sets of weighting coefficient sets.

ここで、重み付け係数セットを決定し予測画像を生成するまでの処理の流れについて詳細に説明する。   Here, the flow of processing from determination of a weighting coefficient set to generation of a predicted image will be described in detail.

図18は、図2の線形予測係数記憶部206と動き補償復号化部204における予測画像を生成する機能構成を示した機能ブロック図である。   FIG. 18 is a functional block diagram showing a functional configuration for generating a prediction image in the linear prediction coefficient storage unit 206 and the motion compensation decoding unit 204 in FIG.

線形予測係数記憶部206aと、線形予測係数記憶部206bと、平均値算出部204aと、線形予測演算部204bにより予測画像が生成される。   A prediction image is generated by the linear prediction coefficient storage unit 206a, the linear prediction coefficient storage unit 206b, the average value calculation unit 204a, and the linear prediction calculation unit 204b.

平均値算出部204aは、符号列解析部201より出力されるref1によって選択される1組の重み付け係数セット(w1_1,w2_1,c_1,d_1)を線形予測係数記憶部206aより獲得し、符号列解析部201より出力されるref2によって選択される1組の重み付け係数セット(w1_2,w2_2,c_2,d_2)を線形予測係数記憶部206bより獲得する。   The average value calculation unit 204a obtains one set of weighting coefficient sets (w1_1, w2_1, c_1, d_1) selected by ref1 output from the code sequence analysis unit 201 from the linear prediction coefficient storage unit 206a, and performs code sequence analysis. A set of weighting coefficients (w1_2, w2_2, c_2, d_2) selected by ref2 output from the unit 201 is acquired from the linear prediction coefficient storage unit 206b.

そして平均値算出部204aは、線形予測係数記憶部206a,206bより獲得したそれぞれの重み付け係数セットのパラメータごとの平均を取り、実際に線形予測に使用する重み付け係数セット(w1,w2,c,d)とし、線形予測演算部204bに出力する。線形予測演算部204bは、重み付け係数セット(w1,w2,c,d)を基に、式1を用いて予測画像を演算し出力する。   Then, the average value calculation unit 204a takes the average for each parameter of the respective weighting coefficient sets acquired from the linear prediction coefficient storage units 206a and 206b, and actually sets the weighting coefficient sets (w1, w2, c, d) used for the linear prediction. ) And output to the linear prediction calculation unit 204b. The linear prediction calculation unit 204b calculates and outputs a prediction image using Equation 1 based on the weighting coefficient set (w1, w2, c, d).

また、図19は予測画像を生成する他の機能構成を示す機能ブロック図である。線形予測係数記憶部206a,線形予測係数記憶部206b,線形予測演算部204c,線形予測演算部204d,および平均値算出部204eにより、予測画像が生成される。   FIG. 19 is a functional block diagram showing another functional configuration for generating a predicted image. A prediction image is generated by the linear prediction coefficient storage unit 206a, the linear prediction coefficient storage unit 206b, the linear prediction calculation unit 204c, the linear prediction calculation unit 204d, and the average value calculation unit 204e.

線形予測演算部204cは、符号列解析部201より出力されるref1によって選択される1組の重み付け係数セット(w1_1,w2_1,c_1,d_1)を線形予測係数記憶部206aより獲得し、その重み付け係数セットを基に、式1を用いて予測画像を演算して平均値算出部204eに出力する。   The linear prediction calculation unit 204c obtains a set of weighting coefficients (w1_1, w2_1, c_1, d_1) selected by ref1 output from the code string analysis unit 201 from the linear prediction coefficient storage unit 206a, and the weighting coefficients Based on the set, the predicted image is calculated using Equation 1 and output to the average value calculation unit 204e.

同様に、線形予測演算部204dは、符号列解析部201より出力されるref2によって選択される1組の重み付け係数セット(w1_2,w2_2,c_2,d_2)を線形予測係数記憶部206bより獲得し、その重み付け係数セットを基に式1を用いて予測画像を演算して平均値算出部204eに出力する。   Similarly, the linear prediction calculation unit 204d acquires, from the linear prediction coefficient storage unit 206b, one set of weighting coefficient sets (w1_2, w2_2, c_2, d_2) selected by ref2 output from the code string analysis unit 201, Based on the weighting coefficient set, a prediction image is calculated using Equation 1 and output to the average value calculation unit 204e.

平均値算出部204eは、線形予測演算部204c,線形予測演算部204dのそれぞれから出力される予測画像の各画素の平均値をとり、最終的な予測画像を生成し出力する。   The average value calculation unit 204e takes the average value of each pixel of the prediction image output from each of the linear prediction calculation unit 204c and the linear prediction calculation unit 204d, and generates and outputs a final prediction image.

図20(a)は、予測画像を生成する他の機能構成を示す機能ブロック図である。線形予測係数記憶部206c,線形予測係数記憶部206d,平均値算出部204f,線形予測演算部204gにより予測画像が生成される。   FIG. 20A is a functional block diagram showing another functional configuration for generating a predicted image. A prediction image is generated by the linear prediction coefficient storage unit 206c, the linear prediction coefficient storage unit 206d, the average value calculation unit 204f, and the linear prediction calculation unit 204g.

平均値算出部204fは、符号列解析部201より出力されるref1によって選択される1組の重み付け係数セット(w1_1、w2_1,c_1,d_1)のうち、c_1,d_1のパラメータを線形予測係数記憶部206cより獲得し、符号列解析部201より出力されるref2によって選択される1組の重み付け係数セット(w1_2、w2_2,c_2,d_2)のうち、c_2,d_2のパラメータを線形予測係数記憶部206dより獲得する。平均値算出部204fは、線形予測係数記憶部206cおよび線形予測係数記憶部206dより獲得したc_1とc_2の平均値と、d_1とd_2の平均値を算出してc、dを求め線形予測演算部204gに出力する。   The average value calculation unit 204f includes the parameters of c_1 and d_1 among the one set of weighting coefficient sets (w1_1, w2_1, c_1, and d_1) selected by ref1 output from the code string analysis unit 201. 206c, the parameters of c_2 and d_2 of one set of weighting coefficient sets (w1_2, w2_2, c_2, d_2) selected by ref2 output from the code string analysis unit 201 are obtained from the linear prediction coefficient storage unit 206d. To win. The average value calculation unit 204f calculates the average value of c_1 and c_2 acquired from the linear prediction coefficient storage unit 206c and the linear prediction coefficient storage unit 206d, and the average value of d_1 and d_2, and obtains c and d. Output to 204g.

また、線形予測演算部204gは、上記重み付け係数セット(w1_1、w2_1,c_1,d_1)のうち、w1_1のパラメータを線形予測係数記憶部206cより獲得し、上記重み付け係数セット(w1_2、w2_2,c_2,d_2)のうち、w2_2のパラメータを線形予測係数記憶部206dより獲得し、平均値算出部204fによりそれぞれの平均を求めてc、dを獲得して、式1を用いて予測画像を演算し出力する。   In addition, the linear prediction calculation unit 204g acquires the w1_1 parameter from the linear prediction coefficient storage unit 206c among the weighting coefficient sets (w1_1, w2_1, c_1, d_1), and obtains the weighting coefficient sets (w1_2, w2_2, c_2). d_2), the w2_2 parameter is acquired from the linear prediction coefficient storage unit 206d, the respective averages are obtained by the average value calculation unit 204f, c and d are acquired, and the prediction image is calculated using Equation 1 and output. To do.

すなわち、線形予測演算部204gは、線形予測係数記憶部206cより得られた重み付け係数セット(w1_1、w2_1,c_1,d_1)と、線形予測係数記憶部206dより得られた重み付け係数セット(w1_2、w2_2,c_2,d_2)のうち、実際に線形予測で使用する重み付け係数セット(w1、w2,c,d)を決定する際に、下記の規則を用いている。   That is, the linear prediction calculation unit 204g includes the weighting coefficient set (w1_1, w2_1, c_1, d_1) obtained from the linear prediction coefficient storage unit 206c and the weighting coefficient set (w1_2, w2_2) obtained from the linear prediction coefficient storage unit 206d. , C_2, d_2), the following rules are used when determining the weighting coefficient set (w1, w2, c, d) actually used in the linear prediction.

w1=w1_1,w2=w2_2,c=(c_1とc_2の平均),d=(d_1とd_2の平均)   w1 = w1_1, w2 = w2_2, c = (average of c_1 and c_2), d = (average of d_1 and d_2)

図20(b)は、予測画像を生成する他の機能構成を示す機能ブロック図である。線形予測係数記憶部206e,線形予測係数記憶部206f,線形予測演算部204hにより予測画像が生成される。   FIG. 20B is a functional block diagram showing another functional configuration for generating a predicted image. A prediction image is generated by the linear prediction coefficient storage unit 206e, the linear prediction coefficient storage unit 206f, and the linear prediction calculation unit 204h.

線形予測演算部204hは、符号列解析部201より出力されるref1によって選択される1組の重み付け係数セット(w1_1、w2_1,c_1,d_1)のうちの一部であるw1_1,c_1,d_1のパラメータを線形予測係数記憶部206eより獲得し、符号列解析部201より出力されるref2によって選択される1組の重み付け係数セット(w1_2、w2_2,c_2,d_2)のうちの一部であるw2_2のパラメータを線形予測係数記憶部206fより獲得する。線形予測演算部204hは、線形予測係数記憶部206e,線形予測係数記憶部206fより獲得したw1_1,c_1,d_1,w2_2を基に、式1を用いて、予測画像を演算し出力する。   The linear prediction calculation unit 204h is a parameter of w1_1, c_1, d_1 that is a part of one set of weighting coefficient sets (w1_1, w2_1, c_1, d_1) selected by ref1 output from the code string analysis unit 201. Is obtained from the linear prediction coefficient storage unit 206e, and a parameter of w2_2 which is a part of one set of weighting coefficient sets (w1_2, w2_2, c_2, d_2) selected by ref2 output from the code string analysis unit 201 Is obtained from the linear prediction coefficient storage unit 206f. The linear prediction calculation unit 204h calculates and outputs a prediction image using Equation 1 based on w1_1, c_1, d_1, and w2_2 acquired from the linear prediction coefficient storage unit 206e and the linear prediction coefficient storage unit 206f.

すなわち、線形予測演算部204hは、線形予測係数記憶部206eより得られた重み付け係数セット(w1_1、w2_1,c_1,d_1)と、線形予測係数記憶部206fより得られた重み付け係数セット(w1_2、w2_2,c_2,d_2)のうち、実際に線形予測で使用する重み付け係数セット(w1、w2,c,d)を決定する際に、下記の規則を用いている。   That is, the linear prediction calculation unit 204h includes the weighting coefficient set (w1_1, w2_1, c_1, d_1) obtained from the linear prediction coefficient storage unit 206e and the weighting coefficient set (w1_2, w2_2) obtained from the linear prediction coefficient storage unit 206f. , C_2, d_2), the following rules are used when determining the weighting coefficient set (w1, w2, c, d) that is actually used in the linear prediction.

w1=w1_1,w2=w2_2,c=c_1,d=d_1   w1 = w1_1, w2 = w2_2, c = c_1, d = d_1

また、w1、w2、c、dのパラメータのうちの1つもしくは複数個を固定の値として使用することも可能である。図21は図20(a)における機能構成に対して、dのみを固定の値として使用した場合の機能ブロック図である。線形予測係数記憶部206g,線形予測係数記憶部206h,平均値算出部204i、線形予測演算部204jにより予測画像が生成される。   It is also possible to use one or more of the parameters w1, w2, c, and d as fixed values. FIG. 21 is a functional block diagram when only d is used as a fixed value for the functional configuration in FIG. A prediction image is generated by the linear prediction coefficient storage unit 206g, the linear prediction coefficient storage unit 206h, the average value calculation unit 204i, and the linear prediction calculation unit 204j.

第1参照インデックスref1によって線形予測係数記憶部206gから選択される係数は(w1_1、c_1)のみであり、第2参照インデックスref2によって線形予測係数記憶部206hから選択される係数は(w2_2、c_2)のみである。平均値算出部204iは、線形予測係数記憶部206gおよび線形予測係数記憶部206hより獲得したc_1とc_2の平均値を算出してcを求め線形予測算出部204jに出力する。   The coefficients selected from the linear prediction coefficient storage unit 206g by the first reference index ref1 are only (w1_1, c_1), and the coefficients selected from the linear prediction coefficient storage unit 206h by the second reference index ref2 are (w2_2, c_2). Only. The average value calculation unit 204i calculates the average value of c_1 and c_2 acquired from the linear prediction coefficient storage unit 206g and the linear prediction coefficient storage unit 206h, obtains c, and outputs the result to the linear prediction calculation unit 204j.

また、線形予測演算部204jは、w1_1のパラメータを線形予測係数記憶部206gより獲得し、w2_2のパラメータを線形予測係数記憶部206hより獲得し、cのパラメータを平均値算出部204iより獲得し、dのパラメータとして予め決められたある固定の値を使用し、式1を用いて予測画像を算出し出力する。この場合式1は実施の形態1で説明した通り式1bのようにして変形して扱うことも可能である。   The linear prediction calculation unit 204j acquires the w1_1 parameter from the linear prediction coefficient storage unit 206g, the w2_2 parameter from the linear prediction coefficient storage unit 206h, and the c parameter from the average value calculation unit 204i. A predetermined fixed value is used as a parameter of d, and a predicted image is calculated and output using Expression 1. In this case, Formula 1 can be modified and handled as Formula 1b as described in the first embodiment.

なお、dの値として使用する予め決定された固定の値とは、常に同じ値を使用することも可能であるが、符号化装置においてスライスヘッダに前記固定の値が記述されている場合は、符号列解析部201において前記固定の値を抽出することによりスライスごとに切り替えることも可能である。同様に、ピクチャ共通情報領域またはシーケンス共通情報領域に記述することによりピクチャごとまたはシーケンスごとに切り替えることも可能である。   It is possible to always use the same fixed value as the predetermined fixed value used as the value of d, but when the fixed value is described in the slice header in the encoding device, It is also possible to switch for each slice by extracting the fixed value in the code string analysis unit 201. Similarly, it is possible to switch between pictures or sequences by describing them in the picture common information area or sequence common information area.

なお、上記の復号化方法は2つの参照ピクチャをもつBピクチャに関するものであったが、1つの参照ピクチャしか持たないPピクチャおよびBピクチャにおける単一ピクチャ参照復号化モードにおいても同様の処理を行うことが可能である。この場合は第1参照インデックスもしくは第2参照インデックスのどちらか一方のみを使用し、図6の符号列におけるスライスヘッダ領域中のpsetおよびidx_cmdは、ブロックデータ領域中に記述される参照インデックスに従って、ref1用もしくはref2用のもののみを記述することになる。また、線形予測の方法は従来の方法で説明した式1に替えて式3もしくは式4を使用する。   Although the above decoding method is related to a B picture having two reference pictures, the same processing is performed in a single picture reference decoding mode for a P picture and a B picture having only one reference picture. It is possible. In this case, only one of the first reference index and the second reference index is used, and pset and idx_cmd in the slice header area in the code string of FIG. 6 are ref1 according to the reference index described in the block data area. Only those for ref2 or ref2. In addition, the linear prediction method uses Formula 3 or Formula 4 instead of Formula 1 described in the conventional method.

式1および式3を使用する場合は、w1、w2、c、dの4つのパラメータが必要だったが、式4を使用する場合は、w1、c、dの3つのパラメータのみで線形予測を行うことができる。つまり、Pピクチャのようにピクチャ全体で第1参照インデックスもしくは第2参照インデックスのどちらか一方のみしか使用されない場合は、スライスヘッダ領域に記述する重み付け係数セットのデータの項目数をそれぞれ3つずつに減らすことが可能となる。   When using Equation 1 and Equation 3, four parameters w1, w2, c, and d were required, but when using Equation 4, linear prediction was performed using only three parameters w1, c, and d. It can be carried out. That is, when only one of the first reference index and the second reference index is used in the entire picture like a P picture, the number of data items of the weighting coefficient set described in the slice header area is set to three each. It becomes possible to reduce.

式3を用いた場合はBピクチャとPピクチャとで構成を変更せずに両方に対応した線形予測を実現することが可能となる。また、式4を用いた場合はPピクチャのヘッダ領域に記述するデータ量を削減することができ、さらに計算が単純化されるため処理量の削減も実現することが可能となる。ただし、いずれの方法においても、本発明において提案する参照インデックスの割り振り方法はそのまま適用することができるため、予測精度の高い予測画像を作成することが可能であり、画像の復号化において非常に有効である。   When Expression 3 is used, linear prediction corresponding to both can be realized without changing the configuration between the B picture and the P picture. Further, when Expression 4 is used, the amount of data described in the header area of the P picture can be reduced, and the calculation can be simplified, so that the amount of processing can be reduced. However, in any method, since the reference index allocation method proposed in the present invention can be applied as it is, it is possible to create a prediction image with high prediction accuracy, which is very effective in image decoding. It is.

ところで、動き補償において参照するピクチャは、各々のピクチャに割り当てられた参照インデックスを指定することによって決定される。その際に、参照することが可能なピクチャの最大枚数を符号列のピクチャ共通情報部分に記述していた。   By the way, a picture to be referred to in motion compensation is determined by designating a reference index assigned to each picture. At that time, the maximum number of pictures that can be referred to is described in the picture common information portion of the code string.

図38は、参照することが可能なピクチャの最大枚数を記述した符号列の模式図である。図に示すように符号列のピクチャ共通情報にref1用のピクチャの最大数Max_pic1と、ref2用のピクチャの最大数Max_pic2を記述していた。   FIG. 38 is a schematic diagram of a code string describing the maximum number of pictures that can be referred to. As shown in the figure, the maximum number of pictures ref1 Max_pic1 and the maximum number of pictures ref2 Max_pic2 are described in the picture common information of the code string.

復号化において必要とする情報は、実際のピクチャの最大枚数ではなく、ピクチャを指定するために使用する参照インデックスの取り得る最大値である。   The information necessary for decoding is not the actual maximum number of pictures, but the maximum value that can be taken by the reference index used to specify a picture.

従来の方法では、1つのピクチャには1つの参照インデックスしか割り当てられなかったため、前述のピクチャの最大枚数を記述することによって矛盾は生じなかったが、特に本発明のように、ピクチャ番号に複数の参照インデックスが割り当てられる場合には、その違いが大きく影響する。   In the conventional method, since only one reference index is assigned to one picture, there is no contradiction by describing the maximum number of pictures as described above. However, as in the present invention, there are a plurality of picture numbers. When a reference index is assigned, the difference greatly affects.

上述したように、符号列には参照インデックスをピクチャ番号に割り当てるためにコマンド列idx_cmd1、およびidx_cmd2が記述されている。このコマンド列idx_cmd1、およびidx_cmd2の各コマンドを基に、ピクチャ番号と参照インデックスとを対応づけていく。このときに、参照インデックスの最大値を知ることで、すべての参照インデックスとピクチャ番号との対応づけが行われたことがわかり、コマンド列idx_cmd1、およびidx_cmd2におけるコマンドの終端を知ることができる。   As described above, the command strings idx_cmd1 and idx_cmd2 are described in the code string in order to assign the reference index to the picture number. Based on the commands in the command sequences idx_cmd1 and idx_cmd2, the picture number and the reference index are associated with each other. At this time, by knowing the maximum value of the reference index, it can be seen that all the reference indexes are associated with the picture numbers, and the end of the command in the command strings idx_cmd1 and idx_cmd2 can be known.

そこで、本実施の形態では、従来のピクチャの最大枚数の代わりに、利用可能な参照インデックスの最大数をピクチャのヘッダであるピクチャ共通情報部分に記述している。もしくは、ピクチャの最大枚数と参照インデックスの最大数の両者を記述する。   Therefore, in the present embodiment, instead of the conventional maximum number of pictures, the maximum number of reference indexes that can be used is described in the picture common information portion that is the header of the picture. Alternatively, both the maximum number of pictures and the maximum number of reference indexes are described.

図23は、ピクチャの符号列のピクチャ共通情報に参照インデクッスの最大数を記述した状態を示している。ピクチャの共通情報部分には、ref1用の利用可能な参照インデックスの最大数Max_idx1、およびref2用の利用可能な参照インデックスの最大数Max_idx2を記述している。   FIG. 23 shows a state in which the maximum number of reference indexes is described in the picture common information of the picture code string. In the common information portion of the picture, the maximum number of reference indexes Max_idx1 that can be used for ref1 and the maximum number of reference indexes that can be used Max2 for ref2 are described.

なお、図23では、ピクチャ共通情報に参照インデクッスの最大数を記述しているが、これに加えて、スライスデータ領域に参照インデクッスの最大数を記述する構成としてもよい。例えば、ピクチャでの参照インデクッスの最大数が8、当該ピクチャ中のスライス1で必要な参照インデクッスの最大数が8、スライス2で必要な参照インデクッスの最大数が4であるというように、スライスによって必要な参照インデクッスの最大数がピクチャ共通情報領域に記述された最大数と異なる場合に、スライス毎に必要な参照インデクッスの最大数を明示することができる。   In FIG. 23, the maximum number of reference indexes is described in the picture common information. However, in addition to this, the maximum number of reference indexes may be described in the slice data area. For example, the maximum number of reference indexes in a picture is 8, the maximum number of reference indexes required in slice 1 in the picture is 8, and the maximum number of reference indexes required in slice 2 is 4. When the maximum number of required reference indexes is different from the maximum number described in the picture common information area, the maximum number of reference indexes required for each slice can be specified.

すなわち、ピクチャ共通情報に記述された参照インデクッスの最大数をピクチャ中の各スライスに共通するデフォルト値として、必要な参照インデクッスの最大数がデフォルト値と異なるスライスについてはスライスヘッダに記述するようにしてもよい。   In other words, the maximum number of reference indexes described in the picture common information is set as a default value common to each slice in the picture, and a slice in which the required maximum number of reference indexes is different from the default value is described in the slice header. Also good.

なお、図23および図38ではピクチャ共通情報領域とスライスデータ領域とをひとまとめにして符号列としている例を示したが、ピクチャ共通情報領域とスライスデータ領域はそれぞれ独立した符号列とすることも可能であり、この場合も全く同様に扱うことができる。   23 and 38 show an example in which the picture common information area and the slice data area are collectively used as a code string. However, the picture common information area and the slice data area may be independent code strings. This case can be handled in exactly the same way.

(実施の形態7)
本発明の実施の形態7における動画像復号化方法について説明する。なお、復号化装置の構成および復号化の処理の流れおよび参照インデックスの割り当て方法は実施の形態6と全く同様であるため、ここでは説明を省略する。
(Embodiment 7)
The moving picture decoding method in Embodiment 7 of this invention is demonstrated. Note that the configuration of the decoding apparatus, the flow of the decoding process, and the method of assigning the reference index are exactly the same as in the sixth embodiment, and thus the description thereof is omitted here.

実施の形態6では動き補償において予測画像を生成する際に、式1もしくは式3もしくは式4を用いて画素ごとに線形予測を行っている。しかし、これらの式はいずれも乗算処理を含むものであり、全ての画素に対してこのような演算を行うことを考えると、処理量が非常に大きくなってしまう。   In the sixth embodiment, when a predicted image is generated in motion compensation, linear prediction is performed for each pixel using Expression 1, 3 or 4. However, all of these equations include multiplication processing, and the processing amount becomes very large considering that such calculation is performed on all pixels.

そこで式1の代わりに式5、式3の代わりに式6、式4の代わりに式7を使用することも可能である。これらの式は乗算を使用することなくビットシフト演算のみで計算を行うことができるため、処理量を少なく抑えることが可能となる。   Therefore, it is also possible to use Formula 5 instead of Formula 1, Formula 6 instead of Formula 3, and Formula 7 instead of Formula 4. Since these equations can be calculated only by a bit shift operation without using multiplication, the amount of processing can be reduced.

実施の形態6と同様に、同時に2枚のピクチャを参照して予測画像を生成するときは式5を使用し、1枚のピクチャのみを参照して予測画像を生成するときは式6もしくは式7を使用する。これらの式では正負の符号を表す識別子が必要となるため、予測演算に必要な重み付け係数セットは、式5および式6の場合は(sign1、m、sign2、n、c)、式7の場合は(sign1、m、c)となる。sign1は1つめの正負の符号を、sign2は2つめの正負の符号を識別するパラメータとする。パラメータの個数は実施の形態3よりも増加しているが、sign1およびsign2はそれぞれ1ビットで表現することができるため符号量の増加はほとんど無い。   As in the sixth embodiment, Formula 5 is used when a predicted image is generated with reference to two pictures at the same time, and Formula 6 or Formula is generated when a predicted image is generated with reference to only one picture. 7 is used. Since these expressions require identifiers representing positive and negative signs, the weighting coefficient set necessary for the prediction calculation is (sign1, m, sign2, n, c) in the case of Expression 5 and Expression 6, and in the case of Expression 7. Becomes (sign1, m, c). sign1 is a parameter for identifying the first positive / negative sign, and sign2 is a parameter for identifying the second positive / negative sign. The number of parameters is larger than that in the third embodiment, but sign1 and sign2 can be expressed by 1 bit, respectively, so that the code amount hardly increases.

ここで、重み付け係数セットを決定し、式5を使用し同時に2枚のピクチャを参照して予測画像を生成するまでの処理の流れについて詳細に説明する。   Here, the flow of processing until the weighted coefficient set is determined and the predicted image is generated with reference to two pictures at the same time using Equation 5 will be described in detail.

まず、予測画像を生成する機能構成が図18である場合について説明する。平均値算出部204aは、線形予測係数記憶部206aより重み付け係数セット(sign1_1,m_1,sign2_1,n_1,c_1)を得る。また、平均値算出部204aは、線形予測係数記憶部206bより重み付け係数セット(sign1_2,m_2,sign2_2,n_2,c_2)を得る。   First, the case where the functional configuration for generating a predicted image is shown in FIG. 18 will be described. The average value calculation unit 204a obtains a weighting coefficient set (sign1_1, m_1, sign2_1, n_1, c_1) from the linear prediction coefficient storage unit 206a. Further, the average value calculation unit 204a obtains a weighting coefficient set (sign1_2, m_2, sign2_2, n_2, c_2) from the linear prediction coefficient storage unit 206b.

平均値算出部204aは、線形予測係数記憶部206a,線形予測係数記憶部206bより得た重み付け係数セットのパラメータ毎の平均値を求め、重み付け係数セット(sign1,m,sign2,n,c)とする。線形予測演算部204bは、平均値算出部204aが出力する重み付け係数セット(sign1,m,sign2,n,c)を基に、式5を用いて予測画像を演算する。   The average value calculation unit 204a calculates an average value for each parameter of the weighting coefficient set obtained from the linear prediction coefficient storage unit 206a and the linear prediction coefficient storage unit 206b, and sets the weighting coefficient set (sign1, m, sign2, n, c) and To do. The linear prediction calculation unit 204b calculates a prediction image using Expression 5 based on the weighting coefficient set (sign1, m, sign2, n, c) output from the average value calculation unit 204a.

なお、図18に記載した線形予測係数記憶部206a等より得られる重み付け係数セット(w1_1,w2_1,c_1,d_1)等は、実施の形態6で説明した式1の場合の例におけるものであり、式5を用いて予測画像を求める場合についてのパラメータについては図示していないがそのまま置き換えることが可能である。以下に説明する図19、図20の場合も同様である。   Note that the weighting coefficient sets (w1_1, w2_1, c_1, d_1) and the like obtained from the linear prediction coefficient storage unit 206a and the like described in FIG. 18 are in the example in the case of Equation 1 described in the sixth embodiment. Although parameters for obtaining a predicted image using Expression 5 are not shown, they can be replaced as they are. The same applies to FIGS. 19 and 20 described below.

次に、予測画像を生成する機能構成が図19である場合について説明する。線形予測演算部204cは、線形予測係数記憶部206aより得た重み付け係数セット(sign1_1,m_1,sign2_1,n_1,c_1)を基に予測画像を演算する。線形予測演算部204dは、線形予測係数記憶部206bより得た重み付け係数セット(sign1_2,m_2,sign2_2,n_2,c_2)を基に予測画像を演算する。そして平均値算出部204eは、線形予測演算部204c,204dのそれぞれが演算した予測画像の各画素の平均を求め、予測画像とする。   Next, a case where the functional configuration for generating a predicted image is FIG. 19 will be described. The linear prediction calculation unit 204c calculates a prediction image based on the weighting coefficient set (sign1_1, m_1, sign2_1, n_1, c_1) obtained from the linear prediction coefficient storage unit 206a. The linear prediction calculation unit 204d calculates a prediction image based on the weighting coefficient set (sign1_2, m_2, sign2_2, n_2, c_2) obtained from the linear prediction coefficient storage unit 206b. Then, the average value calculation unit 204e obtains the average of each pixel of the predicted image calculated by each of the linear prediction calculation units 204c and 204d, and sets it as the predicted image.

この場合、線形予測演算部204cは、重み付け係数セット(sign1_1,m_1,sign2_1,n_1,c_1)を基に式5を用いて、最初に予測画像を演算するため、乗算を使用することなく、ビットシフト演算で計算することができる。線形予測演算部204dも同様である。一方、図18の場合であると、最初に重み付け係数セット(sign1_1,m_1,sign2_1,n_1,c_1)と重み付け係数セット(sign1_2,m_2,sign2_2,n_2,c_2)の平均を求めるため、m_1とm_2の平均値あるいはn_1とn_2の平均値が整数にならない場合があり、すなわち2の指数にあたる部分が整数にならないため、処理量が多くなってしまう可能性がある。また、2の指数にあたる部分が整数になるように丸め処理をおこなうと誤差が大きくなってしまう可能性がある。   In this case, the linear prediction calculation unit 204c first calculates a predicted image using Equation 5 based on the weighting coefficient set (sign1_1, m_1, sign2_1, n_1, c_1), and therefore, without using multiplication, It can be calculated by a shift operation. The same applies to the linear prediction calculation unit 204d. On the other hand, in the case of FIG. 18, first, m_1 and m_2 are obtained in order to obtain an average of the weighting coefficient set (sign1_1, m_1, sign2_1, n_1, c_1) and the weighting coefficient set (sign1_2, m_2, sign2_2, n_2, c_2). Or the average value of n_1 and n_2 may not be an integer, that is, the portion corresponding to the exponent of 2 does not become an integer, and the amount of processing may increase. In addition, if rounding is performed so that the portion corresponding to the exponent of 2 becomes an integer, there is a possibility that the error will increase.

次に、予測画像を生成する機能構成が図20(a)である場合について説明する。線形予測演算部204gは、線形予測係数記憶部206cより得たビットシフト演算に用いられる係数であるパラメータsign1_1,m_1と、線形予測係数記憶部206cより得たビットシフト演算に用いられる係数であるパラメータsign2_2,n_2と、各線形予測係数記憶部206c,206dより得たパラメータc_1とc_2を平均値算出部204fが平均して求めた平均値cとを基に式9を用いて予測画像を演算する。   Next, the case where the functional configuration for generating a predicted image is shown in FIG. The linear prediction calculation unit 204g is a parameter sign1_1, m_1 which is a coefficient used for the bit shift calculation obtained from the linear prediction coefficient storage unit 206c, and a parameter which is a coefficient used for the bit shift calculation obtained from the linear prediction coefficient storage unit 206c. Based on the sign2_2 and n_2 and the average value c obtained by averaging the parameters c_1 and c_2 obtained from the linear prediction coefficient storage units 206c and 206d by the average value calculation unit 204f, a prediction image is calculated using Equation 9. .

この場合においても、ビットシフト演算に用いられる係数は、線形予測係数記憶部206cあるいは線形予測係数記憶部206dよりそのまま得た値であるので、式5における2の指数部分が整数となる。そのため、ビットシフト演算で計算することができ、処理量を少なくすることが可能となる。   Also in this case, since the coefficient used for the bit shift calculation is a value obtained from the linear prediction coefficient storage unit 206c or the linear prediction coefficient storage unit 206d as it is, the exponent part of 2 in Equation 5 is an integer. Therefore, it can be calculated by a bit shift operation, and the processing amount can be reduced.

予測画像を生成する機能構成が図20(b)である場合について説明する。線形予測演算部204hは、線形予測係数記憶部206eより得たパラメータsign1_1,m_1,c_1と、線形予測係数記憶部206fより得たパラメータsign2_2,n_2とを基に式9を用いて予測画像を演算する。   A case where the functional configuration for generating a predicted image is shown in FIG. The linear prediction calculation unit 204h calculates a prediction image using Equation 9 based on the parameters sign1_1, m_1, c_1 obtained from the linear prediction coefficient storage unit 206e and the parameters sign2_2, n_2 obtained from the linear prediction coefficient storage unit 206f. To do.

この場合においても、ビットシフト演算に用いられる係数は、線形予測係数記憶部206e、あるいは線形予測係数記憶部206fよりそのまま得た値であるので、式5における2の指数部分が整数となる。そのため、ビットシフト演算で計算することができ、処理量を少なくすることが可能となる。   Also in this case, since the coefficient used for the bit shift calculation is a value obtained from the linear prediction coefficient storage unit 206e or the linear prediction coefficient storage unit 206f as it is, the exponent part of 2 in Equation 5 is an integer. Therefore, it can be calculated by a bit shift operation, and the processing amount can be reduced.

図20(a)(b)の場合は、実施の形態3における図10(a)(b)の説明と同様に符号列に付加して送らなくてもよいパラメータがあり、符号列を小さくすることが可能である。   In the case of FIGS. 20A and 20B, there is a parameter that does not have to be added to the code string and sent as in the description of FIGS. It is possible.

以上、実施の形態7で説明したような線形予測式を用いると、乗算を使用することなくビットシフト演算で計算することができるため実施の形態6に比べて処理量を大幅に削減することが可能となる。   As described above, when the linear prediction formula as described in the seventh embodiment is used, calculation can be performed by bit shift calculation without using multiplication, so that the processing amount can be significantly reduced as compared with the sixth embodiment. It becomes possible.

なお、上記実施の形態では式1、式3、式4の代わりに式5、式6、式7を用い、符号化するパラメータセットも(w1、w2、c、d)の代わりに(sign1、m、sign2、n、c)を用いて線形予測を行うことによってビットシフト演算のみでの計算を実現し処理量の削減を図っていたが、別のアプローチとして式1、式3、式4および(w1、w2、c、d)をそのまま用いたまま、w1およびw2をビットシフト演算可能な値のみ選択可能として制限することによって実施の形態6と全く同様の構成のままビットシフト演算のみでの計算を実現し処理量の削減を行うことも可能である。   In the above embodiment, Formula 5, Formula 6, and Formula 7 are used instead of Formula 1, Formula 3, and Formula 4, and the parameter set to be encoded is (sign1, m, sign2, n, c) are used to perform linear prediction to achieve calculation only by bit shift operation and reduce the amount of processing. However, as another approach, Equation 1, Equation 3, Equation 4, and (W1, w2, c, d) are used as they are, and w1 and w2 are limited to selectable values that can be subjected to a bit shift operation, so that only the bit shift operation can be performed with the same configuration as in the sixth embodiment. It is also possible to realize calculation and reduce the processing amount.

また、さらに限定する方法として、w1およびw2を常に1として選択するように制限し、直流成分であるc1およびc2のみ任意の値を持つような符号列を入力とすることも可能である。図21の構成の場合を例にとると、ref1用として(1、c_1)、ref2用として(1、c_2)をパラメータセットとして符号化されているものする。この場合、予測画像の画素値P(i)は、(式1a)中のw1_1およびw2_2を1に置き換えた次式により求められる。   Further, as a further limiting method, it is possible to restrict w1 and w2 to be always selected as 1, and to input a code string having only an arbitrary value only for DC components c1 and c2. Taking the case of the configuration of FIG. 21 as an example, it is assumed that (1, c_1) for ref1 and (1, c_2) for ref2 are encoded as parameter sets. In this case, the pixel value P (i) of the predicted image is obtained by the following expression in which w1_1 and w2_2 in (Expression 1a) are replaced with 1.

P(i)=(Q1(i)+Q2(i))/pow(2,d)+(c_1+c_2)/2
(pow(2,d)は2のd乗を示す)
P (i) = (Q1 (i) + Q2 (i)) / pow (2, d) + (c_1 + c_2) / 2
(Pow (2, d) indicates 2 to the power of d)

これによって実施の形態6と全く同様の構成のまま線形予測のための処理量を大幅に削減することが可能となる。   As a result, the processing amount for linear prediction can be greatly reduced with the same configuration as that of the sixth embodiment.

さらに、図24のようにピクチャの符号列のピクチャ共通情報に、線形予測をビットシフト演算のみで行うことが可能であるかを示すフラグsft_flg、および直流成分であるcのみで線形予測を行うことが可能であるかを示すフラグdc_flgが記述されている場合、復号化装置ではこれらフラグを参照することにより、ビットシフト演算のみでの線形予測に適した構成での復号を行うことや、直流成分のみでの線形予測に適した構成での復号を行うことが可能となり、復号化装置の構成によっては大幅な処理量の削減が可能となる。   Furthermore, as shown in FIG. 24, linear prediction is performed only on a flag sft_flg indicating whether linear prediction can be performed only by a bit shift operation, and c, which is a direct current component, in the picture common information of the code string of the picture. When a flag dc_flg indicating whether or not is possible is described, the decoding apparatus refers to these flags to perform decoding with a configuration suitable for linear prediction only by bit shift operation, Therefore, it is possible to perform decoding with a configuration suitable for linear prediction using only the above-described method, and it is possible to significantly reduce the amount of processing depending on the configuration of the decoding device.

(実施の形態8)
本発明の実施の形態8における動画像復号化方法について説明する。なお、
復号化装置の構成および復号化の処理の流れおよび参照インデックスの割り当て方法は実施の形態6と全く同様であるため、ここでは説明を省略する。
(Embodiment 8)
The moving picture decoding method in Embodiment 8 of this invention is demonstrated. In addition,
The configuration of the decoding apparatus, the decoding process flow, and the reference index assignment method are exactly the same as those in the sixth embodiment, and thus the description thereof is omitted here.

従来の技術において説明したように、実施の形態6および実施の形態7のように線形予測係数の重み付け係数セットから求める予測式を用いて予測画像を生成するのではなく、式2aおよび式2bのように予め決めた固定式を用いて予測画像を求める方法があった。この方法を用いると、予測画像を求めるときの重み付け係数セットを符号化して送る必要がないため符号量を削減できるという利点があった。また、線形予測の計算式が単純であるため、少ない処理量で線形予測を大幅に削減することが可能であった。しかし、この固定式を用いた方法であると、選択することのできる線形予測式が式2aおよび式2bの2通りしかないため、予測精度が悪くなってしまうという問題があった。   As described in the prior art, the prediction image is not generated by using the prediction expression obtained from the weighting coefficient set of the linear prediction coefficient as in the sixth embodiment and the seventh embodiment, but instead of the expression 2a and the expression 2b. As described above, there is a method of obtaining a predicted image using a predetermined fixed formula. When this method is used, there is an advantage that the amount of codes can be reduced because it is not necessary to encode and send a weighting coefficient set for obtaining a predicted image. In addition, since the calculation formula for linear prediction is simple, linear prediction can be significantly reduced with a small amount of processing. However, the method using this fixed formula has a problem that the prediction accuracy deteriorates because there are only two types of linear prediction formulas 2a and 2b that can be selected.

そこで本実施の形態では式2a,式2bの代わりに式8a,8bを使用する。これらの式は式2a,式2bにC1およびC2を加えたものである。演算としては加算の回数が増加するだけであるため、元の式と比較しても処理量の増加はほとんど無い。   Therefore, in this embodiment, equations 8a and 8b are used instead of equations 2a and 2b. These equations are obtained by adding C1 and C2 to equations 2a and 2b. As the calculation only increases the number of additions, the amount of processing is hardly increased even when compared with the original expression.

式8a,8bは同時に2枚のピクチャを参照して予測画像を生成するときの予測式であるが、1枚のピクチャのみを参照して予測画像を生成するときは実施の形態で説明した式3、式4の代わりに式9を使用する。   Expressions 8a and 8b are prediction expressions when a predicted image is generated by referring to two pictures at the same time. When generating a predicted image by referring to only one picture, the expressions described in the embodiment are used. 3. Instead of equation 4, equation 9 is used.

この方法を用いるために必要な重み付け係数セットは、ref1用として(C1)、ref2用として(C2)のみである。そのため、この方法を用いた場合のピクチャの符号列の例は図14にようになり、スライスヘッダ領域には線形予測を行うための重み付け係数セット(pset0、pset1、pset2、・・・・)がref1用およびref2用それぞれに記述され、それぞれの重み付け係数セットの中身はCのみとなる。同様に、図15は前記スライスヘッダ領域に含まれる重み付け係数セットの例を表に示したものであるが、図7とは異なり、各重み付け係数セットの要素はCのみとなっている。   The weighting coefficient sets necessary for using this method are only (C1) for ref1 and (C2) for ref2. Therefore, an example of a picture code string when this method is used is as shown in FIG. 14, and weighting coefficient sets (pset0, pset1, pset2,...) For performing linear prediction are shown in the slice header region. It is described for each of ref1 and ref2, and the content of each weighting coefficient set is C only. Similarly, FIG. 15 is a table showing an example of the weighting coefficient set included in the slice header area. Unlike FIG. 7, the element of each weighting coefficient set is C only.

図22は、図2の線形予測係数記憶部206と動き補償復号化部204における予測画像を生成する機能構成を示した機能ブロック図である。   FIG. 22 is a functional block diagram illustrating a functional configuration for generating a prediction image in the linear prediction coefficient storage unit 206 and the motion compensation decoding unit 204 in FIG.

線形予測係数記憶部206aと、線形予測係数記憶部206bと、線形予測演算部204aにより予測画像が生成される。   A prediction image is generated by the linear prediction coefficient storage unit 206a, the linear prediction coefficient storage unit 206b, and the linear prediction calculation unit 204a.

符号列解析部201より出力される第1参照インデックスref1および第2参照インデックスref2によりを線形予測係数記憶部206aおよび206bよりそれぞれ1つの構成要素のみを持つ重み付け係数セット(C1)および(C2)が獲得される。それらの値は線形予測演算部204aに入力され、式8a,8bを用いて線形予測がなされ、予測画像が生成される。   Weighting coefficient sets (C1) and (C2) each having only one component from the linear prediction coefficient storage units 206a and 206b based on the first reference index ref1 and the second reference index ref2 output from the code string analysis unit 201 To be acquired. These values are input to the linear prediction calculation unit 204a, and linear prediction is performed using the equations 8a and 8b to generate a predicted image.

同様に、1枚のみを参照して線形予測を行う場合は図22のref1もしくはref2のどちらかのみにより重み付け係数セット(C1)もしくは(C2)が獲得され、式9を用いて線形予測がなされ、予測画像が生成される。   Similarly, when performing linear prediction with reference to only one sheet, the weighting coefficient set (C1) or (C2) is obtained only by either ref1 or ref2 in FIG. 22, and linear prediction is performed using Equation 9. A predicted image is generated.

このように、本実施の形態では使用するパラメータの数がref1用、ref2用にそれぞれ1つずつのみでよいため、符号列に記述するデータの量を削減することができる。また線形予測式も乗算等の複雑な演算を必要としないため、演算量も最小限に抑えることが可能である。また従来の固定式を用いた方法で欠点とされていた予測精度の悪さも、C1およびC2という係数を用いることにより大幅に改善することが可能である。   As described above, in the present embodiment, since only one parameter is required for each of ref1 and ref2, the amount of data described in the code string can be reduced. In addition, since the linear prediction formula does not require complicated operations such as multiplication, the amount of calculation can be minimized. Further, the poor prediction accuracy, which has been regarded as a drawback in the conventional method using the fixed formula, can be significantly improved by using the coefficients C1 and C2.

なお、本実施の形態で説明した線形予測の方法は、複数の参照インデックスが同一のピクチャを参照することが可能であるかどうかに関わらず用いることが可能である。   Note that the linear prediction method described in this embodiment can be used regardless of whether a plurality of reference indexes can refer to the same picture.

(実施の形態9)
本発明の実施の形態9における動画像復号化方法について説明する。なお、復号化装置の構成および復号化の処理の流れおよび参照インデックスの割り当て方法は実施の形態6と全く同様であるため、ここでは説明を省略する。
(Embodiment 9)
A moving picture decoding method according to the ninth embodiment of the present invention will be described. Note that the configuration of the decoding apparatus, the flow of the decoding process, and the method of assigning the reference index are exactly the same as in the sixth embodiment, and thus the description thereof is omitted here.

各々のピクチャはピクチャ番号と共に、表示時間もしくはそれに代わるものを示すための表示順情報というものが割り当てられている。図39は、その1例としてピクチャ番号と表示順情報とを並べて示した図である。表示順情報は表示される順番に従ってある値が割り当てられる。この図の例では、1ピクチャごとに1ずつ増加する値が使用されている。線形予測を行うための式で用いられる係数の値をこれらの表示順情報を用いて生成する方法について実施の形態9において説明する。   Each picture is assigned with a picture number and display order information for indicating a display time or an alternative. FIG. 39 is a diagram showing a picture number and display order information side by side as an example. A certain value is assigned to the display order information according to the display order. In the example of this figure, a value that increases by 1 for each picture is used. A method for generating coefficient values used in an equation for performing linear prediction using the display order information will be described in Embodiment 9.

実施の形態6では動き補償において予測画像を生成する際に、式1もしくは式3もしくは式4を用いて画素ごとに線形予測を行っている。しかし、これらの線形予測を行うためには係数のデータが必要であり、前記実施の形態では、スライスヘッダ領域に重み付け係数セットとして符号列中に係数のデータを記述し、予測画像の作成に用いていた。しかし、高い符号化効率が得られる反面、重み付け係数セットのデータを作成するための処理が必要となり、また、重み付け係数セットを符号列中に記述することによるビット量の増加も発生する。   In the sixth embodiment, when a predicted image is generated in motion compensation, linear prediction is performed for each pixel using Expression 1, 3 or 4. However, coefficient data is required to perform these linear predictions. In the above embodiment, coefficient data is described in a code string as a weighting coefficient set in a slice header area, and is used to create a prediction image. It was. However, while high coding efficiency can be obtained, a process for creating weighting coefficient set data is required, and an increase in the bit amount due to the description of the weighting coefficient set in the code string also occurs.

そこで式1の代わりに式10、式11a、式12aを用いて線形予測を行うことも可能である。これらの式は各々の参照ピクチャが持つ表示順情報のみから重み付け係数を決定することができるため、別途重み付け係数セットを符号化する必要がない。   Therefore, it is also possible to perform linear prediction using Formula 10, Formula 11a, and Formula 12a instead of Formula 1. Since these equations can determine the weighting coefficient only from the display order information of each reference picture, it is not necessary to separately encode the weighting coefficient set.

例として図39において、符号化対象ピクチャが16番、第1参照インデックスによって指定されたピクチャが11番、第2参照インデックスによって指定されたピクチャが10番とすると、それぞれのピクチャの表示順情報は15、13、10となるため、下記のような線形予測式が決定される。   For example, in FIG. 39, if the encoding target picture is No. 16, the picture specified by the first reference index is No. 11, and the picture specified by the second reference index is No. 10, the display order information of each picture is Since the values are 15, 13, and 10, the following linear prediction formula is determined.

V1=(10−15)/(10−13)=5/3
V2=(15−13)/(10−13)=−2/3
P(i)=5/3×Q1(i)−2/3×Q2(i)
V1 = (10-15) / (10-13) = 5/3
V2 = (15-13) / (10-13) =-2/3
P (i) = 5/3 × Q1 (i) −2 / 3 × Q2 (i)

式1を用いた重み付け係数セットを用いて線形予測を行う方法と比較すると係数の値の自由度が低いため最適な予測画像の作成は困難と言えるが、式2a、式2bを用いた2つの式からなる固定式を2枚の参照ピクチャの位置関係によって切り替える方法と比較すると線形予測式としてより効率の良い式を生成することができる。   Compared with the method of performing linear prediction using the weighting coefficient set using Equation 1, it can be said that it is difficult to create an optimal prediction image because the degree of freedom of the coefficient value is low. However, two methods using Equation 2a and Equation 2b are difficult. A more efficient expression can be generated as a linear prediction expression when compared with a method in which a fixed expression consisting of an expression is switched according to the positional relationship between two reference pictures.

なお、第1参照インデックスおよび第2参照インデックスが同じピクチャを参照している場合は、T1=T2となってしまい、式11a、式12aが成立しない。そこで、参照される2枚のピクチャが同じ表示順情報を持つ場合はV1およびV2の値として1/2を用いて線形予測を行うものとする。その場合の線形予測式は下記のようになる。   When the first reference index and the second reference index refer to the same picture, T1 = T2, and Expressions 11a and 12a are not satisfied. Thus, when two referenced pictures have the same display order information, linear prediction is performed using 1/2 as the values of V1 and V2. In this case, the linear prediction formula is as follows.

V1=1/2
V2=1/2
P(i)=1/2×Q1(i)+1/2×Q2(i)
V1 = 1/2
V2 = 1/2
P (i) = 1/2 * Q1 (i) + 1/2 * Q2 (i)

また、第1参照インデックスおよび第2参照インデックスが異なるピクチャを参照しているが、それらのピクチャが同じ表示順情報を持つ場合にも、T1=T2となってしまい、式11a、式12aが成立しない。このように、参照される2枚のピクチャが同じ表示順情報を持つ場合はV1およびV2の値として1/2を用いて線形予測を行うものとする。   In addition, when the first reference index and the second reference index refer to different pictures, but these pictures have the same display order information, T1 = T2, and Expressions 11a and 12a are satisfied. do not do. In this way, when two referenced pictures have the same display order information, linear prediction is performed using 1/2 as the values of V1 and V2.

このように、参照される2枚のピクチャが同じ表示順情報を持つ場合には、予め設定された値を係数として用いる構成とすればよい。予め設定された値を係数としては、上記の1/2の例のように同じ重みを有する係数としてもよい。   In this way, when two referenced pictures have the same display order information, a configuration may be adopted in which a preset value is used as a coefficient. The preset value may be a coefficient having the same weight as in the above half example.

ところで、上記の実施の形態のように式10を用いると、線形予測を行うために乗算および除算が必要となる。式10による線形予測演算は符号化対象ブロック内の全ての画素に対して演算を行うため、乗算が加わることによる処理量の増加は非常に大きなものとなる。   By the way, when Expression 10 is used as in the above embodiment, multiplication and division are required to perform linear prediction. Since the linear prediction calculation according to Equation 10 is performed on all the pixels in the encoding target block, an increase in processing amount due to the addition of multiplication is very large.

そこで、実施の形態7の考え方と同様にして、V1およびV2を2のべき乗に近似することにより、線形予測の演算をシフト演算のみで行うことを可能とし、処理量の削減を図ることができる。その場合の線形予測式として、式11a、式12aの代わりに式11b、式12bを用いる。   Thus, in the same way as the concept of the seventh embodiment, by approximating V1 and V2 to the power of 2, it is possible to perform the linear prediction operation only by the shift operation and reduce the amount of processing. . As a linear prediction formula in that case, Formula 11b and Formula 12b are used instead of Formula 11a and Formula 12a.

なお、式11a、式12aの代わりに式11c、式12cを用いることも可能である。
なお、式11a、式12aの代わりに式11d、式12dを用いることも可能である。
In addition, it is also possible to use Formula 11c and Formula 12c instead of Formula 11a and Formula 12a.
In addition, it is also possible to use Formula 11d and Formula 12d instead of Formula 11a and Formula 12a.

なお、2のべき乗への近似の方法は、式11bを例にとると、v1の値を1ずつ変化させたとき、±pow(2,v1)と(T2−T0)/(T2−T1)とが最も近くなるときの±pow(2,v1)の値とする。   As an approximation method to the power of 2, taking Expression 11b as an example, when the value of v1 is changed by 1, ± pow (2, v1) and (T2-T0) / (T2-T1) Is the value of ± pow (2, v1) when.

例として図39において、復号化対象ピクチャが16番、第1参照インデックスによって指定されたピクチャが11番、第2参照インデックスによって指定されたピクチャが10番とすると、それぞれのピクチャの表示順情報は15、13、10となるため、(T2−T0)/(T2−T1)および±pow(2,v1)は下記のようになる。   For example, in FIG. 39, when the decoding target picture is No. 16, the picture specified by the first reference index is No. 11, and the picture specified by the second reference index is No. 10, the display order information of each picture is Since 15, 13 and 10, (T2-T0) / (T2-T1) and ± pow (2, v1) are as follows.

(T2−T0)/(T2−T1)=(10−15)/(10−13)=5/3
+pow(2,0)=1、+pow(2,1)=2
(T2-T0) / (T2-T1) = (10-15) / (10-13) = 5/3
+ Pow (2,0) = 1, + pow (2,1) = 2

5/3は1よりも2に近いため、近似の結果V1=2となる。   Since 5/3 is closer to 2 than 1, the approximation result V1 = 2.

また、別の近似の方法として、表示順情報T1およびT2の2つの値の関係によって切り上げによる近似、切り下げによる近似を切り替えることも可能である。   As another approximation method, the approximation by rounding up and the approximation by rounding down can be switched according to the relationship between the two values of the display order information T1 and T2.

その場合、T1がT2よりも時間的に後方にある場合は、V1およびV2の両者に対して切り上げによる近似を行い、T1がT2よりも時間的に前方にある場合は、V1およびV2の両者に対して切り下げによる近似を行う。逆に、T1がT2よりも時間的に後方にある場合は、V1およびV2の両者に対して切り下げによる近似を行い、T1がT2よりも時間的に前方にある場合は、V1およびV2の両者に対して切り上げによる近似を行うことも可能である。   In that case, when T1 is temporally behind T2, both V1 and V2 are approximated by rounding up. When T1 is temporally ahead of T2, both V1 and V2 are approximated. Is approximated by rounding down. Conversely, if T1 is behind T2 in time, both V1 and V2 are approximated by rounding down. If T1 is ahead in time from T2, both V1 and V2 are approximated. It is also possible to approximate by rounding up.

また、別の表示順情報を用いた近似の方法として、T1がT2よりも時間的に後方にある場合は、V1に関する式においては切り上げによる近似を行い、V2に関する式においては切り下げによる近似を行う。これにより2つの係数の値が互いに離れるため、外挿補間に適した値が得られやすくなる。逆に、T1がT2よりも時間的に前方にある場合は、V1に関する式とV2に関する式とでその両者の値を比較したときに、値の小さい方は切り上げによる近似を行い、値の大きい方は切り下げによる近似を行う。これにより2つの係数の値が互いに近づくため、内挿補間に適した値が得られやすくなる。   Further, as another approximation method using display order information, when T1 is temporally behind T2, approximation is performed by rounding up in the formula for V1, and approximation by rounding down is performed in the formula for V2. . As a result, the values of the two coefficients are separated from each other, making it easy to obtain a value suitable for extrapolation. Conversely, when T1 is temporally ahead of T2, when the values of V1 and V2 are compared, the smaller value is approximated by rounding up, and the value is larger. The method is approximated by rounding down. As a result, since the values of the two coefficients are close to each other, it is easy to obtain a value suitable for interpolation.

例として図39において、復号化対象ピクチャが16番、第1参照インデックスによって指定されたピクチャが11番、第2参照インデックスによって指定されたピクチャが10番とすると、それぞれのピクチャの表示順情報は15、13、10となり、T1はT2よりも時間的に後方にあるため、V1に関する式においては切り上げによる近似を行い、V2に関する式においては切り下げによる近似を行う。その結果、式11bおよび式12bは下記のように計算される。   For example, in FIG. 39, if the picture to be decoded is No. 16, the picture specified by the first reference index is No. 11, and the picture specified by the second reference index is No. 10, the display order information of each picture is 15, 13 and 10, and T1 is behind the time T2, so the approximation for the V1 is approximated by rounding up, and the formula for V2 is approximated by rounding down. As a result, Equations 11b and 12b are calculated as follows.

(1)式11bについて
(T2−T0)/(T2−T1)=(10−15)/(10−13)=5/3
+pow(2,0)=1、+pow(2,1)=2
(1) About Formula 11b
(T2-T0) / (T2-T1) = (10-15) / (10-13) = 5/3
+ Pow (2,0) = 1, + pow (2,1) = 2

切り上げによる近似を行った結果V1=2となる。   As a result of approximation by rounding up, V1 = 2.

(2)式12bについて
(T0−T1)/(T2−T1)=(15−13)/(10−13)=−2/3
−pow(2,0)=−1、−pow(2,−1)=−1/2
(2) About Formula 12b
(T0-T1) / (T2-T1) = (15-13) / (10-13) =-2/3
-Pow (2,0) =-1, -pow (2, -1) =-1/2

切り下げによる近似を行った結果V2=−1となる。   As a result of approximation by rounding down, V2 = -1.

なお、上記実施の形態では線形予測の式は式10の1つであったが、従来の技術で説明した式2aおよび式2bの2つの式からなる固定式による線形予測方法と組み合わせて用いることも可能である。その場合、式2aの代わりに式10を使用し、式2bはそのまま使用する。つまり、第1参照インデックスによって指定されるピクチャが第2参照インデックスによって指定されるピクチャよりも表示順において後ろにある場合は式10を使用し、それ以外の場合は式2bを使用する。   In the above embodiment, the linear prediction formula is one of the formulas 10. However, the linear prediction formula should be used in combination with the linear prediction method based on the fixed formula composed of the two formulas 2a and 2b described in the prior art. Is also possible. In that case, Equation 10 is used instead of Equation 2a, and Equation 2b is used as it is. That is, Expression 10 is used when the picture specified by the first reference index is behind the picture specified by the second reference index in the display order, and Expression 2b is used otherwise.

また逆に、式2bの代わりに式10を使用し、式2aはそのまま使用することも可能である。つまり、第1参照インデックスによって指定されるピクチャが第2参照インデックスによって指定されるピクチャよりも表示順において後ろにある場合は式2aを使用し、それ以外の場合は式10を使用する。ただし、このとき参照される2枚のピクチャが同じ表示順情報を持つ場合はV1およびV2の値として1/2を用いて線形予測を行う。   On the contrary, it is also possible to use expression 10 instead of expression 2b and use expression 2a as it is. That is, Expression 2a is used when the picture specified by the first reference index is behind the picture specified by the second reference index in the display order, and Expression 10 is used otherwise. However, when two pictures referred to at this time have the same display order information, linear prediction is performed using 1/2 as the values of V1 and V2.

また、実施の形態8の考え方と同様にして、係数Cのみをスライスヘッダ領域に記述して線形予測に使用することも可能である。その場合、式10の代わりに式13を用いる。V1およびV2の求め方は上記実施の形態と同様である。   Similarly to the concept of the eighth embodiment, it is possible to describe only the coefficient C in the slice header area and use it for linear prediction. In that case, Equation 13 is used instead of Equation 10. The method for obtaining V1 and V2 is the same as in the above embodiment.

係数を生成するための処理が必要になり、さらに、スライスヘッダ領域に係数データを符号化する必要があるが、V1およびV2の精度が低い場合でもC1およびC2を用いることによってより高い精度の線形予測を行うことが可能となる。特にV1およびV2を2のべき乗に近似して線形予測を行う場合において有効である。   A process for generating coefficients is required, and further, coefficient data needs to be encoded in the slice header area. Even when the accuracy of V1 and V2 is low, higher accuracy linearity is obtained by using C1 and C2. It is possible to make a prediction. This is particularly effective when linear prediction is performed by approximating V1 and V2 to powers of 2.

なお、式13を用いた場合の線形予測では、1つのピクチャに1つの参照インデックスが割り当てられている場合でも、また、1つのピクチャに複数の参照インデックスが割り当てられている場合でも、同様に扱うことが可能である。   In the linear prediction using Equation 13, even when one reference index is assigned to one picture or when a plurality of reference indexes are assigned to one picture, the same is handled. It is possible.

なお、式11a、式12a、式11b、式12b、式11c、式12c、式11d、式12dの各式の値の計算では、取り得る値の組み合わせがスライスごとにある程度限られているため、スライスを符号化する再に1度だけ演算を行っておけばよく、式10や式13のように符号化対象ブロックのすべての画素に対して演算を行う必要はないため、全体の処理量への影響は小さいと考えられる。   In addition, in the calculation of the values of the equations 11a, 12a, 11b, 12b, 11c, 12c, 11d, and 12d, possible combinations of values are limited to some extent for each slice. It is only necessary to perform the calculation once for encoding the slice, and it is not necessary to perform the calculation for all the pixels of the encoding target block as in Expression 10 and Expression 13, so that the total processing amount is reduced. The effect of is considered to be small.

なお、本発明の実施の形態における表示順情報は、表示の順番に限定されるものではなく、実際の表示時間や、表示時間に伴って値が大きくなる所定のピクチャを基準とした各ピクチャの参照順序であっても良い。   Note that the display order information in the embodiment of the present invention is not limited to the display order, but the actual display time or the predetermined picture whose value increases with the display time is used as a reference. The reference order may be used.

(実施の形態10)
本発明の実施の形態10における動画像復号化方法について説明する。なお、復号化装置の構成および復号化の処理の流れおよび参照インデックスの割り当て方法は実施の形態6と全く同様であるため、ここでは説明を省略する。
(Embodiment 10)
The moving picture decoding method in Embodiment 10 of this invention is demonstrated. Note that the configuration of the decoding apparatus, the flow of the decoding process, and the method of assigning the reference index are exactly the same as in the sixth embodiment, and thus the description thereof is omitted here.

従来の方法では固定式を用いて予測画像の生成を行う場合と、線形予測係数の重み付け係数セットを用いて予測画像の生成を行う場合とを符号列のピクチャ共通情報部分に記述されるフラグを用いることによって必要に応じて切り替えることを可能としていた。   In the conventional method, a flag described in the picture common information portion of the code string is used to generate a predicted image using a fixed formula and to generate a predicted image using a weighted coefficient set of linear prediction coefficients. By using it, it was possible to switch as needed.

本実施の形態では、さらに実施の形態6から実施の形態9で説明した各種の線形予測方法をフラグを用いて切り替える方法について説明する。   In the present embodiment, a method for switching various linear prediction methods described in the sixth to ninth embodiments using a flag will be described.

図17(a)は、上記切り替えを制御するための5つのフラグ(p_flag、c_flag、d_flag、t_flag、s_flag)を符号列中のスライスヘッダ領域に記述する場合の構成である。   FIG. 17A shows a configuration in which five flags (p_flag, c_flag, d_flag, t_flag, s_flag) for controlling the switching are described in a slice header area in the code string.

図17(b)に示したように、p_flagは重み付け係数が符号化されているかどうかを示すためのフラグである。また、c_flagはref1用およびref2用のパラメータのうち、パラメータC(C1およびC2)に関するデータのみが符号化されているかどうかを示すフラグである。また、t_flagは線形予測を行うための重み付け係数を参照ピクチャの表示順情報を用いて生成するかどうかを示すフラグである。また、s_flagは線形予測を行うための重み付け係数をシフト演算で計算ができるように2のべき乗に近似するかどうかを示すフラグである。   As shown in FIG. 17B, p_flag is a flag for indicating whether or not the weighting coefficient is encoded. C_flag is a flag indicating whether or not only data related to the parameter C (C1 and C2) is encoded among the parameters for ref1 and ref2. Further, t_flag is a flag indicating whether or not a weighting coefficient for performing linear prediction is generated using display order information of reference pictures. Further, s_flag is a flag indicating whether a weighting coefficient for performing linear prediction is approximated to a power of 2 so that it can be calculated by a shift operation.

また、d_flagは式2aおよび式2bで示されたような、予め設定されている2つの固定式を用いて線形予測を行う際に、ref1によって指定されるピクチャとref2によって指定されるピクチャの時間的な位置関係によって2つの式を切り替えるかどうかを示すフラグである。つまり、このフラグによって切り替えるように指定された場合は、従来の方法と同様に、ref1によって指定されるピクチャがref2によって指定されるピクチャよりも表示順において後にある場合は式2aを使用し、それ以外の場合は式2bを使用して線形予測を行う。一方、このフラグによって切り替えを行わないように指定された場合は、ref1によって指定されるピクチャがref2によって指定されるピクチャの位置関係に関係なく、常に式2bを使用して線形予測を行う。   Also, d_flag is the time between the picture specified by ref1 and the picture specified by ref2 when performing linear prediction using two preset fixed expressions as shown in Expression 2a and Expression 2b. It is a flag indicating whether or not two expressions are switched depending on the positional relationship. In other words, if it is specified to switch by this flag, as in the conventional method, if the picture specified by ref1 is later in the display order than the picture specified by ref2, use Equation 2a. Otherwise, linear prediction is performed using Equation 2b. On the other hand, when it is specified not to switch by this flag, linear prediction is always performed using Expression 2b regardless of the positional relationship between the picture specified by ref1 and the picture specified by ref2.

なお、切り替えずに使用する式を式2bの代わりに式2aを用いた場合も同様に扱うことが可能である。   It should be noted that the expression used without switching can be handled in the same manner when the expression 2a is used instead of the expression 2b.

図2に示す復号化装置では符号列解析部201においてフラグp_flagの値を解析し、その結果に基づいて、重み付け係数セットに関するデータを復号化し予測画像の生成を行うのかどうかの指示を動き補償復号化部204に出力し、線形予測による動き補償を行う。これによって、処理能力の高い装置では重み付け係数セットを使用して線形予測を行い、処理能力の低い装置では重み付け係数セットを使用せずに線形予測を行うといった使い分けが可能となる。   In the decoding apparatus shown in FIG. 2, the code string analysis unit 201 analyzes the value of the flag p_flag, and based on the result, indicates whether or not to decode the data related to the weighting coefficient set and generate a predicted image by motion compensation decoding. Output to the conversion unit 204 and performs motion compensation by linear prediction. As a result, it is possible to selectively use such that a device with high processing capability performs linear prediction using a weighting coefficient set and a device with low processing capability performs linear prediction without using a weighting coefficient set.

同様に、図2に示す復号化装置では符号列解析部201においてフラグc_flagの値を解析し、その結果に基づいて、画像データのDC成分に相当するパラメータC(C1およびC2)に関するデータのみ復号化し固定式による予測画像の生成を行うのかどうかの指示を動き補償復号化部204に出力し、線形予測による動き補償を行う。これによって、処理能力の高い装置では全ての重み付け係数セットを使用して線形予測を行い、処理能力の低い装置では直流成分のみを使用して線形予測を行うといった使い分けが可能となる。   Similarly, in the decoding apparatus shown in FIG. 2, the value of the flag c_flag is analyzed by the code string analysis unit 201, and only data related to the parameter C (C1 and C2) corresponding to the DC component of the image data is decoded based on the result. An instruction as to whether or not to generate a prediction image by a fixed formula is output to the motion compensation decoding unit 204, and motion compensation by linear prediction is performed. As a result, it is possible to selectively use linear prediction using all weighting coefficient sets in a device with high processing capability, and linear prediction using only a DC component in a device with low processing capability.

同様に、図2に示す復号化装置では符号列解析部201においてフラグd_flagの値を解析し、その結果に基づいて、固定式を使用して線形予測を行う場合に、2つの式を切り替えて符号化するかどうかの指示を動き補償復号化部204に出力し、線形予測による動き補償を行う。これによって、画面の明度が時間的にほとんど変わらないような場合は片方の固定式のみを用いて線形予測を行い、画面の明度が時間的に変化するような場合は2つの固定式を切り替えて使用して線形予測を行うといった使い分けが可能となる。   Similarly, in the decoding apparatus shown in FIG. 2, when the code string analysis unit 201 analyzes the value of the flag d_flag and performs linear prediction using a fixed expression based on the result, the two expressions are switched. An instruction on whether to encode is output to the motion compensation decoding unit 204 to perform motion compensation by linear prediction. As a result, when the brightness of the screen hardly changes in time, linear prediction is performed using only one fixed formula, and when the brightness of the screen changes in time, the two fixed formulas are switched. It is possible to selectively use such as performing linear prediction.

同様に、図2に示す復号化装置では符号列解析部201においてフラグt_flagの値を解析し、その結果に基づいて、線形予測を行うための係数を参照ピクチャの表示順情
報を用いて生成するかどうかの指示を動き補償復号化部204に出力し、線形予測による動き補償を行う。これによって、符号量に余裕がある場合は重み付け係数セットを符号化して線形予測を行い、符号量に余裕がない場合は表示順情報から係数を生成して線形予測を行うといった使い分けが可能となる。
Similarly, in the decoding apparatus illustrated in FIG. 2, the code string analysis unit 201 analyzes the value of the flag t_flag, and generates a coefficient for performing linear prediction using the display order information of the reference picture based on the result. Is output to the motion compensation decoding unit 204 to perform motion compensation by linear prediction. As a result, when there is a margin in the code amount, linear prediction is performed by encoding the weighting coefficient set, and when there is no margin in the code amount, a coefficient is generated from the display order information and linear prediction is performed. .

同様に、図2に示す復号化装置では符号列解析部201においてフラグs_flagの値を解析し、その結果に基づいて、線形予測を行うための係数をシフト演算で計算できるように2のべき乗に近似するかどうかの指示を動き補償復号化部204に出力し、線形予測による動き補償を行う。これによって、処理能力の高い装置では重み付け係数を近似しないで使用して線形予測を行い、処理能力の低い装置では重み付け係数を2のべき乗に近似して使用しシフト演算で実現できる線形予測を行うといった使い分けが可能となる。   Similarly, in the decoding apparatus shown in FIG. 2, the value of the flag s_flag is analyzed in the code string analysis unit 201, and based on the result, a coefficient for performing linear prediction is raised to a power of 2 so that it can be calculated by a shift operation. An instruction on whether to approximate is output to the motion compensation decoding unit 204, and motion compensation is performed by linear prediction. As a result, a device with high processing capability performs linear prediction using the weighting coefficient without approximation, and a device with low processing capability performs linear prediction that can be realized by a shift operation using the weighting factor approximating a power of 2. It can be used properly.

例えば、(1)(p、c、d、t、s_flag)=(1、0、0、0、1)である場合は、全ての重み付け係数セットが復号化され、実施の形態7で説明したように、係数を2のべき乗で表すことによりシフト演算のみで線形予測を行い予測画像を生成することが指示される。   For example, when (1) (p, c, d, t, s_flag) = (1, 0, 0, 0, 1), all weighting coefficient sets are decoded and described in the seventh embodiment. Thus, by expressing the coefficient as a power of 2, it is instructed to generate a prediction image by performing linear prediction only by a shift operation.

また、(2)(p、c、d、t、s_flag)=(1、1、1、0、0)である場合は、パラメータC(C1およびC2)に関するデータのみが復号化され、実施の形態8で説明した固定式に係数Cを加えることによって予測画像を生成する方法を用い、さらに2つの固定式を切り替えて使用することが指示される。   Also, if (2) (p, c, d, t, s_flag) = (1, 1, 1, 0, 0), only the data related to the parameter C (C1 and C2) is decoded and Using the method of generating a predicted image by adding the coefficient C to the fixed formula described in the eighth mode, it is further instructed to switch between two fixed formulas.

また、(3)(p、c、d、t、s_flag)=(0、0、0、0、0)である場合は、重み付け係数セットは何も復号化されない。つまり、従来の方法である固定式のうち式2bのみを用いた予測画像の生成方法を用いることが指示される。   When (3) (p, c, d, t, s_flag) = (0, 0, 0, 0, 0), no weighting coefficient set is decoded. That is, it is instructed to use a prediction image generation method using only the formula 2b among the conventional fixed methods.

また、(4)(p、c、d、t、s_flag)=(0、0、1、1、1)である場合は、重み付け係数セットは何も復号化されないが、実施の形態9で説明したように、重み付け係数を参照ピクチャの表示順情報から生成し、さらに係数を2のべき乗で近似すことによりシフト演算のみで線形予測を行い、さらに2つの固定式を切り替えて使用して予測画像を生成することが指示される。   Further, when (4) (p, c, d, t, s_flag) = (0, 0, 1, 1, 1), no weighting coefficient set is decoded, but this will be described in the ninth embodiment. As described above, the weighting coefficient is generated from the display order information of the reference picture, and further, the coefficient is approximated by a power of 2 to perform linear prediction only by a shift operation, and the two fixed expressions are switched and used as a predicted image. Is generated.

なお、上記実施の形態では各々1ビットからなる5つのフラグ(p_flag、c_flag、d_flag、t_flag、s_flag)を用いて判別を行っているが、5つのフラグの代わりに5ビットからなる1つのフラグのみで表現することも可能である。また、その場合、5ビットで表現するのではなく可変長復号化を用いて復号化することも可能である。   In the above embodiment, the determination is performed using five flags (p_flag, c_flag, d_flag, t_flag, s_flag) each having one bit, but only one flag having five bits is used instead of the five flags. It can also be expressed as In this case, it is also possible to perform decoding using variable length decoding instead of expressing with 5 bits.

なお、上記実施の形態では各々1ビットからなる5つのフラグ(p_flag、c_flag、d_flag、t_flag、s_flag)を全て用いているが、そのうちの1部分のフラグのみを用いて線形予測方法の切り替えを行う場合も同様に扱うことが可能である。その場合、図17(a)に示したフラグは必要なもののみが符号化されて記述されていることになる。   In the above embodiment, all five flags (p_flag, c_flag, d_flag, t_flag, and s_flag) each consisting of 1 bit are used, but the linear prediction method is switched using only one of the flags. The case can be handled in the same way. In that case, only the necessary flags shown in FIG. 17A are coded and described.

従来の方法では、固定式を用いた予測画像の生成と、線形予測係数の重み付け係数セットを用いた予測画像の生成とを切り替えるためのフラグを符号列のピクチャ共通情報部分に設けて、ピクチャ単位で切り替えることを可能としていた。しかし、この方法であると、ピクチャ毎にしか予測画像の生成方法を切り替えることができなかった。   In the conventional method, a flag for switching between generation of a prediction image using a fixed expression and generation of a prediction image using a weighted coefficient set of linear prediction coefficients is provided in the picture common information portion of the code string, and It was possible to switch with. However, with this method, the prediction image generation method can be switched only for each picture.

しかし、本実施の形態で説明したように、この切り替えフラグを符号列のスライスヘッ
ダに設けるようにして、ピクチャを構成するスライスごとにいずれの方法で予測画像を生成するかを切り替えることを可能とすることにより、例えば、複雑な画像を持つスライスでは重み付け係数セットを用いた予測画像の生成を行い、単純な画像を持つスライスでは固定式を用いた予測画像の生成を行うことにより、処理量の増加を最小限に抑えつつ画質の向上を図ることが可能となる。
However, as described in the present embodiment, by providing this switching flag in the slice header of the code string, it is possible to switch which method is used to generate a predicted image for each slice constituting the picture. For example, in a slice having a complex image, a prediction image is generated using a weighting coefficient set, and in a slice having a simple image, a prediction image is generated using a fixed formula, thereby reducing the processing amount. It is possible to improve the image quality while minimizing the increase.

なお、上記実施の形態ではスライスヘッダ領域に5つのフラグ(p_flag、c_flag、d_flag、t_flag、s_flag)を記述してスライスごとに判別を行っているが、ピクチャ共通情報領域にこれらのフラグを記述することにより、ピクチャ単位で切り替えるようにすることも可能である。また、スライスを構成するブロックごとに切り替えフラグを設けることにより、さらにブロック単位で最適な方法で予測画像の生成を行うことも可能である。   In the embodiment described above, five flags (p_flag, c_flag, d_flag, t_flag, s_flag) are described in the slice header area, and discrimination is performed for each slice. However, these flags are described in the picture common information area. Thus, it is also possible to switch in units of pictures. Further, by providing a switching flag for each block constituting the slice, it is possible to generate a predicted image by an optimum method in units of blocks.

なお、本発明の実施の形態における表示順情報は、表示の順番に限定されるものではなく、実際の表示時間や、表示時間に伴って値が大きくなる所定のピクチャを基準とした各ピクチャの参照順序であっても良い。   Note that the display order information in the embodiment of the present invention is not limited to the display order, but the actual display time or the predetermined picture whose value increases with the display time is used as a reference. The reference order may be used.

(実施の形態11)
本発明の実施の形態11における動画像の符号化方法および復号化方法について説明する。なお、符号化装置および復号化装置の構成および符号化および復号化の処理の流れおよび参照インデックスの割り当て方法は実施の形態1および実施の形態6と全く同様であるため、ここでは説明を省略する。
(Embodiment 11)
A moving picture encoding method and decoding method according to Embodiment 11 of the present invention will be described. Note that the configuration of the encoding device and the decoding device, the flow of encoding and decoding processes, and the method of assigning reference indexes are exactly the same as those in the first and sixth embodiments, and thus description thereof is omitted here. .

本実施の形態は実施の形態5および実施の形態10において説明した内容と同様の技術に関する説明である。   The present embodiment is a description related to the same technology as the contents described in the fifth and tenth embodiments.

パラメータセットが符号化されているかどうかを示すフラグp_flagと、ref1用およびref2用のパラメータのうち、パラメータC(C1およびC2)に関するデータのみが符号化されているかどうかを示すフラグc_flagと、をスライス毎に示す。   Slice a flag p_flag indicating whether or not the parameter set is encoded, and a flag c_flag indicating whether or not only data related to the parameter C (C1 and C2) is encoded among the parameters for ref1 and ref2 Shown for each.

図1に示す符号化装置では動き補償符号化部107において、各スライスごともしくはブロックごとに、パラメータセットに関するデータを符号化するか否かを決定し、それに基づいてフラグp_flagの情報を符号列生成部103に出力し、図40(a)に示すように符号列中に記述する。   In the encoding apparatus shown in FIG. 1, the motion compensation encoding unit 107 determines whether or not to encode data related to the parameter set for each slice or block, and generates information on the flag p_flag based on this. The data is output to the unit 103 and described in the code string as shown in FIG.

同様に、図1に示す符号化装置では動き補償符号化部107において、各スライスごともしくはブロックごとに、画像データのDC成分に相当するパラメータC(C1,C2)に関するデータのみ符号化するか否かを決定し、それに基づいてフラグc_flagの情報を符号列生成部103に出力し、図40(a)に示すように符号列中に記述する。   Similarly, in the encoding apparatus shown in FIG. 1, in the motion compensation encoding unit 107, only data related to the parameter C (C1, C2) corresponding to the DC component of the image data is encoded for each slice or block. Based on this, the information of the flag c_flag is output to the code string generation unit 103 and described in the code string as shown in FIG.

一方、図2に示す復号化装置では符号列解析部201において前記切り替えフラグp_flagとフラグc_flgとの値を解析し、その結果に基づいて、例えばダウンロードしたパラメータセットを用いて予測画像を生成するのか、あるいは固定式を用いて予測画像を生成するのかの指示を動き補償復号化部204に出力し、線形予測による動き補償を行う。   On the other hand, in the decoding apparatus shown in FIG. 2, the code string analysis unit 201 analyzes the values of the switching flag p_flag and the flag c_flg, and based on the result, for example, uses the downloaded parameter set to generate a predicted image. Alternatively, an instruction on whether to generate a predicted image using a fixed expression is output to the motion compensation decoding unit 204, and motion compensation is performed by linear prediction.

例えば、図40(b)に示すように、(1)フラグp_flagが1であり、フラグc_flagが0である場合には、符号化装置において全てのパラメータセットが符号化される。また、(2)フラグp_flagが1であり、フラグc_flagが1である場合には、符号化装置においてパラメータC(C1およびC2)に関するデータのみが符号化される。さらに、(3)フラグp_flagが0であり、フラグc_flagが0である場合に
は、符号化装置においてパラメータセットは何も符号化されない。なお、図40(b)に示すようにフラグの値を決定すると、フラグp_flagによって画像データのDC成分が符号化されているかが判別できる。
For example, as shown in FIG. 40B, (1) when the flag p_flag is 1 and the flag c_flag is 0, all parameter sets are encoded in the encoding device. (2) When the flag p_flag is 1 and the flag c_flag is 1, only the data related to the parameter C (C1 and C2) is encoded in the encoding device. Further, (3) when the flag p_flag is 0 and the flag c_flag is 0, no parameter set is encoded in the encoding device. When the flag value is determined as shown in FIG. 40B, it can be determined whether the DC component of the image data is encoded by the flag p_flag.

符号化装置において、前記(1)の場合は、例えば図8から図10で説明したようにパラメータは処理される。前記(2)の場合は、例えば図16で説明したようにパラメータは処理される。前記(3)の場合は、例えば固定式を用いてパラメータは処理される。   In the encoding apparatus, in the case of (1), parameters are processed as described with reference to FIGS. In the case of (2), parameters are processed as described in FIG. 16, for example. In the case of (3), parameters are processed using, for example, a fixed formula.

復号化装置において、前記(1)の場合は、例えば図18から図20で説明したようにパラメータは処理される。前記(2)の場合は、例えば図22で説明したようにパラメータは処理される。前記(3)の場合は、例えば固定式を用いてパラメータは処理される。   In the decoding apparatus, in the case of (1), parameters are processed as described with reference to FIGS. In the case of (2), for example, the parameters are processed as described in FIG. In the case of (3), parameters are processed using, for example, a fixed formula.

さらに、組み合わせた場合の別の例について、以下に、具体的に説明する。
上記の例では、フラグp_flag、フラグc_flagを用いて明示的にパラメータを符号化する(受信させるか)を切り替えたが、前記フラグを用いず、可変長符号化テーブル(VLCテーブル)を用いることも可能である。
Furthermore, another example in the case of combining will be specifically described below.
In the above example, the parameter is explicitly encoded (received) using the flag p_flag and the flag c_flag, but the variable length coding table (VLC table) may be used without using the flag. Is possible.

図41に示すように、固定式2aと固定式2bを切り替えるかどうかの選択も、さらに明示的に行うことができる。   As shown in FIG. 41, whether or not to switch between the fixed type 2a and the fixed type 2b can also be explicitly selected.

ここで、固定式2の切り替えを行わないとは、以下を意味する。例えば、上記で従来の技術では、第1参照インデックスによって指定されるピクチャが第2参照インデックスによって指定されるピクチャよりも表示順において後にある場合は、固定の係数からなる固定式である式2aを選択し、それ以外は固定の係数からなる固定式である式2bを選択して、予測画像を生成する、ことを説明した。一方、図41に示す例で、切り替えを行わないと指示された場合は、第1参照インデックスによって指定されるピクチャが第2参照インデックスによって指定されるピクチャよりも符号化順において後にある場合であっても、固定の係数からなる固定式である式2bを選択して、予測画像を生成するようにすることを意味する。   Here, not switching the fixed type 2 means the following. For example, in the conventional technique described above, when the picture specified by the first reference index is later in the display order than the picture specified by the second reference index, Expression 2a, which is a fixed expression including a fixed coefficient, is used. It has been described that the predicted image is generated by selecting the formula 2b, which is a fixed formula consisting of a fixed coefficient other than that selected. On the other hand, in the example shown in FIG. 41, when it is instructed not to switch, the picture specified by the first reference index is later in the coding order than the picture specified by the second reference index. However, it means that the formula 2b which is a fixed formula composed of fixed coefficients is selected to generate a predicted image.

固定式2aと固定式2bを切り替えるかどうかの選択も明示的に行うためのフラグv_flagの情報は符号列生成部103から出力され図41(a)に示すように符号列中に記述される。   Information on the flag v_flag for explicitly selecting whether to switch between the fixed expression 2a and the fixed expression 2b is output from the code string generation unit 103 and described in the code string as shown in FIG.

図41(b)にフラグv_flagによる処理の例を示す。図41(b)に示すようにフラグv_flagが1のとき、パラメータの符号化は行わず(符号化装置でパラメータはダウンロードされない。以下同様)、固定式2の切り替えは行わない。また、フラグv_flagが01のとき、パラメータの符号化は行わず、固定式2の切り替えは行う。また、フラグv_flagが0000のとき、パラメータの符号化はパラメータCのみ行い、固定式2の切り替えは行わない。   FIG. 41B shows an example of processing using the flag v_flag. As shown in FIG. 41 (b), when the flag v_flag is 1, the parameter is not encoded (the parameter is not downloaded by the encoding device; the same applies hereinafter), and the fixed type 2 is not switched. When the flag v_flag is 01, the parameter is not encoded and the fixed type 2 is switched. When the flag v_flag is 0000, parameter encoding is performed only for parameter C, and fixed type 2 is not switched.

また、フラグv_flagが0001のとき、パラメータの符号化はパラメータCのみ行い、固定式2の切り替えを行う。また、フラグv_flagが0010のとき、パラメータの符号化はパラメータ全てについて行い、固定式12の切り替えは行わない。また、フラグv_flagが0011のとき、パラメータの符号化はパラメータ全てについて行い、固定式12の切り替えを行う。   When the flag v_flag is 0001, parameter encoding is performed only for parameter C, and fixed type 2 is switched. When the flag v_flag is 0010, parameter encoding is performed for all parameters, and the fixed expression 12 is not switched. When the flag v_flag is 0011, parameter encoding is performed for all parameters, and the fixed expression 12 is switched.

なお、v_flagが0010および0011のときはパラメータ全てが符号化されているので、固定式を使用せずに、重み付けパラメータを用いた線形予測を行うことが可能であり、その場合は固定式を切り替えて使用するかどうかの判別は無視される。   When v_flag is 0010 and 0011, all parameters are encoded, so it is possible to perform linear prediction using weighting parameters without using a fixed formula. In that case, the fixed formula is switched. The determination of whether or not to use is ignored.

なお、フラグv_flagの切り替えは、図1に示す符号化装置では動き補償符号化部107において行い、図2に示す復号化装置では動き補償復号化部204において行うことができる。また、フラグv_flagでなく、上記のフラグp_flagとフラグc_flagに加え、固定式を切り替えるかどうかを示すフラグd_flagを用いるようにしてもよい。   Note that the flag v_flag can be switched in the motion compensation encoding unit 107 in the encoding device shown in FIG. 1, and in the motion compensation decoding unit 204 in the decoding device shown in FIG. Further, instead of the flag v_flag, in addition to the flag p_flag and the flag c_flag, a flag d_flag indicating whether or not to switch the fixed expression may be used.

以上で示したように、フラグを用いることで、パラメータを符号化装置において符号化して、符号化されたパラメータを復号化装置で受信(ダウンロード)するかどうかを切り替えることができるようになる。これにより、アプリケーションの特性や、復号化装置側の処理能力によって、符号化する(受信させる)パラメータを明示的に切り替えることができる。   As described above, by using a flag, it is possible to switch whether the parameter is encoded by the encoding device and whether the encoded parameter is received (downloaded) by the decoding device. Thereby, the parameter to be encoded (received) can be explicitly switched depending on the characteristics of the application and the processing capability on the decoding device side.

また、固定式の切り替えを明示的に変更可能にすることで、画質の向上を図る手段が増え、ひいては符号化効率の向上も図ることが可能になる。また、復号化装置で有していない固定式がある場合でも、明示的に固定式を変更することによって、明示的に選択した固定式による予測画像の生成が可能になる。   In addition, by making it possible to explicitly change the fixed switching, it is possible to increase means for improving the image quality, and thus to improve the encoding efficiency. Further, even when there is a fixed expression that the decoding apparatus does not have, by explicitly changing the fixed expression, it is possible to generate a predicted image using the explicitly selected fixed expression.

なお、図40中のフラグの配置は図示するものに限られない。また、フラグの値は上記で説明したものに限られない。また、2種類のフラグを用いると、4通りのパラメータの用い方を明示することが可能になるので、上記で説明した以外のパラメータの用い方を割り当てるようにしてもよい。また、上記の例で全てのパラメータを送ると説明したが、例えば図10および図20で説明したように必要なパラメータセットを全て送るようにしてもよい。   Note that the arrangement of the flags in FIG. 40 is not limited to that shown in the figure. Further, the value of the flag is not limited to that described above. Further, when two types of flags are used, it is possible to clearly indicate how to use four types of parameters. Therefore, it is possible to assign a method of using parameters other than those described above. Further, although it has been described that all parameters are sent in the above example, all necessary parameter sets may be sent as described in FIGS. 10 and 20, for example.

(実施の形態12)
さらに、上記各実施の形態で示した画像符号化方法または画像復号化方法の構成を実現するためのプログラムを、フレキシブルディスク等の記憶媒体に記録するようにすることにより、上記各実施の形態で示した処理を、独立したコンピュータシステムにおいて簡単に実施することが可能となる。
(Embodiment 12)
Further, by recording a program for realizing the configuration of the image encoding method or the image decoding method shown in each of the above embodiments on a storage medium such as a flexible disk, the above embodiments can be used. The illustrated processing can be easily performed in an independent computer system.

図25は、上記実施の形態1から実施の形態11の画像符号化方法または画像復号化方法を格納したフレキシブルディスクを用いて、コンピュータシステムにより実施する場合の説明図である。   FIG. 25 is an explanatory diagram in the case of implementing by a computer system using a flexible disk storing the image coding method or the image decoding method of the first to eleventh embodiments.

図25(b)は、フレキシブルディスクの正面からみた外観、断面構造、及びフレキシブルディスクを示し、図25(a)は、記録媒体本体であるフレキシブルディスクの物理フォーマットの例を示している。フレキシブルディスクFDはケースF内に内蔵され、該ディスクの表面には、同心円状に外周からは内周に向かって複数のトラックTrが形成され、各トラックは角度方向に16のセクタSeに分割されている。従って、上記プログラムを格納したフレキシブルディスクでは、上記フレキシブルディスクFD上に割り当てられた領域に、上記プログラムとしての画像符号化方法が記録されている。   FIG. 25B shows an appearance, a cross-sectional structure, and a flexible disk as seen from the front of the flexible disk, and FIG. 25A shows an example of a physical format of the flexible disk that is a recording medium body. The flexible disk FD is built in the case F, and a plurality of tracks Tr are formed concentrically on the surface of the disk from the outer periphery toward the inner periphery, and each track is divided into 16 sectors Se in the angular direction. ing. Therefore, in the flexible disk storing the program, an image encoding method as the program is recorded in an area allocated on the flexible disk FD.

また、図25(c)は、フレキシブルディスクFDに上記プログラムの記録再生を行うための構成を示す。上記プログラムをフレキシブルディスクFDに記録する場合は、コンピュータシステムCsから上記プログラムとしての画像符号化方法または画像復号化方法をフレキシブルディスクドライブを介して書き込む。また、フレキシブルディスク内のプログラムにより上記画像符号化方法をコンピュータシステム中に構築する場合は、フレキシブルディスクドライブによりプログラムをフレキシブルディスクから読み出し、コンピ
ュータシステムに転送する。
FIG. 25C shows a configuration for recording and reproducing the program on the flexible disk FD. When recording the program on the flexible disk FD, the image encoding method or the image decoding method as the program is written from the computer system Cs via the flexible disk drive. When the image encoding method is built in a computer system by a program in a flexible disk, the program is read from the flexible disk by a flexible disk drive and transferred to the computer system.

なお、上記説明では、記録媒体としてフレキシブルディスクを用いて説明を行ったが、光ディスクを用いても同様に行うことができる。また、記録媒体はこれに限らず、ICカード、ROMカセット等、プログラムを記録できるものであれば同様に実施することができる。   In the above description, a flexible disk is used as the recording medium, but the same can be done using an optical disk. Further, the recording medium is not limited to this, and any recording medium such as an IC card or a ROM cassette capable of recording a program can be similarly implemented.

(実施の形態13)
図26から図29は、上記実施の形態で示した符号化処理または復号化処理を行う機器、およびこの機器を用いたシステムを説明する図である。
(Embodiment 13)
FIG. 26 to FIG. 29 are diagrams illustrating a device that performs the encoding process or the decoding process described in the above embodiment, and a system using this device.

図26は、コンテンツ配信サービスを実現するコンテンツ供給システムex100の全体構成を示すブロック図である。通信サービスの提供エリアを所望の大きさに分割し、各セル内にそれぞれ固定無線局である基地局ex107〜ex110が設置されている。   FIG. 26 is a block diagram showing an overall configuration of a content supply system ex100 that implements a content distribution service. The communication service providing area is divided into desired sizes, and base stations ex107 to ex110, which are fixed radio stations, are installed in each cell.

このコンテンツ供給システムex100は、例えば、インターネットex101にインターネットサービスプロバイダex102および電話網ex104、および基地局ex107〜ex110を介して、コンピュータex111、PDA(personal digital assistant)ex112、カメラex113、携帯電話ex114、カメラ付きの携帯電話ex115などの各機器が接続される。   The content supply system ex100 includes, for example, a computer ex111, a PDA (personal digital assistant) ex112, a camera ex113, a mobile phone ex114, a camera via the Internet ex101, the Internet service provider ex102, the telephone network ex104, and the base stations ex107 to ex110. Each device such as the attached mobile phone ex115 is connected.

しかし、コンテンツ供給システムex100は図26のような組合せに限定されず、いずれかを組み合わせて接続するようにしてもよい。また、固定無線局である基地局ex107〜ex110を介さずに、各機器が電話網ex104に直接接続されてもよい。   However, the content supply system ex100 is not limited to the combination as shown in FIG. 26, and any combination may be connected. Further, each device may be directly connected to the telephone network ex104 without going through the base stations ex107 to ex110 which are fixed wireless stations.

カメラex113はデジタルビデオカメラ等の動画撮影が可能な機器である。また、携帯電話は、PDC(Personal Digital Communications)方式、CDMA(Code Division Multiple Access)方式、W−CDMA(Wideband-Code Division Multiple Access)方式、若しくはGSM(Global System for Mobile Communications)方式の携帯電話機、またはPHS(Personal Handyphone System)等であり、いずれでも構わない。   The camera ex113 is a device capable of shooting a moving image such as a digital video camera. The mobile phone is a PDC (Personal Digital Communications) system, a CDMA (Code Division Multiple Access) system, a W-CDMA (Wideband-Code Division Multiple Access) system, or a GSM (Global System for Mobile Communications) system mobile phone, Alternatively, PHS (Personal Handyphone System) or the like may be used.

また、ストリーミングサーバex103は、カメラex113から基地局ex109、電話網ex104を通じて接続されており、カメラex113を用いてユーザが送信する符号化処理されたデータに基づいたライブ配信等が可能になる。撮影したデータの符号化処理はカメラex113で行っても、データの送信処理をするサーバ等で行ってもよい。   In addition, the streaming server ex103 is connected from the camera ex113 through the base station ex109 and the telephone network ex104, and live distribution or the like based on the encoded data transmitted by the user using the camera ex113 becomes possible. The encoded processing of the captured data may be performed by the camera ex113 or may be performed by a server or the like that performs data transmission processing.

また、カメラ116で撮影した動画データはコンピュータex111を介してストリーミングサーバex103に送信されてもよい。カメラex116はデジタルカメラ等の静止画、動画が撮影可能な機器である。この場合、動画データの符号化はカメラex116で行ってもコンピュータex111で行ってもどちらでもよい。また、符号化処理はコンピュータex111やカメラex116が有するLSIex117において処理することになる。   Further, the moving image data shot by the camera 116 may be transmitted to the streaming server ex103 via the computer ex111. The camera ex116 is a device that can shoot still images and moving images, such as a digital camera. In this case, the encoding of the moving image data may be performed by the camera ex116 or the computer ex111. The encoding process is performed in the LSI ex117 included in the computer ex111 and the camera ex116.

なお、画像符号化・復号化用のソフトウェアをコンピュータex111等で読み取り可能な記録媒体である何らかの蓄積メディア(CD−ROM、フレキシブルディスク、ハードディスクなど)に組み込んでもよい。さらに、カメラ付きの携帯電話ex115で動画データを送信してもよい。このときの動画データは携帯電話ex115が有するLSIで符号化処理されたデータである。   Note that image encoding / decoding software may be incorporated into any storage medium (CD-ROM, flexible disk, hard disk, etc.) that is a recording medium readable by the computer ex111 or the like. Furthermore, you may transmit moving image data with the mobile telephone ex115 with a camera. The moving image data at this time is data encoded by the LSI included in the mobile phone ex115.

このコンテンツ供給システムex100では、ユーザがカメラex113、カメラex116等で撮影しているコンテンツ(例えば、音楽ライブを撮影した映像等)を上記実施の形態同様に符号化処理してストリーミングサーバex103に送信する一方で、ストリーミング
サーバex103は要求のあったクライアントに対して上記コンテンツデータをストリーム配信する。クライアントとしては、上記符号化処理されたデータを復号化することが可能な、コンピュータex111、PDAex112、カメラex113、携帯電話ex114等がある。このようにすることでコンテンツ供給システムex100は、符号化されたデータをクライアントにおいて受信して再生することができ、さらにクライアントにおいてリアルタイムで受信して復号化し、再生することにより、個人放送をも実現可能になるシステムである。
In this content supply system ex100, the content (for example, video shot of music live) captured by the user with the camera ex113, camera ex116, etc. is encoded and transmitted to the streaming server ex103 as in the above embodiment. On the other hand, the streaming server ex103 distributes the content data to the requested client. Examples of the client include a computer ex111, a PDA ex112, a camera ex113, a mobile phone ex114, and the like that can decode the encoded data. In this way, the content supply system ex100 can receive and reproduce the encoded data at the client, and also realize personal broadcasting by receiving, decoding, and reproducing in real time at the client. It is a system that becomes possible.

このシステムを構成する各機器の符号化、復号化には上記各実施の形態で示した動画像符号化装置あるいは動画像復号化装置を用いるようにすればよい。   For the encoding and decoding of each device constituting this system, the moving image encoding device or the moving image decoding device described in the above embodiments may be used.

その一例として携帯電話について説明する。
図28は、上記実施の形態で説明した動画像符号化方法と動画像復号化方法を用いた携帯電話ex115を示す図である。携帯電話ex115は、基地局ex110との間で電波を送受信するためのアンテナex201、CCDカメラ等の映像、静止画を撮ることが可能なカメラ部ex203、カメラ部ex203で撮影した映像、アンテナex201で受信した映像等が復号化されたデータを表示する液晶ディスプレイ等の表示部ex202、操作キーex204群から構成される本体部、音声出力をするためのスピーカ等の音声出力部ex208、音声入力をするためのマイク等の音声入力部ex205、撮影した動画もしくは静止画のデータ、受信したメールのデータ、動画のデータもしくは静止画のデータ等、符号化されたデータまたは復号化されたデータを保存するための記録メディアex207、携帯電話ex115に記録メディアex207を装着可能とするためのスロット部ex206を有している。記録メディアex207はSDカード等のプラスチックケース内に電気的に書換えや消去が可能な不揮発性メモリであるEEPROM(Electrically Erasable and Programmable Read Only Memory)の一種であるフラッシュメモリ素子を格納したものである。
A mobile phone will be described as an example.
FIG. 28 is a diagram illustrating a mobile phone ex115 that uses the moving picture coding method and the moving picture decoding method described in the above embodiment. The cellular phone ex115 includes an antenna ex201 for transmitting and receiving radio waves to and from the base station ex110, a camera such as a CCD camera, a camera unit ex203 capable of taking a still image, a video shot by the camera unit ex203, and an antenna ex201. A display unit ex202 such as a liquid crystal display for displaying data obtained by decoding received video and the like, a main body unit composed of a group of operation keys ex204, an audio output unit ex208 such as a speaker for audio output, and audio input To store encoded data or decoded data such as a voice input unit ex205 such as a microphone, captured video or still image data, received mail data, video data or still image data, etc. Recording medium ex207 and a slot ex206 for enabling the recording medium ex207 to be attached to the mobile phone ex115. Have. The recording medium ex207 stores a flash memory element which is a kind of EEPROM (Electrically Erasable and Programmable Read Only Memory) which is a nonvolatile memory that can be electrically rewritten and erased in a plastic case such as an SD card.

さらに、携帯電話ex115について図27を用いて説明する。携帯電話ex115は表示部ex202及び操作キーex204を備えた本体部の各部を統括的に制御するようになされた主制御部ex311に対して、電源回路部ex310、操作入力制御部ex304、画像符号化部ex312、カメラインターフェース部ex303、LCD(Liquid Crystal Display)制御部ex302、画像復号化部ex309、多重分離部ex308、記録再生部ex307、変復調回路部ex306及び音声処理部ex305が同期バスex313を介して互いに接続されている。   Further, the cellular phone ex115 will be described with reference to FIG. The mobile phone ex115 controls the power supply circuit ex310, the operation input control unit ex304, and the image encoding for the main control unit ex311 configured to control the respective units of the main body unit including the display unit ex202 and the operation key ex204. Unit ex312, camera interface unit ex303, LCD (Liquid Crystal Display) control unit ex302, image decoding unit ex309, demultiplexing unit ex308, recording / reproducing unit ex307, modulation / demodulation circuit unit ex306, and audio processing unit ex305 via a synchronization bus ex313 Are connected to each other.

電源回路部ex310は、ユーザの操作により終話及び電源キーがオン状態にされると、バッテリパックから各部に対して電力を供給することによりカメラ付ディジタル携帯電話ex115を動作可能な状態に起動する。   When the end call and power key are turned on by a user operation, the power supply circuit ex310 activates the camera-equipped digital mobile phone ex115 by supplying power from the battery pack to each unit. .

携帯電話ex115は、CPU、ROM及びRAM等でなる主制御部ex311の制御に基づいて、音声通話モード時に音声入力部ex205で集音した音声信号を音声処理部ex305によってディジタル音声データに変換し、これを変復調回路部ex306でスペクトラム拡散処理し、送受信回路部ex301でディジタルアナログ変換処理及び周波数変換処理を施した後にアンテナex201を介して送信する。また携帯電話機ex115は、音声通話モード時にアンテナex201で受信した受信信号を増幅して周波数変換処理及びアナログディジタル変換処理を施し、変復調回路部ex306でスペクトラム逆拡散処理し、音声処理部ex305によってアナログ音声信号に変換した後、これを音声出力部ex208を介して出力する。   The mobile phone ex115 converts the voice signal collected by the voice input unit ex205 in the voice call mode into digital voice data by the voice processing unit ex305 based on the control of the main control unit ex311 including a CPU, a ROM, a RAM, and the like. The modulation / demodulation circuit unit ex306 performs spread spectrum processing, and the transmission / reception circuit unit ex301 performs digital analog conversion processing and frequency conversion processing, and then transmits the result via the antenna ex201. In addition, the cellular phone ex115 amplifies the received signal received by the antenna ex201 in the voice call mode, performs frequency conversion processing and analog-digital conversion processing, performs spectrum despreading processing by the modulation / demodulation circuit unit ex306, and analog audio by the voice processing unit ex305. After conversion to a signal, this is output via the audio output unit ex208.

さらに、データ通信モード時に電子メールを送信する場合、本体部の操作キーex204の操作によって入力された電子メールのテキストデータは操作入力制御部ex304を介して主制御部ex311に送出される。主制御部ex311は、テキストデータを変復調回路部ex306でスペクトラム拡散処理し、送受信回路部ex301でディジタルアナログ変換処理及び周波数変換処理を施した後にアンテナex201を介して基地局ex110へ送信する。   Further, when an e-mail is transmitted in the data communication mode, text data of the e-mail input by operating the operation key ex204 on the main body is sent to the main control unit ex311 via the operation input control unit ex304. The main control unit ex311 performs spread spectrum processing on the text data in the modulation / demodulation circuit unit ex306, performs digital analog conversion processing and frequency conversion processing in the transmission / reception circuit unit ex301, and then transmits the text data to the base station ex110 via the antenna ex201.

データ通信モード時に画像データを送信する場合、カメラ部ex203で撮像された画像データをカメラインターフェース部ex303を介して画像符号化部ex312に供給する。また、画像データを送信しない場合には、カメラ部ex203で撮像した画像データをカメラインターフェース部ex303及びLCD制御部ex302を介して表示部ex202に直接表示することも可能である。   When transmitting image data in the data communication mode, the image data captured by the camera unit ex203 is supplied to the image encoding unit ex312 via the camera interface unit ex303. When image data is not transmitted, the image data captured by the camera unit ex203 can be directly displayed on the display unit ex202 via the camera interface unit ex303 and the LCD control unit ex302.

画像符号化部ex312は、本願発明で説明した画像符号化装置を備えた構成であり、カメラ部ex203から供給された画像データを上記実施の形態で示した画像符号化装置に用いた符号化方法によって圧縮符号化することにより符号化画像データに変換し、これを多重分離部ex308に送出する。また、このとき同時に携帯電話機ex115は、カメラ部ex203で撮像中に音声入力部ex205で集音した音声を音声処理部ex305を介してディジタルの音声データとして多重分離部ex308に送出する。   The image encoding unit ex312 has a configuration including the image encoding device described in the present invention, and an encoding method using the image data supplied from the camera unit ex203 in the image encoding device described in the above embodiment. The encoded image data is converted into encoded image data by compression encoding, and sent to the demultiplexing unit ex308. At the same time, the cellular phone ex115 sends the sound collected by the audio input unit ex205 during imaging by the camera unit ex203 to the demultiplexing unit ex308 as digital audio data via the audio processing unit ex305.

多重分離部ex308は、画像符号化部ex312から供給された符号化画像データと音声処理部ex305から供給された音声データとを所定の方式で多重化し、その結果得られる多重化データを変復調回路部ex306でスペクトラム拡散処理し、送受信回路部ex301でディジタルアナログ変換処理及び周波数変換処理を施した後にアンテナex201を介して送信する。   The demultiplexing unit ex308 multiplexes the encoded image data supplied from the image encoding unit ex312 and the audio data supplied from the audio processing unit ex305 by a predetermined method, and the multiplexed data obtained as a result is a modulation / demodulation circuit unit A spectrum spread process is performed at ex306, a digital-analog conversion process and a frequency conversion process are performed at the transmission / reception circuit unit ex301, and then transmitted through the antenna ex201.

データ通信モード時にホームページ等にリンクされた動画像ファイルのデータを受信する場合、アンテナex201を介して基地局ex110から受信した受信信号を変復調回路部ex306でスペクトラム逆拡散処理し、その結果得られる多重化データを多重分離部ex308に送出する。   When receiving data of a moving image file linked to a home page or the like in the data communication mode, the received signal received from the base station ex110 via the antenna ex201 is subjected to spectrum despreading processing by the modulation / demodulation circuit unit ex306, and the resulting multiplexing is obtained. Is sent to the demultiplexing unit ex308.

また、アンテナex201を介して受信された多重化データを復号化するには、多重分離部ex308は、多重化データを分離することにより画像データの符号化ビットストリームと音声データの符号化ビットストリームとに分け、同期バスex313を介して当該符号化画像データを画像復号化部ex309に供給すると共に当該音声データを音声処理部ex305に供給する。   In addition, in order to decode the multiplexed data received via the antenna ex201, the demultiplexing unit ex308 separates the multiplexed data to generate an encoded bitstream of image data and an encoded bitstream of audio data. The encoded image data is supplied to the image decoding unit ex309 via the synchronization bus ex313, and the audio data is supplied to the audio processing unit ex305.

次に、画像復号化部ex309は、本願発明で説明した画像復号化装置を備えた構成であり、画像データの符号化ビットストリームを上記実施の形態で示した符号化方法に対応した復号化方法で復号することにより再生動画像データを生成し、これをLCD制御部ex302を介して表示部ex202に供給し、これにより、例えばホームページにリンクされた動画像ファイルに含まれる動画データが表示される。このとき同時に音声処理部ex305は、音声データをアナログ音声信号に変換した後、これを音声出力部ex208に供給し、これにより、例えばホームページにリンクされた動画像ファイルに含まる音声データが再生される。   Next, the image decoding unit ex309 is configured to include the image decoding device described in the present invention, and a decoding method corresponding to the encoding method described in the above embodiment for an encoded bit stream of image data. To generate playback moving image data, which is supplied to the display unit ex202 via the LCD control unit ex302, thereby displaying, for example, moving image data included in the moving image file linked to the homepage . At the same time, the audio processing unit ex305 converts the audio data into an analog audio signal, and then supplies the analog audio signal to the audio output unit ex208. Thus, for example, the audio data included in the moving image file linked to the home page is reproduced. The

なお、上記システムの例に限られず、最近は衛星、地上波によるディジタル放送が話題となっており、図29に示すようにディジタル放送用システムにも上記実施の形態の少なくとも画像符号化装置または画像復号化装置のいずれかを組み込むことができる。具体的には、放送局ex409では映像情報の符号化ビットストリームが電波を介して通信または放送衛星ex410に伝送される。これを受けた放送衛星ex410は、放送用の電波を発信し、この電波を衛星放送受信設備をもつ家庭のアンテナex406で受信し、テレビ(受信機)ex401またはセットトップボックス(STB)ex407などの装置により符号化ビットストリームを復号化してこれを再生する。   It should be noted that the present invention is not limited to the above-described system, and recently, digital broadcasting using satellites and terrestrial waves has become a hot topic. As shown in FIG. Any of the decoding devices can be incorporated. Specifically, in the broadcasting station ex409, the encoded bit stream of the video information is transmitted to the communication or broadcasting satellite ex410 via radio waves. Receiving this, the broadcasting satellite ex410 transmits a radio wave for broadcasting, and receives the radio wave with a home antenna ex406 having a satellite broadcasting receiving facility, such as a television (receiver) ex401 or a set top box (STB) ex407. The device decodes the encoded bit stream and reproduces it.

また、記録媒体であるCDやDVD等の蓄積メディアex402に記録した符号化ビットストリームを読み取り、復号化する再生装置ex403にも上記実施の形態で示した画像復号化装置を実装することが可能である。この場合、再生された映像信号はモニタex404に表示される。また、ケーブルテレビ用のケーブルex405または衛星/地上波放送のアンテナex406に接続されたセットトップボックスex407内に画像復号化装置を実装し、これをテレビのモニタex408で再生する構成も考えられる。このときセットトップボックスではなく、テレビ内に画像復号化装置を組み込んでも良い。また、アンテナex411を有する車ex412で衛星ex410からまたは基地局ex107等から信号を受信し、車ex412が有するカーナビゲーションex413等の表示装置に動画を再生することも可能である。   In addition, the image decoding apparatus described in the above embodiment can also be implemented in a playback apparatus ex403 that reads and decodes an encoded bitstream recorded on a storage medium ex402 such as a CD or DVD as a recording medium. is there. In this case, the reproduced video signal is displayed on the monitor ex404. Further, a configuration in which an image decoding device is mounted in a set-top box ex407 connected to a cable ex405 for cable television or an antenna ex406 for satellite / terrestrial broadcasting, and this is reproduced on the monitor ex408 of the television is also conceivable. At this time, the image decoding apparatus may be incorporated in the television instead of the set top box. It is also possible to receive a signal from the satellite ex410 or the base station ex107 by the car ex412 having the antenna ex411 and reproduce a moving image on a display device such as the car navigation ex413 that the car ex412 has.

更に、画像信号を上記実施の形態で示した画像符号化装置で符号化し、記録媒体に記録することもできる。具体例としては、DVDディスクex421に画像信号を記録するDVDレコーダや、ハードディスクに記録するディスクレコーダなどのレコーダex420がある。更にSDカードex422に記録することもできる。レコーダex420が上記実施の形態で示した画像復号化装置を備えていれば、DVDディスクex421やSDカードex422に記録した画像信号を再生し、モニタex408で表示することができる。   Further, the image signal can be encoded by the image encoding device shown in the above embodiment and recorded on a recording medium. Specific examples include a recorder ex420 such as a DVD recorder that records image signals on a DVD disk ex421 and a disk recorder that records on a hard disk. Further, it can be recorded on the SD card ex422. If the recorder ex420 includes the image decoding device described in the above embodiment, the image signal recorded on the DVD disc ex421 or the SD card ex422 can be reproduced and displayed on the monitor ex408.

なお、カーナビゲーションex413の構成は例えば図28に示す構成のうち、カメラ部ex203とカメラインターフェース部ex303、画像符号化部ex312を除いた構成が考えられ、同様なことがコンピュータex111やテレビ(受信機)ex401等でも考えられる。   As the configuration of the car navigation ex413, for example, the configuration excluding the camera unit ex203, the camera interface unit ex303, and the image encoding unit ex312 in the configuration illustrated in FIG. 28 can be considered, and the same applies to the computer ex111 and the television (receiver). ) Ex401 can also be considered.

また、上記携帯電話ex114等の端末は、符号化器・復号化器を両方持つ送受信型の端末の他に、符号化器のみの送信端末、復号化器のみの受信端末の3通りの実装形式が考えられる。   In addition to the transmission / reception type terminal having both the encoder and the decoder, the terminal such as the mobile phone ex114 has three implementation formats: a transmitting terminal having only an encoder and a receiving terminal having only a decoder. Can be considered.

このように、上記実施の形態で示した動画像符号化方法あるいは動画像復号化方法を上述したいずれの機器・システムに用いることは可能であり、そうすることで、上記実施の形態で説明した効果を得ることができる。   As described above, the moving picture encoding method or the moving picture decoding method described in the above embodiment can be used in any of the above-described devices and systems, and as a result, the above-described embodiment has been described. An effect can be obtained.

本発明は、予測画像の生成に用いられる係数および参照ピクチャを指定する参照インデックスとピクチャ番号とを対応付けるコマンドを生成し、符号化対象ピクチャ内のブロックに対して動き補償を行うときに参照すべき参照ピクチャを前記参照インデックスにより指定し、指定された参照ピクチャ上の動き検出により得られたブロックに対して、前記参照インデックスに対応した前記係数を用いた線形予測を施すことにより予測画像を生成する画面間符号化を行う画像符号化装置に適している。また、画像符号化装置により符号化信号を復号化する画像復号化装置に適している。   The present invention generates a command for associating a coefficient used for generating a predicted image and a reference index for specifying a reference picture with a picture number, and should be referred to when performing motion compensation on a block in a picture to be encoded. A reference picture is designated by the reference index, and a prediction image is generated by performing linear prediction using the coefficient corresponding to the reference index on a block obtained by motion detection on the designated reference picture. It is suitable for an image encoding device that performs inter-screen encoding. Further, the present invention is suitable for an image decoding apparatus that decodes an encoded signal by an image encoding apparatus.

本発明の実施の形態1による符号化装置の構成を示すブロック図である。It is a block diagram which shows the structure of the encoding apparatus by Embodiment 1 of this invention. 本発明の実施の形態6による復号化装置の構成を示すブロック図である。It is a block diagram which shows the structure of the decoding apparatus by Embodiment 6 of this invention. 参照インデックスにピクチャ番号を割り振る方法を説明するための模式図である。It is a schematic diagram for demonstrating the method to allocate a picture number to a reference index. 参照インデックスにピクチャ番号の関係の例を示すための模式図である。It is a schematic diagram for showing the example of the relationship of a picture number to a reference index. 動き補償の動作を説明するための模式図である。It is a schematic diagram for demonstrating the operation | movement of motion compensation. 符号列の構成を説明するための模式図である。It is a schematic diagram for demonstrating the structure of a code sequence. 線形予測係数の重み付け係数セットの例を示すための模式図である。It is a schematic diagram for showing the example of the weighting coefficient set of a linear prediction coefficient. 符号化装置における予測画像の生成を示す機能ブロック図である。It is a functional block diagram which shows the production | generation of the prediction image in an encoding apparatus. 符号化装置における予測画像の生成を示す他の機能ブロック図である。It is another functional block diagram which shows the production | generation of the prediction image in an encoding apparatus. (a)(b)はいずれも符号化装置における予測画像の生成を示す更に他の機能ブロック図である。(A) (b) is still another functional block diagram which shows the production | generation of the estimated image in an encoding apparatus. 符号化装置における予測画像の生成を示す更に他の機能ブロック図である。It is another functional block diagram which shows the production | generation of the prediction image in an encoding apparatus. 符号列の構成を説明するための模式図である。It is a schematic diagram for demonstrating the structure of a code sequence. 線形予測係数の重み付け係数セットの例を示すための模式図である。It is a schematic diagram for showing the example of the weighting coefficient set of a linear prediction coefficient. 符号列の構成を説明するための模式図である。It is a schematic diagram for demonstrating the structure of a code sequence. 線形予測係数の重み付け係数セットの例を示すための模式図である。It is a schematic diagram for showing the example of the weighting coefficient set of a linear prediction coefficient. 符号化装置における予測画像の生成を示す機能ブロック図である。It is a functional block diagram which shows the production | generation of the prediction image in an encoding apparatus. 符号列の構成およびフラグの例を説明するための模式図である。It is a schematic diagram for demonstrating the structure of a code sequence, and the example of a flag. 復号化装置における予測画像の生成を示す機能ブロック図である。It is a functional block diagram which shows the production | generation of the prediction image in a decoding apparatus. 復号化装置における予測画像の生成を示す他の機能ブロック図である。It is another functional block diagram which shows the production | generation of the prediction image in a decoding apparatus. (a)(b)はいずれも復号化装置における予測画像の生成を示す更に他の機能ブロック図である。(A) (b) is still another functional block diagram which shows the production | generation of the estimated image in a decoding apparatus. 復号化装置における予測画像の生成を示す更に他の機能ブロック図である。It is another functional block diagram which shows the production | generation of the prediction image in a decoding apparatus. 復号化装置における予測画像の生成を示す更に他の機能ブロック図である。It is another functional block diagram which shows the production | generation of the prediction image in a decoding apparatus. 符号列の構成を説明するための模式図である。It is a schematic diagram for demonstrating the structure of a code sequence. 符号列の構成を説明するための模式図である。It is a schematic diagram for demonstrating the structure of a code sequence. 上記各実施の形態の動画像の符号化方法および復号化方法をコンピュータシステムにより実現するためのプログラムを格納するための記録媒体についての説明図である。It is explanatory drawing about the recording medium for storing the program for implement | achieving the encoding method and decoding method of the moving image of said each embodiment with a computer system. コンテンツ供給システムの全体構成を示すブロック図である。It is a block diagram which shows the whole structure of a content supply system. 携帯電話の外観図である。It is an external view of a mobile phone. 携帯電話の構成を示すブロック図である。It is a block diagram which shows the structure of a mobile telephone. ディジタル放送用システムの例を示す図である。It is a figure which shows the example of the system for digital broadcasting. 従来例のピクチャの参照関係を説明するための模式図である。It is a schematic diagram for demonstrating the reference relationship of the picture of a prior art example. 従来例のピクチャの並び替えを説明するための模式図である。It is a schematic diagram for demonstrating rearrangement of the picture of a prior art example. 従来例の動き補償の動作を説明するための模式図である。It is a schematic diagram for demonstrating the operation | movement of the motion compensation of a prior art example. 従来例の線形予測処理の動作を説明するための模式図である。It is a schematic diagram for demonstrating operation | movement of the linear prediction process of a prior art example. 従来例の参照インデックスにピクチャ番号を割り振る方法を説明するための模式図である。It is a schematic diagram for demonstrating the method to allocate a picture number to the reference index of a prior art example. 従来例の参照インデックスにピクチャ番号の関係の例を示すための模式図である。It is a schematic diagram for showing the example of the relationship of a picture number to the reference index of a prior art example. 従来例の符号列の構成を説明するための模式図である。It is a schematic diagram for demonstrating the structure of the code string of a prior art example. 従来例の線形予測係数の重み付け係数セットの例を示すための模式図である。It is a schematic diagram for showing the example of the weighting coefficient set of the linear prediction coefficient of a prior art example. 従来例の符号列の構成を説明するための模式図である。It is a schematic diagram for demonstrating the structure of the code string of a prior art example. ピクチャ番号と表示順情報との関係を説明するための模式図である。It is a schematic diagram for demonstrating the relationship between a picture number and display order information. 符号列の構成およびフラグの例を説明するための模式図である。It is a schematic diagram for demonstrating the structure of a code sequence, and the example of a flag. 符号列の構成およびフラグの例を説明するための模式図である。It is a schematic diagram for demonstrating the structure of a code sequence, and the example of a flag.

符号の説明Explanation of symbols

101 ピクチャメモリ
102 予測残差符号化部
103 符号列生成部
104 予測残差復号化部
105 ピクチャメモリ
106 動きベクトル検出部
107 動き補償符号化部
108 動きベクトル記憶部
109 線形予測係数記憶部
110 線形予測係数生成部
111 参照インデックス・ピクチャ番号変換部
201 符号列解析部
202 予測残差復号化部
203 ピクチャメモリ
204 動き補償復号部
205 動きベクトル記憶部
206 線形予測係数記憶部
207 参照インデックス・ピクチャ番号変換部
Cs コンピュータシステム
FD フレキシブルディスク
FDD フレキシブルディスクドライブ
DESCRIPTION OF SYMBOLS 101 Picture memory 102 Prediction residual encoding part 103 Code sequence production | generation part 104 Prediction residual decoding part 105 Picture memory 106 Motion vector detection part 107 Motion compensation encoding part 108 Motion vector memory | storage part 109 Linear prediction coefficient memory | storage part 110 Linear prediction Coefficient generation unit 111 Reference index / picture number conversion unit 201 Code stream analysis unit 202 Prediction residual decoding unit 203 Picture memory 204 Motion compensation decoding unit 205 Motion vector storage unit 206 Linear prediction coefficient storage unit 207 Reference index / picture number conversion unit Cs Computer system FD Flexible disk FDD Flexible disk drive

Claims (4)

画像符号化信号を復号化して、
復号化対象ブロックの参照ピクチャを指定する参照インデックス、
複数の参照ピクチャと、該複数の参照ピクチャのそれぞれを指定する参照インデックスとを対応付けるコマンド、
ピクチャの表示順を示す表示順情報、および、
予測誤差
を得る画像符号化信号復号化ステップと、
前記コマンドと前記参照インデックスとにより、復号化対象ブロックを動き補償により復号化するときに参照される参照ピクチャを指定する参照ピクチャ指定ステップと、
前記表示順情報によって重み付け係数を生成する重み付け係数生成ステップと、
前記参照ピクチャ指定ステップで指定された参照ピクチャより得られた参照ブロックの画素値に対して、前記重み付け係数を用いた線形予測を施すことにより前記予測画像を生成する予測画像生成ステップと、
前記予測画像と復号化された前記予測誤差とから復号画像を生成する復元画像生成ステップとを有し、
前記参照インデックスは、第1の参照ピクチャを示す第1の参照インデックスと、第2の参照ピクチャを示す第2の参照インデックスとを有することを特徴とする画像復号化方法。
Decode the image encoded signal,
A reference index specifying the reference picture of the block to be decoded,
A command for associating a plurality of reference pictures with a reference index for designating each of the plurality of reference pictures ;
Display order information indicating the display order of pictures , and
An image encoded signal decoding step to obtain a prediction error;
A reference picture designating step for designating a reference picture to be referred to when decoding the decoding target block by motion compensation based on the command and the reference index;
A weighting factor generating step of generating a weighting factor by the display order information,
A predicted image generating step of generating the predicted image by performing linear prediction using the weighting coefficient on the pixel value of the reference block obtained from the reference picture specified in the reference picture specifying step;
A restored image generation step of generating a decoded image from the predicted image and the decoded prediction error;
The image decoding method, wherein the reference index includes a first reference index indicating a first reference picture and a second reference index indicating a second reference picture.
前記予測画像生成ステップにおいて、前記第1の参照インデックスによって指定される第1の参照ピクチャおよび前記第2の参照インデックスによって指定される前記第2の参照ピクチャが同じ表示順情報をもつ時は、予め設定された重み付け係数を用いて線形予測を行うことにより前記予測画像を生成する、
ことを特徴とする請求項1に記載の画像復号化方法。
In the prediction image generation step, when the first reference picture specified by the first reference index and the second reference picture specified by the second reference index have the same display order information, Generating the predicted image by performing linear prediction using a set weighting coefficient;
The image decoding method according to claim 1, wherein:
前記予め設定された重み付け係数は、同じ値を有することを特徴とする請求項に記載の画像復号化方法。 The image decoding method according to claim 2 , wherein the preset weighting coefficients have the same value. 画像符号化信号を復号化して、
復号化対象ブロックの参照ピクチャを指定する参照インデックス、
複数の参照ピクチャと、該複数の参照ピクチャのそれぞれを指定する参照インデックスとを対応付けるコマンド、
ピクチャの表示順を示す表示順情報、および
予測誤差
を得る画像符号化信号復号化手段と、
前記コマンドと前記参照インデックスとにより、復号化対象ブロックを動き補償により復号化するときに参照される参照ピクチャを指定する参照ピクチャ指定手段と、
前記表示順情報によって重み付け係数を生成する重み付け係数生成手段と、
前記参照ピクチャ指定手段で指定された参照ピクチャより得られた参照ブロックの画素値に対して、前記重み付け係数を用いた線形予測を施すことにより前記予測画像を生成する予測画像生成手段と、
前記予測画像と復号化された前記予測誤差とから復号画像を生成する復元画像生成手段とを有し、
前記参照インデックスは、第1の参照ピクチャを示す第1の参照インデックスと、第2の参照ピクチャを示す第2の参照インデックスとを有し、
前記予測画像生成手段において、前記第1の参照インデックスによって指定される第1
の参照ピクチャおよび前記第2の参照インデックスによって指定される前記第2の参照ピクチャが同じ表示順情報をもつ時は、予め設定された重み付け係数を用いて線形予測を行うことにより前記予測画像を生成することを特徴とする画像復号化装置。
Decode the image encoded signal,
A reference index specifying the reference picture of the block to be decoded,
A command for associating a plurality of reference pictures with a reference index for designating each of the plurality of reference pictures ;
Display order information indicating the display order of pictures , and image coded signal decoding means for obtaining a prediction error;
A reference picture designating unit for designating a reference picture to be referred to when decoding a decoding target block by motion compensation based on the command and the reference index;
A weighting coefficient generating means for generating a weighting factor by the display order information,
Predicted image generation means for generating the predicted image by performing linear prediction using the weighting coefficient for the pixel value of the reference block obtained from the reference picture specified by the reference picture specifying means;
Restored image generating means for generating a decoded image from the predicted image and the decoded prediction error;
The reference index includes a first reference index indicating a first reference picture and a second reference index indicating a second reference picture;
In the predicted image generation means, a first designated by the first reference index
When the reference picture and the second reference picture specified by the second reference index have the same display order information, the prediction picture is generated by performing linear prediction using a preset weighting coefficient An image decoding apparatus characterized by:
JP2006188423A 2002-08-08 2006-07-07 Image decoding method and image decoding apparatus Expired - Lifetime JP4485494B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2006188423A JP4485494B2 (en) 2002-08-08 2006-07-07 Image decoding method and image decoding apparatus

Applications Claiming Priority (7)

Application Number Priority Date Filing Date Title
JP2002232160 2002-08-08
JP2002273992 2002-09-19
JP2002289294 2002-10-01
JP2002296726 2002-10-09
JP2002370722 2002-12-20
JP2003008751 2003-01-16
JP2006188423A JP4485494B2 (en) 2002-08-08 2006-07-07 Image decoding method and image decoding apparatus

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
JP2003272185A Division JP4485157B2 (en) 2002-08-08 2003-07-09 Image decoding method and image decoding apparatus

Publications (2)

Publication Number Publication Date
JP2006325238A JP2006325238A (en) 2006-11-30
JP4485494B2 true JP4485494B2 (en) 2010-06-23

Family

ID=37544498

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2006188423A Expired - Lifetime JP4485494B2 (en) 2002-08-08 2006-07-07 Image decoding method and image decoding apparatus

Country Status (1)

Country Link
JP (1) JP4485494B2 (en)

Also Published As

Publication number Publication date
JP2006325238A (en) 2006-11-30

Similar Documents

Publication Publication Date Title
KR100976017B1 (en) Moving picture encoding method and decoding method
JP4767991B2 (en) Image encoding method and image encoding apparatus
JP2011091846A (en) Image decoding method, image decoding device, and storage medium
JP4485157B2 (en) Image decoding method and image decoding apparatus
JP4485494B2 (en) Image decoding method and image decoding apparatus

Legal Events

Date Code Title Description
A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20091215

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20100212

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20100302

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20100324

R150 Certificate of patent or registration of utility model

Ref document number: 4485494

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130402

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130402

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140402

Year of fee payment: 4

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313113

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313113

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S131 Request for trust registration of transfer of right

Free format text: JAPANESE INTERMEDIATE CODE: R313135

SZ02 Written request for trust registration

Free format text: JAPANESE INTERMEDIATE CODE: R313Z02

S131 Request for trust registration of transfer of right

Free format text: JAPANESE INTERMEDIATE CODE: R313135

SZ02 Written request for trust registration

Free format text: JAPANESE INTERMEDIATE CODE: R313Z02

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S131 Request for trust registration of transfer of right

Free format text: JAPANESE INTERMEDIATE CODE: R313135

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313531

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

EXPY Cancellation because of completion of term