JP2015002541A - Image decoding device and image decoding method - Google Patents

Image decoding device and image decoding method Download PDF

Info

Publication number
JP2015002541A
JP2015002541A JP2013127885A JP2013127885A JP2015002541A JP 2015002541 A JP2015002541 A JP 2015002541A JP 2013127885 A JP2013127885 A JP 2013127885A JP 2013127885 A JP2013127885 A JP 2013127885A JP 2015002541 A JP2015002541 A JP 2015002541A
Authority
JP
Japan
Prior art keywords
picture
decoding
image data
buffer
encoding
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.)
Pending
Application number
JP2013127885A
Other languages
Japanese (ja)
Inventor
拓郎 中嶋
Takuro Nakajima
拓郎 中嶋
泰裕 白石
Yasuhiro Shiraishi
泰裕 白石
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2013127885A priority Critical patent/JP2015002541A/en
Publication of JP2015002541A publication Critical patent/JP2015002541A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

PROBLEM TO BE SOLVED: To reduce the number of times of access to a reference memory without installing an intermediate memory.SOLUTION: An image decoding device comprises: a first buffer for storing compression image data; a second buffer for storing a decoded picture; decoding means which refers to the picture stored in the second buffer to decode the compression image data stored in the first buffer and stores the decoded picture in the second buffer; count means for counting the number of MB meeting a specific condition within the decoded picture; and control means for controlling operation of the entire device. The control means determines a picture type of image data being stored in the first buffer, makes a boundary determination to determine a boundary to be defined as an alternative picture without performing decoding processing in accordance with a result of the determination and a count result of the count means and determines the alternative picture without decoding a predetermined number of pictures after the picture determined as the boundary.

Description

本発明は画像復号化装置及び画像復号化方法に関し、特に、フレーム間予測符号化で圧縮された圧縮画像データを復号化するために用いて好適な技術に関する。   The present invention relates to an image decoding apparatus and an image decoding method, and more particularly to a technique suitable for use in decoding compressed image data compressed by interframe predictive encoding.

画像の解像度は大きくなる傾向にあり、それに伴い扱う画像のデータサイズは増加しているため、より圧縮率の高い圧縮符号化技術が望まれている。現在、動画像圧縮符号化方式ではH.264/MPEG4-AVC(以下、H.264と記述)が主流となっている。一般に、動画像の圧縮符号化では、画像データの時間方向および空間方向の冗長性を削減することによって高い圧縮率を実現している。例えば、符号化する際に、既に符号化済みのピクチャから予測画像を生成し、予測画像との差分を符号化することで、生成するデータのサイズを抑えることができる。   Since the resolution of an image tends to increase and the data size of the image to be handled increases accordingly, a compression encoding technique with a higher compression rate is desired. At present, H.264 / MPEG4-AVC (hereinafter referred to as H.264) is the mainstream of moving image compression coding systems. In general, in compression encoding of moving images, a high compression rate is realized by reducing redundancy in the time direction and space direction of image data. For example, when encoding, a predicted image is generated from an already encoded picture, and the difference from the predicted image is encoded, thereby reducing the size of data to be generated.

復号化する際には、符号化時に、予測画像を生成するときに参照したピクチャから予測画像を生成し、予測画像を加算することで復号処理を行う。
符号化時に、予測画像を参照しないものをIピクチャ、1枚の予測画像を参照するものをPピクチャ、2枚の予測画像を参照するものをBピクチャと呼ぶ。また、符号化、復号化時のピクチャの参照はマクロブロック(以下、MBと記述)単位に行われる。H.264では、符号化時に、この参照するMBのサイズを16×16、もしくは8×8など複数から1つを選択することが可能である。
At the time of decoding, a decoding process is performed by generating a prediction image from a picture referred to when generating a prediction image and adding the prediction image at the time of encoding.
At the time of encoding, a picture that does not refer to a predicted picture is called an I picture, a picture that references one predicted picture is called a P picture, and a picture that references two predicted pictures is called a B picture. In addition, reference to pictures at the time of encoding and decoding is performed in units of macroblocks (hereinafter referred to as MB). In H.264, at the time of encoding, it is possible to select one of a plurality of MB sizes to be referred to, such as 16 × 16 or 8 × 8.

H.264などの圧縮符号化技術を採用した民生用のカメラでは、生成した動画像をメディアに保存し、プレイヤーで再生するために目標とする符号量を設定し、この目標符号量を守るように符号化を行う。   In consumer cameras that use compression encoding technology such as H.264, save the generated video to media, set the target code amount for playback on the player, and protect this target code amount Is encoded.

例えば、動きがある映像を符号化する場合は、符号化済みのピクチャから生成する予測画像が外れやすく、符号化する差分のデータサイズが大きくなってしまうので、MBサイズを16×16で符号化することで、符号量を減らそうとする。   For example, when video with motion is encoded, the predicted image generated from the encoded picture is likely to deviate, and the data size of the difference to be encoded becomes large, so the MB size is encoded with 16 × 16. By doing so, it tries to reduce the code amount.

反対に、動きが少ない静止画のような映像を符号化する場合は、予測画像が当たりやすくなるため、差分が0に近くなる。差分がない場合は、SkipMBと呼ばれるデータサイズが小さいMBに差し替えられるため、8×8MBで細かく符号化して符号量を増やそうとする。よって、動きがない映像の圧縮符号化データは、SkipMBと8×8MBが連続する傾向にある。   On the other hand, when a video such as a still image with little motion is encoded, the predicted image is easy to hit, so the difference is close to zero. When there is no difference, the data size called Skip MB is replaced with a small MB, so that the code amount is increased by finely encoding with 8 × 8 MB. Therefore, the compressed and encoded data of a motionless video tends to have Skip MB and 8 × 8 MB continuous.

8×8MBが頻発したPピクチャ、もしくはBピクチャを復号化するとき、復号化済みピクチャが格納されているメモリ(以下、参照メモリと記述)へのアクセスが16×16MBに比べて頻発するので、メモリバスのレートを大量に消費する。特に、Bピクチャは、2枚の予測画像を参照するため、Pピクチャよりも参照メモリの負荷が増え、よりオーバーヘッドが大きくなるので、復号化対象の画像データが高解像度になるに従って負荷が増大していく。   When decoding a P-picture or B-picture where 8 × 8 MB is frequently generated, access to a memory (hereinafter referred to as a reference memory) in which the decoded picture is stored occurs more frequently than 16 × 16 MB. A large amount of memory bus rate is consumed. In particular, since the B picture refers to two predicted images, the load on the reference memory increases and the overhead increases compared to the P picture, so the load increases as the resolution of the image data to be decoded increases. To go.

民生用のカメラでは、撮影者の手振れやセンサーノイズによって、符号化時の予測画像が外れやすく、前述した8×8MBとSkipMBが頻発する圧縮符号化データを生成することは稀である。このため、カメラに搭載する復号化装置はコストの観点から、1ピクチャ内に発生する8×8MBの発生割合が一定以下となるものに限って復号化できるように制限付きで設計を行う場合がある。   In a consumer camera, the predicted image at the time of encoding is likely to be lost due to camera shake of the photographer or sensor noise, and it is rare to generate compressed encoded data in which 8 × 8 MB and Skip MB described above frequently occur. For this reason, the decoding device mounted on the camera may be designed with limitations so that decoding can be performed only when the rate of occurrence of 8 × 8 MB generated in one picture is below a certain level from the viewpoint of cost. is there.

このような復号化装置は、自己録した画像データの復号化は保障されているが、例えば、編集機器などによって生成された8×8MBが頻発するような画像データを復号化させようとすると、参照メモリのアクセスが頻発し、正確に再生できないことがある。   Such a decoding device is guaranteed to decode the self-recorded image data. However, for example, when trying to decode image data frequently generated by 8 × 8 MB generated by an editing device or the like, The reference memory may be accessed frequently and cannot be reproduced accurately.

参照メモリのアクセス回数を低減させる方法として、中間メモリを設置し、参照ピクチャを中間メモリに読み込んでから参照する圧縮符号化装置及び復号化装置が知られている。
例えば特許文献1では、符号化済みピクチャを参照して圧縮符号化するときに、参照メモリから中間メモリに参照ピクチャを読み出す。そして、読み出した中間メモリ上のピクチャを参照するピクチャが複数あった場合、参照ピクチャに対して、MB単位でピクチャを切り替えながら並列参照し、圧縮符号化することで、参照メモリのアクセス回数を低減させる。
As a method for reducing the number of accesses to the reference memory, a compression encoding device and a decoding device are known in which an intermediate memory is installed and a reference picture is read after being read into the intermediate memory.
For example, in Patent Document 1, when compression encoding is performed with reference to an encoded picture, the reference picture is read from the reference memory to the intermediate memory. If there are multiple pictures that refer to the picture in the read intermediate memory, the reference picture is referenced in parallel while switching the picture in MB units, and compression coding is performed, thereby reducing the number of accesses to the reference memory. Let

また、前述した方法で圧縮符号化された画像データを、中間メモリを使用して復号化することで、復号化時も圧縮符号化時と同様の効果が得られる。   In addition, by decoding the image data compressed and encoded by the above-described method using an intermediate memory, the same effect as that at the time of compression encoding can be obtained at the time of decoding.

特開2009−290387号公報JP 2009-290387 A

しかしながら、前述した従来技術の構成では、参照メモリのアクセスを低減するために中間メモリを設置する必要がある。また、特許文献1に記載の復号化装置では、特許文献1に記載の符号化装置で圧縮符号化された画像データが入力されることを想定しているため、他の方法で圧縮符号化された画像データを復号化する場合は、前述した効果が得られないため汎用的ではない。
本発明は前述の問題点に鑑み、中間メモリを設置することなく参照メモリへのアクセス回数を低減できるようにすることを目的とする。
However, in the configuration of the conventional technique described above, it is necessary to install an intermediate memory in order to reduce access to the reference memory. In addition, since the decoding apparatus described in Patent Document 1 assumes that image data compressed and encoded by the encoding apparatus described in Patent Document 1 is input, it is compressed and encoded by another method. When decoding the received image data, the above-described effects cannot be obtained, so that it is not general purpose.
The present invention has been made in view of the above-described problems, and an object thereof is to reduce the number of accesses to a reference memory without installing an intermediate memory.

