[go: up one dir, main page]

JP4383367B2 - Motion vector detection device - Google Patents

Motion vector detection device Download PDF

Info

Publication number
JP4383367B2
JP4383367B2 JP2005049514A JP2005049514A JP4383367B2 JP 4383367 B2 JP4383367 B2 JP 4383367B2 JP 2005049514 A JP2005049514 A JP 2005049514A JP 2005049514 A JP2005049514 A JP 2005049514A JP 4383367 B2 JP4383367 B2 JP 4383367B2
Authority
JP
Japan
Prior art keywords
image
reduced image
motion vector
reduced
holding unit
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
JP2005049514A
Other languages
Japanese (ja)
Other versions
JP2006238046A (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.)
Sanyo Electric Co Ltd
Original Assignee
Sanyo Electric Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Sanyo Electric Co Ltd filed Critical Sanyo Electric Co Ltd
Priority to JP2005049514A priority Critical patent/JP4383367B2/en
Priority to US11/360,495 priority patent/US8019000B2/en
Publication of JP2006238046A publication Critical patent/JP2006238046A/en
Application granted granted Critical
Publication of JP4383367B2 publication Critical patent/JP4383367B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

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

Description

本発明は、動きベクトル検出技術に関し、例えば、フレーム間予測モードを含む画像符号化方式により動画像を符号化するために、フレーム間の動きベクトルを検出する装置に関する。   The present invention relates to a motion vector detection technique, and, for example, to an apparatus for detecting a motion vector between frames in order to encode a moving image by an image encoding method including an inter-frame prediction mode.

動画の圧縮符号化方式の規格であるMPEG(Motion Picture Experts Group)−4では、動きベクトルを用いた動き補償予測符号化が行われる。動きベクトルを検出する技術として、符号化対象画像の解像度を下げて縮小画像を生成し、縮小画像を用いて近似的な動きベクトルを検出した後、その近似的な動きベクトルを参考にしつつ、元の解像度の画像を用いて動きベクトルを検出するという、階層的動きベクトル検出方法が提案されている(例えば、特許文献1参照)。
特開平11−260215号公報
In MPEG (Motion Picture Experts Group) -4, which is a standard for video compression coding, motion compensation prediction coding using motion vectors is performed. As a technique for detecting a motion vector, a reduced image is generated by reducing the resolution of the encoding target image, an approximate motion vector is detected using the reduced image, and then the original motion while referring to the approximate motion vector. A hierarchical motion vector detection method has been proposed in which a motion vector is detected using an image with a resolution of (for example, see Patent Document 1).
Japanese Patent Laid-Open No. 11-260215

従来は、上述した階層動きベクトル検出方法において、符号化の対象となるマクロブロックが変わるたびに、参照画像の探索領域の画像をフレームメモリから読み出して縮小画像を生成していたが、メモリバスの混雑がボトルネックとなり、処理速度に限界があった。   Conventionally, in the hierarchical motion vector detection method described above, every time a macroblock to be encoded changes, the image of the search area of the reference image is read from the frame memory to generate a reduced image. Congestion became a bottleneck, and the processing speed was limited.

本発明はこうした状況に鑑みてなされたものであり、その目的は、動きベクトルの検出に要する時間を短縮する技術を提供することにある。   The present invention has been made in view of such circumstances, and an object of the present invention is to provide a technique for shortening the time required for motion vector detection.

本発明のある態様は、動きベクトル検出装置に関する。この動きベクトル検出装置は、第1画像と、前記第1画像の参照画像である第2画像との間で、動きベクトルを検出する動きベクトル検出装置であって、前記第2画像を取得し、元の画像よりも解像度の低い縮小画像を生成する縮小画像生成部と、前記縮小画像の少なくとも一部を格納する縮小画像保持部と、画像間のマッチングを演算して動きベクトルを検出する演算部と、を含み、前記演算部は、所定のサイズのマクロブロック単位で、前記第1画像の縮小画像と前記第2画像の縮小画像のマッチングを演算することにより得られた動きベクトルを参照して、元の解像度の前記第1画像と前記第2画像のマッチングを演算して動きベクトルを検出し、前記縮小画像を用いて動きベクトルを検出する際に、前記縮小画像のうち、前記縮小画像保持部に保持されている部分は、前記縮小画像保持部から読み出され、前記縮小画像保持部に保持されていない部分は、前記縮小画像生成部で生成されることを特徴とする。このような構成によれば、縮小画像保持部に保持された縮小画像を新たに生成する必要がないので、処理速度を向上させることができる。 One embodiment of the present invention relates to a motion vector detection device. The motion vector detection device is a motion vector detection device that detects a motion vector between a first image and a second image that is a reference image of the first image, and acquires the second image; A reduced image generation unit that generates a reduced image having a resolution lower than that of the original image, a reduced image holding unit that stores at least a part of the reduced image, and a calculation unit that calculates a matching between the images and detects a motion vector The calculation unit refers to a motion vector obtained by calculating matching between the reduced image of the first image and the reduced image of the second image in units of macroblocks of a predetermined size. When the motion vector is detected by calculating the matching between the first image and the second image having the original resolution, and the motion vector is detected using the reduced image, the reduced image is selected from the reduced images. Portions held in the holding section is read out from the reduced image holding unit, wherein the reduced image holding unit is not held in the portion, characterized in that it is generated by the reduced image generation unit. According to such a configuration, it is not necessary to newly generate a reduced image held in the reduced image holding unit, so that the processing speed can be improved.

