JP2016048828A - Information processing device, information processing method, and program - Google Patents
Information processing device, information processing method, and program Download PDFInfo
- Publication number
- JP2016048828A JP2016048828A JP2014172570A JP2014172570A JP2016048828A JP 2016048828 A JP2016048828 A JP 2016048828A JP 2014172570 A JP2014172570 A JP 2014172570A JP 2014172570 A JP2014172570 A JP 2014172570A JP 2016048828 A JP2016048828 A JP 2016048828A
- Authority
- JP
- Japan
- Prior art keywords
- pixel
- image
- color
- brightness
- information processing
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Landscapes
- Character Input (AREA)
- Image Processing (AREA)
- Facsimile Image Signal Circuits (AREA)
- Color Image Communication Systems (AREA)
Abstract
Description
本発明は、情報処理装置、情報処理方法、及びプログラムに関する。 The present invention relates to an information processing apparatus, an information processing method, and a program.
従来、例えばCCD(Charge Coupled Device)などの撮像素子により読み取られた画像データの画質などを補正する技術が各種開発されている。 Conventionally, various techniques for correcting the image quality of image data read by an image pickup device such as a CCD (Charge Coupled Device) have been developed.
例えば、特許文献1には、CCDセンサにより読み取られた帳票のグレースケールの画像データに対して、画素の輝度の頻度分布に基づいて帳票の地色の濃度を検出し、そして、検出した帳票の地色の濃度を基準輝度に一致させるように各画素の輝度を補正する技術が記載されている。 For example, Patent Document 1 discloses that the density of the background color of a form is detected based on the frequency distribution of the luminance of the pixel for grayscale image data of the form read by the CCD sensor, and the detected form of the form is detected. A technique for correcting the luminance of each pixel so that the density of the ground color matches the reference luminance is described.
また、特許文献2には、CCDを構成する各CCD素子による画素信号のシェーディング歪みによる誤差を補正するために、各CCD素子による画素信号の黒レベルと白レベルとが均一になるように補正する技術が記載されている。 Further, in Patent Document 2, in order to correct an error due to shading distortion of a pixel signal by each CCD element constituting the CCD, correction is made so that the black level and the white level of the pixel signal by each CCD element are uniform. The technology is described.
また、特許文献3には、CCDラインセンサから出力されるRGB各チャンネルの出力電圧の各平均値を所定の電圧に一致させる技術が記載されている。 Japanese Patent Application Laid-Open No. 2004-228561 describes a technique for matching each average value of output voltages of RGB channels output from a CCD line sensor to a predetermined voltage.
上述したように、特許文献1に記載の技術は、グレースケール画像に含まれる画素の画素値の分布を補正する技術である。一方、カラー画像は、複数の色成分を有する。従って、特許文献1に記載の技術をカラー画像に対して直接適用することができない。 As described above, the technique described in Patent Document 1 is a technique for correcting the distribution of pixel values of pixels included in a grayscale image. On the other hand, a color image has a plurality of color components. Therefore, the technique described in Patent Document 1 cannot be directly applied to a color image.
そこで、本発明は、上記問題に鑑みてなされたものであり、本発明の目的とするところは、カラー画像に含まれる画素の明るさの分布を補正することが可能な、新規かつ改良された情報処理装置、情報処理方法、及びプログラムを提供することにある。 Accordingly, the present invention has been made in view of the above problems, and an object of the present invention is a new and improved technique capable of correcting the brightness distribution of pixels included in a color image. An information processing apparatus, an information processing method, and a program are provided.
上記課題を解決するために、本発明のある観点によれば、カラー画像に基づいて明度画像を生成する明度画像生成部と、生成された明度画像に含まれる画素の画素値を補正する明度画像補正部と、前記明度画像補正部による補正の結果に基づいて、前記カラー画像に含まれる画素の色成分を補正するカラー画像補正部と、を備える、情報処理装置が提供される。 In order to solve the above-described problem, according to an aspect of the present invention, a brightness image generation unit that generates a brightness image based on a color image, and a brightness image that corrects pixel values of pixels included in the generated brightness image An information processing apparatus is provided that includes: a correction unit; and a color image correction unit that corrects a color component of a pixel included in the color image based on a result of correction by the brightness image correction unit.
前記明度画像は、前記カラー画像に含まれる画素の画素値に応じたグレースケールの画像であってもよい。 The brightness image may be a grayscale image corresponding to a pixel value of a pixel included in the color image.
前記明度画像に含まれる第1の画素の画素値は、前記カラー画像において前記第1の画素に対応する画素の複数の色成分のうち画素値が最も大きい色成分の画素値であってもよい。 The pixel value of the first pixel included in the brightness image may be a pixel value of a color component having the largest pixel value among a plurality of color components of the pixel corresponding to the first pixel in the color image. .
前記カラー画像補正部は、生成された明度画像に含まれる第1の画素の画素値と、前記明度画像補正部により補正された前記第1の画素の画素値との比に基づいて、前記カラー画像において前記第1の画素に対応する画素の色成分を補正してもよい。 The color image correction unit is configured to generate the color based on a ratio between a pixel value of a first pixel included in the generated brightness image and a pixel value of the first pixel corrected by the brightness image correction unit. The color component of the pixel corresponding to the first pixel in the image may be corrected.
前記カラー画像補正部は、生成された明度画像に含まれる前記第1の画素の画素値に対する補正後の前記第1の画素の画素値の割合を、前記カラー画像において前記第1の画素に対応する画素の色成分に乗じることにより、前記カラー画像において前記第1の画素に対応する画素の色成分を補正してもよい。 The color image correction unit corresponds to a ratio of a pixel value of the first pixel after correction to a pixel value of the first pixel included in the generated brightness image, corresponding to the first pixel in the color image. The color component of the pixel corresponding to the first pixel in the color image may be corrected by multiplying the color component of the pixel to be corrected.
前記明度画像補正部は、生成された明度画像に含まれる第1の画素の画素値を前記第1の画素の周囲の複数の画素の画素値に基づいて補正してもよい。 The brightness image correction unit may correct the pixel values of the first pixels included in the generated brightness image based on the pixel values of a plurality of pixels around the first pixels.
前記明度画像補正部は、さらに、前記第1の画素の画素値を、前記第1の画素の周囲の複数の画素との間の距離に基づいて補正してもよい。 The brightness image correction unit may further correct the pixel value of the first pixel based on distances between a plurality of pixels around the first pixel.
前記カラー画像に含まれる画素の色成分は、前記カラー画像に含まれる画素のRGBの各色成分であってもよい。 The color components of the pixels included in the color image may be RGB color components of the pixels included in the color image.
また、上記課題を解決するために、本発明の別の観点によれば、カラー画像に基づいて明度画像を生成するステップと、生成された明度画像に含まれる画素の画素値を補正するステップと、前記補正の結果に基づいて、前記カラー画像に含まれる画素の色成分を補正するステップと、を備える、情報処理方法が提供される。 In order to solve the above problem, according to another aspect of the present invention, a step of generating a brightness image based on a color image, and a step of correcting pixel values of pixels included in the generated brightness image, And a step of correcting a color component of a pixel included in the color image based on the result of the correction.
また、上記課題を解決するために、本発明の別の観点によれば、コンピュータを、カラー画像に基づいて明度画像を生成する明度画像生成部と、生成された明度画像に含まれる画素の画素値を補正する明度画像補正部と、前記明度画像補正部による補正の結果に基づいて、前記カラー画像に含まれる画素の色成分を補正するカラー画像補正部、として機能させるための、プログラムが提供される。 In order to solve the above-described problem, according to another aspect of the present invention, a computer includes a brightness image generation unit that generates a brightness image based on a color image, and pixels of pixels included in the generated brightness image. A program is provided for functioning as a brightness image correction unit that corrects a value, and a color image correction unit that corrects a color component of a pixel included in the color image based on a correction result by the brightness image correction unit. Is done.
以上説明したように本発明によれば、カラー画像に含まれる画素の明るさの分布を補正することができる。 As described above, according to the present invention, the distribution of brightness of pixels included in a color image can be corrected.
以下に添付図面を参照しながら、本発明の好適な実施の形態について詳細に説明する。なお、本明細書及び図面において、実質的に同一の機能構成を有する構成要素については、同一の符号を付することにより重複説明を省略する。 Exemplary embodiments of the present invention will be described below in detail with reference to the accompanying drawings. In addition, in this specification and drawing, about the component which has the substantially same function structure, duplication description is abbreviate | omitted by attaching | subjecting the same code | symbol.
また、本明細書及び図面において、実質的に同一の機能構成を有する複数の構成要素を、同一の符号の後に異なるアルファベットを付して区別する場合もある。例えば、実質的に同一の機能構成を有する複数の構成を、必要に応じて画素300aおよび画素300bのように区別する。ただし、実質的に同一の機能構成を有する複数の構成要素の各々を特に区別する必要がない場合、同一符号のみを付する。例えば、画素300aおよび画素300bを特に区別する必要が無い場合には、単に画素300と称する。
In the present specification and drawings, a plurality of components having substantially the same functional configuration may be distinguished by adding different alphabets after the same reference numeral. For example, a plurality of configurations having substantially the same functional configuration are distinguished as
また、以下に示す項目順序に従って当該「発明を実施するための形態」を説明する。
1.背景
2.実施形態の詳細な説明
2−1.情報処理システム
2−2.構成
2−3.動作
2−4.効果
3.ハードウェア構成
4.変形例
Further, the “DETAILED DESCRIPTION OF THE INVENTION” will be described according to the following item order.
1. Background 2 2. Detailed description of embodiments 2-1. Information processing system 2-2. Configuration 2-3. Operation 2-4. Effect 3. Hardware configuration Modified example
<<1.背景>>
本発明は、一例として「2.実施形態の詳細な説明」において詳細に説明するように、多様な形態で実施され得る。最初に、本発明の特徴を明確に示すために、本発明による情報処理装置を創作するに至った背景について説明する。
<< 1. Background >>
The present invention can be implemented in various forms as will be described in detail in “2. Detailed Description of Embodiments” as an example. First, in order to clearly show the features of the present invention, the background that led to the creation of the information processing apparatus according to the present invention will be described.
従来、グレースケール画像に含まれる画素の画素値を補正するための技術が各種開発されている。例えば、画像データに含まれる画素の明るさが低い領域に対して、周辺の領域の画素の画素値に基づいて影補正を行う技術が開発されている。なお、画素値とは、撮像素子により、物体からの反射光などの光強度が各画素の位置において量子化された値である。また、画素値は、例えば0〜255までの256段階で表現される。 Conventionally, various techniques for correcting pixel values of pixels included in a grayscale image have been developed. For example, a technique has been developed in which shadow correction is performed on an area where the brightness of pixels included in image data is low based on the pixel values of pixels in the surrounding area. The pixel value is a value obtained by quantizing light intensity such as reflected light from an object at the position of each pixel by the image sensor. The pixel value is expressed in 256 levels from 0 to 255, for example.
ところで、グレースケール画像は、一つの色成分のみを有するのに対して、カラー画像は、例えばRGBなどの複数の色成分を有する。このため、カラー画像に対して上記の影補正の技術を直接適用することはできない。そこで、上記の影補正の技術を適用するためには、複数の色成分を一つの成分に変換する必要がある。変換方法の例としては、例えば、複数の色成分の平均値を算出することによる変換方法、または複数の色成分のうち最大値と最小値との平均値を算出することによる変換方法が考えられる。 By the way, the gray scale image has only one color component, whereas the color image has a plurality of color components such as RGB. Therefore, the above-described shadow correction technique cannot be directly applied to a color image. Therefore, in order to apply the above-described shadow correction technique, it is necessary to convert a plurality of color components into one component. As an example of the conversion method, for example, a conversion method by calculating an average value of a plurality of color components, or a conversion method by calculating an average value of a maximum value and a minimum value among a plurality of color components can be considered. .
しかしながら、仮にこれらの変換方法をカラー画像に対して適用し、そして影補正を行った場合には、いずれかの色成分の補正後の値が例えば255などの上限値より大きくなる、つまり飽和してしまう恐れがある。 However, if these conversion methods are applied to a color image and shadow correction is performed, the corrected value of any color component is larger than an upper limit value such as 255, that is, saturated. There is a risk that.
そこで、上記事情を一着眼点にして本発明による情報処理装置を創作するに至った。本発明による情報処理装置は、カラー画像に含まれる画素の明るさの分布を適切に補正することが可能である。以下、このような本発明の実施形態について順次詳細に説明する。 Therefore, the information processing apparatus according to the present invention has been created by focusing on the above circumstances. The information processing apparatus according to the present invention can appropriately correct the distribution of brightness of pixels included in a color image. Hereinafter, such embodiments of the present invention will be sequentially described in detail.
<<2.実施形態の詳細な説明>>
<2−1.情報処理システムの構成>
まず、本実施形態による情報処理システムの構成について図1を参照して説明する。図1に示したように、本実施形態による情報処理システムは、情報処理装置10、スキャナ20、および通信網22を含む。
<< 2. Detailed Description of Embodiment >>
<2-1. Configuration of information processing system>
First, the configuration of the information processing system according to the present embodiment will be described with reference to FIG. As shown in FIG. 1, the information processing system according to the present embodiment includes an
[2−1−1.情報処理装置10]
情報処理装置10は、カラー画像に対して画像処理を行うための装置である。例えば、情報処理装置10は、後述するスキャナ20から受信されるカラー画像に対して、影の補正処理を行うことが可能である。また、情報処理装置10は、OCR(Optical Character Recognition)により、画像に含まれる文字を認識することが可能である。この情報処理装置10は、例えばPC(Personal Computer)や、サーバなどであってもよい。
[2-1-1. Information processing apparatus 10]
The
[2−1−2.スキャナ20]
スキャナ20は、紙媒体を光学的に読み取り、デジタル静止画像として記録するための装置である。例えば、スキャナ20は、紙媒体に光を当て、その反射光を撮像素子で電気信号に変換することにより、紙媒体をデジタル画像として記録する。このスキャナ20は、図1に示したように、例えば非接触型であってもよい。
[2-1-2. Scanner 20]
The
[2−1−3.通信網22]
通信網22は、通信網22に接続されている装置から送信される情報の有線、または無線の伝送路である。例えば、通信網22は、電話回線網、インターネット、衛星通信網などの公衆回線網や、Ethernet(登録商標)を含む各種のLAN(Local Area Network)、WAN(Wide Area Network)などを含む。また、通信網22は、IP−VPN(Internet Protocol−Virtual Private Network)などの専用回線網を含んでもよい。
[2-1-3. Communication network 22]
The
<2−2.構成>
以上、本実施形態による情報処理システムの構成について説明した。次に、本実施形態による情報処理装置10の構成について、図2を参照して説明する。図2に示したように、情報処理装置10は、制御部100、通信部120、および記憶部122を有する。
<2-2. Configuration>
The configuration of the information processing system according to this embodiment has been described above. Next, the configuration of the
[2−2−1.制御部100]
制御部100は、情報処理装置10に内蔵される、後述するCPU(Central Processing Unit)150、RAM(Random Access Memory)154などのハードウェアを用いて、情報処理装置10の動作を全般的に制御する。また、図2に示したように、制御部100は、明度画像生成部102、明度画像補正部104、カラー画像補正部106、OCR用画像生成部108、およびOCR処理部110を有する。
[2-2-1. Control unit 100]
The
[2−2−2.明度画像生成部102]
明度画像生成部102は、後述する通信部120により受信されるカラー画像に基づいてグレースケールの明度画像を生成する。ここで、明度とは、各画素の色の明るさを示す指標であり、例えばマンセル表色系において定義される明度と同義であってもよい。また、明度は、例えば0〜255までの256段階で表現される。
[2-2-2. Lightness image generation unit 102]
The lightness
より具体的には、明度画像生成部102は、カラー画像の各画素に関して、当該画素のRGBの各成分の画素値に応じた値を、明度画像における同じ位置の画素の画素値に設定することにより、明度画像を生成する。例えば、明度画像生成部102は、カラー画像の各画素に関して、当該画素のRGBの各色成分の画素値のうち最も大きい画素値を、明度画像における同じ位置の画素の画素値に設定することにより、明度画像を生成する。
More specifically, for each pixel of the color image, the brightness
ここで、図3を参照して、上記の機能についてより詳細に説明する。図3は、明度画像生成部102による明度画像の生成例を示した説明図である。なお、図3では、簡略的に、カラー画像30が、画素300を4個だけ含む例を図示している。また、図3では、各画素300のRGBの各色成分の画素値を数字で示している。例えば、画素300aにおけるR成分の画素値は「100」であり、G成分の画素値は「20」であり、B成分の画素値は「80」である。
Here, the above function will be described in more detail with reference to FIG. FIG. 3 is an explanatory view showing an example of generation of a brightness image by the brightness
図3に示したように、明度画像生成部102は、画素300aにおけるRGBの各色成分の画素値のうち最も大きい画素値である「100」を、明度画像40における(位置が同じである)画素400aの画素値に設定する。
As illustrated in FIG. 3, the lightness
[2−2−3.明度画像補正部104]
明度画像補正部104は、明度画像生成部102により生成された明度画像に対して画素値の補正処理を行う。より具体的には、明度画像補正部104は、生成された明度画像の各画素に関して、当該画素の周囲の複数の画素の画素値に基づいて、当該画素の画素値を補正する。例えば、明度画像補正部104は、以下で述べるような、特開2002−15313に記載の方法と概略同様の方法により、生成された明度画像の各画素の画素値を補正する。
[2-2-3. Brightness Image Correction Unit 104]
The lightness
(2−2−3−1.補正例1)
例えば、明度画像補正部104は、生成された明度画像における画素値の頻度分布に基づいて帳票の地色の画素値(以下、Pとも称する)を検出し、そして、各画素の画素値とPとの比に基づいて各画素の画素値を補正する。
(2-2-3-1. Correction Example 1)
For example, the lightness
ここで、上記の機能についてより詳細に説明する。図4は、補正前の明度画像に含まれる各画素の画素値の頻度分布を示したグラフである。図4に示したように、明度画像補正部104は、まず、白レベルに近く、かつ頻度が最大の画素値をPとして検出する。そして、明度画像補正部104は、補正前の明度画像の各画素の画素値の大きさによって、各画素の画素値(以下、kとも称する)を以下のように補正する。
Here, the above function will be described in more detail. FIG. 4 is a graph showing a frequency distribution of pixel values of each pixel included in the brightness image before correction. As shown in FIG. 4, the lightness
‐k≦Pの場合
kの値が上記の範囲に含まれる場合には、明度画像補正部104は、各画素に関して、まず、kとPとの比(=k/P)を例えばリニア補正やガンマ補正により変換する。そして、明度画像補正部104は、変換した値に対して基準画素値(以下、Mとも称する)を乗算することにより、kの値を補正する。なお、Mは、例えば「230」などの所定の値である。
When -k ≦ P When the value of k is included in the above range, the brightness
‐P<k≦255−M+Pの場合
また、kの値が上記の範囲に含まれる場合には、明度画像補正部104は、kに対して(M−P)だけ加算することにより、kの値を補正する。つまり、補正後の各画素の画素値をKとおくと、明度画像補正部104は、以下の数式により補正を行う。
K=k+M−P
When −P <k ≦ 255−M + P Also, when the value of k is included in the above range, the lightness
K = k + MP
‐k>255−M+Pの場合
また、kの値が上記の範囲に含まれる場合には、明度画像補正部104は、kの値を一律「255」、つまり上限値に補正する。
-K> 255-M + P When the value of k is included in the above range, the lightness
この補正例1によれば、図4に示した明度画像の画素値の頻度分布が、例えば図5に示したグラフのように、画素値がPである画素の画素値がMになるように補正される。つまり、明度画像の画素値の分布を、所定のレベルまで高めるように補正することができる。 According to this correction example 1, the frequency distribution of the pixel values of the brightness image shown in FIG. 4 is set so that the pixel value of a pixel whose pixel value is P is M, for example, as in the graph shown in FIG. It is corrected. That is, the pixel value distribution of the brightness image can be corrected to be increased to a predetermined level.
(2−2−3−2.補正例2)
または、明度画像補正部104は、補正前の明度画像における各画素に関して、当該画素の周囲の複数の画素の画素値、および当該画素と当該複数の画素の各々との間の距離に基づいて、当該画素の画素値を補正する。
(2-2-3-2. Correction Example 2)
Alternatively, the brightness
例えば、明度画像補正部104は、まず、生成された明度画像を縦m(例えば、100)画素、横n(例えば、100)画素からなる矩形の画像ブロックに分割する。そして、明度画像補正部104は、分割した各画像ブロックに含まれる画素の画素値のうち最大の画素値と、各画像ブロックの中心座標(X,Y)とを対応づけて、後述するブロック画像テーブル124に記録する。これにより、各画像ブロックの中心座標の画素値には、各画像ブロックに含まれる画素の画素値のうち最大の画素値が設定される。
For example, the lightness
そして、明度画像補正部104は、補正前の明度画像における各画素に関して、例えば図6に示したように、当該画素を取り囲む4個の画像ブロックの中心座標P1、P2、P3、およびP4に設定された画素値、および当該画素とこれら4点の各々との間の距離の比率に基づいて、例えば以下の数式1により当該画素の画素値を補正する。
Then, the brightness
なお、図6に示したように、上記の数式1におけるXaはP1およびP2のx座標値であり、XbはP3およびP4のx座標値であり、YaはP1およびP3のy座標値であり、また、YbはP2およびP4のy座標値である。 As shown in FIG. 6, Xa in Equation 1 above is the x coordinate value of P1 and P2, Xb is the x coordinate value of P3 and P4, and Ya is the y coordinate value of P1 and P3. Yb is the y coordinate value of P2 and P4.
また、図7は、ブロック画像テーブル124の構成例を示した説明図である。図7に示したように、ブロック画像テーブル124では、例えば、ブロックNo1240、中心座標1242、および画素値1244が対応づけて記録される。ここで、ブロックNo1240には、明度画像から分割された各画像ブロックを区別するための識別番号が記録される。また、中心座標1242には、ブロックNo1240に対応する画像ブロックの中心の座標値が記録される。また、画素値1244には、ブロックNo1240に対応する画像ブロックに含まれる画素の画素値のうち最大の画素値が記録される。なお、上述したように、中心座標1242の座標値を有する画素の画素値には、画素値1244の値が設定される。
FIG. 7 is an explanatory diagram showing a configuration example of the block image table 124. As shown in FIG. 7, in the block image table 124, for example, block No. 1240, center coordinates 1242, and
この補正例2によれば、各画像ブロックに含まれる画素は、当該画素の周囲の画像ブロックとの間の距離、および画像ブロック間の(最大の)画素値の差に応じた補正量により画素値が補正される。このため、例えば局所的な影などを、見た目に自然になるように、滑らかに補正することができる。 According to this correction example 2, the pixels included in each image block are pixels with a correction amount corresponding to the distance between the image blocks around the pixel and the (maximum) pixel value difference between the image blocks. The value is corrected. For this reason, for example, a local shadow can be smoothly corrected so as to be natural to the eye.
なお、変形例として、明度画像補正部104は、補正例1と補正例2とを組み合わせることにより、生成された明度画像の各画素を補正することも可能である。例えば、明度画像補正部104は、まず、生成された明度画像の各画素に対して補正例2により補正を行い、そして、補正後の明度画像に対して補正例1によりさらに補正してもよい。
As a modification, the lightness
[2−2−4.カラー画像補正部106]
カラー画像補正部106は、受信されたカラー画像の各画素に関して、明度画像生成部102により生成された明度画像における同じ画素の画素値と、明度画像補正部104により補正された当該画素の画素値との比に基づいて、カラー画像における当該画素のRGBの各色成分の画素値を補正する。例えば、カラー画像補正部106は、以下の数式2のように、カラー画像の各画素に関して、補正前の明度画像における同じ画素の画素値に対する補正後の明度画像における当該画素の画素値の割合を、カラー画像における当該画素の各色成分の画素値に乗じることにより、各画素の各色成分の画素値を補正する。
[2-2-4. Color image correction unit 106]
For each pixel of the received color image, the color
なお、上記の数式では、補正前のカラー画像における画素(i,j)のRGBの各色成分の画素値を「R」、「G」、または「B」と記載し、また、補正後のカラー画像における画素(i,j)のRGBの各色成分の画素値を「R'」、「G'」、または「B'」と記載している。 In the above formula, the pixel value of each RGB color component of the pixel (i, j) in the color image before correction is described as “R”, “G”, or “B”, and the color after correction The pixel value of each RGB color component of the pixel (i, j) in the image is described as “R ′”, “G ′”, or “B ′”.
ここで、図8を参照して、上記の機能についてより詳細に説明する。図8は、カラー画像補正部106によるカラー画像の補正例を示した説明図である。図8において画素320aに示したように、カラー画像補正部106は、補正前のカラー画像30における画素300aに含まれるR成分の画素値を、「100(画素300aのR成分)×120(補正後の明度画像42の画素420aの画素値)/100(補正前の明度画像40の画素400aの画素値)」により「120」と補正する。同様に、カラー画像補正部106は、画素300aのG成分の画素値を、「20(画素300aのG成分)×120(画素420aの画素値)/100(画素400aの画素値)」により「24」と補正する。また、カラー画像補正部106は、画素300aのB成分の画素値を、「80(画素300aのB成分)×120(画素420aの画素値)/100(画素400aの画素値)」により「96」と補正する。
Here, the above function will be described in more detail with reference to FIG. FIG. 8 is an explanatory diagram showing an example of color image correction by the color
[2−2−5.OCR用画像生成部108]
OCR用画像生成部108は、カラー画像補正部106により補正されたカラー画像に基づいて、2値画像であるOCR用画像を生成する。
[2-2-5. OCR image generation unit 108]
The OCR
より具体的には、OCR用画像生成部108は、まず、カラー画像補正部106により補正されたカラー画像に基づいてグレースケール画像を生成する。例えば、OCR用画像生成部108は、カラー画像補正部106により補正されたカラー画像の各画素に関して、例えば以下の数式3のように、当該画素に含まれるRGB色成分から輝度(以下、Yとも称する)を算出し、そして、算出した輝度をグレースケール画像における当該画素の画素値に設定することにより、グレースケール画像を生成する。
More specifically, the OCR
そして、OCR用画像生成部108は、生成されたグレースケール画像を例えば所定の閾値により2値化することにより、OCR用画像を生成する。
Then, the OCR
[2−2−6.OCR処理部110]
OCR処理部110は、OCR用画像生成部108により生成されたOCR用画像に対して文字認識を行う。
[2-2-6. OCR processing unit 110]
The
[2−2−7.通信部120]
通信部120は、通信網22を介して、他の装置との間で情報の送受信を行う。例えば、通信部120は、スキャナ20により読み取られたカラー画像をスキャナ20から受信する。
[2-2-7. Communication unit 120]
The
[2−2−8.記憶部122]
記憶部122は、例えば、明度画像生成部102により生成された明度画像や、カラー画像補正部106により補正されたカラー画像など、各種のデータを記憶することが可能である。
[2-2-8. Storage unit 122]
The
なお、本実施形態による情報処理装置10の構成は、上述した構成に限定されない。例えば、情報処理装置10は、液晶ディスプレイ(LCD:Liquid Crystal Display)装置などから構成され、表示画面を表示する表示部をさらに備えてもよい。また、情報処理装置10は、キーボードやマウスなどから構成され、ユーザからの入力を受け付ける入力部をさらに備えてもよい。また、情報処理装置10は、OCR用画像生成部108、およびOCR処理部110を含まなくてもよい。
Note that the configuration of the
<2−3.動作>
以上、本実施形態による構成について説明した。続いて、本実施形態による動作について説明する。
<2-3. Operation>
The configuration according to this embodiment has been described above. Subsequently, an operation according to the present embodiment will be described.
図9は、本実施形態による動作を示したフローチャートである。図9に示したように、まず、情報処理装置10の通信部120は、スキャナ20により読み取られたカラー画像をスキャナ20から受信する(S101)。
FIG. 9 is a flowchart showing the operation according to the present embodiment. As shown in FIG. 9, first, the
続いて、明度画像生成部102は、カラー画像の各画素に関して、当該画素のRGBの各色成分の画素値のうち最も大きい画素値を、明度画像における同じ位置の画素の画素値に設定することにより、明度画像を生成する(S102)。
Subsequently, the brightness
続いて、明度画像補正部104は、S102で生成された明度画像に対して、例えば特開2002−15313号公報に記載の方法と概略同様の方法により、影の補正処理を行う(S103)。
Subsequently, the brightness
続いて、カラー画像補正部106は、S101で受信されたカラー画像の各画素に関して、S102で生成された明度画像における同じ画素の画素値に対するS103で補正された当該画素の画素値の割合を、カラー画像における当該画素のRGBの各色成分の画素値に乗じることにより、カラー画像の各画素のRGBの各色成分の画素値を補正する(S104)。
Subsequently, for each pixel of the color image received in S101, the color
続いて、OCR用画像生成部108は、S104で補正されたカラー画像に基づいて、グレースケール画像を生成する(S105)。そして、OCR用画像生成部108は、生成したグレースケール画像を2値化することにより、OCR用画像を生成する(S106)。
Subsequently, the OCR
その後、OCR処理部110は、S106で生成されたOCR用画像に対して文字認識を行う(S107)。
Thereafter, the
<2−4.効果>
以上、例えば図2、および図9等を参照して説明したように、本実施形態による情報処理装置10は、カラー画像に基づいてグレースケールの明度画像を生成し、生成された明度画像の各画素の画素値を補正し、そして、明度画像に対する補正の結果に基づいて、カラー画像の各画素の各色成分を補正する。このため、カラー画像の各画素の明るさを示す明度画像に対して行った補正の結果をカラー画像の各画素の各色成分に直接反映させるので、カラー画像の各画素の明るさの分布を補正することができる。
<2-4. Effect>
As described above, for example, as described with reference to FIGS. 2 and 9, the
例えば、情報処理装置10は、カラー画像の各画素のRGBの各色成分の画素値のうち最も大きい画素値を、明度画像における各画素の画素値に設定する。そして、情報処理装置10は、カラー画像の各画素に関して、補正前の明度画像における同じ画素の画素値に対する補正後の明度画像における当該画素の画素値の割合を、カラー画像の当該画素の各色成分の画素値に乗じることにより、カラー画像の各画素の各色成分を補正する。
For example, the
このため、補正後のカラー画像の各画素のRGBの各色成分の画素値は上限値以下になり、飽和することがない。従って、補正により色ずれが生じることがなく、また、色あいが補正前のカラー画像から変化することがない。 For this reason, the pixel value of each color component of RGB of each pixel of the color image after correction becomes equal to or lower than the upper limit value and does not become saturated. Therefore, no color shift occurs due to the correction, and the hue does not change from the color image before the correction.
また、情報処理装置10は、明度画像に対して上述した影補正処理を行うことにより、カラー画像に含まれる動的な影を精度高く補正することができる。一般的に、スキャナ20が、図1に示したような非接触型である場合には、上部が蓋などで覆われておらず、ユーザが紙媒体をスキャンする際に例えば手の影などの動的な影が入りやすい。このため、カラー画像が非接触型のスキャナ20により撮影された画像である場合に特に有効である。
The
このように本実施形態によれば、補正前のカラー画像における色あいを保ったまま、カラー画像に含まれる影を精度高く補正することができるので、カラー画像の視認性を向上させることができる。また、同様の理由により、例えば補正前のカラー画像に基づいてOCR処理を行う場合と比較して、OCR処理における文字の認識率を向上させることができる。 As described above, according to the present embodiment, it is possible to correct the shadow included in the color image with high accuracy while maintaining the color tone in the color image before correction, so that the visibility of the color image can be improved. For the same reason, for example, the character recognition rate in the OCR processing can be improved as compared with the case where the OCR processing is performed based on the color image before correction.
<<3.ハードウェア構成>>
次に、本実施形態による情報処理装置10のハードウェア構成について、図10を参照して説明する。図10に示したように、情報処理装置10は、CPU150、ROM(Read Only Memory)152、RAM154、内部バス156、入出力インターフェース158、HDD(Hard Disk Drive)160、およびネットワークインターフェース162を備える。
<< 3. Hardware configuration >>
Next, the hardware configuration of the
<3−1.CPU150>
CPU150は、演算処理装置および制御装置として機能し、各種プログラムに従って情報処理装置10内の動作全般を制御する。また、CPU150は、情報処理装置10において制御部100の機能を実現する。なお、CPU150は、マイクロプロセッサなどのプロセッサにより構成される。
<3-1.
The
<3−2.ROM152>
ROM152は、CPU150が使用するプログラムや演算パラメータ等を記憶する。
<3-2. ROM152>
The
<3−3.RAM154>
RAM154は、CPU150の実行において使用するプログラムや、その実行において適宜変化するパラメータ等を一時記憶する。
<3-3. RAM154>
The
<3−4.内部バス156>
内部バス156は、CPUバスなどから構成される。この内部バス156は、CPU150、ROM152、およびRAM154を相互に接続する。
<3-4.
The
<3−5.入出力インターフェース158>
入出力インターフェース158は、HDD160、およびネットワークインターフェース162を、内部バス156と接続する。例えばHDD160は、この入出力インターフェース158および内部バス156を介して、RAM154などとの間でデータをやり取りする。
<3-5. Input /
The input /
<3−6.HDD160>
HDD160は、記憶部122として機能する、データ格納用の装置である。このHDD160は、例えば、記憶媒体、記憶媒体にデータを記録する記録装置、記憶媒体からデータを読み出す読出し装置、および記憶媒体に記録されたデータを削除する削除装置などを含む。また、HDD160は、CPU150が実行するプログラムや各種データを格納する。
<3-6.
The
<3−7.ネットワークインターフェース162>
ネットワークインターフェース162は、例えばインターネットなどの通信網に接続するための通信デバイス等で構成された通信インターフェースである。このネットワークインターフェース162は、通信部120として機能する。なお、ネットワークインターフェース162は、無線LAN対応通信装置、LTE(Long Term Evolution)対応通信装置、または有線による通信を行うワイヤー通信装置であってもよい。
<3-7.
The
<<4.変形例>>
以上、添付図面を参照しながら本発明の好適な実施形態について詳細に説明したが、本発明はかかる例に限定されない。本発明の属する技術の分野における通常の知識を有する者であれば、特許請求の範囲に記載された技術的思想の範疇内において、各種の変更例または修正例に想到し得ることは明らかであり、これらについても、当然に本発明の技術的範囲に属するものと了解される。
<< 4. Modification >>
The preferred embodiments of the present invention have been described in detail above with reference to the accompanying drawings, but the present invention is not limited to such examples. It is obvious that a person having ordinary knowledge in the technical field to which the present invention pertains can come up with various changes or modifications within the scope of the technical idea described in the claims. Of course, it is understood that these also belong to the technical scope of the present invention.
<4−1.変形例1>
例えば、上記の説明では、カラー画像補正部106が、カラー画像の各画素に含まれる全ての色成分の画素値を補正する例を中心として説明したが、かかる例に限定されない。例えば、カラー画像補正部106は、カラー画像の各画素のRGBの各色成分のうちいずれか1つだけ、または、いずれか2つだけを補正することも可能である。
<4-1. Modification 1>
For example, in the above description, the color
<4−2.変形例2>
また、上記の説明では、本発明におけるカラー画像がスキャナ20により撮影された画像である例について説明したが、かかる例に限定されない。例えば、本発明におけるカラー画像は、ホワイトボードなどの被写体がデジタルカメラにより撮影された画像であってもよい。
<4-2. Modification 2>
In the above description, an example in which the color image in the present invention is an image taken by the
<4−3.変形例3>
また、スキャナ20が、上述した制御部100に含まれる全ての構成要素を有する場合には、本発明による情報処理装置は、スキャナ20であってもよい。また、この変形例では、情報処理装置10は必ずしも設けられなくてもよい。
<4-3. Modification 3>
Further, when the
<4−4.変形例4>
また、本実施形態によれば、CPU150、ROM152、およびRAM154などのハードウェアを、上述した情報処理装置10の各構成と同等の機能を発揮させるためのコンピュータプログラムも提供可能である。また、該コンピュータプログラムが記録された記録媒体も提供される。
<4-4. Modification 4>
In addition, according to the present embodiment, it is possible to provide a computer program for causing hardware such as the
10 情報処理装置
20 スキャナ
22 通信網
100 制御部
102 明度画像生成部
104 明度画像補正部
106 カラー画像補正部
108 OCR用画像生成部
110 OCR処理部
120 通信部
122 記憶部
150 CPU
152 ROM
154 RAM
156 内部バス
158 入出力インターフェース
160 HDD
162 ネットワークインターフェース
DESCRIPTION OF
152 ROM
154 RAM
156 Internal bus 158 I /
162 Network interface
Claims (10)
生成された明度画像に含まれる画素の画素値を補正する明度画像補正部と、
前記明度画像補正部による補正の結果に基づいて、前記カラー画像に含まれる画素の色成分を補正するカラー画像補正部と、
を備える、情報処理装置。 A brightness image generation unit that generates a brightness image based on a color image;
A brightness image correction unit that corrects pixel values of pixels included in the generated brightness image;
A color image correction unit that corrects a color component of a pixel included in the color image based on a result of correction by the brightness image correction unit;
An information processing apparatus comprising:
生成された明度画像に含まれる画素の画素値を補正するステップと、
前記補正の結果に基づいて、前記カラー画像に含まれる画素の色成分を補正するステップと、
を備える、情報処理方法。 Generating a brightness image based on the color image;
Correcting the pixel values of the pixels included in the generated brightness image;
Correcting a color component of a pixel included in the color image based on the result of the correction;
An information processing method comprising:
カラー画像に基づいて明度画像を生成する明度画像生成部と、
生成された明度画像に含まれる画素の画素値を補正する明度画像補正部と、
前記明度画像補正部による補正の結果に基づいて、前記カラー画像に含まれる画素の色成分を補正するカラー画像補正部、
として機能させるための、プログラム。 Computer
A brightness image generation unit that generates a brightness image based on a color image;
A brightness image correction unit that corrects pixel values of pixels included in the generated brightness image;
A color image correction unit that corrects a color component of a pixel included in the color image based on a result of the correction by the brightness image correction unit;
Program to function as
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2014172570A JP2016048828A (en) | 2014-08-27 | 2014-08-27 | Information processing device, information processing method, and program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2014172570A JP2016048828A (en) | 2014-08-27 | 2014-08-27 | Information processing device, information processing method, and program |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2016048828A true JP2016048828A (en) | 2016-04-07 |
Family
ID=55649532
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2014172570A Pending JP2016048828A (en) | 2014-08-27 | 2014-08-27 | Information processing device, information processing method, and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2016048828A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113592739A (en) * | 2021-07-30 | 2021-11-02 | 浙江大华技术股份有限公司 | Method and device for correcting lens shadow and storage medium |
JP7491763B2 (en) | 2020-07-27 | 2024-05-28 | 株式会社日立情報通信エンジニアリング | Image processing device, method, and program |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH08251402A (en) * | 1995-03-07 | 1996-09-27 | Minolta Co Ltd | Image processing unit |
JP2001169097A (en) * | 1999-12-10 | 2001-06-22 | Sharp Corp | Picture processor and picture processing method |
JP2010147908A (en) * | 2008-12-19 | 2010-07-01 | Ricoh Co Ltd | Image processing apparatus, image processing method, image processing program and recording medium |
JP2010268438A (en) * | 2009-04-13 | 2010-11-25 | Canon Inc | Image processing apparatus, control method thereof, and program |
-
2014
- 2014-08-27 JP JP2014172570A patent/JP2016048828A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPH08251402A (en) * | 1995-03-07 | 1996-09-27 | Minolta Co Ltd | Image processing unit |
JP2001169097A (en) * | 1999-12-10 | 2001-06-22 | Sharp Corp | Picture processor and picture processing method |
JP2010147908A (en) * | 2008-12-19 | 2010-07-01 | Ricoh Co Ltd | Image processing apparatus, image processing method, image processing program and recording medium |
JP2010268438A (en) * | 2009-04-13 | 2010-11-25 | Canon Inc | Image processing apparatus, control method thereof, and program |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP7491763B2 (en) | 2020-07-27 | 2024-05-28 | 株式会社日立情報通信エンジニアリング | Image processing device, method, and program |
CN113592739A (en) * | 2021-07-30 | 2021-11-02 | 浙江大华技术股份有限公司 | Method and device for correcting lens shadow and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR101944208B1 (en) | Apparatus and method for color correction | |
JP5810628B2 (en) | Image processing apparatus and image processing program | |
CN105243371A (en) | Human face beauty degree detection method and system and shooting terminal | |
JP2017505956A (en) | How to convert a saturated image to a non-saturated image | |
JP2010263423A (en) | Method and device for processing image | |
JP5782838B2 (en) | Image processing apparatus and image processing program | |
JP2012243216A (en) | Image processing device, and image processing program | |
JP2020074501A (en) | Image processing apparatus, image processing method, and program | |
KR20180127913A (en) | Image processing apparatus, image processing method, and storage medium | |
JP2004178321A (en) | Color difference judgment method | |
JP2016048828A (en) | Information processing device, information processing method, and program | |
JP2008052587A (en) | Program, information storage medium, two-dimensional code generation system and two-dimensional code | |
JP2012028973A (en) | Illumination light estimation device, illumination light estimation method, and illumination light estimation program | |
JP5365740B2 (en) | Image decoding apparatus, image decoding method, and computer program for image decoding | |
JP4569785B2 (en) | Binarization device and binarization processing program | |
JP2013250314A (en) | Image processor, display device, information processor and image processing method | |
JP4321666B2 (en) | Image data correction device | |
JP6818585B2 (en) | Image processing device, image processing method, and program | |
JP5336945B2 (en) | Image processing device | |
JP2015076676A (en) | Image processing apparatus, image processing method, and program | |
CN110599437A (en) | Method and apparatus for processing video | |
JP5147912B2 (en) | Image processing method, image processing apparatus, program, and recording medium | |
WO2021192887A1 (en) | Image processing device, image processing method, and program | |
JP2012205190A (en) | Image processing apparatus and program | |
KR102014217B1 (en) | Method for correcting distortion of shade and apparatus using the same |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20170515 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20180109 |
|
A02 | Decision of refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A02 Effective date: 20180911 |