JP5182285B2 - Decoding method and decoding apparatus - Google Patents

Decoding method and decoding apparatus Download PDF

Info

Publication number
JP5182285B2
JP5182285B2 JP2009506153A JP2009506153A JP5182285B2 JP 5182285 B2 JP5182285 B2 JP 5182285B2 JP 2009506153 A JP2009506153 A JP 2009506153A JP 2009506153 A JP2009506153 A JP 2009506153A JP 5182285 B2 JP5182285 B2 JP 5182285B2
Authority
JP
Japan
Prior art keywords
data
integrated
read
area
storage device
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
JP2009506153A
Other languages
Japanese (ja)
Other versions
JPWO2008117440A1 (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
Publication of JPWO2008117440A1 publication Critical patent/JPWO2008117440A1/en
Application granted granted Critical
Publication of JP5182285B2 publication Critical patent/JP5182285B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/42Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation
    • H04N19/43Hardware specially adapted for motion estimation or compensation
    • H04N19/433Hardware specially adapted for motion estimation or compensation characterised by techniques for memory access
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/44Decoders specially adapted therefor, e.g. video decoders which are asymmetric with respect to the encoder
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation

Description

本発明は、デコード方法及びデコード装置に係り、特にフレーム間予測を行う動画圧縮方式で圧縮された画像データを伸張するデコード方法及びデコード装置に関する。   The present invention relates to a decoding method and a decoding apparatus, and more particularly to a decoding method and a decoding apparatus for expanding image data compressed by a moving image compression method for performing inter-frame prediction.

通常、動画においては、時間的に近い画像同士は画像情報が似ているため、時間的に近い画像を現在の処理領域の元画像として使用することができる。MPEG-2、MPEG-4、H.264等の規格に代表されるフレーム間予測を行う動画圧縮方式では、このような考え方を採用している。   Usually, in a moving image, image information similar in time is similar to each other, and therefore an image close in time can be used as an original image of the current processing region. Such a concept is adopted in a moving picture compression method that performs inter-frame prediction represented by standards such as MPEG-2, MPEG-4, and H.264.

フレーム間予測を行う動画圧縮方式で圧縮されたデータを伸張するデコード装置では、通常は一度デコードされた画像データは外部記憶装置に格納され、別のフレームを処理するときに必要な領域、即ち、参照画像の画像データを外部記憶装置から読み出して使用する。   In a decoding device that decompresses data compressed by a moving image compression method that performs inter-frame prediction, image data that has been decoded once is usually stored in an external storage device, that is, an area necessary for processing another frame, that is, The image data of the reference image is read from the external storage device and used.

ところが、H.264等の近年の圧縮方式では、参照画像の読み出し単位が極小化し、外部記憶装置からの参照画像の読み出し回数及び全体としての読み出し画像データの量も増大している。例えば、H.264ではMPEG-2と比べると読み出し回数が最大で16倍、全体としての読み出し画像データの量が最大で5倍になる。   However, in recent compression schemes such as H.264, the reference image read unit has been minimized, and the number of reference image reads from the external storage device and the amount of read image data as a whole have also increased. For example, in H.264, the number of times of reading is 16 times at the maximum and the amount of read image data as a whole is 5 times at maximum as compared with MPEG-2.

外部記憶装置へのアクセスを低減する方法として、復号化済みのマクロブロックの隅に位置するブロックの動きベクトルに応じて、検出方法を選択し、選択された方法により動きベクトルを検出し、動きベクトルに基づいて動き補償対象ブロックの予測画像を生成するものがある(特許文献1を参照)。
特開2004−194283号公報
As a method of reducing access to the external storage device, a detection method is selected according to a motion vector of a block located at a corner of a decoded macroblock, and a motion vector is detected by the selected method. There is one that generates a predicted image of a motion compensation target block based on (see Patent Document 1).
JP 2004-194283 A

H.264等の近年の圧縮方式では、高精細な画像を扱うため、外部記憶装置からの参照画像の読み出し回数及び読み出し画像データの量が増大しており、規格の要求性能を満たすために、外部記憶装置へのアクセスを制御するメモリコントローラや制御部の動作周波数を増加、或いは、外部記憶装置の動作周波数を増加したり数を増やす等の対策が必要である。このため、デコード装置の回路規模が増大し、これに伴い製造コスト及び消費電力が増大してしまうという問題があった。   In recent compression methods such as H.264, in order to handle high-definition images, the number of times of reference image reading from the external storage device and the amount of read image data are increasing, and in order to satisfy the required performance of the standard, It is necessary to take measures such as increasing the operating frequency of the memory controller or the control unit for controlling access to the external storage device, or increasing the operating frequency or the number of the external storage device. For this reason, there has been a problem that the circuit scale of the decoding device increases, and the manufacturing cost and power consumption increase accordingly.

本発明は、メモリへのアクセス回数及びアクセスされるデータ量を低減し、回路の規模を小さく抑え、製造コストと消費電力を低減することが可能なデコード方法及びデコード装置を提供することを目的とする。   An object of the present invention is to provide a decoding method and a decoding apparatus capable of reducing the number of accesses to a memory and the amount of accessed data, reducing the circuit scale, and reducing the manufacturing cost and power consumption. To do.

上記の課題は、フレーム間予測を行う動画圧縮方式で圧縮されたビデオストリームを記憶装置から読み出し、デコード済のフレームを参照画像としてデコード処理に利用するデコード方法であって、前記ビデオストリームから抽出された動きベクトル情報に基づいて前記参照画像を演算し、前記参照画像に基づいて予測画像を生成し、前記参照画像の処理単位内の各領域を複数の領域を統合して前記記憶装置から読み出すか否かを、前記複数の領域を統合して読み出す場合のバス占有時間と各領域を個別に読み出す場合のバス占有時間を比較することで判定し、各領域を個別に読み出す場合のバス占有時間は、各領域の読み出しサイクルと前記記憶装置のアクセス毎のオーバーヘッドを加算することで算出し、前記複数の領域を統合して読み出す場合のバス占有時間は、統合した領域の読み出しサイクルと前記記憶装置のアクセスのオーバーヘッドを加算することで算出し、前記複数の領域を統合して読み出す場合のバス占有時間の方が短く前記複数の領域を統合して読み出すと判定された場合は、前記記憶装置から読み出すデータ量が増加する場合も統合する複数の領域を前記記憶装置から同時に読み出ことを特徴とするデコード方法により達成できる。 The above-described problem is a decoding method in which a video stream compressed by a moving image compression method for performing inter-frame prediction is read from a storage device, and a decoded frame is used as a reference image for decoding processing, which is extracted from the video stream. Whether the reference image is calculated based on the motion vector information, a predicted image is generated based on the reference image, and each region in the processing unit of the reference image is read from the storage device by integrating a plurality of regions. Is determined by comparing the bus occupancy time when reading the multiple areas together with the bus occupancy time when reading each area individually, and the bus occupancy time when reading each area individually is , Calculated by adding the read cycle of each area and the overhead for each access of the storage device, and reading the integrated multiple areas Bus occupation time to case, calculated by adding the overhead of accessing the storage device and read cycle of integration areas, short plurality towards the bus occupation time of reading by integrating the plurality of regions If it is determined that read by integrating the area can be achieved by decoding method characterized in that also be read out simultaneously a plurality of regions to be integrated from the storage device if the amount of data read from the storage device increases .

上記の課題は、フレーム間予測を行う動画圧縮方式で圧縮されたビデオストリームを記憶装置から読み出し、デコード済のフレームを参照画像としてデコード処理に利用するデコード装置であって、前記ビデオストリームから抽出された動きベクトル情報に基づいて前記参照画像を演算する演算部と、前記参照画像に基づいて予測画像を生成する生成部と、 前記参照画像の処理単位内の各領域を複数の領域を統合して前記記憶装置から読み出すか否かを、前記複数の領域を統合して読み出す場合のバス占有時間と各領域を個別に読み出す場合のバス占有時間を比較することで判定する統合判定部を備え、前記統合判定部は、各領域を個別に読み出す場合のバス占有時間を、各領域の読み出しサイクルと前記記憶装置のアクセス毎のオーバーヘッドを加算することで算出し、前記複数の領域を統合して読み出す場合のバス占有時間を、統合した領域の読み出しサイクルと前記記憶装置のアクセスのオーバーヘッドを加算することで算出し、前記複数の領域を統合して読み出す場合のバス占有時間の方が短く前記複数の領域を統合して読み出すと判定された場合は、前記記憶装置から読み出すデータ量が増加する場合も統合する複数の領域を前記記憶装置から同時に読み出ことを特徴とするデコード装置により達成できる。 The above problem is a decoding device that reads a video stream compressed by a moving image compression method for performing inter-frame prediction from a storage device, and uses the decoded frame as a reference image for decoding processing, and is extracted from the video stream. A calculation unit that calculates the reference image based on the motion vector information, a generation unit that generates a prediction image based on the reference image, and a plurality of regions within each processing unit of the reference image are integrated. Including an integrated determination unit that determines whether to read from the storage device by comparing the bus occupation time when the plurality of areas are read together and the bus occupation time when each area is read individually; The integrated determination unit determines the bus occupancy time when each area is individually read out as an overhead for each area read cycle and each access of the storage device. A bus occupancy time when the plurality of areas are read together and calculated by adding a read cycle of the integrated area and an access overhead of the storage device. If it is determined that the bus occupancy time in the case of reading and integrating the plurality of areas is shorter and the plurality of areas are read together, the plurality of areas to be integrated are also selected even when the amount of data read from the storage device increases. It can be achieved by the decoding apparatus characterized by be read out simultaneously from the storage device.

本発明によれば、メモリへのアクセス回数及びアクセスされるデータ量を低減し、回路の規模を小さく抑え、製造コストと消費電力を低減することが可能なデコード方法及びデコード装置を実現できる。   ADVANTAGE OF THE INVENTION According to this invention, the decoding method and decoding apparatus which can reduce the frequency | count of access to memory and the amount of data accessed, hold down the scale of a circuit, and can reduce manufacturing cost and power consumption are realizable.

本発明の一実施例におけるデコード装置の構成を示すブロック図である。It is a block diagram which shows the structure of the decoding apparatus in one Example of this invention. 読み出し領域の統合を説明する図である。It is a figure explaining integration of a read-out area. DDR−SDRAMのアクセスタイミングを説明するタイミングチャートである。It is a timing chart explaining the access timing of DDR-SDRAM. ブロックを個別に読み出したときと、統合して読み出したときのバスの占有時間を説明する図である。It is a figure explaining the occupancy time of the bus | bath when a block is read separately, and reading is integrated. 既に統合データ記憶部に格納されている領域と、フレーム間予測部内の現在の処理で必要な領域を示す図である。It is a figure which shows the area | region already stored in the integrated data memory | storage part, and the area | region required by the present process in the inter-frame prediction part. 図5に示すデータの再利用を説明する図である。It is a figure explaining reuse of the data shown in FIG. 統合データの再利用を説明するブロック図である。It is a block diagram explaining reuse of integrated data. 統合データの再利用を説明するブロック図である。It is a block diagram explaining reuse of integrated data. 統合データの再利用を説明するブロック図であある。It is a block diagram explaining reuse of integrated data. 統合データの再利用を説明するブロック図である。It is a block diagram explaining reuse of integrated data. 実施例における統合読み出し制御を説明するフローチャートである。It is a flowchart explaining the integrated reading control in an Example. 統合判定処理を説明するフローチャートである。It is a flowchart explaining an integrated determination process. データ読み出し範囲判定処理を説明するフローチャートである。It is a flowchart explaining a data reading range determination process. コピー処理を説明するフローチャートである。It is a flowchart explaining a copy process. リクエスト処理を説明するフローチャートである。It is a flowchart explaining a request process. データを流用しない場合の読み出し制御を説明するフローチャートである。It is a flowchart explaining the read-out control when not diverting data. データを流用しない場合のリクエスト処理を説明するフローチャートである。It is a flowchart explaining the request process when not diverting data.

符号の説明Explanation of symbols

1 デコード装置
11 ストリーム入力部
12 デコード処理部
13 表示制御部
14 SDRAM
21 エントロピーデコーダ
22 係数デコーダ
23 フレーム間予測部
24 画像生成部
25 読み出し予測画像解析部
26 統合データ記憶部
27 メモリコントローラ
30 外部記憶装置
DESCRIPTION OF SYMBOLS 1 Decoding apparatus 11 Stream input part 12 Decoding process part 13 Display control part 14 SDRAM
21 Entropy decoder 22 Coefficient decoder 23 Inter-frame prediction unit 24 Image generation unit 25 Read prediction image analysis unit 26 Integrated data storage unit 27 Memory controller 30 External storage device

本発明は、フレーム間予測を行う動画圧縮方式で圧縮され記憶装置に格納されたビデオストリームを読み出し、動き予測を利用してエンコードされたフレームをデコードする際には、それ以前にデコードしたフレームを参照画像としてデコード処理に利用する。ビデオストリームから抽出された動きベクトル情報に基づいて参照画像を演算し、記憶装置から読み出した参照画像のデータに基づいて予測画像を生成し、各領域の読み出しサイクル、又は、記憶装置のアクセス毎のオーバーヘッド、又は、記憶装置をアクセスするのに用いるバスの占有時間に基づいて参照画像の形状を決定する。   The present invention reads a video stream compressed by a moving image compression method for performing inter-frame prediction and stored in a storage device, and decodes an encoded frame using motion prediction. Used as a reference image for decoding processing. A reference image is calculated based on the motion vector information extracted from the video stream, a predicted image is generated based on the reference image data read from the storage device, and a read cycle of each area or each access of the storage device The shape of the reference image is determined based on the overhead or the occupied time of the bus used to access the storage device.

上記参照画像の決定は、参照画像のデータを読み出す際に、データの処理単位内の各領域について他の領域のデータと統合して読み出すか否かを判定し、統合して読み出すと判定されたときには統合する領域のデータを記憶装置から同時に読み出す統合判定を含んでも良い。この場合、統合判定は、各領域の読み出しサイクル、又は、記憶装置のアクセス毎のオーバーヘッド、又は、バスの占有時間に基づいてこの判定を行う。   When the reference image data is read, it is determined whether or not each of the areas in the data processing unit is read out in combination with the data of other areas, and the reference image is determined to be read out in an integrated manner. Sometimes, it may include integration determination for simultaneously reading the data of the areas to be integrated from the storage device. In this case, the integrated determination is performed based on the read cycle of each area, the overhead for each access of the storage device, or the bus occupation time.

以下に、本発明のデコード方法及びデコード装置の各実施例を図面と共に説明する。   Embodiments of a decoding method and a decoding apparatus according to the present invention will be described below with reference to the drawings.

図1は、本発明の一実施例におけるデコード装置の構成を示すブロック図である。デコード装置1は、図1に示す如く接続されたストリーム入力部11、デコード処理部12、表示制御部13及びメモリ制御部(以下、SDRAM(Synchronous Dynamic Random Access Memory)制御部と言う)14を有する。デコード処理部12は、エントロピーデコーダ(又は、ストリーム解析部)21、係数デコーダ22、フレーム間予測部23、画像生成部24、読み出し予測画像解析部25、統合データ記憶部26及びメモリコントローラ27を有する。デコード装置1は、例えば1チップで構成される半導体装置、或いは、複数のチップからなるマルチチップモジュール(MCM)で構成される半導体装置である。   FIG. 1 is a block diagram showing a configuration of a decoding apparatus according to an embodiment of the present invention. The decoding apparatus 1 includes a stream input unit 11, a decoding processing unit 12, a display control unit 13, and a memory control unit (hereinafter referred to as an SDRAM (Synchronous Dynamic Random Access Memory) control unit) 14 connected as shown in FIG. . The decoding processing unit 12 includes an entropy decoder (or stream analysis unit) 21, a coefficient decoder 22, an inter-frame prediction unit 23, an image generation unit 24, a read prediction image analysis unit 25, an integrated data storage unit 26, and a memory controller 27. . The decoding device 1 is, for example, a semiconductor device configured by one chip or a semiconductor device configured by a multichip module (MCM) including a plurality of chips.

外部記憶装置30は、デコード装置1のSDRAM制御部14に接続されている。本実施例では、外部記憶装置30はSDRAMで構成されており、デコード装置1とは別体である。しかし、デコード装置1と外部記憶装置30は単一のモジュールを構成するものであっても良いことは言うまでもない。   The external storage device 30 is connected to the SDRAM control unit 14 of the decoding device 1. In this embodiment, the external storage device 30 is composed of SDRAM and is separate from the decoding device 1. However, it goes without saying that the decoding device 1 and the external storage device 30 may constitute a single module.

デコード装置1は、MPEG-1、MPEG-2、MPEG-4、H.264、VC-1等の規格に代表されるフレーム間予測を行う動画圧縮方式で圧縮された動画像のビデオストリームを伸張(復号)する。デコード装置1は、例えばビデオプレーヤ/レコーダやビデオカメラ等のビデオ再生機能を備えた装置に搭載される。   The decoding device 1 decompresses a video stream of a moving image compressed by a moving image compression method that performs inter-frame prediction represented by standards such as MPEG-1, MPEG-2, MPEG-4, H.264, and VC-1. (Decrypt) The decoding device 1 is mounted on a device having a video playback function such as a video player / recorder or a video camera.

ストリーム入力部11に入力されたビデオストリームは、SDRAM制御部14を介して一旦外部記憶装置30に格納される。デコード処理部12は、外部記憶装置30からビデオストリームを読み出してデコード処理を行い、デコード画像を外部記憶装置30に再び格納する。又、デコード処理部12は、動き予測を利用してエンコードされたフレームをデコードする際には、それ以前にデコードしたフレームのデータを外部記憶装置30から読み込み、そのフレームを参照画像としてデコード処理に利用する。表示制御部13は、外部記憶装置30に格納されたデコード画像を表示順に読み出し、図示しないビデオインタフェース回路等に表示用画像信号として出力する。これにより、表示用画像信号が、図示しない表示装置の画面上に表示される。   The video stream input to the stream input unit 11 is temporarily stored in the external storage device 30 via the SDRAM control unit 14. The decode processing unit 12 reads the video stream from the external storage device 30 and performs a decoding process, and stores the decoded image in the external storage device 30 again. In addition, when decoding a frame encoded using motion prediction, the decode processing unit 12 reads data of a previously decoded frame from the external storage device 30 and performs the decoding process using the frame as a reference image. Use. The display control unit 13 reads out the decoded images stored in the external storage device 30 in the display order, and outputs them as display image signals to a video interface circuit or the like (not shown). As a result, the display image signal is displayed on the screen of a display device (not shown).

デコード処理部12において、エントロピーデコーダ21は、外部記憶装置300に格納されたビデオストリームを、外部記憶装置30に対するインタフェースとして機能するSDRAM制御部14を介して読み込み、動きベクトル、DCT(Discrete Cosine Transform)係数等のデコード処理に必要な各種情報を抽出する。本実施例は、デコード処理部12内に読み出し予測画像解析部25及び統合データ記憶部26が設けられている点に特に特徴がある。   In the decoding processing unit 12, the entropy decoder 21 reads a video stream stored in the external storage device 300 via the SDRAM control unit 14 that functions as an interface to the external storage device 30, and motion vectors, DCT (Discrete Cosine Transform). Various information necessary for decoding processing such as coefficients is extracted. This embodiment is particularly characterized in that a read prediction image analysis unit 25 and an integrated data storage unit 26 are provided in the decode processing unit 12.

フレーム間予測部23は、ビデオストリームから抽出された動きベクトル等の情報に基づいて参照画像を演算し、参照画像のデータを外部記憶装置30から読み出し、読み出したデータに基づいて予測画像を生成する。後述するように、参照画像のデータの読み出しの際には、データの処理単位内の各領域について他の領域のデータと統合して読み出した方が良いか否かを読み出し予測画像解析部25で判定し、統合した方が外部記憶装置30をアクセスするのに用いるバス(即ち、デコード装置1と外部記憶装置30を接続するバス)の占有時間が短くなり良いと判定されたときには統合する領域のデータを外部記憶装置30から同時に読み出す。統合データ記憶部26には、外部記憶装置30から読み出した統合された領域のデータ、即ち、統合データが格納される。既に統合データ記憶部26に格納された統合データを参照画像のデータの一部として流用可能な場合には、統合データ記憶部26から読み出して再利用する。本明細書では、このような読み出し制御を「統合読み出し制御」と呼ぶものとする。   The inter-frame prediction unit 23 calculates a reference image based on information such as a motion vector extracted from the video stream, reads the reference image data from the external storage device 30, and generates a predicted image based on the read data. . As will be described later, when the reference image data is read, the read predicted image analysis unit 25 determines whether it is better to read each region in the data processing unit in combination with the data of other regions. If it is determined that the occupancy time of the bus used for accessing the external storage device 30 (ie, the bus connecting the decoding device 1 and the external storage device 30) is shorter when it is determined and integrated, Data is read from the external storage device 30 simultaneously. The integrated data storage unit 26 stores integrated area data read from the external storage device 30, that is, integrated data. If the integrated data already stored in the integrated data storage unit 26 can be used as part of the reference image data, it is read from the integrated data storage unit 26 and reused. In this specification, such read control is referred to as “integrated read control”.

係数デコーダ22は、エントロピーデコーダ21により抽出された係数情報を用いて逆量子化及び逆DCT変換の演算を行い、予測誤差を復元する。画像生成部24は、フレーム間予測部23により生成された予測画像のデータに係数デコーダ22で復元された予測誤差を加算してデコード画像を生成し、外部記憶装置30に格納する。   The coefficient decoder 22 performs inverse quantization and inverse DCT transform using the coefficient information extracted by the entropy decoder 21 to restore a prediction error. The image generation unit 24 adds the prediction error restored by the coefficient decoder 22 to the prediction image data generated by the inter-frame prediction unit 23, generates a decoded image, and stores the decoded image in the external storage device 30.

通常、参照画像が細分化されたとしても、同一矩形の領域(マクロブロック)、或いは、隣接マクロブロックにおいては近い部分を参照画像として読み出してくることが多い。そこで、読み出し予測画像解析部25において、隣接する複数の領域をまとめて、1つの読み出し領域として統合する。その統合された領域を外部記憶装置30からまとめて読み出し、統合データ記憶部26に格納する。後に、フレーム間予測の演算をする際に、フレーム間予測部23で必要な部分だけを統合データ記憶部26から読み出し、外部記憶装置30からも必要に応じてデータを読み出して、フレーム間予測部23でフレーム間予測を行う。   In general, even if the reference image is subdivided, the same rectangular area (macroblock) or an adjacent macroblock is often read as a reference image. Therefore, the read predicted image analysis unit 25 integrates a plurality of adjacent areas as one read area. The integrated area is collectively read from the external storage device 30 and stored in the integrated data storage unit 26. Later, when calculating the inter-frame prediction, only the necessary part in the inter-frame prediction unit 23 is read out from the integrated data storage unit 26, and the data is also read out from the external storage device 30 as necessary. 23, inter-frame prediction is performed.

本実施例では、フレーム間予測部23は、ビデオストリームから抽出された動きベクトル情報に基づいて参照画像を演算する演算手段と、参照画像のデータを外部記憶装置30から読み出し、読み出したデータに基づいて予測画像を生成する手段を含む。又、後述するように、読み出し予測画像解析部25は、各領域の読み出しサイクル、又は、外部記憶装置30のアクセス毎のオーバーヘッド、又は、外部記憶装置30をアクセスするのに用いるバスの占有時間に基づいて参照画像の形状を決定する決定手段を含む。この決定手段は、参照画像のデータを読み出す際に、データの処理単位内の各領域について他の領域のデータと統合して読み出すか否かを判定し、統合して読み出すと判定されたときには統合する領域のデータを外部記憶装置30から同時に読み出す統合判定手段を有する。   In the present embodiment, the inter-frame prediction unit 23 reads a reference image based on motion vector information extracted from the video stream, and reads the reference image data from the external storage device 30, and based on the read data. Means for generating a predicted image. Further, as will be described later, the read predicted image analysis unit 25 determines the read cycle of each area, the overhead for each access of the external storage device 30, or the occupied time of the bus used to access the external storage device 30. A determining unit configured to determine a shape of the reference image based on the reference image; When the reference image data is read, the determining unit determines whether or not each area in the data processing unit is to be integrated with the data of the other areas, and when it is determined to be integrated and read, Integrated determination means for simultaneously reading out data of the area to be read from the external storage device 30.

図2は、読み出し領域の統合を説明する図である。図2は、1マクロブロック当たりの読み出しリクエスト(要求)のある領域(ブロック)Bが7個の場合を示す。この場合、読み出し予測画像解析部25は、(a)で示す7個のブロックBのうち、左側の隣接する2個のブロックBを(b)のハッチングで示す領域を含むように1つの読み出し領域IRに統合し、右側の隣接する5個のブロックBを(b)のハッチングで示す領域を含むように1つの読み出し領域IRに統合する。又、(b)に示す2個の統合された読み出し領域IRは、統合データ記憶部26に格納される。従って、フレーム間予測部23でフレーム間予測の演算をする際には、(c)に示す統合データ記憶部26内の統合された読み出し領域IRのうち、必要な部分(ブロックB)だけを読み出し予測画像解析部25を介して読み出して使用する。   FIG. 2 is a diagram for explaining integration of readout areas. FIG. 2 shows a case where there are seven areas (blocks) B having a read request (request) per macroblock. In this case, the read predicted image analysis unit 25 includes one read area so that the left two adjacent blocks B among the seven blocks B indicated by (a) include the areas indicated by hatching (b). It is integrated into IR, and the adjacent five blocks B on the right side are integrated into one readout area IR so as to include the area indicated by hatching in (b). Also, the two integrated read areas IR shown in (b) are stored in the integrated data storage unit 26. Therefore, when the inter-frame prediction unit 23 calculates inter-frame prediction, only a necessary part (block B) is read out of the integrated read area IR in the integrated data storage unit 26 shown in (c). It reads out and uses through the prediction image analysis part 25. FIG.

次に、読み出し予測画像解析部25で行う演算を説明する前に、外部記憶装置30として使用し得る一般的なDDR−SDRAMのアクセスタイミングを、図3と共に説明する。図3は、DDR−SDRAMのアクセスタイミングを説明するタイミングチャートであり、DDR−SDRAMに入力されるクロック、アドレス指定及びデータ出力を示す。   Next, before explaining the calculation performed by the read predicted image analysis unit 25, a general DDR-SDRAM access timing that can be used as the external storage device 30 will be described with reference to FIG. FIG. 3 is a timing chart for explaining the access timing of the DDR-SDRAM, and shows the clock, address designation and data output input to the DDR-SDRAM.

外部記憶装置30にDDR−SDRAMが使用されている場合、先ず最初のサイクルでアクセスするDDR−SDRAMの行アドレス(Adr)が指定され、次のサイクルで列アドレス(Adr)が指定されることで、これらの2つのサイクルでアクセスするべきDDR−SDRAM内のアクセス領域が確定する。これに対し、図3の例では2.5サイクル後からデータが出力される。DDR−SDRAMでは、クロックの立ち上がりと立ち下がりの両エッジでデータが出力されるため、4ワード分のデータの読み出しは2サイクルで完了する。つまり、アドレス発行時点から4ワード分のデータを読むのに、2+2+2.5+(4/2)=6.5サイクルの時間が必要である。又、クロックの立下りでデータの読み出しが完了しても次の立ち上がりエッジで次のアドレスを指定することはできないので、実質的には2サイクルで終る読み出しのために、+5サイクルのオーバーヘッドが付加されることになる。   When a DDR-SDRAM is used for the external storage device 30, the row address (Adr) of the DDR-SDRAM accessed in the first cycle is specified first, and the column address (Adr) is specified in the next cycle. In these two cycles, an access area in the DDR-SDRAM to be accessed is determined. On the other hand, in the example of FIG. 3, data is output after 2.5 cycles. In the DDR-SDRAM, data is output at both the rising and falling edges of the clock, so reading of data for four words is completed in two cycles. That is, it takes 2 + 2 + 2.5 + (4/2) = 6.5 cycles to read 4 words of data from the address issuance point. Even if data reading is completed at the falling edge of the clock, the next address cannot be specified at the next rising edge, so an overhead of +5 cycles is added for reading that ends in two cycles. Will be.

このようなDDR−SDRAMのアクセス準備期間に加え、読み出し予測画像解析部25からの読み出しリクエストがDDR−SDRAMに到達するまでの間にはいくつかの回路ブロックが介在するため、更にオーバーヘッドが増加する。ここでは、説明の便宜上、この増加分のオーバーヘッドが+4サイクルであると仮定する。従って、この場合のオーバーヘッドは合計で9サイクルとなる。尚、この場合の合計のオーバーヘッドは、使用するDDR−SDRAMの種類やハードウェアの構成により変化するので、ハードウェア固有の値となる可能性が高いものの、上記9サイクルは一例にすぎない。   In addition to the DDR-SDRAM access preparation period, several circuit blocks are interposed before the read request from the read predicted image analysis unit 25 reaches the DDR-SDRAM, so that the overhead further increases. . Here, for convenience of explanation, it is assumed that this increased overhead is +4 cycles. Therefore, the overhead in this case is 9 cycles in total. Note that the total overhead in this case varies depending on the type of DDR-SDRAM used and the hardware configuration, so the above-mentioned nine cycles are merely examples, although there is a high possibility of being a value unique to the hardware.

2つのブロックBiとBjをDDR−SDRAMから読み出す際のバスの占有時間は、データ読み出しサイクル等の関数を次のように定義すると、
Biのデータ読み出しサイクル (= Biのワード数/2) = ReadCycle(Bi)
Bjのデータ読み出しサイクル (= Bjのワード数/2) = ReadCycle(Bj)
SDRAMアクセス毎のオーバーヘッド = Overhead
BiとBjを1つの矩形領域として統合する = merge(Bi,Bj)
BiとBjを個別に読み出したときのバスの占有時間は次のようになり、
ReadCycle(Bi) + ReadCycle(Bj) + Overhead×2
BiとBjを統合して読み出したときのバスの占有時間は次のようになる。
The bus occupancy time when reading the two blocks Bi and Bj from the DDR-SDRAM is defined as a function such as a data read cycle as follows:
Bi data read cycle (= Bi word number / 2) = ReadCycle (Bi)
Bj data read cycle (= number of words in Bj / 2) = ReadCycle (Bj)
Overhead for each SDRAM access = Overhead
Merge Bi and Bj as one rectangular area = merge (Bi, Bj)
The bus occupancy time when Bi and Bj are read separately is as follows:
ReadCycle (Bi) + ReadCycle (Bj) + Overhead × 2
The bus occupation time when Bi and Bj are integrated and read is as follows.

ReadCycle(merge(Bi,Bj)) + Overhead
図4は、ブロックBiとBjを個別に読み出したときのバスの占有時間と、統合して読み出したときのバスの占有時間を説明する図である。図4では、ReadCycle(Bi)=4、ReadCycle(Bj)=4、Overhead=9、ReadCycle(merge(Bi,Bj))=9であるものとする。図4に示す例の場合、ブロックBiとBjを個別に読み出したときのバスの占有時間(アクセス時間)は4+4+9×2=26サイクルとなり、ブロックBiとBjを統合して読み出したときのバスの占有時間(アクセス時間)は10+=19サイクルとなり、この場合はブロックBiとBjを統合して読み出した方がバスの占有時間が短いことが分かる。
ReadCycle (merge (Bi, Bj)) + Overhead
FIG. 4 is a diagram for explaining the bus occupation time when the blocks Bi and Bj are individually read and the bus occupation time when the blocks Bi and Bj are read together. In FIG. 4, it is assumed that ReadCycle (Bi) = 4, ReadCycle (Bj) = 4, Overhead = 9, and ReadCycle (merge (Bi, Bj)) = 9. In the case of the example shown in FIG. 4, the bus occupation time (access time) when the blocks Bi and Bj are read individually is 4 + 4 + 9 × 2 = 26 cycles, and the buses when the blocks Bi and Bj are read together are read. The occupation time (access time) is 10 + 9 = 19 cycles. In this case, it can be seen that the bus occupation time is shorter when the blocks Bi and Bj are integrated and read.

このように、オーバーヘッド分を考慮することにより、DDR−SDRAMから読み出すデータ量が増加したとしても、隣接ブロックを統合して読み出した方が効率的であることが分かる。   Thus, by considering the overhead, it can be seen that even if the amount of data read from the DDR-SDRAM increases, it is more efficient to read adjacent blocks in an integrated manner.

次に、隣接ブロックを統合した統合データを再利用することにより、アクセス量を更に減少する手法、即ち、統合読み出し制御について説明する。   Next, a method of further reducing the access amount by reusing integrated data obtained by integrating adjacent blocks, that is, integrated read control will be described.

先ず、統合データ記憶部26に格納された統合データの再利用について、図5乃至図10と共に説明する。ここでは説明の便宜上、1マクロブロック毎に統合読み出しを行うアルゴリズムを採用した場合の例を説明する。本実施例では、1マクロブロックの処理を1単位としているが、例えば2マクロブロックを1単位とする等、処理単位を変更しても同様の手法で演算が可能であることは言うまでもない。   First, reuse of integrated data stored in the integrated data storage unit 26 will be described with reference to FIGS. Here, for convenience of explanation, an example will be described in which an algorithm that performs integrated reading for each macroblock is employed. In the present embodiment, the processing of one macroblock is set as one unit, but it goes without saying that the same method can be used even if the processing unit is changed, for example, two macroblocks are set as one unit.

図5は、既に統合データ記憶部26に格納されている領域Pと、フレーム間予測部23内の現在の処理で必要な領域Biを示す図である。図5中、領域Pは太い実線で示し、領域Biは太い一点鎖線で示す。本実施例では、図5のような場合、一部のデータは既に外部記憶装置30から読み出されているので再利用する。   FIG. 5 is a diagram showing a region P already stored in the integrated data storage unit 26 and a region Bi necessary for the current processing in the inter-frame prediction unit 23. In FIG. 5, the region P is indicated by a thick solid line, and the region Bi is indicated by a thick alternate long and short dash line. In this embodiment, in the case shown in FIG. 5, some data has already been read from the external storage device 30 and is reused.

図6は、図5に示すデータの再利用を説明する図である。図6中、Pは既に過去のマクロブロックの処理で読み込んだ画像保持領域、Biは統合処理の結果、現在のマクロブロック処理において必要とされる現必要領域、Ciは上記2つの領域P,Biが重なる部分、即ち、流用可能な流用領域、Riは新たに外部記憶装置30から読み出す必要がある新規読込領域を示す。   FIG. 6 is a diagram for explaining the reuse of data shown in FIG. In FIG. 6, P is an image holding area that has already been read in the past macroblock processing, Bi is a current required area that is required in the current macroblock processing as a result of the integration process, and Ci is the above two areas P and Bi. , That is, a diversion area that can be diverted, Ri indicates a new read area that needs to be newly read from the external storage device 30.

図7乃至図10は、統合データの再利用を説明するブロック図であり、図1と同一部分には同一符号を付し、その説明は省略する。図7乃至図10中、26Aは統合データ記憶部26内の偶数番目のマクロブロックを格納する統合データ記憶領域、26Bは統合データ記憶部26内の奇数番目のマクロブロックを格納する統合データ記憶領域を示す。   7 to 10 are block diagrams for explaining the reuse of the integrated data. The same parts as those in FIG. 7 to 10, reference numeral 26A denotes an integrated data storage area for storing even-numbered macroblocks in the integrated data storage section 26, and 26B denotes an integrated data storage area for storing odd-numbered macroblocks in the integrated data storage section 26. Indicates.

統合データを再利用するために、統合データ記憶部26は、図7に示すように2つの統合データ記憶領域26A,26Bに分かれており、一方の統合データ記憶領域26Aに偶数番目マクロブロックデータを格納し、他方の統合データ記憶領域26Bに奇数番目マクロブロックデータを格納する。尚、統合データ記憶領域26A,26Bは、物理的に別体の記憶部により構成されていても良いことは言うまでもない。   In order to reuse the integrated data, the integrated data storage unit 26 is divided into two integrated data storage areas 26A and 26B as shown in FIG. 7, and even-numbered macroblock data is stored in one integrated data storage area 26A. The odd-numbered macroblock data is stored in the other integrated data storage area 26B. Needless to say, the integrated data storage areas 26A and 26B may be configured by physically separate storage units.

1番目のマクロブロックを処理する時点では、その前のマクロブロックのデータは無いのでデータの再利用はできないため、図8に破線の矢印Dinで示すように1番目のマクロブロックの全てのデータを外部記憶装置30から読み出して統合データ記憶領域26Aに格納するデータ入力を行う。   At the time of processing the first macroblock, since there is no data of the previous macroblock, the data cannot be reused. Therefore, as shown by the broken arrow Din in FIG. Data is read from the external storage device 30 and stored in the integrated data storage area 26A.

次のマクロブロックを処理する時点では、前のマクロブロックのデータの再利用が可能な場合には、図9に破線の矢印Dcopyで示すように前のマクロブロックのデータを統合データ記憶領域26Aから統合データ記憶領域26Bにコピーするデータコピーを行う。   At the time of processing the next macroblock, if the data of the previous macroblock can be reused, the data of the previous macroblock is transferred from the integrated data storage area 26A as indicated by the broken arrow Dcopy in FIG. Data copying to be performed on the integrated data storage area 26B is performed.

又、新たに読み出すマクロブロックのデータに関しては、図10に破線の矢印Dinで示すように外部記憶装置30から読み出して統合データ記憶領域26Bに格納するデータ入力を行う必要がある。   Further, regarding the macro block data to be newly read, it is necessary to input data to be read from the external storage device 30 and stored in the integrated data storage area 26B, as indicated by the broken line arrow Din in FIG.

上記の如き動作を、1マクロブロック毎に繰り返すことにより、続くマクロブロックを処理する際にも、前のマクロブロックで使用したデータを再利用することが可能となる。   By repeating the above operation for each macroblock, the data used in the previous macroblock can be reused even when the subsequent macroblock is processed.

図11は、上記一連の処理、即ち、本実施例における統合読み出し制御を説明するフローチャートである。図11において、ステップS1は、フレーム間予測部23により、1マクロブロック分の動きベクトル夫々に対する参照画像(即ち、統合前の領域)を演算する。ステップS2は、読み出し予測画像解析部25により、1マクロブロック内の各ブロックについて他のブロックのデータと統合した方が良いか否かを判定する統合判定処理を行う。ステップS3は、読み出し予測画像解析部25により、統合判定処理の結果に基づいて外部記憶装置30及び統合データ記憶部26からのデータの読み出し範囲を判定するデータ読み出し範囲判定処理を行う。ステップS4は、読み出し予測画像解析部25により、データ読み出し範囲判定処理に基づいて統合データ記憶部26からデータをコピーするコピー処理を行う。ステップS5は、読み出し予測画像解析部25により、データ読み出し範囲判定処理に基づいて統合データ記憶部26からのデータをリクエストするリクエスト処理を行い、処理は終了する。このようにして、1マクロブロック中の、夫々の動きベクトルに対する参照画像を求め、統合判定処理、データ読み出し範囲判定処理、コピー処理及びリクエスト処理を行う。   FIG. 11 is a flowchart for explaining the above series of processing, that is, integrated reading control in the present embodiment. In FIG. 11, in step S <b> 1, the inter-frame prediction unit 23 calculates a reference image (that is, a region before integration) for each motion vector for one macroblock. In step S <b> 2, the read prediction image analysis unit 25 performs integration determination processing for determining whether or not each block in one macroblock should be integrated with data of other blocks. In step S <b> 3, the read predicted image analysis unit 25 performs a data read range determination process for determining a data read range from the external storage device 30 and the integrated data storage unit 26 based on the result of the integration determination process. In step S4, the read predicted image analysis unit 25 performs a copy process of copying data from the integrated data storage unit 26 based on the data read range determination process. In step S5, the read predicted image analysis unit 25 performs a request process for requesting data from the integrated data storage unit 26 based on the data read range determination process, and the process ends. In this way, a reference image for each motion vector in one macroblock is obtained, and an integration determination process, a data read range determination process, a copy process, and a request process are performed.

図12は、ステップS2の統合判定処理を説明するフローチャートである。図12においてステップS201は統合判定の対象ブロック数をN(Nは1以上の整数)に設定し、ステップS202はiをi=1に設定する。統合判定の対象ブロック数Nは、1マクロブロック中の動きベクトル数と等しい。ステップS203は現必要領域(ブロック)Biがヌル(Null)であるか否かを判定する。ステップS203の判定結果がYESであると、ステップS204はjをj=1に設定する。ステップS205はi=j、且つ、現必要ブロックBiがNullであり、ブロックBiとBjの参照画像が同一であるか否かを判定する。ステップS205の判定結果がYESであると、ステップS206は個別読み出し時のアクセス時間が統合読み出し時のアクセス時間より長いか否かを判定する。つまり、ステップS206は、{ReadCycle(Bi) + ReadCycle(Bj) + Overhead×2}>{ReadCycle(merge(Bi,Bj)) + Overhead}であるか否かを判定する。   FIG. 12 is a flowchart illustrating the integration determination process in step S2. In FIG. 12, step S201 sets the number of target blocks for integration determination to N (N is an integer equal to or greater than 1), and step S202 sets i to i = 1. The number N of target blocks for integration determination is equal to the number of motion vectors in one macroblock. In step S203, it is determined whether or not the current necessary area (block) Bi is null. If the decision result in the step S203 is YES, a step S204 sets j to j = 1. In step S205, it is determined whether i = j, the current necessary block Bi is Null, and the reference images of the blocks Bi and Bj are the same. If the decision result in the step S205 is YES, a step S206 decides whether or not the access time at the individual reading is longer than the access time at the integrated reading. That is, step S206 determines whether {ReadCycle (Bi) + ReadCycle (Bj) + Overhead × 2}> {ReadCycle (merge (Bi, Bj)) + Overhead}.

ステップS206の判定結果がNOであると、ステップS207は現必要ブロックBiをBi=merge(Bi,Bj)に設定すると共に、ブロックBjをBj=NULLに設定し、処理はステップS208へ進む。他方、ステップS205の判定結果がNO、或いは、ステップS206の判定結果がYESであると、処理はステップS208へ進む。ステップS208はjをj=j+1に設定し、ステップS209はj>Nであるか否かを判定する。ステップS209の判定結果がNOであると処理はステップS205へ戻り、YESであると処置はステップS210へ進む。ステップS210はiをi=i+1に設定し、ステップS211はi=Nであるか否かを判定する。ステップS211の判定結果がNOであると処理はステップS203へ戻り、YESであると処理は終了する。   If the decision result in the step S206 is NO, a step S207 sets the current necessary block Bi to Bi = merge (Bi, Bj) and sets the block Bj to Bj = NULL, and the process advances to a step S208. On the other hand, if the determination result of step S205 is NO, or if the determination result of step S206 is YES, the process proceeds to step S208. In step S208, j is set to j = j + 1, and in step S209, it is determined whether j> N. If the determination result in step S209 is NO, the process returns to step S205, and if YES, the process proceeds to step S210. Step S210 sets i to i = i + 1, and step S211 determines whether i = N. If the determination result in step S211 is NO, the process returns to step S203, and if YES, the process ends.

このようにして、1マクロブロック内の各ブロックについて他のブロックのデータと統合した方が良いか否かを判定し、統合した方がデコード装置1と外部記憶装置30間のバスの占有時間が短くなり良いと判定されたときには統合するブロックのデータを同時に読み出す。又、ブロックのデータを個別に読み出すか、或いは、統合して読み出すかの判定を繰り返すことにより、最終的にどのような形状で参照画像を読み出すか、即ち、参照画像の取得範囲を決定する。   In this way, it is determined whether or not it is better to integrate each block in one macroblock with the data of other blocks, and the integrated time of the bus between the decoding device 1 and the external storage device 30 is determined. When it is determined that the data can be shortened, the data of the blocks to be integrated are read simultaneously. Further, by repeatedly determining whether the block data is individually read out or integratedly read out, the shape in which the reference image is finally read out, that is, the reference image acquisition range is determined.

図13は、ステップS3のデータ読み出し範囲判定処理を説明するフローチャートである。図13において、ステップS301はiをi=1に設定し、ステップS302は現必要領域(ブロック)Bi=Nullであるか否かを判定する。ステップS302の判定結果がYESであると、ステップS303は現必要ブロックBiの参照画像データを前のマクロブロックで使用しているか否かを判定する。ステップS303の判定結果がYESであると、ステップS304は新規読込領域Riを新規読込領域Ri=現必要領域Bi−画像保持領域Pに設定し、処理はステップS305へ進む。他方、ステップS302又はS303の判定結果がNOであると、処理は後述するステップS310へ進む。   FIG. 13 is a flowchart for explaining the data read range determination processing in step S3. In FIG. 13, step S301 sets i to i = 1, and step S302 determines whether or not the current necessary area (block) Bi = Null. If the decision result in the step S302 is YES, a step S303 decides whether or not the reference image data of the current necessary block Bi is used in the previous macro block. If the decision result in the step S303 is YES, a step S304 sets the new reading area Ri to the new reading area Ri = the current necessary area Bi−the image holding area P, and the process advances to the step S305. On the other hand, if the decision result in the step S302 or S303 is NO, the process advances to a step S310 described later.

ステップS305は、新規読込領域Ri=現必要領域Biであるか否かを判定し、判定結果がNOであると、ステップS306は新規読込領域Riは矩形であるか否かを判定する。ステップS306の判定結果がNOであると、データを再利用しないので、ステップS307で新規読込領域RiをRi=Biに設定すると共に流用領域CiをCi=Nullに設定し、処理はステップS310へ進む。ステップS306の判定結果がYESであると、データを再利用するので、ステップS308で流用領域CiをCi=Bi-Riに設定し、処理はステップS310へ進む。ステップS305の判定結果がYESであると、再利用できる領域はないため、ステップS309で流用領域CiをCi=Nullに設定し、処理はステップS310へ進む。   Step S305 determines whether or not the new reading area Ri = currently required area Bi. If the determination result is NO, step S306 determines whether or not the new reading area Ri is a rectangle. If the decision result in the step S306 is NO, since the data is not reused, the new reading area Ri is set to Ri = Bi and the diversion area Ci is set to Ci = Null in the step S307, and the process proceeds to the step S310. . If the decision result in the step S306 is YES, since the data is reused, the diversion area Ci is set to Ci = Bi-Ri in a step S308, and the process advances to a step S310. If the decision result in the step S305 is YES, since there is no area that can be reused, the diversion area Ci is set to Ci = Null in a step S309, and the process proceeds to a step S310.

ステップS310はiをi=i+1に設定し、ステップS311はi=Nであるか否かを判定する。ステップS311の判定結果がNOであると処理はステップS302へ戻り、YESであると処理は終了する。   Step S310 sets i to i = i + 1, and step S311 determines whether i = N. If the determination result in step S311 is NO, the process returns to step S302, and if YES, the process ends.

このようにして、流用領域Ciと新規読込領域Riを決定し、統合データ記憶部26からのデータのコピーと外部記憶装置30からのデータの読み出しを行う。   In this way, the diversion area Ci and the new reading area Ri are determined, and the data is copied from the integrated data storage unit 26 and the data is read from the external storage device 30.

このように、データ読み出し範囲判定処理は、統合判定処理後の読み出しブロックの単位で行われる。前のマクロブロック処理時に使用されたデータを再利用できない場合には、コピー処理は行われず流用領域Ci= NULLに設定される。又、データを再利用可能な場合であっても、新規読込領域Riが矩形でないときには、複数回の読み出しリクエストを発生する必要があり、処理が複雑になる。このため、本実施例では、新規読込領域Riが矩形ではない場合には、新規読込領域Ri=現必要領域Biとし、データの流用は行わない。尚、新規読込領域Riは矩形に限定されるものではない。   Thus, the data read range determination process is performed in units of read blocks after the integration determination process. If the data used in the previous macroblock processing cannot be reused, the copy process is not performed and the diversion area Ci = NULL is set. Even if the data can be reused, if the new read area Ri is not rectangular, it is necessary to generate a plurality of read requests, which complicates the processing. For this reason, in this embodiment, when the new read area Ri is not rectangular, the new read area Ri = the current required area Bi, and data is not used. The new reading area Ri is not limited to a rectangle.

図14は、ステップS4のコピー処理を説明するフローチャートである。図14において、ステップS401はiをi=1に設定し、ステップS402は流用領域CiがCi=Nullであるか否かを判定する。ステップS402の判定結果がNOであると、ステップS403は流用領域Ciを統合データ記憶部26からコピーし、処理はステップS404へ進む。ステップS402の判定結果がYESであると、処理はステップS404へ進む。ステップS404はiをi=i+1に設定し、ステップS405はi=Nであるか否かを判定する。ステップS405の判定結果がNOであると処理はステップS402へ戻り、YESであると処理は終了する。   FIG. 14 is a flowchart for explaining the copy processing in step S4. In FIG. 14, step S401 sets i to i = 1, and step S402 determines whether the diversion area | region Ci is Ci = Null. If the decision result in the step S402 is NO, a step S403 copies the diversion area Ci from the integrated data storage unit 26, and the process advances to a step S404. If the decision result in the step S402 is YES, the process advances to a step S404. Step S404 sets i to i = i + 1, and step S405 determines whether i = N. If the decision result in the step S405 is NO, the process returns to the step S402, and if it is YES, the process is ended.

このようにして、流用領域Ciを、1つずつ前のマクロブロックのデータを格納している統合データ記憶部26からコピーする。   In this way, the diversion area Ci is copied from the integrated data storage unit 26 storing the data of the previous macroblock one by one.

図15は、ステップS5のリクエスト処理を説明するフローチャートである。図15において、ステップS501はiをi=1に設定し、ステップS502は新規読込領域RiがRi=Nullであるか否かを判定する。ステップS502の判定結果がNOであると、ステップS503は新規読込領域Riを外部記憶装置30へリクエストし、処理はステップS504へ進む。ステップS502の判定結果がYESであると、処理はステップS504へ進む。ステップS504はiをi=i+1に設定し、ステップS505はi=Nであるか否かを判定する。ステップS505の判定結果がNOであると処理はステップS502へ戻り、YESであると処理は終了する。   FIG. 15 is a flowchart for explaining the request processing in step S5. In FIG. 15, step S501 sets i to i = 1, and step S502 determines whether or not the new reading area Ri is Ri = Null. If the decision result in the step S502 is NO, a step S503 requests a new read area Ri to the external storage device 30, and the process advances to a step S504. If the decision result in the step S502 is YES, the process advances to a step S504. Step S504 sets i to i = i + 1, and step S505 determines whether i = N. If the decision result in the step S505 is NO, the process returns to the step S502, and if it is YES, the process is ended.

このようにして、統合されてNULLとなったブロック以外に対して順番にリクエストを立てることで、新規読込領域Riを1つずつ前のマクロブロックのデータを格納している外部記憶装置30へリクエストしてコピーする。   In this way, by making a request in turn for the blocks other than the block that has been integrated and null, a request is made to the external storage device 30 that stores the data of the previous macroblock for each new read area Ri. And copy.

図16は、データを流用しない場合の読み出し制御を説明するフローチャートである。図16において、ステップS11及びS12の処理は、図11に示すステップS1及びS2の処理と同じであり、その説明は省略する。ステップS13のリクエスト処理は、図17に示す如きステップからなる。   FIG. 16 is a flowchart for explaining read control when data is not used. In FIG. 16, the processes of steps S11 and S12 are the same as the processes of steps S1 and S2 shown in FIG. The request process in step S13 includes steps as shown in FIG.

図17は、データを流用しない場合のステップS13のリクエスト処理を説明するフローチャートである。図17において、ステップS1301はiをi=1に設定し、ステップS1302は現必要領域BiがBi=Nullであるか否かを判定する。ステップS1302の判定結果がNOであると、ステップS1303は現必要領域Biを外部記憶装置30へリクエストしてコピーし、処理はステップS1304へ進む。ステップS1302の判定結果がYESであると、処理はステップS1304へ進む。ステップS1304はiをi=i+1に設定し、ステップS1305はi=Nであるか否かを判定する。ステップS1305の判定結果がNOであると処理はステップS1302へ戻り、YESであると処理は終了する。   FIG. 17 is a flowchart for explaining the request processing in step S13 when data is not used. In FIG. 17, step S1301 sets i to i = 1, and step S1302 determines whether or not the current necessary area Bi is Bi = Null. If the decision result in the step S1302 is NO, a step S1303 requests and copies the current necessary area Bi to the external storage device 30, and the process advances to a step S1304. If the decision result in the step S1302 is YES, the process advances to a step S1304. In step S1304, i is set to i = i + 1, and in step S1305, it is determined whether i = N. If the determination result in step S1305 is NO, the process returns to step S1302, and if YES, the process ends.

上記の如く、本実施例では、1マクロブロック内の各ブロックについて他のブロックのデータと統合した方が良いか否かを統合判定処理により判定し、統合した方がバスの占有時間が短くなり良いと判定されたときには統合するブロックのデータを同時に読み出す。このようにデータを同時に読み出す際、統合データ記憶部26に既に格納されているデータを利用可能な場合には、外部記憶装置30から再度読み出すことなく、統合データ記憶部26内のデータを再利用する。尚、この判定は1マクロブロック内に限定されるものではなく、数マクロブロック、或いは、1画像全体のベクトルに対して適応的に設定しても良い。ただし、対象マクロブロック同士が時間的に離れていると統合してもバスの占有時間が短くなる可能性は低くなり、上記演算自体も煩雑になるため、1マクロブロックか2〜3マクロブロック、多くとも10マクロブロック以下のベクトルに対して上記演算を行うことが望ましい。   As described above, in this embodiment, it is determined whether or not it is better to integrate each block in one macro block with the data of other blocks by the integration determination process. When it is determined to be good, the data of the blocks to be integrated are read out simultaneously. In this way, when data is read out simultaneously, if the data already stored in the integrated data storage unit 26 can be used, the data in the integrated data storage unit 26 is reused without being read out from the external storage device 30 again. To do. This determination is not limited to one macroblock, but may be adaptively set for several macroblocks or a vector of one image. However, if the target macroblocks are separated from each other in time, there is a low possibility that the bus occupation time will be shortened, and the calculation itself becomes complicated, so one macroblock or two to three macroblocks, It is desirable to perform the above operation on vectors of at most 10 macroblocks.

又、統合判定処理は、ブロックの読み出しサイクル、又は、外部記憶装置30のアクセス毎のオーバーヘッド、又は、バス占有時間を考慮して判定するものであれば、図12に示す処理に限定されるものではない。同様に、データ読み出し範囲判定処理、コピー処理及びリクエスト処理も、図13乃至図15に示す処理に限定されるものではない。   Further, the integration determination process is limited to the process shown in FIG. 12 as long as the determination is performed in consideration of the block read cycle, the overhead for each access of the external storage device 30, or the bus occupation time. is not. Similarly, the data read range determination process, the copy process, and the request process are not limited to the processes shown in FIGS.

本発明は、例えばビデオプレーヤ/レコーダやビデオカメラ等のビデオ再生機能を備えた装置に搭載された、MPEG-1、MPEG-2、MPEG-4、H.264、VC-1等の規格に代表されるフレーム間予測を行う動画圧縮方式で圧縮された動画像のビデオストリームを伸張(復号)するデコード装置に適用可能である。   The present invention is represented by standards such as MPEG-1, MPEG-2, MPEG-4, H.264, and VC-1, which are mounted on devices equipped with video playback functions such as video players / recorders and video cameras. The present invention is applicable to a decoding apparatus that decompresses (decodes) a video stream of a moving image compressed by a moving image compression method that performs inter-frame prediction.

以上、本発明を実施例により説明したが、本発明は上記実施例に限定されるものではなく、本発明の範囲内で種々の変形及び改良が可能であることは言うまでもない。   While the present invention has been described with reference to the embodiments, it is needless to say that the present invention is not limited to the above-described embodiments, and various modifications and improvements can be made within the scope of the present invention.

Claims (10)

フレーム間予測を行う動画圧縮方式で圧縮されたビデオストリームを記憶装置から読み出し、デコード済のフレームを参照画像としてデコード処理に利用するデコード方法であって、
前記ビデオストリームから抽出された動きベクトル情報に基づいて前記参照画像を演算し、
前記参照画像に基づいて予測画像を生成し、
前記参照画像の処理単位内の各領域を複数の領域を統合して前記記憶装置から読み出すか否かを、前記複数の領域を統合して読み出す場合のバス占有時間と各領域を個別に読み出す場合のバス占有時間を比較することで判定し、
各領域を個別に読み出す場合のバス占有時間は、各領域の読み出しサイクルと前記記憶装置のアクセス毎のオーバーヘッドを加算することで算出し、
前記複数の領域を統合して読み出す場合のバス占有時間は、統合した領域の読み出しサイクルと前記記憶装置のアクセスのオーバーヘッドを加算することで算出し、
前記複数の領域を統合して読み出す場合のバス占有時間の方が短く前記複数の領域を統合して読み出すと判定された場合は、前記記憶装置から読み出すデータ量が増加する場合も統合する複数の領域を前記記憶装置から同時に読み出ことを特徴とするデコード方法。
A decoding method for reading a video stream compressed by a moving image compression method for performing inter-frame prediction from a storage device, and using the decoded frame as a reference image for decoding processing,
Calculating the reference image based on motion vector information extracted from the video stream;
Generating a predicted image based on the reference image;
Whether to read out each area within the reference image processing unit from the storage device by integrating a plurality of areas, or to read the bus occupation time and each area separately when reading the plurality of areas together Judging by comparing the bus occupancy time of
The bus occupation time when reading each area individually is calculated by adding the read cycle of each area and the overhead for each access of the storage device,
The bus occupation time when the plurality of areas are read together is calculated by adding the read cycle of the integrated area and the access overhead of the storage device,
If it is determined that the bus occupancy time in the case of reading out the plurality of areas in an integrated manner is shorter and the plurality of areas are read out in a unified manner, a plurality of data to be integrated may be integrated even when the amount of data read from the storage device increases . decoding method characterized in that to read out simultaneously an area from the storage device.
前記記憶装置から統合して読み出した領域を統合データ記憶部に格納し、
前記動きベクトル情報に基づいて前記参照画像を演算するときに、前記統合データ記憶部に格納済みの統合された領域を前記参照画像のデータの一部として流用可能な場合には、前記格納済みの統合された領域を前記統合データ記憶部から読み出すことを特徴とする請求項1記載のデコード方法。
An integrated data storage unit stores the area read from the storage device,
When calculating the reference image based on the motion vector information, if the integrated area stored in the integrated data storage unit can be used as part of the data of the reference image, the stored image is stored. 2. The decoding method according to claim 1, wherein the integrated area is read from the integrated data storage unit.
前記統合データ記憶部は、偶数番目のマクロブロックを格納する第1の統合データ記憶領域と、奇数番目のマクロブロックを格納する第2の統合データ記憶領域を有し、
1番目のマクロブロックの全てのデータを前記記憶装置から読み出して第1の統合データ記憶領域に格納し、次のマクロブロックを処理する時点で前のマクロブロックのデータの再利用が可能な場合には前のマクロブロックのデータを第1の統合データ記憶領域から第2の統合データ記憶領域にコピーするデータコピーを行い、新たに読み出すマクロブロックのデータは前記記憶装置から読み出して第2の統合データ記憶領域に格納し、
前記マクロブロックのデータの格納又はデータコピーを1マクロブロック毎に繰り返すことで、続くマクロブロックを処理する際に前のマクロブロックで使用したデータを再利用することを特徴とする、請求項2記載のデコード方法。
The integrated data storage unit has a first integrated data storage area for storing even-numbered macroblocks, and a second integrated data storage area for storing odd-numbered macroblocks,
When all data of the first macroblock is read from the storage device and stored in the first integrated data storage area, and the data of the previous macroblock can be reused when the next macroblock is processed Performs a data copy of copying the data of the previous macroblock from the first integrated data storage area to the second integrated data storage area, and the newly read macroblock data is read from the storage device and the second integrated data Store it in the storage area,
3. The data used in the previous macroblock is reused when processing the subsequent macroblock by repeating the storage or data copy of the data of the macroblock for each macroblock. Decoding method.
前記動画圧縮方式はMPEG-1、MPEG-2、MPEG-4、H.264、VC-1のいずれかであることを特徴とする請求項1〜3のいずれか1項に記載のデコード方法。  The decoding method according to any one of claims 1 to 3, wherein the moving image compression method is one of MPEG-1, MPEG-2, MPEG-4, H.264, and VC-1. 前記参照画像の前記処理単位は、矩形のマクロブロック1乃至3個であることを特徴とする請求項1〜4のいずれか1項に記載のデコード方法。  5. The decoding method according to claim 1, wherein the processing unit of the reference image is 1 to 3 rectangular macroblocks. フレーム間予測を行う動画圧縮方式で圧縮されたビデオストリームを記憶装置から読み出し、デコード済のフレームを参照画像としてデコード処理に利用するデコード装置であって、
前記ビデオストリームから抽出された動きベクトル情報に基づいて前記参照画像を演算する演算部と、
前記参照画像に基づいて予測画像を生成する生成部と、
前記参照画像の処理単位内の各領域を複数の領域を統合して前記記憶装置から読み出すか否かを、前記複数の領域を統合して読み出す場合のバス占有時間と各領域を個別に読み出す場合のバス占有時間を比較することで判定する統合判定部
を備え、
前記統合判定部は、
各領域を個別に読み出す場合のバス占有時間を、各領域の読み出しサイクルと前記記憶装置のアクセス毎のオーバーヘッドを加算することで算出し、
前記複数の領域を統合して読み出す場合のバス占有時間を、統合した領域の読み出しサイクルと前記記憶装置のアクセスのオーバーヘッドを加算することで算出し、
前記複数の領域を統合して読み出す場合のバス占有時間の方が短く前記複数の領域を統合して読み出すと判定された場合は、前記記憶装置から読み出すデータ量が増加する場合も統合する複数の領域を前記記憶装置から同時に読み出ことを特徴とするデコード装置。
A decoding device that reads a video stream compressed by a moving image compression method that performs inter-frame prediction from a storage device, and uses the decoded frame as a reference image for decoding processing,
A computing unit that computes the reference image based on motion vector information extracted from the video stream;
A generating unit that generates a predicted image based on the reference image;
Whether to read out each area within the reference image processing unit from the storage device by integrating a plurality of areas, or to read the bus occupation time and each area separately when reading the plurality of areas together An integrated determination unit that determines by comparing the bus occupation time of
The integrated determination unit
The bus occupation time when reading each area individually is calculated by adding the read cycle of each area and the overhead for each access of the storage device,
The bus occupancy time when the plurality of areas are read together is calculated by adding the read area read cycle and the access overhead of the storage device,
If it is determined that the bus occupancy time in the case of reading out the plurality of areas in an integrated manner is shorter and the plurality of areas are read out in a unified manner, a plurality of data to be integrated may be integrated even when the amount of data read from the storage device increases . decoding apparatus characterized by be read out simultaneously an area from the storage device.
前記記憶装置から統合して読み出した領域を統合データ記憶部に格納する格納部を更に含み、
前記演算部は、前記統合データ記憶部に格納済みの統合された領域を前記参照画像のデータの一部として流用可能な場合には、前記統合された領域を前記統合データ記憶部から読み出すことを特徴とする請求項6記載のデコード装置。
A storage unit that stores the integrated data read from the storage device in the integrated data storage unit;
When the integrated area stored in the integrated data storage section can be used as a part of the reference image data, the arithmetic section reads the integrated area from the integrated data storage section. 7. The decoding device according to claim 6, wherein
前記統合データ記憶部は、偶数番目のマクロブロックを格納する第1の統合データ記憶領域と、奇数番目のマクロブロックを格納する第2の統合データ記憶領域を有し、
前記格納部は、1番目のマクロブロックの全てのデータを前記記憶装置から読み出して第1の統合データ記憶領域に格納し、次のマクロブロックを処理する時点で前のマクロブロックのデータの再利用が可能な場合には前のマクロブロックのデータを第1の統合データ記憶領域から第2の統合データ記憶領域にコピーするデータコピーを行い、新たに読み出すマクロブロックのデータは前記記憶装置から読み出して第2の統合データ記憶領域に格納し、
前記マクロブロックのデータの格納又はデータコピーを1マクロブロック毎に繰り返すことで、続くマクロブロックを処理する際に前のマクロブロックで使用したデータを再利用することを特徴とする、請求項7記載のデコード装置。
The integrated data storage unit has a first integrated data storage area for storing even-numbered macroblocks, and a second integrated data storage area for storing odd-numbered macroblocks,
The storage unit reads all data of the first macroblock from the storage device, stores the data in the first integrated data storage area, and reuses the data of the previous macroblock at the time of processing the next macroblock If possible, the data of the previous macroblock is copied from the first integrated data storage area to the second integrated data storage area, and the newly read macroblock data is read from the storage device. Stored in a second integrated data storage area;
The data used in the previous macroblock is reused when processing the subsequent macroblock by repeating the storage or data copy of the data of the macroblock every macroblock. Decoding device.
前記動画圧縮方式はMPEG-1、MPEG-2、MPEG-4、H.264、VC-1のいずれかであることを特徴とする請求項6〜8のいずれか1項記載のデコード装置。  9. The decoding apparatus according to claim 6, wherein the moving image compression method is any one of MPEG-1, MPEG-2, MPEG-4, H.264, and VC-1. 前記参照画像の前記処理単位は、矩形のマクロブロック1乃至3個であることを特徴とする請求項6〜9のいずれか1項に記載のデコード装置。  The decoding apparatus according to claim 6, wherein the processing unit of the reference image is 1 to 3 rectangular macroblocks.
JP2009506153A 2007-03-27 2007-03-27 Decoding method and decoding apparatus Expired - Fee Related JP5182285B2 (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/JP2007/056397 WO2008117440A1 (en) 2007-03-27 2007-03-27 Decoding method and decoding device

Publications (2)

Publication Number Publication Date
JPWO2008117440A1 JPWO2008117440A1 (en) 2010-07-08
JP5182285B2 true JP5182285B2 (en) 2013-04-17

Family

ID=39788183

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2009506153A Expired - Fee Related JP5182285B2 (en) 2007-03-27 2007-03-27 Decoding method and decoding apparatus

Country Status (2)

Country Link
JP (1) JP5182285B2 (en)
WO (1) WO2008117440A1 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2011129067A1 (en) * 2010-04-13 2011-10-20 パナソニック株式会社 Motion compensation method, image decoding method, image encoding method, motion compensation device, program, and integrated circuit
JP5688585B2 (en) * 2011-05-23 2015-03-25 富士通セミコンダクター株式会社 Inter-frame prediction processing apparatus and image processing apparatus
JPWO2013031071A1 (en) * 2011-09-02 2015-03-23 パナソニックIpマネジメント株式会社 Moving picture decoding apparatus, moving picture decoding method, and integrated circuit
JP6094760B2 (en) * 2012-02-07 2017-03-15 パナソニックIpマネジメント株式会社 Image processing apparatus and image processing method

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH10215457A (en) * 1997-01-30 1998-08-11 Toshiba Corp Moving image decoding method and device
JPH10304354A (en) * 1997-04-28 1998-11-13 Toshiba Corp Moving image decoding method and moving image decoder
JP2005354673A (en) * 2004-05-14 2005-12-22 Matsushita Electric Ind Co Ltd Motion compensating apparatus
JP2006520551A (en) * 2003-03-03 2006-09-07 モービリゲン コーポレーション Memory word array configuration and memory access prediction combination

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006166308A (en) * 2004-12-10 2006-06-22 Victor Co Of Japan Ltd Decoding apparatus and decoding method
JP4787044B2 (en) * 2005-03-31 2011-10-05 パナソニック株式会社 Image decoding apparatus, image decoding method, image decoding program, and image decoding integrated circuit

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH10215457A (en) * 1997-01-30 1998-08-11 Toshiba Corp Moving image decoding method and device
JPH10304354A (en) * 1997-04-28 1998-11-13 Toshiba Corp Moving image decoding method and moving image decoder
JP2006520551A (en) * 2003-03-03 2006-09-07 モービリゲン コーポレーション Memory word array configuration and memory access prediction combination
JP2005354673A (en) * 2004-05-14 2005-12-22 Matsushita Electric Ind Co Ltd Motion compensating apparatus

Also Published As

Publication number Publication date
JPWO2008117440A1 (en) 2010-07-08
WO2008117440A1 (en) 2008-10-02

Similar Documents

Publication Publication Date Title
US9667972B2 (en) Image coding device, image coding method, and image coding integrated circuit
EP1775961B1 (en) Video decoding device and method for motion compensation with sequential transfer of reference pictures
US20070071099A1 (en) External memory device, method of storing image data for the same, and image processor using the method
JP4606311B2 (en) Image coding apparatus and image coding method
US8184700B2 (en) Image decoder
US7447266B2 (en) Decoding device and decoding program for video image data
JPH05268590A (en) Moving picture coding decoding circuit
US20170019679A1 (en) Hybrid video decoding apparatus for performing hardware entropy decoding and subsequent software decoding and associated hybrid video decoding method
US8923384B2 (en) System, method and device for processing macroblock video data
US8514937B2 (en) Video encoding apparatus
JP2010119084A (en) High-speed motion search apparatus and method
JP5182285B2 (en) Decoding method and decoding apparatus
JP2008271292A (en) Motion compensating apparatus
JP4675383B2 (en) Image decoding apparatus and method, and image encoding apparatus
JPH10174108A (en) Motion vector retrieval device and moving image coder
WO2007028323A1 (en) Device and method for loading motion compensation data
US8406306B2 (en) Image decoding apparatus and image decoding method
JP5053774B2 (en) Video encoding device
JP2006042143A (en) Image processing system
JP4383367B2 (en) Motion vector detection device
JP2007006194A (en) Image decoding/reproducing apparatus
JP6221820B2 (en) Encoding apparatus, encoding method, and encoding program
JP2008136177A (en) Motion detection apparatus, mos (metal-oxide semiconductor) integrated circuit and video system
US20030123555A1 (en) Video decoding system and memory interface apparatus
JP4419608B2 (en) Video encoding device

Legal Events

Date Code Title Description
A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20120228

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20120426

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20120731

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20120928

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20121231

R150 Certificate of patent or registration of utility model

Ref document number: 5182285

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20160125

Year of fee payment: 3

LAPS Cancellation because of no payment of annual fees