JP4354443B2 - Image reading device - Google Patents

Image reading device Download PDF

Info

Publication number
JP4354443B2
JP4354443B2 JP2005274617A JP2005274617A JP4354443B2 JP 4354443 B2 JP4354443 B2 JP 4354443B2 JP 2005274617 A JP2005274617 A JP 2005274617A JP 2005274617 A JP2005274617 A JP 2005274617A JP 4354443 B2 JP4354443 B2 JP 4354443B2
Authority
JP
Japan
Prior art keywords
document
main scanning
scanning direction
image
pixels
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
JP2005274617A
Other languages
Japanese (ja)
Other versions
JP2007088785A (en
Inventor
克玄 林
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Kyocera Document Solutions Inc
Original Assignee
Kyocera Mita 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 Kyocera Mita Corp filed Critical Kyocera Mita Corp
Priority to JP2005274617A priority Critical patent/JP4354443B2/en
Publication of JP2007088785A publication Critical patent/JP2007088785A/en
Application granted granted Critical
Publication of JP4354443B2 publication Critical patent/JP4354443B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明は、原稿の画像を読み取る画像読取装置に関し、特に、読取対象とされる原稿のサイズを検出する技術に関する。   The present invention relates to an image reading apparatus that reads an image of an original, and more particularly, to a technique for detecting the size of an original to be read.

従来、複写機、スキャナ、ファクシミリ等の画像読取装置における原稿サイズの検知は、プラテンガラス上に原稿を載置する場合については、例えば下記特許文献1,2又は3に示されるように、プラテンガラス上の所定の位置における原稿の有無を検知するセンサを用いて行われていた。また、載置された原稿をシートフィーダにより引き込む場合については、主走査方向の原稿サイズについては、原稿ガイド板の位置の検知により行われ、副走査方向の原稿サイズについては、副走査方向の先頭と末尾の通過時を検知するセンサを用いて行われていた。
特開平10−010651号公報 特開平10−090807号公報 特開平08−083033号公報
Conventionally, the detection of the document size in an image reading apparatus such as a copying machine, a scanner, or a facsimile is performed when a document is placed on the platen glass. This is done using a sensor that detects the presence or absence of a document at a predetermined position above. When the placed document is pulled in by the sheet feeder, the document size in the main scanning direction is detected by detecting the position of the document guide plate, and the document size in the sub scanning direction is detected at the head in the sub scanning direction. And it was done using a sensor that detects when the tail passes.
JP-A-10-010651 JP-A-10-090807 Japanese Patent Application Laid-Open No. 08-083033

しかしながら、従来技術では、センサ等の原稿サイズを検知するために原稿サイズ検知用の特別なハードウェアを画像読取装置に備える必要があり、その分コストがかかっていた。   However, in the prior art, it is necessary to provide the image reading apparatus with special hardware for detecting the document size in order to detect the document size, such as a sensor, which increases the cost.

本発明は、上記問題点に鑑みて成されたもので、原稿サイズを検知するためのセンサ等のハードウェアを設けることなく原稿サイズを検知できる画像読取装置を提供することを目的とする。   The present invention has been made in view of the above problems, and an object of the present invention is to provide an image reading apparatus that can detect the document size without providing hardware such as a sensor for detecting the document size.

請求項1に係る発明は、原稿から画像を主走査ライン毎に読み取る読取手段と、
前記読取手段の原稿読取位置における原稿の背面側に設けられた、予め定められた画像が形成されたパターン画像と、
前記パターン画像の画像データを比較データとして記憶する比較データ記憶手段と、
前記比較データ記憶手段に記憶されている比較データの各画素と、その画素と一致する主走査方向位置にある前記読取手段によって読み取られた各主走査ライン毎の画像データの画素及びその前後に位置する予め定められた画素数分の画素との各差分を算出する差分算出部と、前記各主走査ライン毎に、前記差分算出部により算出された前記対応する各画素同士の差分が、予め定められた値以内であるか否かを判定し、当該差分が予め定められた値以内である場合に当該対応する各画素同士が一致したと判定する第1の一致判定部と、前記予め定められた画素数の画素との間で前記差分算出部により差分が算出された前記比較データの画素ごとに、前記第1の一致判定部による前記各主走査ライン毎の判定結果が予め定められた数だけ一致したと判定されたか否かを判断し、当該予め定められた数だけ一致したと判定された場合に、当該比較データの画素が、当該比較データの画素と一致する主走査方向位置にある前記画像データの画素と一致したと判定する第2の一致判定部と、前記第2の一致判定部によって比較データの画素が原稿データの画素と一致したと判定された数が予め定められた数に達している場合に、当該主走査ラインの画像データが前記比較データと一致したと判定し、当該一致した主走査ラインと、一致しない主走査ラインとの境目を、前記原稿の画像データの副走査方向における端位置として判定する端位置判定部とを有する副走査方向端位置判定手段と、
前記副走査方向端位置判定手段により判定された副走査方向における端位置に基づいて、原稿のサイズを求めるサイズ算出手段と
を備える画像読取装置である。
The invention according to claim 1 comprises reading means for reading an image from the document for each main scanning line;
A pattern image provided with a predetermined image provided on the back side of the document at the document reading position of the reading unit;
Comparison data storage means for storing image data of the pattern image as comparison data;
Each pixel of the comparison data stored in the comparison data storage means, and the pixels of the image data for each main scanning line read by the reading means at the position in the main scanning direction that coincides with the pixels, and positions before and after the pixels A difference calculation unit for calculating each difference from a predetermined number of pixels and a difference between the corresponding pixels calculated by the difference calculation unit for each main scanning line is determined in advance. A first coincidence determination unit that determines whether or not the corresponding pixels match when the difference is within a predetermined value, and the predetermined match determination unit A predetermined number of determination results for each main scanning line by the first coincidence determination unit for each pixel of the comparison data for which the difference is calculated by the difference calculation unit with respect to pixels having a predetermined number of pixels. Only match The image data at the position in the main scanning direction where the pixels of the comparison data coincide with the pixels of the comparison data when it is determined that the predetermined number matches. A second coincidence determining unit that determines that the pixel of the comparison data matches the pixel of the original data, and the number of pixels determined by the second match determination unit that the pixel of the comparison data matches the pixel of the document data has reached a predetermined number If the image data of the main scanning line matches the comparison data, the boundary between the matching main scanning line and the non-matching main scanning line is determined in the sub-scanning direction of the image data of the document. A sub-scanning direction end position determination unit having an end position determination unit that determines the end position;
The image reading apparatus includes: a size calculating unit that obtains the size of the document based on the end position in the sub-scanning direction determined by the sub-scanning direction end position determining unit.

この構成によれば、読取手段により原稿及び背景から主走査ライン毎に画像データが読み取られ、この読み取られた主走査ラインの画像データと、比較データ記憶手段に記憶されているパターン画像の画像データとが、副走査方向端位置判定手段により比較されて、一致度の高い主走査ラインと、一致度の低い主走査ラインとの境目が、当該読取対象となっている原稿の画像データの副走査方向における端位置と判定される。 According to this configuration, the image data is read for each main scanning line from the document and the background by the reading unit, and the image data of the read main scanning line and the image data of the pattern image stored in the comparison data storage unit Are compared by the sub-scanning direction end position determining means, and the boundary between the main scanning line having a high coincidence and the main scanning line having a low coincidence is sub-scanning the image data of the document to be read. It is determined as the end position in the direction.

また、この構成によれば、差分算出部が、比較データの1つの画素と、原稿の各主走査ライン毎の画像データにおける複数の画素との差分を算出し、第1の一致判定部が、当該複数の差分のうち、予め定められている個数が予め定められた値以内である場合に当該両画素が一致したと判定するので、パターン画像の画素位置、又は原稿の画像データが若干不正確に読み取られた場合においても、正確な原稿サイズを検出することができる。 Further , according to this configuration, the difference calculation unit calculates a difference between one pixel of the comparison data and a plurality of pixels in the image data for each main scanning line of the document, and the first match determination unit includes: Among the plurality of differences, when the predetermined number is within a predetermined value, it is determined that the two pixels match, so the pixel position of the pattern image or the image data of the document is slightly inaccurate. Even when the document is read, the accurate document size can be detected.

請求項に係る発明は、請求項に記載の画像読取装置であって、前記差分算出部は、前記比較データの主走査方向における予め定められた画素数おきの画素のみを、差分算出の対象画素とするものである。 The invention according to claim 2 is the image reading apparatus according to claim 1 , wherein the difference calculation unit calculates a difference only for pixels every predetermined number of pixels in the main scanning direction of the comparison data. This is the target pixel.

この構成によれば、差分算出部によって差分算出の対象とされる画素数が少ないので、より速く原稿サイズを検出することができる。   According to this configuration, since the number of pixels that are subjected to difference calculation by the difference calculation unit is small, the document size can be detected more quickly.

請求項に係る発明は、請求項1又は請求項2に記載の画像読取装置であって、前記パターン画像として、格子パターンを用いるものである。 The invention according to claim 3 is the image reading apparatus according to claim 1 or 2 , wherein a lattice pattern is used as the pattern image.

この構成では、パターン画像として格子パターンを用いることで、原稿に形成されている画像と、背面に形成されている画像との境界を判定しやすくしている。   In this configuration, by using a lattice pattern as a pattern image, it is easy to determine the boundary between the image formed on the original and the image formed on the back surface.

請求項に係る発明は、請求項1乃至請求項のいずれかに記載の画像読取装置であって、前記背面に形成されたパターン画像として、低濃度の画像を用いるものである。 A fourth aspect of the present invention is the image reading apparatus according to any one of the first to third aspects, wherein a low-density image is used as the pattern image formed on the back surface.

この構成では、パターン画像として低濃度の画像を用いることで、パターン画像が原稿を透けてしまうことをなくし、原稿からの画像の読取時における裏写りの発生を少なくしている。   In this configuration, by using a low-density image as the pattern image, the pattern image is prevented from being seen through the original, and the occurrence of show-through during reading of the image from the original is reduced.

請求項に係る発明は、請求項1乃至請求項のいずれかに記載の画像読取装置であって、前記読取手段によって読み取られた主走査ラインの画像データと、前記比較データ記憶手段に記憶されている比較データとを比較して、当該主走査ラインの各位置における一致度を求め、一致度の高い領域と一致度の低い領域の境目を、当該原稿の画像データの主走査方向における原稿の端位置と判定する主走査方向端位置判定手段を更に備え、
前記サイズ算出手段は、前記副走査方向端位置判定手段及び主走査方向端位置判定手段によって判定された、原稿の副走査方向及び主走査方向における端位置に基づいて、当該原稿のサイズを求めるものである。
A fifth aspect of the present invention is the image reading apparatus according to any one of the first to fourth aspects, wherein the main scanning line image data read by the reading unit and the comparison data storage unit store the image data. The comparison data is compared with each other to obtain the degree of coincidence at each position of the main scanning line, and the boundary between the high coincidence area and the low coincidence area is the original in the main scanning direction of the image data of the original. An end position determining means for determining the end position of the main scanning direction,
The size calculating means obtains the size of the document based on the edge positions in the sub-scanning direction and main scanning direction of the document determined by the sub-scanning direction edge position determining means and the main scanning direction edge position determining means. It is.

この構成によれば、読取手段によって読み取られた原稿の画像データと、比較データ記憶手段に予め記憶されているパターン画像の背景データとが、主走査方向端位置判定手段により比較され、当該主走査ラインの各位置における一致度の高い領域と一致度の低い領域の境目を、当該原稿の画像データの主走査方向における原稿の端位置と判定する。そして、この主走査方向における原稿の端位置と、副走査方向端位置判定部によって判定された副走査方向における原稿の端位置に基づいて、サイズ算出手段により原稿のサイズが求められる。   According to this configuration, the image data of the document read by the reading unit and the background data of the pattern image stored in advance in the comparison data storage unit are compared by the main scanning direction end position determining unit, and the main scanning is performed. The boundary between the high coincidence area and the low coincidence area at each line position is determined as the end position of the original in the main scanning direction of the image data of the original. Then, based on the edge position of the document in the main scanning direction and the edge position of the document in the sub-scanning direction determined by the sub-scanning direction edge position determination unit, the size of the document is obtained by the size calculating unit.

請求項1に記載の発明によれば、原稿サイズを検知するためのセンサ等のハードウェアを設けることなく副走査方向における原稿サイズを検出できるため、安価に当該原稿サイズ検知を行うことができる。また、センサを用いる従来の原稿サイズ検知のように1点のみでサイズ検知するわけではなく、主走査方向に延びるライン上の画像データを利用してサイズ検知するので、副走査方向の長さが異なる原稿であっても、精度のよいサイズ検知が可能になる。これにより、例えば、自動原稿給装装置に、サイズの異なる原稿が混載して一度に載置された場合であっても、それぞれの原稿のサイズを的確に検出することができる。 According to the first aspect of the invention, since the document size in the sub-scanning direction can be detected without providing hardware such as a sensor for detecting the document size, the document size can be detected at a low cost. Further, the size detection is not performed at a single point as in the conventional document size detection using a sensor, but size detection is performed using image data on a line extending in the main scanning direction. Even different documents can be accurately detected in size. Thereby, for example, even when documents of different sizes are mixedly placed on the automatic document feeder, the sizes of the respective documents can be accurately detected.

さらに、請求項に記載の発明によれば、パターン画像の画素位置、又は原稿の画像データが若干不正確に読み取られた場合においても、正確に副走査方向における原稿サイズを検出することができる。 Furthermore, according to the first aspect of the present invention, the document size in the sub-scanning direction can be accurately detected even when the pixel position of the pattern image or the image data of the document is read slightly inaccurately. .

請求項に記載の発明によれば、差分算出部によって差分算出の対象とされる画素数が少ないので、より速く原稿サイズを検出することができる。 According to the second aspect of the present invention, since the number of pixels that are subjected to difference calculation by the difference calculation unit is small, the document size can be detected more quickly.

請求項に記載の発明によれば、パターン画像として格子パターンを用いるので、原稿に形成されている画像と、背面に形成されている画像との境界を判定しやすくなる。 According to the third aspect of the present invention, since the lattice pattern is used as the pattern image, it is easy to determine the boundary between the image formed on the original and the image formed on the back surface.

請求項に記載の発明によれば、パターン画像として低濃度の画像を用いるので、パターン画像が原稿を透けてしまうことをなくし、原稿からの画像の読取時における裏写りの発生を少なくすることができる。 According to the fourth aspect of the present invention, since a low-density image is used as the pattern image, the pattern image is prevented from being seen through the original, and the occurrence of show-through when the image is read from the original is reduced. Can do.

請求項に記載の発明によれば、主走査方向端位置判定部によって判定された主走査方向における原稿の端位置と、副走査方向端位置判定部によって判定された副走査方向における原稿の端位置とに基づいて、原稿サイズを検知するためのセンサ等のハードウェアを設けることなく主走査方向及び副走査方向における原稿サイズ検出を、安価な構成で行うことができる。 According to the fifth aspect of the present invention, the end position of the document in the main scanning direction determined by the main scanning direction end position determination unit and the end of the document in the sub scanning direction determined by the sub scanning direction end position determination unit. Based on the position, document size detection in the main scanning direction and the sub-scanning direction can be performed with an inexpensive configuration without providing hardware such as a sensor for detecting the document size.

以下、本発明に係る実施形態を図面に基づいて説明する。図1は、本発明の一実施形態に係る画像読取装置のシートフィーダ部分の機械的な概略構成を示す斜視図である。画像読取装置は、例えば複写機、スキャナ、ファクシミリ、又はこれらの機能を併せ持つ複合機等に適用される。原稿112は、読み取る面を下にして載置され、シートフィーダの原稿引込機構(図示省略)により1枚ずつ矢印Aの方向に搬送される。原稿引込機構により引き出された原稿の下部にあたる位置には、原稿の画像を読み取る読取センサ113が設けられている。読取センサ113は、CCD(電荷結合素子)等から構成され、原稿の例えば主走査方向の1走査ラインを読み取り可能なものである。読取センサ113は、主走査方向の1走査ラインの読み取りを、引き込まれる原稿112に対し全走査ライン繰り返すことにより原稿の全面を読み取る。当該シートフィーダにおいて、読取センサ113に対する原稿の背面側であり、原稿が載置されていない場合に読取センサ113により読み取られる部分111には、所定のパターン画像114が描かれている。このパターン画像114は、原稿に裏写りせず、あらゆるタイプの原稿画像に対し原稿との境界が明確であるものが望ましく、例えば低濃度のパターン、格子パターン、又は低濃度の格子パターンである。本実施形態では、パターン画像114は、低濃度の格子パターンからなるものとする。読取センサ113は、原稿が搬送される場合、原稿面上の画像を読み取ると共に、原稿搬送方向に直交する方向における記録紙の外側領域のパターン画像114を読み取る。また、読取センサ113は、原稿が搬送されてくる前後に、パターン画像114を読み取る。   Embodiments according to the present invention will be described below with reference to the drawings. FIG. 1 is a perspective view showing a mechanical schematic configuration of a sheet feeder portion of an image reading apparatus according to an embodiment of the present invention. The image reading apparatus is applied to, for example, a copying machine, a scanner, a facsimile machine, or a multifunction machine having both functions. The documents 112 are placed with the reading surface facing down, and conveyed one by one in the direction of arrow A by a document drawing mechanism (not shown) of the sheet feeder. A reading sensor 113 that reads an image of the original is provided at a position corresponding to the lower part of the original drawn by the original drawing mechanism. The reading sensor 113 is composed of a CCD (charge coupled device) or the like, and can read, for example, one scanning line in the main scanning direction of the document. The reading sensor 113 reads the entire surface of the document by repeating reading of one scanning line in the main scanning direction with respect to the document 112 to be pulled in all scanning lines. In the sheet feeder, a predetermined pattern image 114 is drawn on a portion 111 on the back side of the document with respect to the reading sensor 113 and read by the reading sensor 113 when the document is not placed. The pattern image 114 is preferably not a show-through on the original and has a clear boundary with the original for all types of original images. For example, the pattern image 114 is a low-density pattern, a lattice pattern, or a low-density lattice pattern. In the present embodiment, the pattern image 114 is assumed to be composed of a low-density lattice pattern. When the document is transported, the reading sensor 113 reads an image on the surface of the document and also reads a pattern image 114 in the outer region of the recording paper in a direction orthogonal to the document transport direction. The reading sensor 113 reads the pattern image 114 before and after the document is conveyed.

次に、本発明に係る画像読取装置の一実施形態であるスキャナ1の機能構成を説明する。図2は、スキャナ1の機能構成を示すブロック図である。スキャナ1は、その機能部として、画像読取部11、比較データ記憶部13、原稿端位置判定部14、及びサイズ算出部15を備える。ここでは、スキャナ1の画像データの出力についての説明は省略する。   Next, the functional configuration of the scanner 1 as an embodiment of the image reading apparatus according to the present invention will be described. FIG. 2 is a block diagram illustrating a functional configuration of the scanner 1. The scanner 1 includes an image reading unit 11, a comparison data storage unit 13, a document edge position determination unit 14, and a size calculation unit 15 as functional units. Here, the description about the output of the image data of the scanner 1 is omitted.

画像読取部11は、原稿から画像を読み取る。画像読取部11の機械的構成は、図1に示す画像読取装置のシートフィーダ部分に相当する。   The image reading unit 11 reads an image from a document. The mechanical configuration of the image reading unit 11 corresponds to the sheet feeder portion of the image reading apparatus shown in FIG.

比較データ記憶部13は、原稿が載置されていない場合に読取センサ113により読み取られる上記背面のパターン画像を予め記憶しておくものである。比較データ記憶部13は、例えばRAM等から構成される。比較データ記憶部13には、画像読取部11が原稿データを読み取る直前に上記背面のパターン画像が読み取られ記憶される。なお、このパターン画像読み取り時期は、原稿データを読み取る前の任意の時期等であり、例えば、スキャナ1の原稿読取スタートボタン(図略)を押下した時である。比較データ記憶部13に記憶されるパターン画像は、原稿の画像が読み取られたときに、その画像データ(この画像データは原稿の画像とその周辺の上記背景のパターン画像とを含んでいる。)と比較され、原稿の主走査方向及び副走査方向における外端位置を検出するために用いられる。   The comparison data storage unit 13 stores in advance the back pattern image read by the reading sensor 113 when no document is placed. The comparison data storage unit 13 is composed of, for example, a RAM. In the comparison data storage unit 13, the pattern image on the back side is read and stored immediately before the image reading unit 11 reads the document data. The pattern image reading time is an arbitrary time before reading the original data, for example, when the original reading start button (not shown) of the scanner 1 is pressed. The pattern image stored in the comparison data storage unit 13 is image data when the image of the document is read (this image data includes the image of the document and the background pattern image around it). Is used to detect the outer edge position of the document in the main scanning direction and the sub-scanning direction.

原稿端位置判定部14は、画像読取部11によって読み取られた原稿画像データについて、例えば、(1)副走査方向に並ぶ複数の主走査ラインのどの走査ラインからどの走査ラインまでが原稿内のものか、(2)所定の主走査方向の1走査ラインにおける各画素が原稿内のものか否かを判定することで、原稿の副走査方向及び主走査方向の端部位置を判定するものである。原稿端位置判定部14の構成及び処理の詳細については後述する。   For example, (1) from which scanning line of a plurality of main scanning lines arranged in the sub-scanning direction to which scanning line of the document edge position determination unit 14 in the document. (2) By determining whether or not each pixel in one scanning line in a predetermined main scanning direction is in the document, the position of the edge of the document in the sub-scanning direction and the main scanning direction is determined. . Details of the configuration and processing of the document edge position determination unit 14 will be described later.

サイズ算出部15は、原稿端位置判定部14により判定された原稿の端部位置に基づいて、原稿の副走査方向及び主走査方向のサイズを求めるものである。サイズ算出部15は、読取センサ113によって読み取られる主走査方向の全読取画素数から、原稿端位置判定部14により判定された主走査方向における両端位置より外側の画素数を引いた画素数(すなわち原稿の主走査方向の画素数)に、1画素の占める主走査方向長さを乗算した長さを主走査方向の原稿サイズxとして算出する。また、サイズ算出部15は、読取センサ113によって読み取られる副走査方向の全読取画素数から、原稿端位置判定部14により判定された副走査方向における両端位置より外側の画素数を引いた画素数(すなわち原稿の副走査方向の画素数)に、1画素の占める副走査方向長さを乗算した長さを副走査方
向の原稿サイズyとして算出する。
The size calculation unit 15 obtains the size of the document in the sub-scanning direction and the main scanning direction based on the document end position determined by the document end position determination unit 14. The size calculation unit 15 subtracts the number of pixels outside the both end positions in the main scanning direction determined by the document end position determination unit 14 from the total number of read pixels in the main scanning direction read by the reading sensor 113 (that is, The length obtained by multiplying the number of pixels in the main scanning direction of the document by the length in the main scanning direction occupied by one pixel is calculated as the document size x in the main scanning direction. Further, the size calculation unit 15 subtracts the number of pixels outside the both end positions in the sub-scanning direction determined by the document end position determination unit 14 from the total number of read pixels in the sub-scanning direction read by the reading sensor 113. A length obtained by multiplying (that is, the number of pixels in the sub-scanning direction of the document) by the length in the sub-scanning direction occupied by one pixel is calculated as a document size y in the sub-scanning direction.

次に、原稿端位置判定部14の構成及び処理の詳細について説明する。図2に基づいて原稿端位置判定部14は、差分算出部141、第1一致判定部142、第2一致判定部143、及び端位置判定部144を備える。   Next, the configuration and processing details of the document edge position determination unit 14 will be described. Based on FIG. 2, the document end position determining unit 14 includes a difference calculating unit 141, a first match determining unit 142, a second match determining unit 143, and an end position determining unit 144.

差分算出部141は、比較データ記憶部13に記憶されている比較元データを構成する画素と、この画素に対応する、画像読取部11によって読み取られた各主走査ラインデータの画素との画素値の差分を算出するものである。この差分算出部141は、1つの比較元画素について、複数の比較先画素との差分を算出する。以下、この1つの比較元画素についての差分算出対象となる比較先画素の纏まりをブロックという。   The difference calculation unit 141 is a pixel value between the pixels constituting the comparison source data stored in the comparison data storage unit 13 and the pixels of each main scanning line data read by the image reading unit 11 corresponding to the pixels. Is calculated. The difference calculation unit 141 calculates a difference from a plurality of comparison target pixels for one comparison source pixel. Hereinafter, a group of comparison target pixels that are differences calculation targets for one comparison source pixel is referred to as a block.

第1一致判定部142は、差分算出部141により求められた各差分が閾値以下であるか否か(例えば、モノクロデータ0〜255の範囲の値で画素の値が表現される場合であれば、9以下であるか否か)をチェックし、差分が閾値以下の場合には、比較元画素と比較先画素とが一致したと判定し、差分が閾値より大きい場合には、比較元画素と比較先画素とは不一致であると判定するものである。   The first match determination unit 142 determines whether or not each difference obtained by the difference calculation unit 141 is equal to or less than a threshold (for example, if the pixel value is expressed by a value in the range of monochrome data 0 to 255). , 9 or less), and if the difference is less than or equal to the threshold value, it is determined that the comparison source pixel and the comparison destination pixel match, and if the difference is greater than the threshold value, It is determined that there is a mismatch with the comparison target pixel.

また、第2一致判定部143は、比較元画素ごとに比較先データとの一致を判定するのである。第2一致判定部143は、上記ブロック内の全画素についての第1一致判定部142による一致判定結果に、少なくとも1つ一致があれば、その比較元画素と比較先データとが一致と判定する。また、第2一致判定部143は、ブロック内に1つも一致がない場合には、その比較元画素と比較先データとが不一致と判定する。   The second match determination unit 143 determines a match with the comparison target data for each comparison source pixel. The second match determination unit 143 determines that the comparison source pixel and the comparison destination data match if there is at least one match in the match determination result by the first match determination unit 142 for all the pixels in the block. . In addition, when there is no match in the block, the second match determination unit 143 determines that the comparison source pixel and the comparison destination data do not match.

端位置判定部144は、副走査方向及び主走査方向における原稿の端位置を判定するものである。副走査方向における原稿端位置を判定する場合、端位置判定部144は、第2一致判定部143の判定により不一致とされた比較元画素が連続する数をカウントし、不一致である比較元画素の連続数が、予め設定されている所定数(=適宜設定される閾値:例えば、画像読取部11の主走査ライン全画素数の例えば25〜30%の数を示す値)に達しなければ、当該主走査ラインはパターン画像と一致すると判定する。また、端位置判定部144は、不一致である比較元画素の連続数が上記所定数に達している場合には、当該主走査ラインはパターン画像と一致しないと判定する。端位置判定部144は、この判定結果に基づいて、上記一致しない主走査ラインと、上記一致した主走査ラインとの境目を、原稿の画像データの副走査方向における端位置として判定する。   The end position determination unit 144 determines the end position of the document in the sub-scanning direction and the main scanning direction. When determining the document end position in the sub-scanning direction, the end position determination unit 144 counts the number of consecutive comparison source pixels determined to be inconsistent by the determination of the second match determination unit 143, and compares the comparison source pixels that do not match. If the continuous number does not reach a predetermined number set in advance (= appropriately set threshold: for example, a value indicating, for example, 25 to 30% of the total number of pixels in the main scanning line of the image reading unit 11) It is determined that the main scanning line matches the pattern image. Also, the end position determination unit 144 determines that the main scanning line does not match the pattern image when the number of consecutive comparison source pixels that do not match has reached the predetermined number. Based on the determination result, the end position determination unit 144 determines the boundary between the mismatched main scan line and the matched main scan line as the end position in the sub-scanning direction of the document image data.

また、主走査方向における原稿端位置を判定する場合、端位置判定部144は、第2一致判定部143のブロック一致判定結果において、不一致が走査ラインの原稿外から原稿内に向かう方向に連続して所定数(=適宜設定される閾値:例えば、画像読取部11の主走査ライン全画素数の例えば25〜30%の数を示す値)に達した場合、その連続の開始画素を主走査方向における原稿開始位置の画素と判定し、一致が走査ラインの原稿内から原稿外に向かう方向に連続して所定数(=適宜設定される閾値:例えば、画像読取部11による読み取りで取得されたデータと、比較データ記憶部13に記憶されている比較データとを適正に照合できる最小幅(主走査方向)となる画素数を示す値。詳細は後述。)に達した場合、その連続の開始画素の1つ前の画素を主走査方向における原稿終了位置の画素と判定する。   When determining the document end position in the main scanning direction, the end position determination unit 144 determines that the mismatch in the block match determination result of the second match determination unit 143 continues in the direction from the outside of the scan line to the inside of the document. When the predetermined number (= threshold value set as appropriate: for example, a value indicating, for example, 25 to 30% of the total number of pixels in the main scanning line of the image reading unit 11) is reached, the continuous start pixel is set in the main scanning direction. Is determined to be a pixel at the original start position in the image, and a predetermined number of coincidence in the direction from the inside of the original of the scanning line to the outside of the original (= threshold value set as appropriate: for example, data acquired by reading by the image reading unit 11 And the comparison data stored in the comparison data storage unit 13, a value indicating the number of pixels having the minimum width (main scanning direction) that can be properly verified (details will be described later). 1 of The previous pixel is determined as the pixel at the document end position in the main scanning direction.

スキャナ1による画像読み取り処理の概略を説明する。図3は、スキャナ1による画像読み取り処理の概略を示すフローチャートである。画像読取部11が主走査ライン毎に原稿及びその周辺の画像を読み取ると(S1)、この読み取った画像のデータに対して、画像処理部(図略)がスキャナ補正、シェーディング補正等の入力データの正規化処理を行う(S2)。   An outline of image reading processing by the scanner 1 will be described. FIG. 3 is a flowchart showing an outline of image reading processing by the scanner 1. When the image reading unit 11 reads the document and its peripheral image for each main scanning line (S1), the image processing unit (not shown) inputs input data such as scanner correction and shading correction for the read image data. The normalization process is performed (S2).

そして、この正規化処理が済んだ画像データに基づいて、原稿端位置判定部14が、副走査方向及び主走査方向における原稿開始位置及び終了位置の検出を開始し、有効区間を生成する(S3)。S3において原稿端位置判定部14が副走査方向及び主走査方向における有効区間開始位置を検出した時点から、画像読取部11が読み取った画像データは、有効区間内の画像データとしてメモリへの格納が開始される(S4)。このメモリへの画像データの格納処理を行う一方、原稿端位置判定部14は、副走査方向及び主走査方向における原稿終了位置の検出処理を続ける。   Then, based on the image data that has undergone this normalization processing, the document end position determination unit 14 starts detecting the document start position and end position in the sub-scanning direction and the main scanning direction, and generates an effective section (S3). ). The image data read by the image reading unit 11 from the time when the document end position determination unit 14 detects the effective section start position in the sub-scanning direction and the main scanning direction in S3 is stored in the memory as image data in the effective section. It starts (S4). While the image data is stored in the memory, the document end position determination unit 14 continues the document end position detection process in the sub-scanning direction and the main scanning direction.

主走査方向における有効区間終了位置が検出されると、以後、主走査方向のデータについては、当該検出された有効区間終了位置までのデータがメモリに格納される。原稿端位置判定部14によって、副走査方向における有効区間の終了位置が検出されると、副走査方向における有効区間終了位置となる主走査ラインまでのデータがメモリに格納される。ここまでで、画像データのメモリへの取り込みが終了する。サイズ算出部15は、検出された有効区間から原稿サイズを算出する。   When the effective section end position in the main scanning direction is detected, the data up to the detected effective section end position is stored in the memory for the data in the main scanning direction. When the document end position determination unit 14 detects the end position of the effective section in the sub-scanning direction, data up to the main scanning line that is the effective section end position in the sub-scanning direction is stored in the memory. Up to this point, the image data has been taken into the memory. The size calculator 15 calculates the document size from the detected effective section.

上記のようにして、メモリへの画像データの取り込みが終了した時点では、原稿画像データの読取及びメモリへの取り込みと、原稿有効区間の検出の両方が終了しているので、スキャナ1の制御部(図略)は、メモリからデータを読み出し、図略の画像処理部が、検出された有効区間情報に応じた画像処理を実施した後、スキャナデータとしてパーソナルコンピュータ等に出力、また、スキャナ1が画像形成装置に適用されている場合は、印刷対象データとして画像形成部に出力する(S5)。   As described above, since the reading of the original image data, the reading of the original image data into the memory, and the detection of the effective original section have been completed when the acquisition of the image data into the memory is completed, the control unit of the scanner 1 (Not shown) reads out data from the memory, the image processing unit (not shown) performs image processing according to the detected effective section information, and then outputs the data as scanner data to a personal computer or the like. If it is applied to the image forming apparatus, it is output to the image forming unit as print target data (S5).

原稿の副走査方向及び主走査方向における端位置の判定処理の流れについて説明する。図4乃至図6は原稿の副走査方向及び主走査方向における端位置の判定処理の流れを示すフローチャートである。   The flow of the edge position determination process in the sub-scanning direction and main scanning direction of the document will be described. 4 to 6 are flowcharts showing the flow of edge position determination processing in the sub-scanning direction and main-scanning direction of the document.

操作者によってスキャナ1の画像読み取り開始ボタンが押し下げられると(S11)、画像読取部11がパターン画像114を読み取って比較データを取得し(S12)、取得された比較データは比較データ記憶部13に記憶される。複写機の原稿搬送機構が、原稿を画像読取部11の原稿読取位置(読取センサ113の配設位置)への搬送を開始する(S13)。   When the image reading start button of the scanner 1 is depressed by the operator (S11), the image reading unit 11 reads the pattern image 114 and acquires comparison data (S12), and the acquired comparison data is stored in the comparison data storage unit 13. Remembered. The document transport mechanism of the copying machine starts transporting the document to the document reading position of the image reading unit 11 (position where the reading sensor 113 is disposed) (S13).

ここから、副走査方向における原稿先端位置を検出する処理が開始される。画像読取部11の読取センサ113は、主走査方向の1走査ライン分の画像のデータ読み取りを開始する(S14)。この画像読取部11による画像読み取りは、原稿が読取センサ113の読取位置に到達すると想定される時点よりも前の時点から開始する。このとき、端位置判定部144は、比較データ(パターン画像)と、画像読取部11による読取データとを比較した場合における不一致画素の連続数をカウントするカウンタのカウンタ値Nは、初期化しておく。   From here, the process of detecting the leading edge position of the document in the sub-scanning direction is started. The reading sensor 113 of the image reading unit 11 starts reading data of an image for one scanning line in the main scanning direction (S14). The image reading by the image reading unit 11 starts from a time before the time when the document is assumed to reach the reading position of the reading sensor 113. At this time, the end position determination unit 144 initializes the counter value N of the counter that counts the number of consecutive non-matching pixels when the comparison data (pattern image) and the read data by the image reading unit 11 are compared. .

上記画像読取部11による読み取り中に、原稿端位置判定部14は、当該読取で取得された画像データと、比較データ記憶部13に記憶されている比較データとが一致するか否かの判定を行う(S15)。   During reading by the image reading unit 11, the document end position determination unit 14 determines whether or not the image data acquired by the reading matches the comparison data stored in the comparison data storage unit 13. Perform (S15).

ここで、原稿端位置判定部14による原稿端位置の判定処理を説明する。図7は原稿端位置判定部14の回路構成例を示す図、図8は原稿端位置判定部14による原稿端位置の判定処理の様子を模式的に示す図である。   Here, the document edge position determination process by the document edge position determination unit 14 will be described. FIG. 7 is a diagram showing a circuit configuration example of the document end position determination unit 14, and FIG. 8 is a diagram schematically showing a state of document end position determination processing by the document end position determination unit 14.

画像読取部11により読み取られた主走査ラインの画像データを構成する1つの画素が、比較先画素として、画像読取部11から原稿端位置判定部14に入力されると、比較データ記憶部13からも比較元データとなる画素が比較元画素として原稿端位置判定部14に入力される。そして、減算器(差分算出部141として機能)1411aによって両者の差分が算出され、比較回路(第1一致判定部142として機能)1421aによって、当該算出された差分が、閾値記憶メモリ16に記憶されている予め定められた閾値(上述)以下となっているかが判定される。   When one pixel constituting the image data of the main scanning line read by the image reading unit 11 is input from the image reading unit 11 to the document end position determination unit 14 as a comparison destination pixel, the comparison data storage unit 13 Also, the pixel serving as the comparison source data is input to the document edge position determination unit 14 as the comparison source pixel. Then, a difference between the two is calculated by a subtractor (functioning as a difference calculation unit 141) 1411a, and the calculated difference is stored in the threshold value storage memory 16 by a comparison circuit (functioning as the first match determination unit 142) 1421a. It is determined whether it is below a predetermined threshold value (described above).

続いて、次の新たな比較元データの画素が比較データ記憶部13から原稿端位置判定部14に入力され、次の新たな比較先データとなる画素が画像読取部11から原稿端位置判定部14に入力されると、差分算出及び当該差分の閾値との比較が行われるが、前回の比較元画素は、減算器1411b、フリップフロップ1412b及び比較回路1421bにより、引き続き当該新たに入力された比較先画素との差分算出及び当該差分の閾値との比較が行われる。すなわち、比較元画素は、一旦原稿端位置判定部14に入力されると、フリップフロップ1412a乃至1412eと、減算器1411a乃至1411eとにより、次々に入力されてくる新たな比較先画素との差分算出及び当該差分の閾値との比較が繰り返し行われる。これにより、図8に示すように、比較元データとなる1つの画素は、比較先データとなる画素として次々に入力されてくる複数の画素(本実施形態では5つの画素)に対して、上記差分算出及び当該差分の閾値との比較が行われる。   Subsequently, the pixel of the next new comparison source data is input from the comparison data storage unit 13 to the document end position determination unit 14, and the pixel as the next new comparison destination data is input from the image reading unit 11 to the document end position determination unit. 14, difference calculation and comparison with the threshold value of the difference are performed, but the previous comparison source pixel is continuously compared with the newly input comparison by the subtractor 1411 b, flip-flop 1412 b, and comparison circuit 1421 b. Difference calculation with the previous pixel and comparison with the threshold value of the difference are performed. That is, once the comparison source pixel is input to the document edge position determination unit 14, the difference between the flip-flops 1412a to 1412e and the new comparison destination pixels input one after another is calculated by the subtracters 1411a to 1411e. And the comparison with the threshold value of the difference is repeated. Thereby, as shown in FIG. 8, one pixel serving as comparison source data is compared with a plurality of pixels (five pixels in the present embodiment) sequentially input as pixels serving as comparison destination data. Difference calculation and comparison with the threshold of the difference are performed.

このようにして1つの比較元画素(パターン画像のデータ)に対して5つの比較先画素(画像読取部11によって読み取られたデータ)との一致・不一致の判定を行った後、この5つの比較結果がOR回路(第2一致判定部143として機能)143aに入力される。このOR回路143aにより、比較結果の少なくとも1つが一致である場合には、比較データの画素が読取データの画素と一致したと判定され、1つも一致していない場合には、比較データの画素が原稿データと一致していないと判定される。   In this way, after one comparison source pixel (pattern image data) is determined to match or mismatch with five comparison target pixels (data read by the image reading unit 11), the five comparisons are performed. The result is input to the OR circuit (functioning as the second match determination unit 143) 143a. The OR circuit 143a determines that the pixel of the comparison data matches the pixel of the read data when at least one of the comparison results matches, and if no pixel matches the pixel of the read data, It is determined that the original data does not match.

このような原稿端位置判定部14による原稿端位置の判定処理による判定結果に基づき、比較元画素が比較先画素と一致する判定された場合は(S15でYES)、当該比較先画素は原稿外画像の画素である可能性が高いため、比較データ記憶部13に記憶されている比較データと、画像読取部11による読取データとを比較した場合における不一致画素の連続数をカウントするカウンタのカウンタ値Nをクリアする(S16)。また、比較元画素が比較先画素と一致していないと判定された場合は(S15でNO)、上記カウンタ値Nをインクリメントする(S17)。   If it is determined that the comparison source pixel matches the comparison destination pixel based on the determination result of the document edge position determination processing by the document edge position determination unit 14 (YES in S15), the comparison destination pixel is outside the document. Since there is a high possibility of being an image pixel, the counter value of the counter that counts the number of consecutive mismatched pixels when the comparison data stored in the comparison data storage unit 13 and the read data by the image reading unit 11 are compared. N is cleared (S16). If it is determined that the comparison source pixel does not match the comparison destination pixel (NO in S15), the counter value N is incremented (S17).

上記の比較元画素と比較先画素との比較を、主走査ラインのデータを構成する全ての画素について終了すると(S18でYES)、端位置判定部144は、上記カウンタ値Nが所定値(例えば、画像読取部11の主走査ライン全画素数の例えば25〜30%の数を示す値)以上である場合には(S19でYES)、当該主走査ラインのデータは、原稿内の画像データであると判断し、画素カウンタ144aに、当該主走査ラインを副走査有効区間開始位置として記憶させる(S20)。すなわち、端位置判定部144は、一致度の高い主走査ラインと、一致度の低い主走査ラインとの境目を、原稿の画像データの副走査方向における先端位置と判定する。以上で、副走査方向における有効区間開始位置(副走査方向における原稿先端位置)の検出を終了する。   When the comparison between the comparison source pixel and the comparison target pixel is completed for all the pixels constituting the main scanning line data (YES in S18), the end position determination unit 144 determines that the counter value N is a predetermined value (for example, If it is equal to or greater than the total number of pixels of the main scanning line of the image reading unit 11 (for example, a value indicating 25 to 30%) (YES in S19), the data of the main scanning line is image data in the document. It is determined that there is, and the main counter line is stored in the pixel counter 144a as the sub-scanning effective section start position (S20). That is, the end position determination unit 144 determines the boundary between the main scanning line with a high degree of coincidence and the main scanning line with a low degree of coincidence as the leading end position in the sub-scanning direction of the document image data. This completes the detection of the effective section start position in the sub-scanning direction (the document front end position in the sub-scanning direction).

なお、上記S15においては、読取で取得された画像データと比較データとの一致判定では、1つの比較元画素(パターン画像のデータ)に対して5つの比較先画素(画像読取部11によって読み取られたデータ)との一致・不一致の判定を行うようにしているが、これに代えて、複数の比較元画素(この複数の比較元画素からなる区間を1ブロックとする)の平均値と、これと同数の比較先画素(この複数の比較先画素からなる区間を1ブロックとする)の平均値との差分を算出して上記閾値との比較を行って、比較元画素と比較先画素との一致・不一致を1ブロック毎に判定するようにし、S19及びS20で、不一致ブロック数を示すカウンタ値Nが、所定値(画像読取部11の主走査ラインにおける全ブロック数の例えば25〜30%の数を示す値)以上である場合に、当該主走査ラインのデータが原稿内の画像データであると判断するようにしてもよい。   Note that in S15 described above, in the coincidence determination between the image data acquired by reading and the comparison data, five comparison target pixels (read by the image reading unit 11) with respect to one comparison source pixel (pattern image data). In place of this, instead of this, an average value of a plurality of comparison source pixels (a section composed of the plurality of comparison source pixels is defined as one block), and this The difference between the comparison target pixel and the average value of the same number of comparison target pixels (the section including the plurality of comparison target pixels is defined as one block) is compared with the threshold value, and the comparison source pixel and the comparison target pixel are compared. Match / mismatch is determined for each block. In S19 and S20, the counter value N indicating the number of mismatched blocks is a predetermined value (for example, 25 to 30% of the total number of blocks in the main scanning line of the image reading unit 11). number Or more), it may be determined that the data of the main scanning line is image data in the document.

この後、原稿搬送機構が原稿を主走査方向有効区間検出位置に移動させる(S21)。主走査方向有効区間検出位置は、例えば、画像読取部11の読取位置が、原稿の副走査方向の先端部から5mm程度の位置であり、S19において副走査有効区間開始位置が検出されてから一定時間経過が図略のタイマによって計測され、原稿が副走査方向の先端部が画像読取部11の読取位置に5mm程度進入したと想定される位置まで原稿搬送機構が原稿を
移動させる。
Thereafter, the document transport mechanism moves the document to the main scanning direction effective section detection position (S21). The main scanning direction effective section detection position is, for example, a position where the reading position of the image reading unit 11 is about 5 mm from the leading end in the sub scanning direction of the document, and is constant after the sub scanning effective section start position is detected in S19. The passage of time is measured by a timer (not shown), and the document transport mechanism moves the document to a position where it is assumed that the leading end in the sub-scanning direction has entered the reading position of the image reading unit 11 by about 5 mm.

次に、主走査方向における原稿開始及び終了位置の検出処理について説明する。上記S21の原稿搬送の後、この位置にある原稿に対して、画像読取部11の読取センサ113が、主走査方向の1走査ライン分の画像のデータ読み取りを開始する(S31)。端位置判定部144は、比較データ(パターン画像)と、画像読取部11による読取データとを比較した場合における不一致画素の連続数をカウントするカウンタのカウンタ値Nを初期化する。   Next, document start and end position detection processing in the main scanning direction will be described. After the document conveyance in S21, the reading sensor 113 of the image reading unit 11 starts reading the image data for one scanning line in the main scanning direction with respect to the document at this position (S31). The end position determination unit 144 initializes a counter value N of a counter that counts the continuous number of mismatched pixels when the comparison data (pattern image) and the read data by the image reading unit 11 are compared.

上記画像読取部11による読み取り中に、原稿端位置判定部14は、当該読取で取得された画像データと、比較データ記憶部13に記憶されている比較データとが一致するか否かの判定を行い(S32)、この判定結果に基づく不一致画素の連続数のカウントはS15乃至S17と同様に行う(S33,S34)。   During reading by the image reading unit 11, the document end position determination unit 14 determines whether or not the image data acquired by the reading matches the comparison data stored in the comparison data storage unit 13. (S32), and counting the number of consecutive non-matching pixels based on the determination result is performed in the same manner as S15 to S17 (S33, S34).

上記カウント後、不一致連続カウント値Nが所定値以上になったとき(S35でYES)、端位置判定部144は、当該所定値以上となったカウント値Nをカウントし始めた最初の画素の位置を主走査方向における主走査方向における原稿開始位置とし、当該位置の座標を主走査方向における有効区間開始位置として画素カウンタ144aに記憶させる(S36)。以上で、主走査方向における有効区間開始位置の検出処理が終了する。   After the above counting, when the disagreement continuous count value N becomes equal to or greater than the predetermined value (YES in S35), the end position determination unit 144 positions the first pixel that starts counting the count value N that is equal to or greater than the predetermined value. Is the original start position in the main scanning direction in the main scanning direction, and the coordinates of the position are stored in the pixel counter 144a as the effective section start position in the main scanning direction (S36). Thus, the detection process of the effective section start position in the main scanning direction is completed.

上記主走査方向における原稿開始位置の検出処理が済むと、これにより、主走査方向及び副走査方向共に有効区間内に入ったことになるため、図略の制御部は、この時点よりも後に画像読取部11が読み取ったデータが、図略のメモリに格納されるように設定する(S37)。すなわち、以後は、原稿画像の読取及び読取データのメモリへの格納と共に、主走査方向における原稿終了位置の検出も併せて行われる。   When the document start position detection process in the main scanning direction is completed, the main scanning direction and the sub-scanning direction are now within the effective section. Therefore, the control unit (not shown) displays the image after this point. The data read by the reading unit 11 is set to be stored in a memory (not shown) (S37). That is, thereafter, the document end position in the main scanning direction is detected together with the reading of the document image and the storage of the read data in the memory.

続いて、主走査方向における原稿終了位置の検出に入り、端位置判定部144は、比較データと、画像読取部11による読取データとを比較した場合に、一致する画素の連続数をカウントするカウンタのカウンタ値Mを初期化する(S38)。   Subsequently, the document end position is detected in the main scanning direction, and the end position determination unit 144 counts the continuous number of matching pixels when the comparison data and the read data by the image reading unit 11 are compared. The counter value M is initialized (S38).

原稿端位置判定部14は、上記S31の画像読取部11による読み取りで取得されたデータと、比較データ記憶部13に記憶されている比較データとが一致するか否かの判定を行う(S39)。この判定では、比較元画素と比較先画素とが一致するか否かの判断は、S15の処理と同様であるが、カウンタ値Mとして残す値は、一致する画素の連続数である。   The document edge position determination unit 14 determines whether or not the data acquired by reading by the image reading unit 11 in S31 matches the comparison data stored in the comparison data storage unit 13 (S39). . In this determination, whether or not the comparison source pixel matches the comparison destination pixel is the same as the process of S15, but the value to be left as the counter value M is the continuous number of matching pixels.

端位置判定部144は、上記カウンタ値Mが所定値(例えば、画像読取部11による読み取りで取得されたデータと、比較データ記憶部13に記憶されている比較データとを適正に照合できる最小幅(主走査方向)となる画素数を示す値。パターン画像114の格子サイズが1mmピッチであるとすると、3mm程度の幅で一致が確認できれば、画像読取部11による読み取りで取得されたデータと、比較データ記憶部13に記憶されている比較データとが一致すると判定してよいため、この場合、当該3mmに対応する50画素程度を所定値とすればよい。)以上となった場合に(S42でYES)、当該所定値以上に達したカウント値Mをカウントし始めた最初の画素の更に1つ前の画素位置を、主走査方向における原稿終了位置とし(図8参照)、当該位置の座標を主走査方向における有効区間終了位置として画素カウンタ144aに記憶させる(S43)。以上で、主走査方向における原稿終了位置の検出処理が終了する。これにより、主走査方向における有効区間の開始位置及び終了位置が検出されたため、図略の制御部は、これ以降に画像読取部11が読み取る主走査ライン毎のデータは、上記で検出された主走査方向における有効区間の開始位置及び終了位置内の画素が、図略のメモリに格納されるように設定する(S44)。   The end position determination unit 144 determines that the counter value M is a predetermined value (for example, the minimum width in which the data acquired by reading by the image reading unit 11 and the comparison data stored in the comparison data storage unit 13 can be properly verified) A value indicating the number of pixels (in the main scanning direction) If the lattice size of the pattern image 114 is 1 mm pitch, if the coincidence can be confirmed with a width of about 3 mm, the data acquired by reading by the image reading unit 11; Since it may be determined that the comparison data stored in the comparison data storage unit 13 matches, in this case, about 50 pixels corresponding to the 3 mm may be set to a predetermined value.) YES), the pixel position immediately before the first pixel that started counting the count value M that has reached the predetermined value or more is set as the document end position in the main scanning direction (see FIG. 8). The position of the coordinate is stored in the pixel counter 144a as an effective section end position in the main scanning direction (S43). This completes the document end position detection process in the main scanning direction. As a result, since the start position and end position of the effective section in the main scanning direction are detected, the control unit (not shown) reads data for each main scanning line read by the image reading unit 11 thereafter. The pixels in the start position and end position of the effective section in the scanning direction are set to be stored in a memory (not shown) (S44).

