JPH10173920A - Image reader - Google Patents

Image reader

Info

Publication number
JPH10173920A
JPH10173920A JP8335517A JP33551796A JPH10173920A JP H10173920 A JPH10173920 A JP H10173920A JP 8335517 A JP8335517 A JP 8335517A JP 33551796 A JP33551796 A JP 33551796A JP H10173920 A JPH10173920 A JP H10173920A
Authority
JP
Japan
Prior art keywords
image
dot
reading
image data
continuous
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP8335517A
Other languages
Japanese (ja)
Inventor
Kenichi Yamamoto
健一 山本
Satoru Oishi
哲 大石
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.)
TEC CORP
Original Assignee
TEC CORP
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 TEC CORP filed Critical TEC CORP
Priority to JP8335517A priority Critical patent/JPH10173920A/en
Publication of JPH10173920A publication Critical patent/JPH10173920A/en
Pending legal-status Critical Current

Links

Landscapes

  • Image Processing (AREA)
  • Facsimile Image Signal Circuits (AREA)

Abstract

PROBLEM TO BE SOLVED: To read an original accurately even on the occurrence of a dirty original or a defective CCD sensor. SOLUTION: This image reader is provided with a CCD sensor that reads an original image optically and that binarizes dot image data obtained by reading the image with the CCD sensor based on a prescribed threshold level. The reader is provided with a memory device storing tentatively the dot image data obtained by reading the image with the CCD sensor, the dot image data from the memory device are binarized by setting at first the threshold level to be an initial value, a maximum number of consecutive same kinds of dots in the binarized data is detected and when the maximum number reaches a prescribed value or over, the threshold level is changed and the dot image data are again binarized based on the threshold level after the revision.

Description

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

【0001】[0001]

【発明の属する技術分野】本発明は、原稿に描かれた手
書き文字や印刷文字等の画像を読取る画像読取装置に関
する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an image reading apparatus for reading images such as handwritten characters and printed characters drawn on a document.

【0002】[0002]

【従来の技術】この種の画像読取装置は、読取ガラスに
セットした原稿に沿って移動しながら光を照射しその反
射光をCCD(電荷結合素子)センサで1ラインごとに
取込み、その取込まれたドットデータからなる画像デー
タをCCD制御回路で電子的画像情報(例えば画像濃度
を256バイトで表現した中間調データ)に変換してメ
モリ装置へ記憶するようになっている。そして、メモリ
装置から画像データを取出して予め定められた閾値で2
値化した2値化データをホストコンピュータへ転送する
ようになっている。
2. Description of the Related Art An image reading apparatus of this type irradiates light while moving along a document set on a reading glass, and captures reflected light of the light by a CCD (Charge Coupled Device) sensor line by line. The image data composed of the dot data is converted into electronic image information (for example, halftone data in which the image density is represented by 256 bytes) by a CCD control circuit and stored in a memory device. Then, the image data is taken out from the memory device and is set to 2 by a predetermined threshold value.
The binarized data is transferred to the host computer.

【0003】しかしながら、2値化するための閾値は、
CCDセンサや光源である発光素子、原稿の背景色、原
稿に手書き文字を書く場合のペンの種類等によってその
最適値が異なる。このため、従来は、メモリ装置から画
像データの1ライン分ごとに読取濃度の最大値を検出
し、その最大値の1/2を閾値としその閾値を使用して
2値化するようにしていた。
However, the threshold for binarization is
The optimum value differs depending on the CCD sensor, the light emitting element which is a light source, the background color of the original, the type of pen for writing handwritten characters on the original, and the like. For this reason, conventionally, the maximum value of the read density has been detected for each line of image data from the memory device, and a half of the maximum value has been set as a threshold, and binarized using the threshold. .

【0004】このような画像読取装置の制御部本体を構
成するMPU(マイクロ・プロセッサ・ユニット)が行
う画像読取制御を図6を参照しながら具体的に説明す
る。MPUは先ずST(ステップ)1にてCCDセンサ
を制御して原稿1ぺージ分の画像データを取込ませる。
するとこの画像データは次々とCCD制御回路で中間調
データに変換され、メモリ装置へ記憶される。
The image reading control performed by an MPU (microprocessor unit) constituting the control section main body of such an image reading apparatus will be specifically described with reference to FIG. The MPU first controls the CCD sensor in ST (step) 1 to capture image data for one page of the document.
Then, the image data is successively converted into halftone data by the CCD control circuit and stored in the memory device.

【0005】次に、ST2にてメモリ装置から1ライン
分の画像データ(既に変換されている中間調データ)を
取出し、ST3にてその1ライン分の画像データについ
て読取濃度の最大値を検出する。続いて、ST4にて読
取濃度の最大値の1/2を閾値として当該画像データを
2値化して、ST5にてその2値化データをホストコン
ピュータへ転送する。そして、ST6にて2値化データ
を1ぺージ分転送したか否かを判断する。このとき、未
だ1ぺージ分転送していないと判断した場合はST2の
処理に戻り、1ぺージ分転送したと判断した場合はこの
画像読取制御を終了する。
Next, in ST2, one line of image data (halftone data that has already been converted) is extracted from the memory device, and in ST3, the maximum value of the read density is detected for the one line of image data. . Subsequently, in ST4, the image data is binarized using 1/2 of the maximum value of the read density as a threshold, and in ST5, the binarized data is transferred to the host computer. Then, in ST6, it is determined whether or not the binary data has been transferred for one page. At this time, if it is determined that one page has not been transferred yet, the process returns to ST2, and if it is determined that one page has been transferred, the image reading control ends.

【0006】[0006]

