JP2002135595A - Image decompression apparatus - Google Patents

Image decompression apparatus

Info

Publication number
JP2002135595A
JP2002135595A JP2000318708A JP2000318708A JP2002135595A JP 2002135595 A JP2002135595 A JP 2002135595A JP 2000318708 A JP2000318708 A JP 2000318708A JP 2000318708 A JP2000318708 A JP 2000318708A JP 2002135595 A JP2002135595 A JP 2002135595A
Authority
JP
Japan
Prior art keywords
data
image
block
output
decoding
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
Application number
JP2000318708A
Other languages
Japanese (ja)
Inventor
Koji Inagaki
孝次 稲垣
Takahiro Okamoto
隆浩 岡本
Miho Igarashi
美帆 五十嵐
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.)
Dai Nippon Printing Co Ltd
Original Assignee
Dai Nippon Printing Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Dai Nippon Printing Co Ltd filed Critical Dai Nippon Printing Co Ltd
Priority to JP2000318708A priority Critical patent/JP2002135595A/en
Publication of JP2002135595A publication Critical patent/JP2002135595A/en
Withdrawn legal-status Critical Current

Links

Landscapes

  • Bus Control (AREA)
  • Studio Circuits (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression Of Band Width Or Redundancy In Fax (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

PROBLEM TO BE SOLVED: To provide an image decompression apparatus (LSI) that can use a high-speed transfer means such as DMA, simplify processing after acquisition of data and uses even a CPU at a low speed to attain high-speed processing. SOLUTION: The image decompression apparatus that decodes an image compression data file by using block coding, is provided with a decoding means that decodes the block-coded file to generate block decoding data, a storage means that stores a plurality of block decoding data, an image size arithmetic means that calculates an image size in the image decoding data file as an aggregate of the block decoding data, a rearrangement means that rearranges the block decoding data outputted from the decoding means in a scanning line detection of the image decoding data in the decoding data storage means, and a read means that continuously reads the image decoding data stored in the decoding data storage means in the scanning line direction.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明はブロック符号を用い
た画像圧縮データ、特にJPEG画像圧縮データの伸張
を行なうLSIの技術分野に属する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention belongs to the technical field of LSI for decompressing compressed image data using block codes, particularly JPEG compressed image data.

【0002】[0002]

【従来技術】JPEG画像ファイルは、縦8画素×横8
画素のブロック単位で圧縮処理がされており、出力画像
も8画素×8画素のブロック単位で出力されている。
2. Description of the Related Art A JPEG image file has a length of 8 pixels × width of 8 pixels.
The compression processing is performed in units of blocks of pixels, and the output image is also output in units of blocks of 8 pixels × 8 pixels.

【0003】[0003]

【発明が解決しようとする課題】画像伸張LSIからの
出力が縦8画素×横8画素等のブロック単位で出力され
ると、それを受け取るCPUがDMAなどの高速転送手
段を使用できなくなる。また、データ取得後の処理が複
雑になり低速のCPUを使用している組込み機器などで
は、高速処理が困難となる。
If the output from the image decompression LSI is output in blocks of 8 pixels by 8 pixels, the CPU receiving the data cannot use high-speed transfer means such as DMA. Further, processing after data acquisition becomes complicated, and high-speed processing becomes difficult in an embedded device using a low-speed CPU.

【0004】本発明はこのような問題を解決するために
なされたものであり、その目的は、DMAなどの高速転
送手段を使用でき、データ取得後の処理が簡潔で低速の
CPUでも高速処理が可能となる画像伸張装置(LS
I)を提供することにある。
The present invention has been made in order to solve such a problem, and an object of the present invention is to use a high-speed transfer means such as a DMA, which is simple in processing after data acquisition and that high-speed processing can be performed by a low-speed CPU. Image expansion device (LS
I).

【0005】[0005]

【課題を解決するための手段】上記の課題は下記の本発
明によって解決される。すなわち、本発明の請求項1に
係る画像伸張装置は、ブロック符号を用いた画像圧縮デ
ータファイルの復号化を行なう画像伸張装置であって、
ブロック符号化されたファイルを復号しブロック復号デ
ータを生成する復号手段と、前記ブロック復号データの
複数を記憶する記憶手段と、前記ブロック復号データの
集合体としての画像復号データファイルにおける画像サ
イズを演算する画像サイズ演算手段と、前記復号手段か
ら出力されるブロック復号データを前記復号データ記憶
手段において前記画像復号データファイルの走査線方向
に並べ替る並替手段と、前記復号データ記憶手段に記憶
されている画像復号データを走査線方向に連続的に読み
出す読出手段とを有するようにしたものである。本発明
によれば、DMAなどの高速転送手段を使用でき、デー
タ取得後の処理が簡潔で低速のCPUでも高速処理が可
能となる画像伸張装置(LSI)が提供される。
The above object is achieved by the present invention described below. That is, an image decompression device according to claim 1 of the present invention is an image decompression device that decodes an image compression data file using a block code,
Decoding means for decoding a block-encoded file to generate block decoded data, storage means for storing a plurality of the block decoded data, and calculating an image size in an image decoded data file as an aggregate of the block decoded data Image size calculating means for performing the decoding, block decoding data output from the decoding means in the decoded data storage means in the scanning line direction of the image decoded data file, and rearranging means for rearranging the block decoded data; Reading means for continuously reading the decoded image data in the scanning line direction. According to the present invention, there is provided an image decompression device (LSI) that can use a high-speed transfer unit such as a DMA, performs simple processing after data acquisition, and enables high-speed processing even with a low-speed CPU.

【0006】また本発明の請求項2に係る画像伸張装置
は、請求項1に係る画像伸張装置において、前記ブロッ
ク符号化されたファイルはJPEG方式のファイルであ
って、前記復号手段は縦8画素×横8画素のブロック復
号データを生成し、前記記憶手段は走査線方向に少なく
とも8ラインのデータを記憶するようにしたものであ
る。本発明によれば、JPEGファイルにおいて、画像
伸張、高速転送、高速処理が可能となる。
According to a second aspect of the present invention, there is provided the image decompression apparatus according to the first aspect, wherein the block-encoded file is a JPEG file, and the decoding means comprises eight vertical pixels. × The block decoding data of 8 pixels in the horizontal direction is generated, and the storage means stores at least 8 lines of data in the scanning line direction. According to the present invention, image expansion, high-speed transfer, and high-speed processing can be performed on a JPEG file.

【0007】また本発明の請求項3に係る画像伸張装置
は、請求項1または2に係る画像伸張装置において、出
力画像データの原画像に対する倍率を指定する倍率指定
手段と、前記復号手段から出力されるブロック復号デー
タを指定された倍率に、既に出力されたブロック復号デ
ータにおける必要とされるデータを取得しながら、画像
サイズを変更する画像サイズ変更手段と、前記サイズ変
更した画像データを前記記憶手段において走査線方向に
並べ替える並替手段とを有するようにしたものである。
本発明によれば、画像伸張、画像変倍、高速転送、高速
処理が可能となる。
According to a third aspect of the present invention, there is provided the image decompression apparatus according to the first or second aspect, wherein a magnification designating means for designating a magnification of the output image data with respect to the original image, and an output from the decoding means. Image-size changing means for changing the image size while obtaining the required data in the already-decoded block decoded data at a specified magnification of the block-decoded data to be output, and storing the resized image data in the block-decoded data. And means for rearranging in the scanning line direction.
According to the present invention, image expansion, image scaling, high-speed transfer, and high-speed processing can be performed.

【0008】また本発明の請求項4に係る画像伸張装置
は、請求項1〜3のいずれかに係る画像伸張装置におい
て、出力画像データの原画像に対する倍率Kを指定する
手段と、指定された倍率Kと出力画素位置Mxより、M
xをKで割った値Sxを求める手段と、Sxの整数部S
aと、現在まで処理済みのブロック数Bxと、ブロッ
クサイズ(Lx画素×Ly画素)より、SxaがBx×
Lx<=Sxa<(Bx+1)×Lxを判定する手段
と、前記復号手段から出力されるブロック復号データの
Sxa−(Bx×Lx)番目のデータDSBとSxa−(B
x×Lx)+1番目のデータDSB+1をを取得する手段
と、Sxの小数部Sxbより、DSB×(1−Sxb)+D
SB+1Sxbを算出し出力画像データとする手段と、前記
操作をブロック内のライン数Ly回繰り返し行なう手段
と、前記復号手段から出力されるブロック画像データの
走査線方向におけるラインデータの各最終データを保存
し、次のブロック出力時においてSxa=(Bx+1)
×Lxとなった場合に書くラインのDSBデータとして使
用する手段と、前記走査線方向だけサイズ変更された画
像データを前記記憶手段に出力画像の走査線方向にデー
タを並べ替える手段と、前記記憶手段に保存されたデー
タから、Y方向のラインデータを取得する手段と、現在
処理中のライン位置MyとMyをKで割った値Syを求
める手段と、Syの整数部Syaと、現在まで処理済み
のY方向ブロック数Byと、ブロックサイズ(Lx画素
×Ly画素)より、SyaがBy×Ly<=Sya<(B
y+1)×Lyを判断する手段と、取得したY方向デー
タのSya−(By×Ly)番目のデータDSBとSya
(By×Ly)+1番目のデータDSB+1を取得する手段
と、Syの小数部Sybより、DS×(1−Syb)+D
S+1×Sybを算出し出力画像データとする手段と、前記
操作を前記記憶手段に記憶されているすべてのラインデ
ータについて繰り返し行なう手段と、各Y方向ラインデ
ータの最終データを保存する手段と、次回のY方向サイ
ズ変更処理のとき、Sya=(By+1)×Lyとなっ
た場合に各ラインのDSBデータとして使用する手段と、
サイズ変更した画像データを前記記憶手段に出力画像の
走査線方向に並ぶように再度書き戻す手段とを有するよ
うにしたものである。本発明によれば、DMAなどの高
速転送手段を使用でき、データ取得後の処理が簡潔で低
速のCPUでも高速処理が可能となる画像伸張装置(L
SI)が提供される。
According to a fourth aspect of the present invention, in the image decompression apparatus according to any one of the first to third aspects, means for designating a magnification K of the output image data with respect to the original image is provided. From the magnification K and the output pixel position Mx, M
means for obtaining a value Sx obtained by dividing x by K, and an integer part S of Sx
and x a, and the number of blocks Bx processed to date than the block size (Lx pixels × Ly pixels), Sx a is Bx ×
Means for determining Lx <= Sx a <(Bx + 1) × Lx, and Sx a − (Bx × Lx) -th data D SB and Sx a − (B
x × Lx) means for obtaining the + 1st data D SB + 1, from the fractional part Sx b of Sx, D SB × (1- Sx b) + D
Means to calculate the SB + 1 Sx b output image data, and means for performing the operation is repeated the number of lines Ly times in the block, each of the line data in the scanning line direction of the block image data output from said decoding means The final data is saved, and Sx a = (Bx + 1) at the time of the next block output
× Lx means for using as the DSB data of the line to be written, and means for rearranging the image data whose size has been changed only in the scanning line direction to the storage means in the scanning line direction of the output image; from the storage unit stored in the data, and means for obtaining the line data in the Y direction, means for determining a value Sy divided by a line position My and My currently treated with K, an integer part Sy a of Sy, the current and treated Y-direction block count By far, than the block size (Lx pixels × Ly pixels), Sy a is By × Ly <= Sy a < (B
y + 1) means for determining × Ly, the obtained Y-direction data Sy a - (By × Ly) th data D SB and Sy a -
(By × Ly) and + 1st means for acquiring data D SB + 1, from the fractional part Sy b of Sy, D S × (1- Sy b) + D
Means for calculating S + 1 × Sy b as output image data; means for repeating the operation for all line data stored in the storage means; means for storing final data of each Y-direction line data If, when the next Y-resize processing, and means for use as D SB data of each line when a Sy a = (By + 1) × Ly,
Means for rewriting the resized image data in the storage means so as to be arranged in the scanning line direction of the output image. According to the present invention, it is possible to use a high-speed transfer means such as a DMA or the like.
SI) is provided.

【0009】また本発明の請求項5に係る画像伸張装置
は、請求項4に係る画像伸張装置において、倍率として
1/Kを設定することにより、SをM×(1/K)によ
り得るようにしたものである。本発明によればM×(1
/K)の掛け算によりSが求められるから簡潔で精度が
よい。
According to a fifth aspect of the present invention, in the image decompression apparatus according to the fourth aspect, by setting 1 / K as a magnification, S is obtained by M × (1 / K). It was made. According to the present invention, M × (1
/ K) is simple and accurate because S is obtained by multiplication.

【0010】また本発明の請求項6に係る画像伸張装置
は、請求項4に係る画像伸張装置において、Y方向ライ
ンデータのSya−(By×Ly)を計算した後、必要
なデータDSBとデータDSB+1を記憶装置から取得するよ
うにしたものである。本発明によれば演算過程が簡素化
される。
Further image decompression apparatus according to claim 6 of the present invention, in the image decompression apparatus according to claim 4, Sy a Y-direction line data - after calculating (By × Ly), necessary data D SB And the data DSB + 1 are obtained from the storage device. According to the present invention, the calculation process is simplified.

【0011】また本発明の請求項7に係る画像伸張装置
は、請求項4に係る画像伸張装置において、画像変倍手
法がバイリニア方式であるようにしたものである。本発
明によれば、バイリニアによる画像変倍が行なわれる。
According to a seventh aspect of the present invention, in the image decompression apparatus according to the fourth aspect, the image scaling method is a bilinear method. According to the present invention, image scaling by bilinear is performed.

【0012】[0012]

【発明の実施の形態】次に、本発明について実施の形態
を説明する。本発明における画像伸張装置の構成の一例
を図1に示し、それを参照しながら説明する。図1に示
す一例は、データ並べ替えを行なうとき、画像サイズの
変更を行なわない構成となっている。データ並べ替えを
行なうときに画像サイズの変更も行なう構成の一例は図
2に示し、それについては後述する。図1において、1
01は画像伸張装置、102はCPU(central proces
sor unit)、111はJPEG(joint photographic e
xpert group)デコーダ、112はラインデータメモ
リ、113はステータレジスタ、114はリードライト
コントローラ、115はDMA(direct memory access)
コントローラである。
Next, an embodiment of the present invention will be described. An example of the configuration of the image decompression device according to the present invention is shown in FIG. 1 and will be described with reference to FIG. The example shown in FIG. 1 has a configuration in which the image size is not changed when the data is rearranged. FIG. 2 shows an example of a configuration in which the image size is changed when the data is rearranged, which will be described later. In FIG. 1, 1
01 is an image decompression device, 102 is a CPU (central process)
sor unit), 111 is JPEG (joint photographic e)
xpert group) decoder, 112 is a line data memory, 113 is a status register, 114 is a read / write controller, 115 is a DMA (direct memory access)
It is a controller.