そして、次の主走査ラインの原稿データの読み取り、及び副走査方向における原稿終端位置の検出を行うために、次の主走査ラインを画像読取部11が読み取る(S51)。端位置判定部144は、比較データ(パターン画像)と、画像読取部11による読取データとを比較した場合の不一致画素の連続数カウンタのカウンタ値Nを初期化する。   Then, in order to read the document data of the next main scanning line and detect the document end position in the sub-scanning direction, the image reading unit 11 reads the next main scanning line (S51). The end position determination unit 144 initializes the counter value N of the continuous number counter of mismatched pixels when the comparison data (pattern image) and the read data by the image reading unit 11 are compared.

上記画像読取部11による読み取り中に、原稿端位置判定部14は、当該読取で取得された画像データと、比較データ記憶部13に記憶されている比較データとが一致するか否かの判定を行う(S52)。この判定結果に基づく不一致画素の連続数のカウントはS15乃至S17と同様に行う(S53,S54)。   During reading by the image reading unit 11, the document end position determination unit 14 determines whether or not the image data acquired by the reading matches the comparison data stored in the comparison data storage unit 13. This is performed (S52). Counting the number of consecutive non-matching pixels based on the determination result is performed in the same manner as S15 to S17 (S53, S54).

上記一致・不一致の判定を主走査ラインのデータを構成する全ての画素について終了すると(S55でYES)、端位置判定部144は、上記カウンタ値Nが所定値(例えば、主走査ラインの全画素数の例えば30%の数を示す値)以下である場合には(S56でYES)、当該主走査ラインのデータは、原稿外の画像データであると判断し、画素カウンタ144aに、当該主走査ラインの1つ前の走査ラインまでを副走査有効区間終了位置として記憶させる(S57)。すなわち、端位置判定部144は、一致度の高い主走査ラインと、一致度の低い主走査ラインとの境目を、原稿の画像データの副走査方向における後端位置と判定する。以上で、副走査方向における有効区間終了位置(副走査方向における原稿後端位置)の検出を終了する。   When the determination of coincidence / non-coincidence is completed for all the pixels constituting the main scanning line data (YES in S55), the end position determining unit 144 determines that the counter value N is a predetermined value (for example, all the pixels of the main scanning line). If it is equal to or smaller than the number (e.g., a value indicating 30% of the number) (YES in S56), it is determined that the data of the main scanning line is image data outside the document, and the pixel counter 144a receives the main scanning. The first scanning line before the line is stored as the sub-scanning effective section end position (S57). That is, the end position determination unit 144 determines the boundary between the main scanning line having a high degree of coincidence and the main scanning line having a low degree of coincidence as the rear end position in the sub-scanning direction of the document image data. This completes the detection of the effective section end position in the sub-scanning direction (the document trailing edge position in the sub-scanning direction).

