JP2006211323A - Image processor - Google Patents
Image processor Download PDFInfo
- Publication number
- JP2006211323A JP2006211323A JP2005021104A JP2005021104A JP2006211323A JP 2006211323 A JP2006211323 A JP 2006211323A JP 2005021104 A JP2005021104 A JP 2005021104A JP 2005021104 A JP2005021104 A JP 2005021104A JP 2006211323 A JP2006211323 A JP 2006211323A
- Authority
- JP
- Japan
- Prior art keywords
- code amount
- image
- memory
- encoded data
- image data
- 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.)
- Withdrawn
Links
Images
Landscapes
- Compression Of Band Width Or Redundancy In Fax (AREA)
- Image Processing (AREA)
- Studio Devices (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
Description
本発明は、ディジタルスチルカメラ等に用いて好適な画像処理装置に関し、特に、画像の画素数の増加した場合のハードウェア規模の縮小及び開発コストの低減に係わる。 The present invention relates to an image processing apparatus suitable for use in a digital still camera or the like, and more particularly to reduction in hardware scale and development cost when the number of pixels of an image increases.
従来、画像データを効率的に符号化する可変長符号化方式として、例えば、JPEG(Joint Photographic Experts Group)規格に基づく符号化、復号化方式が知られている。この方式においては、画像データを符号化する場合と、復号化する場合の何れの場合においても、(8×8)画素のブロックを入出力の単位としている。 2. Description of the Related Art Conventionally, for example, an encoding / decoding method based on the JPEG (Joint Photographic Experts Group) standard is known as a variable-length encoding method for efficiently encoding image data. In this system, a block of (8 × 8) pixels is used as an input / output unit in both cases where image data is encoded and decoded.
例えば、この方式を備えた画像処理装置により画像データの符号化を行う場合、画像データを(8×8)画素のブロック単位でJPEGの符号化部に入力し、符号化を行う。そして符号化された画像データは、順次、記録媒体に格納される。また、この画像処理装置により画像データの復号化を行う場合、記録媒体に格納された画像データを読み出し、JPEGの復号部により復号化を行い、画像データを(8×8)画素のブロック単位で出力している。 For example, when image data is encoded by an image processing apparatus equipped with this method, the image data is input to a JPEG encoding unit in units of (8 × 8) pixel blocks and encoded. The encoded image data is sequentially stored in a recording medium. When image data is decoded by this image processing apparatus, the image data stored in the recording medium is read out, decoded by the JPEG decoding unit, and the image data is divided into blocks of (8 × 8) pixels. Output.
これに対して、カメラのような画像入力装置やディスプレイのような画像出力装置には、ラスタ単位で画像データが入出力される装置が多い。ラスタ走査では、左から右に走査し、1ラインの走査が終了したら、下のラインに移り、左から右に走査していき、以下、左から右、上から下の順に繰り返し走査が行われる。ラスタ単位の画像データは、ラスタ走査の順に画像データが入出力される。 On the other hand, many image input devices such as cameras and image output devices such as displays input and output image data in raster units. In raster scanning, scanning is performed from left to right. When scanning of one line is completed, the scanning proceeds to the lower line, and scanning is performed from left to right. Thereafter, scanning is repeatedly performed in order from left to right and from top to bottom. . The raster unit image data is input / output in the order of raster scanning.
したがって、このような処理単位がラスタ単位である装置と、JPEG規格に基づく画像処理のような処理単位がブロック単位である装置との間でデータの送受信を行う場合、特許文献1に示されるように、ラスタ単位(又はブロック単位)のデータをメモリに一旦格納し、ブロック単位(又はラスタ単位)でメモリから出力するデータ転送単位の変換(以下、ラスタ−ブロック変換と称する)を行う必要がある。
Therefore, when data is transmitted / received between a device in which such a processing unit is a raster unit and a device in which a processing unit such as image processing based on the JPEG standard is a block unit, as shown in
図24は、従来の画像処理装置100の一例を示すものである。図24において、図示していないカメラなどの画像データ入力装置により、画像データが入力される。入力される画像データは、ベイヤー配列に並んだ単一色(R(赤)、G(緑)、又はB(青))の画像データであり、1フレームの画像は例えば(2564(水平方向)×1924(垂直方向))画素である。入力された画像データは、バス110を介して、大容量メモリ101に格納される。入力された画像データは、大容量メモリ101に、ラスタ走査順に書き込まれる。
FIG. 24 shows an example of a conventional
大容量メモリ101に一旦蓄積された画像データは、書き込み時と同様に、ラスタ走査の順に読み出され、バス110を介して、データ読出部103に読み出される。データ読出部103により読み出された画像データは、前処理部104に送られる。前処理部104では、色補間処理や輪郭強調処理など、好適な画像を生成するための画像処理が行われる。前処理部104により、単一色の画像データが補間処理によりRGBの画像データに変換され、更に、RGBの画像データがYUV(輝度信号Y及び色差信号U、V)の画像データに変換される。
The image data once stored in the large-
前処理部104からのYUVの画像データは、ブロック変換部105に送られる。ブロック変換部105では、ラスタ単位の画像データ形式をブロック単位のデータ形式に変換する処理(ラスタ−ブロック変換)が行われる。例えば、前処理部104からラスタ単位で出力されるY,U,Vそれぞれの画像データは、ブロック変換メモリに8ライン分格納され、後段に対して(8×8)画素のブロック単位毎に出力される。
The YUV image data from the preprocessing
ブロック変換部105でブロック変換された画像データは、符号化部106に送られる。符号化部106で、ブロック変換部105から入力されるブロック単位の画像データが符号化される。例えばJPEG方式で圧縮符号化を行う場合には、ブロック毎にDCT(Discrete Cosine Transform)演算が行われ、時間領域のデータから周波数領域のデータに変換される。DCT変換により周波数領域に変換されたデータは、量子化器で量子化され、ハフマン符号により可変長符号化される。符号化部106からの符号化データは、符号化データ書込部108により、大容量メモリ101に送られる。大容量メモリ101には、符号化データが蓄積される。大容量メモリ101に蓄積された符号化データは、符号化データ読出部109により読み出され、後段に出力される。
上述のような画像処理装置100がディジタルスチルカメラに搭載される場合、画像処理装置100の電装系ユニットはLSI(Large Scale Integration)により実現されることが多い。また、画像処理装置100の大容量メモリ101としては例えばSDRAM(Synchronous Dynamic Random Access Memory)が用いられ、この大容量メモリ101は、LSI外部に配置することが一般的である。
When the
これに対して、前処理部104の色補間処理やブロック変換部105において使用されるメモリは、画像処理過程の途中に配置される場合が多いことや、LSI外部に配置すると処理速度の低下やLSIの端子数の増加を招くことから、一般的に、LSI内部に備えられる。
In contrast, the color interpolation processing of the preprocessing
前処理部104やブロック変換部105において使用されるメモリとしては、以下のようなメモリ量が必要とされる。
As the memory used in the preprocessing
前処理部104では、補間処理により、各画素の単色の画像データから、各画素がR,G,Bの3種類の色情報を有する画像データへの変換が行われる。補間処理には、例えば、着目画素に存在しない色を、着目画素の近傍の画素より補間する例えば(5×5)のフィルタが用いられる。(5×5)のフィルタ処理を行うためには、4個のラインモリ量が必要である。
In the
ブロック変換部105においては、例えば、符号化部106に搭載しているJPEG符号化処理がYUV(4:2:0)を要求している場合、色差の画像データU及びVは1ラインあたりの画素数が半分になるため、輝度の画像データY用として8個のラインメモリが必要であり、色差の画像データU及びV用としてそれぞれ4ライン分のラインメモリが必要である。さらに、これらのブロック変換メモリはスループットを低下させないように書き込み用と読み出し用にその2倍のメモリ量が必要とされる。したがって、画像処理装置100においては、大容量メモリ101以外に、36個のラインメモリが必要である。
In the
しかしながら、画像の画素数の増大に伴い、1ラインあたりの画素数が数千画素を越える画像が増加している。このため、このような多数のラインメモリをLSI内部に備えると、LSIの回路規模や開発コストが増大するという問題がある。 However, with an increase in the number of pixels of an image, an image in which the number of pixels per line exceeds several thousand pixels is increasing. For this reason, if such a large number of line memories are provided inside the LSI, there is a problem that the circuit scale and development cost of the LSI increase.
また、従来の画像処理装置100では、LSI内部に備えられたラインメモリが1ラインあたりの画素数に依存しているため、ラインメモリに格納できる画素数を越える画像に対応できず、画素数が変わると、設計変更が必要である。
Further, in the conventional
本発明は、上述の課題を鑑み、LSI内部に配置されるメモリの使用量を抑えることにより回路規模や開発コストを抑えると共に、画像の画素数の増加に対して柔軟に対応できるようにした画像処理装置を提供することを目的とする。 In view of the above-described problems, the present invention reduces the circuit size and development cost by suppressing the amount of memory used in an LSI, and can flexibly cope with an increase in the number of pixels of an image. An object is to provide a processing apparatus.
上述の課題を解決するために、請求項1に係わる本発明の画像処理装置は、画像データを格納するメモリと、メモリに格納された1フレーム分の画像データを水平方向にM個(Mは正の整数)の小フレームが並んだ画像データとみなし、小フレームをそれぞれラスタ走査順に読み出すデータ読出部と、データ読出部により読み出された画像データを、所定のライン数を処理ラインとして符号化する符号化部と、符号化部から出力される符号化データの符号量を順次格納する符号量記憶部と、符号量記憶部に記憶された各小フレームの対応する処理ラインに係る符号量に基づき、メモリに符号化データを格納するためのアドレスを算定し、メモリのその算定されたアドレスに符号化データを格納する符号化データ書込部と、符号量記憶部に記憶された各小フレームの対応する処理ラインに係る符号量に基づき、メモリに格納された符号化データを読み出すためのアドレスを算定し、メモリのその算定されたアドレスから符号化データを読み出す符号化データ読出部とを備えることを特徴とする。 In order to solve the above problem, an image processing apparatus according to a first aspect of the present invention includes a memory for storing image data, and M pieces of image data for one frame stored in the memory in a horizontal direction (M is It is regarded as image data in which small frames of (positive integers) are arranged, and the data reading unit for reading the small frames in raster scanning order and the image data read by the data reading unit are encoded with a predetermined number of lines as processing lines. An encoding unit, a code amount storage unit that sequentially stores a code amount of encoded data output from the encoding unit, and a code amount related to a processing line corresponding to each small frame stored in the code amount storage unit Based on this, an address for storing the encoded data in the memory is calculated, and the encoded data writing unit for storing the encoded data in the calculated address of the memory and the code amount storage unit are stored. Encoded data for calculating an address for reading out the encoded data stored in the memory based on the code amount associated with the corresponding processing line of each small frame, and reading out the encoded data from the calculated address in the memory And a reading unit.
請求項2に係る本発明の画像処理装置は、請求項1の発明において、符号量記憶部は、各小フレームの対応する処理ラインに係る符号量を加算した符号量を、処理ライン毎に格納することを特徴とする。 According to a second aspect of the present invention, in the first aspect of the present invention, the code amount storage unit stores, for each processing line, a code amount obtained by adding the code amount related to the processing line corresponding to each small frame. It is characterized by doing.
請求項3に係る本発明の画像処理装置は、請求項1の発明において、符号量記憶部は、各小フレームの処理ライン毎に符号量を格納することを特徴とする。 According to a third aspect of the present invention, in the image processing apparatus according to the first aspect, the code amount storage unit stores the code amount for each processing line of each small frame.
請求項1に係る本発明の画像処理装置によれば、1フレームの画像データを水平方向にM個の小フレームが並んだ画像データとみなし、小フレーム毎に画像処理を実行することにより、画像処理装置内のメモリの使用量を抑えることできる。そのため、画像処理装置の規模や開発コストを削減することができる。また、画像の画素数が増大しても小フレームの数を調整することにより、画像処理装置内部のメモリ構成に大きな影響を与えることなく対応することができる。したがって、画像の画素数の増大に対して柔軟に対応可能な画像処理装置を提供することができる。
According to the image processing apparatus of the present invention according to
また、請求項2に係る本発明の画像処理装置によれば、各小フレームの対応する処理ラインに係る符号量を加算した符号量を、処理ライン毎に格納することにより、各処理ラインの符号化データを連続して読み出すことができる。
According to the image processing apparatus of the present invention according to
また、請求項3に係る本発明の画像処理装置によれば、1フレーム分の符号量を小フレーム内の処理ライン毎に記憶する符号量メモリを備えることにより、画像1フレーム分の符号化データを復号せずに、画像の一部分を抽出して符号化データを保存することと、画像の一部分をのみを高速に表示することが可能になる。
In addition, according to the image processing apparatus of the present invention according to
以下、本発明の実施の形態について図面を参照しながら説明する。図1は、本発明が適用された画像処理装置の一例の主要部を示すブロック図である。図1に示すように、本発明が適用された画像処理装置1は、大容量メモリ11と、アドレス記憶部12と、データ読出部13と、前処理部14と、ブロック変換部15と、符号化部16と、符号量記憶部17と、符号化データ書込部18と、符号化データ読出部19とを備える。
Hereinafter, embodiments of the present invention will be described with reference to the drawings. FIG. 1 is a block diagram showing a main part of an example of an image processing apparatus to which the present invention is applied. As shown in FIG. 1, an
大容量メモリ11は、入力画像データを一時的に蓄積すると共に、符号化データを一時的に蓄積する。大容量メモリ11は、入力画像データを蓄積するための入力画像格納領域21と、符号化データを蓄積するための符号化データ格納領域22とを有している。
The large-capacity memory 11 temporarily stores input image data and temporarily stores encoded data. The large-capacity memory 11 has an input
大容量メモリ11の入力画像格納領域21は、少なくとも1フレーム分の画像領域を有する。大容量メモリ11の入力画像格納領域21に画像データを書き込む際には、ラスタ走査の順に書き込みが行われる。大容量メモリ11から画像データを読み出す際には、大容量メモリ11の1フレームの画像データを水平方向にM個の小フレームが並んだ画像データとみなし、各小フレーム毎にラスタ走査順に読み出しを行う。
The input
アドレス記憶部12は、大容量メモリ11に記憶される符号化データのアドレスを記憶するレジスタを備える。このレジスタはメモリで実現しても構わない。また、アドレス記憶部12そのものを画像処理装置1の外部に備えても良い。
The
データ読出部13は、大容量メモリ11の入力画像格納領域21に格納された1フレームの画像データを、水平方向にM個(Mは正の整数)の小フレームが並んだ画像データとみなし、大容量メモリ11から、各小フレーム毎に画像データをラスタ走査順に読み出す。このとき、大容量メモリ11の入力画像格納領域21に格納された画像データを読み出すためのアドレスは、アドレス記憶部12に記憶された該当レジスタ値に基づいて算出される。
The
前処理部14は、色補間処理や輪郭強調処理など、好適な画像を生成するための画像処理を行う。前処理部14により、単一色(R、G、又はB)の画像データは、補間処理によりRGBの画像データに変換され、更に、YUVの画像データに変換される。
The preprocessing
ブロック変換部15は、ラスタ−ブロック変換を行うためのブロック変換メモリを備え、前段から入力されるラスタ単位の画像データ形式をブロック単位のデータ形式に変換して後段に出力する。例えば、JPEG符号化処理を行う画像処理装置1では、前処理部14からラスタ単位で出力されるY,U,Vそれぞれの画像データをブロック変換メモリに8ライン分格納し、後段に対して(8×8)画素のブロック単位毎にYUVの画像データを出力する。また、ブロック変換部15は、ラスタ−ブロック変換によるスループットの低下を発生させないように、書き込み用と読み出し用の2通りのブロック変換メモリを備える。
The
符号化部16は、ブロック変換部15から入力されるブロック単位の画像データを例えばJPEG方式で符号化し、符号化データを後段に出力する。JPEG方式の符号化では、画像データをブロック単位でDCT変換し、時間領域の画像データを周波数領域に変換する。そして、DCT変換された画像データを量子化し、ハフマン符号により可変長符号化する。
The
符号量記憶部17は符号量メモリ31を備えており、符号化部16で画像データを符号化する際に、符号化部16から符号量を取得し、符号量記憶部17の符号量メモリ31に、各処理ライン毎の符号量を記憶する。
The code
符号化データ書込部18は、符号化部16で符号化された画像データを大容量メモリ11に送り、大容量メモリ11の符号化データ格納領域22に記憶させる。大容量メモリ11の符号化データ格納領域22は処理ライン毎に記憶領域が区切られており、符号化された画像データは、大容量メモリ11の符号化データ格納領域22に、処理ライン毎に格納されていく。このとき、大容量メモリ11の符号化データ格納領域22に符号化データを格納するためのアドレスは、アドレス記憶部12に記憶されたアドレスと、符号量記憶部17に記憶された符号量に基づいて算出される。
The encoded
符号化データ読出部19は、大容量メモリ11の符号化データ格納領域22に格納された符号化データを、処理ライン毎に連続して、各処理ラインの有効な符号化データを読み出し、後段に出力する。このとき、大容量メモリ11の符号化データ格納領域22から符号化データを読み出すためのアドレスは、アドレス記憶部12に記憶されたアドレスと、符号量記憶部17に記憶された符号量に基づいて算出される。
The encoded
次に、上述のように構成される画像処理装置の動作について説明する。図1において、図示していないカメラなどの画像データ入力装置により、画像データが入力される。入力された画像データは、バス10を介して、大容量メモリ11に送られる。入力画像データは、大容量メモリ11の入力画像格納領域21に、ラスタ走査順に書き込まれる。画像データは、図2に示すように、R,G,Bの画素がベイヤー配列で並んだ単一色の画像データであり、1フレームの画素数は、例えば(2564(水平方向)×1924(垂直方向))である。
Next, the operation of the image processing apparatus configured as described above will be described. In FIG. 1, image data is input by an image data input device such as a camera (not shown). The input image data is sent to the large-capacity memory 11 via the
大容量メモリ11の入力画像格納領域21に一旦蓄積された画像データは、バス10を介して、データ読出部13に読み出される。このとき、大容量メモリ11の入力画像格納領域21に格納された1フレームの画像データは、水平方向にM個の小フレームが並んだ画像データとみなされ、各小フレーム毎にラスタ走査順に画像データが読み出される。
The image data once accumulated in the input
つまり、図3及び図4は、大容量メモリ11の入力画像格納領域21からのデータの転送を説明するものである。図3に示すように、大容量メモリ11の入力画像格納領域21には、ラスタ走査の順に、(2564画素×1924画素)の画像データが書き込まれる。
That is, FIG. 3 and FIG. 4 illustrate the transfer of data from the input
すなわち、1フレームの最上のライン「1」の画像データが水平方向に2564画素分、左から右に書き込まれる。以下、ライン「1」からライン「1924」まで、各ライン毎に、ラスタ走査の順に画像データが書き込まれる。 That is, the image data of the uppermost line “1” of one frame is written in the horizontal direction for 2564 pixels from left to right. Thereafter, image data is written in the order of raster scanning from line “1” to line “1924” for each line.
大容量メモリ11の入力画像格納領域21から画像データを読み出す際には、図4に示すように、1フレームがM個の小フレームに分割される。この例では、1フレームが4つの小フレームA、B、C、Dに分割される。そして、各小フレームA〜D毎に、ラスタ走査の順に、画像データが読み出される。
When image data is read from the input
すなわち、先ず、小フレームAのライン「1」の画像データが水平方向に644画素分、左から右に読み出される。以下、ライン「1」からライン「1924」まで、各ライン毎に、ラスタ走査の順に画像データが読み出される。 That is, first, the image data of the line “1” of the small frame A is read from the left to the right for 644 pixels in the horizontal direction. Hereinafter, image data is read out in the order of raster scanning for each line from line “1” to line “1924”.
小フレームAの読み出しが終了したら、次に、小フレームBの画像データがライン「1」からライン「1924」までラスタ走査の順に読み出される。小フレームBの読み出しが終了したら、次に、小フレームCの画像データがライン「1」からライン「1924」までラスタ走査の順に読み出され、小フレームCの読み出しが終了したら、小フレームDの画像データがライン「1」からライン「1924」までラスタ走査の順に読み出される。 When the reading of the small frame A is completed, the image data of the small frame B is then read from the line “1” to the line “1924” in the order of raster scanning. When the reading of the small frame B is completed, the image data of the small frame C is then read in the order of raster scanning from the line “1” to the line “1924”, and when the reading of the small frame C is completed, the small frame D is read. Image data is read from line “1” to line “1924” in the order of raster scanning.
このとき、大容量メモリ11の入力画像格納領域21に格納された画像データを読み出すためのアドレスは、アドレス記憶部12に記憶された該当レジスタ値に基づいて算出される。
At this time, an address for reading the image data stored in the input
なお、このように画像を読み出す際、図4に示すように、隣り合う小フレームに重複して読み出される画素の部分Pa〜Pcが存在する。このように、重複して読み出される画素の部分Pa〜Pcが存在する理由については、後に説明する。 When the image is read out in this way, as shown in FIG. 4, there are pixel portions Pa to Pc that are read out redundantly in adjacent small frames. The reason why there are pixel portions Pa to Pc that are redundantly read out will be described later.
また、この例では、1フレームを等分に分割し、全ての小フレームA〜Dの水平方向の画素数を644画素としているが、その画素数は小フレーム毎に異なっていても良い。また、ここでは、1フレームを4個の小フレームに分割しているが、これに限られるものではない。 In this example, one frame is divided equally and the number of pixels in the horizontal direction of all the small frames A to D is 644 pixels. However, the number of pixels may be different for each small frame. Here, one frame is divided into four small frames, but the present invention is not limited to this.
図1において、データ読出部13により、小フレームA〜Dの順に読み出された画像データは、前処理部14に送られる。前処理部14では、色補間処理や輪郭強調処理など、好適な画像を生成するための画像処理が行われる。色補間処理を施された画像データは、1画素がR、G、又はBの単一色の画像データから、1画素がR,G,Bの3種類の色情報を有する画像データになる。補間処理には、例えば、着目画素に存在しない色を、着目画素の近傍の画素より補間する例えば(5×5)の補間フィルタが用いられる。補間処理により各画素毎にRGBの情報を持った画素データは、マトリクス演算により、Y,U,Vの3種類の画像データに変換される。
In FIG. 1, the image data read by the
このような補間処理を行うときのフィルタ処理では、フィルタ処理後の画像サイズがフィルタ処理前の画像サイズより小さくなるという性質がある。なぜなら、図5(A)に示すように、着目画素Pxの周辺に有効な参照画素のデータがある場合には、着目画素Pxの周辺の画像データを用いて、フィルタ演算が行えるが、図5(B)に示すように、フィルタ演算を行う着目画素Pyが画像の端部付近の場合は、(5×5)フィルタの参照画素に有効ではない画像データが含まれるため、その画素の演算結果が無効なデータとなるためである。 The filter process when performing such an interpolation process has a property that the image size after the filter process is smaller than the image size before the filter process. This is because, as shown in FIG. 5A, when there is valid reference pixel data around the pixel of interest Px, filter calculation can be performed using image data around the pixel of interest Px. As shown in (B), when the pixel of interest Py to be subjected to the filter calculation is near the edge of the image, the reference pixel of the (5 × 5) filter includes image data that is not valid, and the calculation result of that pixel Is invalid data.
例えば、本実施の形態のように(644画素×1924画素)の画像サイズの小フレームに対して(5×5)のフィルタ処理を施すと、フィルタ処理後の有効画像サイズは(640画素×1920画素)となる。そのため、フィルタ処理により減少する画像サイズを考慮して、小フレームの画像サイズを決定しなければならない。また、このことが、図4に示したように、隣り合う小フレームに重複して読み出される画素の部分Pa〜Pcが存在する理由である。 For example, when (5 × 5) filter processing is performed on a small frame having an image size of (644 pixels × 1924 pixels) as in the present embodiment, the effective image size after the filter processing is (640 pixels × 1920). Pixel). Therefore, it is necessary to determine the image size of the small frame in consideration of the image size that is reduced by the filtering process. This is also the reason why there are pixel portions Pa to Pc that are read out redundantly in adjacent small frames, as shown in FIG.
図1において、前処理部14からのYUVの画像データは、ブロック変換部15に送られる。ブロック変換部15では、ラスタ単位の画像データ形式をブロック単位のデータ形式に変換する処理が行われる。例えば、JPEG符号化処理を行う場合には、前処理部14からラスタ単位で出力されるY,U,Vそれぞれの画像データは、ブロック変換メモリに8ライン分格納され、後段に対して(8×8)画素のブロック単位毎に出力される。
In FIG. 1, the YUV image data from the preprocessing
ブロック変換部15でブロック変換された画像データは、符号化部16に送られる。符号化部16で、ブロック変換部15から入力されるブロック単位の画像データが符号化される。例えばJPEG方式で圧縮符号化を行う場合には、ブロック毎にDCT演算が行われ、時間領域のデータから周波数領域のデータに変換される。DCT変換により周波数領域に変換されたデータは、量子化器で量子化され、ハフマン符号を用いて可変長符号化される。
The image data block-converted by the
符号化部16で符号化された符号化データの符号量は、符号量記憶部17で取得される。符号量記憶部17には、各処理ライン毎の符号量を記憶する符号量メモリ31が設けられている。符号量メモリ31には、図6に示すように、処理ライン毎の符号量を格納するための領域ARA_M1〜ARA_M240が設けられている。
The code amount of the encoded data encoded by the
符号量記憶部17では、符号化部16により符号化された小フレームが画像左端を含む場合は、小フレーム内の処理ライン(以下、ドメインと称する)の符号量が各処理ラインの毎に符号量メモリ31の領域ARA_M1〜ARA_M240にそれぞれ記憶される。符号化部16により符号化された小フレームが画像左端を含まない場合は、該当ドメインの符号量と、符号量メモリ31の領域ARA_M1〜ARA_M240に既に格納されている該当処理ラインの符号量とが加算され、加算結果が新たな該当処理ラインの符号量として、各処理ライン毎に符号量メモリ31の領域ARA_M1〜ARA_M240にそれぞれ格納される。これにより、符号量記憶部17の符号量メモリ31の領域ARA_M1〜ARA_M240には、各処理ライン毎の符号量がそれぞれ記憶される。
In the code
この例では、可変長符号であるJPEG方式で符号化を行っているため、このような符号量記憶部17が必要になるが、符号化部16における符号化処理が固定長符号化処理の場合は、符号量を予め見積もることができるため、符号量記憶部17を備える必要はない。また、符号量を記憶する代わりに、大容量メモリ11におけるアドレスのステップ幅、又はアドレスそのものを符号量から算出して符号量記憶部17に記憶しても構わない。
In this example, since encoding is performed using the JPEG method, which is a variable-length code, such a code
なお、符号量記憶部17に格納する符号量は、大容量メモリ11に格納された符号化データが不必要になるまで、例えば、後述する符号化データ読出部19により大容量メモリ11から符号化データが読み出され外部記憶媒体(図示せず)に保存されるまで、記憶しておけば良い。また、本実施の形態において複数フレームの画像処理を連続的に実行して、大容量メモリ11に複数フレーム分の符号化データを格納する場合は、そのフレーム数と同数の符号量メモリ31を備えれば良い。この符号量記憶部17の詳細な説明は、以下の符号化データ書込部18の説明と共に行う。
The code amount stored in the code
図1において、符号化部16からの符号化データは、符号化データ書込部18により、大容量メモリ11に送られる。大容量メモリ11の符号化データ格納領域22は、図7に示すように、各処理ライン毎の格納領域に区切られており、処理ライン毎のメモリ領域ARA_N1〜ARA_N240を備えている。符号化データ書込部18により、小フレームを構成する少なくとも1つ以上のドメインの符号化データは、そのドメインが属する処理ラインのメモリ領域ARA_N1〜ARA_N240にそれぞれ格納される。
In FIG. 1, the encoded data from the
このとき、格納される符号化データに対応するドメインが画像左端を含む場合は、該当ドメインが属する処理ラインのメモリ領域ARA_N1〜ARA_N240の先頭から、その符号化データが格納される。一方、格納される符号化データに対応するドメインが画像左端を含まない場合は、各メモリ領域ARA_N1〜ARA_N240において、直前に符号量を格納した小フレームの同一処理ラインに対応する符号化データの直後から、符号化データが格納される。 At this time, if the domain corresponding to the stored encoded data includes the left end of the image, the encoded data is stored from the top of the memory areas ARA_N1 to ARA_N240 of the processing line to which the corresponding domain belongs. On the other hand, when the domain corresponding to the stored encoded data does not include the left end of the image, in each memory area ARA_N1 to ARA_N240, immediately after the encoded data corresponding to the same processing line of the small frame storing the code amount immediately before From this, the encoded data is stored.
すなわち、アドレス記憶部12には、メモリ領域ARA_N1〜ARA_N240の先頭アドレスADDR1〜ADDR240が記憶されている。格納される符号化データに対応するドメインが画像左端を含む場合は、アドレス記憶部12に記憶されている先頭アドレスADDR1〜ADDR240を参照して、各メモリ領域ARA_N1〜ARA_N240の先頭から符号化データが格納される。
That is, the
また、符号化データ書込部18の符号量メモリ31には、それまで格納した同一処理ラインの符号化データの符号量が記憶されている。格納される符号化データに対応するドメインが画像左端を含まない場合は、メモリ領域ARA_N1〜ARA_N240の先頭アドレスADDR1〜ADDR240に、符号化データ書込部18の符号量メモリ31からの符号量に相当するアドレスを加算する。このようにして算定されたアドレスから符号化データを格納することで、各メモリ領域ARA_N1〜ARA_N240において、直前に符号量を格納した小フレームの同一処理ラインに対応する符号化データの直後から、符号化データが格納される。
Further, the
図8は、符号化処理を行う際の小フレーム、処理ライン及びドメインの構成を説明するものである。符号化部16で符号化処理を行う際には、図8において、先ず、小フレームAの処理ライン「1」(ドメインA1)の符号化処理が行われる。なお、(8×8)のブロック化を行った場合、処理ラインは、8ライン分の画素データに相当する。次に、小フレームAの処理ライン「2」(ドメインA2)の符号化処理が行われ、小フレームAの処理ライン「3」(ドメインA3)の符号化処理が行われ、以下、小フレームAの処理ライン「240」(ドメインA240)まで、順に、符号化処理が行われる。
FIG. 8 illustrates the configuration of a small frame, a processing line, and a domain when performing an encoding process. When the
図7に示したように、大容量メモリ11の符号化データ格納領域22は、各ライン毎のメモリ領域ARA_N1〜ARA_N240に区切られており、各ドメインの符号化データは、そのドメインが属する処理ラインのメモリ領域ARA_N1〜ARA_N240にそれぞれ格納される。このとき、格納される符号化データに対応するドメインが画像左端を含む場合は、該当ドメインが属する処理ラインのメモリ領域ARA_N1〜ARA_N240の先頭から、その符号化データが格納される。小フレームAの画像は左端を含んでいるので、各ドメインA1〜A240の符号化データENC_A1〜ENC_A240は、そのドメインが属する処理ラインのメモリ領域ARA_N1〜ARA_N240の先頭から格納される。メモリ領域ARA_N1〜ARA_N240の先頭アドレスADDR1〜ADDR240は、アドレス記憶部12から参照される。
As shown in FIG. 7, the encoded
このように、小フレームAの各処理ライン「1」、「2」、「3」、…、「240」(ドメインA1、A2、A3、…、A240)の符号化を行っていく際に、その符号量が符号量記憶部17で取得される。前述したように、符号量記憶部17では、符号化部16により符号化された小フレームが画像左端を含む場合は、小フレーム内の処理ライン(ドメイン)の符号量が各処理ラインの領域毎に符号量メモリ31に記憶される。小フレームAの画像は左端を含んでいるので、小フレームA内の各処理ライン(ドメイン)の符号量は、各処理ラインの領域毎に、符号量記憶部17の符号量メモリ31に記憶される。
Thus, when encoding each processing line “1”, “2”, “3”,..., “240” (domains A1, A2, A3,..., A240) of the small frame A, The code amount is acquired by the code
すなわち、符号化部16で符号化されたドメインA1の符号化データENC_A1は、図9に示すように、符号化データ格納領域22のメモリ領域ARA_N1の先頭から記憶される。ドメインA1の符号化が終了すると、ドメインA1の符号量AMT_A1が符号量記憶部17で取得される。この符号量AMT_A1は、図10に示すように、処理ライン「1」の符号量SUM1(SUM1=AMT_A1)として、符号量メモリ31の領域ARA_M1に記憶される。
That is, the encoded data ENC_A1 of the domain A1 encoded by the
次に、ドメインA2の符号化データENC_A2は、図9に示すように、符号化データ格納領域22のメモリ領域ARA_N2の先頭から記憶される。ドメインA2の符号化が終了すると、ドメインA2の符号量AMT_A2が符号量記憶部17で取得される。この符号量AMT_A2は、図10に示すように、処理ライン「2」の符号量SUM2(SUM2=AMT_A2)として、符号量メモリ31の領域ARA_M2に記憶される。
Next, the encoded data ENC_A2 of the domain A2 is stored from the beginning of the memory area ARA_N2 of the encoded
以下、小フレームAの各ドメインA1〜A240の符号化データENC_A1〜ENC_A240は、図9に示すように、符号化データ格納領域22のメモリ領域ARA_N1〜ARA_N240の先頭からそれぞれ記憶される。小フレームAの各ドメインA1〜A240の符号化が終了すると、そのドメインの符号量AMT_A1〜AMT_A240が符号量記憶部17で取得され、この符号量AMT_A1〜AMT_A240が各処理ラインの符号量として、図10に示すように、符号量メモリ31の領域ARA_M1〜ARA_M240にそれぞれ記憶される。
Hereinafter, the encoded data ENC_A1 to ENC_A240 of the domains A1 to A240 of the small frame A are respectively stored from the top of the memory areas ARA_N1 to ARA_N240 of the encoded
小フレームAの符号化が終了すると、次に、小フレームBの処理ライン「1」(ドメインB1)の符号化処理が行われ、以下、小フレームBの処理ライン「240」(ドメインB240)まで、順に、符号化処理が行われる。小フレームBの画像は左端を含んでいないので、各ドメインの符号化データは、各メモリ領域ARA_N1〜ARA_N240において、直前に符号量を格納した小フレームの同一処理ラインに対応する符号化データの直後から、符号化データが格納される。このときのアドレスは、アドレス記憶部12に記憶されているメモリ領域ARA_N1〜ARA_N240の先頭アドレスADDR1〜ADDR240に、符号量記憶部17の符号量メモリ31の各処理ライン毎の符号量SUM1〜SUM240を加算することにより求めることができる。
When the encoding of the small frame A is completed, the encoding process of the processing line “1” (domain B1) of the small frame B is performed, and then the processing line “240” (domain B240) of the small frame B is performed. In order, the encoding process is performed. Since the image of the small frame B does not include the left end, the encoded data of each domain is immediately after the encoded data corresponding to the same processing line of the small frame storing the code amount immediately before in each memory area ARA_N1 to ARA_N240. From this, the encoded data is stored. At this time, the code amount SUM1 to SUM240 for each processing line of the
このように、小フレームBの各処理ライン「1」、「2」、「3」、…、「240」(ドメインB1、B2、B3、…、B240)で符号化を行っていく際に、その符号量が符号量記憶部17で取得される。小フレームBは画像左端を含まないので、該当ドメインの符号量と、符号量メモリ31に既に格納されている該当処理ラインの符号量とが加算され、加算結果が新たな該当処理ラインの符号量として各処理ライン毎に符号量メモリ31に格納される。
In this way, when encoding is performed on each processing line “1”, “2”, “3”,..., “240” (domains B1, B2, B3,..., B240) of the small frame B, The code amount is acquired by the code
すなわち、符号化部16で符号化されたドメインB1の符号化データENC_B1は、図11に示すように、符号化データ格納領域22のメモリ領域ARA_N1において、符号化データENC_A1に続いて記憶される。ドメインB1の符号化が終了すると、ドメインB1の符号量AMT_B1が符号量記憶部17で取得される。この符号量AMT_B1が処理ライン「1」のそれまでの符号量SUM1に加算され、加算結果が処理ライン「1」の新たな符号量として、図12に示すように、符号量メモリ31の領域ARA_M1に記憶される(SUM1=SUM1+AMT_B1)。なお、領域ARA_M1には、それまで、ドメインA1での符号量AMT_A1が記憶されているので、処理ライン「1」の符号量SUM1は、(SUM1=AMT_A1+AMT_B1)となる。
That is, the encoded data ENC_B1 of the domain B1 encoded by the
符号化部16で符号化されたドメインB2の符号化データENC_B2は、図11に示すように、符号化データ格納領域22のメモリ領域ARA_N2において、符号化データENC_A2に続いて記憶される。ドメインB2の符号化が終了すると、ドメインB2の符号量AMT_B2が符号量記憶部17で取得される。この符号量AMT_B2が処理ライン「2」のそれまでの符号量SUM2に加算され、加算結果が処理ライン「2」の新たな符号量として、図12に示すように、符号量メモリ31の領域ARA_M2に記憶される(SUM2=SUM2+AMT_B2)。なお、領域ARA_M2には、それまで、ドメインA2での符号量AMT_A2が記憶されているので、処理ライン「2」の符号量SUM2は、(SUM2=AMT_A2+AMT_B2)となる。
The encoded data ENC_B2 of the domain B2 encoded by the
以下、小フレームBの各ドメインB1〜B240の符号化データENC_B1〜ENC_B240は、図11に示すように、符号化データ格納領域22のメモリ領域ARA_N1〜ARA_N240に、符号化データENC_A1〜ENC_A240に続いてそれぞれ記憶される。小フレームBの各ドメインB1〜B240の符号化が終了すると、そのドメインの符号量AMT_B1〜AMT_B240が符号量記憶部17で取得され、この符号量AMT_B1〜AMT_B240が各処理ラインの符号量として、図12に示すように、符号量メモリ31の領域ARA_M1〜ARA_M240にそれぞれ記憶される。
Hereinafter, the encoded data ENC_B1 to ENC_B240 of each of the domains B1 to B240 of the small frame B follow the encoded data ENC_A1 to ENC_A240, following the memory areas ARA_N1 to ARA_N240 of the encoded
小フレームBの符号化が終了すると、次に、小フレームCの符号化処理が行われる。小フレームCの各ドメインC1〜C240の符号化データENC_C1〜ENC_C240は、図13に示すように、符号化データ格納領域22のメモリ領域ARA_N1〜ARA_N240に、符号化データENC_B1〜ENC_B240に続いてそれぞれ記憶される。小フレームCの各ドメインC1〜C240の符号化が終了すると、そのドメインの符号量AMT_C1〜AMT_C240が符号量記憶部17で取得され、この符号量AMT_C1〜AMT_C240が各処理ラインの符号量として、図14に示すように、符号量メモリ31の領域ARA_C1〜ARA_C240にそれぞれ記憶される。
When the encoding of the small frame B is completed, the encoding process of the small frame C is performed next. As shown in FIG. 13, the encoded data ENC_C1 to ENC_C240 of the domains C1 to C240 of the small frame C are stored in the memory areas ARA_N1 to ARA_N240 of the encoded
小フレームCの符号化が終了すると、次に、小フレームDの符号化処理が行われる。小フレームDの各ドメインD1〜D240の符号化データENC_D1〜ENC_D240は、図15に示すように、符号化データ格納領域22のメモリ領域ARA_N1〜ARA_N240に、符号化データENC_C1〜ENC_C240に続いて記憶される。小フレームDの各ドメインD1〜D240の符号化が終了すると、そのドメインの符号量AMT_D1〜AMT_D240が符号量記憶部17で取得され、この符号量AMT_D1〜AMT_D240が各処理ラインの符号量として、図16に示すように、符号量メモリ31の領域ARA_C1〜ARA_C240にそれぞれ記憶される。
When the encoding of the small frame C is completed, the encoding process of the small frame D is performed next. The encoded data ENC_D1 to ENC_D240 of the domains D1 to D240 of the small frame D are stored in the memory areas ARA_N1 to ARA_N240 of the encoded
以上のようにして、小フレームAからDまでの符号化処理が完了すると、図15に示すように、大容量メモリ11の符号化データ格納領域22の領域ARA_N1〜ARA_N240には、各処理ライン毎の符号化データENC_A1〜ENC_D1、ENC_A2〜ENC_D2、…、ENC_A240〜ENC_D240がそれぞれ格納される。また、符号量記憶部17には、図16に示すように、各処理ライン毎の符号量SUM1〜SUM240が記憶される。
When the encoding process from the small frames A to D is completed as described above, the areas ARA_N1 to ARA_N240 of the encoded
図1において、上述のようにして大容量メモリ11の符号化データ格納領域22に一旦格納された符号化データは、符号化データ読出部19により、処理ライン毎に読み出される。このとき符号化データ読出部19が大容量メモリ11に対して発行するアドレスは、アドレス記憶部12に記憶された各処理ラインのメモリ領域ARA_N1〜ARA_N240の先頭アドレスと、符号量記憶部17に記憶された各処理ラインの符号量SUM1〜SUM240とから算出される。
In FIG. 1, the encoded data once stored in the encoded
つまり、先ず、図15における大容量メモリ11のメモリ空間における処理ライン「1」のメモリ領域ARA_N1の先頭アドレスADDR1がアドレス記憶部12より参照され、そのアドレスADDR1を用いて、処理ライン「1」の符号化データの符号化データの読み出し開始位置が設定される。そして、図16における符号量記憶部17の領域ARA_M1から処理ライン「1」の符号量SUM1が参照され、アドレスADDR1から、符号量SUM1に相当する符号量に相当するアドレスが算出され、算出されたアドレスの分だけ、データが読み出される。これにより、大容量メモリ11の符号化データ格納領域22のメモリ領域ARA_N1から、処理ライン「1」の符号化データ(ENC_A1、ENC_B1、ENC_C1、ENC_D1)が読み出され、読み出された符号化データが後段に出力される。
That is, first, the start address ADDR1 of the memory area ARA_N1 of the processing line “1” in the memory space of the large capacity memory 11 in FIG. 15 is referred from the
処理ライン「1」の符号化データの読み出しが終了したら、連続的に、処理ライン「2」の符号化データの読み出しが行われ、読み出された符号化データが後段に出力される。処理ライン「2」の符号化データの読み出しは、処理ライン「1」と同様に行われる。 When the reading of the encoded data of the processing line “1” is completed, the encoded data of the processing line “2” is continuously read, and the read encoded data is output to the subsequent stage. Reading of the encoded data of the processing line “2” is performed in the same manner as the processing line “1”.
このようにして、処理ライン「240」まで、大容量メモリ11の符号化データ格納領域22のメモリ領域ARA_N1〜ARA_N240から、符号化データの読み出しと、後段への符号化データの出力とが繰り返し行われる。
In this way, until the processing line “240”, the reading of the encoded data and the output of the encoded data to the subsequent stage are repeatedly performed from the memory areas ARA_N1 to ARA_N240 of the encoded
なお、本実施の形態では符号化データ読出部19において、先頭の処理ラインから符号化データを読み出したが、これに限らず、任意の処理ラインからデータを読み出すことも可能である。
In the present embodiment, the encoded
以上のようにして、図17に示すように、符号化データ読出部19からは、各処理ライン「1」、「2」、「3」、…の符号化データが連続して出力される。符号化データ読出部19から出力される符号化データは、一般的なJPEG符号化処理により生成された符号化データの順序と差異がない。そのため、符号化データの復号にあたって特殊な復号化方法は必要なく、一般的なJPEG復号化方法で符号化データを復号することができる。
As described above, as shown in FIG. 17, the encoded
なお、復号する符号化データの転送を本発明の画像処理装置において実行する場合においては、必ずしも図17のようにデータを隙間なく転送する必要はない。この場合、転送された符号化データを復号するために再度転送する際、各処理ラインの符号量を参照して、復号化装置にデータを隙間なく転送すれば良い。そのため、この場合は各処理ラインの符号量は符号化データを復号するまで保持しておくか、符号化データと共に符号量を転送しておく必要がある。 Note that when the encoded data to be decoded is transferred in the image processing apparatus of the present invention, it is not always necessary to transfer the data without gaps as shown in FIG. In this case, when the transferred encoded data is transferred again for decoding, the code amount of each processing line is referred to and the data may be transferred to the decoding device without any gap. Therefore, in this case, it is necessary to hold the code amount of each processing line until the encoded data is decoded or to transfer the code amount together with the encoded data.
また、符号化データ読出部19の後段に備えられる装置としては、例えば、外部記憶装置や通信装置が考えられるが、これに限られるものではない。また、これらの装置は符号化データ読出部19を排他的に使用するように備えても良いし、複数の符号化データ読出部19を備えることにより並列に備えても構わない。
Further, as a device provided in the subsequent stage of the encoded
なお、上述の実施形態では、符号化方式としてJPEGを用いたが、本発明はJPEG方式に限定されず、他の符号化方式の場合でも同様に適用できる。また、上述の例では、画素数を(2564×1924)画素としているが、本発明は、どのような画素数の場合でも、適用できる。 In the above-described embodiment, JPEG is used as the encoding method. However, the present invention is not limited to the JPEG method, and can be similarly applied to other encoding methods. In the above example, the number of pixels is (2564 × 1924), but the present invention can be applied to any number of pixels.
本発明は、上述した実施形態に限定されるものではなく、この発明の要旨を逸脱しない範囲内で様々な変形や応用が可能である。 The present invention is not limited to the above-described embodiments, and various modifications and applications can be made without departing from the gist of the present invention.
例えば、上述の実施の形態では、図6に示したように、符号量記憶部17に1フレームの処理ライン毎の符号量を記憶させるようにしているが、図18に示すように、ドメイン毎の符号量を記憶させるようにしても良い。すなわち、符号量記憶部17において、1フレーム分の符号量をドメイン毎に記憶する符号量メモリを備え、各ドメインの符号量を符号量メモリの対応する領域に格納するように構成する。この場合、大容量メモリ11、符号化データ書込部18及び符号化データ読出部19を、以下のように変形する。
For example, in the above-described embodiment, as shown in FIG. 6, the code
大容量メモリ11では、少なくとも1フレーム分の符号化データ格納領域を、1フレームを構成するドメイン数に分割する。 In the large-capacity memory 11, the encoded data storage area for at least one frame is divided into the number of domains constituting one frame.
符号化データ書込部18では、各ドメインの符号化データを、大容量メモリ11における対応するメモリ領域毎に格納する。このとき、符号化データ書込部18が大容量メモリ11に対して発行するアドレスは、アドレス記憶部12に記憶された各ドメインのメモリ領域の先頭アドレスと、符号量記憶部17に記憶された各ブロックの符号量とから算出する。
The encoded
例えば、前述の実施の形態のように、1フレームを4つの小フレームに分割し、処理ラインの単位を8ラインとした場合、符号量記憶部17においては、図18のように各ドメイン毎に符号量を格納し、また、符号化データ書込部18は、図19に示すように、大容量メモリ11の符号化データ格納領域22に各ドメイン毎に符号化データを格納する。
For example, as in the above-described embodiment, when one frame is divided into four small frames and the unit of the processing line is 8 lines, the code
符号化データ読出部19では、大容量メモリ11に格納された符号化データをドメイン毎に連続的に読み出し、各ドメインの有効な符号化データのみを後段に出力する。このとき、符号化データ読出部19が大容量メモリ11に対して発行するアドレスは、アドレス記憶部12に記憶された各ドメインのメモリ領域の先頭アドレスと、符号量記憶部17に記憶された各ドメインの符号量とから算出する。なお、符号化データの転送方法は変形前の転送方法と同様である。
The encoded
このような変形例では、例えば、画像1フレーム分の符号化データを復号せずに、画像の一部分を抽出して符号化データを保存することと、画像の一部分をのみを高速に表示することが可能になる。 In such a modification, for example, a part of the image is extracted and stored without decoding the encoded data for one frame of the image, and only a part of the image is displayed at high speed. Is possible.
以上に説明したように、本発明の実施の形態によれば、1フレームの画像データを水平方向にM個の小フレームが並んだ画像データとみなし、小フレーム毎に画像処理を実行するようにしている。これにより、画像処理装置のLSI内のメモリの使用量を抑えることでき、画像処理装置のハードウェア規模や開発コストを削減することができる。このことについて詳述する。 As described above, according to the embodiment of the present invention, one frame of image data is regarded as image data in which M small frames are arranged in the horizontal direction, and image processing is executed for each small frame. ing. As a result, the amount of memory used in the LSI of the image processing apparatus can be suppressed, and the hardware scale and development cost of the image processing apparatus can be reduced. This will be described in detail.
前述したように、図1における前処理部14では、補間フィルタを用いて、着目画素に存在しない色を、着目画素近傍の画素により補間している。補間には、例えば(5×5)の補間フィルタが用いられるが、ここでは、説明を簡単にするために、(3×3)の補間フィルタを用いて説明する。
As described above, the preprocessing
例えば、図20において、画素P5が着目画素であるとすると、着目画素P5の画像データは、Bの色情報のみを持っており、Rの色情報やGの色情報は持っていない。このため、着目画素P5の周辺の画素を用いて、Rの色情報とGの色情報を補間により形成する。 For example, in FIG. 20, if the pixel P5 is the target pixel, the image data of the target pixel P5 has only the B color information, and does not have the R color information or the G color information. For this reason, R color information and G color information are formed by interpolation using pixels around the pixel of interest P5.
すなわち、着目画素P5のRの色情報は、着目画素P5の周辺の画素Rの画素P1、P3、P7、P9により、
H1×P1+H2×P3+H3×P7+H4×P9
なるフィルタ演算で求められる。また、着目画素P5のGの色情報は、着目画素P5の周辺の画素Gの画素P2、P4、P6、P8により、
H1×P2+H2×P4+H3×P6+H4×P8
なるフィルタ演算で求められる。但しH1〜H4はフィルタ係数である。
That is, the R color information of the target pixel P5 is obtained by the pixels P1, P3, P7, and P9 of the pixel R around the target pixel P5.
H1 × P1 + H2 × P3 + H3 × P7 + H4 × P9
It is calculated | required by the filter calculation. The G color information of the target pixel P5 is obtained by the pixels P2, P4, P6, and P8 of the pixels G around the target pixel P5.
H1 × P2 + H2 × P4 + H3 × P6 + H4 × P8
It is calculated | required by the filter calculation. However, H1-H4 are filter coefficients.
上述のフィルタ演算を行う補間フィルタは、一般的には、図21に示すように、各タップの出力を得るための1サンプル遅延回路51a〜51f及び1ライン遅延回路52a及び52bと、フィルタ係数を乗じるための乗算器53a〜53iと、加算器54とから構成できる。なお、図21において、不要なタップの出力は、乗算器53a〜53iに係数「0」を与えれば良い。
As shown in FIG. 21, the interpolation filter that performs the above-described filter calculation generally has 1-sample delay circuits 51a to 51f and 1-
ここで、1ライン遅延回路52a及び52bは、ラインメモリから構成される。従来では、ラスタ走査に従って画像データを処理していたため、画素数が(2564×1924)の場合、1ライン遅延回路52a及び52bを構成するラインメモリとして、図22(A)に示すように、2564画素分の容量が必要になる。これに対して、本発明の実施形態では、1フレームの画像データを水平方向に例えば4個の小フレームが並んだ画像データとみなし、小フレーム毎に画像データを処理している。このため、1ライン遅延回路52a及び52bを構成するラインメモリとして、図22(B)に示すように、640画素分の容量があれば良い。したがって、前処理部14の色補間処理におけるメモリの容量は、従来に比べて、約1/4に削減することが可能になる。
Here, the one-
また、図1におけるブロック変換部15では、ラスタ−ブロック変換により、(8×8)画素のブロックデータを形成しているが、ここでは、説明を簡単とするために、(4×4)のブロックを形成する場合について説明する。
Further, in the
ラスタ走査の順の画像データから、(4×4)のブロックデータへの変換は、図23に示すように、4個のラインメモリ61a〜61dにより構成できる。
The conversion from image data in the order of raster scanning into (4 × 4) block data can be configured by four
ここで、従来では、ラスタ走査に従って画像データを処理していたため、画素数が(2564×1924)の場合、ラインメモリ61a〜61dとして、図22(A)に示すように、2564画素分の容量が必要になる。これに対して、本発明の実施形態では、1フレームの画像データを水平方向に例えば4個の小フレームが並んだ画像データとみなし、小フレーム毎に画像データを処理している。このため、ラインメモリ61a〜61dとして、図22(B)に示すように、640画素分の容量があれば良い。したがって、ブロック変換部15におけるメモリの容量は、従来に比べて、約1/4に削減することが可能になる。
Here, conventionally, since image data is processed according to raster scanning, when the number of pixels is (2564 × 1924), the
また、本発明の実施形態では、画像の画素数が増大しても、小フレームの数を調整することにより、画像処理装置内部のメモリ構成に大きな影響を与えることなく対応することができる。したがって、画像の画素数の増大に対して柔軟に対応可能な画像処理装置を提供することができる。 Further, in the embodiment of the present invention, even if the number of pixels of an image increases, it is possible to cope with the problem by adjusting the number of small frames without greatly affecting the memory configuration inside the image processing apparatus. Therefore, it is possible to provide an image processing apparatus that can flexibly cope with an increase in the number of pixels of an image.
さらに、本実施の形態を変形させ、1フレーム分の符号量を小フレーム内の処理ライン毎に記憶する符号量メモリを備えることにより、画像1フレーム分の符号化データを復号せずに、画像の一部分を抽出して符号化データを保存することと、画像の一部分をのみを高速に表示することが可能になる。 Further, the present embodiment is modified to include a code amount memory for storing the code amount for one frame for each processing line in the small frame, so that the encoded data for one frame of the image is not decoded. It is possible to extract a part of the image and save the encoded data, and to display only a part of the image at high speed.
本発明は、ディジタルスチルカメラ等、ラスタ単位の画像データをブロック単位の画像データに変換して処理する、又は、ブロック単位の画像データをラスタ単位の画像データに変換して処理する画像処理装置に用いることができる。 The present invention relates to an image processing apparatus such as a digital still camera that converts raster unit image data to block unit image data or processes block unit image data to raster unit image data. Can be used.
1 画像処理装置
10 バス
11 大容量メモリ
12 アドレス記憶部
13 データ読出部
14 前処理部
15 ブロック変換部
16 符号化部
17 符号量記憶部
18 符号化データ書込部
19 符号化データ読出部
DESCRIPTION OF
Claims (3)
前記メモリに格納された1フレーム分の画像データを水平方向にM個(Mは正の整数)の小フレームが並んだ画像データとみなし、前記小フレームをそれぞれラスタ走査順に読み出すデータ読出部と、
前記データ読出部により読み出された画像データを、所定のライン数を処理ラインとして符号化する符号化部と、
前記符号化部から出力される符号化データの符号量を順次格納する符号量記憶部と、
前記符号量記憶部に記憶された各小フレームの対応する処理ラインに係る符号量に基づき、前記メモリに前記符号化データを格納するためのアドレスを算定し、前記メモリのその算定されたアドレスに前記符号化データを格納する符号化データ書込部と、
前記符号量記憶部に記憶された各小フレームの対応する処理ラインに係る符号量に基づき、前記メモリに格納された符号化データを読み出すためのアドレスを算定し、前記メモリのその算定されたアドレスから符号化データを読み出す符号化データ読出部と
を備えることを特徴とする画像処理装置。 A memory for storing image data;
A data reading unit that regards image data for one frame stored in the memory as image data in which M small frames (M is a positive integer) are arranged in a horizontal direction, and reads the small frames in raster scanning order;
An encoding unit that encodes the image data read by the data reading unit using a predetermined number of lines as processing lines;
A code amount storage unit for sequentially storing code amounts of encoded data output from the encoding unit;
Based on the code amount relating to the processing line corresponding to each small frame stored in the code amount storage unit, the address for storing the encoded data in the memory is calculated, and the calculated address in the memory is calculated. An encoded data writing unit for storing the encoded data;
Based on the code amount related to the processing line corresponding to each small frame stored in the code amount storage unit, the address for reading the encoded data stored in the memory is calculated, and the calculated address of the memory An image processing apparatus comprising: an encoded data reading unit that reads encoded data from the image data.
The image processing apparatus according to claim 1, wherein the code amount storage unit stores the code amount for each processing line of each small frame.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005021104A JP2006211323A (en) | 2005-01-28 | 2005-01-28 | Image processor |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2005021104A JP2006211323A (en) | 2005-01-28 | 2005-01-28 | Image processor |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2006211323A true JP2006211323A (en) | 2006-08-10 |
Family
ID=36967683
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2005021104A Withdrawn JP2006211323A (en) | 2005-01-28 | 2005-01-28 | Image processor |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2006211323A (en) |
-
2005
- 2005-01-28 JP JP2005021104A patent/JP2006211323A/en not_active Withdrawn
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4151684B2 (en) | Encoding apparatus, encoding method, encoding program, and imaging apparatus | |
WO2009087783A1 (en) | Data generator for coding, method of generating data for coding, decoder and decoding method | |
US6563946B2 (en) | Image processing apparatus and method | |
JP2010098352A (en) | Image information encoder | |
CN113068026B (en) | Coding prediction method, device and computer storage medium | |
US10798419B2 (en) | Embedded codec circuitry for sub-block based encoding of quantized prediction residual levels | |
JP2007258882A (en) | Image decoder | |
JPH1175183A (en) | Image signal processing method and device and storage medium | |
US7787700B2 (en) | Signal processing method, signal processing apparatus, computer-readable medium and a data recording medium | |
JP4092830B2 (en) | Image data compression method | |
WO2010021153A1 (en) | Motion detection device | |
JP2006211323A (en) | Image processor | |
JP2776284B2 (en) | Image coding device | |
US6681051B1 (en) | Arrangement for transforming picture data | |
JP4988623B2 (en) | Image encoding apparatus and image decoding apparatus | |
JP3709106B2 (en) | Image compression and decompression device | |
JP2004165733A (en) | Image converter, image conversion method, and recording medium | |
JP4720494B2 (en) | Imaging apparatus, imaging method and program, and recording medium | |
JP5175796B2 (en) | Encoding / preprocessing device, decoding / postprocessing device, encoding device, decoding device, and program | |
JP3193285B2 (en) | Coding noise reduction filter circuit | |
JP2005348176A (en) | Image processor | |
JP3781012B2 (en) | Image data compression method, image data expansion method, and image data expansion circuit | |
JP2006211197A (en) | Image processing method | |
JPH1117955A (en) | Image processing unit | |
JP2000175061A (en) | Color transformation processing method and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A300 | Application deemed to be withdrawn because no request for examination was validly filed |
Free format text: JAPANESE INTERMEDIATE CODE: A300 Effective date: 20080401 |