前記縮小画像保持部は、前記第2画像の縮小画像の全体を保持可能なメモリにより構成され、前記縮小画像の画素の配列と同様の配列で画素データを前記メモリに格納してもよい。十分な容量のメモリを設けておくことにより、処理速度を向上させることができる。また、メモリ上の画素データの配列を実際の画像における画素の配列と同じにしておくことにより、読み出し及び書き込みの制御が容易となるとともに、高速に読み出し及び書き込みを行うことができる。   The reduced image holding unit may include a memory capable of holding the entire reduced image of the second image, and store pixel data in the memory in an arrangement similar to the arrangement of pixels of the reduced image. By providing a memory with a sufficient capacity, the processing speed can be improved. Further, by making the arrangement of the pixel data on the memory the same as the arrangement of the pixels in the actual image, it becomes easy to control the reading and writing, and the reading and writing can be performed at high speed.

前記縮小画像保持部は、次回の動きベクトル検出に必要な縮小画像と重なる領域を格納してもよい。これにより、縮小画像保持部の容量が小さくても、処理速度を向上させることができる。   The reduced image holding unit may store a region overlapping with a reduced image necessary for the next motion vector detection. Thereby, even when the capacity of the reduced image holding unit is small, the processing speed can be improved.

本発明の別の態様は、画像符号化装置に関する。この画像符号化装置は、動画像を符号化して符号化データ列を生成する画像符号化装置であって、第1画像と、前記第1画像の参照画像である第2画像との間で、動きベクトルを検出する動きベクトル検出部と、前記動きベクトルを利用して前記第1画像を符号化する符号化部と、を備え、前記動きベクトル検出部は、前記第2画像を取得し、元の画像よりも解像度の低い縮小画像を生成する縮小画像生成部と、前記縮小画像の少なくとも一部を格納する縮小画像保持部と、画像間のマッチングを演算して動きベクトルを検出する演算部と、を含み、前記演算部は、前記第1画像の縮小画像と前記第2画像の縮小画像のマッチングを演算することにより得られた動きベクトルを参照して、元の解像度の前記第1画像と前記第2画像のマッチングを演算して動きベクトルを検出し、前記縮小画像を用いて動きベクトルを検出する際に、前記縮小画像のうち、前記縮小画像保持部に保持されている部分は、前記縮小画像保持部から読み出されることを特徴とする。   Another aspect of the present invention relates to an image encoding device. The image encoding device is an image encoding device that encodes a moving image to generate an encoded data sequence, and between a first image and a second image that is a reference image of the first image, A motion vector detection unit that detects a motion vector; and an encoding unit that encodes the first image using the motion vector, wherein the motion vector detection unit obtains the second image, A reduced image generation unit that generates a reduced image having a resolution lower than that of the image, a reduced image holding unit that stores at least a part of the reduced image, a calculation unit that calculates a matching between the images and detects a motion vector, The calculation unit refers to a motion vector obtained by calculating a matching between the reduced image of the first image and the reduced image of the second image, and the first image having the original resolution Matchon of the second image When the motion vector is detected by calculating and the motion vector is detected using the reduced image, the portion of the reduced image held in the reduced image holding unit is read from the reduced image holding unit. It is characterized by that.

本発明の更に別の態様は、動きベクトル検出方法に関する。この動きベクトル検出方法は、第1画像と、前記第1画像の参照画像である第2画像との間で、動きベクトルを検出する方法であって、前記第2画像を取得して、元の画像よりも解像度の低い縮小画像を生成するステップと、前記第1画像の縮小画像と前記第2画像の縮小画像とのマッチングを演算して近似的な動きベクトルを検出するステップと、前記近似的な動きベクトルを参照して、元の解像度の前記第1画像と前記第2画像とのマッチングを演算して動きベクトルを検出するステップと、前記縮小画像の少なくとも一部を、縮小画像を保持する縮小画像保持部へ格納するステップと、を含み、前記縮小画像を用いて動きベクトルを検出する際に、前記縮小画像のうち、前記縮小画像保持部に保持されている部分は、前記縮小画像保持部から読み出されることを特徴とする。   Yet another embodiment of the present invention relates to a motion vector detection method. The motion vector detection method is a method of detecting a motion vector between a first image and a second image that is a reference image of the first image, and acquires the second image, Generating a reduced image having a resolution lower than that of the image; calculating a matching between the reduced image of the first image and the reduced image of the second image; and detecting an approximate motion vector; and A motion vector is detected by calculating matching between the first image and the second image of the original resolution with reference to a simple motion vector, and at least a part of the reduced image is held as a reduced image A step of storing in the reduced image holding unit, and when detecting a motion vector using the reduced image, a portion of the reduced image held in the reduced image holding unit holds the reduced image Characterized in that it is read from.

なお、以上の構成要素の任意の組合せ、本発明の表現を方法、装置、システム、プログラムなどの間で変換したものもまた、本発明の態様として有効である。   It should be noted that any combination of the above-described constituent elements and a representation obtained by converting the expression of the present invention between a method, an apparatus, a system, a program and the like are also effective as an aspect of the present invention.

本発明によれば、動きベクトルの検出に要する時間を短縮する技術を提供することができる。   ADVANTAGE OF THE INVENTION According to this invention, the technique which shortens the time required for the detection of a motion vector can be provided.

実施の形態に係る画像符号化装置は、まず符号化すべき画像から解像度を下げた縮小画像を生成し、縮小画像を用いて解像度の低い大まかな動きベクトル(以下、「近似動きベクトル」という)を検出した後、その近似動きベクトルを参考にして、元の解像度の高い画像を用いて動きベクトルを検出する。本実施の形態では、このような階層的動きベクトル検出技術を用いるに際して、メモリアクセス量を低減し、動きベクトルの検出速度を向上させる技術を提案する。   The image encoding apparatus according to the embodiment first generates a reduced image with a reduced resolution from an image to be encoded, and uses the reduced image to generate a rough motion vector with a low resolution (hereinafter referred to as an “approximate motion vector”). After the detection, the motion vector is detected using the original high-resolution image with reference to the approximate motion vector. The present embodiment proposes a technique for reducing the memory access amount and improving the motion vector detection speed when using such a hierarchical motion vector detection technique.