続いて、サイズ算出部15は、上記のようにして算出した副走査方向及び主走査方向における有効区間情報に基づいて、画像読取部11で読み取られた原稿のサイズを算出する(S58)。例えば、サイズ算出部15は、A4サイズ、B5サイズ、B4サイズ等の定型サイズの寸法情報(主走査方向の原稿サイズx’×副走査方向の原稿サイズy’)を保有しておき、図9に示すように、上記のようにして求めた主走査方向の原稿サイズx×副走査方向の原稿サイズyよりも大きい、主走査方向の原稿サイズx’×副走査方向の原稿サイズy’を有する定型サイズを、原稿サイズと判定する(S101乃至S103)。   Subsequently, the size calculation unit 15 calculates the size of the document read by the image reading unit 11 based on the valid section information in the sub-scanning direction and the main scanning direction calculated as described above (S58). For example, the size calculation unit 15 holds dimension information of a standard size such as A4 size, B5 size, and B4 size (original size x ′ in the main scanning direction × original size y ′ in the sub-scanning direction). As shown in FIG. 5, the document size x ′ in the main scanning direction × the document size y ′ in the sub-scanning direction is larger than the document size x in the main scanning direction × the document size y in the sub-scanning direction obtained as described above. The standard size is determined as the document size (S101 to S103).