【発明が解決しようとする課題】しかし、このような画
像読取装置においては、1ラインごとに画像データの読
取濃度の最大値を検出してその最大値に基いて2値化す
るための閾値を決定していたが、常に最大値の1/2を
閾値としていたため、原稿画像に描かれた文字の背景状
態(図7又は図8に示すような原稿の背景色の違いや図
4(a)に示すような原稿の汚れ等)やCCDセンサ不
良等によっては読取り不良となる場合があった。
However, in such an image reading apparatus, a threshold value for detecting the maximum value of the read density of the image data for each line and binarizing it based on the maximum value is set. However, since the threshold value is always set to の of the maximum value, the background state of the character drawn on the document image (the background color difference of the document as shown in FIG. 7 or FIG. In some cases, the reading may be defective due to the contamination of the original as shown in FIG.

【0007】すなわち、図7に示すように原稿の汚れ等
がない場合には、文字を構成する線の部分についての読
取濃度はその周囲に比して高いレベルとなるため、読取
濃度の最大値の1/2を閾値として2値化すれば文字の
線部分だけが黒ドットとなり、良好な画像を読取ること
ができるが、図8に示すように原稿の汚れ等がある場合
には、文字を構成する線の部分についての読取濃度はそ
の周囲とあまり変わらないレベルとなるため、読取濃度
の最大値の1/2を閾値として2値化しても汚れの部分
まで黒ドットとなってしまい、文字の画像を良好に読取
ることができない。
That is, as shown in FIG. 7, when there is no dirt on the original, the reading density of the line portion constituting the character is higher than its surroundings, so that the maximum reading density When the binarization is performed using 1/2 of the threshold value as a threshold value, only the line portion of the character becomes a black dot and a good image can be read. However, when the original is stained as shown in FIG. Since the reading density of the line portion constituting the reading density is not much different from the surrounding area, even if binarization is performed using 1/2 of the maximum value of the reading density as a threshold value, black dots are formed even in the stained portion, and the characters are not printed. Cannot be read well.

【0008】つまり、図8に示す例では原稿画像の文字
「い」と「う」の間の読取濃度レベルは閾値よりも高い
レベルになるため、黒ドットが連続してしまう。その結
果、このような2値化データをホストコンピュータへ転
送した場合に、ホストコンピュータ側でその文字を正し
く認識できないこととなる。
In other words, in the example shown in FIG. 8, the read density level between the characters "I" and "U" of the original image is higher than the threshold value, so that black dots continue. As a result, when such binary data is transferred to the host computer, the host computer cannot correctly recognize the character.

【0009】そこで、本発明は、原稿の汚れやCCDセ
ンサ不良等があっても、原稿画像を正確に読取ることが
できる画像読取装置を提供しようとするものである。
Accordingly, an object of the present invention is to provide an image reading apparatus capable of accurately reading a document image even if the document is stained or a CCD sensor is defective.

【0010】[0010]

【課題を解決するための手段】請求項1の本発明は、原
稿画像を光学的に読取る光学読取手段を設け、この光学
読取手段によって読取って得られたドット画像データを
所定の閾値で2値化する画像読取装置において、光学読
取手段によって読取って得られたドット画像データを一
時的に記憶しておくドット画像データ記憶手段と、この
ドット画像データ記憶手段からのドット画像データを2
値化する2値化手段と、この2値化手段により得られた
2値化データのうち連続する同種のドットの最大数を検
出する連続ドット数検出手段と、この連続ドット検出手
段で検出した最大数が所定値以上となるときに、閾値を
変更してその変更後の閾値で2値化手段によりドット画
像データ記憶手段からのドット画像データを2値化する
2値化制御手段とを設けたものである。
According to a first aspect of the present invention, there is provided an optical reading means for optically reading an original image, and dot image data obtained by reading the original image is binarized by a predetermined threshold value. A dot image data storage unit for temporarily storing dot image data obtained by reading by an optical reading unit, and a dot image data from the dot image data storage unit.
Binarizing means for binarizing, continuous dot number detecting means for detecting the maximum number of continuous dots of the same kind in the binarized data obtained by the binarizing means; When the maximum number is equal to or greater than a predetermined value, a threshold value is changed, and binarization control means for binarizing the dot image data from the dot image data storage means by the binarization means with the changed threshold value is provided. It is a thing.

【0011】請求項2の本発明は、連続ドット数検出手
段は、2値化手段により得られた2値化データのうち光
学読取手段で読取るライン方向に連続する同種のドット
の最大数を検出する請求項1記載の画像読取装置であ
る。
According to a second aspect of the present invention, the continuous dot number detecting means detects the maximum number of the same kind of dots continuous in the line direction read by the optical reading means among the binary data obtained by the binarizing means. The image reading device according to claim 1.

【0012】請求項3の本発明は、連続ドット数検出手
段は、2値化手段により得られた2値化データのうち光
学読取手段で読取るライン方向と直角方向に連続する同
種のドットの最大数を検出する請求項1記載の画像読取
装置である。
According to a third aspect of the present invention, in the continuous dot number detecting means, the maximum of the same kind of dots continuous in the direction perpendicular to the line direction read by the optical reading means is selected from the binarized data obtained by the binarizing means. 2. The image reading device according to claim 1, wherein the number is detected.

【0013】請求項4の本発明は、連続ドット数検出手
段は2値化手段により得られた2値化データのうち光学
読取手段で読取るライン方向に連続する同種のドットの
ライン方向最大数及びライン方向に直角な方向に連続す
る同種のドットの直角方向最大数を検出し、2値化制御
手段は連続ドット検出手段で検出したライン方向最大数
がライン方向の所定値以上となるとき、又は直角方向最
大数が直角方向所定値以上となるときに、閾値を変更し
てその変更後の閾値で2値化手段によりドット画像デー
タ記憶手段からのドット画像データを2値化する請求項
1記載の画像読取り装置である。
According to a fourth aspect of the present invention, the continuous dot number detecting means includes, in the binarized data obtained by the binarizing means, the maximum number in the line direction of the same kind of continuous dots in the line direction read by the optical reading means; Detecting the maximum number of the same kind of dots continuous in the direction perpendicular to the line direction in the perpendicular direction, and the binarization control means when the maximum number in the line direction detected by the continuous dot detection means is equal to or more than a predetermined value in the line direction, or 2. The method according to claim 1, wherein when the maximum number in the right-angle direction is equal to or more than a predetermined value in the right-angle direction, the threshold value is changed, and the binarized means binarizes the dot image data from the dot image data storage means with the changed threshold value. Image reading device.

【0014】[0014]

【発明の実施の形態】以下、本発明の第1の実施の形態
を図1ないし図4を参照して説明する。図1は、本実施
の形態における画像読取装置の構成を示す図で、1はこ
の装置の制御部本体を構成するMPU(マイクロ・プロ
セッサ・ユニット)、2はMPUが各部を制御するため
のプログラム等が記憶されたROM、3は原稿画像を光
学的に読取るCCDセンサ4で原稿画像を読取ったとき
の画像データをいわゆる白補正や黒補正等を施して電子
的画像情報(例えば画像濃度を256バイトで表現した
中間調データ)に変換するCCD制御回路、5はCCD
制御回路3からの画像データを一時的に記憶しておくメ
モリ装置、6はホストコンピュータ7等を通信回線を介
して接続するインタフェースである。上記MPU1と、
ROM2、CCD制御回路3、メモリ装置5、インタフ
ェース6とはデータバス、制御バス、アドレスバス等の
バスライン8で電気的に接続されている。また、MPU
1には、図示しない内部メモリが設けられ、外部のメモ
リ装置3から画像データを取出して2値化等のデータ処
理を行うことができるようになっている。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS Hereinafter, a first embodiment of the present invention will be described with reference to FIGS. FIG. 1 is a diagram showing a configuration of an image reading apparatus according to the present embodiment. Reference numeral 1 denotes an MPU (microprocessor unit) constituting a control unit main body of the apparatus, and 2 denotes a program for the MPU to control each unit. ROM 3 stores electronic image information (for example, when image density is 256) by applying so-called white correction or black correction to image data obtained when the original image is read by the CCD sensor 4 for optically reading the original image. CCD control circuit for converting into halftone data expressed in bytes)
A memory device 6 for temporarily storing image data from the control circuit 3 is an interface for connecting a host computer 7 and the like via a communication line. The above MPU1,
The ROM 2, the CCD control circuit 3, the memory device 5, and the interface 6 are electrically connected by a bus line 8 such as a data bus, a control bus, and an address bus. Also, MPU
1 is provided with an internal memory (not shown) so that image data can be extracted from an external memory device 3 and data processing such as binarization can be performed.

