JP5375676B2 - Image processing apparatus, image processing method, and image processing program - Google Patents

Image processing apparatus, image processing method, and image processing program Download PDF

Info

Publication number
JP5375676B2
JP5375676B2 JP2010047763A JP2010047763A JP5375676B2 JP 5375676 B2 JP5375676 B2 JP 5375676B2 JP 2010047763 A JP2010047763 A JP 2010047763A JP 2010047763 A JP2010047763 A JP 2010047763A JP 5375676 B2 JP5375676 B2 JP 5375676B2
Authority
JP
Japan
Prior art keywords
matrix
block
transform
elements
coefficient matrix
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 - Fee Related
Application number
JP2010047763A
Other languages
Japanese (ja)
Other versions
JP2011188007A (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.)
Fujitsu Ltd
Original Assignee
Fujitsu 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 Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP2010047763A priority Critical patent/JP5375676B2/en
Publication of JP2011188007A publication Critical patent/JP2011188007A/en
Application granted granted Critical
Publication of JP5375676B2 publication Critical patent/JP5375676B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Image Analysis (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To reduce an operation amount of two-dimensional orthogonal transformation. <P>SOLUTION: This image processing device calculates difference between a first pixel value matrix (Bc_l) regarding a pixel which does not overlap a first prediction block in a second prediction block and a second pixel value matrix (Bp_l) regarding a pixel which does not overlap the second prediction block in the first prediction block. Then, by using a calculated differential value matrix as a target matrix for orthogonal transformation, the image processing device performs first orthogonal transformation and second orthogonal transformation to the differential value matrix using an orthogonal transformation matrix. The image processing device calculates a second transformation coefficient matrix regarding a second block by complementing conversion coefficient matrixes after the first and second orthogonal transformation, using a first conversion coefficient matrix regarding the first prediction block. <P>COPYRIGHT: (C)2011,JPO&amp;INPIT

Description

本発明は、画像内のブロックに対して二次元直交変換処理をおこなう画像処理装置、画像処理方法、および画像処理プログラムに関する。   The present invention relates to an image processing apparatus, an image processing method, and an image processing program that perform two-dimensional orthogonal transform processing on blocks in an image.

従来より、H.264、MPEG−2等の予測画像を生成する手段としてフレーム間予測を用いる画像処理装置では、フレーム間予測で使用される動きベクトルを算出する処理を備えている(たとえば、下記特許文献1参照。)。動きベクトルとは、原画像内の対象となるブロックが参照画像内のどのブロックから動いたのかを示す動き位置情報である。   Conventionally, H.M. An image processing apparatus that uses inter-frame prediction as a means for generating a predicted image such as H.264 or MPEG-2 includes a process of calculating a motion vector used in inter-frame prediction (see, for example, Patent Document 1 below). ). The motion vector is motion position information indicating from which block in the reference image the target block in the original image has moved.

動きベクトルの算出処理では、原画像内の対象ブロックと、候補となる動きベクトルによって示された参照画像内の予測ブロックとの類似度を判定している。類似度判定のための評価指標として最も広く用いられているのがSAD(Sum Of Absolute Difference、絶対値差分和)である。SADは、当該対象ブロックと予測ブロックの対応する各画素同士の差の絶対値を取り、差の絶対値を合計することで得られる。   In the motion vector calculation process, the similarity between the target block in the original image and the predicted block in the reference image indicated by the candidate motion vector is determined. The most widely used evaluation index for similarity determination is SAD (Sum Of Absolute Difference). The SAD is obtained by taking the absolute value of the difference between corresponding pixels of the target block and the prediction block and summing the absolute values of the differences.

しかしながら、動きベクトルの評価指標としては、SADよりもSATD(Sum Of Absolute Transformed Difference)(たとえば、下記特許文献2参照。)の方が正確である。SATDは、予測ブロックと対象ブロックの画素同士の差分を直交変換し、変換後の各係数の絶対値を合計することで得られる。   However, as a motion vector evaluation index, SATD (Sum Of Absolute Transformed Difference) (for example, refer to Patent Document 2 below) is more accurate than SAD. The SATD is obtained by orthogonally transforming the difference between the pixels of the prediction block and the target block and summing the absolute values of the respective coefficients after the transformation.

SADを使っての評価は差分処理まで符号化処理を進めた結果の評価に相当するのに対して、SATDは直交変換処理まで符号化を進めた結果の評価である。よって、SATDでは、符号化結果であるストリームにより近いところまで符号化処理を進めているので、SADと比較して正確に予測画像の評価をおこなうことができる。   The evaluation using the SAD corresponds to the evaluation of the result of the encoding process up to the difference process, whereas the SATD is the evaluation of the result of the encoding process up to the orthogonal transform process. Therefore, in SATD, since the encoding process is advanced to a position closer to the stream that is the encoding result, it is possible to accurately evaluate the predicted image as compared with SAD.

また、直交変換では、演算量の少ないアダマール変換を用いることが多い。H.264のリファレンスエンコーダ内でもアダマール変換が用いられている。さらに、アダマール変換で用いるアダマール変換行列を変形することでアダマール変換での演算量を削減する処理が知られている(たとえば、下記特許文献3参照。)。   In orthogonal transform, Hadamard transform with a small amount of calculation is often used. H. The Hadamard transform is also used in the H.264 reference encoder. Furthermore, a process for reducing the amount of computation in the Hadamard transform by modifying the Hadamard transform matrix used in the Hadamard transform is known (for example, see Patent Document 3 below).

特開2006−186504号公報JP 2006-186504 A 特開平3−185986号公報JP-A-3-185986 特開2004−241957号公報JP 2004-241957 A

しかしながら、SATDでは、SADよりも多くの計算が必要であり、符号化処理全体の計算処理のうちのSAD/SATDが占める計算処理の割合が非常に大きいため、SADとSATDのうち、どちらを採用するかによって、符号化処理全体の演算量は、大きく異なっていた。   However, since SATD requires more calculations than SAD and the ratio of calculation processing occupied by SAD / SATD is very large in the calculation processing of the entire encoding process, either SAD or SATD is adopted. Depending on whether or not, the calculation amount of the entire encoding process is greatly different.

H.264リファレンスエンコーダでは、整数精度の探索ではSADによるベクトルの評価をおこない、小数精度の探索ではSATDを用いるという手法を用いることにより、SATDを用いながらも演算量を削減していた。しかし、SATDの演算量が大きいという問題点があったため、実際の製品では評価精度が下がっても演算量の少ないSADを採用することが一般的であった。   H. In the H.264 reference encoder, the amount of calculation is reduced while using SATD by using a technique of evaluating vectors by SAD in integer precision search and using SATD in decimal precision search. However, since there is a problem that the amount of calculation of SATD is large, it is common to adopt SAD with a small amount of calculation even if the evaluation accuracy is lowered in an actual product.

本発明は、上述した従来技術による問題点を解消するため、直交変換の対象となる行列の要素数を減らすことで二次元直交変換の演算量を削減できる画像処理装置、画像処理方法、および画像処理プログラムを提供することを目的とする。   In order to solve the above-described problems caused by the prior art, the present invention provides an image processing apparatus, an image processing method, and an image processing apparatus that can reduce the amount of computation of two-dimensional orthogonal transformation by reducing the number of elements of a matrix to be subjected to orthogonal transformation. An object is to provide a processing program.

本発明の一観点によれば、画像内のN×N要素の第1のブロックが任意の探索方向にM(1≦M<N/2)要素シフトしたN×N要素の第2のブロック内で前記第1のブロックに重複していない第1の特徴量行列と、前記第1のブロック内で前記第2のブロックに重複していない第2の特徴量行列との差分となる差分値行列を算出する差分値算出手段と、前記差分値算出手段により算出されたN×M要素の差分値行列をN×N要素の直交変換行列を用いて一次元直交変換してN×M要素の変換係数行列を算出する第1の直交変換手段と、前記第1の直交変換手段により算出されたN×M要素の変換係数行列を、M×N要素の直交変換行列を用いて一次元直交変換してN×N要素の変換係数行列を算出する第2の直交変換手段と、前記第1のブロックに関するN×N要素の第1の変換係数行列と、前記第2の直交変換手段により変換されたN×N要素の変換係数行列とに基づいて前記第2のブロックに関するN×N要素の第2の変換係数行列を算出する係数値算出手段と、を備える画像処理装置が提供される。   According to one aspect of the present invention, an N × N element first block in an image is shifted by M (1 ≦ M <N / 2) elements in an arbitrary search direction. The difference value matrix that is the difference between the first feature quantity matrix that does not overlap the first block and the second feature quantity matrix that does not overlap the second block in the first block. A difference value calculation means for calculating the difference value, and a one-dimensional orthogonal transformation of the difference value matrix of N × M elements calculated by the difference value calculation means using an orthogonal transformation matrix of N × N elements to convert N × M elements A first orthogonal transform unit that calculates a coefficient matrix and a N × M element transform coefficient matrix calculated by the first orthogonal transform unit are subjected to a one-dimensional orthogonal transform using an M × N element orthogonal transform matrix. Second orthogonal transform means for calculating a transform coefficient matrix of N × N elements, and the first block A second N × N element related to the second block based on the first N × N element first transform coefficient matrix and the N × N element transform coefficient matrix transformed by the second orthogonal transform means. There is provided an image processing apparatus comprising: a coefficient value calculating unit that calculates the conversion coefficient matrix of

本画像処理装置、画像処理方法、および画像処理プログラムによれば、直交変換の対象となる行列の要素数を減らすことで二次元直交変換の演算量を削減することができるという効果を奏する。   According to the image processing apparatus, the image processing method, and the image processing program, there is an effect that it is possible to reduce the calculation amount of the two-dimensional orthogonal transformation by reducing the number of elements of the matrix to be subjected to the orthogonal transformation.

本発明の1実施例を示す説明図(その1)である。It is explanatory drawing (the 1) which shows one Example of this invention. 本発明の1実施例を示す説明図(その2)である。It is explanatory drawing (the 2) which shows one Example of this invention. 現ベクトルのx成分が前ベクトルのx成分より1大きい場合を示す説明図である。It is explanatory drawing which shows the case where x component of a current vector is one larger than x component of a previous vector. 現ベクトルのx成分が前ベクトルのx成分より1小さい場合を示す説明図である。It is explanatory drawing which shows the case where the x component of the current vector is 1 smaller than the x component of the previous vector. 現ベクトルのy成分が前ベクトルのy成分より1大きい場合を示す説明図である。It is explanatory drawing which shows the case where y component of the current vector is one larger than y component of the previous vector. 現ベクトルのy成分が前ベクトルのy成分より1小さい場合を示す説明図である。It is explanatory drawing which shows the case where y component of the current vector is 1 smaller than y component of the previous vector. 実施の形態1にかかる画像処理装置の一例を示す説明図である。1 is an explanatory diagram illustrating an example of an image processing apparatus according to a first embodiment; スパイラルサーチによる動きベクトル探索例を示す説明図である。It is explanatory drawing which shows the example of a motion vector search by a spiral search. 実施の形態2においての第2の直交変換回路303の具体的な処理例を示す説明図(その1)である。FIG. 11 is an explanatory diagram (part 1) illustrating a specific processing example of the second orthogonal transform circuit 303 in the second embodiment. 実施の形態2においての第2の直交変換回路303の具体的な処理例を示す説明図(その2)である。FIG. 10 is an explanatory diagram (part 2) of a specific process example of the second orthogonal transform circuit 303 in the second embodiment. 実施の形態2においての第2の直交変換回路303の具体的な処理例を示す説明図(その3)である。FIG. 11 is an explanatory diagram (part 3) illustrating a specific processing example of the second orthogonal transform circuit 303 in the second embodiment. 実施の形態2においての第2の直交変換回路303の具体的な処理例を示す説明図(その4)である。FIG. 12 is an explanatory diagram (part 4) illustrating a specific processing example of the second orthogonal transform circuit 303 in the second embodiment. 入れ替え行列との乗算処理が入れ替え処理および符号変換処理に置き換えられた例を示す説明図(その1)である。It is explanatory drawing (the 1) which shows the example by which the multiplication process with the permutation matrix was replaced by the permutation process and the code conversion process. 入れ替え行列との乗算処理が入れ替え処理および符号変換処理に置き換えられた例を示す説明図(その2)である。It is explanatory drawing (the 2) which shows the example by which the multiplication process with the permutation matrix was replaced by the permutation process and the code conversion process. 入れ替え行列との乗算処理が入れ替え処理および符号変換処理に置き換えられた例を示す説明図(その3)である。It is explanatory drawing (the 3) which shows the example by which the multiplication process with the permutation matrix was replaced by the permutation process and the code conversion process. 入れ替え行列との乗算処理が入れ替え処理および符号変換処理に置き換えられた例を示す説明図(その4)である。It is explanatory drawing (the 4) which shows the example by which the multiplication process with the permutation matrix was replaced by the permutation process and the code conversion process. マクロブロックの一例を示す説明図である。It is explanatory drawing which shows an example of a macroblock. 実施の形態3にかかる画像処理装置の一例を示す説明図である。FIG. 9 is an explanatory diagram illustrating an example of an image processing apparatus according to a third embodiment. ユニット0_1〜ユニット0_7の詳細な説明を示す説明図である。It is explanatory drawing which shows the detailed description of unit 0_1-unit 0_7. ユニット1_1〜ユニット1_4の詳細な説明を示す説明図である。It is explanatory drawing which shows the detailed description of unit 1_1-unit 1_4. ユニット2−3_1〜ユニット2−3_9の詳細な説明を示す説明図である。It is explanatory drawing which shows the detailed description of the unit 2-3_1 to the unit 2-3_9. 実施の形態にかかる画像処理装置のハードウェア構成を示すブロック図である。1 is a block diagram illustrating a hardware configuration of an image processing apparatus according to an embodiment. 実施の形態4にかかる画像処理装置の機能的構成を示すブロック図である。FIG. 10 is a block diagram illustrating a functional configuration of an image processing apparatus according to a fourth embodiment. 係数値算出部1304の詳細な構成を示す説明図(その1)である。FIG. 11 is an explanatory diagram (part 1) illustrating a detailed configuration of a coefficient value calculation unit 1304; 第1の直交変換部1302の詳細な構成を示す説明図である。6 is an explanatory diagram showing a detailed configuration of a first orthogonal transform unit 1302; FIG. 係数値算出部1304の詳細な構成を示す説明図(その2)である。FIG. 10 is an explanatory diagram (part 2) illustrating a detailed configuration of a coefficient value calculation unit 1304; 画像処理装置による画像処理手順の一例を示すフローチャートである。It is a flowchart which shows an example of the image processing procedure by an image processing apparatus. 図15で示した第1の二次元直交変換処理(ステップS1503)の詳細な説明を示すフローチャートである。16 is a flowchart showing a detailed description of the first two-dimensional orthogonal transformation process (step S1503) shown in FIG. 図15で示した第2の二次元直交変換処理(ステップS1504)の詳細な説明を示すフローチャートである。16 is a flowchart showing a detailed description of the second two-dimensional orthogonal transformation process (step S1504) shown in FIG. 図15で示した第2の二次元直交変換処理(ステップS1505)の詳細な説明を示すフローチャートである。16 is a flowchart showing a detailed description of the second two-dimensional orthogonal transformation process (step S1505) shown in FIG.

以下に添付図面を参照して、本発明にかかる画像処理装置、画像処理方法、および画像処理プログラムの好適な実施の形態を詳細に説明する。   Exemplary embodiments of an image processing apparatus, an image processing method, and an image processing program according to the present invention are explained in detail below with reference to the accompanying drawings.

図1−1,1−2は、本発明の1実施例を示す説明図である。まず、図1−1には、参照画像内で前ベクトルによって示される第1の予測ブロックと、第1の予測ブロックが探索方向に1シフトした現ベクトルによって示される第2の予測ブロックとが示されている。ここでは、N×N要素のブロックとは、N×N画素のブロックを示し、図1−1,1−2においては、4×4画素を1ブロックとして扱っている。画素に関する特徴量とは、画素値である。   FIGS. 1-1 and 1-2 are explanatory views showing an embodiment of the present invention. First, FIG. 1-1 shows a first prediction block indicated by a previous vector in a reference image and a second prediction block indicated by a current vector obtained by shifting the first prediction block by 1 in the search direction. Has been. Here, the block of N × N elements indicates a block of N × N pixels, and in FIGS. 1-1 and 1-2, 4 × 4 pixels are handled as one block. The feature amount related to the pixel is a pixel value.

まず、画像処理装置が、第2の予測ブロック内で第1の予測ブロックに重複していない第1の画素値行列(Bc_l)と、第1の予測ブロック内で第2の予測ブロックに重複していない第2の画素値行列(Bp_l)との差分となる差分値行列を算出する。   First, the image processing apparatus overlaps a first pixel value matrix (Bc_l) that does not overlap with the first prediction block in the second prediction block and a second prediction block in the first prediction block. A difference value matrix that is a difference from the second pixel value matrix (Bp_l) not calculated is calculated.

つぎに、画像処理装置が、4×4要素の直交変換行列を用いて4×1要素の差分値行列を一次元直交変換して4×1要素の変換係数行列を算出する。直交変換に関しては、既存の技術を用いればよく、直交変換行列は、直交変換によって決定される。   Next, the image processing apparatus calculates a 4 × 1 element transform coefficient matrix by performing one-dimensional orthogonal transform on the 4 × 1 element difference value matrix using the 4 × 4 element orthogonal transform matrix. Regarding the orthogonal transformation, an existing technique may be used, and the orthogonal transformation matrix is determined by the orthogonal transformation.

そして、画像処理装置が、4×1要素の変換係数行列を、1×4要素の直交変換行列を用いて一次元直交変換して、4×4要素の変換係数行列を算出する。   Then, the image processing apparatus calculates a 4 × 4 element conversion coefficient matrix by performing one-dimensional orthogonal transformation on the 4 × 1 element conversion coefficient matrix using the 1 × 4 element orthogonal conversion matrix.

つぎに、図1−2に移って、画像処理装置が、第1の予測ブロックに関する4×4要素の第1の変換係数行列(Rp)と、算出された4×4要素の変換係数行列とに基づいて第2の予測ブロックに関する4×4の第2の変換係数行列を算出する。具体的には、たとえば、画像処理装置が、第1の変換係数行列と算出された4×4要素の変換係数行列とを加算し、行ベクトルを入れ替えるための入れ替え行列と乗算する。これにより、4×4の第2の変換係数行列が算出される。   Next, moving to FIG. 1-2, the image processing apparatus includes a 4 × 4 element first transform coefficient matrix (Rp) related to the first prediction block, a calculated 4 × 4 element transform coefficient matrix, and Based on the above, a 4 × 4 second transform coefficient matrix for the second prediction block is calculated. Specifically, for example, the image processing apparatus adds the first conversion coefficient matrix and the calculated 4 × 4 element conversion coefficient matrix, and multiplies the replacement matrix for replacing row vectors. As a result, a 4 × 4 second transform coefficient matrix is calculated.

第2の予測ブロックが第1の予測ブロックに対して横方向に1シフトしたブロックの場合、第1の特徴行列と第2の特徴行列とは、N行1列の行列である。そして、一次元直交変換では、N行N列の直交変換行列と1行N列の直交変換行列を用いておこなわれる。また、横方向にM(1≦M<N/2)シフトした場合、第1の特徴行列と第2の特徴行列とは、N行M列の行列である。そして、一次元直交変換では、N行N列の直交変換行列とM行N列の直交変換行列を用いておこなわれる。   When the second prediction block is a block that is shifted by 1 in the horizontal direction with respect to the first prediction block, the first feature matrix and the second feature matrix are N rows and one column. The one-dimensional orthogonal transformation is performed using an N-row N-column orthogonal transformation matrix and a 1-row N-column orthogonal transformation matrix. Further, when shifting in the horizontal direction by M (1 ≦ M <N / 2), the first feature matrix and the second feature matrix are N rows and M columns. The one-dimensional orthogonal transformation is performed using an N-row N-column orthogonal transformation matrix and an M-row N-column orthogonal transformation matrix.

一方、第2の予測ブロックが第1の予測ブロックに対して縦方向に1シフトしたブロックの場合、第1の特徴行列と第2の特徴行列とは、1行N列の行列である。一次元直交変換では、N行N列の直交変換行列とN行1列の直交変換行列を用いておこなわれる。また、縦方向にM(1≦M<N/2)シフトした場合、第1の特徴行列と第2の特徴行列とは、M行N列の行列である。そして、一次元直交変換では、N行N列の直交変換行列とN行M列の直交変換行列を用いておこなわれる。   On the other hand, when the second prediction block is a block shifted by 1 in the vertical direction with respect to the first prediction block, the first feature matrix and the second feature matrix are 1-row N-column matrices. One-dimensional orthogonal transformation is performed using an N-row N-column orthogonal transformation matrix and an N-row 1-column orthogonal transformation matrix. When the vertical shift is performed by M (1 ≦ M <N / 2), the first feature matrix and the second feature matrix are M rows and N columns. The one-dimensional orthogonal transformation is performed using an N-row N-column orthogonal transformation matrix and an N-row M-column orthogonal transformation matrix.

本発明の詳細な説明については、実施の形態1から4を用いて説明する。まず、実施の形態1では、現ベクトルにより示されるN×N画素の第2の予測ブロックが、前ベクトルにより示されるN×N画素の第1の予測ブロックを用いて二次元直交変換される例を説明する。   Detailed description of the present invention will be described using Embodiments 1 to 4. First, in the first embodiment, an example in which the second prediction block of N × N pixels indicated by the current vector is two-dimensionally orthogonally transformed using the first prediction block of N × N pixels indicated by the previous vector. Will be explained.

つぎに、実施の形態2では、現ベクトルにより示されるN×N画素の第2の予測ブロックが、前ベクトルにより示されるN×N画素の第1の予測ブロックを用いて二次元アダマール変換される例を説明する。   Next, in the second embodiment, the N × N pixel second prediction block indicated by the current vector is subjected to two-dimensional Hadamard transform using the N × N pixel first prediction block indicated by the previous vector. An example will be described.

そして、実施の形態3では、N=4の場合において、現ベクトルにより示されるN×N画素の第2の予測ブロックに関するSATDを算出する例を説明する。   In the third embodiment, an example in which the SATD for the second prediction block of N × N pixels indicated by the current vector is calculated when N = 4 will be described.