【0013】画像伸張装置101は、圧縮された画像フ
ァイルの伸張(デコード:復号)を行なう装置である。
図1における画像伸張装置101の部分が本発明の部分
である。この画像伸張装置101は、たとえばLSI
(large scale integrated circuit)として実現され
る。
The image decompression device 101 is a device that decompresses (decodes) a compressed image file.
The part of the image decompression device 101 in FIG. 1 is the part of the present invention. This image decompression device 101 is, for example, an LSI
(Large scale integrated circuit).

【0014】CPU12は、その画像ファイルを使用す
るシステムのCPUである。図1にはCPU12を介し
てそのシステムのメモリ(図示せず)に復号が行なわれ
た画像データの書き込みが行なわれる構成として一例を
示してある。CPUを介せず、直接メモリに書き込みが
行なわれる構成とすることもできる。
The CPU 12 is a CPU of a system that uses the image file. FIG. 1 shows an example of a configuration in which decoded image data is written to a memory (not shown) of the system via the CPU 12. A configuration in which writing is performed directly on the memory without using the CPU may be adopted.

【0015】JPEGデコーダ111はJPEG圧縮さ
れた画像ファイルを順次入力して縦8画素×横8画素の
ブロック復号データ(画像データ)を出力する。図1に
おいては、JPEGデコーダ111におけるデータ入力
部分は図示されていない。
The JPEG decoder 111 sequentially inputs JPEG-compressed image files and outputs block-decoded data (image data) of 8 pixels × 8 pixels. In FIG. 1, the data input part in the JPEG decoder 111 is not shown.

【0016】ラインデータメモリ112はそのブロック
復号データを記憶する。このブロック復号データを記憶
するとき、ラインデータメモリ112はリード・ライト
コントローラの制御下において動作する。そして、原画
像のラインデータが得られるような所定のデータ配列で
記憶する。
The line data memory 112 stores the block decoded data. When storing the block decoded data, the line data memory 112 operates under the control of the read / write controller. Then, the image data is stored in a predetermined data array such that line data of the original image can be obtained.

【0017】ステータスレジスタ113は、画像サイ
ズ、サンプリングファクタ等のJPEGファイルの情報
(ステータス)を一時記憶する。このステータスはJP
EGデコーダから直接読み込みを行なう構成とすること
ができる。また、CPU102等から書き込みを行なう
構成とすることができる。
The status register 113 temporarily stores information (status) of a JPEG file such as an image size and a sampling factor. This status is JP
It is possible to adopt a configuration in which reading is performed directly from the EG decoder. Further, the writing can be performed from the CPU 102 or the like.