最後に、スキャナ1の制御部(図略)は、メモリからデータを読み出し、図略の画像処理部が、上記検出された有効区間情報に応じた画像処理を実施する(S59)。   Finally, the control unit (not shown) of the scanner 1 reads data from the memory, and the image processing unit (not shown) performs image processing according to the detected effective section information (S59).

このようにすれば、原稿サイズを検知するためのセンサ等のハードウェアを画像読取装置に設けなくても原稿サイズを検出でき、読取対象とした原稿の画像形成に適した記録紙のサイズを判定することができる。   In this way, it is possible to detect the document size without providing hardware such as a sensor for detecting the document size in the image reading apparatus, and to determine the size of the recording paper suitable for image formation of the document to be read. can do.

なお、本発明は、上記実施形態のものに限定されるものではなく、以下に述べる態様を採用することができる。上記実施形態においては、背面のパターン画像に低濃度の格子パターンを用いたが、原稿に裏写りせず(すなわち低濃度)、原稿との境界がわかりやすい(すなわち原稿と同じパターンや色合いになりにくい)パターン画像であればよく、必ずしも低濃度の格子パターンである必要はない。また、格子パターンを用いる場合には、できるだけ格子の小さいパターンを用いた方が原稿端をより正確に検出することができる。   In addition, this invention is not limited to the thing of the said embodiment, The aspect described below can be employ | adopted. In the above embodiment, a low-density grid pattern is used for the pattern image on the back, but it does not show through to the original (that is, low density), and the boundary with the original is easy to understand (that is, the same pattern and color as the original do not easily occur). ) It only needs to be a pattern image, and does not necessarily need to be a low-density lattice pattern. Further, when using a lattice pattern, it is possible to detect the document edge more accurately by using a pattern having a lattice as small as possible.