図1は、本発明の実施の形態に係る画像符号化装置10の全体構成を示す。画像符号化装置10は、動きベクトル検出回路24、動き補償回路26、フレームメモリ28、符号化回路30、復号化回路32、出力バッファ34、符号量制御回路36、及び参照モード選択回路38を含む。これらの構成は、ハードウエア的には、任意のコンピュータのCPU、メモリ、その他のLSIで実現でき、ソフトウエア的にはメモリにロードされたプログラムなどによって実現されるが、ここではそれらの連携によって実現される機能ブロックを描いている。したがって、これらの機能ブロックがハードウエアのみ、ソフトウエアのみ、またはそれらの組合せによっていろいろな形で実現できることは、当業者には理解されるところである。   FIG. 1 shows an overall configuration of an image encoding device 10 according to an embodiment of the present invention. The image encoding device 10 includes a motion vector detection circuit 24, a motion compensation circuit 26, a frame memory 28, an encoding circuit 30, a decoding circuit 32, an output buffer 34, a code amount control circuit 36, and a reference mode selection circuit 38. . These configurations can be realized in terms of hardware by a CPU, memory, or other LSI of any computer, and in terms of software, they are realized by programs loaded into the memory. It depicts the functional blocks that are realized. Accordingly, those skilled in the art will understand that these functional blocks can be realized in various forms by hardware only, software only, or a combination thereof.

画像符号化装置10に外部から入力された画像(以下、「入力画像」という)は、動きベクトル検出回路24に送られる。動きベクトル検出回路24は、予めフレームメモリ28に格納されて予測のために参照の対象となる画像(以下、「参照画像」という)と入力画像との間で動きベクトルを検出する。動き補償回路26は、符号量制御回路36から量子化に用いる量子化ステップの値を取得し、その量子化の係数とマクロブロックの予測モードを決定する。動きベクトル検出回路24により検出された動きベクトルと、動き補償回路26により決定された量子化係数及びマクロブロック予測モードが、符号化回路30へ送られる。また、動き補償回路26は、マクロブロックについての予測値と実際の値との差分を予測誤差として符号化回路30に送る。   An image input from the outside to the image encoding device 10 (hereinafter referred to as “input image”) is sent to the motion vector detection circuit 24. The motion vector detection circuit 24 detects a motion vector between an input image and an image (hereinafter referred to as “reference image”) stored in advance in the frame memory 28 and used as a reference target for prediction. The motion compensation circuit 26 acquires the value of the quantization step used for quantization from the code amount control circuit 36, and determines the quantization coefficient and the macroblock prediction mode. The motion vector detected by the motion vector detection circuit 24, the quantization coefficient determined by the motion compensation circuit 26, and the macroblock prediction mode are sent to the encoding circuit 30. Also, the motion compensation circuit 26 sends the difference between the predicted value and the actual value for the macroblock to the encoding circuit 30 as a prediction error.

符号化回路30は、予測誤差を量子化係数を用いて符号化して出力バッファ34へ送る。符号化回路30は、量子化した予測誤差と量子化係数を復号化回路32へ送る。復号化回路32は、量子化された予測誤差を量子化係数に基づいて復号化し、復号化した予測誤差と動き補償回路26による予測値との和を復号画像としてフレームメモリ28に送る。この復号画像は、後続の画像の符号化処理において参照される場合に、参照画像として動きベクトル検出回路24へ送られる。符号量制御回路36は、出力バッファ34の蓄積量の状態を取得し、その蓄積量の状態に応じて次の量子化に用いる量子化ステップの値を生成する。   The encoding circuit 30 encodes the prediction error using the quantization coefficient and sends it to the output buffer 34. The encoding circuit 30 sends the quantized prediction error and the quantized coefficient to the decoding circuit 32. The decoding circuit 32 decodes the quantized prediction error based on the quantization coefficient, and sends the sum of the decoded prediction error and the prediction value from the motion compensation circuit 26 to the frame memory 28 as a decoded image. This decoded image is sent to the motion vector detection circuit 24 as a reference image when it is referred to in the subsequent image encoding process. The code amount control circuit 36 acquires the state of the accumulation amount of the output buffer 34, and generates a quantization step value used for the next quantization according to the state of the accumulation amount.

参照モード選択回路38は、フレーム内符号化、フレーム間前方向予測符号化、フレーム間双方向予測符号化、の間でフレーム予測モードの切り替えを行い、他の回路に対してフレームの予測モード情報を出力する。   The reference mode selection circuit 38 switches the frame prediction mode among intra-frame coding, inter-frame forward prediction coding, and inter-frame bidirectional prediction coding, and provides frame prediction mode information to other circuits. Is output.