本発明の画像復号化装置は、フレーム間予測符号化を用いて圧縮符号化された圧縮画像データを復号化する画像復号化装置において、前記圧縮画像データを記憶する第1のバッファと、復号化されたピクチャを記憶する第2のバッファと、前記第2のバッファに記憶されるピクチャを参照して、前記第1のバッファに記憶される前記圧縮画像データを復号化し、復号化されたピクチャを前記第2のバッファに記憶する復号化手段と、前記復号化手段が復号化したピクチャ内に特定の条件を満たす符号化ブロックの数をカウントするカウント手段と、装置全体の動作を制御する制御手段とを有し、前記制御手段は、前記第1のバッファに格納されている画像データのピクチャタイプを判断するピクチャタイプ判断手段と、前記ピクチャタイプ判断手段の判断結果と、前記カウント手段のカウント結果とから、復号化処理を行わずに代わりに代替ピクチャとする境界を判断する境界判断手段とを有し、前記境界判断手段によって境界と判断されたピクチャ以降、所定枚数のピクチャの復号化を行わずに、代替ピクチャとすることを特徴とする。   An image decoding apparatus according to the present invention comprises: a first buffer that stores the compressed image data; and a decoding apparatus that decodes compressed image data that has been compression-encoded using inter-frame predictive encoding. A second buffer for storing the decoded picture and a picture stored in the second buffer, the compressed image data stored in the first buffer is decoded, and the decoded picture is Decoding means for storing in the second buffer; counting means for counting the number of encoded blocks satisfying a specific condition in the picture decoded by the decoding means; and control means for controlling the operation of the entire apparatus The control means includes a picture type determination means for determining a picture type of the image data stored in the first buffer, and the picture type determination. A boundary determination unit that determines a boundary to be an alternative picture instead of performing the decoding process from the determination result of the unit and the count result of the counting unit, and is determined to be a boundary by the boundary determination unit After the picture, a predetermined number of pictures are not decoded and replaced with alternative pictures.

本発明によれば、画像データを復号化する処理において、参照メモリへのアクセスが頻発する複数の画像データが連続して入力された場合でも、メモリ等の追加回路なしに、参照メモリへのアクセス回数を低減させることが可能となる。これにより、システムの破綻を低コストで回避することができる。   According to the present invention, in the process of decoding image data, even when a plurality of image data frequently accessed to the reference memory are continuously input, the access to the reference memory can be performed without an additional circuit such as a memory. The number of times can be reduced. Thereby, the failure of the system can be avoided at a low cost.

本発明の実施形態を示し、画像復号化装置の構成例を示すブロック図である。1 is a block diagram illustrating an exemplary configuration of an image decoding device according to an embodiment of the present invention. 画像復号化装置が画像データを復号化する手順を説明するフローチャートである。It is a flowchart explaining the procedure in which an image decoding apparatus decodes image data. 第1と第2の実施形態における、復号処理スキップの基準を判断する手順を説明するフローチャートである。It is a flowchart explaining the procedure which judges the reference | standard of a decoding process skip in 1st and 2nd embodiment. 第1の実施形態における、復号処理スキップの判断する手順を説明するフローチャートである。It is a flowchart explaining the procedure which judges the decoding process skip in 1st Embodiment. 第1の実施形態における、復号処理スキップの判断処理の説明図である。It is explanatory drawing of the judgment process of a decoding process skip in 1st Embodiment. 第2の実施形態における、カウンタ設定する手順を説明するフローチャートである。It is a flowchart explaining the procedure which sets a counter in 2nd Embodiment. 第2の実施形態における、復号処理スキップの判断する手順を説明するフローチャートである。It is a flowchart explaining the procedure which judges the decoding process skip in 2nd Embodiment. 第2の実施形態における、復号処理スキップの判断処理の説明図である。It is explanatory drawing of the determination process of a decoding process skip in 2nd Embodiment. 第3の実施形態における、復号処理スキップの基準を判断する処理手順を説明するフローチャートである。It is a flowchart explaining the process sequence which judges the reference | standard of a decoding process skip in 3rd Embodiment. 第3の実施形態における、復号処理スキップの判断する処理手順を説明するフローチャートである。It is a flowchart explaining the process sequence which judges the decoding process skip in 3rd Embodiment. 第3の実施形態における、復号処理スキップの判断処理の説明図である。It is explanatory drawing of the determination process of a decoding process skip in 3rd Embodiment. 第4の実施形態における記録再生装置の構成例を示すブロック図である。It is a block diagram which shows the structural example of the recording / reproducing apparatus in 4th Embodiment. 符号化処理部の詳細な構成例を説明するブロック図である。It is a block diagram explaining the detailed structural example of an encoding process part. 第4の実施形態を示し、符号化処理の手順の一例を説明するフローチャートである。It is a flowchart which shows 4th Embodiment and demonstrates an example of the procedure of an encoding process. 第5の実施形態における記録再生装置の構成例を示すブロック図である。It is a block diagram which shows the structural example of the recording / reproducing apparatus in 5th Embodiment. 第5の実施形態を示し、符号化処理の手順の一例を説明するフローチャートである。It is a flowchart which shows 5th Embodiment and demonstrates an example of the procedure of an encoding process. 図16のフローチャートのS1603の画面周辺の配置方法について説明する図である。It is a figure explaining the arrangement | positioning method of the screen periphery of S1603 of the flowchart of FIG.

以下、図面を参照しながら本発明の画像復号化装置の好適な実施形態を説明する。
(第1の実施形態)
本実施形態では、H.264で圧縮符号化された画像データの復号処理において、ある条件を満たしたピクチャ以降、Bピクチャが続く間は、復号処理をスキップさせ、代わりに代替ピクチャを表示する例について説明する。なお、各実施形態における画像復号化装置の方式はH.264に限定されるものではなく、その他の同様の符号化方式であっても同様に適用可能である。
Hereinafter, preferred embodiments of an image decoding apparatus of the present invention will be described with reference to the drawings.
(First embodiment)
In the present embodiment, in the decoding process of image data compressed and encoded by H.264, an example in which the decoding process is skipped while a B picture continues after a picture satisfying a certain condition and an alternative picture is displayed instead. Will be described. In addition, the system of the image decoding apparatus in each embodiment is not limited to H.264, and other similar encoding systems can be similarly applied.

図1は、本実施形態に適応した画像復号化装置の一例を示すブロック図である。
図1の画像復号化装置100は、CPB101と、復号部102と、DPB103と、ピクチャ情報格納部104と、制御部105と、バス106とを備え、フレーム間予測符号化を用いて圧縮符号化された圧縮画像データを復号化する。
FIG. 1 is a block diagram illustrating an example of an image decoding apparatus adapted to the present embodiment.
The image decoding apparatus 100 in FIG. 1 includes a CPB 101, a decoding unit 102, a DPB 103, a picture information storage unit 104, a control unit 105, and a bus 106, and performs compression encoding using inter-frame prediction encoding. The compressed image data is decoded.

CPB(Coded Picture Buffers)101は、画像入力部(図示せず)から入力された圧縮符号化済みデータを格納するために設けられている第1のバッファであり、画像データを一定のビットレートで復号化するために使用する。
復号部102は、制御部105の制御に基づいて復号処理を行うものであり、復号化機能と符号化ブロック(特定MB)数のカウント機能とを有する。具体的には、以下に示す(イ)〜(ハ)の3つの機能を有している。
CPB (Coded Picture Buffers) 101 is a first buffer provided for storing compression-encoded data input from an image input unit (not shown), and stores image data at a constant bit rate. Used to decrypt.
The decoding unit 102 performs decoding processing based on the control of the control unit 105, and has a decoding function and a counting function of the number of encoded blocks (specific MB). Specifically, it has the following three functions (a) to (c).

(イ)H.264方式で圧縮符号化された入力データを復号する機能。
(ロ)復号時に、ピクチャ内のSkipMBの割合を算出する機能。
(ハ)復号時に、ピクチャ内の8×8MBの割合を算出する機能。
(A) A function for decoding input data compressed and encoded by the H.264 method.
(B) A function for calculating the ratio of SkipMB in a picture during decoding.
(C) A function for calculating a ratio of 8 × 8 MB in a picture at the time of decoding.

SkipMBとは、フレーム間予測符号化で圧縮符号化した際に、参照部分と符号化対象部分の差異がない場合に、データ量を抑えるために使用されるMBである。復号部102は、復号処理で得られたピクチャ単位の前述した情報をピクチャ情報格納部104に書き込み、復号したピクチャをDPB(Decoded Picture Buffers)103に書き込む。   SkipMB is an MB used to reduce the amount of data when there is no difference between the reference portion and the encoding target portion when compression encoding is performed with inter-frame predictive encoding. The decoding unit 102 writes the above-described information in units of pictures obtained by the decoding process into the picture information storage unit 104, and writes the decoded picture into a DPB (Decoded Picture Buffers) 103.

DPB103は、復号化済みのピクチャを格納するために設けられている第2のバッファであり、復号化済みピクチャの並び替えや、復号部102が、フレーム間予測符号化で圧縮された画像データを復号する際に参照するピクチャを格納するために使用する。   The DPB 103 is a second buffer provided for storing decoded pictures. The DPB 103 rearranges decoded pictures and the image data compressed by the decoding unit 102 by inter-frame prediction encoding. Used to store a picture to be referenced when decoding.

ピクチャ情報格納部104は、復号処理によって得られた1ピクチャ内のSkipMBの割合や8×8MBの割合、ピクチャタイプ、ピクチャサイズなどの情報をピクチャ単位で管理する。   The picture information storage unit 104 manages information such as Skip MB ratio, 8 × 8 MB ratio, picture type, and picture size in one picture obtained by decoding processing in units of pictures.

制御部105は、画像復号化装置100の制御、すなわち、装置全体の動作を制御するものであり、ピクチャタイプ判断手段と境界判断手段とを有する。具体的には、制御部105は、CPB101に格納されている画像データのピクチャタイプを判断し、判断結果をピクチャ情報格納部104に書き込む。また、ピクチャ情報格納部104に格納されているピクチャ情報から、復号処理をスキップさせる基準の判断処理と、復号処理スキップの判断処理を行う。これらの2つの処理についての詳細は後述する。   The control unit 105 controls the image decoding apparatus 100, that is, controls the operation of the entire apparatus, and includes a picture type determination unit and a boundary determination unit. Specifically, the control unit 105 determines the picture type of the image data stored in the CPB 101 and writes the determination result in the picture information storage unit 104. Also, based on the picture information stored in the picture information storage unit 104, a criterion determination process for skipping the decoding process and a decoding process skip determination process are performed. Details of these two processes will be described later.

バス106は、CPB101〜制御部105のブロック間でのデータの受け渡しを行う。以下、各ブロック間において、データの受け渡しをする際の、バス106の処理の記述については省略する。   The bus 106 exchanges data between the blocks of the CPB 101 to the control unit 105. Hereinafter, description of processing of the bus 106 when data is transferred between the blocks is omitted.

次に、画像復号化装置100の全体処理について、図2を用いて説明する。以下の図2〜図4に説明するフローチャートの処理は、制御部105に設けられているROMに格納されているプログラムをRAMに展開し、CPUが実行することにより実現される。
図2は、画像復号化装置が1つの画像データを復号化する処理のフローチャートである。
S201において、制御部105は、復号処理スキップの基準となるピクチャが設定されているか否かを判断する。
Next, the overall processing of the image decoding apparatus 100 will be described with reference to FIG. The processing of the flowcharts described below with reference to FIGS. 2 to 4 is realized by developing a program stored in the ROM provided in the control unit 105 in the RAM and executing it by the CPU.
FIG. 2 is a flowchart of a process in which the image decoding apparatus decodes one piece of image data.
In step S201, the control unit 105 determines whether a picture that is a reference for skipping the decoding process is set.

