JP2013057839A - Focus detector and imaging apparatus - Google Patents

Focus detector and imaging apparatus Download PDF

Info

Publication number
JP2013057839A
JP2013057839A JP2011196729A JP2011196729A JP2013057839A JP 2013057839 A JP2013057839 A JP 2013057839A JP 2011196729 A JP2011196729 A JP 2011196729A JP 2011196729 A JP2011196729 A JP 2011196729A JP 2013057839 A JP2013057839 A JP 2013057839A
Authority
JP
Japan
Prior art keywords
focus
amount
shift
optical system
correlation amount
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2011196729A
Other languages
Japanese (ja)
Other versions
JP5923900B2 (en
Inventor
Akira Takemura
朗 竹村
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.)
Nikon Corp
Original Assignee
Nikon Corp
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 Nikon Corp filed Critical Nikon Corp
Priority to JP2011196729A priority Critical patent/JP5923900B2/en
Publication of JP2013057839A publication Critical patent/JP2013057839A/en
Application granted granted Critical
Publication of JP5923900B2 publication Critical patent/JP5923900B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

PROBLEM TO BE SOLVED: To provide a focus detector capable of properly performing focus detection of an optical system.SOLUTION: A focus detector includes: an imaging part 22 having imaging pixels for inputting an image signal corresponding to an image imaged by an optical system and a pair of pixel columns for focus detection receiving a pair of light fluxes subjected to the pupil division; a diaphragm 34 which restricts light flux made incident on the imaging part 22; a phase difference detection part for performing a shift operation for calculation of a correlation amount for all of a predetermined shift range, while one-dimensionally and relatively shifting a first data column and a second data column outputted from the pair of pixel columns for focus detection, respectively, and detecting a shift amount by which an extreme value of the correlation amount is obtained, thus detecting a focus state; and a setting part for setting an effective shift range for obtaining the extreme value of the correlation amount corresponding to a diaphragm value. The phase difference detection part detects the shift amount by which the extreme value of the correlation amount is obtained, by using the calculation result in the effective shift range among the shift calculation result performed for all of the predetermined shift range.

Description

本発明は、焦点検出装置および撮像装置に関する。   The present invention relates to a focus detection apparatus and an imaging apparatus.

従来より、撮像素子に一対の焦点検出用画素列を備え、一対の焦点検出用画素列から出力される第1データ列と第2データ列とを相対的にシフトさせながら、第1データ列と第2データ列との間の相関量を演算し、相関量の極値が得られるシフト量に基づいて、デフォーカス量を算出する焦点検出装置が知られている(たとえば、特許文献1)。   Conventionally, the imaging device includes a pair of focus detection pixel rows, and the first data row and the second data row output from the pair of focus detection pixel rows are relatively shifted. A focus detection device is known that calculates a defocus amount based on a shift amount by which a correlation amount with a second data string is calculated and an extreme value of the correlation amount is obtained (for example, Patent Document 1).

特開2011−90143号公報JP 2011-90143 A

しかしながら、従来技術では、所定のシフト範囲の全域について、第1データ列と第2データ列とを相対的にシフトさせながら相関量を演算し、所定のシフト範囲の全域にて演算した相関量に基づいて相関量の極値を算出し、算出した極値に対応するシフト量からデフォーカス量を算出するものであるため、光学系に設けられた絞りの絞り値によっては、偽合焦となってしまうという問題があった。   However, in the conventional technique, the correlation amount is calculated while relatively shifting the first data sequence and the second data sequence for the entire range of the predetermined shift range, and the correlation amount calculated over the entire range of the predetermined shift range is obtained. Since the extremum of the correlation amount is calculated based on this, and the defocus amount is calculated from the shift amount corresponding to the calculated extremum, depending on the aperture value of the aperture provided in the optical system, the false focus is obtained. There was a problem that.

本発明が解決しようとする課題は、光学系の焦点検出を適切に行なうことができる焦点検出装置を提供することにある。   The problem to be solved by the present invention is to provide a focus detection apparatus capable of appropriately performing focus detection of an optical system.

本発明は、以下の解決手段によって上記課題を解決する。なお、以下においては、本発明の実施形態を示す図面に対応する符号を付して説明するが、この符号は本発明の理解を容易にするためだけのものであって発明を限定する趣旨ではない。   The present invention solves the above problems by the following means. In the following description, the reference numerals corresponding to the drawings showing the embodiments of the present invention are used for explanation, but these reference numerals are only for facilitating the understanding of the present invention and are not intended to limit the invention. Absent.

[1]本発明に係る焦点検出装置は、焦点調節光学系(32)を備える光学系による像を撮像し、撮像した像に対応する画像信号を出力する撮像用画素(221)と、瞳分割された一対の光束を受光する一対の焦点検出用画素列(22a,22b,22c)とを有する撮像部(22)と、前記光学系を通過し、前記撮像部に入射する光束を制限する絞り(34)と、前記一対の焦点検出用画素列からそれぞれ出力された第1データ列および第2データ列を、一次元状に相対的にシフトさせながら、前記第1データ列と前記第2データ列との間の相関量を演算するシフト演算を、予め定められた所定のシフト範囲全域について行い、該シフト演算結果に基づいて、前記相関量の極値が得られるシフト量を検出することで、前記光学系の焦点状態を検出する位相差検出部(21)と、前記絞りによる絞り値に基づいて、前記絞り値に対応する、前記相関量の極値を得るための有効シフト範囲を設定する設定部(21)と、を備え、前記位相差検出部は、前記所定のシフト範囲全域について行ったシフト演算結果のうち、前記絞りの絞り値に応じた有効シフト範囲における演算結果を用いて、前記相関量の極値が得られるシフト量の検出を行うことを特徴とする。   [1] A focus detection apparatus according to the present invention captures an image by an optical system including a focus adjustment optical system (32), outputs an image signal corresponding to the captured image, and pupil division. An imaging unit (22) having a pair of focus detection pixel rows (22a, 22b, 22c) for receiving the pair of light fluxes, and an aperture that restricts the light flux that passes through the optical system and enters the imaging unit (34) and the first data row and the second data row while relatively shifting the first data row and the second data row respectively output from the pair of focus detection pixel rows in a one-dimensional manner. By performing a shift operation for calculating the correlation amount between the columns over a predetermined range of a predetermined shift range, and detecting a shift amount from which the extreme value of the correlation amount is obtained based on the shift calculation result , The focus state of the optical system A phase difference detection unit (21) to be output, and a setting unit (21) for setting an effective shift range for obtaining the extreme value of the correlation amount corresponding to the aperture value based on the aperture value by the aperture; The phase difference detection unit uses the calculation result in the effective shift range corresponding to the aperture value of the diaphragm among the shift calculation results performed for the entire predetermined shift range, and the extreme value of the correlation amount is The obtained shift amount is detected.

[2]本発明の焦点検出装置において、前記位相差検出部による焦点状態の検出結果に基づいて、前記焦点調節光学系(32)を光軸方向に駆動させることで、前記光学系の焦点調節を行なう焦点調節部(36)をさらに備え、前記位相差検出部(21)が、前記焦点調節部により前記焦点調節光学系を駆動させた結果、前記焦点調節光学系が、合焦位置を含む合焦位置近傍に位置していると判断できる場合には、前記所定のシフト範囲全域についてシフト演算を行なう代わりに、前記相関量の演算を、シフト量の絶対値が最も小さなものから開始し、前記シフト量の絶対値を順に大きくしていきながら前記相関量の演算および前記相関量の極値が得られるシフト量の検出を逐次行うとともに、前記相関量の極値が得られるシフト量が検出された場合には、前記相関量の極値が得られるシフト量が検出された時点で、前記相関量の演算を終了し、前記相関量の極値が得られるシフト量に基づいて、前記光学系の焦点状態の検出を行うように構成することができる。   [2] In the focus detection apparatus of the present invention, the focus adjustment of the optical system is driven by driving the focus adjustment optical system (32) in the optical axis direction based on the detection result of the focus state by the phase difference detection unit. And the phase difference detection unit (21) drives the focus adjustment optical system with the focus adjustment unit. As a result, the focus adjustment optical system includes a focus position. When it can be determined that the position is in the vicinity of the in-focus position, instead of performing a shift operation for the entire predetermined shift range, the calculation of the correlation amount is started from the smallest absolute value of the shift amount, While sequentially increasing the absolute value of the shift amount, the calculation of the correlation amount and the detection of the shift amount that obtains the extreme value of the correlation amount are performed sequentially, and the shift amount that obtains the extreme value of the correlation amount is detected. Is In this case, when a shift amount at which the extreme value of the correlation amount is obtained is detected, the calculation of the correlation amount is terminated, and based on the shift amount from which the extreme value of the correlation amount is obtained, the optical system The focus state can be detected.

[3]本発明の焦点検出装置において、前記位相差検出部(21)が、前記焦点調節部(36)により前記焦点調節光学系(32)を駆動させた結果、前記焦点調節光学系が、合焦位置を含む合焦位置近傍に位置していると判断できる場合には、前記設定部(21)により設定された有効シフト範囲において、前記相関量の演算および前記相関量の極値が得られるシフト量の検出を行うように構成することができる。   [3] In the focus detection apparatus of the present invention, as a result of the phase difference detection unit (21) driving the focus adjustment optical system (32) by the focus adjustment unit (36), the focus adjustment optical system is When it can be determined that the position is in the vicinity of the in-focus position including the in-focus position, the calculation of the correlation amount and the extreme value of the correlation amount are obtained in the effective shift range set by the setting unit (21). The shift amount can be detected.

[4]本発明の焦点検出装置において、前記設定部(21)は、前記絞り(34)による絞り値が大きいほど、前記有効シフト範囲を小さい範囲にするように構成することができる。   [4] In the focus detection apparatus of the present invention, the setting unit (21) can be configured such that the effective shift range is made smaller as the aperture value by the aperture (34) is larger.

[5]本発明の焦点検出装置において、前記撮像用画素(221)により出力された前記画像信号に基づいて、前記光学系による像のコントラストに関する評価値を算出することで、前記光学系の焦点状態を検出するコントラスト検出部(21)をさらに備えるように構成することができる。   [5] In the focus detection apparatus of the present invention, the evaluation value relating to the contrast of the image by the optical system is calculated based on the image signal output from the imaging pixel (221), thereby the focus of the optical system. It can comprise so that the contrast detection part (21) which detects a state may be further provided.

[6]本発明に係る撮像装置は、上記焦点検出装置を備えることを特徴とする。   [6] An imaging apparatus according to the present invention includes the focus detection apparatus.

本発明によれば、光学系の焦点検出を適切に行なうことができる。   According to the present invention, focus detection of an optical system can be performed appropriately.

図1は、本実施形態に係るカメラを示すブロック図である。FIG. 1 is a block diagram showing a camera according to the present embodiment. 図2は、図1に示す撮像素子の撮像面を示す正面図である。FIG. 2 is a front view showing an imaging surface of the imaging device shown in FIG. 図3は、図2のIII部を拡大して焦点検出画素222a,222bの配列を模式的に示す正面図である。FIG. 3 is a front view schematically showing the arrangement of the focus detection pixels 222a and 222b by enlarging the III part of FIG. 図4は、撮像画素221の一つを拡大して示す正面図である。FIG. 4 is an enlarged front view showing one of the imaging pixels 221. 図5(A)は、焦点検出画素222aの一つを拡大して示す正面図、図5(B)は、焦点検出画素222bの一つを拡大して示す正面図である。FIG. 5A is an enlarged front view showing one of the focus detection pixels 222a, and FIG. 5B is an enlarged front view showing one of the focus detection pixels 222b. 図6は、撮像画素221の一つを拡大して示す断面図である。FIG. 6 is an enlarged cross-sectional view showing one of the imaging pixels 221. 図7(A)は、焦点検出画素222aの一つを拡大して示す断面図、図7(B)は、焦点検出画素222bの一つを拡大して示す断面図である。FIG. 7A is an enlarged cross-sectional view showing one of the focus detection pixels 222a, and FIG. 7B is an enlarged cross-sectional view showing one of the focus detection pixels 222b. 図8は、図3のVIII-VIII線に沿う断面図である。8 is a cross-sectional view taken along line VIII-VIII in FIG. 図9は、本実施形態に係るカメラ1における位相差検出方式による像ずれ量の演算処理を示すフローチャート(その1)である。FIG. 9 is a flowchart (part 1) showing the calculation processing of the image shift amount by the phase difference detection method in the camera 1 according to the present embodiment. 図10は、本実施形態に係るカメラ1における位相差検出方式による像ずれ量の演算処理を示すフローチャート(その2)である。FIG. 10 is a flowchart (part 2) illustrating the image shift amount calculation processing by the phase difference detection method in the camera 1 according to the present embodiment. 図11(A)は、絞り値がF2.8である場合の射出瞳と焦点検出画素の測距瞳との関係の一例を示す図であり、図11(B)は、絞り値がF2.8である場合の第1データ列および第2データ列の信号強度の一例を示すグラフである。FIG. 11A is a diagram showing an example of the relationship between the exit pupil and the distance measurement pupil of the focus detection pixel when the aperture value is F2.8, and FIG. 8 is a graph showing an example of signal strengths of a first data string and a second data string when the number is 8. FIG. 図12(A)は、絞り値がF5.6である場合の射出瞳と焦点検出画素の測距瞳との関係の一例を示す図であり、図12(B)は、絞り値がF5.6である場合の第1データ列および第2データ列の信号強度の一例を示すグラフである。FIG. 12A is a diagram showing an example of the relationship between the exit pupil and the distance measurement pupil of the focus detection pixel when the aperture value is F5.6, and FIG. 6 is a graph showing an example of signal intensities of a first data string and a second data string in the case of 6. FIG.

以下、本発明の実施形態を図面に基づいて説明する。   Hereinafter, embodiments of the present invention will be described with reference to the drawings.

