JP4067033B2 - Image processing apparatus and method - Google Patents
Image processing apparatus and method Download PDFInfo
- Publication number
- JP4067033B2 JP4067033B2 JP2007214604A JP2007214604A JP4067033B2 JP 4067033 B2 JP4067033 B2 JP 4067033B2 JP 2007214604 A JP2007214604 A JP 2007214604A JP 2007214604 A JP2007214604 A JP 2007214604A JP 4067033 B2 JP4067033 B2 JP 4067033B2
- Authority
- JP
- Japan
- Prior art keywords
- color
- evaluation value
- light source
- image
- ratio
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
Images
Landscapes
- Color Television Image Signal Generators (AREA)
- Processing Of Color Television Signals (AREA)
Description
本発明は画像処理装置及び方法に係り、特に画像記録機能を備えたデジタルカメラやビデオカメラなどに好適な、画像記録の際に光源か物体色かを判別してホワイトバランス制御を行う技術を備えた画像処理装置及び方法に関する。 The present invention relates to an image processing apparatus and method, and particularly suitable for a digital camera or a video camera having an image recording function, and has a technique for performing white balance control by discriminating between a light source and an object color at the time of image recording. The present invention relates to an image processing apparatus and method.
従来、デジタルカメラやビデオカメラなどに使用するオート系ホワイトバランス制御は、広範囲な色温度への追従性を保持させたい要請があり、これにより、画像に最適なホワイトバランス制御を得ようとしていた。しかし、広範囲な色温度への追従性を保持しようとすれば副作用として物体色を光源と誤って判別することがあり、これによってカラーフェリア現象がおきてしまうことがあった。このようなオートホワイトバランス制御において追従性を上げることは、同時に光源を誤って判別してしまう確率も高くなってしまうという、いわゆるトレードオフの関係が成り立っている。 Conventionally, there has been a demand for auto white balance control used for digital cameras, video cameras, and the like to keep trackability over a wide range of color temperatures, and thereby, it has been attempted to obtain optimal white balance control for images. However, if an attempt is made to maintain the ability to follow a wide range of color temperatures, the object color may be mistakenly identified as a light source as a side effect, which may cause a color feria phenomenon. Increasing the followability in such auto white balance control has a so-called trade-off relationship in which the probability of erroneously determining the light source at the same time increases.
このようなトレードオフの関係が成立する広範囲な色温度領域の中で、赤黄系の光源領域である低色温度領域においてホワイトバランス破綻を防止することが重要である。赤黄系の物体色は低色温度のタングステンなどの光源とRGB分布上で非常に酷似しており、物体色シーンか光源シーンかを判別することが難しく、物体色優先にして補正をかけない方がよいのか(この場合は、タングステン光源が補正しきれず犠牲となる)、光源優先にして物体色のカラーフェリア現象(物体色を光源と誤判別するので物体色が白く補正されてしまう)に目をつぶるのかでカメラ設計上の思想が大きく分岐していた。 It is important to prevent white balance failure in a low color temperature region, which is a red-yellow light source region, in a wide range of color temperature regions where such a trade-off relationship is established. Red-yellow object colors are very similar in RGB distribution to light sources such as tungsten with low color temperature, and it is difficult to distinguish between object color scenes and light source scenes, and correction is not performed with priority on object colors. Whether it is better (in this case, the tungsten light source cannot be corrected and sacrificed) or the color feria phenomenon of the object color with priority given to the light source (the object color is corrected to white because the object color is misidentified as the light source) The idea of camera design has diverged greatly as I closed my eyes.
下記特許文献1は、そのような問題を解決するために、光源が低彩度である確率が多いことに着目して、低彩度の部分でホワイトバランスをとる方法を用いたが、シーン合格率は低いものがあった。つまり、物体色シーンなどは、ほぼ過補正なく救うことができるが、青色の物体色シーンにおいてタングステン光源下で青色物体色を撮影すると、タングステン光源よりも青色の物体色の方が低彩度になってしまうというものである。
In order to solve such a problem,
また、光源シーンにおいても2つ以上の光源が混ざり合った光源などの場合、低彩度の光源のみのホワイトバランスしかかからずに補正が足りなくなってしまうという問題もある。例えば、タングステン光源レストランなどで窓から夜景、ネオンサインなどが見えていた場合、ネオンサインの方が低彩度とみなされて、ホワイトバランスゲイン補正量が足りなくなりタングステン光源が残りすぎた画像になってしまう。このようなシーンは撮影頻度としては決して少なくはない。
本発明は、上記の事実を考慮し、シーンに応じた適切なホワイトバランス制御を行うことができる画像処理装置及び方法を提供することを目的とする。 In view of the above facts, an object of the present invention is to provide an image processing apparatus and method capable of performing appropriate white balance control according to a scene.
請求項1の本発明は、光学像を電気信号に変換する撮像手段を用いて被写体を撮影して得られた画像の画像データを処理する画像処理装置であって、被写体が撮像された画面を複数のエリアに分割し、各エリアごとに色情報を取得する色情報取得手段と、少なくとも光源種に対応する色分布の範囲を示す検出枠を設定し、前記取得した各エリアごとの色情報に基づいて前記検出枠に入るエリアの個数を求める個数獲得手段と、前記求められたエリアの個数から低彩度領域に属するエリアの個数の割合が少ないときは画面における主要光源の比率が低いと判断し、広範囲の色温度に追従する評価値と光源の色味を残す低彩度用評価値との間をとる色評価値であって前記低彩度領域に属するエリアの個数の割合に応じて前記広範囲の色温度に追従する評価値と光源の色味を残す低彩度用評価値との比率を変えた色評価値を算出する色評価値算出手段と、前記算出した色評価値に基づいてホワイトバランスゲイン値を演算する演算手段と、からなる画像処理装置、からなる。
The present invention of
請求項1の本発明によれば、求められたエリアの個数から低彩度領域に属するエリアの個数の割合が少ないときは、通常、光源は低彩度の確率が高いことから、画面における主要光源の比率が低いと判断し、広範囲の色温度に追従する評価値と光源の色味を残す低彩度用評価値との間をとる色評価値を算出する。この色評価値は、前記低彩度領域に属するエリアの個数の割合に応じて前記広範囲の色温度に追従する評価値と光源の色味を残す低彩度用評価値との比率を変えたものである。この比率は画面のシーンによって変化し、主要光源の比率に依存する。すなわち、前記低彩度領域に属するエリアの個数の割合が特に少ないときは、低彩度領域のエリアが本当に光源であると判断できないため、色評価値において光源の色味を残す低彩度用評価値の比率を低くして広範囲の色温度に追従する評価値の比率を高くする。この結果、低彩度領域を基にホワイトバランスゲイン値をとった場合に生じるカラーフェリア等の副作用的要素を防止することができる。なお、前記広範囲の色温度に追従する評価値と光源の色味を残す低彩度用評価値との比率の変更は、画面のシーンによって自動的に行われるようにする。 According to the first aspect of the present invention, when the ratio of the number of areas belonging to the low saturation region is small from the number of areas obtained, the light source usually has a high probability of low saturation. It is determined that the ratio of the light source is low, and a color evaluation value is calculated that takes between an evaluation value that follows a wide range of color temperatures and an evaluation value for low saturation that retains the color of the light source. The color evaluation value is obtained by changing the ratio between the evaluation value that follows the wide range of color temperature and the evaluation value for low saturation that retains the color of the light source according to the ratio of the number of areas belonging to the low saturation region. Is. This ratio varies with the scene on the screen and depends on the ratio of the main light sources. That is, when the ratio of the number of areas belonging to the low saturation area is particularly small, it cannot be determined that the area of the low saturation area is really a light source, so the color evaluation value is for low saturation. The ratio of evaluation values is lowered to increase the ratio of evaluation values that follow a wide range of color temperatures. As a result, it is possible to prevent side effect elements such as color feria that occur when the white balance gain value is obtained based on the low saturation region. The ratio of the evaluation value that follows the wide range of color temperatures and the low saturation evaluation value that retains the color of the light source is automatically changed depending on the scene on the screen.
請求項1、2の本発明によれば、光源特定ができなかった場合でもカラーフェリア等の副作用的要素を防止することができ、かつ画面のシーン合格率をより高めることができるのでシーンに応じた適切なホワイトバランスゲイン値を算出することができ、画質が改善される。 According to the first and second aspects of the present invention, even when the light source cannot be specified, a side effect element such as a color feria can be prevented, and the scene pass rate of the screen can be further increased. Therefore, an appropriate white balance gain value can be calculated, and the image quality is improved.
以下、添付図面に従って本発明に係る画像処理装置として機能するデジタルカメラの好ましい実施の形態について説明する。 A preferred embodiment of a digital camera that functions as an image processing apparatus according to the present invention will be described below with reference to the accompanying drawings.
図1は、本発明の第1の実施形態に係る画像処理装置として機能するデジタルカメラのブロック図である。 FIG. 1 is a block diagram of a digital camera that functions as an image processing apparatus according to the first embodiment of the present invention.
このカメラ10は、画像の記録および再生機能を備えたデジタルカメラであり、カメラ10全体の動作は中央処理装置(CPU)12によって統括制御される。 CPU12は、所定のプログラムに従って本カメラシステムを制御する制御手段として機能するとともに、自動露出(AE)演算、自動焦点調節(AF)演算、自動ホワイトバランス調節(AWB)演算など、各種演算を実施する演算手段として機能する。
The
なお、自動露出、自動焦点調節および自動ホワイトバランス調節はそれぞれAE、AF、AWBと記載することがある。 Note that automatic exposure, automatic focus adjustment, and automatic white balance adjustment may be described as AE, AF, and AWB, respectively.
バス14を介してCPU12と接続されたROM16には、CPU12が実行するプログラムおよび制御に必要な各種データ等が格納されている。なお、不揮発性記憶手段であるROM16は書き換え不能なものであってもよいし、EEPROMのように書き換え可能なものでもよい。
A
また、メモリ(SDRAM)18は、プログラムの展開領域およびCPU12の演算作業用領域として利用されるとともに、画像データや音声データの一時記憶領域として利用される。VRAM20は画像データ専用の一時記憶メモリであり、A領域20AとB領域20Bが含まれている。メモリ18とVRAM20は共用することが可能である。
The memory (SDRAM) 18 is used as a program development area and a calculation work area for the
カメラ10にはモード選択スイッチ22、撮影ボタン24、その他、メニュー/OKキー、十字キー、キャンセルキーなどの操作手段26が設けられている。これら各種の操作部(22〜26)からの信号はCPU12に入力され、CPU12は入力信号に基づいてカメラ10の各回路を制御し、例えば、レンズ駆動制御、撮影動作制御、画像処理制御、画像データの記録/再生制御、画像表示装置28の表示制御などを行う。
The
モード選択スイッチ22は、静止画撮影モード、動画撮影モードと再生モードとを切り換えるための操作手段である。モード選択スイッチ20を操作して可動接片22Aを接点aに接続させると、その信号がCPU12に入力され、カメラ10は静止画撮影モードに設定され、可動接片22Aを接点bに接続させると、カメラ10は動画撮影モードに設定される。また、可動切片22Aを接点cに接続させると、カメラ10は記録済みの画像を再生する「再生モード」に設定される。
The
再生される画像データが静止画である場合には、画像表示装置28には静止画像が表示される。また、再生される画像が動画である場合には、まず、ファイルの代表画像が表示され、インデックスを表示させるか否かを選択する。インデックスを表示させない場合にはファイルの先頭から再生が開始され、インデックスを表示させる場合には、所望のインデックス画像を選択し、再生開始操作を行うと、画像表示装置28には選択されたインデックス画像に対応した画像から動画が再生される。
When the image data to be reproduced is a still image, the still image is displayed on the
撮影ボタン24は、撮影開始の指示を入力する操作ボタンであり、動画撮影においては録画開始(スタート)/停止(ストップ)ボタンとして機能し、静止画撮影においてはレリーズボタンとして機能する。撮影ボタン24は、半押し時にONするS1スイッチと、全押し時にONするS2スイッチとを有する二段ストローク式のスイッチで構成されている。
The
メニュー/OKキーは、画像表示装置28の画面上にメニューを表示させる指令を行うためのメニューボタンとしての機能と、選択内容の確定および実行などを指令するOKボタンとしての機能とを兼備した操作キーである。十字キーは、上下左右の4方向の指示を入力する操作部であり、メニュー画面から項目を選択したり、各メニューから各種設定項目の選択を指示したりするボタン(カーソル移動操作手段)として機能する。また、十字キーの上/下キーは撮影時のズームスイッチあるいは再生時の再生ズームスイッチとして機能し、左/右キーは再生モード時のコマ送り(順方向/逆方向送り)ボタンとして機能する。キャンセルキーは、選択項目など所望の対象の消去や指示内容の取消し、あるいは1つ前の操作状態に戻らせる時などに使用される。
The menu / OK key is an operation having both a function as a menu button for instructing to display a menu on the screen of the
画像表示装置28は、カラー表示可能な液晶ディスプレイで構成されている。画像表示装置28は、撮影時に画角確認用の電子ファインダーとして使用できるとともに、記録済み画像を再生表示する手段として利用される。また、画像表示装置28は、ユーザインターフェース用表示画面としても利用され、必要に応じてメニュー情報や選択項目、設定内容などの情報が表示される。液晶ディスプレイに代えて、有機ELなど他の方式の表示装置(表示手段)を用いることも可能である。
The
デジタルカメラ10は、メディアソケット(メディア装着部)30を有し、メディアソケット30には記録メディア32を装着することができる。記録メディアの形態は特に限定されず、XD−PictureCard(登録商標)、スマートメディア(登録商標)に代表される半導体メモリカード、可搬型小型ハードディスク、磁気ディスク、光ディスク、光磁気ディスクなど、種々の媒体を用いることができる。
The
本発明の実施に際しては、メディアソケットの個数は特に限定されず、複数でもよい。また、画像データを記録する手段はリムーバブルメディアに限らず、デジタルカメラ10に内蔵された記録媒体(内部メモリ)であってもよい。
In carrying out the present invention, the number of media sockets is not particularly limited, and a plurality of media sockets may be used. Further, the means for recording the image data is not limited to the removable medium, but may be a recording medium (internal memory) built in the
メディアコントローラ34は、メディアソケット30に装着される記録メディア32に適した入出力信号の受渡しを行うために所要の信号変換を行う。
The
また、デジタルカメラ10はパソコンその他の外部機器と接続するための通信手段としてUSBインターフェース部36を備えている。図示せぬUSBケーブルを用いてデジタルカメラ10を外部機器と接続することにより、外部機器との間でデータの受渡しが可能となる。もちろん、通信方式はUSBに限らず、IEEE1394やBluetooth その他の通信方式を適用してもよい。
The
次に、デジタルカメラ10の撮影機能について説明する。
Next, the photographing function of the
モード選択スイッチ22によって静止画撮影モードまたは動画撮影モードが選択されると、CCD固体撮像素子(以下CCDと記載)38を含む撮像部に電源が供給され、撮影可能な状態になる。
When the still image shooting mode or the moving image shooting mode is selected by the
レンズユニット40は、フォーカスレンズを含む撮影レンズ42と絞り兼用メカシャッター44とを含む光学ユニットである。レンズユニット40は、CPU12によって制御されるレンズ駆動部46、絞り駆動部48によって電動駆動され、ズーム制御、フォーカス制御およびアイリス制御が行われる。
The
レンズユニット40を通過した光は、CCD38の受光面に結像される。CCD38の受光面には多数のフォトダイオード(受光素子)が二次元的に配列されており、各フォトダイオードに対応して赤(R)、緑(G)、青(B)の原色カラーフィルタが所定の配列構造(ベイヤー、Gストライプなど)で配置されている。また、CCD38は、各フォトダイオードの電荷蓄積時間(シャッタースピード)を制御する電子シャッター機能を有している。CPU12は、タイミングジェネレータ50を介してCCD38での電荷蓄積時間を制御する。なお、CCD38に代えてMOS型など他の方式の撮像素子を用いてもよい。
The light that has passed through the
CCD38の受光面に結像された被写体像は、各フォトダイオードによって入射光量に応じた量の信号電荷に変換される。各フォトダイオードに蓄積された信号電荷は、CPU12の指令に従いタイミングジェネレータ50から与えられる駆動パルスに基づいて信号電荷に応じた電圧信号(画像信号)として順次読み出される。
The subject image formed on the light receiving surface of the
CCD38から出力された信号はアナログ処理部(CDS/AMP)52に送られ、ここで画素ごとのR、G、B信号がサンプリングホールド(相関二重サンプリング処理)され、増幅された後、A/D変換器54に加えられる。A/D変換器54は、順次入力するR、G、B信号をデジタル信号に変換して画像入力コントローラ56に出力する。
The signal output from the
画像信号処理回路58は、画像入力コントローラ56を介して入力するデジタルの画像信号をCPU12の指令に従って処理する。すなわち、画像信号処理回路58は、同時化回路(単板CCDのカラーフィルタ配列に伴う色信号の空間的なズレを補間して色信号を同時式に変換する処理回路)、輝度・色差信号生成回路、ガンマ補正回路、輪郭補正回路、ホワイトバランス補正回路等を含む画像処理手段として機能し、CPU12からのコマンドに従ってメモリ18を活用しながら所定の信号処理を行う。
The image signal processing circuit 58 processes a digital image signal input via the
なお、画像入力コントローラ56には、メモリ18およびVRAM20のデータ読み出し制御、書き込み制御を行うメモリコントローラが含まれている。
Note that the
画像信号処理回路58に入力されたRGBの画像データは、画像信号処理回路58において輝度信号(Y信号)および色差信号(Cr,Cb 信号)に変換されるとともに、ガンマ補正等の所定の処理が施される。画像信号処理回路58で処理された画像データはVRAM20に格納される。
The RGB image data input to the image signal processing circuit 58 is converted into a luminance signal (Y signal) and a color difference signal (Cr, Cb signal) by the image signal processing circuit 58, and predetermined processing such as gamma correction is performed. Applied. The image data processed by the image signal processing circuit 58 is stored in the
撮影画像を画像表示装置28にモニタ出力する場合、VRAM20から画像データが読み出され、バス14を介してビデオエンコーダ60に送られる。ビデオエンコーダ60は、入力された画像データを表示用の所定方式の信号(例えば、NTSC方式のカラー複合映像信号)に変換して画像表示装置28に出力する。
When the captured image is output to the
CCD38から出力される画像信号によって、1コマ分の画像を表す画像データがA領域20AとB領域20Bとで交互に書き換えられる。VRAM20のA領域20AおよびB領域20Bのうち、画像データが書き換えられている方の領域以外の領域から、書き込まれている画像データが読み出される。このようにしてVRAM20内の画像データが定期的に書き換えられ、その画像データから生成される映像信号が画像表示装置28に供給されることにより、撮像中の映像がリアルタイムに画像表示装置28に表示される。撮影者は、画像表示装置28に表示される映像(スルームービー画)によって撮影画角を確認できる。
Image data representing an image for one frame is rewritten alternately in the
撮影ボタン24が半押しされ、S1がオンすると、デジタルカメラ10はAEおよびAF処理を開始する。すなわち、CCD38から出力された画像信号はA/D変換後に画像入力コントローラ56を介してAF検出回路62並びにAE/AWB検出回路64に入力される。
When the
AE/AWB検出回路64は、1画面を複数のエリア(例えば、8×8、16×16)に分割し、分割エリアごとにRGB信号を積算する回路を含み、その積算値をCPU12に提供する。CPU12は、AE/AWB検出回路64から得た積算値に基づいて被写体の明るさ(被写体輝度)を検出し、撮影に適した露出値(撮影EV値)を算出する。求めた露出値と所定のプログラム線図に従い、絞り値とシャッタースピードが決定され、これに従いCPU12はCCD38の電子シャッターおよびアイリスを制御して適正な露光量を得る。
The AE /
また、AE/AWB検出回路64は、分割エリアごとにRGB信号の色別の平均積算値を算出し、その算出結果をCPU12に提供する。CPU12は、Rの積算値、Bの積算値、Gの積算値を得て、R/GおよびB/Gの比を求め、これらR/G、B/Gの値から後述する方法でホワイトバランス調整値を算出し、その算出したホワイトバランス調整値に従って、ホワイトバランス調整回路のアンプゲインを制御し、各色チャンネルの信号に補正をかける。なお、ホワイトバランス制御の詳細は後述する。
The AE /
本カメラ10におけるAF制御は、例えば映像信号のG信号の高周波成分が極大になるようにフォーカシングレンズ(撮影レンズ42を構成するレンズ光学系のうちフォーカス調整に寄与する移動レンズ)を移動させるコントラストAFが適用される。すなわち、AF検出回路62は、G信号の高周波成分のみを通過させるハイパスフィルタ、絶対値化処理部、画面内(例えば、画面中央部)に予め設定されているフォーカス対象エリア内の信号を切り出すAFエリア抽出部、およびAFエリア内の絶対値データを積算する積算部から構成される。
The AF control in the
AF検出回路62で求めた積算値のデータはCPU12に通知される。CPU12は、レンズ駆動部46を制御してフォーカシングレンズを移動させながら、複数のAF検出ポイントで焦点評価値(AF評価値)を演算し、評価値が極大となるレンズ位置を合焦位置として決定する。そして、求めた合焦位置にフォーカシングレンズを移動させるようにレンズ駆動部46を制御する。なお、AF評価値の演算はG信号を利用する態様に限らず、輝度信号(Y信号)を利用してもよい。
The integrated value data obtained by the
撮影ボタン24が半押しされ、S1オンによってAE/AF処理が行われ、撮影ボタン24が全押しされ、S2オンによって記録用の撮影動作がスタートする。S2オンに応動して取得された画像データは画像信号処理回路58において輝度/色差信号(Y/C信号)に変換され、ガンマ補正等の所定の処理が施された後、メモリ18に格納される。
The
メモリ18に格納されたY/C信号は、圧縮伸張回路66によって所定のフォーマットに従って圧縮された後、メディアコントローラ34を介して記録メディア32に記録される。例えば、静止画についてはJPEG(Joint Photographic Experts Group)形式、動画についてはモーションJPEG形式で記録される。
The Y / C signal stored in the
モーションJPEG方式では、CCD38から取得した画像データを一旦、内部のメモリ18に記憶した後、画像信号処理回路58において輝度/色差信号(Y/C信号)に変換し、1画像内でJPEG圧縮しながら、外部の記録メディア32に一定のフレームレート(例えば、30フレーム/秒)で静止画を連続的に保存していく。
In the motion JPEG method, the image data acquired from the
動画のファイル形式はモーションJPEGに限定されず、MPEGなど他のファイル形式を適用してもよい。また、静止画ファイルの記録形式もJPEG形式に限定されず、TIF 形式やBMP 形式など他の形式を用いてもよい。MPEG方式の場合は、フレーム内圧縮およびフレーム間圧縮を行いながら外部の記録メディア32に連続的に記録する。
The file format of the moving image is not limited to motion JPEG, and other file formats such as MPEG may be applied. Also, the recording format of the still image file is not limited to the JPEG format, and other formats such as a TIF format and a BMP format may be used. In the case of the MPEG system, recording is continuously performed on the
動画撮影中には、いわゆる「山登り方式」の連続的なAF処理(コンティニアスAF)を行う。すなわち、フォーカシングレンズを光軸に沿って前後に微小移動させて、焦点評価値の増減方向をチェックしながら、AF評価値の極大点まで、徐々にフォーカシングレンズを移動させる。 During moving image shooting, so-called “mountain climbing” continuous AF processing (continuous AF) is performed. That is, the focusing lens is slightly moved back and forth along the optical axis, and the focusing lens is gradually moved to the maximum point of the AF evaluation value while checking the increase / decrease direction of the focus evaluation value.
動画撮影時の音声はマイク(図1には不図示)によって検出され、その検出信号(音声信号)は、A/D変換器(図1には不図示)によってデジタル信号に変換され、音声信号処理回路(図1には不図示)に送られる。音声信号処理回路はバス14に接続されており、メモリ18を利用しながらCPU12の指令に従い音声データを所定の信号形式に変換する。こうして生成された音声データは、メモリ18に記憶され、画像データとともに圧縮伸張回路66で圧縮された後、記録メディア32に記録される。
The sound during video shooting is detected by a microphone (not shown in FIG. 1), and the detection signal (sound signal) is converted into a digital signal by an A / D converter (not shown in FIG. 1). It is sent to a processing circuit (not shown in FIG. 1). The audio signal processing circuit is connected to the
録画開始後に、もう一度撮影ボタン24を押下(S1オン)すると録画動作が停止する。なお、撮影ボタン24を押下継続している期間、録画動作を行い、押下解除により録画を停止させる態様や、録画開始後の一定時間で録画を自動停止させる態様などもある。
After the start of recording, when the photographing
モード選択スイッチ22により再生モードが選択されると、記録メディア32に記録されている最終の画像ファイル(最後に記録されたファイル)の圧縮データが読み出される。最後の記録に係るファイルが静止画ファイルの場合、この読み出された画像圧縮データは、圧縮伸張回路66を介して非圧縮のYC信号に伸張され、画像信号処理回路58およびビデオエンコーダ60を介して表示用の信号に変換された後、画像表示装置28に出力される。これにより、当該ファイルの画像内容が画像表示装置28の画面上に表示される。
When the playback mode is selected by the
再生対象ファイルが動画ファイルの場合には、インデックス画像が表示され、動画再生開始の指示を受け付ける画面になる。表示されているインデックス画像から所望のインデックス画像を選択し、操作部から所定の操作(例えば、十字キーの下キー押下)を行うと、選択されたインデックス画像に対応した動画ファイルの再生処理がスタートし、画像表示装置28に動画映像が表示されるとともに、音声信号処理回路において再生処理された音声データがD/A変換器を介してスピーカ(図1には不図示)に出力され、動画とともに記録した音声も再生される。
When the reproduction target file is a moving image file, an index image is displayed and a screen for accepting an instruction to start moving image reproduction is displayed. When a desired index image is selected from the displayed index images and a predetermined operation (for example, pressing the down key of the cross key) is performed from the operation unit, the playback process of the moving image file corresponding to the selected index image starts. Then, the moving image is displayed on the
静止画の一コマ再生中(動画の先頭フレーム再生中も含む。)に、十字キーの右キー又は左キーを操作することによって、再生対象のファイルを切り換えること(順コマ送り/逆コマ送り)ができる。コマ送りされた位置の画像ファイルが記録メディア32から読み出され、上記と同様にして静止画像や動画が画像表示装置28に再生表示される。
During single-frame playback of a still image (including playback of the first frame of a moving image), the file to be played is switched by operating the right or left key of the four-way controller (forward / reverse frame advance). Can do. The image file at the frame-advanced position is read from the
次に、図2乃至6を用いて、上記の如く構成されたデジタルカメラ10のオートホワイトバランス調節機能について説明する。
Next, the auto white balance adjustment function of the
図2は、本実施形態に係るデジタルカメラ10のオートホワイトバランス処理に関連する部分のブロック図である。図2中、図1と同一または類似するする部分には同一の符号を付しその説明は省略する。
FIG. 2 is a block diagram of a portion related to the auto white balance process of the
図2のデジタル信号処理回路100は図1中、画像信号処理回路58の一部であり、同時化回路102、ホワイトバランス調整回路104、ガンマ補正回路106、YC信号作成回路108、およびメモリ110から構成されている。ここで、メモリ110は図1のメモリ18と同一であるが、本発明の理解を容易にするために図2ではメモリ18とメモリ110とが別々に記載されている。なお、図1ではメモリ18とメモリ110を合わせてメモリ18と記載されている。
A digital
A/D変換器54から出力されたR、G、B信号は画像入力コントローラ56を介して一旦メモリ18に格納される。同時化回路102は、メモリ18から読み出された点順次のR、G、B信号を同時式に変換し、R、G、B信号を同時にホワイトバランス調整回路104に出力する。ホワイトバランス調整回路104は、R、G、B信号のデジタル値をそれぞれ増減するための乗算器104R、104G、104Bから構成されており、R、G、B信号は、それぞれ乗算器104R、104G、104Bに加えられる。
The R, G, and B signals output from the A /
乗算器104R、104G、104Bの他の入力には、CPU12からホワイトバランス制御するためのホワイトバランス補正値(ゲイン値)Rg、Gg、Bgが加えられており、乗算器104R、104G、104Bはそれぞれ2入力を乗算し、この乗算によってホワイトバランス調整されたR’、G’、B’信号をガンマ補正回路106に出力する。
White balance correction values (gain values) Rg, Gg, and Bg for white balance control are added from the
ホワイトバランス補正値をRg、Gg、Bg、補正する前の信号をR、G、Bとし、ホワイトバランス調整回路104での補正結果をR’、G’、B’とすると、補正結果R’、G’、B’は次式 によって表される。
Assuming that the white balance correction values are Rg, Gg, Bg, the signals before correction are R, G, B, and the correction results in the white
[数1]
R’=Rg×R
G’=Gg×G
B’=Bg×B
ガンマ補正回路106は、ホワイトバランス調整されたR’、G’、B’信号が所望のガンマ特性となるように入出力特性を変更し、YC信号作成回路108に出力する。YC信号作成回路108は、ガンマ補正されたR、G、B信号から輝度信号Yと色差信号であるクロマ信号Cr、Cbとを作成する。これらの輝度信号Yとクロマ信号Cr、Cbは、メモリ110に格納される。メモリ110内のYC信号を読み出し、画像表示装置28に出力することにより、動画または静止画を画像表示装置28に表示させることができる。
[Equation 1]
R ′ = Rg × R
G ′ = Gg × G
B ′ = Bg × B
The
次に、オートホワイトバランス(AWB)制御の流れを説明する。 Next, the flow of auto white balance (AWB) control will be described.
図6は、オートホワイトバランス制御の流れを示したフローチャートである。 FIG. 6 is a flowchart showing the flow of auto white balance control.
撮影ボタン全押し(S2オン)に応動してオートホワイトバランス制御が開始され(ステップ200)、CCD38より取得された1画面分のRGBデータはメモリ18に記憶される。撮像画面は複数のエリア(例えば8×8、16×16など)に分割され、エリアごとにR、G、B信号の色別の平均積算値が算出される(ステップ202)。
The auto white balance control is started in response to full depression of the shooting button (S2 ON) (step 200), and RGB data for one screen acquired from the
得られた色別の積算値からR信号とG信号との比R/G、およびB信号とG信号との比B/Gが求められる(ステップ204)。 The ratio R / G between the R signal and the G signal and the ratio B / G between the B signal and the G signal are obtained from the obtained integrated value for each color (step 204).
なお、エリアごとのR、G、B信号の色別平均積算値は、図2に示した積算回路112によって算出され、CPU12に送られる。また積算回路112とCPU12との間には乗算器112R、112G、112Bが設けられており、乗算器112R、112G、112Bには、機器のばらつきを調整するため調整ゲインが加えられるようになっている。なお、図2に示した積算回路112は図1に示したAE/AWB検出回路64に含まれている。
The average integrated value for each color of the R, G, and B signals for each area is calculated by the integrating circuit 112 shown in FIG. 2 and sent to the
ここで、ホワイトバランスゲイン補正量を算出するためには、色評価値HCLiを算出する必要がある。色評価値HCLiは、低彩度のものを光源とするAWB計算の重み付き係数であり、低彩度のものを光源と推定する彩度評価値HSi及び明るさの要素から計算された係数である。すなわち、 Here, in order to calculate the white balance gain correction amount, it is necessary to calculate the color evaluation value HCLi. The color evaluation value HCLi is a weighted coefficient for AWB calculation using a low-saturation light source as a light source, and is a coefficient calculated from a saturation evaluation value HSi and a brightness element for estimating a low-saturation light source. is there. That is,
[数2]
F(色評価値HCLi)=F(彩度評価値HSi)×F(明るさの要素)
である。明るさの要素は、撮影露出値から算出されるEV値によって決定され、被写体の明るさによって重み付けされる関数である。ここで、各エリアの輝度(EV値Evi)は、次式によって求められる。
[Equation 2]
F (color evaluation value HCLi) = F (saturation evaluation value HSi) × F (element of brightness)
It is. The brightness element is a function that is determined by the EV value calculated from the photographic exposure value and is weighted by the brightness of the subject. Here, the luminance (EV value Evi) of each area is obtained by the following equation.
[数3]
Evi=Ev+log2 (Gi/45)
但し、Ev:撮影EV値
Gi:各エリアのGの平均積算値
に基づいて計算する。なお、上記式中の45は、A/D変換後の値の中での適正値である。
[Equation 3]
Evi = Ev + log2 (Gi / 45)
However, Ev: Shooting EV value Gi: Calculated based on the average integrated value of G in each area. In addition, 45 in the said formula is an appropriate value in the value after A / D conversion.
彩度評価値HSiは、以下の手順で算出される。 The saturation evaluation value HSi is calculated by the following procedure.
彩度評価値は、低彩度を光源とするシステムを用いた距離判別アルゴリズムを用いて物体色と光源とを分離するものである。すなわち、このアルゴリズムは、以下に述べる色温度別に枠が用意された軸上において、最も彩度が低い検出枠の分布とその他検出枠の分布との距離を求め、その他検出枠の分布が前記最も彩度が低い検出枠の分布に近ければ近いほど最も彩度が低い検出枠の分布は光源らしいと判断して評価値を高くする評価値換算法である。 The saturation evaluation value is used to separate the object color and the light source using a distance discrimination algorithm using a system using low saturation as the light source. That is, this algorithm obtains the distance between the distribution of the detection frame with the lowest saturation and the distribution of the other detection frames on the axis on which the frame is prepared for each color temperature described below, and the distribution of the other detection frames is the highest. This is an evaluation value conversion method in which the closer to the distribution of detection frames with lower saturation, the higher the evaluation value is determined by determining that the distribution of detection frames with the lowest saturation seems to be a light source.
まず、前記エリアごとに求められる色情報(R/G、B/G)が、それぞれのエリアが図3の表色座標300上に表された検出枠のうち何れの検出枠に入るかを判別するために使用される。なお、図3における日陰検出枠や昼白色検出枠等の検出枠は、横軸をR/G×50、たて軸をB/G×100とする表色座標300上に表された枠であり、検出枠ごとに光源種などの色分布の範囲を規定するものである。 First, the color information (R / G, B / G) obtained for each area determines which detection frame is included in the detection frames represented on the color coordinate 300 of FIG. Used to do. The detection frames such as the shade detection frame and the daylight white detection frame in FIG. 3 are frames represented on the color coordinate 300 with the horizontal axis being R / G × 50 and the vertical axis being B / G × 100. Yes, a range of color distribution such as a light source type is defined for each detection frame.
図3では、青空検出枠、日陰検出枠、昼光色検出枠、晴れ検出枠、緑検出枠、昼白色検出枠、タングステン1検出枠、タングステン2検出枠、タングステン3検出枠が示されている。ただし、検出枠の種類や数、設定範囲などについては本例に限定されず、多様な設計が可能である。
FIG. 3 shows a blue sky detection frame, a shade detection frame, a daylight color detection frame, a sunny detection frame, a green detection frame, a daylight white detection frame, a
図3に示した検出枠を用い、撮像画面の各エリアに対応する256点の分布を得て、256点の分布を検出枠ごとに平均化する。即ち、各検出枠に出力された点のみに関して、各検出枠に入った個数と各検出枠での平均座標(Ri/Gi,Bi/Gi)とが算出される(図6のステップ206)。 Using the detection frames shown in FIG. 3, a distribution of 256 points corresponding to each area of the imaging screen is obtained, and the distribution of 256 points is averaged for each detection frame. That is, for only the points that are output to each detection frame, the number that has entered each detection frame and the average coordinates (Ri / Gi, Bi / Gi) in each detection frame are calculated (step 206 in FIG. 6).
図3の表色座標300の原点(グレー)から、分布が生じた各検出枠の上記平均座標(Ri/Gi,Bi/Gi)までの距離ΔSiを求め(図6のステップ208)、最も彩度(R/G軸,B/G軸での距離)が原点に近いものを光源らしいとして定義し(ステップ210、212)、最も彩度の低い検出枠を光源とする。
A distance ΔSi from the origin (gray) of the color coordinate 300 in FIG. 3 to the average coordinate (Ri / Gi, Bi / Gi) of each detection frame in which the distribution has occurred is obtained (
すなわち、ΔSiは以下の式によって求められる。 That is, ΔSi is obtained by the following equation.
[数4]
ΔSi={(1−Ri/Gi)2 +(1−Bi/Gi)2 }1/2
次に、光源らしいと定義された検出枠の平均座標から他の検出枠の平均座標までの彩度距離ΔDi(R/G軸、B/G軸上のもの)を求める(ステップ214)。ここで、光源の平均座標(Ri/Gi,Bi/Gi)を(Xn、Yn)と置き換える。(Xn、Yn)は低彩度検出枠平均値であるので、この低彩度検出枠平均値(Xn、Yn)から各枠座標平均(Xi,Yi)の距離ΔDiは、以下の式によって求められる。
[Equation 4]
ΔSi = {(1−Ri / Gi) 2 + (1−Bi / Gi) 2} 1/2
Next, a saturation distance ΔDi (on the R / G axis and B / G axis) from the average coordinate of the detection frame defined as likely to be a light source to the average coordinate of another detection frame is obtained (step 214). Here, the average coordinates (Ri / Gi, Bi / Gi) of the light source are replaced with (Xn, Yn). Since (Xn, Yn) is the low saturation detection frame average value, the distance ΔDi of each frame coordinate average (Xi, Yi) from this low saturation detection frame average value (Xn, Yn) is obtained by the following equation. It is done.
[数5]
ΔDi={(Xn−Xi)2 +(Yn−Yi)2 }1/2
次に、光源からの距離に応じて、分布の存在する各検出枠での色情報の補正量を変えるために、図4の関数を用いて彩度評価値HSiを決定する(ステップ216)。図4の関数は、平均座標が低彩度検出枠から近い位置の分布には彩度評価値を大きくして光源らしいと補正し、平均座標が低彩度検出枠から遠くなるにしたがってその分布はもともと持っている色の影響力が強い物体色として彩度評価値を徐徐に下げるようにするものである。
[Equation 5]
ΔDi = {(Xn−Xi) 2 + (Yn−Yi) 2} 1/2
Next, in order to change the correction amount of the color information in each detection frame where the distribution exists according to the distance from the light source, the saturation evaluation value HSi is determined using the function of FIG. 4 (step 216). The function shown in FIG. 4 corrects the distribution of the position where the average coordinates are close to the low saturation detection frame as a light source by increasing the saturation evaluation value, and distributes the distribution as the average coordinates become farther from the low saturation detection frame. Is to gradually lower the saturation evaluation value as an object color that has a strong influence of the colors it has.
つまり、R/G軸,B/G軸上でみると、図5のようになる。図5において、第一近隣円400にあるものは、低彩度検出枠からの距離も近く、極めて光源らしいと判断できる。第二近隣円402の外側にあるものは、この円から離れれば離れるほど物体色の確率が高いと判定され、彩度評価値は低くなる。
That is, when viewed on the R / G axis and the B / G axis, it is as shown in FIG. In FIG. 5, the one in the first
以上の処理により、彩度評価値HSiが出力される(ステップ218)。 Through the above processing, the saturation evaluation value HSi is output (step 218).
その後、上記[数2]の式により、色評価値HCLiが算出される(ステップ220)。 Thereafter, the color evaluation value HCLi is calculated by the above equation (2) (step 220).
算出された色評価値HCLiを用いてホワイトバランスゲイン補正量を求める。 A white balance gain correction amount is obtained using the calculated color evaluation value HCLi.
まず、それぞれの検出枠の座標平均値をグレーにもっていくようなR/G軸,B/G軸ゲイン補正量Gri,Gbiを求める(ステップ222)。そして、下記の式により、色評価値HCLiとの重み付け処理によって、最終R/G,B/GゲインGr’、Gb’が算出される(ステップ224)。 First, R / G-axis and B / G-axis gain correction amounts Gri and Gbi are calculated so as to bring the coordinate average value of each detection frame to gray (step 222). Then, final R / G and B / G gains Gr ′ and Gb ′ are calculated by weighting processing with the color evaluation value HCLi according to the following equation (step 224).
[数6]
Gr’=Σ(Gri×HCLi)/ΣHCLi
Gb’=Σ(Gbi×HCLi)/ΣHCLi
このようにして、ホワイトバランスゲインGr’、Gb’が算出されるとオートホワイトバランス制御は終了する。
[Equation 6]
Gr ′ = Σ (Gri × HCLi) / ΣHCLi
Gb ′ = Σ (Gbi × HCLi) / ΣHCLi
In this way, when the white balance gains Gr ′ and Gb ′ are calculated, the auto white balance control ends.
第1の実施の形態により、低彩度領域を光源と推定し、光源からのR/G軸、B/G軸上の色の距離に応じて重み付けした評価値を算出し、その評価値に基づいてホワイトバランスゲイン補正値を演算することにより、物体色の過補正を防止することができ、カメラの画質が改善される。 According to the first embodiment, a low saturation region is estimated as a light source, and an evaluation value that is weighted according to the color distance on the R / G axis and B / G axis from the light source is calculated. By calculating the white balance gain correction value based on this, overcorrection of the object color can be prevented, and the image quality of the camera is improved.
次に、第2の実施の形態に係る画像処理装置として機能するデジタルカメラについて図7〜9を用いて説明する。 Next, a digital camera that functions as an image processing apparatus according to the second embodiment will be described with reference to FIGS.
第2の実施の形態は、シーンによって光源の色味を生かした補正量を好む場合と、例えばグレーのものはグレーに撮って欲しい場合とがあることに着目し、光源らしさを生かすホワイトバランスゲイン補正をする場合と、シーン依存で完全追従するホワイトバランスゲイン補正をする場合との比重を切り替えて補正できる機能を持つことを特徴としている。これによって、シーン合格率をより高いものにすることができる。 The second embodiment pays attention to the fact that there are cases in which a correction amount that makes use of the color of the light source is preferred depending on the scene, and cases in which, for example, gray ones are desired to be taken in gray, white balance gain that makes use of the light source characteristics It is characterized by having a function that can be corrected by switching the specific gravity between the case of correcting and the case of performing white balance gain correction that completely follows depending on the scene. As a result, the scene pass rate can be made higher.
第2の実施形態に係る画像処理装置として機能するデジタルカメラの構成は第1の実施形態のものと同様であるので説明を省略する。 Since the configuration of the digital camera that functions as the image processing apparatus according to the second embodiment is the same as that of the first embodiment, the description thereof is omitted.
ホワイトバランス補正値をRg、Gg、Bg、補正する前の信号をR、G、Bとし、ホワイトバランス調整回路104での補正結果をR’、G’、B’とすると、補正結果R’、G’、B’が上記〔数1〕の式によって表されることも第1の実施形態と同様である。ホワイトバランスゲイン補正量の算出方法が第1の実施形態と異なるのでそれを説明する。
Assuming that the white balance correction values are Rg, Gg, Bg, the signals before correction are R, G, B, and the correction results in the white
第2の実施の形態によるオートホワイトバランス(AWB)制御の流れを説明する。 The flow of auto white balance (AWB) control according to the second embodiment will be described.
図9は、第2の実施の形態に係るオートホワイトバランス制御の流れを示したフローチャートである。 FIG. 9 is a flowchart showing a flow of auto white balance control according to the second embodiment.
撮影ボタン全押し(S2オン)に応動してオートホワイトバランス制御が開始され(ステップ230)、CCD38より取得された1画面分のRGBデータはメモリ18に記憶される。撮像画面は複数のエリア(例えば8×8、16×16など)に分割され、エリアごとにR、G、B信号の色別の平均積算値が算出される(ステップ232)。
The auto white balance control is started in response to full depression of the shooting button (S2 ON) (step 230), and the RGB data for one screen acquired from the
得られた色別の積算値からR信号とG信号との比R/G、およびB信号とG信号との比B/Gが求められる(ステップ234)。 A ratio R / G between the R signal and the G signal and a ratio B / G between the B signal and the G signal are obtained from the obtained integrated value for each color (step 234).
なお、エリアごとのR、G、B信号の色別平均積算値は、図2に示した積算回路112によって算出され、CPU12に送られる。また積算回路112とCPU12との間には乗算器112R、112G、112Bが設けられており、乗算器112R、112G、112Bには、機器のばらつきを調整するため調整ゲインが加えられるようになっている。なお、図2に示した積算回路112は図1に示したAE/AWB検出回路64に含まれている。
The average integrated value for each color of the R, G, and B signals for each area is calculated by the integrating circuit 112 shown in FIG. 2 and sent to the
ここで、ホワイトバランスゲイン補正量を算出するためには、重み付け評価値HCLi’を算出する必要がある。重み付け評価値HCLi’は、AWB計算の重み付き係数であり、色評価値HCLi及び明るさの要素から計算された係数である。すなわち、 Here, in order to calculate the white balance gain correction amount, it is necessary to calculate the weighted evaluation value HCLi ′. The weighted evaluation value HCLi ′ is a weighted coefficient for AWB calculation, and is a coefficient calculated from the color evaluation value HCLi and brightness elements. That is,
[数7]
F(重み付き評価値HCLi’)=F(色評価値HCLi)×F(明るさの要素)
である。明るさの要素は、撮影露出値から算出されるEV値によって決定され、被写体の明るさによって重み付けされる関数である。ここで、各エリアの輝度(EV値Evi)は、次式によって求められる。
[Equation 7]
F (weighted evaluation value HCLi ′) = F (color evaluation value HCLi) × F (element of brightness)
It is. The brightness element is a function that is determined by the EV value calculated from the photographic exposure value and is weighted by the brightness of the subject. Here, the luminance (EV value Evi) of each area is obtained by the following equation.
[数8]
Evi=Ev+log2 (Gi/45)
但し、Ev:撮影EV値
Gi:各エリアのGの平均積算値
に基づいて計算する。なお、上記式中の45は、A/D変換後の値の中での適正値である。
[Equation 8]
Evi = Ev + log2 (Gi / 45)
Where Ev: EV value
Gi: Calculated based on the average integrated value of G in each area. In addition, 45 in the said formula is an appropriate value in the value after A / D conversion.
色評価値HCLiは、シーンによって完全にグレーになる評価値(追従評価値HCi)を算出したり彩度評価値HSiに切り替えたりできる関数である。色評価値HCLiは、追従評価値HCiと彩度評価値HSiとを用いて以下の式で表される。 The color evaluation value HCLi is a function that can calculate an evaluation value (following evaluation value HCi) that becomes completely gray depending on the scene, or switch to the saturation evaluation value HSi. The color evaluation value HCLi is expressed by the following equation using the follow-up evaluation value HCi and the saturation evaluation value HSi.
[数9]
α=α’×β
HCLi=HSi×α+HCi×(1−α) (α<=1)
α’は各色温度別光源ごとにもつ値であるので、光源によって彩度評価値を重視することも可能である。αを形成する補正量βは図7の関数を用いて決定される。
[Equation 9]
α = α '× β
HCLi = HSi × α + HCi × (1−α) (α <= 1)
Since α ′ is a value for each light source for each color temperature, it is possible to place importance on the saturation evaluation value depending on the light source. The correction amount β forming α is determined using the function of FIG.
図7の関数では、低彩度を光源とした場合の低彩度の分布の個数(画面の面積比率)が少ないときは本当に光源であると判断できないため、彩度評価値の比重を減らすものである。これによって、全体のシーン重視の色評価値が算出される。 The function of FIG. 7 reduces the specific gravity of the saturation evaluation value because it cannot be determined that the light source is really a light source when the number of low saturation distributions (area ratio of the screen) is small when low saturation is used as the light source. It is. As a result, a color evaluation value for the entire scene is calculated.
追従評価値HCiは、次の計算で算出される(ステップ236)。 The follow-up evaluation value HCi is calculated by the following calculation (step 236).
[数10]
F(追従評価値HCi)=F(分布の個数)×F(明るさの要素)
追従評価値HCiは、図8に示すように、R/G軸、B/G軸上において画面中の色の分布の中にある色の集団(かたまり)を検出し、それぞれのかたまりの個数から算出される評価値であり、分布の個数による関数である。つまり、追従評価値は画面の面積比率と明るさから算出されるものである。図8のようなR/G軸、B/G軸分布上で検出個数が多いものを中心に重み付けして追従評価値が決定される。
[Equation 10]
F (follow-up evaluation value HCi) = F (number of distributions) × F (element of brightness)
As shown in FIG. 8, the follow-up evaluation value HCi detects a group of colors (lumps) in the color distribution on the screen on the R / G axis and B / G axis, and determines the number of the respective chunks. This is a calculated evaluation value, which is a function of the number of distributions. That is, the follow-up evaluation value is calculated from the screen area ratio and brightness. The follow-up evaluation value is determined by weighting a large number of detected numbers on the R / G axis and B / G axis distribution as shown in FIG.
上記〔数9〕の式では、光源らしさをみる彩度評価値HSiに画面の色支配率をみる追従評価値HCiを混合させているが、これにより、彩度評価値の副作用ともいえるMIX光などの、光源判別がうまくいかず補正量が足りなくなった場合の不具合を緩和させる効果をもつ。 In the above equation (9), the saturation evaluation value HSi that looks like a light source is mixed with the follow-up evaluation value HCi that looks at the color dominance ratio of the screen. This has the effect of alleviating inconveniences when the light source discrimination is not successful and the correction amount is insufficient.
この後、追従評価値HCiが出力される(ステップ238)。 Thereafter, the follow-up evaluation value HCi is output (step 238).
彩度評価値HSiは第1の実施の形態と同様に算出される(ステップ240)。 The saturation evaluation value HSi is calculated in the same manner as in the first embodiment (step 240).
そして、色評価値HCLiが〔数9〕の式により算出され(ステップ242)、出力される(ステップ244)。 Then, the color evaluation value HCLi is calculated by the equation [Equation 9] (step 242) and output (step 244).
その後、上記方法により重み付き評価値HCLi’が算出されて(ステップ246)、最終的なオートホワイトバランスゲインは、以降、第1の実施の形態と同様な方法で算出される(ステップ248,250)。
Thereafter, the weighted evaluation value HCLi ′ is calculated by the above method (step 246), and the final auto white balance gain is thereafter calculated by the same method as in the first embodiment (
第2の実施の形態により、広範囲追従アルゴリズムと光源の色味を残す低彩度アルゴリズムとの間をとるような切り替えがシーンによって自動ででき、カメラの画質が改善される。完全色温度追従型アルゴリズムと低彩度光源アルゴリズムとの比率は、シーンによって変化し、主要光源確率に依存する。 According to the second embodiment, switching between the wide-range tracking algorithm and the low-saturation algorithm that keeps the color of the light source can be automatically performed according to the scene, and the image quality of the camera is improved. The ratio between the perfect color temperature tracking algorithm and the low saturation light source algorithm varies from scene to scene and depends on the main light source probability.
上記第1、第2の実施形態では、表色座標にR/G、B/G座標系を用いたが、表色座標系にはR、G、B座標系等、他の座標系を用いてもよい。 In the first and second embodiments, the R / G and B / G coordinate systems are used for the color coordinate, but other coordinate systems such as the R, G, and B coordinate systems are used for the color coordinate system. May be.
10…デジタルカメラ、12…CPU、18…メモリ、24…撮影ボタン、58…画像信号処理回路、64…AE/AWB検出回路、104…ホワイトバランス調整回路、112…積算回路、300…表色座標
DESCRIPTION OF
Claims (2)
被写体が撮像された画面を複数のエリアに分割し、各エリアごとに色情報を取得する色情報取得手段と、
少なくとも光源種に対応する色分布の範囲を示す検出枠を設定し、前記取得した各エリアごとの色情報に基づいて前記検出枠に入るエリアの個数を求める個数獲得手段と、
前記求められたエリアの個数から低彩度領域に属するエリアの個数の割合が少ないときは画面における主要光源の比率が低いと判断し、広範囲の色温度に追従する評価値と光源の色味を残す低彩度用評価値との間をとる色評価値であって前記低彩度領域に属するエリアの個数の割合に応じて前記広範囲の色温度に追従する評価値と光源の色味を残す低彩度用評価値との比率を変えた色評価値を算出する色評価値算出手段と、
前記算出した色評価値に基づいてホワイトバランスゲイン値を演算する演算手段と、
からなる画像処理装置。 An image processing apparatus that processes image data of an image obtained by photographing a subject using an imaging unit that converts an optical image into an electrical signal,
A color information acquisition unit that divides a screen on which a subject is imaged into a plurality of areas and acquires color information for each area;
A number acquisition means for setting a detection frame indicating a range of color distribution corresponding to at least a light source type, and determining the number of areas entering the detection frame based on the acquired color information for each area;
When the ratio of the number of areas belonging to the low-saturation area is small from the obtained number of areas, it is determined that the ratio of the main light source on the screen is low, and the evaluation value that follows a wide range of color temperatures and the color of the light source are determined. A color evaluation value that falls between the remaining low saturation evaluation values, and retains the evaluation value that follows the wide range of color temperatures and the color of the light source according to the ratio of the number of areas belonging to the low saturation region A color evaluation value calculating means for calculating a color evaluation value in which the ratio to the evaluation value for low saturation is changed;
A computing means for computing a white balance gain value based on the calculated color evaluation value;
An image processing apparatus comprising:
被写体が撮像された画面を複数のエリアに分割し、各エリアごとに色情報を取得するステップと、
少なくとも光源種に対応する色分布の範囲を示す検出枠を設定し、前記取得した各エリアごとの色情報に基づいて前記検出枠に入るエリアの個数を求めるステップと、
前記求められたエリアの個数から低彩度領域に属するエリアの個数の割合が少ないときは画面における主要光源の比率が低いと判断し、広範囲の色温度に追従する評価値と光源の色味を残す低彩度用評価値との間をとる色評価値であって前記低彩度領域に属するエリアの個数の割合に応じて前記広範囲の色温度に追従する評価値と光源の色味を残す低彩度用評価値との比率を変えた色評価値を算出するステップと、
前記算出した色評価値に基づいてホワイトバランスゲイン値を演算するステップと、
からなる画像処理方法。 An image processing method for processing image data of an image obtained by photographing a subject using an imaging means for converting an optical image into an electrical signal,
Dividing the screen on which the subject is imaged into a plurality of areas and obtaining color information for each area;
Setting a detection frame indicating a range of color distribution corresponding to at least a light source type, and obtaining the number of areas entering the detection frame based on the acquired color information for each area;
When the ratio of the number of areas belonging to the low-saturation area is small from the obtained number of areas, it is determined that the ratio of the main light source on the screen is low, and the evaluation value that follows a wide range of color temperatures and the color of the light source are determined. A color evaluation value that falls between the remaining low saturation evaluation values, and retains the evaluation value that follows the wide range of color temperatures and the color of the light source according to the ratio of the number of areas belonging to the low saturation region Calculating a color evaluation value by changing a ratio with the evaluation value for low saturation;
Calculating a white balance gain value based on the calculated color evaluation value;
An image processing method comprising:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007214604A JP4067033B2 (en) | 2007-08-21 | 2007-08-21 | Image processing apparatus and method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007214604A JP4067033B2 (en) | 2007-08-21 | 2007-08-21 | Image processing apparatus and method |
Related Parent Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2003061644A Division JP4026516B2 (en) | 2003-03-07 | 2003-03-07 | Image processing apparatus and method |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2008005540A JP2008005540A (en) | 2008-01-10 |
JP4067033B2 true JP4067033B2 (en) | 2008-03-26 |
Family
ID=39009467
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2007214604A Expired - Fee Related JP4067033B2 (en) | 2007-08-21 | 2007-08-21 | Image processing apparatus and method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP4067033B2 (en) |
Families Citing this family (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101534450B (en) * | 2008-03-11 | 2012-03-28 | 鸿富锦精密工业(深圳)有限公司 | Image retrieving device, and unit and method thereof for establishing gain form |
JP5545191B2 (en) | 2010-11-30 | 2014-07-09 | ブラザー工業株式会社 | Image processing apparatus and image processing program |
JP5631714B2 (en) | 2010-12-10 | 2014-11-26 | 株式会社東芝 | Auto white balance adjustment system |
JP5818668B2 (en) | 2011-12-16 | 2015-11-18 | 株式会社東芝 | Auto white balance adjustment system |
US10114838B2 (en) | 2012-04-30 | 2018-10-30 | Dolby Laboratories Licensing Corporation | Reference card for scene referred metadata capture |
CN106486087B (en) * | 2015-09-02 | 2020-04-24 | 深迪半导体(上海)有限公司 | Mobile terminal and adjusting method and adjusting device for display brightness of mobile terminal |
-
2007
- 2007-08-21 JP JP2007214604A patent/JP4067033B2/en not_active Expired - Fee Related
Also Published As
Publication number | Publication date |
---|---|
JP2008005540A (en) | 2008-01-10 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP4329125B2 (en) | White balance control method, white balance control device, and imaging device | |
JP4158592B2 (en) | Auto white balance adjustment method and camera to which this method is applied | |
KR100799215B1 (en) | Camera | |
JP4284448B2 (en) | Image processing apparatus and method | |
US8830348B2 (en) | Imaging device and imaging method | |
JP4791331B2 (en) | Imaging apparatus and exposure control method | |
JP6521776B2 (en) | Image processing apparatus, image processing method | |
JP4730553B2 (en) | Imaging apparatus and exposure control method | |
US8319864B2 (en) | Imaging apparatus and imaging method | |
JP2007053499A (en) | White balance control unit and imaging apparatus | |
EP2362662B1 (en) | Imaging device, imaging method and computer readable recording medium storing program for performing the imaging method | |
JP4067033B2 (en) | Image processing apparatus and method | |
JP4796007B2 (en) | Imaging device | |
JP4026516B2 (en) | Image processing apparatus and method | |
US7570294B2 (en) | Digital camera | |
JP5948997B2 (en) | Imaging apparatus and imaging method | |
JP5903478B2 (en) | Imaging apparatus and imaging method | |
JP5146015B2 (en) | Imaging apparatus and imaging method | |
JP2008017198A (en) | Device and method for calculating light source color, and photographing device | |
JP4264808B2 (en) | Moving image processing apparatus and method | |
JP5310331B2 (en) | Imaging apparatus and imaging method | |
JP2010050784A (en) | Digital camera | |
JP2004304695A (en) | White balance adjustment method | |
JP4239219B2 (en) | Auto white balance adjustment method and apparatus | |
JP5929362B2 (en) | Imaging apparatus and imaging method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
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: 20071218 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20071231 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20110118 Year of fee payment: 3 |
|
R150 | Certificate of patent or registration of utility model |
Free format text: JAPANESE INTERMEDIATE CODE: R150 Ref document number: 4067033 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20110118 Year of fee payment: 3 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20120118 Year of fee payment: 4 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20120118 Year of fee payment: 4 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20130118 Year of fee payment: 5 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20130118 Year of fee payment: 5 |
|
FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20140118 Year of fee payment: 6 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
R250 | Receipt of annual fees |
Free format text: JAPANESE INTERMEDIATE CODE: R250 |
|
LAPS | Cancellation because of no payment of annual fees |