復号処理スキップの基準となるピクチャが設定されている場合は、S202において、復号処理スキップの判断処理を行う。設定されていない場合は、S203において復号処理スキップの基準判断処理を行う。
S202または203の処理を終了すると、S204において、復号化したデータの出力を行い、処理を終了する。
以上の処理を、入力されるピクチャを全て表示するまで繰り返し行う。
If a picture serving as a reference for skipping decoding processing is set, decoding processing skip determination processing is performed in S202. If it has not been set, a criterion judgment process for skipping the decoding process is performed in S203.
When the process of S202 or 203 ends, the decoded data is output in S204, and the process ends.
The above processing is repeated until all input pictures are displayed.

次に、S203の復号処理スキップの基準判断処理について、図3のフローチャートを用いて説明する。
図3は、復号処理スキップの基準を判断する手順を説明するフローチャートである。
CPB101に格納されている画像データが復号化される直前に、制御部105は、画像データのスライスヘッダからピクチャタイプを判断し、ピクチャ情報格納部104に書き込む。
Next, the decoding determination skip criterion determination process of S203 will be described with reference to the flowchart of FIG.
FIG. 3 is a flowchart illustrating a procedure for determining a criterion for skipping the decoding process.
Immediately before the image data stored in the CPB 101 is decoded, the control unit 105 determines the picture type from the slice header of the image data and writes it in the picture information storage unit 104.

S301において、制御部105は、復号部102に対して、CPB101に入力された画像データを復号処理するように指示する。
復号部102は、画像データの復号処理を行う。フレーム間予測符号化された画像データ、例えばBピクチャやPピクチャの復号時は、復号部102は、DPB103に格納されている復号済みピクチャを適宜参照し、復号処理を行う。フレーム内予測によって圧縮符号化されている場合は、参照は行わずに復号処理を行う。
In step S <b> 301, the control unit 105 instructs the decoding unit 102 to decode the image data input to the CPB 101.
The decoding unit 102 performs image data decoding processing. When decoding interframe predictive-encoded image data, for example, a B picture or a P picture, the decoding unit 102 refers to the decoded picture stored in the DPB 103 as appropriate, and performs a decoding process. When compression encoding is performed by intra-frame prediction, the decoding process is performed without reference.

また、復号部102は、復号処理と並列して、画像データのSkipMBと8×8MBの数をカウントする。そして、画像データの復号処理後、SkipMBと8×8MBが全体のMB数の何割を占めているかそれぞれ算出し、ピクチャ情報格納部104に書き込み、復号済みピクチャをDPB103に書き込む。   In parallel with the decoding process, the decoding unit 102 counts the number of SkipMB and 8 × 8 MB of image data. Then, after decoding the image data, calculate what percentage SkipMB and 8 × 8 MB occupy the total number of MBs, write to the picture information storage unit 104, and write the decoded picture to the DPB 103.

S302において、制御部105は、復号部102が復号した画像データのピクチャタイプをピクチャ情報格納部104から参照して、復号化した画像データがBピクチャであるか判断する。復号化された画像データがBピクチャならばS303に進む。Bピクチャ以外ならば、処理を終了する。   In step S <b> 302, the control unit 105 refers to the picture type of the image data decoded by the decoding unit 102 from the picture information storage unit 104 and determines whether the decoded image data is a B picture. If the decoded image data is a B picture, the process proceeds to S303. If it is not a B picture, the process ends.

S303において、制御部105は、復号部102が復号した画像データのSkipMBの割合をピクチャ情報格納部104から参照して、SkipMBの割合が、あらかじめ設定されたしきい値α以上か、α未満かを判断する。例えば、しきい値を70%とした場合、画像データ全体のMB数に対して、SkipMBが70%以上ならばS304に進む。70%未満なら、処理を終了する。   In S303, the control unit 105 refers to the rate of SkipMB of the image data decoded by the decoding unit 102 from the picture information storage unit 104, and determines whether the rate of SkipMB is greater than or equal to a preset threshold value α. Judging. For example, when the threshold value is 70%, if SkipMB is 70% or more with respect to the total number of MBs of the image data, the process proceeds to S304. If it is less than 70%, the process is terminated.

S304において、制御部105は、復号部102が復号した画像データの8×8MBの割合をピクチャ情報格納部104から参照して、8×8MBの割合があらかじめ設定されたしきい値β以上か、β未満かを判断する。例えば、しきい値を70%とした場合、画像データ全体のMB数に対して、8×8MBが70%以上ならばS305に進む。70%未満なら、処理を終了する。   In S304, the control unit 105 refers to the 8 × 8 MB ratio of the image data decoded by the decoding unit 102 from the picture information storage unit 104, and the 8 × 8 MB ratio is equal to or higher than a preset threshold value β. Judge whether it is less than β. For example, when the threshold value is 70%, if 8 × 8 MB is 70% or more with respect to the number of MBs of the entire image data, the process proceeds to S305. If it is less than 70%, the process is terminated.

S305において、制御部105は、Bピクチャであり、SkipMBと8×8MBの割合が70%を超えた画像データを復号処理スキップの基準のピクチャとして設定し、基準判断処理を終了する。   In step S305, the control unit 105 sets the image data that is a B picture and the ratio of Skip MB to 8 × 8 MB exceeds 70% as a reference picture for skipping decoding processing, and ends the reference determination processing.

次に、S202の復号処理スキップの判断を行う処理について、図4と図5を用いて説明する。図4は、復号処理スキップ判断処理のフローチャートである。図5は、復号処理スキップ判断処理の説明図である。
CPB101に入力される画像データの並びを図5の入力順とし、S203の処理でB0が基準のピクチャとして判断された後、B1が入力されたとする。Bはピクチャタイプ、0は表示順を示す。
Next, the process of determining whether to skip the decoding process in S202 will be described with reference to FIGS. FIG. 4 is a flowchart of the decoding process skip determination process. FIG. 5 is an explanatory diagram of the decoding process skip determination process.
Assume that the arrangement of the image data input to the CPB 101 is the input order of FIG. 5 and that B1 is input after B0 is determined as the reference picture in the process of S203. B indicates the picture type, and 0 indicates the display order.

S401において、制御部105は、CPB101に入力された画像データであるB1のスライスヘッダからピクチャタイプがBピクチャか否かを判断する。画像データがBピクチャならばS402に進む。Bピクチャ以外ならばS404に進む。
B1はBピクチャなので、S402に進む。
In step S <b> 401, the control unit 105 determines whether the picture type is a B picture from the slice header of B <b> 1 that is image data input to the CPB 101. If the image data is a B picture, the process proceeds to S402. If it is not a B picture, the process proceeds to S404.
Since B1 is a B picture, the process proceeds to S402.

S402において、制御部105は、B1の復号処理を復号部102に指示せずに復号処理をスキップさせる。
S403において、制御部105は、B1の復号結果の代わりに表示させる代替ピクチャの設定を行う。
In S402, the control unit 105 skips the decoding process without instructing the decoding unit 102 to perform the decoding process of B1.
In step S403, the control unit 105 sets a substitute picture to be displayed instead of the B1 decoding result.

例えば、代替ピクチャの候補としては、
(a)B1の参照先ピクチャ。
(b)B1の表示順で一番近いピクチャ。
などが、考えられる。
For example, as alternative picture candidates,
(A) B1 reference picture.
(B) The closest picture in the display order of B1.
Etc. are conceivable.

本実施形態では、対象ピクチャの表示順で一番近いピクチャを代替ピクチャとする(図5参照)。よって、DPB103に格納されている復号化済みのB0ピクチャを代替ピクチャとして設定し、S204において、制御部105は、代替ピクチャであるB0ピクチャをB1の復号結果の代わりに出力させる。
CPB101に次の入力画像データである、P5が入力された場合、S401において、制御部105は、Bピクチャではないと判断して、S404の処理に進む。
In the present embodiment, the closest picture in the display order of the target picture is set as a substitute picture (see FIG. 5). Therefore, the decoded B0 picture stored in the DPB 103 is set as a substitute picture, and in S204, the control unit 105 causes the substitute picture B0 picture to be output instead of the decoding result of B1.
When P5, which is the next input image data, is input to the CPB 101, in S401, the control unit 105 determines that it is not a B picture, and proceeds to the processing of S404.

S404において、Bピクチャが途切れたので、制御部105は、復号処理スキップの基準となるピクチャをリセットする。
S405において、制御部105は、復号部102に対して、CPB101に入力された画像データであるP5を復号処理するように指示し、復号部102は復号処理を行う。S204において、制御部105は、DPB103に格納されている、次の表示順のI2ピクチャを出力させる。
以下、入力される画像データに対して、S201からS204の処理を繰り返し行う。
In step S404, since the B picture is interrupted, the control unit 105 resets a picture that is a reference for skipping the decoding process.
In step S405, the control unit 105 instructs the decoding unit 102 to decode the image data P5 input to the CPB 101, and the decoding unit 102 performs the decoding process. In S <b> 204, the control unit 105 outputs the next I2 picture in the display order stored in the DPB 103.
Thereafter, the processing from S201 to S204 is repeated for the input image data.

前述した処理結果を図5に示す。表示されるピクチャの並びは「B0、B0、I2、B3、B4、P5」となる。
以上説明したように、本実施形態では、復号処理スキップの基準となるピクチャ以降、Bピクチャが続く限り、対象のピクチャの復号処理を行わずに、代わりに代替ピクチャを表示させる。これにより、参照メモリへのアクセスが頻発する複数の画像データが連続して入力された場合でも、参照メモリへのアクセスを低減させることで、システムの破綻を回避することができる。
FIG. 5 shows the processing result described above. The displayed picture sequence is “B0, B0, I2, B3, B4, P5”.
As described above, in this embodiment, as long as the B picture continues after the picture that is the reference for skipping the decoding process, the alternative picture is displayed instead of performing the decoding process of the target picture. As a result, even when a plurality of image data frequently accessed to the reference memory are continuously input, the system failure can be avoided by reducing the access to the reference memory.

(第2の実施形態)
本実施形態では、H.264で圧縮符号化された画像データの復号処理において、ある条件を満たしたピクチャ以降、Bピクチャが続き、かつ高フレームレートの場合は、復号処理のスキップ期間を長くする。そして、低フレームレートの場合は、復号処理のスキップ期間を短くする例について説明する。
(Second Embodiment)
In the present embodiment, in the decoding process of image data compressed and encoded by H.264, if a B picture continues after a picture satisfying a certain condition and the frame rate is high, the decoding process skip period is lengthened. . In the case of a low frame rate, an example in which the skip period of the decoding process is shortened will be described.

本実施形態の画像復号化装置の構成は、第1の実施形態の構成である図1と同じである。また、全体の処理と、復号処理スキップの基準判断処理も第1の実施形態で使用した図2と図3のフローチャートと同じであるので、説明は省略する。
図6及び図7に説明するフローチャートの処理は、制御部105に設けられているROMに格納されているプログラムをRAMに展開し、CPUが実行することにより実現される。
The configuration of the image decoding apparatus according to the present embodiment is the same as that of FIG. 1 that is the configuration of the first embodiment. The overall process and the decoding process skip criterion determination process are also the same as those in the flowcharts of FIGS. 2 and 3 used in the first embodiment, and a description thereof will be omitted.
6 and 7 is realized by developing a program stored in a ROM provided in the control unit 105 in a RAM and executing the program by the CPU.