最後に、実施の形態4では、実施の形態1で示した画像処理装置による処理がコンピュータによって処理される例を説明する。   Finally, in the fourth embodiment, an example in which the processing by the image processing apparatus shown in the first embodiment is processed by a computer will be described.

(実施の形態1)
まず、図2−1〜図2−4を用いて前ベクトルが示す第1の予測ブロックと現ベクトルが示す第2の予測ブロックとについて説明する。
(Embodiment 1)
First, the first prediction block indicated by the previous vector and the second prediction block indicated by the current vector will be described with reference to FIGS.

図2−1は、現ベクトルのx成分が前ベクトルのx成分より1大きい場合を示す説明図である。原画像内の対象ブロックから参照画像内の第1の予測ブロックへの矢印が、前ベクトルである。原画像内の対象ブロックから参照画像内の第2の予測ブロックへの矢印が、現ベクトルである。現ベクトルのx成分が前ベクトルのx成分より1大きい。したがって、第2の予測ブロックは、第1の予測ブロックから横方向に+1シフトしたブロックである。   FIG. 2A is an explanatory diagram illustrating a case where the x component of the current vector is one greater than the x component of the previous vector. The arrow from the target block in the original image to the first prediction block in the reference image is the previous vector. The arrow from the target block in the original image to the second prediction block in the reference image is the current vector. The x component of the current vector is one greater than the x component of the previous vector. Therefore, the second prediction block is a block shifted by +1 in the horizontal direction from the first prediction block.

なお、本実施の形態1では、1ブロックが、4画素×4画素である。ベクトルのxは、横方向の画素であり、yは縦方向の画素である。ベクトル(0、0)とは、原画像内の対象ブロックと同一位置にある参照画像内の予測ブロックを示すベクトルである。   In the first embodiment, one block is 4 pixels × 4 pixels. The vector x is a pixel in the horizontal direction, and y is a pixel in the vertical direction. The vector (0, 0) is a vector indicating a prediction block in the reference image at the same position as the target block in the original image.

そして、Bc_lは、第2の予測ブロック内で第1の予測ブロックに重複していない画素の列ベクトルである。一方、Bp_lは、第1の予測ブロック内で第2の予測ブロックに重複していない画素の列ベクトルである。   Bc_l is a column vector of pixels that do not overlap the first prediction block in the second prediction block. On the other hand, Bp_l is a column vector of pixels that do not overlap with the second prediction block in the first prediction block.

本実施の形態1では、第2の予測ブロックが二次元直交変換された第2の変換係数行列(Rc)を、第1の予測ブロックが二次元直交変換された第1の変換係数行列(Rp)を用いて算出する。現ベクトルのx成分が前ベクトルのx成分より1大きい場合は、下記式(1)を用いてRcを算出する。   In the first embodiment, the second prediction coefficient matrix (Rc) obtained by two-dimensional orthogonal transformation of the second prediction block is used as the first transformation coefficient matrix (Rp) obtained by two-dimensional orthogonal transformation of the first prediction block. ) To calculate. If the x component of the current vector is one greater than the x component of the previous vector, Rc is calculated using the following equation (1).

Rc=[Rp+{T1・(Bc_l−Bp_l)}・T2_u]・(iT2・Sr・T2) ・・・(1)   Rc = [Rp + {T1. (Bc_1-Bp_1)}. T2_u]. (IT2.Sr.T2) (1)

T1、T2、T2_u、Srについては、後述する。   T1, T2, T2_u, and Sr will be described later.

図2−2は、現ベクトルのx成分が前ベクトルのx成分より1小さい場合を示す説明図である。原画像内の対象ブロックから参照画像内の第1の予測ブロックへの矢印が、前ベクトルである。原画像内の対象ブロックから参照画像内の第2の予測ブロックへの矢印が、現ベクトルである。現ベクトルのx成分が前ベクトルのx成分より1小さい。したがって、第2の予測ブロックは、第1の予測ブロックから横方向に−1シフトしたブロックである。なお、本実施の形態1では、1ブロックが、4画素×4画素である。   FIG. 2B is an explanatory diagram of a case where the x component of the current vector is one smaller than the x component of the previous vector. The arrow from the target block in the original image to the first prediction block in the reference image is the previous vector. The arrow from the target block in the original image to the second prediction block in the reference image is the current vector. The x component of the current vector is one less than the x component of the previous vector. Therefore, the second prediction block is a block shifted by −1 in the horizontal direction from the first prediction block. In the first embodiment, one block is 4 pixels × 4 pixels.

そして、Bc_lは、第2の予測ブロック内で第1の予測ブロックに重複していない画素の列ベクトルである。一方、Bp_lは、第1の予測ブロック内で第2の予測ブロックに重複していない画素の列ベクトルである。   Bc_l is a column vector of pixels that do not overlap the first prediction block in the second prediction block. On the other hand, Bp_l is a column vector of pixels that do not overlap with the second prediction block in the first prediction block.

第1の予測ブロックが二次元直交変換された第1の変換係数行列(Rp)を用いて第2の予測ブロックに関する第2の変換係数行列(Rc)が算出される。現ベクトルのx成分が前ベクトルのx成分より1小さい場合は、下記式(2)を用いてRcを算出する。   A second transform coefficient matrix (Rc) relating to the second predicted block is calculated using the first transform coefficient matrix (Rp) obtained by two-dimensionally orthogonally transforming the first predicted block. When the x component of the current vector is one smaller than the x component of the previous vector, Rc is calculated using the following equation (2).

Rc=[Rp+{T1・(Bc_l−Bp_l)}・T2_d]・(iT2・Sl・T2) ・・・(2)   Rc = [Rp + {T1. (Bc_1-Bp_1)}. T2_d]. (IT2.S1.T2) (2)

T2_d、Slについては、後述する。   T2_d and Sl will be described later.

図2−3は、現ベクトルのy成分が前ベクトルのy成分より1大きい場合を示す説明図である。原画像内の対象ブロックから参照画像内の第1の予測ブロックへの矢印が、前ベクトルである。原画像内の対象ブロックから参照画像内の第2の予測ブロックへの矢印が、現ベクトルである。現ベクトルのy成分が前ベクトルのy成分より1大きい。したがって、第2の予測ブロックは、第1の予測ブロックから縦方向に+1シフトしたブロックである。   FIG. 2-3 is an explanatory diagram illustrating a case where the y component of the current vector is one greater than the y component of the previous vector. The arrow from the target block in the original image to the first prediction block in the reference image is the previous vector. The arrow from the target block in the original image to the second prediction block in the reference image is the current vector. The y component of the current vector is one greater than the y component of the previous vector. Therefore, the second prediction block is a block shifted by +1 in the vertical direction from the first prediction block.

そして、Bc_rは、第2の予測ブロック内で第1の予測ブロックに重複していない画素の列ベクトルである。一方、Bp_rは、第1の予測ブロック内で第2の予測ブロックに重複していない画素の列ベクトルである。   Bc_r is a column vector of pixels that do not overlap the first prediction block in the second prediction block. On the other hand, Bp_r is a column vector of pixels that do not overlap with the second prediction block in the first prediction block.

現ベクトルのy成分が前ベクトルのy成分より1大きい場合は下記式(3)によりRcが算出される。   When the y component of the current vector is one greater than the y component of the previous vector, Rc is calculated by the following equation (3).

Rc=(T1・Sd・iT1)・[Rp+T1_l・{(Bc_r−Bp_r)・T2}] ・・・(3)   Rc = (T1 · Sd · iT1) · [Rp + T1 — l · {(Bc_r−Bp_r) · T2}] (3)

T1_l、Sdについては、後述する。   T1_l and Sd will be described later.

図2−4は、現ベクトルのy成分が前ベクトルのy成分より1小さい場合を示す説明図である。原画像内の対象ブロックから参照画像内の第1の予測ブロックへの矢印が、前ベクトルである。原画像内の対象ブロックから参照画像内の第2の予測ブロックへの矢印が、現ベクトルである。現ベクトルのy成分が前ベクトルのy成分より1小さい。したがって、第2の予測ブロックは、第1の予測ブロックから縦方向に−1シフトしたブロックである。   FIG. 2-4 is an explanatory diagram illustrating a case where the y component of the current vector is one smaller than the y component of the previous vector. The arrow from the target block in the original image to the first prediction block in the reference image is the previous vector. The arrow from the target block in the original image to the second prediction block in the reference image is the current vector. The y component of the current vector is one less than the y component of the previous vector. Therefore, the second prediction block is a block shifted by −1 in the vertical direction from the first prediction block.

そして、Bc_rは、第2の予測ブロック内で第1の予測ブロックに重複していない画素の列ベクトルである。一方、Bp_rは、第1の予測ブロック内で第2の予測ブロックに重複していない画素の列ベクトルである。   Bc_r is a column vector of pixels that do not overlap the first prediction block in the second prediction block. On the other hand, Bp_r is a column vector of pixels that do not overlap with the second prediction block in the first prediction block.

現ベクトルのy成分が前ベクトルのy成分より1小さい場合は下記式(4)によりRcが算出される。   When the y component of the current vector is one smaller than the y component of the previous vector, Rc is calculated by the following equation (4).

Rc=(T1・Su・iT1)・[Rp+T1_r・{(Bc_r−Bp_r)・T2}] ・・・(4)   Rc = (T1 · Su · iT1) · [Rp + T1_r · {(Bc_r−Bp_r) · T2}] (4)

T1_r、Suについては、後述する。   T1_r and Su will be described later.

以下に、上記式(1)〜(4)で示される各行列について示す。
・T1:一次元直交変換行列
・T2:一次元直交変換行列
・iT1:T1の逆行列
・iT2:T2の逆行列
・Sr:右からかけると、最右列を最左列に、残りの列を1つ右に移す行列
・Sl:右からかけると、最左列を最右列に、残りの列を1つ左に移す行列
・Sd:左からかけると、最下行を最上行に、残りの行を1つ下に移す行列
・Su:左からかけると、最上行を最下行に、残りの行を1つ上に移す行列
・Bc_l:現ベクトルで示される予測ブロック内で前ベクトルで示される予測ブロックに重複していないN×1画素の画素値行列(第1の画素値行列)、列ベクトル
・Bp_l:前ベクトルで示される予測ブロック内で現ベクトルで示される予測ブロックに重複していないN×1画素の画素値行列(第2の画素値行列)、列ベクトル
・Bc_r:現ベクトルで示される予測ブロック内で前ベクトルで示される予測ブロックに重複していない1×N画素の画素値行列(第1の画素値行列)、行ベクトル
・Bp_r:前ベクトルで示される予測ブロック内で現ベクトルで示される予測ブロックに重複していない1×N画素の画素値行列(第2の画素値行列)、行ベクトル
・T2_u:T2の最上行を要素に持つ行ベクトル
・T2_d:T2の最下行を要素に持つ行ベクトル
・T1_l:T1の最左列を要素に持つ列ベクトル
・T1_r:T1の最右列を要素に持つ列ベクトル
・Rp:第1の予測ブロックに関する第1の変換係数行列
・Rc:第2の予測ブロックに関する第2の変換係数行列
Below, it shows about each matrix shown by said Formula (1)-(4).
T1: One-dimensional orthogonal transformation matrix T2: One-dimensional orthogonal transformation matrix iT1: Inverse matrix of T1 iT2: Inverse matrix of T2 Sr: When applied from the right, the rightmost column becomes the leftmost column and the remaining columns A matrix that moves one to the right ・ Sl: If applied from the right, the leftmost column is moved to the rightmost column, and the remaining column is moved one to the left A matrix that moves the next row down by one. Su: When applied from the left, the top row is the bottom row, and the remaining rows are moved up by one. Bc_l: indicated by the previous vector in the prediction block indicated by the current vector N × 1 pixel value matrix (first pixel value matrix) that does not overlap with the predicted block to be displayed, column vector Bp — l: overlaps with the prediction block indicated by the current vector in the prediction block indicated by the previous vector No N × 1 pixel value matrix (second pixel value matrix), column Kutor ・ Bc_r: 1 × N pixel value matrix (first pixel value matrix) that does not overlap the prediction block indicated by the previous vector in the prediction block indicated by the current vector, row vector ・ Bp_r: the previous vector A pixel value matrix (second pixel value matrix) of 1 × N pixels that does not overlap the prediction block indicated by the current vector in the indicated prediction block, a row vector T2_u: a row vector having the top row of T2 as an element T2_d: a row vector having the bottom row of T2 as an element T1_1: a column vector having the leftmost column of T1 as an element T1_r: a column vector having the rightmost column of T1 as an element Rp: relating to the first prediction block First transform coefficient matrix Rc: second transform coefficient matrix for the second prediction block

上記式(1)の(iT2・Sr・T2)と、上記式(2)の(iT2・Sl・T2)と、上記式(3)の(T1・Sd・iT1)と、上記式(4)の(T1・Su・iT1)とは、行列の入れ替えに関する入れ替え行列である。   (IT2 · Sr · T2) of the above formula (1), (iT2 · Sl · T2) of the above formula (2), (T1 · Sd · iT1) of the above formula (3), and the above formula (4) (T1 · Su · iT1) is a replacement matrix related to matrix replacement.

ここで、上記式(1)の導出過程について説明する。また、T1、Pc、T2は、N行N列の行列であり、T1、T2は正則行列である。現ベクトルによって示される予測画像をPc、前ベクトルによって示される予測画像をPpとする。下記式(5)では、Pcを直交変換してRcを算出する例である。   Here, the derivation process of the formula (1) will be described. T1, Pc, and T2 are N rows and N columns, and T1 and T2 are regular matrices. Let Pc be the predicted image indicated by the current vector, and Pp be the predicted image indicated by the previous vector. The following formula (5) is an example in which Rc is calculated by orthogonal transformation of Pc.

Rc=T1・Pc・T2 ・・・(5)   Rc = T1, Pc, T2 (5)

たとえば、下記式(6)とする。   For example, it is set as the following formula (6).

Pm=Pc・Sr ・・・(6)   Pm = Pc · Sr (6)

よって、上記式(6)から下記式(7)を得ることができる。   Therefore, the following formula (7) can be obtained from the above formula (6).

Pc=Pm・iSr ・・・(7)   Pc = Pm · iSr (7)

そして、上記式(7)を上記式(5)に代入することで下記式(8)を得ることができる。   Then, the following formula (8) can be obtained by substituting the above formula (7) into the above formula (5).

Rc=T1・Pm・iSr・T2 ・・・(8)   Rc = T1, Pm, iSr, T2 (8)

Ppの左上の座標を(0,0)とした場合、第1の予測ブロック内の画素を(0,0)からの相対座標を用いてp(x,y)と表した場合、PmとPpの成分は、それぞれ以下のようになる。   When the upper left coordinate of Pp is (0, 0), the pixel in the first prediction block is expressed as p (x, y) using the relative coordinate from (0, 0), and Pm and Pp The components are as follows.

Figure 0005375676
Figure 0005375676

PmとPpの関係を下記式(9)とする。   The relationship between Pm and Pp is represented by the following formula (9).

Pm=Pp+Z ・・・(9)   Pm = Pp + Z (9)

Zは、第1列が(Bc_l−Bp_l)に等しく、残りの列はすべての成分が0の行列である。したがって、下記式(10)を得ることができる。   Z is a matrix in which the first column is equal to (Bc_l-Bp_l) and the remaining columns are all 0 components. Therefore, the following formula (10) can be obtained.

Rc=T1・(Pp+Z)・iSr・T2
=T1・(Pp+Z)・I・iSr・T2
=T1・(Pp+Z)・T2・iT2・iSr・T2
=(T1・(Pp+Z)・T2)・(iT2・iSr・T2)
=(T1・Pp・T2+T1・Z・T2)・(iT2・iSr・T2)
・・・(10)
Rc = T1. (Pp + Z) .iSr.T2
= T1 ・ (Pp + Z) ・ I ・ iSr ・ T2
= T1 ・ (Pp + Z) ・ T2 ・ iT2 ・ iSr ・ T2
= (T1 · (Pp + Z) · T2) · (iT2 · iSr · T2)
= (T1 · Pp · T2 + T1 · Z · T2) · (iT2 · iSr · T2)
(10)

なお、IはN×N要素の単位行列である。Rpは、T1・Pp・T2であるため、Rcを下記式(11)にすることができる。   Note that I is a unit matrix of N × N elements. Since Rp is T1, Pp, and T2, Rc can be expressed by the following formula (11).

Rc=(Rp+T1・Z・T2)・(iT2・iSr・T2) ・・・(11)   Rc = (Rp + T1 · Z · T2) · (iT2 · iSr · T2) (11)

Figure 0005375676
Figure 0005375676

上記式(1)のZ・T2は、上記式(12)である。また、T22、・・・、T2nはそれぞれT2の2行目、・・・、n行目、0は、n行n―1列の零行列である。よって、下記式(13)となり、上記式(1)が得られる。   Z · T2 in the above formula (1) is the above formula (12). In addition, T22,..., T2n are the second matrix of T2,..., Nth row, and 0 are n matrixes of n rows and n−1 columns, respectively. Therefore, the following formula (13) is obtained, and the above formula (1) is obtained.

Rc={Rp+T1・(Bc_l−Bp_l)・T2_u}・(iT2・iSr・T2) ・・・(13)   Rc = {Rp + T1. (Bc_1-Bp_1) .T2_u}. (IT2.iSr.T2) (13)

ここで、従来での演算量を説明する。従来では、上記式(5)のようにN×N要素の行列同士の演算を2回おこなう。N×N要素の行列同士の乗算では、従来の画像処理装置は、乗算結果の各要素を求めるのに乗算N回、加算をN−1回おこなう。したがって、N×N要素の行列同士の乗算回数は、乗算がN^3回(「^」は乗数を示し、N^3はNの3乗である。)、加算が(N−1)・N^2回である。変換結果を算出するには、N×N要素の行列同士の乗算を2回おこなうので、一のブロックの直交変換では、乗算を2N^3回、加算を(N−1)・2N^2回実施する。なお、「^2」は、2乗であることを示す。   Here, a conventional calculation amount will be described. Conventionally, the calculation of the matrix of N × N elements is performed twice as in the above equation (5). In multiplication of matrices of N × N elements, a conventional image processing apparatus performs multiplication N times and addition N−1 times to obtain each element of the multiplication result. Therefore, the number of multiplications between N × N matrixes is N ^ 3 times ("^" indicates a multiplier, N ^ 3 is the third power of N), and addition is (N-1). N ^ 2 times. In order to calculate the conversion result, the matrix of N × N elements is multiplied twice, so in the orthogonal transformation of one block, multiplication is performed 2N ^ 3 times and addition is performed (N-1) · 2N ^ 2 times. carry out. “^ 2” indicates a square.

つぎに、本発明での演算量を、上記式(1)を例に挙げて説明する。
・Bc_l−Bp_l:減算N回
・T1と(Bc_l−Bp_l)の乗算:「乗算N回、加算N−1回」をN回、すなわち乗算N^2回、加算N(N−1)回
・(T1・(Bc_l−Bp_l))とT2_uの乗算:乗算N^2回
・Rpと{T1・(Bc_l−Bp_l)・T2_u}との加算:加算N^2回
・[Rp+{T1・(Bc_l−Bp_l)・T2_u}]と(iT2・Sr・T2)の乗算:乗算N^3回、加算を(N−1)・N^2回
Next, the calculation amount in the present invention will be described by taking the above equation (1) as an example.
Bc_l-Bp_l: N times of subtraction. Multiplication of T1 and (Bc_l-Bp_l): N times "multiplication N times, N-1 times addition", that is, N ^ 2 times multiplication and N (N-1) times addition. Multiplication of (T1 · (Bc_l−Bp_l)) and T2_u: multiplication N ^ 2 times Rp and {T1 · (Bc_l−Bp_l) · T2_u} addition: addition N ^ 2 times [Rp + {T1 · (Bc_l -Bp_l) · T2_u}] and (iT2 · Sr · T2): Multiplication N ^ 3 times, addition (N-1) · N ^ 2 times

したがって、乗算が2N^2回+N^3回、加減算がN回+N・(N−1)回+N^2回+(N−1)・N^2回となり、従来と比較して高速化することができる。   Therefore, multiplication is 2N ^ 2 times + N ^ 3 times, and addition / subtraction is N times + N · (N−1) times + N ^ 2 times + (N−1) · N ^ 2 times, which is faster than the conventional method. be able to.

上記式(1)の(iT2・Sr・T2)と、上記式(2)の(iT2・Sl・T2)と、上記式(3)の(T1・Sd・iT1)と、上記式(4)の(T1・Su・iT1)とについては、直交変換行列(T1、T2)が決定された時点で決定される。したがって、実際には、N×N要素の行列である。   (IT2 · Sr · T2) of the above formula (1), (iT2 · Sl · T2) of the above formula (2), (T1 · Sd · iT1) of the above formula (3), and the above formula (4) (T1 · Su · iT1) is determined when the orthogonal transformation matrix (T1, T2) is determined. Therefore, it is actually a matrix of N × N elements.

なお、図示では、4×4のブロックであるが、N×Nのブロック(N>=4)であればよく、上記式(1)〜(4)においての直交変換についても特に規定しない。   In the figure, although it is a 4 × 4 block, it may be an N × N block (N> = 4), and the orthogonal transform in the above formulas (1) to (4) is not particularly defined.

図3は、実施の形態1にかかる画像処理装置の一例を示す説明図である。画像処理装置300は、差分値算出回路301と、第1の直交変換回路302と、第2の直交変換回路303と、係数値算出回路304を備えている。ここでは、上記式(1)を例に挙げて説明する。   FIG. 3 is an explanatory diagram of an example of the image processing apparatus according to the first embodiment. The image processing apparatus 300 includes a difference value calculation circuit 301, a first orthogonal transformation circuit 302, a second orthogonal transformation circuit 303, and a coefficient value calculation circuit 304. Here, the above formula (1) will be described as an example.

差分値算出回路301は、上記式(1)の(Bc_l−Bp_l)の処理をおこない、具体的には、減算回路である。   The difference value calculation circuit 301 performs the process of (Bc_l−Bp_l) in the above equation (1), and is specifically a subtraction circuit.

つぎに、第1の直交変換回路302は、上記式(1)のT2と差分値行列との乗算処理をおこない、具体的には、たとえば、乗算回路と加算回路により構成される。   Next, the first orthogonal transform circuit 302 performs a multiplication process of T2 of the above formula (1) and the difference value matrix, and specifically includes, for example, a multiplication circuit and an addition circuit.

