JPH0676108A - Tilt detecting method for document image - Google Patents

Tilt detecting method for document image

Info

Publication number
JPH0676108A
JPH0676108A JP4224444A JP22444492A JPH0676108A JP H0676108 A JPH0676108 A JP H0676108A JP 4224444 A JP4224444 A JP 4224444A JP 22444492 A JP22444492 A JP 22444492A JP H0676108 A JPH0676108 A JP H0676108A
Authority
JP
Japan
Prior art keywords
black pixel
continuous black
pixel component
inclination
read image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
JP4224444A
Other languages
Japanese (ja)
Inventor
Naohiro Amamoto
直弘 天本
Sadamasa Hirogaki
節正 広垣
Yoshitaka Hamaguchi
佳孝 濱口
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.)
Oki Electric Industry Co Ltd
Original Assignee
Oki Electric Industry 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 Oki Electric Industry Co Ltd filed Critical Oki Electric Industry Co Ltd
Priority to JP4224444A priority Critical patent/JPH0676108A/en
Publication of JPH0676108A publication Critical patent/JPH0676108A/en
Withdrawn legal-status Critical Current

Links

Landscapes

  • Character Input (AREA)
  • Facsimile Scanning Arrangements (AREA)

Abstract

PURPOSE:To detect the tilt of a read image in an easy way and with high efficiency based on the height and the width of the circumscribed rectangle of the continuous black picture element components extracted through the tilt detection processing. CONSTITUTION:The read image included in a binary image memory 2 is horizontally scanned and then registered if a black run is detected out of the image. Then the extraction processing 31 is carried out for the horizontal continuous black picture element components after the general processing is complete with all rectangles. Then the extraction processing 31 is carried out for the vertical continuous black picture element components. In the continuous black picture element component decision processing 32, it is decided whether the continuous black picture elements are included in the extracted circumscribed rectangle or not. If so, the tilt of the read image is calculated by the tilt detection processing 33a. If not, the tilt of the read image is calculated by the tilt detection processing 33b.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、光学式文字読取り装置
(OCR)、ファクシミリ装置(FAX)等における文
書画像の傾きを検出する文書画像の傾き検出方法に関す
るものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a document image inclination detecting method for detecting the inclination of a document image in an optical character reader (OCR), a facsimile machine (FAX) or the like.

【0002】[0002]

【従来の技術】従来、この種の文書画像の傾き検出方法
としては、例えば、特開平2−17587号公報に記載
されるものがある。この文書画像の傾き検出方法では、
原稿等の文書画像をイメージセンサ等で読取り、その読
取り画像において各列の白から黒へ反転した時の黒画素
点を検出し、検出された各列の反転黒画素点の中から極
小値を与える点を抽出し、抽出された極小点が同一直線
上にあると判定される点の集合に統合分類する。そし
て、分類された集合の中から、統合された点の数が最も
多い1つの集合を抽出し、抽出された集合に含まれる各
点に最小二乗法等を適用して読取り画像の傾きを算出す
る。この種の傾き検出方法では、傾き抽出のために用い
るデータを削減でき、それによって傾き検出処理の高速
化が図れるという利点がある。
2. Description of the Related Art Conventionally, as a method for detecting the inclination of a document image of this type, there is one described in Japanese Patent Laid-Open No. 17587/1990, for example. In this document image tilt detection method,
A document image such as a manuscript is read by an image sensor, etc., and the black pixel points when white is reversed from each row in the read image are detected, and the minimum value is detected from the detected black pixel points in each row. The given points are extracted, and the extracted minimum points are integrated and classified into a set of points determined to be on the same straight line. Then, one set having the largest number of integrated points is extracted from the classified sets, and the slope of the read image is calculated by applying the least square method or the like to each point included in the extracted set. To do. This kind of inclination detection method has an advantage that the data used for the inclination extraction can be reduced and the inclination detection processing can be speeded up.

【0003】[0003]