【0015】上記CCDセンサ4は、図示はしないCC
Dユニットに搭載される。このCCDユニットは、例え
ば複数のLED(発光ダイオード)を一列に配設したL
EDアレイ、このLEDアレイで照射した原稿からの反
射光を受ける集光レンズ等から構成され、CCDセンサ
4は原稿からの反射光を集光レンズを介して入力するよ
うになっている。このCCDユニットは原稿を図示しな
い読取ガラス上に載置して読取る場合は、原稿の対向位
置をその原稿に沿って移動する。なお、原稿をADF
(自動紙送装置)で読取らせる場合は、CCDユニット
は所定位置に停止した状態で原稿がCCDユニットの対
向面をフィードするように原稿を搬送制御してもよい。
The CCD sensor 4 includes a CC (not shown).
Mounted on D unit. This CCD unit has, for example, an L in which a plurality of LEDs (light emitting diodes) are arranged in a line.
The CCD sensor 4 includes an ED array, a condensing lens that receives reflected light from the document irradiated by the LED array, and the like, and the CCD sensor 4 receives the reflected light from the document via the condensing lens. When the CCD unit reads a document placed on a reading glass (not shown), the CCD unit moves the position facing the document along the document. Note that the manuscript must be ADF
When reading is performed by an (automatic paper feeder), the conveyance of the document may be controlled such that the document is fed to the opposite surface of the CCD unit while the CCD unit is stopped at a predetermined position.

【0016】上記MPU1は、例えば画像読取装置の読
取ガラス上に原稿が載置され、ホストコンピュータ7か
ら原稿読取を開始させる指令があると、図2に示すよう
な画像読取制御を行うようになっている。すなわち、M
PU1は先ずST11にてCCDユニットを原稿に対向
して移動制御させてCCDセンサ4により原稿画像を1
ラインごとに読取らせる。すると、CCDセンサ4から
の画像データは、CCD制御回路3で白補正や黒補正等
の処理が施されて例えば読取濃度を256バイトで表現
する中間調データとして変換され、メモリ制御装置5へ
次々と記録される。
The MPU 1 performs an image reading control as shown in FIG. 2 when a document is placed on a reading glass of an image reading device and a command to start reading the document is received from the host computer 7. ing. That is, M
First, at step ST11, the PU 1 controls the movement of the CCD unit so as to face the original, and the CCD sensor 4 converts the original image into one.
Read each line. Then, the image data from the CCD sensor 4 is subjected to processing such as white correction and black correction by the CCD control circuit 3 and is converted as halftone data expressing the read density in 256 bytes, for example, and is successively sent to the memory controller 5. Is recorded.

【0017】続いて、ST12にて2値化のための閾値
を、読取濃度の最大値における所定の割合として初期化
する。例えば、中間調データが256バイトで構成され
る場合、1ライン中の読取濃度の最大値の3/16程度
の比較的低いレベルに初期化する。ST13にてメモリ
装置5から1ライン分の画像データを取出して、ST1
4にてその画像データの読取濃度の最大値を検出し、そ
の最大値に基いて得られた閾値で2値化して黒ドット及
び白ドットの2値化データに変換する(2値化手段)。
Subsequently, in ST12, a threshold value for binarization is initialized as a predetermined ratio in the maximum value of the read density. For example, when the halftone data is composed of 256 bytes, it is initialized to a relatively low level of about 3/16 of the maximum value of the read density in one line. In ST13, one line of image data is extracted from the memory device 5, and ST1 is read.
In step 4, the maximum value of the read density of the image data is detected, binarized by a threshold obtained based on the maximum value, and converted into binary data of black dots and white dots (binarization means). .

