JP2013153248A - Image pickup device, white balance control method, and white balance control program - Google Patents

Image pickup device, white balance control method, and white balance control program Download PDF

Info

Publication number
JP2013153248A
JP2013153248A JP2012011780A JP2012011780A JP2013153248A JP 2013153248 A JP2013153248 A JP 2013153248A JP 2012011780 A JP2012011780 A JP 2012011780A JP 2012011780 A JP2012011780 A JP 2012011780A JP 2013153248 A JP2013153248 A JP 2013153248A
Authority
JP
Japan
Prior art keywords
white balance
adjustment value
image data
balance adjustment
imaging
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.)
Granted
Application number
JP2012011780A
Other languages
Japanese (ja)
Other versions
JP5885023B2 (en
Inventor
Hiroyasu Kitagawa
博康 北川
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Casio Computer Co Ltd
Original Assignee
Casio Computer Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Casio Computer Co Ltd filed Critical Casio Computer Co Ltd
Priority to JP2012011780A priority Critical patent/JP5885023B2/en
Publication of JP2013153248A publication Critical patent/JP2013153248A/en
Application granted granted Critical
Publication of JP5885023B2 publication Critical patent/JP5885023B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

PROBLEM TO BE SOLVED: To enable photographing to be performed with appropriate AWB processing corresponding to a photographing environment.SOLUTION: When there is not sufficient valid data equal to or greater than a threshold as a result of determination in step S307, determination of whether a flag UF=1 is made (step S312). The flag UF indicates that when UF=1, it means through-image data taken in immediately before capture-image data was taken in in step S302 contains valid data equal to or greater than a threshold. Furthermore, the flag UF indicates that when UF=1, it means through R and B needed for controlling the WB of through-image data taken in immediately before capture-image data was taken in are stored in memory. Therefore, through R and B gains determined in AWB data analysis processing are converted into capture R and B gains (step S313). These converted capture R and B gains are used to adjust the R and B components of capture image data (step S309).

Description

本発明は、撮像装置、ホワイトバランス制御方法及びホワイトバランス制御プログラムに関する。   The present invention relates to an imaging apparatus, a white balance control method, and a white balance control program.

CCD(Charge Coupled Device) などの固体撮像素子を用いたカメラ装置では、撮像対象の白色を撮像結果においても無彩色の白色とするために、光源の色温度が変化した場合には、色温度の変化に応じて撮像結果において色が付いて見える白色を、無彩色の白色に自動的に合わせるオートホワイトバランス(AWB)処理を行う。その際、ホワイトバランスをとる範囲を制限する引き込み制限枠を光源の種別毎に設定しておき、この引き込み制限枠(例えば、その光源下でグレーと判断される色の範囲)にある色の画素を検出する。そして、検出された画素の数が閾値以上であった場合には、判定した光源に対応するWBゲインl[Cbの積算値とCrの積算値とが「0」となる(Cb=Cr=0となる)ような、R成分のゲインとB成分のゲイン]により、AWB処理を実行する(例えば、下記特許文献1参照)。   In a camera device using a solid-state imaging device such as a CCD (Charge Coupled Device), the color temperature of the light source changes when the color temperature of the light source changes in order to make the white color of the imaging target an achromatic white color in the imaging result. An auto white balance (AWB) process is performed to automatically match white that appears to be colored in the imaging result in accordance with the change with achromatic white. At that time, a pull-in limit frame for limiting the range for white balance is set for each type of light source, and pixels of colors in this pull-in limit frame (for example, a color range determined to be gray under the light source) Is detected. If the number of detected pixels is equal to or greater than the threshold, the WB gain l [Cb integrated value and Cr integrated value corresponding to the determined light source is “0” (Cb = Cr = 0). The AWB process is executed according to the R component gain and the B component gain] (see, for example, Patent Document 1 below).

特開平11−136698号公報JP-A-11-136698

このように、従来技術は、引き込み制限枠で検出された画素の数が閾値以上であった場合には、判定した光源に対応するWBゲインを用いて、AWB処理を実行するものである。したがって、引き込み制限枠で検出された画素の数が閾値未満であったり、当該画素を発見できなかった場合には、AWB処理を実行することができない。   As described above, in the related art, when the number of pixels detected in the pull-in restriction frame is equal to or larger than the threshold value, the AWB process is executed using the WB gain corresponding to the determined light source. Therefore, if the number of pixels detected in the pull-in limit frame is less than the threshold value or the pixel cannot be found, the AWB process cannot be executed.

本発明は、かかる従来の課題に鑑みてなされたものであり、引き込み制限枠で検出された画素の数が閾値未満であったり、当該画素を発見できなかった場合であっても、撮影環境に応じた適切なAWB処理を伴って撮影を行うことのできる撮像装置、ホワイトバランス制御方法及びホワイトバランス制御プログラムを提供することを目的とする。   The present invention has been made in view of such a conventional problem. Even if the number of pixels detected in the pull-in restriction frame is less than a threshold value or the pixel cannot be found, the present invention is not limited to a shooting environment. An object of the present invention is to provide an imaging apparatus, a white balance control method, and a white balance control program that can perform imaging with appropriate AWB processing.

前記課題を解決するために本発明にあっては、被写体を撮像して順次画像データを出力する撮像手段と、前記撮像手段から順次出力される各画像データに基づき、ホワイトバランスを調整するための第1のホワイトバランス調整値を生成する第1の生成手段と、この第1の生成手段により生成された第1のホワイトバランス調整値に基づき、当該画像データのホワイトバランスを調整して画像の表示に供する第1の制御手段と、前記第1の生成手段により生成された前記第1のホワイトバランス調整値を記憶する調整値記憶手段と、前記第1の制御手段による制御中における撮像指示に応答して、前記撮像手段から出力された画像データを取り込む取込手段と、この取込手段により取り込まれた画像データがホワイトバランス調整値を生成する上で有効な画像データであるか否かを判断する第1の判断手段と、この第1の判断手段により有効な画像データであると判断された場合に、前記取込手段により取り込まれた画像データに基づき、ホワイトバランスを調整するための第2のホワイトバランス調整値を生成する第2の生成手段と、前記第1の判断手段により有効な画像データでないと判断された場合に、前記調整値記憶手段に記憶されている前記第1のホワイトバランス調整値を取得する取得手段と、前記第2の生成手段により生成された第2のホワイトバランス調整値、及び前記取得手段により取得された第1のホワイトバランス調整値に基づき、前記取込手段により取り込まれた画像データのホワイトバランスを調整して画像の記録に供する第2の制御手段と、を備えることを特徴とする。   In order to solve the above-described problems, the present invention provides an imaging unit that images a subject and sequentially outputs image data, and for adjusting white balance based on each image data sequentially output from the imaging unit. First generation means for generating a first white balance adjustment value, and display of an image by adjusting the white balance of the image data based on the first white balance adjustment value generated by the first generation means Responding to an imaging instruction during control by the first control means, first adjustment means for storing the first white balance adjustment value generated by the first generation means, A capturing unit that captures the image data output from the imaging unit, and the image data captured by the capturing unit generates a white balance adjustment value. First determination means for determining whether or not the image data is valid above, and an image captured by the capture means when the first determination means determines that the image data is valid A second generation unit that generates a second white balance adjustment value for adjusting white balance based on the data; and the adjustment value when the first determination unit determines that the image data is not valid. Acquisition means for acquiring the first white balance adjustment value stored in the storage means, second white balance adjustment value generated by the second generation means, and first acquired by the acquisition means Second control means for adjusting the white balance of the image data captured by the capturing means and using it for image recording based on the white balance adjustment value of And wherein the door.

本発明によれば、キャプチャ時に有効なデータが得られなかった場合には、スルー画像のデータを用いてホワイトバランスを制御するので、常により撮影環境に応じた適切なAWB処理を行うことができる。   According to the present invention, when effective data cannot be obtained at the time of capture, white balance is controlled using data of a through image, so that it is possible to always perform appropriate AWB processing according to the shooting environment. .

本発明の一実施の形態を示す電子スチルカメラのブロック構成図である。It is a block block diagram of the electronic still camera which shows one embodiment of this invention. (a)はゲインテーブル、(b)はスルー検出枠テーブル、(c)はキャプチャ検出枠テーブル、(d)はスルー基準WBゲインテーブル、(e)はキャプチャ基準WBゲインテーブルを各々示す概念図である。(A) is a gain table, (b) is a through detection frame table, (c) is a capture detection frame table, (d) is a through reference WB gain table, and (e) is a conceptual diagram showing a capture reference WB gain table. is there. 出荷前に実行される処理の手順を示すフローチャートである。It is a flowchart which shows the procedure of the process performed before shipment. 本実施の形態のRECモードにおけるメインルーチンを示すフローチャートである。It is a flowchart which shows the main routine in the REC mode of this Embodiment. 図5のメインルーチンに対するインターラプトルーチンを示すフローチャートである。It is a flowchart which shows the interrupt routine with respect to the main routine of FIG.

以下、本発明の実施の形態を図に従って説明する。図1は、本発明を電子スチルカメラに適用した場合のブロック構成図である。   Hereinafter, embodiments of the present invention will be described with reference to the drawings. FIG. 1 is a block diagram when the present invention is applied to an electronic still camera.

レンズ20の後方に配置されたCCD25は、タイミング信号発生器26、垂直ドライバ27によって駆動される。CCD25は原色R(赤),G(緑),B(青)の色フィルタアレイが設けられたものであって、CCD25の受光面に結像された光学像はR,G,Bの各受光部で電荷蓄積され、光の強さに応じた量のR,G,Bの信号電荷に変換された後、アナログの画像信号としてユニット回路28に出力される。ユニット回路28は、入力した撮像信号からノイズを除去するCDSと、ノイズが除去された撮像信号をデジタルの画像データに変換するA/D変換器とからなり、ユニット回路28から出力された画像データ(RAWデータ)は一旦バッファメモリ28´に記憶された後、読み出されて第1及び第2ゲイン調整回路21,22に送られる。   The CCD 25 disposed behind the lens 20 is driven by a timing signal generator 26 and a vertical driver 27. The CCD 25 is provided with a color filter array of primary colors R (red), G (green), and B (blue). The optical image formed on the light receiving surface of the CCD 25 is received by each of R, G, and B. The charge is accumulated in the unit, converted into R, G, and B signal charges corresponding to the intensity of light, and then output to the unit circuit 28 as an analog image signal. The unit circuit 28 includes a CDS that removes noise from the input imaging signal and an A / D converter that converts the imaging signal from which noise has been removed into digital image data. The image data output from the unit circuit 28 (RAW data) is temporarily stored in the buffer memory 28 ′, read out, and sent to the first and second gain adjustment circuits 21 and 22.

第1及び第2ゲイン調整回路21、22は、R,G,Bの色成分毎にR用アンプ21a、22a、G用アンプ21b、22b、B用アンプ21c、22cを各々備えており、制御部35から送られるホワイトバランス調整値を制御信号として、各アンプ21a、22a、21b、22b、21c、22cのゲインを制御する。第1ゲイン調整回路21によって増幅された画像信号は第1カラープロセス回路23に送られ、ここでカラープロセス処理を行われた後、デジタルの輝度信号(Y信号)と色差信号(Cb信号、Cr信号)を含んだYUVデータとしてDMAコントローラ29のバッファに書き込まれる。同時にバッファには、DMAコントローラ29はバッファに書き込まれたYUVデータをDRAM30の指定領域に転送し、展開する。   The first and second gain adjustment circuits 21 and 22 include R amplifiers 21a and 22a, G amplifiers 21b and 22b, and B amplifiers 21c and 22c for each of R, G, and B color components, respectively. The gain of each amplifier 21a, 22a, 21b, 22b, 21c, 22c is controlled using the white balance adjustment value sent from the unit 35 as a control signal. The image signal amplified by the first gain adjustment circuit 21 is sent to the first color process circuit 23, where color process processing is performed, and then a digital luminance signal (Y signal) and a color difference signal (Cb signal, Cr). Signal) is written to the buffer of the DMA controller 29 as YUV data. At the same time, in the buffer, the DMA controller 29 transfers the YUV data written in the buffer to the designated area of the DRAM 30 and expands it.