図1は、本発明の実施形態に係るデジタルカメラ1を示す要部構成図である。本実施形態のデジタルカメラ1(以下、単にカメラ1という。)は、カメラ本体2とレンズ鏡筒3から構成され、これらカメラ本体2とレンズ鏡筒3はマウント部4により着脱可能に結合されている。   FIG. 1 is a main part configuration diagram showing a digital camera 1 according to an embodiment of the present invention. A digital camera 1 according to the present embodiment (hereinafter simply referred to as a camera 1) includes a camera body 2 and a lens barrel 3, and the camera body 2 and the lens barrel 3 are detachably coupled by a mount unit 4. Yes.

レンズ鏡筒3は、カメラ本体2に着脱可能な交換レンズである。図1に示すように、レンズ鏡筒3には、レンズ31,32,33、および絞り34を含む撮影光学系が内蔵されている。   The lens barrel 3 is an interchangeable lens that can be attached to and detached from the camera body 2. As shown in FIG. 1, the lens barrel 3 includes a photographic optical system including lenses 31, 32, 33 and a diaphragm 34.

レンズ32は、フォーカスレンズであり、光軸L1方向に移動することで、撮影光学系の焦点距離を調節可能となっている。フォーカスレンズ32は、レンズ鏡筒3の光軸L1に沿って移動可能に設けられ、エンコーダ35によってその位置が検出されつつフォーカスレンズ駆動モータ36によってその位置が調節される。   The lens 32 is a focus lens, and can adjust the focal length of the photographing optical system by moving in the direction of the optical axis L1. The focus lens 32 is provided so as to be movable along the optical axis L1 of the lens barrel 3, and its position is adjusted by the focus lens drive motor 36 while its position is detected by the encoder 35.

このフォーカスレンズ32の光軸L1に沿う移動機構の具体的構成は特に限定されない。一例を挙げれば、レンズ鏡筒3に固定された固定筒に回転可能に回転筒を挿入し、この回転筒の内周面にヘリコイド溝(螺旋溝)を形成するとともに、フォーカスレンズ32を固定するレンズ枠の端部をヘリコイド溝に嵌合させる。そして、フォーカスレンズ駆動モータ36によって回転筒を回転させることで、レンズ枠に固定されたフォーカスレンズ32が光軸L1に沿って直進移動することになる。   The specific configuration of the moving mechanism along the optical axis L1 of the focus lens 32 is not particularly limited. For example, a rotating cylinder is rotatably inserted into a fixed cylinder fixed to the lens barrel 3, a helicoid groove (spiral groove) is formed on the inner peripheral surface of the rotating cylinder, and the focus lens 32 is fixed. The end of the lens frame is fitted into the helicoid groove. Then, by rotating the rotating cylinder by the focus lens drive motor 36, the focus lens 32 fixed to the lens frame moves straight along the optical axis L1.

上述したようにレンズ鏡筒3に対して回転筒を回転させることによりレンズ枠に固定されたフォーカスレンズ32は光軸L1方向に直進移動するが、その駆動源としてのフォーカスレンズ駆動モータ36がレンズ鏡筒3に設けられている。フォーカスレンズ駆動モータ36と回転筒とは、たとえば複数の歯車からなる変速機で連結され、フォーカスレンズ駆動モータ36の駆動軸を何れか一方向へ回転駆動すると所定のギヤ比で回転筒に伝達され、そして、回転筒が何れか一方向へ回転することで、レンズ枠に固定されたフォーカスレンズ32が光軸L1の何れかの方向へ直進移動することになる。なお、フォーカスレンズ駆動モータ36の駆動軸が逆方向に回転駆動すると、変速機を構成する複数の歯車も逆方向に回転し、フォーカスレンズ32は光軸L1の逆方向へ直進移動することになる。   As described above, the focus lens 32 fixed to the lens frame by rotating the rotary cylinder with respect to the lens barrel 3 moves straight in the direction of the optical axis L1, but the focus lens drive motor 36 as the drive source is the lens. The lens barrel 3 is provided. The focus lens drive motor 36 and the rotary cylinder are connected by a transmission composed of a plurality of gears, for example, and when the drive shaft of the focus lens drive motor 36 is driven to rotate in any one direction, it is transmitted to the rotary cylinder at a predetermined gear ratio. Then, when the rotating cylinder rotates in any one direction, the focus lens 32 fixed to the lens frame moves linearly in any direction of the optical axis L1. When the drive shaft of the focus lens drive motor 36 is rotated in the reverse direction, the plurality of gears constituting the transmission also rotate in the reverse direction, and the focus lens 32 moves straight in the reverse direction of the optical axis L1. .

フォーカスレンズ32の位置はエンコーダ35によって検出される。既述したとおり、フォーカスレンズ32の光軸L1方向の位置は回転筒の回転角に相関するので、たとえばレンズ鏡筒3に対する回転筒の相対的な回転角を検出すれば求めることができる。   The position of the focus lens 32 is detected by the encoder 35. As described above, the position of the focus lens 32 in the optical axis L1 direction correlates with the rotation angle of the rotating cylinder, and can be obtained by detecting the relative rotation angle of the rotating cylinder with respect to the lens barrel 3, for example.

本実施形態のエンコーダ35としては、回転筒の回転駆動に連結された回転円板の回転をフォトインタラプタなどの光センサで検出して、回転数に応じたパルス信号を出力するものや、固定筒と回転筒の何れか一方に設けられたフレキシブルプリント配線板の表面のエンコーダパターンに、何れか他方に設けられたブラシ接点を接触させ、回転筒の移動量(回転方向でも光軸方向の何れでもよい)に応じた接触位置の変化を検出回路で検出するものなどを用いることができる。   As the encoder 35 of this embodiment, an encoder that detects the rotation of a rotating disk coupled to the rotational drive of the rotating cylinder with an optical sensor such as a photo interrupter and outputs a pulse signal corresponding to the number of rotations, or a fixed cylinder And the contact point of the brush on the surface of the flexible printed wiring board provided on either one of the rotating cylinders, and the brush contact provided on the other, the amount of movement of the rotating cylinder (in either the rotational direction or the optical axis direction) A device that detects a change in the contact position according to the detection circuit using a detection circuit can be used.

フォーカスレンズ32は、上述した回転筒の回転によってカメラボディ側の端部(至近端ともいう)から被写体側の端部(無限端ともいう)までの間を光軸L1方向に移動することができる。ちなみに、エンコーダ35で検出されたフォーカスレンズ32の現在位置情報は、レンズ制御部37を介して後述するカメラ制御部21へ送出され、フォーカスレンズ駆動モータ36は、この情報に基づいて演算されたフォーカスレンズ32の駆動位置が、カメラ制御部21からレンズ制御部37を介して送出されることにより駆動する。   The focus lens 32 can move in the direction of the optical axis L1 from the end on the camera body side (also referred to as the closest end) to the end on the subject side (also referred to as the infinite end) by the rotation of the rotating cylinder described above. it can. Incidentally, the current position information of the focus lens 32 detected by the encoder 35 is sent to the camera control unit 21 to be described later via the lens control unit 37, and the focus lens drive motor 36 calculates the focus calculated based on this information. The driving position of the lens 32 is driven by being sent from the camera control unit 21 via the lens control unit 37.

絞り34は、上記撮影光学系を通過して撮像素子22に至る光束の光量を制限するとともにボケ量を調整するために、光軸L1を中心にした開口径が調節可能に構成されている。絞り34による開口径の調節は、たとえば自動露出モードにおいて演算された適切な開口径が、カメラ制御部21からレンズ制御部37を介して送出されることにより行われる。また、カメラ本体2に設けられた操作部28によるマニュアル操作により、設定された開口径がカメラ制御部21からレンズ制御部37に入力される。絞り34の開口径は図示しない絞り開口センサにより検出され、レンズ制御部37で現在の開口径が認識される。   The diaphragm 34 is configured such that the aperture diameter around the optical axis L1 can be adjusted in order to limit the amount of light flux that passes through the photographing optical system and reaches the image sensor 22 and to adjust the blur amount. The adjustment of the aperture diameter by the diaphragm 34 is performed, for example, by sending an appropriate aperture diameter calculated in the automatic exposure mode from the camera control unit 21 via the lens control unit 37. Further, the set aperture diameter is input from the camera control unit 21 to the lens control unit 37 by a manual operation by the operation unit 28 provided in the camera body 2. The aperture diameter of the aperture 34 is detected by an aperture sensor (not shown), and the lens controller 37 recognizes the current aperture diameter.

レンズ制御部37は、カメラ制御部21とマウント部4に設けられた電気信号接点部41により電気的に接続され、カメラ制御部21からの指令に基づき、フォーカスレンズ32の駆動、絞り34による開口径の調節などを行なうとともに、フォーカスレンズ32の位置、絞り34の開口径などのレンズ情報をカメラ制御部21に送信する。   The lens control unit 37 is electrically connected to the camera control unit 21 by an electric signal contact unit 41 provided on the mount unit 4, and is driven by the focus lens 32 and opened by the diaphragm 34 based on a command from the camera control unit 21. In addition to adjusting the aperture, lens information such as the position of the focus lens 32 and the aperture diameter of the diaphragm 34 is transmitted to the camera control unit 21.