【0018】そして、ST15にて2値化データのうち
CCDセンサ4で読取るライン方向に連続するドット数
の最大値nを検出し、ST16にてこの最大値nが所定
値以上か否かを判断する(連続ドット数検出手段)。こ
の所定値は、読取らせる原稿画像の性質によって最適な
値に設定すべきであるが、例えば鉛筆やボールペンで手
書き文字が描かれた原稿画像の場合は、線幅がある程度
の範囲(ドット幅)内に特定されるため、その範囲(ド
ット幅)を所定値として設定すればよい。具体的には、
300DPIの解像度において、0.8mmのボールペ
ンで文字等を描いた場合は、9ドット程度に設定すると
よい。
In step ST15, the maximum value n of the number of continuous dots in the line direction read by the CCD sensor 4 is detected from the binary data, and it is determined in step ST16 whether the maximum value n is equal to or larger than a predetermined value. (Consecutive dot number detecting means). This predetermined value should be set to an optimum value according to the nature of the original image to be read. For example, in the case of an original image in which handwritten characters are drawn with a pencil or a ballpoint pen, the line width is within a certain range (dot width). ), The range (dot width) may be set as a predetermined value. In particular,
At a resolution of 300 DPI, when a character or the like is drawn with a 0.8 mm ball-point pen, it may be set to about 9 dots.

【0019】ST16にて黒ドットの連続するドット数
の最大値nが所定値以上でないと判断した場合は、ST
17にて2値化データをホストコンピュータ7へ転送
し、ST18の処理に移る。すなわち、ST18にて1
ぺージ分の2値化データをホストコンピュータ7へ転送
したか否かを判断する。このとき、1ぺージ分の2値化
データをホストコンピュータ7へ転送したと判断した場
合は、この画像読取制御を終了し、1ぺージ分の2値化
データをホストコンピュータ7へ転送していないと判断
した場合は、ST14の処理に戻る。
If it is determined in ST16 that the maximum value n of the number of consecutive black dots is not greater than a predetermined value, the process proceeds to ST16.
At 17, the binary data is transferred to the host computer 7, and the process proceeds to ST18. That is, in ST18, 1
It is determined whether or not the page of binary data has been transferred to the host computer 7. At this time, if it is determined that the one-page binary data has been transferred to the host computer 7, the image reading control is terminated and the one-page binary data has been transferred to the host computer 7. If it is determined that there is not, the process returns to ST14.

【0020】これに対して、ST16にて黒ドットの連
続するドット数の最大値nが所定値以上であると判断し
た場合は、ST19にて2値化するための閾値を所定量
だけ変更してST13の処理に戻る(2値化制御手
段)。この所定量は、読取濃度の最大値に対する割合
で、処理速度や読取精度等の関係で決定するとよい。例
えば閾値の初期値が上述した読取濃度の最大値の3/1
6である場合、読取濃度の最大値の1/16を所定量と
して加えてこれを新たな閾値として2値化する。
On the other hand, if it is determined in ST16 that the maximum value n of the number of consecutive black dots is equal to or greater than a predetermined value, the threshold for binarization is changed by a predetermined amount in ST19. To return to the process of ST13 (binary control means). This predetermined amount may be a ratio to the maximum value of the reading density, and may be determined in relation to the processing speed, reading accuracy, and the like. For example, the initial value of the threshold value is 3/1 of the maximum value of the read density described above.
In the case of 6, 1/16 of the maximum value of the reading density is added as a predetermined amount, and this is binarized as a new threshold value.

【0021】このような構成の本発明の実施の形態にお
いては、原稿画像を読取る場合には、CCDセンサ4で
原稿画像を取込み、その画像データをCCD制御回路3
で中間調データに変換してメモリ装置5へ1ぺージ分記
録する。
In the embodiment of the present invention having such a configuration, when reading an original image, the original image is captured by the CCD sensor 4 and the image data is transferred to the CCD control circuit 3.
The data is converted into halftone data and recorded in the memory device 5 for one page.

【0022】このメモリ装置5から画像データを1ライ
ンごとに取出し、2値化する。このとき、最初は図3に
示すように閾値の初期値で2値化を行い、そのラインの
2値化データで連続する黒ドット数の最大値が所定値以
上の場合は、閾値が所定量だけ大きくなるように変更し
て再度2値化する。そして、黒ドット数の最大値が所定
値以上でなくなるまで閾値を変更して2値化する処理を
繰返す。こうして、最適な閾値で2値化された2値化デ
ータがホストコンピュータ7へ転送される。
Image data is taken out from the memory device 5 line by line and binarized. At this time, first, as shown in FIG. 3, binarization is performed with the initial value of the threshold, and when the maximum value of the number of continuous black dots in the binarized data of the line is equal to or more than a predetermined value, the threshold is set to a predetermined And then binarize again. Then, the processing of changing the threshold value and binarizing is repeated until the maximum value of the number of black dots does not exceed the predetermined value. Thus, the binarized data binarized with the optimum threshold is transferred to the host computer 7.

【0023】従って、図4(a)に示すように読取りの
対象となる原稿に手書き文字が描かれ、そこに幅のある
汚れAがある場合、最初に2値化されるときの閾値がそ
のラインの読取濃度の最大値の3/16であるとする
と、その閾値で得られた2値化データは原稿の汚れAの
部分で黒ドットが連続することになる。
Accordingly, as shown in FIG. 4A, when a handwritten character is drawn on a document to be read and there is a wide dirt A there, the threshold value at the time of first binarization is set to the threshold value. If the read density of the line is 3/16 of the maximum value, then the binarized data obtained at the threshold value will have continuous black dots at the stain A portion of the document.