図6を用いて、基準となるピクチャ以降、Bピクチャが連続した場合、何枚まで復号処理のスキップを行うかを決定するカウンタの設定処理について説明する。
図6は、カウンタ設定処理の手順を説明するフローチャートである。
S601において、制御部105は、CPB101に入力される画像データのフレームレートが、あらかじめ設定されたしきい値γ以上か、γ未満かを判断する。例えば、しきい値を60fpsとした場合、入力される画像データのフレームレートが60fps以上ならばS602に進む。60fps未満ならばS603に進む。
With reference to FIG. 6, a description will be given of a counter setting process that determines how many decoding processes to skip when B pictures continue after the reference picture.
FIG. 6 is a flowchart for explaining the procedure of the counter setting process.
In step S601, the control unit 105 determines whether the frame rate of the image data input to the CPB 101 is greater than or equal to a preset threshold value γ or less than γ. For example, when the threshold is 60 fps, if the frame rate of the input image data is 60 fps or more, the process proceeds to S602. If it is less than 60 fps, the process proceeds to S603.

S602とS603において、制御部105は、変数iに値XとY(X>Y)を設定する。
変数iは、復号処理スキップの基準となるピクチャから、何枚のBピクチャに対して復号処理のスキップを行うのか示した変数である。例えば、制御部105は、X=2、Y=1のようにあらかじめ決めておいた値を変数iに格納し、カウンタ設定処理を終了する。
カウンタ設定処理は、CPB101に入力された画像データの内、次に復号化されるものに対して行われる。
In S602 and S603, the control unit 105 sets values X and Y (X> Y) for the variable i.
The variable i is a variable indicating how many B pictures the decoding process is skipped from the picture that is the reference for the decoding process skip. For example, the control unit 105 stores a predetermined value such as X = 2 and Y = 1 in the variable i, and ends the counter setting process.
The counter setting process is performed on the next image data input to the CPB 101 to be decoded.

次に、復号処理スキップの判断を行う処理について、図7と図8を用いて説明する。
図7は、復号処理スキップ判断処理の手順を説明するフローチャートである。S401、S402、S403、S404、S405は図4のフローチャートの処理と同じなので、説明は省略する。
Next, processing for determining whether to skip decoding processing will be described with reference to FIGS.
FIG. 7 is a flowchart for explaining the procedure of the decoding process skip determination process. Since S401, S402, S403, S404, and S405 are the same as those in the flowchart of FIG.

図8は、復号処理スキップ判断処理の説明図である。本実施形態において、CPB101には、図8の入力順で画像データが入力されるものとする。B0が復号処理スキップの基準となるピクチャとして設定された後、画像データがB1から入力されるものとして、以下処理の説明をする。   FIG. 8 is an explanatory diagram of the decoding process skip determination process. In the present embodiment, it is assumed that image data is input to the CPB 101 in the input order of FIG. The processing will be described below on the assumption that image data is input from B1 after B0 is set as a reference for skipping decoding processing.

S401において、次に復号化されるB1のピクチャタイプがBピクチャか否かを判定し、BピクチャならばS701に進む。Bピクチャ以外ならばS703に進む。
B1はBピクチャと同一のピクチャタイプなので、S701において、制御部105は、変数iの値が0であるか否かを判定する。変数iが0でない場合は、S702に進む、変数iが0ならばS703に進む。
変数iは、カウンタ設定処理で2が設定されているので、S702に進む。
In S401, it is determined whether or not the picture type of B1 to be decoded next is a B picture. If it is a B picture, the process proceeds to S701. If it is not a B picture, the process proceeds to S703.
Since B1 is the same picture type as the B picture, in step S701, the control unit 105 determines whether or not the value of the variable i is 0. If the variable i is not 0, the process proceeds to S702. If the variable i is 0, the process proceeds to S703.
Since variable i is set to 2 in the counter setting process, the process proceeds to S702.

S702において、制御部105は、変数iをデクリメントし、S402、S403で復号処理のスキップを行い、代替ピクチャB0を設定する。
上記処理をBピクチャが途切れるか、変数iが0になるまで繰り返し行う。
入力画像データがB3のときに、S702において、制御部105は、変数iを0と判定してS703に進む。
In S702, the control unit 105 decrements the variable i, skips the decoding process in S402 and S403, and sets a substitute picture B0.
The above processing is repeated until the B picture is interrupted or the variable i becomes 0.
When the input image data is B3, in S702, the control unit 105 determines that the variable i is 0, and proceeds to S703.

S703において、制御部105は、変数iをカウンタ設定処理で設定した値にセットし、S404、S405の処理を行い、処理を終了する。
以下、入力される画像データに対して、S201からS204の処理を繰り返し行う。
In S703, the control unit 105 sets the variable i to the value set in the counter setting process, performs the processes in S404 and S405, and ends the process.
Thereafter, the processing from S201 to S204 is repeated for the input image data.

前述した処理結果を図8に示す。表示されるピクチャの並びは「B0、B0、B0、B3、I4」となる。
以上説明したように、本実施形態では、入力されるフレームレートが高い場合は、隣り合う画が似ていると判断し、復号処理のスキップ期間を長く設定する。フレームレートが低い場合は、隣り合う画の違いが大きいと判断し、復号処理のスキップ期間を短く設定する。
FIG. 8 shows the processing result described above. The displayed picture sequence is “B0, B0, B0, B3, I4”.
As described above, in the present embodiment, when the input frame rate is high, it is determined that adjacent images are similar, and the decoding process skip period is set to be long. If the frame rate is low, it is determined that the difference between adjacent images is large, and the skip period of the decoding process is set short.

復号処理スキップの基準となるピクチャ以降、Bピクチャが続きかつ、設定されたスキップ期間は、対象のピクチャの復号処理を行わずに、代わりに代替ピクチャを表示させる。これにより、参照メモリへのアクセスが頻発する複数の画像データが入力される場合でも、参照メモリへのアクセスを低減させることで、システムの破綻を回避することができる。   Subsequent pictures are displayed instead of the decoding process of the target picture without performing the decoding process of the target picture during the set skip period after the picture that becomes the reference for the decoding process skip. As a result, even when a plurality of image data frequently accessed to the reference memory is input, it is possible to avoid a system failure by reducing the access to the reference memory.

(第3の実施形態)
本実施形態では、圧縮符号化された画像データの復号処理で、ある条件を満たしたピクチャ以降、Bピクチャが続き、かつ前記条件を満たしたピクチャより所定値以上のサイズのピクチャが出てくるまで、復号処理のスキップを行う例について説明する。
本実施形態の構成は、第1の実施形態の構成である図1と同じである。また、全体の処理も第1の実施形態で使用した図2のフローチャートと同じであるので、説明は省略する。
(Third embodiment)
In the present embodiment, in the decoding process of compression-encoded image data, a B picture continues after a picture satisfying a certain condition, and a picture having a size greater than or equal to a predetermined value appears from a picture satisfying the condition. An example in which decoding processing is skipped will be described.
The configuration of this embodiment is the same as that of FIG. 1 which is the configuration of the first embodiment. Moreover, since the whole process is the same as the flowchart of FIG. 2 used in the first embodiment, the description thereof is omitted.

復号処理のスキップを判断する際に使用する、ピクチャサイズのしきい値の設定処理について図9を用いて説明する。
図9は、復号処理スキップの基準を判断する処理である。S301、S302、S303、S304、S305の処理は、図3のフローチャートの処理と同じなので、説明は省略する。
A picture size threshold setting process used when determining whether to skip the decoding process will be described with reference to FIG.
FIG. 9 is a process for determining a decoding process skip criterion. The processing of S301, S302, S303, S304, and S305 is the same as the processing of the flowchart of FIG.

Bピクチャであり、かつSkipMBの割合がしきい値α以上であり、かつ8×8MBの割合がしきい値β以上の画像データが復号されたとき、S305において、制御部105は、前述した条件を満たしたピクチャを基準のピクチャに設定する。   When image data that is a B picture, the rate of SkipMB is greater than or equal to the threshold value α, and the rate of 8 × 8 MB is greater than or equal to the threshold value β is decoded in S305, the control unit 105 performs the above-described conditions. A picture that satisfies the above is set as a reference picture.

S901において、制御部105は、ピクチャ情報格納部104から基準のピクチャの復号化前のデータサイズを取得し、取得したデータサイズからピクチャサイズのしきい値を設定する。ここで設定したしきい値は、復号化処理のスキップの判断に使用する。   In step S901, the control unit 105 acquires the data size of the reference picture before decoding from the picture information storage unit 104, and sets a threshold for the picture size from the acquired data size. The threshold value set here is used to determine whether to skip the decoding process.

しきい値の設定方法として、例えば、基準のピクチャに対して、ある程度違うピクチャも復号処理をスキップさせるならば、しきい値を大きく設定し、違いが少ないピクチャのみをスキップさせたい場合は、しきい値を小さく設定する。
本実施形態では、基準ピクチャとの違いが少ないピクチャをスキップ処理の対象とするので、
「しきい値Z=基準ピクチャのサイズN+3kバイト」
のように、しきい値Zを設定する。しきい値を設定後に、処理を終了する。
As a threshold setting method, for example, if the decoding process is skipped even for a picture that is somewhat different from the reference picture, set a large threshold and skip only pictures with little difference. Set the threshold value smaller.
In the present embodiment, since a picture with little difference from the reference picture is a target of skip processing,
"Threshold Z = size of reference picture N + 3k bytes"
The threshold value Z is set as follows. After setting the threshold value, the process is terminated.

次に、復号処理スキップの判断を行う処理について、図10と図11を用いて説明する。
図10は、復号処理スキップ判断処理のフローチャートである。S401、S402、S403、S404、S405は図4のフローチャートの処理と同じなので、説明は省略する。
Next, processing for determining whether to skip decoding processing will be described with reference to FIGS. 10 and 11.
FIG. 10 is a flowchart of the decoding process skip determination process. Since S401, S402, S403, S404, and S405 are the same as those in the flowchart of FIG.

図11は、本実施形態の復号処理スキップ判断処理の説明図である。本実施形態において、CPB101には、図11の入力順で画像データが入力されるものとする。また、B0のピクチャサイズをNとしたとき、B1のサイズをN+1kバイト、B2のサイズをN+4kバイトとする。   FIG. 11 is an explanatory diagram of the decoding process skip determination process of the present embodiment. In the present embodiment, it is assumed that image data is input to the CPB 101 in the input order of FIG. When the picture size of B0 is N, the size of B1 is N + 1k bytes, and the size of B2 is N + 4k bytes.

B0が復号処理スキップの基準となるピクチャとして設定された後、画像データがB1からの入力されるものとして、以下処理の説明をする。
S401において、次に復号化されるB1のピクチャタイプがBピクチャか否かを判定し、BピクチャならばS1001に進む。Bピクチャ以外ならばS404に進む。
The processing will be described below assuming that image data is input from B1 after B0 is set as a reference picture for decoding processing skipping.
In S401, it is determined whether or not the picture type of B1 to be decoded next is a B picture. If it is a B picture, the process proceeds to S1001. If it is not a B picture, the process proceeds to S404.

