JP2020148907A - Imaging device, control method thereof, program, and storage medium - Google Patents

Imaging device, control method thereof, program, and storage medium Download PDF

Info

Publication number
JP2020148907A
JP2020148907A JP2019046381A JP2019046381A JP2020148907A JP 2020148907 A JP2020148907 A JP 2020148907A JP 2019046381 A JP2019046381 A JP 2019046381A JP 2019046381 A JP2019046381 A JP 2019046381A JP 2020148907 A JP2020148907 A JP 2020148907A
Authority
JP
Japan
Prior art keywords
focus
focus detection
subject
process proceeds
detected
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
JP2019046381A
Other languages
Japanese (ja)
Other versions
JP7249174B2 (en
Inventor
直樹 岩▲崎▼
Naoki Iwasaki
直樹 岩▲崎▼
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 JP2019046381A priority Critical patent/JP7249174B2/en
Publication of JP2020148907A publication Critical patent/JP2020148907A/en
Application granted granted Critical
Publication of JP7249174B2 publication Critical patent/JP7249174B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Automatic Focus Adjustment (AREA)
  • Studio Devices (AREA)
  • Focusing (AREA)

Abstract

To improve the followability to the movement in far-and-near directions of a subject in an autofocus function of an imaging device.SOLUTION: An imaging device includes: an imaging element for capturing a subject image; a focus detection unit for detecting a focused state using an image signal obtained from the imaging element; a setting unit for setting a plurality of focus detection areas in a screen of the imaging element; a detection unit for performing focus detection by the focus detection unit multiple times for one focus detection area among the plurality of focus detection areas before photographing, and detecting a moving direction of the subject; and a selection unit for selecting one to be used for focus detection from the plurality of focus detection areas based on the moving direction of the subject detected by the detection unit.SELECTED DRAWING: Figure 17

Description

本発明は、デジタルカメラ、ビデオカメラ等の撮像装置におけるオートフォーカス技術に関する。 The present invention relates to an autofocus technique in an imaging device such as a digital camera or a video camera.

従来より、デジタルカメラなどにおいては、被写体に焦点を合わせる方法として、CCDなどの撮像素子から得られる輝度信号を用いて焦点検出を行い、自動的にフォーカスレンズを動かして合焦動作を行うオートフォーカス方式が用いられている。このオートフォーカス方式を用いた自動合焦装置では、各画面内に設定された焦点検出領域内における信号の高周波成分を積分したAF評価値に基づいて、最もコントラストの高いフォーカスレンズ位置を検出し、合焦点を求めることが一般的に行われている。 Conventionally, in digital cameras and the like, as a method of focusing on a subject, autofocus is performed by detecting the focus using a luminance signal obtained from an image sensor such as a CCD and automatically moving the focus lens to perform a focusing operation. The method is used. In the automatic focusing device using this autofocus method, the focus lens position having the highest contrast is detected based on the AF evaluation value obtained by integrating the high frequency components of the signal in the focus detection area set in each screen. It is common practice to find the focus.

このAF方法において、近づくあるいは離れる方向(以下、遠近方向と呼ぶ)に動いている被写体にピントを合わせ続けるためには、常にフォーカスレンズを駆動して合焦点を求め続ける必要がある。合焦位置が得られた場合、さらにその合焦位置を記憶しておけば、過去の合焦位置より、次回の合焦位置を予め予測することが可能となる。 In this AF method, in order to keep focusing on a subject moving in an approaching or distant direction (hereinafter referred to as a perspective direction), it is necessary to constantly drive the focus lens to obtain in-focus. When the in-focus position is obtained, if the in-focus position is further memorized, the next in-focus position can be predicted in advance from the past in-focus position.

例えば、特許文献1には、撮影前にレンズ駆動によるAFスキャンを繰り返して、被写体にAF追従させる自動合焦装置を備えた撮像装置が開示されている。また、特許文献2には、連続撮影などにおいて、毎撮影前にAFスキャンを行った後に合焦位置を記憶しておき、記憶している過去の合焦位置に基づいて、次回の撮影前の合焦位置を予測し、AFスキャンをする所定範囲を決定する焦点調整装置が開示されている。 For example, Patent Document 1 discloses an imaging device including an automatic focusing device that repeats AF scanning driven by a lens before photographing to cause AF tracking on a subject. Further, in Patent Document 2, in continuous shooting or the like, the focusing position is memorized after performing an AF scan before each shooting, and based on the memorized past focusing position, before the next shooting. A focus adjusting device for predicting the in-focus position and determining a predetermined range for AF scanning is disclosed.

特開2004−212556号公報Japanese Unexamined Patent Publication No. 2004-212556 特開2007−206433号公報JP-A-2007-206433

動いている被写体に対してAFスキャンによって合焦位置を求める場合、一時的な背景抜けやAFスキャン中の被写体の変化などによって、信頼性の低い合焦位置または誤った合焦位置が求められてしまうことがある。 When finding the in-focus position for a moving subject by AF scan, an unreliable in-focus position or an incorrect in-focus position is found due to temporary background omission or changes in the subject during AF scan. It may end up.

特許文献1では、画面内での被写体の動きを検出して、被写体の画面内での動きが大きい場合にAF枠を拡大したり、AFスキャン範囲を広げるなどの対策をとっている。しかし、遠近方向の被写体の動きについては対策されていない。そのため、被写体に画面の平面方向での動きがなく、遠近方向の動きが大きい場合には、被写体へのピント追従性能が悪くなってしまうという問題がある。 In Patent Document 1, the movement of the subject in the screen is detected, and when the movement of the subject in the screen is large, the AF frame is enlarged or the AF scan range is widened. However, no countermeasures have been taken for the movement of the subject in the perspective direction. Therefore, if the subject does not move in the plane direction of the screen and the movement in the perspective direction is large, there is a problem that the focus tracking performance for the subject deteriorates.

特許文献2では、常に過去の合焦位置に基づいて次回の被写体の合焦位置を予測してAFスキャンをする所定範囲を決定するため、一時的な背景抜けやAFスキャン中の被写体の変化などがあった場合、誤った予測をしてしまうことがある。そのため、被写体へのピント追従性能が悪くなってしまうという問題がある。 In Patent Document 2, since the focus position of the next subject is always predicted based on the past focus position to determine the predetermined range for AF scanning, temporary background omission, change of the subject during AF scanning, etc. If there is, you may make a wrong prediction. Therefore, there is a problem that the focus tracking performance for the subject is deteriorated.

また、特許文献1及び2はともに、被写体が静止していてもスキャンを続けるため、フォーカスレンズの駆動による消費電力が大きい。また、常にスキャンを行うため、常にピント変動があり、ライブビュー画像の見栄えが悪いという問題もある。 Further, in both Patent Documents 1 and 2, since scanning is continued even when the subject is stationary, power consumption due to driving the focus lens is large. In addition, since scanning is always performed, there is a problem that the focus fluctuates constantly and the live view image does not look good.

本発明は上述した課題に鑑みてなされたものであり、その目的は、撮像装置のオートフォーカス機能において、被写体の遠近方向の動きへの追従性を改善することである。 The present invention has been made in view of the above-mentioned problems, and an object of the present invention is to improve the ability to follow the movement of a subject in the perspective direction in the autofocus function of the image pickup apparatus.

本発明に係わる撮像装置は、被写体像を撮像する撮像素子と、前記撮像素子から得られた画像信号を用いて合焦状態を検出する焦点検出手段と、前記撮像素子の画面内に複数の焦点検出領域を設定する設定手段と、撮影の前に、前記複数の焦点検出領域のうちの1つの焦点検出領域について、前記焦点検出手段による焦点検出を複数回行い、被写体の移動方向を検出する検出手段と、前記検出手段により検出された被写体の移動方向に基づいて、前記複数の焦点検出領域のいずれを用いて焦点検出を行うかを選択する選択手段と、を備えることを特徴とする。 The image pickup device according to the present invention includes an image pickup element that captures a subject image, a focus detection means that detects a focusing state using an image signal obtained from the image pickup element, and a plurality of focal points in the screen of the image pickup element. A setting means for setting a detection area and a detection for detecting a moving direction of a subject by performing focus detection by the focus detection means a plurality of times for one of the plurality of focus detection areas before shooting. It is characterized by including means and a selection means for selecting which of the plurality of focus detection regions is used for focus detection based on the moving direction of the subject detected by the detection means.

本発明によれば、撮像装置のオートフォーカス機能において、被写体の遠近方向の動きへの追従性を改善することが可能となる。 According to the present invention, the autofocus function of the image pickup apparatus can improve the ability to follow the movement of the subject in the perspective direction.

本発明の撮像装置の一実施形態であるデジタルカメラの構成を示すブロック図。The block diagram which shows the structure of the digital camera which is one Embodiment of the image pickup apparatus of this invention. 一実施形態のデジタルカメラの動作を示すフローチャート。A flowchart showing the operation of the digital camera of one embodiment. 図2におけるServoAFのサブルーチンを示すフローチャート。The flowchart which shows the subroutine of ServoAF in FIG. AF枠設定の概念を説明するための図。The figure for demonstrating the concept of AF frame setting. 図3における被写体距離変化判定のサブルーチンを示すフローチャート。The flowchart which shows the subroutine of the subject distance change determination in FIG. 図2における通常AF動作のサブルーチンを示すフローチャート。The flowchart which shows the subroutine of the normal AF operation in FIG. 図3におけるServo中AF動作のサブルーチンを示すフローチャート。The flowchart which shows the subroutine of AF operation in Servo in FIG. 図7における予測可能判定のサブルーチンを示すフローチャート。The flowchart which shows the subroutine of predictable determination in FIG. 図7における被写***置予測のサブルーチンを示すフローチャート。The flowchart which shows the subroutine of subject position prediction in FIG. 被写***置予測の計算を説明するための図。The figure for demonstrating the calculation of the subject position prediction. 図6及び図7におけるスキャンのサブルーチンを示すフローチャート。The flowchart which shows the subroutine of the scan in FIG. 6 and FIG. 図6及び図7における合焦判定のサブルーチンを示すフローチャート。The flowchart which shows the subroutine of focusing determination in FIG. 6 and FIG. AF評価値の判定の概念を説明するための図。The figure for demonstrating the concept of judgment of AF evaluation value. 無限遠方向の単調減少を求める動作を示すフローチャート。A flowchart showing an operation for obtaining a monotonous decrease in the infinity direction. 至近端方向の単調減少を求める動作を示すフローチャート。A flowchart showing an operation for obtaining a monotonous decrease in the closest end direction. 図2における撮影動作のサブルーチンを示すフローチャート。The flowchart which shows the subroutine of the shooting operation in FIG. 図7における合焦枠選択のサブルーチンを示すフローチャート。The flowchart which shows the subroutine of focusing frame selection in FIG.

以下、添付図面を参照して実施形態を詳しく説明する。なお、以下の実施形態は特許請求の範囲に係る発明を限定するものではない。実施形態には複数の特徴が記載されているが、これらの複数の特徴の全てが発明に必須のものとは限らず、また、複数の特徴は任意に組み合わせられてもよい。さらに、添付図面においては、同一若しくは同様の構成に同一の参照番号を付し、重複した説明は省略する。 Hereinafter, embodiments will be described in detail with reference to the accompanying drawings. The following embodiments do not limit the invention according to the claims. Although a plurality of features are described in the embodiment, not all of the plurality of features are essential for the invention, and the plurality of features may be arbitrarily combined. Further, in the attached drawings, the same or similar configurations are designated by the same reference numbers, and duplicate description is omitted.

図1は本発明の撮像装置の一実施形態であるデジタルカメラの構成を示すブロック図である。 FIG. 1 is a block diagram showing a configuration of a digital camera according to an embodiment of the imaging device of the present invention.

デジタルカメラ100は、撮影光学系として、ズーム機構を含む撮影レンズ101、光量を制御する絞り及びシャッター102、撮像素子108上に焦点を合わせるためのフォーカスレンズ104を備える(配置されている)。AE処理部103は、絞り及びシャッター102を制御して露出を調整する。AF処理部105は、フォーカスレンズ104を駆動して撮影光学系の焦点を合わせる。ストロボ106は、EF処理部107の制御により、被写体を照明する。 The digital camera 100 includes (arranges) a photographing lens 101 including a zoom mechanism, a diaphragm and a shutter 102 for controlling the amount of light, and a focus lens 104 for focusing on the image pickup element 108 as a photographing optical system. The AE processing unit 103 controls the aperture and the shutter 102 to adjust the exposure. The AF processing unit 105 drives the focus lens 104 to focus the photographing optical system. The strobe 106 illuminates the subject under the control of the EF processing unit 107.

撮像素子108は、被写体からの反射光(被写体像)を電気信号に変換する多数の光電変換素子を有する。A/D変換部109は、撮像素子108の出力ノイズを除去するCDS回路、A/D変換前に行う非線形増幅回路、そしてアナログ信号をデジタル信号に変換するA/D変換器を含む。画像処理部110は、デジタル信号に変換された画像信号に信号処理を施す。WB処理部111は、デジタル画像信号に対してホワイトバランス処理を行う。フォーマット変換部112は、画像処理部110で処理された画像データに対してフォーマット変換を行う。DRAM113は、画像データの一時保存などに用いられる高速アクセスが可能な内蔵メモリ(例えばランダムアクセスメモリなど)である。画像記録部114は、メモリーカードなどの記録媒体とそのインターフェースからなる。 The image pickup device 108 has a large number of photoelectric conversion elements that convert the reflected light (subject image) from the subject into an electric signal. The A / D conversion unit 109 includes a CDS circuit that removes output noise of the image sensor 108, a non-linear amplifier circuit that is performed before A / D conversion, and an A / D converter that converts an analog signal into a digital signal. The image processing unit 110 performs signal processing on the image signal converted into a digital signal. The WB processing unit 111 performs white balance processing on the digital image signal. The format conversion unit 112 performs format conversion on the image data processed by the image processing unit 110. The DRAM 113 is a built-in memory (for example, a random access memory) that can be accessed at high speed and is used for temporary storage of image data. The image recording unit 114 includes a recording medium such as a memory card and its interface.

システム制御部115は、撮影シーケンス制御などのデジタルカメラ100全体の制御を司る。VRAM116は、表示用の画像を記憶する画像表示用メモリである。操作表示部117は、画像表示、操作補助のための表示、カメラの状態の表示などの他、撮影時には撮影画面と焦点検出領域を表示する。操作部118は、ユーザーがカメラを外部から操作するための操作部材を有する。撮影モードスイッチ119は、顔検出モードをONまたはOFFに切り替えたり、撮影モードを選択する等の操作を行うためのスイッチである。メインスイッチ120は、デジタルカメラ100の電源を投入するためのスイッチである。 The system control unit 115 controls the entire digital camera 100, such as shooting sequence control. The VRAM 116 is an image display memory that stores an image for display. The operation display unit 117 displays a shooting screen and a focus detection area at the time of shooting, in addition to displaying an image, displaying for assisting operation, and displaying the state of the camera. The operation unit 118 has an operation member for the user to operate the camera from the outside. The shooting mode switch 119 is a switch for performing operations such as switching the face detection mode to ON or OFF and selecting a shooting mode. The main switch 120 is a switch for turning on the power of the digital camera 100.

スイッチSW1(121)は、レリーズボタン130が半押しされることによりONとなり、AFやAE等の撮影スタンバイ動作が行われる。また、スイッチSW2(122)は、スイッチSW1がONされた後、レリーズボタン130がさらに押し込まれる(全押しされる)ことによりONとなり、実際の撮影動作が実行される。顔検出モジュール123は、画像処理部110で処理された画像信号を用いて顔検出を行い、検出した一つ又は複数の顔情報(位置・大きさ・信頼度)をシステム制御部115に送る。なお、顔の検出方法は、公知の方法が用いられるが、本発明の主眼点ではないため詳細な説明は省略する。 The switch SW1 (121) is turned on when the release button 130 is half-pressed, and a shooting standby operation such as AF or AE is performed. Further, the switch SW2 (122) is turned on by further pushing (fully pressing) the release button 130 after the switch SW1 is turned on, and the actual shooting operation is executed. The face detection module 123 performs face detection using the image signal processed by the image processing unit 110, and sends one or more detected face information (position, size, reliability) to the system control unit 115. A known method is used as the face detection method, but detailed description thereof will be omitted because it is not the main point of the present invention.

物体検出モジュール124は、画面内の顔以外の物体を検出して検出情報をシステム制御部115に送る。具体的には、画面内の色・輝度などの特徴量から主被写体と推定される領域を自動的に検出する。もしくは、操作表示部117がタッチパネル等により画面操作を受け付ける場合は、ユーザーが指定した表示部の座標から一定範囲内において、色・輝度などの特徴量から被写体を検出して追尾する。タッチパネル等が非搭載の場合は、操作表示部117に被写体指定用のGUI等を表示させて操作部118で被写体を指定し、特徴量を算出して追尾できるような構成とする。こちらも本発明の主眼点ではないため詳細な説明は省略する。角速度センサ部125は、カメラ自体の動きを検出して、カメラの動き情報をシステム制御部115に送る。 The object detection module 124 detects an object other than the face on the screen and sends the detection information to the system control unit 115. Specifically, the area estimated to be the main subject is automatically detected from the features such as color and brightness in the screen. Alternatively, when the operation display unit 117 accepts a screen operation using a touch panel or the like, the subject is detected and tracked from the feature quantities such as color and brightness within a certain range from the coordinates of the display unit specified by the user. When the touch panel or the like is not installed, the operation display unit 117 displays a GUI or the like for subject designation, the operation unit 118 specifies the subject, and the feature amount is calculated and tracked. Since this is also not the main point of the present invention, detailed description thereof will be omitted. The angular velocity sensor unit 125 detects the movement of the camera itself and sends the movement information of the camera to the system control unit 115.

なお、DRAM113は、一時的に画像を記憶する高速バッファとして、あるいは画像の圧縮伸張における作業用メモリなどとして使用される。操作部118は、例えば次のようなものが含まれる。撮像装置の撮影機能や画像再生時の設定などの各種設定を行うメニュースイッチ、撮影レンズのズーム動作を指示するズームレバー、撮影モードと再生モードの動作モード切換えスイッチ、などである。 The DRAM 113 is used as a high-speed buffer for temporarily storing an image, or as a working memory for compressing and decompressing an image. The operation unit 118 includes, for example, the following. Menu switches for making various settings such as the shooting function of the image pickup device and settings for image playback, a zoom lever for instructing the zoom operation of the shooting lens, and an operation mode switching switch for shooting mode and playback mode.

以下、本実施形態におけるデジタルカメラ100の動作について説明する。図2は、本実施形態のデジタルカメラ100の全体動作を示すフローチャートである。 Hereinafter, the operation of the digital camera 100 in this embodiment will be described. FIG. 2 is a flowchart showing the overall operation of the digital camera 100 of the present embodiment.

まず、メインスイッチ120がONされると、ステップS201へと進む。ステップS201では、スイッチSW1の状態を判定し、ONであればステップS202へと進み、ONでなければステップS201を継続的に実行する。 First, when the main switch 120 is turned on, the process proceeds to step S201. In step S201, the state of the switch SW1 is determined, and if it is ON, the process proceeds to step S202, and if it is not ON, step S201 is continuously executed.

ステップS202では、AE処理部103が画像処理部110の出力からAE処理(露出制御処理)を行ってステップS203へと進む。ステップS203では、後述する図6のフローチャートに従って、通常AF動作が行われ、ステップS204へと進む。 In step S202, the AE processing unit 103 performs AE processing (exposure control processing) from the output of the image processing unit 110 and proceeds to step S203. In step S203, the normal AF operation is performed according to the flowchart of FIG. 6 described later, and the process proceeds to step S204.

ステップS204では、ServoAFモードに設定されているか否かを判定し、ServoAFモードに設定されていればステップS205へと進み、ServoAFモードに設定されていなければステップS206へと進む。ここで、ServoAFモードとは、被写体に一旦焦点が合った後も、被写体を追尾して焦点を合わせ続けるAFモードである。 In step S204, it is determined whether or not the ServoAF mode is set, and if the ServoAF mode is set, the process proceeds to step S205, and if the ServoAF mode is not set, the process proceeds to step S206. Here, the Servo AF mode is an AF mode in which the subject is tracked and continues to be focused even after the subject is once focused.

ステップS205では、後述する図3に従って、ServoAFを行ってステップS206へと進む。ステップS206では、スイッチSW1の状態を判定し、ONであればステップS207へと進み、ONでなければステップS201へと戻る。 In step S205, ServoAF is performed according to FIG. 3 described later, and the process proceeds to step S206. In step S206, the state of the switch SW1 is determined, and if it is ON, the process proceeds to step S207, and if it is not ON, the process returns to step S201.

ステップS207では、スイッチSW2の状態を判定し、ONであればステップS208へと進み、ONでなければステップS204へと戻る。ステップS208では、後述する図16のフローチャートに従って、撮影動作を行ってステップS201へと戻る。 In step S207, the state of the switch SW2 is determined, and if it is ON, the process proceeds to step S208, and if it is not ON, the process returns to step S204. In step S208, the shooting operation is performed according to the flowchart of FIG. 16 described later, and the process returns to step S201.

図3は、図2のフローチャートのステップS205におけるServoAF動作のサブルーチンのフローチャートである。 FIG. 3 is a flowchart of the subroutine of the ServoAF operation in step S205 of the flowchart of FIG.

まず、ステップS301では、顔検出モジュール123と物体検出モジュール124により、被写体を検出したか否かを判定する。ステップS301において被写体が検出されていればステップS302へ進み、被写体が検出されていなければS303へ進む。 First, in step S301, the face detection module 123 and the object detection module 124 determine whether or not the subject has been detected. If the subject is detected in step S301, the process proceeds to step S302, and if the subject is not detected, the process proceeds to S303.

ステップS302では、被写体として顔が検出されていればステップS304へと進み、検出された被写体が顔でない場合はステップS305へと進む。 In step S302, if a face is detected as a subject, the process proceeds to step S304, and if the detected subject is not a face, the process proceeds to step S305.

ステップS304では、顔検出モジュール123で検出した顔の位置、顔のサイズなどの顔情報を取得してステップS306へと進む。ステップS306では、最新の顔検出位置にAF枠(焦点検出枠)を設定してステップS308へと進む。ここで、顔が検出されている場合のAF枠のサイズは、予め設定された所定のサイズにしてもよいし、検出された顔のサイズに基づいて決定してもよい。本実施形態では、検出された顔のサイズに基づいて決定することとする。このイメージを図4(a)に示す。 In step S304, face information such as the face position and face size detected by the face detection module 123 is acquired, and the process proceeds to step S306. In step S306, an AF frame (focus detection frame) is set at the latest face detection position, and the process proceeds to step S308. Here, the size of the AF frame when a face is detected may be a predetermined size set in advance, or may be determined based on the size of the detected face. In the present embodiment, the determination is made based on the detected face size. This image is shown in FIG. 4 (a).

ステップS305では、物体検出モジュール124で検出した物体の位置、物体のサイズなどの情報を取得してステップS307へと進む。ステップS307では、最新の物体検出位置を中心に3×3の所定サイズの9つのAF枠を設定してステップS308へと進む。ここで、物体が検出されているときのAF枠のサイズは、予め設定された所定のサイズにしてもよいし、検出サイズに基づいて決定してもよい。本実施形態では、顔以外の被写体では、動いている場合に検出サイズの変動が発生しやすいため、AF評価値への影響を考慮して所定サイズで固定することとする。このイメージを図4(b)に示す。 In step S305, information such as the position of the object and the size of the object detected by the object detection module 124 is acquired, and the process proceeds to step S307. In step S307, nine AF frames having a predetermined size of 3 × 3 are set around the latest object detection position, and the process proceeds to step S308. Here, the size of the AF frame when the object is detected may be a predetermined size set in advance, or may be determined based on the detection size. In the present embodiment, since the detection size tends to fluctuate when the subject is moving, the subject is fixed at a predetermined size in consideration of the influence on the AF evaluation value. This image is shown in FIG. 4 (b).

ステップS303では、画面の中央領域などの所定位置にAF枠を設定してステップS308へと進む。 In step S303, the AF frame is set at a predetermined position such as the center area of the screen, and the process proceeds to step S308.

ステップS308では、設定したAF枠において焦点評価値及び輝度値を取得してステップS309へと進む。 In step S308, the focus evaluation value and the brightness value are acquired in the set AF frame, and the process proceeds to step S309.

ステップS309では、後述するステップS311のServo中AF動作においてピークが検出されたことを示す、ピーク検出フラグの状態を調べる。ピーク検出フラグがTRUEであればステップS310へと進み、ピーク検出フラグがFALSEであれば、ステップS311へと進む。 In step S309, the state of the peak detection flag indicating that the peak was detected in the AF operation during Servo in step S311 described later is examined. If the peak detection flag is TRUE, the process proceeds to step S310, and if the peak detection flag is FALSE, the process proceeds to step S311.

ステップS311では、後述する図7のフローチャートに従ってServo中AFの動作を行って、図2のステップS206へと進む。 In step S311 the AF during Servo operation is performed according to the flowchart of FIG. 7 described later, and the process proceeds to step S206 of FIG.

ステップS310では、後述する図5のステップS405において設定される被写体距離が変化したことを示す距離変化フラグの状態を調べる。距離変化フラグがTUREであればステップS314へと進み、距離変化フラグがFALSEであれば、ステップS312へと進む。 In step S310, the state of the distance change flag indicating that the subject distance set in step S405 of FIG. 5 described later has changed is examined. If the distance change flag is TURE, the process proceeds to step S314, and if the distance change flag is FALSE, the process proceeds to step S312.

ステップS312では、後述する図6のステップS508において設定される合焦フラグがTRUEであるか否かを判定し、合焦フラグがTRUEであればステップS313へと進み、合焦フラグがFALSEであればステップS314へと進む。ステップS313では後述する図5のフローチャートに従って被写体距離変化判定処理を行う。 In step S312, it is determined whether or not the focusing flag set in step S508 of FIG. 6 described later is TRUE. If the focusing flag is TRUE, the process proceeds to step S313, and if the focusing flag is FALSE. If so, the process proceeds to step S314. In step S313, the subject distance change determination process is performed according to the flowchart of FIG. 5 described later.

ステップS314では、一度でも焦点評価値が所定値以上変化したか否かを判定する。ステップS314の条件を満たした場合はステップS315へ進み、満たさない場合はステップS316へ進む。 In step S314, it is determined whether or not the focus evaluation value has changed by a predetermined value or more even once. If the condition of step S314 is satisfied, the process proceeds to step S315, and if the condition is not satisfied, the process proceeds to step S316.

ステップS315では、後述の図16のステップS1501におけるフォーカスレンズ104の停止状態での撮影指示後の再スキャン判定(再度のスキャンの判定)に用いる再スキャン判定フラグ(以後再スキャンFlg)をTRUEにしてServoAFの処理を終了する。また、ステップS316では再スキャン判定フラグをFALSEにしてServoAFの処理を終了する。この再スキャンFlgは図2におけるステップS201のスイッチSW1のON時にFALSEで初期化するが図示は省略する。 In step S315, the rescan determination flag (hereinafter, rescan Flg) used for the rescan determination (determination of rescan) after the shooting instruction in the stopped state of the focus lens 104 in step S1501 of FIG. 16 described later is set to TRUE. The ServoAF process ends. Further, in step S316, the rescan determination flag is set to FALSE and the ServoAF process is terminated. This rescan Flg is initialized by FALSE when the switch SW1 in step S201 in FIG. 2 is turned on, but the illustration is omitted.

図5は、図3のフローチャートにおけるステップS313の被写体距離変化判定処理のサブルーチンを示す図である。 FIG. 5 is a diagram showing a subroutine of the subject distance change determination process in step S313 in the flowchart of FIG.

まず、ステップS401では、顔検出モジュール123により、顔が検出されているか否かを判定し、顔が検出されていればステップS402へと進み、顔が検出されていなければステップS406へと進む。 First, in step S401, the face detection module 123 determines whether or not a face is detected, and if a face is detected, the process proceeds to step S402, and if no face is detected, the process proceeds to step S406.

ステップS402では、今回検出した顔サイズが前回検出した顔サイズに対して所定割合以上変化したか否かを判定し、所定割合以上変化していればステップS403へと進み、所定割合以上変化していなければステップS406へと進む。ステップS403では、顔検出サイズ変化回数に1を加えてステップS404へと進む。 In step S402, it is determined whether or not the face size detected this time has changed by a predetermined ratio or more with respect to the face size detected last time, and if it has changed by a predetermined ratio or more, the process proceeds to step S403 and the face size has changed by a predetermined ratio or more. If not, the process proceeds to step S406. In step S403, 1 is added to the number of face detection size changes, and the process proceeds to step S404.

ステップS404では、顔サイズ変化回数が閾値以上か否かを判定し、閾値以上であればステップS405へと進み、そうでなければステップS406へと進む。 In step S404, it is determined whether or not the number of face size changes is equal to or greater than the threshold value, and if it is equal to or greater than the threshold value, the process proceeds to step S405, and if not, the process proceeds to step S406.

ステップS406では、前回取得した輝度値に対して、今回取得した輝度値が所定値以上変化したか否かを判定し、所定値以上変化していればステップS407へと進み、所定値以上変化していなければステップS409へと進む。ステップS407では、輝度値変化回数に1を加えてステップS408へと進む。 In step S406, it is determined whether or not the brightness value acquired this time has changed by a predetermined value or more with respect to the brightness value acquired last time, and if the brightness value has changed by a predetermined value or more, the process proceeds to step S407 and the change is made by a predetermined value or more. If not, the process proceeds to step S409. In step S407, 1 is added to the number of times the luminance value is changed, and the process proceeds to step S408.

ステップS408では、輝度値変化回数が閾値以上か否かを判定し、閾値以上であればステップS405へと進み、そうでなければステップS409へと進む。 In step S408, it is determined whether or not the number of changes in the luminance value is equal to or greater than the threshold value, and if it is equal to or greater than the threshold value, the process proceeds to step S405, and if not, the process proceeds to step S409.

ステップS409では、前回取得した焦点評価値に対して、今回取得した焦点評価値が所定値以上変化したか否かを判定し、所定値以上変化していればステップS410へと進み、所定値以上変化していなければステップS412へと進む。ステップS410では、焦点評価値変化回数に1を加えてステップ411へと進む。 In step S409, it is determined whether or not the focus evaluation value acquired this time has changed by a predetermined value or more with respect to the focus evaluation value acquired last time, and if the focus evaluation value has changed by a predetermined value or more, the process proceeds to step S410, and the value exceeds the predetermined value. If it has not changed, the process proceeds to step S412. In step S410, 1 is added to the number of changes in the focus evaluation value, and the process proceeds to step 411.

ステップS411では、焦点評価値変化回数が閾値以上か否かを判定し、閾値以上であればステップS405へと進み、そうでなければステップS412へと進む。 In step S411, it is determined whether or not the number of changes in the focus evaluation value is equal to or greater than the threshold value, and if it is equal to or greater than the threshold value, the process proceeds to step S405, and if not, the process proceeds to step S412.

ステップS412では、角速度センサ部125で検出したカメラの動作量が所定値以上変化したか否かを判定し、所定値以上変化していればステップS413へと進み、そうでなければステップS415へと進む。ステップS413では、カメラ動作回数に1を加えてステップS414へと進む。 In step S412, it is determined whether or not the movement amount of the camera detected by the angular velocity sensor unit 125 has changed by a predetermined value or more, and if it has changed by a predetermined value or more, the process proceeds to step S413, and if not, the process proceeds to step S415. move on. In step S413, 1 is added to the number of camera operations to proceed to step S414.

ステップS414では、カメラ動作回数が閾値以上か否かを判定し、閾値以上であればステップS405へと進み、そうでなければステップS415へと進む。 In step S414, it is determined whether or not the number of camera operations is equal to or greater than the threshold value, and if it is equal to or greater than the threshold value, the process proceeds to step S405, and if not, the process proceeds to step S415.

ステップS415では、物体検出モジュール124により被写体の動作量が所定値以上であるか否かを判定し、所定値以上であればステップS416へと進み、そうでなければステップS418へと進む。ステップS416では、被写体動作回数に1を加えてステップS417へと進む。 In step S415, the object detection module 124 determines whether or not the movement amount of the subject is equal to or greater than a predetermined value, and if it is equal to or greater than the predetermined value, the process proceeds to step S416, and if not, the process proceeds to step S418. In step S416, 1 is added to the number of times the subject is moved, and the process proceeds to step S417.

ステップS417では、被写体動作回数が閾値以上か否かを判定し、閾値以上であればステップS405へと進み、そうでなければステップS418へと進む。 In step S417, it is determined whether or not the number of times the subject moves is equal to or greater than the threshold value, and if it is equal to or greater than the threshold value, the process proceeds to step S405, and if not, the process proceeds to step S418.

ステップS405では、合焦フラグをFALSEにし、距離変化フラグをTRUEにして被写体距離変化判定処理を終了し、図3のステップS314へと進む。 In step S405, the focusing flag is set to FALSE, the distance change flag is set to TRUE, the subject distance change determination process is completed, and the process proceeds to step S314 of FIG.

ステップS418では、顔検出サイズ・輝度値・焦点評価値のいずれの評価値も変化せず、カメラ動作量、被写体動作量が所定値以上となっていないかを判定する。いずれの評価値も変化しておらず、いずれの動作量も所定値以上となっていなければステップS419へと進む。前述のどれかの評価値が変化している、または、どれかの動作量が所定値以上となっていれば、被写体距離変化判定処理を終了する。 In step S418, none of the evaluation values of the face detection size, the brightness value, and the focus evaluation value changes, and it is determined whether the camera movement amount and the subject movement amount are equal to or more than the predetermined values. If none of the evaluation values has changed and none of the operating amounts is equal to or greater than a predetermined value, the process proceeds to step S419. If any of the above-mentioned evaluation values has changed, or if any of the movement amounts is equal to or greater than a predetermined value, the subject distance change determination process ends.

ステップS419では、顔サイズ変化回数・輝度値変化回数・焦点評価値変化回数・カメラ動作回数・被写体動作回数の全てを0にして被写体距離変化判定処理を終了する。 In step S419, the number of changes in face size, the number of changes in brightness value, the number of changes in focus evaluation value, the number of camera operations, and the number of subject operations are all set to 0, and the subject distance change determination process is completed.

図6は、図2のフローチャートにおけるステップS203の通常AF動作のサブルーチンを示す図である。 FIG. 6 is a diagram showing a subroutine of the normal AF operation in step S203 in the flowchart of FIG.

まず、ステップS501では、顔検出モジュール123で顔検出、もしくは物体検出モジュール124により被写体が検出されたか否かを判定し、被写体が検出されていればステップS503へと進み、検出されていなければステップS502へと進む。 First, in step S501, it is determined whether or not the face is detected by the face detection module 123 or the subject is detected by the object detection module 124, and if the subject is detected, the process proceeds to step S503, and if not, the step S503 is performed. Proceed to S502.

ステップS503では、顔検出モジュール123、もしくは物体検出モジュール124で検出した被写***置・サイズなどの情報を取得して、最新の被写体検出位置にAF枠を設定する。ここで、被写体が検出されている場合のAF枠のサイズは、予め設定された所定のサイズにしてもよいし、検出サイズに基づいて決定してもよい。本実施形態では、被写体検出サイズに基づいて一つのAF枠を設定する。顔が検出されている場合のイメージは、ServoAFの場合と同様に図4(a)のようになる。物体が検出されている場合は、図4(c)のようになる。 In step S503, information such as the subject position / size detected by the face detection module 123 or the object detection module 124 is acquired, and the AF frame is set at the latest subject detection position. Here, the size of the AF frame when the subject is detected may be a predetermined size set in advance or may be determined based on the detection size. In this embodiment, one AF frame is set based on the subject detection size. The image when the face is detected is as shown in FIG. 4A as in the case of ServoAF. When an object is detected, the result is as shown in FIG. 4 (c).

ステップS502では、画面の中央領域などの所定位置にAF枠を設定してステップS504へと進む。ステップS504では、後述する図11のフローチャートに従ってフォーカスレンズ104のスキャンを行って、ステップS505へと進む。 In step S502, the AF frame is set at a predetermined position such as the center area of the screen, and the process proceeds to step S504. In step S504, the focus lens 104 is scanned according to the flowchart of FIG. 11 described later, and the process proceeds to step S505.

ステップS505では、後述する図12のフローチャートに従って合焦判定を行って、ステップS506へと進む。 In step S505, focusing determination is performed according to the flowchart of FIG. 12 described later, and the process proceeds to step S506.

ステップS506では、ステップS505における合焦判定の結果が、OK判定であるか否かを判定し、OK判定であればステップS507へと進み、OK判定でなければステップS509へと進む。 In step S506, it is determined whether or not the result of the focusing determination in step S505 is an OK determination, and if it is an OK determination, the process proceeds to step S507, and if it is not an OK determination, the process proceeds to step S509.

ステップS507では、フォーカスレンズ104をステップS504でのスキャンで検出したピーク位置へ移させしてステップS508へと進む。ステップS508では、ピーク検出フラグ及び合焦フラグをTRUEにして、距離変化フラグをFALSEにして通常AF動作を終了し、図2のステップS204へと進む。 In step S507, the focus lens 104 is moved to the peak position detected by the scan in step S504, and the process proceeds to step S508. In step S508, the peak detection flag and the focusing flag are set to TRUE, the distance change flag is set to FALSE, the normal AF operation is terminated, and the process proceeds to step S204 of FIG.

ステップS509では、フォーカスレンズ104を予め設定している位置(定点)へと移動させてステップS510へと進む。ここで、定点は被写体の存在確率の高い距離に設定する。顔が検出されていれば、顔サイズから人物の距離を推定し、推定した距離に設定してもよい。ステップS510では、ピーク検出フラグ及び合焦フラグ、さらに距離変化フラグをFALSEにして通常AF動作を終了する。 In step S509, the focus lens 104 is moved to a preset position (fixed point), and the process proceeds to step S510. Here, the fixed point is set to a distance with a high probability of existence of the subject. If a face is detected, the distance of the person may be estimated from the face size and set to the estimated distance. In step S510, the peak detection flag, the focusing flag, and the distance change flag are set to FALSE to end the normal AF operation.

図7は、図3のフローチャートにおけるステップS311のServo中AF動作のサブルーチンを示す図である。 FIG. 7 is a diagram showing a subroutine of AF operation during Servo in step S311 in the flowchart of FIG.

まず、ステップS601では、現在の時刻と、次回のスキャン(後述するステップS610のスキャン)までの時間と、次回のスキャンにかかる時間とから、次回のスキャンにおいてフォーカスレンズ104の位置がスキャン範囲の中心に位置するときの時刻(予測時刻)を算出して、PreTimeとする。 First, in step S601, the position of the focus lens 104 is the center of the scan range in the next scan based on the current time, the time until the next scan (the scan in step S610 described later), and the time required for the next scan. The time (estimated time) when the lens is located in is calculated and used as PreTime.

ステップS602では、後述する図8のフローチャートに従って予測可能判定を行って、ステップS603へと進む。 In step S602, a predictable determination is made according to the flowchart of FIG. 8 described later, and the process proceeds to step S603.

ステップS603では、ステップS602の予測可能判定における予測可能判定結果がOK判定であるか否かを判定し、OK判定であればステップS604へと進み、OK判定でなければステップS605へと進む。 In step S603, it is determined whether or not the predictable determination result in the predictable determination in step S602 is an OK determination. If the determination is OK, the process proceeds to step S604, and if the determination is not OK, the process proceeds to step S605.

ステップS604では、後述する図9のフローチャートに従って被写***置予測処理を行って、ステップS607へと進む。 In step S604, subject position prediction processing is performed according to the flowchart of FIG. 9 described later, and the process proceeds to step S607.

ステップS605では、後述する過去の動体予測用のデータScanTime[0]〜ScanTime[i-1]及びHokanPeak[0]〜HokanPeak[i-1]をクリアし、さらに連続して予測可能判定となった回数を示すiを0にしてステップS606へと進む。ステップS606では、フォーカスレンズ104の現在位置をスキャン中心位置に設定して、ステップS607へと進む。 In step S605, the data ScanTime [0] to ScanTime [i-1] and HokanPeak [0] to HokanPeak [i-1] for past motion prediction, which will be described later, are cleared, and the predictable determination is made continuously. The i indicating the number of times is set to 0, and the process proceeds to step S606. In step S606, the current position of the focus lens 104 is set to the scan center position, and the process proceeds to step S607.

ステップS607では、合焦フラグがTRUEか否かを判定し、合焦フラグがTRUEであればステップS608へと進み、合焦フラグがFALSEであればステップS609へと進む。ステップS608では、スキャン範囲を所定範囲に設定してステップS610へと進む。ステップS609では、ステップS608で設定する所定範囲よりも広い範囲にスキャン範囲を設定してステップS610へと進む。 In step S607, it is determined whether or not the focusing flag is TRUE, and if the focusing flag is TRUE, the process proceeds to step S608, and if the focusing flag is FALSE, the process proceeds to step S609. In step S608, the scan range is set to a predetermined range and the process proceeds to step S610. In step S609, the scan range is set in a range wider than the predetermined range set in step S608, and the process proceeds to step S610.

ステップS610では、後述する図11のフローチャートに従ってスキャンを行って、ステップS611へと進む。 In step S610, scanning is performed according to the flowchart of FIG. 11 described later, and the process proceeds to step S611.

ステップS611では、後述する図12のフローチャートに従って合焦判定を行って、ステップS612へと進む。 In step S611, focusing determination is performed according to the flowchart of FIG. 12 described later, and the process proceeds to step S612.

ステップS612では、物体検出モジュール124により被写体が検出されたか否かを判定する。被写体が検出されていれば複数のAF枠を生成しているので、ステップS613において後述する図17に従って合焦枠の選択を行う。 In step S612, it is determined whether or not the object is detected by the object detection module 124. If the subject is detected, a plurality of AF frames are generated. Therefore, in step S613, the focusing frame is selected according to FIG. 17 described later.

ステップS614では、ステップS611において判定した合焦判定結果がOK判定か否かを判定し、OK判定であればステップS615へと進み、OK判定でなければステップS627へと進む。 In step S614, it is determined whether or not the focusing determination result determined in step S611 is OK determination, and if it is OK determination, the process proceeds to step S615, and if it is not OK determination, the process proceeds to step S627.

ステップS615では、合焦フラグをTRUEにしてステップS616へと進む。ステップS616では、連続して合焦判定がOK判定でなかった回数を示すNGcountを0にしてステップS617へと進む。 In step S615, the focusing flag is set to TRUE and the process proceeds to step S616. In step S616, the NG count indicating the number of times that the focusing determination is not OK is set to 0 and the process proceeds to step S617.

ステップS617では、ステップS610におけるスキャン結果(ピーク位置)とスキャン中心位置の差が所定値より小さいか否かを判定し、所定値より小さければステップS618へと進み、そうでなければステップS621へと進む。ステップS618では、連続してステップS610におけるピーク位置とスキャン中心位置の差が所定値より小さくなった回数を示すStCountに1を加えてステップS619へと進む。 In step S617, it is determined whether or not the difference between the scan result (peak position) and the scan center position in step S610 is smaller than the predetermined value, and if it is smaller than the predetermined value, the process proceeds to step S618, otherwise the process proceeds to step S621. move on. In step S618, 1 is continuously added to StCount indicating the number of times the difference between the peak position and the scan center position in step S610 becomes smaller than a predetermined value, and the process proceeds to step S619.

ステップS619では、StCountが閾値以上であるか否かを判定し、閾値以上であればステップS620へと進み、そうでなければステップS622へと進む。ステップS620では、被写体の距離変化がなくなったと判断して、距離変化フラグをFALSEにしてServo中AF動作を終了する。これにより、被写体距離が変化しない場合には、無駄にスキャンを繰り返すことなくフォーカスレンズを停止させることができる。 In step S619, it is determined whether or not StCount is equal to or higher than the threshold value, and if it is equal to or higher than the threshold value, the process proceeds to step S620, and if not, the process proceeds to step S622. In step S620, it is determined that the distance change of the subject has disappeared, the distance change flag is set to FALSE, and the AF operation during Servo is terminated. As a result, when the subject distance does not change, the focus lens can be stopped without unnecessary repeating scanning.

ステップS621では、StCountを0にクリアしてステップS622へと進む。ステップS622では、ステップS610における今回のスキャン中心位置に対する今回のピーク位置の方向と、前回のスキャン中心位置に対する前回のピーク位置の方向とが同方向であるか否かを判定する。そして、同方向であればステップS623へと進み、同方向でなければステップS624へと進む。 In step S621, StCount is cleared to 0 and the process proceeds to step S622. In step S622, it is determined whether or not the direction of the current peak position with respect to the current scan center position in step S610 and the direction of the previous peak position with respect to the previous scan center position are the same direction. Then, if they are in the same direction, the process proceeds to step S623, and if they are not in the same direction, the process proceeds to step S624.

ステップS623では、同方向移動フラグをTRUEにしてステップS625へと進む。ステップS624では、同方向移動フラグをFALSEにしてステップS625へと進む。 In step S623, the same direction movement flag is set to TRUE and the process proceeds to step S625. In step S624, the same direction movement flag is set to FALSE and the process proceeds to step S625.

ステップS625では、今回のスキャンにおいてフォーカスレンズ104の位置がスキャン範囲の中心に位置した時刻をScanTime[i]として、今回のスキャンにおけるピーク位置をHokanPeak[i]としてステップS626へと進む。ステップS626では、iに1を加えてServo中AF動作を終了する。 In step S625, the time when the position of the focus lens 104 is located at the center of the scan range in this scan is set as ScanTime [i], and the peak position in this scan is set as HokanPeak [i], and the process proceeds to step S626. In step S626, 1 is added to i to end the AF operation during Servo.

ステップS627では、合焦フラグをFALSEにしてステップS628へと進む。ステップS628ではNGCountに1を加えてステップS629へと進む。ステップS629では、NGCountが所定値よりも大きいか否かを判定し、所定値より大きければステップS630へと進み、そうでなければServo中AF動作を終了する。ステップS630では、ピーク検出フラグ及び距離変化フラグをFALSEにしてServo中AF動作を終了する。 In step S627, the focusing flag is set to FALSE and the process proceeds to step S628. In step S628, 1 is added to NGCount and the process proceeds to step S629. In step S629, it is determined whether or not NGCount is larger than the predetermined value, and if it is larger than the predetermined value, the process proceeds to step S630. If not, the AF operation during Servo is terminated. In step S630, the peak detection flag and the distance change flag are set to FALSE, and the AF operation during Servo is terminated.

図8は、図7のフローチャートにおけるステップS602の予測可能判定処理のサブルーチンを示すフローチャートである。 FIG. 8 is a flowchart showing a subroutine of the predictable determination process of step S602 in the flowchart of FIG. 7.

まず、ステップS701では、i=0か否かを判定し、0であればステップS705へと進み、そうでなければステップS702へと進む。 First, in step S701, it is determined whether or not i = 0, and if it is 0, the process proceeds to step S705, and if not, the process proceeds to step S702.

ステップS702では、PreTimeとScanTime[i-1]の差が所定時間よりも短いか否かを判定し、所定時間よりも短ければステップS703へと進み、そうでなければステップS705へと進む。これにより、前回のスキャンから今回のスキャンまでの間の時間が分かり、前回のスキャン結果を使用した予測の信頼性があるのか否かを判断することができる。 In step S702, it is determined whether or not the difference between PreTime and ScanTime [i-1] is shorter than the predetermined time, and if it is shorter than the predetermined time, the process proceeds to step S703, and if not, the process proceeds to step S705. This makes it possible to know the time between the previous scan and the current scan, and to determine whether or not the prediction using the results of the previous scan is reliable.

ステップS703では同方向移動フラグがTRUEか否かを判定し、同方向移動フラグがTRUEであればステップS704へと進み、同方向移動フラグがFALSEであればステップS705へと進む。これにより、被写体が遠近方向で同方向に移動していると判断したときにのみ予測を行うことで、誤測距の結果を使用することによる誤った予測を抑制することができる。 In step S703, it is determined whether or not the same direction movement flag is TRUE, and if the same direction movement flag is TRUE, the process proceeds to step S704, and if the same direction movement flag is FALSE, the process proceeds to step S705. As a result, it is possible to suppress erroneous prediction by using the result of erroneous distance measurement by performing prediction only when it is determined that the subject is moving in the same direction in the perspective direction.

ステップS704では、予測可能判定の結果をOK判定として、予測可能判定フローを終了する。ステップS705では、予測可能判定の結果をNG判定として、予測可能判定フローを終了する。 In step S704, the predictable determination result is regarded as an OK determination, and the predictable determination flow is terminated. In step S705, the predictable determination result is regarded as NG determination, and the predictable determination flow is terminated.

図9は、図7のフローチャートにおけるステップS604の被写***置予測処理のサブルーチンを示すフローチャートである。図10は、被写***置の予測を示す図である。 FIG. 9 is a flowchart showing a subroutine of the subject position prediction process in step S604 in the flowchart of FIG. 7. FIG. 10 is a diagram showing the prediction of the subject position.

まず、ステップS801では、iが2より小さいか否かを判定し、iが2より小さければステップS802へと進み、そうでなければステップS803へと進む。ステップS802では、スキャン中心位置を前回のスキャンのピーク位置に設定して被写***置予測フローを終了する。 First, in step S801, it is determined whether or not i is smaller than 2, and if i is smaller than 2, the process proceeds to step S802, and if not, the process proceeds to step S803. In step S802, the scan center position is set to the peak position of the previous scan, and the subject position prediction flow ends.

ステップS803では、i=2であるか否かを判定し、i=2であればステップS804へと進み、iが2より大きければステップS806へと進む。 In step S803, it is determined whether or not i = 2, and if i = 2, the process proceeds to step S804, and if i is larger than 2, the process proceeds to step S806.

ステップS804では、図10(a)に示すように、下記の動体予測式1を使って、(ScanTime[0],HokanPeak[0])と、(ScanTime[1],HokanPeak[1])の2点から、PreTime時の被写体の予測位置PrePositionを算出し、ステップS805へと進む。 In step S804, as shown in FIG. 10A, using the following motion prediction formula 1, (ScanTime [0], HokanPeak [0]) and (ScanTime [1], HokanPeak [1]) 2 From the point, the predicted position PrePosition of the subject at the time of PreTime is calculated, and the process proceeds to step S805.

<動体予測式1>
PrePosition=(PreTime−ScanTime[0])×(HokanPeak[1]−HokanPeak[0])
/(ScanTime[1]−ScanTime[0])+HokanPeak[0]
ステップS805では、ステップS804で算出した被写体の予測位置PrePositionをスキャン中心位置に設定して被写***置予測フローを終了する。
<Motion prediction formula 1>
PrePosition = (PreTime-ScanTime [0]) x (HokanPeak [1] -HokanPeak [0])
/ (ScanTime [1] -ScanTime [0]) + HokanPeak [0]
In step S805, the subject position prediction position PrePosition calculated in step S804 is set at the scan center position, and the subject position prediction flow ends.

ステップS806では、図10(b)に示すように、下記の動体予測式2を使って、(ScanTime[i-2],HokanPeak[i-2])、(ScanTime[i-1],HokanPeak[i-1])、(ScanTime[i],HokanPeak[i])の3点から、PreTime時の被写体の予測位置PrePositionを算出し、ステップS807へと進む。 In step S806, as shown in FIG. 10B, the following motion prediction formula 2 is used to (ScanTime [i-2], HokanPeak [i-2]), (ScanTime [i-1], HokanPeak [ From the three points i-1]) and (ScanTime [i], HokanPeak [i]), the predicted position PrePosition of the subject at the time of PreTime is calculated, and the process proceeds to step S807.

<動体予測式2>
PrePosition=(t3/t2)×{(t3−t2)×(t2×Pos1−t1×Pos2)
/t1/(t1−t2)+Pos2}+HokanPeak[i-2]
t1=ScanTime[i-1]−ScanTime[i-2]
t2=ScanTime[i]−ScanTime[i-2]
t3=PreTime−ScanTime[i-2]
Pos1=HokanPeak[i-1]−HokanPeak[i-2]
Pos2=HokanPeak[i]−HokanPeak[i-2]
ステップS807では、ステップS806で算出した被写体の予測位置PrePositionをスキャン中心位置に設定し、被写***置予測フローを終了する。
<Motion prediction formula 2>
PrePosition = (t3 / t2) x {(t3-t2) x (t2 x Pos1-t1 x Pos2)
/ t1 / (t1-t2) + Pos2} + HokanPeak [i-2]
t1 = ScanTime [i-1] -ScanTime [i-2]
t2 = ScanTime [i] -ScanTime [i-2]
t3 = PreTime-ScanTime [i-2]
Pos1 = HokanPeak [i-1] − HokanPeak [i-2]
Pos2 = HokanPeak [i] − HokanPeak [i-2]
In step S807, the subject prediction position PrePosition calculated in step S806 is set at the scan center position, and the subject position prediction flow ends.

図11は、図6のフローチャートにおけるステップS504、及び図7のフローチャートにおけるステップS610のスキャン動作のサブルーチンを示すフローチャートである。 FIG. 11 is a flowchart showing a subroutine of the scanning operation of step S504 in the flowchart of FIG. 6 and step S610 in the flowchart of FIG. 7.

まず、ステップS1001では、フォーカスレンズ104をスキャン開始位置に移動させる。スキャン開始位置は設定されたスキャン範囲(所定の移動範囲)の一端に設定される。ステップS1002では、撮影画面内に設定される焦点検出領域の焦点評価値(合焦状態の程度を示す評価値)とフォーカスレンズ104の位置をシステム制御部115に内蔵される図示しない演算メモリに記憶する。 First, in step S1001, the focus lens 104 is moved to the scan start position. The scan start position is set at one end of the set scan range (predetermined movement range). In step S1002, the focus evaluation value (evaluation value indicating the degree of focusing state) of the focus detection area set in the shooting screen and the position of the focus lens 104 are stored in a calculation memory (not shown) built in the system control unit 115. To do.

ステップS1003では、フォーカスレンズ104の位置がスキャン終了位置にあるか否かを判定し、終了位置であればステップS1005へ、そうでなければステップS1004へ進む。スキャン終了位置は、設定されたスキャン範囲の他端に設定される。ステップS1004ではフォーカスレンズ104を所定の方向へ所定量(所定の移動範囲)動かしてステップS1002へと戻る。ステップS1005では、ステップS1002で記憶した焦点評価値とそのレンズ位置とから、焦点評価値のピーク位置を算出する。 In step S1003, it is determined whether or not the position of the focus lens 104 is at the scan end position, and if it is the end position, the process proceeds to step S1005, otherwise the process proceeds to step S1004. The scan end position is set at the other end of the set scan range. In step S1004, the focus lens 104 is moved in a predetermined direction by a predetermined amount (a predetermined movement range) to return to step S1002. In step S1005, the peak position of the focus evaluation value is calculated from the focus evaluation value stored in step S1002 and the lens position thereof.

図12は、図6のフローチャートにおけるステップS505、及び図7のフローチャートにおけるステップS611の合焦判定処理のサブルーチンを示すフローチャートである。図13は、焦点評価値の変化を示す図である。 FIG. 12 is a flowchart showing the subroutines of the focusing determination process of step S505 in the flowchart of FIG. 6 and step S611 in the flowchart of FIG. 7. FIG. 13 is a diagram showing changes in the focus evaluation value.

焦点評価値は遠近競合などの特殊な場合を除けば、横軸にフォーカスレンズ位置、縦軸に焦点評価値をとるとその形は図13に示すような山状になる。そこで焦点評価値が山状になっているか否かを、焦点評価値の最大値と最小値の差、一定値(SlopeThr)以上の傾きで傾斜している部分の長さ、傾斜している部分の勾配から判断することにより、合焦判定を行うことができる。合焦判定における判定結果は、以下に示すようにOK、NGで出力される。 Except for special cases such as perspective competition, the focus evaluation value has a mountain shape as shown in FIG. 13 when the focus lens position is on the horizontal axis and the focus evaluation value is on the vertical axis. Therefore, whether or not the focus evaluation value has a mountain shape is determined by the difference between the maximum value and the minimum value of the focus evaluation value, the length of the portion inclined with an inclination of a certain value (SlopeThr) or more, and the inclined portion. Focusing can be determined by judging from the gradient of. The determination result in the focusing determination is output as OK or NG as shown below.

OK:焦点評価値のピーク位置から、被写体の焦点調節が可能である。 OK: The focus of the subject can be adjusted from the peak position of the focus evaluation value.

NG:被写体のコントラストが不十分、もしくはスキャンした距離範囲外の距離に被写体が位置する。 NG: The contrast of the subject is insufficient, or the subject is located at a distance outside the scanned distance range.

ここで図13に示すように、山の頂上(A点)から傾斜が続いていると認められる点をD点、E点とし、D点とE点の幅を山の幅L、A点とD点の焦点評価値の差SL1とA点とE点の焦点評価値の差SL2の和SL1+SL2をSLとする。 Here, as shown in FIG. 13, the points where the slope is recognized to continue from the top of the mountain (point A) are defined as points D and E, and the widths of points D and E are defined as the widths L and A of the mountain. Let SL1 + SL2, which is the sum of the difference SL1 of the focus evaluation values at point D and the difference SL2 between the focus evaluation values at points A and E, SL2.

まず、図12のステップS1101において、焦点評価値の最大値と最小値、及び最大値を与えるスキャンポイントioを求めてステップS1102へと進む。ステップS1102では、焦点評価値の山の幅を表す変数L、山の勾配を表す変数SLをともに零に初期化してステップS1103へと進む。ステップS1103では、最大値を与えるスキャンポイントioがスキャンを行った所定範囲における遠側端の位置か否かを調べ、遠側端位置でないならばステップS1104へ進み無限遠方向への単調減少を調べる。遠側端位置であったならば、この処理をスキップしステップS1105に進む。 First, in step S1101 of FIG. 12, the process proceeds to step S1102 in search of the maximum and minimum values of the focus evaluation value and the scan point io that gives the maximum value. In step S1102, the variable L representing the mountain width of the focal evaluation value and the variable SL representing the mountain gradient are both initialized to zero, and the process proceeds to step S1103. In step S1103, it is checked whether or not the scan point io giving the maximum value is the position of the far end in the predetermined range where scanning is performed, and if it is not the far end position, the process proceeds to step S1104 and the monotonous decrease in the infinity direction is checked. .. If it is at the far end position, this process is skipped and the process proceeds to step S1105.

ここで、ステップS1104における無限遠方向への単調減少を調べる処理について説明する。図14にそのフローチャートを示す。 Here, the process of checking the monotonous decrease in the infinity direction in step S1104 will be described. FIG. 14 shows the flowchart.

まず、ステップS1201において、カウンタ変数iをioに初期化してステップS1202へと進む。ステップS1202では、スキャンポイントiにおける焦点評価値の値d[i]と、iより1スキャンポイント分無限遠寄りのスキャンポイントi−1における焦点評価値の値d[i−1]の差を所定値SlopeThrと比較する。d[i]−d[i−1]≧SlopeThrであれば、無限遠方向への単調減少が生じていると判断し、ステップS1203に進む。一方、d[i]−d[i−1]≧SlopeThrでなければ、無限遠方向への単調減少は生じていないと判断し、無限遠方向への単調減少をチェックする処理を終了する。 First, in step S1201, the counter variable i is initialized to io, and the process proceeds to step S1202. In step S1202, the difference between the focus evaluation value d [i] at the scan point i and the focus evaluation value d [i-1] at the scan point i-1 which is one scan point closer to infinity than i is determined. Compare with the value SlopeThr. If d [i] −d [i-1] ≧ SlopeThr, it is determined that a monotonous decrease in the infinity direction has occurred, and the process proceeds to step S1203. On the other hand, if d [i] −d [i-1] ≧ SlopeThr, it is determined that the monotonous decrease in the infinity direction has not occurred, and the process of checking the monotonous decrease in the infinity direction ends.

ステップS1203では、焦点評価値が一定値以上の傾きで傾斜している部分の長さ(山の幅)を表す変数L、単調減少区間における減少量を表す変数SLを以下の式に従い更新してステップS1204へと進む。 In step S1203, the variable L representing the length (mountain width) of the portion where the focus evaluation value is inclined with an inclination of a certain value or more and the variable SL representing the amount of decrease in the monotonous decrease section are updated according to the following equations. The process proceeds to step S1204.

L=L+1
SL=SL+(d[i]−d[i−1])
ステップS1204では、i=i−1として、検出をする点を1スキャンポイント無限遠側に移してステップS1205へと進む。ステップS1205では、カウンタiがスキャンを行った所定範囲における遠側端位置の値(=0)になったか否かを判定する。カウンタiの値が0、すなわち単調減少を検出する開始点がスキャンを行った所定範囲における遠側端位置に達したならば、無限遠方向への単調減少をチェックする処理を終了する。以上のようにしてi=ioから無限遠方向への単調減少をチェックする。
L = L + 1
SL = SL + (d [i] -d [i-1])
In step S1204, i = i-1, the point to be detected is moved to the infinity side of one scan point, and the process proceeds to step S1205. In step S1205, it is determined whether or not the counter i has reached the value (= 0) at the far end position in the predetermined range in which scanning has been performed. When the value of the counter i reaches 0, that is, the start point for detecting the monotonous decrease reaches the far end position in the predetermined range in which the scan is performed, the process of checking the monotonous decrease in the infinity direction ends. As described above, the monotonous decrease from i = io in the infinity direction is checked.

図12の説明に戻って、ステップS1105では、最大値を与えるスキャンポイントioがスキャンを行った所定範囲における至近端の位置か否かを判定し、至近端位置でないならばステップS1106へ進み至近端方向への単調減少を調べる。至近端位置であったならば、この処理をスキップしステップS1107に進む。 Returning to the description of FIG. 12, in step S1105, it is determined whether or not the scan point io giving the maximum value is the closest end position in the predetermined range where scanning is performed, and if it is not the closest end position, the process proceeds to step S1106. Examine the monotonous decrease toward the nearest end. If it is the closest end position, this process is skipped and the process proceeds to step S1107.

ここで、ステップS1106における至近端方向への単調減少を調べる処理について説明する。図15にそのフローチャートを示す。 Here, the process of checking the monotonous decrease in the nearest end direction in step S1106 will be described. FIG. 15 shows the flowchart.

まず、ステップS1301において、カウンタ変数iをioに初期化してステップS1302へと進む。ステップS1302では、スキャンポイントiにおける焦点評価値の値d[i]と、iより1スキャンポイント分至近端寄りのスキャンポイントi+1における焦点評価値の値d[i+1]の差を所定値SlopeThrと比較する。d[i]−d[i+1]≧SlopeThrであれば、至近端方向への単調減少が生じていると判断し、ステップS1303に進む。一方、d[i]−d[i+1]≧SlopeThrでなければ、至近端方向への単調減少は生じていないと判断し、至近端方向への単調減少をチェックする処理を終了する。 First, in step S1301, the counter variable i is initialized to io and the process proceeds to step S1302. In step S1302, the difference between the focus evaluation value d [i] at the scan point i and the focus evaluation value d [i + 1] at the scan point i + 1 that is one scan point closer to the i than i is set as the predetermined value SlopeThr. Compare. If d [i] −d [i + 1] ≧ SlopeThr, it is determined that a monotonous decrease in the closest end direction has occurred, and the process proceeds to step S1303. On the other hand, if d [i] −d [i + 1] ≧ SlopeThr, it is determined that the monotonous decrease in the nearest end direction has not occurred, and the process of checking the monotonous decrease in the nearest end direction ends.

ステップS1303では、焦点評価値が一定値以上の傾きで傾斜している部分の長さ(山の幅)を表す変数L、単調減少区間における減少量を表す変数SLを以下の式に従い更新してステップS1304へと進む。 In step S1303, the variable L representing the length (mountain width) of the portion where the focus evaluation value is inclined with an inclination of a certain value or more and the variable SL representing the amount of decrease in the monotonous decrease section are updated according to the following equations. The process proceeds to step S1304.

L=L+1
SL=SL+(d[i]−d[i+1])
ステップS1304では、i=i+1として、検出をする点を1スキャンポイント至近端側に移してステップS1305へと進む。ステップS1305では、カウンタiがスキャンを行った所定範囲における至近端位置の値(=N)になったか否かを判定する。カウンタiの値がN、すなわち単調減少を検出する開始点がスキャンを行った所定範囲における至近端位置に達したならば、至近端方向への単調減少をチェックする処理を終了する。以上のようにしてi=ioから至近端方向への単調減少をチェックする。
L = L + 1
SL = SL + (d [i] -d [i + 1])
In step S1304, with i = i + 1, the point to be detected is moved to the closest end side to one scan point, and the process proceeds to step S1305. In step S1305, it is determined whether or not the counter i has reached the value (= N) of the nearest end position in the predetermined range in which scanning has been performed. When the value of the counter i reaches N, that is, the start point for detecting the monotonous decrease reaches the nearest end position in the predetermined range in which the scan is performed, the process of checking the monotonous decrease in the nearest end direction ends. As described above, the monotonous decrease from i = io toward the nearest end is checked.

無限遠方向および至近端方向への単調減少をチェックする処理が終了したならば、得られた焦点評価値が山状になっているか否か、諸係数をそれぞれのしきい値と比較し、OK、NGの判定を行う。 After the process of checking the monotonous decrease in the infinity direction and the near end direction is completed, whether or not the obtained focus evaluation value is mountainous or not, and the coefficients are compared with each threshold value. Judge OK or NG.

ステップS1107において、焦点評価値の最大値を与えるスキャンポイントioがスキャンを行った所定範囲における至近端であり、かつ至近端スキャンポイントnにおける焦点評価値の値d[n]と、nより1スキャンポイント分無限遠寄りのスキャンポイントn−1における焦点評価値の値d[n−1]の差が、所定値SlopeThr以上であればステップS1111へ進み、そうでなければステップS1108へ進む。 In step S1107, the scan point io that gives the maximum value of the focus evaluation value is the closest end in the predetermined range in which the scan is performed, and the value d [n] of the focus evaluation value at the nearest end scan point n and n If the difference between the focal evaluation value values d [n-1] at the scan point n-1 that is closer to infinity by one scan point is equal to or greater than the predetermined value SlopeThr, the process proceeds to step S1111. If not, the process proceeds to step S1108.

ステップS1108では、焦点評価値の最大値を与えるスキャンポイントioがスキャンを行った所定範囲における遠側端であり、かつ遠側端スキャンポイント0における焦点評価値の値d[0]と、0より1スキャンポイント分至近端よりのスキャンポイント1における焦点評価値の値d[1]の差が、所定値SlopeThr以上であればステップS1111へ進み、そうでなければステップS1109へ進む。 In step S1108, the scan point io that gives the maximum value of the focus evaluation value is the far side end in the predetermined range where scanning is performed, and the focus evaluation value value d [0] at the far side end scan point 0 and 0 If the difference of the focus evaluation value d [1] at the scan point 1 from the nearest end by one scan point is equal to or greater than the predetermined value SlopeThr, the process proceeds to step S1111. If not, the process proceeds to step S1109.

ステップS1109では、一定値以上の傾きで傾斜している部分の長さLが所定値Lo以上であり、かつ傾斜している部分の傾斜の平均値SL/Lが所定値SLo/Lo以上であり、かつ焦点評価値の最大値と最小値の差が所定値以上であれば、ステップS1110へ進み、そうでなければステップS1111へ進む。 In step S1109, the length L of the portion inclined with an inclination of a certain value or more is a predetermined value Lo or more, and the average value SL / L of the inclination of the inclined portion is a predetermined value SLo / Lo or more. If the difference between the maximum value and the minimum value of the focus evaluation value is equal to or greater than a predetermined value, the process proceeds to step S1110, and if not, the process proceeds to step S1111.

ステップS1110では、得られた焦点評価値が山状となっていて、被写体の焦点調節が可能であるため判定結果をOKとしている。ステップS1111では、得られた焦点評価値が山状となっておらず、被写体の焦点調節が不可能であるため判定結果をNGとしている。また、複数のAF枠を設定している場合は設定したAF枠ごとに同様の判定を行う。 In step S1110, the obtained focus evaluation value has a mountain shape, and the focus of the subject can be adjusted, so that the determination result is OK. In step S1111, the obtained focus evaluation value is not mountain-shaped and the focus of the subject cannot be adjusted, so the determination result is NG. If a plurality of AF frames are set, the same determination is performed for each set AF frame.

以上のようにして、図6のフローチャートにおけるステップS505、及び図7のフローチャートにおけるステップS611の合焦判定を行う。 As described above, the focusing determination of step S505 in the flowchart of FIG. 6 and step S611 in the flowchart of FIG. 7 is performed.

次に、図16は、図2のフローチャートにおけるステップS208の撮影動作を示すサブルーチンである。 Next, FIG. 16 is a subroutine showing the shooting operation of step S208 in the flowchart of FIG.

まず、ステップS1501では、前述した図3のステップS315もしくはステップS316で設定された再スキャンFlgがTRUEであるか否かを判定する。再スキャンFlgがTRUEであるはS1502へ進み、TRUEでない場合はS1503へ進む。 First, in step S1501, it is determined whether or not the rescan Flg set in step S315 or step S316 of FIG. 3 described above is TRUE. If the rescan Flg is TRUE, the process proceeds to S1502, and if it is not TRUE, the process proceeds to S1503.

ステップS1502では、前述した図11のスキャンを実行する。このスキャンは、前述した図3のステップS309の条件を満たし、かつ被写体が動いた直後に撮影指示されたことを想定して最終的にピントを追い込めるよう実施する。すなわち被写体が動いたにもかかわらず前述した図3のステップS311が実行されないまま撮影されてしまうことを防ぐ。 In step S1502, the scan of FIG. 11 described above is executed. This scan is carried out so as to satisfy the condition of step S309 of FIG. 3 described above and to finally focus on the assumption that the shooting instruction is given immediately after the subject moves. That is, it is possible to prevent the subject from being photographed without executing step S311 in FIG. 3 even though the subject has moved.

次にステップS1503において被写体輝度を測定してステップS1504へと進む。ステップS1504では、ステップS1503で測定した被写体輝度に応じて撮像素子108への露光を行ってステップS1505へと進む。撮像素子面上に結像された像は光電変換されてアナログ信号となり、ステップS1505においてA/D変換部109へと送られ、撮像素子108の出力ノイズ除去や非線形処理などの前処理の後にデジタル信号に変換される。 Next, the subject brightness is measured in step S1503, and the process proceeds to step S1504. In step S1504, the image sensor 108 is exposed according to the subject brightness measured in step S1503, and the process proceeds to step S1505. The image formed on the surface of the image sensor is photoelectrically converted into an analog signal, which is sent to the A / D conversion unit 109 in step S1505, and is digitally processed after preprocessing such as output noise removal and non-linear processing of the image sensor 108. Converted to a signal.

ステップS1506では、A/D変換部109からの出力信号をWB処理部111と画像処理部110によりホワイトバランス調整し、適正な出力画像信号としてステップS1507へと進む。 In step S1506, the white balance of the output signal from the A / D conversion unit 109 is adjusted by the WB processing unit 111 and the image processing unit 110, and the process proceeds to step S1507 as an appropriate output image signal.

ステップS1507では、出力画像信号をフォーマット変換部112でJPEGフォーマット等へフォーマット変換を行い、DRAM113に一時的に記憶してステップS1508へと進む。ステップS1508では、DRAM113内のデータを画像記録部114においてカメラ内のメモリ、またはカメラに装着されたメモリカードなどの外部記憶媒体へと転送し記憶して撮影動作を終了する。 In step S1507, the format conversion unit 112 converts the output image signal into a JPEG format or the like, temporarily stores the output image signal in the DRAM 113, and proceeds to step S1508. In step S1508, the image recording unit 114 transfers the data in the DRAM 113 to a memory in the camera or an external storage medium such as a memory card mounted on the camera, stores the data, and ends the shooting operation.

次に、図17は、図7のフローチャートにおけるステップS613の合焦枠選択処理のサブルーチンを示すフローチャートである。 Next, FIG. 17 is a flowchart showing a subroutine of the focusing frame selection process in step S613 in the flowchart of FIG. 7.

まず、ステップS1701において、3×3枠中の中心のAF枠における輝度値変化が所定値以内であることと、図7のステップS611での合焦判定結果がOKか否かを判定する。ここで輝度変化が所定値以内であるか否かを判断するのは、スキャン中にAF枠内に輝度の異なる被写体の出入りがあった場合、所望の合焦位置が算出できない場合があるためである。ステップS1701で上記の条件を満たした場合はステップS1702へ進み、そうでなければS1703へ進む。 First, in step S1701, it is determined that the change in the brightness value in the central AF frame in the 3 × 3 frame is within a predetermined value, and whether or not the focusing determination result in step S611 in FIG. 7 is OK. Here, it is determined whether or not the brightness change is within a predetermined value because the desired focusing position may not be calculated if a subject having a different brightness moves in and out of the AF frame during scanning. is there. If the above condition is satisfied in step S1701, the process proceeds to step S1702, otherwise the process proceeds to S1703.

S1702では、中心のAF枠を選択し、このAF枠で得られたピーク位置を採用する。次にステップS1736ではステップS1704において後述する被写体の移動方向を検出するための情報として選択したAF枠のピーク位置を保存し、合焦枠選択を終了する。 In S1702, the central AF frame is selected, and the peak position obtained in this AF frame is adopted. Next, in step S1736, the peak position of the AF frame selected as information for detecting the moving direction of the subject described later in step S1704 is saved, and the focusing frame selection is completed.

ステップS1703では、スキャン中に物体検出モジュール124において検出された被写体が非検出状態になっているか否かを判定する。スキャン中に被写体が非検出状態になっていればステップS1723へ進み、そうでなければステップS1704へ進む。 In step S1703, it is determined whether or not the subject detected by the object detection module 124 during scanning is in the non-detection state. If the subject is in the non-detection state during scanning, the process proceeds to step S1723, otherwise the process proceeds to step S1704.

ステップS1704では、被写体の移動方向を判定する。本実施形態では、前述したステップS1736で保存した過去にスキャンして求めたピーク位置を使用する。このピーク位置のスキャン3回分(スキャンを複数回行う)を、SetPosition1(3回前)、SetPosition2(前々回)、SetPosition3(前回)として保存し、スキャンを実行し、ピーク位置を検出するごとに更新しておく構成とする。また、フォーカスレンズ位置の値が大きくなるほど被写体がデジタルカメラ100側へ近くなる構成とすると、ピーク位置が以下の条件式3を満たした場合に近方向(デジタルカメラ100へ近づく方向)へ移動したと判定する。 In step S1704, the moving direction of the subject is determined. In this embodiment, the peak position obtained by scanning in the past saved in step S1736 described above is used. The three scans of the peak position (performing multiple scans) are saved as SetPosition1 (three times before), SetPosition2 (two times before), and SetPosition3 (previous), and the scan is executed and updated every time the peak position is detected. It is configured to be kept. Further, assuming that the subject is closer to the digital camera 100 side as the value of the focus lens position becomes larger, it is said that the peak position moves in the near direction (direction approaching the digital camera 100) when the following conditional expression 3 is satisfied. judge.

SetPosition3>SetPosition2 かつ SetPosition2>SetPosition1 …(式3)
また、ピーク位置が以下条件式4を満たした場合に遠方向(デジタルカメラ100から遠ざかる方向)へ移動したと判定する。
SetPosition3> SetPosition2 and SetPosition2> SetPosition1… (Equation 3)
Further, when the peak position satisfies the following conditional expression 4, it is determined that the peak position has moved in the distant direction (the direction away from the digital camera 100).

SetPosition3<SetPosition2 かつ SetPosition2<SetPosition1 …(式4)
スキャン試行回数が3回未満、もしくはスキャン試行回数が3回以上であり上記の式3、式4のいずれも満たさなかった場合は移動方向が未検出の状態とする。
SetPosition3 <SetPosition2 and SetPosition2 <SetPosition1… (Equation 4)
If the number of scan attempts is less than 3 or the number of scan attempts is 3 or more and neither of the above equations 3 and 4 is satisfied, the moving direction is considered to be undetected.

ステップS1705では、被写体が近方向へ移動したか否かを判定する。S1705を満たした場合はステップS1706へ進み、満たさない場合はステップS1707へ進む。ステップS1706ではAF枠選択に必要な変数の初期化を行う。ここで後述するIndexをインクリメントしながら、設定した3×3全てのAF枠に対して合焦結果を判定していく。 In step S1705, it is determined whether or not the subject has moved in the near direction. If S1705 is satisfied, the process proceeds to step S1706, and if not satisfied, the process proceeds to step S1707. In step S1706, the variables required for AF frame selection are initialized. Here, while incrementing the Index described later, the focusing result is determined for all the set 3 × 3 AF frames.

ステップS1708では、参照しているAF枠の合焦判定がOKかつ、前回スキャンしたピーク位置(前回合焦した位置)に対して所定以内のピーク位置か否かを判定する。ここで前回のピーク位置に対して所定以内(所定深度以内)のピーク位置か否かを判定するのは被写体の出入りなどで異なる被写体や背景に対して誤ってピーク位置を算出した結果を使用しないためである。ステップS1708の条件を満たした場合はステップS1709へ進み、満たさなければステップS1711へ進む。 In step S1708, it is determined whether or not the in-focus determination of the referenced AF frame is OK and the peak position is within a predetermined range with respect to the previously scanned peak position (previously focused position). Here, to determine whether or not the peak position is within a predetermined range (within a predetermined depth) with respect to the previous peak position, the result of erroneously calculating the peak position for a different subject or background due to the entry and exit of the subject is not used. Because. If the condition of step S1708 is satisfied, the process proceeds to step S1709. If not, the process proceeds to step S1711.

ステップS1709では、今回参照しているAF枠のピーク位置がステップS1708からステップS1712のルーチンにおいて選択されているAF枠(以後SelectFrame)のピーク位置よりも近側であるか否かを判定する。ステップS1709を満たした場合はステップS1710に進み、S1709を満たさない場合はステップS1711へ進む。 In step S1709, it is determined whether or not the peak position of the AF frame referred to this time is closer to the peak position of the AF frame (hereinafter referred to as SelectFrame) selected in the routine of steps S1708 to S1712. If step S1709 is satisfied, the process proceeds to step S1710, and if S1709 is not satisfied, the process proceeds to step S1711.

ステップS1710では、今回参照しているAF枠を選択枠候補として保存する。ここでIdexは今回参照しているAF枠を表し、Indexで選択枠候補を表すSelectFrameを更新する構成とする。さらにステップS1710においてAF枠が選択できたことを示すフラグSelectFlgをTRUEにする。 In step S1710, the AF frame referred to this time is saved as a selection frame candidate. Here, Idex represents the AF frame referred to this time, and the SelectFrame representing the selection frame candidate by Index is updated. Further, in step S1710, the flag SelectFlg indicating that the AF frame has been selected is set to TRUE.

ステップS1711では、AF枠を参照するためのIndexをインクリメントする。ステップS1712ではAF枠を参照するためのIndexが設定されたAF枠数−1に達している、つまり全AF枠について選択判定されたか否かを判断する。ステップS1712を満たした場合は、ステップS1713へ進み、満たさない場合はS1708へ戻る。 In step S1711, the Index for referencing the AF frame is incremented. In step S1712, it is determined whether or not the index for referring to the AF frame has reached the set number of AF frames -1, that is, whether or not the selection determination has been made for all AF frames. If step S1712 is satisfied, the process proceeds to step S1713, and if not, the process returns to S1708.

ステップS1713では、前述したSelectFlgがFALSEであるか否かを判定する。ステップS1713を満たす場合はS1714へ進み、満たさない場合は処理を終了する。ステップS1714では焦点検出評価値の極大値が最も近側に算出されたAF枠を選択し、処理を終了する。 In step S1713, it is determined whether or not the above-mentioned SelectFlg is FALSE. If step S1713 is satisfied, the process proceeds to S1714, and if not satisfied, the process ends. In step S1714, the AF frame in which the maximum value of the focus detection evaluation value is calculated to be closest to the maximum value is selected, and the process ends.

ステップS1707では、被写体が遠方向へ移動したか否かを判定する。S1707を満たした場合はステップS1715へ進み、満たさない場合はステップS1723へ進む。ステップS1715ではAF枠選択に必要な変数の初期化を行う。ステップS1716では参照しているAF枠の合焦判定がOKかつ、前回スキャンしたピーク位置に対して所定以内のピーク位置か否かを判定する。ステップS1716の条件を満たした場合はステップS1717へ進み、満たさなければステップS1719へ進む。 In step S1707, it is determined whether or not the subject has moved in the distant direction. If S1707 is satisfied, the process proceeds to step S1715, and if not satisfied, the process proceeds to step S1723. In step S1715, the variables required for AF frame selection are initialized. In step S1716, it is determined whether or not the focusing determination of the referenced AF frame is OK and the peak position is within a predetermined range with respect to the peak position scanned last time. If the condition of step S1716 is satisfied, the process proceeds to step S1717, and if not, the process proceeds to step S1719.

ステップS1717では今回参照しているAF枠のピーク位置がステップS1716からステップS1720のルーチンにおいて選択されているSelectFrameのピーク位置よりも遠側であるか否かを判定する。ステップS1717を満たした場合はステップS1718に進み、S1717を満たさない場合はステップS1719へ進む。 In step S1717, it is determined whether or not the peak position of the AF frame referred to this time is farther from the peak position of the Select Frame selected in the routine of steps S1716 to S1720. If step S1717 is satisfied, the process proceeds to step S1718, and if S1717 is not satisfied, the process proceeds to step S1719.

ステップS1718では、ステップS1710と同様に、今回参照しているAF枠を選択枠候補として保存し、AF枠が選択できたことを示すフラグSelectFlgをTRUEにする。 In step S1718, as in step S1710, the AF frame referred to this time is saved as a selection frame candidate, and the flag SelectFlg indicating that the AF frame has been selected is set to TRUE.

ステップS1719では、AF枠を参照するためのIndexをインクリメントする。ステップ1720では、AF枠を参照するためのIndexが設定されたAF枠数−1に達しているか否かを判定する。ステップS1720を満たした場合は、ステップS1721へ進み、満たさない場合はS1716へ戻る。 In step S1719, the Index for referencing the AF frame is incremented. In step 1720, it is determined whether or not the Index for referring to the AF frame has reached the set number of AF frames-1. If step S1720 is satisfied, the process proceeds to step S1721, and if not, the process returns to S1716.

ステップS1721では、前述したSelectFlgがFALSEであるか否かを判定する。ステップS1721を満たす場合はS1722へ進み、満たさない場合は処理を終了する。ステップS1722では焦点検出評価値の極大値が最も遠側に算出されたAF枠を選択し、処理を終了する。 In step S1721, it is determined whether or not the above-mentioned SelectFlg is FALSE. If step S1721 is satisfied, the process proceeds to S1722, and if not satisfied, the process ends. In step S1722, the AF frame in which the maximum value of the focus detection evaluation value is calculated to the farthest side is selected, and the process ends.

ステップS1707において条件を満たさない場合は被写体の移動方向が検出されていないとしてステップS1723へ進む。ステップS1723ではAF枠選択に必要な変数の初期化を行う。ステップS1724では参照しているAF枠の合焦判定がOKか否かを判定する。ステップS1724の条件を満たした場合はステップS1725へ進み、満たさない場合はステップS1730へ進む。 If the condition is not satisfied in step S1707, it is assumed that the moving direction of the subject has not been detected, and the process proceeds to step S1723. In step S1723, the variables required for AF frame selection are initialized. In step S1724, it is determined whether or not the focusing determination of the referenced AF frame is OK. If the condition of step S1724 is satisfied, the process proceeds to step S1725, and if the condition is not satisfied, the process proceeds to step S1730.

ステップS1725では、前述した図7のステップS610におけるServo中AFのスキャンが2回以上実行されているか否かを判定する。ステップS1725の条件を満たした場合はS1726へ進み、満たさなければステップS1727へ進む。 In step S1725, it is determined whether or not the AF scan during Servo in step S610 of FIG. 7 described above is executed twice or more. If the condition of step S1725 is satisfied, the process proceeds to S1726, and if not, the process proceeds to step S1727.

ステップS1726では、前回スキャンしたピーク位置に対して所定以内のピーク位置か否かを判定する。ステップS1727では前述した図2のステップS203の通常AFにおいて算出したピーク位置に対して所定以内のピーク位置か否かを判定する。ステップS1726、もしくはステップS1727の条件を満たした場合はステップS1728へ進み、満たさなければステップS1730へ進む。 In step S1726, it is determined whether or not the peak position is within a predetermined range with respect to the peak position scanned last time. In step S1727, it is determined whether or not the peak position is within a predetermined range with respect to the peak position calculated in the normal AF of step S203 of FIG. 2 described above. If the conditions of step S1726 or step S1727 are satisfied, the process proceeds to step S1728, and if not satisfied, the process proceeds to step S1730.

ステップS1728では、今回参照しているAF枠のピーク位置がステップS1724からステップS1731のルーチンにおいて選択されているSelectFrameのピーク位置よりも前回スキャンしたピーク位置に近いか否かを判定する。ステップS1728を満たした場合はステップS1729に進み、S1728を満たさない場合はステップS1730へ進む。 In step S1728, it is determined whether or not the peak position of the AF frame referred to this time is closer to the peak position scanned last time than the peak position of the Select Frame selected in the routine of steps S1724 to S1731. If step S1728 is satisfied, the process proceeds to step S1729, and if S1728 is not satisfied, the process proceeds to step S1730.

ステップS1729では、ステップS1710と同様に今回参照しているAF枠を選択枠候補として保存し、AF枠が選択できたことを示すフラグSelectFlgをTRUEにする。ステップS1730では、AF枠を参照するためのIndexをインクリメントする。 In step S1729, the AF frame referred to this time is saved as a selection frame candidate as in step S1710, and the flag SelectFlg indicating that the AF frame has been selected is set to TRUE. In step S1730, the Index for referencing the AF frame is incremented.

ステップS1731では、AF枠を参照するためのIndexが設定されたAF枠数−1に達しているか否かを判定する。ステップS1731の条件を満たした場合は、ステップS1732へ進み、満たさない場合はS1724へ戻る。 In step S1731, it is determined whether or not the index for referring to the AF frame has reached the set number of AF frames-1. If the condition of step S1731 is satisfied, the process proceeds to step S1732, and if the condition is not satisfied, the process returns to S1724.

ステップS1732では、前述したSelectFlgがFALSEであるか否かを判定する。ステップS1732を満たす場合はS1733へ進み、満たさない場合は処理を終了する。ステップS1733では、前述したステップS1725同様にServo中AFのスキャンが2回以上実行されているか否かを判定する。ステップS1733の条件を満たした場合はステップS1734へ進み、満たさない場合はステップS1735へ進む。 In step S1732, it is determined whether or not the above-mentioned SelectFlg is FALSE. If step S1732 is satisfied, the process proceeds to S1733, and if not satisfied, the process ends. In step S1733, it is determined whether or not the AF scan during Servo is executed twice or more in the same manner as in step S1725 described above. If the condition of step S1733 is satisfied, the process proceeds to step S1734, and if the condition is not satisfied, the process proceeds to step S1735.

ステップS1734では、焦点検出評価値の極大値が最も前回スキャンしたピーク位置に近いピーク位置が算出されたAF枠を選択し、処理を終了する。ステップS1735では、焦点検出評価値の極大値が最も通常AFのピーク位置に近いピーク位置が算出されたAF枠を選択し、処理を終了する。 In step S1734, the AF frame in which the peak position where the maximum value of the focus detection evaluation value is closest to the peak position scanned last time is calculated is selected, and the process ends. In step S1735, the AF frame in which the peak position where the maximum value of the focus detection evaluation value is closest to the peak position of the normal AF is calculated is selected, and the process is terminated.

以上説明したように、本実施形態によれば、AF枠に対して別の被写体が入った、もしくは被写体がAF枠から外れてしまったなどの原因により、信頼性の低い合焦位置を求めてしまった場合に、 誤った合焦位置を採用しにくくする。これにより、被写体への追従不能を軽減させることができる。また、被写体が遠近方向に動いていないと判断した場合に、次に動くまでフォーカスレンズを停止させることにより、無駄なレンズ駆動を軽減させることができ、ライブ画像の見栄えの低下及び電池消耗を軽減させることができる。 As described above, according to the present embodiment, an unreliable focusing position is obtained due to a cause such as another subject entering the AF frame or the subject moving out of the AF frame. If it does, it will be difficult to adopt the wrong focusing position. As a result, it is possible to reduce the inability to follow the subject. In addition, when it is determined that the subject is not moving in the perspective direction, unnecessary lens driving can be reduced by stopping the focus lens until the next movement, which reduces the appearance of the live image and reduces battery consumption. Can be made to.

(他の実施形態)
また本発明は、上述の実施形態の1以上の機能を実現するプログラムを、ネットワーク又は記憶媒体を介してシステム又は装置に供給し、そのシステム又は装置のコンピュータにおける1つ以上のプロセッサーがプログラムを読出し実行する処理でも実現できる。また、1以上の機能を実現する回路(例えば、ASIC)によっても実現できる。
(Other embodiments)
The present invention also supplies a program that realizes one or more functions of the above-described embodiment to a system or device via a network or storage medium, and one or more processors in the computer of the system or device reads the program. It can also be realized by the processing to be executed. It can also be realized by a circuit (for example, ASIC) that realizes one or more functions.

発明は上記実施形態に制限されるものではなく、発明の精神及び範囲から離脱することなく、様々な変更及び変形が可能である。従って、発明の範囲を公にするために請求項を添付する。 The invention is not limited to the above embodiments, and various modifications and modifications can be made without departing from the spirit and scope of the invention. Therefore, a claim is attached to make the scope of the invention public.

101:撮影レンズ、102:絞り及びシャッター、103:AE処理部、104:フォーカスレンズ、105:AF処理部、108:撮像素子、109:A/D変換部、110:画像処理部、111:WB処理部、114:画像記録部、115:システム制御部、120:メインスイッチ、123:顔検出モジュール、124:物体検出部、125:角速度センサ部、130:レリーズボタン 101: Shooting lens, 102: Aperture and shutter, 103: AE processing unit, 104: Focus lens, 105: AF processing unit, 108: Image sensor, 109: A / D conversion unit, 110: Image processing unit, 111: WB Processing unit, 114: image recording unit, 115: system control unit, 120: main switch, 123: face detection module, 124: object detection unit, 125: angular velocity sensor unit, 130: release button

Claims (17)

被写体像を撮像する撮像素子と、
前記撮像素子から得られた画像信号を用いて合焦状態を検出する焦点検出手段と、
前記撮像素子の画面内に複数の焦点検出領域を設定する設定手段と、
撮影の前に、前記複数の焦点検出領域のうちの1つの焦点検出領域について、前記焦点検出手段による焦点検出を複数回行い、被写体の移動方向を検出する検出手段と、
前記検出手段により検出された被写体の移動方向に基づいて、前記複数の焦点検出領域のいずれを用いて焦点検出を行うかを選択する選択手段と、
を備えることを特徴とする撮像装置。
An image sensor that captures the subject image and
Focus detection means for detecting the in-focus state using the image signal obtained from the image sensor, and
A setting means for setting a plurality of focus detection regions in the screen of the image sensor, and
Prior to shooting, the focus detection area of one of the plurality of focus detection areas is subjected to focus detection by the focus detection means a plurality of times to detect the moving direction of the subject.
A selection means for selecting which of the plurality of focus detection regions is used for focus detection based on the moving direction of the subject detected by the detection means.
An imaging device characterized by comprising.
前記焦点検出手段は、前記画像信号のコントラストを示す焦点評価値を求め、前記焦点評価値の値に基づいて焦点を検出することを特徴とする請求項1に記載の撮像装置。 The imaging device according to claim 1, wherein the focus detecting means obtains a focus evaluation value indicating the contrast of the image signal and detects the focus based on the value of the focus evaluation value. 前記焦点検出手段は、撮影レンズに配置されたフォーカスレンズを所定の移動範囲についてスキャンさせながら、前記焦点評価値を求めることにより、焦点を検出することを特徴とする請求項2に記載の撮像装置。 The imaging device according to claim 2, wherein the focus detecting means detects a focus by obtaining a focus evaluation value while scanning a focus lens arranged on a photographing lens for a predetermined moving range. .. 前記検出手段は、前記複数の焦点検出領域のうちの中心に配置された焦点検出領域について、前記焦点検出手段による焦点検出を複数回行い、被写体の移動方向を検出することを特徴とする請求項1乃至3のいずれか1項に記載の撮像装置。 The detection means is characterized in that the focus detection region arranged at the center of the plurality of focus detection regions is subjected to the focus detection by the focus detection means a plurality of times to detect the moving direction of the subject. The imaging device according to any one of 1 to 3. 前記被写体を検出する被写体検出手段をさらに備え、前記検出手段は、前記被写体検出手段により検出された被写体について、前記焦点検出手段による焦点検出を複数回行い、被写体の移動方向を検出することを特徴とする請求項1乃至4のいずれか1項に記載の撮像装置。 A subject detecting means for detecting the subject is further provided, and the detecting means is characterized in that the subject detected by the subject detecting means is focused detected by the focus detecting means a plurality of times to detect the moving direction of the subject. The imaging device according to any one of claims 1 to 4. 前記検出手段は、前記1つの焦点検出領域における輝度変化が所定値以内である場合に、該1つの焦点検出領域について、前記焦点検出手段による焦点検出を複数回行い、被写体の移動方向を検出することを特徴とする請求項5に記載の撮像装置。 When the change in brightness in the one focus detection region is within a predetermined value, the detection means performs focus detection by the focus detection means a plurality of times in the one focus detection region to detect the moving direction of the subject. The imaging device according to claim 5, characterized in that. 前記1つの焦点検出領域についての前記被写体に対する合焦の程度が、前回合焦した位置に対して所定の深度に収まっている場合は、前記選択手段は、前記1つの焦点検出領域を、焦点検出の結果を採用する焦点検出領域として選択することを特徴とする請求項6に記載の撮像装置。 When the degree of focusing on the subject with respect to the one focus detection area is within a predetermined depth with respect to the previously focused position, the selection means focuses on the one focus detection area. The imaging apparatus according to claim 6, wherein the result of the above is selected as a focus detection region. 前記検出手段は、前記1つの焦点検出領域において前記被写体が前記被写体検出手段により検出され続けている場合に、該1つの焦点検出領域について、前記焦点検出手段による焦点検出を複数回行い、被写体の移動方向を検出することを特徴とする請求項5乃至7のいずれか1項に記載の撮像装置。 When the subject is continuously detected by the subject detection means in the one focus detection region, the detection means performs focus detection by the focus detection means a plurality of times for the one focus detection region, and the subject is subjected to the focus detection. The imaging apparatus according to any one of claims 5 to 7, wherein the moving direction is detected. 前記選択手段は、前記1つの焦点検出領域における輝度変化が所定値以内でない場合に、前記被写体の移動方向に前回の焦点検出における合焦位置から所定の深度に収まっている合焦位置が算出された焦点検出領域を、焦点検出の結果を採用する焦点検出領域として選択することを特徴とする請求項6に記載の撮像装置。 When the change in brightness in the one focus detection region is not within a predetermined value, the selection means calculates a focus position within a predetermined depth from the focus position in the previous focus detection in the moving direction of the subject. The imaging apparatus according to claim 6, wherein the focus detection region is selected as the focus detection region that adopts the result of the focus detection. 前記選択手段は、前記1つの焦点検出領域において前記被写体が前記被写体検出手段により検出され続けていない場合に、前記被写体の移動方向に前回の焦点検出における合焦位置から所定の深度に収まっている合焦位置が算出された焦点検出領域を、焦点検出の結果を採用する焦点検出領域として選択することを特徴とする請求項6に記載の撮像装置。 When the subject is not continuously detected by the subject detection means in the one focus detection region, the selection means is within a predetermined depth from the focus position in the previous focus detection in the moving direction of the subject. The imaging apparatus according to claim 6, wherein the focus detection region in which the in-focus position is calculated is selected as the focus detection region in which the result of focus detection is adopted. 前記選択手段は、前記検出手段により被写体の移動方向が検出されていない場合に、前回の焦点検出における合焦位置に最も近い合焦位置が算出された焦点検出領域を、焦点検出の結果を採用する焦点検出領域として選択することを特徴とする請求項6に記載の撮像装置。 The selection means adopts the result of the focus detection in the focus detection region in which the focus position closest to the focus position in the previous focus detection is calculated when the moving direction of the subject is not detected by the detection means. The imaging apparatus according to claim 6, wherein the focus detection region is selected. 前記1つの焦点検出領域における焦点評価値の変化に応じて、ユーザーによる撮影の指示後に再度のスキャンを行わせる再スキャン手段をさらに備えることを特徴とする請求項3に記載の撮像装置。 The imaging device according to claim 3, further comprising a rescan means for performing a rescan after a user gives an instruction to take a picture in response to a change in the focus evaluation value in the one focus detection region. 前記1つの焦点検出領域における焦点評価値の変化は、合焦していた場合のフォーカスレンズの停止状態において検出されることを特徴とする請求項12に記載の撮像装置。 The imaging device according to claim 12, wherein the change in the focus evaluation value in the one focus detection region is detected in the stopped state of the focus lens when the focus is in focus. 前記1つの焦点検出領域は、前記複数の焦点検出領域の中心に配置された焦点検出領域であることを特徴とする請求項12または13に記載の撮像装置。 The imaging device according to claim 12 or 13, wherein the one focus detection region is a focus detection region arranged at the center of the plurality of focus detection regions. 被写体像を撮像する撮像素子と、前記撮像素子から得られた画像信号を用いて合焦状態を検出する焦点検出手段とを備える撮像装置を制御する方法であって、
前記撮像素子の画面内に複数の焦点検出領域を設定する設定工程と、
撮影の前に、前記複数の焦点検出領域のうちの1つの焦点検出領域について、前記焦点検出手段による焦点検出を複数回行い、被写体の移動方向を検出する検出工程と、
前記検出工程により検出された被写体の移動方向に基づいて、前記複数の焦点検出領域のいずれを用いて焦点検出を行うかを選択する選択工程と、
を有することを特徴とする撮像装置の制御方法。
A method of controlling an image pickup device including an image pickup device for capturing a subject image and a focus detection means for detecting a focusing state using an image signal obtained from the image pickup device.
A setting step of setting a plurality of focus detection regions in the screen of the image sensor, and
Prior to shooting, a detection step of detecting the moving direction of a subject by performing focus detection by the focus detecting means a plurality of times for one of the plurality of focus detection areas.
A selection step of selecting which of the plurality of focus detection regions is used for focus detection based on the moving direction of the subject detected by the detection step.
A method for controlling an imaging device, which comprises.
請求項15に記載の制御方法の各工程をコンピュータに実行させるためのプログラム。 A program for causing a computer to execute each step of the control method according to claim 15. 請求項15に記載の制御方法の各工程をコンピュータに実行させるためのプログラムを記憶したコンピュータが読み取り可能な記憶媒体。 A computer-readable storage medium that stores a program for causing a computer to execute each step of the control method according to claim 15.
JP2019046381A 2019-03-13 2019-03-13 IMAGING DEVICE AND CONTROL METHOD THEREOF, PROGRAM, STORAGE MEDIUM Active JP7249174B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2019046381A JP7249174B2 (en) 2019-03-13 2019-03-13 IMAGING DEVICE AND CONTROL METHOD THEREOF, PROGRAM, STORAGE MEDIUM

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2019046381A JP7249174B2 (en) 2019-03-13 2019-03-13 IMAGING DEVICE AND CONTROL METHOD THEREOF, PROGRAM, STORAGE MEDIUM

Publications (2)

Publication Number Publication Date
JP2020148907A true JP2020148907A (en) 2020-09-17
JP7249174B2 JP7249174B2 (en) 2023-03-30

Family

ID=72429594

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2019046381A Active JP7249174B2 (en) 2019-03-13 2019-03-13 IMAGING DEVICE AND CONTROL METHOD THEREOF, PROGRAM, STORAGE MEDIUM

Country Status (1)

Country Link
JP (1) JP7249174B2 (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012003029A (en) * 2010-06-17 2012-01-05 Olympus Corp Imaging device
JP2014160186A (en) * 2013-02-20 2014-09-04 Nikon Corp Focus detection device and imaging device
JP2016061797A (en) * 2014-09-12 2016-04-25 キヤノン株式会社 Focus adjustment device and control method therefor
JP2018087864A (en) * 2016-11-28 2018-06-07 オリンパス株式会社 Focus adjustment device, and focus adjustment device control method

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012003029A (en) * 2010-06-17 2012-01-05 Olympus Corp Imaging device
JP2014160186A (en) * 2013-02-20 2014-09-04 Nikon Corp Focus detection device and imaging device
JP2016061797A (en) * 2014-09-12 2016-04-25 キヤノン株式会社 Focus adjustment device and control method therefor
JP2018087864A (en) * 2016-11-28 2018-06-07 オリンパス株式会社 Focus adjustment device, and focus adjustment device control method

Also Published As

Publication number Publication date
JP7249174B2 (en) 2023-03-30

Similar Documents

Publication Publication Date Title
EP1956831B1 (en) Focus adjusting device, image pickup apparatus, and focus adjustment method
JP4429328B2 (en) Automatic focusing device, control method therefor, and imaging device
US8184192B2 (en) Imaging apparatus that performs an object region detection processing and method for controlling the imaging apparatus
JP5134476B2 (en) Imaging apparatus and control method thereof
US7634185B2 (en) Focusing device, image pickup apparatus, and control method
JP5004649B2 (en) Focus adjustment device, imaging device, and focus adjustment method
JP2007206433A (en) Focusing apparatus, imaging apparatus, and control method
JP2010015024A (en) Image pickup apparatus, control method thereof, program and storage medium
JP5787634B2 (en) Imaging device
KR100965320B1 (en) Automatic controlling device of a continuous auto focus and Automatic controlling method of the same
JP2014126612A (en) Imaging device and control method therefore
US9357124B2 (en) Focusing control device and controlling method of the same
JP2009271557A (en) Automatic focusing device, control method thereof, and imaging apparatus
US10313602B2 (en) Image capture apparatus and method for controlling the same
JP6234016B2 (en) Focus adjustment device, imaging device, and control method thereof
JP2015111226A (en) Subject tracking device and control method of the same, imaging device, program, and storage medium
JP7249174B2 (en) IMAGING DEVICE AND CONTROL METHOD THEREOF, PROGRAM, STORAGE MEDIUM
JP2005141068A (en) Automatic focusing device, automatic focusing method, and control program readable by computer
JP2014038288A (en) Focus adjustment device and control method therefor
JP2008197676A (en) Focusing device, imaging apparatus, and control method
JP2010008711A (en) Imaging apparatus, imaging method, and program
JP6335503B2 (en) Imaging apparatus, control method therefor, program, and storage medium
JP6624789B2 (en) Focus control device, control method thereof, control program, and imaging device
GB2595559A (en) Image capturing apparatus, control method therefor, program, and storage medium
JP2019032370A (en) Imaging device and control method thereof

Legal Events

Date Code Title Description
RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7421

Effective date: 20210103

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20210113

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20220311

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20221011

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20221012

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20221208

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20230317

R151 Written notification of patent or utility model registration

Ref document number: 7249174

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151