【0018】リード・ライトコントローラ114は、J
PEGデコーダ111におけるブロック復号データの読
み出し制御と、ラインデータメモリ112への書き込み
制御とを行なう。この制御の様式はステータスレジスタ
113が記憶するステータスによる。
The read / write controller 114
The read control of the block decoded data in the PEG decoder 111 and the write control to the line data memory 112 are performed. This control mode depends on the status stored in the status register 113.

【0019】DMAコントローラ115は、ラインデー
タメモリ112におけるラインデータの読み出し制御
と、CPU102への書き込み制御とを行なう。すなわ
ち、CPUを介した転送、DMA転送、等のデータ転送
の制御を行なう。データ転送は8ライン分のデータを単
位として行なわれる(JPEGデータのサンプリングフ
ァクターによっては16ラインの場合もある)。ライン
データメモリ112に、8ライン分のデータが書き込ま
れると、DMAコントローラ115によって、連続的か
つ高速のデータ転送が行なわれる。
The DMA controller 115 controls reading of line data in the line data memory 112 and control of writing to the CPU 102. That is, it controls data transfer such as transfer via the CPU, DMA transfer, and the like. Data transfer is performed in units of 8 lines of data (16 lines in some cases depending on the sampling factor of JPEG data). When eight lines of data are written to the line data memory 112, the DMA controller 115 performs continuous and high-speed data transfer.

【0020】以上の構成において、次に、動作の詳細に
ついて説明を行なう。JPEGデコーダ111が出力す
るデータは、前述のように、縦8画素×横8画素のブロ
ック復号データである。そのデータ出力の順序を図3に
説明図として示す。図3に示すように、縦8画素×横8
画素のブロック復号データの1つについて、1行の中で
は左側の画素から右側の画素へと、また上の行から下の
行へと1行づつ走査を行ないデータを出力する。
Next, the operation of the above configuration will be described in detail. The data output from the JPEG decoder 111 is, as described above, block-decoded data of 8 × 8 pixels. The order of the data output is shown in FIG. As shown in FIG. 3, 8 vertical pixels × 8 horizontal pixels
With respect to one of the block decoded data of the pixels, the scanning is performed one row at a time from the left pixel to the right pixel in one row, and from the upper row to the lower row, and data is output.

【0021】そして、その走査を完了すると、次のブロ
ック復号データへと移行して走査を行なう。この走査に
おけるブロック復号データ間の移動は、1行の中では左
側のブロック復号データから右側のブロック復号データ
へと、また上の行から下の行へと1行づつ走査を行ない
データを出力する。このJPEGデコーダ111が出力
するブロック復号データは、リードライトコントローラ
114からのデータ読み出し要求によって1画素のデー
タを1単位として出力が行なわれる。
When the scanning is completed, the process proceeds to the next block decoded data and scanning is performed. The movement between the block decoded data in this scanning is performed by scanning one row at a time from the left block decoded data to the right block decoded data, and from the upper row to the lower row, one row at a time. . The block decoded data output by the JPEG decoder 111 is output in units of one pixel data in response to a data read request from the read / write controller 114.

【0022】リードライトコントローラ114は、JP
EGファイルのステータス情報であるXレジスタから出
力画像のX方向の画素数(または、X方向の縦8画素×
横8画素のブロック数)を読み出し、JPEGデコード
回路から出力されるデータのX方向の画素数を認識す
る。リードライトコントローラ114は、JPEGデコ
ーダ111にデータ読み出し要求を出し、ラインデータ
メモリ112の先頭アドレスを出力する。
The read / write controller 114 has a function of JP
From the X register, which is the status information of the EG file, the number of pixels in the X direction of the output image (or 8 pixels in the vertical direction in the X direction)
The number of pixels in the X direction of the data output from the JPEG decoding circuit is recognized. The read / write controller 114 issues a data read request to the JPEG decoder 111 and outputs the head address of the line data memory 112.

【0023】データは3色分同時に出力される場合と、
各色ごとに出力される場合とがあるが、ここに説明する
一例では、1画素のデータが3色分、3回に分けて連続
で出力されるものとする。また、ラインデータメモリ1
12の先頭アドレスはここでは0とする。なお、3色同
時に出力される場合には、以下に説明する処理におい
て、ラインデータメモリ112のデータを3倍にする
か、3回に分けて各メモリに書き込めばよい。
The data is output simultaneously for three colors,
Although output may be performed for each color, in the example described here, it is assumed that data of one pixel is continuously output in three times for three colors. Also, the line data memory 1
Here, the start address of Twelve is set to 0. In the case where three colors are simultaneously output, in the processing described below, the data in the line data memory 112 may be tripled, or may be written into each memory three times.

【0024】リードライトコントローラ114における
処理の過程をフロー図として図4、図5に示す。図4、
図5に示す一例では、メモリ書き込み時にデータの並べ
替えを行なっているが、DMA読み出し時にデータの並
びを変更しつつ出力するようにしてもよい。また、リー
ドライトコントローラ114のカウンタレジスタ、等の
構成の一例を図6に示す。図4〜図6を参照しながら、
リードライトコントローラ114における処理の過程を
説明する。
FIGS. 4 and 5 show flowcharts of the processing steps in the read / write controller 114. FIG. FIG.
In the example shown in FIG. 5, the data is rearranged at the time of writing to the memory. However, the data may be rearranged and output at the time of DMA reading. FIG. 6 shows an example of a configuration of the read / write controller 114 such as a counter register. Referring to FIG. 4 to FIG.
A process in the read / write controller 114 will be described.

【0025】まず、図4のステップS1(回路初期化)
において、各カウンター等の初期化を行なう。また、各
色(YCbCr,RGB,CYM等JPEGデコーダの
出力形態による)のデータを保存するメモリのバンクを
指定するバンクレジスタ値を設定する。また、出力画像
のX方向のブロックを設定するXレジスタと、出力画像
のY方向のブロックを設定する。その他の初期設定も行
なう。
First, step S1 in FIG. 4 (circuit initialization)
, Initialization of each counter and the like is performed. Also, a bank register value for designating a bank of a memory for storing data of each color (depending on the output form of a JPEG decoder such as YCbCr, RGB, CYM, etc.) is set. Further, an X register for setting an X-direction block of the output image and a Y-direction block of the output image are set. Other initial settings are also performed.

【0026】メモリバンクについては、1つのメモリを
3つのバンクに分ける方法、3つのメモリを各色に分け
る方法、3色連続で保存する方法、3色同時に保存する
方法等がある。いずれの方法とするかは、メモリ構成、
使用条件、等に依存する。ここでは、1つのメモリを3
バンクに分けて各バンクに各色を保存する一例により説
明する。
As for the memory bank, there are a method of dividing one memory into three banks, a method of dividing three memories into respective colors, a method of continuously storing three colors, a method of simultaneously storing three colors, and the like. Which method to use depends on the memory configuration,
It depends on the conditions of use. Here, one memory is 3
An example in which each color is stored in each bank by dividing into banks will be described.

【0027】次に、ステップS2(デコードデータ出力
待ち)において、JPEGデコーダ111からのデータ
出力可能状態になるまで待つ。次に、ステップS3(ラ
インデータメモリ書込みアドレス出力)において、出力
状態になると、ラインデータメモリ112への書き込み
アドレスを出力する。次に、ステップS4(デコードデ
ータ出力要求)において、JPEGデコーダ111への
データ読み出し要求を出力する。
Next, in step S2 (waiting for decoding data output), the process waits until data can be output from the JPEG decoder 111. Next, in step S3 (line data memory write address output), when an output state is set, a write address to the line data memory 112 is output. Next, in step S4 (decode data output request), a data read request to the JPEG decoder 111 is output.

【0028】次に、ステップS5(ラインメモリデータ
書込)において、書込み信号を出力する。そして、読み
出したデータをラインデータメモリ112へ書き込む。
ここで説明する一例では、3色分のデータが順次出力さ
れる。したがって、次に、ステップS6(3色完?)か
らステップS7(バンク切替)に進み、バンクを切り替
えて、2色目、3色目を同様の手順で書き込む。すなわ
ち、ステップS4に戻り以降のステップを繰り返す。ア
ドレスに関しては、バンクを切り替えることで、バンク
内のアドレスは同一画素データでは同一とする。
Next, in step S5 (line memory data writing), a write signal is output. Then, the read data is written to the line data memory 112.
In the example described here, data for three colors is sequentially output. Accordingly, next, the process proceeds from step S6 (complete three colors?) To step S7 (bank switching), switches the bank, and writes the second color and the third color in the same procedure. That is, the process returns to step S4 and repeats the subsequent steps. As for the address, by switching the bank, the address in the bank is the same for the same pixel data.