つぎに、第2の直交変換回路303は、上記式(1)のT2_uとの乗算処理をおこない、具体的には、たとえば、乗算回路と加算回路により構成される。   Next, the second orthogonal transformation circuit 303 performs a multiplication process with T2_u in the above equation (1), and specifically includes, for example, a multiplication circuit and an addition circuit.

そして、係数値算出回路304は、上記式(1)のRpとの加算および(iT2・Sr・T2)との乗算であり、具体的には、乗算回路と加算回路である。   The coefficient value calculation circuit 304 is addition with Rp in the above equation (1) and multiplication with (iT2 · Sr · T2), and specifically, a multiplication circuit and an addition circuit.

図示していないが、探索方法については、従来から知られている動きベクトル探索(たとえば、全探索)の処理を用いればよく特に限定しない。なお、画像処理装置300は、少なくとも探索開始点である1つの動きベクトル候補については、上記式(5)の処理を実行する。   Although not shown, the search method is not particularly limited as long as a conventionally known motion vector search (for example, full search) process is used. Note that the image processing apparatus 300 executes the processing of the above formula (5) for at least one motion vector candidate that is a search start point.

また、上述の例では、第2の予測ブロックは、第1の予測ブロックが探索方向に1画素シフトしたブロックであるが、M(1≦M<N/2)画素シフトした場合にも高速化をおこなうことができる。   In the above example, the second prediction block is a block in which the first prediction block is shifted by one pixel in the search direction, but the speed is increased even when M (1 ≦ M <N / 2) pixels are shifted. Can be done.

まず、上記式(1)の(Bc_l−Bp_l)については、Bc_lおよびBp_lがN行×M列である。そして、T2_uは、M行N列である。また、(iT2・Sr・T2)については、たとえば、2画素シフトされた場合、(iT2・Sr・Sr・T2)とるが、T1、T2が決定された時点で(iT2・Sr・Sr・T2)の結果も決定しているのでN行N列である。したがって、演算量は、下記のようになります。   First, for (Bc_l−Bp_l) in the above formula (1), Bc_l and Bp_l are N rows × M columns. T2_u is M rows and N columns. For (iT2 · Sr · T2), for example, when (iT2 · Sr · Sr · T2) is shifted by 2 pixels, it is (iT2 · Sr · Sr · T2) when T1 and T2 are determined. ) Is also determined, so N rows and N columns. Therefore, the calculation amount is as follows.

・Bc_l−Bp_l:減算N×M回
・T1と(Bc_l−Bp_l)の乗算:乗算N^2回、加算N(N−1)回
・(T1・(Bc_l−Bp_l))とT2_uの乗算:乗算N^2回
・Rpと{T1・(Bc_l−Bp_l)・T2_u}との加算:加算N^2回
・[Rp+{T1・(Bc_l−Bp_l)・T2_u}]と(iT2・Sr・T2)の乗算:乗算N^3回、加算を(N−1)・N^2回
Bc_l-Bp_l: Subtraction N × M times Multiplication of T1 and (Bc_l−Bp_l): Multiplication N ^ 2 times, addition N (N−1) times Multiplication of (T1 · (Bc_l−Bp_l)) and T2_u: Multiplication N ^ 2 · Rp and {T1 · (Bc_l-Bp_l) · T2_u} addition: addition N ^ 2 times · [Rp + {T1 · (Bc_l-Bp_l) · T2_u}] and (iT2 · Sr · T2 ) Multiplication: multiplication N ^ 3 times, addition (N-1) · N ^ 2 times

乗算がM×N^2回+M×N^2回+N^3回であり、加減算がN×M回+M×N(N−1)+(M−1)×N^2回+N^2回+(N−1)×N^2回である。   Multiplication is M * N ^ 2 times + M * N ^ 2 times + N ^ 3 times, and addition / subtraction is N * M times + M * N (N-1) + (M-1) * N ^ 2 times + N ^ 2 times. + (N−1) × N ^ 2 times.

よって、N=8の場合、1画素〜3画素シフトした場合に高速化することができる。従来では、N=8の場合、乗算が1024回で、加算が896回である。実施の形態1においては、N=8で第2の予測ブロックが第1の予測ブロックから横方向に1画素シフトした場合、乗算が640回で、加算が512回である。第2の予測ブロックが第1の予測ブロックから横方向に2画素シフトした場合、乗算が768回で、加算が640回である。第2の予測ブロックが第1の予測ブロックから横方向に3画素シフトした場合、乗算が896回で、加算が768回である。   Therefore, in the case of N = 8, it is possible to increase the speed when shifting by 1 to 3 pixels. Conventionally, when N = 8, multiplication is 1024 times and addition is 896 times. In the first embodiment, when N = 8 and the second prediction block is shifted by one pixel in the horizontal direction from the first prediction block, the multiplication is 640 times and the addition is 512 times. When the second prediction block is shifted by two pixels in the horizontal direction from the first prediction block, the multiplication is 768 times and the addition is 640 times. When the second prediction block is shifted by 3 pixels in the horizontal direction from the first prediction block, the multiplication is 896 times and the addition is 768 times.

また、少なくとも1個のベクトルについては、必ず従来と同様の二次元直交変換を施さなければならない。従来と同様の二次元直交変換をおこなうベクトルの個数については、動きベクトル探索の探索方法によって異なる。   Also, at least one vector must be subjected to the same two-dimensional orthogonal transformation as before. The number of vectors to be subjected to the same two-dimensional orthogonal transformation as in the past differs depending on the search method of motion vector search.

図4は、スパイラルサーチによる動きベクトル探索例を示す説明図である。たとえば、動きベクトル探索をスパイラルサーチでおこなう場合、ベクトルの指す参照画像の左上の画素は図のように変化する。各ベクトルは隣接するベクトルのx成分、またはy成分が1だけ違うようなベクトル列を形成する。よって、スパイラルサーチでは、従来と同様の二次元直交変換については、探索開始の中心点でのみ行えばよい。   FIG. 4 is an explanatory diagram showing an example of motion vector search by spiral search. For example, when motion vector search is performed by spiral search, the upper left pixel of the reference image indicated by the vector changes as shown in the figure. Each vector forms a vector sequence in which the x components or y components of adjacent vectors differ by one. Therefore, in the spiral search, the same two-dimensional orthogonal transformation as before may be performed only at the center point of the search start.

(実施の形態2)
つぎに、実施の形態2では、M=1、かつ実施の形態1で示した式(1)〜(4)のT1,T2がアダマール変換行列の場合に演算量を削減する例について説明する。アダマール変換行列は、各要素が「−1」、「1」の行列である。また、実施の形態2では、実施の形態1で示した構成と同一構成には同一符号を付し、当該構成の説明を省略する。
(Embodiment 2)
Next, in the second embodiment, an example in which the amount of calculation is reduced when M = 1 and T1 and T2 in the equations (1) to (4) shown in the first embodiment are Hadamard transform matrices will be described. The Hadamard transform matrix is a matrix having elements “−1” and “1”. In the second embodiment, the same reference numerals are given to the same components as those shown in the first embodiment, and the description of the components is omitted.

また、実施の形態1で示したようにT2_uは、T2の最上行を要素に持つ行ベクトルであり、T2_dは、T2の最下行を要素に持つ行ベクトルである。T2_uおよびT2_dの各要素は、「1」または「−1」である。   Further, as described in the first embodiment, T2_u is a row vector having the uppermost row of T2 as an element, and T2_d is a row vector having the lowermost row of T2 as an element. Each element of T2_u and T2_d is “1” or “−1”.

T2_uやT2_dは、設計時にT2が決定された時点で決定されるため、定数である。よって、上記式(1)、(2)の一次元直交変換後の差分(T1・(Bc_l−Bp_l))は、N×1の変換係数行列であるため、N×1の変換係数行列とT2_uまたはT2_dとの乗算は、単に列ベクトルの複製および符号変換のみで実現することができる。   T2_u and T2_d are constants because they are determined when T2 is determined at the time of design. Therefore, since the difference (T1 · (Bc — 1−Bp — l)) after the one-dimensional orthogonal transformation of the above equations (1) and (2) is an N × 1 transform coefficient matrix, the N × 1 transform coefficient matrix and the T2_u Alternatively, multiplication with T2_d can be realized simply by duplicating the column vector and code conversion.

実施の形態1で示したようにT1_lは、T1の最左列を要素に持つ列ベクトルであり、T1_rは、T1の最右列を要素に持つ列ベクトルである。T1_lおよびT1_rの各要素は、「1」または「−1」である。   As described in the first embodiment, T1_l is a column vector having the leftmost column of T1 as an element, and T1_r is a column vector having the rightmost column of T1 as an element. Each element of T1_l and T1_r is “1” or “−1”.

T1_lやT1_rは、設計時にT1が決定された時点で決定されるため、定数である。よって、上記式(3)、(4)の一次元直交変換後の差分((Bc_r−Bp_r)・T2)は、1×1の変換係数行列であるため、1×Nの変換係数行列とT1_lやT1_rとの乗算は、単に行ベクトルの複製および符号変換のみで実現することができる。   T1_l and T1_r are constants because they are determined when T1 is determined at the time of design. Therefore, since the difference ((Bc_r−Bp_r) · T2) after the one-dimensional orthogonal transformation in the above equations (3) and (4) is a 1 × 1 transformation coefficient matrix, a 1 × N transformation coefficient matrix and T1_l And multiplication with T1_r can be realized simply by duplication of row vectors and code conversion.

実施の形態2では、たとえば、N=4とし、T1、T2を下記式(14)とすると、T2_d、T2_u、T1_l、T1_rは、それぞれ下記式(15)〜(18)である。   In the second embodiment, for example, when N = 4 and T1 and T2 are represented by the following equation (14), T2_d, T2_u, T1_l, and T1_r are respectively represented by the following equations (15) to (18).

Figure 0005375676
Figure 0005375676

図5−1は、実施の形態2においての第2の直交変換回路303の具体的な処理例を示す説明図(その1)である。まず、k1_0〜k1_3を要素とする列ベクトルが、上記式(1)の一次元直交変換後の差分(T1・(Bc_l−Bp_l))である。上記式(16)のようにT2_uの各要素は、すべて「1」であるため、k1_0〜k1_3を要素とする列ベクトルが3つ複製されて4×4要素の行列が生成される。   FIG. 5A is an explanatory diagram (part 1) of a specific processing example of the second orthogonal transform circuit 303 in the second embodiment. First, a column vector whose elements are k1_0 to k1_3 is the difference (T1 · (Bc_l−Bp_l)) after the one-dimensional orthogonal transformation of the above equation (1). Since each element of T2_u is “1” as in the above equation (16), three column vectors having k1_0 to k1_3 as elements are duplicated to generate a 4 × 4 element matrix.

図5−2は、実施の形態2においての第2の直交変換回路303の具体的な処理例を示す説明図(その2)である。まず、k2_0〜k2_3を要素とする列ベクトルが、上記式(2)の一次元直交変換後の差分(T1・(Bc_l−Bp_l))である。まず、k2_0〜k2_3を要素とする列ベクトルが3つ複製されて、4×4の行列が生成される。つぎに、上記式(15)のようにT2_dの要素は、1列目と3列目が「1」であり、2列目と4列目が「−1」であるため、2列目および4列目の各要素の符号が変換される。   FIG. 5-2 is an explanatory diagram (part 2) of a specific process example of the second orthogonal transform circuit 303 in the second embodiment. First, a column vector whose elements are k2_0 to k2_3 is the difference (T1 · (Bc_l−Bp_l)) after the one-dimensional orthogonal transformation of the above equation (2). First, three column vectors whose elements are k2_0 to k2_3 are duplicated to generate a 4 × 4 matrix. Next, since the elements of T2_d are “1” in the first column and the third column and “−1” in the second column and the fourth column as shown in the above formula (15), The sign of each element in the fourth column is converted.

図5−3は、実施の形態2においての第2の直交変換回路303の具体的な処理例を示す説明図(その3)である。まず、k3_0〜k3_3を要素とする行ベクトルが、上記式(3)の一次元直交変換後の差分{(Bc_r−Bp_r)・T2}である。上記式(17)のようにT1_lの各要素は、すべて「1」であるため、k3_0〜k3_3を要素とする行ベクトルが3つ複製されて4×4の行列が生成される。   FIG. 5C is an explanatory diagram (part 3) of a specific process example of the second orthogonal transform circuit 303 in the second embodiment. First, the row vector whose elements are k3_0 to k3_3 is the difference {(Bc_r−Bp_r) · T2} after the one-dimensional orthogonal transformation of the above equation (3). Since each element of T1_l is “1” as in the above equation (17), three row vectors having k3_0 to k3_3 as elements are duplicated to generate a 4 × 4 matrix.

図5−4は、実施の形態2においての第2の直交変換回路303の具体的な処理例を示す説明図(その4)である。まず、k4_0〜k4_3を要素とする行ベクトルが、上記式(4)の一次元直交変換後の差分{(Bc_r−Bp_r)・T2}である。まず、k4_0〜k4_3を要素とする列ベクトルが3つ複製されて、4×4の行列が生成される。   FIG. 5-4 is an explanatory diagram (part 4) of a specific process example of the second orthogonal transform circuit 303 in the second embodiment. First, the row vector whose elements are k4_0 to k4_3 is the difference {(Bc_r−Bp_r) · T2} after the one-dimensional orthogonal transformation of the above equation (4). First, three column vectors whose elements are k4_0 to k4_3 are duplicated to generate a 4 × 4 matrix.

つぎに、上記式(18)のようにT1_rの要素は、1行目と3行目が「1」であり、2行目と4行目が「−1」であるため、2行目および4行目の各要素の符号が変換される。   Next, since the elements of T1_r are “1” in the first and third lines and “−1” in the second and fourth lines as in the above equation (18), the second and The sign of each element in the fourth row is converted.

したがって、実施の形態2にかかる画像処理装置では、第2の直交変換回路303の具体的な処理を複製処理および符号変換処理とすることで、演算量を削減できる。   Therefore, in the image processing apparatus according to the second embodiment, the amount of calculation can be reduced by setting the specific processing of the second orthogonal transform circuit 303 as replication processing and code conversion processing.

また、上述では、第2の直交変換後にRpと第2の直交変換処理後のN×N要素の変換係数行列とを加算している。ここで、上述のように符号の変換でなく、Rpとの加算に代わって変換係数行列の要素が「−1」に対応する行または列に関しては、Rpとの加算を減算に置き換えることができる。   In the above description, Rp is added after the second orthogonal transformation and the N × N element transformation coefficient matrix after the second orthogonal transformation processing. Here, instead of sign conversion as described above, addition to Rp can be replaced with subtraction for a row or column corresponding to an element of the transform coefficient matrix of “−1” instead of addition to Rp. .

上記式(1)を例に挙げると、画像処理装置が、第2の直交変換回路303によりN×1要素の変換係数行列を(N−1)個複製してN×N要素の変換係数行列を生成する。   Taking the above equation (1) as an example, the image processing apparatus duplicates (N−1) N × 1 element conversion coefficient matrices by the second orthogonal conversion circuit 303 to obtain an N × N element conversion coefficient matrix. Is generated.

つぎに、画像処理装置が、T2_uは、すべて「1」であるため、係数値算出回路304によりN×N要素の変換係数行列と第1の変換係数行列とを加算する。そして、加算後のN×N要素の変換係数行列に行列の入れ替えに関する入れ替え行列(iT2・Sr・T2)を乗算して第2の変換係数行列(Rc)を算出する。   Next, since T2_u is all “1”, the image processing apparatus adds the N × N element conversion coefficient matrix and the first conversion coefficient matrix by the coefficient value calculation circuit 304. Then, a second conversion coefficient matrix (Rc) is calculated by multiplying the added N × N element conversion coefficient matrix by the replacement matrix (iT 2 · Sr · T 2) related to the replacement of the matrix.

上記式(2)を例に挙げると、画像処理装置300が、第2の直交変換回路303によりN×1要素の変換係数行列を(N−1)個複製してN×N要素の変換係数行列を生成する。   Taking the above equation (2) as an example, the image processing apparatus 300 duplicates (N−1) N × 1 element conversion coefficient matrices by the second orthogonal transformation circuit 303 to convert N × N element conversion coefficients. Generate a matrix.

つぎに、画像処理装置300が、T2_dは、2列目と3列目が「−1」であるため、係数値算出回路304によりN×N要素の第1の変換係数行列の1列目とN×N要素の変換係数行列の1列目とを加算する。そして、係数値算出回路304によりN×N要素の第1の変換係数行列の2列目とN×N要素の変換係数行列の2列目とを減算し、係数値算出回路304によりN×N要素の第1の変換係数行列の3列目とN×N要素の変換係数行列の3列目とを減算する。さらに、係数値算出回路304によりN×N要素の第1の変換係数行列の4列目とN×N要素の変換係数行列の4列目とを加算する。そして、加減算後のN×N要素の変換係数行列に行列の入れ替えに関する入れ替え行列(iT2・Sl・T2)を乗算して第2の変換係数行列(Rc)を算出する。   Next, since the second column and the third column of the image processing apparatus 300 are “−1”, the coefficient value calculation circuit 304 determines that the first column of the N × N element first transform coefficient matrix is the T2_d. The first column of the N × N element conversion coefficient matrix is added. Then, the coefficient value calculation circuit 304 subtracts the second column of the N × N element first conversion coefficient matrix and the second column of the N × N element conversion coefficient matrix, and the coefficient value calculation circuit 304 calculates N × N. The third column of the first transformation coefficient matrix of the element is subtracted from the third column of the N × N element transformation coefficient matrix. Further, the coefficient value calculation circuit 304 adds the fourth column of the N × N element first conversion coefficient matrix and the fourth column of the N × N element conversion coefficient matrix. Then, the second transformation coefficient matrix (Rc) is calculated by multiplying the transformation coefficient matrix of N × N elements after addition and subtraction by the exchange matrix (iT2, S1, and T2) related to the matrix exchange.

上記式(3)を例に挙げると、画像処理装置300が、第2の直交変換回路303により1×N要素の変換係数行列を(N−1)個複製してN×N要素の変換係数行列を生成する。   Taking the above equation (3) as an example, the image processing apparatus 300 uses the second orthogonal transform circuit 303 to replicate (N−1) 1 × N element conversion coefficient matrices to generate N × N element conversion coefficients. Generate a matrix.

つぎに、画像処理装置300が、T1_lの要素は、すべて「1」であるため、係数値算出回路304によりN×N要素の変換係数行列と第1の変換係数行列とを加算する。そして、加算後のN×N要素の変換係数行列に行列の入れ替えに関する入れ替え行列(T1・Sd・iT1)を乗算して第2の変換係数行列(Rc)を算出する。   Next, since all of the elements of T1_l are “1”, the image processing apparatus 300 adds the N × N element conversion coefficient matrix and the first conversion coefficient matrix by the coefficient value calculation circuit 304. Then, a second conversion coefficient matrix (Rc) is calculated by multiplying the added N × N element conversion coefficient matrix by the replacement matrix (T1, Sd, iT1) related to the replacement of the matrix.

上記式(2)を例に挙げると、画像処理装置300が、第2の直交変換回路303によりN×1要素の変換係数行列を(N−1)個複製してN×N要素の変換係数行列を生成する。   Taking the above equation (2) as an example, the image processing apparatus 300 duplicates (N−1) N × 1 element conversion coefficient matrices by the second orthogonal transformation circuit 303 to convert N × N element conversion coefficients. Generate a matrix.

つぎに、画像処理装置300が、T1_rは、2行目と4行目が「−1」であるため、係数値算出回路304によりN×N要素の第1の変換係数行列の1行目とN×N要素の変換係数行列の1行目とを加算する。そして、係数値算出回路304によりN×N要素の第1の変換係数行列の2行目とN×N要素の変換係数行列の2行目とを減算し、係数値算出回路304によりN×N要素の第1の変換係数行列の3行目とN×N要素の変換係数行列の3行目とを加算する。さらに、係数値算出回路304によりN×N要素の第1の変換係数行列の4行目とN×N要素の変換係数行列の4行目とを減算する。そして、加減算後のN×N要素の変換係数行列に行列の入れ替えに関する入れ替え行列(T1・Su・iT1)を乗算して第2の変換係数行列(Rc)を算出する。   Next, since the image processing apparatus 300 determines that T1_r is “−1” in the second and fourth rows, the coefficient value calculation circuit 304 determines that the first row of the first transformation coefficient matrix of N × N elements The first row of the N × N element conversion coefficient matrix is added. Then, the coefficient value calculation circuit 304 subtracts the second row of the N × N element first conversion coefficient matrix and the second row of the N × N element conversion coefficient matrix, and the coefficient value calculation circuit 304 calculates N × N. The third row of the first transformation coefficient matrix of the element and the third row of the N × N element transformation coefficient matrix are added. Further, the coefficient value calculation circuit 304 subtracts the fourth row of the N × N element first transformation coefficient matrix and the fourth row of the N × N element transformation coefficient matrix. Then, the second transformation coefficient matrix (Rc) is calculated by multiplying the transformation coefficient matrix of N × N elements after addition / subtraction by the exchange matrix (T1 · Su · iT1) relating to the matrix exchange.

したがって、実施の形態2にかかる画像処理装置300では、直交変換行列をアダマール行列とすることで、第1の直交変換回路302の処理を加算処理または減算処理のみで実現でき、演算量を削減できる。さらに、第2の直交変換回路303の具体的な処理を複製処理とし、係数値算出回路304での加算処理を第2の直交変換行列に基づいて加算処理または減算処理とすることで演算量を削減できる。   Therefore, in the image processing apparatus 300 according to the second embodiment, by using an orthogonal transformation matrix as a Hadamard matrix, the processing of the first orthogonal transformation circuit 302 can be realized only by addition processing or subtraction processing, and the amount of computation can be reduced. . Furthermore, the specific processing of the second orthogonal transformation circuit 303 is a replication processing, and the addition processing in the coefficient value calculation circuit 304 is an addition processing or a subtraction processing based on the second orthogonal transformation matrix, thereby reducing the amount of computation. Can be reduced.

(実施の形態3)
つぎに、実施の形態3では、N=4の場合のみの場合においての高速化処理について説明する。実施の形態3では、原画像内の対象ブロックの直交変換から現ベクトルの直交変換結果を算出する処理を、現ベクトルの直交変換結果を算出せずに高速化する。
(Embodiment 3)
Next, in the third embodiment, the speed-up process in the case of only N = 4 will be described. In Embodiment 3, the process of calculating the orthogonal transformation result of the current vector from the orthogonal transformation of the target block in the original image is speeded up without calculating the orthogonal transformation result of the current vector.