【発明が解決しようとする課題】しかしながら、従来の
方法では、極小点が抽出できない場合、さらに複雑な処
理が必要となり、安定した結果が得られないという問題
があり、容易に、効率良く、文書画像の傾きを検出する
ことが困難であった。本発明は、前記従来技術が持って
いた課題として、極小点が抽出できない時には安定した
結果が得られないという点について解決し、文書画像内
の長い黒画素成分(黒ランともいう)を利用して容易
に、効率良く、文書画像の傾きを検出できる文書画像の
傾き検出方法を提供するものである。
However, the conventional method has a problem that if the minimum point cannot be extracted, more complicated processing is required, and a stable result cannot be obtained. It was difficult to detect the tilt of the image. The present invention solves the problem that the above-described conventional art has, that a stable result cannot be obtained when a minimum point cannot be extracted, and uses a long black pixel component (also called a black run) in a document image. The present invention provides a method for detecting the inclination of a document image, which can easily and efficiently detect the inclination of the document image.

【0004】[0004]

【課題を解決するための手段】第1の発明は、前記課題
を解決するために、文書画像を読取り、その読取り画像
において各列の白から黒へ反転した時の黒画素点を検出
し、検出された各列の反転黒画素点を用いて前記読取り
画像の傾きを検出する文書画像の傾き検出方法におい
て、連続黒画素成分抽出処理により、前記読取り画像を
縦及び横方向に走査して第1の閾値より長い黒画素成分
を抽出し、抽出された全黒画素成分の外接矩形について
統合条件を満たすものを統合して連続黒画素成分を抽出
する。次に、連続黒画素成分判定処理により、前記連続
黒画素成分抽出処理で抽出された連続黒画素成分の長さ
と第2の閾値との比較によって連続黒画素成分の有無を
判定する。その後、傾き検出処理により、前記連続黒画
素成分判定処理で連続黒画素成分有りと判定された場合
に、前記抽出された連続黒画素成分の外接矩形の高さと
幅から前記読取り画像の傾きを算出し、連続黒画素成分
無しと判定された場合は、前記反転黒画素点を用いた傾
き検出を行うようにしている。
In order to solve the above-mentioned problems, a first invention is to read a document image and detect a black pixel point at the time when the read image is inverted from white to black in each column, In a document image inclination detecting method for detecting the inclination of the read image using the detected inverted black pixel points of each column, the read image is scanned in the vertical and horizontal directions by continuous black pixel component extraction processing. Black pixel components longer than the threshold value of 1 are extracted, and those circumscribing rectangles of all the extracted black pixel components that satisfy the integration condition are integrated to extract continuous black pixel components. Next, in the continuous black pixel component determination process, the presence or absence of the continuous black pixel component is determined by comparing the length of the continuous black pixel component extracted in the continuous black pixel component extraction process with the second threshold value. After that, when it is determined by the inclination detection processing that there is a continuous black pixel component in the continuous black pixel component determination processing, the inclination of the read image is calculated from the height and width of the circumscribed rectangle of the extracted continuous black pixel component. However, when it is determined that there is no continuous black pixel component, the inclination detection is performed using the inverted black pixel point.

【0005】第2の発明では、第1の発明の文書画像の
傾き検出方法において、前記読取り画像を所定の縮小率
で縮小した縮小画像を用い、前記第1および第2の閾値
を該縮小率に応じて正規化し、前記連続黒画素成分抽出
処理、連続黒画素成分判定処理、及び傾き検出処理によ
って前記読取り画像の傾きの検出を行うようにしてい
る。
According to a second aspect of the present invention, in the document image inclination detecting method according to the first aspect, a reduced image obtained by reducing the read image at a predetermined reduction rate is used, and the first and second threshold values are set to the reduction rate. According to the above, the inclination of the read image is detected by the continuous black pixel component extraction processing, the continuous black pixel component determination processing, and the inclination detection processing.

【0006】[0006]

