JP5968263B2 - Image processing device - Google Patents
Image processing device Download PDFInfo
- Publication number
- JP5968263B2 JP5968263B2 JP2013110417A JP2013110417A JP5968263B2 JP 5968263 B2 JP5968263 B2 JP 5968263B2 JP 2013110417 A JP2013110417 A JP 2013110417A JP 2013110417 A JP2013110417 A JP 2013110417A JP 5968263 B2 JP5968263 B2 JP 5968263B2
- Authority
- JP
- Japan
- Prior art keywords
- document image
- scanning direction
- edge
- value
- 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.)
- Expired - Fee Related
Links
Images
Landscapes
- Image Input (AREA)
- Facsimile Scanning Arrangements (AREA)
- Editing Of Facsimile Originals (AREA)
Description
本発明は、画像処理装置に関するものである。 The present invention relates to an image processing apparatus.
スキャナーなどの画像処理装置が画像読取を行う際に、プラテンガラス上の原稿が傾いた状態で載置されたり、自動原稿送り装置(ADF:Auto Document Feeder)による原稿送りにおいて原稿スキューが生じると、読み取られた原稿画像が傾いてしまう。 When an image processing apparatus such as a scanner scans an image, if a document on the platen glass is placed in a tilted state or a document skew occurs during document feeding by an automatic document feeder (ADF), The read original image is tilted.
ある第1の装置では、搬送対象の原稿の先端部を2つのセンサーで検出し、一方のセンサーにより先端部が検出されてから、他方のセンサーにより先端部が検出されるまでの、搬送に使用しているステッピングモーターのステップ数を測定し、そのステップ数にもとづいて原稿の傾きを検出している(例えば特許文献1参照)。 In a first apparatus, the leading end of a document to be transported is detected by two sensors, and used for transporting from the detection of the leading end by one sensor to the detection of the leading end by the other sensor. The number of steps of the stepping motor is measured, and the inclination of the document is detected based on the number of steps (see, for example, Patent Document 1).
また、別の第2の装置では、原稿の裏当て部分の読み取りデータにおける主走査方向の全幅における各画素について周辺の5×5画素の範囲の画素値の平均値を基準データとして計算し、主走査方向における各画素位置について、基準データと画像データとを比較することで原稿の4辺のエッジを検出し、そのエッジの情報に基づいて傾き補正を行っている(例えば特許文献2参照)。 In another second apparatus, the average value of the peripheral pixel values in the range of 5 × 5 pixels is calculated as reference data for each pixel in the entire width in the main scanning direction in the reading data of the backing portion of the document, and the main data is calculated. For each pixel position in the scanning direction, the reference data and the image data are compared to detect the edges of the four sides of the document, and tilt correction is performed based on the edge information (see, for example, Patent Document 2).
しかしながら、第1の装置では、センサーを設置する必要があるため、装置のコストが高くなってしまう。また、第2の装置では、主走査方向における全幅の各画素について画素値(階調を示す例えば8ビット値)を保持するラインメモリーを設ける必要があり、装置のコストが高くなってしまう。 However, since it is necessary to install a sensor in the first device, the cost of the device increases. Further, in the second apparatus, it is necessary to provide a line memory that holds a pixel value (for example, an 8-bit value indicating gradation) for each pixel of the full width in the main scanning direction, which increases the cost of the apparatus.
また、5×5画素の周辺領域における画素値の平均値を求める場合、注目画素の属するラインの前後2ラインについてのラインメモリーをさらに設ける必要があるため、さらに装置のコストが高くなってしまう。 Further, when obtaining the average value of the pixel values in the peripheral area of 5 × 5 pixels, it is necessary to further provide line memories for two lines before and after the line to which the pixel of interest belongs, which further increases the cost of the apparatus.
本発明は、上記の問題に鑑みてなされたものであり、低コストで、原稿画像の傾きを検出する画像処理装置を得ることを目的とする。 SUMMARY An advantage of some aspects of the invention is that it provides an image processing apparatus that detects the inclination of an original image at low cost.
本発明に係る画像処理装置は、原稿画像読取時に光学系からみて原稿の後側に位置する背景部位を読み取ることで得られる1または複数のラインを主走査方向において分割した複数の分割ブロック内の複数の画素の画素値に基づいて、前記複数の分割ブロックのそれぞれに対応する複数の基準値を基準データとして生成する基準データ生成部と、副走査方向に沿ってラインを選択していき、選択したライン内の主走査方向における所定の複数の画素位置についての読み取り画素値とその画素位置が属する前記分割ブロックに対応する前記基準値とに基づいて、前記原稿画像の副走査方向のエッジを検出する原稿画像エッジ検出部と、前記所定の複数の画素位置について検出された前記原稿画像の副走査方向のエッジに基づいて前記原稿画像の傾きを検出する画像属性特定部と、主走査方向におけるスジ領域を特定するスジ領域特定部とを備える。前記原稿画像エッジ検出部は、副走査方向における所定の複数のラインのそれぞれについて、前記ライン内の主走査方向における各画素位置の読み取り画素値とその画素位置が属する前記分割ブロックに対応する前記基準値とに基づいて、前記原稿画像の主走査方向のエッジを検出し、前記画像属性特定部は、前記原稿画像の副走査方向のエッジ、または、前記原稿画像の副走査方向のエッジおよび前記原稿画像の主走査方向のエッジに基づいて前記原稿画像の傾きを検出する。さらに、前記原稿画像エッジ検出部は、前記スジ領域外では、前記ライン内の各画素位置の読み取り画素値とその画素位置が属する前記分割ブロックに対応する前記基準値とに基づいて、前記原稿画像の主走査方向のエッジを検出し、前記スジ領域内では、前記ライン内の各画素位置の読み取り画素値とその画素位置の隣接画素位置の読み取り画素値とに基づいて、前記原稿画像の主走査方向のエッジを検出する。
The image processing apparatus according to the present invention includes a plurality of divided blocks obtained by dividing one or a plurality of lines obtained in the main scanning direction by reading a background portion located on the rear side of the document as viewed from the optical system when the document image is read. Based on pixel values of a plurality of pixels, a reference data generation unit that generates a plurality of reference values corresponding to each of the plurality of divided blocks as reference data, and a line along the sub-scanning direction are selected and selected An edge in the sub-scanning direction of the document image is detected based on the read pixel value for a plurality of predetermined pixel positions in the main scanning direction in the line and the reference value corresponding to the divided block to which the pixel position belongs. A document image edge detection unit configured to detect the document image based on edges in the sub-scanning direction of the document image detected for the predetermined plurality of pixel positions. Comprising an image attribute specifying unit for detecting gas, and a streak region specifying unit for specifying a streak area in the main scanning direction. The document image edge detection unit, for each of a plurality of predetermined lines in the sub-scanning direction, the read pixel value of each pixel position in the main scanning direction in the line and the reference corresponding to the divided block to which the pixel position belongs. An edge in the main scanning direction of the document image is detected based on the value, and the image attribute specifying unit is configured to detect an edge in the sub scanning direction of the document image or an edge in the sub scanning direction of the document image and the document. The inclination of the original image is detected based on the edge of the image in the main scanning direction. Further, the document image edge detection unit, outside the streak area, based on the read pixel value of each pixel position in the line and the reference value corresponding to the divided block to which the pixel position belongs, The main scanning direction of the original image is detected based on the read pixel value at each pixel position in the line and the read pixel value at the adjacent pixel position in the line in the stripe area. Detect edge in direction.
本発明によれば、低コストで、原稿画像の傾きを検出する画像処理装置が得られる。 According to the present invention, an image processing apparatus that detects the inclination of a document image can be obtained at low cost.
以下、図に基づいて本発明の実施の形態を説明する。 Hereinafter, embodiments of the present invention will be described with reference to the drawings.
図1は、本発明の実施の形態に係る画像処理装置の内部構成を示す側面図である。図1に示す画像処理装置は、スキャナー機、コピー機、ファクシミリ機、複合機などといった装置である。 FIG. 1 is a side view showing an internal configuration of an image processing apparatus according to an embodiment of the present invention. The image processing apparatus shown in FIG. 1 is an apparatus such as a scanner, a copier, a facsimile machine, or a multifunction machine.
図1に示す画像処理装置は、コンタクトガラス1a,1b、キャリッジ2,3、結像レンズ4、イメージセンサー5、白基準パッチ6、および原稿カバー7を有する。
The image processing apparatus shown in FIG. 1 includes
コンタクトガラス1aは、当該画像処理装置本体の上面に設置され、原稿カバー7の原稿自動送り装置(ADF:Auto Document Feeder)を使用せずに画像読取を行う場合に原稿を載置される。 The contact glass 1 a is installed on the upper surface of the image processing apparatus main body, and is used to place an original when reading an image without using an automatic document feeder (ADF) of the original cover 7.
また、コンタクトガラス1bは、当該画像処理装置本体の上面に設置され、原稿カバー7のADFで原稿を自動的に搬送しつつ画像読取を行う際に、原稿がその上を通過する。
Further, the
上述のADFは、コンタクトガラス1b上を通過するように原稿を通過させ、画像読取部21が、コンタクトガラス1b上を通過する原稿の画像を読み取る。
The ADF described above passes the document so as to pass over the
画像読取部21において、キャリッジ2は、図示せぬ駆動源によって副走査方向に移動可能に設置されている。キャリッジ2は、光源11とミラー12とを有する。光源11は、主走査方向に沿って配置され、例えば配列された複数の発光ダイオードで光を出射する。光源11から出射された光は、キャリッジ2の位置に応じて、コンタクトガラス1a上に載置された原稿、コンタクトガラス1b上を通過する原稿などで反射する。ミラー12は、原稿などからの反射光を反射する。原稿カバー7のADFを使用して原稿の画像読取を行う場合、キャリッジ2は、コンタクトガラス1bの下に固定的に配置される。
In the
また、キャリッジ3は、図示せぬ駆動源によってキャリッジ2とともに副走査方向に移動可能に設置されている。キャリッジ3は、ミラー13,14を有する。ミラー13,14は、キャリッジ2のミラー12からの光を反射して副走査方向に沿って出射する。
The
結像レンズ4は、ミラー14からの光をイメージセンサー5に結像させる。イメージセンサー5は、主走査方向に配列された所定の画素数の受光素子を有する一次元イメージセンサーであり、ラインごとに、その画素数の画素についての受光量に対応する電気信号を出力する。イメージセンサー5としては、例えば、CCD(Charge Coupled Device)が使用される。
The imaging lens 4 focuses the light from the
白基準パッチ6は、装置内部の天面に配置され、白色の基準データを取得するために使用される板状の部材である。
The
原稿カバー7は、コンタクトガラス1aに面接触可能で回動自在に設置されている部材であって、原稿をコンタクトガラス1aに密着させるとともに、画像読取時に環境光がコンタクトガラス1から装置内部へ入射することを防ぐ。また、原稿カバー7は、ADFを有しており、原稿トレイ7aに載置された原稿を1枚ずつ搬送ローラー7bによって搬送し、コンタクトガラス1b上を通過させる。
The document cover 7 is a member that can be brought into surface contact with the contact glass 1a and is rotatably mounted. The document cover 7 closely contacts the document with the contact glass 1a, and ambient light is incident on the inside of the apparatus from the
図2は、本発明の実施の形態に係る画像処理装置の電気的な構成を示すブロック図である。図3は、本発明の実施の形態における分割ブロック、並びに原稿画像の先端エッジおよび後端エッジの検出について説明する図である。図4は、本発明の実施の形態における原稿画像の左端エッジおよび右端エッジの検出について説明する図である。図5は、スジ領域の一例を示す図である。 FIG. 2 is a block diagram showing an electrical configuration of the image processing apparatus according to the embodiment of the present invention. FIG. 3 is a diagram for explaining detection of divided blocks and leading edge and trailing edge of a document image in the embodiment of the present invention. FIG. 4 is a diagram for explaining detection of the left end edge and the right end edge of the document image in the embodiment of the present invention. FIG. 5 is a diagram illustrating an example of a streak area.
図2に示すように、画像読取部21により得られる原稿画像を含む読み取り画像の画像データが画像処理部22に供給される。
As shown in FIG. 2, image data of a read image including a document image obtained by the
画像処理部22は、基準データ生成部31、スジ領域特定部32、原稿画像エッジ検出部33、画像属性特定部34、および原稿画像処理部35を有する。なお、画像処理部22は、ASIC(Application Specific Integrated Circuit)などでハードウェアとして実現してもよいし、コンピューターでプログラムを実行することで、ソフトウェアとして実現してもよい。
The
基準データ生成部31は、背景部位を読み取ることで得られる1または複数のラインを主走査方向において分割した複数の分割ブロック内の複数の画素の画素値に基づいて、複数の分割ブロックのそれぞれに対応する複数の基準値を基準データとして生成し、図示せぬメモリーにおいて保持する。例えば図3に示すように、副走査方向の幅がLref本のライン幅である16個の分割ブロックが設定される場合、16個の基準値がメモリーに保持される。
The reference
背景部位は、原稿画像読取時に光学系(図1におけるコンタクトガラス1a,1bなど)からみて原稿の後側に位置する部位であって、コンタクトガラス1a上の原稿をコンタクトガラス1aに押し付ける原稿カバー7の原稿押さえ部、およびコンタクトガラス1b上方の原稿搬送ガイド、原稿搬送ローラーなどの部位である。
The background portion is a portion located on the rear side of the original when viewed from the optical system (
なお、上述の基準値は、分割ブロックが1ラインである場合、その基準値に対応する分割ブロック内の画素値の最頻値とされ、分割ブロックが複数ラインである場合、その基準値に対応する分割ブロック内のそれぞれのラインにおける画素値の最頻値についての平均値とされるようにしてもよい。このようにすることで、多くのラインメモリーを必要とせずに、上述の基準値が得られる。例えば、基準データ生成部31は、画素値(濃度値)のヒストグラムを生成し、そのヒストグラムから最頻値を特定する。
The above-mentioned reference value is the mode value of the pixel values in the divided block corresponding to the reference value when the divided block is one line, and corresponds to the reference value when the divided block is a plurality of lines. Alternatively, the average value of the mode values of the pixel values in each line in the divided block may be set. By doing so, the above-mentioned reference value can be obtained without requiring a lot of line memory. For example, the reference
また、上述の基準値は、分割ブロックが1ラインである場合、その基準値に対応する分割ブロック内の画素値の平均値とされ、分割ブロックが複数ラインである場合、その基準値に対応する分割ブロック内のそれぞれのラインにおける画素値の平均値についての平均値とされるようにしてもよい。このようにすることで、多くのラインメモリーを必要とせずに、上述の基準値が得られる。 In addition, when the divided block has one line, the above-described reference value is an average value of pixel values in the divided block corresponding to the reference value. When the divided block has a plurality of lines, the reference value corresponds to the reference value. You may make it be the average value about the average value of the pixel value in each line in a division block. By doing so, the above-mentioned reference value can be obtained without requiring a lot of line memory.
このように、主走査方向において長い幅を有する1つの分割ブロック内に対して1つの基準値を決定するので、光源11、イメージセンサー5などの特性に起因する主走査方向における読み取り輝度のばらつきの影響が抑制されるとともに、ノイズの影響も抑制される。
In this way, since one reference value is determined for one divided block having a long width in the main scanning direction, variations in reading luminance in the main scanning direction due to characteristics of the
スジ領域特定部32は、コンタクトガラス1bに付着したゴミなどに起因して読み取り画像内において副走査方向に延びるスジを検出し、そのスジの主走査方向におけるスジ領域を特定する。
The streak
原稿画像エッジ検出部33は、副走査方向に沿ってラインを選択していき、選択したライン内の所定の複数の画素位置についての読み取り画素値(画像読取部21により得られた画素値)とその画素位置が属する分割ブロックに対応する基準値とに基づいて、原稿画像の副走査方向のエッジを検出する。
The document image
この実施の形態では、原稿画像エッジ検出部33は、副走査方向における所定の複数のラインのそれぞれについて、そのライン内の各画素位置の読み取り画素値とその画素位置が属する分割ブロックに対応する基準値とに基づいて、原稿画像の主走査方向のエッジを検出する。
In this embodiment, the document image
この実施の形態では、原稿画像エッジ検出部33は、原稿画像の副走査方向の先端エッジおよび後端エッジを検出するとともに、原稿画像の主走査方向の左端エッジおよび右端エッジを検出する。
In this embodiment, the document image
例えば図3に示すように、所定の画素位置P1〜P4のそれぞれについて、副走査方向における先端エッジ位置(つまり、先端エッジが存在するライン)LS1〜LS4および後端エッジ位置LE1〜LE4が検出される。 For example, as shown in FIG. 3, for each of predetermined pixel positions P1 to P4, leading edge positions (that is, lines where leading edges exist) LS1 to LS4 and trailing edge positions LE1 to LE4 in the sub-scanning direction are detected. The
また、例えば図4に示すように、所定のラインL1〜L4のそれぞれについて、主走査方向における左端エッジ位置(つまり、左端エッジが存在する画素位置)PL1〜PL4および右端エッジ位置PR1〜PR4が検出される。 For example, as shown in FIG. 4, for each of the predetermined lines L1 to L4, left end edge positions (that is, pixel positions where the left end edges exist) PL1 to PL4 and right end edge positions PR1 to PR4 in the main scanning direction are detected. Is done.
具体的には、原稿画像エッジ検出部33は、背景部位の色が白である場合、選択したラインが、分割ブロックに対応する基準値から読み取り画素値を減算して得られる値が所定の閾値以上となった最初のラインである場合、選択したラインのその注目画素位置に、原稿画像の副走査方向の先端エッジがあると判定する。
Specifically, when the color of the background portion is white, the document image
また、原稿画像エッジ検出部33は、背景部位の色が白以外の色である場合、選択したラインが、選択したラインにおける注目画素位置において、分割ブロックに対応する基準値から読み取り画素値を減算して得られる値の絶対値が所定の閾値以上となった最初のラインである場合、選択したラインのその注目画素位置に、原稿画像の副走査方向の先端エッジがあると判定する。
In addition, when the color of the background part is a color other than white, the document image
さらに、原稿画像エッジ検出部33は、背景部位の色が白である場合、先端エッジの検出後、選択したラインが、分割ブロックに対応する基準値から読み取り画素値を減算して得られる値が所定の閾値以上となった最後のラインである場合、選択したラインのその注目画素位置に、原稿画像の副走査方向の後端エッジがあると判定する。
Further, when the background part color is white, the document image
また、原稿画像エッジ検出部33は、背景部位の色が白以外の色である場合、選択したラインが、選択したラインにおける注目画素位置において、分割ブロックに対応する基準値から読み取り画素値を減算して得られる値の絶対値が所定の閾値以下へ変化した最後のラインである場合、選択したラインのその注目画素位置に、原稿画像の副走査方向の後端エッジがあると判定する。
In addition, when the color of the background part is a color other than white, the document image
さらに、具体的には、原稿画像エッジ検出部33は、背景部位の色が白である場合、ライン内の注目画素位置が、分割ブロックに対応する基準値から読み取り画素値を減算して得られる値が所定の閾値以上となった最初の画素位置である場合、そのラインのその注目画素位置に、原稿画像の主走査方向の左端エッジがあると判定する。
More specifically, when the color of the background portion is white, the document image
また、原稿画像エッジ検出部33は、背景部位の色が白以外の色である場合、ライン内の注目画素位置が、分割ブロックに対応する基準値から読み取り画素値を減算して得られる値の絶対値が所定の閾値以上となった最初の画素位置である場合、そのラインのその注目画素位置に、原稿画像の主走査方向の左端エッジがあると判定する。
In addition, when the color of the background part is a color other than white, the document image
さらに、具体的には、原稿画像エッジ検出部33は、背景部位の色が白である場合、ライン内の注目画素位置が、分割ブロックに対応する基準値から読み取り画素値を減算して得られる値が所定の閾値以上となった最後の画素位置である場合、そのラインのその注目画素位置に、原稿画像の主走査方向の右端エッジがあると判定する。
More specifically, when the color of the background portion is white, the document image
また、原稿画像エッジ検出部33は、背景部位の色が白以外の色である場合、ライン内の注目画素位置が、分割ブロックに対応する基準値から読み取り画素値を減算して得られる値の絶対値が所定の閾値以下へ変化した最後の画素位置である場合、そのラインのその注目画素位置に、原稿画像の主走査方向の右端エッジがあると判定する。
In addition, when the color of the background part is a color other than white, the document image
また、原稿画像エッジ検出部33は、スジ領域外では、上述のように、ライン内の各画素位置の読み取り画素値とその画素位置が属する分割ブロックに対応する基準値とに基づいて、原稿画像の主走査方向のエッジを検出し、スジ領域内では、ライン内の各画素位置の読み取り画素値とその画素位置の隣接画素位置の読み取り画素値とに基づいて、原稿画像の主走査方向のエッジを検出する。
Further, as described above, the document image
なお、左端エッジについては、スジ領域内では、ライン内の各画素位置の読み取り画素値とその画素位置の左側に隣接する画素位置の読み取り画素値とに基づいて、原稿画像の主走査方向の左端エッジを検出する。具体的には、ライン内の注目画素位置の読み取り画素値からその画素位置の左側に隣接する画素位置の読み取り画素値を減算して得られる値が所定の閾値以上となったとき、注目画素位置に原稿画像の主走査方向の左端エッジが存在すると判定する。 As for the left edge, in the streak area, the left edge in the main scanning direction of the document image is determined based on the read pixel value at each pixel position in the line and the read pixel value at the pixel position adjacent to the left side of the pixel position. Detect edges. Specifically, when the value obtained by subtracting the read pixel value of the pixel position adjacent to the left side of the pixel position from the read pixel value of the target pixel position in the line is equal to or greater than a predetermined threshold value, It is determined that there is a left edge in the main scanning direction of the document image.
また、右端エッジについては、スジ領域内では、ライン内の各画素位置の読み取り画素値とその画素位置の右側に隣接する画素位置の読み取り画素値とに基づいて、原稿画像の主走査方向の右端エッジを検出する。具体的には、ライン内の注目画素位置の読み取り画素値からその画素位置の右側に隣接する画素位置の読み取り画素値を減算して得られる値が所定の閾値以上となったとき、注目画素位置に原稿画像の主走査方向の右端エッジが存在すると判定する。 The right edge in the main scanning direction of the document image in the streak area is based on the read pixel value at each pixel position in the line and the read pixel value at the pixel position adjacent to the right side of the pixel position. Detect edges. Specifically, when the value obtained by subtracting the read pixel value of the pixel position adjacent to the right side of the pixel position from the read pixel value of the target pixel position in the line is equal to or greater than a predetermined threshold value, the target pixel position It is determined that the right edge of the document image in the main scanning direction exists.
例えば、図5に示す例では、ラインL1,L2については、スジ領域内で、右端エッジおよび左端エッジが検出され、ラインL3,L4については、スジ領域外で、右端エッジおよび左端エッジが検出される。 For example, in the example shown in FIG. 5, for the lines L1 and L2, the right end edge and the left end edge are detected in the streak area, and for the lines L3 and L4, the right end edge and the left end edge are detected outside the streak area. The
なお、スジ領域特定部32は、スジ領域でのエッジ検出を上述のように切り替えるためのマスクデータを生成する。マスクデータは、全幅分の1画素あたり1ビットのデータであり、スジ領域内かスジ領域外かを示すデータである。原稿画像エッジ検出部33は、そのマスクデータを参照して注目画素位置がスジ領域内か否かを判定する。
The streak
スジ領域特定部32は、以下の4つの条件から選択された1つの条件が成立した画素はスジ領域内とし、それ以外はスジ領域外としてマスクデータを生成する。
The streak
条件#1:主走査方向における注目画素位置(スジ領域内か否かを特定すべき画素位置)について、基準データ生成に使用されるラインの範囲内で副走査方向に沿って配列している画素のうち、少なくとも1つの画素の読み取り画素値(RGB値)のR値、G値およびB値の少なくとも1つが所定の閾値以下である。 Condition # 1: Pixels arranged in the sub-scanning direction within the range of lines used for reference data generation with respect to the target pixel position in the main scanning direction (the pixel position where it should be specified whether or not it is within the streak area) Among them, at least one of the R value, G value, and B value of the read pixel value (RGB value) of at least one pixel is equal to or less than a predetermined threshold value.
条件#2:主走査方向における注目画素位置について、基準データ生成に使用されるラインの範囲内で副走査方向に沿って配列している画素のうち、少なくとも1つの画素の読み取り画素値(RGB値)のR値、G値およびB値のすべてが所定の閾値以下である。 Condition # 2: At the target pixel position in the main scanning direction, the read pixel value (RGB value) of at least one pixel among the pixels arranged along the sub-scanning direction within the range of the line used for generating the reference data ) All of R value, G value and B value are below a predetermined threshold.
条件#3:主走査方向における注目画素位置について、基準データ生成に使用されるラインの範囲内で副走査方向に沿って配列している全画素の読み取り画素値(RGB値)のR値、G値およびB値の少なくとも1つが所定の閾値以下である。 Condition # 3: R value of read pixel values (RGB values) of all pixels arranged along the sub-scanning direction within the range of lines used for generating reference data for the target pixel position in the main scanning direction, G At least one of the value and the B value is less than or equal to a predetermined threshold value.
条件#4:主走査方向における注目画素位置について、基準データ生成に使用されるラインの範囲内で副走査方向に沿って配列している全画素の読み取り画素値(RGB値)のR値、G値およびB値のすべてが所定の閾値以下である。 Condition # 4: R value of read pixel values (RGB values) of all the pixels arranged along the sub-scanning direction within the range of lines used for generating reference data for the target pixel position in the main scanning direction, G All of the values and B values are below a predetermined threshold.
図2に戻り、画像属性特定部34は、主走査方向における上述の所定の複数の画素位置について検出された原稿画像の副走査方向のエッジに基づいて原稿画像の傾きを検出する。
Returning to FIG. 2, the image
また、画像属性特定部34は、原稿画像の副走査方向のエッジおよび原稿画像の主走査方向のエッジに基づいて原稿画像の傾きを検出するようにしてもよい。
Further, the image
この実施の形態では、画像属性特定部34は、原稿画像の副走査方向の先端エッジおよび後端エッジ並びに原稿画像の主走査方向の左端エッジおよび右端エッジに基づいて、原稿画像の位置を特定する。
In this embodiment, the image
原稿画像処理部35は、検出された上述の傾きの角度に応じて、原稿画像が正立するように原稿画像を回転するとともに、原稿画像の位置に応じて、例えば原稿画像が所定読み取りサイズの画像内の中央に位置するように原稿画像を移動する。
The manuscript
次に、上記画像処理装置の動作について説明する。図6は、本発明の実施の形態に係る画像処理装置の動作を説明するフローチャートである。 Next, the operation of the image processing apparatus will be described. FIG. 6 is a flowchart for explaining the operation of the image processing apparatus according to the embodiment of the present invention.
画像処理部22は、画像読取部21による読み取り画像の先頭から1ラインずつ、各ラインの読み取り画素値を取得していく。
The
そして、まず、基準データ生成部31が、上述のようにして基準データを生成する(ステップS1)。
First, the reference
その後、原稿画像エッジ検出部32は、読み取り画像内で副走査方向に沿って注目ラインを順番に選択していき、その注目ラインにおける所定の画素位置P1〜P4において副走査方向の先端エッジまたは後端エッジが存在するか否かを上述のようにして判定する(ステップS2)。
Thereafter, the document image
また、原稿画像エッジ検出部32は、その注目ラインが所定のラインL1〜L4である場合、その注目ラインにおいて主走査方向の左端エッジおよび右端エッジが存在するか否かを上述のようにして判定する(ステップS3)。
Further, when the target line is the predetermined lines L1 to L4, the document image
そして、原稿画像エッジ検出部32により先端エッジおよび後端エッジ並びに左端エッジおよび右端エッジが検出されると、画像属性特定部34は、読み取り画像内の原稿画像の位置、サイズおよび傾き角を、その先端エッジおよび後端エッジ並びに左端エッジおよび右端エッジの位置に基づいて特定する(ステップS4)。
When the leading edge, the trailing edge, the left edge, and the right edge are detected by the document image
原稿画像処理部35は、その読み取り画像内の原稿画像の位置、サイズおよび傾き角に基づき、原稿画像の編集(回転、移動など)が必要か否かを判定し(ステップS5)、原稿画像の編集が必要であると判定した場合には、必要な編集を原稿画像に対して施す(ステップS6)。
The document
以上のように、上記実施の形態によれば、基準データ生成部31は、背景部位を読み取ることで得られる1または複数のラインを主走査方向において分割した複数の分割ブロック内の複数の画素の画素値に基づいて、複数の分割ブロックのそれぞれに対応する複数の基準値を基準データとして生成し、原稿画像エッジ検出部33は、副走査方向に沿ってラインを選択していき、選択したライン内の所定の複数の画素位置についての読み取り画素値とその画素位置が属する分割ブロックに対応する基準値とに基づいて、原稿画像の副走査方向のエッジを検出する。そして、画像属性特定部34は、所定の複数の画素位置について検出された原稿画像の副走査方向のエッジに基づいて原稿画像の傾きを検出する。
As described above, according to the above embodiment, the reference
これにより、全幅分の画素値を基準データとしてラインメモリーで保持する必要がないため、装置のコストが低くなる。 This eliminates the need to store pixel values for the entire width in the line memory as reference data, thereby reducing the cost of the apparatus.
なお、上述の実施の形態は、本発明の好適な例であるが、本発明は、これらに限定されるものではなく、本発明の要旨を逸脱しない範囲において、種々の変形、変更が可能である。 The above-described embodiments are preferred examples of the present invention, but the present invention is not limited to these, and various modifications and changes can be made without departing from the scope of the present invention. is there.
例えば、上記実施の形態において、原稿画像の傾きを検出するだけでよい場合、副走査方向における原稿画像のエッジを検出し、主走査方向における原稿画像のエッジを検出しないようにしてもよい。 For example, in the above embodiment, when only the inclination of the document image needs to be detected, the edge of the document image in the sub-scanning direction may be detected and the edge of the document image in the main scanning direction may not be detected.
本発明は、例えば、スキャナー、コピー機、複合機などに適用可能である。 The present invention can be applied to, for example, a scanner, a copier, and a multifunction machine.
31 基準データ生成部
32 スジ領域特定部
33 原稿画像エッジ検出部
34 画像属性特定部
35 原稿画像処理部
31 Reference
Claims (4)
副走査方向に沿ってラインを選択していき、選択したライン内の主走査方向における所定の複数の画素位置についての読み取り画素値とその画素位置が属する前記分割ブロックに対応する前記基準値とに基づいて、前記原稿画像の副走査方向のエッジを検出する原稿画像エッジ検出部と、
前記所定の複数の画素位置について検出された前記原稿画像の副走査方向のエッジに基づいて前記原稿画像の傾きを検出する画像属性特定部と、
主走査方向におけるスジ領域を特定するスジ領域特定部と、
を備え、
前記原稿画像エッジ検出部は、副走査方向における所定の複数のラインのそれぞれについて、前記ライン内の主走査方向における各画素位置の読み取り画素値とその画素位置が属する前記分割ブロックに対応する前記基準値とに基づいて、前記原稿画像の主走査方向のエッジを検出し、
前記画像属性特定部は、前記原稿画像の副走査方向のエッジ、または、前記原稿画像の副走査方向のエッジおよび前記原稿画像の主走査方向のエッジに基づいて前記原稿画像の傾きを検出し、
前記原稿画像エッジ検出部は、前記スジ領域外では、前記ライン内の各画素位置の読み取り画素値とその画素位置が属する前記分割ブロックに対応する前記基準値とに基づいて、前記原稿画像の主走査方向のエッジを検出し、前記スジ領域内では、前記ライン内の各画素位置の読み取り画素値とその画素位置の隣接画素位置の読み取り画素値とに基づいて、前記原稿画像の主走査方向のエッジを検出すること、
を特徴とする画像処理装置。 Based on pixel values of a plurality of pixels in a plurality of divided blocks obtained by dividing one or a plurality of lines in the main scanning direction obtained by reading a background portion located on the rear side of the document as viewed from the optical system when reading a document image. A reference data generation unit that generates a plurality of reference values corresponding to each of the plurality of divided blocks as reference data;
A line is selected along the sub-scanning direction, and the read pixel value for a plurality of predetermined pixel positions in the main scanning direction in the selected line and the reference value corresponding to the divided block to which the pixel position belongs are selected. A document image edge detection unit for detecting an edge of the document image in the sub-scanning direction,
An image attribute specifying unit that detects an inclination of the document image based on edges in the sub-scanning direction of the document image detected for the predetermined plurality of pixel positions;
A streak area specifying unit for specifying a streak area in the main scanning direction;
Equipped with a,
The document image edge detection unit, for each of a plurality of predetermined lines in the sub-scanning direction, the read pixel value of each pixel position in the main scanning direction in the line and the reference corresponding to the divided block to which the pixel position belongs. And an edge in the main scanning direction of the document image based on the value,
The image attribute specifying unit detects an inclination of the document image based on an edge of the document image in a sub-scanning direction, or an edge of the document image in a sub-scanning direction and an edge of the document image in a main scanning direction;
The document image edge detection unit, outside the streak area, based on the read pixel value of each pixel position in the line and the reference value corresponding to the divided block to which the pixel position belongs, An edge in the scanning direction is detected, and in the stripe area, the original image in the main scanning direction of the document image is detected based on the read pixel value of each pixel position in the line and the read pixel value of the adjacent pixel position of the pixel position. Detecting edges,
An image processing apparatus.
前記原稿画像エッジ検出部は、前記原稿画像の副走査方向の先端エッジおよび後端エッジを検出するとともに、前記原稿画像の主走査方向の左端エッジおよび右端エッジを検出し、
前記画像属性特定部は、前記原稿画像の副走査方向の先端エッジおよび後端エッジ並びに前記原稿画像の主走査方向の左端エッジおよび右端エッジに基づいて、前記原稿画像の位置を特定し、
前記原稿画像処理部は、前記検出された前記傾きの角度に応じて前記原稿画像を回転するとともに、前記原稿画像の位置に応じて前記原稿画像を移動すること、
を特徴とする請求項1記載の画像処理装置。 A document image processing unit;
The document image edge detection unit detects a leading edge and a trailing edge in a sub-scanning direction of the document image, and detects a left edge and a right edge in a main scanning direction of the document image;
The image attribute specifying unit specifies the position of the document image based on a leading edge and a trailing edge in a sub-scanning direction of the document image and a left edge and a right edge in a main scanning direction of the document image;
The document image processing unit rotates the document image according to the detected inclination angle and moves the document image according to the position of the document image;
The image processing apparatus according to claim 1 .
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2013110417A JP5968263B2 (en) | 2013-05-24 | 2013-05-24 | Image processing device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2013110417A JP5968263B2 (en) | 2013-05-24 | 2013-05-24 | Image processing device |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JP2014230222A JP2014230222A (en) | 2014-12-08 |
| JP5968263B2 true JP5968263B2 (en) | 2016-08-10 |
Family
ID=52129662
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2013110417A Expired - Fee Related JP5968263B2 (en) | 2013-05-24 | 2013-05-24 | Image processing device |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP5968263B2 (en) |
Families Citing this family (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP6700721B2 (en) | 2015-11-04 | 2020-05-27 | キヤノン株式会社 | Image reading device and image reading method |
| JP6642833B2 (en) * | 2016-10-28 | 2020-02-12 | 京セラドキュメントソリューションズ株式会社 | Image processing device |
| JP6883283B2 (en) * | 2018-01-16 | 2021-06-09 | ブラザー工業株式会社 | Image reader |
| JP2023129806A (en) * | 2022-03-07 | 2023-09-20 | 京セラドキュメントソリューションズ株式会社 | Image forming device |
Family Cites Families (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPH07203143A (en) * | 1993-12-28 | 1995-08-04 | Mitsubishi Electric Corp | Image reader |
| JP4611160B2 (en) * | 2005-09-21 | 2011-01-12 | 株式会社Pfu | Image reading device |
| JP2007140684A (en) * | 2005-11-15 | 2007-06-07 | Toshiba Corp | Image processing apparatus, method, and program |
-
2013
- 2013-05-24 JP JP2013110417A patent/JP5968263B2/en not_active Expired - Fee Related
Also Published As
| Publication number | Publication date |
|---|---|
| JP2014230222A (en) | 2014-12-08 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US7630102B2 (en) | Image reading device and method | |
| US8102575B2 (en) | Image processing apparatus and method | |
| US20090109496A1 (en) | Image reading device and image forming device | |
| JP5968263B2 (en) | Image processing device | |
| JP7087620B2 (en) | Output image generation method of image reader and image reader | |
| US8947749B2 (en) | Image reading apparatus, control method of image reading apparatus, and storage medium | |
| JP6519808B2 (en) | Image processing device | |
| JP5255891B2 (en) | Image reading device | |
| JP2009284190A (en) | Image reading apparatus and image reading system | |
| CN110881088A (en) | Storage medium and method of generating output images | |
| JP5206582B2 (en) | Image reading device | |
| JP4678806B2 (en) | Image reading apparatus and image forming apparatus | |
| JP6642833B2 (en) | Image processing device | |
| JP5267108B2 (en) | Image processing device | |
| US12052398B2 (en) | Precision of flatbed or ADF document reading by detecting different reference positions driving image sensor in different directions to read reference plate | |
| JP2022012616A (en) | Image reading apparatus | |
| JP6081874B2 (en) | Image reading device | |
| JP2020120230A (en) | Image reader | |
| JP6288514B2 (en) | Image reading device | |
| JP5797102B2 (en) | Image reading device | |
| JP2014146981A (en) | Image reading device, image forming apparatus, and image reading method | |
| JP4864029B2 (en) | Document reader | |
| JP5901560B2 (en) | Image processing device | |
| JP2020077959A (en) | Image reading device, image reading method, and program | |
| JP2021197605A (en) | Image reading device, skew angle determination method, and program |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20150318 |
|
| A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20160310 |
|
| A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20160407 |
|
| A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20160516 |
|
| 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: 20160609 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20160705 |
|
| R150 | Certificate of patent or registration of utility model |
Ref document number: 5968263 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
| LAPS | Cancellation because of no payment of annual fees |