【0024】このような場合には、その連続する黒ドッ
ト数が所定値以上となるため、閾値を3/16に1/1
6を加えた読取濃度の最大値の4/16として2値化す
る。それでも、連続する黒ドット数が所定値以上となれ
ば、閾値を読取濃度の最大値の5/16、6/16、…
と上昇させて2値化を行っていき、最終的に連続する黒
ドット数が所定値以上でなくなるまでこれを繰返す。す
ると、所定幅の線のデータのみが黒ドットとなるような
2値化データが得られる。
In such a case, since the number of consecutive black dots is equal to or more than a predetermined value, the threshold value is reduced to 1/16 to 3/16.
The binarization is performed as 4/16 of the maximum value of the reading density obtained by adding 6 to the value. Even so, if the number of consecutive black dots is equal to or more than a predetermined value, the threshold value is set to 5/16, 6/16,.
And the binarization is performed, and this is repeated until the number of continuous black dots finally becomes smaller than a predetermined value. Then, binarized data is obtained such that only data of a line having a predetermined width becomes a black dot.

【0025】このように、本実施の形態では、原稿の幅
方向(CCDセンサ4の読取ライン方向)に原稿画像の
文字よりも広い汚れやCCDセンサ不良があったり、原
稿の背景色が文字の濃度に近い場合でも、適切な閾値で
2値化することができるため、原稿画像を正確に読取る
ことができる。これにより、ホストコンピュータ7にお
ける手書き文字の文字認識等の精度が向上する。
As described above, in the present embodiment, there is dirt or CCD sensor failure wider than the characters in the document image in the width direction of the document (the reading line direction of the CCD sensor 4), or the background color of the document is Even when the density is close to the density, the image can be binarized with an appropriate threshold value, so that the original image can be read accurately. This improves the accuracy of the host computer 7 in character recognition of handwritten characters and the like.

【0026】次に、本発明の第2の実施の形態について
図4及び図5を参照して説明する。なお、本実施の形態
における制御部の構成は図1に示すものと同様であるた
め、その詳細な説明を省略する。
Next, a second embodiment of the present invention will be described with reference to FIGS. Note that the configuration of the control unit according to the present embodiment is the same as that shown in FIG. 1, and a detailed description thereof will be omitted.

【0027】MPU1は、例えば画像読取装置の読取ガ
ラス上に原稿が載置され、ホストコンピュータ7から原
稿読取を開始させる指令があると、図5に示すような画
像読取制御を行うようになっている。すなわち、MPU
1は先ずST21にてCCDユニットを原稿に対向して
移動制御させてCCDセンサ4により原稿画像を1ライ
ンごとに読取らせる。すると、CCDセンサ4からの画
像データは、CCD制御回路3で白補正や黒補正等の処
理が施されて例えば読取濃度を256バイトで表現する
中間調データとして変換され、メモリ制御装置5へ次々
と記録される。続いて、ST22にて2値化のための閾
値を、読取濃度の最大値における所定の割合として初期
化する。例えば、中間調データが256バイトで構成さ
れる場合、1ライン中の読取濃度の最大値の3/16程
度の比較的低いレベルに初期化する。ST23にてメモ
リ装置5から画像データを取出して、その画像データの
読取濃度の最大値を検出し、その最大値に基いて得られ
た閾値で1ぺージ分を2値化して黒ドット及び白ドット
の2値化データに変換する(2値化手段)。
The MPU 1 performs image reading control as shown in FIG. 5, for example, when an original is placed on a reading glass of an image reading apparatus and a command to start reading the original is received from the host computer 7. I have. That is, MPU
First, in ST21, the movement of the CCD unit is controlled so as to face the original, and the original image is read line by line by the CCD sensor 4. Then, the image data from the CCD sensor 4 is subjected to processing such as white correction and black correction by the CCD control circuit 3 and is converted as halftone data expressing the read density in 256 bytes, for example, and is successively sent to the memory controller 5. Is recorded. Subsequently, in ST22, a threshold value for binarization is initialized as a predetermined ratio of the maximum value of the read density. For example, when the halftone data is composed of 256 bytes, it is initialized to a relatively low level of about 3/16 of the maximum value of the read density in one line. In ST23, the image data is taken out from the memory device 5, the maximum value of the read density of the image data is detected, and one page is binarized with a threshold obtained based on the maximum value to obtain black dots and white dots. The data is converted into dot binary data (binarization means).

【0028】そして、ST24にて2値化データのうち
黒ドットが原稿の縦方向(CCDセンサ4の読取ライン
に直角の方向)に連続するライン数の最大値mを検出し
(連続ドット数検出手段)、ST25にてこの最大値m
が所定値以上か否かを判断する。この所定値は、読取ら
せる原稿画像の汚れ等の性質によって最適な値に設定す
べきであるが、例えば複写機やファックシミリによって
得られた原稿には、縦方向に細長いライン状の汚れが現
れ易いため、このような汚れのついた原稿を読取る場合
は、原稿の縦サイズの1/2程度のドット長さを所定値
として設定すればよい。
In step ST24, the maximum value m of the number of lines in which the black dots continue in the vertical direction of the document (in the direction perpendicular to the read line of the CCD sensor 4) is detected from the binary data (detection of the number of continuous dots). Means), this maximum value m in ST25
Is determined to be greater than or equal to a predetermined value. This predetermined value should be set to an optimal value depending on the nature of the original image to be read, such as dirt, but, for example, an original obtained by a copying machine or a facsimile may have long and thin line-shaped dirt in the vertical direction. In order to read such a dirty original, a dot length of about の of the vertical size of the original may be set as the predetermined value.

【0029】ST25にて黒ドットの連続するライン数
の最大値mが所定値以上でないと判断した場合は、ST
26にて2値化データをホストコンピュータ7へ転送
し、ST27の処理に移る。すなわち、ST27にて1
ぺージ分の2値化データをホストコンピュータ7へ転送
したか否かを判断する。このとき、1ぺージ分の2値化
データをホストコンピュータ7へ転送したと判断した場
合は、この画像読取制御を終了する。
If it is determined in step ST25 that the maximum value m of the number of continuous lines of black dots is not greater than a predetermined value, the process proceeds to step ST25.
At 26, the binary data is transferred to the host computer 7, and the process proceeds to ST27. That is, in ST27, 1
It is determined whether or not the page of binary data has been transferred to the host computer 7. At this time, if it is determined that one page of the binary data has been transferred to the host computer 7, the image reading control ends.