また、上記実施形態においては、シートフィーダで原稿を引き込みながら画像を読み取る場合(原稿が移動して読取センサ113は移動しない)を例に採り説明したが、プラテンガラス上に原稿を載置して画像を読み取る場合(原稿は移動せず読取センサ113が移動する)であっても同様の方法で原稿のサイズを検出することができる。   Further, in the above-described embodiment, the case where an image is read while pulling the document with the sheet feeder (the document moves and the reading sensor 113 does not move) has been described as an example. However, the document is placed on the platen glass. Even when an image is read (the reading sensor 113 moves without moving the document), the size of the document can be detected by the same method.

また、上記実施形態における比較元データと比較先データとを逆に用いて(すなわち、原稿データを比較元データとし比較データを比較先データとする。)原稿サイズの検出を行ってもよい。   Further, the document size may be detected by using the comparison source data and the comparison destination data in the above embodiment in reverse (that is, the document data is the comparison source data and the comparison data is the comparison destination data).

また、上記図5及び図6で示した主走査方向の有効区間を判定する処理では、主走査方向の1走査ライン分のデータから有効区間を判定しているが、主走査方向の複数の走査ラインのデータに基づいて、主走査方向の有効区間を算出するようにしてもよい。このようにすると、より正確な有効区間を求めることができる。   In the processing for determining the effective section in the main scanning direction shown in FIGS. 5 and 6, the effective section is determined from the data for one scanning line in the main scanning direction. The effective section in the main scanning direction may be calculated based on the line data. In this way, a more accurate effective section can be obtained.

