JP6346431B2 - Image processing apparatus and image processing method - Google Patents
Image processing apparatus and image processing method Download PDFInfo
- Publication number
- JP6346431B2 JP6346431B2 JP2013235007A JP2013235007A JP6346431B2 JP 6346431 B2 JP6346431 B2 JP 6346431B2 JP 2013235007 A JP2013235007 A JP 2013235007A JP 2013235007 A JP2013235007 A JP 2013235007A JP 6346431 B2 JP6346431 B2 JP 6346431B2
- Authority
- JP
- Japan
- Prior art keywords
- image
- group
- shading
- coefficient
- value
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
Images
Description
本発明は画像処理装置及び画像処理方法に関する。 The present invention relates to an image processing apparatus and an image processing method.
撮像装置に赤外カットフィルタを適用したときに、撮像画像に色シェーディングが生じることがある。特許文献1には、そのような色シェーディングを補正する画像処理装置として、撮像画像に複数のシェーディング補正係数をそれぞれ適用し、適切に色シェーディングを補正できたシェーディング補正係数を選択し、当該撮像画像に選択したシェーディング補正係数を適用して、当該撮像画像の色シェーディングを補正し出力する画像処理装置が開示されている。
When an infrared cut filter is applied to the imaging apparatus, color shading may occur in the captured image. In
上記の画像処理装置では、撮像画像を複数のブロックに分割し、ブロック毎の画素値の統計値を求め、この統計値とシェーディング補正係数のブロック毎の係数値とを乗算し、乗算結果の撮像画像内での分散値を求める。この分散値をシェーディング補正係数毎に求め、分散値がいちばん小さいシェーディング補正係数を、適切に色シェーディングを補正できたシェーディング補正係数として選択する。
しかしながら、撮像シーンが複雑であったときに、分散値がいちばん小さいシェーディング補正係数が、必ずしも適切に色シェーディングを補正できるシェーディング補正係数とならないという問題点があった。
In the above image processing apparatus, the captured image is divided into a plurality of blocks, the statistical value of the pixel value for each block is obtained, the statistical value is multiplied by the coefficient value for each block of the shading correction coefficient, and the multiplication result is captured. Find the variance value in the image. The dispersion value is obtained for each shading correction coefficient, and the shading correction coefficient with the smallest dispersion value is selected as the shading correction coefficient that has been able to appropriately correct the color shading.
However, when the imaging scene is complicated, there is a problem that the shading correction coefficient with the smallest variance value is not necessarily a shading correction coefficient that can appropriately correct the color shading.
本発明は、このような問題点を解決するためになされたものであり、画像に適したシェーディング補正係数を選択することのできる画像処理装置及び画像処理方法を提供することを目的とする。 The present invention has been made to solve such a problem, and an object thereof is to provide an image processing apparatus and an image processing method capable of selecting a shading correction coefficient suitable for an image.
本発明に係る画像処理装置は、画像にシェーディング推定係数を複数適用し、前記画像に適切なシェーディング推定係数を選択する推定部と、前記適切なシェーディング推定係数に対応するシェーディング補正係数を前記画像に適用し、前記画像のシェーディングを補正する補正部とを備え、前記推定部は、前記画像を前記画像の中央部からの距離に基づいて複数のグループに分類し、前記画像に前記シェーディング推定係数を適用したときの画像特性値を前記グループ毎に算出し、前記画像特性値の統計値を算出して、前記画像に適切なシェーディング推定係数を選択するものである。この構成により、画像に適したシェーディング推定係数を選択し、画像に適したシェーディング補正係数を選択することができる。 An image processing apparatus according to the present invention applies a plurality of shading estimation coefficients to an image, selects an appropriate shading estimation coefficient for the image, and a shading correction coefficient corresponding to the appropriate shading estimation coefficient to the image. And a correction unit that corrects shading of the image, and the estimation unit classifies the image into a plurality of groups based on a distance from a central part of the image, and the shading estimation coefficient is applied to the image. An image characteristic value when applied is calculated for each of the groups, a statistical value of the image characteristic value is calculated, and an appropriate shading estimation coefficient for the image is selected. With this configuration, a shading estimation coefficient suitable for an image can be selected, and a shading correction coefficient suitable for an image can be selected.
本発明に係る画像処理方法は、画像にシェーディング推定係数を複数適用し、前記画像に適切なシェーディング推定係数を選択する推定ステップと、前記適切なシェーディング推定係数に対応するシェーディング補正係数を前記画像に適用し、前記画像のシェーディングを補正する補正ステップとを有し、前記推定ステップは、前記画像を前記画像の中央部からの距離に基づいて複数のグループに分類するステップと、前記画像に前記シェーディング推定係数を適用したときの画像特性値を前記グループ毎に算出するステップと、前記画像特性値の統計値を算出して、前記画像に適切なシェーディング推定係数を選択するステップとを有するものである。これにより、画像に適したシェーディング推定係数を選択し、画像に適したシェーディング補正係数を選択することができる。 An image processing method according to the present invention includes an estimation step of applying a plurality of shading estimation coefficients to an image, selecting an appropriate shading estimation coefficient for the image, and a shading correction coefficient corresponding to the appropriate shading estimation coefficient to the image. Applying and correcting the shading of the image, the estimating step classifying the image into a plurality of groups based on a distance from a central portion of the image, and the shading into the image Calculating an image characteristic value when the estimation coefficient is applied for each group, and calculating a statistical value of the image characteristic value and selecting an appropriate shading estimation coefficient for the image. . Accordingly, it is possible to select a shading estimation coefficient suitable for an image and select a shading correction coefficient suitable for the image.
本発明により、画像に適したシェーディング補正係数を選択することのできる画像処理装置及び画像処理方法を提供することができる。 According to the present invention, it is possible to provide an image processing apparatus and an image processing method capable of selecting a shading correction coefficient suitable for an image.
以下、図面を参照して本発明の実施の形態について説明する。
まず、本実施の形態に係る画像処理装置の構成について、当該画像処理装置を備えたデジタルスチルカメラ100の構成も含めて説明する。
Embodiments of the present invention will be described below with reference to the drawings.
First, the configuration of the image processing apparatus according to the present embodiment will be described including the configuration of the digital
図1は、本実施の形態に係る画像処理装置を備えたデジタルスチルカメラ100の構成を示すブロック図である。
電子的撮像装置であるデジタルスチルカメラ100は、レンズ光学系102、撮像素子104、AFE回路106、画像信号処理回路108、画像表示部110、画像記録部112、ドライバ114、タイミングジェネレータ(TG)116、画像ブロック統計回路118、制御部120、係数記憶部122などを備えている。
FIG. 1 is a block diagram illustrating a configuration of a digital
A
レンズ光学系102は、レンズ、絞り、シャッターなどを有し、被写体像を撮像素子104の撮像面に結像する。撮像素子104はCCDやCMOSなどのイメージセンサであり、撮像素子104のレンズ光学系102側には赤外カットフィルタ(図示せず)が装着されている。撮像素子104は、被写体像を光電変換して画像信号(RGB色信号)を取得する。AFE回路106は、撮像素子104が取得し、CDS回路(図示せず)が信号処理を施した画像信号をA/D変換してデジタル信号とする。
The lens
画像信号処理回路108は、AFE回路106が出力した画像信号に、デモザイキング処理、エッジ強調処理、ホワイトバランス(WB)補正処理、シェーディング補正処理、ガンマ補正処理などを施す。画像表示部110は液晶表示ディスプレイ(LCD)などであり、画像信号処理回路108で各種処理が施された画像信号を表示する。画像記録部112はメモリであり、画像信号処理回路108で各種処理が施された画像信号を記録する。
The image
ドライバ114は、レンズ光学系102のレンズ、絞り、シャッターを駆動する。タイミングジェネレータ116は、撮像素子104を駆動するためのタイミングを生成する。
画像ブロック統計回路118は、AFE回路106でデジタル信号となった画像信号の撮像画像領域又は撮像画像領域の一部の領域を格子状に分割して複数のブロックとし、ブロック毎にブロック統計値を算出する。画像ブロック統計回路118は、ブロック統計値として、各ブロック内のRGB別の画素積算値又はRGB別の画素平均値を算出する。
The
The image block
制御部120は、画像ブロック統計回路118が算出したブロック統計値に基づいて、画像信号処理回路108のホワイトバランス補正処理を制御する。また、制御部120は、シェーディング推定部124、シェーディング補正部126を有している。
The
シェーディング推定部124は、画像ブロック統計回路118が算出したブロック統計値と、係数記憶部122が記憶するシェーディング推定係数とに基づいてシェーディングを推定し、画像に適したシェーディング推定係数を選択する。シェーディング推定係数は光源毎に、また、R値、G値、B値毎に設定されており、ブロック毎の係数値を有している。シェーディング推定処理については後述する。
The
シェーディング補正部126は、シェーディング推定部124が選択したシェーディング推定係数に対応するシェーディング補正係数を係数記憶部122から選択し、画像信号処理回路108において撮像画像のシェーディングを補正する。シェーディング補正係数は光源毎に、また、R値、G値、B値毎に設定されており、画素毎又は複数の画素毎の係数値を有している。
The
係数記憶部122は、シェーディング推定係数とシェーディング補正係数との組みを太陽光、電球、蛍光灯などの光源別に記憶している。多くの場合に、シェーディング推定係数とシェーディング推定係数とは1対1の組みとなっているが、これに限られるものではない。シェーディング推定係数及びシェーディング補正係数は、パソコンなどの外部装置において算出することができる。
The
シェーディング推定係数は、各光源下で撮影した白色チャートの画像を用いて算出する。白色チャートには、標準白色反射板などの分光反射率が対象波長域全般に亘って一定でかつ90%以上の均等拡散反射面を用いることが望ましい。赤外光が多く含まれる電球などの光源に対しては、画像周辺部のR信号を強く補正するシェーディング推定係数が算出される。赤外光があまり含まれない蛍光灯などの光源に対しては、画像周辺部のR信号を弱く補正するシェーディング推定係数が算出される。画像周辺部のR信号を最も弱く補正するシェーディング推定係数を初期設定(デフォルト)のシェーディング推定係数とし、特に、シェーディング推定初期係数という。
なお、本実施の形態に係る画像処理装置は、画像信号処理回路108、画像ブロック統計回路118、制御部120、係数記憶部122などにより構成されるが、この構成に限られるものではない。
The shading estimation coefficient is calculated using a white chart image taken under each light source. For the white chart, it is desirable to use a uniform diffuse reflection surface having a spectral reflectance such as a standard white reflector that is constant over the entire target wavelength range and 90% or more. For a light source such as a light bulb that contains a large amount of infrared light, a shading estimation coefficient that strongly corrects the R signal at the periphery of the image is calculated. For a light source such as a fluorescent lamp that does not contain much infrared light, a shading estimation coefficient for correcting the R signal at the periphery of the image weakly is calculated. The shading estimation coefficient that corrects the R signal at the periphery of the image most weakly is set as an initial setting (default) shading estimation coefficient, and is particularly referred to as a shading estimation initial coefficient.
Note that the image processing apparatus according to this embodiment includes the image
また、制御部120が実現する各構成要素は、例えば、コンピュータである制御部120が備える演算装置(図示せず)の制御によって、プログラムを実行させることにより実現できる。より具体的には、制御部120は、記憶部(図示せず)に格納されたプログラムを主記憶装置(図示せず)にロードし、演算装置の制御によってプログラムを実行して実現する。また、各構成要素は、プログラムによるソフトウェアで実現することに限ることなく、ハードウェア、ファームウェア及びソフトウェアのうちのいずれかの組み合わせなどにより実現しても良い。
Moreover, each component which the
上述したプログラムは、様々なタイプの非一時的なコンピュータ可読媒体(non-transitory computer readable medium)を用いて格納され、コンピュータに供給することができる。非一時的なコンピュータ可読媒体は、様々なタイプの実体のある記録媒体(tangible storage medium)を含む。非一時的なコンピュータ可読媒体の例は、磁気記録媒体(例えば、フレキシブルディスク、磁気テープ、ハードディスクドライブ)、光磁気記録媒体(例えば、光磁気ディスク)、CD−ROM(Read Only Memory)、CD−R、CD−R/W、半導体メモリ(例えば、マスクROM、PROM(Programmable ROM)、EPROM(Erasable PROM)、フラッシュROM、RAM(random access memory))を含む。 The above-described program can be stored using various types of non-transitory computer readable media and supplied to a computer. Non-transitory computer readable media include various types of tangible storage media. Examples of non-transitory computer-readable media include magnetic recording media (for example, flexible disks, magnetic tapes, hard disk drives), magneto-optical recording media (for example, magneto-optical disks), CD-ROMs (Read Only Memory), CD-ROMs. R, CD-R / W, semiconductor memory (for example, mask ROM, PROM (Programmable ROM), EPROM (Erasable PROM), flash ROM, RAM (random access memory)).
また、プログラムは、様々なタイプの一時的なコンピュータ可読媒体(transitory computer readable medium)によってコンピュータに供給されても良い。一時的なコンピュータ可読媒体の例は、電気信号、光信号、及び電磁波を含む。一時的なコンピュータ可読媒体は、電線及び光ファイバなどの有線通信路、または無線通信路を介して、プログラムをコンピュータに供給できる。 Further, the program may be supplied to the computer by various types of temporary computer readable media. Examples of transitory computer readable media include electrical signals, optical signals, and electromagnetic waves. The transitory computer readable medium can supply the program to the computer via a wired communication path such as an electric wire and an optical fiber, or a wireless communication path.
次に、本実施の形態のシェーディング推定部124の動作について説明する。
図2は、本実施の形態に係るシェーディング推定部124の動作を説明するためのフローチャートである。
まず、シェーディング推定部124は、画像ブロック統計回路118がシェーディング補正の対象となる画像から算出したブロック統計値を用いて、全てのブロックのR値、G値、B値の平均値Rav、Gav、Bavを算出する(ステップS010)。
Next, the operation of the
FIG. 2 is a flowchart for explaining the operation of
First, the
次に、(1)式に示すように、規格化係数Rg、Bg、Ggを算出する(ステップS020)。規格化係数Rg、Bg、Ggは、全画面のRGBバランスを一致させるための係数であって、画像を規格化するゲインである。
Vav=max(Rav,Gav,Bav)
Rg=Vav/Rav
Gg=Vav/Gav
Bg=Vav/Bav ・・・(1)
Next, normalization coefficients Rg, Bg, and Gg are calculated as shown in equation (1) (step S020). The normalization coefficients Rg, Bg, and Gg are coefficients for matching the RGB balance of the entire screen, and are gains that normalize the image.
Vav = max (Rav, Gav, Bav)
Rg = Vav / Rav
Gg = Vav / Gav
Bg = Vav / Bav (1)
次に、(2)式に示すように、全てのブロック統計値R(x,y)、G(x,y)、B(x,y)に対して、シェーディング推定係数Cr[t](x,y)、Cg[t](x,y)、Cg[t](x,y)及び規格化係数Rg、Bg、Ggを適用して乗算し、ブロック毎にRc[t](x,y)、Gc[t](x,y)、Bc[t](x,y) を算出する(ステップS030)。
Rc[t](x,y)=R(x,y)・Cr[t](x,y)・Rg
Gc[t](x,y)=G(x,y)・Cg[t](x,y)・Gg
Bc[t](x,y)=B(x,y)・Cb[t](x,y)・Bg ・・・(2)
Next, as shown in equation (2), the shading estimation coefficient Cr [t] (x) is calculated for all the block statistical values R (x, y), G (x, y), and B (x, y). , y), Cg [t] (x, y), Cg [t] (x, y) and normalization coefficients Rg, Bg, Gg are applied and multiplied, and Rc [t] (x, y) is applied to each block. ), Gc [t] (x, y), Bc [t] (x, y) are calculated (step S030).
Rc [t] (x, y) = R (x, y) · Cr [t] (x, y) · Rg
Gc [t] (x, y) = G (x, y) · Cg [t] (x, y) · Gg
Bc [t] (x, y) = B (x, y) · Cb [t] (x, y) · Bg (2)
ここでは、後述する基準グループを選択するためのグループ毎のR信号比を算出するために、シェーディング推定係数として、前述のシェーディング推定初期係数を用いる。
また、規格化係数は撮像画像のRGB平均値を無彩色とみなし、このRGB平均値から当該ブロックの色差がどの程度あるかを判定するために適用する。
シェーディング推定係数が画像に適しているほど、Rc[t](x,y)、Gc[t](x,y)、Bc[t](x,y)は等しく1.0に近くなり、Rc[t](x,y)、Gc[t](x,y)、Bc[t](x,y)を画像化すると、画像は灰色一色となる。
Here, the aforementioned shading estimation initial coefficient is used as the shading estimation coefficient in order to calculate the R signal ratio for each group for selecting a reference group to be described later.
In addition, the normalization coefficient is applied to determine the degree of color difference of the block from the RGB average value by regarding the RGB average value of the captured image as an achromatic color.
Rc [t] (x, y), Gc [t] (x, y), Bc [t] (x, y) are equally close to 1.0 as the shading estimation coefficient is more suitable for an image. When [t] (x, y), Gc [t] (x, y), and Bc [t] (x, y) are imaged, the image becomes a single gray color.
次に、(3)式に示すように、ブロック毎にR信号比Rr[t](x,y)を求める(ステップS040、ステップS050)。
Rr[t](x,y)=Rc[t](x,y)/Gc[t](x,y) ・・・(3)
なお、(3)式の分母は、Rc[t](x,y)、Gc[t](x,y)、Bc[t](x,y)の和であっても良い。また、ブロック毎のR信号比に加えて、または、ブロック毎のR信号比に代えて、ブロック毎のB信号比を算出し、以降の処理に用いても良い。
Next, as shown in equation (3), an R signal ratio Rr [t] (x, y) is obtained for each block (steps S040 and S050).
Rr [t] (x, y) = Rc [t] (x, y) / Gc [t] (x, y) (3)
Note that the denominator of equation (3) may be the sum of Rc [t] (x, y), Gc [t] (x, y), and Bc [t] (x, y). Further, in addition to the R signal ratio for each block or instead of the R signal ratio for each block, the B signal ratio for each block may be calculated and used for the subsequent processing.
(3)式では、規格化係数を適用したRGB画像についてR信号比を求めているため、シェーディング推定係数が画像に適しているときほど、有彩色の被写体、例えば、画像全面が赤となるような被写体であってもR信号比は1.0に近い値となる。逆に、シェーディング推定係数が画像に適していないときほど、R信号比は1.0から離れた値となる。 In the equation (3), since the R signal ratio is obtained for the RGB image to which the normalization coefficient is applied, the chromatic object, for example, the entire image becomes red as the shading estimation coefficient is suitable for the image. Even if the subject is a small subject, the R signal ratio is close to 1.0. Conversely, the R signal ratio becomes a value farther from 1.0 when the shading estimation coefficient is not suitable for an image.
次に、シェーディング推定部124は、グループ毎のR信号比を算出する(ステップS060、ステップS070)。
図3は、本実施の形態に係るグループの例を説明するための図である。
シェーディング推定部124は、画像ブロック統計回路118が画像領域を格子状に分割して取得した各ブロックを画像中央部からの距離に基づいて複数のグループに分類する。図3に示す画像300では、画像中央部から画像周辺部に向けて、この画像の各ブロックをグループ0からグループ5までの6つのグループに分類している。
そして、(4)式に示すように、グループに含まれるブロックのR信号比Rr(i)を平均し、グループ毎のR信号比GpRr[j]を算出する。
Next, the
FIG. 3 is a diagram for explaining an example of a group according to the present embodiment.
The
Then, as shown in equation (4), the R signal ratio Rr (i) of the blocks included in the group is averaged to calculate the R signal ratio GpRr [j] for each group.
次に、基準グループの選択を行う(ステップS080)。画像中央部のグループより順次、外側のグループに向かって探索し、基準グループとして1つのグループを選択する。例えば、図3に示すグループ0より探索を開始し、シェーディングの影響を受けていないと考えられるグループ3までを探索する。このとき、(5)式に示すように、グループのR信号比GpRr[j]の閾値判定を行い、最初に(5)式を満たすグループを基準グループとして選択する。閾値Th1、Th2は、その間に1.0が含まれるように、例えば、0.9、1.1に設定する。規格化係数を適用した後に基準グループを選択しているので、無彩色の被写体の場合に限らず一様な有彩色の被写体の場合であっても基準グループを選択することができる。
Th1<GpRr[j]<Th2 ・・・(5)
Next, a reference group is selected (step S080). A search is performed sequentially from the group in the center of the image toward the outer group, and one group is selected as the reference group. For example, the search is started from the
Th1 <GpRr [j] <Th2 (5)
次に、基準グループの有無を判定する(ステップS090)。
基準グループが有ったとき(ステップS090のYes)は、グループ評価値を算出する(ステップS100、ステップS110)。
グループ評価値は、ステップS080で選択した基準グループよりも外側の各グループについて算出する。例えば、基準グループとしてグループ1を選択したときには、外側のグループ2〜グループ5の各グループについてグループ評価値を算出する。(6)式に示すように、基準グループのR信号比GpRr[j]と外側のグループのR信号比GpRr[j+k]との差分を求め、あらかじめ用意した外側のグループの重みWg[j+k]を乗算して各グループ評価値Dg[j+k]を算出する。
Dg[j+k]=(GpRr[j]−GpRr[j+k])・Wg[j+k] ・・・(6)
Next, the presence / absence of a reference group is determined (step S090).
When there is a reference group (Yes in step S090), a group evaluation value is calculated (step S100, step S110).
The group evaluation value is calculated for each group outside the reference group selected in step S080. For example, when
Dg [j + k] = (GpRr [j] −GpRr [j + k] ) · Wg [j + k] (6)
グループの重みWgは次のようにグループ毎に用意する。画像周辺部のグループの方が、重みWgは大きい。これにより、シェーディング推定係数の画像周辺部のシェーディング補正の適否をより精度良く評価できるようになる。
グループ 重みWg
1 0.2
2 0.4
3 0.6
4 0.8
5 1.0
The group weight Wg is prepared for each group as follows. The group at the periphery of the image has a larger weight Wg. As a result, it is possible to more accurately evaluate the suitability of the shading correction of the shading estimation coefficient at the periphery of the image.
Group weight Wg
1 0.2
2 0.4
3 0.6
4 0.8
5 1.0
次に、(7)式に示すように、グループ評価値Dg[j+k]の絶対値の総和をとり、ステップS030で適用したシェーディング推定係数の評価値Edとする(ステップS120)。 Next, as shown in the equation (7), the sum of absolute values of the group evaluation values Dg [j + k] is taken to obtain the evaluation value Ed of the shading estimation coefficient applied in step S030 (step S120).
この評価値Edは画像中心部から周辺部にかけて減衰するR信号比の特徴を抽出するもので、シェーディング補正の対象となる画像に対して、ステップS030で用いたシェーディング推定係数が適しているか否かを判断する指標となる。 This evaluation value Ed is used to extract the characteristic of the R signal ratio that attenuates from the center to the periphery of the image. Whether or not the shading estimation coefficient used in step S030 is appropriate for the image subjected to shading correction. It becomes an index to judge.
次に、シェーディング推定部124は、シェーディング補正の対象となる画像について、すべてのシェーディング推定係数の評価値を算出したか判定する(ステップS130)。すべてのシェーディング推定係数の評価値を算出していないとき(ステップS130のNo)は、ステップS030に戻り、評価値を算出していないシェーディング推定係数、すなわち、シェーディング推定初期係数以外のシェーディング推定係数について、ステップS030からステップS130までの処理を繰り返す。
Next, the
なお、シェーディング推定初期係数以外のシェーディング推定係数の評価値を算出するときには、ステップS080の基準グループの選択、及び、ステップS090の基準グループの有無の判定を行わない。そして、シェーディング推定初期係数の評価値を算出するときに選択した基準グループ、例えば、グループ1を、そのまま、シェーディング推定初期係数以外のシェーディング推定係数の評価値を算出するときの基準グループとして選択する。つまり、シェーディング推定初期係数の評価値を算出するときに選択した基準グループに基づいて、シェーディング推定初期係数以外のシェーディング推定係数の評価値を算出する。
When calculating an evaluation value of a shading estimation coefficient other than the shading estimation initial coefficient, the selection of the reference group in step S080 and the determination of the presence or absence of the reference group in step S090 are not performed. Then, the reference group selected when calculating the evaluation value of the shading estimation initial coefficient, for example,
最後に、シェーディング推定部124は、すべてのシェーディング推定係数の評価値を算出した後に(ステップS130のYes)、シェーディング推定初期係数を含むすべてのシェーディング推定係数の中で、評価値Edが最も小さくなるものを、シェーディング補正の対象となる画像に適したシェーディング推定係数であるとして選択する(ステップS140)。
Finally, after calculating the evaluation values of all the shading estimation coefficients (Yes in step S130), the
また、シェーディング推定部124は、基準グループが無かったとき(ステップS090のNo)は、シェーディング推定初期係数をシェーディング補正の対象となる画像に適したシェーディング推定係数であるとして選択する(ステップS140)。
Further, when there is no reference group (No in step S090), the
なお、本実施の形態では、図3に示すように、シェーディング補正の対象となる画像全体に対して、基準グループ選択処理から評価値算出処理まで(ステップS080〜ステップS120)を行っているが、シェーディング補正の対象となる画像を複数の領域に分けて、それぞれの領域において、基準グループ選択処理から評価値算出処理までを行って良い。 In this embodiment, as shown in FIG. 3, the entire process target for shading correction is performed from the reference group selection process to the evaluation value calculation process (steps S080 to S120). An image to be subjected to shading correction may be divided into a plurality of areas, and the process from the reference group selection process to the evaluation value calculation process may be performed in each area.
図4は、本実施の形態に係る別のグループを説明するための図である。
シェーディング推定部124は、シェーディング補正の対象となる画像400を4つの領域I〜IVに分け、更に、領域I〜IV内の各ブロックを画像中央部からの距離に基づいて複数のグループに分類する。例えば、図4に示す画像400では、領域Iにおいて、各ブロックをグループI−1からグループI−5までの5つのグループに分類する。そして、領域Iにおいて、基準グループ選択処理から評価値算出処理までを行う。また、領域II〜IVについても同様とする。これにより、領域I〜IV毎に各シェーディング推定係数の評価値を算出し、領域I〜IV毎に被写体に適したシェーディング推定係数を選択することができる。
FIG. 4 is a diagram for explaining another group according to the present embodiment.
The
また、本実施の形態においては、画像処理装置はデジタルスチルカメラ100に組み込まれていたが、画像処理装置をパソコンなどの外部装置に組み込んで、当該装置において画像のシェーディング推定及びシェーディング補正を行うようにしても良い。
また、本実施の形態においては、特許文献1記載のように選択した推定係数をそのまま補正係数として選択して用いても良い。すなわち、本実施の形態に係るシェーディング補正係数には、シェーディング推定係数と異なるものと、シェーディング推定係数と同一のものとがあっても良い。
In the present embodiment, the image processing apparatus is incorporated in the digital
In the present embodiment, the estimated coefficient selected as described in
また、本実施の形態においては、シェーディング推定係数の評価値をグループ評価値の絶対値の総和により求めたが、シェーディング推定係数の評価値をグループ評価値の分散などにより求めても良い。すなわち、本実施の形態に係るシェーディング推定係数の評価値をグループ評価値の何らかの統計値により求めても良い。
また、本実施の形態においては、各グループ評価値を、基準グループのR信号比と外側のグループのR信号比との差分を求め、これに外側のグループの重みを乗算して求めたが、各グループ評価値を、基準グループのR信号比と外側のグループのR信号比との差分として求めても良い。すなわち、外側のグループの重みを乗算することを省略しても良い。
In this embodiment, the evaluation value of the shading estimation coefficient is obtained by the sum of the absolute values of the group evaluation values. However, the evaluation value of the shading estimation coefficient may be obtained by variance of the group evaluation values. That is, the evaluation value of the shading estimation coefficient according to the present embodiment may be obtained from some statistical value of the group evaluation value.
Further, in the present embodiment, each group evaluation value is obtained by calculating the difference between the R signal ratio of the reference group and the R signal ratio of the outer group and multiplying this by the weight of the outer group. Each group evaluation value may be obtained as a difference between the R signal ratio of the reference group and the R signal ratio of the outer group. That is, multiplying the weight of the outer group may be omitted.
以上、説明したように、本実施の形態に係る画像処理装置は、画像にシェーディング推定係数を複数適用し、画像に適切なシェーディング推定係数を選択する推定部と、適切なシェーディング推定係数に対応するシェーディング補正係数を画像に適用し、画像のシェーディングを補正する補正部とを備え、推定部は、画像を画像の中央部からの距離に基づいて複数のグループに分類し、画像にシェーディング推定係数を適用したときの画像特性値をグループ毎に算出し、画像特性値の統計値を算出して、画像に適切なシェーディング推定係数を選択するものである。この構成により、画像に適したシェーディング補正係数を選択することができる。 As described above, the image processing apparatus according to this embodiment applies a plurality of shading estimation coefficients to an image, and corresponds to an estimation unit that selects an appropriate shading estimation coefficient for an image and an appropriate shading estimation coefficient. A correction unit that applies the shading correction coefficient to the image and corrects the shading of the image, and the estimation unit classifies the images into a plurality of groups based on the distance from the center of the image, and adds the shading estimation coefficient to the image. An image characteristic value when applied is calculated for each group, a statistical value of the image characteristic value is calculated, and an appropriate shading estimation coefficient for the image is selected. With this configuration, it is possible to select a shading correction coefficient suitable for an image.
また、本実施の形態に係る画像処理装置は、推定部が、画像の中央部のグループから順番に画像特性値を閾値判定してグループから基準グループを選択し、基準グループの画像特性値と、基準グループの外側にあるグループの画像特性値との差分の絶対値を外側にあるグループ毎に算出し、差分の絶対値の総和を画像特性値の統計値として算出するものである。 Further, in the image processing apparatus according to the present embodiment, the estimation unit determines the threshold value of the image characteristic value in order from the group at the center of the image and selects the reference group from the group, and the image characteristic value of the reference group, The absolute value of the difference from the image characteristic value of the group outside the reference group is calculated for each group outside, and the sum of the absolute values of the differences is calculated as the statistical value of the image characteristic value.
また、本実施の形態に係る画像処理装置は、推定部が、画像の中央部からの距離に応じて大きくなるグループ重みをグループ毎に有し、画像の中央部のグループから順番に画像特性値を閾値判定してグループから基準グループを選択し、基準グループの画像特性値と、基準グループの外側にあるグループの画像特性値との差分の絶対値に、外側にあるグループのグループ重みを乗じた乗算結果を外側にあるグループ毎に算出し、乗算結果の総和を画像特性値の統計値として算出するものである。 Also, in the image processing apparatus according to the present embodiment, the estimation unit has a group weight that increases in accordance with the distance from the center of the image for each group, and the image characteristic value in order from the group at the center of the image. The threshold value is determined, a reference group is selected from the group, and the absolute value of the difference between the image characteristic value of the reference group and the image characteristic value of the group outside the reference group is multiplied by the group weight of the group outside. The multiplication result is calculated for each group outside, and the sum of the multiplication results is calculated as a statistical value of the image characteristic value.
また、本実施の形態に係る画像処理装置は、画像特性値が、R信号比又はB信号比の少なくとも1つであるものである。
また、本実施の形態に係る画像処理装置は、画像を複数のブロックに分割し、ブロック毎に画素値の統計値を算出する統計部を更に備え、推定部は、ブロックを画像の中央部からの距離に基づいて複数のグループに分類し、グループに属するブロックの画素値の統計値に基づいて、画像特性値を算出するものである。
In the image processing apparatus according to the present embodiment, the image characteristic value is at least one of the R signal ratio and the B signal ratio.
The image processing apparatus according to the present embodiment further includes a statistical unit that divides the image into a plurality of blocks and calculates a statistical value of the pixel value for each block, and the estimation unit removes the blocks from the central portion of the image. The image characteristic values are calculated based on the statistical values of the pixel values of the blocks belonging to the group.
また、本実施の形態に係る画像処理装置は、推定部が、画像特性値を算出するときに、全画面のRGBバランスを一致させるための係数を適用するものである。
また、本実施の形態に係る画像処理装置は、シェーディング推定係数とシェーディング補正係数との組みを複数記憶する記憶部を更に備え、補正部は、適切なシェーディング推定係数と組みになったシェーディング補正係数を、対応するシェーディング補正係数として選択するものである。
また、本実施の形態に係る画像処理装置は、組みは光源毎に設けられているものである。
In the image processing apparatus according to the present embodiment, the estimation unit applies a coefficient for matching the RGB balance of the entire screen when calculating the image characteristic value.
The image processing apparatus according to the present embodiment further includes a storage unit that stores a plurality of sets of shading estimation coefficients and shading correction coefficients, and the correction unit includes a shading correction coefficient paired with an appropriate shading estimation coefficient. Are selected as the corresponding shading correction coefficients.
In the image processing apparatus according to the present embodiment, a set is provided for each light source.
108 画像信号処理回路
118 画像ブロック統計回路
120 制御部
122 係数記憶部
124 シェーディング推定部
126 シェーディング補正部
108 image
Claims (9)
前記適切なシェーディング推定係数に対応するシェーディング補正係数を前記画像に適用し、前記画像のシェーディングを補正する補正部と
を備える画像処理装置であって、
前記推定部は、
前記画像を前記画像の中央部からの距離に基づいて複数のグループに分類し、
前記画像に前記シェーディング推定係数を適用したときの画像特性値を前記グループ毎に算出し、
前記画像特性値の統計値を算出して、前記画像に適切なシェーディング推定係数を選択する
画像処理装置。 Applying a plurality of shading estimation coefficients to the image, and selecting an appropriate shading estimation coefficient for the image;
A correction unit that applies a shading correction coefficient corresponding to the appropriate shading estimation coefficient to the image and corrects shading of the image, and an image processing apparatus comprising:
The estimation unit includes
Classifying the images into a plurality of groups based on the distance from the center of the image;
An image characteristic value when the shading estimation coefficient is applied to the image is calculated for each group,
An image processing apparatus that calculates a statistical value of the image characteristic value and selects an appropriate shading estimation coefficient for the image.
前記画像の中央部のグループから順番に前記画像特性値を閾値判定して前記グループから基準グループを選択し、
前記基準グループの画像特性値と、前記基準グループの外側にあるグループの画像特性値との差分の絶対値を前記外側にあるグループ毎に算出し、
前記差分の絶対値の総和を前記画像特性値の統計値として算出する
請求項1記載の画像処理装置。 The estimation unit includes
The threshold value of the image characteristic value is determined in order from the group at the center of the image, and a reference group is selected from the group,
Calculating the absolute value of the difference between the image characteristic value of the reference group and the image characteristic value of the group outside the reference group for each of the groups outside;
The image processing apparatus according to claim 1, wherein a sum of absolute values of the differences is calculated as a statistical value of the image characteristic value.
前記画像の中央部のグループから順番に前記画像特性値を閾値判定して前記グループから基準グループを選択し、
前記基準グループの画像特性値と、前記基準グループの外側にあるグループの画像特性値との差分の絶対値に、前記外側にあるグループの前記グループ重みを乗じた乗算結果を前記外側にあるグループ毎に算出し、
前記乗算結果の総和を前記画像特性値の統計値として算出する
請求項1記載の画像処理装置。 The estimation unit has, for each group, a group weight that increases according to the distance from the center of the image,
The threshold value of the image characteristic value is determined in order from the group at the center of the image, and a reference group is selected from the group,
The multiplication result obtained by multiplying the absolute value of the difference between the image characteristic value of the reference group and the image characteristic value of the group outside the reference group by the group weight of the group outside is obtained for each group outside the group. To
The image processing apparatus according to claim 1, wherein the sum of the multiplication results is calculated as a statistical value of the image characteristic value.
請求項1乃至請求項3のいずれか1項に記載の画像処理装置。 The image processing apparatus according to any one of claims 1 to 3, wherein the image characteristic value is at least one of an R signal ratio and a B signal ratio.
前記推定部は、
前記ブロックを前記画像の中央部からの距離に基づいて前記複数のグループに分類し、
前記グループに属するブロックの前記画素値の統計値に基づいて、前記画像特性値を算出する
請求項1乃至請求項4のいずれか1項に記載の画像処理装置。 Further comprising a statistical unit that divides the image into a plurality of blocks and calculates a statistical value of a pixel value for each block;
The estimation unit includes
Classifying the blocks into the plurality of groups based on a distance from a central portion of the image;
The image processing apparatus according to claim 1, wherein the image characteristic value is calculated based on a statistical value of the pixel values of the blocks belonging to the group.
前記画像特性値を算出するときに、全画面のRGBバランスを一致させるための係数を適用する
請求項1乃至請求項5のいずれか1項に記載の画像処理装置。 The estimation unit includes
The image processing apparatus according to claim 1, wherein a coefficient for matching the RGB balance of the entire screen is applied when calculating the image characteristic value.
前記補正部は、前記適切なシェーディング推定係数と組みになったシェーディング補正係数を、前記対応するシェーディング補正係数として選択する
請求項1乃至請求項6のいずれか1項に記載の画像処理装置。 A storage unit for storing a plurality of sets of shading estimation coefficients and shading correction coefficients;
The image processing apparatus according to any one of claims 1 to 6, wherein the correction unit selects a shading correction coefficient paired with the appropriate shading estimation coefficient as the corresponding shading correction coefficient.
請求項7記載の画像処理装置。 The image processing apparatus according to claim 7, wherein the set is provided for each light source.
前記適切なシェーディング推定係数に対応するシェーディング補正係数を前記画像に適用し、前記画像のシェーディングを補正する補正ステップと
を有する画像処理方法であって、
前記推定ステップは、
前記画像を前記画像の中央部からの距離に基づいて複数のグループに分類するステップと、
前記画像に前記シェーディング推定係数を適用したときの画像特性値を前記グループ毎に算出するステップと、
前記画像特性値の統計値を算出して、前記画像に適切なシェーディング推定係数を選択するステップと
を有する画像処理方法。 An estimation step of applying a plurality of shading estimation coefficients to the image and selecting an appropriate shading estimation coefficient for the image;
A correction step of applying a shading correction coefficient corresponding to the appropriate shading estimation coefficient to the image to correct shading of the image, comprising:
The estimation step includes
Classifying the images into a plurality of groups based on a distance from a central portion of the images;
Calculating an image characteristic value for each group when the shading estimation coefficient is applied to the image;
Calculating a statistical value of the image characteristic value, and selecting an appropriate shading estimation coefficient for the image.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2013235007A JP6346431B2 (en) | 2013-11-13 | 2013-11-13 | Image processing apparatus and image processing method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2013235007A JP6346431B2 (en) | 2013-11-13 | 2013-11-13 | Image processing apparatus and image processing method |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2015095811A JP2015095811A (en) | 2015-05-18 |
JP6346431B2 true JP6346431B2 (en) | 2018-06-20 |
Family
ID=53197924
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2013235007A Expired - Fee Related JP6346431B2 (en) | 2013-11-13 | 2013-11-13 | Image processing apparatus and image processing method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP6346431B2 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP6284428B2 (en) * | 2014-05-22 | 2018-02-28 | オリンパス株式会社 | Microscope system |
US9661290B2 (en) | 2014-11-21 | 2017-05-23 | Samsung Electronics Co., Ltd. | Image processing apparatus and method |
JP6563751B2 (en) | 2015-09-09 | 2019-08-21 | 三星電子株式会社Samsung Electronics Co.,Ltd. | Image processing apparatus and image processing method |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP4309695B2 (en) * | 2003-05-14 | 2009-08-05 | オリンパス株式会社 | Image processing system, image processing control method, and program |
JP4603319B2 (en) * | 2004-09-01 | 2010-12-22 | パナソニック株式会社 | Image input device |
JP6004221B2 (en) * | 2012-03-22 | 2016-10-05 | 三星電子株式会社Samsung Electronics Co.,Ltd. | Image processing device |
JP2013229677A (en) * | 2012-04-24 | 2013-11-07 | Olympus Corp | Image processing program and image processing device |
-
2013
- 2013-11-13 JP JP2013235007A patent/JP6346431B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2015095811A (en) | 2015-05-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
KR100983037B1 (en) | Method for controlling auto white balance | |
US10419685B2 (en) | Image processing apparatus, image processing method, and computer-readable recording medium | |
JP6563751B2 (en) | Image processing apparatus and image processing method | |
JP6004221B2 (en) | Image processing device | |
JPWO2010053029A1 (en) | Image input device | |
KR101685887B1 (en) | Image processing device, image processing method, and computer-readable storage medium having image processing program | |
US10416026B2 (en) | Image processing apparatus for correcting pixel value based on difference between spectral sensitivity characteristic of pixel of interest and reference spectral sensitivity, image processing method, and computer-readable recording medium | |
US20200228770A1 (en) | Lens rolloff assisted auto white balance | |
JP6346431B2 (en) | Image processing apparatus and image processing method | |
JP5899894B2 (en) | Imaging apparatus, image processing apparatus, image processing program, and image processing method | |
US11457189B2 (en) | Device for and method of correcting white balance of image | |
KR102366254B1 (en) | Image processing apparatus and method | |
JP6276564B2 (en) | Image processing apparatus and image processing method | |
JP6900395B2 (en) | Image processing equipment, imaging equipment, image processing methods, image processing programs, and recording media | |
KR20200145670A (en) | Device and method for correcting white balance of image | |
US20200228769A1 (en) | Lens rolloff assisted auto white balance | |
JP6827782B2 (en) | Image processing equipment, imaging equipment, image processing methods, image processing programs, and recording media | |
JP7208379B2 (en) | Calibration method | |
US10937230B2 (en) | Image processing | |
US8953063B2 (en) | Method for white balance adjustment | |
JP2010147800A (en) | Image processing apparatus | |
JP4993275B2 (en) | Image processing device | |
JP2015109582A (en) | Image processing device and image processing method | |
JP6011022B2 (en) | Image processing apparatus, image processing program, and image processing method | |
JP2014127869A (en) | Image pickup device, image pickup method, and image pickup program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20161005 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20171016 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20171128 |
|
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: 20180515 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20180525 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 6346431 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
LAPS | Cancellation because of no payment of annual fees |