B1はBピクチャなので、S1001において、制御部105は、ピクチャ情報格納部104からB1のピクチャサイズを取得し、B1のピクチャサイズがS901で設定されたしきい値Zを超えているか否かを判断する。しきい値Z未満ならばS402に進み、復号処理のスキップを行う。しきい値Z以上ならばS404に進み、復号処理スキップの基準となるピクチャをリセットし、復号処理を行う。   Since B1 is a B picture, in S1001, the control unit 105 obtains the B1 picture size from the picture information storage unit 104, and determines whether the B1 picture size exceeds the threshold value Z set in S901. To do. If it is less than the threshold value Z, the process proceeds to S402 and the decoding process is skipped. If it is equal to or greater than the threshold value Z, the process advances to step S404 to reset a picture that serves as a reference for skipping the decoding process and perform a decoding process.

B1のピクチャサイズは、N+1kバイトなので、しきい値Z未満となり、S402、S403において、表示順で最も近いB0ピクチャを代替ピクチャに設定し、復号処理をスキップさせる。   Since the picture size of B1 is N + 1k bytes, it becomes less than the threshold value Z. In S402 and S403, the nearest B0 picture in the display order is set as the alternative picture, and the decoding process is skipped.

次に入力されるB2では、S1001において、B2のサイズは、N+4kバイトなので、しきい値Z以上となり、基準ピクチャであるB0に対して動きがあったと判断し、S404、S405において、基準ピクチャのリセットとB2の復号処理を行う。以下、入力される画像データに対して、S201からS204の処理を繰り返し行う。
前述した処理結果を図11に示す。表示されるピクチャの並びは「B0、B0、B2、B3、I4」となる。
In the next input B2, since the size of B2 is N + 4k bytes in S1001, it is determined that there is a motion with respect to the reference picture B0 because it is equal to or greater than the threshold value Z. In S404 and S405, the reference picture Perform reset and B2 decryption. Thereafter, the processing from S201 to S204 is repeated for the input image data.
The processing results described above are shown in FIG. The displayed picture sequence is “B0, B0, B2, B3, I4”.

以上説明したように、本実施形態では、あらかじめピクチャサイズのしきい値を設定し、対象のピクチャサイズがしきい値以上ならば、参照ピクチャと大きく異なると判断し、通常の復号処理を行う。Bピクチャで、かつピクチャサイズがしきい値未満ならば、動きが小さいと判断し、対象のピクチャの復号処理を行わずに、代わりに代替ピクチャを表示させる。これにより、参照メモリへのアクセスが頻発する複数の画像データが入力される場合でも、参照メモリへのアクセスを低減させることで、システムの破綻を回避することができる。   As described above, in this embodiment, a picture size threshold value is set in advance, and if the target picture size is equal to or larger than the threshold value, it is determined that the picture size is significantly different from the reference picture, and normal decoding processing is performed. If it is a B picture and the picture size is less than the threshold value, it is determined that the motion is small, and instead of decoding the target picture, an alternative picture is displayed instead. As a result, even when a plurality of image data frequently accessed to the reference memory is input, it is possible to avoid a system failure by reducing the access to the reference memory.

(第4の実施形態)
以下に、本発明の画像符号化装置の好ましい実施形態を、添付の図面に基づいて詳細に説明する。図12は、本発明の画像符号化装置を適用できる記録再生装置の構成例を示すブロック図である。
(Fourth embodiment)
Hereinafter, preferred embodiments of an image encoding device of the present invention will be described in detail with reference to the accompanying drawings. FIG. 12 is a block diagram showing a configuration example of a recording / reproducing apparatus to which the image coding apparatus of the present invention can be applied.

以下、図12を参照して、本発明の第4の実施形態による全体システムの構成について説明する。
図12において、1201はフォーカスレンズを含む撮影レンズ、1202は絞り機能を備えるアイリス、1203は光学像を電気信号に変換するCCDやCMOS素子のセンサー等で構成される撮像部である。1204はA/D変換器であり、アナログ信号をデジタル信号に変換する。A/D変換器1204は、撮像部1203から出力されるアナログ信号をデジタル信号に変換するために用いられる。
Hereinafter, the configuration of the entire system according to the fourth embodiment of the present invention will be described with reference to FIG.
In FIG. 12, reference numeral 1201 denotes a photographing lens including a focus lens, 1202 denotes an iris having a diaphragm function, and 1203 denotes an imaging unit including a CCD or a CMOS element sensor that converts an optical image into an electric signal. An A / D converter 1204 converts an analog signal into a digital signal. The A / D converter 1204 is used to convert an analog signal output from the imaging unit 1203 into a digital signal.

1205は画像処理部であり、A/D変換器1204からのデータに対しカメラ信号処理や所定の画素補間、縮小といったリサイズ処理や色変換処理を行う。また、画像処理部1205では、撮像した画像データを用いて所定の演算処理が行われ、得られた演算結果に基づいてシステム制御部1208が露光制御、測距制御を行う。   An image processing unit 1205 performs resize processing and color conversion processing such as camera signal processing, predetermined pixel interpolation, and reduction on the data from the A / D converter 1204. The image processing unit 1205 performs predetermined calculation processing using the captured image data, and the system control unit 1208 performs exposure control and distance measurement control based on the obtained calculation result.

これにより、TTL(スルー・ザ・レンズ)方式のAF(オートフォーカス)処理、AE(自動露出)処理、EF(フラッシュプリ発光)処理が行われる。画像処理部1205では更に、撮像した画像データを用いて所定の演算処理を行い、得られた演算結果に基づいてTTL方式のAWB(オートホワイトバランス)処理も行っている。   Thereby, AF (autofocus) processing, AE (automatic exposure) processing, and EF (flash pre-emission) processing of the TTL (through-the-lens) method are performed. The image processing unit 1205 further performs predetermined calculation processing using the captured image data, and also performs TTL AWB (auto white balance) processing based on the obtained calculation result.

A/D変換器1204からの出力データは、画像処理部1205でカメラ信号処理を介して、メモリ1207に書かれる。メモリ1207は、撮像部1203によって得られA/D変換器1204と画像処理部1205によりデジタルデータに変換された画像データを格納する。メモリ1207は、所定枚数の静止画像や所定時間の動画像および音声を格納するのに十分な記憶容量を備えている。
1206は符号化処理部であり、メモリ1207より入力される原画像データを所定のフォーマットに符号化する。本実施形態においては、ブロック化された複数のブロックを集め、マクロブロック毎に符号化する。
Output data from the A / D converter 1204 is written in the memory 1207 via the camera signal processing in the image processing unit 1205. The memory 1207 stores image data obtained by the imaging unit 1203 and converted into digital data by the A / D converter 1204 and the image processing unit 1205. The memory 1207 has a storage capacity sufficient to store a predetermined number of still images, a moving image and sound for a predetermined time.
Reference numeral 1206 denotes an encoding processing unit that encodes original image data input from the memory 1207 into a predetermined format. In the present embodiment, a plurality of blocked blocks are collected and encoded for each macroblock.

不揮発性メモリ1211は、電気的に消去・記録可能なメモリであり、例えばEEPROM等が用いられる。不揮発性メモリ1211には、システム制御部1208の動作用の定数、プログラム等が記憶される。ここでいう、プログラムとは、本実施形態にて後述する各種フローチャートを実行するためのプログラムのことである。   The nonvolatile memory 1211 is an electrically erasable / recordable memory, and for example, an EEPROM or the like is used. The nonvolatile memory 1211 stores constants for operating the system control unit 1208, programs, and the like. Here, the program is a program for executing various flowcharts described later in the present embodiment.

1208はシステム制御部であり、記録再生装置1200全体を制御する。前述した不揮発性メモリ1211に記録されたプログラムを実行することで、後述する本実施形態の各処理を実現する。1210はシステムメモリであり、RAMが用いられる。システムメモリ1210には、システム制御部1208の動作用の定数、変数、不揮発性メモリ1211から読み出したプログラム等を展開する。操作部1209は、システム制御部1208に各種の動作指示を入力するための操作手段である。   A system control unit 1208 controls the entire recording / reproducing apparatus 1200. By executing the program recorded in the non-volatile memory 1211 described above, each process of the present embodiment to be described later is realized. A system memory 1210 uses a RAM. In the system memory 1210, constants and variables for operation of the system control unit 1208, a program read from the nonvolatile memory 1211, and the like are expanded. The operation unit 1209 is an operation unit for inputting various operation instructions to the system control unit 1208.

システム制御部1208は、操作部1209の撮影開始要求により、撮像部1203からの信号読み出しから記録媒体1222に画像データを書き込むまでの一連の撮影処理の動作を制御する。また、システム制御部1208は操作部1209の入力情報に応じて記録再生装置1200の各部を制御する。1221はメモリカードやハードディスク等の記録媒体1222とのインタフェースである。記録媒体1222は、メモリカード等の記録媒体であり、半導体メモリや磁気ディスク等から構成される。   The system control unit 1208 controls an operation of a series of imaging processes from reading a signal from the imaging unit 1203 to writing image data to the recording medium 1222 in response to a shooting start request from the operation unit 1209. Further, the system control unit 1208 controls each unit of the recording / reproducing apparatus 1200 in accordance with input information from the operation unit 1209. Reference numeral 1221 denotes an interface with a recording medium 1222 such as a memory card or a hard disk. The recording medium 1222 is a recording medium such as a memory card, and includes a semiconductor memory or a magnetic disk.

図13は、符号化処理部1206の詳細について説明する図である。
原画像データ1300は、画像処理部1205が出力したデータである。原画像データ1300は一旦前述したメモリ1207に保持される。メモリ1207はシステム全体で使用する共通メモリである。メモリ1207に出力されたデータを原画像データ1301とする。
FIG. 13 is a diagram illustrating details of the encoding processing unit 1206.
The original image data 1300 is data output by the image processing unit 1205. The original image data 1300 is once held in the memory 1207 described above. A memory 1207 is a common memory used in the entire system. The data output to the memory 1207 is referred to as original image data 1301.

フレーム間予測部1305は、動き検出部1305(a)と動き補償部1305(b)を有し、入力された原画像データ1301と後述する局所復号化データ1302を元にフレーム間予測処理を行い、フレーム間予測画像データを生成する。
フレーム内/フレーム間判定部1304は入力された原画像データ1301を用いてフレーム内予測処理を行う。そして、フレーム間予測部1305から出力されたフレーム間予測画像データと比較して、フレーム内予測とフレーム間予測のいずれかを最終的なマクロブロックとするかを判定する。
The inter-frame prediction unit 1305 includes a motion detection unit 1305 (a) and a motion compensation unit 1305 (b), and performs inter-frame prediction processing based on the input original image data 1301 and local decoded data 1302 described later. The inter-frame prediction image data is generated.
An intra-frame / inter-frame determination unit 1304 performs intra-frame prediction processing using the input original image data 1301. Then, by comparing with the inter-frame prediction image data output from the inter-frame prediction unit 1305, it is determined whether either intra-frame prediction or inter-frame prediction is the final macroblock.

