JP6512005B2 - Image reader - Google Patents

Image reader Download PDF

Info

Publication number
JP6512005B2
JP6512005B2 JP2015140222A JP2015140222A JP6512005B2 JP 6512005 B2 JP6512005 B2 JP 6512005B2 JP 2015140222 A JP2015140222 A JP 2015140222A JP 2015140222 A JP2015140222 A JP 2015140222A JP 6512005 B2 JP6512005 B2 JP 6512005B2
Authority
JP
Japan
Prior art keywords
data
gray
black
white
line
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.)
Active
Application number
JP2015140222A
Other languages
Japanese (ja)
Other versions
JP2016096532A (en
Inventor
加藤 哲也
哲也 加藤
大樹 山野
大樹 山野
崇史 松海
崇史 松海
修一 砂子
修一 砂子
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Brother Industries Ltd
Original Assignee
Brother Industries Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Brother Industries Ltd filed Critical Brother Industries Ltd
Priority to US14/932,149 priority Critical patent/US9432552B2/en
Publication of JP2016096532A publication Critical patent/JP2016096532A/en
Application granted granted Critical
Publication of JP6512005B2 publication Critical patent/JP6512005B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Image Input (AREA)
  • Facsimile Scanning Arrangements (AREA)
  • Facsimile Image Signal Circuits (AREA)

Description

本発明は、画像読取装置に関する。   The present invention relates to an image reading apparatus.

一般に、画像読取装置において、シェーディング補正のための配光基準部材として白色基準部材が使用され、白色基準部材を通過する原稿の画像が読み取られる。しかし、白色基準部材を使用した場合には、原稿の裏面の濃度変化が表面に影響する裏写り現象が発生することがある。この裏写り現象を低減するために、白色基準部材より反射率の低い灰色基準部材を使用してシェーディング補正を行う画像読取装置が種々提案されている。   Generally, in an image reading apparatus, a white reference member is used as a light distribution reference member for shading correction, and an image of a document passing through the white reference member is read. However, when a white reference member is used, an off-set phenomenon may occur in which changes in density on the back side of the document affect the front side. In order to reduce the show-through phenomenon, various image reading apparatuses have been proposed which perform shading correction using a gray reference member having a reflectance lower than that of a white reference member.

たとえば、特許文献1には、非白色の基準部材が原稿給送装置の原稿ガイドに設けられた画像読取装置が開示されている。特許文献1に記載の画像読取装置では、非白色の基準部材を読み取って得られた反射濃度が、白色基準部材を読み取って得られる白色の反射濃度と同等の値になるように、非白色の基準部材の反射率を基に補正される。原稿給送装置により給送される原稿の画像を読み取るときには、補正された反射濃度を使用してシェーディング補正が実行される。   For example, Patent Document 1 discloses an image reading apparatus in which a non-white reference member is provided in a document guide of a document feeding apparatus. In the image reading device described in Patent Document 1, the non-white color is obtained so that the reflection density obtained by reading the non-white reference member has a value equivalent to the white reflection density obtained by reading the white reference member. Correction is performed based on the reflectance of the reference member. When reading an image of a document fed by the document feeding apparatus, shading correction is performed using the corrected reflection density.

特開2000−125094号公報JP 2000-125094 A

特許文献1に記載の画像読取装置では、白色の反射濃度と同等の値になるように、ROM
に保存されている非白色の基準部材の反射率を基に反射濃度の補正が実行される。即ち、白色の反射率である100%に対する非白色の基準部材の反射率を反射濃度に掛けることで、反射濃度が補正される。よって、白色の反射率100%に対する非白色の基準部材の反射率[%]というROMに予め保存されている固定値により補正が実行される。
In the image reading apparatus described in Patent Document 1, the ROM is set to have a value equivalent to the white reflection density.
Correction of the reflection density is performed on the basis of the reflectance of the non-white reference member stored in. That is, the reflection density is corrected by multiplying the reflection density by the reflection factor of the non-white reference member with respect to the white reflection factor of 100%. Therefore, the correction is performed by a fixed value stored in advance in the ROM, that is, the reflectance [%] of the non-white reference member with respect to the white reflectance 100%.

しかし、非白色の基準部材は印刷等により製造されるため、非白色の基準部材の基準濃度に対して管理を行っていても濃度バラツキが発生してしまう。また、白色基準部材を読み取って得られる白色の反射濃度は読取デバイスの出力濃度のバラツキによりバラツキを生ずる。これらのバラツキの影響により、非白色の基準部材の反射率、又は白色の反射濃度に製品毎のバラツキが発生する。この非白色の基準部材の反射率、又は白色の反射濃度のバラツキにより、上述した固定値で補正すると、シェーディング補正を精度良く行うことができず、濃度バラツキ、すなわち階調バラツキが発生していた。   However, since the non-white reference member is manufactured by printing or the like, even if the control is performed on the reference density of the non-white reference member, density variation occurs. Further, the reflection density of white obtained by reading the white reference member causes a variation due to the variation of the output density of the reading device. Due to the influence of these variations, product-to-product variations occur in the reflectance of the non-white reference member or the white reflection density. Due to variations in the reflectance of the non-white reference member or the reflection density of white, shading correction can not be performed accurately if correction is performed with the above-described fixed value, and density variation, that is, tone variation occurs. .

そこで、本発明は、上述した事情に鑑みてなされ、灰色基準部材を使用して読み取った画像の階調バラツキを低減することができる画像読取装置を提供することを目的とする。   Therefore, the present invention has been made in view of the above-described circumstances, and an object of the present invention is to provide an image reading apparatus capable of reducing gradation variation of an image read using a gray reference member.

上記目的を達成するために、請求項1に記載の発明態様は、原稿が搬送される搬送経路に配置され、白色より反射率が低い灰色基準部材と、原稿が前記灰色基準部材を通過するときに原稿の画像をライン単位で画素毎に読み取るために光源と光電変換素子とを含む読取部と、予め定められた最大光量値までの範囲において前記光源の光量調整値を設定する光量設定部と、前記光電変換素子からのアナログ信号をデジタルデータに変換する変換部と、前記デジタルデータを基準データに基づきシェーディング補正する補正部と、記憶部
と、事前処理を実行した後に、読取前処理を実行する制御部と、を備え、前記制御部は、前記事前処理として、前記光源を消灯したときに前記変換部から出力される1ライン分の第1黒データを取得する第1黒データ取得処理と、前記光源が白色基準部材を照射するときに前記変換部から出力される1ライン分の白データを取得する白データ取得処理であって、前記白データを取得するときの前記光量調整値は第1光量調整値である前記白データ取得処理と、同じ画素位置における前記1ライン分の前記白データから前記1ライン分の前記第1黒データを引算して1ライン分の白黒差分データを算出し、前記1ラインの全画素についての白黒差分最大値を算出し、前記白黒差分最大値に対応する特定画素位置を取得する最大値算出処理と、前記白黒差分最大値と前記特定画素位置とを関連付けて前記記憶部に記憶させる記憶制御処理と、を実行し、前記読取前処理として、前記光源を消灯したときに前記変換部から出力される1ライン分の第2黒データを取得する第2黒データ取得処理と、前記光源が前記最大光量値で前記灰色基準部材を照射するときに前記変換部から出力される1ライン分の灰淡データを取得する灰淡データ取得処理と、前記1ライン分の前記灰淡データから前記1ライン分の前記第2黒データを引算して1ライン分の灰淡黒差分データを算出する灰淡黒差分データ算出処理と、前記特定画素位置における前記白黒差分最大値と前記特定画素位置における前記灰淡黒差分データとについて、前記白黒差分最大値を前記灰淡黒差分データで割算することで灰白比率を算出する灰白比率算出処理と、前記1ライン分の前記灰淡データと前記灰白比率とを掛算して1ライン分の前記基準データを算出する補正値算出処理と、を実行する。
In order to achieve the above object, the invention according to claim 1 is characterized in that when the document passes through the gray reference member, the gray reference member is disposed in the conveyance path along which the document is conveyed and has a reflectance lower than white. A reading unit including a light source and a photoelectric conversion element in order to read an image of an original document line by line, and a light quantity setting unit for setting the light quantity adjustment value of the light source in a range up to a predetermined maximum light quantity value; After performing pre-processing, a conversion unit that converts an analog signal from the photoelectric conversion element into digital data, a correction unit that performs shading correction on the digital data based on reference data, and pre-processing A control unit, and the first control unit, as the pre-processing, obtains the first black data for one line output from the conversion unit when the light source is turned off. Data acquisition processing and white data acquisition processing for acquiring white data for one line output from the conversion unit when the light source irradiates a white reference member, the data being acquired when the white data is acquired The light quantity adjustment value is equivalent to the first light quantity adjustment value, and the first black data for the one line is subtracted from the white data for the one line at the same pixel position, Calculating a black-and-white difference data, calculating a black-and-white difference maximum value for all pixels of the one line, and acquiring a specific pixel position corresponding to the black-and-white difference maximum value; Storage control processing for storing in the storage unit in association with a specific pixel position, and as the pre-reading processing, second black data for one line output from the conversion unit when the light source is turned off Second black data acquisition processing for acquiring the gray light data acquisition processing for acquiring gray data of one line output from the conversion unit when the light source irradiates the gray reference member with the maximum light amount value And gray-black difference data calculation processing for calculating gray-black difference data of one line by subtracting the second black data of one line from the gray-light data of the one line; Gray-white ratio calculation processing for calculating the gray-white ratio by dividing the black-and-white difference maximum value by the gray-black difference data for the black-and-white difference maximum value at the pixel position and the gray-light black difference data at the specific pixel position And a correction value calculation process of calculating the reference data of one line by multiplying the gray-and-light data of the one line and the gray-white ratio.

請求項2に記載の具体的態様では、前記白データは複数の色データから構成され、前記最大値算出処理は、複数の前記色データのうちの1つの前記色データである特定の色データに対応する前記白黒差分データを用いて前記白黒差分最大値を算出し、複数の前記色データの各色データについて前記白黒差分最大値の画素位置を前記特定画素位置として取得する。   In the specific aspect according to claim 2, the white data is composed of a plurality of color data, and the maximum value calculation process is performed on a specific color data which is the one color data among the plurality of the color data. The black and white difference maximum value is calculated using the corresponding black and white difference data, and the pixel position of the black and white difference maximum value is acquired as the specific pixel position for each color data of the plurality of color data.

請求項3に記載の具体的態様では、前記最大値算出処理は、前記1ライン分の前記白黒差分データのうち大きい順に所定個の画素の前記白黒差分データを前記白黒差分最大値とし、前記記憶制御処理は、前記所定個の前記白黒差分最大値と前記所定個の特定画素位置とを関連付けて前記記憶部に記憶させ、前記灰白比率算出処理は、前記所定個の前記特定画素位置における前記白黒差分最大値と前記所定個の前記特定画素位置における前記灰淡黒差分データとについて、前記白黒差分最大値を前記灰淡黒差分データで割算して算出した前記所定個の値の平均値を前記灰白比率とする。   In the specific aspect according to claim 3, in the maximum value calculation process, the black-and-white difference data of a predetermined number of pixels in the descending order of the one-line black-and-white difference data is used as the black-and-white difference maximum value. The control processing associates the predetermined number of black and white difference maximum values with the predetermined number of specific pixel positions and stores the same in the storage unit, and the gray-white ratio calculation processing includes the black and white at the predetermined number of specific pixel positions The average value of the predetermined number of values calculated by dividing the black-and-white differential maximum value by the gray-black difference data for the maximum difference value and the gray-black difference data at the predetermined number of specific pixel positions It is assumed that the ratio is gray.

請求項4に記載の具体的態様では、前記特定の前記色データは、複数の前記色データのうち前記白黒差分最大値が最も大きい前記色データである。   In the specific aspect of the present invention, the specific color data is the color data having the largest black-and-white difference maximum value among a plurality of the color data.

請求項5に記載の具体的態様では、複数の前記色データは、赤色、青色、および緑色に対応する前記色データであり、前記特定の前記色データは、前記赤色に対応する前記色データである。   In the specific aspect according to claim 5, the plurality of color data are the color data corresponding to red, blue and green, and the specific color data is the color data corresponding to the red is there.

請求項6に記載の具体的態様では、原稿が搬送される搬送経路に配置され、白色より反射率が低い灰色基準部材と、原稿が前記灰色基準部材を通過するときに原稿の画像をライン単位で画素毎に読み取るために光源と光電変換素子とを含む読取部と、予め定められた最大光量値までの範囲において前記光源の光量調整値を設定する光量設定部と、前記光電変換素子からのアナログ信号をデジタルデータに変換する変換部と、前記デジタルデータを基準データに基づきシェーディング補正する補正部と、記憶部と、事前処理を実行した後に、読取前処理を実行する制御部と、を備え、前記制御部は、前記事前処理として、前記光源を消灯したときに前記変換部から出力される1ライン分の第1黒データを取得する第1黒データ取得処理と、前記光源が白色基準部材を照射するときに前記変換部から出力
される1ライン分の白データを取得する白データ取得処理であって、前記白データを取得するときの前記光量調整値は第1光量調整値である前記白データ取得処理と、前記光源が前記第1光量調整値で灰色基準部材を照射するときに前記変換部から出力される1ライン分の第1灰データを取得する第1灰データ取得処理と、同じ画素位置における前記1ライン分の前記白データから前記1ライン分の前記第1黒データを引算して1ライン分の白黒差分データを算出し、前記1ラインの全画素についての白黒差分最大値を算出し、前記白黒差分最大値に対応する特定画素位置を取得する最大値算出処理と、前記1ライン分の前記第1灰データから前記1ライン分の前記第1黒データを引算して1ライン分の第1灰黒差分データを算出し、前記特定画素位置における前記第1灰黒差分データの灰黒差分最大値を算出する灰黒差分最大値算出処理と、前記白黒差分最大値と、前記灰黒差分最大値と、前記特定画素位置とを関連付けて前記記憶部に記憶させる記憶制御処理と、を実行し、前記読取前処理として、前記光源を消灯したときに前記変換部から出力される1ライン分の第2黒データを取得する第2黒データ取得処理と、前記光源が前記最大光量値で前記灰色基準部材を照射するときに前記変換部から出力される1ライン分の灰淡データを取得する灰淡データ取得処理と、前記光源が前記第1光量調整値で前記灰色基準部材を照射するときに前記変換部から出力される1ライン分の第2灰データを取得する第2灰データ取得処理と、前記1ライン分の前記灰淡データから前記1ライン分の前記第2黒データを引算して1ライン分の灰淡黒差分データを算出する灰淡黒差分データ算出処理と、前記1ライン分の前記第2灰データから前記1ライン分の前記第2黒データを引算して1ライン分の第2灰黒差分データを算出する第2灰黒差分データ算出処理と、前記特定画素位置における前記白黒差分最大値と前記特定画素位置における前記灰淡黒差分データとについて、前記白黒差分最大値を前記灰淡黒差分データで割算することで灰白比率を算出する灰白比率算出処理と、前記特定画素位置における前記灰黒差分最大値と前記特定画素位置における前記第2灰黒差分データとについて、前記第2灰黒差分データを前記灰黒差分最大値で割算することで灰比率を算出する灰比率算出処理と、前記1ライン分の前記灰淡データと前記灰白比率と前記灰比率とを掛算して1ライン分の前記基準データを算出する補正値算出処理と、を実行する。
According to the specific aspect of the present invention, the gray reference member disposed in the conveyance path along which the document is conveyed and having a reflectance lower than white, and the image of the document line by line when the document passes through the gray reference member A reading unit including a light source and a photoelectric conversion element for reading each pixel, a light quantity setting section for setting the light quantity adjustment value of the light source within a range up to a predetermined maximum light quantity value, and the photoelectric conversion element It comprises: a converter for converting an analog signal into digital data; a correction unit for performing shading correction on the digital data based on reference data; a storage unit; and a controller for executing pre-reading processing after performing pre-processing. The first black data acquisition process for acquiring the first black data for one line output from the conversion unit when the light source is turned off as the pre-processing. A white data acquisition process for acquiring white data of one line output from the conversion unit when the source irradiates a white reference member, wherein the light amount adjustment value when acquiring the white data is a first light amount White data acquisition processing which is an adjustment value, and first ash for acquiring one line of first ash data output from the conversion unit when the light source irradiates a gray reference member with the first light amount adjustment value In the data acquisition process, the first black data of the one line is subtracted from the white data of the one line at the same pixel position to calculate black and white difference data of one line, and all pixels of the one line Calculating the maximum value of the black-and-white difference with respect to each other and obtaining the specific pixel position corresponding to the black-and-white difference maximum, and the first black of the one line from the first gray data of the one line Pull data And calculating the first gray-black difference data for one line, and calculating the gray-black difference maximum value of the first gray-black difference data at the specific pixel position; A storage control process for storing a value, the gray-black difference maximum value, and the specific pixel position in association with each other in the storage unit, and converting the conversion unit when the light source is turned off as the reading pre-processing Black data acquisition processing for acquiring second black data for one line output from the image processing unit, and one line output from the conversion unit when the light source irradiates the gray reference member with the maximum light amount value Gray light data acquisition processing for acquiring gray light data, and the second gray data for one line output from the conversion unit when the light source irradiates the gray reference member with the first light amount adjustment value Second ash data acquisition process Gray-black difference data calculation processing for calculating gray-black difference data of one line by subtracting the second black data of one line from the gray-light data of the one line; Second gray-black difference data calculation processing for calculating second gray-black difference data for one line by subtracting the second black data for one line from the second gray data for one line; Gray-white ratio calculation processing for calculating the gray-white ratio by dividing the black-and-white difference maximum value by the gray-black difference data for the black-and-white difference maximum value at the pixel position and the gray-light black difference data at the specific pixel position The second gray-black difference data is divided by the gray-black difference maximum value for the gray-black difference maximum value at the specific pixel position and the second gray-black difference data at the specific pixel position. Calculate the ratio Performing a ratio calculation process, and a correction value calculating process for calculating the reference data of one line by multiplying the 1 line of the ash pale data and the gray proportion and the ash ratio.

請求項1に記載の発明態様では、第1黒データ取得処理は、光源を消灯したときに変換部から出力される1ライン分の第1黒データを取得する。白データ取得処理は、光源が白基準部材を照射するときに変換部から出力される1ライン分の白データを取得する。最大値算出処理は、同じ画素位置における1ライン分の白データから1ライン分の黒データを引算して1ライン分の白黒差分データを算出し、前記1ラインの全画素についての白黒差分最大値を算出し、前記白黒差分最大値に対応する特定画素位置を取得する。記憶制御処理は、前記白黒差分最大値と前記特定画素位置とを関連付けて記憶部に記憶させる。第2黒データ取得処理は、光源を消灯したときに変換部から出力される1ライン分の第2黒データを取得する。灰淡データ取得処理は、光源が最大光量値で灰色基準部材を照射するときに変換部から出力される1ライン分の灰淡データを取得する。灰淡黒差分データ算出処理は、1ライン分の灰淡データから1ライン分の第2黒データを引算して1ライン分の灰淡黒差分データを算出する。灰白比率算出処理は、前記特定画素位置における前記白黒差分最大値と前記特定画素位置における前記灰淡黒差分データとについて、前記白黒差分最大値を灰淡黒差分データで割算することで灰白比率を算出する。補正値算出処理は、1ラ
イン分の灰淡データと灰白比率とを掛算して1ライン分の基準データを算出する。よって、灰色基準部材を読み取ったときの灰淡データを取得し、シェーディング補正データを生成するための灰白比率を精度よく求め、灰白比率と灰淡データとから基準データを算出することで、画像の階調バラツキを低減できる。
In the first aspect of the present invention, the first black data acquisition process acquires one line of first black data output from the conversion unit when the light source is turned off. The white data acquisition process acquires white data of one line output from the conversion unit when the light source irradiates the white reference member. In the maximum value calculation process, black data of one line is subtracted from white data of one line at the same pixel position to calculate black and white difference data of one line, and the black and white difference maximum for all pixels of the one line is calculated. A value is calculated, and a specific pixel position corresponding to the black and white difference maximum value is acquired. The storage control process associates the black-and-white difference maximum value with the specific pixel position and stores the same in the storage unit. The second black data acquisition process acquires one line of second black data output from the conversion unit when the light source is turned off. The gray-light data acquisition process acquires gray-scale data for one line output from the conversion unit when the light source irradiates the gray reference member with the maximum light amount value. The light gray black difference data calculation process calculates gray gray black difference data for one line by subtracting second black data for one line from gray light data for one line. In the gray-white ratio calculation process, the gray-white ratio is calculated by dividing the black-and-white difference maximum value by the gray-black difference data with respect to the black-and-white difference maximum value at the specific pixel position and the gray-light black difference data at the specific pixel position. Calculate In the correction value calculation process, one line of gray-scale data is multiplied by an ash-white ratio to calculate one line of reference data. Therefore, gray-light data when the gray reference member is read is acquired, the gray-white ratio for generating shading correction data is accurately determined, and the reference data is calculated from the gray-white ratio and gray-light data to obtain an image. Gradation variation can be reduced.

請求項2に記載の具体的態様では、最大値算出処理は、特定の色データに対して白黒差分最大値を算出し、各色の特定画素位置を取得する。よって、各色データで同じ特定画素
位置となり、各色の灰白比率を精度よく算出することができる。
According to the specific aspect of the present invention, the maximum value calculation process calculates the black and white difference maximum value for the specific color data, and acquires the specific pixel position of each color. Therefore, it becomes the same specific pixel position in each color data, and the gray-white ratio of each color can be calculated accurately.

請求項3に記載の具体的態様では、最大値算出処理は、白黒差分データのうち大きい順に所定個の画素の差分データを白黒差分最大値とし、灰白比率算出処理は、所定個の値で構成される白黒差分最大値の平均値を灰白比率とする。よって、精度の高い灰白比率を算出することができる。   In a specific aspect according to claim 3, in the maximum value calculation processing, the difference data of predetermined number of pixels in the order of large among the black and white difference data is set as the black and white difference maximum value, and the gray / white ratio calculation processing is configured by predetermined values. The average value of the black-and-white difference maximum values to be Therefore, the gray-white ratio can be calculated with high accuracy.

請求項4に記載の具体的態様では、特定の色データは白黒差分最大値が最も大きい色データである。よって、特定画素位置を精度よく算出することができ、灰白比率を精度よく算出することができる。   In a specific aspect according to claim 4, the specific color data is color data having the largest black and white difference maximum value. Therefore, the specific pixel position can be accurately calculated, and the gray-white ratio can be accurately calculated.

請求項5に記載の具体的態様では、特定の色データは、赤色である。よって、他の色に比べて発光ダイオードを用いて高輝度の出力を出すことができる。この高輝度の出力により、特定画素位置を精度よく算出することができ、灰白比率を精度よく算出することができる。   In a specific aspect according to claim 5, the specific color data is red. Thus, the light emitting diode can be used to provide an output of high luminance as compared to other colors. The output of the high luminance enables the specific pixel position to be accurately calculated, and the gray-white ratio to be accurately calculated.

請求項6に記載の具体的態様では、事前処理である第1灰データ取得処理は、第1光量調整値で灰色基準部材を照射するときに変換部から出力される1ライン分の第1灰データを取得する。灰黒差分最大値算出処理は、前記第1灰データから1ライン分の第1黒データを
引算して1ライン分の第1灰黒差分最大値を算出する。読取前処理である第2灰データ取得処理は、第1光量調整値で灰色基準部材を照射するときに変換部から出力される1ライン分の第2灰データを取得する。第2灰黒差分データ算出処理は、第2灰データから第2黒データを引算して第2灰黒差分データを算出する。灰比率算出処理は、第2灰黒差分データを灰黒差分最大値で割算することで灰比率を算出する。補正値算出処理は、灰淡データと灰比率とを掛算して基準データを算出する。よって、事前処理から読取前処理までに灰データが変化した場合にも、正確な基準データを算出することができる。
In the specific aspect according to claim 6, the first ash data acquisition process, which is the pre-processing, is a process for outputting the first light for one line output from the conversion unit when the gray reference member is irradiated with the first light amount adjustment value. Get data The gray black difference maximum value calculation process subtracts the first black data for one line from the first gray data to calculate the first gray black difference maximum value for one line. The second ash data acquisition process, which is a pre-reading process, acquires one line of second ash data output from the conversion unit when the gray reference member is irradiated with the first light amount adjustment value. The second gray-black difference data calculating process calculates second gray-black difference data by subtracting the second black data from the second gray data. In the ash ratio calculation process, the ash ratio is calculated by dividing the second gray-black difference data by the gray-black difference maximum value. In the correction value calculation process, reference data is calculated by multiplying gray data and the ash ratio. Therefore, accurate reference data can be calculated even when ash data changes from the pre-processing to the pre-reading processing.

本発明の実施形態に係る画像読取装置1の内部構成を示す正面図である。FIG. 1 is a front view showing an internal configuration of an image reading device 1 according to an embodiment of the present invention. 画像読取装置1の読取部24の構成を拡大して示す図面である。5 is an enlarged view of a configuration of a reading unit 24 of the image reading apparatus 1. FIG. 読取部24の受光部31の構成を示すブロック図である。FIG. 6 is a block diagram showing a configuration of a light receiving unit 31 of the reading unit 24. 画像読取装置1の電気的構成を示すブロック図である。FIG. 2 is a block diagram showing an electrical configuration of the image reading apparatus 1; 保守メイン処理を示すフローチャートである。It is a flow chart which shows maintenance main processing. 灰淡黒差分データ記憶M15を示すフローチャートである。It is a flowchart which shows the light gray black difference data storage M15. 読取メイン処理を示すフローチャートである。It is a flow chart which shows reading main processing. 基準データ算出R7を示すフローチャートである。It is a flowchart which shows reference data calculation R7.

[実施形態]
以下に、本発明の一実施形態に係る画像読取装置1について図面を参照して説明する。図1において、上下方向および前後方向は矢印により示される。
[Embodiment]
Hereinafter, an image reading apparatus 1 according to an embodiment of the present invention will be described with reference to the drawings. In FIG. 1, the vertical direction and the front-rear direction are indicated by arrows.

<画像読取装置1の機械的構成>
図1において、画像読取装置1は、給紙トレイ2と、本体部3と、排紙トレイ4とを備える。操作部5、および表示部6が、本体部3の上面に配置される。操作部5は、電源スイッチ、および各種設定ボタンを含み、使用者からの操作指令等を受け付ける。たとえば、操作部5は、3色のカラーモードおよび単色のモノモードのいずれかを選択する選択ボタン、解像度を設定する操作ボタンなどを含む。表示部6は、LCDを含み、画像読取装置1の状況を表示する。
<Mechanical Configuration of Image Reading Device 1>
In FIG. 1, the image reading apparatus 1 includes a sheet feeding tray 2, a main body 3, and a sheet discharging tray 4. The operation unit 5 and the display unit 6 are disposed on the upper surface of the main body unit 3. The operation unit 5 includes a power switch and various setting buttons, and receives an operation instruction and the like from the user. For example, the operation unit 5 includes a selection button for selecting one of three color modes and a single color mono mode, an operation button for setting a resolution, and the like. The display unit 6 includes an LCD and displays the status of the image reading apparatus 1.

搬送経路20が、本体部3の内部に形成される。給紙トレイ2に載置された原稿GSは、搬送経路20に沿って搬送方向FDに搬送され、排紙トレイ4に排出される。給紙ローラ21と、分離パッド22と、一対の上流側搬送ローラ23と、読取部24と、プラテンガラス25と、一対の下流側搬送ローラ26とが、搬送経路20に沿って配置される。   A transport path 20 is formed inside the main body 3. The document GS placed on the paper feed tray 2 is conveyed in the conveyance direction FD along the conveyance path 20 and discharged to the paper discharge tray 4. The paper feed roller 21, the separation pad 22, the pair of upstream conveyance rollers 23, the reading unit 24, the platen glass 25, and the pair of downstream conveyance rollers 26 are disposed along the conveyance path 20.

給紙ローラ21は、分離パッド22と協働して、給紙トレイ2に載置された複数枚の原稿GSを、1枚ずつ給送する。上流側搬送ローラ23、および下流側搬送ローラ26は、搬送モータMT(図4参照)により駆動される。プラテンガラス25は、光透過性を有し、搬送経路20の下側において搬送経路20に沿って配置される。搬送ローラ23、26は、給紙ローラ21から給送された原稿GSがプラテンガラス25の上を通過するように原稿GSを搬送する。   The sheet feed roller 21 cooperates with the separation pad 22 to feed a plurality of sheets of the document GS placed on the sheet feed tray 2 one by one. The upstream side conveyance roller 23 and the downstream side conveyance roller 26 are driven by a conveyance motor MT (see FIG. 4). The platen glass 25 is light transmissive and is disposed along the transport path 20 below the transport path 20. The conveyance rollers 23 and 26 convey the document GS such that the document GS fed from the paper feed roller 21 passes over the platen glass 25.

本実施形態では、原稿GSの読み取り面が給紙トレイ2の載置面に向くように原稿GSが給紙トレイ2に載置される。読取部24は、搬送経路20の下側に配置され、プラテンガラス25を通過する原稿GSの読み取り面の画像を読み取る。原稿センサ27が、給紙トレイ2に配置され、給紙トレイ2に原稿GSが載置されたときにオンし、給紙トレイ2に原稿GSが載置されていないときにオフするように構成される。   In the present embodiment, the document GS is placed on the paper feed tray 2 such that the reading surface of the document GS faces the placement surface of the paper feed tray 2. The reading unit 24 is disposed below the transport path 20 and reads an image on the reading surface of the document GS passing through the platen glass 25. The document sensor 27 is disposed on the sheet feeding tray 2 and configured to be turned on when the document GS is placed on the sheet feeding tray 2 and turned off when the document GS is not placed on the sheet feeding tray 2 Be done.

(読取部24の詳細な構成)
読取部24の詳細な構成について図2および図3を参照して説明する。図2において、読取部24は、光源30と、受光部31と、光学部材32とを備える。光源30は、赤色、緑色および青色の3色の発光ダイオードを含む。光源30から出射された光が原稿GSの読み取り面などにより反射されたときに、光学部材32は、反射光を受光部31に導く。本実施形態において、カラーモードが選択されたとき、3色の発光ダイオードが順次点灯することにより1ライン分の原稿GSの画像が読み取られる。また、モノモードが選択されたとき、3色のうちの特定の1色、たとえば緑色の発光ダイオードが点灯することにより1ライン分の原稿GSの画像が読み取られる。赤色の発光ダイオードは安価で高輝度を出力できる。
(Detailed Configuration of Reading Unit 24)
The detailed configuration of the reading unit 24 will be described with reference to FIGS. 2 and 3. In FIG. 2, the reading unit 24 includes a light source 30, a light receiving unit 31, and an optical member 32. The light source 30 includes light emitting diodes of three colors of red, green and blue. When the light emitted from the light source 30 is reflected by the reading surface of the document GS or the like, the optical member 32 guides the reflected light to the light receiving unit 31. In this embodiment, when the color mode is selected, the light emitting diodes of three colors are sequentially turned on to read an image of the document GS of one line. When the mono mode is selected, the light emitting diode of one of the three colors, for example, the green light is turned on, whereby the image of the document GS of one line is read. The red light emitting diode is inexpensive and can output high brightness.

灰色基準板34が、読取部24と搬送経路20を介して対向する位置に、配置される。灰色基準板34は、原稿GSの背景色である白色より低い反射率を有する。搬送経路20に原稿GSが存在しない場合、光源30からの出射光は、灰色基準板34により反射され、その反射光は光学部材32を介して受光部31により受光される。光学部材32は、主走査方向MDに延びるロッドレンズを含む。   The gray reference plate 34 is disposed at a position facing the reading unit 24 via the transport path 20. The gray reference plate 34 has a lower reflectance than white, which is the background color of the document GS. When the document GS does not exist in the transport path 20, the light emitted from the light source 30 is reflected by the gray reference plate 34, and the reflected light is received by the light receiving unit 31 via the optical member 32. The optical member 32 includes a rod lens extending in the main scanning direction MD.

図3において、受光部31は、主走査方向MDに直線状に配列される多数のセンサICチップを有し、各センサICチップは、主走査方向MDに配列される多数の光電変換素子33を含み、図示しないシフトレジスタ、および増幅器を内蔵する。多数のセンサICチップは、6つのチャンネルCH1〜CH6に区分される。各チャンネルには、1つまたは2つのセンサICチップが含まれる。多数のセンサICチップを有する受光部の構成は、特開2003−298813号公報などにより公知であるので、その詳細な説明を省略する。   In FIG. 3, the light receiving section 31 has a large number of sensor IC chips linearly arranged in the main scanning direction MD, and each sensor IC chip has a large number of photoelectric conversion elements 33 arranged in the main scanning direction MD. Incorporates a shift register and an amplifier (not shown). The multiple sensor IC chips are divided into six channels CH1 to CH6. Each channel contains one or two sensor IC chips. The configuration of a light receiving unit having a large number of sensor IC chips is known from, for example, Japanese Patent Laid-Open No. 2003-298813, and thus the detailed description thereof is omitted.

<画像読取装置1の電気的構成>
画像読取装置1の電気的構成について図4を参照して説明する。図4において、画像読取装置1は、CPU40、ROM41、RAM42、フラッシュPROM43、デバイス制御部44、アナログフロントエンド(以下、AFEという。)45、画像処理部46、および駆動回路47を構成要素の一部として備える。これらの構成要素は、バス48を介して、操作部5、表示部6、および原稿センサ27に接続される。
<Electric Configuration of Image Reading Device 1>
The electrical configuration of the image reading apparatus 1 will be described with reference to FIG. In FIG. 4, the image reading apparatus 1 includes a CPU 40, a ROM 41, a RAM 42, a flash PROM 43, a device control unit 44, an analog front end (hereinafter referred to as AFE) 45, an image processing unit 46, and a drive circuit 47. Prepare as a department. These components are connected to the operation unit 5, the display unit 6, and the document sensor 27 via the bus 48.

ROM41は、後述する保守メイン処理、読取メイン処理、各メイン処理中のサブルーチンの処理など、画像読取装置1の各種動作を実行するためのプログラムを記憶する。CPU40は、ROM41から読み出されたプログラムに従って、各部の制御を行う。フラッシュPROM43は、読み書き可能な不揮発性メモリであり、CPU40の制御処理により生成された各種のデータ、たとえば保守メイン処理により算出された各データなどを記憶する。RAM42は、CPU40の制御処理により生成された算出結果などを一時的に記憶する。   The ROM 41 stores programs for executing various operations of the image reading apparatus 1 such as maintenance main processing described later, reading main processing, and processing of subroutines in each main processing. The CPU 40 controls each part in accordance with the program read from the ROM 41. The flash PROM 43 is a readable and writable nonvolatile memory, and stores various data generated by control processing of the CPU 40, for example, each data calculated by the maintenance main processing. The RAM 42 temporarily stores calculation results and the like generated by control processing of the CPU 40.

デバイス制御部44は、読取部24に接続され、CPU40からの命令に基いて、光源30の点灯または消灯を制御する信号、および、光源30に流れる電流値を制御する信号を読取部24に送信する。また、デバイス制御部44は、CPU40からの命令に基いて、受光部31の各センサICチップの多数の光電変換素子33を順番に動作させるために、図3に示すように各画素を転送するためのクロック信号CLK、および、全ての光電変換素子の電気信号を同時にシフトレジスタに転送するためのシリアルイン信号SIを受光部31に送信する。読取部24は、デバイス制御部44から点灯制御信号を受け取ると、光源30を点灯させるとともに、受光部31が受光した受光量に応じたアナログ信号をAFE45に送信する。ここで、光源30が照射する最大光量は、予め定められた最大電流値とシリアルイン信号SIの間隔における光源30が点灯可能な期間とから決定される光量である。   The device control unit 44 is connected to the reading unit 24 and transmits to the reading unit 24 a signal for controlling turning on / off of the light source 30 and a signal for controlling the current value flowing to the light source 30 based on an instruction from the CPU 40 Do. Further, the device control unit 44 transfers each pixel as shown in FIG. 3 in order to operate the large number of photoelectric conversion elements 33 of each sensor IC chip of the light receiving unit 31 in order based on an instruction from the CPU 40. The clock signal CLK for transmission and a serial-in signal SI for simultaneously transferring the electric signals of all the photoelectric conversion elements to the shift register are transmitted to the light receiving section 31. When receiving the lighting control signal from the device control unit 44, the reading unit 24 turns on the light source 30, and transmits an analog signal according to the amount of light received by the light receiving unit 31 to the AFE 45. Here, the maximum light quantity emitted by the light source 30 is a light quantity determined from a predetermined maximum current value and a period in which the light source 30 can be lit at an interval of the serial-in signal SI.

AFE45は、読取部24に接続され、CPU40からの命令に基づいて、読取部24から送信されるアナログ信号をデジタルデータに変換する。AFE45は、予め定められた入力レンジおよび分解能を有する。たとえば、分解能は、10ビットであるならば「0」から「1023」の階調である。この場合、AFE45は、読取部24から送信されたアナログ信号をデジタルデータとして10ビット(0〜1023)の階調データに変換する。AFE45によって変換されたデジタルデータは、画像処理部46に送信される。画像処理部46は、画像処理用の専用ICであるASICから構成され、階調データに各種の画像処理を施す。画像処理は、シェーディング補正、γ補正などの各種の補正処理、および解像度変換処理などである。画像処理部46は、各種の画像処理を施さないように設定することもできるし、全ての画像処理を施すように設定することもできる。画像処理部46は、設定された画像処理をデジタルデータに施し、デジタル画像データを生成する。そのデジタル画像データは、バス48を介してRAM42に記憶される。   The AFE 45 is connected to the reading unit 24, and converts an analog signal transmitted from the reading unit 24 into digital data based on an instruction from the CPU 40. The AFE 45 has a predetermined input range and resolution. For example, if the resolution is 10 bits, it has a gradation of "0" to "1023". In this case, the AFE 45 converts, as digital data, the analog signal transmitted from the reading unit 24 into gradation data of 10 bits (0 to 1023). The digital data converted by the AFE 45 is transmitted to the image processing unit 46. The image processing unit 46 is composed of an ASIC, which is a dedicated IC for image processing, and performs various types of image processing on gradation data. The image processing includes various correction processing such as shading correction and γ correction, and resolution conversion processing. The image processing unit 46 can be set not to perform various types of image processing, or can be set to perform all image processing. The image processing unit 46 applies the set image processing to the digital data to generate digital image data. The digital image data is stored in the RAM 42 via the bus 48.

駆動回路47は、搬送モータMTに接続され、CPU40から送信される駆動指令に基づいて搬送モータMTを駆動する。駆動回路47は、駆動指令により指令された回転量および回転方向に従って搬送モータMTを回転させる。搬送モータMTが所定量だけ回転すると、搬送ローラ23、26が所定角度回転し、搬送経路20において原稿GSが所定距離だけ搬送される。   The drive circuit 47 is connected to the transport motor MT, and drives the transport motor MT based on a drive command transmitted from the CPU 40. The drive circuit 47 rotates the transport motor MT in accordance with the rotation amount and the rotation direction instructed by the drive instruction. When the transport motor MT rotates by a predetermined amount, the transport rollers 23, 26 rotate by a predetermined angle, and the document GS is transported by a predetermined distance in the transport path 20.

<実施形態の動作>
次に、画像読取装置1の動作について図面を参照して説明する。画像読取装置1は、原稿GSの読み取り前に実行される保守メイン処理と、原稿GSを読み取る読取メイン処理とを主に実行する。保守メイン処理中のステップM1〜M15の処理、読取メイン処理中のステップR1〜R8の処理、および各サブルーチンのステップの処理は、CPU40が実行する処理である。本実施形態において、CPU40が1ライン分の各画素について実行するデータ処理は、カラーモードにおいて3色の画素の各画素について実行する処理であり、モノモードにおいて特定の1色の画素について実行する処理である。
<Operation of Embodiment>
Next, the operation of the image reading apparatus 1 will be described with reference to the drawings. The image reading apparatus 1 mainly executes maintenance main processing executed before reading of the document GS and reading main processing of reading the document GS. The processing of steps M1 to M15 in the maintenance main processing, the processing of steps R1 to R8 in the reading main processing, and the processing of steps of each subroutine are processing that the CPU 40 executes. In the present embodiment, the data processing executed by the CPU 40 for each pixel for one line is processing executed for each pixel of three color pixels in the color mode, and processing executed for the pixel of one specific color in the mono mode. It is.

(保守メイン処理)
図5に示す保守メイン処理は、画像読取装置1が工場から出荷される前に、または出荷
後にサービスマンが保守点検するときに、サービスマン等の作業者が画像読取装置1の操作部5を特別な操作方法に従って操作することにより開始される。
(Maintenance main processing)
In the maintenance main process shown in FIG. 5, before the image reading apparatus 1 is shipped from the factory, or when the service person performs maintenance inspection after shipment, a worker such as the service person can operate the operation unit 5 of the image reading apparatus 1. It starts by operating according to a special operation method.

まず、作業者が、白基準となる特別な原稿GSを給紙トレイ2に載置すると、原稿センサ27が原稿GSを検知する。原稿センサ27からの検知信号に従って、原稿GSがあるか否かが判断される(M1)。原稿GSがあるとき(M1:YES)、処理がステップM2に進む。原稿GSがないとき(M1:NO)、処理がステップM10に進み、原稿GSがないことを報知するエラーメッセージが表示部6に表示され(M10)、保守メイン処理が終了する。   First, when the operator places a special document GS serving as a white reference on the paper feed tray 2, the document sensor 27 detects the document GS. In accordance with the detection signal from the document sensor 27, it is determined whether the document GS is present (M1). If there is a document GS (M1: YES), the process proceeds to step M2. If the document GS is not present (M1: NO), the process proceeds to step M10, an error message notifying that the document GS is not present is displayed on the display unit 6 (M10), and the maintenance main processing is ended.

CPU40は、駆動回路47により原稿GSをプラテンガラス25まで給送させ、デバイス制御部44、AFE45、および画像処理部46に読取設定値を設定する(M2)。具体的には、CPU40は、駆動回路47に駆動指令を送信し、給紙トレイ2に載置された白基準原稿GSをプラテンガラス25まで給送させる。さらに、CPU40は、600DPIの読取解像度に応じたクロック信号CLKおよびシリアルイン信号SIの設定をフラッシュPROM43から取得し、デバイス制御部44に設定する。CPU40は、カラーモード時の光源30に対する信号の設定をフラッシュPROM43から取得し、デバイス制御部44に設定する。CPU40は、AFE45のオフセット調整値およびゲイン調整値をフラッシュPROM43から取得し、AFE45に設定する。ここで、オフセット調整値は、AFE45に入力されるアナログ信号のレベルをシフトする値であり、ゲイン調整値は、AFE45に入力されるアナログ信号の利得を調整する値である。CPU40は、画像処理部46に各種の画像処理を施さないように設定する。   The CPU 40 causes the drive circuit 47 to feed the document GS to the platen glass 25, and sets reading setting values in the device control unit 44, the AFE 45, and the image processing unit 46 (M2). Specifically, the CPU 40 transmits a drive command to the drive circuit 47 to feed the white reference document GS placed on the paper feed tray 2 to the platen glass 25. Further, the CPU 40 acquires settings of the clock signal CLK and the serial in signal SI according to the reading resolution of 600 DPI from the flash PROM 43 and sets them in the device control unit 44. The CPU 40 acquires the setting of the signal to the light source 30 in the color mode from the flash PROM 43 and sets it in the device control unit 44. The CPU 40 acquires the offset adjustment value and the gain adjustment value of the AFE 45 from the flash PROM 43 and sets the AFE 45. Here, the offset adjustment value is a value for shifting the level of the analog signal input to the AFE 45, and the gain adjustment value is a value for adjusting the gain of the analog signal input to the AFE 45. The CPU 40 sets the image processing unit 46 not to perform various image processing.

CPU40は、光源30の光量を調整する(M3)。具体的には、CPU40は、白基準原稿GSに向けて、光源30から光を照射させ、その反射光を読み取った時のアナログ信号がAFE45の入力レンジの最大となるように、各色の光量STを調整する。ここで、光量STは、光源30の1ライン中の各色における点灯時間および電流値にて決定される。   The CPU 40 adjusts the light amount of the light source 30 (M3). Specifically, the CPU 40 irradiates light from the light source 30 toward the white reference document GS, and the light intensity ST of each color is set so that the analog signal when the reflected light is read becomes the maximum of the AFE 45 input range. Adjust the Here, the light amount ST is determined by the lighting time and current value of each color in one line of the light source 30.

CPU40は、白データWHを取得する(M4)。具体的には、CPU40は、光源30を各色の光量STで点灯させ、白基準原稿GSを読み取る。そして、CPU40は、読み取った1ライン分の各色のデジタル画像データを白データWHとして取得する。   The CPU 40 acquires the white data WH (M4). Specifically, the CPU 40 turns on the light source 30 with the light intensity ST of each color to read the white reference document GS. Then, the CPU 40 acquires the read digital image data of each color for one line as white data WH.

CPU40は、黒データBK1を取得する(M5)。具体的には、CPU40は、光源30を消灯させ、白基準原稿GSを読み取る。そして、読み取った1ラインのうち1色分
のデジタル画像データを黒データBK1として取得する。
The CPU 40 acquires black data BK1 (M5). Specifically, the CPU 40 turns off the light source 30 and reads the white reference document GS. Then, digital image data for one color in one read line is acquired as black data BK1.

CPU40は、白黒差分データWBdifを算出する(M6)。具体的には、CPU40は、各色の白データWHから黒データBK1を引算し、1ライン分の白黒差分データWBdifを算出し、RAM42に記憶する。   The CPU 40 calculates black-and-white difference data WBdif (M6). Specifically, the CPU 40 subtracts the black data BK1 from the white data WH of each color, calculates the black-and-white difference data WBdif for one line, and stores it in the RAM 42.

CPU40は、白黒差分最大値WBmaxを取得する(M7)。具体的には、CPU40は、M6の処理で算出した1ライン分の白黒差分データWBdifのうち赤色の白黒差分データWBdifにおいて大きい値から順に16画素分の白黒差分データWBdifを赤色に対応する白黒差分最大値WBmaxとして取得する。CPU40は、赤色に対応する白黒差分最大値WBmaxが存在する16画素の画素位置Pmaxを取得する。CPU40は、1ライン分の青色に対応する白黒差分データWBdifのうち画素位置Pmaxに対応するデータを青色に対応する白黒差分最大値WBmaxとして取得する。緑色に対応する白黒差分最大値WBmaxも青色と同様に取得し、CPU40は、各色の白黒差分最大値WBmaxを取得する。ここで、赤色は、青色、緑色、および赤色の3色のうちで
白データWHが最も大きい色であり、そのため、後述する灰白比率GWRTを精度よく算出することができる色である。
The CPU 40 acquires the black and white difference maximum value WBmax (M7). Specifically, the CPU 40 sequentially converts the black-and-white difference data WBdif for 16 pixels into the black-and-white difference corresponding to red sequentially from the largest value in the black-and-white difference data WBdif of the black‐and-white difference data WBdif calculated in the process of M6. Acquired as the maximum value WBmax. The CPU 40 acquires a pixel position Pmax of 16 pixels in which the black-and-white difference maximum value WBmax corresponding to red is present. The CPU 40 acquires data corresponding to the pixel position Pmax in the black-and-white difference data WBdif corresponding to one line of blue as the black-and-white difference maximum value WBmax corresponding to blue. The black-and-white difference maximum value WBmax corresponding to green is also acquired similarly to blue, and the CPU 40 acquires the black-and-white difference maximum value WBmax of each color. Here, red is the color in which the white data WH is the largest among the three colors of blue, green, and red, and therefore, it is a color that can accurately calculate the gray-white ratio GWRT described later.

CPU40は、白黒差分最大値WBmaxの画素位置Pmaxを記憶する(M8)。CPU40は、M7で取得した各色の16画素の白黒差分最大値WBmaxが存在する画素位置Pmaxを白黒差分最大値WBmaxと関連付けて16画素分をフラッシュPROM43に記憶する。   The CPU 40 stores the pixel position Pmax of the black and white difference maximum value WBmax (M8). The CPU 40 associates the pixel position Pmax where the black and white difference maximum value WBmax of 16 pixels of each color obtained in M7 exists with the black and white difference maximum value WBmax, and stores 16 pixels in the flash PROM 43.

M8の処理が終了すると、CPU40は、操作部5に配置されるセットキーが押下されるまで、画像読取装置1を待機状態にさせる。(M9)CPU40は、作業者が白基準原稿GSを取り除き、セットキーが押下されると、原稿センサ27がオフとなっているか否かを判断する。CPU40は、原稿センサ27がオフであると判断(M9:Yes)すれば、灰データGR1を取得する処理(M11)へ進む。CPU40は、原稿センサ27がオンであると判断(M9:No)すれば、エラー表示する処理(M10)へ進む。CPU40は、原稿GSが誤って載置されたことを報知するエラーメッセージを表示部6に表示させ(M10)、保守メイン処理が終了する。   When the process of M8 is completed, the CPU 40 causes the image reading device 1 to be in a standby state until the set key arranged on the operation unit 5 is pressed. (M9) The CPU 40 determines whether the document sensor 27 is off when the worker removes the white reference document GS and presses the set key. If the CPU 40 determines that the document sensor 27 is off (M9: Yes), it proceeds to a process (M11) of acquiring the ash data GR1. If the CPU 40 determines that the document sensor 27 is on (M9: No), the process proceeds to a process of displaying an error (M10). The CPU 40 causes the display unit 6 to display an error message notifying that the document GS has been erroneously placed (M10), and the maintenance main processing is completed.

CPU40は、灰データGR1を取得する(M11)。具体的には、CPU40は、各色の光量STで灰色基準板34を照射させ、読み取った1ライン分のデジタル画像データを灰データGR1として取得する。   The CPU 40 acquires the ash data GR1 (M11). Specifically, the CPU 40 irradiates the gray reference plate 34 with the light amount ST of each color, and acquires the read digital image data of one line as the gray data GR1.

CPU40は、灰データ最大値GRmaxを取得する(M12)。CPU40は、M11で取得した1ライン分の各色の灰データGR1のうちで、各色の灰データGR1における最大値を灰データ最大値GRmaxとして取得する。CPU40は、この灰データ最大値GRmaxを各色に対応付けてフラッシュPROM43に記憶する。   The CPU 40 acquires the ash data maximum value GRmax (M12). The CPU 40 acquires, as the ash data maximum value GRmax, the maximum value of the ash data GR1 of each color among the ash data GR1 of each color corresponding to one line acquired in M11. The CPU 40 stores the gray data maximum value GRmax in the flash PROM 43 in association with each color.

CPU40は、灰黒差分最大値GBmax1を取得する(M13)。具体的には、CPU40は、各色の灰データGR1から黒データBK1を引算し、1ライン分の灰黒差分データGBdif1を算出する。CPU40は、算出した1ライン分の灰黒差分データGBdif1のうち画素位置Pmaxに存在する灰黒差分データGBdif1を灰黒差分最大値GBmax1として取得する。   The CPU 40 acquires the gray black difference maximum value GBmax1 (M13). Specifically, the CPU 40 subtracts black data BK1 from gray data GR1 of each color to calculate gray-black difference data GBdif1 for one line. The CPU 40 acquires gray-black difference data GBdif1 existing at the pixel position Pmax among the calculated gray-black difference data GBdif1 for one line as the gray-black difference maximum value GBmax1.

CPU40は、光源30を各色の最大光量で点灯させる(M14)。具体的には、CPU40は、各色に対して予め定められている最大電流値と600DPIの読取解像度のときの最大点灯期間とで光源30を点灯する。   The CPU 40 turns on the light source 30 with the maximum light quantity of each color (M14). Specifically, the CPU 40 turns on the light source 30 with the maximum current value predetermined for each color and the maximum lighting period at the reading resolution of 600 DPI.

CPU40は、赤色の灰淡黒差分データLGBdif1をフラッシュPROM43に記憶する(M15)。詳細は後述するが、CPU40は、各色の最大光量で灰色基準板34を照射させて赤色の灰淡データLGR1を取得する。CPU40は、取得した灰淡データLGR1から黒データBK1を引算して灰淡黒差分データLGBdif1を算出する。CPU40は、算出した灰淡黒差分データLGBdif1から埃等に起因して異常な値となった異常画素の値を周辺画素の値と置換する。CPU40は、異常画素のない灰淡黒差分データLGBdif1をフラッシュPROM43に記憶する。M15の処理が終了すると、保守メイン処理が終了する。   The CPU 40 stores the red light gray black difference data LGBdif1 in the flash PROM 43 (M15). Although the details will be described later, the CPU 40 irradiates the gray reference plate 34 with the maximum light amount of each color to acquire red gray light data LGR1. The CPU 40 subtracts the black data BK1 from the obtained light and light data LGR1 to calculate the light and light black difference data LGBdif1. The CPU 40 replaces the value of the abnormal pixel which has become an abnormal value due to dust or the like from the calculated light gray black difference data LGBdif 1 with the value of the peripheral pixel. The CPU 40 stores in the flash PROM 43 the light gray black difference data LGBdif 1 having no abnormal pixel. When the process of M15 ends, the maintenance main process ends.

(灰淡黒差分データ記憶M15)
図6に示す灰淡黒差分データ記憶処理(M15)が開始されると、CPU40は、灰淡データLGR1を取得する(MA1)。具体的には、CPU40は、光源30を各色の最大光量で点灯させた状態で、灰色基準板34を照射し、読み取った1ライン分のうち赤色に対応するデジタル画像データを灰淡データLGR1として取得する。
(Gray gray black difference data storage M15)
When the light gray black difference data storage process (M15) shown in FIG. 6 is started, the CPU 40 acquires gray light data LGR1 (MA1). Specifically, the CPU 40 irradiates the gray reference plate 34 in a state where the light source 30 is lit with the maximum light amount of each color, and sets the digital image data corresponding to red among the read one line as the gray data LGR1. get.

CPU40は、灰淡黒差分データLGBdif1を算出する(MA2)。具体的には、CPU40は、灰淡データLGR1から黒データBK1を引算し、1色分の灰淡黒差分データLGBdif1を算出する。   The CPU 40 calculates light gray black difference data LGBdif1 (MA2). Specifically, the CPU 40 subtracts the black data BK1 from the light / light data LGR1 to calculate gray / black difference data LGBdif1 for one color.

CPU40は、判別データRT1を算出する(MA3)。具体的には、CPU40は、灰淡黒差分データLGBdif1を赤色に対応する白黒差分データWBdifで割算し、1色分の判別データRT1を算出する。   The CPU 40 calculates discrimination data RT1 (MA3). Specifically, the CPU 40 divides the light gray black difference data LGBdif1 by the black-and-white difference data WBdif corresponding to red to calculate the discrimination data RT1 for one color.

CPU40は、チャンネル毎の平均値AVE1を算出する(MA4)。具体的には、CPU40は、1色分の判別データRT1を各チャンネルにおける判別データRT1に分割する。CPU40は、分割した各チャンネルの判別データRT1の平均値をチャンネル毎の平均値AVE1として算出する。   The CPU 40 calculates an average value AVE1 for each channel (MA4). Specifically, the CPU 40 divides the discrimination data RT1 for one color into discrimination data RT1 for each channel. The CPU 40 calculates an average value of the discrimination data RT1 of the divided channels as an average value AVE1 for each channel.

CPU40は、各チャンネルにおける閾値TH1を算出する(MA5)。具体的には、CPU40は、MA4の処理で算出したチャンネル毎の平均値AVE1に保守加算値を加算し、白閾値WTH1を算出する。CPU40は、MA4の処理で算出したチャンネル毎の平均値AVE1から保守減算値を減算し、黒閾値BTH1を算出する。閾値TH1は、白閾値WTH1、または黒閾値BTH1を意味する。ここで、保守加算値と保守減算値とは、本実施形態ではチャンネル毎の平均値AVE1の3%分に相当する値であり、同じ値である。保守加算値と保守減算値とが同じ値であることにより、出力を下げる黒い埃と出力を上げる白い埃とが読取メイン処理で使用する灰淡黒差分データLGBdif1へ与える影響を同程度以内とすることができる。   The CPU 40 calculates the threshold TH1 for each channel (MA5). Specifically, the CPU 40 adds the maintenance addition value to the average value AVE1 for each channel calculated in the process of MA4 to calculate the white threshold value WTH1. The CPU 40 subtracts the maintenance subtraction value from the average value AVE1 for each channel calculated in the process of MA4 to calculate the black threshold BTH1. The threshold TH1 means the white threshold WTH1 or the black threshold BTH1. Here, the maintenance addition value and the maintenance subtraction value are values corresponding to 3% of the average value AVE1 for each channel in the present embodiment, and are the same value. Since the maintenance addition value and the maintenance subtraction value are the same value, the influence of the black dust for reducing the output and the white dust for increasing the output on the light gray black difference data LGBdif1 used in the main processing of reading is made within the same extent. be able to.

CPU40は、対象画素の設定をする(MA6)。具体的には、CPU40は、対象画素が設定されていれば、次の画素を対象画素として設定し、対象画素が設定されていなければ、先頭画素を対象画素として設定する。CPU40は、対象画素の画素番号を取得し、RAM42に記憶する。CPU40は、対象画素が含まれる対象チャンネルのチャンネル番号をRAM42に記憶する。   The CPU 40 sets a target pixel (MA6). Specifically, the CPU 40 sets the next pixel as the target pixel if the target pixel is set, and sets the head pixel as the target pixel if the target pixel is not set. The CPU 40 acquires the pixel number of the target pixel and stores the pixel number in the RAM 42. The CPU 40 stores in the RAM 42 the channel number of the target channel in which the target pixel is included.

CPU40は、対象画素が異常画素か否かを判断する(MA7)。具体的には、CPU40は、対象画素の灰淡黒差分データLGBdif1が対象チャンネルのチャンネル番号に対応する黒閾値BTH1以上であり、且つ対象チャンネルのチャンネル番号に対応する白閾値WTH1以下の範囲内であるか否かを判断する。範囲内にある場合(MA7:No)は、異常画素でないと判断し、対象画素が最終画素か否かを判断する処理(MA11)へ進む。範囲内にない場合(MA7:Yes)は、異常画素であると判断し、異常画素数が設定値以内か否かを判断する処理(MA8)へ進む。   The CPU 40 determines whether the target pixel is an abnormal pixel (MA7). Specifically, the CPU 40 controls the gray-black difference data LGBdif1 of the target pixel to be within the range from the black threshold BTH1 corresponding to the channel number of the target channel to the white threshold WTH1 corresponding to the channel number of the target channel. Determine if there is. If it is in the range (MA7: No), it is determined that the pixel is not an abnormal pixel, and the process proceeds to a process (MA11) of determining whether the target pixel is the final pixel. If not within the range (MA7: Yes), it is determined that the pixel is an abnormal pixel, and the process proceeds to a process (MA8) of determining whether the number of abnormal pixels is within a set value.

CPU40は、異常画素数が設定値以内か否かを判断する(MA8)。具体的には、CPU40は、1ライン中の異常画素数を表わすカウンタCTaに1を加算し、対象チャンネルのチャンネル番号に対応するチャンネル中の異常画素数を表わすカウンタCTbに1を加算する。CPU40は、カウンタCTaがライン上限値(例えば、25画素)を超えたか、またはカウンタCTbがチャンネル上限値(例えば、8画素)を超えたか否かを判断する。どちらか一方を超えた場合(MA8:No)は、異常画素数が設定された値を超えたと判断し、エラーを表示する処理(MA9)へ進む。どちらも越えなかった場合(MA8:Yes)は、異常画素数が設定値以内と判断し、異常画素置換処理(MA10)へ進む。エラーを表示する処理(MA9)では、エラー表示する処理(M9)と同様に、表示部にエラーを表示し、灰淡黒差分データ記憶処理(M14)を終了する。   The CPU 40 determines whether the number of abnormal pixels is within the set value (MA8). Specifically, the CPU 40 adds 1 to the counter CTa indicating the number of abnormal pixels in one line, and adds 1 to the counter CTb indicating the number of abnormal pixels in the channel corresponding to the channel number of the target channel. The CPU 40 determines whether the counter CTa exceeds the line upper limit (for example, 25 pixels) or the counter CTb exceeds the channel upper limit (for example, 8 pixels). If one of them is exceeded (MA8: No), it is determined that the number of abnormal pixels exceeds the set value, and the process proceeds to a process of displaying an error (MA9). If neither exceeds (MA8: Yes), it is determined that the number of abnormal pixels is within the set value, and the process proceeds to abnormal pixel replacement processing (MA10). In the process of displaying an error (MA9), as in the process of displaying an error (M9), an error is displayed on the display unit, and the light gray black difference data storage process (M14) is ended.

CPU40は、対象画素の灰淡黒差分データLGBdif1を周辺画素の灰淡黒差分デ
ータLGBdif1に置き換える(MA10)。具体的には、CPU40は、対象画素の灰淡黒差分データLGBdif1を対象チャンネルのチャンネル番号と同じチャンネルに含まれる画素における灰淡黒差分データLGBdif1で置き換える。
The CPU 40 replaces the light gray black difference data LGBdif1 of the target pixel with the light gray black difference data LGBdif1 of the peripheral pixels (MA10). Specifically, the CPU 40 replaces the light gray black difference data LGBdif1 of the target pixel with the light gray black difference data LGBdif1 in the pixels included in the same channel as the channel number of the target channel.

CPU40は、対象画素が最終画素か否かを判断する(MA11)。具体的には、CPU40は、対象画素の画素番号が最終画素を示す画素番号と一致するか否かを判断し、一致する場合(MA11:Yes)は、MA6で記憶した画素番号とチャンネル番号とを消去し、灰淡黒差分データLGBdif1記憶処理(MA12)へ進む。一致しない場合(MA11:No)は、対象画素設定処理(MA6)へ進む。   The CPU 40 determines whether the target pixel is the final pixel (MA11). Specifically, the CPU 40 determines whether the pixel number of the target pixel matches the pixel number indicating the final pixel, and if they match (MA11: Yes), the pixel number and the channel number stored in MA6 And the light gray black difference data LGBdif1 storage processing (MA12). If they do not match (MA11: No), the process proceeds to the target pixel setting process (MA6).

CPU40は、灰淡黒差分データLGBdif1を記憶する(MA12)。具体的には、CPU40は、MA10において置換された灰淡黒差分データLGBdif1をフラッシュPROM43に記憶する。本処理が終了すると、灰淡黒差分データ記憶処理(M15)が終了する。   The CPU 40 stores the light gray black difference data LGBdif1 (MA12). Specifically, the CPU 40 stores the light gray black difference data LGBdif1 replaced in the MA 10 in the flash PROM 43. When the present process is completed, the light gray black difference data storage process (M15) is completed.

(読取メイン処理)
図7に示す読取メイン処理は、ユーザが原稿GSを給紙トレイ2に載置し、操作部5のカラー読取開始ボタンを押下することにより、開始される。本実施形態の読取メイン処理では、カラーモードにおける説明を行う。
(Reading main processing)
The reading main process shown in FIG. 7 is started by the user placing the document GS on the sheet feeding tray 2 and pressing the color reading start button of the operation unit 5. In the reading main process of the present embodiment, the color mode will be described.

CPU40は、デバイス制御部44、AFE45、および画像処理部46に読取設定値を設定する(R1)。具体的には、CPU40は、600DPIの読取解像度に応じたクロック信号CLKおよびシリアルイン信号SIの設定をフラッシュPROM43から取得し、デバイス制御部44に設定する。CPU40は、カラーモード時の光源30に対する信号の設定をフラッシュPROM43から取得し、デバイス制御部44に設定する。CPU40は、AFE45のオフセット調整値およびゲイン調整値をフラッシュPROM43から取得し、AFE45に設定する。CPU40は、画像処理部46に各種画像処理を施さないように設定する。   The CPU 40 sets reading setting values in the device control unit 44, the AFE 45, and the image processing unit 46 (R1). Specifically, the CPU 40 acquires settings of the clock signal CLK and the serial in signal SI corresponding to the reading resolution of 600 DPI from the flash PROM 43 and sets them in the device control unit 44. The CPU 40 acquires the setting of the signal to the light source 30 in the color mode from the flash PROM 43 and sets it in the device control unit 44. The CPU 40 acquires the offset adjustment value and the gain adjustment value of the AFE 45 from the flash PROM 43 and sets the AFE 45. The CPU 40 sets the image processing unit 46 not to perform various image processing.

CPU40は、光源30の光量を調整する(R2)。CPU40は、灰色基準板34に向けて、光源30から光を照射させ、その反射光を読み取った時のデジタル画像データが灰データ最大値GRmaxとなるとなるように、各色の光量STを調整する。   The CPU 40 adjusts the light amount of the light source 30 (R2). The CPU 40 irradiates light from the light source 30 toward the gray reference plate 34, and adjusts the light intensity ST of each color so that the digital image data when the reflected light is read becomes the gray data maximum value GRmax.

CPU40は、灰データGR2を取得する(R3)。具体的には、CPU40は、各色の光量STで灰色基準板34を照射させ、読み取った1ライン分のデジタル画像データを灰データGR2として取得する。   The CPU 40 acquires ash data GR2 (R3). Specifically, the CPU 40 irradiates the gray reference plate 34 with the light amount ST of each color, and acquires the read digital image data of one line as the gray data GR2.

CPU40は、黒データBK2を取得する(R4)。具体的には、CPU40は、光源30を消灯させ、灰色基準板34を読み取る。そして、読み取った1ラインのうち1色分
のデジタル画像データを黒データBK1として取得する。
The CPU 40 acquires black data BK2 (R4). Specifically, the CPU 40 turns off the light source 30 and reads the gray reference plate 34. Then, digital image data for one color in one read line is acquired as black data BK1.

CPU40は、灰黒差分最大値GBmax2を取得する(R5)。具体的には、CPU40は、各色の灰データGR2から黒データBK2を引算し、1ライン分の灰黒差分データGBdif2を算出する。CPU40は、算出した1ライン分の灰黒差分データGBdif2のうち画素位置Pmaxに存在する灰黒差分データGBdif2を灰黒差分最大値GBmax2として取得する。
CPU40は、光源30を各色の最大光量で点灯する(R6)。具体的には、CPU40は、各色に対して予め定められている最大電流値と600DPIの読取解像度のときの最大点灯期間とで光源30を点灯する。
The CPU 40 acquires the gray black difference maximum value GBmax2 (R5). Specifically, the CPU 40 subtracts black data BK2 from gray data GR2 of each color to calculate gray-black difference data GBdif2 for one line. The CPU 40 acquires gray-black difference data GBdif2 existing at the pixel position Pmax among the calculated gray-black difference data GBdif2 for one line as the gray-black difference maximum value GBmax2.
The CPU 40 turns on the light source 30 with the maximum amount of light of each color (R6). Specifically, the CPU 40 turns on the light source 30 with the maximum current value predetermined for each color and the maximum lighting period at the reading resolution of 600 DPI.

CPU40は、基準データCDを算出する(R7)。詳細は後述するが、CPU40は、各色の最大光量で灰色基準板34を照射させて1ライン分の灰淡データLGR2を取得する。CPU40は、取得した灰淡データLGR2から黒データBK2を引算して灰淡黒差分データLGBdif2を算出する。CPU40は、算出した灰淡黒差分データLGBdif2から埃等に起因して異常な値となった異常画素の値を周辺画素の値と置換する。CPU40は、置換した灰淡黒差分データLGBdif2と、後述する灰白比率GWRTと、後述する灰比率GRRTとを掛算して、基準データCDを算出する。   The CPU 40 calculates reference data CD (R7). Although the details will be described later, the CPU 40 irradiates the gray reference plate 34 with the maximum light amount of each color to acquire gray level data LGR2 for one line. The CPU 40 subtracts the black data BK2 from the obtained light and light data LGR2 to calculate the light and light black difference data LGBdif2. The CPU 40 replaces the value of the abnormal pixel which has become an abnormal value due to dust or the like from the calculated light gray black difference data LGBdif2 with the value of the peripheral pixel. The CPU 40 multiplies the replaced light gray black difference data LGBdif2, the gray / white ratio GWRT described later, and the gray ratio GRRT described later to calculate the reference data CD.

CPU40は、読取処理を実行する(R8)。具体的には、CPU40は、画像処理部46に各種画像処理を施すように設定する。CPU40は、駆動回路47により原稿GSを搬送する。CPU40は、搬送された原稿GSを読み取らせ、R7で算出した基準データCDに基づき各色に対してシェーディング補正を実行させ、さらに各種補正処理を実行させた後、解像度変換処理を実行し、デジタル画像データを生成させる。読取処理(R8)が終了すると、読取メイン処理は終了する。   The CPU 40 executes a reading process (R8). Specifically, the CPU 40 sets the image processing unit 46 to perform various image processing. The CPU 40 causes the drive circuit 47 to transport the document GS. The CPU 40 reads the conveyed document GS, performs shading correction on each color based on the reference data CD calculated in R7, and further executes various correction processing, and then executes resolution conversion processing to obtain a digital image. Generate data. When the reading process (R8) ends, the reading main process ends.

(基準データ算出R7)
図8に示す基準データ算出処理(R7)が開始されると、CPU40は、灰淡データLGR2を取得する(RA1)。具体的には、CPU40は、光源30を各色の最大光量で点灯させた状態で、灰色基準板34を照射し、読み取った1ライン分のデジタル画像データを灰淡データLGR2として取得する。
(Reference data calculation R7)
When the reference data calculation process (R7) shown in FIG. 8 is started, the CPU 40 acquires light gray data LGR2 (RA1). Specifically, the CPU 40 irradiates the gray reference plate 34 in a state in which the light source 30 is lit with the maximum light amount of each color, and acquires the read digital image data for one line as gray-light data LGR2.

CPU40は、灰淡黒差分データLGBdif2を算出する(RA2)。具体的には、CPU40は、各色の灰淡データLGR2から黒データBK2を引算し、1ライン分の灰淡黒差分データLGBdif2を算出する。   The CPU 40 calculates light gray black difference data LGBdif2 (RA2). Specifically, the CPU 40 subtracts the black data BK2 from the gray-light data LGR2 of each color to calculate gray-black difference data LGBdif2 for one line.

CPU40は、判別データRT2を算出する(RA3)。具体的には、CPU40は、灰淡黒差分データLGBdif2を灰淡黒差分データLGBdif1で割算し、1ライン分の判別データRT2を算出する。   The CPU 40 calculates discrimination data RT2 (RA3). Specifically, the CPU 40 divides the light gray black difference data LGBdif2 by the light gray black difference data LGBdif1 to calculate discrimination data RT2 for one line.

CPU40は、チャンネル毎の平均値AVE2を算出する(RA4)。具体的には、CPU40は、1ライン分の各色の判別データRT2を各チャンネルにおける判別データRT2に分割する。CPU40は、各色における分割した各チャンネルの判別データRT2の平均値をチャンネル毎の平均値AVE2として算出する。   The CPU 40 calculates an average value AVE2 for each channel (RA4). Specifically, the CPU 40 divides the discrimination data RT2 of each color for one line into discrimination data RT2 in each channel. The CPU 40 calculates the average value of the discrimination data RT2 of each of the divided channels in each color as the average value AVE2 of each channel.

CPU40は、各色の各チャンネルにおける閾値TH2を算出する(RA5)。具体的には、CPU40は、RA4の処理で算出したチャンネル毎の平均値AVE2に読取加算値を加算し、白閾値WTH2を算出する。CPU40は、RA4の処理で算出したチャンネル毎の平均値AVE2から読取減算値を減算し、黒閾値BTH2を算出する。閾値TH2は、白閾値WTH2、または黒閾値BTH2を意味する。ここで、読取加算値と読取減算値とは、本実施形態ではチャンネル毎の平均値AVE2の5%分に相当する値であり、同じ値である。読取加算値と読取減算値とが同じ値であることにより、出力を下げる黒い埃と出力を上げる白い埃とに起因する読取画質への影響を同程度以内とすることができる。   The CPU 40 calculates a threshold TH2 for each channel of each color (RA5). Specifically, the CPU 40 adds the read addition value to the average value AVE2 for each channel calculated in the process of RA4, and calculates the white threshold value WTH2. The CPU 40 subtracts the read subtraction value from the average value AVE2 for each channel calculated in the process of RA4 to calculate the black threshold BTH2. The threshold TH2 means the white threshold WTH2 or the black threshold BTH2. Here, the read addition value and the read subtraction value are values corresponding to 5% of the average value AVE2 for each channel in the present embodiment, and are the same value. When the read addition value and the read subtraction value are the same value, the influence on the read image quality due to the black dust for reducing the output and the white dust for increasing the output can be made to the same extent or less.

CPU40は、対象画素の設定をする(RA6)。MA6の処理と同様に、具体的には、CPU40は、対象画素が設定されていれば、次の画素を対象画素として設定し、対象画素が設定されていなければ、先頭画素を対象画素として設定する。CPU40は、対象画素の画素番号を取得し、RAM42に記憶する。CPU40は、対象画素が含まれる対象チャンネルのチャンネル番号をRAM42に記憶する。   The CPU 40 sets a target pixel (RA6). As in the process of MA6, specifically, the CPU 40 sets the next pixel as the target pixel if the target pixel is set, and sets the head pixel as the target pixel if the target pixel is not set. Do. The CPU 40 acquires the pixel number of the target pixel and stores the pixel number in the RAM 42. The CPU 40 stores in the RAM 42 the channel number of the target channel in which the target pixel is included.

CPU40は、対象画素が異常画素か否かを判断する(RA7)。具体的には、CPU40は、対象画素の灰淡黒差分データLGBdif2が対象チャンネルのチャンネル番号に対応する黒閾値BTH2以上であり、且つ対象チャンネルのチャンネル番号に対応する白閾値WTH2以下の範囲内であるか否かを判断する。範囲内にある場合(RA7:No)は、異常画素でないと判断し、全画素終了したか否かを判断する処理(RA9)へ進む。範囲内にない場合(RA7:Yes)は、異常画素であると判断し、異常画素置換処理(RA8)へ進む。本処理の判断は、各色における灰淡黒差分データLGBdif2と、その同じ色における黒閾値BTH2と白閾値WTH2とを用いて、チャンネル毎に実行される。   The CPU 40 determines whether the target pixel is an abnormal pixel (RA7). Specifically, the CPU 40 controls the gray-black difference data LGBdif2 of the target pixel to be within the range from the black threshold BTH2 corresponding to the channel number of the target channel to the white threshold WTH2 corresponding to the channel number of the target channel. Determine if there is. If it is in the range (RA7: No), it is determined that the pixel is not an abnormal pixel, and the process proceeds to a process (RA9) of determining whether all the pixels are completed. If it is not within the range (RA7: Yes), it is determined that the pixel is an abnormal pixel, and the process proceeds to abnormal pixel replacement processing (RA8). The determination of this process is performed for each channel using the light gray black difference data LGBdif2 for each color, and the black threshold BTH2 and the white threshold WTH2 for the same color.

CPU40は、対象画素の灰淡黒差分データLGBdif2を周辺画素の灰淡黒差分データLGBdif2に置き換える(RA8)。具体的には、CPU40は、対象画素の灰淡黒差分データLGBdif2を対象チャンネルのチャンネル番号と同じチャンネルに含まれる画素の灰淡黒差分データLGBdif2で置き換える。   The CPU 40 replaces the light gray black difference data LGBdif2 of the target pixel with the light gray black difference data LGBdif2 of the peripheral pixels (RA8). Specifically, the CPU 40 replaces the light gray black difference data LGBdif2 of the target pixel with the light gray black difference data LGBdif2 of the pixel included in the same channel as the channel number of the target channel.

CPU40は、対象画素が最終画素か否かを判断する(RA9)。具体的には、CPU40は、RA6で記憶した画素番号が最終画素を示す画素番号と一致するか否かを判断し、一致する場合(RA9:Yes)は、RA6で記憶した画素番号とチャンネル番号とを消去し、灰淡黒差分最大値LGBmax取得処理(RA10)へ進む。一致しない場合(RA10:No)は、対象画素設定処理(RA6)へ進む。   The CPU 40 determines whether the target pixel is the final pixel (RA9). Specifically, the CPU 40 determines whether the pixel number stored in RA6 matches the pixel number indicating the final pixel, and if they match (RA9: Yes), the pixel number and channel number stored in RA6 And the light gray black difference maximum value LGBmax acquisition processing (RA10). If they do not match (RA10: No), the process proceeds to the target pixel setting process (RA6).

CPU40は、灰淡黒差分最大値LGBmaxを取得する(RA10)。具体的には、CPU40は、RA8で置換した各色の灰淡黒差分データLGBdif2のうち画素位置Pmaxに存在する各色の灰淡黒差分データLGBdif2を各色の灰淡黒差分最大値LGBmaxとして取得する。   The CPU 40 acquires the light gray black difference maximum value LGBmax (RA10). Specifically, the CPU 40 acquires the gray-black difference data LGBdif2 of each color present at the pixel position Pmax among the gray-light black difference data LGBdif2 of each color replaced by RA8 as the gray-black difference maximum value LGBmax of each color.

CPU40は、灰白比率GWRTを算出する(RA11)。具体的には、CPU40は、各画素位置Pmaxにおいて白黒差分最大値WBmaxを灰淡黒差分最大値LGBmaxで割算し、割算して得られた16画素の値の平均値を灰白比率GWRTとして算出する。本処理は、各色に対して行われる。   The CPU 40 calculates the gray-white ratio GWRT (RA11). Specifically, the CPU 40 divides the black-and-white difference maximum value WBmax by the gray-black difference maximum value LGBmax at each pixel position Pmax, and divides the obtained average value of 16 pixels obtained as the gray-white ratio GWRT. calculate. This process is performed for each color.

CPU40は、灰比率GRRTを算出する(RA12)。具体的には、CPU40は、各画素位置Pmaxにおいて灰黒差分最大値GBmax2を灰黒差分最大値GBmax1で割算し、割算して得られた16画素の値の平均値を灰比率GRRTとして算出する。本処理は、各色に対して行われる。   The CPU 40 calculates the ash ratio GRRT (RA12). Specifically, the CPU 40 divides the gray-black difference maximum value GBmax2 by the gray-black difference maximum value GBmax1 at each pixel position Pmax, and divides the obtained average value of 16 pixels obtained as the gray ratio GRRT. calculate. This process is performed for each color.

CPU40は、基準データCDを算出する(RA13)。具体的には、CPU40は、RA8で置換した灰淡黒差分データLGBdif2と、灰白比率GWRTと、灰比率GRRTとを掛算し、1ライン分の各色の基準データCDを算出する。
<実施形態の効果>
本実施形態では、保守メイン処理の白黒差分最大値WBmax取得M7は、赤色に対応する白黒差分データWBdifにおいて大きい値から順に16画素分の白黒差分データWBdifを赤色に対応する白黒差分最大値WBmaxとして取得する。さらに、白黒差分最大値WBmax取得M7は、赤色に対応する白黒差分最大値WBmaxが存在する16画素(言い換えると、画素位置Pmaxの画素)において青色および緑色に対応する白黒差分最大値WBmaxを算出する。よって、白黒差分最大値WBmaxは、各色において同じ画素位置Pmaxで取得されることになり、各色の白黒差分最大値WBmaxのバラツキが低減される。読取メイン処理の基準データ算出R7における灰淡黒差分最大値LGBmax取得RA10は、画素位置Pmaxに存在する灰淡黒差分データLGBdif2を灰淡黒差分最大値LGBmaxとして取得する。よって、灰淡黒差分最大値LGBma
xは、白黒差分最大値WBmaxと同じ画素位置Pmaxで取得されることになり、灰淡黒差分最大値LGBmaxのバラツキが低減される。読取メイン処理の基準データ算出R7における灰白比率GWRT算出RA11は、灰淡黒差分最大値LGBmaxを白黒差分最大値WBmaxで割算することで灰白比率GWRTを算出する。読取メイン処理の基準データ算出R7における基準データCD算出RA13は、灰淡黒差分データLGBdif2と灰白比率GWRTとを掛算し、1ライン分の各色の基準データCDを算出する。よって、灰白比率GWRTは、バラツキが低減された灰淡黒差分最大値LGBmaxと白黒差分最大値WBmaxとから算出されるので、灰白比率GWRTを高精度で算出することができる。基準データCDは、精度良い灰白比率GWRTから算出されるため、基準データCDを高精度で算出することができる。
[実施形態と発明との対応関係]
画像読取装置1、読取部24、および灰色基準板34が、本発明の画像読取装置、読取部、および灰色基準部材の一例である。デバイス制御部44、AFE45、および画像処理部46が、本発明の光量設定部、変換部、および補正部の一例である。CPU40が、本発明の制御部の一例である。黒データBK1取得処理(M5)が、本発明の第1黒データ取得処理の一例である。白データWH取得処理(M4)が、本発明の白データ取得処理の一例である。白黒差分データWBdif算出処理(M6)および白黒差分最大値WBmax取得処理(M7)が、本発明の最大値算出処理の一例である。画素位置Pmax記憶処理(M8)が、本発明の記憶制御処理の一例である。黒データBK2取得処理(R4)が、本発明の第2黒データ取得処理の一例である。灰淡データLGR2取得処理(RA1)が、本発明の灰淡データ取得処理の一例である。灰淡黒差分データLGBdif2算出処理(RA2)が、本発明の灰淡黒差分データ算出処理の一例である。灰白比率GWRT算出処理(RA11)が、本発明の灰白比率算出処理の一例である。基準データCD算出処理(RA13)が、本発明の補正値算出処理の一例である。
The CPU 40 calculates reference data CD (RA13). Specifically, the CPU 40 multiplies the gray-light black difference data LGBdif2 replaced by RA8, the gray-white ratio GWRT, and the gray ratio GRRT to calculate reference data CD of each color for one line.
<Effect of the embodiment>
In the present embodiment, acquisition of the black-and-white difference maximum value WBmax M7 of the maintenance main processing is performed sequentially from the largest value in the black-and-white difference data WBdif corresponding to red as the black-to-white difference maximum WBmax corresponding to red get. Further, the black-and-white difference maximum value WBmax acquisition M7 calculates the black-and-white difference maximum value WBmax corresponding to blue and green in 16 pixels (in other words, the pixel at pixel position Pmax) where the black-and-white difference maximum value WBmax corresponding to red is present. . Therefore, the black-and-white difference maximum value WBmax is obtained at the same pixel position Pmax in each color, and the variation in the black-and-white difference maximum value WBmax of each color is reduced. The gray gray black difference maximum value LGBmax acquisition RA10 in the reference data calculation R7 of the reading main process acquires gray gray black difference data LGBdif2 existing at the pixel position Pmax as the gray gray black difference maximum value LGBmax. Therefore, the light gray black difference maximum value LGBma
Since x is acquired at the same pixel position Pmax as the black and white difference maximum value WBmax, the variation of the light gray black difference maximum value LGBmax is reduced. The gray-white ratio GWRT calculation RA11 in the reference data calculation R7 of the reading main process calculates the gray-white ratio GWRT by dividing the gray light black difference maximum value LGBmax by the black and white difference maximum value WBmax. The reference data CD calculation RA13 in the reference data calculation R7 of the reading main process multiplies the gray light black difference data LGBdif2 and the gray white ratio GWRT to calculate the reference data CD of each color for one line. Therefore, since the gray-white ratio GWRT is calculated from the gray-light black difference maximum value LGBmax and the black-white difference maximum value WBmax in which the variation is reduced, the gray-white ratio GWRT can be calculated with high accuracy. Since the reference data CD is calculated from the accurate gray-white ratio GWRT, the reference data CD can be calculated with high accuracy.
[Correspondence between embodiment and invention]
The image reading device 1, the reading unit 24, and the gray reference plate 34 are examples of the image reading device, the reading unit, and the gray reference member of the present invention. The device control unit 44, the AFE 45, and the image processing unit 46 are examples of the light amount setting unit, the conversion unit, and the correction unit of the present invention. The CPU 40 is an example of the control unit of the present invention. The black data BK1 acquisition process (M5) is an example of the first black data acquisition process of the present invention. White data WH acquisition processing (M4) is an example of white data acquisition processing of the present invention. The monochrome difference data WBdif calculation process (M6) and the monochrome difference maximum value WBmax acquisition process (M7) are examples of the maximum value calculation process of the present invention. The pixel position Pmax storage process (M8) is an example of the storage control process of the present invention. The black data BK2 acquisition process (R4) is an example of the second black data acquisition process of the present invention. The gray-light data LGR2 acquisition process (RA1) is an example of the gray-light data acquisition process of the present invention. The light gray black difference data LGBdif2 calculation processing (RA2) is an example of the light gray black difference data calculation processing of the present invention. The gray-white ratio GWRT calculation process (RA11) is an example of the gray-white ratio calculation process of the present invention. The reference data CD calculation process (RA13) is an example of the correction value calculation process of the present invention.

灰データGR1取得処理(M11)が、本発明の第1灰データ取得処理の一例である。灰黒差分最大値GBmax1取得処理(M13)が、本発明の灰黒差分最大値算出処理の一例である。灰データGR2取得処理(R3)が、本発明の第2灰データ取得処理の一例である。灰黒差分最大値GBmax2取得処理(R5)が、本発明の第2灰黒差分データ算出処理の一例である。灰比率GRRT算出処理(RA12)が、本発明の灰比率算出処理の一例である。   Ash data GR1 acquisition processing (M11) is an example of the 1st ash data acquisition processing of the present invention. The gray-black difference maximum value GBmax1 acquisition process (M13) is an example of the gray-black difference maximum value calculation process of the present invention. Ash data GR2 acquisition processing (R3) is an example of the second ash data acquisition processing of the present invention. The gray-black difference maximum value GBmax2 acquisition process (R5) is an example of the second gray-black difference data calculation process of the present invention. The ash ratio GRRT calculation process (RA12) is an example of the ash ratio calculation process of the present invention.

[変形例]
本発明は、本実施形態に限定されることなく、その趣旨を逸脱しない範囲において種々の変形が可能である。以下にその変形の一例を述べる。
(1)本実施形態の画像読取装置1は、プリンタ部を備えた複合機に適用されても良い。また、本実施形態では、1つの読取部24と、1つの灰色基準板34とが備えられる構成であるが、原稿GSの両面を読み取るために、2つの読取部と、2つの灰色基準板とが備えられる構成でもよい。
(2)本実施形態では、図5に示す保守メイン処理、および図7に示す読取メイン処理の全てがCPU40によって実行される構成であるが、この構成に限定されない。例えば、保守メイン処理のM3〜M8、M11〜M15の一部、および読取メイン処理のR2〜R7の一部が画像処理部46、デバイス制御部44、またはAFE45により実行されてもよい。また、保守メイン処理が、画像読取装置1から独立した外部装置、たとえばコンピュータなどで実行される構成でもよい。
(3)本実施形態では、図5に示す保守メイン処理、および図7に示す読取メイン処理において、カラーモードについて説明を行ったが、モノモードとしてもよい。カラーモードの場合は、3色で1ラインであったが、モノモードの場合は、1色で1ラインとなる。
(4)本実施形態では、画素位置Pmaxとして16画素の画素位置を用いて説明を行ったが、デジタル画像データのバラツキが大きい場合には、16画素よりも大きい画素数を
用いても良いし、デジタル画像データのバラツキが小さい場合には、16画素よりも小さい画素数を用いても良い。16画素の意義は、A4幅である210mmを600DPIで読み取る時の画素数4960画素に対して、許容できない異常画素数として16画素が決定されている。
(5)本実施形態では、図6に示す灰淡黒差分データ記憶(M15)において、赤色の灰淡データLGR1についてのみ説明を行ったが、2色、若しくは3色の灰淡データを用いて、2色、若しくは3色の灰淡黒差分データを記憶させる様に構成しても良い。
[Modification]
The present invention is not limited to the present embodiment, and various modifications can be made without departing from the scope of the present invention. An example of the modification is described below.
(1) The image reading apparatus 1 of the present embodiment may be applied to a multifunction peripheral provided with a printer unit. In the present embodiment, one reading unit 24 and one gray reference plate 34 are provided. However, in order to read both sides of the document GS, two reading units and two gray reference plates are provided. May be provided.
(2) In the present embodiment, although the maintenance main process shown in FIG. 5 and the reading main process shown in FIG. 7 are all executed by the CPU 40, the present invention is not limited to this configuration. For example, the image processing unit 46, the device control unit 44, or the AFE 45 may execute M3 to M8 and a part of M11 to M15 of the maintenance main process and a part of R2 to R7 of the reading main process. Further, the maintenance main process may be executed by an external device independent of the image reading apparatus 1, for example, a computer.
(3) In the present embodiment, the color mode has been described in the maintenance main process shown in FIG. 5 and the reading main process shown in FIG. 7, but it may be a mono mode. In the case of the color mode, one line is provided for three colors, but in the case of the mono mode, one line is provided for one line.
(4) Although the present embodiment has been described using the pixel position of 16 pixels as the pixel position Pmax, if the variation of the digital image data is large, the number of pixels larger than 16 pixels may be used. When the variation of digital image data is small, the number of pixels smaller than 16 pixels may be used. The significance of the 16 pixels is that 16 pixels are determined as an unacceptable number of abnormal pixels with respect to 4960 pixels when the A4 width of 210 mm is read at 600 DPI.
(5) In the present embodiment, only the gray gray data LGR1 of red is described in the gray gray black difference data storage (M15) shown in FIG. 6, but gray light data of two colors or three colors is used It may be configured to store gray-white difference data of two, three or three colors.

1…画像読取装置、5…操作部、24…読取部、30…光源、31…受光部、33…光電変換素子、40…CPU、43…フラッシュPROM、45…AFE、46…画像処理部 DESCRIPTION OF SYMBOLS 1 ... Image reader, 5 ... Operation part, 24 ... Reading part, 30 ... Light source, 31 ... Light reception part, 33 ... Photoelectric conversion element, 40 ... CPU, 43 ... Flash PROM, 45 ... AFE, 46 ... Image processing part

Claims (6)

原稿が搬送される搬送経路に配置され、白色より反射率が低い灰色基準部材と、
原稿が前記灰色基準部材を通過するときに原稿の画像をライン単位で画素毎に読み取るために光源と光電変換素子とを含む読取部と、
予め定められた最大光量値までの範囲において前記光源の光量調整値を設定する光量設定部と、
前記光電変換素子からのアナログ信号をデジタルデータに変換する変換部と、
前記デジタルデータを基準データに基づきシェーディング補正する補正部と、
記憶部と、事前処理を実行した後に、読取前処理を実行する制御部と、を備え、
前記制御部は、
前記事前処理として、
前記光源を消灯したときに前記変換部から出力される1ライン分の第1黒データを取得する第1黒データ取得処理と、
前記光源が白色基準部材を照射するときに前記変換部から出力される1ライン分の白データを取得する白データ取得処理であって、前記白データを取得するときの前記光量調整値は第1光量調整値である前記白データ取得処理と、
同じ画素位置における前記1ライン分の前記白データから前記1ライン分の前記第1黒データを引算して1ライン分の白黒差分データを算出し、前記1ラインの全画素についての白黒差分最大値を算出し、前記白黒差分最大値に対応する特定画素位置を取得する最大値算出処理と、
前記白黒差分最大値と前記特定画素位置とを関連付けて前記記憶部に記憶させる記憶制御処理と、を実行し、
前記読取前処理として、
前記光源を消灯したときに前記変換部から出力される1ライン分の第2黒データを取得する第2黒データ取得処理と、
前記光源が前記最大光量値で前記灰色基準部材を照射するときに前記変換部から出力される1ライン分の灰淡データを取得する灰淡データ取得処理と、
前記1ライン分の前記灰淡データから前記1ライン分の前記第2黒データを引算して1ライン分の灰淡黒差分データを算出する灰淡黒差分データ算出処理と、
前記特定画素位置における前記白黒差分最大値と前記特定画素位置における前記灰淡黒差分データとについて、前記白黒差分最大値を前記灰淡黒差分データで割算することで灰白比率を算出する灰白比率算出処理と、
前記1ライン分の前記灰淡データと前記灰白比率とを掛算して1ライン分の前記基準データを算出する補正値算出処理と、を実行することを特徴とする画像読取装置。
A gray reference member disposed in a conveyance path along which the document is conveyed and having a reflectance lower than that of white;
A reading unit including a light source and a photoelectric conversion element for reading an image of a document on a line-by-line basis as the document passes through the gray reference member;
A light amount setting unit configured to set a light amount adjustment value of the light source in a range up to a predetermined maximum light amount value;
A converter for converting an analog signal from the photoelectric conversion element into digital data;
A correction unit that performs shading correction on the digital data based on reference data;
A storage unit, and a control unit that executes pre-reading processing after performing pre-processing;
The control unit
As the pre-processing,
First black data acquisition processing for acquiring first black data for one line output from the conversion unit when the light source is turned off;
In the white data acquisition processing for acquiring white data of one line output from the conversion unit when the light source irradiates a white reference member, the light amount adjustment value when acquiring the white data is a first value. The white data acquisition process which is the light amount adjustment value;
The first black data of the one line is subtracted from the white data of the one line at the same pixel position to calculate black and white difference data of one line, and the black and white difference maximum for all pixels of the one line A maximum value calculation process of calculating a value and acquiring a specific pixel position corresponding to the black and white difference maximum value;
Performing a storage control process of storing the black-and-white difference maximum value and the specific pixel position in association with each other in the storage unit;
As the pre-reading process,
Second black data acquisition processing for acquiring second black data for one line output from the conversion unit when the light source is turned off;
Gray light data acquisition processing for acquiring gray light data for one line output from the conversion unit when the light source irradiates the gray reference member with the maximum light amount value;
Light gray black difference data calculation processing for calculating gray gray black difference data for one line by subtracting the second black data for the one line from the gray light data for the one line;
The gray-to-white ratio for calculating the gray-white ratio by dividing the black-and-white difference maximum value by the gray-and-white black difference data for the black-and-white difference maximum value at the specific pixel position and the gray-light black difference data at the specific pixel position Calculation processing,
An image reading device that executes correction value calculation processing of calculating the reference data of one line by multiplying the gray-and-light data of the one line and the gray-white ratio;
前記白データは複数の色データから構成され、
前記最大値算出処理は、複数の前記色データのうちの1つの前記色データである特定の色データに対応する前記白黒差分データを用いて前記白黒差分最大値を算出し、複数の前記色データの各色データについて前記白黒差分最大値の画素位置を前記特定画素位置として取得することを特徴とする請求項1に記載の画像読取装置。
The white data is composed of a plurality of color data,
The maximum value calculation process calculates the black and white difference maximum value using the black and white difference data corresponding to specific color data that is one of the plurality of color data and the plurality of color data 2. The image reading apparatus according to claim 1, wherein a pixel position of the maximum value of the black-and-white difference is acquired as the specific pixel position for each color data of.
前記最大値算出処理は、前記白黒差分データのうち大きい順に所定個の画素を前記白黒差分最大値とし、
前記記憶制御処理は、前記所定個の前記白黒差分最大値と前記所定個の特定画素位置とを関連付けて前記記憶部に記憶させ、
前記灰白比率算出処理は、前記所定個の前記特定画素位置における前記白黒差分最大値と前記所定個の前記特定画素位置における前記灰淡黒差分データとについて、前記白黒差分最大値を前記灰淡黒差分データで割算して算出した前記所定個の値の平均値を前記灰白比率とすることを特徴とする請求項1又は請求項2に記載の画像読取装置。
In the maximum value calculation process, a predetermined number of pixels of the black and white difference data in descending order of magnitude are used as the black and white difference maximum value
The storage control processing associates the predetermined number of black and white difference maximum values with the predetermined number of specific pixel positions and causes the storage unit to store the same.
The gray-white ratio calculation process is performed by using the gray-black difference maximum value for the gray-black difference maximum value for the gray-black difference data at the predetermined number of specific pixel positions and the gray-black difference data at the predetermined number of specific pixel positions. The image reading apparatus according to claim 1, wherein an average value of the predetermined number of values calculated by dividing by difference data is set as the gray-white ratio.
前記特定の前記色データは、複数の前記色データのうち前記白黒差分最大値が最も大きい前記色データであることを特徴とする請求項2に記載の画像読取装置。   3. The image reading apparatus according to claim 2, wherein the specific color data is the color data having the largest black-and-white difference maximum value among a plurality of the color data. 複数の前記色データは、赤色、青色、および緑色に対応する前記色データであり、
前記特定の前記色データは、前記赤色に対応する前記色データであることを特徴とする請求項2に記載の画像読取装置。
The plurality of color data are the color data corresponding to red, blue and green,
The image reading apparatus according to claim 2, wherein the specific color data is the color data corresponding to the red color.
原稿が搬送される搬送経路に配置され、白色より反射率が低い灰色基準部材と、
原稿が前記灰色基準部材を通過するときに原稿の画像をライン単位で画素毎に読み取るために光源と光電変換素子とを含む読取部と、
予め定められた最大光量値までの範囲において前記光源の光量調整値を設定する光量設定部と、
前記光電変換素子からのアナログ信号をデジタルデータに変換する変換部と、
前記デジタルデータを基準データに基づきシェーディング補正する補正部と、
記憶部と、事前処理を実行した後に、読取前処理を実行する制御部と、を備え、
前記制御部は、
前記事前処理として、
前記光源を消灯したときに前記変換部から出力される1ライン分の第1黒データを取得する第1黒データ取得処理と、
前記光源が白色基準部材を照射するときに前記変換部から出力される1ライン分の白データを取得する白データ取得処理であって、前記白データを取得するときの前記光量調整値は第1光量調整値である前記白データ取得処理と、
前記光源が前記第1光量調整値で灰色基準部材を照射するときに前記変換部から出力される1ライン分の第1灰データを取得する第1灰データ取得処理と、
同じ画素位置における前記1ライン分の前記白データから前記1ライン分の前記第1黒データを引算して1ライン分の白黒差分データを算出し、前記1ラインの全画素についての白黒差分最大値を算出し、前記白黒差分最大値に対応する特定画素位置を取得する最大値算出処理と、
前記1ライン分の前記第1灰データから前記1ライン分の前記第1黒データを引算して1ライン分の第1灰黒差分データを算出し、前記特定画素位置における前記第1灰黒差分データの灰黒差分最大値を算出する灰黒差分最大値算出処理と、
前記白黒差分最大値と、前記灰黒差分最大値と、前記特定画素位置とを関連付けて前記記憶部に記憶させる記憶制御処理と、を実行し、
前記読取前処理として、
前記光源を消灯したときに前記変換部から出力される1ライン分の第2黒データを取得する第2黒データ取得処理と、
前記光源が前記最大光量値で前記灰色基準部材を照射するときに前記変換部から出力される1ライン分の灰淡データを取得する灰淡データ取得処理と、
前記光源が前記第1光量調整値で前記灰色基準部材を照射するときに前記変換部から出力される1ライン分の第2灰データを取得する第2灰データ取得処理と、
前記1ライン分の前記灰淡データから前記1ライン分の前記第2黒データを引算して1ライン分の灰淡黒差分データを算出する灰淡黒差分データ算出処理と、
前記1ライン分の前記第2灰データから前記1ライン分の前記第2黒データを引算して1ライン分の第2灰黒差分データを算出する第2灰黒差分データ算出処理と、
前記特定画素位置における前記白黒差分最大値と前記特定画素位置における前記灰淡黒差分データとについて、前記白黒差分最大値を前記灰淡黒差分データで割算することで灰白比率を算出する灰白比率算出処理と、
前記特定画素位置における前記灰黒差分最大値と前記特定画素位置における前記第2灰黒差分データとについて、前記第2灰黒差分データを前記灰黒差分最大値で割算すること
で灰比率を算出する灰比率算出処理と、
前記1ライン分の前記灰淡データと前記灰白比率と前記灰比率とを掛算して1ライン分の前記基準データを算出する補正値算出処理と、を実行することを特徴とする画像読取装置。
A gray reference member disposed in a conveyance path along which the document is conveyed and having a reflectance lower than that of white;
A reading unit including a light source and a photoelectric conversion element for reading an image of a document on a line-by-line basis as the document passes through the gray reference member;
A light amount setting unit configured to set a light amount adjustment value of the light source in a range up to a predetermined maximum light amount value;
A converter for converting an analog signal from the photoelectric conversion element into digital data;
A correction unit that performs shading correction on the digital data based on reference data;
A storage unit, and a control unit that executes pre-reading processing after performing pre-processing;
The control unit
As the pre-processing,
First black data acquisition processing for acquiring first black data for one line output from the conversion unit when the light source is turned off;
In the white data acquisition processing for acquiring white data of one line output from the conversion unit when the light source irradiates a white reference member, the light amount adjustment value when acquiring the white data is a first value. The white data acquisition process which is the light amount adjustment value;
First ash data acquisition processing for acquiring first ash data for one line output from the conversion unit when the light source irradiates a gray reference member with the first light amount adjustment value;
The first black data of the one line is subtracted from the white data of the one line at the same pixel position to calculate black and white difference data of one line, and the black and white difference maximum for all pixels of the one line A maximum value calculation process of calculating a value and acquiring a specific pixel position corresponding to the black and white difference maximum value;
The first gray black difference data for one line is calculated by subtracting the first black data for one line from the first gray data for one line, and the first gray black at the specific pixel position is calculated. Gray-black difference maximum value calculation processing for calculating the gray-black difference maximum value of difference data;
Performing a storage control process of storing the black-and-white difference maximum value, the gray-black difference maximum value, and the specific pixel position in the storage unit in association with each other;
As the pre-reading process,
Second black data acquisition processing for acquiring second black data for one line output from the conversion unit when the light source is turned off;
Gray light data acquisition processing for acquiring gray light data for one line output from the conversion unit when the light source irradiates the gray reference member with the maximum light amount value;
A second ash data acquisition process for acquiring one line of second ash data output from the conversion unit when the light source irradiates the gray reference member with the first light amount adjustment value;
Light gray black difference data calculation processing for calculating gray gray black difference data for one line by subtracting the second black data for the one line from the gray light data for the one line;
Second gray-black difference data calculation processing for calculating second gray-black difference data for one line by subtracting the second black data for the one line from the second gray data for the one line;
The gray-to-white ratio for calculating the gray-white ratio by dividing the black-and-white difference maximum value by the gray-and-white black difference data for the black-and-white difference maximum value at the specific pixel position and the gray-light black difference data at the specific pixel position Calculation processing,
The gray ratio is calculated by dividing the second gray black difference data by the gray black difference maximum value for the gray black difference maximum value at the specific pixel position and the second gray black difference data at the specific pixel position. Calculation of the ash ratio to be calculated
An image reading apparatus that executes correction value calculation processing of calculating the reference data of one line by multiplying the gray-and-light data of the one line, the gray-white ratio, and the ash ratio;
JP2015140222A 2014-11-10 2015-07-14 Image reader Active JP6512005B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US14/932,149 US9432552B2 (en) 2014-11-10 2015-11-04 Image scanning apparatus

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2014227756 2014-11-10
JP2014227756 2014-11-10

Publications (2)

Publication Number Publication Date
JP2016096532A JP2016096532A (en) 2016-05-26
JP6512005B2 true JP6512005B2 (en) 2019-05-15

Family

ID=56071596

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2015140222A Active JP6512005B2 (en) 2014-11-10 2015-07-14 Image reader

Country Status (1)

Country Link
JP (1) JP6512005B2 (en)

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5793905B2 (en) * 2011-03-23 2015-10-14 ブラザー工業株式会社 Image reading apparatus and light amount adjustment method thereof

Also Published As

Publication number Publication date
JP2016096532A (en) 2016-05-26

Similar Documents

Publication Publication Date Title
JP6554973B2 (en) Image reading device
US8760741B2 (en) Image scanning device, image forming device, and method for correcting pixel value for pixel corresponding to position of rod lens array joint
JP2019161321A (en) Image reading apparatus and method for controlling image reading apparatus
JP6152819B2 (en) Image reading device
JP6156746B2 (en) Image reading device
JP6558639B2 (en) Image reading device
US8823994B2 (en) Image reading device and image forming apparatus with the same
US11431875B2 (en) Image reading apparatus and image forming apparatus
US9503605B2 (en) Image reader, and method and computer-readable medium therefor
US10750032B2 (en) Image inspection apparatus
JP6512005B2 (en) Image reader
JP6493807B2 (en) Image reading device
US9432552B2 (en) Image scanning apparatus
JP6555166B2 (en) Image reading device
JP6311576B2 (en) Image reading device
JP6152820B2 (en) Image reading device
JP2013085132A (en) Image reader and image forming apparatus equipped with the same
JP2012124562A (en) Image reading device, image reading method, and program thereof
JP6558211B2 (en) Image reading device
JP2012178790A (en) Image reader and image forming apparatus
US10880441B2 (en) Image reading apparatus and shading correction method for switching shading correction based on external light
JP2012151644A (en) Image reader, image formation apparatus provided with image reader, and image processing method
JP2012124560A (en) Image reading device, image reading method, and program thereof
EP3125516B1 (en) Image processing apparatus, image forming apparatus and dew determination method
JP6337800B2 (en) Image reading device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20180529

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20190215

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: 20190312

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20190325

R150 Certificate of patent or registration of utility model

Ref document number: 6512005

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150