また、上記図5及び図6で示した主走査方向の有効区間を判定する処理では、全ての比較元画素について比較先画素との一致判定を行っているが、比較データの主走査方向における予め定められた画素数おき(例えば、5画素おき等)の画素のみを、差分算出の対象画素としてもよい。また、1つの比較元画素と複数(上記実施形態では5つ)の比較先画素との一致・不一致判断結果に基づいて、当該比較元画素が比較先画素に一致するか否かを判断しているが、1つの比較元画素と、これに対応する位置の1つの比較先画素との一致・不一致判断結果に基づいて、当該比較元画素が比較先画素に一致するか否かを判断するようにしてもよい。   In the process of determining the effective section in the main scanning direction shown in FIGS. 5 and 6, all the comparison source pixels are determined to coincide with the comparison target pixel. Only pixels with a predetermined number of pixels (for example, every 5 pixels) may be set as the difference calculation target pixels. Further, based on the result of coincidence / mismatch judgment between one comparison source pixel and a plurality of (5 in the above embodiment) comparison destination pixels, it is determined whether or not the comparison source pixel matches the comparison destination pixel. However, based on the match / mismatch determination result between one comparison source pixel and one comparison destination pixel at the position corresponding thereto, it is determined whether or not the comparison source pixel matches the comparison destination pixel. It may be.