図2は、動きベクトル検出回路の内部構成を示す。動きベクトル検出回路24は、縮小画像生成部40、縮小画像保持部42、及び演算部44を含む。縮小画像生成部40は、フレームメモリ28に格納されている入力画像及び参照画像を取得して、それらの画像の解像度を下げ、所定の倍率に縮小した画像を生成する。縮小画像生成部40は、画素を間引いて画像を縮小してもよいし、所定のサイズのブロックに含まれる画素データを平均し、そのブロックを1つの画素としてもよいし、任意の技術を用いて縮小画像を生成してもよい。演算部44は、入力画像の符号化の対象となるマクロブロック(符号化対象マクロブロック)と参照画像の探索領域内のマクロブロックとの間で差分(予測誤差)を演算し、差分が最も小さい参照画像のマクロブロックを探索して動きベクトルを検出する。縮小画像保持部42は、SDRAMなどのメモリにより構成されており、後述するように、縮小画像生成部40が生成した縮小画像の一部又は全部を保持する。縮小画像保持部42は、フレームメモリ28の一部により実現されてもよいし、フレームメモリ28と共用されてもよい。   FIG. 2 shows the internal configuration of the motion vector detection circuit. The motion vector detection circuit 24 includes a reduced image generation unit 40, a reduced image holding unit 42, and a calculation unit 44. The reduced image generation unit 40 acquires the input image and the reference image stored in the frame memory 28, reduces the resolution of these images, and generates an image reduced to a predetermined magnification. The reduced image generation unit 40 may reduce the image by thinning out pixels, average pixel data included in a block of a predetermined size, and use the block as one pixel, or use any technique. A reduced image may be generated. The calculation unit 44 calculates a difference (prediction error) between a macroblock to be encoded of the input image (encoding target macroblock) and a macroblock in the search area of the reference image, and the difference is the smallest. A motion vector is detected by searching a macroblock of the reference image. The reduced image holding unit 42 is configured by a memory such as an SDRAM, and holds a part or all of the reduced image generated by the reduced image generating unit 40, as will be described later. The reduced image holding unit 42 may be realized by a part of the frame memory 28 or may be shared with the frame memory 28.

本実施の形態では、階層的な動きベクトルの検出を行う。すなわち、まず、解像度の低い縮小画像における近似動きベクトルを検出し、その近似動きベクトルを参考にしつつ、解像度の高い画像における動きベクトルを検出する。まず、縮小画像生成部40は、入力画像の符号化対象マクロブロックと、参照画像の探索領域の縮小画像を生成する。つづいて、演算部44は、縮小された符号化対象マクロブロックと探索領域を取得して、ブロックマッチングを行い、近似動きベクトルを検出する。次に、演算部44は、符号化対象マクロブロックと探索領域の原画像を取得し、検出された近似動きベクトルの近傍を中心にブロックマッチングを行い、動きベクトルを検出する。演算部44による動きベクトルの検出は、所定のサイズ、例えば縦16ピクセル×横16ピクセルのマクロブロック単位で行われる。   In the present embodiment, hierarchical motion vectors are detected. That is, first, an approximate motion vector in a reduced image with low resolution is detected, and a motion vector in an image with high resolution is detected while referring to the approximate motion vector. First, the reduced image generation unit 40 generates an encoding target macroblock of the input image and a reduced image of the search area of the reference image. Subsequently, the calculation unit 44 acquires the reduced encoding target macroblock and the search region, performs block matching, and detects an approximate motion vector. Next, the calculation unit 44 acquires the encoding target macroblock and the original image of the search area, performs block matching around the detected approximate motion vector, and detects a motion vector. The motion vector is detected by the calculation unit 44 in a predetermined size, for example, in units of macroblocks of vertical 16 pixels × horizontal 16 pixels.

図3は、従来の動きベクトルの検出手順を説明するための図である。図3(a)は、入力画像の左上端のマクロブロックの動きベクトルを検出するときの探索領域を示す。参照画像60aにおいて、入力画像の符号化対象マクロブロックと同じ位置にあるマクロブロック62aを含む領域64aが探索領域に設定されている。この例では、1つのマクロブロックは、縦16ピクセル×横16ピクセルであり、探索領域64aは、縦80ピクセル×横80ピクセルとする。   FIG. 3 is a diagram for explaining a conventional motion vector detection procedure. FIG. 3A shows the search area when detecting the motion vector of the macro block at the upper left corner of the input image. In the reference image 60a, a region 64a including a macroblock 62a located at the same position as the encoding target macroblock of the input image is set as a search region. In this example, one macroblock is 16 pixels long × 16 pixels wide, and the search area 64a is 80 pixels long × 80 pixels wide.

縮小画像生成部40は、フレームメモリ28から入力画像の符号化対象マクロブロックの画素データを読み出して、画像を1/4倍に縮小し、縦4ピクセル×横4ピクセルの縮小画像を生成する。また、フレームメモリ28から探索領域64aの画素データを読み出して、画像を1/4倍に縮小し、縦20ピクセル×横20ピクセルの縮小画像を得る。演算部44は、これらの縮小画像を用いて、近似動きベクトルを検出する。つづいて、演算部44は、フレームメモリ28から符号化対象マクロブロックと探索領域の原画像を取得し、近似動きベクトルを参考にしつつ、動きベクトルを検出する。   The reduced image generation unit 40 reads out the pixel data of the encoding target macroblock of the input image from the frame memory 28, reduces the image by a factor of 1/4, and generates a reduced image of vertical 4 pixels × horizontal 4 pixels. In addition, the pixel data of the search area 64a is read from the frame memory 28, and the image is reduced by a factor of 1/4 to obtain a reduced image of 20 pixels vertically × 20 pixels horizontally. The computing unit 44 detects an approximate motion vector using these reduced images. Subsequently, the calculation unit 44 acquires the encoding target macroblock and the original image of the search area from the frame memory 28, and detects the motion vector while referring to the approximate motion vector.

動きベクトルが検出されると、図3(b)に示すように、符号化対象マクロブロックを右隣にうつし、同様に動きベクトルを検出する。入力画像の最上段の右端のマクロブロックまで動きベクトルが検出されると、次の段のマクロブロックにうつる。こうして、入力画像の全マクロブロックの動きベクトルを検出する。   When a motion vector is detected, as shown in FIG. 3B, the encoding target macroblock is moved to the right and the motion vector is detected in the same manner. When a motion vector is detected up to the rightmost macroblock in the uppermost stage of the input image, the next macroblock is moved to. In this way, motion vectors of all macroblocks of the input image are detected.