ビデオエンコーダ31は、前記バッファから読み出したYUVデータを元にビデオ信号を発生してLCDからなる表示装置32に出力する。これにより、RECモード(撮影モード)における撮像待機状態にあるRECスルーモード時には、撮像された被写体像が表示装置32にスルー画像として表示される。   The video encoder 31 generates a video signal based on the YUV data read from the buffer and outputs it to a display device 32 comprising an LCD. Thereby, in the REC through mode in the imaging standby state in the REC mode (imaging mode), the captured subject image is displayed on the display device 32 as a through image.

また、シャッターキーが押されたRECモードにおける撮影指示時には、制御部35からの指示により、バッファメモリ28´から読み出された画像データが第2ゲイン調整回路22に送られて取り込まれる。この第2ゲイン調整回路22に取り込まれた画像データは、制御部35により制御される第2ゲイン調整回路22によりR、B成分のゲインが調整される。   Further, at the time of a shooting instruction in the REC mode in which the shutter key is pressed, the image data read from the buffer memory 28 ′ is sent to the second gain adjustment circuit 22 and is taken in by an instruction from the control unit 35. The gain of the R and B components of the image data captured by the second gain adjustment circuit 22 is adjusted by the second gain adjustment circuit 22 controlled by the control unit 35.

このR,Bゲインが調整された画像データは、第2カラープロセス回路24に送られ、ここでカラープロセス処理を行われた後、デジタルの輝度信号(Y信号)と色差信号(Cb信号、Cr信号)を含んだYUVデータとしてDMAコントローラ29のバッファに書き込まれる。このバッファに書き込まれた1フレーム分のYUVデータが圧縮/伸張部33に送られ、圧縮処理が施されてフラッシュメモリ34に記録される。これにより、フラッシュメモリ34にホワイトバランスが確保された被写体画像の画像データを記録することができる。   The image data in which the R and B gains are adjusted is sent to the second color process circuit 24, where color process processing is performed, and then a digital luminance signal (Y signal) and a color difference signal (Cb signal, Cr). Signal) is written to the buffer of the DMA controller 29 as YUV data. One frame worth of YUV data written in this buffer is sent to the compression / expansion unit 33, subjected to compression processing, and recorded in the flash memory 34. Thereby, the image data of the subject image in which the white balance is ensured can be recorded in the flash memory 34.

制御部35はCPU、プログラムやデータが格納されたROM、作業用のRAMを有しており、所定のプログラムに従い前述した各部の動作を制御するとともに、操作部36から送られる状態信号に対応して電子スチルカメラの各機能、すなわち自動露出制御(AE)やオートホワイトバランス(AWB)を実現する。操作部36には、前記シャッターキー、及びRECスルーモードとPLAYモードの切り替えキー等の各種キーが設けられており、キー操作に応じた状態信号を制御部35に送る。ストロボ37は、シャッターキーの操作時(撮影時)に必要に応じて駆動され補助光を発する。   The control unit 35 includes a CPU, a ROM in which programs and data are stored, and a working RAM. The control unit 35 controls the operation of each unit described above according to a predetermined program and corresponds to a status signal sent from the operation unit 36. Thus, each function of the electronic still camera, that is, automatic exposure control (AE) and auto white balance (AWB) is realized. The operation unit 36 is provided with various keys such as the shutter key and a key for switching between the REC through mode and the PLAY mode, and sends a state signal corresponding to the key operation to the control unit 35. The strobe 37 is driven as necessary when the shutter key is operated (during shooting) and emits auxiliary light.

制御データ記憶部38は、図2(a)に示すゲインテーブル381、同図(b)に示すスルー検出枠テーブル382、同図(c)に示すキャプチャ検出枠テーブル383、同図(d)に示すスルー基準WBゲインテーブル384、同図(e)に示すキャプチャ基準WBゲインテーブル385が記憶されている。ゲインテーブル381には、後述するようにして実測された光源の種別「太陽光」、「蛍光灯」、「電球」毎にR成分とB成分のスルーゲインとキャプチャゲインとが記憶されている。また、これらスルーゲインとキャプチャゲインは、各光源下での撮像時に適切なホワイトバランスを設定するため使用されるRゲインの値とBゲインの値でもある。   The control data storage unit 38 includes a gain table 381 shown in FIG. 2A, a through detection frame table 382 shown in FIG. 2B, a capture detection frame table 383 shown in FIG. 2C, and FIG. A through reference WB gain table 384 and a capture reference WB gain table 385 shown in FIG. The gain table 381 stores the through gain and capture gain of the R component and the B component for each type of light source “sunlight”, “fluorescent lamp”, and “bulb” measured as described later. The through gain and the capture gain are also an R gain value and a B gain value used for setting an appropriate white balance at the time of imaging under each light source.

スルー検出枠テーブル382には、前記光源の種別「太陽光」、「蛍光灯」、「電球」毎に、スルー画像を表示する際にAWB処理の実行に必要なグレーを検出する領域であるグレー検出領域枠を示すデータが記憶されている。キャプチャ検出枠テーブル383には、前記光源の種別「太陽光」、「蛍光灯」、「電球」毎に、画像を記録する際にAWB処理の実行に必要なグレーを検出する領域であるグレー検出領域枠を示すデータが記憶されている。   In the through detection frame table 382, a gray that is an area for detecting gray necessary for executing the AWB process when displaying a through image for each of the types of light sources “sunlight”, “fluorescent lamp”, and “bulb”. Data indicating the detection area frame is stored. In the capture detection frame table 383, for each of the types of light sources “sunlight”, “fluorescent lamp”, and “bulb”, a gray detection that is an area for detecting gray necessary for executing an AWB process when an image is recorded Data indicating the area frame is stored.

スルー基準WBゲインテーブル384には、前記光源の種別「太陽光」、「蛍光灯」、「電球」毎に、スルー画像を表示する際にAWB処理の実行に必要な有効データが閾値以上ない場合において使用される基準WBゲインがRゲインとBゲインとにより記憶されている。キャプチャ基準WBゲインテーブル385には、前記光源の種別「太陽光」、「蛍光灯」、「電球」毎に、画像を記録する際にAWB処理の実行に必要な有効データが閾値以上ない場合において使用される基準WBゲインがRゲインとBゲインとにより記憶されている。   In the through reference WB gain table 384, when the through data is displayed for each of the light source types “sunlight”, “fluorescent lamp”, and “bulb”, there is no valid data necessary for executing the AWB process exceeding the threshold value. The reference WB gain used in is stored as an R gain and a B gain. In the capture reference WB gain table 385, for each of the types of light sources “sunlight”, “fluorescent lamp”, and “bulb”, when the effective data necessary for executing the AWB process when recording an image is not equal to or greater than a threshold value, A reference WB gain to be used is stored as an R gain and a B gain.

以上の構成からなる本実施の形態において、この電子スチルカメラが製造されて工場から市場に出荷される前に、メーカーの作業者は、輝度箱が設置されている部屋において、光源を先ず「太陽光」にする。引き続き、操作部36にて所定の操作を行い、出荷時前処理モードを設定すると、制御部35はROMに予め記憶されているプログラムに従って図3のフローチャートに示す処理を実行する。   In the present embodiment having the above-described configuration, before the electronic still camera is manufactured and shipped from the factory to the market, the manufacturer's worker first turns the light source into the “sun” in the room where the luminance box is installed. "Light". Subsequently, when a predetermined operation is performed by the operation unit 36 and the pre-shipment processing mode is set, the control unit 35 executes the process shown in the flowchart of FIG. 3 in accordance with a program stored in advance in the ROM.

すなわち、撮像待機状態にあるRECスルーモードの設定時と同様の撮影条件を用いて撮影処理を行う(ステップS101)。また、このスルー画像撮影処理によりバッファメモリ28´に記憶された画像データを制御部35のRAMに取り込む(ステップS102)。   That is, the photographing process is performed using the same photographing condition as that when setting the REC through mode in the imaging standby state (step S101). Further, the image data stored in the buffer memory 28 'by the through image photographing process is taken into the RAM of the control unit 35 (step S102).