【作用】第1の発明によれば、以上のように文書画像の
傾き検出方法を構成したので、文書画像が読取られる
と、その読取り画像から、連続黒画素成分抽出処理によ
って連続黒画素成分が抽出される。抽出された連続黒画
素成分は、その長さが閾値よりも大きいか否かが連続黒
画素成分判定処理で判定され、大きい時には傾き検出処
理によって該連続黒画素成分の外接矩形の高さと幅から
読取り画像の傾きが検出される。閾値以上の長さの連続
黒画素成分が抽出されない場合は、反転黒画素点を用い
て読取り画像の傾きが検出される。第2の発明によれ
ば、読取り画像を縮小した縮小画像を用い、第1の発明
とほぼ同様に、連続黒画素成分が抽出され、抽出された
連続黒画素成分の外接矩形の高さと幅から縮小画像の傾
きが検出される。従って、前記課題を解決できるのであ
る。
According to the first aspect of the invention, since the method for detecting the inclination of the document image is configured as described above, when the document image is read, the continuous black pixel component is extracted from the read image by the continuous black pixel component extraction processing. To be extracted. Whether or not the length of the extracted continuous black pixel component is larger than the threshold value is determined by the continuous black pixel component determination process, and when it is large, the inclination detection process determines the height and width of the circumscribed rectangle of the continuous black pixel component. The tilt of the read image is detected. When a continuous black pixel component having a length equal to or longer than the threshold value is not extracted, the inclination of the read image is detected using the inverted black pixel point. According to the second aspect of the invention, the reduced image obtained by reducing the read image is used to extract the continuous black pixel component almost in the same manner as in the first aspect of the invention, and the height and width of the circumscribed rectangle of the extracted continuous black pixel component The inclination of the reduced image is detected. Therefore, the above problem can be solved.

【0007】[0007]

【実施例】図1は本発明の実施例の傾き検出方法の処理
内容を示すフローチャート、図2(a)〜(d)は図1
の連続黒画素成分の説明図、図3は図1における連続黒
画素成分抽出処理(横方向)の処理内容を示すフローチ
ャート、図4(a),(b)は図2における横長黒ラン
の場合と縦長黒画ランの場合の結合条件を説明する図、
及び図5(a),(b)は図1における幅>高さの時と
幅≦高さの時の傾き検出処理33aの説明図である。
DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS FIG. 1 is a flow chart showing the processing contents of a tilt detecting method according to an embodiment of the present invention, and FIGS.
Of the continuous black pixel component of FIG. 3, FIG. 3 is a flowchart showing the processing contents of the continuous black pixel component extraction processing (horizontal direction) in FIG. 1, and FIGS. 4A and 4B are the cases of the horizontally long black run in FIG. And a diagram for explaining the combining condition in the case of a vertical black image run,
5A and 5B are explanatory views of the inclination detection processing 33a when width> height and width ≦ height in FIG.