まず、Sr、Sd、Su、Slがそれぞれ下記式(19)、(20)である。さらに、T1とT2が設計時に決定されているため、上記式(1)の(iT2・Sr・T2)は、下記式(21)であり、上記式(2)の(iT2・Sl・T2)は、下記式(22)である。そして、上記式(3)の(T1・Sd・iT1)は、下記式(23)であり、上記式(4)の(T1・Su・iT1)は、下記式(24)である。   First, Sr, Sd, Su, and S1 are the following expressions (19) and (20), respectively. Furthermore, since T1 and T2 are determined at the time of design, (iT2 · Sr · T2) in the above formula (1) is the following formula (21), and (iT2 · Sl · T2) in the above formula (2). Is the following formula (22). And (T1 * Sd * iT1) of the above-mentioned formula (3) is the following formula (23), and (T1 * Su * iT1) of the above-mentioned formula (4) is the following formula (24).

Figure 0005375676
Figure 0005375676

上記式(1)〜(4)は、Rcの算出に関する式であるが、SATDでは、原画内の対象ブロックの変換結果(C)からRcを引いて、各要素の絶対値を合計する。   The above formulas (1) to (4) are formulas related to the calculation of Rc. In SATD, Rc is subtracted from the conversion result (C) of the target block in the original image, and the absolute values of the respective elements are summed.

上記式(1)の(iT2・Sr・T2)は、上記式(21)であるため、上記式(1)のように4×4要素の行列に対して(iT2・Sr・T2)を右からかけると下記式(25)のようになる。   Since (iT2 · Sr · T2) in the above equation (1) is the above equation (21), (iT2 · Sr · T2) is to the right of the 4 × 4 matrix as in the above equation (1). When multiplied, the following equation (25) is obtained.

Figure 0005375676
Figure 0005375676

T1_0〜T1_15を要素に持つ4×4要素の行列が、上記式(1)の[Rp+{T1・(Bc_l−Bp_l)}・T2_u]の算出結果とする。したがって、(iT2・Sr・T2)の右からの乗算は、4×4要素の行列のうちの3列目と4列目を入れ替えて、入れ替え後の2列目と4列目の符号を反転することに相当する。   A matrix of 4 × 4 elements having T1_0 to T1_15 as elements is the calculation result of [Rp + {T1 · (Bc_l−Bp_l)} · T2_u] in the above equation (1). Therefore, multiplication from the right of (iT2, Sr, T2) is performed by switching the third and fourth columns of the 4 × 4 element matrix and inverting the signs of the second and fourth columns after the replacement. It corresponds to doing.

図6−1は、入れ替え行列との乗算処理が入れ替え処理および符号変換処理に置き換えられた例を示す説明図(その1)である。H1_0からH1_3が、1列目であり、H1_4からH1_7が2列目であり、H1_8からH1_11が3列目であり、H1_12からH1_15が4列目である。   FIG. 6A is an explanatory diagram (part 1) of an example in which multiplication processing with a replacement matrix is replaced with replacement processing and code conversion processing. H1_0 to H1_3 are the first column, H1_4 to H1_7 are the second column, H1_8 to H1_11 are the third column, and H1_12 to H1_15 are the fourth column.

まず、3列目と4列目が入れ替えられ、つぎに、2列目と4列目の符号が変換されている。これにより、4×4要素の行列と(iT2・Sr・T2)との乗算処理が、列の入れ替え処理および符号の反転処理のみとなり、高速化を図ることができる。   First, the third and fourth columns are interchanged, and then the codes of the second and fourth columns are converted. As a result, the multiplication process of the 4 × 4 element matrix and (iT2, Sr, T2) is only the column replacement process and the sign inversion process, and the speed can be increased.

そして、対象ブロックから反転処理後の4×4要素の行列が減算される。   Then, the 4 × 4 element matrix after the inversion process is subtracted from the target block.

つぎに、上記式(2)の(iT2・Sl・T2)は、上記式(22)であるため、上記式(2)のように4×4要素の行列に対して(iT2・Sl・T2)を右からかけると下記式(26)のようになる。   Next, since (iT2 · S1 · T2) in the above equation (2) is the above equation (22), the (iT2 · S1 · T2) is calculated for a 4 × 4 element matrix as in the above equation (2). ) From the right, the following equation (26) is obtained.

Figure 0005375676
Figure 0005375676

したがって、(iT2・Sl・T2)の右からの乗算は、4×4要素の行列のうちの3列目と4列目を入れ替えて、入れ替え後の2列目と3列目の符号を反転することに相当する。   Therefore, multiplication from the right of (iT2, S1, T2) is performed by switching the third and fourth columns of the 4 × 4 element matrix and inverting the signs of the second and third columns after the replacement. It corresponds to doing.

図6−2は、入れ替え行列との乗算処理が入れ替え処理および符号変換処理に置き換えられた例を示す説明図(その2)である。H2_0からH2_3が、1列目であり、H2_4からH2_7が2列目であり、H2_8からH2_11が3列目であり、H2_12からH2_15が4列目である。まず、3列目と4列目が入れ替えられ、つぎに、2列目と3列目の符号が変換されている。これにより、4×4要素の行列と(iT2・Sl・T2)との乗算処理が、列の入れ替え処理および符号の反転処理のみとなり、高速化を図ることができる。   FIG. 6B is an explanatory diagram (part 2) of the example in which the multiplication process with the exchange matrix is replaced with the exchange process and the code conversion process. H2_0 to H2_3 are the first column, H2_4 to H2_7 are the second column, H2_8 to H2_11 are the third column, and H2_12 to H2_15 are the fourth column. First, the third and fourth columns are interchanged, and then the codes in the second and third columns are converted. As a result, the multiplication process of the 4 × 4 element matrix and (iT2, S1, T2) is only the column replacement process and the sign inversion process, and the speed can be increased.

つぎに、上記式(3)の(T1・Sd・iT1)は、上記式(23)であるため、上記式(3)のように4×4要素の行列に対して(T1・Sd・iT1)を左からかけると下記式(27)のようになる。   Next, since (T1 · Sd · iT1) in the above equation (3) is the above equation (23), (T1 · Sd · iT1) is applied to a 4 × 4 element matrix as in the above equation (3). ) From the left, the following equation (27) is obtained.

Figure 0005375676
Figure 0005375676

したがって、(T1・Sd・iT1)を左から4×4要素の行列に乗算するのは、4×4要素の行列のうちの3列目と4列目を入れ替えて、入れ替え後の2列目と3列目の符号を反転することに相当する。   Therefore, (T1 · Sd · iT1) is multiplied by the 4 × 4 element matrix from the left to replace the third and fourth columns of the 4 × 4 element matrix, and the second column after the replacement. Is equivalent to reversing the sign of the third column.

図6−3は、入れ替え行列との乗算処理が入れ替え処理および符号変換処理に置き換えられた例を示す説明図(その3)である。H3_0、H3_4、H3_8、H3_12が、1行目であり、H3_1、H3_5、H3_9、H3_13が、2行目であり、H3_2、H3_6、H3_10、H3_14が、3行目であり、H3_3、H3_7、H3_11、H3_15が、4行目である。まず、3行目と4行目が入れ替えられ、つぎに、2行目と3行目の符号が変換されている。これにより、4×4要素の行列と(T1・Sd・iT1)との乗算処理が、列の入れ替え処理および符号の反転処理のみとなり、高速化を図ることができる。   FIG. 6C is an explanatory diagram (part 3) of the example in which the multiplication process with the exchange matrix is replaced with the exchange process and the code conversion process. H3_0, H3_4, H3_8, H3_12 are the first row, H3_1, H3_5, H3_9, H3_13 are the second row, H3_2, H3_6, H3_10, H3_14 are the third row, H3_3, H3_7, H3_11 , H3_15 is the fourth row. First, the third and fourth lines are interchanged, and then the codes of the second and third lines are converted. As a result, the multiplication process of the 4 × 4 element matrix and (T1, Sd, iT1) is only the column replacement process and the sign inversion process, and the speed can be increased.

つぎに、上記式(4)の(T1・Su・iT1)は、上記式(24)であるため、上記式(4)のように4×4要素の行列に対して(T1・Su・iT1)を左からかけると下記式(28)のようになる。   Next, since (T1 · Su · iT1) in the above equation (4) is the above equation (24), (T1 · Su · iT1) is applied to a 4 × 4 element matrix as in the above equation (4). ) From the left, the following equation (28) is obtained.

Figure 0005375676
Figure 0005375676

したがって、(T1・Su・iT1)を左から4×4要素の行列に乗算するのは、4×4要素の行列のうちの3行目と4行目を入れ替えて、入れ替え後の2行目と4行目の符号を反転することに相当する。   Therefore, (T1 · Su · iT1) is multiplied by the 4 × 4 element matrix from the left to replace the third row and the fourth row of the 4 × 4 element matrix, and the second row after the replacement. Is equivalent to reversing the sign of the fourth row.

図6−4は、入れ替え行列との乗算処理が入れ替え処理および符号変換処理に置き換えられた例を示す説明図(その4)である。H4_0、H4_4、H4_8、H4_12が、1行目であり、H4_1、H4_5、H4_9、H4_13が、2行目であり、H4_2、H4_6、H4_10、H4_14が、3行目であり、H4_3、H4_7、H4_11、H4_15が、4行目である。   6-4 is explanatory drawing (the 4) which shows the example by which the multiplication process with the permutation matrix was replaced by the permutation process and the code conversion process. H4_0, H4_4, H4_8, H4_12 are the first row, H4_1, H4_5, H4_9, H4_13 are the second row, H4_2, H4_6, H4_10, H4_14 are the third row, H4_3, H4_7, H4_11 , H4_15 is the fourth row.

まず、3行目と4行目が入れ替えられ、つぎに、2行目と4行目の符号が変換されている。これにより、4×4要素の行列と(T1・Su・iT1)との乗算処理が、列の入れ替え処理および符号の反転処理のみとなり、高速化を図ることができる。   First, the third and fourth lines are interchanged, and then the codes of the second and fourth lines are converted. As a result, the multiplication process of the 4 × 4 element matrix and (T1, Su, iT1) is only the column replacement process and the sign inversion process, and the speed can be increased.

上述の係数値の算出に関する乗算処理では、入れ替え処理後に符号を変換している。動きベクトル検出処理では、実際には、第2の予測ブロックに関する第2の変換係数行列が算出された後、対象ブロックに関する第3の変換係数行列から第2の変換係数行列が減算される。係数値の算出に関する乗算処理では、入れ替え処理のみとし、第3の変換係数行列(Rp)から第2の変換係数行列を減算する際の処理の一部を加算に置き換えることで、第3の変換係数行列(Rp)と第2の変換係数行列との差分を算出できる。   In the multiplication processing related to the calculation of the coefficient value described above, the code is converted after the replacement processing. In the motion vector detection process, actually, after the second transform coefficient matrix relating to the second prediction block is calculated, the second transform coefficient matrix is subtracted from the third transform coefficient matrix relating to the target block. In the multiplication process relating to the calculation of the coefficient value, only the replacement process is performed, and a part of the process when the second conversion coefficient matrix is subtracted from the third conversion coefficient matrix (Rp) is replaced with addition, whereby the third conversion is performed. The difference between the coefficient matrix (Rp) and the second transform coefficient matrix can be calculated.

上記式(1)を例に挙げると、上述のようにN×N要素の変換係数行列の3列目と4列目が入れ替えられる。そして、第3の変換係数行列(Rp)の1列目から第2の変換係数行列の1列目を減算し、第3の変換係数行列(Rp)の2列目から第2の変換係数行列の2列目を加算する。さらに、第3の変換係数行列(Rp)の3列目から第2の変換係数行列の3列目を減算し、第3の変換係数行列(Rp)の4列目から第2の変換係数行列の4列目を加算する。   Taking the above equation (1) as an example, the third column and the fourth column of the N × N element conversion coefficient matrix are exchanged as described above. Then, the first column of the second conversion coefficient matrix is subtracted from the first column of the third conversion coefficient matrix (Rp), and the second conversion coefficient matrix is calculated from the second column of the third conversion coefficient matrix (Rp). Are added to the second column. Further, the third column of the second conversion coefficient matrix is subtracted from the third column of the third conversion coefficient matrix (Rp), and the second conversion coefficient matrix is calculated from the fourth column of the third conversion coefficient matrix (Rp). Are added to the fourth column.

上記式(2)を例に挙げると、上述のようにN×N要素の変換係数行列の3列目と4列目が入れ替えられる。そして、第3の変換係数行列(Rp)の1列目から第2の変換係数行列の1列目を減算し、第3の変換係数行列(Rp)の2列目から第2の変換係数行列の2列目を加算する。さらに、第3の変換係数行列(Rp)の3列目から第2の変換係数行列の3列目を加算し、第3の変換係数行列(Rp)の4列目から第2の変換係数行列の4列目を減算する。   Taking the above equation (2) as an example, the third column and the fourth column of the N × N element conversion coefficient matrix are exchanged as described above. Then, the first column of the second conversion coefficient matrix is subtracted from the first column of the third conversion coefficient matrix (Rp), and the second conversion coefficient matrix is calculated from the second column of the third conversion coefficient matrix (Rp). Are added to the second column. Furthermore, the third column of the second transform coefficient matrix is added from the third column of the third transform coefficient matrix (Rp), and the second transform coefficient matrix is added from the fourth column of the third transform coefficient matrix (Rp). The fourth column is subtracted.

上記式(3)を例に挙げると、上述のようにN×N要素の変換係数行列の3行目と4行目が入れ替えられる。そして、第3の変換係数行列(Rp)の1行目から第2の変換係数行列の1行目を減算し、第3の変換係数行列(Rp)の2行目から第2の変換係数行列の2行目を加算する。さらに、第3の変換係数行列(Rp)の3行目から第2の変換係数行列の3行目を加算し、第3の変換係数行列(Rp)の4行目から第2の変換係数行列の4行目を減算する。   Taking the above equation (3) as an example, the third row and the fourth row of the N × N element conversion coefficient matrix are interchanged as described above. Then, the first row of the second transformation coefficient matrix is subtracted from the first row of the third transformation coefficient matrix (Rp), and the second transformation coefficient matrix is obtained from the second row of the third transformation coefficient matrix (Rp). Add the second line of. Further, the third row of the second transformation coefficient matrix is added from the third row of the third transformation coefficient matrix (Rp), and the second transformation coefficient matrix is obtained from the fourth row of the third transformation coefficient matrix (Rp). The 4th line is subtracted.

なお、入れ替え後のN×N要素の変換係数行列と、第2の予測ブロックに関する第2の変換係数行列とは異なる。   Note that the N × N element transform coefficient matrix after replacement is different from the second transform coefficient matrix related to the second prediction block.

上記式(4)を例に挙げると、上述のようにN×N要素の変換係数行列の3行目と4行目が入れ替えられる。そして、第3の変換係数行列(Rp)の1行目から第2の変換係数行列の1行目を減算し、第3の変換係数行列(Rp)の2行目から第2の変換係数行列の2行目を加算する。さらに、第3の変換係数行列(Rp)の3行目から第2の変換係数行列の3行目を減算し、第3の変換係数行列(Rp)の4行目から第2の変換係数行列の4行目を加算する。これにより、演算量を削減することができる。   Taking the above equation (4) as an example, the third row and the fourth row of the N × N element conversion coefficient matrix are interchanged as described above. Then, the first row of the second transformation coefficient matrix is subtracted from the first row of the third transformation coefficient matrix (Rp), and the second transformation coefficient matrix is obtained from the second row of the third transformation coefficient matrix (Rp). Add the second line of. Further, the third row of the second transformation coefficient matrix is subtracted from the third row of the third transformation coefficient matrix (Rp), and the second transformation coefficient matrix is obtained from the fourth row of the third transformation coefficient matrix (Rp). Add the 4th line. Thereby, the amount of calculation can be reduced.

また、入れ替え後のN×N要素の変換係数行列と、第2の予測ブロックに関する第2の変換係数行列とは異なる。よって、第2の変換係数行列(Rc)が算出されないため、現ベクトルを用いて次ベクトルのSATDを求めるには、別の値を用いる。   Further, the N × N element transform coefficient matrix after replacement is different from the second transform coefficient matrix related to the second prediction block. Therefore, since the second transform coefficient matrix (Rc) is not calculated, another value is used to obtain the SATD of the next vector using the current vector.

ここでは、上記式(2)のみを例に挙げて説明する。上記式(22)は、下記式(29)のようにSとLの2つの行列に分解できる。   Here, only the above formula (2) will be described as an example. The above equation (22) can be decomposed into two matrices of S and L as in the following equation (29).

Figure 0005375676
Figure 0005375676

(T1・(Bc_l−Bp_l))・T2_dをBとすると、下記式(30)のようになる。   When (T1 · (Bc — 1−Bp — 1)) · T2_d is B, the following equation (30) is obtained.

C−Rc=C−(Rp+B)・S・L ・・・(30)   C−Rc = C− (Rp + B) · S · L (30)

上記式(29)において、Lは、Cとの減算の一部を加算へ置き換えることで実現できる。ここで、Cとの加減算および置き換え処理を◎を用いて表すと下記式(31)のようになる。   In the above equation (29), L can be realized by replacing a part of subtraction with C by addition. Here, the addition / subtraction with C and the replacement processing are expressed by using ◎, as shown in the following formula (31).

C−Rc=C◎(Rp+B)・S ・・・(31)   C−Rc = C ◎ (Rp + B) · S (31)

また、現ベクトルの変換結果を用いて次ベクトルの変換結果を算出するには、Rcの代わりにiL(Lの逆行列)・Rcを用いる。次ベクトルが現ベクトルの上下左右いずれかの方向に1画素移動したものであったとしても、L・(iM・Rp)+Pc、またはPc+M・(iM・Rp)という演算が行われ、Mの左からの乗算は、Pcの加算の一部を減算とすることに置き換えることができる。   In order to calculate the conversion result of the next vector using the conversion result of the current vector, iL (inverse matrix of L) · Rc is used instead of Rc. Even if the next vector is moved by one pixel in either the up, down, left, or right direction of the current vector, the operation L · (iM · Rp) + Pc or Pc + M · (iM · Rp) is performed, and the left of M The multiplication from can be replaced with subtraction as part of the addition of Pc.

つぎに、実施の形態3をH.264エンコーダに適用した際の動きベクトル探索部の構成の一例を説明する。ここでは、動きベクトル探索部全体ではなく、原画像と参照画像をフレームメモリから取得した後SATD算出をおこなう部分までの回路構成を説明する。   Next, the third embodiment is described in H.264. An example of the configuration of a motion vector search unit when applied to an H.264 encoder will be described. Here, the circuit configuration from the acquisition of the original image and the reference image from the frame memory to the portion where the SATD calculation is performed, instead of the entire motion vector search unit will be described.

図7は、マクロブロックの一例を示す説明図である。図7には、原画像内の現マクロブロックと参照画像内で対象マクロブロックと同一位置にある参照マクロブロックが示されている。現マクロブロックサイズおよび参照マクロブロックサイズは、4×4ブロックの集合であり、各ブロックサイズは、4×4画素である。   FIG. 7 is an explanatory diagram illustrating an example of a macroblock. FIG. 7 shows the current macroblock in the original image and the reference macroblock in the same position as the target macroblock in the reference image. The current macroblock size and the reference macroblock size are a set of 4 × 4 blocks, and each block size is 4 × 4 pixels.

実施の形態3では、動きベクトル探索はマクロブロックごとにおこなわれ、水平方向に並んだ5個のベクトルのSATDを並列に算出する。ここで、水平方向に並んだ5個のベクトル0〜ベクトル4の一例について説明する。   In Embodiment 3, motion vector search is performed for each macroblock, and SATDs of five vectors arranged in the horizontal direction are calculated in parallel. Here, an example of five vectors 0 to 4 arranged in the horizontal direction will be described.

原画像内のマクロブロック内にはBK1_1〜BK1_4がある。参照画像内のマクロブロック内にはBK2_1〜BK2_4がある。ここでは、原画像内のBK1_1〜BK1_4からベクトル0で指されているブロックをBK2_1〜BK2_4とする。BK1_1と同一位置にある参照画像内のブロックは、BK2_1である。よって、BK2_1を示す動きベクトルが、BK1_1に関するベクトル0である。   There are BK1_1 to BK1_4 in the macroblock in the original image. There are BK2_1 to BK2_4 in the macroblock in the reference image. Here, BK2_1 to BK2_4 are blocks pointed to by vector 0 from BK1_1 to BK1_4 in the original image. The block in the reference image at the same position as BK1_1 is BK2_1. Therefore, the motion vector indicating BK2_1 is the vector 0 regarding BK1_1.

また、BK1_2と同一位置にある参照画像内のブロックは、BK2_2であり、BK2_2を示す動きベクトルが、BK1_2に関するベクトル0である。そして、BK1_3と同一位置にある参照画像内のブロックは、BK2_3であり、BK2_3を示す動きベクトルが、BK1_3に関するベクトル0である。BK1_4と同一位置にある参照画像内のブロックは、BK2_4であり、BK2_4を示す動きベクトルが、BK1_4に関するベクトル0である。   Further, the block in the reference image at the same position as BK1_2 is BK2_2, and the motion vector indicating BK2_2 is the vector 0 regarding BK1_2. The block in the reference image at the same position as BK1_3 is BK2_3, and the motion vector indicating BK2_3 is the vector 0 regarding BK1_3. The block in the reference image at the same position as BK1_4 is BK2_4, and the motion vector indicating BK2_4 is vector 0 regarding BK1_4.

そして、BK1_1に関するベクトルを例に挙げると、BK2_1を横方向に−1シフトしたブロックを示す動きベクトルが、BK1_1に関するベクトル1である。さらに、横方向に−1シフトしたブロックを示す動きベクトルが、BK1_1に関するベクトル2であり、以降、BK1_1に関するベクトル3、4までが図示されている。上述のように本実施の形態3では、ベクトル0〜4までの5個のベクトルに関するSATDを並列に算出する。   Taking a vector related to BK1_1 as an example, a motion vector indicating a block obtained by shifting BK2_1 by -1 in the horizontal direction is a vector 1 related to BK1_1. Furthermore, a motion vector indicating a block shifted by −1 in the horizontal direction is a vector 2 regarding BK1_1, and thereafter, vectors 3 and 4 regarding BK1_1 are illustrated. As described above, in the third embodiment, SATDs for five vectors 0 to 4 are calculated in parallel.