【0029】3色分のデータをラインデータメモリ11
2へ書き込むと、次に、ステップS6(3色完?)から
ステップS8(次データ出力アドレス作成)に進み、次
データ出力アドレスを計算する。このステップS8の処
理は、書き込みアドレス出力時に行なってもよいが、こ
の一例では、書き込み後に行なっている。このステップ
S8の処理は、図5に詳細が示されている。
The data for three colors is stored in the line data memory 11.
After writing to 2, the process proceeds from step S6 (3 colors completed?) To step S8 (create next data output address) to calculate the next data output address. The process of step S8 may be performed at the time of output of the write address, but in this example, is performed after the write. FIG. 5 shows the details of the processing in step S8.

【0030】スタートアドレスレジスタには、ブロック
の先頭データの書き込みを行なったアドレスが常に保管
されている。1データ(3色分)の書き込みが終了する
と、図5のステップS801において、ドットカウンタ
をカウントアップし、8画素分のデータ書き込みをカウ
ントする。次に、8画素分のデータ書き込み以前におい
ては、ステップS802からステップS803に進み、
アドレスデータは単純にカウントアップされる。一方、
8画素分のデータ書き込みが行なわれると、ステップS
802からステップS804に進み、ラインカウンタを
カウントアップし、ドットカウンタをリセットする。
The start address register always stores the address at which the head data of the block has been written. When the writing of one data (for three colors) is completed, in step S801 in FIG. 5, the dot counter is counted up, and data writing for eight pixels is counted. Next, before writing data for eight pixels, the process proceeds from step S802 to step S803.
The address data is simply counted up. on the other hand,
When data writing for eight pixels is performed, step S
The process advances from step 802 to step S804 to count up the line counter and reset the dot counter.

【0031】次に、8ライン分のデータ書き込み以前に
は、ステップS805からステップS806に進み、現
在のアドレスレジスタ値に((Xレジスタ値)×8−
7)を加算して、次ラインの先頭アドレスを算出し、ア
ドレスレジスタに格納する。一方、8ライン分のデータ
書き込みが行なわれると、ステップS805からステッ
プS807に進み、Xブロックカウンタをカウントアッ
プし、ラインカウンタをリセットする。
Next, before writing data for eight lines, the process proceeds from step S805 to step S806, where the current address register value is ((X register value) × 8−
7) is added to calculate the start address of the next line and store it in the address register. On the other hand, when data for eight lines is written, the process proceeds from step S805 to step S807, where the X block counter is counted up and the line counter is reset.

【0032】次に、Xブロックカウンタが(Xブロック
カウンタ値)がXレジスタ値(ブロック数)となる以前
には、ステップS808からステップS809に進み、
スタートアドレスレジスタ値に8を加算する。一方、処
理ブロック数がXレジスタ値と等しくなると、ステップ
S808からステップS810に進み、アドレスレジス
タ、スタートアドレスレジスタにそれぞれ書き込みを行
い、カウンタを初期化する。
Next, before the X block counter becomes (X block counter value) equal to the X register value (the number of blocks), the process proceeds from step S808 to step S809.
Add 8 to the start address register value. On the other hand, when the number of processing blocks becomes equal to the value of the X register, the process proceeds from step S808 to step S810, where writing is performed to the address register and the start address register, respectively, and the counter is initialized.

【0033】このような操作を繰り返す。すなわちステ
ップS9(データ出力?)からステップS2に戻って以
降のステップを繰り返す。そして、X方向のデータを出
力することが可能となると、図4のステップS9(デー
タ出力?)からステップS10(DMAデータ出力待
ち)に進み、データ出力状態となる。すなわち、DMA
コントローラ115に処理を渡し、出力終了まで待ち状
態となる。この操作をY方向ブロック数に等しい回数行
う。すなわちステップS11からステップS2に戻って
以降のステップを繰り返す。そして、全データの出力が
終了するとステップS11(全データ出力完了?)にお
いて、すべての処理を終了する。
Such an operation is repeated. That is, the process returns from step S9 (data output?) To step S2 and repeats the subsequent steps. Then, when it becomes possible to output data in the X direction, the process proceeds from step S9 (data output?) To step S10 (waiting for DMA data output) in FIG. 4 to enter a data output state. That is, DMA
The process is passed to the controller 115, and the controller 115 waits until the output is completed. This operation is performed a number of times equal to the number of blocks in the Y direction. That is, the process returns from step S11 to step S2, and the subsequent steps are repeated. Then, when the output of all data is completed, in step S11 (complete output of all data?), All processing is ended.

【0034】ラインデータメモリ112は画像全体を保
存できるほど大きければ、全データの並べ替えを終了し
てから全データを転送してもよいが、最小のメモリで受
け側が処理し易いように、ここに示す一例では、8ライ
ン(16ライン)分のメモリで処理を行なっている。さ
らにメモリの容量を確保できない場合には、適当なブロ
ック数で出力を行ってもよい。JPEG以外のブロック
符号化を用いて画像圧縮を行なう場合においても、ブロ
ックサイズ等を、対象とする符号に合わせて構成すれ
ば、同様の処理でデータの並べ替え、出力を行なうこと
ができる。
If the line data memory 112 is large enough to store the entire image, all the data may be transferred after the rearrangement of all the data is completed. In the example shown in (1), processing is performed in a memory for 8 lines (16 lines). If the memory capacity cannot be secured, the output may be performed with an appropriate number of blocks. Even in the case of performing image compression using block encoding other than JPEG, if the block size and the like are configured according to the target code, data can be rearranged and output by the same processing.

【0035】図6に示し上述した、ドットカウンタ、ラ
インカウンタ、Xブロックカウンタは、ブロックのX、
Y画素数がJPEGのように2の累乗である場合は、1
つのカウンタで実現してもよい。ラインデータメモリに
データ書き込みが完了すると、外部データ出力を行なう
ためにDMAコントローラ部に処理が渡される。データ
の読み出しはCPU等の外部装置から特定アドレスを指
定して読み出す方法や、ラインデータメモリのアドレス
を直接アクセスして読み出す方法、等が考えられるが、
ここに示す一例では、一般的なDMAによるシングルア
クセスモードによる読み出しを示している。
The dot counter, line counter, and X block counter shown in FIG.
When the number of Y pixels is a power of 2 like JPEG, 1
It may be realized by one counter. When the data writing to the line data memory is completed, the processing is passed to the DMA controller for performing external data output. Data can be read by a method of specifying a specific address from an external device such as a CPU and reading the data, a method of directly accessing and reading an address of a line data memory, and the like.
In the example shown here, a read in a single access mode by a general DMA is shown.

【0036】次に、DMAコントローラ115について
説明する。DMAコントローラ115における処理過程
を図7にフロー図として示す。ラインデータメモリ11
2に書き込みが終了し、出力が可能な状態になると、ま
ず、図7のステップS101において、DMAコントロ
ーラ115を初期化する。次に、ステップS102にお
いて、ラインデータメモリ112へのデータ読み出しア
ドレスを出力し、データの出力が可能な状態とする。次
に、ステップS103において、外部に対して、データ
読み出し要求を出力しデータ出力要求を待つ。ここで外
部とは、図1に示すようにCPU102のことである。
Next, the DMA controller 115 will be described. FIG. 7 is a flowchart showing a processing procedure in the DMA controller 115. Line data memory 11
When the writing to 2 is completed and the output becomes possible, first, in step S101 in FIG. 7, the DMA controller 115 is initialized. Next, in step S102, the data read address to the line data memory 112 is output, and the data output is enabled. Next, in step S103, a data read request is output to the outside, and the data output request is awaited. Here, the outside refers to the CPU 102 as shown in FIG.

【0037】データ出力要求を受けると、次に、ステッ
プS104において、ラインデータメモリ112からC
PU102にデータを出力する。1色分のデータを出力
し終えない内はステップS105からステップS102
に戻り、以降のステップを繰り返す。1色分のデータを
出力し終えるとステップS105からステップS106
に進み、3色分のデータを出力し終えない内はステップ
S107に進んでラインデータメモリ112のバンク切
り替えを行なって、ステップS102に戻り、以降のス
テップを繰り返す。3色分のデータを出力し終えると、
コントロールブロックにデータ出力の終了を伝え、処理
を終了する(END)。
When the data output request is received, next, in step S104, the C
The data is output to the PU 102. Until the output of the data for one color is not completed, steps S105 to S102
And repeat the subsequent steps. When the output of the data for one color is completed, steps S105 to S106 are performed.
If the process has not finished outputting the data for three colors, the process proceeds to step S107, the bank of the line data memory 112 is switched, the process returns to step S102, and the subsequent steps are repeated. When you have finished outputting data for three colors,
The end of the data output is notified to the control block, and the processing ends (END).