本発明の一実施形態における画像読取装置のシートフィーダ部分の機械的な構成を示す斜視図である。FIG. 3 is a perspective view illustrating a mechanical configuration of a sheet feeder portion of the image reading apparatus according to the embodiment of the present invention. 本発明の一実施形態における画像読取装置の機能構成を示すブロック図である。1 is a block diagram illustrating a functional configuration of an image reading apparatus according to an embodiment of the present invention. スキャナによる画像読み取り処理の概略を示すフローチャートである。It is a flowchart which shows the outline of the image reading process by a scanner. 原稿の副走査方向及び主走査方向における端位置の判定処理の流れを示すフローチャートである。6 is a flowchart illustrating a flow of edge position determination processing in a sub-scanning direction and a main scanning direction of a document. 原稿の副走査方向及び主走査方向における端位置の判定処理の流れを示すフローチャートである。6 is a flowchart illustrating a flow of edge position determination processing in a sub-scanning direction and a main scanning direction of a document. 原稿の副走査方向及び主走査方向における端位置の判定処理の流れを示すフローチャートである。6 is a flowchart illustrating a flow of edge position determination processing in a sub-scanning direction and a main scanning direction of a document. 原稿端位置判定部の回路構成例を示す図である。3 is a diagram illustrating a circuit configuration example of a document edge position determination unit. FIG. 原稿端位置判定部による原稿端位置の判定処理の様子を模式的に示す図である。FIG. 6 is a diagram schematically illustrating a document edge position determination process performed by a document edge position determination unit. 記録紙サイズ判定処理のフローチャートを示す図である。FIG. 10 is a flowchart of recording paper size determination processing.

1 画像読取装置
11 画像読取部(読取手段)
114 格子パターン(パターン画像)
13 比較データ記憶部(比較データ記憶手段)
14 原稿端位置判定部(副走査方向端位置判定手段、主走査方向端位置判定手段)
141 差分算出部(差分算出部)
142 第1一致判定部(第1の一致判定部)
143 第2一致判定部(第2の一致判定部)
144 端位置判定部(端位置判定部)
15 サイズ算出部(サイズ算出手段)
DESCRIPTION OF SYMBOLS 1 Image reader 11 Image reading part (reading means)
114 Lattice pattern (pattern image)
13 Comparison data storage unit (comparison data storage means)
14 Document edge position determination unit (sub-scanning direction edge position determination means, main scanning direction edge position determination means)
141 Difference calculation unit (difference calculation unit)
142 first match determination unit (first match determination unit)
143 Second match determination unit (second match determination unit)
144 Edge position determination unit (edge position determination unit)
15 Size calculator (size calculator)