図4及び図5は、本実施の形態の動きベクトルの検出手順を説明するための図である。図4(a)は、入力画像の左上端のマクロブロックの動きベクトルを検出するときの探索領域を示す。図3(a)の場合と同様に、探索領域64aの縮小画像を生成して近似動きベクトルを検出し、つづいて、原画像を用いて動きベクトルを検出する。このとき、縮小画像生成部40が生成した探索領域64aの縮小画像を縮小画像保持部42に格納しておく。   4 and 5 are diagrams for explaining a motion vector detection procedure according to the present embodiment. FIG. 4A shows a search area when detecting the motion vector of the macro block at the upper left corner of the input image. As in the case of FIG. 3A, a reduced image of the search area 64a is generated to detect an approximate motion vector, and then a motion vector is detected using the original image. At this time, the reduced image of the search area 64 a generated by the reduced image generation unit 40 is stored in the reduced image holding unit 42.

この例では、縮小画像保持部42は、1フレームの入力画像の全てのマクロブロックの動きベクトルを検出するために用いられる全ての探索領域64の縮小画像を格納可能な程度の容量のメモリにより構成される。すなわち、参照画像の縮小画像を1フレーム分程度格納可能な容量を有するメモリにより構成される。入力画像の端部付近のマクロブロックの動きベクトルを検出するときに、図4(a)などに示すように、参照画像をはみ出すように探索領域が設定される場合は、その分だけ参照画像の縮小画像の1フレーム分よりも容量の大きなメモリを設ければよい。   In this example, the reduced image holding unit 42 is configured by a memory having a capacity enough to store reduced images of all search areas 64 used for detecting motion vectors of all macroblocks of an input image of one frame. Is done. That is, it is configured by a memory having a capacity capable of storing a reduced image of the reference image for about one frame. When detecting a motion vector of a macroblock near the edge of an input image, as shown in FIG. 4A and the like, if a search region is set so as to protrude from the reference image, the reference image is correspondingly increased. A memory having a larger capacity than one frame of the reduced image may be provided.

次に、図4(b)に示すように、右隣のマクロブロックの動きベクトル検出にうつる。探索領域64bの縮小画像を生成する際に、探索領域64aと重なっている領域66bの縮小画像は、既に生成されて縮小画像保持部42に格納されているので、縮小画像保持部42から読み出せばよい。したがって、縮小画像生成部40は、探索領域64aと重なっていない領域68bの画素データのみをフレームメモリ28から読み出して縮小画像を生成すればよい。このとき、新たに生成した領域68bの縮小画像も、縮小画像保持部42に格納しておく。   Next, as shown in FIG. 4B, the motion vector detection of the right macroblock is performed. When the reduced image of the search area 64b is generated, the reduced image of the area 66b that overlaps the search area 64a has already been generated and stored in the reduced image holding section 42, and therefore can be read from the reduced image holding section 42. That's fine. Therefore, the reduced image generation unit 40 may read out only the pixel data of the area 68b that does not overlap the search area 64a from the frame memory 28 and generate a reduced image. At this time, the newly generated reduced image of the area 68 b is also stored in the reduced image holding unit 42.

図4(c)に示すように、それ以降のマクロブロックの動きベクトルを検出する際にも、同様に、探索領域64cの縮小画像の全てを新たに生成する必要はなく、領域66cの縮小画像は縮小画像保持部42から読み出し、領域68cの縮小画像のみを生成すればよい。   As shown in FIG. 4C, when detecting the motion vector of the subsequent macroblock, it is not necessary to newly generate all the reduced images in the search region 64c, and the reduced image in the region 66c. May be read from the reduced image holding unit 42 and only the reduced image in the region 68c may be generated.

図5は、入力画像の2段目以降のマクロブロックの動きベクトルを検出する手順を説明するための図である。図5(a)に示すように、2段目の左端のマクロブロックの動きベクトルを検出するとき、探索領域64dのうち、領域66dの縮小画像は縮小画像保持部42から読み出せばよく、領域68dの縮小画像のみを生成すればよい。   FIG. 5 is a diagram for explaining the procedure for detecting the motion vectors of the second and subsequent macroblocks of the input image. As shown in FIG. 5A, when detecting the motion vector of the leftmost macroblock in the second row, the reduced image in the region 66d in the search region 64d may be read from the reduced image holding unit 42. It is only necessary to generate a 68d reduced image.

図5(b)及び図5(c)に示すように、2段目の2列目以降のマクロブロックにおいては、新たに縮小画像を生成するのは、探索領域64e、64fの右下端の領域68e、68fのみでよい。   As shown in FIGS. 5 (b) and 5 (c), in the macroblocks in the second and subsequent columns of the second stage, a new reduced image is generated in the lower right area of the search areas 64e and 64f. Only 68e and 68f are sufficient.

上述のように、縮小画像保持部42を設けることにより、演算部44が縮小画像を用いて近似動きベクトルを検出する際に、符号化対象マクロブロックが変わるたびにフレームメモリ28から参照画像の探索領域の原画像を取得して縮小画像を新たに生成するのではなく、過去の近似動きベクトルの検出において既に生成されて保持されていた参照画像の縮小画像を縮小画像保持部42から読み出して再利用することができる。これにより、フレームメモリ28に対するメモリアクセスを飛躍的に削減し、動きベクトル検出の処理速度を向上させることができる。ひいては、動きベクトルの検出精度を向上させることもできる。   As described above, by providing the reduced image holding unit 42, when the calculation unit 44 detects the approximate motion vector using the reduced image, the reference memory is searched from the frame memory 28 every time the macroblock to be encoded changes. Rather than acquiring an original image of a region and newly generating a reduced image, a reduced image of a reference image that has already been generated and held in the detection of past approximate motion vectors is read out from the reduced image holding unit 42 and regenerated. Can be used. Thereby, memory access to the frame memory 28 can be drastically reduced, and the processing speed of motion vector detection can be improved. As a result, motion vector detection accuracy can be improved.