【0030】これに対して、ST25にて黒ドットの連
続するライン数の最大値mが所定値以上であると判断し
た場合は、ST28にて2値化するための閾値を所定量
だけ変更してST23の処理に戻る(2値化制御手
段)。この所定量は、読取濃度の最大値に対する割合
で、処理速度や読取精度等の関係で決定するとよい。例
えば閾値の初期値が上述した読取濃度の最大値の3/1
6である場合、読取濃度の最大値の1/16を所定量と
して加えてこれを新たな閾値として2値化する。
On the other hand, if it is determined in ST25 that the maximum value m of the number of continuous lines of black dots is equal to or greater than a predetermined value, the threshold for binarization is changed by a predetermined amount in ST28. To return to the processing of ST23 (binary control means). This predetermined amount may be a ratio to the maximum value of the reading density, and may be determined in relation to the processing speed, reading accuracy, and the like. For example, the initial value of the threshold value is 3/1 of the maximum value of the read density described above.
In the case of 6, 1/16 of the maximum value of the reading density is added as a predetermined amount, and this is binarized as a new threshold value.

【0031】このような構成の本発明の実施の形態にお
いては、原稿画像を読取る場合には、CCDセンサ4で
原稿画像を取込み、その画像データをCCD制御回路3
で中間調データに変換してメモリ装置5へ1ぺージ分記
録する。
In the embodiment of the present invention having such a configuration, when reading an original image, the original image is captured by the CCD sensor 4 and the image data is transferred to the CCD control circuit 3.
The data is converted into halftone data and recorded in the memory device 5 for one page.

【0032】このメモリ装置5から画像データを取出
し、1ぺージ分を2値化する。このとき、その1ぺージ
分の2値化データで黒ドットが原稿の縦方向に連続する
ライン数の最大値が所定値以上である場合は、閾値を変
更して再度2値化する。そして、黒ドットが連続するラ
イン数の最大値が所定値以上でなくなるまで閾値を変更
して2値化する処理を繰返す。こうして得られた2値化
データをホストコンピュータ7へ転送する。
Image data is fetched from the memory device 5 and one page is binarized. At this time, if the maximum value of the number of lines in which the black dot continues in the vertical direction of the document is equal to or larger than a predetermined value in the one-page binary data, the threshold is changed and binarization is performed again. Then, the processing of changing the threshold value and binarizing is repeated until the maximum value of the number of lines of continuous black dots does not exceed the predetermined value. The binary data thus obtained is transferred to the host computer 7.

【0033】従って、図4(a)に示すように読取りの
対象となる原稿に手書き文字が描かれ、そこに原稿の縦
方向に長くなる汚れAやライン状の汚れBがある場合、
最初に2値化されるときの閾値がそのラインの読取濃度
の最大値の3/16であるとすると、その閾値で得られ
た2値化データは原稿の汚れA,Bの部分で黒ドットが
連続することになる。
Therefore, as shown in FIG. 4A, when a handwritten character is drawn on a document to be read and there is a dirt A or a line-shaped dirt B elongated in the vertical direction of the document.
Assuming that the threshold value at the time of the first binarization is 3/16 of the maximum value of the read density of the line, the binarized data obtained at the threshold value is a black dot at the stains A and B of the original. Will be continuous.

【0034】このような場合には、その連続する黒ドッ
トのライン数が所定値以上となるため、閾値を3/16
に1/16を加えた読取濃度の最大値の4/16として
2値化する。それでも、連続する黒ドット数が所定値以
上となれば、閾値を読取濃度の最大値の5/16、6/
16、…と上昇させて2値化を行っていき、最終的に連
続する黒ドット数が所定値以上でなくなるまでこれを繰
返す。すると、図4(b)に示すような原稿の縦方向の
所定の範囲内にある画像、例えば手書き文字や印刷文字
のみが黒ドットとなるような2値化データが得られる。
In such a case, the number of lines of the continuous black dots is equal to or more than a predetermined value.
Is added to 1/16 and binarized as 4/16 of the maximum value of the reading density. Even so, if the number of consecutive black dots is equal to or greater than a predetermined value, the threshold is set to 5/16, 6 /
The binarization is performed by increasing the number of dots, and this process is repeated until the number of continuous black dots finally becomes smaller than a predetermined value. Then, as shown in FIG. 4B, an image within a predetermined range in the vertical direction of the document, for example, binary data in which only handwritten characters and printed characters are black dots is obtained.

【0035】このように、本実施の形態では、CCDセ
ンサ不良があったり、原稿画像に背景色がついていて
も、適切な閾値で2値化することができるため、原稿画
像を正確に読取ることができる。原稿の縦方向(CCD
センサ4の読取ラインの直角方向)に原稿画像の文字よ
りも長い汚れがあった場合、その汚れが上記第1の実施
の形態における連続する黒ドット数の所定値以内の幅の
狭いものであれば上記第1の実施の形態では黒ドットと
されてしまうが、このような汚れでも原稿の縦方向に長
いものであれば、本実施の形態では閾値が変更されて再
度2値化が行われるため、特に有効である。これによ
り、ホストコンピュータ7における手書き文字の文字認
識等の精度が向上する。
As described above, in this embodiment, even if the CCD sensor is defective or the original image has a background color, binarization can be performed with an appropriate threshold value. Can be. Original length (CCD
If there is dirt longer than the characters of the original image in the direction perpendicular to the reading line of the sensor 4), the dirt may be narrow within a predetermined value of the number of consecutive black dots in the first embodiment. For example, in the first embodiment, black dots are formed in the first embodiment. However, even if such dirt is long in the vertical direction of the document, the threshold value is changed and binarization is performed again in the present embodiment. Especially effective. This improves the accuracy of the host computer 7 in character recognition of handwritten characters and the like.