【0038】上述の一例では、1色ごとにラインデータ
を出力しているが、各画素ごとに、3色分のデータを連
続的に、もしくは一度に出力してもよい。その場合に
は、ラインデータメモリ112の読み出しアドレスを出
力後、順次バンクを切り替えることでデータ出力を行な
うことができる。このとき、ラインデータメモリ112
内のデータが、JPEGデコーダ111からデータをそ
のまま書き込んだ場合、DMAコントローラ115で走
査線方向のデータ順となるようにアドレスを発生し、読
み出すようにすることもできる。
In the above example, line data is output for each color. However, data for three colors may be output continuously or at once for each pixel. In this case, after outputting the read address of the line data memory 112, data can be output by sequentially switching banks. At this time, the line data memory 112
In the case where data is written as it is from the JPEG decoder 111, an address can be generated and read by the DMA controller 115 in the order of data in the scanning line direction.

【0039】次に、データ並べ替えを行なうとき、画像
サイズの変更も行なう本発明について説明する。その本
発明における画像伸張装置の構成の一例を図2に示し、
それを参照しながら説明する。図2において、201は
画像伸張装置、202はCPU(central processor un
it)、211はJPEG(joint photographic expert
group)デコーダ、212はラインデータメモリ、21
3はステータレジスタ、214は補間演算付リードライ
トコントローラ、215はDMA(direct memory acces
s)コントローラである。
Next, a description will be given of the present invention in which the image size is changed when the data is rearranged. FIG. 2 shows an example of the configuration of the image decompression device according to the present invention,
The description will be given with reference to this. 2, reference numeral 201 denotes an image decompression device, and 202 denotes a CPU (central processor union).
it) and 211 are JPEG (joint photographic expert)
group) decoder, 212 is a line data memory, 21
3 is a stator register, 214 is a read / write controller with interpolation operation, and 215 is a DMA (direct memory acces
s) Controller.

【0040】図1と図2における構成上の相違点は、図
1におけるリードライトコントローラ114に代って図
2においては補間演算付リードライトコントローラとな
っている部分である。その他の部分については、図1と
同様であり重複するから説明を省略する。補間演算付リ
ード・ライトコントローラ114は、JPEGデコーダ
111におけるブロック復号データの読み出し制御と、
画像サイズの変更と、ラインデータメモリ112への書
き込み制御とを行なう。この制御の様式はステータスレ
ジスタ113が記憶するステータスによる。
The difference between the configuration in FIGS. 1 and 2 is that the read / write controller 114 in FIG. 1 is replaced by a read / write controller with interpolation calculation in FIG. The other parts are the same as those in FIG. The read / write controller with interpolation operation 114 controls reading of block decoded data in the JPEG decoder 111,
The image size is changed and writing to the line data memory 112 is controlled. This control mode depends on the status stored in the status register 113.

【0041】ステータスレジスタ113において、以下
の設定を行なう。すなわち、JPEGデコーダ211か
らの出力画像X,Yブロック数(Xb,Yb)、元画像
のサイズから出力画像への倍率の逆数(1/K:以降単
に倍率)、バンクレジスタ、スタートアドレスレジスタ
(SA)、ラインメモリアドレスレジスタ(MA)、画
像サイズ変更後の出力画像サイズ(Xd,Yd)、の設
定を行なう。これは、JPEGデコーダ211から必要
なファイル情報を取得するように構成してもよいし、外
部から直接的に値を書き込むように構成してもよい。こ
こに示す一例では、サイズ変更処理を制御し易いよう
に、外部からデータを書き込むように構成している。ま
た、出力画像サイズは、倍率と出力画像ブロック数、ま
たは画素数から計算できるように構成可能である。しか
し、ここに示す一例では、不完全MCU等のブロック等
のコントロールがし易いように、外部から指定可能とし
ている。
The following settings are made in the status register 113. That is, the number of X and Y blocks (Xb, Yb) of the output image from the JPEG decoder 211, the reciprocal of the magnification from the size of the original image to the output image (1 / K: hereinafter simply referred to as the magnification), the bank register, the start address register (SA) ), The line memory address register (MA), and the output image size (Xd, Yd) after changing the image size. This may be configured to acquire necessary file information from the JPEG decoder 211, or may be configured to directly write a value from outside. In the example shown here, data is externally written so that the size change process can be easily controlled. The output image size can be configured to be calculated from the magnification and the number of output image blocks or the number of pixels. However, in the example shown here, it is possible to specify from the outside so as to easily control blocks such as incomplete MCUs.

【0042】補間演算付リード・ライトコントローラ1
14における画像サイズ変更処理部の構成の一例を図8
に示す。また、補間演算付リード・ライトコントローラ
114におけるにおける処理手順を図9、図10に示
す。また、補間方法の説明図を図11に示す。以下、図
8、図9、図10、および図11を参照しながら本発明
について説明する。
Read / write controller 1 with interpolation operation
FIG. 8 shows an example of the configuration of the image size change processing unit in FIG.
Shown in 9 and 10 show a processing procedure in the read / write controller 114 with interpolation calculation. FIG. 11 shows an explanatory diagram of the interpolation method. Hereinafter, the present invention will be described with reference to FIGS. 8, 9, 10, and 11. FIG.

【0043】補間演算は、図11に示すように、現在の
出力ドット位置(Mx)に倍率1/Kを乗算し、乗算結
果(SX)の整数部より、原画像(JPEGデコーダ2
11の出力画像)の補間演算に使用するドットデータと
してDSB,DSB+1を決定し、SXの小数部(position)
を用いて補間演算を行なう。この一例では、(1−posi
tion)×DSB+(position×DSB+1)により補間演算を
行なっている。倍率1/Kおよび乗算結果SXの精度
は、画像精度、外部機器の精度、必要な倍率に応じて適
当に選択すればよいが、一般的な高精細JPEG画像で
も、乗算結果SXの小数以下は2進数で8ビット以上は
不要である。乗算結果SXの整数部については、出力す
る画像サイズに応じてビット長を決定すればよい。
In the interpolation operation, as shown in FIG. 11, the current output dot position (Mx) is multiplied by a magnification 1 / K, and the original image (JPEG decoder 2) is obtained from the integer part of the multiplication result (SX).
Eleven (11 output images), DSB and DSB + 1 are determined as dot data to be used in the interpolation calculation, and the decimal part (position) of SX is determined.
Is used to perform an interpolation operation. In this example, (1-posi
and performing interpolation calculation with tion) × D SB + (position × D SB + 1). The precision of the magnification 1 / K and the precision of the multiplication result SX may be appropriately selected according to the precision of the image, the precision of the external device, and the required magnification. No more than 8 bits in binary are unnecessary. The bit length of the integer part of the multiplication result SX may be determined according to the size of the output image.

【0044】補間演算付リード・ライトコントローラ1
14における補間演算処理を行なう部分の構成は、この
一例では図8に示す構成となっている。図8に示すよう
に、補間演算を行なう2画素分のデータを保持しておく
レジスタDSB,DSB+1とブロック間のデータ補間を行な
うためのレジスタ(TREG)を有し、元画像の画素位
置を算出するための乗算器と補間演算ブロック、コント
ローラから構成されている。
Read / write controller 1 with interpolation operation
In this example, the configuration of the portion that performs the interpolation calculation process in 14 is the configuration shown in FIG. As shown in FIG. 8, the register D SB to hold the data of two pixels for performing an interpolation operation, has a register (TREG) for performing data interpolation between D SB + 1 and the block, the original image It is composed of a multiplier for calculating a pixel position, an interpolation operation block, and a controller.

【0045】ここに示す一例では、JPEGファイルを
対象としているため、TREGは8ビット×8ワードで
構成している(対象とするJPEGファイルによっては
16ワードのこともある)。また、この一例では、Y方
向の画像サイズ変更処理を行なう場合、Y方向のライン
データを一時的に取込むためにも使用している。この一
例では、X方向の変倍処理を行い、一度、ラインデータ
メモリ212に書き込み、ライン処理が終了した後、Y
方向変倍処理を行なうように構成している。別の一例と
して、補間処理後のデータをブロック単位で2ライン分
またはそれ以上を、一時的にレジスタ等に取り込み、所
定のY方向の変倍処理を行なった後、ラインメモリに書
き込んでもよい。
In the example shown here, since the JPEG file is targeted, the TREG is composed of 8 bits × 8 words (depending on the target JPEG file, the word may be 16 words). Further, in this example, when performing the image size changing process in the Y direction, it is also used to temporarily capture line data in the Y direction. In this example, a scaling process in the X direction is performed, written once in the line data memory 212, and after the line process is completed,
It is configured to perform directional scaling processing. As another example, two or more lines of data after the interpolation processing for each block may be temporarily fetched into a register or the like, and may be written in a line memory after performing a predetermined scaling process in the Y direction.