【0008】図1に示すように、本実施例の傾き検出方
法では、先ず、イメージスキャナ等の読取り手段10に
より、原稿等の文書画像を2値で読取り、その読取り画
像を2値画像メモリ20に格納する。次に、傾き検出手
段30により、2値画像メモリ20に格納した読取り画
像を走査し、図2(a)〜(d)のような連続する黒画
素成分(黒ラン)である連続黒画素成分を抽出し、抽出
した連続黒画素成分の外接矩形の高さと幅等から、読取
り画像の傾きを検出し、処理を終了する。次に、本実施
例の特徴である傾き検出手段30の処理内容を説明す
る。傾き検出手段30では、先ず、連続黒画素成分抽出
処理31により、図2のような連続黒画素成分の外接矩
形を抽出する。この連続黒画素成分抽出処理31の具体
的な処理手順を図3を参照しつつ説明する。図3に示す
ように、ステップ31aで、2値画像メモリ20内の読
取り画像を横方向に走査し、ステップ31bで、長さが
第1の閾値th1以上の黒ランが存在するか否かを判定
する。黒ランが存在すれば、x,y座標で表わされるこ
の黒ランの外接矩形xs,ys,xe,yeをステップ
31cで登録した後、ステップ31dで最終ラインか否
かの判定を行う。閾値th1以上の長さの黒ランが存在
しなければ、ステップ31dへ進む。ステップ31dで
最終ラインでない時には、ステップ31eを介して次の
ラインへ進み、前記と同様に、読取り画像を横方向に走
査する。この走査を読取り画像全体について行う。
As shown in FIG. 1, in the tilt detecting method of the present embodiment, first, a reading means 10 such as an image scanner reads a document image such as a document in binary, and the read image is read in a binary image memory 20. To store. Next, the inclination detection means 30 scans the read image stored in the binary image memory 20, and a continuous black pixel component that is a continuous black pixel component (black run) as shown in FIGS. 2A to 2D. Is extracted, the inclination of the read image is detected from the height and width of the circumscribed rectangle of the extracted continuous black pixel components, and the process is terminated. Next, the processing contents of the tilt detecting means 30, which is a feature of this embodiment, will be described. In the inclination detecting means 30, first, the continuous black pixel component extraction processing 31 extracts the circumscribed rectangle of the continuous black pixel components as shown in FIG. A specific processing procedure of the continuous black pixel component extraction processing 31 will be described with reference to FIG. As shown in FIG. 3, in step 31a, the read image in the binary image memory 20 is horizontally scanned, and in step 31b, it is determined whether or not there is a black run having a length equal to or greater than the first threshold th1. judge. If there is a black run, the circumscribed rectangle xs, ys, xe, ye of this black run represented by the x, y coordinates is registered in step 31c, and then it is determined in step 31d whether or not it is the final line. If there is no black run having a length equal to or greater than the threshold value th1, the process proceeds to step 31d. When it is not the final line in step 31d, the process proceeds to the next line through step 31e, and the read image is scanned in the horizontal direction as described above. This scan is performed on the entire read image.

【0009】読取り画像全体の走査が終わると、ステッ
プ31f,31gで、登録された全矩形について図4
(a),(b)の統合条件を満たしているか否かを判定
する。図4(a)に示す横長黒ランの場合の統合条件
は、x座標がxs1 <xeかつxe1 >xsで、y座標
が隣接していることである。図4(b)の縦長黒ランの
場合の統合条件は、y座標がys1 <yeかつye1
ysで、x座標が隣接していることである。これらの統
合条件を満たしている場合には、ステップ31hで、矩
形の統合を行い、ステップ31iで、全矩形について統
合が終了したか否かを判定し、終了していない時にはス
テップ31fへ戻る。ステップ31gで統合条件を満た
していない時にも、ステップ31fへ戻る。
When the scanning of the entire read image is completed, steps 31f and 31g are executed for all the registered rectangles as shown in FIG.
It is determined whether or not the integration conditions of (a) and (b) are satisfied. The integration condition in the case of the horizontally long black run shown in FIG. 4A is that the x coordinates are xs 1 <xe and xe 1 > xs, and the y coordinates are adjacent. The integration condition in the case of the vertically long black run in FIG. 4B is that the y coordinate is ys 1 <ye and ye 1 >.
In ys, the x coordinates are adjacent. If these integration conditions are satisfied, rectangles are integrated in step 31h, and it is determined in step 31i whether or not integration has been completed for all rectangles. If not completed, the process returns to step 31f. Even when the integration condition is not satisfied in step 31g, the process returns to step 31f.