【0036】なお、本第2の実施の形態に第1の実施の
形態を組合わせるものであってもよい。例えば、図5の
ST25にて原稿の縦方向に連続する黒ドットのライン
数が所定ライン数以上であり、かつ原稿の幅方向に連続
する黒ドット数が所定黒ドット数以上である場合にのみ
ST26の処理に移り、それ以外はST28の処理に移
るようにしてもよい。これにより、図4(a)に示す原
稿の幅方向の汚れA及び原稿の縦方向に長い汚れBの両
方があっても、適切な閾値で2値化することができるた
め、図4(b)に示す手書き文字等のみが抽出された2
値化データに変換でき、原稿画像をより正確に読取るこ
とができる。これにより、ホストコンピュータ7におけ
る手書き文字の文字認識等の精度が向上する。
It is to be noted that the second embodiment may be combined with the first embodiment. For example, only when the number of continuous black dots in the vertical direction of the document is equal to or more than a predetermined number of lines and the number of continuous black dots in the width direction of the document is equal to or more than the predetermined number of black dots in ST25 of FIG. The process may proceed to ST26, and the other process may proceed to ST28. Thus, even if both the dirt A in the width direction of the original and the dirt B long in the vertical direction of the original shown in FIG. 4A can be binarized with an appropriate threshold value, 2) where only the handwritten characters shown in ()) are extracted
The original image can be converted to value data, and the original image can be read more accurately. This improves the accuracy of the host computer 7 in character recognition of handwritten characters and the like.

【0037】また、本発明の実施の形態においては、読
取素子を原稿の主走査方向にライン状に配設してなるC
CDセンサ4によって原稿画像を1ラインごとに読取る
ものについて述べたが、必ずしもこれに限定されるもの
ではなく、読取素子を原稿の副走査方向に配設してなる
CCDセンサをキャリアに搭載して主走査方向に移動さ
せながら原稿画像の複数ライン分を読取るようなものに
適用してもよい。この場合は、主走査方向、すなわちキ
ャリアの移動方向がライン方向に相当する。
Further, in the embodiment of the present invention, a C element in which reading elements are arranged in a line in the main scanning direction of a document.
Although the reading of the original image line by line by the CD sensor 4 has been described, the present invention is not limited to this, and a CCD sensor having reading elements arranged in the sub-scanning direction of the original is mounted on the carrier. The present invention may be applied to an apparatus in which a plurality of lines of an original image are read while being moved in the main scanning direction. In this case, the main scanning direction, that is, the moving direction of the carrier corresponds to the line direction.

【0038】また、上記第1及び第2の実施の形態にお
いては、2値化するための閾値を読取濃度の最大値に対
する割合として設定するものについて述べたが、本発明
では閾値を変更していって最適な閾値で2値化するもの
であるため、必ずしも閾値を読取濃度の最大値に対する
割合として設定しなくても正確に読取ることができる。
例えば、CCDセンサ4で読取った画像データが256
バイトの中間調データに変換された場合、その256バ
イトの3/16を閾値の初期値とし、変更するときは1
/16ごとに加算した閾値で2値化するようにしてもよ
い。
In the first and second embodiments, the threshold value for binarization is set as a ratio with respect to the maximum value of the read density. However, in the present invention, the threshold value is changed. Therefore, accurate reading can be performed without necessarily setting the threshold as a ratio to the maximum value of the reading density.
For example, if the image data read by the CCD sensor 4 is 256
When the data is converted to byte halftone data, 3/16 of the 256 bytes is used as the initial value of the threshold value, and 1 /
The binarization may be performed using a threshold value added for every / 16.

【0039】[0039]

【発明の効果】以上詳述したように本発明によれば、原
稿の汚れやCCDセンサ不良等があっても、原稿画像を
正確に読取ることができる画像読取装置を提供できるも
のである。
As described above in detail, according to the present invention, it is possible to provide an image reading apparatus capable of accurately reading an original image even if the original is dirty or the CCD sensor is defective.

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

【図1】本発明の第1の実施の形態にかかる画像読取装
置の構成を示すブロック図。
FIG. 1 is a block diagram showing a configuration of an image reading apparatus according to a first embodiment of the present invention.

【図2】図1に示すMPUが行う画像読取制御を示す流
れ図。
FIG. 2 is a flowchart showing image reading control performed by the MPU shown in FIG.

【図3】本実施の形態における原稿画像の読取濃度と2
値化するための閾値との関係を示す図。
FIG. 3 shows the reading density of a document image and 2 in the present embodiment.
The figure which shows the relationship with the threshold value for converting into a value.

【図4】原稿の縦方向や横方向にベタ塗りの汚れA,B
がある場合の1例を示す図。
FIG. 4 shows solid stains A and B in the vertical and horizontal directions of a document.
The figure which shows an example in the case where there is.

【図5】本発明の第2の実施の形態におけるMPUが行
う画像読取制御を示す流れ図。
FIG. 5 is a flowchart illustrating image reading control performed by an MPU according to a second embodiment of the present invention.

【図6】従来の画像読取装置における画像読取制御を示
す流れ図。
FIG. 6 is a flowchart showing image reading control in a conventional image reading apparatus.

【図7】従来の画像読取装置が背景色が白色の原稿画像
を読取る場合の読取濃度と2値化するための閾値との関
係を示す図。
FIG. 7 is a diagram illustrating a relationship between a reading density and a threshold for binarization when a conventional image reading apparatus reads a document image with a white background color.

【図8】従来の画像読取装置が背景色が図7に示す原稿
よりも濃い色の原稿画像を読取る場合の読取濃度と2値
化するための閾値との関係を示す図。
FIG. 8 is a diagram illustrating a relationship between a read density and a threshold for binarization when a conventional image reading apparatus reads a document image having a background color darker than the document illustrated in FIG. 7;

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

