JP2004297128A - Image reading apparatus, image reading program and image reading method - Google Patents
Image reading apparatus, image reading program and image reading method Download PDFInfo
- Publication number
- JP2004297128A JP2004297128A JP2003082813A JP2003082813A JP2004297128A JP 2004297128 A JP2004297128 A JP 2004297128A JP 2003082813 A JP2003082813 A JP 2003082813A JP 2003082813 A JP2003082813 A JP 2003082813A JP 2004297128 A JP2004297128 A JP 2004297128A
- Authority
- JP
- Japan
- Prior art keywords
- reading
- exposure amount
- image
- image data
- average value
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Abstract
Description
【0001】
【発明の属する技術分野】
本発明は、原稿の画像を読み取る画像読取装置、画像読取装置に対する制御をコンピュータで実現させるための画像読取プログラムおよび画像読取方法に関する。
【0002】
【従来の技術】
原稿の画像を読み取る画像読取装置においては、本スキャンの前に予備的にスキャン(いわゆるプリスキャン)を行って本スキャン時の露光量を決めている。具体的には、所定の露光量でプリスキャンを行い、得られた画像データ中の最大輝度値を求める。そして、求めた最大輝度値がA/D変換で取り得る最大値(256階調の場合は255)に一致するように、プリスキャン時の露光量に適当な倍数を乗じて本スキャン時の露光量とする。
【0003】
【発明が解決しようとする課題】
このような画像読取装置を用いて画像の読み取りを行う場合、原稿中に輝点があると、その輝点に合わせるように本スキャン時の露光量が決定されてしまうことになる。そのため、輝点と輝点以外の部分との輝度レベルの差が大きいと露光量が不足し、読み取りにより得られる画像全体が暗くなってしまうことがあった。
【0004】
本発明の目的は、読み取り対象の原稿中に輝点があったとしても、最適な露光量で読み取りを行うことができる画像読取装置、画像読取プログラム、および画像読取方法を提供することである。
【0005】
【課題を解決するための手段】
請求項1に記載の画像読取装置は、所定の露光量で原稿を照明する照明手段と、前記照明手段により照明される前記原稿の画像を予備的に読み取り、画像データを得る予備読取手段と、前記予備読取手段により得られた前記画像データを複数の領域に分割する分割手段と、前記分割手段により分割された前記領域ごとに当該領域内の最大輝度値を抽出する抽出手段と、前記抽出手段により抽出された前記領域ごとの最大輝度値の平均値を算出する平均値算出手段と、前記平均値算出手段により算出された前記平均値に基づいて、本読取時の前記照明手段による前記露光量を決定する露光量決定手段と、前記露光量決定手段により決定された前記露光量で前記照明手段により前記原稿を照明させ、該原稿の画像を読み取り、画像データを得る本読取手段とを備えたことを特徴とする。
【0006】
請求項2に記載の画像読取装置は、請求項1に記載の画像読取装置において、前記分割手段は、前記予備読取手段により得られた前記画像データを、主走査方向および副走査方向の少なくとも一方の方向について分割することを特徴とする。
請求項3に記載の画像読取装置は、請求項1または請求項2に記載の画像読取装置において、前記分割手段による分割数は可変であることを特徴とする。
【0007】
請求項4に記載の画像読取プログラムは、所定の露光量で原稿を照明する照明手段と、前記照明手段により照明される前記原稿の画像を読み取り、画像データを得る読取手段とを備えた画像読取装置に対する制御をコンピュータで実現するためのプログラムであって、前記照明手段により照明される前記原稿の画像を予備的に読み取り、画像データを得る予備読取手順と、前記予備読取手順により得られた前記画像データを複数の領域に分割する分割手順と、前記分割手順により分割された前記領域ごとに当該領域内の最大輝度値を抽出する抽出手順と、前記抽出手順により抽出された前記領域ごとの最大輝度値の平均値を算出する平均値算出手順と、前記平均値算出手順により算出された前記平均値に基づいて、本読取時の前記照明手段による前記露光量を決定する露光量決定手順と、前記露光量決定手順により決定された前記露光量で前記照明手段により前記原稿を照明させ、該原稿の画像を読み取り、画像データを得る本読取手順とをコンピュータで実現させることを特徴とする。
【0008】
請求項5に記載の画像読取方法は、所定の露光量で原稿を照明する照明工程と、前記照明工程により照明される前記原稿の画像を予備的に読み取り、画像データを得る予備読取工程と、前記予備読取工程により得られた前記画像データを複数の領域に分割する分割工程と、前記分割工程により分割された前記領域ごとに当該領域内の最大輝度値を抽出する抽出工程と、前記抽出工程により抽出された前記領域ごとの最大輝度値の平均値を算出する平均値算出工程と、前記平均値算出工程により算出された前記平均値に基づいて、本読取時の前記照明工程による前記露光量を決定する露光量決定工程と、前記露光量決定工程により決定された前記露光量で前記照明工程により前記原稿を照明させ、該原稿の画像を読み取り、画像データを得る本読取工程とを備えたことを特徴とする。
【0009】
【発明の実施の形態】
以下、図面に基づいて、本発明の実施形態について詳細に説明する。なお、以下では本発明の画像読取装置の一例として、フィルム原稿に写し込まれている画像を透過照明によって読み取る画像読取装置を用いて説明を行う。
《第1実施形態》
以下、図面を用いて本発明の第1実施形態について説明する。
【0010】
図1は、第1実施形態の画像読取装置の構成を示すブロック図である。
画像読取装置1は、図1に示すように、スキャナ本体2とフィルム原稿3を保持するアダプタ4とで構成される。アダプタ4は、スキャナ本体2に対して着脱可能であり、スキャナ本体2のスロット部5に差し込まれることによりスキャナ本体2に装着される。
【0011】
スキャナ本体2内には、図1に示すように、光学ブロック6とモータ7と制御部8とが設けられている。
光学ブロック6は、上記したスロット部5の上方に配置された照明光源9と、スロット部5の下方に配置されたレンズ10、ラインCCD11とで構成されている。
【0012】
照明光源9は、RGB各色の発光ダイオード(LED)で構成され、制御部8を構成するLED駆動回路12からの駆動信号(後述する)に応じて順次点灯あるいは消灯される。このようなLED駆動回路12からの駆動信号の間隔に応じて露光時間が変化する。そして、この露光時間を変更することにより、照明光源9からフィルム原稿3への露光量を変えることができる。
【0013】
照明光源9からの照明光は、図1においてx方向(主走査方向)に沿った線状の光である。このため、照明光源9からの照明光の光路とフィルム原稿3とは、x方向に沿った所定ライン(以下「読み取りライン13」と称する)で交叉することになる。
レンズ10は、読み取りライン13を介してフィルム原稿3の下方へ導かれた線状の光をラインCCD11の撮像面に結像する。
【0014】
ラインCCD11は、複数の画素がx方向に一次元配列されたイメージセンサであり、各画素において入射光に応じた電荷を蓄積する。ラインCCD11の各画素に蓄積された電荷は、制御部8を構成するCCD駆動回路14からの駆動信号(後述する)に応じて転送路を転送され、アナログ画像信号として外部に出力される。
【0015】
モータ7は、制御部8を構成するモータ駆動回路15からの駆動信号(後述する)に基づいて、光学ブロック6をy方向(副走査方向)に微細な間隔でステップ移動させる。モータ7によって光学ブロック6がy方向に移動されると、上記の読み取りライン13もy方向に移動する。
制御部8は、上記したLED駆動回路12、CCD駆動回路14、モータ駆動回路15に加えて、信号処理回路16、A/D変換器17、CPU18、ROM19、メモリ20、外部インターフェイス21で構成されている。
【0016】
このうち、LED駆動回路12、CCD駆動回路14、モータ駆動回路15の各駆動回路は、何れもCPU18の指示にしたがって駆動信号を出力する。
また、信号処理回路16は、ラインCCD11から出力されたアナログ画像信号に対して増幅などの信号処理を施し、A/D変換器17へ出力する。A/D変換器17は、信号処理回路16で信号処理が施されたアナログ画像信号をディジタル信号に変換し、1ライン分のディジタル画像データとしてCPU18に出力する。この画像データは、メモリ20に一時格納される。
【0017】
CPU18は、ROM19に格納された制御プログラムや各種データを参照しながら、画像読取装置1における各種制御を実行する。ROM19に格納される制御プログラムには、アダプタ4に保持されたフィルム原稿3の画像を読み取る手順を記載したプログラムが含まれる。
また、外部インターフェイス21は、本発明の画像読取装置1を外部のホストコンピュータ22に接続するためのドライバ(例えばSCSIインターフェイス)であり、画像読取装置1は、外部インターフェイス21を介して外部のホストコンピュータ22に接続される。
【0018】
なお、ホストコンピュータ22には、プリスキャンおよび本スキャン実行の指示などのユーザ操作を受付けるキーボードなどの操作部(不図示)も備えられる。
以上説明したような構成の画像読取装置1における画像の読み取りの大まかな流れについて図2を用いて説明する。
【0019】
不図示の電源がONされると、ステップS1において、CPU18は、各部を介して初期動作を行う。
ここで初期動作とは、スキャナ本体2内の光学ブロック6を所定の読み取り開始位置に移動させる処理などである。
ステップS2において、CPU18は、フィルム原稿3のセットおよびプリスキャンの指示が行われたか否かを判定する。なお、フィルム原稿3がセットされたか否かの判定は、アダプタ4内に備えられたフィルム原稿3の有無を検知するセンサ(不図示)によって実現されるものとし、プリスキャンの指示はユーザによりホストコンピュータ22の操作部を介して行われるものとする。また、セットされたフィルム原稿3は所定の位置に、自動的に位置決めされるものとする。
【0020】
そして、CPU18は、フィルム原稿3のセットおよびプリスキャンの指示が行われるまでステップS2を繰り返す。
ステップS3において、CPU18は、各部を介してプリスキャンおよび露光量決定処理を行う。なお、プリスキャンは本スキャンより低い所定の解像度で行われる。また、露光量決定処理とは、プリスキャンの結果に基づいて本スキャン時の露光量を決定する処理である(詳細は後述する)。
【0021】
ステップS4において、CPU18は、ユーザによりホストコンピュータ22の操作部を介して、本スキャンの指示が行われたか否かを判定する。そして、CPU18は、本スキャンの指示が行われるまでステップS4を繰り返す。
ステップS5において、CPU18は、ステップS3で決定した露光量に応じた露光時間や他の所定の条件(解像度など)で、各部を介して本スキャンを行う。
【0022】
ステップS6において、CPU18は、本スキャンにより得られた画像データを、外部インターフェイス21を介して、外部のホストコンピュータ22に出力し、一連の処理を終了する。
ここで、ステップS3において行われるプリスキャンおよび露光量決定処理について図3および図4を用いて説明する。
【0023】
ホストコンピュータ22の操作部を介して、プリスキャンの指示が行われると、ステップS11において、CPU18は、各部を介して1ライン分の読み取りを行う。
すなわち、CPU18は、LED駆動回路12およびCCD駆動回路14に駆動信号を出力し、1ライン分の読み取りを行わせる。ラインCCD11により読み取られた画像データは、信号処理回路16およびA/D変換器17を介してCPU18に出力される。そして、CPU18は、1ライン分の画像データをメモリ20に記録し、メモリ20内の不図示のカウンタの値を1にして、ステップS12に進む。
【0024】
ステップS12において、CPU18は、1ライン分の画像データをP個のグループ(1グループ〜Pグループ)に等分割して、各グループごとに輝度の最大値を求め、メモリ20にブロック内最大輝度値として記録する。
ここで、ブロックとは、図4に示すように、読み取り対象の画像データをx方向にP等分し、y方向にQ等分した時のそれぞれの領域のことである。なお、x方向における分割数Pおよびy方向における分割数Qは、予めメモリ20内に記録されているものとする。
【0025】
図4に示すように、読み取り完了時の全画像データが、x方向についてはm画素分の画像データから成り、y方向についてはnライン分の画像データから成る場合、1つのブロックは、x方向については(m÷P)画素分の画像データから成り、y方向については(n÷Q)ライン分の画像データから成る。
なお、以下では、x方向にP個並んだブロックをまとめて「ブロック群」と称する。
【0026】
CPU18は、まず、1ライン分の画像データを、1グループ〜Pグループに等分割する。次に、CPU18は、各グループごとに輝度の最大値を求める。そして、CPU18は、求めた最大値をブロック内最大輝度値として、1〜Pのグループ番号に対応付けてメモリ20に記録する。
ステップS13において、CPU18は、次のラインの読み取りを行う。
【0027】
すなわち、CPU18は、モータ駆動回路15に駆動信号を出力し、次のラインを読み取る位置に光学ブロック6を移動させる。そして、CPU18は、ステップS11と同様に、各部を介して1ライン分の読み取りを行う。そして、CPU18は、得られた画像データをメモリ20に記録し、メモリ20内の不図示のカウンタの値を1増やして、ステップS14に進む。
【0028】
ステップS14において、CPU18は、ステップS12と同様に、1ライン分の画像データをP個のグループに等分割して、各グループごとに輝度の最大値を求める。
ステップS15において、CPU18は、メモリ20に記録されているブロック内最大輝度値がステップS14で求めた輝度の最大値より小さいか否かを判定する。ブロック内最大輝度値の方が小さい場合には、CPU18は、ステップS16に進み、ブロック内最大輝度値の方が大きい場合には、CPU18は、ステップS17に進む。
【0029】
ステップS16において、CPU18は、メモリ20に記録されているブロック内最大輝度値をステップS14で求めた輝度の最大値に置き換える。
すなわち、CPU18は、ステップS14で求めた輝度の最大値を、新しいブロック内最大輝度値としてメモリ20に記録する。
なお、ステップS15およびステップS16で説明した処理は、グループごとに行われる。すなわち、ブロック内最大輝度値がステップS14で求めた輝度の最大値より小さいグループについてのみ、最大値の置き換えが行われる。
【0030】
ステップS17において、CPU18は、(n÷q)ライン分(1ブロック群分)の読み取りが完了したか否かを判定する。
すなわち、CPU18は、メモリ20内のカウンタの値が(n÷q)回に達したか否かを判定することにより(n÷q)ライン分の読み取りが完了したか否かを判定する。そして、(n÷q)ライン分の読み取りが完了した場合には、CPU18は、ステップS18に進む。
【0031】
一方、(n÷q)ライン分の読み取りが完了していない場合には、CPU18は、ステップS13に戻り、(n÷q)ライン分の読み取りが完了するまでステップS13〜ステップS17の処理を繰り返す。
ステップS18において、CPU18は、全てのブロック群分の読み取りが完了したか否かを判定する。
【0032】
例えば、メモリ20内には、読み取り対象となったブロック群を計数するための不図示のカウンタが設けられており、CPU18は、そのカウンタの値が、Q(全てのブロック群数)回に達したか否かを判定することにより全てのブロック群分の読み取りが完了したか否かを判定する。
そして、全てのブロック群分の読み取りが完了した場合には、ステップS20に進み、全てのブロック群分の読み取りが完了していない場合には、ステップS19に進む。
【0033】
ステップS19において、CPU18は、次のブロック群を読み取り対象とする。
CPU18は、まず、モータ駆動回路15に駆動信号を出力し、次のラインを読み取る位置に光学ブロック6を移動させる。そして、CPU18は、ステップS11に戻り、ステップS11〜ステップS19の処理を繰り返す。
【0034】
したがって、CPU18は、全てのブロック群分(全てのライン分)の読み取りが完了するまでステップS11〜ステップS19の処理を繰り返し、全てのブロックについてブロック内最大輝度値を求めることになる。
ステップS20において、CPU18は、メモリ20内に記録されている(P×Q)個のブロック内最大輝度値を読み出し、平均値を求める。
【0035】
ステップS21において、CPU18は、ステップS20で求めた平均値に基づいて、本スキャン時の露光量を決定する。
CPU18は、ステップS20で求めた平均値がA/D変換で取り得る最大値(256階調の場合は255)に一致するように、本スキャン時の露光量を決定する。そして、CPU18は、決定した露光量をメモリ20に記録して、一連の処理を終了する。
【0036】
以上説明したように、第1実施形態によれば、プリスキャンにより得られた画像データは複数のブロックに分割される。そして、各ブロックごとにブロック内最大輝度値が求められ、それらの輝度値の平均値が算出される。そして、平均値に基づいて本スキャン時の露光量が決定される。そのため、読み取り対象の原稿中に輝点があったとしても、最適な露光量で読み取りを行うことができる。
【0037】
《第2実施形態》
以下、図面を用いて本発明の第2実施形態について説明する。
第2実施形態の画像読取装置の構成は、第1実施形態と同様であるため説明を省略し、以下では、第1実施形態と同様の符号を用いて説明を行う。
ただし、第2実施形態においては、画像読取装置1における各種制御の際に、ホストコンピュータ22の不図示のCPU(以下、「ホスト側CPU」と称する)、メモリ(以下、「ホスト側メモリ」と称する)、およびROMが使用される。ホスト側CPUは、ホストコンピュータ22のROMに格納された制御プログラムや各種データを参照しながら、画像読取装置1における各種制御を実行する。ホストコンピュータ22のROMに格納される制御プログラムには、アダプタ4に保持されたフィルム原稿3の画像を読み取る手順を記載したプログラムが含まれる。
【0038】
また、第2実施形態の画像読取装置1における画像の読み取りの大まかな流れについては、第1実施形態と同様であるため説明を省略する。ただし、第2実施形態における画像読み取りのための一連の処理は、ホスト側CPUによる指示に基づいて行われるものとする。
以下では、第1実施形態の画像処理装置1における処理とは異なる処理であるプリスキャンおよび露光量決定処理について、図4および図5を用いて説明する。
【0039】
ホストコンピュータ22の操作部を介して、プリスキャンの指示が行われると、ステップS31において、ホスト側CPUは、各部を介して1ライン分の読み取りを行う。
【0040】
ホスト側CPUは、まず、LED駆動回路12およびCCD駆動回路14に駆動信号を出力し、1ライン分の読み取りを行わせる。
ステップS32において、ホスト側CPUは、1ライン分の画像データを信号処理回路16、A/D変換器17および外部インターフェイス21を介してホストコンピュータ22に転送させる。そして、スキャナ本体2から入力された1ライン分の画像データをホスト側メモリに記録し、ホスト側メモリ内の不図示のカウンタの値を1にして、ステップS33に進む。
【0041】
ステップS33において、ホスト側CPUは、全てのライン分の読み取りが完了したか否かを判定する。
ホスト側CPUは、ホスト側メモリ内のカウンタの値が全体のライン数(図4のn)に達したか否かを判定することにより全てのライン分の読み取りが完了したか否かを判定する。そして、全てのライン分の読み取りが完了した場合には、ステップS34に進み、全てのライン分の読み取りが完了していない場合には、ステップS31に戻り、ステップS31〜ステップS33の処理を繰り返す。
【0042】
ステップS34において、ホスト側CPUは、ホスト側メモリ内に記録されている画像データを、図4に示すように、(P×Q)個のブロックに等分割する。ここで、Pとは、予めホスト側メモリ内に記録されたx方向(主走査方向)における分割数であり、Qとは、予めホスト側メモリ内に記録されたy方向(副走査方向)における分割数である。
【0043】
ステップS35において、ホスト側CPUは、各ブロックごとに輝度の最大値を求め、ホスト側メモリにブロック内最大輝度値として記録する。したがって、ホスト側メモリ内には(P×Q)個のブロック内最大輝度値が記録されることになる。
ステップS36において、ホスト側CPUは、ホスト側メモリ内に記録されている(P×Q)個のブロック内最大輝度値を読み出し、平均値を求める。
【0044】
ステップS37において、ホスト側CPUは、ステップS36で求めた平均値に基づいて、第1実施形態のステップS21と同様に、本スキャン時の露光量を決定する。
そして、ホスト側CPUは、決定した露光量をホスト側メモリに記録して、一連の処理を終了する。
【0045】
以上説明したように、第2実施形態によれば、プリスキャンにより得られた画像データはホストコンピュータ22に転送され、複数のブロックに分割される。そして、各ブロックごとにブロック内最大輝度値が求められ、それらの輝度値の平均値が算出される。そして、平均値に基づいて本スキャン時の露光量が決定される。そのため、読み取り対象の原稿中に輝点があったとしても、最適な露光量で読み取りを行うことができる。
【0046】
特に、プリスキャンを行いながら、得られた画像データをホストコンピュータ22に転送し、プリスキャン終了後に一括して処理を行うことにより処理時間を短縮することができる。
なお、第2実施形態では、1ライン読む度にホストコンピュータ22に転送する例を示したが、スキャナ本体2内のメモリ20をバッファメモリとして用い、所定量ずつまとめてホストコンピュータ22に転送するようにしても良い。
【0047】
また、上記各実施形態では、x方向(主走査方向)における分割数Pおよびy方向(副走査方向)における分割数Qは予め定められた値であったが、可変であっても良い。その場合、ユーザ操作により分割数を設定しても良いし、精度や速度に対するユーザの要望に応じて分割数を自動的に設定しても良い。例えば、ユーザにより高精度の読み取りが要求された場合には分割数を多くし、高速度の読み取りが要求された場合には、分割数を少なくすると良い。
【0048】
特に、第2実施形態については、プリスキャンが終了した時点で、画像データの輝度ヒストグラムを求め、そのヒストグラムの解析によって輝点が存在していた場合は分割数を多くするようにしても良い
また、上記各実施形態では、フィルム原稿を透過照明を用いて読み取る例を示したが、読み取り対象の原稿と照明の組合わせは、どのようなものであっても良い。
【0049】
また、上記各実施形態では、プリスキャンの結果に基づいて決定した露光量に応じて本スキャン時の露光時間を変更する例を示したが、照明光源9自体の光量を変更可能である場合には、決定した露光量に応じて本スキャン時の照明光源9の光量を変更するようにしても良い。また、本スキャン時の露光時間と照明光源9の光量との両方を変更するようにしても良い。
【0050】
また、上記各実施形態では、光学ブロック6を移動して、光学ブロック6とフィルム原稿3との相対的な位置関係を変更する例を示したが、フィルム原稿3を移動しても良いし、光学ブロック6とフィルム原稿3との両方を移動しても良い。
【0051】
【発明の効果】
以上説明したように、本発明によれば、読み取り対象の原稿中に輝点があったとしても、最適な露光量で読み取りを行うことができる画像読取装置、画像読取プログラム、および画像読取方法を提供することができる。
【図面の簡単な説明】
【図1】第1実施形態の画像読取装置の構成を示すブロック図である。
【図2】第1実施形態の画像読取装置における画像の読み取りの大まかな流れ示すフローチャートである
【図3】プリスキャンおよび露光量決定処理時の画像読取装置の制御手順を示すフローチャートである。
【図4】プリスキャンにより得られた画像データの分割について説明する図である。
【図5】プリスキャンおよび露光量決定処理時の画像読取装置の制御手順を示すフローチャートである。
【符号の説明】
1 画像読取装置
2 スキャナ本体
3 フィルム原稿
4 アダプタ
5 スロット部
6 光学ブロック
7 モータ
8 制御部
9 照明光源
10 レンズ
11 ラインCCD
12 LED駆動回路
13 読み取りライン
14 CCD駆動回路
15 モータ駆動回路
16 信号処理回路
17 A/D変換器
18 CPU
19 ROM
20 メモリ
21 外部インターフェイス
22 ホストコンピュータ[0001]
TECHNICAL FIELD OF THE INVENTION
The present invention relates to an image reading apparatus that reads an image of a document, an image reading program for causing a computer to control the image reading apparatus, and an image reading method.
[0002]
[Prior art]
In an image reading apparatus that reads an image of a document, a preliminary scan (so-called pre-scan) is performed before the main scan to determine an exposure amount during the main scan. Specifically, a pre-scan is performed with a predetermined exposure amount, and the maximum luminance value in the obtained image data is obtained. The exposure amount at the time of the main scan is multiplied by an appropriate multiple of the exposure amount at the time of the prescan so that the obtained maximum luminance value coincides with the maximum value that can be obtained by the A / D conversion (255 for 256 gradations). Amount.
[0003]
[Problems to be solved by the invention]
When an image is read using such an image reading apparatus, if there is a bright spot in the document, the exposure amount at the time of the main scan is determined so as to match the bright spot. For this reason, if the difference in luminance level between the bright spot and the portion other than the bright spot is large, the exposure amount is insufficient, and the entire image obtained by reading may be dark.
[0004]
SUMMARY OF THE INVENTION An object of the present invention is to provide an image reading apparatus, an image reading program, and an image reading method capable of performing reading with an optimal exposure amount even if a bright spot exists in a document to be read.
[0005]
[Means for Solving the Problems]
The image reading apparatus according to
[0006]
2. The image reading apparatus according to
An image reading apparatus according to a third aspect is the image reading apparatus according to the first or second aspect, wherein the number of divisions by the division unit is variable.
[0007]
An image reading program according to
[0008]
An image reading method according to
[0009]
BEST MODE FOR CARRYING OUT THE INVENTION
Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings. Hereinafter, as an example of the image reading apparatus of the present invention, an image reading apparatus that reads an image printed on a film document by transmitted illumination will be described.
<< 1st Embodiment >>
Hereinafter, a first embodiment of the present invention will be described with reference to the drawings.
[0010]
FIG. 1 is a block diagram illustrating a configuration of the image reading apparatus according to the first embodiment.
As shown in FIG. 1, the
[0011]
As shown in FIG. 1, an
The
[0012]
The illumination light source 9 is composed of light-emitting diodes (LEDs) of each color of RGB, and is sequentially turned on or off according to a drive signal (described later) from an LED drive circuit 12 constituting the
[0013]
The illumination light from the illumination light source 9 is linear light along the x direction (main scanning direction) in FIG. For this reason, the optical path of the illumination light from the illumination light source 9 and the film original 3 intersect at a predetermined line along the x direction (hereinafter, referred to as a “read line 13”).
The
[0014]
The
[0015]
The motor 7 moves the
The
[0016]
Each of the LED driving circuit 12, the CCD driving circuit 14, and the
The
[0017]
The
The external interface 21 is a driver (for example, a SCSI interface) for connecting the
[0018]
Note that the host computer 22 is also provided with an operation unit (not shown) such as a keyboard that receives a user operation such as an instruction to execute prescan and main scan.
A general flow of reading an image in the
[0019]
When a power supply (not shown) is turned on, in step S1, the
Here, the initial operation is a process of moving the
In step S2, the
[0020]
Then, the
In step S3, the
[0021]
In step S <b> 4, the
In step S5, the
[0022]
In step S6, the
Here, the pre-scanning and exposure amount determination processing performed in step S3 will be described with reference to FIGS.
[0023]
When a pre-scan instruction is issued via the operation unit of the host computer 22, in step S11, the
That is, the
[0024]
In step S12, the
Here, as shown in FIG. 4, the blocks are respective areas when the image data to be read is equally divided in P in the x direction and equally divided in Q in the y direction. It is assumed that the number of divisions P in the x direction and the number of divisions Q in the y direction are recorded in the memory 20 in advance.
[0025]
As shown in FIG. 4, when all image data at the time of completion of reading is composed of image data of m pixels in the x direction and image data of n lines in the y direction, one block is in the x direction. Is composed of image data for (m ÷ P) pixels, and in the y direction is composed of image data for (n ラ イ ン Q) lines.
Hereinafter, P blocks arranged in the x direction are collectively referred to as a “block group”.
[0026]
The
In step S13, the
[0027]
That is, the
[0028]
In step S14, as in step S12, the
In step S15, the
[0029]
In step S16, the
That is, the
The processing described in steps S15 and S16 is performed for each group. That is, the replacement of the maximum value is performed only for the group whose maximum luminance value in the block is smaller than the maximum value of the luminance obtained in step S14.
[0030]
In step S17, the
That is, the
[0031]
On the other hand, if the reading for (n ÷ q) lines is not completed, the
In step S18, the
[0032]
For example, the memory 20 is provided with a counter (not shown) for counting the number of blocks to be read, and the
When the reading for all the block groups is completed, the process proceeds to step S20, and when the reading for all the block groups is not completed, the process proceeds to step S19.
[0033]
In step S19, the
First, the
[0034]
Therefore, the
In step S20, the
[0035]
In step S21, the
The
[0036]
As described above, according to the first embodiment, image data obtained by pre-scan is divided into a plurality of blocks. Then, the maximum luminance value in the block is obtained for each block, and the average value of the luminance values is calculated. Then, the exposure amount at the time of the main scan is determined based on the average value. Therefore, even if there is a bright spot in the document to be read, reading can be performed with an optimal exposure amount.
[0037]
<< 2nd Embodiment >>
Hereinafter, a second embodiment of the present invention will be described with reference to the drawings.
The configuration of the image reading apparatus according to the second embodiment is the same as that of the first embodiment, and a description thereof will be omitted. Hereinafter, the description will be given using the same reference numerals as those of the first embodiment.
However, in the second embodiment, a CPU (not shown) of the host computer 22 (hereinafter, referred to as “host-side CPU”) and a memory (hereinafter, “host-side memory”) are used for various controls in the
[0038]
The general flow of image reading in the
Hereinafter, a prescan and an exposure amount determination process, which is different from the process in the
[0039]
When a pre-scan instruction is issued via the operation unit of the host computer 22, in step S31, the host-side CPU reads one line via each unit.
[0040]
The host CPU first outputs a drive signal to the LED drive circuit 12 and the CCD drive circuit 14 to read one line.
In step S32, the host-side CPU transfers one line of image data to the host computer 22 via the
[0041]
In step S33, the host-side CPU determines whether reading for all lines has been completed.
The host-side CPU determines whether reading of all the lines has been completed by determining whether the value of the counter in the host-side memory has reached the total number of lines (n in FIG. 4). . If the reading of all the lines has been completed, the process proceeds to step S34. If the reading of all the lines has not been completed, the process returns to step S31, and the processes of steps S31 to S33 are repeated.
[0042]
In step S34, the host-side CPU equally divides the image data recorded in the host-side memory into (P × Q) blocks as shown in FIG. Here, P is the number of divisions in the x direction (main scanning direction) recorded in the host side memory in advance, and Q is the number of divisions in the y direction (sub scanning direction) recorded in the host side memory in advance. This is the number of divisions.
[0043]
In step S35, the host-side CPU obtains the maximum value of the luminance for each block, and records it in the host-side memory as the maximum luminance value in the block. Therefore, the maximum luminance value in the (P × Q) blocks is recorded in the host side memory.
In step S36, the host-side CPU reads the maximum luminance value in the (P × Q) blocks recorded in the host-side memory, and obtains an average value.
[0044]
In step S37, the host CPU determines the exposure amount during the main scan based on the average value obtained in step S36, as in step S21 of the first embodiment.
Then, the host CPU records the determined exposure amount in the host memory, and ends a series of processing.
[0045]
As described above, according to the second embodiment, the image data obtained by the pre-scan is transferred to the host computer 22 and divided into a plurality of blocks. Then, the maximum luminance value in the block is obtained for each block, and the average value of the luminance values is calculated. Then, the exposure amount at the time of the main scan is determined based on the average value. Therefore, even if there is a bright spot in the document to be read, reading can be performed with an optimal exposure amount.
[0046]
In particular, the processing time can be shortened by transferring the obtained image data to the host computer 22 while performing the pre-scan and performing the processing collectively after the end of the pre-scan.
In the second embodiment, an example is shown in which the data is transferred to the host computer 22 every time one line is read. However, the memory 20 in the
[0047]
Further, in each of the above embodiments, the number of divisions P in the x direction (main scanning direction) and the number of divisions Q in the y direction (sub scanning direction) are predetermined values, but may be variable. In this case, the number of divisions may be set by a user operation, or the number of divisions may be automatically set according to the user's request for accuracy and speed. For example, the number of divisions may be increased when a user requests high-precision reading, and the number of divisions may be decreased when a high-speed reading is requested.
[0048]
In particular, in the second embodiment, at the time when the pre-scan is completed, a luminance histogram of the image data is obtained, and the number of divisions may be increased if a bright spot exists by analyzing the histogram. In each of the above embodiments, the example in which the film original is read using the transmitted illumination is described, but the combination of the original to be read and the illumination may be any combination.
[0049]
Further, in each of the above embodiments, the example in which the exposure time at the time of the main scan is changed according to the exposure amount determined based on the result of the pre-scan has been described. Alternatively, the light amount of the illumination light source 9 during the main scan may be changed according to the determined exposure amount. Further, both the exposure time during the main scan and the light amount of the illumination light source 9 may be changed.
[0050]
Further, in each of the above embodiments, the example in which the
[0051]
【The invention's effect】
As described above, according to the present invention, there is provided an image reading apparatus, an image reading program, and an image reading method capable of reading with an optimal exposure amount even if there is a bright spot in a document to be read. Can be provided.
[Brief description of the drawings]
FIG. 1 is a block diagram illustrating a configuration of an image reading device according to a first embodiment.
FIG. 2 is a flowchart showing a rough flow of image reading in the image reading apparatus according to the first embodiment; FIG. 3 is a flowchart showing a control procedure of the image reading apparatus at the time of pre-scan and exposure amount determination processing.
FIG. 4 is a diagram illustrating division of image data obtained by prescan.
FIG. 5 is a flowchart illustrating a control procedure of the image reading apparatus at the time of prescan and exposure amount determination processing.
[Explanation of symbols]
DESCRIPTION OF
12 LED drive circuit 13 read line 14
19 ROM
Reference Signs List 20 memory 21 external interface 22 host computer
Claims (5)
前記照明手段により照明される前記原稿の画像を予備的に読み取り、画像データを得る予備読取手段と、
前記予備読取手段により得られた前記画像データを複数の領域に分割する分割手段と、
前記分割手段により分割された前記領域ごとに当該領域内の最大輝度値を抽出する抽出手段と、
前記抽出手段により抽出された前記領域ごとの最大輝度値の平均値を算出する平均値算出手段と、
前記平均値算出手段により算出された前記平均値に基づいて、本読取時の前記照明手段による前記露光量を決定する露光量決定手段と、
前記露光量決定手段により決定された前記露光量で前記照明手段により前記原稿を照明させ、該原稿の画像を読み取り、画像データを得る本読取手段と
を備えたことを特徴とする画像読取装置。Illuminating means for illuminating the document with a predetermined exposure amount;
Preliminary reading means for preliminary reading an image of the document illuminated by the illuminating means and obtaining image data;
Dividing means for dividing the image data obtained by the preliminary reading means into a plurality of areas;
Extracting means for extracting a maximum luminance value in the area for each of the areas divided by the dividing means,
Average value calculation means for calculating the average value of the maximum luminance value for each area extracted by the extraction means,
Based on the average value calculated by the average value calculation means, the exposure amount determination means for determining the exposure amount by the illumination means at the time of the main reading,
An image reading apparatus, comprising: a main reading unit that illuminates the document by the illuminating unit with the exposure amount determined by the exposure amount determining unit, reads an image of the document, and obtains image data.
前記分割手段は、前記予備読取手段により得られた前記画像データを、主走査方向および副走査方向の少なくとも一方の方向について分割する
ことを特徴とする画像読取装置。The image reading device according to claim 1,
The image reading apparatus according to claim 1, wherein the dividing unit divides the image data obtained by the preliminary reading unit in at least one of a main scanning direction and a sub-scanning direction.
前記分割手段による分割数は可変である
ことを特徴とする画像読取装置。The image reading device according to claim 1 or 2,
The number of divisions by the division means is variable.
前記照明手段により照明される前記原稿の画像を読み取り、画像データを得る読取手段とを備えた画像読取装置に対する制御をコンピュータで実現するためのプログラムであって、
前記照明手段により照明される前記原稿の画像を予備的に読み取り、画像データを得る予備読取手順と、
前記予備読取手順により得られた前記画像データを複数の領域に分割する分割手順と、
前記分割手順により分割された前記領域ごとに当該領域内の最大輝度値を抽出する抽出手順と、
前記抽出手順により抽出された前記領域ごとの最大輝度値の平均値を算出する平均値算出手順と、
前記平均値算出手順により算出された前記平均値に基づいて、本読取時の前記照明手段による前記露光量を決定する露光量決定手順と、
前記露光量決定手順により決定された前記露光量で前記照明手段により前記原稿を照明させ、該原稿の画像を読み取り、画像データを得る本読取手順と
をコンピュータで実現させることを特徴とする画像読取プログラム。Illuminating means for illuminating the document with a predetermined exposure amount;
A computer-readable storage medium storing a program for reading an image of the document illuminated by the illuminating unit and controlling the image reading apparatus including a reading unit configured to obtain image data,
Preliminary reading procedure for preliminary reading an image of the document illuminated by the illuminating means and obtaining image data;
A division procedure of dividing the image data obtained by the preliminary reading procedure into a plurality of areas;
An extracting step of extracting a maximum luminance value in the area for each of the areas divided by the dividing procedure,
An average value calculation step of calculating an average value of the maximum luminance value for each area extracted by the extraction step,
Based on the average value calculated by the average value calculation step, an exposure amount determination step of determining the exposure amount by the illumination unit at the time of main reading,
Image reading wherein the document is illuminated by the illuminating means with the exposure amount determined by the exposure amount determining step, an image of the document is read, and a main reading step of obtaining image data is realized by a computer. program.
前記照明工程により照明される前記原稿の画像を予備的に読み取り、画像データを得る予備読取工程と、
前記予備読取工程により得られた前記画像データを複数の領域に分割する分割工程と、
前記分割工程により分割された前記領域ごとに当該領域内の最大輝度値を抽出する抽出工程と、
前記抽出工程により抽出された前記領域ごとの最大輝度値の平均値を算出する平均値算出工程と、
前記平均値算出工程により算出された前記平均値に基づいて、本読取時の前記照明工程による前記露光量を決定する露光量決定工程と、
前記露光量決定工程により決定された前記露光量で前記照明工程により前記原稿を照明させ、該原稿の画像を読み取り、画像データを得る本読取工程と
を備えたことを特徴とする画像読取方法。An illumination step of illuminating the original with a predetermined exposure amount,
Preliminary reading step of preliminary reading an image of the document illuminated by the illumination step and obtaining image data;
A dividing step of dividing the image data obtained in the preliminary reading step into a plurality of regions;
An extracting step of extracting a maximum luminance value in the area for each of the areas divided by the dividing step,
An average value calculation step of calculating an average value of the maximum luminance value for each of the regions extracted by the extraction step,
Based on the average value calculated by the average value calculation step, an exposure amount determination step of determining the exposure amount by the illumination step at the time of main reading,
A main reading step of illuminating the document in the illumination step with the exposure amount determined in the exposure amount determining step, reading an image of the document, and obtaining image data.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2003082813A JP2004297128A (en) | 2003-03-25 | 2003-03-25 | Image reading apparatus, image reading program and image reading method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2003082813A JP2004297128A (en) | 2003-03-25 | 2003-03-25 | Image reading apparatus, image reading program and image reading method |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2004297128A true JP2004297128A (en) | 2004-10-21 |
Family
ID=33398475
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2003082813A Pending JP2004297128A (en) | 2003-03-25 | 2003-03-25 | Image reading apparatus, image reading program and image reading method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2004297128A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2010166550A (en) * | 2009-01-16 | 2010-07-29 | Genesys Logic Inc | Image processor having optical source intensity compensation function, intensity compensation apparatus, scanning system and method of the same |
US7768674B2 (en) * | 2006-02-21 | 2010-08-03 | Seiko Epson Corporation | Exposure determining device and exposure determining method |
-
2003
- 2003-03-25 JP JP2003082813A patent/JP2004297128A/en active Pending
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7768674B2 (en) * | 2006-02-21 | 2010-08-03 | Seiko Epson Corporation | Exposure determining device and exposure determining method |
JP2010166550A (en) * | 2009-01-16 | 2010-07-29 | Genesys Logic Inc | Image processor having optical source intensity compensation function, intensity compensation apparatus, scanning system and method of the same |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4997204B2 (en) | Image reading apparatus and image reading method | |
JPH114323A (en) | Image reader | |
US7023591B2 (en) | Image scanning apparatus, storage medium for storing controlling procedure of image scanning apparatus, and control program for image scanning apparatus | |
US7091461B2 (en) | Light source control method and apparatus of image scanner | |
US7190493B2 (en) | Image reading apparatus and image reading method | |
US7929806B2 (en) | Image reading apparatus and image reading method | |
JP2004297128A (en) | Image reading apparatus, image reading program and image reading method | |
JP2004032167A (en) | Image reading system and image reading processing system | |
JP2001169055A (en) | Illumination system for scanner and its operating method | |
JPH03187569A (en) | Picture reader | |
JP5462522B2 (en) | Image processing apparatus, image processing method, and program for causing computer to realize the image processing method | |
US20030202225A1 (en) | Image reading apparatus | |
JP2004126284A (en) | Image read unit and image reader | |
JP2001036744A (en) | Image reading method, image reader and image processor | |
JPH117523A (en) | Image reader | |
US6489601B1 (en) | Correction method for an image reading system | |
JP3154131B2 (en) | Reading method | |
JPH0380668A (en) | High quality of image scanner | |
JP2005184390A (en) | Original reading apparatus, computer program, original reading system, and original reading method | |
US6744543B1 (en) | System and method for scanning a document | |
JP2002171388A (en) | Image reader and storage medium with controlling procedure stored thereon | |
JP4181732B2 (en) | Image discrimination method, image processing method using the same, and recording medium | |
JP2005117657A (en) | Method and apparatus for selective illumination in scanner | |
JP2608264B2 (en) | Image reading device | |
JPH07170436A (en) | Picture input device |