次に、ユーザ(作業者)による所定のキー操作によって太陽光が選択されると、太陽光のグレー検出領域枠を選択(決定)する(ステップS103)。その後、この選択(決定)したグレー検出領域枠(引き込み制限枠)(例えば、その光源下でグレーと判断される色の範囲)にある色の画素を検出し、検出された画素の数が閾値以上であった場合には、その重心に基づくWBゲインl(RAMに記憶されている画像データの太陽光用のグレー検出領域枠内におけるCbの積算値とCrの積算値とが「0」となる(Cb=Cr=0となる)ような、R成分のゲインとB成分のゲイン)を取得する(ステップS104)。さらに、このステップS104で取得したRゲインとBゲインとを夫々ゲインテーブル381のステップS103で選択(決定)された光源の種別「太陽光」の「スルーゲイン(R,B)」欄に記録する(ステップS105)。   Next, when sunlight is selected by a predetermined key operation by the user (operator), a gray detection region frame of sunlight is selected (determined) (step S103). Thereafter, a pixel of a color in the selected (determined) gray detection area frame (retraction restriction frame) (for example, a color range determined to be gray under the light source) is detected, and the number of detected pixels is a threshold value. In the case of the above, the WB gain 1 based on the center of gravity (the integrated value of Cb and the integrated value of Cr in the gray detection area frame for sunlight of the image data stored in the RAM is “0”. R component gain and B component gain such that Cb = Cr = 0 is obtained (step S104). Further, the R gain and B gain acquired in step S104 are recorded in the “through gain (R, B)” column of the type of sunlight “sunlight” selected (determined) in step S103 of the gain table 381. (Step S105).

したがって、以上の処理により当該電子スチルカメラに組み付けられたCCD25の個体差、延いては当該電子スチルカメラの個体差を反映した「スルーゲイン(R,B)」が記録されることとなる。   Therefore, the “through gain (R, B)” reflecting the individual difference of the CCD 25 assembled in the electronic still camera and the individual difference of the electronic still camera is recorded by the above processing.

また、制御部35は、前述のスルー画像撮影処理に用いられて撮影条件とは異なる本撮影用の撮影条件を用いた本撮影処理を行わせることによりバッファメモリ28´に記憶された画像データを制御部35のRAMに取り込む(ステップS106)。次に、前記ステップS103で決定されている「太陽光」のグレー検出領域枠にある色の画素を検出し、検出された画素の数が閾値以上であった場合には、その重心に基づくWBゲインl(RAMに記憶されている画像データの太陽光用のグレー検出領域枠内におけるCbの積算値とCrの積算値とが「0」となる(Cb=Cr=0となる)ような、R成分のゲインとB成分のゲイン)を取得する(ステップS107)。さらに、このステップS107で取得したRゲインとBゲインとを夫々ゲインテーブル381のステップS103で選択(決定)された光源の種別「太陽光」の「キャプチャゲイン(R,B)」欄に記録する(ステップS108)。   Further, the control unit 35 performs the main photographing process using the photographing conditions for the main photographing that are different from the photographing conditions used in the above-described through image photographing processing, and thereby the image data stored in the buffer memory 28 'is obtained. The data is taken into the RAM of the control unit 35 (step S106). Next, pixels of the color in the “sunlight” gray detection area frame determined in step S103 are detected. If the number of detected pixels is equal to or greater than the threshold, WB based on the center of gravity is detected. Gain l (the accumulated value of Cb and the accumulated value of Cr in the gray detection area frame for sunlight of the image data stored in the RAM is “0” (Cb = Cr = 0), R component gain and B component gain) are acquired (step S107). Further, the R gain and the B gain acquired in step S107 are recorded in the “capture gain (R, B)” column of the light source type “sunlight” selected (determined) in step S103 of the gain table 381, respectively. (Step S108).

したがって、以上の処理により当該電子スチルカメラに組み付けられたCCD25の個体差、延いては当該電子スチルカメラの個体差を反映した「キャプチャゲイン(R,B)」が記録されることとなる。   Therefore, by the above processing, “capture gain (R, B)” reflecting individual differences of the CCD 25 assembled in the electronic still camera, and further, individual differences of the electronic still camera is recorded.

また、以上の処理を光源を変えることにより「蛍光灯」及び「電球」についても実行する。これにより、図2(a)に例示するようにゲインテーブル381には、各光源毎に当該電子スチルカメラの個体差を反映したスルーゲイン(R,B)、キャプチャーゲイン(R,B)が記憶されることとなる。   Further, the above processing is also executed for “fluorescent lamp” and “bulb” by changing the light source. Thus, as illustrated in FIG. 2A, the gain table 381 stores through gain (R, B) and capture gain (R, B) reflecting individual differences of the electronic still camera for each light source. Will be.

しかる後に出荷されたこの電子スチルカメラがユーザにより購入され、このユーザがRECモードを設定すると、制御部35は図4に示すフローチャートに従って処理を開始し、CCD25を1フレーム駆動する(ステップS201)。次に、この駆動によりバッファメモリ28´に記憶された1フレーム分のデジタルデータからなる画像データを制御部35のRAMに取り込み(ステップS202)、このRAMに記憶されている画像データを用いて光源を判定する(ステップS203)。すなわち、太陽光、蛍光灯、電球等のグレー検出領域枠を順次切り替えながらRAMに取り込んだ画像データの各グレー検出領域枠内におけるグレイの画素をカウントしてカウント数が一番多かったグレー検出領域枠を決定するとともに、このグレー領域検出枠に対応する光源を光源種として判定する処理を実行する。   When the electronic still camera shipped after that is purchased by the user and the user sets the REC mode, the control unit 35 starts processing according to the flowchart shown in FIG. 4 and drives the CCD 25 by one frame (step S201). Next, image data composed of digital data for one frame stored in the buffer memory 28 'by this driving is taken into the RAM of the control unit 35 (step S202), and a light source is used using the image data stored in the RAM. Is determined (step S203). In other words, the gray detection area where the number of gray pixels in each gray detection area frame of the image data captured in the RAM is counted while sequentially switching the gray detection area frames such as sunlight, fluorescent light, light bulb, etc. A process of determining a frame and determining a light source corresponding to the gray area detection frame as a light source type is executed.

また、後述するステップS205で前回までの光源の種別がRAMに記憶されているので、これと今回判定した判定光源とを比較することにより、光源の種別が変わったか否かを判断する(ステップS204)。この判断の結果、判定光源の種別が変わった場合には、スルー光源フラグSKFをセットしてSKF=1にするとともに、今回変わった光源の種別をRAMに記憶する(ステップS205)。   Further, since the type of the light source up to the previous time is stored in the RAM in step S205 described later, it is determined whether or not the type of the light source has changed by comparing this with the determination light source determined this time (step S204). ). If the result of this determination is that the type of the determined light source has changed, the through light source flag SKF is set to SKF = 1, and the type of light source that has been changed this time is stored in the RAM (step S205).

次に、AWBデータ解析処理を実行する(ステップS206)。このAWB処理に際しては、図2(b)に示したスルー検出枠テーブル382を参照して、前記ステップS203で判定された光源の種別に対応するグレー検出領域枠を示すデータを読み出す。そして、このデータが示すグレー検出枠領域において、グレーの画素を有効データとし、前記ステップS202で取得した画像データにおける有効データの数をカウントする。なお、前記ステップS203で光源判定するために既に有効データの数をカウントしているので、既に取得済みのカウント数を用いることで、ここでのカウントを省略することも可能である。加えて、前記ステップS203で判定された光源の種別に対応するグレー検出領域枠内の前記ステップS202でRAMに記憶した画像データにおけるCbの積算値とCrの積算値とが「0」となる(Cb=Cr=0となる)ような、(その検出された画素の重心に基づく)R成分のゲインとB成分のゲインを決定する。但し、後述のステップS207においてカウントした有効データが閾値以上あると判断された場合にだけここで決定したR成分のゲインとB成分のゲインが使用されることになるので、カウントした有効データが閾値以上あると判断された場合にのみR成分のゲインとB成分のゲインを決定するようにしてもよい。   Next, AWB data analysis processing is executed (step S206). In the AWB process, data indicating a gray detection area frame corresponding to the type of light source determined in step S203 is read with reference to the through detection frame table 382 shown in FIG. Then, in the gray detection frame area indicated by this data, gray pixels are regarded as valid data, and the number of valid data in the image data acquired in step S202 is counted. Since the number of valid data has already been counted in order to determine the light source in step S203, the count here can be omitted by using the already acquired count number. In addition, the integrated value of Cb and the integrated value of Cr in the image data stored in the RAM in step S202 in the gray detection area frame corresponding to the type of light source determined in step S203 are “0” ( R component gain and B component gain (based on the detected barycenter of the pixel) such as Cb = Cr = 0 are determined. However, since the R component gain and the B component gain determined here are used only when it is determined that the valid data counted in step S207, which will be described later, is greater than or equal to the threshold value, the counted valid data is the threshold value. The R component gain and the B component gain may be determined only when it is determined that there is the above.

引き続き、このカウントした有効データが閾値以上あるか否かを判断する(ステップS207)。有効データが閾値以上あるならば、有効データフラグUF=0である場合には有効データフラグUFをセットしてUF=1にする(ステップS208)。また、前記ステップS206でのAWBデータ解析処理で決定したスルーRゲインとスルーBゲインとをRAMに記憶する(ステップS209)。ここで、既にスルーRゲインとスルーBゲインとがRAMに記憶されている場合には更新(上書)記憶することになる。   Subsequently, it is determined whether or not the counted valid data is greater than or equal to a threshold (step S207). If the valid data is greater than or equal to the threshold, if the valid data flag UF = 0, the valid data flag UF is set to UF = 1 (step S208). Further, the through R gain and the through B gain determined by the AWB data analysis processing in step S206 are stored in the RAM (step S209). Here, if the through R gain and the through B gain are already stored in the RAM, they are updated (overwritten).

また、この記憶したスルーRゲインとスルーBゲインとを用いてスルー画像を表示させる画像データをWB制御する(ステップS210)。さらに、このWB制御した画像データに基づく画像を表示装置32に表示させる表示制御を実行する(ステップS211)。   Further, WB control is performed on image data for displaying a through image using the stored through R gain and through B gain (step S210). Further, display control is executed for causing the display device 32 to display an image based on the WB-controlled image data (step S211).

すなわち、ユニット回路28から出力され、バッファメモリ28´に記憶されている画像データは第1ゲイン調整回路21により、前記記憶したスルーRゲインとスルーBゲインとを用いて、R用アンプ21aとB用アンプ21cで増幅される。この第1ゲイン調整回路21によって増幅された画像信号は第1カラープロセス回路23に送られ、ここでカラープロセス処理を行われた後、デジタルの輝度信号(Y信号)と色差信号(Cb信号、Cr信号)を含んだYUVデータとしてDMAコントローラ29のバッファに書き込まれる。   That is, the image data output from the unit circuit 28 and stored in the buffer memory 28 ′ is used by the first gain adjustment circuit 21 to store the R amplifiers 21 a and B using the stored through R gain and through B gain. Amplified by the amplifier 21c. The image signal amplified by the first gain adjustment circuit 21 is sent to the first color process circuit 23, where color process processing is performed, and then a digital luminance signal (Y signal) and a color difference signal (Cb signal, The YUV data including the Cr signal is written to the buffer of the DMA controller 29.

ビデオエンコーダ31は、前記バッファから読み出したYUVデータを元にビデオ信号を発生して表示装置32に出力する。これにより、RECモード(撮影モード)における撮像待機状態にあるRECスルーモード時には、撮像された被写体像が適正なホワイトバランスで表示装置32にスルー画像として表示されることとなる。   The video encoder 31 generates a video signal based on the YUV data read from the buffer and outputs it to the display device 32. Thus, in the REC through mode in the imaging standby state in the REC mode (imaging mode), the captured subject image is displayed as a through image on the display device 32 with an appropriate white balance.

しかる後に、RECモードから他のモードへの変更指示があったか否かを判断する(ステップS212)。他のモードへの変更指示がない場合にはステップS201からの処理を繰り返し、変更指示があったならばこのフローに従った処理を終了する。   Thereafter, it is determined whether or not there is an instruction to change from the REC mode to another mode (step S212). If there is no instruction to change to another mode, the process from step S201 is repeated. If there is an instruction to change, the process according to this flow is terminated.

一方、ステップS207での判断の結果、有効データが閾値以上なかった場合には、有効データフラグUF=1である場合には有効データフラグUFをリセットしてUF=0とした上で(ステップS213)、スルー光源SKF=1となっているか否かを判断する(ステップS214)。SKF=1となっていれば、前記ステップS204での判断の結果、光源の種別が変わったことを意味する。この場合には、図2(d)に示したスルー基準WBゲインテーブル384から、変更された今回の光源に対応するスルー基準Rゲインとスルー基準Bゲインとを読み出す(ステップS215)。そして、ステップS216でスルー光源フラグSKFをリセットしてSKF=0とした後、ステップS214で読み出したスルー基準Rゲインとスルー基準Bゲインとを用いて、前述のステップS210以降の処理を実行する。   On the other hand, if the result of determination in step S207 is that the valid data is not greater than or equal to the threshold, if the valid data flag UF = 1, the valid data flag UF is reset to UF = 0 (step S213). ), It is determined whether or not the through light source SKF = 1 (step S214). If SKF = 1, it means that the type of light source has changed as a result of the determination in step S204. In this case, the through reference R gain and the through reference B gain corresponding to the changed current light source are read from the through reference WB gain table 384 shown in FIG. 2D (step S215). In step S216, the through light source flag SKF is reset to SKF = 0, and then the processes in and after step S210 described above are executed using the through reference R gain and the through reference B gain read out in step S214.

また、ステップS213での判断の結果、スルー光源フラグSKF≠1(SKF=0)であり、光源の種別が変わっていない場合には、前回のWBゲインを保持して(ステップS217)、前述のステップS210以降の処理を実行する。つまり、前述したステップS209での処理により、前回のスルーR、Bゲインが記憶されているので、このスルーR、Bゲインを再度用いて、前述のステップS210以降の処理を実行する。   As a result of the determination in step S213, if the through light source flag SKF ≠ 1 (SKF = 0) and the type of the light source has not changed, the previous WB gain is held (step S217), and the above-mentioned The process after step S210 is executed. That is, since the previous through R and B gains are stored by the process in step S209 described above, the processes in and after step S210 are executed using the through R and B gains again.

他方、制御部35は図5に示すフローチャートに従って処理を一定時間毎に図4に示したメインルーチンに割り込んで実行する。すなわち、撮影指示があったか否かを判断し(ステップS301)、撮影指示があるまで待機する。ユーザがシャッターキーを操作することにより撮影指示が発生すると、制御部35はステップS301からステップS302に処理を進めて、スルー画像用の撮影条件とは異なる本撮影用の撮影条件を用いた撮影処理を行わせることによりユニット回路28から出力され、バッファメモリ28´に記憶されたデジタルデータからなる画像データを制御部35のRAMに取り込む(ステップS302)。次に、前記ステップS205によりRAMに記憶されている光源種別を今回のキャプチャ時の光源種別として取り込む(ステップS303)。   On the other hand, the control unit 35 executes the processing by interrupting the main routine shown in FIG. 4 at regular intervals according to the flowchart shown in FIG. That is, it is determined whether or not there has been a shooting instruction (step S301), and the system waits until there is a shooting instruction. When a shooting instruction is generated by the user operating the shutter key, the control unit 35 advances the processing from step S301 to step S302, and shooting processing using shooting conditions for main shooting different from shooting conditions for through images. The image data composed of the digital data output from the unit circuit 28 and stored in the buffer memory 28 'is taken into the RAM of the control unit 35 (step S302). Next, the light source type stored in the RAM in step S205 is fetched as the light source type at the time of the current capture (step S303).

また、後述するステップS305で前回キャプチャ時の光源種別がRAMに記憶されているので、これと前記ステップS303で取得した光源種別とを比較することにより、前回と今回のキャプチャ時とで光源の種別が変わったか否かを判断する(ステップS304)。この判断の結果、光源種別が変わった場合には、キャプチャ光源フラグCKFをセットしてCKF=1にするとともに、前回キャプチャ時の光源種別に代えて今回キャプチャ時の光源種別をRAMに記憶する(ステップS305)。   Further, since the light source type at the time of the previous capture is stored in the RAM in step S305, which will be described later, by comparing this with the light source type acquired in the step S303, the type of the light source between the previous time and the current time of capture. It is determined whether or not has changed (step S304). If the result of this determination is that the light source type has changed, the capture light source flag CKF is set to CKF = 1, and the light source type at the current capture is stored in the RAM instead of the light source type at the previous capture ( Step S305).

次に、AWBデータ解析処理を実行する(ステップS306)。このAWB処理に際しては、図2(c)に示したキャプチャ検出枠テーブル383を参照して、図4の前記ステップS203で判定され、RAMに記憶されている光源の種別に対応するグレー検出領域枠を示すデータを読み出す。そして、このデータが示すグレー検出枠領域において、グレーの画素を有効データとし、前記ステップS302で読み込んだ画像データにおける有効データの数をカウントする。さらに、読み出したグレー検出領域枠内の前記ステップS302でRAMに記憶された画像データにおけるCbの積算値とCrの積算値とが「0」となる(Cb=Cr=0となる)ような、(その検出された画素の重心に基づく)R成分のゲインとB成分のゲインを決定する。   Next, AWB data analysis processing is executed (step S306). In this AWB process, a gray detection area frame corresponding to the type of light source determined in step S203 of FIG. 4 and stored in the RAM with reference to the capture detection frame table 383 shown in FIG. Read data indicating. Then, in the gray detection frame area indicated by this data, gray pixels are regarded as valid data, and the number of valid data in the image data read in step S302 is counted. Further, the integrated value of Cb and the integrated value of Cr in the image data stored in the RAM in step S302 in the read gray detection area frame are “0” (Cb = Cr = 0). Determine R component gain and B component gain (based on the detected center of gravity of the pixel).

引き続き、このカウントした有効データが閾値以上あるか否かを判断する(ステップS307)。有効データが閾値以上あるならば、前記ステップS306でのAWBデータ解析処理で決定したキャプチャRゲインとキャプチャBゲインとをRAMに記憶する(ステップS308)。ここで、既にキャプチャRゲインとキャプチャBゲインとがRAMに記憶されている場合には更新(上書)記憶することになる。また、この記憶したキャプチャRゲインとキャプチャBゲインとを用いて、第2ゲイン調整回路22を制御し、キャプチャ画像データのR、B成分のゲインを調整する(ステップS309)。   Subsequently, it is determined whether or not the counted valid data is greater than or equal to a threshold value (step S307). If the valid data is greater than or equal to the threshold value, the capture R gain and capture B gain determined in the AWB data analysis process in step S306 are stored in the RAM (step S308). Here, if the capture R gain and the capture B gain are already stored in the RAM, they are updated (overwritten). Further, using the stored capture R gain and capture B gain, the second gain adjustment circuit 22 is controlled to adjust the gains of the R and B components of the captured image data (step S309).

しかる後に、記録処理を実行する(ステップS310)。すなわち、バッファメモリ28´に記憶されている画像データを第2ゲイン調整回路22に出力することにより、このR,Bゲインを調整された画像データを、第2カラープロセス回路24に送って、カラープロセス処理を行った後、デジタルの輝度信号(Y信号)と色差信号(Cb信号、Cr信号)を含んだYUVデータとしてDMAコントローラ29のバッファに書き込む。この書き込んだ1フレーム分のYUVデータが圧縮/伸張部33に送り、圧縮処理を施してフラッシュメモリ34に記録する。これにより、フラッシュメモリ34に、ホワイトバランスが確保された被写体画像の画像データを記録することができる。その後、有効データフラグUF=1である場合にはリセットしてUF=0とすると共に、キャプチャ光源フラグCKF=1である場合にはリセットしてCKF=0とする(ステップS311)。   Thereafter, a recording process is executed (step S310). That is, by outputting the image data stored in the buffer memory 28 ′ to the second gain adjustment circuit 22, the image data adjusted for the R and B gains is sent to the second color process circuit 24, and the color data After performing the process processing, the data is written in the buffer of the DMA controller 29 as YUV data including a digital luminance signal (Y signal) and a color difference signal (Cb signal, Cr signal). The written YUV data for one frame is sent to the compression / decompression unit 33, subjected to compression processing, and recorded in the flash memory 34. Thereby, the image data of the subject image in which the white balance is ensured can be recorded in the flash memory 34. Thereafter, when the valid data flag UF = 1, the reset is performed to set UF = 0, and when the capture light source flag CKF = 1 is set, the reset is performed to set CKF = 0 (step S311).

また、ステップS307での判断の結果、有効データが閾値以上なかった場合には、有効データフラグUF=1の状態にあるか否かを判断する(ステップS312)。この有効データフラグUFは、前述のフローチャートにおいてステップS208でセットされるフラグであり、UF=1により、ステップS302でキャプチャ画像データが取り込まれる直前に取り込まれたスルー画像データのグレー検出枠領域において、前記有効データが閾値以上あったことを示す。また、この有効データフラグUFは、UF=1により、前記キャプチャ画像データが取り込まれる直前に取り込まれたスルー画像データをWB制御するためのスルーRゲインとスルーBゲインとがRAMに記憶されていることを示す。   If the result of determination in step S307 is that the valid data is not greater than or equal to the threshold value, it is determined whether or not the valid data flag UF = 1 (step S312). This valid data flag UF is a flag that is set in step S208 in the above-described flowchart. In the gray detection frame area of the through image data that is captured immediately before capture image data is captured in step S302 due to UF = 1, Indicates that the valid data is equal to or greater than a threshold value. In the valid data flag UF, when UF = 1, a through R gain and a through B gain for WB control of through image data captured immediately before the capture image data is captured are stored in the RAM. It shows that.

そして、このようにUF=1である場合には、前記ステップS206でのAWBデータ解析処理で決定され、ステップS209でRAMに記憶されたスルーRゲインとスルーBゲインをキャプチャゲインに換算し、RAMに一時記憶する(ステップS313)。   If UF = 1 as described above, the slew R gain and the slew B gain determined in the AWB data analysis process in step S206 and stored in the RAM in step S209 are converted into capture gains. (Step S313).

すなわち、本実施の形態に係る電子スチルカメラのスルーゲインとキャプチャゲインとの相対的関係は、図2(a)に示したゲインテーブル381に記憶されている。そして、仮にS203で判定された光源が「電球」であったとすると、電球下での換算値は、下記のようになる。   That is, the relative relationship between the through gain and the capture gain of the electronic still camera according to the present embodiment is stored in the gain table 381 shown in FIG. If the light source determined in S203 is “bulb”, the converted value under the bulb is as follows.

ゲインテーブル381の「電球」欄には、電球でのスルーゲイン(R,B)として(293,775)、キャプチャゲイン(R,B)として(282,791)が記憶されているので、
Rゲイン換算値=スルーRゲイン×282/293
Bゲイン換算値=スルーBゲイン×791/775
となる。
In the “bulb” column of the gain table 381, (293,775) is stored as the through gain (R, B) and (282,791) is captured as the capture gain (R, B).
R gain conversion value = Through R gain x 282/293
B gain conversion value = Through B gain x 791/775
It becomes.

なお、本実施の形態においては、ゲインテーブル381に光源種毎のスルーゲイン(R,B)とキャプチャゲイン(R,B)を記憶させるようにしたが、光源種毎にスルーゲイン(R,B)とキャプチャゲイン(R,B)との比率を記憶させるようにしてもよい。この場合、例えば、ゲインテーブル381の「電球」欄にはRゲインの比率(282/293≒0.962)とRゲインの比率(791/775≒1.021)とが記憶される。この場合、キャプチャゲイン(R,B)とゲインテーブル381に記憶されているゲイン比率(R,B)との乗算によりR,Bゲイン換算値を簡単に算出することが可能になる。   In the present embodiment, the through gain (R, B) and the capture gain (R, B) for each light source type are stored in the gain table 381, but the through gain (R, B) for each light source type is stored. ) And the capture gain (R, B) may be stored. In this case, for example, an R gain ratio (282 / 293≈0.962) and an R gain ratio (791 / 775≈1.021) are stored in the “bulb” column of the gain table 381. In this case, the R and B gain converted values can be easily calculated by multiplying the capture gain (R, B) and the gain ratio (R, B) stored in the gain table 381.

このようにして、Rゲイン換算値とBゲイン換算値とを算出したならば、これらを今回のキャプチャに用いられるキャプチャRゲインとキャプチャBゲインとしてRAMに記憶すると共に、ステップS312で換算したキャプチャRゲインと、キャプチャBゲインとを用いて、前述したステップS309以降の処理を実行する。すなわち、これらキャプチャRゲインとキャプチャBゲインとを用いて、第2ゲイン調整回路22を制御し、キャプチャ画像データのR、B成分のゲインを調整する(ステップS309)。   If the R gain converted value and the B gain converted value are calculated in this way, they are stored in the RAM as the capture R gain and the capture B gain used for the current capture, and the capture R converted in step S312. Using the gain and the capture B gain, the processes after step S309 described above are executed. That is, by using the capture R gain and the capture B gain, the second gain adjustment circuit 22 is controlled to adjust the gains of the R and B components of the captured image data (step S309).

しかる後に、記録処理を実行する(ステップS310)。すなわち、バッファメモリ28´に記憶されている画像データを第2ゲイン調整回路22に出力することにより、このR,Bゲインを調整された画像データを、第2カラープロセス回路24に送って、カラープロセス処理を行った後、デジタルの輝度信号(Y信号)と色差信号(Cb信号、Cr信号)を含んだYUVデータとしてDMAコントローラ29のバッファに書き込む。この書き込んだ1フレーム分のYUVデータが圧縮/伸張部33に送り、圧縮処理を施してフラッシュメモリ34に記録する。   Thereafter, a recording process is executed (step S310). That is, by outputting the image data stored in the buffer memory 28 ′ to the second gain adjustment circuit 22, the image data adjusted for the R and B gains is sent to the second color process circuit 24, and the color data After performing the process processing, the data is written in the buffer of the DMA controller 29 as YUV data including a digital luminance signal (Y signal) and a color difference signal (Cb signal, Cr signal). The written YUV data for one frame is sent to the compression / decompression unit 33, subjected to compression processing, and recorded in the flash memory 34.

(1)つまり、キャプチャ時に有効なデータが得られなかった場合には、ステップS309においては、スルーR、BゲインをキャプチャR、Bゲインに換算した値を用いて、WB制御を実行する。スルーR、Bゲインが算出されるスルー画像にあっては、撮影時点に近接する時点で得られたデータであることから、撮影環境に応じた適切なAWB処理を行うことができる。   (1) That is, when valid data cannot be obtained at the time of capture, in step S309, WB control is executed using a value obtained by converting the through R and B gains into the capture R and B gains. Since the through image in which the through R and B gains are calculated is data obtained at a time close to the photographing time, appropriate AWB processing according to the photographing environment can be performed.

(2)しかも、本実施の形態においては、キャプチャ画像データが取り込まれる直前に取り込まれたスルー画像データをWB制御するためのスルーRゲインとスルーBゲインとを用いて、キャプチャ画像データをWB制御するためのキャプチャRゲインとキャプチャBゲインを算出し、これを用いたキャプチャ画像のWBを制御する。したがって、スルー画像データとキャプチャ画像データとは、極めて近接した時点、いうなれば当該電子スチルカメラにおける最小の時間差を持つ画像データである。よって、キャプチャ画像データから有効データが得られなかった場合であっても、当該電子スチルカメラにおいて最も撮影環境に応じた適切なAWB処理を行うことができる。   (2) In addition, in the present embodiment, the captured image data is WB controlled using the through R gain and the through B gain for WB control of the through image data captured immediately before the capture image data is captured. A capture R gain and a capture B gain are calculated, and the WB of the captured image using these is controlled. Accordingly, the through image data and the captured image data are image data having a minimum time difference in the electronic still camera at a very close point. Therefore, even when valid data cannot be obtained from the captured image data, the electronic still camera can perform the most appropriate AWB process according to the shooting environment.

(3)また、前記換算に用いられる値は、当該電子スチルカメラの出荷時に実測された値である。したがって、当該電子スチルカメラに組み付けられたCCD25の個体差、延いては当該電子スチルカメラの個体差を反映した「キャプチャ(R,B)」でWB制御を行うことができる。よって、個体差を考慮してホワイトバランスが確保された被写体画像の画像データを記録することができる。   (3) The value used for the conversion is a value measured at the time of shipment of the electronic still camera. Therefore, the WB control can be performed by “capture (R, B)” reflecting the individual difference of the CCD 25 assembled in the electronic still camera, that is, the individual difference of the electronic still camera. Therefore, it is possible to record image data of a subject image in which white balance is ensured in consideration of individual differences.

他方、有効データフラグUF≠1=0であり、ステップS312の判断がNOであるならば、キャプチャ光源フラグCKF=1であるか否か、つまりこの前回と今回のキャプチャ時で光源が変わったか否かを判断する(ステップS314)。CKF=1となっていれば、前記ステップS304での判断の結果、光源の種別が変わったことを意味する。この場合には、図2(e)に示したキャプチャ基準WBゲインテーブル385から、変更された今回の光源に対応するキャプチャ基準Rゲインとキャプチャ基準Bゲインとを読み出すと共に、これらを今回のキャプチャに用いられるキャプチャRゲインとキャプチャBゲインとしてRAMに記憶する(ステップS315)。そして、ステップS315で読み出したキャプチャ基準Rゲインとキャプチャ基準Bゲインとを用いて、前述のステップS309以降の処理を実行する。なお、ステップS311の判断がNOの場合にのみ前回と今回のキャプチャ時で光源が変わったか否かを判断することになるので、ステップS311の判断がNOの場合に前記ステップS303〜S305の処理を行うようにしてもよい。   On the other hand, if the valid data flag UF ≠ 1 = 0 and the determination in step S312 is NO, whether or not the capture light source flag CKF = 1, that is, whether or not the light source has changed between the previous and current captures. Is determined (step S314). If CKF = 1, it means that the type of the light source has changed as a result of the determination in step S304. In this case, the capture reference R gain and the capture reference B gain corresponding to the changed current light source are read from the capture reference WB gain table 385 shown in FIG. The capture R gain and capture B gain to be used are stored in the RAM (step S315). Then, using the capture reference R gain and capture reference B gain read out in step S315, the processes in and after step S309 are executed. Note that, only when the determination in step S311 is NO, it is determined whether or not the light source has changed between the previous capture and the current capture. Therefore, if the determination in step S311 is NO, the processes in steps S303 to S305 are performed. You may make it perform.

また、ステップS314での判断の結果、光源フラグCKF≠1(CKF=0)であり、光源の種別が変わっていない場合には、前回のWBゲイン、すなわち前回のキャプチャ時において用いられRAMに記憶されているキャプチャR、Bゲインを取得すると共に、これらを今回のキャプチャに用いられるキャプチャRゲインとキャプチャBゲインとしてRAMに記憶して(ステップS316)、前述のステップS309以降の処理を実行する。   If the light source flag CKF ≠ 1 (CKF = 0) and the type of the light source has not changed as a result of the determination in step S314, the previous WB gain, that is, used in the previous capture, is stored in the RAM. The acquired capture R and B gains are acquired, and these are stored in the RAM as the capture R gain and capture B gain used for the current capture (step S316), and the processing after step S309 described above is executed.

ここで、前回のWBゲインとしては、下記のものがある。
(A)前回のキャプチャ時において有効データが閾値以上あった場合に、ステップS306のAWBデータ解析処理で決定され、ステップS308で記憶されたキャプチャR、Bゲイン。
(B)前回のキャプチャ時において前記(A)が不可能であった場合に、ステップS312でスルー画像のR、Bゲインを用いて換算されたキャプチャR、Bゲイン。
(C)前回のキャプチャ時において前記(A)が不可能でありかつ前記(B)が実行されなかった場合に、ステップS315で光源に応じて読み出されて決定された基準のキャプチャR、Bゲイン。
(D)前回のキャプチャ時において前記(A)、(B)、(C)が実行されなかった場合に、ステップS317でRAMから読み出された前々回のキャプチャ時に用いられたキャプチャR、Bゲイン。
Here, the previous WB gain includes the following.
(A) The capture R and B gains determined in the AWB data analysis process in step S306 and stored in step S308 when the valid data is equal to or greater than the threshold at the previous capture.
(B) Capture R and B gains converted using the R and B gains of the through image in step S312 when (A) was not possible at the previous capture.
(C) Reference capture R, B read and determined in accordance with the light source in step S315 when (A) is not possible and (B) is not executed at the previous capture. gain.
(D) Capture R and B gains used in the previous capture read from the RAM in step S317 when (A), (B), and (C) are not executed during the previous capture.

したがって、特に限定しない場合、ステップS317では以上の(A)(B)(C)(D)のいずれかのキャプチャR、Bゲインが保持され、これを用いて前述のステップS309以降の処理が実行されることとなる。   Therefore, if not particularly limited, in step S317, any of the capture R and B gains in the above (A), (B), (C), and (D) is held, and the processing from step S309 onward is executed using this. Will be.

なお、本実施の形態においては主として、スルー画像を表示した状態でシャッターキーが押されると、その時点で撮像した画像を記録する電子スチルカメラについて説明したが、本発明は、前述したようなカメラに限定されることなく、撮像する画像のオートホワイトバランス制御を行う機器であれば他の装置にも適用することができる。   In the present embodiment, the electronic still camera that records an image captured at that time when the shutter key is pressed in a state where a through image is displayed has been described. However, the present invention is not limited to the above-described camera. The present invention is not limited to this, and any device that performs automatic white balance control of an image to be captured can be applied.

以上、この発明の実施形態について説明したが、この発明はこれらに限定されるものではなく、特許請求の範囲に記載された発明とその均等の範囲を含むものである。   As mentioned above, although embodiment of this invention was described, this invention is not limited to these, The invention described in the claim and its equal range are included.

以下に、本出願の特許請求の範囲に記載された発明を付記する。   The invention described in the claims of the present application will be added below.

<請求項1>
被写体を撮像して順次画像データを出力する撮像手段と、
前記撮像手段から順次出力される各画像データに基づき、ホワイトバランスを調整するための第1のホワイトバランス調整値を生成する第1の生成手段と、
この第1の生成手段により生成された第1のホワイトバランス調整値に基づき、当該画像データのホワイトバランスを調整して画像の表示に供する第1の制御手段と、
前記第1の生成手段により生成された前記第1のホワイトバランス調整値を記憶する調整値記憶手段と、
前記第1の制御手段による制御中における撮像指示に応答して、前記撮像手段から出力された画像データを取り込む取込手段と、
この取込手段により取り込まれた画像データがホワイトバランス調整値を生成する上で有効な画像データであるか否かを判断する第1の判断手段と、
この第1の判断手段により有効な画像データであると判断された場合に、前記取込手段により取り込まれた画像データに基づき、ホワイトバランスを調整するための第2のホワイトバランス調整値を生成する第2の生成手段と、
前記第1の判断手段により有効な画像データでないと判断された場合に、前記調整値記憶手段に記憶されている前記第1のホワイトバランス調整値を取得する取得手段と、
前記第2の生成手段により生成された第2のホワイトバランス調整値、及び前記取得手段により取得された第1のホワイトバランス調整値に基づき、前記取込手段により取り込まれた画像データのホワイトバランスを調整して画像の記録に供する第2の制御手段と、
を備えることを特徴とする撮像装置。
<Claim 1>
Imaging means for imaging a subject and sequentially outputting image data;
First generation means for generating a first white balance adjustment value for adjusting white balance based on each image data sequentially output from the imaging means;
First control means for adjusting the white balance of the image data based on the first white balance adjustment value generated by the first generation means and providing the image for display;
Adjustment value storage means for storing the first white balance adjustment value generated by the first generation means;
In response to an imaging instruction during control by the first control unit, a capturing unit that captures image data output from the imaging unit;
First determination means for determining whether or not the image data captured by the capture means is image data effective in generating a white balance adjustment value;
When it is determined by the first determination means that the image data is valid, a second white balance adjustment value for adjusting white balance is generated based on the image data captured by the capture means. A second generating means;
An acquisition means for acquiring the first white balance adjustment value stored in the adjustment value storage means when the first determination means determines that the image data is not valid;
Based on the second white balance adjustment value generated by the second generation unit and the first white balance adjustment value acquired by the acquisition unit, the white balance of the image data captured by the capture unit is calculated. A second control means for adjusting and providing for image recording;
An imaging apparatus comprising:

<請求項2>
前記第1の判断手段は、所定の色成分を有効データとして、前記取込手段により取り込まれた画像データにおける所定の検出領域内において前記有効データが閾値以上あるか否かを判断し、
<Claim 2>
The first determination means determines whether or not the valid data is equal to or greater than a threshold in a predetermined detection area in the image data captured by the capture means using a predetermined color component as valid data,

前記第2の生成手段は、前記第1の判断手段により前記有効データが閾値以上あると判断された場合に、前記取込手段により取り込まれた画像データに基づき、ホワイトバランスを調整するための第2のホワイトバランス調整値を生成し、   The second generation unit adjusts a white balance based on the image data captured by the capture unit when the first determination unit determines that the valid data is greater than or equal to a threshold value. 2 white balance adjustment values are generated,

前記取得手段は、前記第1の判断手段により前記有効データが閾値以上ないと判断された場合に、前記調整値記憶手段に記憶されている前記第1のホワイトバランス調整値を取得することを特徴とする請求項1記載の撮像装置。   The acquisition unit acquires the first white balance adjustment value stored in the adjustment value storage unit when the first determination unit determines that the valid data is not greater than or equal to a threshold value. The imaging apparatus according to claim 1.

<請求項3>
前記撮像手段から出力される画像データに基づき、撮像時における光源の種別を判定する判定手段を備え、
前記第1の判断手段は、前記判定手段により判定された光源の種別に応じた検出領域内において、前記画像データに有効データが閾値以上あるか否かを判断することを特徴とする請求項2記載の撮像装置。
<Claim 3>
Based on the image data output from the imaging means, comprising a determination means for determining the type of light source at the time of imaging,
The first determination unit determines whether or not the image data includes valid data that is equal to or greater than a threshold value within a detection region corresponding to a type of light source determined by the determination unit. The imaging device described.

<請求項4>
前記取得手段は、前記取込手段が前記画像データを取り込んだ直前に前記撮像手段から出力された画像データに基づき、前記第1の生成手段により生成され、前記調整値憶手段に記憶された第1のホワイトバランス調整値を取得することを特徴とする請求項1から3いずれか記載の撮像装置。
<Claim 4>
The acquisition means is a first generation means that is generated by the first generation means based on the image data output from the imaging means immediately before the acquisition means takes in the image data, and is stored in the adjustment value storage means. The image pickup apparatus according to claim 1, wherein a white balance adjustment value of 1 is acquired.

<請求項5>
前記第1の生成手段による第1のホワイトバランス調整値の生成が可能か否かを判断する第2の判断手段と、
この第2の判断手段により第1のホワイトバランス調整値の生成が不可能であると判断された場合、前記第1の生成手段による第1のホワイトバランス調整値の生成と前記調整値記憶手段による第1のホワイトバランス調整値の記憶を禁止する禁止手段と、
前記取込手段が前記画像データを取り込んだ直前に前記撮像手段から出力された画像データに基づき、前記第1の生成手段により生成され、前記調整値記憶手段に記憶された第1のホワイトバランス調整値があるか否かを判断する第3の判断手段とを備え、
前記取得手段は、前記第3の判断手段により前記直前に前記調整値記憶手段に記憶された第1のホワイトバランス調整値があると判断されたことを条件として、当該第1のホワイトバランス調整値を取得することを特徴とする請求項4記載の撮像装置。
<Claim 5>
Second determination means for determining whether or not the first white balance adjustment value can be generated by the first generation means;
If it is determined by the second determining means that the first white balance adjustment value cannot be generated, the first generating means generates the first white balance adjustment value and the adjustment value storing means. Prohibiting means for prohibiting storage of the first white balance adjustment value;
First white balance adjustment generated by the first generation unit and stored in the adjustment value storage unit based on the image data output from the imaging unit immediately before the capture unit captures the image data. A third determination means for determining whether or not there is a value;
The acquisition unit is conditioned on the condition that the third determination unit determines that there is a first white balance adjustment value stored in the adjustment value storage unit immediately before. The imaging apparatus according to claim 4, wherein:

<請求項6>
前記撮像手段から順次出力される画像データに基づき、光源の種別を判定する第1の判定手段と、
この第1の判定手段により今回判定された光源が前回判定された光源から変わったか否かを判定する第2の判定手段と、
前記光源の種別毎に基準とするホワイトバランス調整値を記憶したテーブル手段とを備え、
前記取得手段は、前記第3の判断手段により前記直前に前記調整値記憶手段に記憶された第1のホワイトバランス調整値がないと判断された場合において、
前記第2の判断手段により光源が変わったと判定された場合に、前記テーブル手段から前記第1の判定手段により判定された光源に対応するホワイトバランス調整値を取得する第1の取得手段と、
前記第2の判断手段により光源が変わらないと判定された場合に、当該時点において前記調整値記憶手段に記憶されている第1のホワイトバランス調整値を取得する第2の取得手段と、
を備えることを特徴とする請求項5記載の撮像装置。
<Claim 6>
First determination means for determining a type of a light source based on image data sequentially output from the imaging means;
Second determination means for determining whether the light source determined this time by the first determination means has changed from the light source determined last time;
Table means storing a white balance adjustment value as a reference for each type of light source,
In the case where it is determined that the first white balance adjustment value stored in the adjustment value storage unit is not immediately before by the third determination unit,
A first acquisition unit configured to acquire a white balance adjustment value corresponding to the light source determined by the first determination unit from the table unit when the second determination unit determines that the light source has changed;
A second acquisition unit configured to acquire a first white balance adjustment value stored in the adjustment value storage unit at the time when the second determination unit determines that the light source is not changed;
The imaging apparatus according to claim 5, further comprising:

<請求項7>
前記第1の判断手段は、光源毎に設定された所定の色成分を有効データとして、この有効データが閾値以上あるか否かを判断することを特徴とする請求項1から6にいずれか記載の撮像装置。
<Claim 7>
7. The first determination unit according to claim 1, wherein a predetermined color component set for each light source is used as effective data, and it is determined whether or not the effective data is greater than or equal to a threshold value. Imaging device.

<請求項8>
前記撮像手段に第1の撮影条件に基づく撮影処理と、前記第1の撮影条件とは異なる第2の撮影条件に基づく撮影処理を行わせる撮影制御手段を備え、
前記第1の生成手段は、前記第1の撮影条件に基づく撮影処理により得られる各画像データに基づき、ホワイトバランスを調整するための第1のホワイトバランス調整値を生成し、
前記取込手段は、前記第2の撮影条件に基づく撮影処理により得られた画像データを取り込み、
さらに、前記取得手段により取得された第1のホワイトバランス調整値を前記第2のホワイトバランス調整値に換算する換算手段を備え、
前記第2の制御手段は、前記第2の生成手段により生成された第2のホワイトバランス調整値、及び前記換算手段により換算された第2のホワイトバランス調整値に基づき、前記取込手段により取り込まれた画像データのホワイトバランスを調整して画像の記録に供することを特徴とする請求項1から7にいずれか記載の撮像装置。
<Claim 8>
A photographing control unit that causes the imaging unit to perform a photographing process based on a first photographing condition and a photographing process based on a second photographing condition different from the first photographing condition;
The first generation means generates a first white balance adjustment value for adjusting a white balance based on each image data obtained by a shooting process based on the first shooting condition,
The capturing means captures image data obtained by a photographing process based on the second photographing condition,
Furthermore, a conversion means for converting the first white balance adjustment value acquired by the acquisition means into the second white balance adjustment value,
The second control means captures by the capture means based on the second white balance adjustment value generated by the second generation means and the second white balance adjustment value converted by the conversion means. The imaging apparatus according to claim 1, wherein the image data is adjusted for white balance and used for image recording.

<請求項9>
前記換算手段は、前記第1のホワイトバランス調整値を前記第2のホワイトバランス調整値に変換する際に使用される両者の相対的関係を記憶した関係記憶手段と、
この関係記憶手段に記憶された関係に基づく係数を用いて、第1のホワイトバランス調整値に対応する第2のホワイトバランス調整値を算出する算出手段と、
を備えることを特徴とする請求項8記載の撮像装置。
<Claim 9>
The conversion means includes a relationship storage means for storing a relative relationship between the first white balance adjustment value and the second white balance adjustment value used when converting the first white balance adjustment value.
Calculating means for calculating a second white balance adjustment value corresponding to the first white balance adjustment value using a coefficient based on the relation stored in the relation storage means;
The imaging apparatus according to claim 8, further comprising:

<請求項10>
前記撮影制御手段は、当該撮像装置の出荷前において、所定の被写体を前記第1の撮影条件と第2の撮影条件とに基づく撮影処理を前記撮像手段に順次行わせることにより第1の画像データと第2の画像データを順次出力し、
前記関係記憶手段は、前記第1の画像データに基づき生成された第1のホワイトバランス調整値と前記第2の画像データに基づき生成された第2のホワイトバランス調整値に基づく情報を記憶することを特徴とする請求項9記載の撮像装置。
<Claim 10>
The imaging control unit causes the imaging unit to sequentially perform imaging processing based on the first imaging condition and the second imaging condition for the predetermined subject before the imaging device is shipped. And second image data are sequentially output,
The relation storage means stores information based on a first white balance adjustment value generated based on the first image data and a second white balance adjustment value generated based on the second image data. The imaging device according to claim 9.

<請求項11>
被写体を撮像して順次画像データを出力する撮像ステップと、
前記撮像ステップで順次出力される各画像データに基づき、ホワイトバランスを調整するための第1のホワイトバランス調整値を生成する第1の生成ステップと、
この第1の生成ステップで生成された第1のホワイトバランス調整値に基づき、当該画像データのホワイトバランスを調整して画像の表示に供する第1の制御ステップと、
前記第1の生成ステップで生成された前記第1のホワイトバランス調整値を記憶する調整値記憶ステップと、
前記第1の制御ステップによる制御中における撮像指示に応答して、前記撮像ステップで出力された画像データを取り込む取込ステップと、
この取込ステップで取り込まれた画像データがホワイトバランス調整値を生成する上で有効な画像データであるか否かを判断する判断ステップと、
この判断ステップにより有効な画像データであると判断された場合に、前記取込ステップで取り込まれた画像データに基づき、ホワイトバランスを調整するための第2のホワイトバランス調整値を生成する第2の生成ステップと、
前記第1の判断ステップで有効な画像データでないと判断された場合に、前記調整値記憶ステップで記憶されている前記第1のホワイトバランス調整値を取得する取得ステップと、
前記第2の生成ステップで生成された第2のホワイトバランス調整値、及び前記取得ステップで取得された第1のホワイトバランス調整値に基づき、前記取込ステップで取り込まれた画像データのホワイトバランスを調整して画像の記録に供する第2の制御ステップと、
を含むことを特徴とするホワイトバランス制御方法。
<Claim 11>
An imaging step of imaging a subject and sequentially outputting image data;
A first generation step of generating a first white balance adjustment value for adjusting white balance based on each image data sequentially output in the imaging step;
A first control step of adjusting the white balance of the image data based on the first white balance adjustment value generated in the first generation step and providing the image for display;
An adjustment value storage step for storing the first white balance adjustment value generated in the first generation step;
In response to an imaging instruction during control by the first control step, a capturing step for capturing the image data output in the imaging step;
A determination step for determining whether or not the image data captured in this capture step is effective image data for generating a white balance adjustment value;
When it is determined that the image data is valid in this determination step, a second white balance adjustment value for adjusting a white balance is generated based on the image data captured in the capture step. Generation step;
An acquisition step of acquiring the first white balance adjustment value stored in the adjustment value storage step when it is determined that the image data is not valid in the first determination step;
Based on the second white balance adjustment value generated in the second generation step and the first white balance adjustment value acquired in the acquisition step, the white balance of the image data acquired in the acquisition step is calculated. A second control step for adjusting and providing for image recording;
A white balance control method comprising:

<請求項12>
被写体を撮像して順次画像データを出力する撮像手段を備える装置が有するコンピュータを、
前記撮像手段から順次出力される各画像データに基づき、ホワイトバランスを調整するための第1のホワイトバランス調整値を生成する第1の生成手段と、
この第1の生成手段により生成された第1のホワイトバランス調整値に基づき、当該画像データのホワイトバランスを調整して画像の表示に供する第1の制御手段と、
前記第1の生成手段により生成された前記第1のホワイトバランス調整値を記憶する調整値記憶手段と、
前記第1の制御手段による制御中における撮像指示に応答して、前記撮像手段から出力された画像データを取り込む取込手段と、
この取込手段により取り込まれた画像データがホワイトバランス調整値を生成する上で有効な画像データであるか否かを判断する第1の判断手段と、
この第1の判断手段により有効な画像データであると判断された場合に、前記取込手段により取り込まれた画像データに基づき、ホワイトバランスを調整するための第2のホワイトバランス調整値を生成する第2の生成手段と、
前記第1の判断手段により有効な画像データでないと判断された場合に、前記調整値記憶手段に記憶されている前記第1のホワイトバランス調整値を取得する取得手段と、
前記第2の生成手段により生成された第2のホワイトバランス調整値、及び前記取得手段により取得された第1のホワイトバランス調整値に基づき、前記取込手段により取り込まれた画像データのホワイトバランスを調整して画像の記録に供する第2の制御手段と、
として機能させることを特徴とするホワイトバランス制御プログラム。
<Claim 12>
A computer included in an apparatus including an imaging unit that images a subject and sequentially outputs image data,
First generation means for generating a first white balance adjustment value for adjusting white balance based on each image data sequentially output from the imaging means;
First control means for adjusting the white balance of the image data based on the first white balance adjustment value generated by the first generation means and providing the image for display;
Adjustment value storage means for storing the first white balance adjustment value generated by the first generation means;
In response to an imaging instruction during control by the first control unit, a capturing unit that captures image data output from the imaging unit;
First determination means for determining whether or not the image data captured by the capture means is image data effective in generating a white balance adjustment value;
When it is determined by the first determination means that the image data is valid, a second white balance adjustment value for adjusting white balance is generated based on the image data captured by the capture means. A second generating means;
An acquisition means for acquiring the first white balance adjustment value stored in the adjustment value storage means when the first determination means determines that the image data is not valid;
Based on the second white balance adjustment value generated by the second generation unit and the first white balance adjustment value acquired by the acquisition unit, the white balance of the image data captured by the capture unit is calculated. A second control means for adjusting and providing for image recording;
White balance control program characterized by functioning as

21 第1ゲイン調整回路
22 第2ゲイン調整回路
23 第1カラープロセス回路
24 第2カラープロセス回路
25 CCD
26 タイミング信号発生器
27 垂直ドライバ
28 ユニット回路
28´ バッファメモリ
29 DMAコントローラ
30 DRAM
31 ビデオエンコーダ
32 表示装置
33 圧縮/伸張部
34 フラッシュメモリ
35 制御部
38 制御データ記憶部
381 ゲインテーブル
382 スルー検出枠テーブル
383 キャプチャ検出枠テーブル
384 スルー基準WBゲインテーブル
385 キャプチャ基準WBゲインテーブル
CKF キャプチャ光源フラグ
SKF スルー光源フラグ
UF 有効データフラグ
21 First gain adjustment circuit 22 Second gain adjustment circuit 23 First color process circuit 24 Second color process circuit 25 CCD
26 Timing signal generator 27 Vertical driver 28 Unit circuit 28 'Buffer memory 29 DMA controller 30 DRAM
31 Video encoder 32 Display device 33 Compression / decompression unit 34 Flash memory 35 Control unit 38 Control data storage unit 381 Gain table 382 Through detection frame table 383 Capture detection frame table 384 Through reference WB gain table 385 Capture reference WB gain table CKF Capture light source Flag SKF Through light source flag UF Valid data flag

Claims (12)

被写体を撮像して順次画像データを出力する撮像手段と、
前記撮像手段から順次出力される各画像データに基づき、ホワイトバランスを調整するための第1のホワイトバランス調整値を生成する第1の生成手段と、
この第1の生成手段により生成された第1のホワイトバランス調整値に基づき、当該画像データのホワイトバランスを調整して画像の表示に供する第1の制御手段と、
前記第1の生成手段により生成された前記第1のホワイトバランス調整値を記憶する調整値記憶手段と、
前記第1の制御手段による制御中における撮像指示に応答して、前記撮像手段から出力された画像データを取り込む取込手段と、
この取込手段により取り込まれた画像データがホワイトバランス調整値を生成する上で有効な画像データであるか否かを判断する第1の判断手段と、
この第1の判断手段により有効な画像データであると判断された場合に、前記取込手段により取り込まれた画像データに基づき、ホワイトバランスを調整するための第2のホワイトバランス調整値を生成する第2の生成手段と、
前記第1の判断手段により有効な画像データでないと判断された場合に、前記調整値記憶手段に記憶されている前記第1のホワイトバランス調整値を取得する取得手段と、
前記第2の生成手段により生成された第2のホワイトバランス調整値、及び前記取得手段により取得された第1のホワイトバランス調整値に基づき、前記取込手段により取り込まれた画像データのホワイトバランスを調整して画像の記録に供する第2の制御手段と、
を備えることを特徴とする撮像装置。
Imaging means for imaging a subject and sequentially outputting image data;
First generation means for generating a first white balance adjustment value for adjusting white balance based on each image data sequentially output from the imaging means;
First control means for adjusting the white balance of the image data based on the first white balance adjustment value generated by the first generation means and providing the image for display;
Adjustment value storage means for storing the first white balance adjustment value generated by the first generation means;
In response to an imaging instruction during control by the first control unit, a capturing unit that captures image data output from the imaging unit;
First determination means for determining whether or not the image data captured by the capture means is image data effective in generating a white balance adjustment value;
When it is determined by the first determination means that the image data is valid, a second white balance adjustment value for adjusting white balance is generated based on the image data captured by the capture means. A second generating means;
An acquisition means for acquiring the first white balance adjustment value stored in the adjustment value storage means when the first determination means determines that the image data is not valid;
Based on the second white balance adjustment value generated by the second generation unit and the first white balance adjustment value acquired by the acquisition unit, the white balance of the image data captured by the capture unit is calculated. A second control means for adjusting and providing for image recording;
An imaging apparatus comprising:
前記第1の判断手段は、所定の色成分を有効データとして、前記取込手段により取り込まれた画像データにおける所定の検出領域内において前記有効データが閾値以上あるか否かを判断し、
前記第2の生成手段は、前記第1の判断手段により前記有効データが閾値以上あると判断された場合に、前記取込手段により取り込まれた画像データに基づき、ホワイトバランスを調整するための第2のホワイトバランス調整値を生成し、
前記取得手段は、前記第1の判断手段により前記有効データが閾値以上ないと判断された場合に、前記調整値記憶手段に記憶されている前記第1のホワイトバランス調整値を取得することを特徴とする請求項1記載の撮像装置。
The first determination means determines whether or not the valid data is equal to or greater than a threshold in a predetermined detection area in the image data captured by the capture means using a predetermined color component as valid data,
The second generation unit adjusts a white balance based on the image data captured by the capture unit when the first determination unit determines that the valid data is greater than or equal to a threshold value. 2 white balance adjustment values are generated,
The acquisition unit acquires the first white balance adjustment value stored in the adjustment value storage unit when the first determination unit determines that the valid data is not greater than or equal to a threshold value. The imaging apparatus according to claim 1.
前記撮像手段から出力される画像データに基づき、撮像時における光源の種別を判定する判定手段を備え、
前記第1の判断手段は、前記判定手段により判定された光源の種別に応じた検出領域内において、前記画像データに有効データが閾値以上あるか否かを判断することを特徴とする請求項2記載の撮像装置。
Based on the image data output from the imaging means, comprising a determination means for determining the type of light source at the time of imaging,
The first determination unit determines whether or not the image data includes valid data that is equal to or greater than a threshold value within a detection region corresponding to a type of light source determined by the determination unit. The imaging device described.
前記取得手段は、前記取込手段が前記画像データを取り込んだ直前に前記撮像手段から出力された画像データに基づき、前記第1の生成手段により生成され、前記調整値憶手段に記憶された第1のホワイトバランス調整値を取得することを特徴とする請求項1から3いずれか記載の撮像装置。   The acquisition means is a first generation means that is generated by the first generation means based on the image data output from the imaging means immediately before the acquisition means takes in the image data, and is stored in the adjustment value storage means. The image pickup apparatus according to claim 1, wherein a white balance adjustment value of 1 is acquired. 前記第1の生成手段による第1のホワイトバランス調整値の生成が可能か否かを判断する第2の判断手段と、
この第2の判断手段により第1のホワイトバランス調整値の生成が不可能であると判断された場合、前記第1の生成手段による第1のホワイトバランス調整値の生成と前記調整値記憶手段による第1のホワイトバランス調整値の記憶を禁止する禁止手段と、
前記取込手段が前記画像データを取り込んだ直前に前記撮像手段から出力された画像データに基づき、前記第1の生成手段により生成され、前記調整値記憶手段に記憶された第1のホワイトバランス調整値があるか否かを判断する第3の判断手段とを備え、
前記取得手段は、前記第3の判断手段により前記直前に前記調整値記憶手段に記憶された第1のホワイトバランス調整値があると判断されたことを条件として、当該第1のホワイトバランス調整値を取得することを特徴とする請求項4記載の撮像装置。
Second determination means for determining whether or not the first white balance adjustment value can be generated by the first generation means;
If it is determined by the second determining means that the first white balance adjustment value cannot be generated, the first generating means generates the first white balance adjustment value and the adjustment value storing means. Prohibiting means for prohibiting storage of the first white balance adjustment value;
First white balance adjustment generated by the first generation unit and stored in the adjustment value storage unit based on the image data output from the imaging unit immediately before the capture unit captures the image data. A third determination means for determining whether or not there is a value;
The acquisition unit is conditioned on the condition that the third determination unit determines that there is a first white balance adjustment value stored in the adjustment value storage unit immediately before. The imaging apparatus according to claim 4, wherein:
前記撮像手段から順次出力される画像データに基づき、光源の種別を判定する第1の判定手段と、
この第1の判定手段により今回判定された光源が前回判定された光源から変わったか否かを判定する第2の判定手段と、
前記光源の種別毎に基準とするホワイトバランス調整値を記憶したテーブル手段とを備え、
前記取得手段は、前記第3の判断手段により前記直前に前記調整値記憶手段に記憶された第1のホワイトバランス調整値がないと判断された場合において、
前記第2の判断手段により光源が変わったと判定された場合に、前記テーブル手段から前記第1の判定手段により判定された光源に対応するホワイトバランス調整値を取得する第1の取得手段と、
前記第2の判断手段により光源が変わらないと判定された場合に、当該時点において前記調整値記憶手段に記憶されている第1のホワイトバランス調整値を取得する第2の取得手段と、
を備えることを特徴とする請求項5記載の撮像装置。
First determination means for determining a type of a light source based on image data sequentially output from the imaging means;
Second determination means for determining whether the light source determined this time by the first determination means has changed from the light source determined last time;
Table means storing a white balance adjustment value as a reference for each type of light source,
In the case where it is determined that the first white balance adjustment value stored in the adjustment value storage unit is not immediately before by the third determination unit,
A first acquisition unit configured to acquire a white balance adjustment value corresponding to the light source determined by the first determination unit from the table unit when the second determination unit determines that the light source has changed;
A second acquisition unit configured to acquire a first white balance adjustment value stored in the adjustment value storage unit at the time when the second determination unit determines that the light source is not changed;
The imaging apparatus according to claim 5, further comprising:
前記第1の判断手段は、光源毎に設定された所定の色成分を有効データとして、この有効データが閾値以上あるか否かを判断することを特徴とする請求項1から6にいずれか記載の撮像装置。   7. The first determination unit according to claim 1, wherein a predetermined color component set for each light source is used as effective data, and it is determined whether or not the effective data is greater than or equal to a threshold value. Imaging device. 前記撮像手段に第1の撮影条件に基づく撮影処理と、前記第1の撮影条件とは異なる第2の撮影条件に基づく撮影処理を行わせる撮影制御手段を備え、
前記第1の生成手段は、前記第1の撮影条件に基づく撮影処理により得られる各画像データに基づき、ホワイトバランスを調整するための第1のホワイトバランス調整値を生成し、
前記取込手段は、前記第2の撮影条件に基づく撮影処理により得られた画像データを取り込み、
さらに、前記取得手段により取得された第1のホワイトバランス調整値を前記第2のホワイトバランス調整値に換算する換算手段を備え、
前記第2の制御手段は、前記第2の生成手段により生成された第2のホワイトバランス調整値、及び前記換算手段により換算された第2のホワイトバランス調整値に基づき、前記取込手段により取り込まれた画像データのホワイトバランスを調整して画像の記録に供することを特徴とする請求項1から7にいずれか記載の撮像装置。
A photographing control unit that causes the imaging unit to perform a photographing process based on a first photographing condition and a photographing process based on a second photographing condition different from the first photographing condition;
The first generation means generates a first white balance adjustment value for adjusting a white balance based on each image data obtained by a shooting process based on the first shooting condition,
The capturing means captures image data obtained by a photographing process based on the second photographing condition,
Furthermore, a conversion means for converting the first white balance adjustment value acquired by the acquisition means into the second white balance adjustment value,
The second control means captures by the capture means based on the second white balance adjustment value generated by the second generation means and the second white balance adjustment value converted by the conversion means. The imaging apparatus according to claim 1, wherein the image data is adjusted for white balance and used for image recording.
前記換算手段は、前記第1のホワイトバランス調整値を前記第2のホワイトバランス調整値に変換する際に使用される両者の相対的関係を記憶した関係記憶手段と、
この関係記憶手段に記憶された関係に基づく係数を用いて、第1のホワイトバランス調整値に対応する第2のホワイトバランス調整値を算出する算出手段と、
を備えることを特徴とする請求項8記載の撮像装置。
The conversion means includes a relationship storage means for storing a relative relationship between the first white balance adjustment value and the second white balance adjustment value used when converting the first white balance adjustment value.
Calculating means for calculating a second white balance adjustment value corresponding to the first white balance adjustment value using a coefficient based on the relation stored in the relation storage means;
The imaging apparatus according to claim 8, further comprising:
前記撮影制御手段は、当該撮像装置の出荷前において、所定の被写体を前記第1の撮影条件と第2の撮影条件とに基づく撮影処理を前記撮像手段に順次行わせることにより第1の画像データと第2の画像データを順次出力し、
前記関係記憶手段は、前記第1の画像データに基づき生成された第1のホワイトバランス調整値と前記第2の画像データに基づき生成された第2のホワイトバランス調整値に基づく情報を記憶することを特徴とする請求項9記載の撮像装置。
The imaging control unit causes the imaging unit to sequentially perform imaging processing based on the first imaging condition and the second imaging condition for the predetermined subject before the imaging device is shipped. And second image data are sequentially output,
The relation storage means stores information based on a first white balance adjustment value generated based on the first image data and a second white balance adjustment value generated based on the second image data. The imaging device according to claim 9.
被写体を撮像して順次画像データを出力する撮像ステップと、
前記撮像ステップで順次出力される各画像データに基づき、ホワイトバランスを調整するための第1のホワイトバランス調整値を生成する第1の生成ステップと、
この第1の生成ステップで生成された第1のホワイトバランス調整値に基づき、当該画像データのホワイトバランスを調整して画像の表示に供する第1の制御ステップと、
前記第1の生成ステップで生成された前記第1のホワイトバランス調整値を記憶する調整値記憶ステップと、
前記第1の制御ステップによる制御中における撮像指示に応答して、前記撮像ステップで出力された画像データを取り込む取込ステップと、
この取込ステップで取り込まれた画像データがホワイトバランス調整値を生成する上で有効な画像データであるか否かを判断する判断ステップと、
この判断ステップにより有効な画像データであると判断された場合に、前記取込ステップで取り込まれた画像データに基づき、ホワイトバランスを調整するための第2のホワイトバランス調整値を生成する第2の生成ステップと、
前記第1の判断ステップで有効な画像データでないと判断された場合に、前記調整値記憶ステップで記憶されている前記第1のホワイトバランス調整値を取得する取得ステップと、
前記第2の生成ステップで生成された第2のホワイトバランス調整値、及び前記取得ステップで取得された第1のホワイトバランス調整値に基づき、前記取込ステップで取り込まれた画像データのホワイトバランスを調整して画像の記録に供する第2の制御ステップと、
を含むことを特徴とするホワイトバランス制御方法。
An imaging step of imaging a subject and sequentially outputting image data;
A first generation step of generating a first white balance adjustment value for adjusting white balance based on each image data sequentially output in the imaging step;
A first control step of adjusting the white balance of the image data based on the first white balance adjustment value generated in the first generation step and providing the image for display;
An adjustment value storage step for storing the first white balance adjustment value generated in the first generation step;
In response to an imaging instruction during control by the first control step, a capturing step for capturing the image data output in the imaging step;
A determination step for determining whether or not the image data captured in this capture step is effective image data for generating a white balance adjustment value;
When it is determined that the image data is valid in this determination step, a second white balance adjustment value for adjusting a white balance is generated based on the image data captured in the capture step. Generation step;
An acquisition step of acquiring the first white balance adjustment value stored in the adjustment value storage step when it is determined that the image data is not valid in the first determination step;
Based on the second white balance adjustment value generated in the second generation step and the first white balance adjustment value acquired in the acquisition step, the white balance of the image data acquired in the acquisition step is calculated. A second control step for adjusting and providing for image recording;
A white balance control method comprising:
被写体を撮像して順次画像データを出力する撮像手段を備える装置が有するコンピュータを、
前記撮像手段から順次出力される各画像データに基づき、ホワイトバランスを調整するための第1のホワイトバランス調整値を生成する第1の生成手段と、
この第1の生成手段により生成された第1のホワイトバランス調整値に基づき、当該画像データのホワイトバランスを調整して画像の表示に供する第1の制御手段と、
前記第1の生成手段により生成された前記第1のホワイトバランス調整値を記憶する調整値記憶手段と、
前記第1の制御手段による制御中における撮像指示に応答して、前記撮像手段から出力された画像データを取り込む取込手段と、
この取込手段により取り込まれた画像データがホワイトバランス調整値を生成する上で有効な画像データであるか否かを判断する第1の判断手段と、
この第1の判断手段により有効な画像データであると判断された場合に、前記取込手段により取り込まれた画像データに基づき、ホワイトバランスを調整するための第2のホワイトバランス調整値を生成する第2の生成手段と、
前記第1の判断手段により有効な画像データでないと判断された場合に、前記調整値記憶手段に記憶されている前記第1のホワイトバランス調整値を取得する取得手段と、
前記第2の生成手段により生成された第2のホワイトバランス調整値、及び前記取得手段により取得された第1のホワイトバランス調整値に基づき、前記取込手段により取り込まれた画像データのホワイトバランスを調整して画像の記録に供する第2の制御手段と、
として機能させることを特徴とするホワイトバランス制御プログラム。
A computer included in an apparatus including an imaging unit that images a subject and sequentially outputs image data,
First generation means for generating a first white balance adjustment value for adjusting white balance based on each image data sequentially output from the imaging means;
First control means for adjusting the white balance of the image data based on the first white balance adjustment value generated by the first generation means and providing the image for display;
Adjustment value storage means for storing the first white balance adjustment value generated by the first generation means;
In response to an imaging instruction during control by the first control unit, a capturing unit that captures image data output from the imaging unit;
First determination means for determining whether or not the image data captured by the capture means is image data effective in generating a white balance adjustment value;
When it is determined by the first determination means that the image data is valid, a second white balance adjustment value for adjusting white balance is generated based on the image data captured by the capture means. A second generating means;
An acquisition means for acquiring the first white balance adjustment value stored in the adjustment value storage means when the first determination means determines that the image data is not valid;
Based on the second white balance adjustment value generated by the second generation unit and the first white balance adjustment value acquired by the acquisition unit, the white balance of the image data captured by the capture unit is calculated. A second control means for adjusting and providing for image recording;
White balance control program characterized by functioning as
JP2012011780A 2012-01-24 2012-01-24 Imaging apparatus, white balance control method, and white balance control program Expired - Fee Related JP5885023B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2012011780A JP5885023B2 (en) 2012-01-24 2012-01-24 Imaging apparatus, white balance control method, and white balance control program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012011780A JP5885023B2 (en) 2012-01-24 2012-01-24 Imaging apparatus, white balance control method, and white balance control program

Publications (2)

Publication Number Publication Date
JP2013153248A true JP2013153248A (en) 2013-08-08
JP5885023B2 JP5885023B2 (en) 2016-03-15

Family

ID=49049291

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012011780A Expired - Fee Related JP5885023B2 (en) 2012-01-24 2012-01-24 Imaging apparatus, white balance control method, and white balance control program

Country Status (1)

Country Link
JP (1) JP5885023B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017092544A (en) * 2015-11-04 2017-05-25 カシオ計算機株式会社 Output control device, output control method and program

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2003143622A (en) * 2001-11-07 2003-05-16 Sanyo Electric Co Ltd Image processor
JP2007228155A (en) * 2006-02-22 2007-09-06 Olympus Imaging Corp Electronic imaging device and method therefor
JP2010103672A (en) * 2008-10-22 2010-05-06 Ricoh Co Ltd Imaging device
JP2011055170A (en) * 2009-08-31 2011-03-17 Canon Inc Information processing apparatus and control method therefor

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2003143622A (en) * 2001-11-07 2003-05-16 Sanyo Electric Co Ltd Image processor
JP2007228155A (en) * 2006-02-22 2007-09-06 Olympus Imaging Corp Electronic imaging device and method therefor
JP2010103672A (en) * 2008-10-22 2010-05-06 Ricoh Co Ltd Imaging device
JP2011055170A (en) * 2009-08-31 2011-03-17 Canon Inc Information processing apparatus and control method therefor

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017092544A (en) * 2015-11-04 2017-05-25 カシオ計算機株式会社 Output control device, output control method and program

Also Published As

Publication number Publication date
JP5885023B2 (en) 2016-03-15

Similar Documents

Publication Publication Date Title
JP4254841B2 (en) Imaging apparatus, imaging method, image processing apparatus, image processing method, and image processing program
KR100689307B1 (en) Image pick-up apparatus and method of controlling auto white balance
JP6455601B2 (en) Control system, imaging apparatus, and program
JP4615458B2 (en) Exposure control method and imaging apparatus
JP4305327B2 (en) Imaging apparatus, white balance control method, and white balance control program
JP3896438B2 (en) Digital camera and auto white balance control method
JP2011166753A (en) Imaging apparatus
US20090027514A1 (en) Image pickup apparatus and method
US7876366B2 (en) Electronic camera
JP2010187113A (en) Imaging apparatus, and white balance bracketing photographing program
JP3630149B2 (en) Imaging apparatus, white balance control method, and white balance control program
JP5316923B2 (en) Imaging apparatus and program thereof
JP5885023B2 (en) Imaging apparatus, white balance control method, and white balance control program
JP2012119756A (en) Imaging apparatus and white-balance control method
KR20110027118A (en) Digital photographing apparatus, method for controlling the same, and recording medium storing program to execute the method
JP5803233B2 (en) Imaging apparatus and imaging method
JP2016046610A (en) Imaging apparatus
US8041206B2 (en) Imaging apparatus and method for controlling flash emission
JP2006217249A (en) Electronic camera, electronic camera system and program
JP2013192088A (en) Imaging apparatus, control method, and control program
KR101589493B1 (en) White ballance control method and apparatus using a flash and digital photographing apparatus using thereof
JP2009206906A (en) Electronic camera
JP2007074201A (en) Photographing apparatus
JP2012227744A (en) Imaging apparatus
JP2018186363A (en) Imaging apparatus

Legal Events

Date Code Title Description
RD02 Notification of acceptance of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7422

Effective date: 20140702

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20150107

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20150729

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20150731

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20150918

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20160127

R150 Certificate of patent or registration of utility model

Ref document number: 5885023

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

LAPS Cancellation because of no payment of annual fees