ここで、5個のベクトルのうち最右のベクトルの変換結果をもとに最右のベクトルよりも左の4点の変換結果を求める構成とする。以降の数式の添え字は対象ベクトルの最右ベクトルとのx座標の差を表す。   Here, it is assumed that a conversion result of four points on the left side of the rightmost vector is obtained based on the conversion result of the rightmost vector among the five vectors. The subscripts in the following mathematical expressions represent the difference of the x coordinate from the rightmost vector of the target vector.

各ベクトルの原画像内のブロックの変換結果と参照画像内のブロックの変換結果の差分Dxは以下のようになる。   The difference Dx between the conversion result of the block in the original image of each vector and the conversion result of the block in the reference image is as follows.

・D0=C−R0
・D1=C−R1=C−(R0△B1)・S・L=C◎(R0△B1)・S
・D2=C−R2=C−(R1△B2)・S・L=C◎(R1△B2)・S
・D3=C−R3=C−(R2△B3)・S・L=C◎(R2△B3)・S
・D4=C−R4=C−(R3△B4)・S・L=C◎(R3△B4)・S
・ D0 = C−R0
· D1 = C-R1 = C-(R0ΔB1) · S · L = C ◎ (R0ΔB1) · S
· D2 = C-R2 = C-(R1ΔB2) · S · L = C ◎ (R1ΔB2) · S
D3 = C−R3 = C− (R2ΔB3) S S L = C ◎ (R2ΔB3) S
・ D4 = C−R4 = C− (R3ΔB4) • S • L = C ◎ (R3ΔB4) • S

ここで、Bnは列ベクトル(T1・(Bc_l−Bp_l))を4つ並べた4×4行列、△と◎は同位置の行列成分に対して、第1列と第3列は加算、第2列と第4列は左辺成分から右辺成分を減ずる演算をおこなう演算子である。これらD0〜D4の絶対値和が各ベクトルにおけるSATDとなる。   Here, Bn is a 4 × 4 matrix in which four column vectors (T1 · (Bc_l−Bp_l)) are arranged, Δ and ◎ are matrix components at the same position, and the first and third columns are added, Columns 2 and 4 are operators that perform an operation of subtracting the right side component from the left side component. The sum of absolute values of D0 to D4 is SATD in each vector.

また、R1=(R0△B1)・S・Lにより、P1=(R0△B1)・Sと置くと、R1△B2=P1・L△B2=P1▲B2となる。Mは右からかけると、第2列と第4列の符号を反転させる行列なので、▲は通常の行列加算演算子+と等しい。D2〜D3をこの方法によって変形して、最終的に以下を得る。   If R1 = (R0ΔB1) · S · L and P1 = (R0ΔB1) · S, then R1ΔB2 = P1 · LΔB2 = P11B2. When M is multiplied from the right, it is a matrix that inverts the sign of the second column and the fourth column, so ▲ is equal to the normal matrix addition operator +. D2 to D3 are modified by this method to finally obtain:

D0=C−R0 ・・・(32)   D0 = C−R0 (32)

D1=C−R1=C◎(R0△B1)・S ・・・(33)   D1 = C−R1 = C ◎ (R0ΔB1) · S (33)

D2=C−R2=C◎(P1+B2)・S ・・・(34)   D2 = C−R2 = C ◎ (P1 + B2) · S (34)

D3=C−R3=C◎(P2+B3)・S ・・・(35)   D3 = C−R3 = C ◎ (P2 + B3) · S (35)

D4=C−R4=C◎(P3+B4)・S ・・・(36)   D4 = C−R4 = C ◎ (P3 + B4) · S (36)

図8は、実施の形態3にかかる画像処理装置の一例を示す説明図である。図8に示す画像処理装置800は、セレクタと、二次元アダマール変換回路と、予測ブロック変換結果保持回路と、対象ブロック変換結果保持回路と、予測ブロック保持回路と、ユニット0〜ユニット4と、を備える構成である。つぎに、ユニット0〜ユニット4について説明する。   FIG. 8 is an explanatory diagram of an example of the image processing apparatus according to the third embodiment. The image processing apparatus 800 illustrated in FIG. 8 includes a selector, a two-dimensional Hadamard transform circuit, a predicted block transform result holding circuit, a target block transform result holding circuit, a predicted block holding circuit, and units 0 to 4. It is the composition provided. Next, unit 0 to unit 4 will be described.

ユニット0は、ユニット0_1〜ユニット0_4を備え、それぞれは同一構成である。ユニット0では、ベクトル0に対応するSATDを算出する。   Unit 0 includes units 0_1 to unit 0_4, and each has the same configuration. In unit 0, the SATD corresponding to vector 0 is calculated.

ユニット1は、ユニット1_1〜ユニット1_4を備え、それぞれは同一構成である。ユニット1では、ベクトル1に対応するSATDを算出する。   The unit 1 includes units 1_1 to 1_4, each having the same configuration. In unit 1, SATD corresponding to vector 1 is calculated.

ユニット2は、ユニット2−3_1〜ユニット2−3_4を備え、ユニット3は、ユニット2−3_5〜ユニット2−3_8を備え、ユニット2−3_1〜ユニット2−3_8は、同一構成である。ユニット2では、ベクトル2に対応するSATDを算出し、ユニット3では、ベクトル3に対応するSATDを算出する   The unit 2 includes units 2-3_1 to 2-3_4, the unit 3 includes units 2-3_5 to 2-3_8, and the units 2-3_1 to 2-3_8 have the same configuration. In unit 2, the SATD corresponding to vector 2 is calculated, and in unit 3, the SATD corresponding to vector 3 is calculated.

ユニット4は、ユニット2−3_9と、ユニット0_5〜ユニット0_7を備え、ユニット2−3_9は、ユニット2−3_1と同一構成であり、ユニット0_5〜ユニット0_7は、ユニット0_1と同一構成である。ユニット4は、ベクトル4に対応するSATDを算出する。   The unit 4 includes a unit 2-3_9 and units 0_5 to 0_7. The unit 2-3_9 has the same configuration as the unit 2-3_1, and the units 0_5 to 0_7 have the same configuration as the unit 0_1. Unit 4 calculates SATD corresponding to vector 4.

図9は、ユニット0_1〜ユニット0_7の詳細な説明を示す説明図である。ユニット0_1〜ユニット0_7では、それぞれ上記式(32)を構成し、それぞれ減算回路を4つと、絶対値演算回路を4つと、総和演算回路を備えている。   FIG. 9 is an explanatory diagram showing a detailed description of the units 0_1 to 0_7. Each of the units 0_1 to 0_7 constitutes the above equation (32), and each includes four subtraction circuits, four absolute value calculation circuits, and a sum calculation circuit.

ユニット0_1〜ユニット0_7では、原画像内の対象ブロックの二次元直交変換結果と参照画像内のブロックの二次元直交変換結果との差分を算出し、それぞれの絶対値をとり、総和を算出してSATDを出力する。   In units 0_1 to 0_7, the difference between the two-dimensional orthogonal transformation result of the target block in the original image and the two-dimensional orthogonal transformation result of the block in the reference image is calculated, the respective absolute values are taken, and the sum is calculated. Output SATD.

図10は、ユニット1_1〜ユニット1_4の詳細な説明を示す説明図である。ユニット1_1〜ユニット1_4では、それぞれ上記式(33)を構成し、減算回路と、差分保持回路と、一次元アダマール変換回路と、△演算回路と、列入れ替え回路と、◎演算回路と、絶対値演算回路を4つと、総和演算回路を備えている。   FIG. 10 is an explanatory diagram showing a detailed description of the units 1_1 to 1_4. Each of the units 1_1 to 1_4 constitutes the above equation (33), and includes a subtraction circuit, a difference holding circuit, a one-dimensional Hadamard transform circuit, a Δ operation circuit, a column replacement circuit, an ◎ operation circuit, and an absolute value. Four arithmetic circuits and a total arithmetic circuit are provided.

減算回路では、Bc_l−Bp_lに対応する減算処理がおこなわれ、差分値を算出する。そして、減算結果を差分保持回路へ出力する。差分保持回路は、減算結果を保持し、また、あるブロックのための差分の受け取りと、つぎに一次元アダマール変換を施すための差分出力を同時におこなうため、ダブルバッファ構成である。   In the subtraction circuit, a subtraction process corresponding to Bc_l−Bp_l is performed, and a difference value is calculated. Then, the subtraction result is output to the difference holding circuit. The difference holding circuit has a double buffer configuration for holding the subtraction result, and simultaneously receiving the difference for a certain block and outputting the difference for the next one-dimensional Hadamard transformation.

一次元アダマール変換回路では、第1の直交変換処理をおこなう。よって、一次元アダマール変換回路では、T1に対応する加減算がおこなわれる。△演算回路では、上述のように1列目と3列目は加算、2列目と4列目は左辺成分から右辺成分を減ずる演算をおこなう。   The one-dimensional Hadamard transform circuit performs a first orthogonal transform process. Therefore, in the one-dimensional Hadamard transform circuit, addition / subtraction corresponding to T1 is performed. In the Δ arithmetic circuit, as described above, the first column and the third column are added, and the second column and the fourth column are calculated by subtracting the right side component from the left side component.

つぎに、列入れ替え回路では、列を入れ替える処理をおこない、◎演算回路では、上述のように1列目と3列目は加算、2列目と4列目は左辺成分から右辺成分を減ずる演算をおこなう。絶対値演算回路と総和演算回路については、公知であるため説明を省略する。   Next, the column replacement circuit performs processing to replace the columns, and in the arithmetic circuit, as described above, the first column and the third column are added, and the second column and the fourth column are calculated by subtracting the right side component from the left side component. To do. Since the absolute value calculation circuit and the sum calculation circuit are known, the description thereof is omitted.

図8に戻って、ユニット1内部ではユニット0から渡された予測ブロックの二次元直交変換結果(R0)に△B1に対応する演算がおこなわれる。B1は差分保持回路で保持されていた差分に一次元アダマール変換回路によって一次元アダマール変換をおこなうことによって得られる。R0△B1に対してSに相当する列入れ替え処理がおこなわれ、P1が得られる。P1は原画変換結果とともに◎演算回路ではP1と原画変換結果よりD1を得、絶対値の総和がSATDとして算出される。また、P1はユニット2へ送られる。このユニットで算出されるSATDはベクトル0のひとつ左を差すベクトル1である。   Returning to FIG. 8, in the unit 1, an operation corresponding to ΔB <b> 1 is performed on the two-dimensional orthogonal transformation result (R <b> 0) of the prediction block passed from the unit 0. B1 is obtained by performing one-dimensional Hadamard transformation on the difference held by the difference holding circuit by the one-dimensional Hadamard transformation circuit. A column replacement process corresponding to S is performed on R0ΔB1, and P1 is obtained. P1 is obtained together with the original image conversion result. The arithmetic circuit obtains D1 from P1 and the original image conversion result, and the sum of absolute values is calculated as SATD. P1 is also sent to unit 2. The SATD calculated by this unit is a vector 1 that puts one vector 0 to the left.

よって、ユニット1は前ベクトルの二次元直交変換結果としてR0を受け取り、ユニットnからユニットn+1へはPnが渡されている。   Therefore, unit 1 receives R0 as the result of the two-dimensional orthogonal transformation of the previous vector, and Pn is passed from unit n to unit n + 1.

図11は、ユニット2−3_1〜ユニット2−3_9の詳細な説明を示す説明図である。ユニット2−3_1〜ユニット2−3_9では、それぞれ上記式(34)〜(36)を構成し、減算回路と、差分保持回路と、一次元アダマール変換回路と、+演算回路と、列入れ替え回路と、◎演算回路と、絶対値演算回路を4つと、総和演算回路を備えている。   FIG. 11 is an explanatory diagram showing a detailed description of the units 2-3_1 to 2-3_9. In the units 2-3_1 to 2-3_9, the above formulas (34) to (36) are configured, respectively, and a subtraction circuit, a difference holding circuit, a one-dimensional Hadamard transform circuit, a + arithmetic circuit, and a column replacement circuit, , ◎ A calculation circuit, four absolute value calculation circuits, and a sum calculation circuit are provided.

ユニット2−3_1〜ユニット2−3_9は
1)△演算回路の代わりに+演算回路(加算回路)である。
2)R0の代わりにP1が入力される。
3)差分保持回路への入力が1画素左にずれた位置での差分結果である。
The units 2-3_1 to 2-3_9 are 1) a + arithmetic circuit (adder circuit) instead of the Δ arithmetic circuit.
2) P1 is input instead of R0.
3) A difference result at a position where the input to the difference holding circuit is shifted to the left by one pixel.

上記1)〜3)以外はユニット1_1〜ユニット1_4と同タイミングで同じ演算がおこなわれる。   Except for the above 1) to 3), the same calculation is performed at the same timing as the units 1_1 to 1_4.

図8に戻って、まず、処理対象原画像内のマクロブロックと参照画像内のマクロブロックをフレームメモリから取得する。原画像内のマクロブロックについてはフレームメモリから取り込まれながらブロックごとに二次元アダマール変換処理が施され、対象ブロック変換結果保持回路に格納される。   Returning to FIG. 8, first, macroblocks in the processing target original image and macroblocks in the reference image are acquired from the frame memory. The macroblocks in the original image are subjected to two-dimensional Hadamard transform processing for each block while being fetched from the frame memory, and stored in the target block transform result holding circuit.

また、参照画像内のマクロブロックについてもフレームメモリから取り込まれながらベクトル0である4つのブロックが、ブロックごとに二次元アダマール変換処理が施され、予測ブロック変換結果保持回路に格納される。ここでは、B2_1〜B2_4に対してアダマール変換処理が施される。さらに、参照画像内のマクロブロックは変換されない状態でも予測ブロック保持回路に格納される。   Also, the four blocks that are vector 0 while being fetched from the frame memory for the macroblocks in the reference image are subjected to the two-dimensional Hadamard transform process for each block and stored in the predicted block transform result holding circuit. Here, Hadamard transform processing is performed on B2_1 to B2_4. Furthermore, the macroblock in the reference image is stored in the prediction block holding circuit even in a state where it is not converted.

予測ブロック保持回路中の画像は以降のSATD算出処理中に使用されるが、たとえば、プリフェッチ機構のようなものを外部に持っていたり、フレームメモリとの帯域が十分に確保できる場合は予測ブロック保持回路を持たない構成も可能である。   The image in the prediction block holding circuit is used during the subsequent SATD calculation process. For example, if the image has a prefetch mechanism or if a sufficient bandwidth with the frame memory can be secured, the prediction block holding is performed. A configuration without a circuit is also possible.

図8の画像処理装置800では、全探索をベースとし垂直成分(y成分)が等しい5個のベクトルを並列に処理し、さらに、4回繰り返し、20個のベクトルに関するSATDを算出している。従来では、加減算回数は30400回であるが、図8の画像処理装置800では、加減算回数は24256回である。なお、絶対値演算回数はいずれも5120回である。   In the image processing apparatus 800 of FIG. 8, five vectors having the same vertical component (y component) are processed in parallel based on the full search, and further, the SATD for 20 vectors is calculated by repeating four times. Conventionally, the number of additions / subtractions is 30400, but in the image processing apparatus 800 of FIG. 8, the number of additions / subtractions is 24256. Note that the absolute value calculation count is 5120 times in all cases.

また、図8で示した原画像、参照画像をフレームメモリから取り込み時に変換する二次元アダマール変換回路は、各ユニット内で用いられる一次元アダマール変換回路と共有する構成も可能である。   Further, the two-dimensional Hadamard transformation circuit that converts the original image and the reference image shown in FIG. 8 when fetching from the frame memory can be shared with the one-dimensional Hadamard transformation circuit used in each unit.

また、実施の形態3では、上記式(2)を例に挙げ、さらに、全探索をベースとして画像処理装置の構成を説明したが、これに限らず、上記式(1)〜(4)や他の探索方法を用いてもよい。   In the third embodiment, the above formula (2) is taken as an example, and the configuration of the image processing apparatus is described based on the full search. However, the present invention is not limited to this, and the above formulas (1) to (4) and Other search methods may be used.

(実施の形態4)
つぎに、実施の形態4について説明する。実施の形態4では、実施の形態1に示される画像処理装置の各機能がコンピュータによる処理で実現される例を示す。
(Embodiment 4)
Next, a fourth embodiment will be described. In the fourth embodiment, an example in which each function of the image processing apparatus shown in the first embodiment is realized by processing by a computer will be described.

(画像処理装置のハードウェア構成)
図12は、実施の形態にかかる画像処理装置のハードウェア構成を示すブロック図である。図12において、画像処理装置は、CPU(Central Processing Unit)1201と、ROM(Read‐Only Memory)1202と、RAM(Random Access Memory)1203と、磁気ディスクドライブ1204と、磁気ディスク1205と、光ディスクドライブ1206と、光ディスク1207と、ディスプレイ1208と、I/F(Interface)1209と、キーボード1210と、マウス1211と、スキャナ1212と、プリンタ1213と、を備えている。また、各構成部はバス1200によってそれぞれ接続されている。
(Hardware configuration of image processing device)
FIG. 12 is a block diagram of a hardware configuration of the image processing apparatus according to the embodiment. In FIG. 12, an image processing apparatus includes a CPU (Central Processing Unit) 1201, a ROM (Read-Only Memory) 1202, a RAM (Random Access Memory) 1203, a magnetic disk drive 1204, a magnetic disk 1205, and an optical disk drive. 1206, an optical disc 1207, a display 1208, an I / F (Interface) 1209, a keyboard 1210, a mouse 1211, a scanner 1212, and a printer 1213. Each component is connected by a bus 1200.

ここで、CPU1201は、画像処理装置の全体の制御を司る。ROM1202は、ブートプログラムなどのプログラムを記憶している。RAM1203は、CPU1201のワークエリアとして使用される。磁気ディスクドライブ1204は、CPU1201の制御にしたがって磁気ディスク1205に対するデータのリード/ライトを制御する。磁気ディスク1205は、磁気ディスクドライブ1204の制御で書き込まれたデータを記憶する。   Here, the CPU 1201 controls the entire image processing apparatus. The ROM 1202 stores programs such as a boot program. The RAM 1203 is used as a work area for the CPU 1201. The magnetic disk drive 1204 controls reading / writing of data with respect to the magnetic disk 1205 under the control of the CPU 1201. The magnetic disk 1205 stores data written under the control of the magnetic disk drive 1204.

光ディスクドライブ1206は、CPU1201の制御にしたがって光ディスク1207に対するデータのリード/ライトを制御する。光ディスク1207は、光ディスクドライブ1206の制御で書き込まれたデータを記憶したり、光ディスク1207に記憶されたデータをコンピュータに読み取らせたりする。   The optical disk drive 1206 controls reading / writing of data with respect to the optical disk 1207 according to the control of the CPU 1201. The optical disk 1207 stores data written under the control of the optical disk drive 1206, and causes the computer to read data stored on the optical disk 1207.

ディスプレイ1208は、カーソル、アイコンあるいはツールボックスをはじめ、文書、画像、機能情報などのデータを表示する。このディスプレイ1208は、たとえば、CRT、TFT液晶ディスプレイ、プラズマディスプレイなどを採用することができる。   A display 1208 displays data such as a document, an image, and function information as well as a cursor, an icon, or a tool box. As the display 1208, for example, a CRT, a TFT liquid crystal display, a plasma display, or the like can be adopted.

インターフェース(以下、「I/F」と略する。)1209は、通信回線を通じてLAN(Local Area Network)、WAN(Wide Area Network)、インターネットなどのネットワーク1214に接続され、このネットワーク1214を介して他の装置に接続される。そして、I/F1209は、ネットワーク1214と内部のインターフェースを司り、外部装置からのデータの入出力を制御する。I/F1209には、たとえばモデムやLANアダプタなどを採用することができる。   An interface (hereinafter abbreviated as “I / F”) 1209 is connected to a network 1214 such as a LAN (Local Area Network), a WAN (Wide Area Network), and the Internet through a communication line, and the other via the network 1214. Connected to other devices. The I / F 1209 controls an internal interface with the network 1214 and controls input / output of data from an external device. For example, a modem or a LAN adapter may be employed as the I / F 1209.

キーボード1210は、文字、数字、各種指示などの入力のためのキーを備え、データの入力をおこなう。また、タッチパネル式の入力パッドやテンキーなどであってもよい。マウス1211は、カーソルの移動や範囲選択、あるいはウィンドウの移動やサイズの変更などをおこなう。ポインティングデバイスとして同様に機能を備えるものであれば、トラックボールやジョイスティックなどであってもよい。   The keyboard 1210 includes keys for inputting characters, numbers, various instructions, and the like, and inputs data. Moreover, a touch panel type input pad or a numeric keypad may be used. The mouse 1211 performs cursor movement, range selection, window movement, size change, and the like. A trackball or a joystick may be used as long as they have the same function as a pointing device.

スキャナ1212は、画像を光学的に読み取り、画像処理装置内に画像データを取り込む。なお、スキャナ1212は、OCR(Optical Character Reader)機能を持たせてもよい。また、プリンタ1213は、画像データや文書データを印刷する。プリンタ1213には、たとえば、レーザプリンタやインクジェットプリンタを採用することができる。   The scanner 1212 optically reads an image and takes in image data into the image processing apparatus. The scanner 1212 may have an OCR (Optical Character Reader) function. The printer 1213 prints image data and document data. As the printer 1213, for example, a laser printer or an ink jet printer can be employed.

(画像処理装置の機能的構成)
図13は、実施の形態4にかかる画像処理装置の機能的構成を示すブロック図である。画像処理装置1300は、差分値算出部1301と、第1の直交変換部1302と、第2の直交変換部1303と、係数値算出部1304と、係数差分値算出部1305と、絶対値演算部1306と、総和演算部1307と、二次元直交変換部1308とを含む構成である。各機能(差分値算出部1301部〜二次元直交変換部1308)は、具体的には、たとえば、図12に示したROM1202、RAM1203、磁気ディスク1205、光ディスク1207などの記憶装置に記憶されたプログラムをCPU1201に実行させることにより、または、I/F1209により、各機能を実現する。
(Functional configuration of image processing apparatus)
FIG. 13 is a block diagram of a functional configuration of the image processing apparatus according to the fourth embodiment. The image processing apparatus 1300 includes a difference value calculation unit 1301, a first orthogonal transformation unit 1302, a second orthogonal transformation unit 1303, a coefficient value calculation unit 1304, a coefficient difference value calculation unit 1305, and an absolute value calculation unit. 1306, a sum operation unit 1307, and a two-dimensional orthogonal transform unit 1308. Specifically, each function (difference value calculation unit 1301 to two-dimensional orthogonal transformation unit 1308) is, for example, a program stored in a storage device such as the ROM 1202, the RAM 1203, the magnetic disk 1205, and the optical disk 1207 shown in FIG. Are executed by the CPU 1201 or by the I / F 1209.