フレーム内/フレーム間判定部1304とフレーム間予測部1305は、入力された原画像データの特性に応じてマクロブロック内のブロックサイズを決定する。例えば、画像が複雑な模様である場合は8×8マクロブロックを使用することで画質の向上を図る。なお、入力された原画像データの特性に関わらず、システム制御部1208がフレーム内/フレーム間判定部1304とフレーム間予測部1305を制御することでマクロブロック内のブロックサイズを決定することができる。   The intra-frame / inter-frame determination unit 1304 and the inter-frame prediction unit 1305 determine the block size in the macro block according to the characteristics of the input original image data. For example, when the image has a complicated pattern, the image quality is improved by using 8 × 8 macroblocks. Regardless of the characteristics of the input original image data, the system control unit 1208 can determine the block size in the macroblock by controlling the intra-frame / inter-frame determination unit 1304 and the inter-frame prediction unit 1305. .

ブロック計数部1306は、フレーム内/フレーム間判定部1304、フレーム間予測部1305で決定したマクロブロックから特定のブロックサイズをもつマクロブロックを計数し、システム制御部1208に通知する。本実施形態では8×8マクロブロックを計数する。   The block counting unit 1306 counts macroblocks having a specific block size from the macroblocks determined by the intraframe / interframe determination unit 1304 and the interframe prediction unit 1305 and notifies the system control unit 1208 of the macroblocks. In this embodiment, 8 × 8 macroblocks are counted.

フレーム内/フレーム間判定部1304にて選択されたマクロブロックタイプがフレーム間予測の場合、動き補償部1305(b)で生成された予測マクロブロック画像は、差分器1303にて現フレームの原画像データ1301との間で差分処理される。そして、差分マクロブロック画像として直交変換部1307に入力される。この際、同時に予測マクロブロック画像は1311のパスを経由して局所復号部1308内の図示しない加算器に出力される。   When the macroblock type selected by the intra-frame / inter-frame determination unit 1304 is inter-frame prediction, the predicted macro-block image generated by the motion compensation unit 1305 (b) is the original image of the current frame by the difference unit 1303. Difference processing is performed with respect to the data 1301. Then, it is input to the orthogonal transform unit 1307 as a difference macroblock image. At this time, the predicted macroblock image is simultaneously output to an adder (not shown) in the local decoding unit 1308 via the 1311 path.

直交変換部1307は、差分器1303から出力された差分マクロブロック画像に直行変換をして変換係数を求めた後、マクロブロックごと変換係数に所定の量子化スケールを適用して量子化する。また、本実施形態では、直交変換にDCT(Discrete Cosin Transfer)を使用するがこれに限定されない。   The orthogonal transform unit 1307 performs orthogonal transform on the difference macroblock image output from the subtractor 1303 to obtain transform coefficients, and then quantizes the macroblock by applying a predetermined quantization scale to the transform coefficients. In this embodiment, DCT (Discrete Cosin Transfer) is used for orthogonal transform, but the present invention is not limited to this.

エントロピー符号化部1309は、直交変換部1307から出力された量子化データをエントロピー符号化する。さらに、フレーム内/フレーム間判定部1304で得られたフレーム内予測のモード情報、及び、フレーム間予測部1305で得られたフレーム間予測の動き情報についてもそれぞれエントロピー符号化し、メモリ1207に出力する。   The entropy encoding unit 1309 performs entropy encoding on the quantized data output from the orthogonal transform unit 1307. Furthermore, the mode information for intra-frame prediction obtained by the intra-frame / inter-frame determination unit 1304 and the motion information for inter-frame prediction obtained by the inter-frame prediction unit 1305 are also entropy-coded and output to the memory 1207. .

局所復号部1308は、直交変換部1307から出力された量子化変換係数に対して、逆量子化及び逆直交交換を実施し、局所復号画像データを生成し、メモリ1207に出力する。メモリ1207に出力されたデータを局所復号化データ1302とする。符号量制御部1310は決められた目標符号量に対し、バッファモデルを維持するように符号量を調整する。   The local decoding unit 1308 performs inverse quantization and inverse orthogonal exchange on the quantized transform coefficient output from the orthogonal transform unit 1307, generates local decoded image data, and outputs the local decoded image data to the memory 1207. The data output to the memory 1207 is referred to as local decoded data 1302. The code amount control unit 1310 adjusts the code amount so as to maintain the buffer model with respect to the determined target code amount.

次に、フレーム間予測部1305の動作について説明する。
フレーム間予測部1305は、動き検出部1305(a)と動き補償部(b)を有する。動き検出部1305(a)は、入力された原画像データ1301と局所復号化データ1302から画像の類似度を評価する。類似度は探索範囲内において参照する位置をずらしながら順次ブロックマッチングした結果に基づいて、処理対象ブロックの動きベクトル(動き情報)を決定する。さらに、動き補償部1305(b)は、動き検出処理によって決定した動きベクトルを用い、参照フレームから抜き出された予想マクロブロック画像を生成して、フレーム間予測画像データとして出力する。
Next, the operation of the inter-frame prediction unit 1305 will be described.
The inter-frame prediction unit 1305 includes a motion detection unit 1305 (a) and a motion compensation unit (b). The motion detection unit 1305 (a) evaluates the similarity between images from the input original image data 1301 and local decoded data 1302. The similarity is determined based on the result of sequential block matching while shifting the reference position within the search range, and the motion vector (motion information) of the processing target block is determined. Furthermore, the motion compensation unit 1305 (b) generates a predicted macroblock image extracted from the reference frame using the motion vector determined by the motion detection process, and outputs the predicted macroblock image as interframe predicted image data.

図14は、第4の実施形態における特定のブロックサイズをもつマクロブロックの数に応じて符号化する制御方法について説明するフローチャートである。本フローチャートにおける各処理は、システム制御部1208が不揮発性メモリ1211に格納されたプログラムをシステムメモリ1210に展開して実行することにより実現される。   FIG. 14 is a flowchart illustrating a control method for encoding according to the number of macroblocks having a specific block size in the fourth embodiment. Each process in this flowchart is realized by the system control unit 1208 developing a program stored in the nonvolatile memory 1211 in the system memory 1210 and executing the program.

S1401では、システム制御部1208はブロック計数部1306から通知された計数をシステムメモリ1210から読み出し、8×8マクロブロックの数が1フレーム内で所定の閾値を超えていないか確認する。超えている場合はS1402に進み、超えていない場合はS1403に進む。   In step S1401, the system control unit 1208 reads the count notified from the block count unit 1306 from the system memory 1210, and checks whether the number of 8 × 8 macroblocks exceeds a predetermined threshold within one frame. When it exceeds, it progresses to S1402, and when it does not exceed, it progresses to S1403.

S1402では、システム制御部1208は後述するS1404で、16×16マクロブロックを使用してフレーム内予測処理、フレーム間予測処理をするようフレーム内/フレーム間判定部1304、フレーム間予測部1305を制御する。ここで、16×16マクロブロックは第2のブロックサイズであり、第1のブロックサイズである8×8マクロブロックより大きい。
S1403では、システム制御部1208は後述するS1404で、原画像データに応じてマクロブロック内のブロックサイズを決定するようフレーム内/フレーム間判定部1304、フレーム間予測部1305を制御する。
In step S1402, the system control unit 1208 controls the intra-frame / inter-frame determination unit 1304 and the inter-frame prediction unit 1305 to perform intra-frame prediction processing and inter-frame prediction processing using 16 × 16 macroblocks in step S1404 described later. To do. Here, the 16 × 16 macroblock has a second block size and is larger than the 8 × 8 macroblock which is the first block size.
In S1403, the system control unit 1208 controls the intra-frame / inter-frame determination unit 1304 and the inter-frame prediction unit 1305 so as to determine the block size in the macroblock according to the original image data in S1404 described later.

S1404では、システム制御部1208はフレーム内/フレーム間判定部1304とフレーム間予測部1305を制御して画素ごとにフレーム内予測データまたはフレーム間予測データを生成する。
S1405では、システム制御部1208はブロック計数部1306を制御して、S1404で生成されたマクロブロックの内、ブロックサイズが8×8画素であるマクロブロックの数を計数する。
In step S1404, the system control unit 1208 controls the intra-frame / inter-frame determination unit 1304 and the inter-frame prediction unit 1305 to generate intra-frame prediction data or inter-frame prediction data for each pixel.
In step S1405, the system control unit 1208 controls the block counting unit 1306 to count the number of macroblocks having a block size of 8 × 8 pixels among the macroblocks generated in step S1404.

S1406では、システム制御部1208は当該フレーム内のすべての画素の符号化が完了したか否かを判定する。YESの場合はS1408に進み、当該フレームの符号化を完了する。NOの場合はS37に進む。
S1407では、システム制御部1208はエントロピー符号化部1309を制御して、直交変換部1307から出力された量子化データをエントロピー符号化し、符号化データをメモリ1207に出力する。
In step S1406, the system control unit 1208 determines whether encoding of all pixels in the frame has been completed. If YES, the process proceeds to S1408, and the encoding of the frame is completed. If NO, the process proceeds to S37.
In step S <b> 1407, the system control unit 1208 controls the entropy encoding unit 1309 to entropy encode the quantized data output from the orthogonal transform unit 1307 and output the encoded data to the memory 1207.

以上のように、第4の実施形態によれば、1フレーム内で、8×8マクロブロックの数が閾値を超えた場合、残りの画素データにおいては、第2のブロックサイズまたは第2のマクロブロック・モード(フレーム内参照マクロブロック)で符号化する。復号化時にシステム破綻が発生しないよう、符号化時に符号化するマクロブロック内のブロックサイズを調整することにより、画像データの復号化時にメモリアクセス増加による画の停止を防ぐことができる。   As described above, according to the fourth embodiment, when the number of 8 × 8 macroblocks exceeds a threshold in one frame, the remaining block of pixel data has the second block size or the second macro. Encode in block mode (intraframe reference macroblock). By adjusting the block size in the macroblock to be encoded at the time of encoding so that system failure does not occur at the time of decoding, it is possible to prevent the stop of the image due to an increase in memory access when decoding the image data.

また、S1405で計数するマクロブロックは、ブロックサイズを8×8画素としたが、ブロックサイズを限定するものではない。
更に、S1402で、符号化するマクロブロックのブロックサイズを、16×16画素としたが、ブロックサイズを限定するものではない。
Further, the macroblock counted in S1405 has a block size of 8 × 8 pixels, but the block size is not limited.
Furthermore, although the block size of the macroblock to be encoded is set to 16 × 16 pixels in S1402, the block size is not limited.

(第5の実施形態)
次に、本発明の第5の実施形態について説明する。第4の実施形態では、1フレームで指定したブロックサイズをもつマクロブロックの数が閾値を超えた場合、残りの画素を前記ブロックサイズより大きいサイズで符号化することについて述べた。本実施形態においては、指定したブロックサイズを持つマクロブロックの数が閾値を超えた場合の、次のフレームを符号化する際のマクロブロックの配置方法について述べる。
(Fifth embodiment)
Next, a fifth embodiment of the present invention will be described. In the fourth embodiment, when the number of macroblocks having a block size specified in one frame exceeds a threshold, the remaining pixels are encoded with a size larger than the block size. In the present embodiment, a macroblock arrangement method for encoding the next frame when the number of macroblocks having a designated block size exceeds a threshold will be described.