Claims (5)

原稿から画像を主走査ライン毎に読み取る読取手段と、
前記読取手段の原稿読取位置における原稿の背面側に設けられた、予め定められた画像が形成されたパターン画像と、
前記パターン画像の画像データを比較データとして記憶する比較データ記憶手段と、
前記比較データ記憶手段に記憶されている比較データの各画素と、その画素と一致する主走査方向位置にある前記読取手段によって読み取られた各主走査ライン毎の画像データの画素及びその前後に位置する予め定められた画素数分の画素との各差分を算出する差分算出部と、前記各主走査ライン毎に、前記差分算出部により算出された前記対応する各画素同士の差分が、予め定められた値以内であるか否かを判定し、当該差分が予め定められた値以内である場合に当該対応する各画素同士が一致したと判定する第1の一致判定部と、前記予め定められた画素数の画素との間で前記差分算出部により差分が算出された前記比較データの画素ごとに、前記第1の一致判定部による前記各主走査ライン毎の判定結果が予め定められた数だけ一致したと判定されたか否かを判断し、当該予め定められた数だけ一致したと判定された場合に、当該比較データの画素が、当該比較データの画素と一致する主走査方向位置にある前記画像データの画素と一致したと判定する第2の一致判定部と、前記第2の一致判定部によって比較データの画素が原稿データの画素と一致したと判定された数が予め定められた数に達している場合に、当該主走査ラインの画像データが前記比較データと一致したと判定し、当該一致した主走査ラインと、一致しない主走査ラインとの境目を、前記原稿の画像データの副走査方向における端位置として判定する端位置判定部とを有する副走査方向端位置判定手段と、
前記副走査方向端位置判定手段により判定された副走査方向における端位置に基づいて、原稿のサイズを求めるサイズ算出手段と
を備える画像読取装置。
Reading means for reading an image from a document for each main scanning line;
A pattern image provided with a predetermined image provided on the back side of the document at the document reading position of the reading unit;
Comparison data storage means for storing image data of the pattern image as comparison data;
The pixels of the comparison data stored in the comparison data storage means, the pixels of the image data for each main scanning line read by the reading means at the position in the main scanning direction coinciding with the pixels, and the positions before and after the pixels A difference calculation unit for calculating each difference from a predetermined number of pixels and a difference between the corresponding pixels calculated by the difference calculation unit for each main scanning line is determined in advance. A first coincidence determination unit that determines whether or not the corresponding pixels match when the difference is within a predetermined value, and the predetermined match determination unit A predetermined number of determination results for each main scanning line by the first coincidence determination unit for each pixel of the comparison data for which the difference is calculated by the difference calculation unit with respect to pixels having a predetermined number of pixels. Only match The image data at the position in the main scanning direction where the pixels of the comparison data coincide with the pixels of the comparison data when it is determined that the predetermined number matches. A second coincidence determining unit that determines that the pixel of the comparison data matches the pixel of the original data, and the number of pixels determined by the second match determination unit that the pixel of the comparison data matches the pixel of the document data has reached a predetermined number If the image data of the main scanning line matches the comparison data, the boundary between the matching main scanning line and the non-matching main scanning line is determined in the sub-scanning direction of the image data of the document. A sub-scanning direction end position determination unit having an end position determination unit that determines the end position;
An image reading apparatus comprising: a size calculating unit that obtains the size of the document based on the end position in the sub-scanning direction determined by the sub-scanning direction end position determining unit.
前記差分算出部は、前記比較データの主走査方向における予め定められた画素数おきの画素のみを、差分算出の対象画素とする請求項に記載の画像読取装置。 The image reading apparatus according to claim 1 , wherein the difference calculation unit sets only pixels every predetermined number of pixels in the main scanning direction of the comparison data as pixels for difference calculation. 前記パターン画像として、格子パターンを用いる請求項1又は求項2に記載の画像読取装置。 Examples pattern image, the image reading apparatus according to claim 1 or Motomeko 2 using a grid pattern. 前記背面に形成されたパターン画像として、低濃度の画像を用いる請求項1乃至請求項のいずれかに記載の画像読取装置。 Examples formed pattern image on the back, the image reading apparatus according to any one of claims 1 to 3 using a low density image. 前記読取手段によって読み取られた主走査ラインの画像データと、前記比較データ記憶手段に記憶されている比較データとを比較して、当該主走査ラインの各位置における一致度を求め、一致度の高い領域と一致度の低い領域の境目を、当該原稿の画像データの主走
査方向における原稿の端位置と判定する主走査方向端位置判定手段を更に備え、
前記サイズ算出手段は、前記副走査方向端位置判定手段及び主走査方向端位置判定手段によって判定された、原稿の副走査方向及び主走査方向における端位置に基づいて、当該原稿のサイズを求める請求項1乃至請求項のいずれかに記載の画像読取装置。
The image data of the main scanning line read by the reading unit and the comparison data stored in the comparison data storage unit are compared to obtain the degree of coincidence at each position of the main scanning line, and the degree of coincidence is high. A main scanning direction end position determining means for determining a boundary of the region having a low coincidence with the region as an end position of the document in the main scanning direction of the image data of the document;
The size calculating means obtains the size of the document based on the position of the document in the sub-scanning direction and the main scanning direction determined by the sub-scanning direction end position determining means and the main scanning direction end position determining means. the image reading apparatus according to any one of claims 1 to 4.
JP2005274617A 2005-09-21 2005-09-21 Image reading device Expired - Fee Related JP4354443B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2005274617A JP4354443B2 (en) 2005-09-21 2005-09-21 Image reading device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2005274617A JP4354443B2 (en) 2005-09-21 2005-09-21 Image reading device

Publications (2)

Publication Number Publication Date
JP2007088785A JP2007088785A (en) 2007-04-05
JP4354443B2 true JP4354443B2 (en) 2009-10-28

Family

ID=37975330

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2005274617A Expired - Fee Related JP4354443B2 (en) 2005-09-21 2005-09-21 Image reading device

Country Status (1)

Country Link
JP (1) JP4354443B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5743861B2 (en) * 2011-11-18 2015-07-01 京セラドキュメントソリューションズ株式会社 Image forming apparatus
JP5865113B2 (en) * 2012-02-20 2016-02-17 株式会社Pfu Image processing apparatus, image processing system, image processing method, and image processing program
US10176341B2 (en) * 2016-03-18 2019-01-08 Oracle International Corporation Systems and methods for providing data residency protection using remote proxies

Also Published As

Publication number Publication date
JP2007088785A (en) 2007-04-05

Similar Documents

Publication Publication Date Title
JP4844247B2 (en) Image processing apparatus and image processing program
JP7211238B2 (en) Edge detection device, tilt correction device, reading device, image processing device, and edge detection method
US10194051B2 (en) Device for detecting amount of skew in document and image processing apparatus
JPH11252351A (en) Image reader
JP2009111472A (en) Image processing apparatus and image reader
EP2932702B1 (en) Method of capturing an image of a document
JP4354443B2 (en) Image reading device
JP6607019B2 (en) Document inclination amount detection apparatus and image processing apparatus
US8208171B2 (en) Image reading apparatus and method to prevent image erasing due to erroneously line-shaped noise detection
JPH11331547A (en) Original detector
US9270838B2 (en) Verifying accuracy of a scanned document
JP2004254166A (en) Image forming apparatus
US20090244662A1 (en) Image reading apparatus and image reading method
JP7196689B2 (en) Image reader
JP2022012616A (en) Image reading apparatus
JP4844427B2 (en) Image forming apparatus, specific document determination method, and specific document determination program
JP4849144B2 (en) Image reading apparatus and streak noise correction method
JP2006005834A (en) Double-sided image reader
JP5883805B2 (en) Image reading apparatus, image forming apparatus, and image reading method
JP6163907B2 (en) Image reading apparatus, image forming apparatus, and program
US9363397B2 (en) Image reading device and image forming apparatus
JP4261498B2 (en) Image reading device
US8879130B2 (en) System for capturing an image of a document
EP1463286A1 (en) System for determining the size of an original image, such as in a digital copier
JP2016197773A (en) Image reading device

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20090323

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090401

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20090529

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20090728

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20090729

R150 Certificate of patent or registration of utility model

Ref document number: 4354443

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20120807

Year of fee payment: 3

S533 Written request for registration of change of name

Free format text: JAPANESE INTERMEDIATE CODE: R313533

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

Free format text: PAYMENT UNTIL: 20120807

Year of fee payment: 3

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

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

Free format text: PAYMENT UNTIL: 20130807

Year of fee payment: 4

LAPS Cancellation because of no payment of annual fees