JP3842968B2 - Image data processing device - Google Patents

Image data processing device Download PDF

Info

Publication number
JP3842968B2
JP3842968B2 JP2000335904A JP2000335904A JP3842968B2 JP 3842968 B2 JP3842968 B2 JP 3842968B2 JP 2000335904 A JP2000335904 A JP 2000335904A JP 2000335904 A JP2000335904 A JP 2000335904A JP 3842968 B2 JP3842968 B2 JP 3842968B2
Authority
JP
Japan
Prior art keywords
data
unit
input
image data
unprocessed
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2000335904A
Other languages
Japanese (ja)
Other versions
JP2002140056A (en
Inventor
達夫 平松
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sanyo Electric Co Ltd
Original Assignee
Sanyo Electric 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 Sanyo Electric Co Ltd filed Critical Sanyo Electric Co Ltd
Priority to JP2000335904A priority Critical patent/JP3842968B2/en
Publication of JP2002140056A publication Critical patent/JP2002140056A/en
Application granted granted Critical
Publication of JP3842968B2 publication Critical patent/JP3842968B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Description

【0001】
【発明の属する技術分野】
本発明は、メモリ内に格納された画像データより、選択された画像を再生するのに必要な画像データを読み出すとともに処理して、ディスプレイなどの後段の装置に出力するグラフィックLSI(Large Scale Integrated Circuit)に代表される画像データ処理装置に関するものである。
【0002】
【従来の技術】
ディスプレイなどの表示装置上に画像再生するために画像データの処理を行うグラフィックLSIは、ユーザーによって指定されたビットマップ画像の画像データがメモリより転送されることで、表示するビットマップ画像の画像データを生成し出力する。このとき、メモリに格納されているデータより、グラフィックLSIで処理されるビットマップ画像の画像データのみが選択され、この処理されるビットマップ画像の画像データのみが順次グラフィックLSIに転送される。
【0003】
又、近年におけるCPU(Centaral Processing Unit)やハードウェア技術の発展により、各回路装置で処理されるデータのバイト数が増加している。よって、CPUからグラフィックLSIに対して、メモリに格納された画像データを4バイト毎にまとめて転送することができ、その処理能力や転送能力が向上している。
【0004】
よって、今、図7のように、メモリに4バイト毎にデータA〜Pが格納されており、再生されるビットマップ画像の画像データがA〜G及びI〜Oとなるとき、一旦、CPUによって、メモリよりデータA〜Pが読み出された後、データH,Pを除いた画像データA〜G,I〜Oが選択される。そして、この読み出された画像データが4バイト毎に、(A,B,C,D)、(E,F,G,I)、(J,K,L,M)、(N,O,*,*)の順にグラフィックLSIに転送される。尚、この場合、*は、無効となるデータである。
【0005】
【発明が解決しようとする課題】
このように、従来では、メモリ内に格納されたデータから、必要とされる画像データがCPUによって選択されて、順次グラフィックLSIに転送されるように、画像データのシフト処理を行う必要がある。よって、CPUでグラフィックLSIに転送するための画像データを生成するために処理時間がかかる。
【0006】
更に、メモリ内に格納された画像データを直接グラフィックLSIに転送するDMA(Direct Memory Access)転送の場合、図7のようにデータがメモリに格納されたとき、画像データがメモリからグラフィックLSIに対して4バイト毎に転送されるため、(A,B,C,D)、(E,F,G,H)、(I,J,K,L)、(M,N,O,P)の順に送出される。よって、グラフィックLSIで処理されないデータH,Pをも転送される。このように、DMA転送においては、上述のような不要なデータを除いて複数データを転送する転送システムを行うことができず、メモリ内に格納された全データが順次転送されてしまう。
【0007】
このような問題を鑑みて、本発明は、メモリより複数のデータ毎に順次データがCPUによる処理もなく転送されるとき、不要とされるデータを除去して必要な画像データのみを処理することができる画像データ処理装置を提供することを目的とする。
【0008】
【課題を解決するための手段】
上記目的を達成するために、請求項1に記載の画像データ処理装置は、画像1ライン毎に該画像を表す画像データを連続的に格納するメモリ内に格納されたデータが所定単位毎に入力されるとともに、入力されるデータ内に含まれる画像データに対して画像データ処理を施す画像データ処理装置において、メモリから与えられるデータから不要データを除去して、必要な画像データを選択して、画像データ処理を施すデータ処理部と、最初に入力される前記所定単位のデータ内に含まれる不要データのデータ数を設定する第1不要データ数設定部と、1ライン最後の画像データと次のライン最初の画像データとの間に存在する不要データのデータ数を設定する第2不要データ数設定部と、第1又は第2不要データ数設定部の何れか一方で設定された不要データのデータ数を選択する選択部と、画像1ライン分の画像データが前記データ処理部に送出されたことを確認したとき、ライン処理終了信号を前記選択部及び前記データ処理部に送出するライン処理終了検出部と、を有し、前記メモリより、画像データを含む所定単位のデータの入力が開始されたとき、前記選択部で前記第1不要データ数設定部で設定された不要データのデータ数が前記データ処理部に与えられ、又、前記ライン処理終了検出部よりライン処理終了信号が発生したとき、前記選択部で前記第2不要データ数設定部で設定された不要データのデータ数が前記データ処理部に与えられることを特徴とする。
【0009】
このような画像データ処理装置は、CPUなどによって指定されたアドレス領域に格納されたデータがメモリより連続的に入力される。このとき、画像データ処理装置では、選択部で選択された不要データのデータ数に基づいて、必要とされる画像データ以外の不要データを除去した後、必要な画像データに対して各種画像データ処理を施す。よって、メモリに格納されたデータを処理して必要な画像データのみを送出するための転送手段が不要となり、データがバス回線の能力に応じて、所定単位数(単位バイト)毎に直接メモリより入力される。
【0010】
請求項2に記載の画像処理装置は、請求項1に記載の画像データ処理装置において、前記データ処理部が、画像データ処理を行う画像データ処理部と、前記メモリより入力される前記所定単位のデータを前記画像データ処理部に送出するとともに、前記選択部で選択された不要データのデータ数に基づいて前記所定単位のデータにおける画像データの位置を特定するための画像データ位置特定信号を生成して前記画像データ処理部に送出する画像データ位置特定部と、を有し、前記メモリより、画像データを含む前記所定単位のデータの入力が開始されたとき、前記選択部で前記第1不要データ数設定部で設定された不要データのデータ数が前記画像データ位置特定部に与えられて、入力開始時の前記所定単位のデータにおける画像データの位置を特定するための画像データ位置特定信号が生成され、前記ライン処理終了検出部よりライン処理終了信号が発生するまでの間、前記メモリより入力されるデータ全てが画像データであることを示す画像データ位置特定信号が生成され、前記ライン処理終了検出部よりライン処理終了信号が発生したとき、前記選択部で前記第2不要データ数設定部で設定された不要データのデータ数が前記画像データ位置特定部に与えられ、1ライン終了時の画像データの位置を特定するとともに次のライン開始時の画像データの位置を特定する画像データ位置特定信号が生成されることを特徴とする。
【0011】
このような画像データ処理装置において、請求項3に記載するように、前記画像データ位置特定信号が、前記画像データ位置特定部より前記画像データ処理部に送出されるデータ数を示す入力未処理数と、1ラインの画像データのうち前記画像データ処理部に送出されていない画像データのデータ数を示すライン未処理数とによって構成されるようにしても構わない。このとき、画像データ処理部にデータとともに入力される入力未処理数及びライン未処理数の変化より、画像データ処理部において、入力されたデータ内における画像データの位置を認識することができる。
【0012】
又、請求項4に記載するように、前記画像データ位置特定部が、前記入力未処理数を設定する入力未処理数設定部と、前記ライン未処理数を設定するライン未処理数設定部と、前記選択部で選択された不要データのデータ数が与えられるとともに、前記画像データ処理部に送出されるデータ内の不要データのデータ数を表す飛ばしデータ数を設定する飛ばしデータ数設定部と、を備え、前記メモリより、画像データを含む前記所定単位のデータの入力が開始されたとき、前記選択部で前記第1不要データ数設定部で設定された不要データのデータ数が前記飛ばしデータ数設定部に与えられて前記飛ばしデータ数設定部において飛ばしデータ数として設定されるとともに、前記ライン未処理数において1ラインの画像データのデータ数がライン未処理数として設定され、前記ライン処理終了検出部よりライン処理終了信号が発生したとき、前記選択部で前記第2不要データ数設定部で設定された不要データのデータ数が前記飛ばしデータ数設定部に与えられて前記飛ばしデータ数設定部において飛ばしデータ数として設定されるとともに、前記ライン未処理数において1ラインの画像データのデータ数がライン未処理数として設定され、前記飛ばしデータ数設定部で設定された飛ばしデータ数が前記入力未処理数で設定された入力未処理数以上のとき、該飛ばしデータ数より該入力未処理数を減算した値が新たに飛ばしデータ数として設定され、前記飛ばしデータ数設定部で設定された飛ばしデータ数が前記入力未処理数で設定された入力未処理数より小さいとき、飛ばしデータ数が0と設定され、前記飛ばしデータ数設定部で設定された飛ばしデータ数が、前記入力未処理数で設定された入力未処理数より小さいとき、前記ライン未処理数で設定されたライン未処理数から該入力未処理数を減算した後に該飛ばしデータ数を加算した値が新たにライン未処理数として設定されるようにしても構わない。
【0013】
このとき、画像データ処理部に画像データ位置特定部よりデータが入力されるたびに、入力されるデータ内の画像データの位置を特定するための入力未処理数及びライン未処理数が、前回設定された入力未処理数及びライン未処理数及び飛ばしデータ数に基づいて画像データ位置特定部で設定される。そして、この設定された入力未処理数及びライン未処理数が、画像データ処理部に画像データ位置特定部よりデータが入力されるたびに、入力されるデータとともに画像データ処理部に与えられる。よって、画像データ処理部では、画像データのみが選択されて、各種画像データ処理が施される。
【0014】
【発明の実施の形態】
本発明の実施の形態について、図面を参照して説明する。図1は、本発明の画像データ処理装置に相当するグラフィックLSI周辺の関係を示すブロック図である。図2は、グラフィックLSI内の内部構成を示すブロック図である。図3は、グラフィックLSIに設けられたデータ転送制御部の内部構成を示すブロック図である。
【0015】
図1のように、CPU1、メモリ2、グラフィックLSI3がバス回線4を介してデータのやりとりを行う。このとき、CPU1よりメモリ2に対して、グラフィックLSI3に転送するデータのアドレスが指定され、この指定されたアドレスのデータが連続的に、メモリ2内に格納された単位バイト毎にグラフィックLSI3に転送される。このように、図1において、メモリ2からグラフィックLSI3に、データがDMA転送される。よって、選択されたビットマップ画像の画像データのみでなく、この画像データとともに格納された不要なデータもグラフィックLSI3に転送される。
【0016】
又、CPU1からグラフィックLSI3に対して、ビットマップ画像の画像データの1ライン毎のバイト数などの後述する各種データが、バス回線4を介して送出される。よって、グラフィックLSI3は、メモリ2から単位バイト毎に転送されるデータから不要なデータを取り除いて、選択されたビットマップ画像の画像データのみを選択した後、この画像データをデータ処理して出力することができる。
【0017】
このグラフィックLSI3について、図2及び図3を参照して説明する。図2に示すグラフィックLSI3は、ビットマップ画像1ライン分の画像データのデータ数(Lバイト)を格納するラインデータ数格納部5と、ビットマップ画像1ライン分の画像データのうち最初の画像データの前にメモリ2から読み出される不要データのデータ数(Lsバイト)を格納する開始不要データ数格納部6と、ビットマップ画像1ライン分の画像データのうち最後の画像データの後にメモリ2から読み出される不要データのデータ数(Leバイト)を格納する終了不要データ数格納部7とを有する。
【0018】
尚、以下、ラインデータ数格納部5、開始不要データ数格納部6、及び終了不要データ数格納部7に格納されるデータ数をそれぞれ、ラインデータ数、開始不要データ数、及び終了不要データ数と呼ぶ。この開始不要データ数及び終了不要データ数については、後述する。又、このラインデータ数L、開始不要データ数Ls、及び終了不要データ数Leは、CPU1よりラインデータ数格納部5、開始不要データ数格納部6、及び終了不要データ数格納部7にそれぞれ送出される。
【0019】
又、グラフィックLSI3では、開始不要データ数Ls及び終了不要データ数Leを加算する加算部8と、開始不要データ数Lsと加算部8で加算された不要データ数Ls+Leとのうちいずれかを選択してデータ転送制御部11に送出する選択部9と、処理されたデータ数を計数して次にメモリ2より入力される単位バイトのデータでビットマップ画像1ライン分のデータが処理されることを検出する1ライン処理終了検出部10と、データ転送部12の動作を制御するデータ転送制御部11と、メモリ2より送出されるデータを転送するデータ転送部12と、データ転送部12より与えられる画像データに対して補間処理やエッジ強調処理などの各画像データ処理を施すデータ処理部13とを有する。
【0020】
このような構成のグラフィックLSI3は、まず、CPU2よりラインデータ数L、開始不要データ数Ls、及び終了不要データ数Leが与えられて、それぞれ、ラインデータ数格納部5、開始不要データ数格納部6、及び終了不要データ数格納部7に格納される。そして、開始不要データ数格納部6に格納された開始不要データ数Lsが加算部8及び選択部9に与えられる。又、終了不要データ数格納部7に格納された終了不要データ数Leが加算部8に与えられる。又、ラインデータ数格納部5に格納されたラインデータ数Lが1ライン処理終了検出部10に与えられる。
【0021】
次に、メモリ2からxバイト毎にデータの転送が開始されるとともに、スタートパルスが選択部9、及びデータ転送制御部11に与えられると、選択部9では、開始不要データ数Lsを選択してデータ転送制御部11に送出する。又、データ転送制御部11が動作を開始し、データ転送部12が動作開始するように制御する。そして、データ転送部12は、データ転送制御部11によってメモリ2からのデータの入力とデータ処理部13への出力とが制御される。
【0022】
又、データ転送制御部11より後述する入力未処理数及びライン未処理数を表す信号が与えられる。そして、データ処理部13は、データ転送制御部11より与えられる入力未処理数及びライン未処理数に基づいて、データ転送部12より与えられるデータから、指定されたビットマップ画像の画像データを選択して画像データ処理を施す。尚、このデータ転送制御部11の詳細な動作については、後述する。
【0023】
又、1ライン処理終了検出部10は、例えばカウンタなどで構成され、データ転送部12によってデータ処理部13に送出された画像データのデータ数(バイト数)が計数される。そして、計数されたデータ数がデータ数L−xに達したことを検出したときに、次にxバイトのデータがデータ転送部12よりデータ処理部13に送出されると、ビットマップ画像1ライン分の画像データが全てデータ処理部13に出力されることが確認される。よって、このとき、データ転送部12にはメモリ2より1ライン終了時の画像データが入力されている。
【0024】
そして、1ライン処理終了検出部10は、選択部9及びデータ転送制御部11に、メモリ2から1ライン分の画像データの読み出しが終了したことを示す1ライン処理終了信号を与える。このようにして1ライン処理終了検出部10より1ライン処理終了信号が送出されると、選択部9が加算部8より与えられる不要データ数Ls+Leを選択する。
【0025】
データ転送制御部11の構成及び動作について、図3を参照して説明する。データ転送制御部11は、データ転送部12の動作を制御するデータ入力制御部20及びデータ出力制御部25と、データ転送部12へ一度に入力されるデータ数(単位バイト)が格納される入力データ数格納部21と、選択部9より与えられる不要データ数より除去するデータ数を設定する飛ばしデータ数設定部22と、データ転送部12に入力される単位バイトのデータのうちデータ転送部12で処理されていないデータ数が設定される入力未処理数設定部23と、データ転送部12に入力される1ラインのデータのうちデータ転送部12で処理されていないデータ数が設定されるライン未処理数設定部24とを備える。
【0026】
データ入力制御部20は、まず、スタートパルスが与えられるとメモリ2からデータ転送部12へのデータ入力を開始する。そして、ビットマップ画像1ライン分の画像データがメモリ2より入力されたこと示す1ライン処理終了信号が、1ライン処理終了検出部10より与えられると、入力未処理数設定部24より与えられる入力未処理数と、ライン未処理数設定部25より与えられるライン未処理数との比較を行う。このとき、入力未処理数とライン未処理数が一致しないとき、次の単位バイト数のデータのデータ転送部12への入力を禁止する。
【0027】
よって、例えば、xバイト単位のデータがメモリ2よりデータ転送部12に入力されるとき、図4(a)のように、このxバイトのデータにa(aは、0<a<xを満たす値)バイトとなる1ライン終了時の画像データが含まれている場合、このxバイトのデータがデータ転送部12に入力された時点で、1ライン処理終了検出部10より1ライン処理終了信号が与えられる。このとき、ライン未処理数がaとなるとともに入力未処理数がxとなるため、入力未処理数とライン未処理数の関係がx>aとなり、ライン未処理数が小さくなる。よって、この入力されたaバイトとなる1ライン終了時の画像データを含むxバイトのデータの次にメモリ2より入力されるxバイトのデータの入力を禁止する。
【0028】
飛ばしデータ数設定部22は、選択部9より与えられる不要データ数と入力未処理数設定部23より与えられる入力未処理数に基づいて、飛ばしデータ数を設定する。そして、設定した飛ばしデータ数を、入力未処理数設定部23、ライン未処理数設定部24、及びデータ出力制御部25に送出する。まず、スタートパルスが与えられるとき、飛ばしデータ数設定部22には、選択部9で選択された開始不要データ数Lsが与えられる。そして、この開始不要データ数Lsを飛ばしデータ数に設定して、入力未処理数設定部23、ライン未処理数設定部24、及びデータ出力制御部25に送出する。
【0029】
又、1ライン終了時の画像データを含んだxバイトのデータがデータ転送部12に入力されて、1ライン処理終了検出部10より1ライン処理終了信号が与えられると、選択部9で選択された加算部8で生成された不要データ数Ls+Leが与えられる。そして、この不要データ数Ls+Leを飛ばしデータ数に設定して、入力未処理数設定部23、ライン未処理数設定部24、及びデータ出力制御部25に送出する。
【0030】
又、スタートパルス及び1ライン処理終了信号の何れの信号も与えられないとき、飛ばしデータ数設定部22内で設定されている飛ばしデータ数が入力未処理数設定部23で設定された入力未処理数(入力未処理数の設定については後述する)と比較される。このとき、飛ばしデータ数が入力未処理数以上となるとき、飛ばしデータ数から入力未処理数を減算した値を新たに飛ばしデータ数に設定して、入力未処理数設定部23、ライン未処理数設定部24、及びデータ出力制御部25に送出する。逆に、飛ばしデータ数が入力未処理数より小さいとき、0を飛ばしデータ数に設定して、入力未処理数設定部23、ライン未処理数設定部24、及びデータ出力制御部25に送出する。
【0031】
入力未処理数設定部23は、入力データ数格納部21より入力される入力データ数、飛ばしデータ数設定部22より入力される飛ばしデータ数、及びライン未処理数設定部24より入力されるライン未処理数に基づいて、入力未処理数を設定する。まず、入力データ数格納部21に格納されている入力データ数が送出され、入力未処理数として設定し、データ入力制御部20、飛ばしデータ数設定部22、ライン未処理数設定部24、及びデータ出力制御部25に送出する。
【0032】
その後、1ライン終了時の画像データを含んだxバイトのデータがデータ転送部12に入力されて、1ライン処理終了検出部10より1ライン処理終了信号が与えられると、設定されている入力未処理数からライン未処理数を減算した値を新たに入力未処理数として設定する。そして、データ入力制御部20、飛ばしデータ数設定部22、ライン未処理数設定部24、及びデータ出力制御部25に送出する。このとき、入力未処理数が0となる場合は、入力データ数を入力未処理数として設定する。
【0033】
ライン未処理数設定部24は、飛ばしデータ数設定部22より入力される飛ばしデータ数、及び入力未処理数設定部23より与えられる入力未処理数に基づいて、飛ばしデータ数を設定する。まず、スタートパルスが与えられると、ラインデータ数格納部5より送出されるラインデータ数Lをライン未処理数として設定し、データ入力制御部20及び入力未処理数設定部23に送出する。又、1ライン処理終了信号が与えられると、ラインデータ数格納部5より送出されるラインデータ数Lがライン未処理数として設定される。そして、データ入力制御部20及び入力未処理数設定部23に送出する。
【0034】
このスタートパルス及び1ライン処理終了信号が与えられないとき、入力未処理数設定部23で設定された入力未処理数数と飛ばしデータ数設定部22で設定された飛ばしデータ数とが比較される。そして、飛ばしデータ数が入力未処理数より小さいとき、ライン未処理数から入力未処理数設定部23より与えられる入力未処理数を減算した後飛ばしデータ数を加算した値をライン未処理数に設定して、データ入力制御部20及び入力未処理数設定部23に送出する。又、飛ばしデータ数が入力データ数以上であるとき、ライン未処理数の変更はない。
【0035】
よって、例えば、xバイト単位のデータがメモリ2よりデータ転送部12に入力されるとき、入力データ数格納部21に格納された入力データ数がxとなるので、まず、入力未処理数設定部23が入力未処理数をxに設定する。この入力未処理数xがデータ入力制御部20、飛ばしデータ数設定部22、ライン未処理数設定部24、及びデータ出力制御部25に送出される。
【0036】
今、図4(b)のように、開始不要データ数Lsがx−b(bは、0<b<xを満たす値)バイトとされると、スタートパルスが与えられたとき、選択部9で選択された開始不要データ数x−bが飛ばしデータ数設定部22に与えられる。又、このとき、ラインデータ数格納部5よりラインデータLがライン未処理数設定部24に与えられる。そして、飛ばしデータ設定部22で、飛ばしデータ数がx−bに設定され、ライン未処理数設定部24で、ライン未処理数がLに設定される。飛ばしデータ数x−bが、入力未処理数設定部23、ライン未処理数設定部24、及びデータ出力制御部25に送出されるとともに、ライン未処理数Lが、データ入力制御部20及び入力未処理数設定部23に送出される。
【0037】
このように、飛ばしデータ数、入力未処理数、及びライン未処理数がそれぞれ、x−b、x、Lに設定されて、飛ばしデータ数設定部22、入力未処理数設定部23、及びライン未処理数設定部24から送出される。次に、飛ばしデータ数設定部22では、入力未処理数xと飛ばしデータ数x−bとが比較される。今、x−b<xとなるため、、新たに、0が飛ばしデータ数として設定される。そして、この飛ばしデータ数0が入力未処理数設定部23、ライン未処理数設定部24、及びデータ出力制御部25に送出される。
【0038】
このとき、入力未処理数設定部23では、1ライン処理終了検出部10より1ライン終了信号が与えられないので、入力未処理数をxのままとし、データ入力制御部20、飛ばしデータ数設定部22、ライン未処理数設定部24、及びデータ出力制御部25に送出する。又、ライン未処理数設定部24では、飛ばしデータ数x−bと入力未処理数xとが比較される。今、x−b<xとなるため、L−x+(x−b)の演算が行われ、新たに、L−bがライン未処理数として設定される。そして、ライン未処理数L−bが、データ入力制御部20及び入力未処理数設定部23に送出される。
【0039】
このように設定された飛ばしデータ数0、入力未処理数x、及びライン未処理数L−bがそれぞれ送出されると、1ライン処理終了信号が与えられるまで、飛ばしデータ数設定部22で飛ばしデータ数が0と設定されるとともに、入力未処理数設定部23で入力未処理数がxに設定される。又、ライン未処理数設定部24では、飛ばしデータ数が入力未処理数より小さくなるため、データ転送部12にxバイトのデータが入力されるたびに、L−b−x、L−b−2x、…のように、x毎に小さくなるように設定される。
【0040】
そして、1ライン処理終了信号が与えられたとき、図4(a)のように、1ライン終了時のaバイトの画像データを含んだxバイトのデータがデータ転送部12に入力されるとき、入力未処理数及びライン未処理数がそれぞれ、x、aと設定されている。このとき、x>aとなり、ライン未処理数が入力未処理数より小さくなるため、入力未処理数設定部23において、x−aの演算が行われ、新たに、x−aが入力未処理数として設定される。そして、入力未処理数x−aが、データ入力制御部20、飛ばしデータ数設定部22、ライン未処理数設定部24、及びデータ出力制御部25に送出される。
【0041】
又、終了不要データ数Leが2x−aとされると、1ライン処理終了信号が与えられたとき、選択部9で選択された開始不要データ数3x−a−bが飛ばしデータ数設定部22に与えられる。又、このとき、ラインデータ数格納部5よりラインデータLがライン未処理数設定部24に与えられる。そして、飛ばしデータ設定部22で、飛ばしデータ数が3x−a−bに設定され、ライン未処理数設定部24で、ライン未処理数がLに設定される。飛ばしデータ数3x−a−bが、入力未処理数設定部23、ライン未処理数設定部24、及びデータ出力制御部25に送出されるとともに、ライン未処理数Lが、データ入力制御部20及び入力未処理数設定部23に送出される。
【0042】
このように、飛ばしデータ数、入力未処理数、及びライン未処理数がそれぞれ、3x−a−b、x−a、Lに設定されて、飛ばしデータ数設定部22、入力未処理数設定部23、及びライン未処理数設定部24から送出される。次に、飛ばしデータ数設定部22では、入力未処理数x−aと飛ばしデータ数3x−a−bとが比較される。今、3x−a−b>x−aとなるため、(3x−a−b)−(x−a)の演算が行われ、新たに、2x−bが飛ばしデータ数として設定される。そして、この飛ばしデータ数2x−bが入力未処理数設定部23、ライン未処理数設定部24、及びデータ出力制御部25に送出される。
【0043】
このとき、入力未処理数設定部23では、1ライン処理終了検出部10より1ライン終了信号が与えられないので、データ入力格納部21に格納された入力データ数xを入力未処理数として設定する。そして、データ入力制御部20、飛ばしデータ数設定部22、ライン未処理数設定部24、及びデータ出力制御部25に送出する。又、ライン未処理数設定部24では、飛ばしデータ数3x−a−bと入力未処理数x−aとが比較される。今、3x−a−b>x−aとなるため、ライン未処理数をLのままとし、データ入力制御部20及び入力未処理数設定部23に送出する。
【0044】
このように、飛ばしデータ数、入力未処理数、及びライン未処理数がそれぞれ、2x−b、x、Lに設定されて、飛ばしデータ数設定部22、入力未処理数設定部23、及びライン未処理数設定部24から送出される。次に、飛ばしデータ数設定部22では、入力未処理数xと飛ばしデータ数2x−bとが比較される。今、2x−b>xとなるため、(2x−b)−xの演算が行われ、新たに、x−bが飛ばしデータ数として設定される。そして、この飛ばしデータ数x−bが入力未処理数設定部23、ライン未処理数設定部24、及びデータ出力制御部25に送出される。
【0045】
このとき、入力未処理数設定部23では、1ライン処理終了検出部10より1ライン終了信号が与えられないので、入力未処理数をxのままとする。そして、データ入力制御部20、飛ばしデータ数設定部22、ライン未処理数設定部24、及びデータ出力制御部25に送出する。又、ライン未処理数設定部24では、飛ばしデータ数2x−bと入力未処理数xとが比較される。今、2x−b>xとなるため、ライン未処理数をLのままとし、データ入力制御部20及び入力未処理数設定部23に送出する。
【0046】
このように、飛ばしデータ数、入力未処理数、及びライン未処理数がそれぞれ、x−b、x、Lに設定されると、1ライン処理終了信号が与えられるまで、上述したスタートパルスが与えられた以降の動作が再び行われる。そして、ユーザーによって指定されたビットマップ画像の画像データが全てデータ転送部12より出力されるまで、1ライン処理終了信号が与えられる毎に、上述の動作を繰り返す。
【0047】
データ出力制御部25は、まず、スタートパルスが与えられるとデータ転送部12からデータ処理部13へのデータ出力を開始させる。そして、ビットマップ画像1ライン分の画像データがメモリ2より入力されたこと示す1ライン処理終了信号が1ライン処理終了検出部10より与えられると、入力未処理数が入力データ数より小さくなるとき、データ転送部12内に入力されたデータを、二度、データ処理部13に出力するように、データ転送部12を出力制御する。
【0048】
よって、例えば、xバイト単位のデータがメモリ2よりデータ転送部12に入力されるとき、図4(a)のように、このxバイトのデータにaバイトとなる1ライン終了時の画像データが含まれている場合、このxバイトのデータがデータ転送部12に入力された時点で、1ライン処理終了検出部10より1ライン処理終了信号が与えられる。そして、入力未処理数設定部23よりx−aとなる入力未処理数が与えられ、入力データ数格納部21に格納された入力データ数xより小さくなる。よって、データ転送部12に入力されたaバイトとなる1ライン終了時の画像データを含むxバイトのデータが、二度、データ処理部13に出力されるように、データ転送部12を出力制御する。
【0049】
このように構成されるグラフィックLSI3の動作について、図面を参照して説明する。今、図5のようにメモリ2内に画像データが格納されるとともに、データがメモリ2でxバイト単位毎に処理されて格納されているものとする。又、1ラインデータ数がL=n×x+a+b、開始不要データ数がLs=x−b、終了不要データ数がLe=m×x−aであるものとする。このような画像データを有するデータを、メモリ2よりグラフィックLSI3に入力するときの動作を、図6のタイムチャートを参照して説明する。
【0050】
このとき、まず、CPU1より、ラインデータ数L、開始不要データ数Ls、終了不要データ数Le、及び入力データ数xがそれぞれ、ラインデータ数格納部5、開始不要データ数格納部6、終了不要データ数格納部7、及び入力データ数格納部21に与えられる。そして、加算部8において、開始不要データ数格納部6に格納された開始不要データ数Lsと終了不要データ数格納部7に格納された終了不要データ数Leとが加算されて不要データ数Ls+Le=(m+1)×x−a−bが生成される。又、入力データ数格納部21より入力未処理数設定部23に入力データ数xが与えられて、入力未処理数xが設定される。
【0051】
その後、スタートパルスが入力されると、選択部9では、開始不要データ数格納部6より与えられる開始不要データ数x−bを選択して、データ転送制御部11に与える。又、データ転送制御部11では、データ入力制御部20が動作を行い、xバイトのデータがデータ転送部12に入力される。このとき、飛ばしデータ数設定部22が選択部9より与えられる開始不要データ数x−bを飛ばしデータ数として設定するとともに、ライン未処理数設定部24がラインデータ数格納部5より与えられるラインデータ数n×x+a+bをライン未処理数として設定する。
【0052】
よって、スタートパルスが与えられると、bバイトの画像データを有するxバイトのデータが入力されるとともに、入力未処理数、ライン未処理数、及び飛ばしデータ数がそれぞれ、x、n×x+a+b、x−bに設定される。又、このとき、入力未処理数x及びライン未処理数n×x+a+bが、データ処理部13に出力される。
【0053】
このように、入力未処理数x、ライン未処理数n×x+a+b、及び飛ばしデータ数x−bがそれぞれ設定されると、データ転送部12よりbバイトの画像データを有するxバイトのデータがデータ処理部13に出力されるように、スタートパルスが与えられたデータ出力制御部25によって、データ転送部12が出力制御される。このとき、データ入力制御部20によってデータ転送部12が入力制御されて、全て画像データとなる次のxバイトのデータがデータ処理部13に入力される。
【0054】
そして、次のxバイトの画像データがデータ転送部12に入力されると、飛ばしデータ数x−bが入力未処理数xより小さいため、飛ばしデータ数設定部22において飛ばしデータ数が0とされるとともに、ライン未処理数設定部24においてライン未処理数が(n×x+a+b)−x+(x−b)=n×x+aとされる。その後、入力未処理数設定部23及びライン未処理数設定部24よりデータ処理部13に、入力未処理数x及びライン未処理数n×x+aが出力される。
【0055】
よって、データ処理部13では、bバイトの画像データを有するxバイトのデータが入力される以前に入力された入力未処理数x及びライン未処理数n×x+a+bと、bバイトの画像データを有するxバイトのデータと同時に入力される入力未処理数x及びライン未処理数n×x+aとを比較する。そして、入力未処理数が等しいことが確認されると、比較するライン未処理数の差がbとなるため、データ転送部12より入力されたxバイトのデータより、x−bバイトの不要データを削除して、このxバイトのデータ内に含まれるbバイトの画像データを選択し、上述した各種画像データ処理を施す。
【0056】
そして、次のxバイトの画像データがデータ転送部12に入力されると、データ転送部12内の前のxバイトの画像データがデータ転送部12より出力される。このとき、飛ばしデータ数0が入力未処理数xより小さいため、飛ばしデータ数設定部22において飛ばしデータ数が0のままとされるとともに、ライン未処理数設定部24においてライン未処理数が(n×x+a)−x+0=(n−1)×x+aとされる。そして、入力未処理数設定部23及びライン未処理数設定部24よりデータ処理部13に、入力未処理数x及びライン未処理数(n−1)×x+aが出力される。
【0057】
よって、データ処理部13では、入力未処理数x及びライン未処理数n×x+aと入力未処理数x及びライン未処理数(n−1)×x+aとを比較する。そして、入力未処理数が等しいことが確認されると、比較するライン未処理数の差がxとなるため、データ転送部12より入力されたxバイトのデータが全て画像データであることを確認し、このxバイトの画像データに対して上述した各種画像データ処理を施す。
【0058】
このようにして、xバイトの画像データが入力されるたびに、ライン未処理数設定部24では、(n−2)×x+a、(n−3)×x+a、…、x+aのように、その値がx毎減算されたライン未処理数が設定され、入力未処理数設定部23で設定される入力未処理数xとともにデータ処理部13に出力される。よって、このとき、データ処理部13では、比較する入力未処理数が等しくなるとともに比較するライン未処理数の差がxとなるため、データ転送部12より出力されるxバイトのデータが全て画像データであることが確認され、このxバイトの画像データに対して上述した各種画像データ処理が施される。又、飛ばしデータ数設定部22では、入力未処理数xが飛ばしデータ数0より大きいので、飛ばしデータ数が0に設定される。
【0059】
そして、aバイトの画像データを含んだxバイトのデータがデータ転送部12に入力されて、ビットマップ画像1ライン目の画像データの入力が終了するとき、飛ばしデータ数、入力未処理数、及びライン未処理数がそれぞれ、0、x、aとなる。このaバイトの画像データを含んだxバイトのデータが入力される前にメモリ2より入力されたxバイトの画像データがデータ転送部12より出力されるとき、同時に、データ転送制御部11より入力未処理数x及びライン未処理数aが出力される。よって、データ処理部13は、データ転送部12より入力されるxバイトのデータが全て画像データとであると認識し、xバイトの画像データに対して各種画像データ処理を施す。
【0060】
そして、このaバイトの画像データを含んだxバイトのデータがデータ転送部12に入力される間に、データ転送部12から出力される画像データ数がL−x=(n−1)×x+a+bに達すると、ビットマップ画像1ライン目の画像データの入力が終了され、1ライン処理終了検出部10より1ライン処理終了信号が選択部9及びデータ転送制御部11に与えられる。このとき、選択部9では、加算部8より与えられる不要データ数(m+1)×x−a−bを選択して、データ転送制御部11に与える。
【0061】
このとき、飛ばしデータ数設定部22が選択部9より与えられる不要データ数(m+1)×x−a−bを飛ばしデータ数として設定するとともに、ライン未処理数設定部24がラインデータ数格納部5より与えられるラインデータ数n×x+a+bをライン未処理数として設定する。又、入力未処理数設定部23において、入力未処理数xがライン未処理数aによって減算され、x−aが入力未処理数として設定される。
【0062】
このように、入力未処理数x−a、ライン未処理数n×x+a+b、及び飛ばしデータ数(m+1)×x−a−bがそれぞれ設定されると、データ転送部12よりaバイトの画像データを有するxバイトのデータがデータ処理部13に二度出力されるように、1ライン処理終了信号が与えられたデータ出力制御部25によって、データ転送部12が出力制御される。このとき、データ入力制御部20において、入力未処理数xとライン未処理数aとが比較される。今、x>aとなるため、データ転送部12への入力が禁止されるように制御される。
【0063】
よって、データ転送部12へのデータ入力が禁止されると、入力未処理数、ライン未処理数、及び飛ばしデータ数がそれぞれ、x−a、n×x+a+b、(m+1)×x−a−bに設定される。又、このとき、入力未処理数x−a及びライン未処理数(m+1)×x−a−bが、aバイトの画像データを有するxバイトのデータとともにデータ処理部13に出力される。
【0064】
よって、データ処理部13では、ビットマップ画像1ライン目の最後の画像データとなるaバイトの画像データを有するxバイトのデータが入力される以前に入力された入力未処理数x及びライン未処理数aと、aバイトの画像データを有するxバイトのデータと同時に入力される入力未処理数x−a及びライン未処理数n×x+a+bとを比較する。そして、比較する入力未処理数の差がaとなるため、x−aバイトの不要データを削除して、このxバイトのデータ内に含まれるaバイトの画像データを選択し、上述した各種画像データ処理を施す。
【0065】
そして、データ入力制御部20によってデータ転送部12へのデータ入力が再開されると、データ出力制御部25が、aバイトの画像データを有するxバイトのデータを再びデータ処理部13に出力するように、データ転送部12のデータ出力を制御する。このように、データ転送部12より再度aバイトの画像データを有するxバイトのデータを送出しようとするとき、入力未処理数設定部23において、入力未処理数がxに再設定される
【0066】
このとき、入力未処理数x−aが飛ばしデータ数(m+1)×x−a−bより小さいため、飛ばしデータ数設定部22において、飛ばしデータ数が、飛ばしデータ数(m+1)×x−a−bより入力未処理数x−aが減算された値m×x−bとされるとともに、ライン未処理数設定部24において、ライン未処理数はn×x+a+bのままとされる。そして、データ処理部13に対して、データ転送部12よりaバイトの画像データを有するxバイトのデータが再出力されるとともに、データ転送制御部11より入力未処理数x及びライン未処理数n×x+a+bが出力される。又、このようにaバイトの画像データを有するxバイトのデータがデータ転送部12より再出力されているとき、全て不要データとなるxバイトのデータがデータ転送部12に入力される。
【0067】
このとき、データ処理部13では、入力未処理数x−a及びライン未処理数n×x+a+bと入力未処理数x及びライン未処理数n×x+a+bとを比較する。そして、入力未処理数が差aの分だけ小さくなっているため、xバイトのデータの最初のaバイトのデータについては既に処理されたことが確認されるとともに、ライン未処理数が等しいため、残りのx−aバイトのデータも不要データであることが確認される。よって、このとき、入力されたデータ全てが不要データであることが確認され、各種画像データ処理が施されない。
【0068】
そして、全て不要データとなる次のxバイトのデータがデータ転送部12に入力されると、データ転送部12内の前のxバイトの不要データがデータ転送部12より出力される。このとき、入力未処理数xが飛ばしデータ数m×x−bより小さいため、飛ばしデータ数設定部22において、飛ばしデータ数が、飛ばしデータ数m×x−bより入力未処理数xが減算された値(m−1)×x−bとされるとともに、ライン未処理数設定部24において、ライン未処理数はn×x+a+bのままとされる。そして、入力未処理数設定部23及びライン未処理数設定部24よりデータ処理部13に、入力未処理数x及びライン未処理数n×x+a+bが出力される。
【0069】
よって、データ処理部13では、データが入力される以前に入力された入力未処理数x及びライン未処理数n×x+a+bと、データと同時に入力される入力未処理数x及びライン未処理数n×x+a+bとを比較する。そして、入力未処理数及びライン未処理数がどちらも等しいため、xバイトのデータ全てが不要データであることが確認され、各種画像データ処理が施されない。
【0070】
このようにして、xバイトの不要データが入力されるたびに、飛ばしデータ数設定部22では、(m−2)×x−b、(m−3)×x−b、…、2x−bのように、その値がx毎減算された飛ばしデータ数が設定される。又、このとき、データ処理部13では、比較する入力未処理数及びライン未処理数がそれぞれ常にx及びn×x+a+bとなり等しいため、データ転送部12より出力されるxバイトのデータが全て不要データであることが確認され、上述した各種画像データ処理が施されない。
【0071】
そして、bバイトの画像データを含んだxバイトのデータがデータ転送部12に入力されて、ビットマップ画像2ライン目の画像データの入力が開始するとき、飛ばしデータ数、入力未処理数、及びライン未処理数がそれぞれ、x−b、x、n×x+a+bとなる。このbバイトの画像データを含んだxバイトのデータが入力される前にメモリ2より入力されたxバイトの不要データがデータ転送部12より出力されるときも同様に、データ転送制御部11より入力未処理数x及びライン未処理数n×x+a+bが出力される。よって、データ処理部13は、データ転送部12より入力されるxバイトのデータが全て不要データとであると認識し、各種画像データ処理が施されない。
【0072】
その後、1ライン目と同様、全て画像データとなるxバイトのデータがメモリ2からデータ転送部12に入力されるとともに、bバイトの画像データを有するxバイトのデータがデータ転送部12からデータ処理部13に出力される。このとき、1ライン目と同様、飛ばしデータ数、入力未処理数、及びライン未処理数がそれぞれ、0、x、n×x+aと設定されるとともに、入力未処理数0及びライン未処理数n×x+aがデータ処理部13に出力される。それ以降の動作については、1ライン処理終了信号が与えられるまで、1ライン目と同様である。
【0073】
このような動作が最終ラインの画像データがデータ処理部13で処理されるまで、ライン毎に繰り返し行われることによって、メモリ2より与えられる不要データを含むデータから不要データを除いて、必要となる画像データのみを選択して各種画像データ処理を施すことができる。
【0074】
尚、本実施形態において、データ転送部からデータ処理部に対して出力するxバイトのデータが不要データばかりで構成されるときも、データ転送制御部より出力される入力未処理数及びライン未処理数とともにデータ処理部に出力するようにしたが、不要データばかりで構成されるxバイトのデータの出力をデータ出力制御部で禁止するようにしても構わない。このとき、データ出力制御部で飛ばしデータ数が入力未処理数より大きくなることが確認されると、データ転送制御部より出力される入力未処理数及びライン未処理数の出力の禁止を行うとともに、このときのデータ転送部に入力されたデータの出力を禁止すればよい。
【0075】
【発明の効果】
本発明によると、画像データ処理装置内で、指定された画像データ以外の不要データを除去することができるので、指定された画像データが格納されたアドレス領域のデータをメモリから連続的に画像データ処理装置に送出することができる。よって、従来のように、CPUなどで一旦、必要な画像データだけを選択して並び替えた後に画像データ処理装置に送出するための処理動作を省くことができ、DMA転送に対応させて、その処理時間を短くすることができる。
【図面の簡単な説明】
【図1】本発明のグラフィックLSIとメモリとの関係を示すブロック図。
【図2】本発明のグラフィックLSIの内部構成を示すブロック図。
【図3】図2のグラフィックLSIに設けられたデータ転送制御部の内部構成を示すブロック図。
【図4】メモリ内に格納されたデータの様子を示す図。
【図5】メモリ内に格納されたデータの様子を示す図。
【図6】本発明のグラフィックLSIの動作を示すタイムチャート。
【図7】メモリ内に格納されたデータの様子を示す図。
【符号の説明】
1 CPU
2 メモリ
3 グラフィックLSI
4 バス回線
5 ラインデータ数格納部
6 開始不要データ数格納部
7 終了不要データ数格納部
8 加算部
9 選択部
10 1ライン処理終了検出部
11 データ転送制御部
12 データ転送部
13 データ処理部
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a graphic LSI (Large Scale Integrated Circuit) that reads out and processes image data necessary for reproducing a selected image from image data stored in a memory, and outputs the processed image data to a subsequent device such as a display. This relates to an image data processing apparatus represented by
[0002]
[Prior art]
A graphic LSI that processes image data to reproduce an image on a display device such as a display transfers the image data of a bitmap image specified by the user from the memory, thereby displaying the image data of the bitmap image to be displayed. Is generated and output. At this time, only the image data of the bitmap image processed by the graphic LSI is selected from the data stored in the memory, and only the image data of the bitmap image to be processed is sequentially transferred to the graphic LSI.
[0003]
In recent years, with the development of CPU (Centaral Processing Unit) and hardware technology, the number of bytes of data processed in each circuit device has increased. Therefore, the image data stored in the memory can be collectively transferred every 4 bytes from the CPU to the graphic LSI, and the processing capability and transfer capability are improved.
[0004]
Therefore, as shown in FIG. 7, when data A to P is stored in the memory every 4 bytes and the image data of the bitmap image to be reproduced is A to G and I to O, the CPU once Thus, after the data A to P are read from the memory, the image data A to G and I to O excluding the data H and P are selected. The read image data is (A, B, C, D), (E, F, G, I), (J, K, L, M), (N, O, *, *) Are transferred to the graphic LSI in this order. In this case, * is invalid data.
[0005]
[Problems to be solved by the invention]
Thus, conventionally, it is necessary to shift image data so that necessary image data is selected by the CPU from the data stored in the memory and sequentially transferred to the graphic LSI. Therefore, it takes a processing time to generate image data to be transferred to the graphic LSI by the CPU.
[0006]
Further, in the case of DMA (Direct Memory Access) transfer in which image data stored in the memory is directly transferred to the graphic LSI, when the data is stored in the memory as shown in FIG. 7, the image data is transferred from the memory to the graphic LSI. Therefore, (A, B, C, D), (E, F, G, H), (I, J, K, L), (M, N, O, P) Sent in order. Therefore, data H and P that are not processed by the graphic LSI are also transferred. As described above, in the DMA transfer, a transfer system that transfers a plurality of data except for the unnecessary data as described above cannot be performed, and all the data stored in the memory is sequentially transferred.
[0007]
In view of such problems, the present invention removes unnecessary data and processes only necessary image data when data is sequentially transferred from the memory for each of a plurality of data without processing by the CPU. An object of the present invention is to provide an image data processing apparatus capable of
[0008]
[Means for Solving the Problems]
In order to achieve the above object, the image data processing apparatus according to claim 1, wherein data stored in a memory for continuously storing image data representing the image for each line of the image is input for each predetermined unit. In the image data processing apparatus that performs image data processing on the image data included in the input data, unnecessary data is removed from the data given from the memory, and necessary image data is selected, A data processing unit that performs image data processing, a first unnecessary data number setting unit that sets the number of unnecessary data included in the predetermined unit of data input first, the last image data of one line, and the next Set by either the second unnecessary data number setting unit for setting the number of unnecessary data existing between the line first image data and the first or second unnecessary data number setting unit. A selection unit for selecting the number of unnecessary data, and when it is confirmed that image data for one line of image has been sent to the data processing unit, a line processing end signal is sent to the selection unit and the data processing unit. A line processing end detection unit to be sent, and when the input of data of a predetermined unit including image data is started from the memory, the selection unit sets the unnecessary unnecessary data set by the first unnecessary data number setting unit. When the number of data is given to the data processing unit and a line processing end signal is generated from the line processing end detection unit, the number of unnecessary data set by the second unnecessary data number setting unit by the selection unit is displayed. The number of data is given to the data processing unit.
[0009]
In such an image data processing apparatus, data stored in an address area designated by a CPU or the like is continuously input from a memory. At this time, the image data processing apparatus removes unnecessary data other than the required image data based on the number of unnecessary data selected by the selection unit, and then performs various image data processing on the required image data. Apply. Therefore, there is no need for a transfer means for processing the data stored in the memory and transmitting only the necessary image data, and the data is directly transferred from the memory every predetermined number of units (unit bytes) according to the capacity of the bus line. Entered.
[0010]
The image processing device according to claim 2 is the image data processing device according to claim 1, wherein the data processing unit includes an image data processing unit that performs image data processing, and the predetermined unit input from the memory. Sending data to the image data processing unit and generating an image data position specifying signal for specifying the position of the image data in the predetermined unit of data based on the number of unnecessary data selected by the selection unit An image data position specifying unit to be sent to the image data processing unit, and when the input of the predetermined unit of data including image data is started from the memory, the selection unit starts the first unnecessary data. The number of unnecessary data set in the number setting unit is given to the image data position specifying unit, and the image data in the predetermined unit data at the start of input An image indicating that all data input from the memory is image data until an image data position specifying signal for specifying a position is generated and a line processing end signal is generated from the line processing end detection unit. When a data position specifying signal is generated and a line processing end signal is generated from the line processing end detection unit, the number of unnecessary data set in the second unnecessary data number setting unit by the selection unit is the image data position. An image data position specifying signal is generated which is supplied to the specifying unit and specifies the position of the image data at the end of one line and specifies the position of the image data at the start of the next line.
[0011]
In such an image data processing apparatus, as described in claim 3, the unprocessed input number indicating the number of data sent from the image data position specifying unit to the image data processing unit. And the number of unprocessed lines indicating the number of pieces of image data that have not been sent to the image data processing unit out of one line of image data. At this time, the position of the image data in the input data can be recognized by the image data processing unit based on the change in the number of unprocessed inputs and the number of unprocessed lines input together with the data to the image data processing unit.
[0012]
In addition, as described in claim 4, the image data position specifying unit includes: an input unprocessed number setting unit that sets the input unprocessed number; and a line unprocessed number setting unit that sets the line unprocessed number; A skip data number setting unit for setting a skip data number indicating the number of unnecessary data in the data sent to the image data processing unit, and a data number of unnecessary data selected by the selection unit; When the input of the predetermined unit data including image data is started from the memory, the number of unnecessary data set in the first unnecessary data number setting unit by the selection unit is the number of skipped data. Given to the setting unit and set as the skip data number in the skip data number setting unit, the number of image data of one line in the unprocessed line number When the line processing end signal is generated from the line processing end detection unit, the number of unnecessary data set by the second unnecessary data number setting unit by the selection unit is set as the skip data number setting unit. Is set as the skip data number in the skip data number setting unit, and the data number of one line of image data is set as the line unprocessed number in the line unprocessed number, and the skip data number setting unit The set number of skip data is set by the number of input unprocessed When the number of input unprocessed number is exceeded, A value obtained by subtracting the input unprocessed number from the skipped data number is newly set as the skipped data number, and the skipped data number set by the skipped data number setting unit is set as the input unprocessed number. When the input raw count is smaller than When the skip data number is set to 0 and the skip data number set by the skip data number setting unit is smaller than the input unprocessed number set by the input unprocessed number, the line unprocessed number is set. A value obtained by adding the skipped data number after subtracting the input unprocessed number from the line unprocessed number may be newly set as the line unprocessed number.
[0013]
At this time, every time data is input from the image data position specifying unit to the image data processing unit, the input unprocessed number and the line unprocessed number for specifying the position of the image data in the input data are set the previous time. Based on the input unprocessed number, line unprocessed number, and skip data number, the image data position specifying unit sets the number. The set number of unprocessed inputs and number of unprocessed lines are given to the image data processing unit together with the input data every time data is input to the image data processing unit from the image data position specifying unit. Therefore, the image data processing unit selects only image data and performs various image data processing.
[0014]
DETAILED DESCRIPTION OF THE INVENTION
Embodiments of the present invention will be described with reference to the drawings. FIG. 1 is a block diagram showing the relationship around a graphic LSI corresponding to the image data processing apparatus of the present invention. FIG. 2 is a block diagram showing an internal configuration in the graphic LSI. FIG. 3 is a block diagram showing an internal configuration of a data transfer control unit provided in the graphic LSI.
[0015]
As shown in FIG. 1, the CPU 1, the memory 2, and the graphic LSI 3 exchange data via the bus line 4. At this time, an address of data to be transferred to the graphic LSI 3 is designated from the CPU 1 to the memory 2, and data at the designated address is continuously transferred to the graphic LSI 3 for each unit byte stored in the memory 2. Is done. As described above, in FIG. 1, data is DMA-transferred from the memory 2 to the graphic LSI 3. Therefore, not only the image data of the selected bitmap image but also unnecessary data stored together with this image data is transferred to the graphic LSI 3.
[0016]
Various data to be described later such as the number of bytes per line of the image data of the bitmap image is sent from the CPU 1 to the graphic LSI 3 through the bus line 4. Accordingly, the graphic LSI 3 removes unnecessary data from the data transferred from the memory 2 for each unit byte, selects only the image data of the selected bitmap image, and then processes and outputs this image data. be able to.
[0017]
The graphic LSI 3 will be described with reference to FIGS. The graphic LSI 3 shown in FIG. 2 includes a line data number storage unit 5 that stores the number of image data (L bytes) for one line of the bitmap image, and the first image data among the image data for one line of the bitmap image. A start unnecessary data number storage 6 for storing the number of unnecessary data (Ls bytes) read from the memory 2 before the image data, and the memory image 2 after the last image data of the image data for one line of the bitmap image. And an unnecessary data amount storage unit 7 for storing the number of unnecessary data items (Le bytes).
[0018]
Hereinafter, the numbers of data stored in the line data number storage unit 5, the start unnecessary data number storage unit 6, and the end unnecessary data number storage unit 7 are respectively referred to as the line data number, the start unnecessary data number, and the end unnecessary data number. Call it. The number of unnecessary start data and the number of unnecessary end data will be described later. The line data number L, the start unnecessary data number Ls, and the end unnecessary data number Le are sent from the CPU 1 to the line data number storage unit 5, the start unnecessary data number storage unit 6, and the end unnecessary data number storage unit 7, respectively. Is done.
[0019]
In addition, the graphic LSI 3 selects one of the addition unit 8 that adds the start unnecessary data number Ls and the end unnecessary data number Le, and the start unnecessary data number Ls and the unnecessary data number Ls + Le added by the addition unit 8. The selection unit 9 to send to the data transfer control unit 11 and the number of processed data are counted, and then the data for one line of the bitmap image is processed with the unit byte data input from the memory 2. 1 line processing end detection unit 10 for detecting, data transfer control unit 11 for controlling the operation of data transfer unit 12, data transfer unit 12 for transferring data sent from memory 2, and data transfer unit 12 And a data processing unit 13 that performs image data processing such as interpolation processing and edge enhancement processing on the image data.
[0020]
In the graphic LSI 3 having such a configuration, first, the CPU 2 is given the line data number L, the start unnecessary data number Ls, and the end unnecessary data number Le, and the line data number storage unit 5 and the start unnecessary data number storage unit, respectively. 6 and the end unnecessary data number storage unit 7. Then, the start unnecessary data number Ls stored in the start unnecessary data number storage unit 6 is given to the addition unit 8 and the selection unit 9. Further, the end unnecessary data number Le stored in the end unnecessary data number storage unit 7 is given to the adding unit 8. Further, the line data number L stored in the line data number storage unit 5 is given to the one-line processing end detection unit 10.
[0021]
Next, when data transfer is started every x bytes from the memory 2 and a start pulse is given to the selection unit 9 and the data transfer control unit 11, the selection unit 9 selects the start unnecessary data number Ls. To the data transfer control unit 11. Further, the data transfer control unit 11 starts the operation and the data transfer unit 12 is controlled to start the operation. The data transfer unit 12 is controlled by the data transfer control unit 11 to input data from the memory 2 and output to the data processing unit 13.
[0022]
Further, the data transfer control unit 11 gives a signal representing the number of input unprocessed and line unprocessed, which will be described later. Then, the data processing unit 13 selects the image data of the designated bitmap image from the data supplied from the data transfer unit 12 based on the input unprocessed number and the line unprocessed number supplied from the data transfer control unit 11. Then, image data processing is performed. The detailed operation of the data transfer control unit 11 will be described later.
[0023]
The one-line processing end detection unit 10 is constituted by a counter, for example, and counts the number of data (bytes) of image data sent to the data processing unit 13 by the data transfer unit 12. When it is detected that the counted number of data has reached the number of data L−x, the next time x bytes of data are sent from the data transfer unit 12 to the data processing unit 13, one line of the bitmap image It is confirmed that all the image data for the minute is output to the data processing unit 13. Therefore, at this time, the image data at the end of one line is input to the data transfer unit 12 from the memory 2.
[0024]
Then, the one-line processing end detection unit 10 gives the selection unit 9 and the data transfer control unit 11 a one-line processing end signal indicating that reading of image data for one line from the memory 2 has been completed. When the 1-line processing end signal is sent from the 1-line processing end detection unit 10 in this way, the selection unit 9 selects the number of unnecessary data Ls + Le given from the addition unit 8.
[0025]
The configuration and operation of the data transfer control unit 11 will be described with reference to FIG. The data transfer control unit 11 stores the data input control unit 20 and the data output control unit 25 that control the operation of the data transfer unit 12 and the number of data (unit bytes) input to the data transfer unit 12 at a time. A data number storage unit 21, a skip data number setting unit 22 for setting the number of data to be removed from the number of unnecessary data given from the selection unit 9, and the data transfer unit 12 among unit byte data input to the data transfer unit 12. The unprocessed input number setting unit 23 in which the number of unprocessed data is set, and the line in which the number of data not processed in the data transfer unit 12 among the data of one line input to the data transfer unit 12 is set. And an unprocessed number setting unit 24.
[0026]
First, when a start pulse is given, the data input control unit 20 starts data input from the memory 2 to the data transfer unit 12. When the 1-line processing end signal indicating that the image data for one line of the bitmap image has been input from the memory 2 is provided from the 1-line processing end detection unit 10, the input is provided from the input unprocessed number setting unit 24. The unprocessed number is compared with the line unprocessed number given from the line unprocessed number setting unit 25. At this time, when the input unprocessed number and the line unprocessed number do not match, the input of the data of the next unit byte number to the data transfer unit 12 is prohibited.
[0027]
Therefore, for example, when data in units of x bytes is input from the memory 2 to the data transfer unit 12, as shown in FIG. 4A, the data of x bytes satisfies a (a satisfies 0 <a <x. Value) When image data at the end of one line, which is a byte, is included, when the x-byte data is input to the data transfer unit 12, the one-line processing end detection unit 10 outputs a one-line processing end signal. Given. At this time, since the line unprocessed number is a and the input unprocessed number is x, the relationship between the input unprocessed number and the line unprocessed number becomes x> a, and the line unprocessed number becomes small. Therefore, input of x-byte data input from the memory 2 next to x-byte data including image data at the end of one line, which is the input a bytes, is prohibited.
[0028]
The skip data number setting unit 22 sets the skip data number based on the number of unnecessary data given from the selection unit 9 and the input unprocessed number given from the input unprocessed number set unit 23. Then, the set number of skipped data is sent to the input unprocessed number setting unit 23, the line unprocessed number setting unit 24, and the data output control unit 25. First, when the start pulse is given, the skip data number setting unit 22 is given the start unnecessary data number Ls selected by the selection unit 9. Then, the start unnecessary data number Ls is skipped, set to the data number, and sent to the input unprocessed number setting unit 23, the line unprocessed number setting unit 24, and the data output control unit 25.
[0029]
Further, when x-byte data including image data at the end of one line is input to the data transfer unit 12 and a one-line processing end signal is given from the one-line processing end detection unit 10, the selection unit 9 selects the data. The number of unnecessary data Ls + Le generated by the adding unit 8 is given. Then, the unnecessary data number Ls + Le is skipped and set as the data number, which is sent to the input unprocessed number setting unit 23, the line unprocessed number setting unit 24, and the data output control unit 25.
[0030]
Further, when neither the start pulse nor the one-line processing end signal is given, the number of skip data set in the skip data number setting unit 22 is the input unprocessed set by the input unprocessed number setting unit 23 It is compared with the number (the setting of the input unprocessed number will be described later). At this time, when the number of skipped data is equal to or greater than the number of input unprocessed, a value obtained by subtracting the number of input unprocessed from the number of skipped data is newly set as the number of skipped data, and the input unprocessed number setting unit 23, line unprocessed The data is sent to the number setting unit 24 and the data output control unit 25. Conversely, when the number of skipped data is smaller than the input unprocessed number, 0 is set as the skipped data number and sent to the input unprocessed number setting unit 23, the line unprocessed number setting unit 24, and the data output control unit 25. .
[0031]
The input unprocessed number setting unit 23 includes the number of input data input from the input data number storage unit 21, the number of skip data input from the skip data number setting unit 22, and Line unprocessed number setting unit 24 The number of unprocessed inputs is set based on the number of unprocessed lines input. First, the number of input data stored in the input data number storage unit 21 is sent out and set as an input unprocessed number, and the data input control unit 20, skip data number setting unit 22, Line unprocessed number setting unit 24 , And the data output control unit 25.
[0032]
Thereafter, when x-byte data including the image data at the end of one line is input to the data transfer unit 12 and a one-line processing end signal is given from the one-line processing end detection unit 10, the set input unset A value obtained by subtracting the number of unprocessed lines from the number of processes is newly set as the number of unprocessed inputs. And the data input control part 20, the skip data number setting part 22, Line unprocessed number setting unit 24 , And the data output control unit 25. At this time, if the number of unprocessed inputs is 0, the number of input data is set as the number of unprocessed inputs.
[0033]
The line unprocessed number setting unit 24 sets the number of skipped data based on the number of skipped data input from the skipped data number setting unit 22 and the input unprocessed number given from the input unprocessed number setter 23. First, when a start pulse is given, the line data number L sent from the line data number storage unit 5 is set as the line unprocessed number and sent to the data input control unit 20 and the input unprocessed number setting unit 23. When a one-line processing end signal is given, the line data number L sent from the line data number storage unit 5 is set as the number of unprocessed lines. Then, the data is sent to the data input control unit 20 and the input unprocessed number setting unit 23.
[0034]
When the start pulse and the one-line processing end signal are not given, the number of input unprocessed numbers set by the input unprocessed number setting unit 23 is compared with the number of skipped data set by the skipped data number setting unit 22. . When the skipped data number is smaller than the input unprocessed number, the value obtained by subtracting the input unprocessed number given from the input unprocessed number setting unit 23 from the line unprocessed number and adding the skipped data number is set as the line unprocessed number. The data is set and sent to the data input control unit 20 and the input unprocessed number setting unit 23. Further, when the number of skipped data is greater than or equal to the number of input data, there is no change in the number of unprocessed lines.
[0035]
Therefore, for example, when data in units of x bytes is input from the memory 2 to the data transfer unit 12, the number of input data stored in the input data number storage unit 21 is x. 23 sets the number of unprocessed inputs to x. This input unprocessed number x is sent to the data input control unit 20, skipped data number setting unit 22, line unprocessed number setting unit 24, and data output control unit 25.
[0036]
As shown in FIG. 4B, when the start unnecessary data number Ls is x−b (b is a value satisfying 0 <b <x) bytes, when the start pulse is given, the selection unit 9 The start-unnecessary data number x-b selected in (1) is given to the skip data number setting unit 22. At this time, line data L is given from the line data number storage unit 5 to the line unprocessed number setting unit 24. The skip data setting unit 22 sets the number of skip data to xb, and the line unprocessed number setting unit 24 sets the line unprocessed number to L. The skipped data number xb is sent to the input unprocessed number setting unit 23, the line unprocessed number setting unit 24, and the data output control unit 25, and the line unprocessed number L is sent to the data input control unit 20 and the input. It is sent to the unprocessed number setting unit 23.
[0037]
In this way, the skip data number, the input unprocessed number, and the line unprocessed number are set to xb, x, and L, respectively, and the skip data number setting unit 22, the input unprocessed number setting unit 23, and the line Sent from the unprocessed number setting unit 24. Next, the skip data count setting unit 22 compares the input unprocessed count x with the skip data count x−b. Since x−b <x now, 0 is newly set as the number of skipped data. Then, the skipped data number 0 is sent to the input unprocessed number setting unit 23, the line unprocessed number setting unit 24, and the data output control unit 25.
[0038]
At this time, the input unprocessed number setting unit 23 does not receive a one-line end signal from the one-line process end detection unit 10, so that the input unprocessed number remains x and the data input control unit 20 sets the skip data number. To the unit 22, the line unprocessed number setting unit 24, and the data output control unit 25. The line unprocessed number setting unit 24 compares the skipped data number xb with the input unprocessed number x. Since x−b <x, L−x + (x−b) is calculated and L−b is newly set as the number of unprocessed lines. Then, the line unprocessed number Lb is sent to the data input control unit 20 and the input unprocessed number setting unit 23.
[0039]
When the skip data number 0, the input unprocessed number x, and the line unprocessed number L-b set in this way are respectively transmitted, the skip data number setting unit 22 skips until a one-line process end signal is given. The number of data is set to 0, and the input unprocessed number setting unit 23 sets the input unprocessed number to x. In the line unprocessed number setting unit 24, since the number of skipped data is smaller than the input unprocessed number, every time x bytes of data are input to the data transfer unit 12, Lbx and Lb- It is set to be smaller for each x, such as 2x,.
[0040]
When a 1-line processing end signal is given, as shown in FIG. 4A, when x-byte data including a-byte image data at the end of one line is input to the data transfer unit 12, The input unprocessed number and the line unprocessed number are set as x and a, respectively. At this time, since x> a, and the number of unprocessed lines is smaller than the number of unprocessed inputs, the input unprocessed number setting unit 23 calculates xa, and x-a is newly unprocessed. Set as a number. Then, the input unprocessed number x-a is sent to the data input control unit 20, the skip data number setting unit 22, the line unprocessed number setting unit 24, and the data output control unit 25.
[0041]
When the end unnecessary data number Le is 2x-a, the start unnecessary data number 3x-ab selected by the selection unit 9 is skipped when the one-line processing end signal is given. Given to. At this time, line data L is given from the line data number storage unit 5 to the line unprocessed number setting unit 24. The skip data setting unit 22 sets the skip data number to 3x-ab, and the line unprocessed number set unit 24 sets the line unprocessed number to L. The skipped data number 3x-a-b is sent to the input unprocessed number setting unit 23, the line unprocessed number setting unit 24, and the data output control unit 25, and the line unprocessed number L is set to the data input control unit 20. And the input unprocessed number setting unit 23.
[0042]
In this way, the skip data number, the input unprocessed number, and the line unprocessed number are set to 3x-ab, xa, and L, respectively, and the skip data number setting unit 22, the input unprocessed number setting unit 23, and the line unprocessed number setting unit 24. Next, the skip data count setting unit 22 compares the input unprocessed count x-a with the skip data count 3x-ab. Now, since 3x-ab> xa, (3x-ab)-(xa) is calculated, and 2x-b is newly set as the number of skipped data. The skipped data number 2x-b is sent to the input unprocessed number setting unit 23, the line unprocessed number setting unit 24, and the data output control unit 25.
[0043]
At this time, the input unprocessed number setting unit 23 sets the number of input data x stored in the data input storage unit 21 as the input unprocessed number because the one-line process end detection unit 10 does not give a one-line end signal. To do. Then, the data is sent to the data input control unit 20, the skip data number setting unit 22, the line unprocessed number setting unit 24, and the data output control unit 25. The line unprocessed number setting unit 24 compares the skipped data number 3x-a-b with the input unprocessed number xa. Since 3x-ab> xa, the line unprocessed number remains L and is sent to the data input control unit 20 and the input unprocessed number setting unit 23.
[0044]
In this way, the skip data number, the input unprocessed number, and the line unprocessed number are set to 2x-b, x, and L, respectively, and the skip data number setting unit 22, the input unprocessed number setting unit 23, and the line Sent from the unprocessed number setting unit 24. Next, the skip data number setting unit 22 compares the input unprocessed number x with the skip data number 2x−b. Now, since 2x−b> x, the calculation of (2x−b) −x is performed, and x−b is newly set as the number of skipped data. Then, the skipped data number xb is sent to the input unprocessed number setting unit 23, the line unprocessed number setting unit 24, and the data output control unit 25.
[0045]
At this time, the input unprocessed number setting unit 23 does not receive a one-line end signal from the one-line process end detection unit 10, so the input unprocessed number remains x. Then, the data is sent to the data input control unit 20, the skip data number setting unit 22, the line unprocessed number setting unit 24, and the data output control unit 25. The line unprocessed number setting unit 24 compares the skipped data number 2x-b with the input unprocessed number x. Now, since 2x−b> x, the line unprocessed number remains L and is sent to the data input control unit 20 and the input unprocessed number setting unit 23.
[0046]
As described above, when the number of skipped data, the number of unprocessed inputs, and the number of unprocessed lines are set to xb, x, and L, respectively, the above-described start pulse is applied until a one-line processing end signal is provided. The subsequent operations are performed again. The above operation is repeated each time a one-line processing end signal is given until all the image data of the bitmap image designated by the user is output from the data transfer unit 12.
[0047]
First, when a start pulse is given, the data output control unit 25 starts data output from the data transfer unit 12 to the data processing unit 13. When the one-line processing end signal indicating that the image data for one line of the bitmap image has been input from the memory 2 is supplied from the one-line processing end detection unit 10, the number of unprocessed inputs is smaller than the number of input data. The data transfer unit 12 is controlled to output the data input in the data transfer unit 12 to the data processing unit 13 twice.
[0048]
Therefore, for example, when data in units of x bytes is input from the memory 2 to the data transfer unit 12, the image data at the end of one line, which is a byte in the x bytes of data, as shown in FIG. If it is included, a 1-line processing end signal is given from the 1-line processing end detection unit 10 when the x-byte data is input to the data transfer unit 12. The input unprocessed number setting unit 23 gives an input unprocessed number xa, which is smaller than the input data number x stored in the input data number storage unit 21. Therefore, the data transfer unit 12 is output-controlled so that x-byte data including the image data at the end of one line which is input to the data transfer unit 12 is output to the data processing unit 13 twice. To do.
[0049]
The operation of the graphic LSI 3 configured as described above will be described with reference to the drawings. Now, it is assumed that image data is stored in the memory 2 as shown in FIG. 5, and the data is processed and stored in the memory 2 in units of x bytes. Further, it is assumed that the number of data for one line is L = n × x + a + b, the number of unnecessary start data is Ls = x−b, and the number of unnecessary end data is Le = m × x−a. The operation when inputting data having such image data from the memory 2 to the graphic LSI 3 will be described with reference to the time chart of FIG.
[0050]
At this time, first, the CPU 1 sets the line data number L, the start unnecessary data number Ls, the end unnecessary data number Le, and the input data number x, respectively, to the line data number storage unit 5, the start unnecessary data number storage unit 6, and the end unnecessary. The data number storage unit 7 and the input data number storage unit 21 are provided. Then, the adding unit 8 adds the start unnecessary data number Ls stored in the start unnecessary data number storage unit 6 and the end unnecessary data number Le stored in the end unnecessary data number storage unit 7 to add the number of unnecessary data Ls + Le = (M + 1) × x−a−b is generated. Further, the input data number x is given from the input data number storage unit 21 to the input unprocessed number setting unit 23, and the input unprocessed number x is set.
[0051]
After that, when a start pulse is input, the selection unit 9 selects the start unnecessary data number xb given from the start unnecessary data number storage unit 6 and gives it to the data transfer control unit 11. In the data transfer control unit 11, the data input control unit 20 operates and x-byte data is input to the data transfer unit 12. At this time, the skip data number setting unit 22 sets the start unnecessary data number xb given from the selection unit 9 as the skip data number, and the line unprocessed number setting unit 24 sets the line given from the line data number storage unit 5. The number of data n × x + a + b is set as the number of unprocessed lines.
[0052]
Therefore, when a start pulse is given, x bytes of data having b bytes of image data are input, and the number of unprocessed inputs, the number of unprocessed lines, and the number of skipped data are x, n × x + a + b, x Set to -b. At this time, the input unprocessed number x and the line unprocessed number n × x + a + b are output to the data processing unit 13.
[0053]
As described above, when the input unprocessed number x, the line unprocessed number n × x + a + b, and the skipped data number x−b are respectively set, the data transfer unit 12 generates x-byte data having b-byte image data. The output of the data transfer unit 12 is controlled by the data output control unit 25 to which the start pulse is given so as to be output to the processing unit 13. At this time, the data transfer unit 12 is input-controlled by the data input control unit 20, and the next x bytes of data that are all image data are input to the data processing unit 13.
[0054]
And the next x bytes of image data Data transfer unit 12 Since the skip data number xb is smaller than the input unprocessed number x, the skip data number setting unit 22 sets the skip data number to 0 and the line unprocessed number setting unit 24 sets the line unprocessed data to x. The number is (n × x + a + b) −x + (x−b) = n × x + a. Thereafter, the input unprocessed number setting unit 23 and Line unprocessed number setting unit 24 Thus, the input unprocessed number x and the line unprocessed number n × x + a are output to the data processing unit 13.
[0055]
Therefore, the data processing unit 13 has the input unprocessed number x and the line unprocessed number n × x + a + b input before x-byte data having b-byte image data is input, and b-byte image data. The input unprocessed number x and the line unprocessed number n × x + a input simultaneously with the x-byte data are compared. When it is confirmed that the number of input unprocessed numbers is equal, the difference in the number of line unprocessed lines to be compared is b. Therefore, x-b bytes of unnecessary data is obtained from x bytes of data input from the data transfer unit 12. Are deleted, b-byte image data included in the x-byte data is selected, and the above-described various image data processing is performed.
[0056]
When the next x-byte image data is input to the data transfer unit 12, the previous x-byte image data in the data transfer unit 12 is output from the data transfer unit 12. At this time, since the number of skipped data 0 is smaller than the input unprocessed number x, the skipped data number setting unit 22 keeps the skipped data number at 0, and the line unprocessed number setting unit 24 sets the line unprocessed number ( n × x + a) −x + 0 = (n−1) × x + a. And the input unprocessed number setting unit 23 and Line unprocessed number setting unit 24 Thus, the input unprocessed number x and the line unprocessed number (n−1) × x + a are output to the data processing unit 13.
[0057]
Therefore, the data processing unit 13 compares the input unprocessed number x and the line unprocessed number n × x + a with the input unprocessed number x and the line unprocessed number (n−1) × x + a. When it is confirmed that the number of input unprocessed numbers is equal, the difference in the number of line unprocessed lines to be compared is x. Therefore, it is confirmed that all x-byte data input from the data transfer unit 12 is image data. Then, the above-described various image data processing is performed on the x-byte image data.
[0058]
In this way, every time x-byte image data is input, the line unprocessed number setting unit 24 determines that (n−2) × x + a, (n−3) × x + a,. The line unprocessed number obtained by subtracting the value by x is set, and is output to the data processing unit 13 together with the input unprocessed number x set by the input unprocessed number setting unit 23. Therefore, at this time, in the data processing unit 13, the input unprocessed numbers to be compared are equal and the difference in the number of unprocessed lines to be compared is x. It is confirmed that the data is data, and the above-described various image data processing is performed on the x-byte image data. Further, in the skip data number setting unit 22, since the input unprocessed number x is larger than the skip data number 0, the skip data number is set to zero.
[0059]
When x-byte data including a-byte image data is input to the data transfer unit 12 and the input of the image data of the first line of the bitmap image is completed, the number of skipped data, the number of unprocessed inputs, and The number of unprocessed lines is 0, x, and a, respectively. When the x-byte image data input from the memory 2 is output from the data transfer unit 12 before the x-byte data including the a-byte image data is input, at the same time, input from the data transfer control unit 11 The unprocessed number x and the line unprocessed number a are output. Therefore, the data processing unit 13 recognizes that all x-byte data input from the data transfer unit 12 is image data, and performs various image data processing on the x-byte image data.
[0060]
While the x-byte data including the a-byte image data is input to the data transfer unit 12, the number of image data output from the data transfer unit 12 is L−x = (n−1) × x + a + b. Is reached, the input of the image data of the first line of the bitmap image is terminated, and the one-line processing end detection unit 10 gives a one-line processing end signal to the selection unit 9 and the data transfer control unit 11. At this time, the selection unit 9 selects the number of unnecessary data (m + 1) × x−a−b given from the addition unit 8 and gives it to the data transfer control unit 11.
[0061]
At this time, the skip data number setting unit 22 sets the number of unnecessary data (m + 1) × x−a−b given from the selection unit 9 as the skip data number, and the line unprocessed number setting unit 24 sets the line data number storage unit. The number of line data n × x + a + b given by 5 is set as the number of unprocessed lines. Further, the input unprocessed number setting unit 23 subtracts the input unprocessed number x by the line unprocessed number a, and sets xa as the input unprocessed number.
[0062]
In this way, when the input unprocessed number x-a, the line unprocessed number n × x + a + b, and the skipped data number (m + 1) × x−a−b are set, the data transfer unit 12 outputs a-byte image data. The data transfer unit 12 is subjected to output control by the data output control unit 25 to which the one-line processing end signal is given so that x-byte data having “” is output to the data processing unit 13 twice. At this time, the data input control unit 20 compares the input unprocessed number x with the line unprocessed number a. Now, since x> a, the input to the data transfer unit 12 is controlled to be prohibited.
[0063]
Therefore, when data input to the data transfer unit 12 is prohibited, the number of unprocessed inputs, the number of unprocessed lines, and the number of skipped data are x−a, n × x + a + b, and (m + 1) × x−a−b, respectively. Set to At this time, the input unprocessed number x-a and the line unprocessed number (m + 1) × x-a-b are output to the data processing unit 13 together with the x-byte data having a-byte image data.
[0064]
Therefore, in the data processing unit 13, the input unprocessed number x and the line unprocessed input before x bytes of data having a-byte image data as the last image data of the first line of the bitmap image are input. The number a is compared with the input unprocessed number x-a and the line unprocessed number n × x + a + b that are input simultaneously with the x-byte data having a-byte image data. Since the difference in the number of unprocessed inputs to be compared is a, x-a bytes of unnecessary data are deleted, a-byte image data included in the x-byte data is selected, and the various images described above are selected. Apply data processing.
[0065]
When data input to the data transfer unit 12 is resumed by the data input control unit 20, the data output control unit 25 outputs x-byte data having a-byte image data to the data processing unit 13 again. Further, the data output of the data transfer unit 12 is controlled. In this way, when the data transfer unit 12 tries to send x-byte data having a-byte image data again, the input unprocessed number setting unit 23 resets the input unprocessed number to x.
[0066]
At this time, since the input unprocessed number x−a is smaller than the number of skipped data (m + 1) × x−a−b, the skipped data number setting unit 22 sets the number of skipped data to the number of skipped data (m + 1) × x−a. A value m × x−b is obtained by subtracting the input unprocessed number x−a from −b, and the line unprocessed number setting unit 24 keeps the line unprocessed number as n × x + a + b. Then, the data transfer unit 12 re-outputs x-byte data having a-byte image data from the data transfer unit 12, and the data transfer control unit 11 receives the input unprocessed number x and the line unprocessed number n. Xx + a + b is output. In addition, when x-byte data having a-byte image data is re-output from the data transfer unit 12 as described above, x-byte data that is all unnecessary data is input to the data transfer unit 12.
[0067]
At this time, the data processing unit 13 compares the input unprocessed number x−a and the line unprocessed number n × x + a + b with the input unprocessed number x and the line unprocessed number n × x + a + b. Since the input unprocessed number is reduced by the difference a, it is confirmed that the first a-byte data of the x-byte data has already been processed and the line unprocessed number is equal. It is confirmed that the remaining x-a byte data is also unnecessary data. Therefore, at this time, it is confirmed that all input data is unnecessary data, and various image data processing is not performed.
[0068]
When the next x bytes of data that are all unnecessary data are input to the data transfer unit 12, the previous x bytes of unnecessary data in the data transfer unit 12 are output from the data transfer unit 12. At this time, since the input unprocessed number x is smaller than the skipped data number m × x−b, the skipped data number setting unit 22 subtracts the input unprocessed number x from the skipped data number m × x−b. And the line unprocessed number setting unit 24 keeps the number of unprocessed lines as n × x + a + b. And the input unprocessed number setting unit 23 and Line unprocessed number setting unit 24 Thus, the input unprocessed number x and the line unprocessed number n × x + a + b are output to the data processing unit 13.
[0069]
Therefore, in the data processing unit 13, Input unprocessed number x and line unprocessed number n × x + a + b input before data is input, and input unprocessed number x and line unprocessed number n × x + a + b input simultaneously with data Compare. And the input unprocessed number and the line unprocessed number are Both Since they are equal, it is confirmed that all x-byte data is unnecessary data, and various image data processing is not performed.
[0070]
In this way, every time x bytes of unnecessary data are input, the skip data number setting unit 22 selects (m−2) × x−b, (m−3) × x−b,..., 2x−b. As described above, the number of skip data obtained by subtracting the value by x is set. At this time, in the data processing unit 13, since the input unprocessed number and the line unprocessed number to be compared are always equal to x and n × x + a + b, respectively, all x bytes of data output from the data transfer unit 12 are unnecessary data. Thus, the various image data processing described above is not performed.
[0071]
Then, when x-byte data including b-byte image data is input to the data transfer unit 12 and input of the image data of the second line of the bitmap image is started, the number of skipped data, the number of unprocessed inputs, and The number of unprocessed lines is x−b, x, and n × x + a + b, respectively. Similarly, when the x-byte unnecessary data input from the memory 2 is output from the data transfer unit 12 before the x-byte data including the b-byte image data is input, the data transfer control unit 11 similarly. The input unprocessed number x and the line unprocessed number n × x + a + b are output. Therefore, the data processing unit 13 recognizes that all x bytes of data input from the data transfer unit 12 are unnecessary data, and various image data processing is not performed.
[0072]
After that, as in the first line, x-byte data, which is all image data, is input from the memory 2 to the data transfer unit 12, and x-byte data having b-byte image data is processed from the data transfer unit 12. Is output to the unit 13. At this time, similarly to the first line, the skip data number, the input unprocessed number, and the line unprocessed number are set to 0, x, n × x + a, respectively, and the input unprocessed number 0 and the line unprocessed number n Xx + a is output to the data processing unit 13. The subsequent operation is the same as that for the first line until a one-line processing end signal is given.
[0073]
Such an operation is repeated for each line until the image data of the final line is processed by the data processing unit 13, so that it is necessary to remove unnecessary data from data including unnecessary data given from the memory 2. Various image data processing can be performed by selecting only image data.
[0074]
In this embodiment, when the x-byte data output from the data transfer unit to the data processing unit is composed of only unnecessary data, the number of unprocessed inputs and line unprocessed output from the data transfer control unit The number is output to the data processing unit together with the number, but the output of x bytes composed of only unnecessary data may be prohibited by the data output control unit. At this time, if the data output control unit confirms that the number of skipped data is larger than the input unprocessed number, the output of the input unprocessed number and the line unprocessed number output from the data transfer control unit is prohibited. The output of the data input to the data transfer unit at this time may be prohibited.
[0075]
【The invention's effect】
According to the present invention, unnecessary data other than the designated image data can be removed in the image data processing apparatus. Therefore, the data in the address area in which the designated image data is stored is continuously transferred from the memory to the image data. It can be sent to the processing device. Therefore, as in the prior art, it is possible to omit processing operations for selecting and rearranging only necessary image data once by a CPU or the like and sending them to the image data processing apparatus. Processing time can be shortened.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a relationship between a graphic LSI of the present invention and a memory.
FIG. 2 is a block diagram showing the internal configuration of the graphic LSI of the present invention.
3 is a block diagram showing an internal configuration of a data transfer control unit provided in the graphic LSI of FIG. 2;
FIG. 4 is a view showing a state of data stored in a memory.
FIG. 5 is a view showing a state of data stored in a memory.
FIG. 6 is a time chart showing the operation of the graphic LSI of the present invention.
FIG. 7 is a view showing a state of data stored in a memory.
[Explanation of symbols]
1 CPU
2 memory
3 Graphic LSI
4 Bus lines
5 Line data number storage
6 Number of unnecessary start data storage
7 Endless data count storage
8 Adder
9 Selection part
10 1-line processing end detection unit
11 Data transfer controller
12 Data transfer unit
13 Data processing section

Claims (4)

画像1ライン毎に該画像を表す画像データを連続的に格納するメモリ内に格納されたデータが所定単位毎に入力されるとともに、入力されるデータに含まれる画像データに対して画像データ処理を施す画像データ処理装置において、
メモリから与えられるデータから不要データを除去して、必要な画像データを選択して、画像データ処理を施すデータ処理部と、
最初に入力される前記所定単位のデータ内に含まれる不要データのデータ数を設定する第1不要データ数設定部と、
1ライン最後の画像データと次のライン最初の画像データとの間に存在する不要データのデータ数を設定する第2不要データ数設定部と、
第1又は第2不要データ数設定部の何れか一方で設定された不要データのデータ数を選択する選択部と、
画像1ライン分の画像データが前記データ処理部に送出されたことを確認したとき、ライン処理終了信号を前記選択部及び前記データ処理部に送出するライン処理終了検出部と、
を有し、
前記メモリより、画像データを含む前記所定単位のデータの入力が開始されたとき、前記選択部で前記第1不要データ数設定部で設定された不要データのデータ数が前記データ処理部に与えられ、
又、前記ライン処理終了検出部よりライン処理終了信号が発生したとき、前記選択部で前記第2不要データ数設定部で設定された不要データのデータ数が前記データ処理部に与えられることを特徴とする画像データ処理装置。
Data stored in a memory that continuously stores image data representing the image for each line of the image is input for each predetermined unit, and image data processing is performed on the image data included in the input data. In the image data processing apparatus to be applied,
A data processing unit that removes unnecessary data from data provided from the memory, selects necessary image data, and performs image data processing;
A first unnecessary data number setting unit for setting the number of unnecessary data included in the predetermined unit of data input first;
A second unnecessary data number setting unit for setting the number of unnecessary data existing between the last image data of one line and the first image data of the next line;
A selection unit for selecting the number of unnecessary data set by either the first or second unnecessary data number setting unit;
A line processing end detection unit for sending a line processing end signal to the selection unit and the data processing unit when confirming that image data for one line of image has been sent to the data processing unit;
Have
When the input of the predetermined unit of data including image data is started from the memory, the number of unnecessary data set by the first unnecessary data number setting unit by the selection unit is given to the data processing unit. ,
Further, when a line processing end signal is generated from the line processing end detection unit, the number of unnecessary data set by the second unnecessary data number setting unit by the selection unit is given to the data processing unit. An image data processing apparatus.
前記データ処理部が、
画像データ処理を行う画像データ処理部と、
前記メモリより入力される前記所定単位のデータを前記画像データ処理部に送出するとともに、前記選択部で選択された不要データのデータ数に基づいて前記所定単位のデータにおける画像データの位置を特定するための画像データ位置特定信号を生成して前記画像データ処理部に送出する画像データ位置特定部と、
を有し、
前記メモリより、画像データを含む前記所定単位のデータの入力が開始されたとき、前記選択部で前記第1不要データ数設定部で設定された不要データのデータ数が前記画像データ位置特定部に与えられて、入力開始時の前記所定単位のデータにおける画像データの位置を特定するための画像データ位置特定信号が生成され、
前記ライン処理終了検出部よりライン処理終了信号が発生するまでの間、前記メモリより入力されるデータ全てが画像データであることを示す画像データ位置特定信号が生成され、
前記ライン処理終了検出部よりライン処理終了信号が発生したとき、前記選択部で前記第2不要データ数設定部で設定された不要データのデータ数が前記画像データ位置特定部に与えられ、1ライン終了時の画像データの位置を特定するとともに次のライン開始時の画像データの位置を特定する画像データ位置特定信号が生成されることを特徴とする請求項1に記載の画像データ処理装置。
The data processing unit is
An image data processing unit for performing image data processing;
The predetermined unit of data input from the memory is sent to the image data processing unit, and the position of the image data in the predetermined unit of data is specified based on the number of unnecessary data selected by the selection unit. An image data position specifying unit for generating an image data position specifying signal for sending to the image data processing unit;
Have
When the input of the predetermined unit of data including image data is started from the memory, the number of unnecessary data set by the first unnecessary data number setting unit in the selection unit is stored in the image data position specifying unit. Given, an image data position specifying signal for specifying the position of the image data in the predetermined unit of data at the start of input is generated,
Until the line processing end signal is generated from the line processing end detection unit, an image data position specifying signal indicating that all data input from the memory is image data is generated,
When a line processing end signal is generated from the line processing end detection unit, the number of unnecessary data set by the second unnecessary data number setting unit by the selection unit is given to the image data position specifying unit, and one line 2. The image data processing apparatus according to claim 1, wherein an image data position specifying signal for specifying the position of the image data at the end and for specifying the position of the image data at the start of the next line is generated.
前記画像データ位置特定信号が、前記画像データ位置特定部より前記画像データ処理部に送出されるデータ数を示す入力未処理数と、1ラインの画像データのうち前記画像データ処理部に送出されていない画像データのデータ数を示すライン未処理数とによって構成されることを特徴とする請求項2に記載の画像データ処理装置。  The image data position specifying signal is sent to the image data processing unit out of the input unprocessed number indicating the number of data sent from the image data position specifying unit to the image data processing unit, and one line of image data. The image data processing apparatus according to claim 2, wherein the image data processing apparatus is configured by a line unprocessed number indicating the number of non-existing image data. 前記画像データ位置特定部が、
前記入力未処理数を設定する入力未処理数設定部と、
前記ライン未処理数を設定するライン未処理数設定部と、
前記選択部で選択された不要データのデータ数が与えられるとともに、前記画像データ処理部に送出されるデータ内の不要データのデータ数を表す飛ばしデータ数を設定する飛ばしデータ数設定部と、
を備え、
前記メモリより、画像データを含む前記所定単位のデータの入力が開始されたとき、前記選択部で前記第1不要データ数設定部で設定された不要データのデータ数が前記飛ばしデータ数設定部に与えられて前記飛ばしデータ数設定部において飛ばしデータ数として設定されるとともに、前記ライン未処理数において1ラインの画像データのデータ数がライン未処理数として設定され、
前記ライン処理終了検出部よりライン処理終了信号が発生したとき、前記選択部で前記第2不要データ数設定部で設定された不要データのデータ数が前記飛ばしデータ数設定部に与えられて前記飛ばしデータ数設定部において飛ばしデータ数として設定されるとともに、前記ライン未処理数において1ラインの画像データのデータ数がライン未処理数として設定され、
前記飛ばしデータ数設定部で設定された飛ばしデータ数が前記入力未処理数で設定された入力未処理数以上のとき、該飛ばしデータ数より該入力未処理数を減算した値が新たに飛ばしデータ数として設定され、
前記飛ばしデータ数設定部で設定された飛ばしデータ数が前記入力未処理数で設定された入力未処理数より小さいとき、飛ばしデータ数が0と設定され、
前記飛ばしデータ数設定部で設定された飛ばしデータ数が、前記入力未処理数で設定された入力未処理数より小さいとき、前記ライン未処理数で設定されたライン未処理数から該入力未処理数を減算した後に該飛ばしデータ数を加算した値が新たにライン未処理数として設定されることを特徴とする請求項3に記載の画像データ処理装置。
The image data position specifying unit
An input unprocessed number setting unit for setting the input unprocessed number;
A line unprocessed number setting unit for setting the number of unprocessed lines;
The number of unnecessary data selected by the selection unit is given, a skip data number setting unit for setting the number of skip data representing the number of unnecessary data in the data sent to the image data processing unit,
With
When the input of the predetermined unit of data including image data is started from the memory, the number of unnecessary data set by the first unnecessary data number setting unit in the selection unit is input to the skip data number setting unit. Given and set as the number of skip data in the skip data number setting unit, the number of image data of one line is set as the number of unprocessed lines in the number of unprocessed lines,
When a line processing end signal is generated from the line processing end detection unit, the number of unnecessary data set by the selection unit in the second unnecessary data number setting unit is given to the skip data number setting unit and the skipping is performed. In the data number setting unit, the number of skipped data is set, and the number of image data of one line is set as the number of unprocessed lines in the number of unprocessed lines.
When the number of skip data set in the skip data number setting unit is equal to or greater than the input unprocessed number set in the input unprocessed number, a value obtained by subtracting the input unprocessed number from the skip data number is a new skip data. Set as a number,
When the skip data number set by the skip data number setting unit is smaller than the input unprocessed number set by the input unprocessed number, the skip data number is set to 0,
When the skip data number set by the skip data number setting unit is smaller than the input unprocessed number set by the input unprocessed number, the input unprocessed from the line unprocessed number set by the line unprocessed number 4. The image data processing apparatus according to claim 3, wherein a value obtained by adding the skip data number after subtracting the number is newly set as a line unprocessed number.
JP2000335904A 2000-11-02 2000-11-02 Image data processing device Expired - Fee Related JP3842968B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2000335904A JP3842968B2 (en) 2000-11-02 2000-11-02 Image data processing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2000335904A JP3842968B2 (en) 2000-11-02 2000-11-02 Image data processing device

Publications (2)

Publication Number Publication Date
JP2002140056A JP2002140056A (en) 2002-05-17
JP3842968B2 true JP3842968B2 (en) 2006-11-08

Family

ID=18811572

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2000335904A Expired - Fee Related JP3842968B2 (en) 2000-11-02 2000-11-02 Image data processing device

Country Status (1)

Country Link
JP (1) JP3842968B2 (en)

Also Published As

Publication number Publication date
JP2002140056A (en) 2002-05-17

Similar Documents

Publication Publication Date Title
US20120203942A1 (en) Data processing apparatus
JP3842968B2 (en) Image data processing device
JP2003219185A (en) Image processor and processing method
EP2133797B1 (en) Dma transfer device and method
JP4313907B2 (en) Imaging apparatus and control method thereof
JP3888422B2 (en) Video data transfer control system and video data transfer control method
JP2000354193A (en) Camera system and video signal processor
US20120144150A1 (en) Data processing apparatus
JP4553998B2 (en) Bus control device
JP2007087086A (en) Dma transfer system
JP2007006017A (en) Image processing apparatus
JPH0785261A (en) Mirror image processor
JP2003309755A (en) Mobile camera
JPH0497665A (en) Picture recording and processing device
JP2019114067A (en) Image processing apparatus, image processing method, and program
JP2005227479A (en) Image processor, image processing method, and program having image processing method executed by computer
JP3118850B2 (en) Image output device
JPH032942A (en) Addressing circuit for picture memory
JPH11164265A (en) Signal conversion circuit
JPH0420224B2 (en)
JP2009265776A (en) Image processor
JP2001243446A (en) Device and method for image input processing
JPS60136880A (en) Picture processing device
JPH03288267A (en) Transmission system for medical image data
JPS6058628B2 (en) Facsimile signal encoding method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20050214

RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20051227

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20060427

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20060516

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20060710

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20060801

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20060811

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

Free format text: PAYMENT UNTIL: 20100818

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20100818

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20110818

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20110818

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20120818

Year of fee payment: 6

LAPS Cancellation because of no payment of annual fees