ここで、N×N画素を1ブロックとする。また、実施の形態4では、参照画像内で前ベクトルにより示される第1の予測ブロックを横方向に+1シフトした場合の現ベクトルにより示される第2の予測ブロックの二次元直交変換処理に関して説明する。また、本実施の形態4では、動きベクトル候補に関する絶対値差分和(SATD)を算出する処理のみを説明する。   Here, N × N pixels are defined as one block. In the fourth embodiment, the two-dimensional orthogonal transform process of the second prediction block indicated by the current vector when the first prediction block indicated by the previous vector in the reference image is shifted +1 in the horizontal direction will be described. . In the fourth embodiment, only the process of calculating the sum of absolute value differences (SATD) related to motion vector candidates will be described.

まず、二次元直交変換部1308は、参照画像内で前ブロックにより示される第1の予測ブロックをN×N要素の変換係数行列を用いて二次元直交変換する機能を有する。具体的には、たとえば、第1の予測ブロックに関する画素値行列に上述のT1を左からかけてT2を右からかけることで第1の予測ブロックに関する第1の変換係数行列を算出する。   First, the two-dimensional orthogonal transform unit 1308 has a function of performing two-dimensional orthogonal transform on the first prediction block indicated by the previous block in the reference image using an N × N element transform coefficient matrix. Specifically, for example, the first transform coefficient matrix related to the first prediction block is calculated by multiplying the pixel value matrix related to the first prediction block by T1 from the left and T2 from the right.

さらに、二次元直交変換部1308は、原画像内で対象となる第3のブロック(上述では対象ブロック)をN×N要素の変換係数行列を用いて二次元直交変換する機能を有する。具体的には、たとえば、対象ブロックに関する画素値行列に上述のT1を左からかけてT2を右からかけることで対象ブロックに関する第3の変換係数行列を算出する。   Further, the two-dimensional orthogonal transform unit 1308 has a function of performing a two-dimensional orthogonal transform on a third block (target block in the above description) in the original image using an N × N element transform coefficient matrix. Specifically, for example, the above-described T1 is applied from the left and T2 is applied from the right to the pixel value matrix related to the target block to calculate the third transform coefficient matrix related to the target block.

そして、係数差分値算出部1305は、二次元直交変換部により算出された原画像内の対象ブロックに関する第3の変換係数行列から二次元直交変換部により算出された参照画像内の第1の予測ブロックに関する第1の変換係数行列との係数差分値を算出する。   Then, the coefficient difference value calculation unit 1305 performs the first prediction in the reference image calculated by the two-dimensional orthogonal transformation unit from the third transformation coefficient matrix related to the target block in the original image calculated by the two-dimensional orthogonal transformation unit. A coefficient difference value with respect to the first transform coefficient matrix relating to the block is calculated.

そして、絶対値演算部1306は、係数差分値の絶対値を算出する機能を有する。さらに、総和演算部1307は、演算済の係数差分値内の要素の総和を算出して第1の絶対値差分和(SATD)を算出する。   The absolute value calculation unit 1306 has a function of calculating the absolute value of the coefficient difference value. Further, the sum calculation unit 1307 calculates the sum of elements in the calculated coefficient difference value to calculate a first absolute value difference sum (SATD).

つぎに、差分値算出部1301は、第2の予測ブロック内で前記第1の予測ブロックに重複していない第1の画素値行列と、第1の予測ブロック内で第2の予測ブロックに重複していない第2の画素値行列との差分となる差分値行列を算出する機能を有する。具体的には、たとえば、CPU1201が、Bc_lからBp_lを引くことで差分値行列を算出する。   Next, the difference value calculation unit 1301 overlaps the first pixel value matrix that does not overlap the first prediction block in the second prediction block and the second prediction block in the first prediction block. And a function of calculating a difference value matrix that is a difference from the second pixel value matrix that has not been performed. Specifically, for example, the CPU 1201 calculates a difference value matrix by subtracting Bp_l from Bc_l.

つぎに、第1の直交変換部1302は、差分値算出部1301により算出されたN×1要素の差分値行列をN×N要素の直交変換行列を用いて一次元直交変換してN×1要素の変換係数行列を算出する機能を有する。具体的には、たとてば、CPU1201が、差分値行列に左からN×N要素の直交変換行列を乗算することで一次元直交変換する。   Next, the first orthogonal transform unit 1302 performs one-dimensional orthogonal transform on the N × 1 element difference value matrix calculated by the difference value calculation unit 1301 using an N × N element orthogonal transform matrix, thereby obtaining N × 1. It has a function of calculating a conversion coefficient matrix of elements. Specifically, for example, the CPU 1201 performs one-dimensional orthogonal transformation by multiplying the difference value matrix by an orthogonal transformation matrix of N × N elements from the left.

第2の直交変換部1303は、第1の直交変換部1302により算出されたN×1要素の変換係数行列を、1×N要素の直交変換行列を用いて一次元直交変換してN×N要素の変換係数行列を算出する機能を有する。具体的には、たとえば、CPU1201が、差分値行列に右から1×N要素の直交変換行列を乗算することで一次元直交変換する。   The second orthogonal transformation unit 1303 performs one-dimensional orthogonal transformation on the N × 1 element transformation coefficient matrix calculated by the first orthogonal transformation unit 1302 using a 1 × N element orthogonal transformation matrix, and obtains N × N. It has a function of calculating a conversion coefficient matrix of elements. Specifically, for example, the CPU 1201 performs one-dimensional orthogonal transformation by multiplying the difference value matrix by an orthogonal transformation matrix of 1 × N elements from the right.

係数値算出部1304は、第1の予測ブロックに関するN×N要素の第1の変換係数行列と、第1の直交変換部1302により変換されたN×N要素の変換係数行列とに基づいて第2の予測ブロックに関するN×N要素の第2の変換係数行列を算出する機能を有する。   The coefficient value calculation unit 1304 is based on the N × N element first transform coefficient matrix related to the first prediction block and the N × N element transform coefficient matrix transformed by the first orthogonal transform unit 1302. A function of calculating a second transform coefficient matrix of N × N elements for two prediction blocks;

つぎに、係数差分値算出部1305は、二次元直交変換部により算出された原画像内の対象ブロックに関する第3の変換係数行列から係数値算出部1304により算出された参照画像内の第2の予測ブロックに関する第2の変換係数行列との係数差分値を算出する。   Next, the coefficient difference value calculation unit 1305 outputs the second value in the reference image calculated by the coefficient value calculation unit 1304 from the third conversion coefficient matrix related to the target block in the original image calculated by the two-dimensional orthogonal transformation unit. A coefficient difference value with respect to the second transform coefficient matrix related to the prediction block is calculated.

そして、絶対値演算部1306は、係数差分値の絶対値を算出する機能を有する。さらに、総和演算部1307は、演算済の係数差分値内の要素の総和を算出して第2の絶対値差分和(SATD)を算出する。   The absolute value calculation unit 1306 has a function of calculating the absolute value of the coefficient difference value. Further, the sum calculation unit 1307 calculates the sum of the elements in the calculated coefficient difference value to calculate a second absolute value difference sum (SATD).

つぎに、係数値算出部1304と、第1の直交変換部1302の詳細例と、係数差分値算出部1305の他の例を示す。   Next, detailed examples of the coefficient value calculation unit 1304 and the first orthogonal transform unit 1302 and other examples of the coefficient difference value calculation unit 1305 are shown.

(例1)
ここでは、N×N画素の第1の予測ブロックを、M(1<=M<N)要素シフトしたN×N画素の第2の予測ブロックの2次元直交変換について説明する。第1の直交変換部1302と係数値算出部1304以外の機能部については、上述と同一であるため説明を省略する。
(Example 1)
Here, the two-dimensional orthogonal transformation of the second prediction block of N × N pixels obtained by shifting the first prediction block of N × N pixels by M (1 <= M <N) elements will be described. Since the functional units other than the first orthogonal transform unit 1302 and the coefficient value calculation unit 1304 are the same as described above, the description thereof is omitted.

上記式(1)を例に挙げると、第1の直交変換部1302は、N×M要素の変換係数行列にM×N要素の直交変換行列を掛けることで、N×N要素の変換係数行列を算出する。   Taking the above equation (1) as an example, the first orthogonal transform unit 1302 multiplies an N × M element transform coefficient matrix by an M × N element orthogonal transform matrix to obtain an N × N element transform coefficient matrix. Is calculated.

つぎに、図14−1は、係数値算出部1304の詳細な構成を示す説明図(その1)である。係数値算出部1304は、加算部1401と入れ替え部1402によって構成されている。加算部1401は、第1の予測ブロックに関するN×N要素の第1の変換係数行列と、第1の直交変換部1302により変換されたN×N要素の変換係数行列とを加算する機能を有する。   Next, FIG. 14A is an explanatory diagram (part 1) of a detailed configuration of the coefficient value calculation unit 1304. The coefficient value calculation unit 1304 includes an addition unit 1401 and a replacement unit 1402. The adding unit 1401 has a function of adding the N × N element first transform coefficient matrix related to the first prediction block and the N × N element transform coefficient matrix transformed by the first orthogonal transform unit 1302. .

そして、入れ替え部1402は、第1の予測ブロックに関する加算後のN×N要素の変換係数行列に対してN×N要素の入れ替え行列を右から乗算することで第2の予測ブロックに関するN×N要素の第2の変換係数行列を算出する。   Then, the replacement unit 1402 multiplies the N × N element conversion coefficient matrix after the addition related to the first prediction block by the N × N element replacement matrix from the right to thereby calculate N × N related to the second prediction block. Calculate a second transform coefficient matrix of the elements.

(例2)
ここでは、直交変換行列(T1とT2)がアダマール変換行列の場合にN×N画素の第1の予測ブロックを、1要素シフトしたN×N画素の第2の予測ブロックの2次元直交変換について説明する。第1の直交変換部1302と係数値算出部1304以外の機能部については、上述と同一であるため説明を省略する。
(Example 2)
Here, when the orthogonal transformation matrix (T1 and T2) is a Hadamard transformation matrix, the two-dimensional orthogonal transformation of the second prediction block of N × N pixels obtained by shifting the first prediction block of N × N pixels by one element. explain. Since the functional units other than the first orthogonal transform unit 1302 and the coefficient value calculation unit 1304 are the same as described above, the description thereof is omitted.

図14−2は、第1の直交変換部1302の詳細な構成を示す説明図である。第1の直交変換部1302は、生成部1403と符号変換部1404によって構成されている。生成部1403は、第1の直交変換部1302により算出されたN×1要素の変換係数行列を、探索方向にN個並べることにより、N×N要素の変換係数行列を生成する。上記式(1)を例に挙げて詳細な処理を説明する。   FIG. 14B is an explanatory diagram of a detailed configuration of the first orthogonal transform unit 1302. The first orthogonal transform unit 1302 includes a generation unit 1403 and a code conversion unit 1404. The generation unit 1403 generates an N × N element transform coefficient matrix by arranging N N × 1 element transform coefficient matrices calculated by the first orthogonal transform unit 1302 in the search direction. Detailed processing will be described by taking the above formula (1) as an example.

具体的には、たとえば、CPU1201が、第1の直交変換部1302により算出されたN×1要素の変換係数行列をN−1個複製し、N×1要素の変換係数行列と複製したN−1個のN×1要素の変換係数行列を探索方向(ここでは、横方向)に並べる。   Specifically, for example, the CPU 1201 replicates N−1 transform coefficient matrices of N × 1 elements calculated by the first orthogonal transform unit 1302, and replicates N−1 transform coefficient matrices. One N × 1 element transform coefficient matrix is arranged in the search direction (here, the horizontal direction).

つぎに、符号変換部1404は、生成部1403により生成されたN×N要素の変換係数行列の符号を、1×N要素の直交変換行列(上記式(1)ではT2_u)に基づいて変換する。具体的には、たとえば、CPU1201が、T2_uの各要素はすべて「1」であるためN×N要素の変換係数行列の符号を変換せずに出力する。T2_dのように「−1」がある場合には、N×N要素の変換係数行列において対応する列ベクトルの符号を反転する。   Next, the code conversion unit 1404 converts the code of the N × N element conversion coefficient matrix generated by the generation unit 1403 based on the 1 × N element orthogonal conversion matrix (T2_u in the above equation (1)). . Specifically, for example, the CPU 1201 outputs all the elements of T2_u without conversion because the codes of the N × N element conversion coefficient matrix are all “1”. When there is “−1” as in T2_d, the sign of the corresponding column vector is inverted in the N × N element conversion coefficient matrix.

そして、係数値算出部1304は、第1の予測ブロックに関するN×N要素の第1の変換係数行列と、符号変換部1404により変換されたN×N要素の変換係数行列に基づいて、第2の予測ブロックに関するN×N要素の第2の変換係数行列を算出する。具体的には、例1の処理と同一である。   Then, the coefficient value calculation unit 1304 performs the second calculation based on the N × N element first conversion coefficient matrix related to the first prediction block and the N × N element conversion coefficient matrix converted by the code conversion unit 1404. A second transformation coefficient matrix of N × N elements related to the prediction block is calculated. Specifically, it is the same as the processing in Example 1.

(例3)
ここでは、例2と同一条件であるが、処理の異なる例を示す。第1の直交変換部1302と係数値算出部1304以外の機能部については、上述と同一であるため説明を省略する。
(Example 3)
Here, although the same conditions as Example 2 are shown, an example of a different process is shown. Since the functional units other than the first orthogonal transform unit 1302 and the coefficient value calculation unit 1304 are the same as described above, the description thereof is omitted.

第1の直交変換部1302は、生成部1403によって構成されている。生成部1403は、第1の直交変換部1302により算出されたN×1要素の変換係数行列を、探索方向にN個並べることにより、N×N要素の変換係数行列を生成する。生成部1403の処理については、例2と同一であるため説明を省略する。   The first orthogonal transform unit 1302 is configured by a generation unit 1403. The generation unit 1403 generates an N × N element transform coefficient matrix by arranging N N × 1 element transform coefficient matrices calculated by the first orthogonal transform unit 1302 in the search direction. Since the processing of the generation unit 1403 is the same as that in Example 2, description thereof is omitted.

つぎに、図14−3は、係数値算出部1304の詳細な構成を示す説明図(その2)である。係数値算出部1304は、加減算部1405と入れ替え部1406により構成されている。加減算部1405は、第1の予測ブロックに関するN×N要素の第1の変換係数行列と生成部1403により生成されたN×N要素の変換係数行列とを、当該N×N要素の変換係数行列に対応する1×N要素の直交変換行列内の要素が1の場合、加算し、−1の場合、減算する。   FIG. 14C is an explanatory diagram (part 2) of the detailed configuration of the coefficient value calculation unit 1304. The coefficient value calculation unit 1304 includes an addition / subtraction unit 1405 and an exchange unit 1406. The addition / subtraction unit 1405 converts the N × N element first transform coefficient matrix related to the first prediction block and the N × N element transform coefficient matrix generated by the generation unit 1403 into the N × N element transform coefficient matrix. When the element in the orthogonal transformation matrix of 1 × N elements corresponding to is 1, addition is performed, and when the element is −1, subtraction is performed.

そして、入れ替え部1406は、加減算部1405により加減算されたN×N要素の変換係数行列に対してN×N要素の入れ替え行列を乗算し、第2の予測ブロックに関する第2の変換係数行列を算出する。加減算部1405と入れ替え部1406については、実施の形態3で説明した処理と同一であるため詳細な説明を省略する。   Then, the replacement unit 1406 multiplies the N × N element conversion coefficient matrix added / subtracted by the addition / subtraction unit 1405 by the N × N element replacement matrix to calculate a second conversion coefficient matrix related to the second prediction block. To do. Since the addition / subtraction unit 1405 and the replacement unit 1406 are the same as the processing described in the third embodiment, detailed description thereof is omitted.

(例4)
ここでは、Nが4であり、直交変換行列(T1とT2)が、アダマール変換の場合について説明する。なお、例1で示した入れ替え部1402についてのみが異なるため、他の機能部については、説明を省略する。
(Example 4)
Here, a case where N is 4 and the orthogonal transformation matrices (T1 and T2) are Hadamard transforms will be described. Since only the replacement unit 1402 shown in Example 1 is different, description of other functional units is omitted.

入れ替え部1402は、加算部1401により加算されたN×N要素の変換係数行列を、N×N要素の入れ替え行列に基づいて行または列の順序を入れ替え、入れ替え後のN×N要素の変換係数行列内の行または列ごとにN×N要素の入れ替え行列に基づいて符号を変換して、第2の予測ブロックに関する第2の変換係数行列を算出する。具体的には、図6−1〜図6−4で示した処理と同一であるため説明を省略する。   The replacement unit 1402 replaces the N × N element conversion coefficient matrix added by the addition unit 1401 with the row or column order based on the N × N element replacement matrix, and the N × N element conversion coefficient after the replacement. The code is converted based on the permutation matrix of N × N elements for each row or column in the matrix to calculate a second conversion coefficient matrix for the second prediction block. Specifically, since it is the same as the processing shown in FIGS.

(例5)
ここでは、例4と同一条件であるが、処理の異なる例を示す。例4で示した入れ替え部1402と係数差分値算出部1305以外の機能部については、上述と同一であるため説明を省略する。
(Example 5)
Here, although the same conditions as Example 4 are shown, an example of a different process is shown. Since the functional units other than the switching unit 1402 and the coefficient difference value calculating unit 1305 shown in Example 4 are the same as described above, the description thereof will be omitted.

入れ替え部1402は、加算部1401により加算されたN×N要素の変換係数行列を、N×N要素の入れ替え行列に基づいて行または列の順序を入れ替える。具体的には、図6−1〜図6−4で示した処理のうち、行列の入れ替えに関する処理と同一であるため説明を省略する。   The replacement unit 1402 switches the order of the rows or columns of the N × N element conversion coefficient matrix added by the addition unit 1401 based on the N × N element replacement matrix. Specifically, among the processes shown in FIGS. 6-1 to 6-4, the process is the same as the process related to matrix replacement, and thus the description thereof is omitted.

係数差分値算出部1305は、原画像内の対象ブロックに関する第3の変換係数行列に入れ替え部1402により入れ替えられたN×N要素の変換係数行列を、当該N×N要素の変換係数行列に対応する入れ替え行列の値が1の場合には減算し、−1の場合には加算することで係数差分値量列を算出する。具体的な処理例については、実施の形態3で示した例と同一であるため説明を省略する。   The coefficient difference value calculation unit 1305 corresponds to the N × N element conversion coefficient matrix replaced by the third conversion coefficient matrix related to the target block in the original image by the replacement unit 1402. When the value of the replacement matrix to be calculated is 1, subtraction is performed, and when the replacement matrix is −1, addition is performed to calculate a coefficient difference value amount sequence. Since a specific processing example is the same as the example shown in the third embodiment, the description thereof is omitted.

(画像処理装置による画像処理手順)
図15は、画像処理装置による画像処理手順の一例を示すフローチャートである。ここでは、動きベクトルの探索方法がスパイラルサーチの場合を例に挙げて説明する。実施の形態1で説明したようにスパイラルサーチの場合、参照画像内で探索開始点での予測ブロックのみ従来の二次元直交変換を施せばよい。まず、画像処理装置が、次の動きベクトル候補を現ベクトルに決定し(ステップS1501)、最初のベクトルか否かを判断する(ステップS1502)。最初のベクトルか否かとは、探索開始点であるか否かを示している。
(Image processing procedure by image processing device)
FIG. 15 is a flowchart illustrating an example of an image processing procedure performed by the image processing apparatus. Here, a case where the motion vector search method is a spiral search will be described as an example. As described in the first embodiment, in the case of spiral search, the conventional two-dimensional orthogonal transformation only needs to be performed on the prediction block at the search start point in the reference image. First, the image processing apparatus determines the next motion vector candidate as the current vector (step S1501), and determines whether it is the first vector (step S1502). Whether or not it is the first vector indicates whether or not it is a search start point.

つぎに、画像処理装置が、最初のベクトルであると判断した場合(ステップS1502:Yes)、第1の二次元直交変換処理を実施する(ステップS1503)。一方、画像処理装置が、最初のベクトルでないと判断した場合(ステップS1502:No)、第2の二次元直交変換処理を実施する(ステップS1504)。   Next, when the image processing apparatus determines that the vector is the first vector (step S1502: Yes), the first two-dimensional orthogonal transformation process is performed (step S1503). On the other hand, when the image processing apparatus determines that the vector is not the first vector (step S1502: No), the second two-dimensional orthogonal transformation process is performed (step S1504).

ステップS1503、またはステップS1504のつぎに、画像処理装置が、各差分の絶対値を算出し(ステップS1506)、絶対値の総和(SATD)を算出し(ステップS1507)、格納する(ステップS1508)。   After step S1503 or step S1504, the image processing apparatus calculates the absolute value of each difference (step S1506), calculates the sum of absolute values (SATD) (step S1507), and stores it (step S1508).

そして、画像処理装置が、探索終了条件を満たしたか否かを判断し(ステップS1509)、満たしていないと判断した場合(ステップS1509:No)、ステップS1501に戻り、満たしたと判断した場合(ステップS1509:Yes)、一連の処理を終了する。   Then, the image processing apparatus determines whether or not the search end condition is satisfied (step S1509). When it is determined that the search end condition is not satisfied (step S1509: No), the process returns to step S1501 and when it is determined that it is satisfied (step S1509). : Yes), a series of processing ends.