一方、カメラ本体2には、上記撮影光学系からの光束L1を受光する撮像素子22が、撮影光学系の予定焦点面に設けられ、その前面にシャッター23が設けられている。撮像素子22はCCDやCMOSなどのデバイスから構成され、受光した光信号を電気信号に変換してカメラ制御部21に送出する。カメラ制御部21に送出された撮影画像情報は、逐次、液晶駆動回路25に送出されて観察光学系の電子ビューファインダ(EVF)26に表示されるとともに、操作部28に備えられたレリーズボタン(不図示)が全押しされた場合には、その撮影画像情報が、記録媒体であるメモリ24に記録される。メモリ24は着脱可能なカード型メモリや内蔵型メモリの何れをも用いることができる。なお、撮像素子22の撮像面の前方には、赤外光をカットするための赤外線カットフィルタ、および画像の折り返しノイズを防止するための光学的ローパスフィルタが配置されている。撮像素子22の構造の詳細は後述する。   On the other hand, the camera body 2 is provided with an imaging element 22 that receives the light beam L1 from the photographing optical system on a planned focal plane of the photographing optical system, and a shutter 23 is provided on the front surface thereof. The image sensor 22 is composed of a device such as a CCD or CMOS, converts the received optical signal into an electrical signal, and sends it to the camera control unit 21. The captured image information sent to the camera control unit 21 is sequentially sent to the liquid crystal drive circuit 25 and displayed on the electronic viewfinder (EVF) 26 of the observation optical system, and a release button ( When (not shown) is fully pressed, the photographed image information is recorded in the memory 24 that is a recording medium. As the memory 24, any of a removable card type memory and a built-in type memory can be used. An infrared cut filter for cutting infrared light and an optical low-pass filter for preventing image aliasing noise are disposed in front of the imaging surface of the image sensor 22. Details of the structure of the image sensor 22 will be described later.

カメラ本体2には、撮像素子22で撮像される像を観察するための観察光学系が設けられている。本実施形態の観察光学系は、液晶表示素子からなる電子ビューファインダ(EVF)26と、これを駆動する液晶駆動回路25と、接眼レンズ27とを備えている。液晶駆動回路25は、撮像素子22で撮像され、カメラ制御部21へ送出された撮影画像情報を読み込み、これに基づいて電子ビューファインダ26を駆動する。これにより、ユーザは、接眼レンズ27を通して現在の撮影画像を観察することができる。なお、光軸L2による上記観察光学系に代えて、または、これに加えて、液晶ディスプレイをカメラ本体2の背面等に設け、この液晶ディスプレイに撮影画像を表示させることもできる。   The camera body 2 is provided with an observation optical system for observing an image picked up by the image pickup device 22. The observation optical system of the present embodiment includes an electronic viewfinder (EVF) 26 composed of a liquid crystal display element, a liquid crystal driving circuit 25 that drives the electronic viewfinder (EVF) 26, and an eyepiece lens 27. The liquid crystal drive circuit 25 reads the captured image information captured by the image sensor 22 and sent to the camera control unit 21, and drives the electronic viewfinder 26 based on the read image information. Thereby, the user can observe the current captured image through the eyepiece lens 27. Note that, instead of or in addition to the observation optical system using the optical axis L2, a liquid crystal display may be provided on the back surface of the camera body 2, and a photographed image may be displayed on the liquid crystal display.

カメラ本体2にはカメラ制御部21が設けられている。カメラ制御部21は、マウント部4に設けられた電気信号接点部41によりレンズ制御部37と電気的に接続され、このレンズ制御部37からレンズ情報を受信するとともに、レンズ制御部37へデフォーカス量や絞り開口径などの情報を送信する。また、カメラ制御部21は、上述したように撮像素子22から画素出力を読み出すとともに、読み出した画素出力について、必要に応じて所定の情報処理を施すことにより画像情報を生成し、生成した画像情報を、電子ビューファインダ26の液晶駆動回路25やメモリ24に出力する。また、カメラ制御部21は、撮像素子22からの画像情報の補正やレンズ鏡筒3の焦点調節状態、絞り調節状態などを検出するなど、カメラ1全体の制御を司る。   A camera control unit 21 is provided in the camera body 2. The camera control unit 21 is electrically connected to the lens control unit 37 through an electric signal contact unit 41 provided in the mount unit 4, receives lens information from the lens control unit 37, and defocuses to the lens control unit 37. Send information such as volume and aperture diameter. The camera control unit 21 reads out the pixel output from the image sensor 22 as described above, generates image information by performing predetermined information processing on the read out pixel output as necessary, and generates the generated image information. Is output to the liquid crystal driving circuit 25 and the memory 24 of the electronic viewfinder 26. The camera control unit 21 controls the entire camera 1 such as correction of image information from the image sensor 22 and detection of a focus adjustment state and an aperture adjustment state of the lens barrel 3.

また、カメラ制御部21は、上記に加えて、撮像素子22から読み出した画素データに基づき、位相検出方式による撮影光学系の焦点状態の検出、およびコントラスト検出方式による撮影光学系の焦点状態の検出を行う。なお、具体的な焦点状態の検出方法については、後述する。   In addition to the above, the camera control unit 21 detects the focus state of the photographic optical system by the phase detection method and the focus state of the photographic optical system by the contrast detection method based on the pixel data read from the image sensor 22. I do. A specific focus state detection method will be described later.

操作部28は、シャッターレリーズボタンやユーザがカメラ1の各種動作モードを設定するための入力スイッチであり、オートフォーカスモード/マニュアルフォーカスモードの切換や、オートフォーカスモードの中でも、ワンショットモード/コンティニュアスモードの切換が行えるようになっている。ここで、ワンショットモードとは、一度調節したフォーカスレンズ32の位置を固定し、そのフォーカスレンズ位置で撮影するモードであるのに対し、コンティニュアスモードとは、フォーカスレンズ32の位置を固定することなく被写体に応じてフォーカスレンズ位置を調節するモードである。この操作部28により設定された各種モードはカメラ制御部21へ送出され、当該カメラ制御部21によりカメラ1全体の動作が制御される。また、シャッターレリーズボタンは、ボタンの半押しでONとなる第1スイッチSW1と、ボタンの全押しでONとなる第2スイッチSW2とを含む。   The operation unit 28 is a shutter release button or an input switch for the user to set various operation modes of the camera 1. Switching between the autofocus mode / manual focus mode and the one-shot mode / continuous mode is also possible in the autofocus mode. The as mode can be switched. Here, the one-shot mode is a mode in which the position of the focus lens 32 once adjusted is fixed and photographing is performed at the focus lens position, whereas the continuous mode is a mode in which the position of the focus lens 32 is fixed. In this mode, the focus lens position is adjusted according to the subject. Various modes set by the operation unit 28 are sent to the camera control unit 21, and the operation of the entire camera 1 is controlled by the camera control unit 21. The shutter release button includes a first switch SW1 that is turned on when the button is half-pressed and a second switch SW2 that is turned on when the button is fully pressed.

次に、本実施形態に係る撮像素子22について説明する。   Next, the image sensor 22 according to the present embodiment will be described.

図2は、撮像素子22の撮像面を示す正面図、図3は、図2のIII部を拡大して焦点検出画素222a,222bの配列を模式的に示す正面図である。   FIG. 2 is a front view showing the imaging surface of the image sensor 22, and FIG. 3 is a front view schematically showing the arrangement of the focus detection pixels 222a and 222b by enlarging the III part of FIG.

本実施形態の撮像素子22は、図3に示すように、複数の撮像画素221が、撮像面の平面上に二次元的に配列され、緑色の波長領域を透過するカラーフィルタを有する緑画素Gと、赤色の波長領域を透過するカラーフィルタを有する赤画素Rと、青色の波長領域を透過するカラーフィルタを有する青画素Bがいわゆるベイヤー配列(Bayer Arrangement)されたものである。すなわち、隣接する4つの画素群223(稠密正方格子配列)において一方の対角線上に2つの緑画素が配列され、他方の対角線上に赤画素と青画素が1つずつ配列されている。このベイヤー配列された画素群223を単位として、当該画素群223を撮像素子22の撮像面に二次元状に繰り返し配列することで撮像素子22が構成されている。   As shown in FIG. 3, the imaging element 22 of the present embodiment includes a green pixel G having a color filter in which a plurality of imaging pixels 221 are two-dimensionally arranged on the plane of the imaging surface and transmit a green wavelength region. A red pixel R having a color filter that transmits a red wavelength region and a blue pixel B having a color filter that transmits a blue wavelength region are arranged in a so-called Bayer Arrangement. That is, in four adjacent pixel groups 223 (dense square lattice arrangement), two green pixels are arranged on one diagonal line, and one red pixel and one blue pixel are arranged on the other diagonal line. The image sensor 22 is configured by repeatedly arranging the pixel group 223 on the imaging surface of the image sensor 22 in a two-dimensional manner with the Bayer array pixel group 223 as a unit.

なお、単位画素群223の配列は、図示する稠密正方格子以外にも、たとえば稠密六方格子配列にすることもできる。また、カラーフィルタの構成や配列はこれに限定されることはなく、補色フィルタ(緑:G、イエロー:Ye、マゼンタ:Mg,シアン:Cy)の配列を採用することもできる。   The unit pixel group 223 may be arranged in a dense hexagonal lattice arrangement other than the dense square lattice shown in the figure. Further, the configuration and arrangement of the color filters are not limited to this, and an arrangement of complementary color filters (green: G, yellow: Ye, magenta: Mg, cyan: Cy) can also be adopted.

図4は、撮像画素221の一つを拡大して示す正面図、図6は断面図である。一つの撮像画素221は、マイクロレンズ2211と、光電変換部2212と、図示しないカラーフィルタから構成され、図6の断面図に示すように、撮像素子22の半導体回路基板2213の表面に光電変換部2212が造り込まれ、その表面にマイクロレンズ2211が形成されている。光電変換部2212は、マイクロレンズ2211により撮影光学系の射出瞳(たとえばF1.0)を通過する撮像光束を受光する形状とされ、撮像光束を受光する。   FIG. 4 is an enlarged front view showing one of the imaging pixels 221, and FIG. 6 is a cross-sectional view. One imaging pixel 221 includes a micro lens 2211, a photoelectric conversion unit 2212, and a color filter (not shown), and a photoelectric conversion unit is formed on the surface of the semiconductor circuit substrate 2213 of the image sensor 22 as shown in the cross-sectional view of FIG. 2212 is built in and a microlens 2211 is formed on the surface. The photoelectric conversion unit 2212 is configured to receive an imaging light beam that passes through an exit pupil (for example, F1.0) of the photographing optical system by the micro lens 2211, and receives the imaging light beam.

また、撮像素子22の撮像面の中心、ならびに中心から左右対称位置の3箇所には、上述した撮像画素221に代えて焦点検出画素222a,222bが配列された焦点検出画素列22a,22b,22cが設けられている。そして、図3に示すように、一つの焦点検出画素列は、複数の焦点検出画素222aおよび222bが、互いに隣接して交互に、横一列(22a,22c,22c)に配列されて構成されている。本実施形態においては、焦点検出画素222aおよび222bは、ベイヤー配列された撮像画素221の緑画素Gと青画素Bとの位置にギャップを設けることなく密に配列されている。   In addition, focus detection pixel rows 22a, 22b, and 22c in which focus detection pixels 222a and 222b are arranged in place of the above-described imaging pixels 221 at the center of the image pickup surface of the image pickup element 22 and three positions that are symmetrical from the center. Is provided. As shown in FIG. 3, one focus detection pixel column includes a plurality of focus detection pixels 222 a and 222 b that are alternately arranged adjacent to each other in a horizontal row (22 a, 22 c, 22 c). Yes. In the present embodiment, the focus detection pixels 222a and 222b are densely arranged without providing a gap at the position of the green pixel G and the blue pixel B of the image pickup pixel 221 arranged in the Bayer array.

なお、図2に示す焦点検出画素列22a〜22cの位置は図示する位置にのみ限定されず、何れか一箇所、二箇所にすることもでき、また、四箇所以上の位置に配置することもできる。また、実際の焦点検出に際しては、複数配置された焦点検出画素列22a〜22cの中から、撮影者が操作部28を手動操作することにより所望の焦点検出画素列を、焦点検出位置として選択することもできる。   Note that the positions of the focus detection pixel rows 22a to 22c shown in FIG. 2 are not limited to the illustrated positions, and may be any one or two, or may be arranged at four or more positions. it can. In actual focus detection, the photographer manually operates the operation unit 28 from among a plurality of focus detection pixel rows 22a to 22c, and selects a desired focus detection pixel row as a focus detection position. You can also.

図5(A)は、焦点検出画素222aの一つを拡大して示す正面図、図7(A)は、焦点検出画素222aの断面図である。また、図5(B)は、焦点検出画素222bの一つを拡大して示す正面図、図7(B)は、焦点検出画素222bの断面図である。焦点検出画素222aは、図5(A)に示すように、マイクロレンズ2221aと、半円形状の光電変換部2222aとから構成され、図7(A)の断面図に示すように、撮像素子22の半導体回路基板2213の表面に光電変換部2222aが造り込まれ、その表面にマイクロレンズ2221aが形成されている。また、焦点検出画素222bは、図5(B)に示すように、マイクロレンズ2221bと、光電変換部2222bとから構成され、図7(B)の断面図に示すように、撮像素子22の半導体回路基板2213の表面に光電変換部2222bが造り込まれ、その表面にマイクロレンズ2221bが形成されている。そして、これら焦点検出画素222aおよび222bは、図3に示すように、互いに隣接して交互に、横一列に配列されることにより、図2に示す焦点検出画素列22a〜22cを構成する。   FIG. 5A is an enlarged front view showing one of the focus detection pixels 222a, and FIG. 7A is a cross-sectional view of the focus detection pixel 222a. FIG. 5B is an enlarged front view showing one of the focus detection pixels 222b, and FIG. 7B is a cross-sectional view of the focus detection pixel 222b. As shown in FIG. 5A, the focus detection pixel 222a includes a micro lens 2221a and a semicircular photoelectric conversion unit 2222a. As shown in the cross-sectional view of FIG. A photoelectric conversion portion 2222a is formed on the surface of the semiconductor circuit substrate 2213, and a micro lens 2221a is formed on the surface. The focus detection pixel 222b includes a micro lens 2221b and a photoelectric conversion unit 2222b as shown in FIG. 5B, and a semiconductor of the image sensor 22 as shown in a cross-sectional view of FIG. 7B. A photoelectric conversion unit 2222b is formed on the surface of the circuit board 2213, and a microlens 2221b is formed on the surface. Then, as shown in FIG. 3, these focus detection pixels 222a and 222b are alternately arranged adjacent to each other in a horizontal row, thereby forming focus detection pixel rows 22a to 22c shown in FIG.

なお、焦点検出画素222a,222bの光電変換部2222a,2222bは、マイクロレンズ2221a,2221bにより撮影光学系の射出瞳の所定の領域(たとえばF2.8)を通過する光束を受光するような形状とされる。また、焦点検出画素222a,222bにはカラーフィルタは設けられておらず、その分光特性は、光電変換を行うフォトダイオードの分光特性と、図示しない赤外カットフィルタの分光特性を総合したものとなっている。ただし、撮像画素221と同じカラーフィルタのうちの一つ、たとえば緑フィルタを備えるように構成することもできる。   The photoelectric conversion units 2222a and 2222b of the focus detection pixels 222a and 222b have such a shape that the microlenses 2221a and 2221b receive a light beam that passes through a predetermined region (eg, F2.8) of the exit pupil of the photographing optical system. Is done. Further, the focus detection pixels 222a and 222b are not provided with color filters, and their spectral characteristics are the total of the spectral characteristics of a photodiode that performs photoelectric conversion and the spectral characteristics of an infrared cut filter (not shown). ing. However, it may be configured to include one of the same color filters as the imaging pixel 221, for example, a green filter.

また、図5(A)、図5(B)に示す焦点検出画素222a,222bの光電変換部2222a,2222bは半円形状としたが、光電変換部2222a,2222bの形状はこれに限定されず、他の形状、たとえば、楕円形状、矩形状、多角形状とすることもできる。   In addition, although the photoelectric conversion units 2222a and 2222b of the focus detection pixels 222a and 222b illustrated in FIGS. 5A and 5B have a semicircular shape, the shapes of the photoelectric conversion units 2222a and 2222b are not limited thereto. Other shapes such as an elliptical shape, a rectangular shape, and a polygonal shape can also be used.

ここで、上述した焦点検出画素222a,222bの画素出力に基づいて撮影光学系の焦点状態を検出する、いわゆる位相差検出方式について説明する。   Here, a so-called phase difference detection method for detecting the focus state of the photographing optical system based on the pixel outputs of the focus detection pixels 222a and 222b described above will be described.

図8は、図3のVIII-VIII線に沿う断面図であり、撮影光軸L1近傍に配置され、互いに隣接する焦点検出画素222a−1,222b−1,222a−2,222b−2が、射出瞳350の測距瞳351,352から照射される光束AB1−1,AB2−1,AB1−2,AB2−2をそれぞれ受光していることを示している。なお、図8においては、複数の焦点検出画素222a,222bのうち、撮影光軸L1近傍に位置するもののみを例示して示したが、図8に示す焦点検出画素以外のその他の焦点検出画素についても、同様に、一対の測距瞳351,352から照射される光束をそれぞれ受光するように構成されている。   FIG. 8 is a cross-sectional view taken along the line VIII-VIII in FIG. 3. The focus detection pixels 222 a-1, 222 b-1, 222 a-2, and 222 b-2 that are arranged in the vicinity of the photographing optical axis L 1 and adjacent to each other are It shows that light beams AB1-1, AB2-1, AB1-2, and AB2-2 irradiated from the distance measuring pupils 351 and 352 of the exit pupil 350 are received. 8 illustrates only the focus detection pixels 222a and 222b that are located in the vicinity of the photographing optical axis L1, but other focus detection pixels other than the focus detection pixels illustrated in FIG. 8 are illustrated. In the same manner, the light beams emitted from the pair of distance measuring pupils 351 and 352 are respectively received.

ここで、射出瞳350とは、撮影光学系の予定焦点面に配置された焦点検出画素222a,222bのマイクロレンズ2221a,2221bの前方の距離Dの位置に設定された像である。距離Dは、マイクロレンズの曲率、屈折率、マイクロレンズと光電変換部との距離などに応じて一義的に決まる値であって、この距離Dを測距瞳距離と称する。また、測距瞳351,352とは、焦点検出画素222a,222bのマイクロレンズ2221a,2221bにより、それぞれ投影された光電変換部2222a,2222bの像をいう。   Here, the exit pupil 350 is an image set at a distance D in front of the microlenses 2221a and 2221b of the focus detection pixels 222a and 222b arranged on the planned focal plane of the photographing optical system. The distance D is a value uniquely determined according to the curvature and refractive index of the microlens, the distance between the microlens and the photoelectric conversion unit, and the distance D is referred to as a distance measurement pupil distance. The distance measurement pupils 351 and 352 are images of the photoelectric conversion units 2222a and 2222b respectively projected by the micro lenses 2221a and 2221b of the focus detection pixels 222a and 222b.

なお、図8において焦点検出画素222a−1,222b−1,222a−2,222b−2の配列方向は一対の測距瞳351,352の並び方向と一致している。   In FIG. 8, the arrangement direction of the focus detection pixels 222a-1, 222b-1, 222a-2, 222b-2 coincides with the arrangement direction of the pair of distance measuring pupils 351, 352.

また、図8に示すように、焦点検出画素222a−1,222b−1,222a−2,222b−2のマイクロレンズ2221a−1,2221b−1,2221a−2,2221b−2は、撮影光学系の予定焦点面近傍に配置されている。そして、マイクロレンズ2221a−1,2221b−1,2221a−2,2221b−2の背後に配置された各光電変換部2222a−1,2222b−1,2222a−2,2222b−2の形状が、各マイクロレンズ2221a−1,2221b−1,2221a−2,2221b−2から測距距離Dだけ離れた射出瞳350上に投影され、その投影形状は測距瞳351,352を形成する。   As shown in FIG. 8, the microlenses 2221a-1, 2221b-1, 2221a-2, and 2221b-2 of the focus detection pixels 222a-1, 222b-1, 222a-2, and 222b-2 are photographic optical systems. Near the planned focal plane. The shapes of the photoelectric conversion units 2222a-1, 2222b-1, 2222a-2, 2222b-2 arranged behind the micro lenses 2221a-1, 2221b-1, 2221a-2, 2221b-2 are the same as the micro lenses 2221a-1, 2221b-1, 2221a-2, 2221b-2. Projected onto the exit pupil 350 that is separated from the lenses 2221 a-1, 2221 b-1, 2221 a-2, and 2221 b-2 by a distance measurement distance D, and the projection shape forms distance measurement pupils 351 and 352.

すなわち、測距距離Dにある射出瞳350上で、各焦点検出画素の光電変換部の投影形状(測距瞳351,352)が一致するように、各焦点検出画素におけるマイクロレンズと光電変換部の相対的位置関係が定められ、それにより各焦点検出画素における光電変換部の投影方向が決定されている。   That is, the microlens and the photoelectric conversion unit in each focus detection pixel so that the projection shapes (distance measurement pupils 351 and 352) of the focus detection pixels coincide on the exit pupil 350 at the distance D. Is determined, and the projection direction of the photoelectric conversion unit in each focus detection pixel is thereby determined.

図8に示すように、焦点検出画素222a−1の光電変換部2222a−1は、測距瞳351を通過し、マイクロレンズ2221a−1に向う光束AB1−1によりマイクロレンズ2221a−1上に形成される像の強度に対応した信号を出力する。同様に、焦点検出画素222a−2の光電変換部2222a−2は測距瞳351を通過し、マイクロレンズ2221a−2に向う光束AB1−2によりマイクロレンズ2221a−2上に形成される像の強度に対応した信号を出力する。   As shown in FIG. 8, the photoelectric conversion unit 2222a-1 of the focus detection pixel 222a-1 is formed on the microlens 2221a-1 by the light beam AB1-1 that passes through the distance measuring pupil 351 and goes to the microlens 2221a-1. A signal corresponding to the intensity of the image to be output is output. Similarly, the photoelectric conversion unit 2222a-2 of the focus detection pixel 222a-2 passes through the distance measuring pupil 351, and the intensity of the image formed on the microlens 2221a-2 by the light beam AB1-2 toward the microlens 2221a-2. The signal corresponding to is output.

また、焦点検出画素222b−1の光電変換部2222b−1は測距瞳352を通過し、マイクロレンズ2221b−1に向う光束AB2−1によりマイクロレンズ2221b−1上に形成される像の強度に対応した信号を出力する。同様に、焦点検出画素222b−2の光電変換部2222b−2は測距瞳352を通過し、マイクロレンズ2221b−2に向う光束AB2−2によりマイクロレンズ2221b−2上に形成される像の強度に対応した信号を出力する。   Further, the photoelectric conversion unit 2222b-1 of the focus detection pixel 222b-1 passes through the distance measuring pupil 352, and the intensity of the image formed on the microlens 2221b-1 by the light beam AB2-1 directed to the microlens 2221b-1. Output the corresponding signal. Similarly, the photoelectric conversion unit 2222b-2 of the focus detection pixel 222b-2 passes through the distance measuring pupil 352, and the intensity of the image formed on the microlens 2221b-2 by the light beam AB2-2 toward the microlens 2221b-2. The signal corresponding to is output.

そして、上述した2種類の焦点検出画素222a,222bを、図3に示すように直線状に複数配置し、各焦点検出画素222a,222bの光電変換部2222a,2222bの出力を、測距瞳351と測距瞳352とのそれぞれに対応した出力グループにまとめることにより、測距瞳351と測距瞳352とのそれぞれを通過する焦点検出光束が焦点検出画素列上に形成する一対の像の強度分布に関するデータが得られる。そして、この強度分布データに対し、相関演算処理または位相差検出処理などの像ずれ検出演算処理を施すことにより、いわゆる位相差検出方式による像ずれ量を検出することができる。   Then, a plurality of the above-described two types of focus detection pixels 222a and 222b are arranged in a straight line as shown in FIG. 3, and the outputs of the photoelectric conversion units 2222a and 2222b of the focus detection pixels 222a and 222b are used as the distance measurement pupil 351. Of the pair of images formed on the focus detection pixel array by the focus detection light fluxes passing through each of the distance measurement pupil 351 and the distance measurement pupil 352. Data on the distribution is obtained. Then, by applying an image shift detection calculation process such as a correlation calculation process or a phase difference detection process to the intensity distribution data, an image shift amount by a so-called phase difference detection method can be detected.

そして、得られた像ずれ量に一対の測距瞳の重心間隔に応じた変換演算を施すことにより、予定焦点面に対する現在の焦点面(予定焦点面上のマイクロレンズアレイの位置に対応した焦点検出位置における焦点面をいう。)の偏差、すなわちデフォーカス量を求めることができる。   Then, by converting the obtained image shift amount according to the center-of-gravity distance between the pair of distance measuring pupils, the current focal plane with respect to the planned focal plane (the focal point corresponding to the position of the microlens array on the planned focal plane) The deviation of the focal plane at the detection position, that is, the defocus amount can be obtained.

なお、これら位相差検出方式による像ずれ量の演算と、これに基づくデフォーカス量の演算は、カメラ制御部21により実行される。   The calculation of the image shift amount by the phase difference detection method and the calculation of the defocus amount based on the calculation are performed by the camera control unit 21.

また、カメラ制御部21は、撮像素子22の撮像画素221の出力を読み出し、読み出した画素出力に基づき、焦点評価値の演算を行う。この焦点評価値は、たとえば撮像素子22の撮像画素221からの画像出力の高周波成分を、高周波透過フィルタを用いて抽出し、これを積算することで求めることができる。また、遮断周波数が異なる2つの高周波透過フィルタを用いて高周波成分を抽出し、それぞれを積算することでも求めることができる。   Further, the camera control unit 21 reads the output of the imaging pixel 221 of the imaging element 22 and calculates a focus evaluation value based on the read pixel output. This focus evaluation value can be obtained by, for example, extracting a high frequency component of an image output from the imaging pixel 221 of the imaging element 22 using a high frequency transmission filter and integrating the extracted high frequency component. It can also be obtained by extracting high-frequency components using two high-frequency transmission filters having different cutoff frequencies and integrating them.

そして、カメラ制御部21は、レンズ制御部37に制御信号を送出してフォーカスレンズ33を所定のサンプリング間隔(距離)で駆動させ、それぞれの位置における焦点評価値を求め、該焦点評価値が最大となるフォーカスレンズ33の位置を合焦位置として求める、コントラスト検出方式による焦点検出を実行する。なお、この合焦位置は、たとえば、フォーカスレンズ33を駆動させながら焦点評価値を算出した場合に、焦点評価値が、2回上昇した後、さらに、2回下降して推移した場合に、これらの焦点評価値を用いて、内挿法などの演算を行うことで求めることができる。   Then, the camera control unit 21 sends a control signal to the lens control unit 37 to drive the focus lens 33 at a predetermined sampling interval (distance) to obtain a focus evaluation value at each position, and the focus evaluation value is maximum. The focus detection by the contrast detection method is performed in which the position of the focus lens 33 is determined as the in-focus position. Note that this in-focus position is obtained when, for example, the focus evaluation value is calculated while the focus lens 33 is driven, and the focus evaluation value rises twice and then moves down twice. Can be obtained by performing an operation such as interpolation using the focus evaluation value.

次いで、本実施形態に係るカメラ1における位相差検出方式による像ずれ量の演算処理について、図9、図10に示すフローチャートを参照して、さらに詳細に説明する。なお、以下に説明する処理は、たとえば、カメラ1の電源がオンとされることにより開始する。   Next, the calculation process of the image shift amount by the phase difference detection method in the camera 1 according to the present embodiment will be described in more detail with reference to the flowcharts shown in FIGS. Note that the processing described below is started, for example, when the camera 1 is turned on.

まず、ステップS101では、カメラ制御部21により、レンズ制御部37を介して、絞り34の絞り値の取得が行われる。   First, in step S <b> 101, the aperture value of the aperture 34 is acquired by the camera control unit 21 via the lens control unit 37.

次いで、ステップS102では、カメラ制御部21により、ステップS101で取得した絞り値に基づいて、有効シフト範囲を決定するための処理が行なわれる。   Next, in step S102, the camera control unit 21 performs processing for determining an effective shift range based on the aperture value acquired in step S101.

ここで、図11、図12を参照して、絞り値と、一対のデータ列のずれ量との関係について説明する。図11(A)は、絞り値がF2.8である場合の射出瞳350と焦点検出画素の測距瞳351,352との関係の一例を示す図であり、図12(A)は、絞り値がF5.6である場合の射出瞳35と焦点検出画素の測距瞳351,352との関係の一例を示す図である。なお、図11(A)および図12(A)はともに、デフォーカス量がたとえば同じく1mmである場面(フォーカスレンズ32のレンズ位置が合焦位置まで像面移動である場面を例示している。また、図11(B)および図12(B)において、横軸は、焦点検出用画素列22a,22b,22cの各画素の画素位置を示している。   Here, with reference to FIG. 11 and FIG. 12, the relationship between the aperture value and the shift amount of the pair of data strings will be described. FIG. 11A is a diagram illustrating an example of the relationship between the exit pupil 350 and the focus detection pupils 351 and 352 when the aperture value is F2.8, and FIG. It is a figure which shows an example of the relationship between the exit pupil 35 in case a value is F5.6, and the ranging pupils 351 and 352 of a focus detection pixel. 11A and 12A exemplify a scene where the defocus amount is also 1 mm, for example (scene where the lens position of the focus lens 32 is moving to the in-focus position). In FIGS. 11B and 12B, the horizontal axis indicates the pixel position of each pixel in the focus detection pixel rows 22a, 22b, and 22c.

図11(A)に示す例においては、絞り値がF2.8であり、図12(A)に示す例と比較して、射出瞳350が大きいため、測距瞳351,352の大部分が射出瞳350に含まれている。そのため、図11(A)に示す例では、射出瞳350に含まれる測距瞳351,352の受光領域も大きく、測距瞳351の受光領域の重心位置351a(測距瞳351の受光領域の重心点の位置)と、測距瞳352の受光領域の重心位置352a(測距瞳352の受光領域の重心点の位置)との間の重心間距離Lも長くなる。その一方で、図12(A)に示す例においては、絞り値がF5.6であり、図11(A)に示す例と比較して、射出瞳350が小さいため、射出瞳350に含まれる測距瞳351,352の受光領域も小さい。そのため、図12(A)に示す例では、測距瞳351の受光領域の重心位置351aと測距瞳352の受光領域の重心位置352aとの間の重心間距離Lも短くなる。 In the example shown in FIG. 11A, the aperture value is F2.8, and the exit pupil 350 is larger than that in the example shown in FIG. 12A. Therefore, most of the distance measurement pupils 351 and 352 are large. It is included in the exit pupil 350. Therefore, in the example shown in FIG. 11A, the light receiving areas of the distance measuring pupils 351 and 352 included in the exit pupil 350 are also large, and the barycentric position 351a of the light receiving area of the distance measuring pupil 351 (the light receiving area of the distance measuring pupil 351). and position) of the center of gravity, also increases the distance between the centers of gravity L 1 between the gravity center position 352a of the light receiving area of the range-finding pupils 352 (position of the center of gravity of the light receiving area of the range-finding pupil 352). On the other hand, in the example shown in FIG. 12A, the aperture value is F5.6, which is smaller than that in the example shown in FIG. The light receiving areas of the distance measuring pupils 351 and 352 are also small. Therefore, in the example shown in FIG. 12 (A), also shortens the distance between the centers of gravity L 2 between the gravity center position 352a of the light receiving area of the gravity center position 351a and range-finding pupils 352 of the light-receiving region of the range-finding pupils 351.

また、図11(B)は、絞り値がF2.8である場合における、一対の焦点検出用画素列22a,22b,22cを構成する各焦点検出画素222a,222bから出力された第1データ列および第2データ列の信号強度の一例を示すグラフである。図11(B)に示す例においては、各焦点検出画素222aからの出力に基づくデータ列を第1データ列、各焦点検出画素222bからの出力に基づくデータ列を第2データ列として示している。   FIG. 11B shows the first data sequence output from the focus detection pixels 222a and 222b constituting the pair of focus detection pixel sequences 22a, 22b, and 22c when the aperture value is F2.8. It is a graph which shows an example of the signal strength of a 2nd data sequence. In the example shown in FIG. 11B, a data string based on the output from each focus detection pixel 222a is shown as a first data string, and a data string based on the output from each focus detection pixel 222b is shown as a second data string. .

同様に、図12(B)は、絞り値がF5.6である場合における、一対の焦点検出用画素列22a,22b,22cを構成する各焦点検出画素222a,222bから出力された第1データ列および第2データ列の信号強度の一例を示すグラフであり、図12(B)においても、各焦点検出画素222aからの出力に基づくデータ列を第1データ列、各焦点検出画素222bからの出力に基づくデータ列を第2データ列として示している。なお、図11(A)および図12(A)と同様に、図11(B)および図12(B)もともに、デフォーカス量がたとえば同じく1mmである場面を例示している。   Similarly, FIG. 12B shows the first data output from the focus detection pixels 222a and 222b constituting the pair of focus detection pixel rows 22a, 22b, and 22c when the aperture value is F5.6. FIG. 12 is a graph showing an example of signal intensities of a column and a second data column. In FIG. 12B as well, a data column based on an output from each focus detection pixel 222a is represented by a first data column and each focus detection pixel 222b A data string based on the output is shown as a second data string. 11 (A) and 12 (A), both FIG. 11 (B) and FIG. 12 (B) exemplify a scene where the defocus amount is 1 mm, for example.

図11(B)に示すように、絞り値がF2.8の場合では、図12(B)に示すように、絞り値がF5.6である場合と比べて、測距瞳351,352の受光領域の重心位置351a,352a間の重心間距離Lが長いため、第1データ列と第2データ列との間のずれ量Wは大きくなる。一方、図12(B)に示すように、絞り値がF5.6である場合では、図11(B)に示すように絞り値がF2.8である場合と比べて、測距瞳351,352の受光領域の重心位置351a,352a間の重心間距離Lが短いため、第1データ列と第2データ列との間のずれ量Wは小さくなる。このように、デフォーカス量が同じ場合でも、絞り値に応じて、第1データ列と第2データ列との間のずれ量が異なることとなる。 As shown in FIG. 11B, when the aperture value is F2.8, as shown in FIG. 12B, compared to the case where the aperture value is F5.6, the distance measurement pupils 351 and 352 are different. gravity position 351a of the light receiving region, because the long distance between the centers of gravity L 1 between 352a, deviation amount W 1 between the first and second data streams increases. On the other hand, as shown in FIG. 12B, when the aperture value is F5.6, as compared with the case where the aperture value is F2.8 as shown in FIG. 352 gravity position 351a of the light receiving region of is short distance between the centroids L 2 between 352a, deviation amount W 2 between the first and second data streams is reduced. As described above, even when the defocus amount is the same, the shift amount between the first data string and the second data string differs depending on the aperture value.

そして、この場合においては、図11(B)に示す例においては、第1データ列と、第2データ列とをシフトさせ、第1データ列と、第2データ列とがほぼ重なる状態とするためには、図12(B)に示す例と比較して、第1データ列と、第2データ列とをシフトさせるためのシフト量が比較的大きくなる。すなわち、デフォーカス量が同じ場合でも、絞り値が小さい場合(開放側である場合)には、絞り値が大きい場合(絞り込み側である場合)と比較して、第1データ列と、第2データ列とをシフトさせるためのシフト量を比較的大きくする必要がある。   In this case, in the example shown in FIG. 11B, the first data string and the second data string are shifted so that the first data string and the second data string substantially overlap each other. Therefore, compared with the example shown in FIG. 12B, the shift amount for shifting the first data string and the second data string becomes relatively large. That is, even when the defocus amount is the same, when the aperture value is small (when it is on the open side), the first data string and the second data string are compared with when the aperture value is large (when it is on the narrow side). It is necessary to relatively increase the shift amount for shifting the data string.

あるいは、逆に、絞り値が大きい場合(絞り込み側である場合)には、絞り値が小さい場合(開放側である場合)と比較して、第1データ列と、第2データ列とをシフトさせるためのシフト量を大きくした場合には、対応するデフォーカス量も大きくなってしまい、このような場合において、相関量の極小値が検出されたとしても、光学系の焦点状態を適切に検出できておらず、たとえば、偽合焦となってしまう可能性が高くなる。   Or, conversely, when the aperture value is large (when it is on the narrowing side), the first data sequence and the second data sequence are shifted compared to when the aperture value is small (when it is on the open side). When the shift amount for increasing the amount of shift is increased, the corresponding defocus amount also increases. In such a case, even if the minimum value of the correlation amount is detected, the focus state of the optical system is appropriately detected. For example, there is a high possibility of false focusing.

そのため、本実施形態では、このような問題を解消するために、絞り34の絞り値に応じて、第1データ列と第2データ列とをシフトさせながら、相関量の演算を行なう際における有効シフト範囲Snaを設定する。具体的には、下記式(1)に基づいて、有効シフト範囲Snaを設定する。
Sna=So×(k1/k2) ・・・(1)
なお、上記式(1)において、Soは、有効シフト範囲Snaを決定するための基準となる基準シフト範囲であり、たとえば、絞り値がF5.6、デフォーカス量が1mmである場合に、第1データ列と第2データ列とを相対的にシフトさせることで、第1データ列と第2データ列との間の相関量の極小値を得ることができるシフト範囲とすることができる。あるいは、Soは、たとえば、所定の絞り値において、デフォーカス量が5mmである場合に、第1データ列と第2データ列との相関量の極小値を得ることができるシフト範囲とすることもできる。また、上記式(1)において、k1は、相関量の極小値が得られるシフト量をデフォーカス量に変換するための変換係数(変換係数については後述する。)のうち、基準となるシフト範囲Soの絞り値に対応する変換係数であり、たとえば、基準となるシフト範囲Soが、絞り値がF2.8、デフォーカス量が1mmである場合に、相関量の極小値を得ることができるシフト範囲として設定されている場合には、k1は、絞り値F2.8に対応する変換係数となる。さらに、上記式(1)において、k2は、相関量の極小値が得られるシフト量をデフォーカス量に変換するための変換係数のうち、ステップS101で取得された絞り値に対応する変換係数である。
Therefore, in the present embodiment, in order to solve such a problem, it is effective when calculating the correlation amount while shifting the first data string and the second data string in accordance with the aperture value of the aperture 34. A shift range Sna is set. Specifically, the effective shift range Sna is set based on the following formula (1).
Sna = So × (k1 / k2) (1)
In the above formula (1), So is a reference shift range that is a reference for determining the effective shift range Sna. For example, when the aperture value is F5.6 and the defocus amount is 1 mm, By relatively shifting the one data string and the second data string, a shift range in which a minimum value of the correlation amount between the first data string and the second data string can be obtained can be obtained. Alternatively, So may be a shift range in which a minimum value of the correlation amount between the first data string and the second data string can be obtained when the defocus amount is 5 mm at a predetermined aperture value, for example. it can. In the above equation (1), k1 is a reference shift range among conversion coefficients (conversion coefficients will be described later) for converting a shift amount that provides a minimum value of the correlation amount into a defocus amount. A conversion coefficient corresponding to the aperture value of So, for example, a shift that can obtain a minimum value of the correlation amount when the reference shift range So is an aperture value of F2.8 and a defocus amount of 1 mm. When set as a range, k1 is a conversion coefficient corresponding to the aperture value F2.8. Further, in the above equation (1), k2 is a conversion coefficient corresponding to the aperture value obtained in step S101, among the conversion coefficients for converting the shift amount from which the minimum value of the correlation amount is obtained into the defocus amount. is there.

たとえば、基準シフト範囲Soが、絞り値がF5.6、デフォーカス量が1mmである場合に相関量の極小値を得ることができるシフト範囲であり、ステップS101で取得された絞り値がF2.8である場合において、絞り値F5.6における変換係数k1が、たとえば絞り値F2.8における変換係数k2の2倍の値となる場合には、上記式(1)に基づいて、有効シフト範囲Snaを、絞り値F5.6におけるシフト範囲Soの2倍の大きさの範囲として決定することができる。なお、Sna,Soはともに整数であり、本実施系形態では有効シフト範囲Snaを求める際に、So×(k1/k2)の小数部分を切り捨て、あるいは四捨五入等することにより、Snaを整数として算出する。   For example, the reference shift range So is a shift range in which the minimum value of the correlation amount can be obtained when the aperture value is F5.6 and the defocus amount is 1 mm, and the aperture value acquired in step S101 is F2. In the case of 8, when the conversion coefficient k1 at the aperture value F5.6 is, for example, twice the conversion coefficient k2 at the aperture value F2.8, the effective shift range is based on the above equation (1). Sna can be determined as a range twice as large as the shift range So at the aperture value F5.6. Note that Sna and So are both integers. In this embodiment, when the effective shift range Sna is obtained, the decimal part of So × (k1 / k2) is rounded down or rounded off to calculate Sna as an integer. To do.

なお、有効シフト範囲を決定する方法は、上述した方法に特に限定されず、たとえば、絞り値に応じた変換係数と絞り値とはほぼ線形の関係を有するため、シフト量をデフォーカス量に変換するための変換係数に代えて、絞り値をそのまま用いて、有効シフト範囲を決定してもよい。具体的には、下記式(2)に基づいて、有効シフト範囲Snaを決定してもよい。
Sna=So×(f1/f2) ・・・(2)
なお、上記式(2)において、f1は、基準シフト範囲Soにおける絞り値であり、f2は、ステップS101で取得された絞り値である。
Note that the method for determining the effective shift range is not particularly limited to the above-described method. For example, since the conversion coefficient corresponding to the aperture value and the aperture value have a substantially linear relationship, the shift amount is converted into the defocus amount. Instead of the conversion coefficient for this purpose, the effective shift range may be determined using the aperture value as it is. Specifically, the effective shift range Sna may be determined based on the following formula (2).
Sna = So × (f1 / f2) (2)
In the above equation (2), f1 is the aperture value in the reference shift range So, and f2 is the aperture value acquired in step S101.

次いで、ステップS103に進み、カメラ制御部21により、撮像素子22の焦点検出用画素列22a,22b,22cを構成する各焦点検出画素222a,222bから一対の像に対応した一対の像データ、すなわち、第1データ列および第2データ列の読み出しが行なわれる。   Next, the process proceeds to step S103, and a pair of image data corresponding to a pair of images from the focus detection pixels 222a and 222b constituting the focus detection pixel rows 22a, 22b, and 22c of the image sensor 22 by the camera control unit 21, that is, a pair of image data. The first data string and the second data string are read out.

次いで、ステップS104では、カメラ制御部21により、フォーカスレンズ32が、合焦位置を含む合焦位置近傍に位置すると判断できるか否かの判定が行なわれる。たとえば、撮影者により、操作部28に備えられたレリーズボタンの半押しが行なわれておらず、位相差検出方式による焦点検出の結果に基づくフォーカスレンズ32の合焦駆動が実行されていない場合など、フォーカスレンズ32が、合焦位置近傍に位置すると判断できない場合には、ステップS105に進む。一方、撮影者により、レリーズボタンの半押しが行なわれ、位相差検出方式による焦点検出の結果に基づくフォーカスレンズ32の合焦駆動が行われた場合など、フォーカスレンズ32が、合焦位置または合焦位置近傍に位置すると判断できる場合には、図10に示すステップS201に進む。   Next, in step S104, the camera control unit 21 determines whether or not it can be determined that the focus lens 32 is located in the vicinity of the in-focus position including the in-focus position. For example, when the photographer does not half-press the release button provided in the operation unit 28 and the focus lens 32 is not focused based on the result of focus detection by the phase difference detection method. If it cannot be determined that the focus lens 32 is located in the vicinity of the in-focus position, the process proceeds to step S105. On the other hand, when the photographer presses the release button halfway and the focus lens 32 is driven based on the result of focus detection by the phase difference detection method, the focus lens 32 moves to the in-focus position or the focus position. If it can be determined that the position is in the vicinity of the focal position, the process proceeds to step S201 shown in FIG.

なお、ステップS104において、フォーカスレンズ32が、合焦位置を含む合焦位置近傍に位置すると判断できるか否かの判定は、フォーカスレンズ32が、合焦位置を含む合焦位置近傍に実際に位置するか否かを判断するものではなく、位相差検出方式による焦点検出の結果に基づく合焦駆動を実行した後など、フォーカスレンズ32が、合焦位置を含む合焦位置近傍に位置すると判断できるような場合に、合焦位置を含む合焦位置近傍に位置すると判断できると判定するものである。そのため、ステップS104においては、フォーカスレンズ32が、合焦位置を含む合焦位置近傍に実際に位置していない場合でも、位相差検出方式による焦点検出の結果に基づく合焦駆動を実行した後など、フォーカスレンズ32が、合焦位置を含む合焦位置近傍に位置すると判断できるような場合には、合焦位置を含む合焦位置近傍に位置すると判断できると判定するものである。   In step S104, whether or not it can be determined that the focus lens 32 is positioned in the vicinity of the in-focus position including the in-focus position is determined based on whether the focus lens 32 is actually positioned in the vicinity of the in-focus position including the in-focus position. It can be determined that the focus lens 32 is positioned in the vicinity of the in-focus position including the in-focus position, for example, after performing in-focus driving based on the focus detection result by the phase difference detection method. In such a case, it is determined that it can be determined to be located in the vicinity of the in-focus position including the in-focus position. For this reason, in step S104, even when the focus lens 32 is not actually positioned in the vicinity of the in-focus position including the in-focus position, after performing focus drive based on the focus detection result by the phase difference detection method, etc. When it can be determined that the focus lens 32 is located in the vicinity of the in-focus position including the in-focus position, it is determined that the focus lens 32 can be determined in the vicinity of the in-focus position including the in-focus position.

そして、ステップS104において、位相差検出方式による焦点検出の結果に基づくフォーカスレンズ32の合焦駆動が実行されていない場合など、フォーカスレンズ32が、合焦位置近傍に位置すると判断できない場合には、ステップS105に進み、ステップS105では、カメラ制御部21により、予め設定された所定のシフト範囲Sa全域について、相関演算が実行される。なお、所定のシフト範囲Saは、たとえば、各焦点検出画素列22a〜22cを構成する、各焦点検出画素222a,222bの画素数などに基づいて設定されるシフト範囲であり、たとえば、絞り34が開放絞りである場合に、相関演算を適切に行なうことができるようなシフト範囲に設定することができる。   In step S104, when it is not possible to determine that the focus lens 32 is positioned in the vicinity of the focus position, such as when focus drive of the focus lens 32 based on the result of focus detection by the phase difference detection method is not executed, Proceeding to step S105, in step S105, the camera control unit 21 performs a correlation operation for the entire predetermined shift range Sa set in advance. The predetermined shift range Sa is, for example, a shift range set based on the number of focus detection pixels 222a and 222b constituting the focus detection pixel rows 22a to 22c. When the aperture is wide open, the shift range can be set so that the correlation calculation can be appropriately performed.

具体的には、カメラ制御部21は、ステップS103において、各焦点検出画素列22a,22b,22cから読み出した第1データ列a,a,...,aと、第2データ列b,b,...bとを、予め設定された所定のシフト範囲Sa全域において、一次元状に相対的にシフトさせながら、下記式(3)に示す相関演算を実行する。
C(h)=Σ|a(n+h)−b(n)| …(3)
なお、上記式(3)において、Σ演算はnについての累積演算(相和演算)を示す。また、hはシフト量に対応する変数であり、上記式(3)の演算結果においては、第1データ列と第2データ列との間の相関が高いほど、相関量C(h)は小さくなる。本実施形態では、このような相関演算を、予め設定された所定のシフト範囲Sa全域について実行する。
Specifically, in step S103, the camera control unit 21 reads the first data strings a 1 , a 2 ,... Read from the focus detection pixel arrays 22a, 22b, and 22c. . . , An and the second data string b 1 , b 2 ,. . . and b n, in preset predetermined shift range Sa whole, while relatively shifting one-dimensionally, performing a correlation calculation shown by the following formula (3).
C (h) = Σ | a (n + h) −b (n) | (3)
In the above equation (3), the Σ operation indicates a cumulative operation (phase sum operation) for n. Further, h is a variable corresponding to the shift amount. In the calculation result of the above formula (3), the correlation amount C (h) is smaller as the correlation between the first data string and the second data string is higher. Become. In the present embodiment, such correlation calculation is executed for the entire predetermined shift range Sa set in advance.

次いで、ステップS106では、カメラ制御部21により、ステップS105で演算された所定のシフト範囲Sa全域における相関量の演算結果のうち、シフト量が、ステップS102で決定された有効シフト範囲Sna内である演算結果を用いて、相関量の極小値を検出する処理が実行される。すなわち、たとえば、ステップS105で相関演算を行なった所定のシフト範囲Saがシフト量=−20〜+20の範囲であり、一方、ステップS102で決定された有効シフト範囲Snaがシフト量=−10〜+10である場合には、シフト量=−10〜+10とした場合における相関量の演算結果のみを用いて、相関量の極小値を検出する処理を行なう。   Next, in step S106, the shift amount is within the effective shift range Sna determined in step S102 among the calculation results of the correlation amount in the entire range of the predetermined shift range Sa calculated in step S105 by the camera control unit 21. Processing for detecting the minimum value of the correlation amount is executed using the calculation result. That is, for example, the predetermined shift range Sa subjected to the correlation calculation in step S105 is a range of shift amount = −20 to +20, while the effective shift range Sna determined in step S102 is the shift amount = −10 to +10. In this case, the process of detecting the minimum value of the correlation amount is performed using only the calculation result of the correlation amount when the shift amount = −10 to +10.

なお、相関量の極小値の検出は、たとえば、下記式(4)〜(7)に示す3点内挿の手法を用いて、連続的な相関量に対する極小値C(x)が得られるシフト量xを求めることにより行なわれる。ここで、下記式に示すC(hj)は、上記式(3)により算出された相関量C(h)のうち最も小さい値である。
D={C(hj−1)−C(hj+1)}/2 …(4)
C(x)= C(hj)−|D| …(5)
x=hj+D/SLOP …(6)
SLOP=MAX{C(hj+1)−C(hj),C(hj−1)−C(hj)} …(7)
Note that the minimum value of the correlation amount is detected, for example, by using a three-point interpolation method shown in the following formulas (4) to (7) to obtain a minimum value C (x) for the continuous correlation amount. This is done by determining the quantity x. Here, C (hj) shown in the following equation is the smallest value among the correlation amounts C (h) calculated by the above equation (3).
D = {C (hj−1) −C (hj + 1)} / 2 (4)
C (x) = C (hj) − | D | (5)
x = hj + D / SLOP (6)
SLOP = MAX {C (hj + 1) -C (hj), C (hj-1) -C (hj)} (7)

次いで、ステップS107においては、ステップS106において、有効シフト範囲Sna内において、相関量の極小値が検出できたか否かの判定が行なわれる。相関量の極小値が検出できた場合には、ステップS108に進み、一方、相関量の極小値が検出できなかった場合には、ステップS109に進む。   Next, in step S107, it is determined in step S106 whether or not the minimum value of the correlation amount has been detected within the effective shift range Sna. If the minimum value of the correlation amount can be detected, the process proceeds to step S108. On the other hand, if the minimum value of the correlation amount cannot be detected, the process proceeds to step S109.

そして、ステップS108では、ステップS106において検出された相関量の極小値C(x)が得られるシフト量xに基づいて、下記式(8)に従い、デフォーカス量dfを算出する。
df=x・k・p …(8)
なお、上記式(8)において、kは、相関量の極小値C(x)が得られるシフト量xをデフォーカス量に変換するための変換係数である。上述したように、絞り値に応じて、相関量の極小値が得られるシフト量は異なるため、変換係数は、絞り値に応じて予め設定されている。また、pは焦点検出画素列22a〜22cを構成する焦点検出画素222a,222bのピッチ幅によって定まる定数である。
In step S108, the defocus amount df is calculated according to the following equation (8) based on the shift amount x from which the minimum value C (x) of the correlation amount detected in step S106 is obtained.
df = x · k · p (8)
In the above equation (8), k is a conversion coefficient for converting the shift amount x from which the minimum value C (x) of the correlation amount is obtained into the defocus amount. As described above, since the shift amount for obtaining the minimum value of the correlation amount differs depending on the aperture value, the conversion coefficient is preset according to the aperture value. Further, p is a constant determined by the pitch width of the focus detection pixels 222a and 222b constituting the focus detection pixel rows 22a to 22c.

そして、このようにして算出されたデフォーカス量は、撮影者により操作部28に備えられたレリーズボタンの半押しが行なわれた場合に、フォーカスレンズ32を駆動することで光学系の焦点調節を行なう際に使用される。   The defocus amount calculated in this way is used to adjust the focus of the optical system by driving the focus lens 32 when the release button provided in the operation unit 28 is half-pressed by the photographer. Used when doing.

一方、ステップS109では、有効シフト範囲Sna内において、相関量の極小値が検出できなかったため、デフォーカス量が検出不能であると判定する。   On the other hand, in step S109, since the minimum value of the correlation amount cannot be detected within the effective shift range Sna, it is determined that the defocus amount cannot be detected.

そして、ステップS108において、デフォーカス量を算出した場合、およびステップS109において、デフォーカス量が検出不能であると判定された場合のいずれも、ステップS101に戻り、撮影者により、操作部28に備えられたレリーズボタンの半押しが行なわれておらず、位相差検出方式による焦点検出の結果に基づくフォーカスレンズ32の合焦駆動が実行されていない場合など、フォーカスレンズ32が、合焦位置近傍に位置すると判断できない状態が続く限り(ステップS104=No)、ステップS101〜S109の処理を繰り返し行なう。   Then, in both cases where the defocus amount is calculated in step S108 and in the case where it is determined in step S109 that the defocus amount cannot be detected, the process returns to step S101, and the photographer prepares for the operation unit 28. When the release button is not half-pressed and the focus lens 32 is not driven based on the result of focus detection by the phase difference detection method, the focus lens 32 is in the vicinity of the focus position. As long as the state in which it cannot be determined continues (step S104 = No), the processes of steps S101 to S109 are repeated.

一方、上述したステップS104において、撮影者により、操作部28に備えられたレリーズボタンの半押しが行なわれ、位相差検出方式による焦点検出の結果に基づくフォーカスレンズ32の合焦駆動が行われた後など、フォーカスレンズ32が、合焦位置を含む合焦位置近傍に位置すると判断できると判定された場合には、図10に示すステップS201に進み、図10に示すステップS201〜S210において、上述したステップS105〜S109とは異なる方法で、デフォーカス量の算出が実行される。
以下、フォーカスレンズ32が、合焦位置を含む合焦位置近傍に位置すると判断できると判定された場合におけるデフォーカス量の算出方法について説明する。
On the other hand, in step S104 described above, the photographer half-pressed the release button provided in the operation unit 28, and the focus lens 32 was driven to focus based on the result of focus detection by the phase difference detection method. When it is determined that the focus lens 32 can be positioned in the vicinity of the in-focus position including the in-focus position, such as after, the process proceeds to step S201 illustrated in FIG. 10 and in steps S201 to S210 illustrated in FIG. The defocus amount is calculated by a method different from steps S105 to S109.
Hereinafter, a method for calculating the defocus amount when it is determined that the focus lens 32 can be determined to be located in the vicinity of the in-focus position including the in-focus position will be described.

まず、図10に示すステップS201において、カメラ制御部21により、シフト演算に用いる変数Nを、N=1とする処理が行なわれた後、ステップS202に進み、カメラ制御部21により、シフト量=0にて、相関量演算が行われる。   First, in step S201 shown in FIG. 10, the camera control unit 21 performs processing for setting the variable N used for the shift calculation to N = 1, and then proceeds to step S202, where the camera control unit 21 sets the shift amount = At 0, the correlation amount calculation is performed.

具体的には、まず、カメラ制御部21は、上述したステップS103において、各焦点検出画素列22a,22b,22cから読み出した第1データ列a,a,・・・,aと、第2データ列b,b,・・・bとを用いて、上記式(3)にしたがい、シフト量=0における相関量演算を実行し、シフト量=0における相関量C(0)を算出する。 Specifically, first, the camera control unit 21 in step S103 described above, the first data stream read from the focus detection pixel row 22a, 22b, 22c a 1, a 2, ···, and a n, Using the second data string b 1 , b 2 ,..., B n and performing the correlation amount calculation at shift amount = 0 according to the above equation (3), the correlation amount C (0 at shift amount = 0) ) Is calculated.