1…MPU 3…CCD制御回路 4…CCDセンサ(光学読取手段) 5…メモリ装置(ドット画像データ記憶手段) DESCRIPTION OF SYMBOLS 1 ... MPU 3 ... CCD control circuit 4 ... CCD sensor (optical reading means) 5 ... Memory device (dot image data storage means)

Claims (4)

【特許請求の範囲】[Claims] 【請求項1】 原稿画像を光学的に読取る光学読取手段
を設け、この光学読取手段によって読取って得られたド
ット画像データを所定の閾値で2値化する画像読取装置
において、前記光学読取手段によって読取って得られた
ドット画像データを一時的に記憶しておくドット画像デ
ータ記憶手段と、このドット画像データ記憶手段からの
ドット画像データを2値化する2値化手段と、この2値
化手段により得られた2値化データのうち連続する同種
のドットの最大数を検出する連続ドット数検出手段と、
この連続ドット検出手段で検出した最大数が所定値以上
となるときに、閾値を変更してその変更後の閾値で前記
2値化手段により前記ドット画像データ記憶手段からの
ドット画像データを2値化する2値化制御手段とを設け
たことを特徴とする画像読取り装置。
An image reading device for optically reading a document image, and binarizing dot image data obtained by reading the image with a predetermined threshold value; Dot image data storage means for temporarily storing dot image data obtained by reading, binarization means for binarizing dot image data from the dot image data storage means, and binarization means A continuous dot number detecting means for detecting the maximum number of consecutive dots of the same type in the binarized data obtained by
When the maximum number detected by the continuous dot detection means is equal to or more than a predetermined value, the threshold value is changed, and the binarization means converts the dot image data from the dot image data storage means into binary data with the changed threshold value. An image reading apparatus, comprising: a binarization control unit for converting the image into a binary image.
【請求項2】 前記連続ドット数検出手段は、前記2値
化手段により得られた2値化データのうち前記光学読取
手段で読取るライン方向に連続する同種のドットの最大
数を検出することを特徴とする請求項1記載の画像読取
り装置。
2. The method according to claim 1, wherein the continuous dot number detecting means detects a maximum number of dots of the same type continuous in a line direction read by the optical reading means in the binarized data obtained by the binarizing means. The image reading device according to claim 1, wherein:
【請求項3】 前記連続ドット数検出手段は、前記2値
化手段により得られた2値化データのうち前記光学読取
手段で読取るライン方向と直角方向に連続する同種のド
ットの最大数を検出することを特徴とする請求項1記載
の画像読取り装置。
3. The continuous dot number detecting means detects the maximum number of dots of the same kind which are continuous in the direction perpendicular to the line direction read by the optical reading means in the binarized data obtained by the binarizing means. The image reading device according to claim 1, wherein
【請求項4】 前記連続ドット数検出手段は、前記2値
化手段により得られた2値化データのうち前記光学読取
手段で読取るライン方向に連続する同種のドットのライ
ン方向最大数及びライン方向に直角な方向に連続する同
種のドットの直角方向最大数を検出し、 前記2値化制御手段は、前記連続ドット検出手段で検出
したライン方向最大数がライン方向の所定値以上となる
とき、又は直角方向最大数が直角方向所定値以上となる
ときに、閾値を変更してその変更後の閾値で前記2値化
手段により前記ドット画像データ記憶手段からのドット
画像データを2値化する請求項1記載の画像読取り装
置。
4. The continuous dot number detecting means, wherein the maximum number and the line direction of the same type of continuous dots in the line direction read by the optical reading means are included in the binarized data obtained by the binarizing means. Detecting the maximum number of the same kind of dots continuous in the direction perpendicular to the right angle direction, the binarization control means, when the maximum number of line directions detected by the continuous dot detection means is equal to or more than a predetermined value in the line direction, Alternatively, when the maximum number in the right-angle direction is equal to or more than a predetermined value in the right-angle direction, a threshold value is changed, and the binarization means binarizes the dot image data from the dot image data storage means with the changed threshold value. Item 2. The image reading device according to Item 1.
JP8335517A 1996-12-16 1996-12-16 Image reader Pending JPH10173920A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP8335517A JPH10173920A (en) 1996-12-16 1996-12-16 Image reader

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP8335517A JPH10173920A (en) 1996-12-16 1996-12-16 Image reader

Publications (1)

Publication Number Publication Date
JPH10173920A true JPH10173920A (en) 1998-06-26

Family

ID=18289463

Family Applications (1)

Application Number Title Priority Date Filing Date
JP8335517A Pending JPH10173920A (en) 1996-12-16 1996-12-16 Image reader

Country Status (1)

Country Link
JP (1) JPH10173920A (en)

Similar Documents

Publication Publication Date Title
US6438271B1 (en) Image reading apparatus
US8300277B2 (en) Image processing apparatus and method for determining document scanning area from an apex position and a reading reference position
JPS59205678A (en) Input device for form information
US5608544A (en) Framed-area defining rectangle forming device
JPH10173920A (en) Image reader
US20080304700A1 (en) Image forming apparatus and method of image forming
JPH10200739A (en) Picture reader
JP3027663B2 (en) Image input device
JP2779553B2 (en) Image reading apparatus and facsimile apparatus using this image reading apparatus
JPH06111060A (en) Optical character reader
KR950002400Y1 (en) Embossed image reader
JPH04195274A (en) Document terminal detecting method for optical character reader
JPS61166265A (en) Optical reader
JP3361905B2 (en) Optical character reader
JPH08190605A (en) Optical character reader
JPH01147948A (en) Picture processor
JPS5981773A (en) Optical character reader
JPH0677269B2 (en) Graphic quantizer
GB2151102A (en) Image processing apparatus
JPH1074236A (en) Picture input device
JPS61255486A (en) Graphic processing unit
JPH03278276A (en) Embossing image reader
JPH0581458A (en) Emboss image reader
JPS61213177A (en) Optical-type character reader with printing mechanism
JPH0535918A (en) Character recognition system by inclined guide line

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20050401

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20050426

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20050624

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20050726