図3に示した方法と、図4及び図5に示した方法におけるメモリ転送量を比較してみる。図3の例では、1つのマクロブロックにつき、探索領域64の原画像をフレームメモリ28から読み出すので、80×80=6400ピクセル分の画素データを転送する必要がある。それに対して、図4及び図5の例では、最初の最上段1列目のマクロブロックについては図3の例と同様であるが、最上段の2列目以降のマクロブロックにおいては、メモリ転送量が削減される。例えば、最上段2列目のマクロブロックにおいては、図4(b)に示すように、領域68bはフレームメモリ28から原画像を読み出すので80×16=1280ピクセル分、領域66bは縮小画像保持部42から縮小画像を読み出すので20×16=320ピクセル分を読み出す。そして、新たに生成した領域68bの縮小画像を縮小画像保持部42に格納するので、20×4=80ピクセル分を書き込む。すなわち、合計1680ピクセル分の画素データが転送される。これは、図3に示した例の26%にあたる。   Compare the memory transfer amount between the method shown in FIG. 3 and the method shown in FIGS. In the example of FIG. 3, since the original image of the search area 64 is read from the frame memory 28 for each macroblock, it is necessary to transfer pixel data for 80 × 80 = 6400 pixels. On the other hand, in the examples of FIGS. 4 and 5, the macroblock in the first uppermost row is the same as the example in FIG. 3, but in the macroblocks in the second and subsequent rows of the uppermost row, memory transfer is performed. The amount is reduced. For example, in the macroblock in the uppermost second column, as shown in FIG. 4B, since the area 68b reads the original image from the frame memory 28, 80 × 16 = 1280 pixels, and the area 66b is a reduced image holding unit. Since the reduced image is read out from 42, 20 × 16 = 320 pixels are read out. Since the newly generated reduced image of the area 68b is stored in the reduced image holding unit 42, 20 × 4 = 80 pixels are written. That is, pixel data for a total of 1680 pixels is transferred. This corresponds to 26% of the example shown in FIG.

さらに、2段目の2列目以降のマクロブロックにおいては、図5(b)に示すように、領域68eはフレームメモリ28から原画像を読み出すので16×16=256ピクセル分、領域66eは縮小画像保持部42から縮小画像を読み出すので20×16+16×4=384ピクセル分を読み出す。そして、新たに生成した領域68eの縮小画像を縮小画像保持部42に格納するので、4×4=16ピクセル分を書き込む。すなわち、合計656ピクセル分の画素データが転送される。これは、図3に示した例の10%にあたる。   Further, in the second and subsequent macroblocks in the second row, as shown in FIG. 5B, since the original image is read from the frame memory 28 in the area 68e, the area 66e is reduced by 16 × 16 = 256 pixels. Since the reduced image is read out from the image holding unit 42, 20 × 16 + 16 × 4 = 384 pixels are read out. Then, since the newly generated reduced image of the area 68e is stored in the reduced image holding unit 42, 4 × 4 = 16 pixels are written. That is, pixel data for a total of 656 pixels is transferred. This corresponds to 10% of the example shown in FIG.

縮小画像保持部42は、縮小画像の画素の配列と同様の配列で画素データを保持してもよい。これにより、読み出し及び書き込みの制御が容易になるとともに、高速に読み出し及び書き込みを行うことができる。   The reduced image holding unit 42 may hold the pixel data in an arrangement similar to the arrangement of the pixels of the reduced image. As a result, reading and writing can be easily controlled, and reading and writing can be performed at high speed.

図6は、本実施の形態の動きベクトルの検出手順の別の例を説明するための図である。この例では、探索領域64の縮小画像の全てを縮小画像保持部42に格納するのではなく、次回の動きベクトル検出の際に用いられる探索領域と重なる領域のみを縮小画像保持部42に格納しておく。図6(a)に示すように、左上端のマクロブロックの動きベクトルを検出する際に、探索領域64aの縮小画像を生成する。このとき、図6(d)に示すように、次に行う右隣のマクロブロックの動きベクトル検出で用いられる探索領域64bと重なる領域69aの縮小画像を縮小画像保持部42に格納する。   FIG. 6 is a diagram for explaining another example of the motion vector detection procedure of the present embodiment. In this example, not all of the reduced images in the search area 64 are stored in the reduced image holding unit 42, but only the area that overlaps the search area used in the next motion vector detection is stored in the reduced image holding unit 42. Keep it. As shown in FIG. 6A, a reduced image of the search area 64a is generated when detecting the motion vector of the upper left macroblock. At this time, as shown in FIG. 6D, the reduced image in the area 69a that overlaps the search area 64b used in the motion vector detection of the next right macroblock to be performed next is stored in the reduced image holding unit.

図6(b)に示すように、最上段2列目のマクロブロックの動きベクトルを検出する際には、探索領域64bのうち、領域66bは前回の探索領域64aと重なっているので、縮小画像保持部42から縮小画像を読み出せばよい。前回の探索領域64aと重なっていない領域68bは、フレームメモリ28から原画像の画素データを読み出して、新たに縮小画像を生成する。このとき、図6(e)に示すように、次に行う右隣のマクロブロックの動きベクトル検出で用いられる探索領域64cと重なる領域69bの縮小画像を縮小画像保持部42に上書きする。   As shown in FIG. 6B, when detecting the motion vector of the macroblock in the uppermost second row, the area 66b of the search area 64b overlaps the previous search area 64a. A reduced image may be read from the holding unit 42. In an area 68b that does not overlap the previous search area 64a, pixel data of the original image is read from the frame memory 28, and a new reduced image is generated. At this time, as shown in FIG. 6E, the reduced image holding unit 42 is overwritten with the reduced image in the region 69b that overlaps the search region 64c used in the next motion vector detection of the next right macroblock.