次いで、ステップS203に進み、ステップS203では、カメラ制御部21により、シフト量=+Nにて、相関量演算が行われる。すなわち、上記式(3)において、h=+Nとして、シフト量=+Nにおける相関量C(+N)の算出が行なわれる。たとえば、N=+1である場合には、上記式(3)にしたがい、シフト量=+1における相関量演算を実行し、シフト量=+1における相関量C(+1)を算出する。   Next, the process proceeds to step S203. In step S203, the camera control unit 21 performs a correlation amount calculation with a shift amount = + N. That is, in the above equation (3), the correlation amount C (+ N) at the shift amount = + N is calculated with h = + N. For example, when N = + 1, the correlation amount calculation is performed when the shift amount = + 1 according to the above equation (3), and the correlation amount C (+1) when the shift amount = + 1 is calculated.

そして、ステップS203においては、カメラ制御部21により、算出された相関量C(h)を用いて、相関量の極小値の検出が行われる。なお、相関量の極小値の検出は、上述したステップS106と同様に、上記式(4)〜(7)に示す3点内挿の手法を用いて、連続的な相関量に対する極小値C(x)が得られるシフト量xを求めることにより行なわれる。なお、本実施形態において、たとえば、最も小さい相関量である相関量C(hj)が得られている場合でも、相関量C(hj+1)、C(hj−1)が算出されていない場合(たとえば、最も小さい相関量が、C(+1)である場合に、C(+2)が算出されていない場合)には、相関量の極小値の検出を行うことができないため、相関量の極小値の検出については実行しない。   In step S203, the camera control unit 21 detects the minimum value of the correlation amount using the calculated correlation amount C (h). Note that the minimum value of the correlation amount is detected by using the three-point interpolation method shown in the above formulas (4) to (7) as in step S106 described above, with the minimum value C ( x) is performed by obtaining the shift amount x from which the result is obtained. In the present embodiment, for example, even when the correlation amount C (hj) which is the smallest correlation amount is obtained, the correlation amounts C (hj + 1) and C (hj−1) are not calculated (for example, When the smallest correlation amount is C (+1) and C (+2) is not calculated), the minimum value of the correlation amount cannot be detected. Do not perform detection.