【0010】全矩形について統合処理が終わると、横方
向の連続黒画素成分抽出処理31を終了する。図3と同
様の走査を、縦方向についても行い、縦方向の連続黒画
素成分抽出処理31を行う。なお、一般文書で最も良く
用いられる文書サイズは8〜10ポイントである。その
ため、文字の一部を誤って連続黒画素成分(黒ラン)と
して抽出しないよう第1の閾値th1の値は、文字サイ
ズの倍程度に設定するのが適当である。例えば、読取り
解像度が400dpiの時、第1の閾値th1は100
ドット程度となる。図1の連続黒画素成分抽出処理31
が終了すると、連続黒画素成分判定処理32へ進む。こ
の連続黒画素成分判定処理32では、連続黒画素成分抽
出処理31で抽出された外接矩形から、連続黒画素成分
が存在するか否かを判定する。この判定処理32では、
連続黒画素成分抽出処理31で抽出された連続黒画素成
分の長さと、第2の閾値th2とを比較し、連続黒画素
成分が存在するか否かを判定する。(連続黒画素成分の
長さ)>th2を満たす成分が存在すれば、連続黒画素
成分が抽出できたと判定される。
When the integration processing for all the rectangles is completed, the horizontal continuous black pixel component extraction processing 31 is completed. The same scanning as in FIG. 3 is performed also in the vertical direction, and the continuous black pixel component extraction processing 31 in the vertical direction is performed. The most commonly used document size for general documents is 8 to 10 points. Therefore, it is appropriate to set the value of the first threshold th1 to about twice the character size so that a part of the character is not accidentally extracted as a continuous black pixel component (black run). For example, when the reading resolution is 400 dpi, the first threshold th1 is 100
It will be about dots. Continuous black pixel component extraction process 31 in FIG.
When is completed, the process proceeds to the continuous black pixel component determination process 32. In the continuous black pixel component determination process 32, it is determined from the circumscribed rectangle extracted in the continuous black pixel component extraction process 31 whether or not a continuous black pixel component exists. In this determination process 32,
The length of the continuous black pixel component extracted in the continuous black pixel component extraction process 31 is compared with the second threshold th2 to determine whether or not the continuous black pixel component exists. If there is a component that satisfies (length of continuous black pixel component)> th2, it is determined that the continuous black pixel component has been extracted.

【0011】なお、一般文書で用いられる最大の文字サ
イズは28ポイントである。そのため、第2の閾値th
2の値は、最大文字サイズの倍程度に設定するのが適当
である。例えば、読取り解像度が400dpiの時、第
2の閾値th2は300ドット程度となる。図1の連続
黒画素成分判定処理32が終わると、傾き検出処理33
へ進む。連続黒画素成分判定処理32によって連続黒画
素成分が存在すると判定された場合は、本実施例による
傾き検出処理33aで読取り画像の傾きを算出する。即
ち、図5(a),(b)に示すように、抽出された連続
黒画素成分の外接矩形が横長の場合は傾きθをtan-1
(高さ/幅)で求め、縦長の場合は傾きθをtan
-1(幅/高さ)で求めることができる。連続黒画素成分
が複数抽出された場合は、最も長い成分について傾きθ
を求め、その値を読取り画像の傾きとする。
The maximum character size used in general documents is 28 points. Therefore, the second threshold th
It is appropriate to set the value of 2 to about twice the maximum character size. For example, when the reading resolution is 400 dpi, the second threshold th2 is about 300 dots. When the continuous black pixel component determination processing 32 of FIG. 1 is finished, the inclination detection processing 33
Go to. When it is determined by the continuous black pixel component determination process 32 that a continuous black pixel component exists, the inclination of the read image is calculated by the inclination detection process 33a according to the present embodiment. That is, as shown in FIGS. 5A and 5B, when the circumscribed rectangle of the extracted continuous black pixel components is horizontally long, the inclination θ is tan −1.
Calculated by (height / width), and in the case of portrait orientation, the inclination θ is tan
It can be calculated by -1 (width / height). When multiple continuous black pixel components are extracted, the slope θ is calculated for the longest component.
Is obtained, and that value is taken as the inclination of the read image.

【0012】一方、連続黒画素成分判定処理32によっ
て連続黒画素成分が存在しないと判定された場合は、反
転黒画素点を用いた従来方法の傾き検出処理33bによ
って読取り画像の傾きを求める。この傾き検出処理33
bでは、例えば、前記文献に記載されているように、読
取り画像において各列の白から黒へ反転した時の黒画素
点を検出し、検出された各列の反転黒画素点の中から極
小値を与える点を抽出し、この極小点が同一直線上にあ
ると判定される点の集合に統合分類する。そして、分類
された集合の中から、統合された点の数が最も多い1つ
の集合を抽出し、抽出された集合に含まれる各点に最小
二乗法等を適用して読取り画像の傾きを求める。
On the other hand, when the continuous black pixel component determining process 32 determines that there is no continuous black pixel component, the inclination of the read image is obtained by the conventional inclination detecting process 33b using the inverted black pixel point. This tilt detection process 33
In b, for example, as described in the above-mentioned document, a black pixel point at the time of reversing from white to black in each column in a read image is detected, and the minimum among the detected inversion black pixel points in each column is detected. The points that give values are extracted, and the minimum points are integrated and classified into a set of points determined to be on the same straight line. Then, one set having the largest number of integrated points is extracted from the classified sets, and the least square method or the like is applied to each point included in the extracted set to obtain the inclination of the read image. .