つぎに、図16は、図15で示した第1の二次元直交変換処理(ステップS1503)の詳細な説明を示すフローチャートである。ここでは、二次元直交変換の変換行列については、アダマール変換行列であっても他の変換行列であっても処理は同一である。まず、画像処理装置が、原画像内の対象ブロックを二次元直交変換し(ステップS1601)、対象ブロックに関する変換係数行列を格納する(ステップS1602)。   Next, FIG. 16 is a flowchart showing a detailed description of the first two-dimensional orthogonal transform process (step S1503) shown in FIG. Here, regarding the transformation matrix of the two-dimensional orthogonal transformation, the processing is the same regardless of whether it is a Hadamard transformation matrix or another transformation matrix. First, the image processing apparatus performs two-dimensional orthogonal transform on the target block in the original image (step S1601), and stores a transform coefficient matrix related to the target block (step S1602).

つぎに、画像処理装置が、参照画像内で現ベクトルにより示される予測ブロックを二次元直交変換し(ステップS1603)、予測ブロックに関する変換係数行列を格納する(ステップS1604)。そして、画像処理装置が、対象ブロックに関する変換係数行列と予測ブロックに関する変換係数行列との差を算出し(ステップS1605)、ステップS1506に移行する。   Next, the image processing apparatus performs two-dimensional orthogonal transform on the prediction block indicated by the current vector in the reference image (step S1603), and stores a transform coefficient matrix related to the prediction block (step S1604). Then, the image processing apparatus calculates the difference between the transform coefficient matrix related to the target block and the transform coefficient matrix related to the prediction block (step S1605), and proceeds to step S1506.

つぎに、図17は、図15で示した第2の二次元直交変換処理(ステップS1504)の詳細な説明を示すフローチャートである。まず、画像処理装置が、第1の画素値行列と第2の画素値行列を取得し(ステップS1701)、第1の画素値行列と第2の画素値行列との差分を算出する(ステップS1702)。つぎに、画像処理装置が、N×Nの変換行列を用いて差分値行列を一次元直交変換し(ステップS1703)、1×Nの変換係数行列を用いて一次元直交変換後のN×1の変換係数行列を一次元直交変換する(ステップS1704)。   Next, FIG. 17 is a flowchart showing a detailed description of the second two-dimensional orthogonal transformation process (step S1504) shown in FIG. First, the image processing apparatus acquires a first pixel value matrix and a second pixel value matrix (step S1701), and calculates a difference between the first pixel value matrix and the second pixel value matrix (step S1702). ). Next, the image processing apparatus performs one-dimensional orthogonal transformation of the difference value matrix using the N × N transformation matrix (step S1703), and N × 1 after the one-dimensional orthogonal transformation using the 1 × N transformation coefficient matrix. Are transformed by one-dimensional orthogonal transformation (step S1704).

そして、画像処理装置が、現ベクトルによって示される予測ブロックに関する直交変換係数行列を算出し(ステップS1705)、格納する(ステップS1706)。つぎに、画像処理装置が、対象ブロックに関する変換係数と予測ブロックに関する変換係数との差を算出し(ステップS1707)、ステップS1506に移行する。   Then, the image processing apparatus calculates an orthogonal transform coefficient matrix related to the prediction block indicated by the current vector (step S1705) and stores it (step S1706). Next, the image processing apparatus calculates the difference between the transform coefficient related to the target block and the transform coefficient related to the prediction block (step S1707), and proceeds to step S1506.

図18は、図15で示した第2の二次元直交変換処理(ステップS1505)の詳細な説明を示すフローチャートである。ここでは、N=4、M=1、かつ変換行列がアダマール行列の場合において、従来と比較して演算量が削減されていることを示す。まず、画像処理装置が、第1の画素値行列と第2の画素値行列を取得し(ステップS1801)、第1の画素値行列と第2の画素値行列との差分を算出する(ステップS1802)。つぎに、画像処理装置が、N×Nの変換行列を用いて差分値行列を一次元直交変換し(ステップS1803)、ベクトルを複製してN×Nの変換係数行列を生成する(ステップS1804)。   FIG. 18 is a flowchart showing a detailed description of the second two-dimensional orthogonal transform process (step S1505) shown in FIG. Here, in the case where N = 4, M = 1, and the transformation matrix is a Hadamard matrix, it is shown that the amount of calculation is reduced compared to the conventional case. First, the image processing apparatus acquires a first pixel value matrix and a second pixel value matrix (step S1801), and calculates a difference between the first pixel value matrix and the second pixel value matrix (step S1802). ). Next, the image processing apparatus performs one-dimensional orthogonal transformation of the difference value matrix using the N × N transformation matrix (step S1803), and duplicates the vector to generate an N × N transformation coefficient matrix (step S1804). .

そして、画像処理装置が、符号変換し(ステップS1805)、現ベクトルによって示される予測ブロックに関する直交変換係数行列を算出し(ステップS1806)、格納する(ステップS1807)。つぎに、画像処理装置が、対象ブロックに関する変換係数と予測ブロックに関する変換係数との差を算出し(ステップS1808)、ステップS1506に移行する。   Then, the image processing apparatus performs code conversion (step S1805), calculates an orthogonal transformation coefficient matrix related to the prediction block indicated by the current vector (step S1806), and stores it (step S1807). Next, the image processing apparatus calculates the difference between the transform coefficient related to the target block and the transform coefficient related to the prediction block (step S1808), and proceeds to step S1506.

ここで、N=4、M=1、かつ変換行列がアダマール行列の場合において、従来と比較して演算量が削減されていることを示す。   Here, in the case where N = 4, M = 1, and the transformation matrix is a Hadamard matrix, it indicates that the amount of calculation is reduced as compared with the conventional case.

まず、従来について演算量を記載する。
・アダマール変換:減算16回
・二次元アダマール変換:T1、T2のそれぞれで32回の加減算。合計64回の加減算
・絶対値演算:16回
・加算:15回
First, the amount of calculation is described for the conventional case.
Hadamard transformation: subtraction 16 times. Two-dimensional Hadamard transformation: 32 additions and subtractions for each of T1 and T2. Total 64 times addition / subtraction ・ Absolute value calculation: 16 times ・ Addition: 15 times

一方、本発明では、以下のようになる。
・原画像内の対象ブロックおよび少なくとも参照画像内の探索点のブロックについての二次元アダマール変換:従来と同様の64回の加減算
・参照画像内の他のブロック:第1の画素値と第2の画素値の減算4回、アダマール変換の加減算8回、前ベクトル変換結果との加減算16回
・対象ブロックとの差分値算出処理:加減算16回
・絶対値算出処理:絶対値演算16回
・総和:加算15回
On the other hand, the present invention is as follows.
Two-dimensional Hadamard transform for the target block in the original image and at least the block of the search point in the reference image: 64 additions and subtractions as in the prior art Other blocks in the reference image: first pixel value and second block Pixel value subtraction 4 times, Hadamard transform addition / subtraction 8 times, previous vector conversion result addition / subtraction 16 times ・ Difference value calculation process with target block: addition / subtraction 16 times ・ Absolute value calculation process: Absolute value calculation 16 times ・ Total: 15 additions

探索方法としてスパイラルサーチを例に挙げると、マクロブロックごとに20個のベクトルについての評価を行った場合、加減算数は、従来のSATD算出では30400回であるが、本発明では19264回となり、演算量が削減される。絶対値演算は、従来も本発明であっても5120回である。   Taking a spiral search as an example of the search method, when 20 vectors are evaluated for each macroblock, the number of additions / subtractions is 30400 in the conventional SATD calculation, but 19264 in the present invention. The amount is reduced. The absolute value calculation is 5120 times in the conventional and the present invention.

以上説明したように、画像処理装置、画像処理方法、および画像処理プログラムによれば、第1および第2の予測ブロックでの非重複領域の差分値を直交変換の対象行列として直交変換をおこない、第1の予測ブロックに関する変換係数行列を用いて補完する。これにより、対象行列および変換行列の要素数が減り、演算量を削減することができる。   As described above, according to the image processing device, the image processing method, and the image processing program, the orthogonal transformation is performed by using the difference value of the non-overlapping regions in the first and second prediction blocks as the orthogonal transformation target matrix, It complements using the conversion factor matrix regarding a 1st prediction block. Thereby, the number of elements of the target matrix and the transformation matrix is reduced, and the amount of calculation can be reduced.

また、M=1であり、直交変換行列がアダマール変換行列の場合、第2の直交変換処理の際に第1の直交変換処理で得られる変換係数行列を探索方向にN個並べて、直交変換係数行列に基づいて符号を変換することで演算量を削減することができる。   When M = 1 and the orthogonal transform matrix is a Hadamard transform matrix, N transform coefficient matrices obtained by the first orthogonal transform process are arranged in the search direction during the second orthogonal transform process, and the orthogonal transform coefficients are arranged. The amount of calculation can be reduced by converting the code based on the matrix.

また、差分値が直交変換された変換係数行列と第1の予測ブロックに関する変換係数行列とを加算し、加算後の変換係数行列に対して行列の入れ替えに関する入れ替え行列を乗算することで第2の予測ブロックに関する第2の変換係数行列を算出できる。これにより、差分値のみの直交変換によって要素数が減ることで、演算量を削減することができる。   Further, the transform coefficient matrix obtained by orthogonally transforming the difference value and the transform coefficient matrix related to the first prediction block are added, and the second transform coefficient matrix is multiplied by the replacement matrix related to matrix replacement by the added transform coefficient matrix. A second transform coefficient matrix for the prediction block can be calculated. Thereby, the amount of calculation can be reduced by reducing the number of elements by orthogonal transformation of only the difference value.

また、M=1であり、直交変換行列がアダマール変換行列の場合、第2の直交変換処理の際に第1の直交変換処理で得られる変換係数行列を探索方向にN個並べる。そして、並べたN×Nの変換係数行列と第1の変換係数行列とを、直交変換係数行列に基づいて加算または減算することで演算量を削減することができる。   When M = 1 and the orthogonal transform matrix is a Hadamard transform matrix, N transform coefficient matrices obtained by the first orthogonal transform process are arranged in the search direction during the second orthogonal transform process. The amount of calculation can be reduced by adding or subtracting the arranged N × N transform coefficient matrix and the first transform coefficient matrix based on the orthogonal transform coefficient matrix.

また、Nが4であり、直交変換行列が、アダマール変換行列の場合、第1の変換係数行列との加算後の変換係数行列を、入れ替え行列に基づいて行または列の順序を入れ替え、入れ替え行列に基づいて符号を変換することで第2の変換係数行列を算出する。これにより、加算後の変換係数行列と入れ替え行列との加減算を行わずに第2の変換係数行列を算出できるため、演算量を減らすことができる。   Further, when N is 4 and the orthogonal transformation matrix is a Hadamard transformation matrix, the transformation coefficient matrix after addition with the first transformation coefficient matrix is replaced based on the replacement matrix, and the order of the rows or columns is changed. The second conversion coefficient matrix is calculated by converting the code based on the above. As a result, the second conversion coefficient matrix can be calculated without performing addition / subtraction between the conversion coefficient matrix after the addition and the replacement matrix, thereby reducing the amount of calculation.

また、原画像内の対象ブロックに関する第3の変換係数行列の第2の予測ブロックに関する第2の変換係数行列との差分値を算出し、絶対値演算後に総和を算出することで、SATDを算出する。これにより、SATD算出に関する演算量を削減できる。   Also, the difference between the third transform coefficient matrix related to the target block in the original image and the second transform coefficient matrix related to the second prediction block is calculated, and the sum is calculated after the absolute value calculation, thereby calculating SATD. To do. Thereby, the calculation amount regarding SATD calculation can be reduced.

また、Nが4であり、直交変換行列が、アダマール変換行列の場合、第1の変換係数行列との加算後の変換係数行列を、入れ替え行列に基づいて行または列の順序を入れ替え、第3の変換係数行列の第2の予測ブロックに関する第2の変換係数行列との差分値を、
入れ替え行列に基づいて加算または減算することで、演算量を削減できる。
Further, when N is 4 and the orthogonal transformation matrix is a Hadamard transformation matrix, the transformation coefficient matrix after addition with the first transformation coefficient matrix is replaced based on the replacement matrix, and the order of the rows or columns is changed. A difference value between the transform coefficient matrix of the second transform coefficient matrix related to the second prediction block and
The amount of calculation can be reduced by adding or subtracting based on the replacement matrix.

なお、本実施の形態で説明した画像処理方法は、予め用意されたプログラムをパーソナル・コンピュータやワークステーション等のコンピュータで実行することにより実現することができる。本画像処理プログラムは、ハードディスク、フレキシブルディスク、CD−ROM、MO、DVD等のコンピュータで読み取り可能な記録媒体に記録され、コンピュータによって記録媒体から読み出されることによって実行される。また本画像処理プログラムは、インターネット等のネットワークを介して配布してもよい。   The image processing method described in the present embodiment can be realized by executing a program prepared in advance on a computer such as a personal computer or a workstation. The image processing program is recorded on a computer-readable recording medium such as a hard disk, a flexible disk, a CD-ROM, an MO, and a DVD, and is executed by being read from the recording medium by the computer. The image processing program may be distributed via a network such as the Internet.

また、実施の形態4で説明した画像処理装置1300は、スタンダードセルやストラクチャードASIC(Application Specific Integrated Circuit)などの特定用途向けIC(以下、単に「ASIC」と称す。)やFPGAなどのPLD(Programmable Logic Device)によっても実現することができる。具体的には、たとえば、上述した画像処理装置1300の機能(差分値算出部1301〜二次元直行変換部1308)をHDL記述によって機能定義し、機能定義されたHDL記述を論理合成してASICやPLDに与えることにより、画像処理装置1300を製造することができる。   In addition, the image processing apparatus 1300 described in the fourth embodiment includes an application-specific IC (hereinafter simply referred to as “ASIC”) such as a standard cell or a structured ASIC (Application Specific Integrated Circuit), or a PLD (Programmable) such as an FPGA. It can also be realized by Logic Device). Specifically, for example, the functions of the image processing apparatus 1300 described above (difference value calculation unit 1301 to two-dimensional direct conversion unit 1308) are defined by HDL description, and the HDL description defined by the function is logically synthesized to perform ASIC or By giving to the PLD, the image processing apparatus 1300 can be manufactured.

また、実施の形態4で説明した画像処理装置1300の機能(差分値算出部1301〜二次元直行変換部1308)の一部のみを、ASICやFPGAなどのPLDによって実現してもよい。   In addition, only a part of the functions (difference value calculation unit 1301 to two-dimensional orthogonal conversion unit 1308) of the image processing apparatus 1300 described in the fourth embodiment may be realized by a PLD such as an ASIC or FPGA.

上述した実施の形態に関し、さらに以下の付記を開示する。   The following additional notes are disclosed with respect to the embodiment described above.

(付記1)画像内のN×N要素の第1のブロックが任意の探索方向にM(1≦M<N/2)要素シフトしたN×N要素の第2のブロックの二次元直交変換を実行する画像処理装置であって、
前記第2のブロック内で前記第1のブロックに重複していない第1の特徴量行列と、前記第1のブロック内で前記第2のブロックに重複していない第2の特徴量行列との差分となる差分値行列を算出する差分値算出手段と、
前記差分値算出手段により算出されたN×M要素の差分値行列を、N×N要素の直交変換行列を用いて一次元直交変換して、N×M要素の変換係数行列を算出する第1の直交変換手段と、
前記第1の直交変換手段により算出されたN×M要素の変換係数行列を、M×N要素の直交変換行列を用いて一次元直交変換して、N×N要素の変換係数行列を算出する第2の直交変換手段と、
前記第1のブロックに関するN×N要素の第1の変換係数行列と、前記第2の直交変換手段により変換されたN×N要素の変換係数行列とに基づいて、前記第2のブロックに関するN×N要素の第2の変換係数行列を算出する係数値算出手段と、
を備えることを特徴とする画像処理装置。
(Supplementary Note 1) Two-dimensional orthogonal transformation of a second block of N × N elements obtained by shifting the first block of N × N elements in the image by M (1 ≦ M <N / 2) elements in an arbitrary search direction. An image processing apparatus to execute,
A first feature matrix that does not overlap the first block in the second block, and a second feature matrix that does not overlap the second block in the first block. A difference value calculating means for calculating a difference value matrix as a difference;
First, the N × M element difference value matrix calculated by the difference value calculating means is subjected to one-dimensional orthogonal transformation using an N × N element orthogonal transformation matrix to calculate an N × M element transformation coefficient matrix. Orthogonal transformation means,
The N × M element transform coefficient matrix calculated by the first orthogonal transform unit is subjected to one-dimensional orthogonal transform using the M × N element orthogonal transform matrix to calculate an N × N element transform coefficient matrix. A second orthogonal transform means;
Based on the first transform coefficient matrix of N × N elements related to the first block and the transform coefficient matrix of N × N elements transformed by the second orthogonal transform unit, N related to the second block A coefficient value calculating means for calculating a second transform coefficient matrix of × N elements;
An image processing apparatus comprising:

(付記2)M=1、かつ前記N×N要素の直交変換行列がアダマール変換行列、かつ前期M×N要素の変換行列が前記アダマール変換行列の一部を取り出した行列であり、
前記第2の直交変換手段は、
前記第1の直交変換手段により算出されたN×M要素の変換係数行列を前記探索方向にN個並べることにより、N×N要素の変換係数行列を生成する生成手段と、
前記生成手段により生成されたN×N要素の変換係数行列内の各要素の符号を、前記M×N要素の直交変換行列に基づいて変換する符号変換手段と、を備え、
前記係数値算出手段は、
前記第1のブロックに関するN×N要素の第1の変換係数行列と、前記符号変換手段により符号が変換されたN×N要素の変換係数行列とに基づいて、前記第2のブロックに関するN×N要素の第2の変換係数行列を算出することを特徴とする付記1に記載の画像処理装置。
(Supplementary Note 2) M = 1, the N × N element orthogonal transformation matrix is a Hadamard transformation matrix, and the previous M × N element transformation matrix is a matrix obtained by extracting a part of the Hadamard transformation matrix,
The second orthogonal transform means includes:
Generating means for generating an N × N element transform coefficient matrix by arranging N N × M element transform coefficient matrices calculated by the first orthogonal transform means in the search direction;
Code conversion means for converting the code of each element in the N × N element conversion coefficient matrix generated by the generation means based on the M × N element orthogonal conversion matrix;
The coefficient value calculating means includes
Based on the N × N element first transform coefficient matrix related to the first block and the N × N element transform coefficient matrix whose code has been converted by the code conversion means, N × N elements related to the second block. The image processing apparatus according to appendix 1, wherein a second transformation coefficient matrix of N elements is calculated.

(付記3)前記係数値算出手段は、
前記N×N要素の第1の変換係数行列と前記第2の直交変換手段により変換されたN×N要素の変換係数行列とを加算する加算手段と、
前記第2のブロックに関するN×N要素の第2の変換係数行列を、前記加算手段により加算されたN×N要素の変換係数行列とN×N要素の入れ替え行列との乗算により算出する入れ替え手段と、
を備えることを特徴とする付記1または2に記載の画像処理装置。
(Supplementary Note 3) The coefficient value calculating means includes:
Adding means for adding the N × N element first transform coefficient matrix and the N × N element transform coefficient matrix transformed by the second orthogonal transform means;
Replacement means for calculating a second transformation coefficient matrix of N × N elements related to the second block by multiplying the transformation coefficient matrix of N × N elements added by the addition means and a replacement matrix of N × N elements. When,
The image processing apparatus according to appendix 1 or 2, further comprising:

(付記4)M=1、かつ前記N×N要素の直交変換行列および前記M×N要素の直交変換行列が、アダマール変換行列であり、
前記第2の直交変換手段は、
前記第1の直交変換手段により算出されたN×M要素の変換係数行列を前記探索方向にN個並べることにより、N×N要素の変換係数行列を生成し、
前記係数値算出手段は、
前記第1のブロックに関するN×N要素の第1の変換係数行列と前記第2の直交変換手段により生成されたN×N要素の変換係数行列とを、当該N×N要素の変換係数行列に対応する前記M×N要素の直交変換行列内の要素が1の場合、加算し、−1の場合、減算する加減算手段と、
前記第2のブロックに関するN×N要素の第2の変換係数行列を、前記加減算手段により加減算されたN×N要素の変換係数行列に対してN×N要素の入れ替え行列との乗算により算出する入れ替え手段と、を備えることを特徴とする付記1に記載の画像処理装置。
(Supplementary note 4) M = 1, and the orthogonal transformation matrix of N × N elements and the orthogonal transformation matrix of M × N elements are Hadamard transformation matrices,
The second orthogonal transform means includes:
An N × N element transform coefficient matrix is generated by arranging N transform coefficient matrices calculated by the first orthogonal transform means in the search direction,
The coefficient value calculating means includes
The N × N element first transform coefficient matrix related to the first block and the N × N element transform coefficient matrix generated by the second orthogonal transform means are converted into the N × N element transform coefficient matrix. Addition / subtraction means for adding when the corresponding element in the orthogonal transformation matrix of the M × N element is 1, and for subtracting when the element is −1,
An N × N element second transformation coefficient matrix related to the second block is calculated by multiplying the N × N element transformation coefficient matrix added / subtracted by the addition / subtraction means with an N × N element replacement matrix. The image processing apparatus according to appendix 1, further comprising: replacement means.

(付記5)N=4、かつ前記N×N要素の直交変換行列および前記M×N要素の直交変換行列が、アダマール変換行列であり、
前記入れ替え手段は、
前記加算手段により加算されたN×N要素の変換係数行列の行または列の順序をN×N要素の入れ替え行列に基づく入れ替え、および入れ替え後のN×N要素の変換係数行列内の行または列ごとに要素の符号を前記入れ替え行列に基づく変換により前記第2のブロックに関するN×N要素の第2の変換係数行列を算出することを特徴とする付記3または4に記載の画像処理装置。
(Supplementary Note 5) N = 4, and the N × N element orthogonal transform matrix and the M × N element orthogonal transform matrix are Hadamard transform matrices,
The replacement means includes
The order of the rows or columns of the N × N element conversion coefficient matrix added by the adding means is replaced based on the N × N element replacement matrix, and the row or column in the N × N element conversion coefficient matrix after the replacement. 5. The image processing apparatus according to appendix 3 or 4, wherein a second transform coefficient matrix of N × N elements related to the second block is calculated by transforming the element code for each element based on the replacement matrix.