この例におけるメモリ転送量を評価する。各段の2列目以降のマクロブロックにおいては、図6(b)に示すように、領域68bはフレームメモリ28から原画像を読み出すので80×16=1280ピクセル分、領域66bは縮小画像保持部42から縮小画像を読み出すので20×16=320ピクセル分を読み出す。そして、領域69bの縮小画像を縮小画像保持部42に格納するので、20×16=320ピクセル分を書き込む。すなわち、合計1920ピクセル分の画素データが転送される。これは、図3に示した例の30%にあたる。   The memory transfer amount in this example is evaluated. In the macroblocks in the second and subsequent columns of each stage, as shown in FIG. 6B, the area 68b reads the original image from the frame memory 28, so 80 × 16 = 1280 pixels, and the area 66b is a reduced image holding unit. Since the reduced image is read out from 42, 20 × 16 = 320 pixels are read out. Since the reduced image in the area 69b is stored in the reduced image holding unit 42, 20 × 16 = 320 pixels are written. That is, pixel data for a total of 1920 pixels is transferred. This corresponds to 30% of the example shown in FIG.

この例では、縮小画像保持部42として、領域69の縮小画像を保持可能な容量のメモリを設ければよいので、コスト、サイズ、重量、消費電力などの増大を抑えつつ、メモリ転送量を削減する効果が得られる。   In this example, a memory having a capacity capable of holding the reduced image in the area 69 may be provided as the reduced image holding unit 42, so that the memory transfer amount can be reduced while suppressing an increase in cost, size, weight, power consumption, and the like. Effect is obtained.

上述したいずれの技術を用いても、フレームメモリ28に対するアクセスを削減し、高解像度の画像を高速に符号化することができる。   Any of the above-described techniques can reduce access to the frame memory 28 and encode a high-resolution image at high speed.

以上、本発明を実施の形態をもとに説明した。この実施の形態は例示であり、それらの各構成要素や各処理プロセスの組合せにいろいろな変形例が可能なこと、またそうした変形例も本発明の範囲にあることは当業者に理解されるところである。   The present invention has been described based on the embodiments. This embodiment is an exemplification, and it will be understood by those skilled in the art that various modifications can be made to combinations of the respective constituent elements and processing processes, and such modifications are also within the scope of the present invention. is there.

実施の形態では、縮小画像の画素配置と同様の配置で縮小画像保持部42に縮小画像を格納したが、新たに生成した領域68の縮小画像を、使用しなくなった領域に順次上書きしていってもよい。これにより、必要な縮小画像保持部42の容量を小さくすることができる。また、参照画像だけでなく、入力画像についても同様に縮小画像を縮小画像保持部42に格納して再利用してもよい。これにより、さらにメモリアクセスを削減し、処理を高速化することができる。   In the embodiment, the reduced image is stored in the reduced image holding unit 42 in the same arrangement as the pixel arrangement of the reduced image. However, the newly generated reduced image in the area 68 is sequentially overwritten on the unused area. May be. Thereby, the capacity | capacitance of the required reduced image holding | maintenance part 42 can be made small. Further, not only the reference image but also the input image may be stored in the reduced image holding unit 42 and reused similarly. As a result, memory access can be further reduced and the processing speed can be increased.

実施の形態では、縮小画像生成部40が入力画像及び参照画像の縮小画像を生成したが、入力画像の縮小画像は、他の構成により生成されて動きベクトル検出回路24に入力されてもよい。   In the embodiment, the reduced image generation unit 40 generates the reduced image of the input image and the reference image. However, the reduced image of the input image may be generated by another configuration and input to the motion vector detection circuit 24.

本発明の実施の形態に係る画像符号化装置の全体構成を示す図である。It is a figure which shows the whole structure of the image coding apparatus which concerns on embodiment of this invention. 動きベクトル検出回路の内部構成を示す図である。It is a figure which shows the internal structure of a motion vector detection circuit. 従来の動きベクトルの検出手順を説明するための図である。It is a figure for demonstrating the detection procedure of the conventional motion vector. 本実施の形態の動きベクトルの検出手順を説明するための図である。It is a figure for demonstrating the detection procedure of the motion vector of this Embodiment. 本実施の形態の動きベクトルの検出手順を説明するための図である。It is a figure for demonstrating the detection procedure of the motion vector of this Embodiment. 本実施の形態の動きベクトルの検出手順の別の例を説明するための図である。It is a figure for demonstrating another example of the detection procedure of the motion vector of this Embodiment.

符号の説明Explanation of symbols

10 画像符号化装置、24 動きベクトル検出回路、26 動き補償回路、28 フレームメモリ、30 符号化回路、32 復号化回路、34 出力バッファ、36 符号量制御回路、38 参照モード選択回路、40 縮小画像生成部、42 縮小画像保持部、44 演算部。   DESCRIPTION OF SYMBOLS 10 Image coding apparatus, 24 motion vector detection circuit, 26 motion compensation circuit, 28 frame memory, 30 encoding circuit, 32 decoding circuit, 34 output buffer, 36 code amount control circuit, 38 reference mode selection circuit, 40 reduced image Generating unit, 42 reduced image holding unit, 44 calculating unit;

Claims (1)