【0046】次に、変倍処理の過程について図9、図1
0を参照して説明する。図9はX方向の変倍処理、図1
0はY方向の変倍処理を示している。X方向の変倍処理
から説明する。JPEGデーコーダ211においてデー
タ出力が可能となると、まず、図9のステップS201
において、補間演算処理を行なう部分(図8参照)の回
路初期化を行なう。次に、ステップS202において、
出力画素の位置(Mx)から出力データの補間演算に必
要な画素位置を算出する。その演算は、Mx×(1/
K)=SXを算出し、SXの整数部より補間に必要な画
素位置SXを決定する。
Next, FIG. 9 and FIG.
0 will be described. FIG. 9 shows a scaling process in the X direction, and FIG.
0 indicates a scaling process in the Y direction. The scaling process in the X direction will be described. When data can be output in the JPEG decoder 211, first, step S201 in FIG.
, The circuit initialization of the portion for performing the interpolation calculation processing (see FIG. 8) is performed. Next, in step S202,
From the position (Mx) of the output pixel, the pixel position required for the output data interpolation calculation is calculated. The calculation is Mx × (1 /
K) = SX is calculated, and a pixel position SX necessary for interpolation is determined from an integer part of SX.

【0047】その画素位置SXが現ブロック内であれ
ば、ステップS203からステップS204に進み、D
SB,DSB+1にデータをJPEGデコーダ211よりロー
ドする。次に、ステップS205において、そのデータ
に対してSXの小数部(position)を用いて補間演算を
行なう。次に、ステップS206において、演算により
得られた結果を、並べ替えを行なうだけのときと同様
に、最終データが、画像の走査線方向に並ぶようにライ
ンメモリ上に書き込んで行く。1画素分の処理を終了す
ると、ステップS207において、Mxをインクリメン
トし、ステップS202に戻って、次の元画像データ位
置を算出し、以降のステップを繰り返す。
If the pixel position SX is within the current block, the process proceeds from step S203 to step S204, where D
Data is loaded from the JPEG decoder 211 into SB and DSB + 1 . Next, in step S205, an interpolation operation is performed on the data using the decimal part (position) of SX. Next, in step S206, the result obtained by the calculation is written on the line memory so that the final data is arranged in the scanning line direction of the image, as in the case where only the rearrangement is performed. When the process for one pixel is completed, Mx is incremented in step S207, the process returns to step S202, the next original image data position is calculated, and the subsequent steps are repeated.

【0048】SXの整数部が変わらないときには、
SB,DSB+1のデータはそのままで、positionデータの
み、新たな演算結果に変更し、次ドットの補間演算を行
なう。SXの整数部が変化した場合には、対応する
SB,DSB+1データをロードし、演算を繰り返す。
When the integer part of SX does not change,
While the data of DSB and DSB + 1 remain unchanged, only the position data is changed to a new calculation result, and interpolation calculation of the next dot is performed. When the integer part of SX has changed, the corresponding DSB and DSB + 1 data are loaded and the operation is repeated.

【0049】SXの整数部がブロックの最終データを超
えたときには(JPEGデータでは8の倍数)、ステッ
プS203からステップS208に進み、Mxをブロッ
クの処理開始値に戻し、次のライン処理を行なう。ま
た、ブロック内のラインデータの最終データはTREG
に保存する。そして、ブロックの処理が終了しない内
は、ステップS209からステップS202に戻り、以
降のステップを繰り返す。その結果、ブロック内では同
様の処理をブロックのライン数分だけ行なうこととな
る。
When the integer part of SX exceeds the final data of the block (a multiple of 8 in JPEG data), the process proceeds from step S203 to step S208, where Mx is returned to the processing start value of the block, and the next line processing is performed. The final data of the line data in the block is TREG.
To save. If the processing of the block is not completed, the process returns from step S209 to step S202, and the subsequent steps are repeated. As a result, the same processing is performed within the block for the number of lines of the block.

【0050】そして、ブロックの処理が終了すると、ス
テップS209からステップS210に進み、引き続き
次のブロック処理を行なう。ここで、Mxがブロックの
X方向の処理済みブロック数(Bx)とMx=k×Bx
(kはブロックのX方向画素数:JPEGにおいては
8)の関係になったとき、DSBにTREGに保存された
前ブロックのラインの最終データを、DSB+1にブロック
のラインの先頭データをロードし補間演算を行なう。こ
こに示す一例では、TREGは、ブロックのライン数と
同じ数のシフトレジスタで構成されている。そして、前
ブロックのライン最終データを全て取り込むと、対応す
るデータが出力される。その後、ラインの最終データを
TREGに保存するごとに、次のラインの最終データが
読み出されるように構成されている。
When the processing of the block is completed, the process proceeds from step S209 to step S210, and the next block processing is performed. Here, Mx is the number of processed blocks (Bx) in the X direction of the block and Mx = k × Bx
(K is the number of X-direction pixels of the block: 8 in JPEG) when they become relationship, D the final data of the previous block line stored in TREG the SB, the first data line of the block to the D SB + 1 And perform an interpolation operation. In the example shown here, the TREG is configured by the same number of shift registers as the number of lines in the block. Then, when all the line final data of the previous block is fetched, the corresponding data is output. Thereafter, every time the last data of the line is stored in the TREG, the last data of the next line is read.

【0051】このようにしてブロック単位の変倍処理
を、原画像の走査線方向におけるブロックの全てについ
て終了すると、ステップS211において終了(EN
D)となり、次のY方向の変倍処理へと移行する。な
お、ラインメモリの容量を多くとれれば、Y方向2ブロ
ック以上の処理を行なってもかまわないが、この一例で
は、Y方向1ブロック分としている。X方向の終了は、
処理ブロック数がXbになるか、出力画素数がXdにな
った場合に終了する。出力画素数がXdになり処理ブロ
ック数Xbに満たない場合にはXbになるまでブロック
データを読み捨てるようにしている。
When the scaling process for each block is completed for all the blocks in the scanning line direction of the original image in this way, the process ends in step S211 (EN
D), and the processing shifts to the next scaling process in the Y direction. If the capacity of the line memory is large, the processing in two or more blocks in the Y direction may be performed, but in this example, the processing is performed for one block in the Y direction. The end in the X direction
The process ends when the number of processing blocks reaches Xb or the number of output pixels reaches Xd. If the number of output pixels becomes Xd and does not reach the number of processing blocks Xb, block data is read and discarded until Xb is reached.

【0052】次に、Y方向の変倍処理について説明す
る。Y方向の変倍処理の手順を図10に示す。図10に
示すフローは前述の図9との類似点が多いから、特徴点
についてだけ説明する。Y方向の変倍処理を行なう場
合、Y方向の出力画素(My)より必要な原画像(前述
のX方向変倍処理終了後のデータ)位置を算出して、必
要なデータだけを読み出す方法もある。しかし、ここに
示す一例では、Y方向のラインデータをラインデータメ
モリ212からTREGに読み込む。このとき、ライン
メモリ上に前原画像データの最終ラインのデータをメモ
リ上に保存しておき、Y方向のブロック間のデータ補間
を行なう場合、そのデータを使用して補間処理を行な
う。
Next, the scaling process in the Y direction will be described. FIG. 10 shows the procedure of the scaling process in the Y direction. Since the flow shown in FIG. 10 has many similarities to FIG. 9 described above, only the feature points will be described. When performing scaling processing in the Y direction, a method of calculating a necessary original image (data after completion of the above-described scaling processing in the X direction) from output pixels (My) in the Y direction and reading only necessary data is also available. is there. However, in the example shown here, the line data in the Y direction is read from the line data memory 212 into the TREG. At this time, when the data of the last line of the previous original image data is stored in the memory on the line memory and the data interpolation between the blocks in the Y direction is performed, the interpolation processing is performed using the data.

【0053】Y方向における補間処理の方法は、前述し
たX方向の変倍処理における補間方法と同様な方法であ
る。その補間処理で得られるデータを出力画像の走査線
方向にデータが並ぶようにラインデータメモリ212上
にデータを書き戻す。原画像ブロックのY方向における
ドット分の処理が終了すると、原画像の最終データをメ
モリ上の前最終ラインデータを補完する領域に保管し、
次のY方向のラインデータを読み出し、同様の処理を行
なう。
The interpolation method in the Y direction is the same as the interpolation method in the scaling process in the X direction described above. The data obtained by the interpolation processing is written back to the line data memory 212 so that the data is arranged in the scanning line direction of the output image. When the processing for the dots in the Y direction of the original image block is completed, the final data of the original image is stored in an area that complements the previous last line data in the memory,
The next line data in the Y direction is read, and the same processing is performed.