(付記6)前記画像と異なる画像内のN×N要素の第3のブロックに関する第3の変換係数行列と前記係数値算出手段により算出された第2の変換係数行列との差分となる係数差分値行列を算出する係数差分値算出手段と、
前記係数差分値算出手段により算出された係数差分値行列の絶対値を算出する絶対値演算手段と、
前記絶対値演算手段により算出された絶対値行列内の要素の総和を算出する総和演算手段と、
を備えることを特徴とする付記1〜5のいずれか1つに記載の画像処理装置。
(Supplementary Note 6) Coefficient difference that is the difference between the third transform coefficient matrix relating to the third block of N × N elements in the image different from the image and the second transform coefficient matrix calculated by the coefficient value calculating means Coefficient difference value calculating means for calculating a value matrix;
Absolute value calculating means for calculating an absolute value of the coefficient difference value matrix calculated by the coefficient difference value calculating means;
A sum calculating means for calculating a sum of elements in the absolute value matrix calculated by the absolute value calculating means;
The image processing apparatus according to any one of appendices 1 to 5, further comprising:

(付記7)N=4、かつ前記N×N要素の直交変換行列および前記M×N要素の直交変換行列が、アダマール変換行列であり、さらに、
前記画像と異なる画像内のN×N要素の第3のブロックに関する第3の変換係数行列に対して前記入れ替え手段により入れ替えられた4×4要素の変換係数行列を当該変換係数行列に対応する前記4×4要素の入れ替え行列の要素が1の場合の減算、当該要素が−1の場合の加算により係数差分値行列を算出する係数差分値算出手段と、
前記係数差分値算出手段により算出された係数差分値行列の絶対値を算出する絶対値演算手段と、
前記絶対値演算手段により算出された絶対値行列内の要素の総和を算出する総和演算手段と、を備え、
前記入れ替え手段は、
前記加算手段により加算されたN×N要素の変換係数行列を、前記N×N要素の入れ替え行列に基づいて行または列の順序を入れ替えることを特徴とする付記3または4に記載の画像処理装置。
(Supplementary Note 7) N = 4, and the orthogonal transformation matrix of N × N elements and the orthogonal transformation matrix of M × N elements are Hadamard transformation matrices, and
The 4 × 4 element conversion coefficient matrix replaced by the replacement unit with respect to the third conversion coefficient matrix relating to the third block of N × N elements in an image different from the image corresponds to the conversion coefficient matrix. Coefficient difference value calculating means for calculating a coefficient difference value matrix by subtraction when the element of the 4 × 4 element replacement matrix is 1, and addition when the element is −1;
Absolute value calculating means for calculating an absolute value of the coefficient difference value matrix calculated by the coefficient difference value calculating means;
A sum calculating means for calculating a sum of elements in the absolute value matrix calculated by the absolute value calculating means,
The replacement means includes
The image processing apparatus according to appendix 3 or 4, wherein the N × N element transform coefficient matrix added by the adding means is switched in order of rows or columns based on the N × N element replacement matrix. .

(付記8)画像内のN×N要素の第1のブロックが任意の探索方向にM(1≦M<N/2)要素シフトしたN×N要素の第2のブロックの二次元直交変換を実行するコンピュータが、
前記第2のブロック内で前記第1のブロックに重複していない第1の特徴量行列と、前記第1のブロック内で前記第2のブロックに重複していない第2の特徴量行列との差分となる差分値行列を算出する差分値算出工程と、
前記差分値算出工程により算出されたN×M要素の差分値行列を、N×N要素の直交変換行列を用いて一次元直交変換して、N×M要素の変換係数行列を算出する第1の直交変換工程と、
前記第1の直交変換工程により算出されたN×M要素の変換係数行列を、M×N要素の直交変換行列を用いて一次元直交変換して、N×N要素の変換係数行列を算出する第2の直交変換工程と、
前記第1のブロックに関するN×N要素の第1の変換係数行列と、前記第2の直交変換工程により変換されたN×N要素の変換係数行列とに基づいて、前記第2のブロックに関するN×N要素の第2の変換係数行列を算出する係数値算出工程と、
を実行することを特徴とする画像処理方法。
(Supplementary Note 8) Two-dimensional orthogonal transformation of a second block of N × N elements obtained by shifting the first block of N × N elements in the image by M (1 ≦ M <N / 2) elements in an arbitrary search direction. The computer that runs is
A first feature matrix that does not overlap the first block in the second block, and a second feature matrix that does not overlap the second block in the first block. A difference value calculating step for calculating a difference value matrix as a difference;
First, the N × M element difference value matrix calculated in the difference value calculating step is subjected to one-dimensional orthogonal transformation using an N × N element orthogonal transformation matrix to calculate an N × M element transformation coefficient matrix. Orthogonal transformation process of
The N × M element transform coefficient matrix calculated in the first orthogonal transform step is subjected to one-dimensional orthogonal transform using an M × N element orthogonal transform matrix to calculate an N × N element transform coefficient matrix. A second orthogonal transformation step;
Based on the first transform coefficient matrix of N × N elements related to the first block and the transform coefficient matrix of N × N elements transformed by the second orthogonal transform step, N related to the second block A coefficient value calculating step of calculating a second transformation coefficient matrix of × N elements;
The image processing method characterized by performing.

(付記9)画像内のN×N要素の第1のブロックが任意の探索方向にM(1≦M<N/2)要素シフトしたN×N要素の第2のブロックの二次元直交変換を実行するコンピュータを、
前記第2のブロック内で前記第1のブロックに重複していない第1の特徴量行列と、前記第1のブロック内で前記第2のブロックに重複していない第2の特徴量行列との差分となる差分値行列を算出する差分値算出手段、
前記差分値算出手段により算出されたN×M要素の差分値行列を、N×N要素の直交変換行列を用いて一次元直交変換して、N×M要素の変換係数行列を算出する第1の直交変換手段、
前記第1の直交変換手段により算出されたN×M要素の変換係数行列を、M×N要素の直交変換行列を用いて一次元直交変換して、N×N要素の変換係数行列を算出する第2の直交変換手段、
前記第1のブロックに関するN×N要素の第1の変換係数行列と、前記第2の直交変換手段により変換されたN×N要素の変換係数行列とに基づいて、前記第2のブロックに関するN×N要素の第2の変換係数行列を算出する係数値算出手段、
として機能させることを特徴とする画像処理プログラム。
(Supplementary Note 9) Two-dimensional orthogonal transformation of a second block of N × N elements obtained by shifting the first block of N × N elements in the image by M (1 ≦ M <N / 2) elements in an arbitrary search direction. The computer to run,
A first feature matrix that does not overlap the first block in the second block, and a second feature matrix that does not overlap the second block in the first block. A difference value calculating means for calculating a difference value matrix as a difference;
First, the N × M element difference value matrix calculated by the difference value calculating means is subjected to one-dimensional orthogonal transformation using an N × N element orthogonal transformation matrix to calculate an N × M element transformation coefficient matrix. Orthogonal transformation means,
The N × M element transform coefficient matrix calculated by the first orthogonal transform unit is subjected to one-dimensional orthogonal transform using the M × N element orthogonal transform matrix to calculate an N × N element transform coefficient matrix. Second orthogonal transform means;
Based on the first transform coefficient matrix of N × N elements related to the first block and the transform coefficient matrix of N × N elements transformed by the second orthogonal transform unit, N related to the second block X coefficient value calculating means for calculating a second transform coefficient matrix of N elements;
An image processing program that functions as an image processing program.

300 画像処理装置
301 差分値算出回路
302 第1の直交変換回路
303 第2の直交変換回路
304 係数値算出回路
800 画像処理装置
1300 画像処理装置
1301 差分値算出部
1302 第1の直交変換部
1303 第2の直交変換部
1304 係数値算出部
1305 係数差分値算出部
1306 絶対値演算部
1307 総和演算部
1308 二次元直交変換部
300 Image processing device 301 Difference value calculation circuit 302 First orthogonal transformation circuit 303 Second orthogonal transformation circuit 304 Coefficient value calculation circuit 800 Image processing device 1300 Image processing device 1301 Difference value calculation unit 1302 First orthogonal transformation unit 1303 First Two orthogonal transform units 1304 Coefficient value calculation unit 1305 Coefficient difference value calculation unit 1306 Absolute value calculation unit 1307 Summation calculation unit 1308 Two-dimensional orthogonal transform unit

Claims (5)

画像内のN×N要素の第1のブロックが任意の探索方向にM(1≦M<N/2)要素シフトしたN×N要素の第2のブロックの二次元直交変換を実行する画像処理装置であって、
前記第2のブロック内で前記第1のブロックに重複していない第1の特徴量行列と、前記第1のブロック内で前記第2のブロックに重複していない第2の特徴量行列との差分となる差分値行列を算出する差分値算出手段と、
前記差分値算出手段により算出されたN×M要素の差分値行列を、N×N要素の直交変換行列を用いて一次元直交変換して、N×M要素の変換係数行列を算出する第1の直交変換手段と、
前記第1の直交変換手段により算出されたN×M要素の変換係数行列を、M×N要素の直交変換行列を用いて一次元直交変換して、N×N要素の変換係数行列を算出する第2の直交変換手段と、
前記第1のブロックに関するN×N要素の第1の変換係数行列と、前記第2の直交変換手段により変換されたN×N要素の変換係数行列とに基づいて、前記第2のブロックに関するN×N要素の第2の変換係数行列を算出する係数値算出手段と、
を備えることを特徴とする画像処理装置。
Image processing for performing two-dimensional orthogonal transformation of a second block of N × N elements obtained by shifting the first block of N × N elements in the image by M (1 ≦ M <N / 2) elements in an arbitrary search direction A device,
A first feature matrix that does not overlap the first block in the second block, and a second feature matrix that does not overlap the second block in the first block. A difference value calculating means for calculating a difference value matrix as a difference;
First, the N × M element difference value matrix calculated by the difference value calculating means is subjected to one-dimensional orthogonal transformation using an N × N element orthogonal transformation matrix to calculate an N × M element transformation coefficient matrix. Orthogonal transformation means,
The N × M element transform coefficient matrix calculated by the first orthogonal transform unit is subjected to one-dimensional orthogonal transform using the M × N element orthogonal transform matrix to calculate an N × N element transform coefficient matrix. A second orthogonal transform means;
Based on the first transform coefficient matrix of N × N elements related to the first block and the transform coefficient matrix of N × N elements transformed by the second orthogonal transform unit, N related to the second block A coefficient value calculating means for calculating a second transform coefficient matrix of × N elements;
An image processing apparatus comprising:
M=1、かつ前記N×N要素の直交変換行列がアダマール変換行列、かつ前記M×N要素の直交変換行列が前記アダマール変換行列の一部を取り出した行列であり、
前記第2の直交変換手段は、
前記第1の直交変換手段により算出されたN×M要素の変換係数行列を前記探索方向にN個並べることにより、N×N要素の変換係数行列を生成する生成手段と、
前記生成手段により生成されたN×N要素の変換係数行列内の各要素の符号を、前記M×N要素の直交変換行列に基づいて変換する符号変換手段と、を備え、
前記係数値算出手段は、
前記第1のブロックに関するN×N要素の第1の変換係数行列と、前記符号変換手段により符号が変換されたN×N要素の変換係数行列とに基づいて、前記第2のブロックに関するN×N要素の第2の変換係数行列を算出することを特徴とする請求項1に記載の画像処理装置。
M = 1, and is said orthogonal transform matrix is a Hadamard transform matrix of N × N elements, and orthogonal transform matrix of the M × N element was removed portion of the Hadamard transform matrix matrix,
The second orthogonal transform means includes:
Generating means for generating an N × N element transform coefficient matrix by arranging N N × M element transform coefficient matrices calculated by the first orthogonal transform means in the search direction;
Code conversion means for converting the code of each element in the N × N element conversion coefficient matrix generated by the generation means based on the M × N element orthogonal conversion matrix;
The coefficient value calculating means includes
Based on the N × N element first transform coefficient matrix related to the first block and the N × N element transform coefficient matrix whose code has been converted by the code conversion means, N × N elements related to the second block. The image processing apparatus according to claim 1, wherein a second transform coefficient matrix of N elements is calculated.
前記画像と異なる画像内のN×N要素の第3のブロックに関する第3の変換係数行列と前記係数値算出手段により算出された第2の変換係数行列との差分となる係数差分値行列を算出する係数差分値算出手段と、
前記係数差分値算出手段により算出された係数差分値行列の絶対値を算出する絶対値演算手段と、
前記絶対値演算手段により算出された絶対値行列内の要素の総和を算出する総和演算手段と、
を備えることを特徴とする請求項1または2に記載の画像処理装置。
Calculate a coefficient difference value matrix that is a difference between a third transform coefficient matrix relating to a third block of N × N elements in an image different from the image and the second transform coefficient matrix calculated by the coefficient value calculation means. Coefficient difference value calculating means to perform,
Absolute value calculating means for calculating an absolute value of the coefficient difference value matrix calculated by the coefficient difference value calculating means;
A sum calculating means for calculating a sum of elements in the absolute value matrix calculated by the absolute value calculating means;
The image processing apparatus according to claim 1, further comprising:
画像内のN×N要素の第1のブロックが任意の探索方向にM(1≦M<N/2)要素シフトしたN×N要素の第2のブロックの二次元直交変換を実行するコンピュータが、
前記第2のブロック内で前記第1のブロックに重複していない第1の特徴量行列と、前記第1のブロック内で前記第2のブロックに重複していない第2の特徴量行列との差分となる差分値行列を算出する差分値算出工程と、
前記差分値算出工程により算出されたN×M要素の差分値行列を、N×N要素の直交変換行列を用いて一次元直交変換して、N×M要素の変換係数行列を算出する第1の直交変換工程と、
前記第1の直交変換工程により算出されたN×M要素の変換係数行列を、M×N要素の直交変換行列を用いて一次元直交変換して、N×N要素の変換係数行列を算出する第2の直交変換工程と、
前記第1のブロックに関するN×N要素の第1の変換係数行列と、前記第2の直交変換工程により変換されたN×N要素の変換係数行列とに基づいて、前記第2のブロックに関するN×N要素の第2の変換係数行列を算出する係数値算出工程と、
を実行することを特徴とする画像処理方法。
A computer that performs two-dimensional orthogonal transformation of a second block of N × N elements obtained by shifting a first block of N × N elements in an image by M (1 ≦ M <N / 2) elements in an arbitrary search direction. ,
A first feature matrix that does not overlap the first block in the second block, and a second feature matrix that does not overlap the second block in the first block. A difference value calculating step for calculating a difference value matrix as a difference;
First, the N × M element difference value matrix calculated in the difference value calculating step is subjected to one-dimensional orthogonal transformation using an N × N element orthogonal transformation matrix to calculate an N × M element transformation coefficient matrix. Orthogonal transformation process of
The N × M element transform coefficient matrix calculated in the first orthogonal transform step is subjected to one-dimensional orthogonal transform using an M × N element orthogonal transform matrix to calculate an N × N element transform coefficient matrix. A second orthogonal transformation step;
Based on the first transform coefficient matrix of N × N elements related to the first block and the transform coefficient matrix of N × N elements transformed by the second orthogonal transform step, N related to the second block A coefficient value calculating step of calculating a second transformation coefficient matrix of × N elements;
The image processing method characterized by performing.
画像内のN×N要素の第1のブロックが任意の探索方向にM(1≦M<N/2)要素シフトしたN×N要素の第2のブロックの二次元直交変換を実行するコンピュータを、
前記第2のブロック内で前記第1のブロックに重複していない第1の特徴量行列と、前記第1のブロック内で前記第2のブロックに重複していない第2の特徴量行列との差分となる差分値行列を算出する差分値算出手段、
前記差分値算出手段により算出されたN×M要素の差分値行列を、N×N要素の直交変換行列を用いて一次元直交変換して、N×M要素の変換係数行列を算出する第1の直交変換手段、
前記第1の直交変換手段により算出されたN×M要素の変換係数行列を、M×N要素の直交変換行列を用いて一次元直交変換して、N×N要素の変換係数行列を算出する第2の直交変換手段、
前記第1のブロックに関するN×N要素の第1の変換係数行列と、前記第2の直交変換手段により変換されたN×N要素の変換係数行列とに基づいて、前記第2のブロックに関するN×N要素の第2の変換係数行列を算出する係数値算出手段、
として機能させることを特徴とする画像処理プログラム。
A computer that performs a two-dimensional orthogonal transformation of a second block of N × N elements obtained by shifting the first block of N × N elements in the image by M (1 ≦ M <N / 2) elements in an arbitrary search direction. ,
A first feature matrix that does not overlap the first block in the second block, and a second feature matrix that does not overlap the second block in the first block. A difference value calculating means for calculating a difference value matrix as a difference;
First, the N × M element difference value matrix calculated by the difference value calculating means is subjected to one-dimensional orthogonal transformation using an N × N element orthogonal transformation matrix to calculate an N × M element transformation coefficient matrix. Orthogonal transformation means,
The N × M element transform coefficient matrix calculated by the first orthogonal transform unit is subjected to one-dimensional orthogonal transform using the M × N element orthogonal transform matrix to calculate an N × N element transform coefficient matrix. Second orthogonal transform means;
Based on the first transform coefficient matrix of N × N elements related to the first block and the transform coefficient matrix of N × N elements transformed by the second orthogonal transform unit, N related to the second block X coefficient value calculating means for calculating a second transform coefficient matrix of N elements;
An image processing program that functions as an image processing program.
JP2010047763A 2010-03-04 2010-03-04 Image processing apparatus, image processing method, and image processing program Expired - Fee Related JP5375676B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2010047763A JP5375676B2 (en) 2010-03-04 2010-03-04 Image processing apparatus, image processing method, and image processing program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2010047763A JP5375676B2 (en) 2010-03-04 2010-03-04 Image processing apparatus, image processing method, and image processing program

Publications (2)

Publication Number Publication Date
JP2011188007A JP2011188007A (en) 2011-09-22
JP5375676B2 true JP5375676B2 (en) 2013-12-25

Family

ID=44793817

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2010047763A Expired - Fee Related JP5375676B2 (en) 2010-03-04 2010-03-04 Image processing apparatus, image processing method, and image processing program

Country Status (1)

Country Link
JP (1) JP5375676B2 (en)

Families Citing this family (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2015054811A1 (en) 2013-10-14 2015-04-23 Microsoft Corporation Features of intra block copy prediction mode for video and image coding and decoding
CN105659602B (en) 2013-10-14 2019-10-08 微软技术许可有限责任公司 Coder side option for the intra block duplication prediction mode that video and image encode
MX360926B (en) 2014-01-03 2018-11-22 Microsoft Technology Licensing Llc Block vector prediction in video and image coding/decoding.
US11284103B2 (en) 2014-01-17 2022-03-22 Microsoft Technology Licensing, Llc Intra block copy prediction with asymmetric partitions and encoder-side search patterns, search ranges and approaches to partitioning
EP3253059A1 (en) * 2014-03-04 2017-12-06 Microsoft Technology Licensing, LLC Block flipping and skip mode in intra block copy prediction
EP3158734A4 (en) 2014-06-19 2017-04-26 Microsoft Technology Licensing, LLC Unified intra block copy and inter prediction modes
KR102330740B1 (en) 2014-09-30 2021-11-23 마이크로소프트 테크놀로지 라이센싱, 엘엘씨 Rules for intra-picture prediction modes when wavefront parallel processing is enabled
US10337983B2 (en) 2015-04-12 2019-07-02 Taiwan Biophotonic Corporation Module, device and method for optical measurement
US10394777B2 (en) 2015-09-24 2019-08-27 Google Llc Fast orthogonal projection
CN107636639B (en) * 2015-09-24 2021-01-08 谷歌有限责任公司 Fast orthogonal projection
CN109003327B (en) * 2018-06-29 2022-09-30 平安科技(深圳)有限公司 Image processing method, image processing device, computer equipment and storage medium

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2964633B2 (en) * 1990-11-30 1999-10-18 ソニー株式会社 Image signal encoding apparatus and method
JP3655651B2 (en) * 1994-09-02 2005-06-02 テキサス インスツルメンツ インコーポレイテツド Data processing device
US5796434A (en) * 1996-06-07 1998-08-18 Lsi Logic Corporation System and method for performing motion estimation in the DCT domain with improved efficiency
US8654833B2 (en) * 2007-09-26 2014-02-18 Qualcomm Incorporated Efficient transformation techniques for video coding
JP4933405B2 (en) * 2007-11-13 2012-05-16 キヤノン株式会社 Data conversion apparatus and control method thereof

Also Published As

Publication number Publication date
JP2011188007A (en) 2011-09-22

Similar Documents

Publication Publication Date Title
JP5375676B2 (en) Image processing apparatus, image processing method, and image processing program
Zeman et al. A finite element perspective on nonlinear FFT‐based micromechanical simulations
JP7009603B2 (en) Quantum circuit simulation methods, appliances, equipment, storage media, and programs
Bottin et al. Large-scale ab initio calculations based on three levels of parallelization
JP2009266230A (en) Device, system, and method for solving simultaneous linear equation using parallel processing
Ge et al. An efficient fpga implementation of orthogonal matching pursuit with square-root-free qr decomposition
JP6062207B2 (en) Image processing method and image processing apparatus
JP2018022339A (en) Calculation processor and control method of calculation processor
JP2006300939A (en) System for detecting two-dimensional absolute position using target pattern
US8265427B2 (en) Interpolator and designing method thereof
JP4260751B2 (en) Unitary matrix decomposition apparatus, unitary matrix decomposition method, unitary matrix decomposition program, and recording medium
JPH01269183A (en) Spatial filter picture processor
Coelho et al. Computation of 2D 8× 8 DCT based on the Loeffler factorization using algebraic integer encoding
Pinto et al. An efficient architecture for modified lifting-based discrete wavelet transform
JP4672499B2 (en) Interpolation calculation device
Chiang et al. ImageMech: From image to particle spring network for mechanical characterization
Kim et al. Efficient brain-inspired hyperdimensional learning with spatiotemporal structured data
Li et al. Multi-scale cross-fusion for arbitrary scale image super resolution
Anguraj et al. Design of area-efficient modified decoder-based imprecise multiplier for error-resilient applications
JPS6360952B2 (en)
JP4832462B2 (en) Image processing apparatus, image processing program, and image processing method
EP1679626A1 (en) Design support device, design support method, design support program, and recording medium
JP3737723B2 (en) Electronic watermark embedding apparatus, method, program thereof, and program recording medium
Wang An adaptive linearized alternating direction multiplier method with a relaxation step for convex programming
JP2713400B2 (en) Projection information generation device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20130108

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20130527

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20130604

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20130805

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20130909

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

LAPS Cancellation because of no payment of annual fees