図15は、本発明を適用できる記録再生装置1200の構成例を示すブロック図である。1501以外は第4の実施形態と同様なのでここでは説明を省く。
1501は、マクロブロック配置部であり、符号化時に指定したブロックサイズをもつマクロブロックの配置を決定する。
FIG. 15 is a block diagram showing a configuration example of a recording / reproducing apparatus 1200 to which the present invention can be applied. Since other than 1501 is the same as that of the fourth embodiment, the description is omitted here.
Reference numeral 1501 denotes a macroblock arrangement unit that determines the arrangement of macroblocks having a block size designated at the time of encoding.

図16は、第5の実施形態における符号化時にマクロブロックの配置を制御する制御方法について説明するフローチャートである。本フローチャートにおける各処理は、システム制御部1208が不揮発性メモリ1211に格納されたプログラムをシステムメモリ1210に展開して実行することにより実現される。   FIG. 16 is a flowchart for explaining a control method for controlling the arrangement of macroblocks at the time of encoding in the fifth embodiment. Each process in this flowchart is realized by the system control unit 1208 developing a program stored in the nonvolatile memory 1211 in the system memory 1210 and executing the program.

S1601では、システム制御部1208はブロック計数部1306がシステムメモリ1210に保持した計数結果から、前フレームの符号化で8×8マクロブロックの数が閾値を超えていないか確認する。超えている場合はS1602に進む。超えていない場合はS1611に進み、図14で前述したフローチャートの処理を実行する。   In step S <b> 1601, the system control unit 1208 confirms whether the number of 8 × 8 macroblocks exceeds the threshold in the previous frame encoding from the count result held by the block counting unit 1306 in the system memory 1210. If exceeded, the process proceeds to S1602. If not, the process advances to step S1611 to execute the process of the flowchart described above with reference to FIG.

S1602では、システム制御部1208は当該フレームがBピクチャ、Pピクチャ等の参照フレームかを判断する。Iピクチャ等の非参照フレームの場合、S1611に進み、前述した図14のフローチャートの処理を実行する。
S1603では、システム制御部1208はマクロブロック配置部1501を制御して、マクロブロックが画面の周辺か判定する。画面の周辺であれば、S1604に進む。画面の周辺でなければ、S1605に進む。本処理の詳細は図17で後述する。
In step S1602, the system control unit 1208 determines whether the frame is a reference frame such as a B picture or a P picture. In the case of a non-reference frame such as an I picture, the process advances to step S1611 to execute the process of the flowchart in FIG.
In step S1603, the system control unit 1208 controls the macroblock placement unit 1501 to determine whether the macroblock is the periphery of the screen. If it is the periphery of the screen, the process proceeds to S1604. If it is not the periphery of the screen, the process proceeds to S1605. Details of this processing will be described later with reference to FIG.

S1604では、システム制御部1208は後述するS1606で、第1のブロックサイズである8×8マクロブロックより大きい第2のブロックサイズである16×16マクロブロックを使用する。そして、フレーム内予測処理またはフレーム間予測処理をするようフレーム内/フレーム間判定部1304、またはフレーム間予測部1305を制御する。
S1605では、システム制御部1208は後述するS1606で、原画像データに応じてマクロブロック内のブロックサイズ、種類を決定するようフレーム内/フレーム間判定部1304、またはフレーム間予測部1305を制御する。
In S1604, the system control unit 1208 uses a 16 × 16 macroblock having a second block size larger than the first block size of 8 × 8 macroblock in S1606 described later. Then, the intra-frame / inter-frame determination unit 1304 or the inter-frame prediction unit 1305 is controlled to perform intra-frame prediction processing or inter-frame prediction processing.
In step S1605, the system control unit 1208 controls the intra-frame / inter-frame determination unit 1304 or the inter-frame prediction unit 1305 to determine the block size and type in the macro block according to the original image data in step S1606 described later.

S1606では、システム制御部1208はフレーム内/フレーム間判定部1304、フレーム間予測部1305を制御して画素ごとにフレーム内予測データまたはフレーム間予測データを生成する。
S1607では、システム制御部1208はブロック計数部1306を制御して、S1606で生成されたマクロブロックのうち、8×8マクロブロックを計数する。
In step S1606, the system control unit 1208 controls the intra-frame / inter-frame determination unit 1304 and the inter-frame prediction unit 1305 to generate intra-frame prediction data or inter-frame prediction data for each pixel.
In S1607, the system control unit 1208 controls the block counting unit 1306 to count 8 × 8 macroblocks among the macroblocks generated in S1606.

S1608では、システム制御部1208は当該フレーム内のすべての画素の符号化が完了したか判定する。YESの場合はS1610に進み、当該フレームの符号化を完了する。NOの場合はS1609に進む。
S1609では、システム制御部1208はエントロピー符号化部1309を制御して、直交変換部1307から出力された量子化データをエントロピー符号化し、符号化データをメモリ1207に出力する。
In step S1608, the system control unit 1208 determines whether encoding of all pixels in the frame has been completed. If YES, the process advances to S1610 to complete the encoding of the frame. If NO, the process proceeds to S1609.
In step S <b> 1609, the system control unit 1208 controls the entropy encoding unit 1309 to entropy encode the quantized data output from the orthogonal transform unit 1307 and output the encoded data to the memory 1207.

図17は、前述したS1603の画面周辺の配置方法について説明する図である。
符号化対象のフレームとして入力される原画像データは、図17の1700で示すように、フレームを矩形領域に分割した、複数の画素群よりなるマクロブロック毎に符号化される。ここでは1710が一つのマクロブロックを示す。
FIG. 17 is a diagram for explaining the arrangement method around the screen in S1603 described above.
Original image data input as a frame to be encoded is encoded for each macroblock composed of a plurality of pixel groups obtained by dividing the frame into rectangular regions as indicated by reference numeral 1700 in FIG. Here, reference numeral 1710 denotes one macroblock.

システム制御部1208は、前フレームでカウントした16×16マクロブロックの数(αとする)を、カウント結果を本フレームで画面周辺に配置するマクロブロックの総数とする。
画面周辺に使用するマクロブロックの数のパラメタは、図17の垂直方向の上下1701と1702、水平方向の左右1703と1704の4種類がある。マクロブロック配置部1501は1701〜1704の総数が前述したα内に収まるように16×16マクロブロックを配置する。
The system control unit 1208 sets the number of 16 × 16 macroblocks (α) counted in the previous frame as the total number of macroblocks arranged in the periphery of the screen in this frame.
There are four types of parameters for the number of macroblocks used in the periphery of the screen: vertical vertical 1701 and 1702 and horizontal horizontal 1703 and 1704 in FIG. The macroblock arranging unit 1501 arranges 16 × 16 macroblocks so that the total number of 1701 to 1704 is within α described above.

以上のように、第5の実施形態によれば、符号化時にブロックサイズが大きなマクロブロックは画面上の周辺に配置する。画面中央部は人が注目しやすいため、画面中央に16×16マクロブロックだけに制限すると画質劣化が目立つ。そこで、16×16マクロブロックを人の注目度が下がる画面周辺に配置することで、符号対象フレームを復号化する時の画質劣化を目立たなくすることができる。   As described above, according to the fifth embodiment, macroblocks having a large block size are arranged in the periphery on the screen during encoding. Since the central portion of the screen is easily noticed by humans, image quality degradation is conspicuous if restricted to only 16 × 16 macroblocks in the center of the screen. Therefore, by arranging 16 × 16 macroblocks around the screen where the degree of attention of the person is reduced, it is possible to make the image quality degradation inconspicuous when decoding the encoding target frame.

なお、本実施形態ではS1601で判定するブロックサイズを8×8画素としたが、ブロックサイズを限定するものではない。また、S1607で計測するマクロブロックはブロックサイズが8×8画素としたが、ブロックサイズを限定するものではない。更に、S1604で、符号化するマクロブロックのブロックサイズを16×16画素としたが、ブロックサイズを限定するものではない。   In the present embodiment, the block size determined in S1601 is 8 × 8 pixels, but the block size is not limited. Further, although the block size of the macro block measured in S1607 is 8 × 8 pixels, the block size is not limited. Furthermore, in S1604, the block size of the macroblock to be encoded is set to 16 × 16 pixels, but the block size is not limited.

(その他の実施形態)
また、本発明は、以下の処理を実行することによっても実現される。即ち、前述した実施形態の機能を実現するソフトウェア(コンピュータプログラム)を、ネットワーク又は各種のコンピュータ読み取り可能な記憶媒体を介してシステム或いは装置に供給する。そして、そのシステム或いは装置のコンピュータ(またはCPUやMPU等)がプログラムを読み出して実行する処理である。
(Other embodiments)
The present invention can also be realized by executing the following processing. That is, software (computer program) that implements the functions of the above-described embodiments is supplied to a system or apparatus via a network or various computer-readable storage media. Then, the computer (or CPU, MPU, etc.) of the system or apparatus reads out and executes the program.

101 CPB
102 復号部
103 DPB
104 ピクチャ格納部
105 制御部
106 バス
101 CPB
102 Decoding unit 103 DPB
104 Picture storage unit 105 Control unit 106 Bus

Claims (13)