次いで、ステップS204においては、ステップS203において、相関量の極小値が検出できたか否かの判定が行なわれる。相関量の極小値が検出できた場合には、ステップS209に進み、一方、相関量の極小値が検出できなかった場合には、ステップS205に進む。   Next, in step S204, it is determined whether or not the minimum value of the correlation amount has been detected in step S203. If the minimum value of the correlation amount can be detected, the process proceeds to step S209. On the other hand, if the minimum value of the correlation amount cannot be detected, the process proceeds to step S205.

ステップS205では、カメラ制御部21により、シフト量=−Nにて、相関量演算が行われる。すなわち、上記式(3)において、h=−Nとして、シフト量=−Nにおける相関量C(−N)の算出が行なわれる。たとえば、N=−1である場合には、上記式(3)にしたがい、シフト量=−1における相関量演算を実行し、シフト量=−1における相関量C(−1)を算出する。   In step S205, the camera control unit 21 calculates the correlation amount with the shift amount = −N. That is, in the above equation (3), assuming that h = −N, the correlation amount C (−N) at the shift amount = −N is calculated. For example, when N = −1, the correlation amount calculation at the shift amount = −1 is executed according to the above equation (3), and the correlation amount C (−1) at the shift amount = −1 is calculated.

そして、ステップS205においては、上述したステップS203と同様に、カメラ制御部21により算出された相関量C(h)を用いて、上記式(4)〜(7)に示す3点内挿の手法を用いて、相関量の極小値の検出を行う。なお、ステップS205においても、たとえば、最も小さい相関量である相関量C(hj)が得られている場合でも、相関量C(hj+1)、C(hj−1)が算出されていない場合には、相関量の極小値の検出を行うことができないため、相関量の極小値の検出については実行しない。   In step S205, as in step S203 described above, using the correlation amount C (h) calculated by the camera control unit 21, the three-point interpolation method shown in the above equations (4) to (7) is used. Is used to detect the minimum value of the correlation amount. In step S205, for example, when the correlation amount C (hj), which is the smallest correlation amount, is obtained, the correlation amounts C (hj + 1) and C (hj-1) are not calculated. Since the minimum value of the correlation amount cannot be detected, the minimum value of the correlation amount is not detected.