【0054】すべてのデータに関して変倍処理が終了す
ると、外部機器へのデータ転送部へ処理が渡されDMA
等によりデータを出力する。このときの出力は、並べ替
えを行なうときと同じようにして行なわれるが、変倍処
理のため、倍率によっては、各出力ごとに出力ライン数
が異なるため、ここでは、Y変倍時に、処理ライン数を
カウントし、ラインデータを転送コントロール部に与え
ることにより、出力ライン数を外部に知らせると共に、
転送データ数をコントロールするように構成されてい
る。
When the scaling process is completed for all the data, the process is passed to the data transfer unit to the external device and the data is transferred to the DMA.
And the like to output data. The output at this time is performed in the same manner as when the rearrangement is performed. However, since the number of output lines is different for each output depending on the magnification because of the scaling processing, the processing is performed at the time of Y scaling. By counting the number of lines and giving the line data to the transfer control unit, the number of output lines is notified to the outside,
It is configured to control the number of transfer data.

【0055】[0055]

【発明の効果】本発明の請求項1に係る画像伸張装置に
よれば、DMAなどの高速転送手段を使用でき、データ
取得後の処理が簡潔で低速のCPUでも高速処理が可能
となる画像伸張装置(LSI)が提供される。また本発
明の請求項2に係る画像伸張装置によれば、JPEGフ
ァイルにおいて、画像伸張、高速転送、高速処理が可能
となる。また本発明の請求項3に係る画像伸張装置によ
れば、画像伸張、画像変倍、高速転送、高速処理が可能
となる。また本発明の請求項4に係る画像伸張装置によ
れば、DMAなどの高速転送手段を使用でき、データ取
得後の処理が簡潔で低速のCPUでも高速処理が可能と
なる画像伸張装置(LSI)が提供される。また本発明
の請求項5に係る画像伸張装置によればM×(1/K)
の掛け算によりSが求められるから簡潔で精度を良くす
ることができる。また本発明の請求項6に係る画像伸張
装置によれば演算過程が簡素化される。また本発明の請
求項7に係る画像伸張装置によれば、バイリニアによる
画像変倍を行なうことができる。
According to the image decompression apparatus according to the first aspect of the present invention, high-speed transfer means such as DMA can be used, the processing after data acquisition is simple, and high-speed processing can be performed even with a low-speed CPU. An apparatus (LSI) is provided. According to the image decompression device of the second aspect of the present invention, image decompression, high-speed transfer, and high-speed processing can be performed on a JPEG file. According to the image decompression device of the third aspect of the present invention, image decompression, image scaling, high-speed transfer, and high-speed processing can be performed. Further, according to the image decompression device according to the fourth aspect of the present invention, a high-speed transfer means such as a DMA can be used, the processing after data acquisition is simple, and a high-speed processing can be performed even with a low-speed CPU. Is provided. Further, according to the image decompression device according to claim 5 of the present invention, M × (1 / K)
S can be obtained by multiplying by .times..times..times. According to the image decompression device of the sixth aspect of the present invention, the operation process is simplified. Further, according to the image decompression device according to the seventh aspect of the present invention, it is possible to perform bilinear image magnification.

【図面の簡単な説明】[Brief description of the drawings]

【図1】本発明における画像伸張装置の構成の一例を示
す図である。
FIG. 1 is a diagram illustrating an example of the configuration of an image decompression device according to the present invention.

【図2】画像サイズの変更も行なう本発明における画像
伸張装置の構成の一例を示す図である。
FIG. 2 is a diagram illustrating an example of a configuration of an image decompression device according to the present invention that also changes an image size.

【図3】JPEGデコーダが出力するデータの出力順序
を示す説明図である。
FIG. 3 is an explanatory diagram showing an output order of data output by a JPEG decoder.

【図4】リードライトコントローラにおける処理の過程
を示すフロー図(その1)である。
FIG. 4 is a flowchart (part 1) illustrating a process in a read / write controller;

【図5】リードライトコントローラにおける処理の過程
を示すフロー図(その2)である。
FIG. 5 is a flowchart (part 2) showing a process in the read / write controller;

【図6】リードライトコントローラのカウンタレジス
タ、等の構成の一例を示す図である。
FIG. 6 is a diagram showing an example of a configuration of a counter register and the like of a read / write controller.

【図7】DMAコントローラにおける処理過程を示すフ
ロー図である。
FIG. 7 is a flowchart showing a processing procedure in a DMA controller.

【図8】補間演算付リード・ライトコントローラ114
における画像サイズ変更処理部の構成の一例を示す図で
ある。
FIG. 8 is a read / write controller 114 with interpolation operation.
FIG. 4 is a diagram illustrating an example of the configuration of an image size change processing unit in FIG.

【図9】補間演算付リード・ライトコントローラにおけ
る処理手順を示すフロー図(その1)である。
FIG. 9 is a flowchart (part 1) illustrating a processing procedure in a read / write controller with interpolation calculation;

【図10】補間演算付リード・ライトコントローラにお
ける処理手順を示すフロー図(その2)である。
FIG. 10 is a flowchart (part 2) illustrating a processing procedure in the read / write controller with interpolation calculation;

【図11】補間方法の説明図である。FIG. 11 is an explanatory diagram of an interpolation method.

【符号の説明】[Explanation of symbols]

101,201 画像伸張装置 102,202 CPU 111,211 JPEGデコーダ 112,212 ラインデータメモリ 113,213 ステータスレジスタ 114 リードライトコントローラ 214 補間演算付リードライトコントローラ 101, 201 Image decompression device 102, 202 CPU 111, 211 JPEG decoder 112, 212 Line data memory 113, 213 Status register 114 Read / write controller 214 Read / write controller with interpolation operation

───────────────────────────────────────────────────── フロントページの続き (51)Int.Cl.7 識別記号 FI テーマコート゛(参考) H04N 7/30 H04N 7/133 Z (72)発明者 五十嵐 美帆 東京都新宿区市谷加賀町一丁目1番1号 大日本印刷株式会社内 Fターム(参考) 5B061 BA03 DD06 5C023 AA02 AA27 AA40 CA02 DA04 DA08 EA06 5C059 KK08 KK12 KK33 LA09 LC09 MA00 MA27 PP14 UA05 UA30 UA36 5C078 AA09 BA21 DA01 DA02 5J064 BC01 BC02 ──────────────────────────────────────────────────の Continued on the front page (51) Int.Cl. 7 Identification FI FI Theme Court ゛ (Reference) H04N 7/30 H04N 7/133 Z (72) Inventor Miho Igarashi 1-1-1 Ichigaya-Kagacho, Shinjuku-ku, Tokyo No. 1 Dai Nippon Printing Co., Ltd. F term (reference) 5B061 BA03 DD06 5C023 AA02 AA27 AA40 CA02 DA04 DA08 EA06 5C059 KK08 KK12 KK33 LA09 LC09 MA00 MA27 PP14 UA05 UA30 UA36 5C078 AA09 BA21 DA01 DA02 5J064 BC01 BC02

Claims (7)