【0013】以上のように、本実施例では、連続黒画素
成分抽出処理31によって連続黒画素成分を抽出し、傾
き検出処理33aにより、抽出された連続黒画素成分の
外接矩形の高さと幅から読取り画像の傾きを求めるた
め、文書画像に長い連続黒画素成分が1つでも存在すれ
ば、容易に、かつ効率良く、読取り画像の傾きを検出す
ることができる。文書画像に長い連続黒画素成分が存在
しない場合(例えば、文書画像が文字だけの場合)に
は、読取り画像の傾きを求めることができないので、そ
の時には従来方法による傾き検出処理33bによって画
像の傾きを検出する。
As described above, in this embodiment, the continuous black pixel component extracting process 31 extracts the continuous black pixel component, and the inclination detecting process 33a extracts the height and width of the circumscribed rectangle of the extracted continuous black pixel component. Since the inclination of the read image is obtained, if even one long continuous black pixel component exists in the document image, the inclination of the read image can be detected easily and efficiently. When the long continuous black pixel component does not exist in the document image (for example, when the document image is only characters), the inclination of the read image cannot be obtained. At that time, the inclination detection processing 33b according to the conventional method detects the inclination of the image. To detect.

【0014】なお、本発明は上記実施例に限定されず、
他の種々の実施例が考えられる。その実施例としては、
例えば次のようなものがある。 (i)図1において、読取り手段10で読み取った読取
り画像を所定の縮小率で縮小した縮小画像を作成し、連
続黒画素成分抽出処理31及び連続黒画素成分判定処理
32で用いた第1,第2の閾値th1,th2を該縮小
率に応じて正規化し、該縮小画像に対して連続黒画素成
分抽出31、連続黒画素成分判定処理32、及び傾き検
出処理33を行うことにより、上記実施例とほぼ同様の
作用効果が得られる。このように縮小画像を用いて傾き
の検出を行う場合、処理すべきデータ数が少なくなるた
め、高速に処理できるという効果もある。 (ii)図1において、従来方法による傾き検出処理33
bでは、前記文献に記載された方法で読取り画像の傾き
を検出するようにしているが、従来の他の方法を用いて
傾きの検出を行っても良い。
The present invention is not limited to the above embodiment,
Various other embodiments are possible. As an example,
For example: (I) In FIG. 1, a read image read by the reading means 10 is reduced at a predetermined reduction ratio to create a reduced image, which is used in the continuous black pixel component extraction process 31 and the continuous black pixel component determination process 32. The second threshold values th1 and th2 are normalized according to the reduction ratio, and the continuous black pixel component extraction 31, the continuous black pixel component determination processing 32, and the inclination detection processing 33 are performed on the reduced image, thereby performing the above-described implementation. Almost the same effect as the example can be obtained. When the tilt is detected using the reduced image as described above, the number of data to be processed is small, and therefore, there is also an effect that the processing can be performed at high speed. (Ii) In FIG. 1, inclination detection processing 33 by the conventional method
In b, the inclination of the read image is detected by the method described in the above-mentioned document, but the inclination may be detected by using another conventional method.

【0015】[0015]

