JP2006270683A - Coding device and method - Google Patents
Coding device and method Download PDFInfo
- Publication number
- JP2006270683A JP2006270683A JP2005087739A JP2005087739A JP2006270683A JP 2006270683 A JP2006270683 A JP 2006270683A JP 2005087739 A JP2005087739 A JP 2005087739A JP 2005087739 A JP2005087739 A JP 2005087739A JP 2006270683 A JP2006270683 A JP 2006270683A
- Authority
- JP
- Japan
- Prior art keywords
- frame
- pixel data
- memory
- motion
- prefetch
- 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.)
- Granted
Links
Images
Abstract
Description
本発明は、動画像を符号化する符号化装置および方法に関する。 The present invention relates to an encoding apparatus and method for encoding a moving image.
ブロードバンドネットワークが急速に発展しており、高品質な動画像を利用したサービスに期待が集まっている。また、DVDなど大容量の記録媒体が利用されており、高画質の画像を楽しむユーザ層が広がっている。動画像を通信回線で伝送したり、記録媒体に蓄積するために不可欠な技術として圧縮符号化がある。動画像圧縮符号化技術の国際標準として、MPEG4の規格やH.264/AVC規格がある。また、1つのストリームにおいて高画質のストリームと低画質のストリームを併せもつSVC(Scalable Video Codec)のような次世代画像圧縮技術がある。 Broadband networks are rapidly developing, and there are high expectations for services that use high-quality moving images. In addition, a large-capacity recording medium such as a DVD is used, and a user group who enjoys high-quality images is expanding. There is compression coding as an indispensable technique for transmitting moving images via a communication line or storing them in a recording medium. As an international standard for moving image compression coding technology, the MPEG4 standard and H.264 standard. There is a H.264 / AVC standard. Further, there is a next-generation image compression technology such as SVC (Scalable Video Codec) having a high-quality stream and a low-quality stream in one stream.
動画像の圧縮符号化および復号では、フレームメモリに動画像のフレームを蓄積し、フレームメモリを参照して、動き補償が行われるため、フレームメモリからのデータ転送が頻繁に行われる。特により高画質の動画を生成するために、動き探索を小数画素単位で行うことがあり、動き補償で扱うデータ量は増えており、メモリ帯域幅が処理のボトルネックとなりやすい。特許文献1には、フレームメモリのバンド幅の使用効率を改善することのできるディジタル画像復号装置が開示されている。
動画像の圧縮符号化の際、符号化対象フレームの対象マクロブロックの動き検出をするために、参照フレームの所定の探索範囲内の画素領域をフレームメモリから読み出し、その画素領域内で対象マクロブロックとマッチングするマクロブロックを探索する。動き検出では、探索を繰り返して対象マクロブロックと適合する参照フレームのマクロブロックを見つけるため、フレームメモリからの読み出し回数が多くなり、データ転送量も増え、フレームメモリの転送帯域幅を圧迫する。フレームメモリへのアクセスがボトルネックとなって、圧縮符号化の処理速度が低下するという問題が生じる。 In order to detect motion of the target macroblock of the encoding target frame at the time of compression encoding of the moving image, a pixel area within a predetermined search range of the reference frame is read from the frame memory, and the target macroblock is detected within the pixel area. Search for a macroblock that matches. In motion detection, since the search is repeated to find a macroblock of a reference frame that matches the target macroblock, the number of reads from the frame memory increases, the amount of data transfer increases, and the transfer bandwidth of the frame memory is reduced. Access to the frame memory becomes a bottleneck, which causes a problem that the processing speed of compression encoding decreases.
本発明はこうした状況に鑑みてなされたもので、その目的は、フレームメモリへのアクセスを減らして、符号化の処理効率を高めることのできる動画像の符号化技術を提供することにある。 The present invention has been made in view of such circumstances, and an object of the present invention is to provide a moving picture coding technique capable of reducing the access to the frame memory and increasing the coding processing efficiency.
上記課題を解決するために、本発明のある態様の符号化装置は、動画像のフレームを符号化する符号化装置であって、符号化対象フレームの対象ブロックの動き検出をする際に参照する参照フレームを保持するフレームメモリと、前記フレームメモリに保持された前記参照フレームを参照して、動き探索を繰り返して前記対象ブロックの動き検出を行う動き検出部とを含む。前記動き検出部は、前記参照フレーム内の画素データの内、動き探索の際に参照する頻度の高い画素データをあらかじめ前記フレームメモリから転送して保持する先読み用メモリを有する。 In order to solve the above-described problem, an encoding apparatus according to an aspect of the present invention is an encoding apparatus that encodes a frame of a moving image, and is referred to when motion detection of a target block of an encoding target frame is performed. A frame memory that holds a reference frame; and a motion detection unit that refers to the reference frame held in the frame memory and repeats motion search to detect a motion of the target block. The motion detection unit has a prefetch memory that transfers pixel data frequently referenced during motion search from the frame memory and holds the pixel data in the reference frame.
「参照する頻度の高い画素データ」とは、たとえば、動き探索が繰り返して行われる際に、所定の回数以上、繰り返し参照される可能性がある領域内の画素データである。 “Pixel data that is frequently referred to” is, for example, pixel data in an area that may be repeatedly referred to a predetermined number of times or more when motion search is repeatedly performed.
この態様によると、フレームメモリからのデータ転送量を減らすことができる。 According to this aspect, the amount of data transferred from the frame memory can be reduced.
本発明の別の態様は、符号化方法である。この方法は、動画像の符号化対象フレームの対象ブロックの動き検出をする際に参照する参照フレームを保持するフレームメモリから、前記参照フレーム内の動き探索範囲の画素データの内、参照頻度の高い画素データをあらかじめ転送して先読み用メモリに保持し、動き探索の際に参照する画素データが前記先読み用メモリにある場合は、前記先読み用メモリに保持された画素データを参照し、そうでない場合は、前記フレームメモリに保持された画素データを参照することにより、動き探索を行う。 Another aspect of the present invention is an encoding method. This method has a high reference frequency in the pixel data of the motion search range in the reference frame from the frame memory that holds the reference frame to be referred to when the motion of the target block of the encoding target frame of the moving image is detected. If the pixel data is transferred in advance and stored in the pre-read memory, and the pixel data to be referred to in motion search is in the pre-read memory, the pixel data stored in the pre-read memory is referred to. Performs motion search by referring to pixel data held in the frame memory.
なお、以上の構成要素の任意の組み合わせ、本発明の表現を方法、装置、システム、記録媒体、コンピュータプログラムなどの間で変換したものもまた、本発明の態様として有効である。 It should be noted that any combination of the above-described constituent elements and a conversion of the expression of the present invention between a method, an apparatus, a system, a recording medium, a computer program, and the like are also effective as an aspect of the present invention.
本発明によれば、動画像の符号化の処理効率を向上することができる。 According to the present invention, it is possible to improve the processing efficiency of moving picture encoding.
図1は、実施の形態に係る符号化装置100の構成図である。これらの構成は、ハードウエア的には、任意のコンピュータのCPU、メモリ、その他のLSIで実現でき、ソフトウエア的にはメモリにロードされた画像符号化機能のあるプログラムなどによって実現されるが、ここではそれらの連携によって実現される機能ブロックを描いている。したがって、これらの機能ブロックがハードウエアのみ、ソフトウエアのみ、またはそれらの組み合わせによっていろいろな形で実現できることは、当業者には理解されるところである。
FIG. 1 is a configuration diagram of an
本実施の形態の符号化装置100は、ISO/IEC標準であるMPEGシリーズの規格、ITU−T標準であるH.26xシリーズの規格、もしくは両方の標準化グループにより開発された最新技術の動画像圧縮符号化標準であるH.264/AVCの規格に準拠して動画像の符号化を行う。
The
MPEGシリーズの規格では、フレーム内符号化を行う画像フレームをI(Intra)フレーム、過去のフレームを参照画像として順方向のフレーム間予測符号化を行う画像フレームをP(Predictive)フレーム、過去と未来のフレームを参照画像として双方向のフレーム間予測符号化を行う画像フレームをBフレームという。 In the MPEG series standard, an image frame for intra-frame encoding is an I (Intra) frame, an image frame for forward inter-frame predictive encoding with a past frame as a reference image, a P (Predictive) frame, and past and future An image frame that performs bidirectional inter-frame predictive coding using this frame as a reference image is referred to as a B frame.
一方、H.264/AVCでは、参照画像として利用できるフレームは、時間の先後を問わず、過去の2枚のフレームを参照画像としてもよく、未来の2枚のフレームを参照画像としてもよい。また、参照画像として利用できるフレームの枚数も問わず、3枚以上のフレームを参照画像として用いることもできる。したがって、MPEG−1/2/4では、Bフレームは双方向予測(Bi-directional prediction)フレームのことを指していたが、H.264/AVCでは、Bフレームは、参照画像の時間の先後は問わないため、双予測(Bi-predictive prediction)フレームのことを指すことに留意する。 On the other hand, H. In H.264 / AVC, a frame that can be used as a reference image may be a past two frames as a reference image or a future two frames as a reference image regardless of the time. Further, three or more frames can be used as the reference image regardless of the number of frames that can be used as the reference image. Therefore, in MPEG-1 / 2/4, the B frame refers to a Bi-directional prediction frame. Note that in H.264 / AVC, the B frame refers to a bi-predictive prediction frame because the time of the reference image does not matter before and after.
なお、本願明細書では、フレームとピクチャを同じ意味で用いており、Iフレーム、Pフレーム、Bフレームは、それぞれIピクチャ、Pピクチャ、Bピクチャとも呼ばれている。 In the specification of the present application, a frame and a picture are used in the same meaning, and an I frame, a P frame, and a B frame are also called an I picture, a P picture, and a B picture, respectively.
符号化装置100は、フレーム単位で動画像の入力を受け取り、動画像を符号化し、符号化ストリームを出力する。入力された動画フレームはフレームメモリ80に格納される。
The
動き補償部60は、フレームメモリ80に格納されている過去または未来の画像フレームを参照画像として利用し、PフレームまたはBフレームのマクロブロック毎に動き補償を行い、動きベクトルと予測画像を生成する。動き補償部60は、符号化対象のPフレームまたはBフレームの画像と予測画像の差分を取り、差分画像をDCT部20に供給する。また、動き補償部60は、生成した動きベクトルを可変長符号化部90に供給する。
The
DCT部20は、動き補償部60から供給された画像を離散コサイン変換(DCT)し、得られたDCT係数を量子化部30に与える。
The
量子化部30は、DCT係数を量子化し、可変長符号化部90に与える。可変長符号化部90は、動き補償部60から与えられた動きベクトルとともに差分画像の量子化されたDCT係数を可変長符号化し、符号化ストリームを生成する。可変長符号化部90は、符号化ストリームを生成する際、符号化されたフレームを時間順序に並べ替える処理を行う。
The
PフレームもしくはBフレームの符号化処理の場合は、上述のように動き補償部60が動作するが、Iフレームの符号化処理の場合は、動き補償部60は動作せず、ここでは図示しないが、Iフレームはフレーム内予測が行われた後、DCT部20に供給される。
In the case of P frame or B frame encoding processing, the
本実施の形態の動き補償部60は、動きベクトルの探索範囲の先読みを行う。まず、比較のために動き補償部60の一般的な構成を説明し、その後、先読みを行う動き補償部60の構成を説明する。
The
図2は、動き補償部60の一般的な構成を説明する図である。フレームメモリ80と動き補償部60は、SBUS82により接続されている。動き補償部60は、アドレスを指定してフレームメモリ80にデータを要求し、フレームメモリ80からSBUS82を介して伝送されるデータを受け取る。
FIG. 2 is a diagram illustrating a general configuration of the
動き補償部60は、SRAM66、動きベクトル検出部62、および動き補償予測部68を有する。動きベクトル検出部62は、フレームメモリ80に保持された参照画像の所定の探索範囲内の画素データをSRAM66に転送する。
The
フレームメモリ80は、一例として大容量のSDRAMで構成され、SBUS82を介してアクセスされる。一方、SRAM66は、動きベクトル検出部62と同一の集積回路内に形成されており、動きベクトル検出部62から高速にアクセスすることが可能である。SRAM66はフレームメモリ80に比べて容量が限られており、フレームメモリ80に対する高速なキャッシュメモリとして機能する。SRAM66はデータ転送が高速であるから、動きベクトル検出部62がSRAM66内の画素領域を頻繁に参照して、動き探索するのに適している。なお、読み出しポート数を増やすために、一般的には複数枚のSRAM66が設けられる。
The
動きベクトル検出部62は、SRAM66に転送された画素データを参照して動きベクトルの検出を行う。動きベクトル検出部62は、対象マクロブロックに対して誤差の最も小さい予測マクロブロックを参照画像から検出し、対象マクロブロックから予測マクロブロックへの動きを示す動きベクトルを求める。動き検出は、対象マクロブロックとマッチングする参照画像における参照マクロブロックを整数画素単位または小数画素単位で探すことにより行われるため、探索は通常、画素領域内で複数回にわたって繰り返し行われ、その複数回の探索の中で対象マクロブロックと最も適合する参照マクロブロックが予測マクロブロックとして選択される。
The motion
動き補償予測部68は、動きベクトルを用いて対象マクロブロックを動き補償して、予測画像を生成し、符号化対象画像と予測画像の差分画像をDCT部20に出力する。
The motion
動きベクトルの探索方法として、探索方向を求めながら繰り返し探索を行う追跡法や勾配法を利用した場合、各回の探索で参照する範囲の画素データが、探索の度にフレームメモリ80からSRAM66に転送される。たとえば、縦横16画素のマクロブロックの探索を6回繰り返して、対象マクロブロックにマッチングする予測マクロブロックを探し当てたとする。この場合、1回の探索では、マクロブロックの周囲の画素も含めて縦横21画素の画素領域がSRAM66に転送される。それが6回繰り返されると、1つの対象マクロブロックに対して動きベクトルを探索するのに要するデータ転送量は、21×21×6=2646バイトとなる。ただし、1画素の情報量を簡単のため1バイトとした。追跡法や勾配法では、データ転送量は探索回数に応じて変動する。
When a tracking method or gradient method in which a search is repeatedly performed while obtaining a search direction is used as a motion vector search method, pixel data in a range referred to in each search is transferred from the
また、別の動きベクトルの探索方法として、探索範囲を決めてその中のすべてのマクロブロックを一つずつ取り上げ、対象マクロブロックとの間でマッチングを計算し、最もマッチングするマクロブロックを予測マクロブロックとして求める全探索法がある。全探索法を利用した場合、あらかじめ決められている探索範囲内のすべての画素データがフレームメモリ80からSRAM66に転送される。この場合、動きベクトル検出部62は、SRAM66に転送された画素領域内で動きベクトルの探索を行う。全探索法の場合、データ転送は1回だけである。たとえば、縦横16画素の対象マクロブロックに対して探索範囲が±16画素である場合、全探索範囲は縦横48画素になり、1つの対象マクロブロックに対して動きベクトルを探索するのに要するデータ転送量は、48×48=2304バイトとなる。
As another motion vector search method, the search range is determined and all macroblocks are picked up one by one, matching is calculated with the target macroblock, and the best matching macroblock is predicted macroblock. There is a total search method to find as When the full search method is used, all pixel data within a predetermined search range is transferred from the
追跡法や勾配法の場合、1回のデータ転送量は少ないが、探索精度を上げるために探索回数を増やす必要があり、探索回数に比例してデータ転送量が増え、フレームメモリ80からSRAM66へのデータ転送が動き検出処理のボトルネックとなって処理性能が低下する。全探索法では、データ転送は1回で済むが、全探索範囲の画素データをフレームメモリ80からSRAM66に転送するため、データ転送に時間がかかり、やはり処理性能に影響する。
In the tracking method and the gradient method, although the amount of data transferred at one time is small, it is necessary to increase the number of searches in order to increase the search accuracy. The amount of data transfer increases in proportion to the number of searches, and the
また、追跡法や勾配法では、参照画像内で参照するマクロブロックの位置を整数画素単位もしくは小数画素精度で変えながら、1回の探索毎にフレームメモリ80から参照する画素データを転送するが、そのうちの大部分はそれ以前の探索時に参照した画素データと重複しており、探索の度に参照する画素データをあらためて転送するのは無駄が多い。また、全探索法では、全探索範囲の画素データをフレームメモリ80からSRAM66に転送するため、参照する確率が極端に低い探索範囲の画素データまで転送することになり、やはりデータ転送に無駄がある。
In the tracking method and the gradient method, pixel data to be referred to is transferred from the
このように、動きベクトルの検出の際に、一般的にフレームメモリ80からSRAM66へのデータ転送に無駄が生じやすく、SBUS82の帯域幅を圧迫し、符号化処理のボトルネックとなりやすい。このような問題意識のもと、本出願人は、フレームメモリ80からのデータ転送に関して改良の余地があることを認識するに至った。以下、フレームメモリ80からのデータ転送を改良するためのいくつかの動き補償部60の構成とその動作を説明する。
As described above, when detecting a motion vector, generally, data transfer from the
図3は、動き補償部60の構成を説明する図である。図2の一般的な構成と共通する構成要素については同符号を付して説明を省略する。
FIG. 3 is a diagram illustrating the configuration of the
動き補償部60は、フレームメモリ80から転送した画素データを保持するために、通常のSRAM66とは別に、先読み用SRAM64を有する。動きベクトル検出部62は、フレームメモリ80に保持された参照画像の所定の探索範囲の内、参照頻度の高い画素領域のデータをあらかじめフレームメモリ80から先読み用SRAM64に転送する。一方、動きベクトル検出部62は、動きベクトルの探索の際に参照する必要のある画素データを探索の都度、フレームメモリ80からSRAM66に転送する。ただし、既に先読み用SRAM64に保持されている画素データについてはフレームメモリ80からSRAM66への転送は行われず、先読み用SRAM64に保持された画素データが優先的に利用される。
In order to hold the pixel data transferred from the
動きベクトル検出部62は、対象マクロブロックについての各回の探索で参照する画素データが先読み用SRAM64内にあれば、先読み用SRAM64から画素データを読み取り、先読み用SRAM64になければ、参照したい画素データをフレームメモリ80からSRAM66に転送して利用する。
The motion
動きベクトル検出部62は、次の新しい対象マクロブロックに対して動きベクトルの探索を開始する際、新しい対象マクロブロックの動き探索において参照頻度の高い画素データをあらかじめフレームメモリ80から先読み用SRAM64に転送し、先読み用SRAM64に保持されるデータを更新する。
When starting the motion vector search for the next new target macroblock, the motion
動きベクトル検出部62は、先読み用SRAM64とSRAM66とを切り替えて参照することにより、フレームメモリ80から重複したデータを繰り返し転送することを防ぎ、フレームメモリ80からのデータ転送量を減らすことができる。たとえば、先読み用SRAM64が縦横40画素の画素領域を先読みデータとして保持するとして、動き探索において、縦横16画素のマクロブロックの探索を6回繰り返したとする。仮に、6回の探索で参照する画素がすべて先読み用SRAM64内にあったとすれば、データ転送量は、先読み用SRAM64への1回のデータ転送だけで済み、1つの対象マクロブロックに対して動きベクトルを探索するのに要するデータ転送量は、40×40=1600バイトとなる。
The motion
このように、動きベクトル検出部62は、対象マクロブロックの動きベクトルの探索で複数回参照される可能性の高い画素データを前もってフレームメモリ80から読み出し、先読み用SRAM64に転送するが、先読み用SRAM64に転送すべきデータは次のような判断基準で決定する。
As described above, the motion
(1)周囲のマクロブロックの動きベクトルに基づいて決定
対象マクロブロックの周囲のマクロブロックで既に動きベクトルを検出済みのものがある場合、動きベクトル検出部62は、その周囲のマクロブロックの動きベクトルが示す予測マクロブロックおよびその周辺の画素領域を、対象マクロブロックの動き探索でも繰り返し参照される可能性が高いと判断し、先読み用SRAM64にあらかじめ転送する。
(1) Determination based on motion vectors of surrounding macroblocks When there is a motion vector that has already been detected in the surrounding macroblocks of the target macroblock, the motion
(2)画面全体の動きベクトルに基づいて決定
画面のスクロールなどにより画面全体が動いている場合、動きベクトル検出部62は、スクロールにより予想される移動先の画素領域が高い参照頻度をもつと判断し、先読み用SRAM64にあらかじめ転送する。
(2) Determination based on the motion vector of the entire screen When the entire screen is moving by scrolling the screen or the like, the motion
(3)過去または未来のフレームにおける同じ位置のマクロブロックの動きベクトルに基づいて決定
動きベクトル検出部62は、過去または未来のフレームにおいて、対象マクロブロックと同じ位置にある参照マクロブロックの動きベクトルから、対象マクロブロックの動き探索で参照される頻度の高い画素領域を予測し、先読み用SRAM64に転送する。
(3) Determination based on the motion vector of the macroblock at the same position in the past or future frame The motion
これは、画像の動きに時間軸方向の相関があり、時間の先後のフレームの動きベクトルから、符号化対象フレームの対象マクロブロックの動きをある程度予測できる場合に特に有効である。たとえば、線形動きモデルにしたがう場合は、動きを線形予測して探索範囲を絞り込むことができる。 This is particularly effective when the motion of the image has a correlation in the time axis direction, and the motion of the target macroblock of the encoding target frame can be predicted to some extent from the motion vectors of the frames ahead of time. For example, when following a linear motion model, the search range can be narrowed down by linearly predicting the motion.
ここで、対象マクロブロックと参照マクロブロックは、必ずしも画像上で同一位置になくてもよい。たとえば、画面のスクロールなどにより、画素の位置が変わることもあるため、対象マクロブロックと参照マクロブロックが画像上の位置は異なっていても、対応関係にあることもある。そのような場合は、対象マクロブロックに対応する参照マクロブロックの動きベクトルから、対象マクロブロックの動き探索において参照される頻度の高い画素領域を予測すればよい。 Here, the target macroblock and the reference macroblock do not necessarily have to be at the same position on the image. For example, since the pixel position may change due to screen scrolling or the like, the target macroblock and the reference macroblock may be in a corresponding relationship even if the positions on the image are different. In such a case, a pixel region that is frequently referred to in the motion search of the target macroblock may be predicted from the motion vector of the reference macroblock corresponding to the target macroblock.
(4)対象マクロブロックを中心とした周辺領域に固定
動きベクトル検出部62は、対象マクロブロックを中心として、上下左右に所定の画素数だけ広げた範囲が動き探索で繰り返し参照される可能性が高いと判断し、先読み用SRAM64に転送する。動きがあまり激しくない場合は、対象マクロブロックを中心とする狭い範囲でマッチングが取れる確率が高いからである。対象マクロブロックを中心とする上下左右の画素幅は、画像サイズすなわち解像度に応じて調整する。
(4) Fixed to a peripheral region centered on the target macroblock The motion
(5)前回までのパスで判明した探索範囲に基づいて決定
符号化が複数のパスにわたって行われる場合、動きベクトル検出部62は、前回までのパスで判明した探索範囲を今回のパスでも繰り返し探索される可能性が高いと判断し、先読み用SRAM64に転送する。
(5) Determination based on search range found in previous pass When encoding is performed over a plurality of passes, the motion
先読み用SRAM64にあらかじめ転送する画素データが占める領域のサイズは可変にしてもよい。動き量の大小や動き探索に要求される精度などの要因により、探索すべき画素領域の大きさを動的に変えることが必要となることがある。また、符号化装置100を実装する機器の設計上の制約などにより、先読み用SRAM64の容量には制限が設けられることがあったり、機器によってはSRAMの追加が可能なものもあるから、先読みする画素データの領域サイズは、先読み用SRAM64の容量制限や使用制限に応じて適宜変えられるように構成することも必要となる。先読みするデータのサイズは次のような基準で決定される。
The size of the area occupied by the pixel data to be transferred in advance to the
(1)周囲のマクロブロックの動きベクトルに基づいて、探索範囲の大きさやばらつき具合を判断し、先読みするデータのサイズを決める。
(2)画面のスクロールなど画像全体の動きベクトルに基づいて、先読みするデータのサイズを決める。
(3)過去または未来のフレームにおける同じ位置のマクロブロックの動きベクトルに基づいて、探索範囲の大きさを判断し、先読みするデータのサイズを決める。
(4)外部からの入力情報、たとえば、撮影モードなどを用いて、動きの激しい動画像であるかどうかなどを判断し、先読みするデータのサイズを決める。
(1) Based on the motion vectors of surrounding macroblocks, the size of the search range and the degree of variation are determined, and the size of prefetched data is determined.
(2) The size of prefetched data is determined based on the motion vector of the entire image such as screen scrolling.
(3) The size of the search range is determined based on the motion vector of the macroblock at the same position in the past or future frame, and the size of the prefetched data is determined.
(4) Using the input information from the outside, for example, the shooting mode, it is determined whether or not the image is a moving image with a large amount of motion, and the size of prefetched data is determined.
図4は、動き補償部60の別の構成を説明する図である。この構成では、先読み用SRAM65の記憶領域が複数のタイルに分割されており、タイル単位でデータの更新が可能である。動きベクトル検出部62は、フレームメモリ80に保持された参照画像の内、参照頻度の高い画素領域を先読み用SRAM64の各タイルに転送する。
FIG. 4 is a diagram illustrating another configuration of the
動きベクトル検出部62は、次の新しい対象マクロブロックに対する動きベクトルの探索を開始する際に、先読み用SRAM65のデータを更新するが、図4の構成では、このデータ更新をタイル単位で行う。
The motion
前回の対象マクロブロックと今回の対象マクロブロックの間に関連性がある場合、両マクロブロックの探索範囲は重複することが多く、参照頻度の高い画素領域も共通する場合が多い。そこで、動きベクトル検出部62は、前回の対象マクロブロックの動き探索で参照された画素データの内、今回の対象マクロブロックの動き探索でも参照頻度の高いデータは破棄しないで、先読み用SRAM64内にタイル単位でそのまま残し、今回の対象マクロブロックの動き探索に再利用する。
When there is a relationship between the previous target macroblock and the current target macroblock, the search ranges of both macroblocks often overlap, and pixel regions having a high reference frequency are often common. Therefore, the motion
動きベクトル検出部62は、前回の対象マクロブロックの動き探索では参照頻度が高い画素データであったが、今回の対象マクロブロックの動き探索では参照頻度が高くない画素データついては、タイル単位で先読み用SRAM64から破棄し、データが破棄されたタイルには、今回の対象マクロブロックの動き探索で参照頻度が高い画素データをフレームメモリ80から転送して保持する。
The motion
フレームメモリ80は、画像上の画素位置と記憶領域における位置とが対応しているが、先読み用SRAM65は、タイル単位でデータを入れ替えるため、先読み用SRAM65内では、画像上の画素位置と記憶領域における位置との間にフレームメモリのような対応関係はない。そこで、画像上の画素位置と記憶領域における位置の対応関係を格納する対応テーブルを設けておく。
In the
アドレス変換部67は、動きベクトル検出部62から画素位置を指定する参照アドレスを受け取ると、この対応テーブルを参照して、動きベクトル検出部62からの参照アドレスを先読み用SRAM65の実際の格納先を指す実アドレスに変換し、先読み用SRAM65に実アドレスを供給する。先読み用SRAM64は、アドレス変換部67から指定された実アドレスに格納された画素データを動きベクトル検出部62に出力する。
When the
タイル単位でデータ更新が可能な先読み用SRAM65を用いることにより、連続して処理する2つの対象マクロブロック間で、探索範囲に重複がある場合、重複した範囲の画素データは破棄せずに、次の対象マクロブロックでも再利用することができ、フレームメモリ80からのデータ転送量をさらに削減し、SBUS82の帯域幅の消費を抑えることができる。
By using the
図5は、動き補償部60のさらに別の構成を説明する図である。この構成では、第1先読み用SRAM64aと第2先読み用SRAM64bとを設ける。第1先読み用SRAM64aは、現在処理中の対象マクロブロックにおいて参照頻度の高い画素データをあらかじめ転送しておくために用いられ、第2先読み用SRAM64bは、次に処理する対象マクロブロックにおいて参照頻度の高い画素データをあらかじめ転送しておくために用いられる。
FIG. 5 is a diagram illustrating still another configuration of the
これにより、次の対象マクロブロックの処理を開始するときには、既に第2先読み用SRAM64bに画素データが先読みされているため、動きベクトルの探索を直ちに始めることができる。また、現在の対象マクロブロックの動き探索の結果にもとづいて、次の対象マクロブロックで先読みする画素データを決め、第2先読み用SRAM64bに転送したり、現在の対象マクロブロックについての先読みデータの内、次の対象マクロブロックでも利用するデータがあれば、そのデータを第1先読み用SRAM64aから第2先読み用SRAM64bにコピーすることもできる。
Thereby, when the processing of the next target macroblock is started, since the pixel data has already been prefetched in the
以上、本発明を実施の形態をもとに説明した。実施の形態は例示であり、それらの各構成要素や各処理プロセスの組み合わせにいろいろな変形例が可能なこと、またそうした変形例も本発明の範囲にあることは当業者に理解されるところである。 The present invention has been described based on the embodiments. The embodiments are exemplifications, 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 within the scope of the present invention. .
上記の説明では、先読み用SRAM64と通常のSRAM66とを物理的に別々に設けたが、1つのSRAMを論理的に先読み用のメモリ領域と通常のメモリ領域とに分けてそれぞれの機能をもたせてもよい。
In the above description, the
20 DCT部、 30 量子化部、 60 動き補償部、 62 動きベクトル検出部、 64、65 先読み用SRAM、 66 SRAM、 67 アドレス変換部、 68 動き補償予測部、 80 フレームメモリ、 82 SBUS、 90 可変長符号化部、 100 符号化装置。 20 DCT section, 30 quantization section, 60 motion compensation section, 62 motion vector detection section, 64, 65 prefetch SRAM, 66 SRAM, 67 address conversion section, 68 motion compensation prediction section, 80 frame memory, 82 SBUS, 90 variable A long encoding unit, 100 encoding apparatus.
Claims (9)
符号化対象フレームの対象ブロックの動き検出をする際に参照する参照フレームを保持するフレームメモリと、
前記フレームメモリに保持された前記参照フレームを参照して、動き探索を繰り返して前記対象ブロックの動き検出を行う動き検出部とを含み、
前記動き検出部は、前記参照フレーム内の画素データの内、動き探索の際に参照する頻度の高い画素データをあらかじめ前記フレームメモリから転送して保持する先読み用メモリを有することを特徴とする符号化装置。 An encoding device for encoding a frame of a moving image,
A frame memory that holds a reference frame to be referred to when motion detection of the target block of the encoding target frame is performed;
A motion detector that refers to the reference frame stored in the frame memory and performs motion detection by repeating motion search,
The motion detection unit includes a prefetch memory that transfers pixel data frequently referenced during motion search from the frame memory and holds the pixel data in the reference frame. Device.
前記動き検出部は、対象ブロックの動き検出を開始する際に、少なくとも一部のタイルに格納された、前回の対象ブロックの動き探索で参照された画素データを破棄しないで今回の対象ブロックの動き探索に再利用することを特徴とする請求項1から3のいずれかに記載の符号化装置。 The prefetch memory is configured such that the storage area is divided into a plurality of tiles, and data can be updated in units of tiles.
When the motion detection unit starts motion detection of the target block, the motion detection unit does not discard the pixel data referred to in the previous motion search of the target block stored in at least some of the tiles. The encoding apparatus according to claim 1, wherein the encoding apparatus is reused for searching.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005087739A JP4346573B2 (en) | 2005-03-25 | 2005-03-25 | Encoding apparatus and method |
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 |
---|---|---|---|
JP2005087739A JP4346573B2 (en) | 2005-03-25 | 2005-03-25 | Encoding apparatus and method |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2006270683A true JP2006270683A (en) | 2006-10-05 |
JP4346573B2 JP4346573B2 (en) | 2009-10-21 |
Family
ID=37206145
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2005087739A Expired - Fee Related JP4346573B2 (en) | 2005-02-24 | 2005-03-25 | Encoding apparatus and method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP4346573B2 (en) |
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2008136178A1 (en) | 2007-04-26 | 2008-11-13 | Panasonic Corporation | Motion detection apparatus, motion detection method, and motion detection program |
JP2009290387A (en) * | 2008-05-28 | 2009-12-10 | Hitachi Ltd | Encoder, decoder and recording reproducing device |
JPWO2008111451A1 (en) * | 2007-03-14 | 2010-06-24 | 日本電信電話株式会社 | Motion vector search method and apparatus, program thereof, and recording medium storing program |
US8265142B2 (en) | 2007-03-14 | 2012-09-11 | Nippon Telegraph And Telephone Corporation | Encoding bit-rate control method and apparatus, program therefor, and storage medium which stores the program |
JP2012239093A (en) * | 2011-05-13 | 2012-12-06 | Kawasaki Microelectronics Inc | Image processing device |
JP2013157681A (en) * | 2012-01-27 | 2013-08-15 | Fujitsu Semiconductor Ltd | Video decoder and video decoding method |
US9161042B2 (en) | 2007-03-14 | 2015-10-13 | Nippon Telegraph And Telephone Corporation | Quantization control method and apparatus, program therefor, and storage medium which stores the program |
US9455739B2 (en) | 2007-03-14 | 2016-09-27 | Nippon Telegraph And Telephone Corporation | Code amount estimating method and apparatus, and program and storage medium therefor |
WO2022206166A1 (en) * | 2021-04-01 | 2022-10-06 | Oppo广东移动通信有限公司 | Method and device for performing image processing in a video encoding device, and system |
-
2005
- 2005-03-25 JP JP2005087739A patent/JP4346573B2/en not_active Expired - Fee Related
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPWO2008111451A1 (en) * | 2007-03-14 | 2010-06-24 | 日本電信電話株式会社 | Motion vector search method and apparatus, program thereof, and recording medium storing program |
US8265142B2 (en) | 2007-03-14 | 2012-09-11 | Nippon Telegraph And Telephone Corporation | Encoding bit-rate control method and apparatus, program therefor, and storage medium which stores the program |
US8396130B2 (en) | 2007-03-14 | 2013-03-12 | Nippon Telegraph And Telephone Corporation | Motion vector search method and apparatus, program therefor, and storage medium which stores the program |
US9161042B2 (en) | 2007-03-14 | 2015-10-13 | Nippon Telegraph And Telephone Corporation | Quantization control method and apparatus, program therefor, and storage medium which stores the program |
US9455739B2 (en) | 2007-03-14 | 2016-09-27 | Nippon Telegraph And Telephone Corporation | Code amount estimating method and apparatus, and program and storage medium therefor |
WO2008136178A1 (en) | 2007-04-26 | 2008-11-13 | Panasonic Corporation | Motion detection apparatus, motion detection method, and motion detection program |
JP2009290387A (en) * | 2008-05-28 | 2009-12-10 | Hitachi Ltd | Encoder, decoder and recording reproducing device |
JP2012239093A (en) * | 2011-05-13 | 2012-12-06 | Kawasaki Microelectronics Inc | Image processing device |
JP2013157681A (en) * | 2012-01-27 | 2013-08-15 | Fujitsu Semiconductor Ltd | Video decoder and video decoding method |
WO2022206166A1 (en) * | 2021-04-01 | 2022-10-06 | Oppo广东移动通信有限公司 | Method and device for performing image processing in a video encoding device, and system |
Also Published As
Publication number | Publication date |
---|---|
JP4346573B2 (en) | 2009-10-21 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4346573B2 (en) | Encoding apparatus and method | |
US8019000B2 (en) | Motion vector detecting device | |
KR100952861B1 (en) | Processing digital video data | |
KR101177666B1 (en) | Intelligent decoded picture buffering | |
JP4764807B2 (en) | Motion vector detection apparatus and motion vector detection method | |
EP1065883B1 (en) | Image predictive decoding method | |
US20060050976A1 (en) | Caching method and apparatus for video motion compensation | |
US20070217702A1 (en) | Method and apparatus for decoding digital video stream | |
KR19980041898A (en) | Temporary Compression Method and Search Processor for Digital Video Data Streams | |
JP4606311B2 (en) | Image coding apparatus and image coding method | |
WO2008029550A1 (en) | Image data processing method, program for image data processing method, recording medium with recorded program for image data processing method and image data processing device | |
JP4709155B2 (en) | Motion detection device | |
US7843993B2 (en) | Moving picture encoding apparatus having increased encoding speed and method thereof | |
US20080089418A1 (en) | Image encoding apparatus and memory access method | |
US9253493B2 (en) | Fast motion estimation for multiple reference pictures | |
US9363524B2 (en) | Method and apparatus for motion compensation reference data caching | |
JPH11308617A (en) | Digital image coder and motion vector detector used therefor | |
JP5020391B2 (en) | Decoding device and decoding method | |
JP2007096540A (en) | Coding method | |
JPH11328369A (en) | Cache system | |
JP2011097488A (en) | Video compression encoder | |
KR20020008976A (en) | Motion estimator architecture for low bit rate image communication | |
JP2001045493A (en) | Moving image encoding device, moving image output device and storage medium | |
JP2008258769A (en) | Image encoding device and control method thereof, and computer program | |
KR100955828B1 (en) | Reference Frame Selection Method for Motion Estimation of High Performance Multimedia Codec |
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: 20080715 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20080821 |
|
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: 20090616 |
|
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: 20090714 |
|
R151 | Written notification of patent or utility model registration |
Ref document number: 4346573 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: 20120724 Year of fee payment: 3 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20130724 Year of fee payment: 4 |
|
LAPS | Cancellation because of no payment of annual fees |