フレーム間予測符号化を用いて圧縮符号化された圧縮画像データを復号化する画像復号化装置において、
前記圧縮画像データを記憶する第1のバッファと、
復号化されたピクチャを記憶する第2のバッファと、
前記第2のバッファに記憶されるピクチャを参照して、前記第1のバッファに記憶される前記圧縮画像データを復号化し、復号化されたピクチャを前記第2のバッファに記憶する復号化手段と、
前記復号化手段が復号化したピクチャ内に特定の条件を満たす符号化ブロックの数をカウントするカウント手段と、
装置全体の動作を制御する制御手段とを有し、
前記制御手段は、
前記第1のバッファに格納されている画像データのピクチャタイプを判断するピクチャタイプ判断手段と、
前記ピクチャタイプ判断手段の判断結果と、前記カウント手段のカウント結果とから、復号化処理を行わずに代わりに代替ピクチャとする境界を判断する境界判断手段とを有し、
前記境界判断手段によって境界と判断されたピクチャ以降、所定枚数のピクチャの復号化を行わずに、代替ピクチャとすることを特徴とする画像復号化装置。
In an image decoding apparatus for decoding compressed image data that has been compression-encoded using inter-frame prediction encoding,
A first buffer for storing the compressed image data;
A second buffer for storing decoded pictures;
Decoding means for decoding the compressed image data stored in the first buffer with reference to the picture stored in the second buffer and storing the decoded picture in the second buffer; ,
Counting means for counting the number of encoded blocks satisfying a specific condition in the picture decoded by the decoding means;
Control means for controlling the operation of the entire apparatus,
The control means includes
Picture type determination means for determining a picture type of image data stored in the first buffer;
Boundary determination means for determining a boundary as an alternative picture instead of performing decoding processing from the determination result of the picture type determination means and the count result of the counting means;
An image decoding apparatus characterized in that, after a picture determined to be a boundary by the boundary determination means, a predetermined number of pictures are not decoded and are used as substitute pictures.
前記所定枚数は、同一のピクチャタイプが続くまでとすることを特徴とする請求項1に記載の画像復号化装置。   The image decoding apparatus according to claim 1, wherein the predetermined number of images is until the same picture type continues. 前記制御手段は、フレームレートが高いときは、前記所定枚数を増やし、フレームレートが低いときは、前記所定枚数を減らすことを特徴とする請求項1に記載の画像復号化装置。   2. The image decoding apparatus according to claim 1, wherein the control unit increases the predetermined number when the frame rate is high, and decreases the predetermined number when the frame rate is low. 前記所定枚数は、前記境界となるピクチャのサイズに対して、所定値以上のサイズのピクチャが出てくるまでとすることを特徴とする請求項1に記載の画像復号化装置。   2. The image decoding apparatus according to claim 1, wherein the predetermined number is set until a picture having a size larger than a predetermined value with respect to a size of the picture serving as the boundary appears. 前記代替ピクチャは、対象ピクチャの表示順で最も近いピクチャが選択されることを特徴とする請求項1〜4の何れか1項に記載の画像復号化装置。   The image decoding apparatus according to claim 1, wherein the substitute picture is selected as a picture closest to the display order of the target picture. 前記代替ピクチャは、対象ピクチャが復号化時に参照するピクチャの中から選択されることを特徴とする請求項1〜4の何れか1項に記載の画像復号化装置。   The image decoding apparatus according to claim 1, wherein the substitute picture is selected from pictures that the target picture refers to when decoding. 画像入力手段と、
前記画像入力手段により入力された複数の画素を集めてブロック化するブロック化手段と、
前記ブロック化手段によりブロック化された複数のブロックを集め、マクロブロック毎に符号化する符号化手段と、
前記符号化手段が符号化する時に用いられた第1のブロックサイズを計数するブロック計数手段と、
前記画像入力手段により入力された画素データ、及び前記符号化手段により符号化された画像データをメモリに保持する保持手段と、
装置全体の動作を制御する制御手段とを有し、
前記制御手段は、1フレーム内で前記ブロック計数手段で計数した値が所定値を超えた場合、
符号化対象のフレームにおける残りの画素データにおいては、前記第1のブロックサイズより大きい第2のブロックサイズ、または第2のマクロブロック・モードで符号化することを特徴とする画像符号化装置。
Image input means;
Blocking means for collecting and blocking a plurality of pixels input by the image input means;
Encoding means for collecting a plurality of blocks blocked by the blocking means and encoding each block;
Block counting means for counting a first block size used when the encoding means encodes;
Holding means for holding the pixel data input by the image input means and the image data encoded by the encoding means in a memory;
Control means for controlling the operation of the entire apparatus,
The control means, when the value counted by the block counting means within one frame exceeds a predetermined value,
The remaining pixel data in the encoding target frame is encoded in a second block size larger than the first block size or in a second macroblock mode.
前記第2のマクロブロック・モードとは、フレーム内参照マクロブロックであることを特徴とする請求項7に記載の画像符号化装置。   The image coding apparatus according to claim 7, wherein the second macroblock mode is an intra-frame reference macroblock. 前記第2のブロックサイズ、もしくは第2のマクロブロック・モードを用いて符号化する際の画面上のマクロブロックの配置を決定するマクロブロック配置手段を有し、
前記制御手段は、1フレーム内で、前記ブロック計数手段で取得した計数が所定値を超えた場合、次のフレームの符号化は前記マクロブロック配置手段を制御して、第2のブロックサイズのマクロブロックもしくは第2のマクロブロック・モードで符号化する配置を決定することを特徴とする請求項7に記載の画像符号化装置。
Macroblock arrangement means for determining arrangement of macroblocks on the screen when encoding using the second block size or the second macroblock mode;
When the count obtained by the block counting unit exceeds a predetermined value within one frame, the control unit controls the macroblock arranging unit to encode the second block size macro. 8. The image encoding apparatus according to claim 7, wherein an arrangement for encoding in a block or second macroblock mode is determined.
前記マクロブロック配置手段は、符号対象フレームの画面の端に第2のブロックサイズで符号化するマクロブロック、もしくは第2のマクロブロック・モードで符号化するマクロブロックを配置することを特徴とする請求項9に記載の画像符号化装置。   The macroblock arrangement means arranges a macroblock to be encoded with the second block size or a macroblock to be encoded with the second macroblock mode at the edge of the screen of the encoding target frame. Item 10. The image encoding device according to Item 9. フレーム間予測符号化を用いて圧縮符号化された圧縮画像データを復号化する画像復号化方法において、
前記圧縮画像データを第1のバッファに記憶する記憶工程と、
復号化されたピクチャを第2のバッファに記憶する記憶工程と、
前記第2のバッファに記憶されるピクチャを参照して、前記第1のバッファに記憶される前記圧縮画像データを復号化し、復号化されたピクチャを前記第2のバッファに記憶する復号化工程と、
前記復号化工程が復号化したピクチャ内に特定の条件を満たす符号化ブロックの数をカウントするカウント工程と、
装置全体の動作を制御する制御工程とを有し、
前記制御工程は、
前記第1のバッファに格納されている画像データのピクチャタイプを判断するピクチャタイプ判断工程と、
前記ピクチャタイプ判断工程の判断結果と、前記カウント工程のカウント結果とから、復号化処理を行わずに代わりに代替ピクチャとする境界を判断する境界判断工程とを有し、
前記境界判断工程によって境界と判断されたピクチャ以降、所定枚数のピクチャの復号化を行わずに、代替ピクチャとすることを特徴とする画像復号化方法。
In an image decoding method for decoding compressed image data that has been compression-encoded using inter-frame predictive encoding,
A storage step of storing the compressed image data in a first buffer;
Storing the decoded picture in a second buffer;
A decoding step of decoding the compressed image data stored in the first buffer with reference to the picture stored in the second buffer, and storing the decoded picture in the second buffer; ,
A counting step of counting the number of encoded blocks satisfying a specific condition in the picture decoded by the decoding step;
A control process for controlling the operation of the entire apparatus,
The control step includes
A picture type determination step of determining a picture type of image data stored in the first buffer;
From the determination result of the picture type determination step and the count result of the counting step, there is a boundary determination step of determining a boundary as an alternative picture instead of performing a decoding process,
An image decoding method characterized in that after a picture determined to be a boundary by the boundary determination step, a predetermined number of pictures are not decoded and are used as substitute pictures.
フレーム間予測符号化を用いて圧縮符号化された圧縮画像データを復号化する画像復号化方法をコンピュータに実行させるプログラムにおいて、
前記圧縮画像データを第1のバッファに記憶する記憶工程と、
復号化されたピクチャを第2のバッファに記憶する記憶工程と、
前記第2のバッファに記憶されるピクチャを参照して、前記第1のバッファに記憶される前記圧縮画像データを復号化し、復号化されたピクチャを前記第2のバッファに記憶する復号化工程と、
前記復号化工程が復号化したピクチャ内に特定の条件を満たす符号化ブロックの数をカウントするカウント工程と、
装置全体の動作を制御する制御工程とをコンピュータに実行させ、
前記制御工程は、
前記第1のバッファに格納されている画像データのピクチャタイプを判断するピクチャタイプ判断工程と、
前記ピクチャタイプ判断工程の判断結果と、前記カウント工程のカウント結果とから、復号化処理を行わずに代わりに代替ピクチャとする境界を判断する境界判断工程とを実行し、
前記境界判断工程によって境界と判断されたピクチャ以降、所定枚数のピクチャの復号化を行わずに、代替ピクチャとすることをコンピュータに実行させることを特徴とするプログラム。
In a program that causes a computer to execute an image decoding method for decoding compressed image data that has been compression-encoded using inter-frame predictive encoding,
A storage step of storing the compressed image data in a first buffer;
Storing the decoded picture in a second buffer;
A decoding step of decoding the compressed image data stored in the first buffer with reference to the picture stored in the second buffer, and storing the decoded picture in the second buffer; ,
A counting step of counting the number of encoded blocks satisfying a specific condition in the picture decoded by the decoding step;
Causing the computer to execute a control process for controlling the operation of the entire apparatus,
The control step includes
A picture type determination step of determining a picture type of image data stored in the first buffer;
From the determination result of the picture type determination step and the count result of the counting step, perform a boundary determination step of determining a boundary as an alternative picture instead of performing a decoding process,
A program for causing a computer to execute a substitute picture without decoding a predetermined number of pictures after a picture determined to be a boundary in the boundary determination step.
請求項12に記載のプログラムを記憶したことを特徴とするコンピュータ読み取り可能な記憶媒体。   A computer-readable storage medium storing the program according to claim 12.
JP2013127885A 2013-06-18 2013-06-18 Image decoding device and image decoding method Pending JP2015002541A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2013127885A JP2015002541A (en) 2013-06-18 2013-06-18 Image decoding device and image decoding method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2013127885A JP2015002541A (en) 2013-06-18 2013-06-18 Image decoding device and image decoding method

Publications (1)

Publication Number Publication Date
JP2015002541A true JP2015002541A (en) 2015-01-05

Family

ID=52296791

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013127885A Pending JP2015002541A (en) 2013-06-18 2013-06-18 Image decoding device and image decoding method

Country Status (1)

Country Link
JP (1) JP2015002541A (en)

Similar Documents

Publication Publication Date Title
JP4799438B2 (en) Image recording apparatus, image recording method, image encoding apparatus, and program
JP5014195B2 (en) Imaging apparatus, control method thereof, and program
JP5156704B2 (en) Image coding apparatus, image coding method, integrated circuit, and camera
JP5086879B2 (en) Image processing apparatus, control method therefor, and program
US10674110B2 (en) Image encoding apparatus, and control method thereof
BR112021013735A2 (en) IMAGE ENCODING METHOD AND DEVICE TO PERFORM MRL-BASED INTRAPREDICTION
US9319682B2 (en) Moving image encoding apparatus, control method therefor, and non-transitory computer readable storage medium
TW202015403A (en) Video coding and decoding
JP4771986B2 (en) Image encoding apparatus and imaging apparatus using the same
JP2008153907A (en) Image encoding apparatus, information terminal including the same, and image encoding method
US20170142439A1 (en) Encoding apparatus, encoding method, and storage medium
JP5396302B2 (en) Video signal encoding apparatus and video signal encoding method
JP2011130030A (en) Image encoding method and image encoder
US8953055B2 (en) Image pickup apparatus
US10516896B2 (en) Encoding device, encoding method, and storage medium
JP2015002541A (en) Image decoding device and image decoding method
JP5165084B2 (en) Image encoding device
US7412079B2 (en) Image processing apparatus
JP4700992B2 (en) Image processing device
JP4594163B2 (en) Image coding method and image coding apparatus
TW202017387A (en) Video coding and decoding
JP4564856B2 (en) Image encoding apparatus and imaging apparatus
JP7148236B2 (en) Encoding device and its control method and program
JP2009081727A (en) Image encoding apparatus, method of controlling therefor, and program
JP2023030585A (en) Image encoder, method and program