【発明の効果】以上詳細に説明したように、第1の発明
によれば、連続黒画素成分抽出処理によって連続黒画素
成分を抽出し、傾き検出処理により、抽出された連続黒
画素成分の外接矩形の高さと幅から読取り画像の傾きを
検出するようにしたので、文書画像に長い連続黒画素成
分が1つでも存在すれば、容易に、かつ効率良く、読取
り画像の傾きを検出することができる。第2の発明によ
れば、読取り画像を縮小した縮小画像に対し、連続黒画
素成分を抽出し、抽出された連続黒画素成分の外接矩形
の高さと幅から該縮小画像の傾きを求めるようにしたの
で、第1の発明とほぼ同様の効果が得られる上に、縮小
画像を用いているので、処理すべきデータ数が少なくな
り、高速に傾き検出処理が行える。
As described in detail above, according to the first aspect of the present invention, the continuous black pixel component is extracted by the continuous black pixel component extracting process, and the extracted continuous black pixel component is circumscribed by the inclination detecting process. Since the inclination of the read image is detected from the height and width of the rectangle, the inclination of the read image can be detected easily and efficiently if there is even one long continuous black pixel component in the document image. it can. According to the second aspect, the continuous black pixel component is extracted from the reduced image obtained by reducing the read image, and the inclination of the reduced image is obtained from the height and width of the circumscribed rectangle of the extracted continuous black pixel component. Therefore, the same effect as that of the first aspect of the invention is obtained, and since the reduced image is used, the number of data to be processed is reduced, and the inclination detection process can be performed at high speed.

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

【図1】本発明の実施例の傾き検出方法の処理内容を示
すフローチャートである。
FIG. 1 is a flowchart showing the processing contents of a tilt detection method according to an embodiment of the present invention.

【図2】図1の連続黒画素成分を説明する図である。FIG. 2 is a diagram illustrating a continuous black pixel component of FIG.

【図3】図1の連続黒画素成分抽出処理の処理内容を示
すフローチャートである。
FIG. 3 is a flowchart showing the processing contents of continuous black pixel component extraction processing of FIG.

【図4】図2の統合条件を説明する図である。FIG. 4 is a diagram illustrating the integration condition of FIG.

【図5】図1の傾き検出処理の説明図である。FIG. 5 is an explanatory diagram of a tilt detection process in FIG.

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

10 読取り手段 20 2値画像メモリ 30 傾き検出手段 31 連続黒画素成分抽出処理 32 連続黒画素成分判定処理 33 傾き検出処理 10 Reading Means 20 Binary Image Memory 30 Tilt Detection Means 31 Continuous Black Pixel Component Extraction Processing 32 Continuous Black Pixel Component Determination Processing 33 Tilt Detection Processing

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】 文書画像を読取り、その読取り画像にお
いて各列の白から黒へ反転した時の黒画素点を検出し、
検出された各列の反転黒画素点を用いて前記読取り画像
の傾きを検出する文書画像の傾き検出方法において、 連続黒画素成分抽出処理により、前記読取り画像を縦及
び横方向に走査して第1の閾値より長い黒画素成分を抽
出し、抽出された全黒画素成分の外接矩形について統合
条件を満たすものを統合して連続黒画素成分を抽出し、 連続黒画素成分判定処理により、前記連続黒画素成分抽
出処理で抽出された連続黒画素成分の長さと第2の閾値
との比較によって連続黒画素成分の有無を判定し、 傾き検出処理により、前記連続黒画素成分判定処理で連
続黒画素成分有りと判定された場合に、前記抽出された
連続黒画素成分の外接矩形の高さと幅から前記読取り画
像の傾きを算出し、連続黒画素成分無しと判定された場
合は、前記反転黒画素点を用いた傾き検出を行うことを
特徴とする文書画像の傾き検出方法。
1. A document image is read, and black pixel points at the time of reversing from white to black in each column in the read image are detected,
In a document image inclination detection method for detecting the inclination of the read image using the detected inverted black pixel points in each column, a continuous black pixel component extraction process is performed to scan the read image vertically and horizontally. A black pixel component longer than the threshold value of 1 is extracted, and those circumscribing rectangles of all the extracted black pixel components are combined to extract continuous black pixel components, and continuous black pixel component determination processing is performed to extract the continuous black pixel components. The presence or absence of a continuous black pixel component is determined by comparing the length of the continuous black pixel component extracted in the black pixel component extraction process with a second threshold value, and the inclination detection process determines the continuous black pixel component in the continuous black pixel component determination process. When it is determined that there is a component, the inclination of the read image is calculated from the height and width of the circumscribing rectangle of the extracted continuous black pixel component, and when it is determined that there is no continuous black pixel component, the inverted black pixel Tilt detection method of the document image, characterized in that the inclination detection using.
【請求項2】 請求項1記載の文書画像の傾き検出方法
において、 前記読取り画像を所定の縮小率で縮小した縮小画像を用
い、前記第1および第2の閾値を該縮小率に応じて正規
化し、前記連続黒画素成分抽出処理、連続黒画素成分判
定処理、及び傾き検出処理によって前記読取り画像の傾
きの検出を行うことを特徴とする文書画像の傾き検出方
法。
2. The document image inclination detecting method according to claim 1, wherein a reduced image obtained by reducing the read image at a predetermined reduction ratio is used, and the first and second threshold values are set according to the reduction ratio. And detecting the inclination of the read image by the continuous black pixel component extraction processing, the continuous black pixel component determination processing, and the inclination detection processing.
JP4224444A 1992-08-24 1992-08-24 Tilt detecting method for document image Withdrawn JPH0676108A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP4224444A JPH0676108A (en) 1992-08-24 1992-08-24 Tilt detecting method for document image

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP4224444A JPH0676108A (en) 1992-08-24 1992-08-24 Tilt detecting method for document image