次いで、ステップS206においては、ステップS205において、相関量の極小値が検出できたか否かの判定が行なわれる。相関量の極小値が検出できた場合には、ステップS209に進み、一方、相関量の極小値が検出できなかった場合には、ステップS207に進む。たとえば、相関量C(−1)、C(0)、C(+1)が算出されており、これらの相関量のうちC(0)である場合に、上記式(4)〜(7)にしたがって、極小値C(x)が得られた場合には、ステップS209に進む。   Next, in step S206, it is determined whether or not the minimum value of the correlation amount has been detected in step S205. If the minimum value of the correlation amount can be detected, the process proceeds to step S209. On the other hand, if the minimum value of the correlation amount cannot be detected, the process proceeds to step S207. For example, when the correlation amounts C (−1), C (0), and C (+1) are calculated and the correlation amount is C (0), the above equations (4) to (7) Therefore, when the minimum value C (x) is obtained, the process proceeds to step S209.

ステップS207では、ステップS102で決定した有効シフト範囲Snaについて、相関量演算が終了したか否かの判定が行なわれる。有効シフト範囲Snaについて、相関演算が終了していないと判定された場合には、ステップS208に進み、N=N+1とする処理が実行され、ステップS203に戻り、再度、相関量演算が実行される。すなわち、たとえば、有効シフト範囲Sna=−10〜+10に設定されている場合に、相関量演算が終了している範囲がシフト量=−1〜+1である場合には、ステップS208において、N=2(N=1+1)とし、ステップS203に戻る。そして、ステップS203において、シフト量=+2における相関量C(+2)の演算が行われ、相関量の極小値C(x)が検出できない場合には、さらに、ステップS205において、シフト量=−2における相関量C(−2)の演算が実行される。このように本実施形態では、相関量の極小値C(x)が検出されるまで、シフト量を0,+1,−1,+2,−2,+3,−3,・・・と絶対値の大きなシフト量に変更しながら、相関演算を行う。   In step S207, it is determined whether or not the correlation amount calculation has been completed for the effective shift range Sna determined in step S102. If it is determined that the correlation calculation has not been completed for the effective shift range Sna, the process proceeds to step S208, the process of setting N = N + 1 is performed, the process returns to step S203, and the correlation amount calculation is performed again. . That is, for example, when the effective shift range Sna = −10 to +10 is set, and the range in which the correlation amount calculation is completed is the shift amount = −1 to +1, in step S208, N = 2 (N = 1 + 1), and the process returns to step S203. In step S203, when the correlation amount C (+2) at the shift amount = + 2 is calculated and the minimum value C (x) of the correlation amount cannot be detected, in step S205, the shift amount = −2. The calculation of the correlation amount C (−2) is performed. As described above, in this embodiment, the absolute value of the shift amount is set to 0, +1, -1, +2, -2, +3, -3, ... until the minimum value C (x) of the correlation amount is detected. The correlation calculation is performed while changing to a large shift amount.