【特許請求の範囲】[Claims] 【請求項1】ブロック符号を用いた画像圧縮データファ
イルの復号化を行なう画像伸張装置であって、 ブロック符号化されたファイルを復号しブロック復号デ
ータを生成する復号手段と、 前記ブロック復号データの複数を記憶する記憶手段と、 前記ブロック復号データの集合体としての画像復号デー
タファイルにおける画像サイズを演算する画像サイズ演
算手段と、 前記復号手段から出力されるブロック復号データを前記
復号データ記憶手段において前記画像復号データファイ
ルの走査線方向に並べ替る並替手段と、 前記復号データ記憶手段に記憶されている画像復号デー
タを走査線方向に連続的に読み出す読出手段とを有する
ことを特徴とする画像伸張装置。
An image decompression device for decoding a compressed image data file using a block code, comprising: decoding means for decoding a block-encoded file to generate block decoded data; A storage unit for storing a plurality of blocks; an image size calculation unit for calculating an image size in an image decoding data file as an aggregate of the block decoding data; and a block decoding data output from the decoding unit in the decoding data storage unit. An image, comprising: a reordering unit that rearranges the decoded image data file in the scanning line direction; and a reading unit that continuously reads out the decoded image data stored in the decoded data storage unit in the scanning line direction. Stretching device.
【請求項2】請求項1記載の画像伸張装置において、前
記ブロック符号化されたファイルはJPEG方式のファ
イルであって、前記復号手段は縦8画素×横8画素のブ
ロック復号データを生成し、前記記憶手段は走査線方向
に少なくとも8ラインのデータを記憶することを特徴と
する画像伸張装置。
2. An image decompression apparatus according to claim 1, wherein said block-encoded file is a JPEG file, and said decoding means generates block-decoded data of 8 × 8 pixels. An image decompressing apparatus, wherein the storage means stores at least eight lines of data in a scanning line direction.
【請求項3】請求項1または2記載の画像伸張装置にお
いて、 出力画像データの原画像に対する倍率を指定する倍率指
定手段と、 前記復号手段から出力されるブロック復号データを指定
された倍率に、既に出力されたブロック復号データにお
ける必要とされるデータを取得しながら、画像サイズを
変更する画像サイズ変更手段と、 前記サイズ変更した画像データを前記記憶手段において
走査線方向に並べ替える並替手段と、 を有することを特徴とする画像伸張装置。
3. The image decompression device according to claim 1, wherein a magnification designating means for designating a magnification of the output image data with respect to the original image; Image size changing means for changing the image size while obtaining required data in the already output block decoded data; and reordering means for rearranging the resized image data in the scanning line direction in the storage means. An image decompression device, comprising:
【請求項4】請求項1〜3のいずれかに記載の画像伸張
装置において、 出力画像データの原画像に対する倍率Kを指定する手段
と、 指定された倍率Kと出力画素位置Mxより、MxをKで
割った値Sxを求める手段と、 Sxの整数部Sxaと、現在まで処理済みのブロック数
Bxと、ブロックサイズ(Lx画素×Ly画素)より、
SxaがBx×Lx<=Sxa<(Bx+1)×Lxを判
定する手段と、 前記復号手段から出力されるブロック復号データのSx
a−(Bx×Lx)番目のデータDSBとSxa−(Bx×
Lx)+1番目のデータDSB+1をを取得する手段と、 Sxの小数部Sxbより、DSB×(1−Sxb)+DSB+1
Sxbを算出し出力画像データとする手段と、 前記操作をブロック内のライン数Ly回繰り返し行なう
手段と、 前記復号手段から出力されるブロック画像データの走査
線方向におけるラインデータの各最終データを保存し、
次のブロック出力時においてSxa=(Bx+1)×L
xとなった場合に各ラインのDSBデータとして使用する
手段と、 前記走査線方向だけサイズ変更された画像データを前記
記憶手段に出力画像の走査線方向にデータを並べ替える
手段と、 前記記憶手段に保存されたデータから、Y方向のライン
データを取得する手段と、 現在処理中のライン位置MyとMyをKで割った値Sy
を求める手段と、 Syの整数部Syaと、現在まで処理済みのY方向ブロ
ック数Byと、ブロックサイズ(Lx画素×Ly画素)
より、SyaがBy×Ly<=Sya<(By+1)×L
yを判断する手段と、 取得したY方向データのSya−(By×Ly)番目の
データDSBとSya−(By×Ly)+1番目のデータ
SB+1を取得する手段と、 Syの小数部Sybより、DS×(1−Syb)+DS+1×
Sybを算出し出力画像データとする手段と、 前記操作を前記記憶手段に記憶されているすべてのライ
ンデータについて繰り返し行なう手段と、 各Y方向ラインデータの最終データを保存する手段と、 次回のY方向サイズ変更処理のとき、Sya=(By+
1)×Lyとなった場合に各ラインのDSBデータとして
使用する手段と、 サイズ変更した画像データを前記記憶手段に出力画像の
走査線方向に並ぶように再度書き戻す手段と、 を有することを特徴とする画像伸張装置。
4. An image decompression apparatus according to claim 1, wherein: a unit for designating a magnification K of the output image data with respect to the original image; means for determining a value obtained by dividing Sx in K, an integer part Sx a of Sx, the number of blocks Bx processed to date than the block size (Lx pixels × Ly pixels),
Sx a determines Bx × Lx <= Sx a <(Bx + 1) × Lx, and Sx of the block decoded data output from the decoding unit
a− (Bx × Lx) -th data DSB and Sx a− (Bxx ×
Lx) means for obtaining the + 1st data D SB + 1, from the fractional part Sx b of Sx, D SB × (1- Sx b) + D SB + 1
Means to calculate the sx b output image data, and means to repeat the line number Ly times in the block the operation, each last data line data in the scanning line direction of the block image data output from said decoding means Save and
Sx a = (Bx + 1) × L at the time of the next block output
means for using the data as the DSB data of each line when x is reached; means for rearranging the data in the scanning line direction of the output image into the storage means with the image data resized in the scanning line direction; Means for acquiring line data in the Y direction from the data stored in the means, and the line positions My and My which are currently being processed, and a value Sy obtained by dividing My by K
Means for determining, and an integer portion Sy a of Sy, and processed in the Y-direction block count By far, the block size (Lx pixels × Ly pixels)
More, Sy a is By × Ly <= Sy a < (By + 1) × L
means for determining y, the obtained Y-direction data Sy a - (By × Ly) th data D SB and Sy a - (By × Ly) +1 th and means for acquiring data D SB + 1 of, Sy from the fraction Sy b, D S × (1 -Sy b) + D S + 1 ×
Means for calculating Sy b to be output image data; means for repeating the operation for all line data stored in the storage means; means for storing final data of each Y-direction line data; when Y-resize processing, Sy a = (By +
1) means for using as the DSB data of each line when x Ly is obtained, and means for rewriting the resized image data in the storage means so as to be arranged in the scanning line direction of the output image. An image decompression device characterized by the above-mentioned.
【請求項5】請求項4記載の画像伸張装置において、倍
率として1/Kを設定することにより、SをM×(1/
K)により得ることを特徴とする画像伸張装置。
5. The image decompression device according to claim 4, wherein S is set to M × (1/1) by setting 1 / K as a magnification.
An image decompression device obtained by K).
【請求項6】請求項4記載の画像伸張装置において、Y
方向ラインデータのSya−(By×Ly)を計算した
後、必要なデータDSBとデータDSB+1を記憶装置から取
得することを特徴とする画像伸張回路。
6. The image decompression device according to claim 4, wherein Y
Sy a direction line data - (By × Ly) After the calculation, the image extension circuit and acquires the data D SB and the data D SB + 1 needed from the storage device.
【請求項7】請求項4記載の画像伸張装置において、画
像変倍手法がバイリニア方式であることを特徴とする画
像伸張装置。
7. The image decompression device according to claim 4, wherein the image scaling method is a bilinear method.
JP2000318708A 2000-10-19 2000-10-19 Image decompression apparatus Withdrawn JP2002135595A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2000318708A JP2002135595A (en) 2000-10-19 2000-10-19 Image decompression apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2000318708A JP2002135595A (en) 2000-10-19 2000-10-19 Image decompression apparatus

Publications (1)

Publication Number Publication Date
JP2002135595A true JP2002135595A (en) 2002-05-10

Family

ID=18797291

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2000318708A Withdrawn JP2002135595A (en) 2000-10-19 2000-10-19 Image decompression apparatus

Country Status (1)

Country Link
JP (1) JP2002135595A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006109173A (en) * 2004-10-06 2006-04-20 Sony Corp Image filter circuit and interpolation processing method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006109173A (en) * 2004-10-06 2006-04-20 Sony Corp Image filter circuit and interpolation processing method
JP4677755B2 (en) * 2004-10-06 2011-04-27 ソニー株式会社 Image filter circuit and interpolation processing method

Similar Documents

Publication Publication Date Title
JP3931577B2 (en) Method of using memory and arithmetic processing device
WO2012082029A1 (en) Method and device for storing a compression ratio indication in a pixel value buffer in tile encoding
JP2002135595A (en) Image decompression apparatus
JP2006333496A (en) Programmable logic circuit device and information processing system
JP2000311241A (en) Image processor
TW452708B (en) Architecture for fast compression of 2-dimensional image data
JP2000069478A (en) Picture processor, picture processing method and storage medium
JP4109151B2 (en) Image processing device
CN114648444A (en) Vector up-sampling calculation method and device applied to neural network data processing
JP4713957B2 (en) Image processing device
JP3242788B2 (en) Signal processing device and signal processing method
JPH09245164A (en) Picture storage device and picture output device
US20070040842A1 (en) Buffer memory system and method
JP2960328B2 (en) Apparatus for providing operands to &#34;n + 1&#34; operators located in a systolic architecture
JPS62195979A (en) Facsimile code converter
JP2839392B2 (en) Image data restoration method and apparatus
JP2005244844A (en) Moving image coding device
JPH07184063A (en) Binary image compression system
JP2790911B2 (en) Orthogonal transform operation unit
JP2004302647A (en) Vector processor and address designation method for register
JPH07234863A (en) Two-dimensional orthogonal transformation device
JP4330920B2 (en) Memory circuit for image processing
WO2001006461A1 (en) Drawing method and drawing device
JPH06324935A (en) Address generator and address generation system
JP3563235B2 (en) Data interpolation circuit

Legal Events

Date Code Title Description
A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20080108