Publications (1)

Publication Number Publication Date
JPH0676108A true JPH0676108A (en) 1994-03-18

Family

ID=16813871

Family Applications (1)

Application Number Title Priority Date Filing Date
JP4224444A Withdrawn JPH0676108A (en) 1992-08-24 1992-08-24 Tilt detecting method for document image

Country Status (1)

Country Link
JP (1) JPH0676108A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07105310A (en) * 1993-10-05 1995-04-21 Ricoh Co Ltd Method for detecting tilt of picture and method for processing table
JPH07192086A (en) * 1993-12-27 1995-07-28 Ricoh Co Ltd Picture inclination detection method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07105310A (en) * 1993-10-05 1995-04-21 Ricoh Co Ltd Method for detecting tilt of picture and method for processing table
JPH07192086A (en) * 1993-12-27 1995-07-28 Ricoh Co Ltd Picture inclination detection method

Similar Documents

Publication Publication Date Title
US5563403A (en) Method and apparatus for detection of a skew angle of a document image using a regression coefficient
JP4219542B2 (en) Image processing apparatus, image processing method, and recording medium storing image processing program
US6798906B1 (en) Image processing apparatus and method including line segment data extraction
US7660014B2 (en) Image processing apparatus capable of extracting rule from document image with high precision
JP4339925B2 (en) Document image processing method, document image processing apparatus, document image processing program, and storage medium
EP0692767B1 (en) Image processing apparatus and method
US6771842B1 (en) Document image skew detection method
US5467410A (en) Identification of a blank page in an image processing system
US6289120B1 (en) Method and system for processing images of forms which have irregular construction and/or determining whether characters are interior to a form
JP3090848B2 (en) In-frame area rectangularization device
JPH0418351B2 (en)
EP0766193B1 (en) Optical character reader with skew correction
JP2003115031A (en) Image processor and its method
JPH0676108A (en) Tilt detecting method for document image
EP0975146A1 (en) Locating the position and orientation of multiple objects with a smart platen
JP2786355B2 (en) How to determine the attributes of text images
JPH08237404A (en) Selection of optical character recognition mode
JP2003281469A (en) Method for processing document image
JP2881066B2 (en) How to determine the attributes of text images
JP4439054B2 (en) Character recognition device and character frame line detection method
JPH08221515A (en) Image processor
JP2877548B2 (en) Document image attribute discrimination method
JP3754721B2 (en) Image processing apparatus and method
JP3020293B2 (en) Attribute determination method
JP2872757B2 (en) Line direction determination device

Legal Events

Date Code Title Description
A300 Application deemed to be withdrawn because no request for examination was validly filed

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 19991102