そして、相関演算の結果、ステップS203またはステップS205において、相関量の極小値C(x)が検出された場合には、ステップS204またはステップS206から、ステップS209に進み、ステップS209において、デフォーカス量の算出が行なわれる。具体的には、ステップS209では、相関量の極小値C(x)が検出されたため、カメラ制御部21は、相関量演算を終了し、上述したステップS108と同様に、検出された相関量の極小値C(x)が得られるシフト量xに基づいて、上記式(8)に従い、デフォーカス量dfを算出する。   As a result of the correlation calculation, when the minimum value C (x) of the correlation amount is detected in step S203 or step S205, the process proceeds from step S204 or step S206 to step S209. In step S209, the defocus amount is determined. Is calculated. Specifically, since the minimum value C (x) of the correlation amount is detected in step S209, the camera control unit 21 ends the correlation amount calculation, and similarly to step S108 described above, the detected correlation amount is detected. The defocus amount df is calculated according to the above equation (8) based on the shift amount x that provides the minimum value C (x).

そして、このようにして算出されたデフォーカス量に基づいて、フォーカスレンズ32の駆動が必要か否かの判定が行なわれ、フォーカスレンズ32の駆動が必要な場合(たとえば、デフォーカス量が所定値以上である場合)には、算出されたデフォーカス量に基づいて、フォーカスレンズ32の駆動が行なわれ、これにより光学系の焦点調節が実行される。   Based on the defocus amount calculated in this way, it is determined whether or not the focus lens 32 needs to be driven. If the focus lens 32 needs to be driven (for example, the defocus amount is a predetermined value). In such a case, the focus lens 32 is driven based on the calculated defocus amount, and thereby the focus adjustment of the optical system is executed.

一方、ステップS102で決定した有効シフト範囲Snaについて、相関量演算を行なった結果、相関量の極小値C(x)が検出できなかった場合には、ステップS210に進み、デフォーカス量が検出不能であると判定する。   On the other hand, if the correlation amount calculation is not performed for the effective shift range Sna determined in step S102, the minimum value C (x) of the correlation amount cannot be detected, the process proceeds to step S210, and the defocus amount cannot be detected. It is determined that

そして、ステップS209において、デフォーカス量を算出した場合、およびステップS210において、デフォーカス量が検出不能であると判定された場合のいずれも、ステップS101に戻り、フォーカスレンズ32が、合焦位置近傍に位置すると判断できる状態が続く限り(ステップS104=Yes)、ステップS101〜S104、S201〜S210の処理を繰り返し実行する。そして、その一方で、フォーカスレンズ32が、合焦位置近傍に位置すると判断できない状態となった場合(ステップS104=No)には、上述したステップS101〜S109の処理を実行することとなる。   Then, both when the defocus amount is calculated in step S209 and when it is determined that the defocus amount cannot be detected in step S210, the process returns to step S101, and the focus lens 32 is in the vicinity of the in-focus position. As long as the state that can be determined to be located continues (step S104 = Yes), the processes of steps S101 to S104 and S201 to S210 are repeatedly executed. On the other hand, when the focus lens 32 cannot be determined to be located in the vicinity of the in-focus position (step S104 = No), the processes of steps S101 to S109 described above are executed.

本実施形態においては、位相差検出方式により、デフォーカス量の算出を行なう際において、フォーカスレンズ32が、合焦位置近傍に位置すると判断できない場合には、まず、予め設定された所定のシフト範囲Sa全域について相関演算を行い、次いで、相関演算結果を用いて相関量の極小値を算出する際に、所定のシフト範囲Sa全域について実行された相関演算結果のうち、絞り34の絞り値に基づいて設定される有効シフト範囲Sna内の相関演算結果のみを用いて、相関量の極小値を算出する。そして、相関量の極小値が得られるシフト量に基づいて、デフォーカス量を算出する。そのため、本実施形態によれば、絞り34の絞り値によっては、相関量の極小値が検出されたとしても、光学系の焦点状態を適切に検出できておらず、偽合焦となってしまうという問題(たとえば、絞り34の絞り値が比較的大きい場合であり、かつ、比較的大きなシフト量において、相関量の極小値が検出されてしまう場合など)を有効に解決することができ、これにより、光学系の焦点検出を良好に行うことができる。   In the present embodiment, when calculating the defocus amount by the phase difference detection method, if it cannot be determined that the focus lens 32 is positioned in the vicinity of the in-focus position, first, a predetermined shift range set in advance is set. When the correlation calculation is performed for the entire area Sa, and then the minimum value of the correlation amount is calculated using the correlation calculation result, the correlation calculation result executed for the entire predetermined shift range Sa is based on the aperture value of the diaphragm 34. The minimum value of the correlation amount is calculated using only the correlation calculation result within the effective shift range Sna set as described above. Then, the defocus amount is calculated based on the shift amount that provides the minimum value of the correlation amount. Therefore, according to the present embodiment, depending on the aperture value of the aperture 34, even if the minimum value of the correlation amount is detected, the focus state of the optical system cannot be detected properly, resulting in false focusing. (For example, the case where the aperture value of the aperture 34 is relatively large and the minimum value of the correlation amount is detected at a relatively large shift amount) can be effectively solved. Thus, the focus detection of the optical system can be performed satisfactorily.

加えて、本実施形態によれば、位相差検出方式により、デフォーカス量の算出を行なう際において、フォーカスレンズ32が、合焦位置近傍に位置すると判断できる場合には、相関量の演算をシフト量=0から開始し、シフト量の絶対値を順に大きくしていきながら相関量の演算および相関量の極小値の検出を逐次行い、相関量の極小値が検出された場合には、相関量の極小値が検出された時点で、相関量の演算を終了する。そして、相関量の極小値が得られるシフト量に基づいて、デフォーカス量を算出する。そのため、本実施形態によれば、デフォーカス量を算出するために要する時間の短縮化が可能となる。特に、フォーカスレンズ32が、合焦位置近傍に位置すると判断できる場合には、相関量の極小値は、シフト量の絶対値が小さな範囲、具体的には、シフト量=0近傍に存在する場合が多くなる。そして、このような場合において、本実施形態のように、相関量の演算をシフト量=0から開始し、シフト量の絶対値を順に大きくしていきながら相関量の演算および相関量の極小値の検出を逐次行った場合には、比較的短時間で、相関量の極小値を検出することが可能となり、これにより、デフォーカス量を算出するために要する時間を短縮することができる。また、これに加えて、本実施形態によれば、相関量演算に要する演算負荷を低減することもできる。   In addition, according to the present embodiment, when calculating the defocus amount by the phase difference detection method, if it can be determined that the focus lens 32 is located in the vicinity of the in-focus position, the calculation of the correlation amount is shifted. Starting from the amount = 0, the calculation of the correlation amount and the detection of the minimum value of the correlation amount are sequentially performed while increasing the absolute value of the shift amount in order, and when the minimum value of the correlation amount is detected, the correlation amount When the local minimum value is detected, the calculation of the correlation amount is terminated. Then, the defocus amount is calculated based on the shift amount that provides the minimum value of the correlation amount. Therefore, according to the present embodiment, it is possible to reduce the time required to calculate the defocus amount. In particular, when it can be determined that the focus lens 32 is located in the vicinity of the in-focus position, the minimum value of the correlation amount exists in the range where the absolute value of the shift amount is small, specifically, the shift amount = 0. Will increase. In such a case, as in the present embodiment, the calculation of the correlation amount is started from the shift amount = 0, and the calculation of the correlation amount and the minimum value of the correlation amount are sequentially increased while the absolute value of the shift amount is sequentially increased. When the detections are sequentially performed, it is possible to detect the minimum value of the correlation amount in a relatively short time, thereby shortening the time required to calculate the defocus amount. In addition to this, according to the present embodiment, it is possible to reduce the calculation load required for the correlation amount calculation.

なお、以上説明した実施形態は、本発明の理解を容易にするために記載されたものであって、本発明を限定するために記載されたものではない。したがって、上記の実施形態に開示された各要素は、本発明の技術的範囲に属する全ての設計変更や均等物をも含む趣旨である。   The embodiment described above is described for facilitating the understanding of the present invention, and is not described for limiting the present invention. Therefore, each element disclosed in the above embodiment is intended to include all design changes and equivalents belonging to the technical scope of the present invention.

たとえば、上述した実施形態では、所定のシフト範囲Sa全域について実行された相関演算結果のうち、絞り34の絞り値に基づいて設定される有効シフト範囲Sna内の相関演算結果を用いて、相関量の極小値を算出する態様を例示したが、たとえば、前回処理時において、相関量の極小値が得られるシフト量が得られている場合(特に、相関量の極小値が得られるシフト量が得られており、かつ、フォーカスレンズ32が合焦位置に向かって駆動している場合)には、得られたシフト量に基づいて、有効シフト範囲Snaよりも狭いシフト範囲Snpを設定し、所定のシフト範囲Sa全域について実行された相関演算結果のうち、設定したシフト範囲Snp内の相関演算結果のみを用いて、相関量の極小値を算出するような構成としてもよい。   For example, in the above-described embodiment, the correlation amount is calculated using the correlation calculation result in the effective shift range Sna set based on the aperture value of the aperture 34 among the correlation calculation results executed for the entire predetermined shift range Sa. However, for example, when a shift amount that can obtain the minimum value of the correlation amount is obtained in the previous processing (particularly, a shift amount that can obtain the minimum value of the correlation amount is obtained). And when the focus lens 32 is driven toward the in-focus position), a shift range Snp narrower than the effective shift range Sna is set based on the obtained shift amount, and a predetermined value is set. Of the correlation calculation results executed for the entire shift range Sa, only the correlation calculation result within the set shift range Snp may be used to calculate the minimum value of the correlation amount. There.

あるいは、上述した実施形態では、位相差検出方式により焦点検出を行う構成を例示して説明したが、このような構成に加えて、たとえば、位相差検出方式により焦点検出を行い、位相差検出方式では焦点状態を検出できない場合に、フォーカスレンズ32を駆動させながら、コントラスト検出方式により焦点検出を行う構成としてもよい。あるいは、位相差検出方式により焦点検出を行い、位相差検出方式では焦点状態を検出できない場合に、フォーカスレンズ32を駆動させながら、位相差検出方式による焦点検出と、コントラスト検出方式により焦点検出とを同時に行う構成としてもよい。   Alternatively, in the above-described embodiment, the configuration in which focus detection is performed by the phase difference detection method has been described as an example, but in addition to such a configuration, for example, focus detection is performed by the phase difference detection method, and the phase difference detection method is performed. Then, when the focus state cannot be detected, the focus detection may be performed by the contrast detection method while driving the focus lens 32. Alternatively, when focus detection is performed by the phase difference detection method and the focus state cannot be detected by the phase difference detection method, focus detection by the phase difference detection method and focus detection by the contrast detection method are performed while the focus lens 32 is driven. It is good also as a structure performed simultaneously.

なお、上述した実施形態のカメラ1は特に限定されず、例えば、デジタルビデオカメラ、一眼レフデジタルカメラ、レンズ一体型のデジタルカメラ、携帯電話用のカメラなどのその他の光学機器に本発明を適用してもよい。   The camera 1 of the above-described embodiment is not particularly limited. For example, the present invention is applied to other optical devices such as a digital video camera, a single-lens reflex digital camera, a lens-integrated digital camera, and a camera for a mobile phone. May be.

1…デジタルカメラ
2…カメラ本体
21…カメラ制御部
22…撮像素子
221…撮像画素
222a,222b…焦点検出画素
24…メモリ
28…操作部
3…レンズ鏡筒
32…フォーカスレンズ
36…フォーカスレンズ駆動モータ
37…レンズ制御部
DESCRIPTION OF SYMBOLS 1 ... Digital camera 2 ... Camera body 21 ... Camera control part 22 ... Imaging device 221 ... Imaging pixel 222a, 222b ... Focus detection pixel 24 ... Memory 28 ... Operation part 3 ... Lens barrel 32 ... Focus lens 36 ... Focus lens drive motor 37 ... Lens control unit

Claims (6)

焦点調節光学系を備える光学系による像を撮像し、撮像した像に対応する画像信号を出力する撮像用画素と、瞳分割された一対の光束を受光する一対の焦点検出用画素列とを有する撮像部と、
前記光学系を通過し、前記撮像部に入射する光束を制限する絞りと、
前記一対の焦点検出用画素列からそれぞれ出力された第1データ列および第2データ列を、一次元状に相対的にシフトさせながら、前記第1データ列と前記第2データ列との間の相関量を演算するシフト演算を、予め定められた所定のシフト範囲全域について行い、該シフト演算結果に基づいて、前記相関量の極値が得られるシフト量を検出することで、前記光学系の焦点状態を検出する位相差検出部と、
前記絞りによる絞り値に基づいて、前記絞り値に対応する、前記相関量の極値を得るための有効シフト範囲を設定する設定部と、を備え、
前記位相差検出部は、前記所定のシフト範囲全域について行ったシフト演算結果のうち、前記絞りの絞り値に応じた有効シフト範囲における演算結果を用いて、前記相関量の極値が得られるシフト量の検出を行うことを特徴とする焦点検出装置。
An imaging pixel that captures an image by an optical system including a focus adjustment optical system and outputs an image signal corresponding to the captured image, and a pair of focus detection pixel rows that receive a pair of pupil-divided light beams An imaging unit;
A diaphragm that passes through the optical system and restricts a light beam incident on the imaging unit;
While the first data row and the second data row respectively output from the pair of focus detection pixel rows are relatively shifted in a one-dimensional manner, between the first data row and the second data row. A shift operation for calculating the correlation amount is performed over a predetermined predetermined shift range, and based on the shift calculation result, a shift amount at which an extreme value of the correlation amount is obtained is detected. A phase difference detection unit for detecting a focus state;
A setting unit that sets an effective shift range for obtaining an extreme value of the correlation amount corresponding to the aperture value based on the aperture value by the aperture; and
The phase difference detection unit shifts the extreme value of the correlation amount using a calculation result in an effective shift range corresponding to the aperture value of the diaphragm among the shift calculation results performed for the entire predetermined shift range. A focus detection apparatus that detects an amount.
請求項1に記載の焦点検出装置において、
前記位相差検出部による焦点状態の検出結果に基づいて、前記焦点調節光学系を光軸方向に駆動させることで、前記光学系の焦点調節を行なう焦点調節部をさらに備え、
前記位相差検出部は、
前記焦点調節部により前記焦点調節光学系を駆動させた結果、前記焦点調節光学系が、合焦位置を含む合焦位置近傍に位置していると判断できる場合には、
前記所定のシフト範囲全域についてシフト演算を行なう代わりに、前記相関量の演算を、シフト量の絶対値が最も小さなものから開始し、前記シフト量の絶対値を順に大きくしていきながら前記相関量の演算および前記相関量の極値が得られるシフト量の検出を逐次行うとともに、前記相関量の極値が得られるシフト量が検出された場合には、前記相関量の極値が得られるシフト量が検出された時点で、前記相関量の演算を終了し、前記相関量の極値が得られるシフト量に基づいて、前記光学系の焦点状態の検出を行うことを特徴とする焦点検出装置。
The focus detection apparatus according to claim 1,
Based on the detection result of the focus state by the phase difference detection unit, the focus adjustment optical system is further driven by driving the focus adjustment optical system in the direction of the optical axis, thereby further including a focus adjustment unit that performs focus adjustment of the optical system,
The phase difference detector is
As a result of driving the focus adjustment optical system by the focus adjustment unit, when it can be determined that the focus adjustment optical system is located in the vicinity of the focus position including the focus position,
Instead of performing a shift operation for the entire range of the predetermined shift range, the correlation amount calculation is started with the smallest absolute value of the shift amount, and the correlation amount is increased while increasing the absolute value of the shift amount in order. And the detection of the shift amount for obtaining the extreme value of the correlation amount, and the shift for obtaining the extreme value of the correlation amount when the shift amount for obtaining the extreme value of the correlation amount is detected. When the amount is detected, the calculation of the correlation amount is terminated, and the focus state of the optical system is detected based on the shift amount from which the extreme value of the correlation amount is obtained. .
請求項2に記載の焦点検出装置において、
前記位相差検出部は、前記焦点調節部により前記焦点調節光学系を駆動させた結果、前記焦点調節光学系が、合焦位置を含む合焦位置近傍に位置していると判断できる場合には、前記設定部により設定された有効シフト範囲において、前記相関量の演算および前記相関量の極値が得られるシフト量の検出を行うことを特徴とする焦点検出装置。
The focus detection apparatus according to claim 2,
When the phase difference detection unit can determine that the focus adjustment optical system is located in the vicinity of the focus position including the focus position as a result of driving the focus adjustment optical system by the focus adjustment unit. In the effective shift range set by the setting unit, the calculation of the correlation amount and the detection of the shift amount that provides the extreme value of the correlation amount are performed.
請求項1〜3のいずれかに記載の焦点検出装置であって、
前記設定部は、前記絞りによる絞り値が大きいほど、前記有効シフト範囲を小さい範囲にすることを特徴とする焦点検出装置。
The focus detection apparatus according to claim 1,
The focus detection apparatus characterized in that the setting unit sets the effective shift range to a smaller range as the aperture value by the aperture is larger.
請求項1〜4のいずれかに記載の焦点検出装置であって、
前記撮像用画素により出力された前記画像信号に基づいて、前記光学系による像のコントラストに関する評価値を算出することで、前記光学系の焦点状態を検出するコントラスト検出部をさらに備えることを特徴とする焦点検出装置。
The focus detection device according to any one of claims 1 to 4,
A contrast detection unit that detects a focus state of the optical system by calculating an evaluation value related to a contrast of the image by the optical system based on the image signal output by the imaging pixel, Focus detection device.
請求項1〜5のいずれかに記載の焦点検出装置を備える撮像装置。   An imaging device provided with the focus detection apparatus in any one of Claims 1-5.
JP2011196729A 2011-09-09 2011-09-09 Focus detection apparatus and imaging apparatus Active JP5923900B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2011196729A JP5923900B2 (en) 2011-09-09 2011-09-09 Focus detection apparatus and imaging apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011196729A JP5923900B2 (en) 2011-09-09 2011-09-09 Focus detection apparatus and imaging apparatus

Publications (2)

Publication Number Publication Date
JP2013057839A true JP2013057839A (en) 2013-03-28
JP5923900B2 JP5923900B2 (en) 2016-05-25

Family

ID=48133762

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011196729A Active JP5923900B2 (en) 2011-09-09 2011-09-09 Focus detection apparatus and imaging apparatus

Country Status (1)

Country Link
JP (1) JP5923900B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018008243A1 (en) * 2016-07-06 2018-01-11 富士フイルム株式会社 Focus control device, focus control method, focus control program, lens device, and imaging device

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS62139535A (en) * 1985-12-13 1987-06-23 Olympus Optical Co Ltd Phase difference type focus detecting method
JPS62205323A (en) * 1986-03-05 1987-09-09 Minolta Camera Co Ltd Automatic focus detector for camera
JPH0527158A (en) * 1991-07-19 1993-02-05 Ricoh Co Ltd Automatic focusing device
JPH0694987A (en) * 1992-09-03 1994-04-08 Nikon Corp Focus detector
JP2009271523A (en) * 2008-04-11 2009-11-19 Nikon Corp Focus detection device and image-capturing apparatus
JP2010091991A (en) * 2008-10-10 2010-04-22 Canon Inc Imaging apparatus, control method and program therefor

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS62139535A (en) * 1985-12-13 1987-06-23 Olympus Optical Co Ltd Phase difference type focus detecting method
JPS62205323A (en) * 1986-03-05 1987-09-09 Minolta Camera Co Ltd Automatic focus detector for camera
JPH0527158A (en) * 1991-07-19 1993-02-05 Ricoh Co Ltd Automatic focusing device
JPH0694987A (en) * 1992-09-03 1994-04-08 Nikon Corp Focus detector
JP2009271523A (en) * 2008-04-11 2009-11-19 Nikon Corp Focus detection device and image-capturing apparatus
JP2010091991A (en) * 2008-10-10 2010-04-22 Canon Inc Imaging apparatus, control method and program therefor

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2018008243A1 (en) * 2016-07-06 2018-01-11 富士フイルム株式会社 Focus control device, focus control method, focus control program, lens device, and imaging device
JP6462189B2 (en) * 2016-07-06 2019-01-30 富士フイルム株式会社 Focus control device, focus control method, focus control program, lens device, imaging device
CN109477948A (en) * 2016-07-06 2019-03-15 富士胶片株式会社 Focusing control apparatus, focusing control method, focusing control program, lens devices, photographic device
US10802245B2 (en) 2016-07-06 2020-10-13 Fujifilm Corporation Focusing control device, focusing control method, focusing control program, lens device, and imaging device
CN109477948B (en) * 2016-07-06 2021-02-19 富士胶片株式会社 Focus control device, focus control method, focus control program, lens device, and imaging device
US11343422B2 (en) 2016-07-06 2022-05-24 Fujifilm Corporation Focusing control device, focusing control method, focusing control program, lens device, and imaging device

Also Published As

Publication number Publication date
JP5923900B2 (en) 2016-05-25

Similar Documents

Publication Publication Date Title
WO2013015131A1 (en) Focus adjustment device and image capturing apparatus
JP5831070B2 (en) Imaging device
JP2013050690A (en) Focus adjusting device and imaging apparatus
JP5966267B2 (en) Focus adjustment device and imaging device
JP5845660B2 (en) Focus detection apparatus and imaging apparatus
JP2013003486A (en) Focus detector and imaging apparatus
JP6047861B2 (en) Focus adjustment device and camera body
JP5929060B2 (en) Focus detection apparatus and imaging apparatus
JP5477344B2 (en) Focus adjustment device and imaging device provided with the same
JP2012226247A (en) Focus detector and imaging apparatus
JP2014074855A (en) Focus adjustment device and imaging device
JP2017151458A (en) Imaging device
JP6127730B2 (en) Imaging device
JP5923900B2 (en) Focus detection apparatus and imaging apparatus
JP2013061579A (en) Focusing device and imaging apparatus
JP2013061582A (en) Focusing device and imaging apparatus
JP2013054261A (en) Focus detector and imaging device
JP5454521B2 (en) Imaging device
JP2014074853A (en) Focus adjustment device and imaging device
JP5821934B2 (en) Focus detection device, camera body, and camera
JP5982749B2 (en) Focus adjustment device and imaging device
JP2014074851A (en) Focus detection device and image capturing device
JP5423734B2 (en) Lens barrel and imaging device
JP2012255919A (en) Focus adjustment device and imaging apparatus
JP2012247723A (en) Focus adjustment device and imaging apparatus

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20140905

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20150415

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20150421

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20150622

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20151006

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20151204

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20160404

R150 Certificate of patent or registration of utility model

Ref document number: 5923900

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250