JP2009065378A - Base region detecting method, image processor, image forming apparatus, computer program, and recording medium - Google Patents
Base region detecting method, image processor, image forming apparatus, computer program, and recording medium Download PDFInfo
- Publication number
- JP2009065378A JP2009065378A JP2007230559A JP2007230559A JP2009065378A JP 2009065378 A JP2009065378 A JP 2009065378A JP 2007230559 A JP2007230559 A JP 2007230559A JP 2007230559 A JP2007230559 A JP 2007230559A JP 2009065378 A JP2009065378 A JP 2009065378A
- Authority
- JP
- Japan
- Prior art keywords
- background
- density
- image data
- pixels
- value
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Landscapes
- Facsimile Image Signal Circuits (AREA)
Abstract
Description
本発明は、入力された画像から下地領域を検出する下地領域検出方法、この方法を用いて下地領域の検出処理を行う画像処理装置、下地領域の検出結果に基づいて画像の形成を行う画像形成装置、下地領域の検出を行うコンピュータプログラム、及びこのコンピュータプログラムが記録された記録媒体に関する。 The present invention relates to a background area detection method that detects a background area from an input image, an image processing apparatus that performs background area detection processing using this method, and image formation that forms an image based on the detection result of the background area The present invention relates to an apparatus, a computer program for detecting a ground area, and a recording medium on which the computer program is recorded.
従来、電子写真方式又はインクジェット方式等により画像を形成する画像形成装置が普及している。画像処理技術の進展に伴って、画像形成装置はカラーの画像を高画質に再現することが可能となり、近年ではフルカラーのデジタル複写機及び複合機等が製品化されている。これらの画像形成装置では多種多様な原稿が複写され、より高画質に原稿の画像を再現するためには、原稿の種類に応じて最適な画像処理を行う必要がある。 2. Description of the Related Art Conventionally, an image forming apparatus that forms an image by an electrophotographic method or an inkjet method has been widely used. With the development of image processing technology, image forming apparatuses can reproduce color images with high image quality, and in recent years, full-color digital copiers and multifunction machines have been commercialized. In these image forming apparatuses, various kinds of originals are copied, and in order to reproduce an image of the original with higher image quality, it is necessary to perform optimum image processing according to the type of the original.
例えば、原稿には下地色を有するものがある。カラーでの複写は、白黒の複写の場合と比較して画像形成に要する時間が多く、画像形成に必要なトナー又はインク等の消費量が多い。このため、下地色を有する原稿をカラーで複写する場合、下地を再現する必要がなければ、下地の除去を行って画像形成を行うことが時間的及び経済的に望ましい。また、下地色を有するカラーの原稿を白黒で複写する場合には、下地を除去することによって複写物の文字又は画像等の視認性を高めることができる。しかし、原稿の下地のパターンは多種多様であるため、下地の除去を自動的に正確に除去することは容易ではない。 For example, some originals have a background color. Color copying requires more time for image formation than a black and white copy, and consumes a large amount of toner or ink necessary for image formation. For this reason, when an original having a background color is copied in color, if it is not necessary to reproduce the background, it is desirable in terms of time and cost to perform image formation by removing the background. Further, when a color original having a background color is copied in black and white, the visibility of characters or images on the copy can be improved by removing the background. However, since there are a wide variety of background patterns on a document, it is not easy to automatically and accurately remove the background.
特許文献1においては、読み取った画像データのヒストグラムを作成し、このヒストグラムから濃度最大値及び濃度最小値を求め、濃度最大値とヒストグラムの度数最大値の濃度とから仮下地濃度を検知し、検知した仮下地濃度と濃度最小値とから下地濃度を検知する読取画像の下地濃度検知方法が提案されている。この下地濃度検知方法では、例えば閾値との比較により濃度値から画一的に下地の判定を行う場合と比較して、読取画像の濃度のヒストグラムに応じて下地濃度が検知されるため、確実な下地濃度の検知を行うことができ、下地を正確に除去することができる。
In
特許文献2においては、画像データの濃度値と度数とのヒストグラムを生成し、生成したヒストグラムから最大度数とこの度数を持つ濃度値とを検出し、検出した値から下地除去を行う濃度範囲を決定し、画像データの各濃度値がこの濃度範囲内か否かに応じて下地除去を行うことにより、複写機などにおいて原稿のカラー下地のような部分を複写することがなく、トナーを節約することができると共に、複写した原稿の文字の視認性を向上することができる下地除去装置が提案されている。また、この下地除去装置は、検査を行う濃度領域と、最大度数に対する度数の除去レベルを決める割合とを、ユーザが操作部から指示することによって、ムラのある下地及びグラデーションのかかった下地を除去することができる。
In
特許文献3においては、入力画像の明るさが不均一な場合、及び背景濃度が場所により変化している場合等であっても、正確に2値化を行うことができる2値化処理装置が提案されている。この2値化処理装置は、入力画像を所定の領域毎にブロック化してエッジ領域を抽出し、抽出結果からエッジ領域の画素の濃度ヒストグラムを算出し、ブロック毎の2値化閾値を算出する。また、2値化処理装置は、ブロック毎の背景領域を抽出して、背景領域の画素濃度値の平均値と2値化閾値とに基づいて2値化閾値補間データを算出する。算出した2値化閾値及び2値化閾値補間データを基に、2値化処理装置は、図形領域を含むブロックを2値化閾値により2値化すると共に、背景領域からなるブロックは2値化閾値補間データにより2値化する。
しかしながら、特許文献1に記載の下地濃度検知方法においては、読み取った画像データ全体についてヒストグラムを作成し、ヒストグラムから下地として除去する濃度値の閾値を算出する構成であるため、文章の一部に写真が含まれる原稿などを読み取って取得した画像データの全体についてヒストグラムを作成した場合に、下地領域でない部分が下地と判定されて除去される虞がある。
However, in the background density detection method described in
特許文献2に記載の下地除去装置についても、画像データ全体から生成したヒストグラムから下地除去を行う濃度範囲を決定する構成であるため、同様に下地領域でない部分が下地と判定されて除去される虞がある。なお、この下地除去装置では、検査を行う濃度領域、及び最大度数に対する度数の除去レベルを決める割合をユーザが操作部から指示することができるため、ユーザの指示により誤除去を防止することができる。しかし、原稿の頁数が多い場合などには、ユーザの操作が繁雑であり不便であるという問題がある。
The background removal apparatus described in
特許文献3に記載の2値化処理装置においては、入力画像を所定の領域毎にブロック化し、ブロック毎に背景領域を抽出して2値化を行う構成であるため、文章の一部に写真が含まれる原稿などの画像であっても、各ブロックに適した2値化を行うことができる。しかしながら、この2値化処理装置は、入力画像の水平方向又は垂直方向のライン毎にエッジ数をカウントし、エッジ数が閾値を超えるか否かにより背景領域を抽出する構成であり、上述のような下地領域を除去するものではない。また、情報量の少ないブロック毎に処理を行うため、背景領域の抽出判定及び閾値の算出等の処理精度が低い虞がある。
In the binarization processing apparatus described in
本発明は、斯かる事情に鑑みてなされたものであって、その目的とするところは、入力された画像データの複数の所定領域毎にエッジの検出を行い、エッジ検出の結果に応じて複数のヒストグラムを作成して各所定領域の下地濃度候補値を抽出し、抽出した複数の下地濃度候補値から代表下地濃度候補値を得ることによって、正確な下地濃度に基づく下地除去処理を行うことができる下地領域検出方法、画像処理装置、画像形成装置、コンピュータプログラム及び記録媒体を提供することにある。 The present invention has been made in view of such circumstances, and an object of the present invention is to detect an edge for each of a plurality of predetermined areas of input image data, and to detect a plurality of edges according to the result of edge detection. A background density candidate value for each predetermined area is extracted, and a background removal process based on an accurate background density is performed by obtaining a representative background density candidate value from a plurality of extracted background density candidate values. An object of the present invention is to provide a background area detection method, an image processing apparatus, an image forming apparatus, a computer program, and a recording medium.
更に、代表下地濃度候補値を有する画素の連続性から下地領域の有無を判定することによって、より正確に下地領域を検出することができる下地領域検出方法、画像処理装置、画像形成装置、コンピュータプログラム及び記録媒体を提供することにある。 Furthermore, a background area detection method, an image processing apparatus, an image forming apparatus, and a computer program that can detect a background area more accurately by determining the presence or absence of a background area from the continuity of pixels having representative background density candidate values And providing a recording medium.
本発明に係る下地領域検出方法は、入力された画像データに含まれる下地領域を検出する下地領域検出方法において、入力された画像データからエッジを検出し、前記画像データ中の複数の所定領域毎に、検出したエッジに含まれる画素について、濃度値毎に画素数を計数し、前記所定領域毎に、前記エッジに含まれない画素について、濃度値毎に画素数を計数し、前記所定領域毎に、両計数結果を基に下地濃度候補値を抽出し、前記所定領域毎に算出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出し、前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定し、前記代表下地濃度候補値が所定濃度値を超えるか否かを判定し、両判定結果を基に、前記画像データに下地領域が含まれているか否かを判定することを特徴とする。 A background area detection method according to the present invention is a background area detection method for detecting a background area included in input image data, wherein an edge is detected from input image data, and a plurality of predetermined areas in the image data are detected. In addition, for the pixels included in the detected edge, the number of pixels is counted for each density value, and for each pixel not included in the edge, the number of pixels is counted for each density value. In addition, a background density candidate value is extracted based on both count results, and a representative background density candidate value is extracted from a plurality of background density candidate values calculated for each predetermined area based on the number of pixels of each background density candidate value. , Determining whether the number of pixels of the representative background density candidate value exceeds a predetermined number, determining whether the representative background density candidate value exceeds a predetermined density value, and based on both determination results, the image The data contains a ground area And judging whether or not Luke.
また、本発明に係る下地領域検出方法は、入力された画像データに含まれる下地領域を検出する下地領域検出方法において、入力された画像データからエッジを検出し、前記画像データ中の複数の所定領域毎に、検出したエッジに含まれない画素について、濃度値毎に画素数を計数し、前記所定領域毎に、計数結果を基に下地濃度候補値を抽出し、前記所定領域毎に算出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出し、前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定し、前記代表下地濃度候補値が所定濃度値を超えるか否かを判定し、両判定結果を基に、前記画像データに下地領域が含まれているか否かを判定することを特徴とする。 The background area detection method according to the present invention is a background area detection method for detecting a background area included in input image data, wherein an edge is detected from the input image data, and a plurality of predetermined areas in the image data are detected. For each region, for pixels not included in the detected edge, the number of pixels is counted for each density value, and for each predetermined region, a background density candidate value is extracted based on the count result, and calculated for each predetermined region. A representative background density candidate value is extracted from a plurality of background density candidate values based on the number of pixels of each background density candidate value, and it is determined whether or not the number of pixels of the representative background density candidate value exceeds a predetermined number, It is determined whether or not a representative background density candidate value exceeds a predetermined density value, and based on both determination results, it is determined whether or not a background area is included in the image data.
また、本発明に係る下地領域検出方法は、入力された画像データに含まれる下地領域を検出する下地領域検出方法において、濃度値毎の画素数を計数する計数手段を複数用い、入力された画像データからエッジを検出し、前記画像データ中の複数の所定領域毎に、エッジの検出結果に応じて前記計数手段を切り替えて、濃度値毎に画素数を計数し、前記所定領域毎に、各計数手段の計数結果を基に下地濃度候補値を抽出し、前記所定領域毎に算出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出し、前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定し、前記代表下地濃度候補値が所定濃度値を超えるか否かを判定し、両判定結果を基に、前記画像データに下地領域が含まれているか否かを判定することを特徴とする。 Further, the background area detection method according to the present invention uses a plurality of counting means for counting the number of pixels for each density value in the background area detection method for detecting the background area included in the input image data, and the input image Edges are detected from the data, and for each of a plurality of predetermined areas in the image data, the counting means is switched according to the detection result of the edges, and the number of pixels is counted for each density value. A background density candidate value is extracted based on the counting result of the counting means, and a representative background density candidate value is extracted from a plurality of background density candidate values calculated for each predetermined area based on the number of pixels of each background density candidate value. , Determining whether the number of pixels of the representative background density candidate value exceeds a predetermined number, determining whether the representative background density candidate value exceeds a predetermined density value, and based on both determination results, the image Does the data contain a background area? Or wherein the determining.
また、本発明に係る下地領域検出方法は、前記下地濃度候補値の抽出は、計数結果から最多の画素数に対応する濃度値を抽出することで行い、前記代表下地濃度候補値の抽出は、前記所定領域毎に抽出した複数の下地濃度候補値から、画素数が最多の下地濃度候補値を抽出することで行うことを特徴とする。 Further, in the background region detection method according to the present invention, the extraction of the background density candidate value is performed by extracting a density value corresponding to the largest number of pixels from the count result, and the extraction of the representative background density candidate value is This is performed by extracting a background density candidate value having the largest number of pixels from a plurality of background density candidate values extracted for each predetermined region.
また、本発明に係る下地領域検出方法は、前記画像データが、縦横に並設された複数の画素で構成される場合に、前記所定領域は、前記画像データの縦又は横の一又は複数の列で構成される領域であることを特徴とする。 In the ground area detection method according to the present invention, when the image data is composed of a plurality of pixels arranged in parallel in the vertical and horizontal directions, the predetermined area is one or a plurality of the vertical or horizontal of the image data. It is an area composed of columns.
また、本発明に係る下地領域検出方法は、前記代表下地濃度候補値を有する複数の画素について前記画像データ中での連続性を判定し、所定数以上の前記画素が連続している場合に、前記画像データに下地領域が含まれていると判定することを特徴とする。 Further, the background region detection method according to the present invention determines continuity in the image data for a plurality of pixels having the representative background density candidate value, and when a predetermined number or more of the pixels are continuous, It is determined that a background area is included in the image data.
また、本発明に係る下地領域検出方法は、前記画像データに含まれる下地領域を除去することを特徴とする。 Also, the background area detection method according to the present invention is characterized in that the background area included in the image data is removed.
また、本発明に係る画像処理装置は、入力された画像データに含まれる下地領域を検出する画像処理装置において、入力された画像データからエッジを検出するエッジ検出手段と、前記画像データ中の複数の所定領域毎に、検出したエッジに含まれる画素について、濃度値毎に画素数を計数する計数手段と、前記所定領域毎に、前記エッジに含まれない画素について、濃度値毎に画素数を計数する計数手段と、前記所定領域毎に、両計数手段の計数結果を基に下地濃度候補値を抽出する下地濃度候補値抽出手段と、前記所定領域毎に抽出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出する代表下地濃度候補値抽出手段と、前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定する画素数判定手段と、前記代表下地濃度候補値が所定濃度値を超えるか否かを判定する濃度値判定手段と、前記画素数判定手段及び前記濃度値判定手段の判定結果を基に、前記画像データに下地領域が含まれているか否かを判定する下地判定手段とを備えることを特徴とする。 Further, an image processing apparatus according to the present invention is an image processing apparatus that detects a background region included in input image data, an edge detection unit that detects an edge from the input image data, and a plurality of the image data in the image data. Counting means for counting the number of pixels for each density value for pixels included in the detected edge for each predetermined area, and the number of pixels for each density value for pixels not included in the edge for each predetermined area. A counting means for counting, a background density candidate value extracting means for extracting a background density candidate value based on the counting results of both counting means for each predetermined area, and a plurality of background density candidate values extracted for each predetermined area Representative background density candidate value extracting means for extracting a representative background density candidate value based on the number of pixels of each background density candidate value, and a pixel for determining whether or not the number of pixels of the representative background density candidate value exceeds a predetermined number Based on the determination results of the determination means, the density value determination means for determining whether or not the representative background density candidate value exceeds a predetermined density value, and the pixel number determination means and the density value determination means, And a background determination means for determining whether or not a background area is included.
また、本発明に係る画像処理装置は、入力された画像データに含まれる下地領域を検出する画像処理装置において、入力された画像データからエッジを検出するエッジ検出手段と、前記画像データ中の複数の所定領域毎に、検出したエッジに含まれない画素について、濃度値毎に画素数を計数する計数手段と、前記所定領域毎に、前記計数手段の計数結果を基に下地濃度候補値を抽出する下地濃度候補値抽出手段と、前記所定領域毎に抽出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出する代表下地濃度候補値抽出手段と、前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定する画素数判定手段と、前記代表下地濃度候補値が所定濃度値を超えるか否かを判定する濃度値判定手段と、前記画素数判定手段及び前記濃度値判定手段の判定結果を基に、前記画像データに下地領域が含まれているか否かを判定する下地判定手段とを備えることを特徴とする。 Further, an image processing apparatus according to the present invention is an image processing apparatus that detects a background region included in input image data, an edge detection unit that detects an edge from the input image data, and a plurality of the image data in the image data. For each pixel that is not included in the detected edge, a counting unit that counts the number of pixels for each density value, and for each predetermined region, a background density candidate value is extracted based on the counting result of the counting unit. And a background density candidate value extraction means for extracting a background density candidate value from the plurality of background density candidate values extracted for each predetermined area based on the number of pixels of each background density candidate value. And a pixel number determining means for determining whether the number of pixels of the representative background density candidate value exceeds a predetermined number, and a density value determining means for determining whether the representative background density candidate value exceeds a predetermined density value When Based on the determination result of the pixel number determination means and the density value determination means, characterized in that it comprises a base determination means for determining whether contains background region in the image data.
また、本発明に係る画像形成装置は、上述の画像処理装置と、画像データを前記画像処理装置へ入力する入力手段と、前記画像処理装置にて画像処理された画像データに係る画像を出力する出力手段とを備えることを特徴とする。 In addition, an image forming apparatus according to the present invention outputs the above-described image processing apparatus, an input unit that inputs image data to the image processing apparatus, and an image related to the image data image-processed by the image processing apparatus. Output means.
また、本発明に係るコンピュータプログラムは、コンピュータに、画像データに含まれる下地領域を検出させるコンピュータプログラムにおいて、コンピュータに、前記画像データからエッジを検出させ、前記画像データ中の複数の所定領域毎に、検出したエッジに含まれる画素について、濃度値毎に画素数を計数させ、前記所定領域毎に、前記エッジに含まれない画素について、濃度値毎に画素数を計数させ、前記所定領域毎に、両計数結果を基に下地濃度候補値を抽出させ、前記所定領域毎に抽出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出させ、前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定させ、前記代表下地濃度候補値が所定濃度値を超えるか否かを判定させ、両判定結果を基に、前記画像データに下地領域が含まれているか否かを判定させることを特徴とする。 The computer program according to the present invention is a computer program for causing a computer to detect a background area included in image data, causing the computer to detect an edge from the image data, and for each of a plurality of predetermined areas in the image data. For each pixel included in the detected edge, the number of pixels is counted for each density value, and for each predetermined area, for each pixel not included in the edge, the number of pixels is counted for each density value. The background density candidate value is extracted based on both count results, and the representative background density candidate value is extracted based on the number of pixels of each background density candidate value from the plurality of background density candidate values extracted for each predetermined region, Determining whether the number of pixels of the representative background density candidate value exceeds a predetermined number; determining whether the representative background density candidate value exceeds a predetermined density value; Based on the constant results, characterized in that to determine if it contains a background region in the image data.
また、本発明に係るコンピュータプログラムは、コンピュータに、画像データに含まれる下地領域を検出させるコンピュータプログラムにおいて、コンピュータに、前記画像データからエッジを検出させ、前記画像データ中の複数の所定領域毎に、検出したエッジに含まれない画素について、濃度値毎に画素数を計数させ、前記所定領域毎に、計数結果を基に下地濃度候補値を抽出させ、前記所定領域毎に抽出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出させ、前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定させ、前記代表下地濃度候補値が所定濃度値を超えるか否かを判定させ、両判定結果を基に、前記画像データに下地領域が含まれているか否かを判定させることを特徴とする。 The computer program according to the present invention is a computer program for causing a computer to detect a background area included in image data, causing the computer to detect an edge from the image data, and for each of a plurality of predetermined areas in the image data. For each pixel not included in the detected edge, the number of pixels is counted for each density value, and for each predetermined area, a background density candidate value is extracted based on the count result, and a plurality of backgrounds extracted for each predetermined area The representative background density candidate value is extracted from the density candidate value based on the number of pixels of each background density candidate value, and it is determined whether or not the number of pixels of the representative background density candidate value exceeds a predetermined number. Determining whether or not the candidate value exceeds a predetermined density value, and determining whether or not a background area is included in the image data based on both determination results To.
また、本発明に係る記録媒体は、上述のコンピュータプログラムが記録してあることを特徴とする。 A recording medium according to the present invention is recorded with the computer program described above.
本発明においては、入力された画像データからエッジを検出して、画像データの複数の所定領域毎に、エッジに含まれる画素について濃度値毎に画素数をカウンタなどにより計数すると共に、エッジに含まれない画素について濃度値毎に画素数をカウンタなどにより計数する。即ち、エッジ成分とそれ以外の成分とのそれぞれについて濃度値のヒストグラムを作成する。下地領域内に含まれるエッジ成分は少ないが、文字領域及び画像領域等に含まれるエッジ成分は多いため、エッジの検出結果に応じてカウンタを切り替えてヒストグラムを作成することによって、下地領域のヒストグラムと他の領域のヒストグラムとを分離することができる。これにより、下地の濃度値の推定、又は下地領域と他の領域とを分離するための閾値の算出が行いやすく、また、精度よく行うことができる。 In the present invention, the edge is detected from the input image data, and the number of pixels for each density value is counted by a counter or the like for each of a plurality of predetermined regions of the image data and included in the edge. The number of pixels for each density value is counted by a counter or the like for pixels that are not. That is, a histogram of density values is created for each of the edge component and the other components. Although there are few edge components included in the background area, there are many edge components included in the character area and the image area, etc., so by generating a histogram by switching the counter according to the edge detection result, The histograms of other regions can be separated. Accordingly, it is easy to estimate the density value of the background or calculate the threshold value for separating the background area from other areas, and it is possible to accurately perform the calculation.
なお、本発明においては、入力された画像データからエッジを検出して、画像データの複数の所定領域毎に、エッジに含まれない画素について濃度値毎に画素数をカウンタなどにより計数し、即ちエッジ以外の成分のみについて濃度値のヒストグラムを作成して、下地領域の検出を行うこともできる。この方法の場合、エッジに含まれる画素を考慮して下地領域の検出を行う上述の方法と比較して、検出精度が多少低下する虞がある(例えば、エッジで挟まれる文字領域の画素については、この画素の濃度値が文字の濃度値であると判断することができないため、文字が多いと文字の濃度値が下地の濃度値として誤判定される可能性がある)が、下地領域の検出を行うことは可能である。 In the present invention, an edge is detected from input image data, and the number of pixels for each density value is counted by a counter or the like for each of a plurality of predetermined areas of the image data, It is also possible to create a histogram of density values for only components other than the edges and detect the background area. In the case of this method, there is a possibility that the detection accuracy may be slightly reduced as compared with the above-described method in which the background region is detected in consideration of the pixels included in the edge (for example, for pixels in the character region sandwiched between edges) Since the density value of this pixel cannot be determined to be the density value of the character, if there are many characters, the density value of the character may be erroneously determined as the density value of the background). It is possible to do.
また、本発明においては、濃度値毎の画素数を計数する計数手段として例えばカウンタを複数用いる。画像データは横方向又は縦方向等に順次的に各画素の処理が行われるが、この際に入力された画像データからエッジを検出し、画像データの複数の所定領域毎に、例えばエッジの立ち上がり又は立ち下がり等に応じてカウンタを切り替えながら計数を行って複数のヒストグラムを作成する。原稿中の下地領域と文字領域又は画像領域等とはエッジにて切り替わるため、領域毎にヒストグラムを分離して作成することができる。これにより、下地の濃度値の推定、又は下地領域と他の領域とを分離するための閾値の算出が行いやすく、また、精度よく行うことができる。 In the present invention, for example, a plurality of counters are used as counting means for counting the number of pixels for each density value. The image data is processed for each pixel sequentially in the horizontal direction or the vertical direction. Edges are detected from the input image data at this time, and for example, rising edges are detected for each of a plurality of predetermined areas of the image data. Alternatively, a plurality of histograms are created by performing counting while switching the counter according to the fall or the like. Since the background region and the character region or the image region in the document are switched at the edge, the histogram can be created separately for each region. Accordingly, it is easy to estimate the density value of the background or calculate the threshold value for separating the background area from other areas, and it is possible to accurately perform the calculation.
このようにして作成した複数のヒストグラムから、各所定領域での下地濃度候補値を抽出し、抽出した複数の下地濃度候補値から代表下地濃度候補値を更に抽出する。本発明においては、例えば複数の計数結果、即ち複数のヒストグラムから画素数が最多の濃度値を抽出して各所定領域での下地濃度候補値とする。更に、複数の所定領域について抽出した複数の下地濃度候補値から、画素数が最多の下地濃度候補値を抽出して代表下地濃度候補値とする。この代表下地濃度候補値が、原稿全体での下地の濃度値の推定値となる。計数した代表下地濃度候補値の画素数が所定数を超え、代表下地濃度候補値が所定濃度値を超える場合に、この代表下地濃度候補値は画像データの全体に万遍なく存在する濃度値であると判断できるため、代表下地濃度候補値を下地の濃度値として、画像データに下地領域が含まれていると判定することができる。 A background density candidate value in each predetermined region is extracted from the plurality of histograms thus created, and a representative background density candidate value is further extracted from the extracted plurality of background density candidate values. In the present invention, for example, a density value having the largest number of pixels is extracted from a plurality of counting results, that is, a plurality of histograms, and set as background density candidate values in each predetermined region. Further, a background density candidate value having the largest number of pixels is extracted from a plurality of background density candidate values extracted for a plurality of predetermined areas, and set as a representative background density candidate value. This representative background density candidate value is an estimated value of the background density value of the entire document. When the number of representative background density candidate values counted exceeds a predetermined number and the representative background density candidate value exceeds a predetermined density value, the representative background density candidate value is a density value that exists uniformly in the entire image data. Therefore, it can be determined that the background area is included in the image data using the representative background density candidate value as the background density value.
また、本発明においては、画像データが縦横に並設された複数の画素で構成される場合、画素数を計数してヒストグラムを作成する所定領域を、画像データの縦又は横の一又は複数の列で構成される領域、即ち画像データの一又は複数のラインとする。画像データを所定領域に分離する処理が容易である。この所定領域毎に下地濃度候補値を抽出し、更に代表下地濃度候補値を抽出する構成とすることによって、画像データの全体に万遍なく下地濃度の画素が存在しているか否かを検出することができ、画像データの一部に濃度が偏っている場合などに誤検出が生じ難い。 In the present invention, when the image data is composed of a plurality of pixels arranged side by side in the vertical and horizontal directions, the predetermined area for counting the number of pixels and creating a histogram is set as one or a plurality of vertical or horizontal of the image data. It is assumed that a region composed of columns, that is, one or more lines of image data. Processing for separating image data into predetermined areas is easy. By detecting the background density candidate value for each predetermined area and further extracting the representative background density candidate value, it is detected whether or not the background density pixels exist uniformly in the entire image data. Therefore, it is difficult for erroneous detection to occur when the density is biased to a part of the image data.
また、本発明においては、代表下地濃度候補値を有する画素が画像データ中に連続して存在するか否か、及び連続する場合にはその画素数等を連続性として判定する。代表下地濃度候補値を有する画素が連続する場合には、その領域は下地領域である可能性が高く、画像データに下地領域が含まれていると判定することができる。 In the present invention, whether or not pixels having representative background density candidate values are continuously present in the image data, and the number of pixels when they are consecutive, are determined as continuity. When pixels having representative background density candidate values continue, it is highly possible that the area is a background area, and it can be determined that the background area is included in the image data.
また、本発明においては、代表下地濃度候補値を有する画素であり、且つ、連続性を有する画素を下地領域として除去する。上述のように下地領域を精度よく判定することができるため、原稿全体の画質を劣化させることなく、下地領域のみを精度よく除去することが可能である。 In the present invention, pixels having representative background density candidate values and having continuity are removed as a background area. Since the background area can be determined with high accuracy as described above, it is possible to accurately remove only the background area without degrading the image quality of the entire document.
また、本発明においては、上述の方法による下地領域の検出及び除去を画像処理装置及び画像形成装置等にて行う。これにより、画像処理装置による画像処理結果及び画像形成装置により形成される画像の画質が向上する。また、上述の方法による下地領域の検出及び除去をコンピュータプログラムにて行う。これにより、汎用的なコンピュータにて精度のよい下地領域の検出及び除去を行うことが可能となり、汎用性が高まる。また、このコンピュータプログラムを記録媒体に記録しておくことによって、容易に多数のコンピュータに下地領域の検出及び除去を行わせることができる。 In the present invention, the detection and removal of the base region by the above-described method is performed by an image processing apparatus, an image forming apparatus, or the like. Thereby, the image processing result by the image processing apparatus and the image quality of the image formed by the image forming apparatus are improved. In addition, the detection and removal of the background area by the above-described method is performed by a computer program. Thereby, it becomes possible to detect and remove the base region with high accuracy by a general-purpose computer, and versatility is enhanced. In addition, by recording this computer program on a recording medium, a large number of computers can be easily detected and removed.
本発明による場合は、画像データの所定領域毎にエッジ検出の結果に応じて複数のヒストグラムを作成して、所定領域毎の下地濃度候補値を抽出し、複数の下地濃度候補値から代表下地濃度候補値を抽出すると共に、代表下地濃度候補値及びその画素数が所定の閾値を超えた場合に下地領域と判定することによって、下地領域の検出を精度よく行うことができる。更には、代表下地濃度候補値を有する画素の連続性を調べて下地領域の検出を行うことによって、検出精度をより高めることができる。よって、原稿の画像データから精度よく下地領域の除去などの処理を行うことができ、処理後の画像データの画質を高めることができる。 According to the present invention, a plurality of histograms are created for each predetermined area of the image data according to the result of edge detection, a background density candidate value for each predetermined area is extracted, and the representative background density is extracted from the plurality of background density candidate values. By extracting the candidate value and determining the background area when the representative background density candidate value and the number of pixels exceed a predetermined threshold, the background area can be detected with high accuracy. Furthermore, detection accuracy can be further improved by detecting the background region by examining the continuity of pixels having representative background density candidate values. Therefore, it is possible to perform processing such as removal of the background area with high accuracy from the image data of the document, and to improve the image quality of the processed image data.
以下、本発明をその実施の形態を示す図面に基づき具体的に説明する。図1は、本発明に係る画像形成装置の構成を示すブロック図である。図において1は、画像形成装置の各部の制御及び各種の演算等を行うCPU(Central Processing Unit)である。CPU1には、ROM(Read Only Memory)2、RAM(Random Access Memory)3、操作部4、表示部5、メモリ装着部6、画像入力装置11、画像出力装置12及び画像処理装置20等がバスを介して接続されており、これらの制御を行うようにしてある。なお、本図に示す画像形成装置は、所謂デジタルカラー複写機である。
Hereinafter, the present invention will be specifically described with reference to the drawings showing embodiments thereof. FIG. 1 is a block diagram showing a configuration of an image forming apparatus according to the present invention. In the figure,
ROM2は、マスクROM、EEPROM(Electrically Erasable Programmable ROM)又はフラッシュメモリ等の不揮発性のメモリ素子により構成され、CPU1が実行するプログラム及び実行に必要なデータ等が予め記憶されている。画像形成装置の電源投入後に、CPU1はROM2からプログラムを読み出して実行することにより処理を開始するようにしてある。RAM3は、SRAM(Static RAM)、DRAM(Dynamic RAM)又はフラッシュメモリ等によるデータの書き換えが可能な大容量のメモリ素子により構成され、CPU1が演算処理を行う際に発生するデータ及びユーザが設定する各種の設定値等を記憶するようにしてある。
The
操作部4は、ファンクションキー、スタートキー、テンキー及び電源キー等を備えており、ユーザからの複写スタート指令又は複写設定の入力等の操作を受け付けることができるようにしてある。操作部4は、受け付けたユーザの操作をCPU1へ与えるようにしてある。表示部5は、液晶ディスプレイを備え、CPU1からの表示命令に基づいて、画像形成装置の動作状態、ユーザへの警告メッセージ、及びユーザの操作を補助する各種のメニュー等を液晶ディスプレイに表示するようにしてある。なお、操作部4及び表示部5は、両者を一体に構成したタッチパネルであってもよい。
The
メモリ装着部6は、所謂メモリカードスロットであり、SDメモリカード又はメモリスティック等のメモリカード100を着脱自在に装着することができるようにしてある。メモリ装着部6にメモリカード100が装着された場合、CPU1はメモリカード100に記憶されたデータの読み出し及びメモリカード100へのデータの書き込みを行うことができる。また、メモリカード100にプログラムコード101が記憶されている場合には、CPU1はメモリカード100からプログラムコード101を読み出してRAM3に記憶すると共に、プログラムコード101を実行してプログラムコード101に係る処理を行うことができるようにしてある。なお、ROM2が書き換え可能なメモリ素子で構成されている場合には、メモリカード100から読み出したプログラムコード101をROM2に記憶してもよい。
The
画像入力装置11は、原稿に光を照射する光源、CCD(Charge Coupled Device)などのイメージセンサが並設された受光部等を備えるスキャナにて構成されている。画像入力装置11は、CPU1の制御に基づいて、光源により原稿へ光を照射すると共に、受光部を一方向へ移動させて、原稿からの反射光をR(赤)G(緑)B(青)の3つの色成分に分解して受光部で読み取り、RGBのアナログ信号として画像処理装置20へ与えるようにしてある。
The image input device 11 includes a light source that irradiates light on a document, and a scanner that includes a light receiving unit in which image sensors such as a CCD (Charge Coupled Device) are arranged in parallel. Based on the control of the
画像処理装置20は、A/D変換部21、シェーディング補正部22、入力階調補正部23、領域分離処理部24、下地検出処理部25、下地除去処理部26、空間フィルタ処理部27、変倍処理部28、色補正部29、黒生成下色除去部30、出力階調補正部31及び階調再現処理部32等を備えている。A/D変換部21は、画像入力装置11から与えられたRGBのアナログ信号を例えば8ビットのデジタル信号、即ちRGBの画像データに変換するものであり、変換したRGBの画像データをシェーディング補正部22に与えるようにしてある。
The
シェーディング補正部22は、A/D変換部21から与えられたRGBの画像データに対して、画像入力装置11の照明系、結像系及び撮像系等において生じる各種の歪みを、予め取得してある情報に従って取り除くシェーディング処理を行い、シェーディング処理されたRGBの画像データを入力階調補正部23へ与えるようにしてある。入力階調補正部23は、シェーディング補正部22にて歪みが取り除かれたRGBの画像データに対して、カラーバランスの調整及びコントラストの調整等の処理を行って、処理後のRGBの画像データを領域分離処理部24へ与えるようにしてある。
The
領域分離処理部24は、入力階調補正部23から与えられたRGBの画像データ中の各画素を、文字領域、網点領域又は写真領域等のいずれに属するかを判定し、各画素を分離するようにしてある。領域分離処理部24は、処理結果として各画素がいずれの領域に属しているかを示す情報(領域分離結果)を、下地検出処理部25、空間フィルタ処理部27、黒生成下色除去部30及び階調再現処理部32へ与えると共に、入力階調処理部23から与えられたRGBの画像データをそのまま下地検出処理部25へ与えるようにしてある。また、領域分離処理部24は、文字領域の分離を行う際には、画像データのエッジ検出処理を行い、エッジの検出結果を基に分離を行うようにしてある。なお、画像データのエッジ検出は、例えばソーベルフィルタを用いた画像処理を施すことによって行うことができる。
The region
下地検出処理部25は、領域分離処理部24から与えられたRGBの画像データに含まれる下地領域の検出を行うものである。詳細は後述するが、下地検出処理部25は、与えられたRGBの画像データに下地領域が含まれるか否かの判定を行い、下地領域が含まれる場合にはこの領域に係る情報を下地検出結果として下地除去処理部26へ出力するようにしてあると共に、与えられたRGBの画像データを下地除去処理部26へ出力するようにしてある。
The background
下地検出処理部25にて下地領域が検出された場合、下地除去処理部26にはRGBの画像データと下地検出結果が同期して入力される。下地除去処理部26は、与えられたRGBの画像データに対して下地検出結果に基づく下地除去処理を行って、下地が除去されたRGBの画像データを空間フィルタ処理部27へ出力するようにしてある。
When the background area is detected by the background
空間フィルタ処理部27は、領域分離処理部24から与えられる領域分離の結果に基づいて、下地除去処理部26にて下地除去されたRGBの画像データに対してデジタルフィルタによる空間フィルタ処理を行うようにしてある。これにより、画像の空間周波数特性が補正され、画像出力装置12が出力する画像にぼやけ又は粒状性劣化等を生じることが防止される。例えば、領域分離処理部24にて文字領域に分離された領域には、特に黒文字又は色文字の再現性を高めることを目的として、空間フィルタ処理部27が鮮鋭強調のフィルタ処理を施して高周波成分を強調する。また、例えば領域分離処理部24にて網点領域に分離された領域には、空間フィルタ処理部27がローパスフィルタ処理を施して入力網点成分を除去する。このように空間フィルタ処理が施されたRGBの画像データは、空間フィルタ処理部27から変倍処理部28へ与えられる。
The spatial
画像形成装置においては、ユーザは操作部4を操作することによって、形成する画像の拡大/縮小の設定を行うことができるようにしてある。変倍処理部28は、空間フィルタ処理が施されたRGBの画像データに対して、ユーザが設定した所定の倍率となるように拡大演算処理又は縮小演算処理を行うようにしてあり、演算処理後のRGBの画像データを色補正部29へ出力するようにしてある。
In the image forming apparatus, the user can set enlargement / reduction of an image to be formed by operating the
色補正部29は、変倍処理部28から与えられたRGBの画像データを、C(シアン)M(マゼンタ)Y(イエロー)の色空間の画像データに変換すると共に、画像出力装置12での色再現の忠実化実現のために、CMYの各色成分に色補正処理を行うようにしてある。色補正処理は、具体的には、不要吸収成分をそれぞれ含むCMYのトナー又はインク等の分光特性に基づいた色濁りを、CMYの各色成分から取り除く処理である。色補正部29は、変換したCMYの画像データを黒生成下色除去部30へ与えるようにしてある。
The
黒生成下色除去部30は、領域分離処理部24から与えられた領域分離結果、及び色補正部29から与えられたCMYの画像データの各色成分に基づいて、K(黒)の色成分を生成する黒生成処理を行うと共に、元のCMYの各色成分から黒生成処理にて生成されたK成分を差し引いて新たなCMY信号を生成する処理を行うようにしてある。これにより、色補正部29から与えられたCMYの画像データは、CMYKの4つの色成分を有する画像データに変換される。
The black generation and under
例えば、スケルトンブラックによる黒生成処理を行う場合に、スケルトンカーブの入出力特性をy=f(x)とし、入力されるデータをC、M、Yとし、出力されるデータをC’、M’、Y’、K’とし、UCR(Under Color Removal、下色除去)率をα(0<α<1)とすると、黒生成下色除去処理は以下の式で表される。黒生成下色除去部30の黒生成下色除去処理により変換されたCMYKの画像データは、出力階調補正部31にて補正処理が施された後に、階調再現処理部32へ与えられるようにしてある。
K’ = f{min(C、M、Y)}
C’ = C−αK’
M’ = M−αK’
Y’ = Y−αK’
For example, when performing black generation processing using skeleton black, the input / output characteristics of the skeleton curve are set to y = f (x), the input data are C, M, and Y, and the output data are C ′ and M ′. , Y ′ and K ′, and the UCR (Under Color Removal) rate is α (0 <α <1), the black generation and under color removal processing is expressed by the following equation. The CMYK image data converted by the black generation / undercolor removal process of the black generation /
K ′ = f {min (C, M, Y)}
C ′ = C−αK ′
M ′ = M−αK ′
Y ′ = Y−αK ′
階調再現処理部32は、領域分離処理部24から与えられる領域分離結果に応じて、出力階調補正部31から与えられたCMYKの画像データに対して、階調再現処理を行うようにしてある。階調再現処理は、画像データを複数の画素に分類して中間調を再現できるようにする処理であり、二値又は多値のディザ法又は誤差拡散法等を用いることができる。例えば、領域分離処理部24にて文字領域に分離された領域には、特に黒文字又は色文字の再現性を高めることを目的として、階調再現処理部32が画像出力装置12の高域周波数成分の再現に適する二値化処理又は多値化処理を施すようにしてある。また、例えば領域分離処理部24にて網点領域に分離された領域には、出力階調補正部31にて画像データの濃度を画像出力装置12の特性値である網点面積率に変換する階調補正処理を施しておき、階調再現処理部32が画像データを画素に分離してそれぞれの階調を再現できるように中間階調処理を施すようにしてある。また、例えば領域分離処理部24にて写真領域に分離された領域には、階調再現処理部32が画像出力装置12における階調再現性に適する二値化処理又は多値化処理を施すようにしてある。
The gradation
階調再現処理部32による処理が施されてCMYKの画像データは、図示しない画像メモリなどの記憶手段に一時的に蓄積された後、CPU1の制御により画像形成のタイミングに合わせて記憶手段から読み出されて画像出力装置12へ与えられるようにしてある。画像出力装置12は、与えられた画像データを紙などの記録用紙上に出力するものであり、電子写真方式又はインクジェット方式等のプリンタである。例えば、電子写真方式の場合には、画像出力装置12は、感光体ドラムを所定の電位に帯電する帯電器、与えられた画像データに応じてレーザ光を発して感光体ドラム表面に静電潜像を生成するレーザ書込器、感光体ドラム表面に生成された静電潜像にトナーを供給して顕像化する現像器及び感光体ドラム表面に形成されたトナー像を紙上に転写する転写器等を備える。なお、画像出力装置12は、ディスプレイなどの表示装置であってもよい。
The CMYK image data processed by the gradation
なお、図1に示す画像処理装置20においては、下地検出処理部25及び下地除去処理部26が領域分離処理部24の直後に配されているが、これに限るものではなく、空間フィルタ処理部27の後などの他の位置に配する構成であってもよく、少なくとも領域分離処理部24より後であり、色補正部29の前の位置であればいずれの位置に配されてもよい。また、下地検出処理部25及び下地除去処理部26が連続的に配されなくてもよく、これらの間に空間フィルタ処理部27などが配される構成であってもよい。
In the
次に、画像処理装置20の下地検出処理部25の詳細について説明する。図2乃至図5は、本発明に係る画像処理装置20の下地検出処理部の詳細構成を示すブロック図である。下地検出処理部25は、計数部35、下地判定部36及び下地領域抽出部37等を有しており、領域分離処理部24が出力したRGBの画像データは下地検出処理部25の計数部35に与えられるようにしてある。計数部35は第1カウンタ41、第2カウンタ42及び下地濃度カウンタ43の3つのカウンタを有しており(図3参照)、第1カウンタ41及び第2カウンタ42には、領域分離処理部24の領域分離結果に含まれるエッジ検出結果が与えられている。第1カウンタ41は、画素の濃度値(0〜255)毎に画像データに含まれる画素を計数してヒストグラムを作成することができるカウンタであり、256個のカウンタの集合体である。第2カウンタ42及び下地濃度カウンタ43についても同様の構成である。
Next, details of the background
図6は、計数部35の第1カウンタ41及び第2カウンタ42による計数を説明するための模式図であり、計数部35に与えられる画像データの一部を拡大して図示したものである。また、領域分離処理部24にてエッジ検出を行った結果、エッジに該当する画素をハッチングを付した正方形で示し、エッジに該当しない画素をハッチングを付さない正方形で示してある。計数部35は、与えられたRGBの画像データについて、横方向のラインに従って各画素の濃度値を調べ、第1カウンタ41及び第2カウンタ42による計数を行うようにしてある。
FIG. 6 is a schematic diagram for explaining counting by the first counter 41 and the
例えば、計数部35は、第1カウンタ41を用いて画素数の計数を画素aから開始し、第1カウンタ41の画素aの濃度値に応じたカウント値に1を加算する。計数部35は横方向のラインに従って第1カウンタ41による計数を継続して行い、エッジに該当する画素bに到達した場合、第1カウンタ41から第2カウンタ42にカウンタを切り替えて、第2カウンタを用いた画素の計数を行う。その後、計数部35はエッジに該当しない画素cに到達した場合には、第2カウンタ42から第1カウンタ41にカウンタを切り替えて、第1カウンタ41を用いた画素の計数を行うようにしてある。即ち、計数部35は、第1カウンタ41にて画像データ中のエッジに該当しない画素(ハッチングを付していない画素)の計数を行ってエッジ以外の成分のヒストグラムを作成し、第2カウンタ42にてエッジに該当する画素(ハッチングを付した画素)の計数を行ってエッジ成分のヒストグラムを作成するようにしてある。
For example, the
また、計数部35は、第1カウンタ41及び第2カウンタ42による計数を画像データの所定ライン(1ライン〜数ライン程度)毎に行うようにしてある。計数部35は、所定ラインの画素について計数を終了した場合、第1カウンタ41及び第2カウンタ42の計数結果から最大のカウント値を有する濃度値を抽出する。このとき、第1カウンタ41からカウント値が最大の濃度値を抽出すると共に、第2カウンタ42からカウント値が最大の濃度値を抽出し、これらの2つの濃度値のカウント値を比較して、よりカウント値が多い方の濃度値を更に抽出すればよい。これにより、入力された画像データの所定ラインにおける下地濃度候補値が得られる。計数部35は、抽出した濃度値(下地濃度候補値)に応じた下地濃度カウンタ43のカウント値に1を加算する。
The
その後、計数部35は、第1カウンタ41及び第2カウンタ42のカウント値をリセットし、全画像データについて計数が終了するまで、所定ライン毎の計数を繰り返し行うようにしてある。全画像データについて上述の処理が終了した場合、計数部35は、下地濃度カウンタ43による計数結果から、カウント値が最大の濃度値を代表下地濃度候補値として抽出し、このときの最大カウント値及び濃度値を下地判定部36へ出力するようにしてある。
Thereafter, the
なお、計数部35が下地濃度カウンタ43の計数結果からカウント値が最大のものを抽出するのみでなく、下地濃度カウンタ43のカウント値が予め定められた閾値以上の濃度値を複数の代表下地濃度候補値として抽出する構成としてもよい。カウント値が最大のもののみを抽出する場合、濃度値をカウントした領域に含まれる下地領域が少ないと下地領域以外の濃度値が抽出される。よって、このような領域が複数存在する場合には、最終的な下地領域の判定の際に、誤判定が生じる可能性がある。そこで、下地濃度カウンタ43のカウント値が予め定められた閾値以上の複数の濃度値を抽出することによって、カウント値が最大でなくとも領域毎にある程度下地が存在すれば、下地領域の濃度値が複数の代表下地濃度候補値として抽出されるため、最終的な判定の際に正しい下地濃度が判定される可能性が高くなる。
The
下地判定部36は、最大カウント値判定部45及び濃度値判定部46等を有しており、計数部35から与えられる最大カウント値及び濃度値から画像データに下地が存在するか否かを判定するものである。計数部35からの出力は最大カウント値判定部45に与えられており、最大カウント値判定部45は与えられた最大カウント値が予め定められた第1閾値を超えるか否かを判定するようにしてある。第1閾値は、例えば下地濃度カウンタ43によるカウント値の合計に対する60%程度のカウント値とすることができるが、これに限るものではなく、種々の画像データを調査して適切な値を設定すればよい。
The
なお、計数部35を下地濃度カウンタ43のカウント値が予め定められた閾値以上の濃度値を複数の代表下地濃度候補値として抽出する構成とした場合には、下地判定部36は最大カウント値判定部45を有さない構成とすることができる。この場合、下地判定部36は、計数部35からの複数のカウント値及び濃度値を濃度値判定部46へ与えるものとする。
When the
最大カウント値が第1閾値を超える場合、最大カウント値判定部45は計数部35から与えられた濃度値を濃度値判定部46へ与えて、濃度値の判定を行わせるようにしてある。濃度値判定部46は、与えられた濃度値が予め定められた第2閾値を超えるか否かを判定するようにしてある。第2閾値もまた第1閾値と同様に、種々の画像データを調査して下地として許容される濃度範囲を予め設定すればよく、例えば濃度値が200以上を下地の濃度値とした場合には第2閾値を199と設定すればよい。濃度値判定部46にて濃度値が第2閾値を超えると判定された場合、下地判定部36は入力された画像データに下地濃度の画素が含まれていると判定し、このときの濃度値を下地濃度値として下地領域抽出部37へ出力するようにしてある。
When the maximum count value exceeds the first threshold value, the maximum count
なお、計数部35を下地濃度カウンタ43のカウント値が予め定められた閾値以上の濃度値を複数の代表下地濃度候補値として抽出する構成とした場合には、濃度値判定部46は与えられた複数の代表下地濃度候補値が第2閾値を超えるか否かをそれぞれ判定し、第2閾値を超える全ての濃度値を下地濃度値として下地領域抽出部37へ出力する。
In the case where the
なお、下地判定部36は、閾値1及び閾値2との比較により下地濃度と判定した下地濃度値のみでなく、この値の前後の濃度値を含めて複数の濃度値を下地濃度値として出力してもよい。下地判定部36は、判定した下地濃度値の前後の所定範囲について濃度値に対応するカウンタ値を下地濃度カウンタ43から取得し、このカウンタ値が所定値を超える濃度地を下地濃度値とすればよい。このときの所定値は、例えば画像データの全所定領域の数(即ち、下地濃度カウンタ43の全カウント値の合計値)に対して1/4以上の値などとする。
The
下地領域抽出部37は、下地濃度判定部51、連続性カウンタ52、下地領域判定部53及び下地ラインカウンタ54等を有している。下地領域抽出部37は、下地判定部36から与えられた下地濃度値を基に、入力されたRGBの画像データから下地領域の抽出を行うものであり、下地濃度値の画素が所定数以上連続した場合に、この連続した画素を下地領域として抽出するようにしてある。RGBの画像データ及び下地濃度値は下地濃度判定部51に与えられ、下地濃度判定部51は画像データの各画素の濃度値が与えられた下地濃度値に一致するか否かをラインに従って順に判定するようにしてある。下地濃度判定部51は、画像データの各画素の濃度値が下地濃度値に一致する場合には連続性カウンタ52に1を加算し、一致しない場合には連続性カウンタ52をリセットするようにしてある。また、下地濃度判定部51は、画像データのライン毎に処理を行うようにしてあり、1ラインの処理が終了するごとに連続性カウンタ52をリセットするようにしてある。
The background
連続性カウンタ52は、下地濃度値を有する画素が画像データ中で連続する数を計数するためのものであり、1つの値を計数する簡単なカウンタである。連続性カウンタ52は、計数結果であるカウント値を下地領域判定部53へ出力するようにしてある。下地領域判定部53は、連続性カウンタ52のカウント値が第3閾値を超えるか否かを判定し、第3閾値を超える場合には連続した画素が下地の画素である旨を示す情報を画像データに同期して下地除去処理部26へ出力するようにしてある。
The
また、下地領域判定部53は、画像データのライン毎に下地の画素が含まれていたか否か(即ち、ライン毎に一度でも連続性カウンタ52のカウント値が第3閾値を超えたか否か)を調べ、下地の画素が含まれていた場合には下地ラインカウンタ54に1を加算するようにしてある。下地領域判定部53は、画像データのライン毎にこの判定を行って下地ラインカウンタ54による計数を行って、画像データの全ラインの処理が終了した後に、下地の画素が含まれるライン数が全ライン数の所定割合(例えば70%など)を超えるか否かを調べる。下地の画素が含まれるライン数が所定割合を超える場合、下地領域判定部53は与えられた画像データが下地領域を有すると判定し、また下地の画素が含まれるライン数が所定割合を超えない場合には、画像データが下地領域を有しないと判定し、判定結果を下地除去処理部26へ通知するようにしてある。下地除去処理部26は、この判定結果を基に、画像データが下地領域を有する場合にのみ下地除去処理を行うようにしてある。
Further, the background
なお、計数部35を下地濃度カウンタ43のカウント値が予め定められた閾値以上の濃度値を複数の代表下地濃度候補値として抽出する構成とし、下地判定部36が第2閾値を超える全ての濃度値を下地濃度値として下地領域抽出部37へ出力する構成とした場合には、下地領域抽出部37にて以下の処理を行って、局所的な下地を下地領域ではないと判定し、下地領域の除去を行わないようにすることが可能である。例えば、下地領域抽出部37は与えられた複数の下地濃度値毎に下地濃度判定部51にてそれぞれ判定を行い、連続性カウンタ52にて最もカウント値が大きい(即ち、最も連続性の高い)ものについて、下地領域判定部53にて判定を行う構成とすることができる。
Note that the
また、下地除去処理部26にて下地除去処理を行うことに代えて、例えば画像形成装置が複数の用紙トレイを備えて、各用紙トレイに異なる色つきの用紙をセットすると共に、用紙の色と用紙トレイとの対応を関係付けておくことができる構成の場合には、下地領域抽出部37で抽出された下地領域の色を基に、この色に最も近い色の用紙を使用して出力を行う構成としてもよい。
Further, instead of performing the background removal processing in the background
図7は、本発明に係る画像形成装置が行う画像データの下地に係る画像処理の手順を示すフローチャートであり、プログラムコード101を実行するCPU1の制御により画像処理装置20にて行われる処理である。まず画像処理装置20は、領域分離処理部24にて、画像入力装置11から入力された画像データのエッジ検出を行う(ステップS1)。エッジ検出の結果を基に、画像処理装置20は下地検出処理部25の計数部35にて計数処理を行い(ステップS2)、代表下地濃度候補値を抽出する。次いで、抽出した代表下地濃度候補値を基に、画像処理装置20は下地検出処理部25の下地判定部36にて第1閾値及び第2閾値による下地判定処理を行い(ステップS3)、画像データに下地濃度値が含まれているか否かを調べる(ステップS4)。
FIG. 7 is a flowchart showing a procedure of image processing relating to the background of image data performed by the image forming apparatus according to the present invention, which is processing performed by the
下地濃度値が含まれている場合(S4:YES)、画像処理装置20は下地検出処理部25の下地領域抽出部37にて下地領域抽出処理を行って(ステップS5)、下地濃度値を有する画素の連続性から、画像データに下地領域が存在するか否かを調べる(ステップS6)。下地領域が存在する場合(S6:YES)、画像処理装置20は下地除去処理部26にて下地除去処理を行って(ステップS7)、処理を終了する。ステップS4にて下地濃度地が含まれていない場合(S4:NO)、又はステップS6にて下地領域が存在しない場合(S6:NO)、画像処理装置20は下地除去処理を行わずに処理を終了する。
When the background density value is included (S4: YES), the
図8及び図9は、本発明に係る画像形成装置が行う計数処理の手順を示すフローチャートであり、図7のフローチャートのステップS2にて行われる処理である。画像処理装置20の計数部35は、まず計数に用いるカウンタとして第1カウンタ41を選択し(ステップS21)、1画素分の画像データを取得する(ステップS22)。なお、画像データの1画素は各8ビット(0〜255)のR、G、Bの濃度値で構成されており、濃度値0が黒を表し、濃度値255が赤、緑、青を表すものとする。
8 and 9 are flowcharts showing the procedure of the counting process performed by the image forming apparatus according to the present invention, which is the process performed in step S2 of the flowchart of FIG. The
次いで、計数部35は、取得した画素に対する領域分離処理部24からのエッジ検出結果を取得して(ステップS23)、エッジから非エッジへ又は非エッジからエッジへエッジの変化が生じたか否かを調べる(ステップS24)。エッジに変化が生じた場合(S24:YES)、計数部35は第1カウンタ41から第2カウンタ42へ又は第2カウンタ42から第1カウンタ41へカウンタの切り替えを行い(ステップS25)、選択されたカウンタを用いて、取得した画素の濃度値に対応するカウント値のカウントアップを行う(ステップS26)。また、エッジに変化が生じていない場合(S24:NO)、計数部35はカウンタの切り替えを行うことなく、選択されたカウンタのカウントアップを行う(ステップS26)。
Next, the
次いで、計数部35は、上述の処理を所定ラインについて終了したか否かを調べ(ステップS27)、終了していない場合には(S27:NO)、ステップS22へ戻って上述の処理を繰り返し行う。所定ラインについて処理が終了した場合(S27:YES)、計数部35は、第1カウンタ41及び第2カウンタ42のカウント値を調べて、カウント値が最大の濃度値(下地濃度候補値)を抽出し(ステップS28)、抽出した濃度値に対応する下地濃度カウンタ43のカウントアップを行って(ステップS29)、第1カウンタ41及び第2カウンタ42をリセットする(ステップS30)。
Next, the
次いで、計数部35は、画像データの全画素について上述の処理を終了したか否かを調べ(ステップS31)、全画素について処理を終了していない場合は(S31:NO)、ステップS21へ戻って上述の処理を繰り返し行う。全画素について処理を終了した場合(S31:YES)、計数部35は、下地濃度カウンタ43のカウント値から、カウント値が最大の濃度値(代表下地濃度候補値)を抽出して(ステップS32)、抽出した最大カウント値及び対応する濃度値を下地判定部36へ出力し、計数処理を終了する。
Next, the
図10は、本発明に係る画像形成装置が行う下地判定処理の手順を示すフローチャートであり、図7のフローチャートのステップS3にて行われる処理である。まず、画像処理部20の下地判定処理部36は、計数部35が出力した最大カウント値及び濃度値を取得し(ステップS41)、取得した最大カウント値が第1閾値を超えるか否かを最大カウント値判定部45にて調べる(ステップS42)。最大カウント値が第1閾値を超える場合には(S42:YES)、更に、下地判定処理部36は、取得した濃度値が第2閾値を超えるか否かを濃度値判定部46にて調べる(ステップS43)。濃度値が第2閾値を超える場合(S43:YES)、下地判定処理部36は、この濃度値を下地濃度値として下地領域抽出部37へ出力し(ステップS44)、下地判定処理を終了する。ステップS42にて最大カウント値が第1閾値を超えない場合(S42:NO)、又はステップS43にて濃度値が第2閾値を超えない場合(S43:NO)、下地判定処理部36は、画像データに下地領域が含まれておらず、下地濃度値が存在しないと判定して(ステップS45)、下地判定処理を終了する。
FIG. 10 is a flowchart showing the procedure of the background determination process performed by the image forming apparatus according to the present invention, and is the process performed in step S3 of the flowchart of FIG. First, the background
図11及び図12は、本発明に係る画像形成装置が行う下地領域抽出処理の手順を示すフローチャートであり、図7のフローチャートのステップS5にて行われる処理である。まず、画像処理部20の下地領域抽出部37は、下地判定処理部36からの下地濃度値を取得し(ステップS61)、1画素分の画像データを取得して(ステップS62)、この画素の濃度が下地濃度であるか否かを下地濃度判定部51にて調べる(ステップS63)。取得した画素の濃度が下地濃度である場合(S63:YES)、連続性カウンタ52をカウントアップして(ステップS64)、ステップS68へ進む。
11 and 12 are flowcharts showing the procedure of the background area extraction process performed by the image forming apparatus according to the present invention, which is the process performed in step S5 of the flowchart of FIG. First, the background
取得した画素の濃度が下地濃度でない場合(S63:NO)、更に下地領域抽出部37は、連続性カウンタ52のカウント値が第3閾値を超えるか否かを下地領域判定部53にて調べる(ステップS65)。カウント値が第3閾値を超える場合(S65:YES)、下地領域抽出部37は、連続する画素が下地領域の画素である旨を示す下地領域情報を画像データに同期させて下地除去処理部26へ出力し(ステップS66)、連続性カウンタ52をリセットして(ステップS67)、ステップS68へ進む。また、連続性カウンタ52のカウント値が第3閾値を超えない場合には(S65:NO)、下地領域抽出部37は、下地領域情報を出力せずに、連続性カウンタ52をリセットして(ステップS67)、ステップS68へ進む。連続性カウンタ52のカウントアップ又はリセットを行った後、下地領域抽出部37は、画像データの所定ラインについて上述の処理が終了したか否かを調べ(ステップS68)、終了していない場合には(S68:NO)、ステップS62へ戻って上述の処理を繰り返し行う。
When the acquired pixel density is not the background density (S63: NO), the background
所定ラインについて処理が終了した場合(S68:YES)、更に下地領域抽出部37は、この所定ラインに下地の画素が含まれていたか否かを調べる(ステップS69)。所定ラインに下地の画素が含まれていた場合(S69:YES)、下地領域抽出部37は下地ラインカウンタ54をカウントアップし(ステップS70)、ステップS71へ進む。所定ラインに下地の画素が含まれていなかった場合(S69:NO)、下地ラインカウンタ54をカウントアップせずに、下地領域抽出部37はステップS71へ進む。次いで、下地領域抽出部37は、上述の処理を画像データの全画素について終了したか否かを調べ(ステップS71)、全画素について終了していない場合には(S71:NO)、ステップS62へ戻って上述の処理を繰り返し行う。
When the processing is completed for the predetermined line (S68: YES), the ground
画像データの全画素について処理が終了した場合(S71:YES)、更に下地領域抽出部37は、下地ラインカウンタ54によりカウントされた下地ラインの数が全ラインに対する所定割合を超えたか否かを調べる(ステップS72)。下地ラインの数が所定割合を超えた場合(S72:YES)、下地領域抽出部37は、画像データ中に下地領域が存在すると判定し(ステップS73)、処理を終了する。下地ラインの数が所定割合を超えない場合(S72:NO)、下地領域抽出部37は、画像データ中に下地領域が存在しないと判定し(ステップS74)、処理を終了する。
When the processing has been completed for all the pixels of the image data (S71: YES), the background
図13は、本発明に係る画像形成装置が行う下地除去処理の手順を示すフローチャートであり、図7のフローチャートのステップS7にて行われる処理である。画像処理装置20の下地除去処理部26は、まず、下地検出処理部25から出力される1画素分の画像データを取得すると共に(ステップS81)、下地検出結果として画像データに同期して出力される下地領域情報を取得する(ステップS82)。次いで、下地除去処理部26は、取得した下地領域情報を基に、取得した画像データの画素が下地の画素であるか否かを調べる(ステップS83)。取得した画素が下地の場合(S83:YES)、下地除去処理部26は下地の除去を行って(ステップS84)、ステップS85へ進む。なお、下地の除去は、例えば下地の画素の濃度値を255などの予め定められた濃度値に変換することで行うことができる。取得した画素が下地でない場合(S83:NO)、下地除去処理部26は下地の除去を行わずにステップS85へ進む。次いで、下地除去処理部26は、画像データの全ての画素について上述の処理が終了したか否かを調べ(ステップS85)、全ての画素について終了していない場合には(S85:NO)、ステップS81へ戻って上述の処理を繰り返し行い、全ての画素について終了した場合には(S85:YES)、下地除去処理を終了する。
FIG. 13 is a flowchart showing the procedure of the background removal process performed by the image forming apparatus according to the present invention, which is the process performed in step S7 of the flowchart of FIG. The background
図14は、画像入力装置11が画像処理部20に入力する画像データの一例を示す模式図である。図示の画像データは、文字、網点写真及び網点下地の領域を有しており、それ以外の領域が下地領域である。画像処理部20の下地検出処理部25は画像データの横方向の1ライン〜数ラインを所定領域として処理を行うが、図14にはこれらのうちの3つの所定領域121〜123を一点鎖線で囲む領域として図示してある。所定領域121には文字及び下地の画素が含まれており、所定領域122には文字、網点写真及び下地の画素が含まれており、所定領域123には文字、網点下地及び下地の画素が含まれている。
FIG. 14 is a schematic diagram illustrating an example of image data input to the
図15は、所定領域121〜123の画素の構成を説明するための模式図であり、(a)に所定領域121の構成を示し、(b)に所定領域122の構成を示し、(c)に所定領域123の構成を示してある。図15(a)〜(c)においては、上段には画像データの濃度値を画素の高低で示してあり、濃度値が低い(即ち暗い)画素を上側に示し、濃度値が高い(即ち明るい)画素を下側に示してある。また、下段には画像データのエッジ検出結果を示してあり、ハッチングを付した画素がエッジとして検出されたものである。なお、図15に示す画像データでは各所定領域が37個の画素で構成されているが、これは簡略化したものであり、実際には画像データはより多数の画素で構成される。
FIG. 15 is a schematic diagram for explaining the configuration of the pixels in the
また、図16は、計数部35の第1カウンタ41及び第2カウンタ42の一計数例を示す図表であり、図15(a)〜(c)における計数結果をそれぞれ図16(a)〜(c)に示してある。なお、図16においては、画像データ中の文字の濃度値は10とし、下地の濃度値は200とし、網点写真の同度値は100から199までの値が不均一に分散しているとし、網点の濃度値は150及び250の2つの値が均一に分散しているとする。
FIG. 16 is a chart showing a counting example of the first counter 41 and the
所定領域121には下地121a及び文字121bの2種の画素が含まれており、全37画素中の14画素がエッジである(図15(a)参照)。上述のように下地検出処理部25の計数部35では、エッジでない画素について濃度値毎に第1カウンタ41にて画素数を計数し、エッジの画素について第2カウンタ42にて画素数を計数するようにしてある。よって、第1カウンタ41は、下地121aのエッジ以外の部分と、文字121bのエッジ以外の部分(即ち、文字121bの内部)とについてのヒストグラムを作成する。第2カウンタ42は、下地121a及び文字121bのエッジ部分のヒストグラムを作成する。
The
所定領域121の計数結果(図16(a)参照)では、第1カウンタ41による濃度値10の画素数が10であり、濃度値200の画素数が17である。また、第2カウンタ42による濃度値10の画素数が6であり、濃度値200の画素数が8である。よって、最大のカウント値は第1カウンタ41の濃度値200のカウント値17であり、計数部35はこの濃度値200を下地濃度候補値とし、下地濃度カウンタ43の濃度値200のカウント値をカウントアップする。
In the counting result of the predetermined area 121 (see FIG. 16A), the number of pixels of the density value 10 by the first counter 41 is 10, and the number of pixels of the
所定領域122には下地122a、写真122b及び文字122cの3種の画素が含まれている(図15(b)参照)。所定領域122の計数結果(図16(b)参照)では、第1カウンタ41による濃度値10の画素数が1であり、濃度値100〜199に9画素が分散し、濃度値200の画素数が8である。また、第2カウンタ42による濃度値10の画素数が4であり、濃度値100〜199に7画素が分散し、濃度地200の画素数が8である。濃度値100〜199の画素は分散しているため、最大のカウント値は第1カウンタ41及び第2カウンタ42の濃度値200のカウント値8であり、計数部35はこの濃度値200を下地濃度候補値とし、下地濃度カウンタ43の濃度値200のカウント値をカウントアップする。
The
所定領域123には下地123a、網点下地123b及び文字123cの3種の画素が含まれている(図15(c)参照)。所定領域123の計数結果(図16(c)参照)では、第1カウンタ41による濃度値10の画素数が4であり、濃度値150の画素数が3であり(エッジでない網点領域の画素数は6であるが、網点領域では濃度値150の画素と濃度値250の画素とが均等に分散するため)、濃度値200の画素数が9であり、濃度値250の画素数が3である。また、第2カウンタ42による濃度値10の画素数が6であり、濃度値150の画素数が5であり、濃度値200の画素数が2であり、濃度値250の画素数が5である。よって、最大のカウント値は第1カウンタ41の濃度値200のカウント値9であり、計数部35はこの濃度値200を下地濃度候補値とし、下地濃度カウンタ43の濃度値200のカウント値をカウントアップする。
The
3つの所定領域121〜123についての第1カウンタ41及び第2カウンタ42による計数結果では、濃度値200のカウント値が最大であるため、下地濃度カウンタ43の濃度値200のカウント値には3が加算される。ただし、画像データ全体について計数を行った場合、必ずしも濃度値200のカウント値が最大となるわけではないため、この場合には下地濃度カウンタ43の対応するカウント値をカウントアップする。しかし、本発明に係る画像形成装置のように、画像データの1ライン〜数ラインを所定領域として部分的に濃度値毎の画素数を計数し、更にカウント値が最大となる濃度値の画素数を計数することによって、画像データの全体に亘って多く存在する濃度値が下地濃度カウンタ43に多数カウントされるため、下地濃度カウンタ43の最大カウント値に対応する濃度値が画像データの全体に存在する濃度値とすることができる。
In the count results of the first counter 41 and the
ただし、下地濃度カウンタ43により計数される所定領域の数の最大値が、画像データの全所定領域の数に対して一定以上の数に達していない場合には、この最大値に対応する濃度値が画像データの全体に分布していない虞があるため、本発明に係る画像形成装置では下地判定部36にて下地濃度カウンタ43による最大カウント値と閾値1との比較を行い、最大カウント値が閾値1を超えない場合には画像データに下地領域が含まれないと判定するようにしてある。また、最大カウント値に対応する濃度値が小さい、即ち濃度が濃い場合には、この濃度値は下地の濃度ではない虞があるため、本発明に係る画像形成装置では下地判定部36にて下地濃度カウンタ43の最大カウント値に対応する濃度値と閾値2との比較を行い、濃度値が画像データに下地領域が含まれないと判定するようにしてある。また、閾値1及び閾値2との比較処理を行って下地濃度値を決定した下地判定部36は、この下地濃度値の前後の濃度値についても下地濃度カウンタ43のカウンタ値を基に下地濃度と判定し、複数の下地濃度値を出力する構成とすることもできる。
However, if the maximum value of the number of predetermined areas counted by the
第1カウンタ41、第2カウンタ42及び下地濃度カウンタ43を用いて下地濃度を取得した後、下地領域抽出部37は入力された画像データから下地領域を抽出する。下地領域抽出部37には画像データが1画素毎に与えられており、下地領域抽出部37は与えられた画素の濃度値が下地濃度値であるか否かを判定する。与えられた画素の濃度値が下地濃度値である場合、下地領域抽出部37は連続性カウンタ52に1を加算し、初めて連続性カウンタ52に1を加算するとき(即ち、連続性カウンタ52の値が0から1に変化したとき)にはこの画素の位置情報を保持しておく。与えられた画素の濃度値が下地濃度値でない場合、同じ所定領域中のこの画素以前の画素までの連続性を連続性カウンタ52のカウント値を基に下地領域抽出部37が判定する。連続性カウンタ52のカウント値が閾値3を超えない場合、これらの画素は下地領域のものではないと下地領域抽出部37は判定する。連続性カウンタ52のカウント値が閾値3を超える場合、下地領域抽出部37はこれらの画素を下地領域のものであると判定し、この画素の位置の1つ前までの画素に同期して、下地領域である旨を示す信号を下地検出結果として下地除去処理部26へ出力する。なお、閾値3は、例えば画像データの1ラインの画素数が7000であるとき、閾値3=700として、10%以上の割合の画素が連続した場合に連続性があると判定することができる。なお、この割合についても実験的又は経験的に予め決定すればよいが、画像データのサイズ又は倍率等に応じたものである。また、下地検出処理部25と下地除去処理部26との同期をとるために、下地検出処理部25から出力する画像データは1ライン分のラインバッファに保持されており、1ラインの全画素の処理が終了するまで下地領域抽出部37は連続性の判定を繰り返し行い、1ラインの処理が終了した場合に連続性カウンタ52の値をリセットする。
After obtaining the background density using the first counter 41, the
これらの処理によって、画像入力装置11から入力された画像データに対する下地領域の検出処理が終了する。図17は、下地領域の検出結果の一例を示す模式図であり、図14に示した画像データについて上述の処理を行った処理結果を示してある。図17にハッチングを付して示した領域が検出された下地領域である。なお、画像データの文字領域は、実際には1文字毎に文字形状に従って分離されるが、図17においては簡略化のために文字列毎に分離したように図示してある。よって、この文字列の部分に含まれる文字以外の画素についても実際には下地検出処理部25が下地領域として出力する。
With these processes, the background area detection process for the image data input from the image input device 11 is completed. FIG. 17 is a schematic diagram showing an example of the detection result of the background region, and shows the processing result obtained by performing the above-described processing on the image data shown in FIG. The areas indicated by hatching in FIG. 17 are the detected base areas. Note that the character area of the image data is actually separated according to the character shape for each character, but in FIG. 17, it is illustrated as separated for each character string for simplification. Therefore, the background
下地検出処理部25にて下地領域が検出された後、この検出結果を基に下地除去処理部26が画像データから下地の除去処理を行う。下地除去処理部26には画像データに同期して下地検出結果が与えられており、処理対象の画素が下地領域の画素である場合、下地除去処理部26はこの画素の濃度値を白色に変換する。下地領域の画素でない場合には、下地除去処理部26は与えられた画素をそのまま出力する。下地除去処理部26は、この処理を画像データの全画素について行う。
After the background area is detected by the background
ただし、例えば下地検出処理部25が、検出した下地濃度値を基に、この下地濃度値が白く変換されるようなガンマカーブを生成して下地検出結果として下地除去処理部26へ与え、下地除去処理部26がこのガンマカーブを基に画像データの変換を行う構成としてもよい。
However, for example, the background
以上の構成の画像形成装置においては、画像データの1ライン又は複数ラインによる所定領域毎に複数のカウンタ(第1カウンタ41及び第2カウンタ42)を用いて下地濃度候補値を抽出し、複数の下地濃度候補値から下地濃度カウンタ43を用いて代表下地濃度候補値を抽出し、このときのカウント値及び代表下地濃度候補値を閾値1及び閾値2と下地判定部36にて比較して下地濃度を取得する構成とすることにより、画像データの全体に亘って広く分布する濃度を下地濃度値として取得することができるため、画像形成装置が精度よく下地を除去した高品質の画像を形成することができる。また、下地濃度値を有する画素が所定数以上連続している場合にのみ、これらの連続した画素を下地領域と判定する構成とすることにより、画像形成装置はより精度よく画像データから下地領域を検出することができる。
In the image forming apparatus having the above configuration, the background density candidate values are extracted using a plurality of counters (first counter 41 and second counter 42) for each predetermined region of one line or a plurality of lines of image data. A representative background density candidate value is extracted from the background density candidate value using the
なお、本実施の形態においては、メモリカード100からプログラムコード101(実行形式プログラム、中間コードプログラム又はソースプログラム等)をCPU1が読み出して実行することにより画像形成装置が上述の下地検出処理を行う構成としたが、これに限るものではなく、ROM2に予めプログラムコード101を記憶しておく構成としてもよい。また、プログラムコード101を汎用のコンピュータなどにて実行することにより、コンピュータ上にて上述の下地検出処理を行う構成としてもよい。また、プログラムコード101をメモリカード100が保持するのではなく、コンピュータに備えられたROM、RAM又はハードディスク等に保持する構成とすることもできる。更には、画像形成装置若しくはコンピュータ等に着脱可能な記録媒体として、磁気テープ若しくはカセットテープ等のテープ媒体、フレキシブルディスク若しくはハードディスク等の磁気ディスク媒体、CD−ROM、MO、MD若しくはDVD等のディスク媒体、ICカード若しくは光カード等のカード媒体、又はマスクROM、EPROM、EEPROM若しくはフラッシュメモリ等の半導体メモリ等にプログラムコード101を保持する構成としてもよい。これにより、下地検出処理及び下地除去処理を行うプログラムコード101を記録媒体によって持ち運び自由に提供することができる。
In the present embodiment, the
また、これらの記録媒体に保持されたプログラムコード101は、画像形成装置又はコンピュータ等が直接的に読み出して実行する構成であってもよく、画像形成装置又はコンピュータ等に備えられたハードディスクなどに予めインストールされて、画像形成装置又はコンピュータ等がインストールされたプログラムコード101を読み出して実行する構成であってもよい。 Further, the program code 101 held in these recording media may be directly read and executed by the image forming apparatus or the computer, or may be stored in advance on a hard disk provided in the image forming apparatus or the computer. The program code 101 which is installed and the image forming apparatus or the computer is installed may be read and executed.
また、インターネット及びLAN等のネットワークに接続機能を画像形成装置又はコンピュータ等に搭載し、ネットワークを介してプログラムコード101をダウンロードする構成としてもよい。この場合、ダウンロードの処理を行うプログラムは画像形成装置又はコンピュータ等に予め記憶しておくか、又は種々の記録媒体に保持されたプログラムをインストールして実行する構成としてもよい。なお、本発明は、プログラムコード101が電子的な伝送で具現化された搬送波に埋め込まれたコンピュータデータ信号の形態でも実現され得る。また、プログラムコード101は、上述の下地検出処理及び下地除去処理のみを実行するためのものでなく、画像形成装置のその他の処理を含めて統括的に実行するように構成されたものであってよい。 In addition, a connection function may be installed in an image forming apparatus, a computer, or the like on a network such as the Internet and a LAN, and the program code 101 may be downloaded via the network. In this case, a program for performing the download process may be stored in advance in an image forming apparatus or a computer, or may be configured to install and execute a program held in various recording media. Note that the present invention can also be realized in the form of a computer data signal in which the program code 101 is embedded in a carrier wave embodied by electronic transmission. Further, the program code 101 is configured not to execute only the above-described background detection processing and background removal processing, but to be executed comprehensively including other processing of the image forming apparatus. Good.
また、画像入力装置11としては、例えばフラットヘッドスキャナ、フィルムスキャナ又はデジタルカメラ等の機器を用いることができる。画像出力装置12としては、例えばCRTディスプレイ若しくは液晶ディスプレイ等の画像表示装置、又は処理結果を紙などの記録用紙に出力する電子写真方式若しくはインクジェット方式等のプリンタ等を用いることができる。また、画像形成装置は、ネットワークを介してサーバ装置などに接続するための通信手段としてモデムなどを備える構成としてもよい。
Further, as the image input device 11, for example, a device such as a flat head scanner, a film scanner, or a digital camera can be used. As the
また、本実施形態においては、画像形成装置がRGBの画像データに対して下地検出処理を行う構成としたが、これに限るものではなく、検出精度及び画像処理構成等に応じて、CMYK又はCIELAB等の他の色空間の画像データに対して下地検出処理を行う構成としてもよい。この場合、濃度値と色情報とが混在するCMYKなどの色空間では、RGBの場合と同様の処理で下地検出処理を行えばよい。輝度と色度とが分離されたCIELABなどの色空間では、輝度を中心として処理を行い、補助的な情報として色度情報を用いる構成としてもよい。 In this embodiment, the image forming apparatus is configured to perform background detection processing on RGB image data. However, the present invention is not limited to this, and may be CMYK or CIELAB depending on detection accuracy, image processing configuration, and the like. For example, the background detection processing may be performed on image data in another color space. In this case, in a color space such as CMYK in which density values and color information are mixed, background detection processing may be performed by the same processing as in the case of RGB. In a color space such as CIELAB in which luminance and chromaticity are separated, processing may be performed with luminance as the center, and chromaticity information may be used as auxiliary information.
(変形例1)
上述の実施形態においては、計数部35が第1カウンタ41及び第2カウンタ42の2つのカウンタを有し、画像データのエッジ成分と非エッジ成分とで計数に用いるカウンタを切り替える構成としたが、これに限るものではなく、3つ以上のより多くのカウンタを用いて計数を行う構成とすることもできる。変形例1においては、画像形成装置の計数部が第1カウンタ〜第3カウンタの3つのカウンタを有する場合について説明する。
(Modification 1)
In the above-described embodiment, the
変形例1に係る画像形成装置は、画像データのエッジ検出を行って、画像データのエッジ成分の立ち上がり及び立ち下がりに応じて3つのカウンタの切り替えを行う。変形例1に係る画像形成装置の計数部は画像データの1画素毎に順に計数を行うようにしてあるが、例えば計数部はまず第1カウンタを用いて計数を始め、画像データのエッジ成分の立ち上がり毎に第1カウンタから第2カウンタへ、第2カウンタから第3カウンタへカウンタの切り替えを行うと共に、画像データのエッジ成分の立ち下がり毎に第3カウンタから第2カウンタへ、第2カウンタから第1カウンタへカウンタの切り替えを行うようにしてある。
The image forming apparatus according to the first modification detects the edge of the image data, and switches the three counters according to the rise and fall of the edge component of the image data. The counting unit of the image forming apparatus according to
図18は、本発明の変形例1に係る画像形成装置のカウンタの切り替え例を説明するための模式図である。図示の例は、画像データが下地、網点下地、文字及び網点上文字(網点下地上の文字)を有する場合である。画像形成装置の計数部は、まず第1カウンタにて下地の画素の計数を開始し、下地及び網点下地のエッジの立ち上がりにて第1カウンタから第2カウンタへカウンタを切り替えて計数を行う。更に網点下地及び網点上文字のエッジの立ち上がりにて、計数部は第2カウンタから第3カウンタへカウンタを切り替えて計数を行う。その後、計数部は、網点上文字及び網点下地のエッジの立ち下りにて、第3カウンタから第2カウンタへカウンタを切り替えて計数を行い、網点下地及び下地のエッジの立ち下りにて第2カウンタから第1カウンタへカウンタを切り替えて計数を行う。同様に、計数部は、下地及び文字のエッジの立ち上がりにて、第1カウンタから第2カウンタへカウンタを切り替えて計数を行い、文字および下地のエッジの立ち下がりにて、第2カウンタから第1カウンタへカウンタを切り替えて計数を行う。 FIG. 18 is a schematic diagram for explaining a counter switching example of the image forming apparatus according to the first modification of the present invention. The example shown in the figure is a case where the image data has a background, a halftone dot background, a character, and a character on a halftone dot (a character on a halftone dot background). The counting unit of the image forming apparatus first starts counting the background pixels by the first counter, and switches the counter from the first counter to the second counter at the rising edge of the background and the halftone background and performs the counting. Further, at the rising edge of the halftone dot base and the character on the halftone dot, the counting unit switches the counter from the second counter to the third counter and performs counting. Thereafter, the counting unit performs counting by switching the counter from the third counter to the second counter at the falling edge of the halftone dot character and the halftone dot edge, and at the falling edge of the halftone dot edge and the background edge. Counting is performed by switching the counter from the second counter to the first counter. Similarly, the counting unit performs counting by switching the counter from the first counter to the second counter at the rising edge of the background and the character edge, and performs counting from the second counter at the falling edge of the character and the background edge. The counter is switched to the counter and counts.
以上のように、エッジの立ち上がり及び立ち下がりにてカウンタの切り替えを行うことによって、第1カウンタは下地の画素について計数を行い、第2カウンタは網点下地及び文字の画素について計数を行い、第3カウンタは網点上文字について計数を行うことができるため、3つのカウンタにて各領域を分離したヒストグラムを作成することができる。よって、画像データの全体に万遍なく存在する濃度を下地濃度としてより精度よく検出することができる。なお、3つのカウンタによる計数を1つの所定領域について終了した場合、計数部は3つのカウンタからカウント値が最大の濃度値(下地濃度候補値)を抽出し、下地濃度カウンタ43のこの濃度値に対応するカウント値に1を加算する。その後の処理については、上述の処理と同様であるため説明を省略する。
As described above, by switching the counter at the rising edge and the falling edge, the first counter counts the background pixel, the second counter counts the halftone dot background and the character pixel, Since the three counters can count the characters on the halftone dots, it is possible to create a histogram in which each region is separated by the three counters. Therefore, it is possible to more accurately detect the density that exists uniformly in the entire image data as the background density. When the counting by the three counters is completed for one predetermined area, the counting unit extracts the density value (background density candidate value) having the maximum count value from the three counters, and uses this density value of the
(変形例2)
上述の実施形態においては、計数部35が第1カウンタ41及び第2カウンタ42の2つのカウンタを有し、画像データのエッジ成分と非エッジ成分とで計数に用いるカウンタを切り替える構成としたが、これに限るものではなく、非エッジ成分のみについて計数を行う構成とすることもできる。
(Modification 2)
In the above-described embodiment, the
図19は、本発明の変形例2に係る画像処理装置の計数部135の構成を示すブロック図である。図3に示す計数部35は第1カウンタ41及び第2カウンタ42の2つのカウンタを有する構成であるが、変形例2に係る画像形成装置の計数部135は第1カウンタ41のみを有し、第2カウンタ42を有さない構成である。第1カウンタ41には領域分離処理部24の領域分離結果に含まれるエッジ検出結果が与えられており、エッジの検出結果からエッジでない画素の計数を行ってヒストグラムを作成するようにしてある。
FIG. 19 is a block diagram illustrating a configuration of the
計数部35は、第1カウンタ41による計数を画像データの所定ライン毎に行い、所定ラインの画素について計数を終了した場合、第1カウンタ41の計数結果から最大のカウント値を有する濃度値を抽出する。これにより、入力された画像データの所定ラインにおける下地濃度候補値が得られる。計数部35は、抽出した下地濃度候補値に応じた下地濃度カウンタ43のカウント値に1を加算する。
The
以上の変形例2の構成の場合であっても、下地領域の検出精度が多少低下する可能性があるが、下地領域の検出を行うことができる。即ち、エッジ成分及び非エッジ成分の両方の画素を考慮して下地領域の検出を行う場合と比較して、非エッジ成分のみから下地領域の検出を行う場合は、例えばエッジに挟まれる文字領域の画素の濃度値に対して、この濃度値が文字の濃度値であると判断する情報がないため、文字が多い画像データでは文字の濃度値が下地候補濃度値として誤判定される領域が出る可能性があり、下地領域の検出精度が低下する可能性がある。しかし、変形例2の構成であっても下地領域の検出を行うことは可能であり、計数部135の構成を簡略化してハードウェア資源を節約することができるという利点がある。
Even in the case of the configuration of
1 CPU
2 ROM
3 RAM
6 メモリ装着部
11 画像入力装置(入力手段)
12 画像出力装置(出力手段)
20 画像処理装置
21 A/D変換部
22 シェーディング補正部
23 入力階調補正部
24 領域分離処理部(エッジ検出手段)
25 下地検出処理部(下地濃度候補抽出手段、代表下地濃度候補値抽出手段)
26 下地除去処理部
27 空間フィルタ処理部
28 変倍処理部
29 色補正部
30 黒生成下色除去部
31 出力階調補正部
32 階調再現処理部
35 計数部
36 下地判定部
37 下地領域抽出部(下地領域判定手段)
41 第1カウンタ(計数手段)
42 第2カウンタ(計数手段)
43 下地濃度カウンタ
45 最大カウント値判定部(画素数判定手段)
46 濃度値判定部(濃度値判定手段)
51 下地濃度判定部
52 連続性カウンタ
53 下地領域判定部
100 メモリカード(記録媒体)
101 プログラムコード(コンピュータプログラム)
121〜123 所定領域
1 CPU
2 ROM
3 RAM
6 Memory mounting part 11 Image input device (input means)
12 Image output device (output means)
DESCRIPTION OF
25 Background detection processing unit (background density candidate extraction means, representative background density candidate value extraction means)
26 Background
41 First counter (counting means)
42 Second counter (counting means)
43
46 Density value determination unit (density value determination means)
51 Background
101 Program code (computer program)
121-123 predetermined area
Claims (13)
入力された画像データからエッジを検出し、
前記画像データ中の複数の所定領域毎に、検出したエッジに含まれる画素について、濃度値毎に画素数を計数し、
前記所定領域毎に、前記エッジに含まれない画素について、濃度値毎に画素数を計数し、
前記所定領域毎に、両計数結果を基に下地濃度候補値を抽出し、
前記所定領域毎に算出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出し、
前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定し、
前記代表下地濃度候補値が所定濃度値を超えるか否かを判定し、
両判定結果を基に、前記画像データに下地領域が含まれているか否かを判定すること
を特徴とする下地領域検出方法。 In a background area detection method for detecting a background area included in input image data,
Detect edges from input image data,
For each of a plurality of predetermined areas in the image data, for the pixels included in the detected edge, count the number of pixels for each density value,
For each pixel that is not included in the edge for each predetermined area, count the number of pixels for each density value,
For each predetermined area, extract a background density candidate value based on both count results,
From the plurality of background density candidate values calculated for each predetermined region, a representative background density candidate value is extracted based on the number of pixels of each background density candidate value,
Determining whether the number of pixels of the representative background density candidate value exceeds a predetermined number;
Determining whether the representative background density candidate value exceeds a predetermined density value;
A background area detection method, comprising: determining whether a background area is included in the image data based on both determination results.
入力された画像データからエッジを検出し、
前記画像データ中の複数の所定領域毎に、検出したエッジに含まれない画素について、濃度値毎に画素数を計数し、
前記所定領域毎に、計数結果を基に下地濃度候補値を抽出し、
前記所定領域毎に算出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出し、
前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定し、
前記代表下地濃度候補値が所定濃度値を超えるか否かを判定し、
両判定結果を基に、前記画像データに下地領域が含まれているか否かを判定すること
を特徴とする下地領域検出方法。 In a background area detection method for detecting a background area included in input image data,
Detect edges from input image data,
For each of a plurality of predetermined regions in the image data, for pixels not included in the detected edge, count the number of pixels for each density value,
For each predetermined area, extract the background density candidate value based on the counting result,
From the plurality of background density candidate values calculated for each predetermined region, a representative background density candidate value is extracted based on the number of pixels of each background density candidate value,
Determining whether the number of pixels of the representative background density candidate value exceeds a predetermined number;
Determining whether the representative background density candidate value exceeds a predetermined density value;
A background area detection method, comprising: determining whether a background area is included in the image data based on both determination results.
濃度値毎の画素数を計数する計数手段を複数用い、
入力された画像データからエッジを検出し、
前記画像データ中の複数の所定領域毎に、エッジの検出結果に応じて前記計数手段を切り替えて、濃度値毎に画素数を計数し、
前記所定領域毎に、各計数手段の計数結果を基に下地濃度候補値を抽出し、
前記所定領域毎に算出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出し、
前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定し、
前記代表下地濃度候補値が所定濃度値を超えるか否かを判定し、
両判定結果を基に、前記画像データに下地領域が含まれているか否かを判定すること
を特徴とする下地領域検出方法。 In a background area detection method for detecting a background area included in input image data,
Using a plurality of counting means for counting the number of pixels for each density value,
Detect edges from input image data,
For each of a plurality of predetermined regions in the image data, the counting unit is switched according to the edge detection result, and the number of pixels is counted for each density value.
For each predetermined area, extract the background density candidate value based on the counting result of each counting means,
From the plurality of background density candidate values calculated for each predetermined region, a representative background density candidate value is extracted based on the number of pixels of each background density candidate value,
Determining whether the number of pixels of the representative background density candidate value exceeds a predetermined number;
Determining whether the representative background density candidate value exceeds a predetermined density value;
A background area detection method, comprising: determining whether a background area is included in the image data based on both determination results.
前記代表下地濃度候補値の抽出は、前記所定領域毎に抽出した複数の下地濃度候補値から、画素数が最多の下地濃度候補値を抽出することで行うこと
を特徴とする請求項1から請求項3までのいずれか1つに記載の下地領域検出方法。 The extraction of the background density candidate value is performed by extracting the density value corresponding to the largest number of pixels from the counting result,
2. The representative background density candidate value is extracted by extracting a background density candidate value having the largest number of pixels from a plurality of background density candidate values extracted for each of the predetermined areas. Item 4. The background region detection method according to any one of Items 1 to 3.
前記所定領域は、前記画像データの縦又は横の一又は複数の列で構成される領域であること
を特徴とする請求項1から請求項4までのいずれか一項に記載の下地領域検出方法。 When the image data is composed of a plurality of pixels arranged side by side vertically and horizontally,
The ground region detection method according to any one of claims 1 to 4, wherein the predetermined region is a region formed of one or a plurality of columns of the image data in the vertical or horizontal direction. .
所定数以上の前記画素が連続している場合に、前記画像データに下地領域が含まれていると判定すること
を特徴とする請求項1から請求項5までのいずれか一項に記載の下地領域検出方法。 Determining continuity in the image data for a plurality of pixels having the representative background density candidate value;
6. The background according to claim 1, wherein when the predetermined number or more of the pixels are continuous, it is determined that the background area is included in the image data. Region detection method.
を特徴とする請求項1から請求項6までのいずれか一項に記載の下地領域検出方法。 The ground area detection method according to claim 1, wherein a ground area included in the image data is removed.
入力された画像データからエッジを検出するエッジ検出手段と、
前記画像データ中の複数の所定領域毎に、検出したエッジに含まれる画素について、濃度値毎に画素数を計数する計数手段と、
前記所定領域毎に、前記エッジに含まれない画素について、濃度値毎に画素数を計数する計数手段と、
前記所定領域毎に、両計数手段の計数結果を基に下地濃度候補値を抽出する下地濃度候補値抽出手段と、
前記所定領域毎に抽出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出する代表下地濃度候補値抽出手段と、
前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定する画素数判定手段と、
前記代表下地濃度候補値が所定濃度値を超えるか否かを判定する濃度値判定手段と、
前記画素数判定手段及び前記濃度値判定手段の判定結果を基に、前記画像データに下地領域が含まれているか否かを判定する下地判定手段と
を備えることを特徴とする画像処理装置。 In an image processing apparatus for detecting a background area included in input image data,
Edge detection means for detecting edges from input image data;
Counting means for counting the number of pixels for each density value for the pixels included in the detected edge for each of a plurality of predetermined regions in the image data;
Counting means for counting the number of pixels for each density value for pixels not included in the edge for each predetermined area;
A background density candidate value extracting means for extracting a background density candidate value based on the counting results of both counting means for each predetermined area;
Representative background density candidate value extraction means for extracting a representative background density candidate value based on the number of pixels of each background density candidate value from a plurality of background density candidate values extracted for each predetermined region;
A pixel number determination means for determining whether or not the number of pixels of the representative background density candidate value exceeds a predetermined number;
Density value determining means for determining whether the representative background density candidate value exceeds a predetermined density value;
An image processing apparatus comprising: a background determination unit that determines whether or not a background region is included in the image data based on determination results of the pixel number determination unit and the density value determination unit.
入力された画像データからエッジを検出するエッジ検出手段と、
前記画像データ中の複数の所定領域毎に、検出したエッジに含まれない画素について、濃度値毎に画素数を計数する計数手段と、
前記所定領域毎に、前記計数手段の計数結果を基に下地濃度候補値を抽出する下地濃度候補値抽出手段と、
前記所定領域毎に抽出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出する代表下地濃度候補値抽出手段と、
前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定する画素数判定手段と、
前記代表下地濃度候補値が所定濃度値を超えるか否かを判定する濃度値判定手段と、
前記画素数判定手段及び前記濃度値判定手段の判定結果を基に、前記画像データに下地領域が含まれているか否かを判定する下地判定手段と
を備えることを特徴とする画像処理装置。 In an image processing apparatus for detecting a background area included in input image data,
Edge detection means for detecting edges from input image data;
Counting means for counting the number of pixels for each density value for pixels not included in the detected edge for each of a plurality of predetermined regions in the image data;
A background density candidate value extracting means for extracting a background density candidate value based on a counting result of the counting means for each predetermined area;
Representative background density candidate value extraction means for extracting a representative background density candidate value based on the number of pixels of each background density candidate value from a plurality of background density candidate values extracted for each predetermined region;
A pixel number determination means for determining whether or not the number of pixels of the representative background density candidate value exceeds a predetermined number;
Density value determining means for determining whether the representative background density candidate value exceeds a predetermined density value;
An image processing apparatus comprising: a background determination unit that determines whether or not a background region is included in the image data based on determination results of the pixel number determination unit and the density value determination unit.
画像データを前記画像処理装置へ入力する入力手段と、
前記画像処理装置にて画像処理された画像データに係る画像を出力する出力手段と
を備えることを特徴とする画像形成装置。 The image processing apparatus according to claim 8 or 9,
Input means for inputting image data to the image processing device;
An image forming apparatus comprising: an output unit configured to output an image related to image data image-processed by the image processing apparatus.
コンピュータに、
前記画像データからエッジを検出させ、
前記画像データ中の複数の所定領域毎に、検出したエッジに含まれる画素について、濃度値毎に画素数を計数させ、
前記所定領域毎に、前記エッジに含まれない画素について、濃度値毎に画素数を計数させ、
前記所定領域毎に、両計数結果を基に下地濃度候補値を抽出させ、
前記所定領域毎に抽出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出させ、
前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定させ、
前記代表下地濃度候補値が所定濃度値を超えるか否かを判定させ、
両判定結果を基に、前記画像データに下地領域が含まれているか否かを判定させること
を特徴とするコンピュータプログラム。 In a computer program for causing a computer to detect a background area included in image data,
On the computer,
Detecting edges from the image data;
For each of a plurality of predetermined areas in the image data, for the pixels included in the detected edge, the number of pixels is counted for each density value,
For each pixel that is not included in the edge for each predetermined area, the number of pixels is counted for each density value,
For each predetermined area, based on both counting results, extract a background density candidate value,
From the plurality of background density candidate values extracted for each predetermined area, the representative background density candidate value is extracted based on the number of pixels of each background density candidate value,
Determining whether the number of pixels of the representative background density candidate value exceeds a predetermined number;
Determining whether the representative background density candidate value exceeds a predetermined density value;
A computer program for determining whether or not a background area is included in the image data based on both determination results.
コンピュータに、
前記画像データからエッジを検出させ、
前記画像データ中の複数の所定領域毎に、検出したエッジに含まれない画素について、濃度値毎に画素数を計数させ、
前記所定領域毎に、計数結果を基に下地濃度候補値を抽出させ、
前記所定領域毎に抽出した複数の下地濃度候補値から、各下地濃度候補値の画素数を基に代表下地濃度候補値を抽出させ、
前記代表下地濃度候補値の画素数が所定数を超えるか否かを判定させ、
前記代表下地濃度候補値が所定濃度値を超えるか否かを判定させ、
両判定結果を基に、前記画像データに下地領域が含まれているか否かを判定させること
を特徴とするコンピュータプログラム。 In a computer program for causing a computer to detect a background area included in image data,
On the computer,
Detecting edges from the image data;
For each of a plurality of predetermined regions in the image data, for pixels not included in the detected edge, the number of pixels is counted for each density value,
For each predetermined area, based on the counting result, extract a background density candidate value,
From the plurality of background density candidate values extracted for each predetermined area, the representative background density candidate value is extracted based on the number of pixels of each background density candidate value,
Determining whether the number of pixels of the representative background density candidate value exceeds a predetermined number;
Determining whether the representative background density candidate value exceeds a predetermined density value;
A computer program for determining whether or not a background area is included in the image data based on both determination results.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007230559A JP2009065378A (en) | 2007-09-05 | 2007-09-05 | Base region detecting method, image processor, image forming apparatus, computer program, and recording medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007230559A JP2009065378A (en) | 2007-09-05 | 2007-09-05 | Base region detecting method, image processor, image forming apparatus, computer program, and recording medium |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2009065378A true JP2009065378A (en) | 2009-03-26 |
Family
ID=40559569
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2007230559A Pending JP2009065378A (en) | 2007-09-05 | 2007-09-05 | Base region detecting method, image processor, image forming apparatus, computer program, and recording medium |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2009065378A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2013074474A (en) * | 2011-09-28 | 2013-04-22 | Brother Ind Ltd | Image reading apparatus and ground color compensation program |
-
2007
- 2007-09-05 JP JP2007230559A patent/JP2009065378A/en active Pending
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2013074474A (en) * | 2011-09-28 | 2013-04-22 | Brother Ind Ltd | Image reading apparatus and ground color compensation program |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4495197B2 (en) | Image processing apparatus, image forming apparatus, image processing program, and recording medium for recording image processing program | |
JP4496239B2 (en) | Image processing method, image processing apparatus, image forming apparatus, image reading apparatus, computer program, and recording medium | |
JP5157774B2 (en) | Image forming apparatus, image forming method, and program | |
JP4166744B2 (en) | Image processing apparatus, image forming apparatus, image processing method, computer program, and recording medium | |
JP4170353B2 (en) | Image processing method, image processing apparatus, image reading apparatus, image forming apparatus, program, and recording medium | |
JP4402090B2 (en) | Image forming apparatus, image forming method, program, and recording medium | |
JP2008205652A (en) | Image processing method, image processing apparatus, image forming apparatus, program, and recording medium | |
JP2003051946A (en) | Image processing method, image processing apparatus, imaging device provided with the image processing apparatus, image processing program, and computer- readable recording medium with the program recorded | |
JP2007043394A (en) | Apparatus and method for image processing, and program making computer implement same method | |
JP2003338930A (en) | Image processing method, image processing apparatus, and image forming apparatus | |
JP6474315B2 (en) | Image processing apparatus, image forming apparatus, image processing method, image processing program, and recording medium therefor | |
JP2006304015A (en) | Image processing apparatus, image forming apparatus, method of processing image, computer program and recording medium | |
JP4549227B2 (en) | Image processing apparatus, image forming apparatus, image processing method, computer program, and recording medium | |
JP2006155572A (en) | Image processor, image forming device, image processing method and computer program | |
JP2009065378A (en) | Base region detecting method, image processor, image forming apparatus, computer program, and recording medium | |
JP2008306400A (en) | Image processing method, image processing device, image forming apparatus, computer program, and record medium | |
JP4740913B2 (en) | Image processing apparatus, image processing method, image forming apparatus and program, and recording medium | |
JP4545167B2 (en) | Image processing method, image processing apparatus, image forming apparatus, computer program, and recording medium | |
JP2006229817A (en) | Background detection method, program, recording medium, image processing apparatus, and image forming apparatus | |
JP4958626B2 (en) | Image processing method, image processing apparatus, image forming apparatus, computer program, and recording medium | |
JP2005191890A (en) | Image processing device, image processing method, image processing program, recording medium stored with image processing program and image forming apparatus with image processor | |
JP4808282B2 (en) | Image processing apparatus, image forming apparatus, image processing method, image processing program, and recording medium for recording image processing program | |
JP2009194739A (en) | Image conversion method, image processing apparatus, image forming apparatus, computer program and recording medium | |
JP4257708B2 (en) | Shadow area determination method, image processing method, shadow area determination apparatus, image processing apparatus, image forming apparatus, image reading apparatus, computer program, and recording medium | |
JP5122507B2 (en) | Image processing apparatus, image forming apparatus, image processing method, program, and recording medium |