第1画像と、前記第1画像の参照画像である第2画像との間で、動きベクトルを検出する動きベクトル検出装置であって、
前記第2画像を取得し、元の画像よりも解像度の低い縮小画像を生成する縮小画像生成部と、
前記縮小画像の少なくとも一部を格納する縮小画像保持部と、
画像間のマッチングを演算して動きベクトルを検出する演算部と、を含み、
前記演算部は、所定のサイズのマクロブロック単位で、前記第1画像の縮小画像と前記第2画像の縮小画像のマッチングを演算することにより得られた動きベクトルを参照して、元の解像度の前記第1画像と前記第2画像のマッチングを演算して動きベクトルを検出し、
前記縮小画像を用いて動きベクトルを検出する際に、前記縮小画像のうち、前記縮小画像保持部に保持されている部分は、前記縮小画像保持部から読み出され、前記縮小画像保持部に保持されていない部分は、前記縮小画像生成部で生成され、
前記縮小画像保持部は、前記第2画像の縮小画像の全体を保持可能なメモリにより構成され、前記縮小画像の画素の配列と同様の配列で画素データを前記メモリに格納することを特徴とすることを特徴とする動きベクトル検出装置。
A motion vector detection device that detects a motion vector between a first image and a second image that is a reference image of the first image,
A reduced image generation unit that acquires the second image and generates a reduced image having a lower resolution than the original image;
A reduced image holding unit for storing at least a part of the reduced image;
A calculation unit for calculating a matching between images and detecting a motion vector,
The computing unit refers to a motion vector obtained by computing matching between the reduced image of the first image and the reduced image of the second image in units of macroblocks of a predetermined size, and has an original resolution. A motion vector is detected by calculating a matching between the first image and the second image;
When detecting a motion vector using the reduced image, a portion of the reduced image held in the reduced image holding unit is read from the reduced image holding unit and held in the reduced image holding unit. The part that has not been generated is generated by the reduced image generation unit,
The reduced image holding unit includes a memory capable of holding the entire reduced image of the second image, and stores pixel data in the memory in an arrangement similar to the arrangement of pixels of the reduced image. motion-out vector detecting device you wherein a.
JP2005049514A 2005-02-24 2005-02-24 Motion vector detection device Expired - Fee Related JP4383367B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2005049514A JP4383367B2 (en) 2005-02-24 2005-02-24 Motion vector detection device
US11/360,495 US8019000B2 (en) 2005-02-24 2006-02-24 Motion vector detecting device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2005049514A JP4383367B2 (en) 2005-02-24 2005-02-24 Motion vector detection device

Publications (2)

Publication Number Publication Date
JP2006238046A JP2006238046A (en) 2006-09-07
JP4383367B2 true JP4383367B2 (en) 2009-12-16

Family

ID=37045214

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2005049514A Expired - Fee Related JP4383367B2 (en) 2005-02-24 2005-02-24 Motion vector detection device

Country Status (1)

Country Link
JP (1) JP4383367B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5094750B2 (en) * 2009-01-19 2012-12-12 キヤノン株式会社 Moving picture coding apparatus and moving picture coding method
JP5683153B2 (en) * 2010-07-09 2015-03-11 キヤノン株式会社 Image processing apparatus and image processing method
JP5598199B2 (en) * 2010-09-16 2014-10-01 富士通株式会社 Video encoding device

Also Published As

Publication number Publication date
JP2006238046A (en) 2006-09-07

Similar Documents

Publication Publication Date Title
TWI586149B (en) Video encoder, method and computing device for processing video frames in a block processing pipeline
US8731044B2 (en) Moving-picture processing apparatus
US20090110077A1 (en) Image coding device, image coding method, and image coding integrated circuit
US20050190976A1 (en) Moving image encoding apparatus and moving image processing apparatus
US8619862B2 (en) Method and device for generating an image data stream, method and device for reconstructing a current image from an image data stream, image data stream and storage medium carrying an image data stream
JP2005303984A (en) Motion vector detecting device and method thereof, and image encoding apparatus capable of utilizing the motion vector detecting device
JP4764807B2 (en) Motion vector detection apparatus and motion vector detection method
JP4502203B2 (en) Image encoding apparatus and image decoding apparatus
CN1937773B (en) External storage device, method for storing image data, and image processor
CN101783958B (en) Calculation method and device of temporal direct mode motion vector in AVS video standard
US20080212719A1 (en) Motion vector detection apparatus, and image coding apparatus and image pickup apparatus using the same
JP5043012B2 (en) Video encoding / decoding method for preserving cache locality
JP4383367B2 (en) Motion vector detection device
JP5182285B2 (en) Decoding method and decoding apparatus
JP5580541B2 (en) Image decoding apparatus and image decoding method
JP4675383B2 (en) Image decoding apparatus and method, and image encoding apparatus
JP5299319B2 (en) Motion vector detection device
JP5206070B2 (en) Decoding device and decoding method
JP2006279330A (en) Motion compensation processing method
JP2011097488A (en) Video compression encoder
JP2008136177A (en) Motion detection device, MOS (metal-oxide semiconductor) integrated circuit, and video system
KR100708183B1 (en) Image data storage device for motion estimation and data storage method
JP5867050B2 (en) Image processing device
JP2009272948A (en) Moving image decoding apparatus and moving image decoding method
JP5401909B2 (en) Transcoding device and transcoding method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20070109

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20080626

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20080708

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080821

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090616

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20090731

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

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20090918

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

Free format text: PAYMENT UNTIL: 20121002

Year of fee payment: 3

R151 Written notification of patent or utility model registration

Ref document number: 4383367

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151

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

Free format text: PAYMENT UNTIL: 20121002

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20131002

Year of fee payment: 4

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313113

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S131 Request for trust registration of transfer of right

Free format text: JAPANESE INTERMEDIATE CODE: R313135

SZ02 Written request for trust registration

Free format text: JAPANESE INTERMEDIATE CODE: R313Z02

S131 Request for trust registration of transfer of right

Free format text: JAPANESE INTERMEDIATE CODE: R313135

SZ02 Written request for trust registration

Free format text: JAPANESE INTERMEDIATE CODE: R313Z02

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S131 Request for trust registration of transfer of right

Free format text: JAPANESE INTERMEDIATE CODE: R313135

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313531

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees