JP6080579B2 - Imaging apparatus and control method thereof - Google Patents

Imaging apparatus and control method thereof Download PDF

Info

Publication number
JP6080579B2
JP6080579B2 JP2013021798A JP2013021798A JP6080579B2 JP 6080579 B2 JP6080579 B2 JP 6080579B2 JP 2013021798 A JP2013021798 A JP 2013021798A JP 2013021798 A JP2013021798 A JP 2013021798A JP 6080579 B2 JP6080579 B2 JP 6080579B2
Authority
JP
Japan
Prior art keywords
image
evaluation value
exposure
images
amount
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
Application number
JP2013021798A
Other languages
Japanese (ja)
Other versions
JP2014154979A (en
Inventor
稔 坂井田
稔 坂井田
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2013021798A priority Critical patent/JP6080579B2/en
Publication of JP2014154979A publication Critical patent/JP2014154979A/en
Application granted granted Critical
Publication of JP6080579B2 publication Critical patent/JP6080579B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Description

本発明は画像から得られる評価値に基づいて撮像制御を行う撮像装置およびその制御方法に関する。   The present invention relates to an imaging apparatus that performs imaging control based on an evaluation value obtained from an image, and a control method therefor.

白飛びや黒つぶれを抑制するために、露出を異ならせて同一シーンを撮影した複数の画像のうち、階調情報が記録されている部分を合成することにより、撮影ダイナミックレンジより広いダイナミックレンジを有する画像を得る方法が知られている。本明細書ではこのようなダイナミックレンジ拡大処理をHDR(High Dynamic Range)処理と呼ぶ。   To suppress overexposure and underexposure, the dynamic range that is wider than the shooting dynamic range can be obtained by combining the portions where the gradation information is recorded from multiple images shot from the same scene with different exposures. A method for obtaining an image having the same is known. In this specification, such dynamic range expansion processing is referred to as HDR (High Dynamic Range) processing.

従来、HDR処理は静止画撮影にのみ用いられていたが、HDR処理を適用して各フレームを生成することにより動画撮影にも適用できる。以下、動画フレームに対するHDR処理を動画HDR処理と呼ぶ。動画HDR処理では、各フレームを生成するために異なる露出の複数の画像が必要となるため、露出の異なる画像が順次撮影される。   Conventionally, HDR processing has been used only for still image shooting, but it can also be applied to moving image shooting by generating each frame by applying HDR processing. Hereinafter, the HDR processing for the moving image frame is referred to as moving image HDR processing. In the moving image HDR process, a plurality of images with different exposures are required to generate each frame, and therefore images with different exposures are sequentially captured.

このような撮影が順次行われる場合に、画像のコントラスト情報より合焦状態を評価してフォーカス制御を行う、コントラスト検出方式のフォーカス制御(以下、コントラストAF制御という)では、被写体に追従したAF制御が精度よく行えない場合がある。   When such shooting is performed sequentially, focus control is performed by evaluating the in-focus state from the contrast information of the image. In contrast detection type focus control (hereinafter referred to as contrast AF control), AF control that follows the subject is performed. May not be accurate.

特許文献1では、複数の露出画像より得られた、コントラストAFに用いる評価値(以下、単にAF評価値と呼ぶ。)に対して、露出の差に応じたゲインを重畳することで、露出の差がAF評価値へ与える影響を除去する技術が提案されている。   In Patent Document 1, an exposure value obtained by superimposing a gain corresponding to an exposure difference on an evaluation value (hereinafter simply referred to as an AF evaluation value) used for contrast AF obtained from a plurality of exposure images. A technique for removing the effect of the difference on the AF evaluation value has been proposed.

特開2002−323649号公報JP 2002-323649 A

しかし、特許文献1では、例えば被写体に動きのある場合に露出の差がAF評価値に与える影響を除去できない場合があるなど、撮影環境に応じた制御について考慮されていなかった。また、この問題はAF評価値に限らず、撮影画像から得られる情報に基づく評価値全般において課題となり得る。   However, in Patent Document 1, for example, when the subject moves, the influence of the exposure difference on the AF evaluation value may not be removed, and control according to the shooting environment is not considered. In addition, this problem is not limited to the AF evaluation value, and can be a problem in general evaluation values based on information obtained from the captured image.

本発明はこのような従来技術の課題に鑑みてなされたものであり、異なる露出量で撮影された画像から得られる評価値を用いた撮像制御の追従性を向上させた撮像装置およびその制御方法の提供を目的とする。   The present invention has been made in view of the above-described problems of the prior art, and an imaging apparatus with improved follow-up capability of imaging control using evaluation values obtained from images captured with different exposure amounts and a control method thereof The purpose is to provide.

上述の目的は、フレームごとに露光量を異ならせて順次撮像を行う撮像手段と、撮像手段によって得られた複数の画像を合成した合成画像をフレーム画像とする動画を生成する画像処理手段と、画像間の被写体の動き量を検出する検出手段と、撮像手段のフォーカス制御に用いる評価値を生成する生成手段と、生成手段によって生成され評価値に基づいて、撮像手段のフォーカス制御する制御手段と、を有し、制御手段は、複数の画像間の露光量の差が第1閾値より大きい場合は、複数の画像のうちで最も露光量が大きい画像から生成した評価値を用いてフォーカス制御を行い、複数の画像間の露光量の差が第1閾値よりも小さい場合は、被写体の動き量に応じて何れかの画像を選択し、選択された画像から生成した評価値を用いてフォーカス制御を行うことを特徴とする撮像装置によって達成される。 The above-described object is to provide an imaging unit that sequentially captures images with different exposure amounts for each frame, an image processing unit that generates a moving image using a composite image obtained by combining a plurality of images obtained by the imaging unit , and a frame image ; Detection means for detecting the amount of movement of a subject between images , generation means for generating an evaluation value used for focus control of the imaging means , and control means for controlling focus of the imaging means based on the evaluation value generated by the generation means And when the difference in exposure amount between the plurality of images is greater than the first threshold , the control means performs focus control using an evaluation value generated from an image having the largest exposure amount among the plurality of images. If the difference in exposure amount between the plurality of images is smaller than the first threshold value, one of the images is selected according to the amount of movement of the subject, and the evaluation value generated from the selected image is used for the foreground. It is achieved by an imaging device and performs scan control.

このような構成により、本発明によれば、異なる露出量で撮影された画像から得られるAF評価値を用いたフォーカス制御の追従性を向上させた撮像装置およびその制御方法を提供できる。   With such a configuration, according to the present invention, it is possible to provide an imaging apparatus and a control method thereof that improve the follow-up performance of focus control using AF evaluation values obtained from images captured with different exposure amounts.

実施形態に係る撮像装置の機能構成例を示すブロック図1 is a block diagram illustrating an example of a functional configuration of an imaging apparatus according to an embodiment HDR処理に係る画像とその輝度ヒストグラムの例を模式的に示す図The figure which shows the example of the image which concerns on HDR processing, and its luminance histogram typically 実施形態における、動画HDR処理時の撮影、合成、AF評価値取得、フォーカス制御のタイミング例を示すタイミングチャートTiming chart showing timing examples of shooting, composition, AF evaluation value acquisition, and focus control during moving image HDR processing in the embodiment 実施形態における低露出画像の露出段差量の制御を説明するためのフローチャートFlowchart for explaining control of exposure step amount of low-exposure image in the embodiment フォーカスレンズ位置とコントラストAF評価値との関係例を示す図The figure which shows the example of relationship between focus lens position and contrast AF evaluation value 第1の実施形態におけるフォーカス制御を説明するためのフローチャートFlowchart for explaining focus control in the first embodiment 図6のS608におけるAF評価値選択処理を説明するためのフローチャートFlowchart for explaining AF evaluation value selection processing in S608 of FIG. 実施形態におけるAF評価値の選択および合成に利用可能な撮影情報の例を示す図The figure which shows the example of the imaging | photography information which can be utilized for selection and the synthesis | combination of AF evaluation value in embodiment 第2の実施形態におけるフォーカス制御を説明するためのフローチャートFlowchart for explaining focus control in the second embodiment 図9のS901におけるAF評価値合成処理を説明するためのフローチャートFlowchart for explaining AF evaluation value composition processing in S901 of FIG. (a)は第2の実施形態における動き量と合成係数との関係例を、(b)は(a)は第2の実施形態における露出段差量と合成係数との関係例を示す図(A) is an example of the relationship between the amount of motion and the synthesis coefficient in the second embodiment, (b) is a diagram showing an example of the relationship between the exposure step amount and the synthesis coefficient in the second embodiment. 複数のAF評価枠の例を模式的に示す図Diagram showing examples of multiple AF evaluation frames 第3の実施形態におけるフォーカス制御を説明するためのフローチャートFlowchart for explaining focus control in the third embodiment 第1の実施形態におけるAF評価値選択部の機能構成例を示すブロック図FIG. 2 is a block diagram illustrating an example of a functional configuration of an AF evaluation value selection unit according to the first embodiment. 第2の実施形態におけるAF評価値合成部の機能構成例を示すブロック図The block diagram which shows the function structural example of AF evaluation value synthetic | combination part in 2nd Embodiment

以下、添付図面を参照して、本発明の例示的な実施形態について詳細に説明する。
まず、特許文献1の技術では、例えば被写体に動きのある場合に露出の差がAF評価値に与える影響を除去できない場合がある理由について図5を用いて説明する。
図5は、横軸をフォーカスレンズ位置、縦軸をAF評価値として、フォーカスレンズ位置に応じたAF評価値の変化を示している。図に示されるように、フォーカスレンズ位置が合焦位置となると、AF評価値は最大値となる。
Hereinafter, exemplary embodiments of the present invention will be described in detail with reference to the accompanying drawings.
First, the technique of Patent Document 1 will be described with reference to FIG. 5 for the reason that the influence of the exposure difference on the AF evaluation value may not be removed when the subject moves, for example.
FIG. 5 shows a change in the AF evaluation value according to the focus lens position, with the horizontal axis as the focus lens position and the vertical axis as the AF evaluation value. As shown in the figure, when the focus lens position becomes the in-focus position, the AF evaluation value becomes the maximum value.

図5(a)は、同一静止被写体を適正露出で撮影した画像から算出したAF評価値501と、露出不足で撮影した画像(低露出画像)から算出したAF評価値502を示している。また、図5(b)は、同一動被写体を適正露出で撮影した画像から算出したAF評価値501と、低露出画像から算出したAF評価値502を示している。   FIG. 5A shows an AF evaluation value 501 calculated from an image obtained by photographing the same still subject with appropriate exposure, and an AF evaluation value 502 calculated from an image obtained by underexposure (low exposure image). FIG. 5B shows an AF evaluation value 501 calculated from an image obtained by photographing the same moving subject with appropriate exposure, and an AF evaluation value 502 calculated from a low-exposure image.

露光時間を変更して露出量に差をつける場合、動被写体の速度が一定であれば、撮影した画像における被写体ブレの量は、露出不足で撮影した画像の方が少なくなる。また、手ぶれの量についても同様の関係がある。コントラストはブレが少ない方が高くなるため、露出不足で撮影した画像から算出したAF評価値502の方が適正露出で撮影した画像から算出したAF評価値501よりも高く、その差は動被写体を撮影した場合の方が大きい。   When changing the exposure time to make a difference in the exposure amount, if the speed of the moving subject is constant, the amount of subject blurring in the captured image is smaller in the image captured due to underexposure. There is a similar relationship regarding the amount of camera shake. Since the contrast is higher when there is less blur, the AF evaluation value 502 calculated from an image shot with underexposure is higher than the AF evaluation value 501 calculated from an image shot with appropriate exposure, and the difference is the difference between moving subjects. Larger when shooting.

このように、露出量を変えながら動被写体を順次撮影した画像が入力される場合には、AF評価値がフレーム毎に変動する量が大きくなり、合焦状態の評価が困難となる場合がある。この場合、動被写体に追従したフォーカスができない。
また、この問題はAF評価値に限らず、被写体検出のための評価値、露出制御のための評価値、ホワイトバランス処理のための評価値など、撮影画像から得られる情報に基づく評価値全般において課題となり得る。
As described above, when an image obtained by sequentially capturing moving subjects while changing the exposure amount is input, the amount by which the AF evaluation value fluctuates for each frame becomes large, and it may be difficult to evaluate the in-focus state. . In this case, it is impossible to focus following the moving subject.
In addition, this problem is not limited to AF evaluation values. In general evaluation values based on information obtained from captured images, such as evaluation values for subject detection, evaluation values for exposure control, and evaluation values for white balance processing. It can be a challenge.

そこで、本実施形態では、異なる露出条件で撮影された複数の画像の各々から得られる評価値のうち、撮像装置や被写体の動き、白飛び・黒つぶれの状況などから信頼度がより高いと判定される評価値を少なくとも1つ選択し用いることを特徴とする。   Therefore, in the present embodiment, among the evaluation values obtained from each of a plurality of images taken under different exposure conditions, it is determined that the reliability is higher from the movement of the imaging device or the subject, the state of overexposure / blackout, etc. At least one evaluation value to be selected is selected and used.

図1は、本発明の第1の実施形態に係る撮像装置の機能構成例を示すブロック図である。なお、各機能ブロックは、個別のハードウェアで実現されてもよいし、ソフトウェアをプログラマブルプロセッサが実行することによって実現されてもよい。また、図において別個の機能ブロックとして記載されている機能が、1つのハードウェアで実現されてもよいし、1つの機能ブロックが複数のハードウェアで実現されてもよい。   FIG. 1 is a block diagram illustrating a functional configuration example of an imaging apparatus according to the first embodiment of the present invention. Each functional block may be realized by individual hardware, or may be realized by executing software by a programmable processor. In addition, the functions described as separate functional blocks in the figure may be realized by a single piece of hardware, or a single functional block may be realized by a plurality of pieces of hardware.

フォーカスレンズを含んだ光学系101によって撮像素子102に結像された被写体像は、撮像素子102によって画像信号に変換される。画像処理部103はこの画像信号に対してホワイトバランス処理や、デモザイク処理、色(輝度・色差信号)変換処理、γ補正処理などを適用する。また、画像処理部103は、入力される画像信号を用いて公知のマッチング等の手法によって評価値を算出し、被写体の検出処理を行う。例えば顔検出などを行う。得られる被写体検出の検出結果は、本実施形態において各評価値を算出する際に、被写体検出領域に重みをつける、などの制御に利用されたり、画像を表示する際に被写体検出領域をユーザに知らしめるために利用されたりする。このような被写体検出のための評価値もAF評価値と同様に撮影環境によってどの露出画像が評価値取得に適切かという課題が生じ得る。   A subject image formed on the image sensor 102 by the optical system 101 including the focus lens is converted into an image signal by the image sensor 102. The image processing unit 103 applies white balance processing, demosaic processing, color (luminance / color difference signal) conversion processing, γ correction processing, and the like to this image signal. In addition, the image processing unit 103 calculates an evaluation value by a known technique such as matching using the input image signal, and performs subject detection processing. For example, face detection is performed. The obtained detection result of the subject detection is used for control such as weighting the subject detection region when calculating each evaluation value in the present embodiment, or the subject detection region is displayed to the user when displaying an image. It is used to let you know. Similar to the AF evaluation value, such an evaluation value for subject detection may cause a problem as to which exposure image is appropriate for obtaining the evaluation value depending on the shooting environment.

また、ホワイトバランス処理では、画像信号の画像内の本来白と思われる白領域を抽出し、当該白領域の評価値を算出する。あるいは、画像信号全体を積分して評価値を算出したり、上述した方法で検出された顔領域内の画像信号を肌色領域とする評価値を算出したりする。これらの少なくとも1つの評価値から、ホワイトバランスのためのゲインを算出し、当該ゲインで画像信号を補正する。このようなホワイトバランス処理のための評価値もAF評価値と同様に撮影環境によってどの露出画像が評価値取得に適切かという課題が生じ得る。   In the white balance processing, a white area that is supposed to be white in the image of the image signal is extracted, and an evaluation value of the white area is calculated. Alternatively, the evaluation value is calculated by integrating the entire image signal, or the evaluation value using the image signal in the face area detected by the above-described method as the skin color area is calculated. A gain for white balance is calculated from at least one of these evaluation values, and the image signal is corrected with the gain. Similar to the AF evaluation value, the evaluation value for such white balance processing may cause a problem as to which exposure image is appropriate for obtaining the evaluation value depending on the shooting environment.

画像処理部103から出力された画像信号は、システム制御部110の指示に従って、フレームメモリ105、もしくは画像合成部106に入力される。この入力の切り替え制御については、画像合成処理の説明にて詳細を述べる。   The image signal output from the image processing unit 103 is input to the frame memory 105 or the image composition unit 106 in accordance with an instruction from the system control unit 110. This input switching control will be described in detail in the description of the image composition process.

画像合成部106は、画像処理部103から出力される画像と、フレームメモリ105に記憶された画像とを、黒つぶれや白飛びを抑制するように合成し、ダイナミックレンジを拡張した1つの画像(HDR画像)として出力する。   The image composition unit 106 synthesizes the image output from the image processing unit 103 and the image stored in the frame memory 105 so as to suppress blackout and overexposure, and expands the dynamic range. HDR image).

撮像素子102から出力される画像信号は、AF評価値算出部107、動きベクトル検出部108、ヒストグラム算出部109にも入力される。AF評価値算出部107は、システム制御部110から指示された領域(AF評価枠)に対応する画像信号のAF評価値を算出し、システム制御部110に入力する。   The image signal output from the image sensor 102 is also input to the AF evaluation value calculation unit 107, the motion vector detection unit 108, and the histogram calculation unit 109. The AF evaluation value calculation unit 107 calculates an AF evaluation value of an image signal corresponding to an area (AF evaluation frame) designated by the system control unit 110 and inputs the AF evaluation value to the system control unit 110.

動きベクトル検出部108は、撮像素子102から入力される、異なるタイミングで撮影された複数の画像信号から、AF評価枠の動きベクトル情報を算出し、システム制御部110に入力する。   The motion vector detection unit 108 calculates the motion vector information of the AF evaluation frame from a plurality of image signals photographed at different timings input from the image sensor 102 and inputs the motion vector information to the system control unit 110.

また、ヒストグラム算出部109は、撮像素子102からの画像信号の輝度情報として、AF評価枠内の画素の輝度信号についてのヒストグラム情報(以下、輝度ヒストグラム情報と呼ぶ)を算出し、システム制御部110に入力する。   Further, the histogram calculation unit 109 calculates histogram information (hereinafter referred to as luminance histogram information) about the luminance signal of the pixels in the AF evaluation frame as the luminance information of the image signal from the image sensor 102, and the system control unit 110. To enter.

システム制御部110は例えばCPUやMPU等のプログラマブルプロセッサと、プログラムを記憶したROMと、プログラムの実行などに用いるRAMとを有し、プログラムを実行することによって撮像装置全体の動作を制御する。システム制御部110は、光学系101の焦点距離(画角)、絞り値、フォーカス位置(合焦距離)などの制御、撮像素子102の駆動方式の制御、スイッチ104の制御、などを行う。これらの制御は、AF評価値算出部107からのAF評価値、ヒストグラム算出部109からの輝度ヒストグラム情報、動きベクトル検出部108からの動きベクトル情報などに基づいて行われる。   The system control unit 110 includes, for example, a programmable processor such as a CPU or MPU, a ROM that stores a program, and a RAM that is used to execute the program. The system control unit 110 controls the operation of the entire imaging apparatus by executing the program. The system control unit 110 performs control of the focal length (field angle), aperture value, focus position (focusing distance), etc. of the optical system 101, control of the driving method of the image sensor 102, control of the switch 104, and the like. These controls are performed based on the AF evaluation value from the AF evaluation value calculation unit 107, the luminance histogram information from the histogram calculation unit 109, the motion vector information from the motion vector detection unit 108, and the like.

また、システム制御部110は、AF評価値、輝度ヒストグラム、動きベクトル検出情報を取得する画像領域(AF評価枠)を、AF評価値算出部107、ヒストグラム算出部109、動きベクトル検出部108に対して設定する。設定方法に制限はないが、例えばAF評価枠を特定する座標を用いて設定することができる。   In addition, the system control unit 110 sends an AF evaluation value, luminance histogram, and motion vector detection information image area (AF evaluation frame) to the AF evaluation value calculation unit 107, histogram calculation unit 109, and motion vector detection unit 108. To set. Although there is no restriction | limiting in the setting method, For example, it can set using the coordinate which specifies AF evaluation frame.

なお、図1および上述の説明は本実施形態の撮像装置が有する構成のうち、本発明の理解に必要な最低限の構成についてのものであり、図示および説明がされていなくても、一般的な撮像装置が有する構成は存在している。   Note that FIG. 1 and the above description relate to the minimum configuration necessary for understanding the present invention out of the configurations of the imaging apparatus according to the present embodiment. There exists a configuration of such an imaging device.

次に、本実施形態の撮像装置におけるHDR処理について説明する。
HDR処理のうち、画像を合成してHDR画像を生成する画像合成部106についてまず説明する。画像合成部106は、露出を変えて連続撮影された画像群に含まれる複数枚の画像を、1枚の画像を基準として合成することで、ダイナミックレンジが拡大された1フレームのHDR画像を生成する。
Next, HDR processing in the imaging apparatus according to the present embodiment will be described.
In the HDR processing, the image composition unit 106 that composes images and generates an HDR image will be described first. The image synthesizing unit 106 generates one frame of HDR image with an expanded dynamic range by synthesizing a plurality of images included in a group of images continuously shot with different exposures based on one image. To do.

HDR画像を合成する手法は既に様々な提案がなされており、公知の任意の方法を用いることができる。一例を挙げれば、特開2011−221924号公報に記載されるような、基準とする画像以外の画像について手ぶれや被写体の動きに伴うズレを補正してから、画像合成処理を行う方法を用いることができる。   Various proposals have already been made for synthesizing HDR images, and any known method can be used. For example, as described in Japanese Patent Application Laid-Open No. 2011-221924, a method of performing image composition processing after correcting a shift caused by camera shake or subject movement for an image other than the reference image is used. Can do.

HDR処理の例と、HDR処理に用いる画像を撮影するための露出制御について説明する。
HDR処理(合成処理)に用いられる画像の数や各画像を撮影する際の露出条件は様々な設定が可能である。本実施形態では一例として、図2に示すように、基準露出で撮影した基準露出画像201と、基準露出より少ない露出量で撮影した低露出画像202の2フレームから、1フレームの合成画像(HDR画像)203を得るものとする。なお、本実施形態では基準露出を適正露出とするため、以下では基準露出画像を適正露出画像と呼ぶ。適正露出のための露出制御量(露光時間、ISO感度、絞り)は、画像から得られる輝度の評価値と、プログラム線図に基づいて決定される。図2では、適正露出画像201、低露出画像202、および合成画像203に対してヒストグラム算出部109で求めた輝度ヒストグラム204〜206を併せて示している。輝度ヒストグラム情報204,205における輝度LhighおよびLlowは、白飛びおよび黒つぶれが発生している領域を判定するための閾値である。輝度がLlow以下の画素207,209は黒つぶれ画素、輝度がLhigh以上の画素208,210は白飛び画素と見なす。閾値LhighおよびLlowは撮像素子のダイナミックレンジなどを考慮して予め定めておく。
An example of HDR processing and exposure control for capturing an image used for HDR processing will be described.
Various settings are possible for the number of images used for HDR processing (compositing processing) and the exposure conditions when each image is captured. As an example in the present embodiment, as shown in FIG. 2, a composite image (HDR) of one frame from two frames of a reference exposure image 201 photographed with a reference exposure and a low exposure image 202 photographed with an exposure amount smaller than the reference exposure. Image) 203 is obtained. In the present embodiment, the reference exposure is referred to as a proper exposure image in order to set the reference exposure as a proper exposure. An exposure control amount (exposure time, ISO sensitivity, aperture) for proper exposure is determined based on a luminance evaluation value obtained from an image and a program diagram. FIG. 2 also shows luminance histograms 204 to 206 obtained by the histogram calculation unit 109 for the proper exposure image 201, the low exposure image 202, and the composite image 203. The luminances Low and Llow in the luminance histogram information 204 and 205 are thresholds for determining an area where whiteout and blackout occur. Pixels 207 and 209 having a luminance of Llow or lower are regarded as blackout pixels, and pixels 208 and 210 having a luminance of Lhigh or higher are regarded as whiteout pixels. The thresholds Lhigh and Llow are determined in advance in consideration of the dynamic range of the image sensor and the like.

また、本実施形態においては、適正露出画像201の露出設定に対しN段暗くした露出設定で低露出画像202を撮影するものとし、以下、Nを露出段差量と呼ぶ。本実施形態では、撮影された低露出画像の白飛び、黒つぶれの程度に応じて次の撮影時の露出段差量Nを動的に変更する。露出段差量Nの露出段差をつける手法としては、露光時間、ISO感度などがあり、その一方またはどちらも用いて段差量Nを達成して良い。   In the present embodiment, the low-exposure image 202 is shot with an exposure setting that is N steps darker than the exposure setting of the proper exposure image 201. Hereinafter, N is referred to as an exposure step amount. In the present embodiment, the exposure step amount N at the time of the next photographing is dynamically changed according to the degree of overexposure or underexposure in the photographed low-exposure image. There are exposure time, ISO sensitivity, and the like as a method of providing an exposure step of the exposure step amount N, and one or both of them may be used to achieve the step amount N.

本実施形態における露出段差量Nの制御について図4のフローチャートを用いて説明する。
システム制御部110は、撮影開始時に、露出段差量Nを初期値N0とする(S401)。システム制御部110は、適正露出画像と低露出画像の撮影を行い(S402)、ヒストグラム算出部109から低露出画像の所定領域の輝度ヒストグラム情報を取得する(S403)。
The control of the exposure step amount N in the present embodiment will be described using the flowchart of FIG.
The system control unit 110 sets the exposure step amount N to the initial value N0 at the start of shooting (S401). The system control unit 110 captures a proper exposure image and a low exposure image (S402), and acquires luminance histogram information of a predetermined area of the low exposure image from the histogram calculation unit 109 (S403).

そして、システム制御部110は、この低露出画像を用いたHDR画像に白飛びが発生するかどうかを輝度ヒストグラム情報に基づいて判定する(S404)。具体的には、白飛び閾値Lhigh以上の輝度を有する画素数(図2の領域210の頻度の積分値)が所定数以上であれば、この低露出画像を用いたHDR画像に白飛びが発生すると判断する。この場合、システム制御部110は現在の露出段差量Nが不足していると判断し、次の低露出画像に対する露出段差量Nとして、現在の露出段差量N+所定段差量N’(例えば1/3段)を設定する(S404)。つまり、次の低露出画像の撮影では、さらに露出段差量を大きくし、露出量を低減する。   Then, the system control unit 110 determines whether or not whiteout occurs in the HDR image using the low-exposure image based on the luminance histogram information (S404). Specifically, if the number of pixels having a luminance equal to or greater than the whiteout threshold Lhigh (the integrated value of the frequency of the area 210 in FIG. 2) is equal to or greater than a predetermined number, whiteout occurs in the HDR image using the low-exposure image. Judge that. In this case, the system control unit 110 determines that the current exposure step amount N is insufficient, and sets the current exposure step amount N + the predetermined step amount N ′ (for example, 1/1) as the exposure step amount N for the next low-exposure image. (3 steps) is set (S404). That is, in the next shooting of a low exposure image, the exposure step amount is further increased to reduce the exposure amount.

一方、白飛び閾値Lhigh以上の輝度を有する画素数が所定数未満の場合、システム制御部110は、黒つぶれの判定を行う(S406)。具体的には、閾値Llow以下の輝度を有する画素数(図2の領域209の頻度の積分値)が所定数以上であれば、黒つぶれが生じていると判断する。この場合、白飛びが発生しておらず、黒つぶれが発生しているため、システム制御部110は低露出画像の露出量を必要以上に低下させている(露出段差量Nが大きすぎる)と判断する。   On the other hand, when the number of pixels having a luminance equal to or greater than the whiteout threshold Lhigh is less than the predetermined number, the system control unit 110 determines whether or not the image is dark (S406). Specifically, if the number of pixels having a luminance equal to or lower than the threshold Llow (the integrated value of the frequency of the region 209 in FIG. 2) is equal to or greater than a predetermined number, it is determined that blackout has occurred. In this case, since the whiteout does not occur and the blackout occurs, the system control unit 110 reduces the exposure amount of the low exposure image more than necessary (the exposure step amount N is too large). to decide.

そして、システム制御部110は、次に撮影する低露出画像の露出段差量Nとして、現在の露出段差量N−所定段差量N’(例えば1/3段)を設定する(S407)。つまり、次の低露出画像の撮影では、露出段差量を小さくし、露出量を増大する。   Then, the system control unit 110 sets the current exposure step amount N−predetermined step amount N ′ (for example, 1/3 step) as the exposure step amount N of the low exposure image to be photographed next (S407). That is, in the next shooting of a low-exposure image, the exposure step amount is reduced and the exposure amount is increased.

S406において、閾値Llow以下の輝度を有する画素数が所定数未満の場合、システム制御部110は現在の露出段差量Nを変更せず、露出設定を維持する。以上の動作を継続しながら撮影を行うことで、HDR処理に最適な露出段差量Nで低露出画像を撮影することができ、良好なHDR画像を生成することができる。
また、画像処理部103により被写体領域が検出されている場合、S403〜S406において上述した方法で被写体領域についても同様に評価を行い、被写体領域の判定結果に重みをつけて全体の結果と合わせて、露出段差量Nの制御を行う。
In S406, when the number of pixels having the luminance equal to or lower than the threshold Llow is less than the predetermined number, the system control unit 110 does not change the current exposure step amount N and maintains the exposure setting. By performing shooting while continuing the above operations, a low-exposure image can be shot with an exposure step amount N optimum for HDR processing, and a good HDR image can be generated.
Also, when the subject area is detected by the image processing unit 103, the subject area is similarly evaluated by the method described above in S403 to S406, and the determination result of the subject area is weighted together with the overall result. Then, the exposure step amount N is controlled.

システム制御部110は、低露出画像202を撮影する際に、適正露出に対して露出段差量Nに相当する量だけ露出量が少ない画像が得られるよう、撮像素子102の露光時間(電荷蓄積時間)を制御する。適正露出画像の露光時間を1とした場合、1/2Nの露光時間で撮影するように制御すればよく、例えば露出段差量N=2であれば、適正露出画像の露光時間の1/4とすればよい。 When photographing the low-exposure image 202, the system control unit 110 exposes the exposure time (charge accumulation time) of the image sensor 102 so that an image with a small exposure amount by an amount corresponding to the exposure step amount N with respect to the proper exposure can be obtained. ) To control. If the exposure time of the proper exposure image is 1, it may be controlled to shoot with an exposure time of 1/2 N. For example, if the exposure step amount N = 2, 1/4 of the exposure time of the proper exposure image. And it is sufficient.

次に、図3のタイミングチャートを用いて、動画HDR処理時の撮影、合成、AF評価値取得、フォーカスレンズ制御のタイミングについて説明する。
キャプチャパルス301は撮像素子102が画像取り込み(電荷読みだし)を開始するトリガである。シャッターパルス302は、撮像素子102の露光(電荷蓄積)開始タイミングを決定する。図3において、第1フレームはシャッターパルスS1からキャプチャパルスC1までの時間Tlowで露光が行われ、低露出画像304が撮影される。第2フレームはS2からC2までの時間Tbaseで露光が行われ、適正露出画像305が撮影される。以下、同様に第3フレームに低露出画像、第4フレームに適正露出画像、第5フレームに低露出画像、と交互に連続して撮影を行う。3フレーム以上の画像を合成して1フレームのHDR画像を生成する場合も同様に、合成に用いるフレームを連続的に順次撮影する。
Next, the timing of shooting, composition, AF evaluation value acquisition, and focus lens control during moving image HDR processing will be described using the timing chart of FIG.
A capture pulse 301 is a trigger for the image sensor 102 to start image capture (charge reading). The shutter pulse 302 determines the exposure (charge accumulation) start timing of the image sensor 102. In FIG. 3, the first frame is exposed at a time Tlow from the shutter pulse S1 to the capture pulse C1, and a low-exposure image 304 is taken. The second frame is exposed for a time Tbase from S2 to C2, and a proper exposure image 305 is taken. Hereinafter, similarly, a low exposure image is taken in the third frame, a proper exposure image is taken in the fourth frame, and a low exposure image is taken in the fifth frame. Similarly, when three or more frames of images are combined to generate a one-frame HDR image, the frames used for combining are sequentially and sequentially photographed.

本実施形態では、合成に用いる画像群のうち、適正露出画像を最後に撮影しているため、画像合成処理は適正露出画像の撮影後に行われる。従って、システム制御部110は、先に撮影が終了している低露出画像304がフレームメモリ105に記憶されるようにスイッチ104の切り替えを制御する。そして、画像合成部106は、フレームメモリ105に記憶された(1フレーム前の)低露出画像304と、撮像された(現フレームの)適正露出画像305を合成して、HDR動画の1フレームであるHDR画像306を生成する。従って、本実施形態のHDR動画のフレームレートは撮像フレームレートの1/2となる。   In the present embodiment, since the proper exposure image is taken last in the group of images used for synthesis, the image synthesis process is performed after the proper exposure image is taken. Therefore, the system control unit 110 controls the switching of the switch 104 so that the low-exposure image 304 that has been shot first is stored in the frame memory 105. Then, the image synthesis unit 106 synthesizes the low-exposure image 304 (one frame before) stored in the frame memory 105 and the captured appropriate exposure image 305 (of the current frame) to generate one HDR video frame. An HDR image 306 is generated. Therefore, the frame rate of the HDR moving image according to the present embodiment is ½ of the imaging frame rate.

AF評価値は、タイミングパルス307のタイミングで取得される。キャプチャパルスV1で取得された低露出画像304のAF評価値は、パルスA1、すなわち1フレーム後のタイミングで取得される。なお、AF評価値は合成画像ではなく、撮影画像の各フレームで取得する。   The AF evaluation value is acquired at the timing of the timing pulse 307. The AF evaluation value of the low-exposure image 304 acquired by the capture pulse V1 is acquired at the timing of the pulse A1, that is, one frame later. The AF evaluation value is acquired for each frame of the captured image, not the composite image.

フォーカスレンズは、タイミングパルス308のタイミングで駆動される。後述するフォーカス制御によって、HDR動画のフレームレートと同じ頻度でフォーカスレンズの駆動が行われる。システム制御部110は、パルスA1、A2のタイミングで取得したAF評価値に基づくフォーカス制御を、パルスL1のタイミングで実施する。   The focus lens is driven at the timing of the timing pulse 308. The focus lens is driven at the same frequency as the HDR moving image frame rate by focus control described later. The system control unit 110 performs focus control based on the AF evaluation value acquired at the timing of the pulses A1 and A2 at the timing of the pulse L1.

次に、本実施形態におけるフォーカス制御について説明する。
AF評価値算出部107で算出するAF評価値は、画像のコントラストの高低を反映した値であり、公知かつ任意の方法で算出することができる。一例を挙げれば、特開2011−13324号公報に記載されるような、画像に所定のバンドパスフィルタを適用してコントラスト成分を抽出し、このコントラスト信号のライン毎のピーク値を積分することで求めることができる。
Next, focus control in the present embodiment will be described.
The AF evaluation value calculated by the AF evaluation value calculation unit 107 is a value reflecting the level of contrast of the image, and can be calculated by a known and arbitrary method. For example, as described in Japanese Patent Application Laid-Open No. 2011-13324, a predetermined band pass filter is applied to an image to extract a contrast component, and a peak value for each line of the contrast signal is integrated. Can be sought.

システム制御部110は、AF評価値算出部107が算出したAF評価値に基づいて光学系101のフォーカス状態(合焦状態)を評価し、AF評価値が最大となるフォーカスレンズの位置を算出する。そして、システム制御部110は、フォーカスレンズを算出した位置に移動(シフト)するよう光学系101に指示し、フォーカス制御を実現する。   The system control unit 110 evaluates the focus state (in-focus state) of the optical system 101 based on the AF evaluation value calculated by the AF evaluation value calculation unit 107, and calculates the position of the focus lens that maximizes the AF evaluation value. . Then, the system control unit 110 instructs the optical system 101 to move (shift) the focus lens to the calculated position, thereby realizing focus control.

再び図5を参照して、適正露出AF評価値と低露出AF評価値の特徴について説明する。なお、図5に示すAF評価値は、適正露出画像と低露出画像の輝度レベルが揃うように、補正処理が行われている。例えば、適正露出画像の露光時間Tbaseと低露出画像の露光時間Tlowの比Tdを以下の式1のように算出し、低露出画像のAF評価値にTdをゲインとして重畳する補正処理であってよい。
Td=Tbase / Tlow (式1)
With reference to FIG. 5 again, the characteristics of the proper exposure AF evaluation value and the low exposure AF evaluation value will be described. It should be noted that the AF evaluation values shown in FIG. 5 are corrected so that the brightness levels of the proper exposure image and the low exposure image are aligned. For example, the correction process is to calculate the ratio Td between the exposure time Tbase of the proper exposure image and the exposure time Tlow of the low exposure image as shown in the following equation 1, and superimpose the Td as a gain on the AF evaluation value of the low exposure image. Good.
Td = Tbase / Tlow (Formula 1)

図5(a)に示すように、静止被写体に対しては、低露出画像のAF評価値502は、適正露出画像のAF評価値501よりもノイズ量が大きい(S/Nが悪い)という特徴がある。
図5(b)に示すように、動被写体に対しては、低露出画像のAF評価値502は、適正露出画像のAF評価値501よりも被写体の動きによるコントラスト低下が小さく、AF評価値の最大値が大きいという特徴がある。
これらの特徴はいずれも、露光時間が短いことによるものである。
As shown in FIG. 5A, for a still subject, the AF evaluation value 502 of the low exposure image has a larger amount of noise (poor S / N) than the AF evaluation value 501 of the proper exposure image. There is.
As shown in FIG. 5B, for a moving subject, the AF evaluation value 502 of the low-exposure image has a smaller contrast decrease due to the movement of the subject than the AF evaluation value 501 of the proper exposure image, and the AF evaluation value It is characterized by a large maximum value.
All of these features are due to the short exposure time.

次に、本実施形態におけるフォーカス制御を図6のフローチャートを用いて説明する。
本実施形態のシステム制御部110は、図14に示すようなAF評価値選択部1401を有している。AF評価値選択部1401は、動きベクトル検出部108からの動きベクトル情報Mvと、システム制御部110で算出する露出段差量Nとから、適正露出画像のAF評価値と低露出画像のAF評価値のうち、信頼度が高いと判定される一方を選択する。選択したAF評価値はシステム制御部110内で用いる。
Next, focus control in the present embodiment will be described with reference to the flowchart of FIG.
The system control unit 110 of this embodiment has an AF evaluation value selection unit 1401 as shown in FIG. The AF evaluation value selection unit 1401 determines the AF evaluation value of the proper exposure image and the AF evaluation value of the low exposure image from the motion vector information Mv from the motion vector detection unit 108 and the exposure step amount N calculated by the system control unit 110. Among them, one of which is determined to have high reliability is selected. The selected AF evaluation value is used in the system control unit 110.

図3のタイミングチャートに示すように、適正露出画像305と低露出画像304は交互に撮像され、AF評価値算出部107は各撮影画像でAF評価値を算出する(S601)。システム制御部110内のAF評価値選択部1401は、タイミングパルス307のタイミングで取得したAF評価値に応じて処理を切り替える(S602)。   As shown in the timing chart of FIG. 3, the proper exposure image 305 and the low exposure image 304 are alternately captured, and the AF evaluation value calculation unit 107 calculates an AF evaluation value for each captured image (S601). The AF evaluation value selection unit 1401 in the system control unit 110 switches processing according to the AF evaluation value acquired at the timing of the timing pulse 307 (S602).

低露出AF評価値を取得した場合、適正露出画像と低露出画像の輝度レベルが揃うように、補正部1402が低露出AF評価値を補正する(S603)。この補正は上述したTdの乗算であってよい。そして、補正部1402は、次フレームに行われるAF評価値選択処理のために、この補正したAF評価値を保持部1403に保持する。   When the low-exposure AF evaluation value is acquired, the correction unit 1402 corrects the low-exposure AF evaluation value so that the luminance levels of the appropriate exposure image and the low-exposure image are aligned (S603). This correction may be the multiplication of Td described above. Then, the correction unit 1402 holds the corrected AF evaluation value in the holding unit 1403 for the AF evaluation value selection process performed for the next frame.

一方、適正露出AF評価値を取得した場合、選択部1405は、動きベクトル検出部108から、AF評価枠に関する動きベクトル情報Mvを取得する(S607)。動きベクトル検出部108は、適正露出画像と1フレーム前の低露出画像とから、一方の画像内のAF評価枠内の画像をテンプレートとして切り出し、もう一方の画像内で相関の高い領域を探索し、位置の差を動きベクトルとして算出する。動きベクトル検出部108は、横方向の動きベクトルMvx、縦方向の動きベクトルMvyから、動きベクトル情報Mvを以下の式2で求めて出力する。
Mv=√(Mvx2+Mvy2) (式2)
このように、本実施形態では、動きベクトル情報Mvは動き量そのものであるが、他の実施形態では動き量を表す他の形態の情報であってもよい。
On the other hand, when the appropriate exposure AF evaluation value is acquired, the selection unit 1405 acquires the motion vector information Mv related to the AF evaluation frame from the motion vector detection unit 108 (S607). The motion vector detection unit 108 extracts an image within the AF evaluation frame in one image as a template from the appropriate exposure image and the low exposure image one frame before, and searches for a highly correlated area in the other image. The position difference is calculated as a motion vector. The motion vector detection unit 108 obtains and outputs motion vector information Mv from the horizontal motion vector Mvx and the vertical motion vector Mvy according to the following Expression 2.
Mv = √ (Mvx 2 + Mvy 2 ) (Formula 2)
Thus, in the present embodiment, the motion vector information Mv is the motion amount itself, but in other embodiments, the motion vector information Mv may be other forms of information representing the motion amount.

S608で選択部1405は、上述した露出段差量Nを取得する。
そして、選択部1405は、低露出AF評価値と適正露出AF評価値の選択処理を実施する(S608)。
In step S <b> 608, the selection unit 1405 acquires the exposure step amount N described above.
Then, the selection unit 1405 performs a process of selecting a low exposure AF evaluation value and a proper exposure AF evaluation value (S608).

図7に示すフローチャートを用いて、S608におけるAF評価値選択処理について説明する。
まず、選択部1405は、露出段差量Nと閾値ThNを比較する(701)。露出段差量Nが閾値ThNより大きい、すなわち適正露出画像と低露出画像の露出段差が大きい場合、図5で説明したように低露出画像のAF評価値はS/Nが低下する。そのため、低露出AF評価値の信頼性は低下し、適正露出AF評価値を用いた場合よりも合焦精度が低下する可能性が大きくなる。
The AF evaluation value selection process in S608 will be described using the flowchart shown in FIG.
First, the selection unit 1405 compares the exposure step amount N with the threshold ThN (701). When the exposure level difference N is larger than the threshold ThN, that is, when the exposure level difference between the appropriate exposure image and the low exposure image is large, as described with reference to FIG. 5, the S / N decreases in the AF evaluation value of the low exposure image. For this reason, the reliability of the low-exposure AF evaluation value is lowered, and the possibility that the focusing accuracy is lowered is larger than that in the case where the proper exposure AF evaluation value is used.

従って、露出段差量Nが閾値ThNより大きい場合、選択部1405は信頼度が低露出AF評価値より高いと判定される適正露出AF評価値を選択することを決定し、現フレームで得られる適正露出AF評価値を選択するようにSW1404を制御する。なお、閾値ThNは、所定の露出段差量を設定してもよいし、例えば、露出情報(適正露出画像のゲイン設定など)に応じて制御してもよい。   Accordingly, when the exposure step amount N is larger than the threshold value ThN, the selection unit 1405 determines to select an appropriate exposure AF evaluation value that is determined to have a reliability higher than the low exposure AF evaluation value, and the appropriate value obtained in the current frame. SW 1404 is controlled to select an exposure AF evaluation value. Note that the threshold ThN may be set to a predetermined exposure step amount, or may be controlled according to, for example, exposure information (such as a gain setting for a proper exposure image).

一方、露出段差量Nが閾値ThN以下の場合、S703で選択部1405は、動きベクトル情報Mvを閾値ThMvと比較する。そして、動きベクトル情報Mvが閾値ThMvより大きい、すなわちAF評価値を算出する被写体もしくは領域の動きが大きい場合は、図5で説明したように、適正露出画像の方が低露出画像よりも大きくコントラストが低下する。そのため、適正露出AF評価値の信頼度は低露出AF評価値を用いた場合よりも低く、適正露出AF評価値を用いた場合には合焦精度が低下する可能性が大きくなる。   On the other hand, when the exposure step amount N is equal to or smaller than the threshold ThN, the selection unit 1405 compares the motion vector information Mv with the threshold ThMv in S703. When the motion vector information Mv is larger than the threshold ThMv, that is, when the motion of the subject or area for which the AF evaluation value is calculated is large, as described with reference to FIG. 5, the appropriate exposure image has a larger contrast than the low exposure image. Decreases. For this reason, the reliability of the appropriate exposure AF evaluation value is lower than that when the low exposure AF evaluation value is used, and there is a high possibility that the focusing accuracy is lowered when the appropriate exposure AF evaluation value is used.

従って、動き量に相当する動きベクトル情報Mvが閾値ThMvより大きい場合、選択部1405はより信頼度が高いと判定される低露出AF評価値を選択するよう決定する。そして、選択部1405は、保持部1403に保存されている1フレーム前の低露出AF評価値を選択するようにSW1404を制御する(S704)。一方、動きベクトル情報Mvが閾値ThMv以下の場合には、選択部1405は一般的に信頼性が低露出AF評価値より高いと判定される適正露出AF評価値を選択するよう決定する。そして選択部1405は、現フレームで得られる適正露出AF評価値を選択するようにSW1404を制御する。
なお、閾値ThMvは、所定の動き量を設定しても良いし、例えば、露出情報(適正露出画像のゲイン設定など)に応じて制御してもよい。また、動きベクトル情報Mvが閾値ThMv以下の場合には、どちらも信頼性が基準より高いとしてどちらのAF評価値も用いるように決定しても良い。
Therefore, when the motion vector information Mv corresponding to the motion amount is larger than the threshold value ThMv, the selection unit 1405 determines to select a low-exposure AF evaluation value that is determined to be more reliable. Then, the selection unit 1405 controls the SW 1404 so as to select the low-exposure AF evaluation value for the previous frame stored in the holding unit 1403 (S704). On the other hand, when the motion vector information Mv is equal to or less than the threshold ThMv, the selection unit 1405 determines to select an appropriate exposure AF evaluation value that is generally determined to be higher in reliability than the low exposure AF evaluation value. Then, the selection unit 1405 controls the SW 1404 so as to select a proper exposure AF evaluation value obtained in the current frame.
Note that the threshold ThMv may be set to a predetermined amount of motion, or may be controlled according to, for example, exposure information (such as setting the gain of a proper exposure image). Further, when the motion vector information Mv is equal to or less than the threshold value ThMv, both AF evaluation values may be determined to be used because both have higher reliability than the reference.

なお、本実施形態では、選択するAF評価値の信頼度を、動きベクトル情報Mvの大きさと露出段差量Nの大きさに基づいて判定し、信頼度が基準より高いと判定される少なくとも1つを選択する構成について説明した。しかし、信頼度の判定は他の情報に基づくこともできる。例えば、図8に示すような撮影情報を用いてAF評価値の選択を行うことが可能である。   In the present embodiment, the reliability of the AF evaluation value to be selected is determined based on the magnitude of the motion vector information Mv and the magnitude of the exposure step amount N, and at least one of which the reliability is determined to be higher than the reference. The configuration for selecting is described. However, the determination of reliability can also be based on other information. For example, it is possible to select an AF evaluation value using shooting information as shown in FIG.

例えば、撮像装置が像ブレ補正機能を有する場合、ジャイロセンサなど装置の動きを検出する手段から既知の手法で求められる装置の動き量(手ブレ量)Hvを、動きベクトル情報Mvと同様に用いてAF評価値の選択を行ってもよい。これは、手ブレ量が大きいということは、動きによる適正露出画像のコントラスト低下が大きく、信頼度が低下すると考えられるためである。従って、選択部1405は手ブレ量Hvが所定の閾値ThHvより大きい場合には低露出AF評価値の選択を、閾値ThHv以下の場合には適正露出AF評価値の選択を、それぞれ決定し、SW1404を制御する。   For example, when the imaging device has an image blur correction function, the device motion amount (camera shake amount) Hv obtained by a known method from means for detecting the motion of the device such as a gyro sensor is used similarly to the motion vector information Mv. AF evaluation value may be selected. This is because that the amount of camera shake is large, it is thought that the contrast of the properly exposed image due to movement is greatly reduced and the reliability is lowered. Therefore, the selection unit 1405 determines the selection of the low exposure AF evaluation value when the camera shake amount Hv is larger than the predetermined threshold ThHv, and the selection of the appropriate exposure AF evaluation value when the camera shake amount Hv is less than the threshold ThHv. To control.

また、例えば、適正露出画像のAF評価枠内の画素について、図2で示したような輝度ヒストグラム204を算出しておき、所定の輝度値Lhigh以上(Lmaxまで)の輝度値を有する画素数と、全画素数の比Vh(以下、白飛び量と呼ぶ)を算出する。白飛び量Vhは、以下の式によって算出できる。なお、図8では、露出量の異なる1群の画像のうち、最も露出量が多い画像という意味において「高露出画像」と記載している。本実施形態では適正露出画像が最も露出量の多い画像であるため、白飛び量は適正露出画像について算出する。
Further, for example, the luminance histogram 204 as shown in FIG. 2 is calculated for the pixels within the AF evaluation frame of the appropriate exposure image, and the number of pixels having a luminance value equal to or higher than a predetermined luminance value Lhigh (up to Lmax) is calculated. The ratio Vh of the total number of pixels (hereinafter referred to as the amount of whiteout) is calculated. The whiteout amount Vh can be calculated by the following equation. In FIG. 8, “high exposure image” is described in the sense of an image having the largest exposure amount among a group of images having different exposure amounts. In this embodiment, since the proper exposure image is the image with the largest exposure amount, the amount of whiteout is calculated for the proper exposure image.

白飛び量Vhが大きいということは、適正露出画像のAF評価枠内に白飛び画素が多く、AF評価値の信頼度は低いと考えられる。そのため、選択部1405は白飛び量Vhが閾値ThVhより大きい場合にはより信頼度が高いと判定される低露出AF評価値を選択することを決定する。一方、選択部1405は、閾値ThVh以下であれば一般的に低露出AF評価値よりも信頼性が高いと考えられる適正露出AF評価値を選択することを決定する。選択部1405は、決定結果に応じてSW1404を制御する。   If the amount of whiteout Vh is large, it is considered that there are many whiteout pixels in the AF evaluation frame of the appropriate exposure image and the reliability of the AF evaluation value is low. Therefore, the selection unit 1405 determines to select a low-exposure AF evaluation value that is determined to be more reliable when the whiteout amount Vh is larger than the threshold value ThVh. On the other hand, the selection unit 1405 determines to select an appropriate exposure AF evaluation value that is generally considered to be more reliable than the low exposure AF evaluation value if it is equal to or less than the threshold value ThVh. The selection unit 1405 controls the SW 1404 according to the determination result.

また、例えば、低露出画像のAF評価枠内の画素について、図2で示すような輝度ヒストグラム205を算出しておき、所定の輝度値Llow以下(0まで)の積分値を有する画素と、全画素数の比Vl(以下、黒つぶれ量と呼ぶ)に応じて選択してもよい。黒つぶれ量Vlは、以下の式によって算出できる。
Further, for example, a luminance histogram 205 as shown in FIG. 2 is calculated for the pixels in the AF evaluation frame of the low-exposure image, and a pixel having an integration value equal to or less than a predetermined luminance value Llow (up to 0), The selection may be made according to the ratio Vl of the number of pixels (hereinafter referred to as the blackout amount). The blackout amount Vl can be calculated by the following equation.

黒つぶれ量Vlが大きいということは、低露出画像のAF評価枠内に黒つぶれ画素が多く、低露出AF評価値の信頼度は低いと考えられる。そのため、選択部1405は黒つぶれ量Vlが閾値ThVlより大きい場合には適正露出AF評価値を選択することを決定する。選択部1405はまた、黒つぶれ量V1が閾値ThVh以下であれば低露出AF評価値を選択することをそれぞれ決定し、SW1404を制御する。なお、図8における「低露出画像」は、露出量の異なる1群の画像のうち、最も露出量が少ない画像という意味である。   The large blackout amount Vl is considered that there are many blackout pixels in the AF evaluation frame of the low exposure image and the reliability of the low exposure AF evaluation value is low. Therefore, the selection unit 1405 determines to select the appropriate exposure AF evaluation value when the blackout amount Vl is larger than the threshold value ThVl. The selection unit 1405 also determines to select the low-exposure AF evaluation value if the blackout amount V1 is equal to or less than the threshold ThVh, and controls the SW 1404. Note that the “low exposure image” in FIG. 8 means an image with the smallest exposure amount among a group of images having different exposure amounts.

そして、システム制御部110は、このようにして選択したAF評価値に基づいて光学系101のフォーカス状態(合焦状態)を評価し、AF評価値が最大となるフォーカスレンズ位置を算出する。そして、システム制御部110は、フォーカスレンズを、算出した位置に移動(シフト)するよう、光学系101に指示する。そして、図3のタイミングパルス308が示すように、適正露出AF評価値を取得した次フレームでフォーカスレンズ駆動が行われる。   Then, the system control unit 110 evaluates the focus state (in-focus state) of the optical system 101 based on the AF evaluation value selected in this way, and calculates the focus lens position where the AF evaluation value is maximized. Then, the system control unit 110 instructs the optical system 101 to move (shift) the focus lens to the calculated position. Then, as indicated by the timing pulse 308 in FIG. 3, the focus lens is driven in the next frame in which the proper exposure AF evaluation value is acquired.

このように、本実施形態では、異なる露出条件で撮影された複数の画像の各々から得られるAF評価値のうち、撮像装置や被写体の動き、白飛び・黒つぶれの状況などから信頼度がより高いと判定される1つを動的に選択し、光学系のフォーカス制御に用いる。そのため、HDR動画用の撮影時においても被写体への追従性が良好なコントラストAFを実現することができる。   As described above, in the present embodiment, among the AF evaluation values obtained from each of a plurality of images shot under different exposure conditions, the reliability is higher due to the movement of the imaging device and subject, the situation of overexposure / blackout, etc. One that is determined to be high is dynamically selected and used for focus control of the optical system. For this reason, it is possible to realize contrast AF with good followability to the subject even when shooting for HDR video.

なお、本実施形態におけるフォーカス制御は、撮影時に画像合成を行わず、適正露出画像と低露出画像とを全て記録した後でHDR画像を生成する場合であっても有効である。また、本実施形態におけるフォーカス制御は、適正露出画像と低露出画像の組み合わせ以外の撮影であっても適用可能である。例えば、適正露出よりも露出量の多い高露出画像と、低露出画像とを撮影する場合であっても適用可能である。この場合、高露出画像を上述の適正露出画像に当てはめて処理すればよい。   Note that the focus control in the present embodiment is effective even when HDR images are generated after the proper exposure image and the low exposure image are all recorded without performing image synthesis at the time of shooting. Further, the focus control in the present embodiment can be applied to shooting other than a combination of a proper exposure image and a low exposure image. For example, the present invention can be applied even when a high-exposure image and a low-exposure image having a larger exposure amount than the proper exposure are taken. In this case, the high-exposure image may be applied to the above-described proper exposure image for processing.

また、本実施形態では、複数の露出画像から少なくとも1つの画像の評価値を取得する評価値の例として主にAF評価値、当該評価値に基づいて制御する撮影パラメータとしてフォーカスレンズ位置などのフォーカス制御値について説明したが、これに限らない。本実施形態を適用できる評価値としては、上述した被写体検出の評価値、ホワイトバランスの評価値、露出制御のための評価値など、撮像画像から得られる各種評価値について適用できる。被写体検出結果は、AF、露出制御(撮影パラメータの制御)、ホワイトバランス処理(画像処理パラメータの制御)などに用いられる。ホワイトバランスの評価値は当然ホワイトバランス処理に用いられる。露出制御のための評価値は撮影パラメータとしての露出制御値の制御に用いられる。   In the present embodiment, an AF evaluation value is mainly used as an example of an evaluation value for obtaining an evaluation value of at least one image from a plurality of exposure images, and a focus lens position or the like is used as a shooting parameter to be controlled based on the evaluation value. Although the control value has been described, the present invention is not limited to this. The evaluation values to which the present embodiment can be applied can be applied to various evaluation values obtained from captured images, such as the above-described subject detection evaluation values, white balance evaluation values, and exposure control evaluation values. The subject detection result is used for AF, exposure control (control of imaging parameters), white balance processing (control of image processing parameters), and the like. The white balance evaluation value is naturally used for white balance processing. Evaluation values for exposure control are used to control exposure control values as imaging parameters.

(第2の実施形態)
次に、本発明の第2の実施形態について説明する。本実施形態は、システム制御部110がAF評価値選択部の代わりにAF評価値合成部を有する点と、フォーカス制御以外は第1の実施形態と同じであるため、以下では本実施形態に特徴的な部分のみ説明する。
(Second Embodiment)
Next, a second embodiment of the present invention will be described. The present embodiment is the same as the first embodiment except that the system control unit 110 includes an AF evaluation value synthesis unit instead of the AF evaluation value selection unit, and focus control. Therefore, the following is a feature of the present embodiment. Only the relevant parts will be described.

本実施形態のシステム制御部110は、AF評価値選択部の代わりに図15に示すようなAF評価値合成部1501を有している。図15において、図14と同じ構成については共通の参照数字を用い、重複する説明を省略する。AF評価値合成部1501は、動きベクトル検出部108が算出する、AF評価枠内の画像の動きベクトル情報Mvと、システム制御部110で算出する露出段差量Nとに基づいて、合成係数を算出する。そして、AF評価値合成部1501は、適正露出AF評価値と低露出AF評価値を合成係数に基づいて合成したAF評価値をシステム制御部110に出力する。システム制御部110は合成されたAF評価値を光学系101の合焦状態の評価およびフォーカス制御に用いる。   The system control unit 110 of this embodiment has an AF evaluation value synthesis unit 1501 as shown in FIG. 15 instead of the AF evaluation value selection unit. 15, common reference numerals are used for the same components as those in FIG. 14, and duplicate descriptions are omitted. The AF evaluation value synthesis unit 1501 calculates a synthesis coefficient based on the motion vector information Mv of the image in the AF evaluation frame calculated by the motion vector detection unit 108 and the exposure step amount N calculated by the system control unit 110. To do. Then, the AF evaluation value combining unit 1501 outputs an AF evaluation value obtained by combining the appropriate exposure AF evaluation value and the low exposure AF evaluation value based on the combination coefficient to the system control unit 110. The system control unit 110 uses the synthesized AF evaluation value for evaluation of the focus state of the optical system 101 and focus control.

図9は、本実施形態におけるフォーカス制御動作を説明するためのフローチャートであり、第1の実施形態と共通する処理については図6と共通する参照数字を用いている。本実施形態のフォーカス制御動作では、S608におけるAF評価値の選択処理に代わってAF評価値の合成処理を行うS901を有する点が異なる。具体的には、信頼度が高いほど大きな重みを付与して複数のAF評価値を重み付け合成し、1つの(合成)AF評価値を生成することを特徴とする。そのため、S901におけるAF評価値合成処理についてのみ、図10のフローチャートを用いて説明する。   FIG. 9 is a flowchart for explaining the focus control operation in the present embodiment, and the same reference numerals as in FIG. 6 are used for the processes common to the first embodiment. The focus control operation of the present embodiment is different in that it has S901 for performing AF evaluation value synthesis processing instead of the AF evaluation value selection processing in S608. Specifically, the higher the reliability is, the greater the weight is assigned, and a plurality of AF evaluation values are weighted and combined to generate one (synthesized) AF evaluation value. Therefore, only the AF evaluation value composition processing in S901 will be described using the flowchart of FIG.

まず、第1合成係数算出部1505により、動きベクトル情報Mvに基づく合成係数Cmを算出する(S1001)。
図11(a)は、横軸を動きベクトル情報Mv(動き量)、縦軸を合成係数Cmとして、本実施形態における両者の関係例を示している。なお、本実施形態における合成係数は合成時における低露出AF評価値の重みを%で示した値である。従って、合成係数100は、低露出AF評価値が合成後のAF評価値としてそのまま使用されることを意味する。本実施形態において、合成係数Cmは、閾値ThMvを用いて、以下の式で求める。なお、閾値ThMvは第1の実施形態と同様に定めることができる。
Cm=(Mv−ThMv)×Km (式5)
ただし、Cm<0ならCm=0,
Cm>100ならCm=100とする。
First, the first synthesis coefficient calculation unit 1505 calculates a synthesis coefficient Cm based on the motion vector information Mv (S1001).
FIG. 11A shows an example of the relationship between the present embodiment, with the horizontal axis representing motion vector information Mv (motion amount) and the vertical axis representing the synthesis coefficient Cm. The synthesis coefficient in the present embodiment is a value indicating the weight of the low exposure AF evaluation value at the time of synthesis in%. Therefore, the synthesis coefficient 100 means that the low-exposure AF evaluation value is used as it is as the AF evaluation value after synthesis. In the present embodiment, the synthesis coefficient Cm is obtained by the following equation using the threshold ThMv. Note that the threshold ThMv can be determined in the same manner as in the first embodiment.
Cm = (Mv−ThMv) × Km (Formula 5)
However, if Cm <0, Cm = 0,
If Cm> 100, Cm = 100.

ここで、Kmは、図11(a)の合成係数Cmの変化部分の傾きである。特に、動きベクトル情報Mvが閾値ThMvを挟んだ近傍の値でフレームごとに変化した場合に、合成後のAF評価値の変動が大きくならないように、閾値付近では合成係数Cmを滑らかに変化させる値をKmに設定する。   Here, Km is the slope of the changing portion of the synthesis coefficient Cm in FIG. In particular, when the motion vector information Mv changes for each frame at a value in the vicinity of the threshold ThMv, a value that smoothly changes the composition coefficient Cm in the vicinity of the threshold so that the AF evaluation value after the composition does not vary greatly. Is set to Km.

また、第2合成係数算出部1506が、露出段差量Nに基づく合成係数Ceを算出する(S1002)。
図11(b)は、横軸を露出段差量N、縦軸を合成係数Ceとして、本実施形態における両者の関係例を示している。合成係数の算出式は、閾値ThNを用いて、以下の式で求める。なお、閾値ThNは第1の実施形態と同様に定めることができる。
Ce=100−(N−ThN)×Ke (式6)
ただし、Ce<0ならCe=0,
Ce>100ならCe=100とする。
Further, the second synthesis coefficient calculation unit 1506 calculates a synthesis coefficient Ce based on the exposure step amount N (S1002).
FIG. 11B shows an example of the relationship between the two in the present embodiment, with the horizontal axis representing the exposure step amount N and the vertical axis representing the synthesis coefficient Ce. The formula for calculating the synthesis coefficient is obtained by the following formula using the threshold ThN. Note that the threshold ThN can be determined in the same manner as in the first embodiment.
Ce = 100− (N−ThN) × Ke (Formula 6)
However, if Ce <0, Ce = 0,
If Ce> 100, Ce = 100.

ここで、Keは、図11(b)の合成係数Ceの変化部分の傾きである。特に、露出段差量Nが閾値ThNを挟んだ近傍の値でフレームごとに変化した場合に、合成後のAF評価値の変動が大きくならないように、閾値付近では合成係数Ceを滑らかに変化させる値をKeに設定する。
なお、合成係数CmとCeの算出は、並行して実施してもよい。
Here, Ke is the slope of the changing portion of the synthesis coefficient Ce in FIG. In particular, when the exposure step amount N changes for each frame at a value in the vicinity of the threshold ThN, a value for smoothly changing the composition coefficient Ce in the vicinity of the threshold so that the AF evaluation value after the composition does not increase. Is set to Ke.
Note that the synthesis coefficients Cm and Ce may be calculated in parallel.

次に、係数合成部1507で、合成係数CeおよびCmを合成して、合成係数Cを算出する(S1003)。
合成係数Cは、例えば以下の式で示されるような単純な乗算により算出することができる。
C=(Ce×Cm)/100 (式7)
なお、合成係数Cは、露出情報(シャッタースピードやゲイン設定など)を評価した値を重みとして、2つの合成係数を重み付け合成するなど、他の方法でも算出できる。シャッタースピードは速いほどブレが少ないため、合成係数Cmの重みはシャッタースピードが速いほど高くすることができる。また、ゲインは高いほど暗部のノイズが大きくなるため、ゲインが高いほど合成係数Ceの重みを小さくすることができる。
Next, the coefficient synthesizing unit 1507 synthesizes the synthesis coefficients Ce and Cm to calculate the synthesis coefficient C (S1003).
The synthesis coefficient C can be calculated by simple multiplication as shown by the following equation, for example.
C = (Ce × Cm) / 100 (Formula 7)
Note that the synthesis coefficient C can also be calculated by other methods such as weighting and synthesis of two synthesis coefficients using a value obtained by evaluating exposure information (shutter speed, gain setting, etc.) as a weight. Since the faster the shutter speed, the less blurring occurs, so the weight of the synthesis coefficient Cm can be increased as the shutter speed increases. Further, since the dark portion noise increases as the gain increases, the weight of the synthesis coefficient Ce can be reduced as the gain increases.

次に、評価値合成部1504で、適正露出画像から算出したAF評価値と、低露出画像から算出したAF評価値とを、合成係数Cを用いて合成する。適正露出AF評価値をAfb、低露出AF評価値をAfl、合成AF評価値をAfcとした場合、以下の式に従って合成AF評価値を得ることができる。
Next, the evaluation value synthesis unit 1504 synthesizes the AF evaluation value calculated from the proper exposure image and the AF evaluation value calculated from the low exposure image using the synthesis coefficient C. When the proper exposure AF evaluation value is Afb, the low exposure AF evaluation value is Afl, and the composite AF evaluation value is Afc, a composite AF evaluation value can be obtained according to the following formula.

なお、ここでは、AF評価値の合成係数を動きベクトル情報に基づく合成係数と、露出段差量に基づく合成係数から算出する場合について説明した。しかし、図8に示すような撮影情報を動きベクトル情報や露出段差量の代わりに用い、同様の手法で合成係数を求めてもよい。
例えば、以下の様な撮影情報と合成係数との関係に基づいて合成係数を算出することができる。
手ブレ量Hvが所定の閾値ThHvより大きくなるほど、合成係数を大きくする。
白飛び量Vhが所定の閾値ThVhより大きくなるほど、合成係数を大きくする。
黒つぶれ量Vlが所定の閾値ThVlより大きくなるほど、合成係数を小さくする。
Here, the case has been described where the synthesis coefficient of the AF evaluation value is calculated from the synthesis coefficient based on the motion vector information and the synthesis coefficient based on the exposure step amount. However, it is also possible to use the shooting information as shown in FIG. 8 instead of the motion vector information and the exposure step amount and obtain the synthesis coefficient by the same method.
For example, the synthesis coefficient can be calculated based on the relationship between the following photographing information and the synthesis coefficient.
The synthesis coefficient is increased as the camera shake amount Hv is larger than the predetermined threshold value ThHv.
As the amount of whiteout Vh becomes larger than a predetermined threshold value ThVh, the synthesis coefficient is increased.
As the blackout amount Vl becomes larger than a predetermined threshold value ThVl, the synthesis coefficient is reduced.

システム制御部110は、合成AF評価値を用いて、光学系101のフォーカス状態(合焦状態)を評価し、合成AF評価値が最大となる光学系101のフォーカス位置を算出する。そして、フォーカスレンズを、算出した位置に移動(シフト)するよう、光学系101に指示することで、フォーカス制御が実現される。   The system control unit 110 evaluates the focus state (in-focus state) of the optical system 101 using the composite AF evaluation value, and calculates the focus position of the optical system 101 that maximizes the composite AF evaluation value. Then, the focus control is realized by instructing the optical system 101 to move (shift) the focus lens to the calculated position.

なお、第1の実施形態と同様、本実施形態におけるフォーカス制御も、撮影時に画像合成を行わず、適正露出画像と低露出画像とを全て記録した後でHDR画像を生成する場合であっても有効である。また、本実施形態におけるフォーカス制御は、適正露出画像と低露出画像の組み合わせ以外の撮影であっても適用可能である。例えば、適正露出よりも露出量の多い高露出画像と、低露出画像とを撮影する場合であっても適用可能である。この場合、高露出画像を上述の適正露出画像に当てはめて処理すればよい。   Note that, as in the first embodiment, the focus control in the present embodiment is also performed when HDR images are generated after all the proper exposure images and low exposure images are recorded without performing image synthesis at the time of shooting. It is valid. Further, the focus control in the present embodiment can be applied to shooting other than a combination of a proper exposure image and a low exposure image. For example, the present invention can be applied even when a high-exposure image and a low-exposure image having a larger exposure amount than the proper exposure are taken. In this case, the high-exposure image may be applied to the above-described proper exposure image for processing.

本実施形態では、信頼度の度合いに応じた重みで合成したAF評価値を用いるため、所定の閾値の大小関係に応じて一つのAF評価値を選択する第1の実施形態よりも信頼度をきめ細かく反映したAF評価値を用いたフォーカス制御が可能である。そのため、フォーカス制御の精度の一層の向上が期待される。なお、信頼度が高い評価値の重みを信頼度が低い評価値の重みよりも大きくして用いるという観点からは、信頼度の高い評価値を選択して用いる第1の実施形態は本実施形態の一つの形態とも言える。   In this embodiment, since an AF evaluation value synthesized with a weight according to the degree of reliability is used, the reliability is higher than that in the first embodiment in which one AF evaluation value is selected according to the magnitude relationship of a predetermined threshold. It is possible to control the focus using the AF evaluation value that is reflected finely. Therefore, further improvement in the accuracy of focus control is expected. From the viewpoint of using the weight of the evaluation value with high reliability higher than the weight of the evaluation value with low reliability, the first embodiment that selects and uses the evaluation value with high reliability is the present embodiment. It can be said that it is one form.

また、本実施形態では、複数の露出画像から少なくとも1つの画像の評価値を取得する評価値の例として主にAF評価値、当該評価値に基づいて制御する撮影パラメータとしてフォーカスレンズ位置などのフォーカス制御値について説明したが、これに限らない。本実施形態を適用できる評価値としては、上述した被写体検出の評価値、ホワイトバランスの評価値、露出制御のための評価値など、撮像画像から得られる各種評価値について適用できる。被写体検出結果は、AF、露出制御(撮影パラメータの制御)、ホワイトバランス処理(画像処理パラメータの制御)などに用いられる。ホワイトバランスの評価値は当然ホワイトバランス処理に用いられる。露出制御のための評価値は撮影パラメータとしての露出制御値の制御に用いられる。   In the present embodiment, an AF evaluation value is mainly used as an example of an evaluation value for obtaining an evaluation value of at least one image from a plurality of exposure images, and a focus lens position or the like is used as a shooting parameter to be controlled based on the evaluation value. Although the control value has been described, the present invention is not limited to this. The evaluation values to which the present embodiment can be applied can be applied to various evaluation values obtained from captured images, such as the above-described subject detection evaluation values, white balance evaluation values, and exposure control evaluation values. The subject detection result is used for AF, exposure control (control of imaging parameters), white balance processing (control of image processing parameters), and the like. The white balance evaluation value is naturally used for white balance processing. Evaluation values for exposure control are used to control exposure control values as imaging parameters.

(第3の実施形態)
次に、本発明の第3の実施形態について説明する。本実施形態は、AF評価枠が複数存在することによるフォーカス制御処理の差異を除き、第1の実施形態と同じであるため、以下では本実施形態に特徴的な部分のみ説明する。
(Third embodiment)
Next, a third embodiment of the present invention will be described. Since this embodiment is the same as the first embodiment except for the difference in focus control processing due to the existence of a plurality of AF evaluation frames, only the characteristic features of this embodiment will be described below.

本実施形態におけるAF評価値算出部107(図1)は、AF評価値を算出するための機能ブロックを複数有し、各機能ブロックは予め指定された異なるAF評価枠についてのAF評価値を算出する。従って、例えば、図12に示す複数のAF評価枠1201〜1205について、AF評価値算出部107でAF評価値Af1〜Af5が算出される。   The AF evaluation value calculation unit 107 (FIG. 1) in this embodiment has a plurality of functional blocks for calculating an AF evaluation value, and each functional block calculates an AF evaluation value for a different AF evaluation frame designated in advance. To do. Therefore, for example, the AF evaluation value calculation unit 107 calculates AF evaluation values Af1 to Af5 for a plurality of AF evaluation frames 1201 to 1205 shown in FIG.

AF評価枠1201〜1205の位置は固定であっても、ユーザが変更可能であってもよい。また、多くの固定位置の中からユーザが選択可能であってもよいし、任意の位置を指定可能であってもよい。いずれの場合も、設定されているAF評価枠のそれぞれについてAF評価値を算出するよう、AF評価値算出部107は内部の機能ブロックを割り当てる。   The positions of the AF evaluation frames 1201 to 1205 may be fixed or changeable by the user. Further, the user may be able to select from many fixed positions, or an arbitrary position may be designated. In any case, the AF evaluation value calculation unit 107 assigns an internal functional block so as to calculate an AF evaluation value for each of the set AF evaluation frames.

また、複数のAF評価枠1201〜1205のそれぞれについて動きベクトル情報Mv1〜Mv5を算出するため、動きベクトル検出部108もまた、動きベクトル情報を算出する機能ブロックを複数有する。
なお、AF評価値算出部107および動きベクトル検出部108が複数のAF評価枠に対応する複数の機能ブロックを有することは必須ではない。処理時間に問題がなければ、AF評価枠の数よりも少ない機能ブロックを用いてAF評価値および動きベクトル情報を算出してもよい。
Further, in order to calculate the motion vector information Mv1 to Mv5 for each of the plurality of AF evaluation frames 1201 to 1205, the motion vector detection unit 108 also includes a plurality of functional blocks for calculating the motion vector information.
It is not essential that the AF evaluation value calculation unit 107 and the motion vector detection unit 108 have a plurality of functional blocks corresponding to a plurality of AF evaluation frames. If there is no problem in processing time, the AF evaluation value and the motion vector information may be calculated using functional blocks smaller than the number of AF evaluation frames.

本実施形態では、複数のAF評価枠1201〜1205のそれぞれについて、第1の実施形態で説明したAF評価値選択処理を行う。
すなわち、システム制御部110は、各AF評価枠について、撮影情報に基づき、適正露出AF評価値と低露出AF評価値のうち、フォーカス制御に最適なAF評価値を選択する。本実施形態における撮影情報とは、露出段差量NとAF評価枠に対応した動きベクトル情報Mvである。
In the present embodiment, the AF evaluation value selection process described in the first embodiment is performed for each of the plurality of AF evaluation frames 1201 to 1205.
That is, for each AF evaluation frame, the system control unit 110 selects an optimal AF evaluation value for focus control from the appropriate exposure AF evaluation value and the low exposure AF evaluation value based on the shooting information. The shooting information in the present embodiment is motion vector information Mv corresponding to the exposure step amount N and the AF evaluation frame.

図13は、本実施形態におけるフォーカス制御動作を説明するためのフローチャートであり、第1の実施形態と共通する処理については図6と共通する参照数字を用いている。
図3のタイミングチャートで示したように、AF評価値算出部107は、AF評価枠1201〜1205で、適正露出AF評価値と低露出AF評価値を交互に算出する(S1301)。そして、タイミングパルス307のタイミングで、システム制御部110内のAF評価値選択部1401は、AF評価値算出部107から各AF評価枠のAF評価値を取得する。そして、AF評価値選択部1401は、低露出AF評価値を取得した場合にはS603に、適正露出AF評価値を取得した場合にはS1303に処理を進める。
FIG. 13 is a flowchart for explaining the focus control operation in the present embodiment, and the same reference numerals as in FIG. 6 are used for the processes common to the first embodiment.
As shown in the timing chart of FIG. 3, the AF evaluation value calculation unit 107 alternately calculates the appropriate exposure AF evaluation value and the low exposure AF evaluation value in the AF evaluation frames 1201 to 1205 (S1301). At the timing of the timing pulse 307, the AF evaluation value selection unit 1401 in the system control unit 110 acquires the AF evaluation value of each AF evaluation frame from the AF evaluation value calculation unit 107. Then, the AF evaluation value selection unit 1401 advances the process to S603 when the low exposure AF evaluation value is acquired, and proceeds to S1303 when the appropriate exposure AF evaluation value is acquired.

低露出AF評価値群を取得した場合は、AF評価枠ごとに、補正部1402での補正処理(S603)および保持部1403への保持(S604)が行われる。   When the low-exposure AF evaluation value group is acquired, correction processing in the correction unit 1402 (S603) and holding in the holding unit 1403 (S604) are performed for each AF evaluation frame.

一方、適正露出AF評価値群を取得した場合には、AF評価枠ごとに、第1の実施形態で説明したAF評価値選択処理を行う。
動きベクトル情報Mvの取得(S606)、露出段差量Nの取得(S607)、フォーカス制御に用いるAF評価値の選択(S608)は、S606およびS608がAF評価枠ごとに処理が行われることを除き、第1の実施形態と同じ処理である。
On the other hand, when a proper exposure AF evaluation value group is acquired, the AF evaluation value selection process described in the first embodiment is performed for each AF evaluation frame.
The acquisition of the motion vector information Mv (S606), the acquisition of the exposure step amount N (S607), and the selection of the AF evaluation value used for focus control (S608), except that S606 and S608 are processed for each AF evaluation frame. This is the same processing as in the first embodiment.

なお、本実施形態においてもAF評価値の選択処理は第1の実施形態と同様であるため、動きベクトル情報Mvと露出段差量Nとを用いた選択の代わりに、図8に示したような撮影情報を用いてAF評価値を選択するようにしてもよい。この場合も、AF評価枠ごとに処理を行うこと以外は第1の実施形態で説明したとおりである。   In this embodiment, since the AF evaluation value selection process is the same as that in the first embodiment, instead of selection using the motion vector information Mv and the exposure step amount N, as shown in FIG. An AF evaluation value may be selected using shooting information. In this case, the process is the same as that described in the first embodiment except that the process is performed for each AF evaluation frame.

AF評価値選択部1401が、全てのAF評価枠について、S606〜S608の処理を適用すると(S1304,YES)、システム制御部110は、フォーカス制御に使用するAF評価枠をAF評価枠1201〜1205から選択する(S1305)。   When the AF evaluation value selection unit 1401 applies the processing of S606 to S608 for all AF evaluation frames (S1304, YES), the system control unit 110 sets AF evaluation frames used for focus control as AF evaluation frames 1201-1205. (S1305).

複数のAF評価枠の中からフォーカス制御に用いるAF評価枠を選択する方法には特に制限はなく、公知かつ任意の方法を用いることができるが、例えば特開2006−330211号公報に記載される方法を用いることができる。   A method for selecting an AF evaluation frame used for focus control from a plurality of AF evaluation frames is not particularly limited, and any known and arbitrary method can be used. For example, it is described in JP-A-2006-330211. The method can be used.

システム制御部110は、選択したAF評価枠について得られた(選択された)AF評価値に基づいて光学系101のフォーカス状態(合焦状態)を評価し、AF評価値が最大となるフォーカスレンズの位置を算出する。そして、システム制御部110は、フォーカスレンズを算出した位置に移動(シフト)するよう光学系101に指示し、フォーカス制御を実現する。   The system control unit 110 evaluates the focus state (focused state) of the optical system 101 based on the (selected) AF evaluation value obtained for the selected AF evaluation frame, and the focus lens that maximizes the AF evaluation value The position of is calculated. Then, the system control unit 110 instructs the optical system 101 to move (shift) the focus lens to the calculated position, thereby realizing focus control.

(変形例)
なお、本実施形態においては、複数のAF評価枠のそれぞれについて第1の実施形態で説明した方法で選択したAF評価値を用いる形態について説明した。しかし、第2実施形態で説明したような、適正露出AF評価値と低露出AF評価値を合成したAF評価値を各AF評価値ついて求めるような形態であってもよい。
(Modification)
In the present embodiment, a mode has been described in which the AF evaluation value selected by the method described in the first embodiment is used for each of a plurality of AF evaluation frames. However, as described in the second embodiment, an AF evaluation value obtained by combining the appropriate exposure AF evaluation value and the low exposure AF evaluation value may be obtained for each AF evaluation value.

また、本実施形態では、複数の露出画像から少なくとも1つの画像の評価値を取得する評価値の例として主にAF評価値、当該評価値に基づいて制御する撮影パラメータとしてフォーカスレンズ位置などのフォーカス制御値について説明したが、これに限らない。本実施形態を適用できる評価値としては、上述した被写体検出の評価値、ホワイトバランスの評価値、露出制御のための評価値など、撮像画像から得られる各種評価値について適用できる。被写体検出結果は、AF、露出制御(撮影パラメータの制御)、ホワイトバランス処理(画像処理パラメータの制御)などに用いられる。ホワイトバランスの評価値は当然ホワイトバランス処理に用いられる。露出制御のための評価値は撮影パラメータとしての露出制御値の制御に用いられる。   In the present embodiment, an AF evaluation value is mainly used as an example of an evaluation value for obtaining an evaluation value of at least one image from a plurality of exposure images, and a focus lens position or the like is used as a shooting parameter to be controlled based on the evaluation value. Although the control value has been described, the present invention is not limited to this. The evaluation values to which the present embodiment can be applied can be applied to various evaluation values obtained from captured images, such as the above-described subject detection evaluation values, white balance evaluation values, and exposure control evaluation values. The subject detection result is used for AF, exposure control (control of imaging parameters), white balance processing (control of image processing parameters), and the like. The white balance evaluation value is naturally used for white balance processing. Evaluation values for exposure control are used to control exposure control values as imaging parameters.

(その他の実施形態)
なお、上述の実施形態では説明および理解を容易にするため、適正露出と低露出(露出アンダー)の2種類の撮影を周期的に行う場合について説明した。しかし、本発明は3種類以上の撮影を周期的に行う場合であっても適用可能である。この場合、基本的には適正露出もしくはそれに最も近い露出量の画像から得られるAF評価値を選択すればよい。また、動き量が多い場合や白飛び量が多い場合には程度に応じた段階の低露出画像のAF評価値を、黒つぶれ量が多い場合には程度に応じた段階の高露出画像のAF評価値を用いるようにすればよい。第2の実施形態のように合成を行う場合には、適正露出からの差が大きい画像のAF評価値ほど、合成係数の最大値小さく設定するようにすればよい。あるいは、3種類以上の画像を撮影する場合であっても、上述の実施形態で説明した2種類の画像から得られるAF評価値を用いるようにしてもよい。
(Other embodiments)
In the above-described embodiment, in order to facilitate explanation and understanding, the case where two types of photographing of proper exposure and low exposure (underexposure) are periodically performed has been described. However, the present invention is applicable even when three or more types of photographing are periodically performed. In this case, basically, an AF evaluation value obtained from an image having an appropriate exposure or an exposure amount closest thereto may be selected. Also, if the amount of movement is large or the amount of whiteout is large, the AF evaluation value of the low-exposure image depending on the degree is used. If the amount of blackout is large, the AF of the high-exposure image depending on the degree is used. An evaluation value may be used. When combining is performed as in the second embodiment, an AF evaluation value of an image having a larger difference from the appropriate exposure may be set to a smaller maximum value of the combination coefficient. Alternatively, even when three or more types of images are taken, AF evaluation values obtained from the two types of images described in the above embodiment may be used.

また、本発明は、以下の処理を実行することによっても実現される。即ち、上述した実施形態の機能を実現するソフトウェア(プログラム)を、ネットワーク又は各種記憶媒体を介してシステム或いは装置に供給し、そのシステム或いは装置のコンピュータ(またはCPUやMPU等)がプログラムを読み出して実行する処理である。   The present invention can also be realized by executing the following processing. That is, software (program) that realizes the functions of the above-described embodiments is supplied to a system or apparatus via a network or various storage media, and a computer (or CPU, MPU, or the like) of the system or apparatus reads the program. It is a process to be executed.

Claims (6)

フレームごとに露光量を異ならせて順次撮像を行う撮像手段と、
前記撮像手段によって得られた複数の画像を合成した合成画像をフレーム画像とする動画を生成する画像処理手段と、
画像間の被写体の動き量を検出する検出手段と、
前記撮像手段のフォーカス制御に用いる評価値を生成する生成手段と、
前記生成手段によって生成され評価値に基づいて、前記撮像手段のフォーカス制御する制御手段と、を有し、
前記制御手段は
前記複数の画像間の露光量の差が第1閾値より大きい場合は、前記複数の画像のうちで最も露光量が大きい画像から生成した評価値を用いてフォーカス制御を行い、
前記複数の画像間の露光量の差が第1閾値よりも小さい場合は、前記被写体の動き量に応じて何れかの画像を選択し、選択された画像から生成した評価値を用いてフォーカス制御を行うことを特徴とする撮像装置。
Imaging means for sequentially imaging with different exposure amounts for each frame ;
Image processing means for generating a moving image having a composite image obtained by combining a plurality of images obtained by the imaging means as a frame image ;
Detecting means for detecting the amount of movement of the subject between the images;
Generating means for generating an evaluation value used for focus control of the imaging means ;
Control means for controlling the focus of the imaging means based on the evaluation value generated by the generation means,
Wherein,
When the difference in exposure amount between the plurality of images is larger than a first threshold value, focus control is performed using an evaluation value generated from an image having the largest exposure amount among the plurality of images,
When the difference in exposure amount between the plurality of images is smaller than a first threshold value, one of the images is selected according to the amount of movement of the subject, and focus control is performed using an evaluation value generated from the selected image. An imaging apparatus characterized by performing
前記制御手段は、前記複数の画像間の露光量の差が第1閾値よりも小さい場合、前記被写体の動き量が第2閾値よりも大きい場合には前記複数の画像のうちで最も露出量が小さい画像から生成した評価値を用いてフォーカス制御を行うことを特徴とする請求項1に記載の撮像装置。 The control means has the largest exposure amount among the plurality of images when a difference in exposure amount between the plurality of images is smaller than a first threshold value, or when a movement amount of the subject is larger than a second threshold value. The imaging apparatus according to claim 1, wherein focus control is performed using an evaluation value generated from a small image. 前記合成画像は、前記複数の画像に対してダイナミックレンジが拡張された画像であることを特徴とする請求項1または請求項2に記載の撮像装置。The imaging apparatus according to claim 1, wherein the composite image is an image in which a dynamic range is expanded with respect to the plurality of images. 撮像手段により、フレームごとに露光量を異ならせて順次撮像を行う撮像工程と、An imaging step of sequentially imaging with different exposure amounts for each frame by the imaging means;
画像処理手段が、前記撮像工程で得られた複数の画像を合成した合成画像をフレーム画像とする動画を生成する画像処理工程と、  An image processing unit that generates a moving image using a combined image obtained by combining the plurality of images obtained in the imaging step as a frame image; and
検出手段が、画像間の被写体の動き量を検出する検出工程と、  A detecting step in which the detecting means detects the amount of movement of the subject between the images;
生成手段が、前記撮像手段のフォーカス制御に用いる評価値を生成する生成工程と、  A generating step of generating an evaluation value used for focus control of the imaging unit;
制御手段が、前記生成工程で生成された評価値に基づいて、前記撮像手段のフォーカス制御する制御工程と、を有し、  And a control unit that performs focus control of the imaging unit based on the evaluation value generated in the generation step,
前記制御工程において前記制御手段は、  In the control step, the control means includes:
前記複数の画像間の露光量の差が第1閾値より大きい場合は、前記複数の画像のうちで最も露光量が大きい画像から生成した評価値を用いてフォーカス制御を行い、    When the difference in exposure amount between the plurality of images is larger than a first threshold value, focus control is performed using an evaluation value generated from an image having the largest exposure amount among the plurality of images,
前記複数の画像間の露光量の差が第1閾値よりも小さい場合は、前記被写体の動き量に応じて何れかの画像を選択し、選択された画像から生成した評価値を用いてフォーカス制御を行うことを特徴とする撮像装置の制御方法。    When the difference in exposure amount between the plurality of images is smaller than a first threshold value, one of the images is selected according to the amount of movement of the subject, and focus control is performed using an evaluation value generated from the selected image. A method for controlling an imaging apparatus, comprising:
前記制御工程において前記制御手段は、前記複数の画像間の露光量の差が第1閾値よりも小さい場合、前記被写体の動き量が第2閾値よりも大きい場合には前記複数の画像のうちで最も露出量が小さい画像から生成した評価値を用いてフォーカス制御を行うことを特徴とする請求項4に記載の撮像装置の制御方法 In the control step, the control means includes the plurality of images when the difference in exposure amount between the plurality of images is smaller than a first threshold, or when the amount of movement of the subject is larger than a second threshold. 5. The method according to claim 4, wherein focus control is performed using an evaluation value generated from an image with the smallest exposure amount . 前記合成画像は、前記複数の画像に対してダイナミックレンジが拡張された画像であることを特徴とする請求項4または請求項5に記載の撮像装置の制御方法。6. The method according to claim 4, wherein the composite image is an image in which a dynamic range is extended with respect to the plurality of images.
JP2013021798A 2013-02-06 2013-02-06 Imaging apparatus and control method thereof Expired - Fee Related JP6080579B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2013021798A JP6080579B2 (en) 2013-02-06 2013-02-06 Imaging apparatus and control method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2013021798A JP6080579B2 (en) 2013-02-06 2013-02-06 Imaging apparatus and control method thereof

Publications (2)

Publication Number Publication Date
JP2014154979A JP2014154979A (en) 2014-08-25
JP6080579B2 true JP6080579B2 (en) 2017-02-15

Family

ID=51576458

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013021798A Expired - Fee Related JP6080579B2 (en) 2013-02-06 2013-02-06 Imaging apparatus and control method thereof

Country Status (1)

Country Link
JP (1) JP6080579B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10341565B2 (en) * 2016-05-10 2019-07-02 Raytheon Company Self correcting adaptive low light optical payload
JP7362441B2 (en) 2019-11-18 2023-10-17 キヤノン株式会社 Imaging device and method of controlling the imaging device

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11113008A (en) * 1997-10-08 1999-04-23 Olympus Optical Co Ltd Electronic image pickup device
JP4589646B2 (en) * 2004-03-31 2010-12-01 富士フイルム株式会社 Digital still camera and control method thereof
JP2011232671A (en) * 2010-04-30 2011-11-17 Olympus Corp Imaging apparatus

Also Published As

Publication number Publication date
JP2014154979A (en) 2014-08-25

Similar Documents

Publication Publication Date Title
JP5589446B2 (en) Image processing apparatus, imaging apparatus, image processing method, and program
US9596400B2 (en) Image pickup apparatus that periodically changes exposure condition, a method of controlling image pickup apparatus, and storage medium
JP6218389B2 (en) Image processing apparatus and image processing method
JP6643371B2 (en) Imaging device, control method, and program
US9071766B2 (en) Image capturing apparatus and control method thereof
KR20150045877A (en) Image processing apparatus and image processing method
JP2013258444A (en) Image processing device, image processing method, and program
JP2015144475A (en) Imaging apparatus, control method of the same, program and storage medium
US20230007155A1 (en) Notifying apparatus, image capturing apparatus, notifying method, image capturing method, and storage medium
JP2015231118A (en) Image composition device, image composition system and image composition method
CN110958361B (en) Image pickup apparatus capable of HDR composition, control method therefor, and storage medium
JP5882702B2 (en) Imaging device
JP6727205B2 (en) Image processing apparatus, image processing method and program
JP5713643B2 (en) IMAGING DEVICE, IMAGING DEVICE CONTROL METHOD, PROGRAM, AND STORAGE MEDIUM
JP6305290B2 (en) Image processing apparatus, imaging apparatus, and image processing method
JP6080579B2 (en) Imaging apparatus and control method thereof
US8982244B2 (en) Image capturing apparatus for luminance correction, a control method therefor, and a recording medium
JP5446847B2 (en) Image processing apparatus and method, and program
JP2013138522A (en) Image processing apparatus and program
US11398014B2 (en) Image processing apparatus and image processing method
JP5541956B2 (en) Image composition method, image composition program, and image composition apparatus
JP2014138378A (en) Image pickup device, control method thereof, and control program thereof
JP6779408B2 (en) Imaging equipment, imaging methods, and programs
KR101677394B1 (en) Image acquiring system and image acquiring method therefor
JP2024033748A (en) Image processing device, imaging device, image processing method, imaging device control method, program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20160204

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20160929

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20161011

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20161129

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20170117

R151 Written notification of patent or utility model registration

Ref document number: 6080579

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151

LAPS Cancellation because of no payment of annual fees