JP6890937B2 - Focus detector, image pickup device, and focus detection method - Google Patents
Focus detector, image pickup device, and focus detection method Download PDFInfo
- Publication number
- JP6890937B2 JP6890937B2 JP2016151419A JP2016151419A JP6890937B2 JP 6890937 B2 JP6890937 B2 JP 6890937B2 JP 2016151419 A JP2016151419 A JP 2016151419A JP 2016151419 A JP2016151419 A JP 2016151419A JP 6890937 B2 JP6890937 B2 JP 6890937B2
- Authority
- JP
- Japan
- Prior art keywords
- focus detection
- focus
- correction value
- phase difference
- optical system
- 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.)
- Active
Links
Images
Landscapes
- Focusing (AREA)
- Structure And Mechanism Of Cameras (AREA)
- Automatic Focus Adjustment (AREA)
- Studio Devices (AREA)
Description
本発明は焦点検出装置、撮像装置、および焦点検出方法に関し、特には自動焦点検出技術に関する。 The present invention is a focus detection apparatus, imaging apparatus, and relates to a focus detecting method and, more particularly, to an automatic focus detection technique.
撮像装置の自動焦点検出(AF)方式として、位相差焦点検出方式(位相差AF)が知られている。位相差AFは、ビデオカメラやデジタルスチルカメラで多く用いられるAFであり、撮像素子が焦点検出用センサとして用いられるものが存在する。位相差AFは、光学像を利用して焦点検出を行うため、光学像を結像する光学系の収差が焦点検出結果に誤差を与える場合があり、このような誤差を低減するための方法が提案されている。 A phase difference focus detection method (phase difference AF) is known as an automatic focus detection (AF) method for an image pickup apparatus. Phase-difference AF is AF that is often used in video cameras and digital still cameras, and there are some that use an image sensor as a focus detection sensor. Since phase-difference AF uses an optical image to detect the focus, the aberration of the optical system that forms the optical image may give an error to the focus detection result, and a method for reducing such an error is available. Proposed.
例えば、特許文献1には、合焦状態において一対の焦点検出光束が形成する一対の光学像の形状が、光学系の収差に起因して一致しなくなることによる焦点検出誤差を補正する方法が開示されている。
For example,
しかしながら、従来の方法では、被写体の色、方向、空間周波数に依存する補正と、位相差AFに依存する補正をまとめて補正しているため、補正精度が十分でないことがある。また、特許文献1では、最良像面と予定焦点面との間のデフォーカス量を検知し補正している。そのため、被写体の色、方向、空間周波数に依存する補正と、位相差AFに依存する補正をまとめて補正することとなり、算出される補正値が大きくなる。このことから、補正値算出誤差の影響が大きくなり、補正精度が十分でない。
However, in the conventional method, the correction that depends on the color, direction, and spatial frequency of the subject and the correction that depends on the phase difference AF are collectively corrected, so that the correction accuracy may not be sufficient. Further, in
本発明は、上記課題を鑑みて、被写体の色、方向、空間周波数に依存する補正と、位相差AFに依存する補正を分けて補正することで、位相差AFの焦点検出誤差を高精度に補正可能な焦点検出方法を提供することを目的とする。 In view of the above problems, the present invention makes the focus detection error of the phase difference AF highly accurate by separately correcting the correction depending on the color, direction, and spatial frequency of the subject and the correction depending on the phase difference AF. It is an object of the present invention to provide a correctable focus detection method.
上記の課題を解決するために、本発明の焦点検出装置は、撮像光学系の異なる瞳領域を通過した光束を光電変換して、一対の光電変換信号を出力することが可能な複数の画素を有する撮像手段と、撮影光学系の収差情報を取得する取得手段と、前記取得した収差情報から、画像の画像特性または評価特性から算出される撮像合焦位置と、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置から第1補正値を算出し、一対の線像強度分布の形状が互いに異なることで生じる重心ずれ量差に応じた補正値であって、前記焦点検出合焦位置における前記撮像手段の一対の光電変換部に対応した前記撮影光学系の線像強度分布に基づいて位相差焦点検出方式で検出される位相差焦点検出合焦位置から第2補正値を算出し、前記第1補正値と前記第2補正値から焦点検出補正値を算出する算出手段と、
を有する。
In order to solve the above problems, the focus detection device of the present invention photoelectrically converts light beams that have passed through different pupil regions of the imaging optical system, and outputs a plurality of pixels capable of outputting a pair of photoelectric conversion signals. From the image pickup means, the acquisition means for acquiring the aberration information of the photographing optical system, the imaging focus position calculated from the image characteristics or the evaluation characteristics of the image from the acquired aberration information, and the focus detection characteristics of the focus detection means. The first correction value is calculated from the calculated focus detection focus position, and is a correction value according to the difference in the amount of center of gravity shift caused by the shapes of the pair of line image intensity distributions being different from each other. calculating a second correction value from the pair of phase difference focus detection in-focus position which based on the line image intensity distribution of the photographing optical system corresponding to the photoelectric conversion unit is detected by the phase difference focus detection method of the image pickup means in and , A calculation means for calculating the focus detection correction value from the first correction value and the second correction value, and
Have.
本発明によれば、被写体の色、方向、空間周波数に依存する補正と、位相差AFに依存する補正を分けて補正することにより、光学系の収差による位相差AFの焦点検出誤差を精度良く補正可能な焦点検出方法を提供できる。 According to the present invention, the focus detection error of the phase difference AF due to the aberration of the optical system can be accurately corrected by separately correcting the correction depending on the color, direction, and spatial frequency of the subject and the correction depending on the phase difference AF. A correctable focus detection method can be provided.
以下、図面を参照しながら本発明の例示的な実施形態について説明する。なお、実施形態は発明の理解と説明を容易にするため、具体的かつ特定の構成を有するが、本発明はそのような特定の構成に限定されない。例えば、以下では本発明をレンズ交換可能な一眼レフタイプのデジタルカメラに適用した実施形態について説明するが、本発明はレンズ交換できないタイプのデジタルカメラや、ビデオカメラに対しても適用可能である。また、カメラを備えた任意の電子機器、例えば携帯電話機、パーソナルコンピュータ(ラップトップ、タブレット、デスクトップ型など)、ゲーム機などで実施することもできる。 Hereinafter, exemplary embodiments of the present invention will be described with reference to the drawings. The embodiment has a specific and specific configuration in order to facilitate understanding and explanation of the invention, but the present invention is not limited to such a specific configuration. For example, although the embodiment in which the present invention is applied to a single-lens reflex type digital camera with interchangeable lenses will be described below, the present invention can also be applied to a digital camera of a non-interchangeable lens type and a video camera. It can also be carried out on any electronic device equipped with a camera, such as a mobile phone, a personal computer (laptop, tablet, desktop type, etc.), a game machine, or the like.
(第1実施形態)
(撮像装置の構成の説明−レンズユニット)
図1は、本実施形態に係る撮像装置の一例としてデジタルカメラの機能構成を示すブロック図である。本実施形態のデジタルカメラは、レンズ交換式一眼レフカメラであり、レンズユニット100とカメラ本体120とを有する。レンズユニット100は、図中央の点線で示されるマウントMを介して、カメラ本体120に装着される。なお、本実施形態のデジタルカメラとしてレンズ交換式一眼レフカメラを例に説明するが、これに限定することなく、例えば、レンズ一体式のカメラであってもよい。
(First Embodiment)
(Explanation of the configuration of the imaging device-lens unit)
FIG. 1 is a block diagram showing a functional configuration of a digital camera as an example of an imaging device according to the present embodiment. The digital camera of the present embodiment is a single-lens reflex camera with interchangeable lenses, and has a
レンズユニット100は、光学系(第1レンズ群101、絞り102、第2レンズ群103、フォーカスレンズ群(以下、単に「フォーカスレンズ」という)104)、及び駆動/制御系を有する。本実施形態において、レンズユニット100は、フォーカスレンズ104を含み、被写体の光学像を形成する撮影レンズである。なお、本実施形態では、レンズユニット100は、制御手段を構成する。
The
第1レンズ群101は、レンズユニット100の被写体側の先端に配置され、光軸方向OAに移動可能に保持される。絞り102は、撮影時の光量を調節する機能のほか、静止画撮影時には露出時間を制御するメカニカルシャッタとしても機能する。絞り102及び第2レンズ群103は、一体で光軸方向OAに移動可能であり、第1レンズ群101と連動して移動することによりズーム機能を実現する。フォーカスレンズ104も光軸方向OAに移動可能であり、位置に応じてレンズユニット100が合焦する被写体距離(合焦距離)が変化する。フォーカスレンズ104の光軸方向OAにおける位置を制御することにより、レンズユニット100の合焦距離を調節する焦点調節を行う。
The
駆動/制御系は、ズームアクチュエータ111、絞りアクチュエータ112、フォーカスアクチュエータ113、ズーム駆動回路114、絞り絞り駆動回路115、フォーカス駆動回路116、レンズMPU117、レンズメモリ118を有する。ズーム駆動回路114は、ズームアクチュエータ111を用いて第1レンズ群101や第3レンズ群103を光軸方向OAに駆動し、レンズユニット100の光学系の画角を制御する。絞りシャッタ駆動回路115は、絞りアクチュエータ112を用いて絞り102を駆動し、絞り102の開口径や開閉動作を制御する。フォーカス駆動回路116は、フォーカスアクチュエータ113を用いてフォーカスレンズ104を光軸方向OAに駆動し、レンズユニット100の光学系の合焦距離を制御する。また、フォーカス駆動回路116は、フォーカスアクチュエータ113を用いてフォーカスレンズ104の現在位置を検出する。
The drive / control system includes a
レンズMPU(プロセッサ)117は、レンズユニット100に係る全ての演算、制御を行い、ズーム駆動回路114、絞り駆動回路115、フォーカス駆動回路116を制御する。また、レンズMPU117は、マウントMを通じてカメラMPU125と接続され、コマンドやデータを通信する。例えば、レンズMPU117は、フォーカスレンズ104の位置を検出し、カメラMPU125からの要求に対してレンズ位置情報を通知する。このレンズ位置情報は、フォーカスレンズ104の光軸方向OAにおける位置、光学系が移動していない状態の射出瞳の光軸方向OAにおける位置および直径、射出瞳の光束を制限するレンズ枠の光軸方向OAにおける位置および直径などの情報を含む。また、レンズMPU117は、カメラMPU125からの要求に応じて、ズーム駆動回路114、絞り駆動回路115、フォーカス駆動回路116を制御する。レンズメモリ118は、自動焦点検出に必要な光学情報が予め記憶されている。カメラMPU125は、例えば、内蔵する不揮発性メモリやレンズメモリ118に記憶されているプログラムを実行することで、レンズユニット100の動作を制御する。
The lens MPU (processor) 117 performs all calculations and controls related to the
(撮像装置の構成の説明−カメラ本体)
カメラ本体120は、光学系(光学ローパスフィルタ121及び撮像素子122)と、駆動/制御系とを有する。レンズユニット100の第1レンズ群101、絞り102、第2レンズ群103、フォーカスレンズ104と、カメラ本体120の光学ローパスフィルタ121は、撮影光学系を構成する。
(Explanation of the configuration of the imaging device-camera body)
The
光学ローパスフィルタ121は、撮影画像の偽色やモアレを軽減する。撮像素子122は、CMOSイメージセンサと周辺回路で構成され、横方向m画素、縦方向n画素(n、mは2以上の整数)が配置される。本実施形態の撮像素子122は、瞳分割機能を有し、画像データを用いた位相差AFが可能である。画像処理回路124は、撮像素子122が出力する画像データから、位相差AF用のデータと、表示、記録、およびコントラスト焦点検出方式(コントラストAF、TVAF)用の画像データを生成する。
The optical low-
駆動/制御系は、撮像素子駆動回路123、画像処理回路124、カメラMPU125、表示器126、操作スイッチ群127、メモリ128、位相差AF部129、TVAF部130を有する。撮像素子駆動回路123は、撮像素子122の動作を制御するとともに、取得した画像信号をA/D変換してカメラMPU125に送信する。画像処理回路124は、撮像素子122が取得した画像データに対し、例えば、γ変換、ホワイトバランス調整処理、色補間処理、圧縮符号化処理など、デジタルカメラで行われる一般的な画像処理を行う。また、画像処理回路124は、位相差AF用の信号も生成する。
The drive / control system includes an image
カメラMPU(プロセッサ)125は、カメラ本体120に係る全ての演算、制御を行い、センサ駆動回路123、画像処理回路124、表示器126、操作スイッチ群127、メモリ128、位相差AF部129、TVAF部130を制御する。カメラMPU125は、マウントMの信号線を介してレンズMPU117と接続され、レンズMPU117とコマンドやデータを通信する。また、カメラMPU125は、レンズMPU117に対し、レンズ位置の取得要求や、所定の駆動量での絞り、フォーカスレンズ、ズーム駆動要求や、レンズユニット100に固有の光学情報の取得要求などを発行する。さらに、カメラMPU125には、カメラ動作を制御するプログラムを格納したROM125a、変数を記憶するRAM125b、諸パラメータを記憶するEEPROM125cが内蔵されている。
The camera MPU (processor) 125 performs all calculations and controls related to the
表示器126は、LCDなどから構成され、カメラの撮影モードに関する情報、撮影前のプレビュー画像と撮影後の確認用画像、焦点検出時の合焦状態表示画像などを表示する。操作スイッチ群127は、電源スイッチ、レリーズ(撮影トリガ)スイッチ、ズーム操作スイッチ、撮影モード選択スイッチ等で構成される。本実施形態の記録手段としてのメモリ128は、着脱可能なフラッシュメモリで、撮影済み画像を記録する。
The
位相差AF部129は、画像処理回路124により得られる焦点検出用データを用いて位相差AFで焦点検出処理を行う。より具体的には、画像処理回路124が、撮影光学系の一対の瞳領域を通過する光束で形成される一対の像データを焦点検出用データとして生成し、位相差AF部129は、この一対の像データのずれ量に基づいて焦点ずれ量を検出する。このように、本実施形態の位相差AF部129は、専用のAFセンサを用いず、撮像素子122の出力に基づく位相差AF(撮像面位相差AF)を行う。位相差AF部129の動作については後で詳細に説明する。
The phase
TVAF部130は、画像処理回路124が生成するTVAF用評価値(画像データのコントラスト情報)に基づいてコントラストAFの焦点検出処理を行う。コントラストAFの焦点検出処理は、フォーカスレンズ104を移動して評価値がピークとなるフォーカスレンズ位置を合焦位置として検出する。このように、本実施形態のデジタルカメラは、位相差AFとコントラストAFの両方を実行可能であり、状況に応じて選択的に使用したり、組み合わせて使用したりすることができる。
The
(焦点検出動作の説明:位相差AF)
次に、位相差AF部129およびTVAF部130の動作についてさらに説明する。まず、位相差AF部129の動作について説明する。図2(A)は、本実施形態に係る撮像素子122の画素配列を示した図で、2次元C−MOSエリアセンサの縦(Y方向)6行と横(X方向)8列の範囲を、レンズユニット100側から観察した状態を示している。撮像素子122には、ベイヤー配列のカラーフィルタが設けられ、奇数行の画素には、左から順に緑(G)と赤(R)のカラーフィルタが交互に、偶数行の画素には、左から順に青(B)と緑(G)のカラーフィルタが交互に配置されている。画素211において、円211iは、オンチップマイクロレンズを表し、オンチップマイクロレンズの内側に配置された複数の矩形211a,211bは、それぞれ光電変換部である。
(Explanation of focus detection operation: phase difference AF)
Next, the operations of the phase
本実施形態の撮像素子122は、すべての画素の光電変換部がX方向に2分割され、個々の光電変換部の光電変換信号と、光電変換信号の和が独立して読み出し可能である。また、光電変換信号の和から一方の光電変換部の光電変換信号を減じることで、他方の光電変換部の光電変換信号に相当する信号を得ることができる。個々の光電変換部における光電変換信号は位相差AF用のデータとして用いたり、3D(3−Dimensional)画像を構成する視差画像の生成に用いてもよい。また、光電変換信号の和は、通常の撮影画像データとして用いることができる。
In the
ここで、位相差AFを行う場合の画素信号について説明する。後述するように、本実施形態においては、図2(A)のマイクロレンズ211iと、分割された光電変換部211a,211bで撮影光学系の射出光束を瞳分割する。そして、同一画素行に配置された所定範囲内の複数の画素211について、光電変換部211aの出力をつなぎ合わせて編成したものをAF用A像、光電変換部211bの出力をつなぎ合わせて編成したものをAF用B像とする。光電変換部211a、211bの出力は、カラーフィルタの単位配列に含まれる緑、赤、青、緑の出力を加算して算出した疑似的な輝度(Y)信号を用いる。但し、赤、青、緑の色ごとに、AF用A像、B像を編成してもよい。
Here, the pixel signal when performing phase difference AF will be described. As will be described later, in the present embodiment, the emission light flux of the photographing optical system is pupilly divided by the
このように生成したAF用A像とB像の相対的な像ずれ量を相関演算により検出することで、所定領域の焦点ずれ量(デフォーカス量)を検出することができる。本実施形態では、一方の光電変換部の出力と全光電変換部の出力の和を撮像素子122から読み出すものとする。例えば、光電変換部211aの出力と、光電変換部211a,211bの出力の和とが読み出される場合、光電変換部211bの出力は、和から光電変換部211aの出力を減じることで取得する。これにより、AF用A像とB像の両方を得ることができ、位相差AFが実現できる。このような撮像素子は、公知であるため、これ以上の詳細な説明は省略する。
By detecting the relative image shift amount of the AF image A and B generated in this way by the correlation calculation, the focus shift amount (defocus amount) in the predetermined region can be detected. In the present embodiment, the sum of the output of one photoelectric conversion unit and the output of all photoelectric conversion units is read from the
図2(B)は、本実施形態の撮像素子122の読み出し回路の構成例を示す図である。水平走査回路151、垂直走査回路153の各画素の境界部には、水平走査ライン152a及び152bと、垂直走査ライン154a及び154bが配線され、各光電変換部は、これらの走査ラインを介して信号が外部に読み出される。
FIG. 2B is a diagram showing a configuration example of a readout circuit of the
なお、本実施形態の撮像素子は上述の画素内の読み出し方法に加え、以下の2種類の読み出しモード(第1の読み出しモード及び第2の読み出しモード)を有する。具体的には、第1の読み出しモードは、全画素読み出しモードと称するもので、高精細静止画を撮像するためのモードであり、この場合、全画素の信号が読み出される。 The image sensor of the present embodiment has the following two types of read modes (first read mode and second read mode) in addition to the above-mentioned in-pixel reading method. Specifically, the first read mode is called an all-pixel read mode, which is a mode for capturing a high-definition still image, and in this case, signals of all pixels are read.
第2の読み出しモードは、間引き読み出しモードと称するもので、動画記録、もしくはプレビュー画像の表示のみを行うためのモードである。この場合に必要な画素数は、全画素よりも少ないため、画素群は、X方向及びY方向ともに所定比率に間引いた画素のみ読み出す。また、高速に読み出す必要がある場合にも、同様に間引き読み出しモードを用いる。X方向に間引く際には、信号の加算を行いS/Nの改善を図り、Y方向に対する間引きは、間引かれる行の信号出力を無視する。位相差AFおよびコントラストAFも、通常、第2の読み出しモードで読み出された信号に基づいて行われる。 The second read mode is called a thinning read mode, and is a mode for only recording a moving image or displaying a preview image. Since the number of pixels required in this case is smaller than that of all pixels, the pixel group reads only the pixels thinned out to a predetermined ratio in both the X direction and the Y direction. Also, when it is necessary to read at high speed, the thinning read mode is used in the same manner. When thinning out in the X direction, signals are added to improve S / N, and when thinning out in the Y direction, the signal output of the line to be thinned out is ignored. Phase-difference AF and contrast AF are also usually performed based on the signals read in the second read mode.
図3は、本実施形態の撮像装置において、撮影光学系の射出瞳面と、像高ゼロ、すなわち像面中央近傍に配置された撮像素子の光電変換部の共役関係を説明する図である。撮像素子内の光電変換部と撮影光学系の射出瞳面は、オンチップマイクロレンズによって共役関係となるように設計される。そして、撮影光学系の射出瞳は、一般的に光量調節用の虹彩絞りが置かれる面とほぼ一致する。一方、本実施形態の撮影光学系は、変倍機能を有したズームレンズであるが、光学タイプによっては変倍操作を行うと、射出瞳の像面からの距離や大きさが変化する。図3では、レンズユニット100の焦点距離が広角端と望遠端の中央にある状態を示している。この状態における射出瞳距離Zepを標準値として、オンチップマイクロレンズの形状や、像高(X,Y座標)に応じた偏心パラメータの最適設計がなされる。
FIG. 3 is a diagram for explaining the conjugate relationship between the exit pupil surface of the photographing optical system and the photoelectric conversion unit of the image pickup device arranged at zero image height, that is, near the center of the image surface in the image pickup apparatus of the present embodiment. The photoelectric conversion unit in the image sensor and the exit pupil surface of the photographing optical system are designed to have a conjugate relationship by an on-chip microlens. The exit pupil of the photographing optical system generally coincides with the surface on which the iris diaphragm for adjusting the amount of light is placed. On the other hand, the photographing optical system of the present embodiment is a zoom lens having a scaling function, but depending on the optical type, the distance and size of the exit pupil from the image plane change when the scaling operation is performed. FIG. 3 shows a state in which the focal length of the
図3(A)において、レンズユニット100は、第1レンズ群101を保持する鏡筒部材101b、第3レンズ群105、フォーカスレンズ104を保持する鏡筒部材104bを含む。また、絞り102の開放時の開口径を規定する開口板102a、絞り込み時の開口径を調節するための絞り羽根102bを含む。なお、撮影光学系を通過する光束の制限部材として作用する虚像101b、102a、102b、及び104bは、像面から観察した場合の光学的な虚像を示している。また、絞り102の近傍における合成開口をレンズの射出瞳と定義し、前述したように像面からの距離をZepとしている。
In FIG. 3A, the
画素211は、像面中央近傍に配置されており、本実施形態では、中央画素と呼ぶ。中央画素211は、最下層より、光電変換部211a,211b、配線層211e〜211g、カラーフィルタ211h、及びオンチップマイクロレンズ211iの各部材で構成される。そして、2つの光電変換部は、オンチップマイクロレンズ211iによって撮影光学系の射出瞳面に投影される。すなわち、撮影光学系の射出瞳が、オンチップマイクロレンズ211iを介して、光電変換部の表面に投影される。
The
図3(B)は、撮影光学系の射出瞳面上における、光電変換部の投影像を示したもので、光電変換部211a及び211bに対する投影像は、各々EP1a及びEP1bとなる。また、本実施形態では、撮像素子は、2つの光電変換部211aと211bのいずれか一方の出力と、両方の和の出力を得ることができる画素を有している。両方の和の出力は、撮影光学系のほぼ全瞳領域である投影像EP1a、EP1bの両方の領域を通過した光束を光電変換したものである。
FIG. 3B shows projected images of the photoelectric conversion unit on the exit pupil surface of the photographing optical system, and the projected images on the
図3(A)で、撮影光学系を通過する光束の最外部をLで示すと、光束Lは、絞りの開口板102aで規制されており、投影像EP1a及びEP1bは、撮影光学系でケラレがほぼ発生していない。図3(B)では、図3(A)の光束Lを、TLで示している。TLで示す円の内部に、光電変換部の投影像EP1a、EP1bの大部分が含まれていることからも、ケラレがほぼ発生していないことがわかる。光束Lは、絞りの開口板102aでのみ制限されているため、TLは、102aと言い換えることができる。この際、像面中央では、各投影像EP1a及びEP1bのケラレ状態は、光軸に対して対称となり、各光電変換部211a及び211bが受光する光量は等しい。
In FIG. 3A, when the outermost light flux passing through the photographing optical system is indicated by L, the luminous flux L is regulated by the
位相差AFを行う場合、カメラMPU125は、撮像素子122から上述した2種類の出力を読み出すようにセンサ駆動回路123を制御する。そして、カメラMPU125は、画像処理回路124に対して焦点検出領域の情報を与え、焦点検出領域内に含まれる画素の出力から、AF用A像およびB像のデータを生成して位相差AF部129に供給するよう命令する。画像処理回路124は、この命令に従ってAF用A像およびB像のデータを生成して位相差AF部129に出力する。また、画像処理回路124は、TVAF部130に対してRAW画像データを供給する。
When performing phase-difference AF, the
以上のように、撮像素子122は、位相差AFおよびコントラストAFの両方について、焦点検出装置の一部を構成している。なお、本実施形態では、一例として水平方向に射出瞳を2分割する構成を説明したが、撮像素子一部の画素については、垂直方向に射出瞳を2分割する構成としてもよい。また、水平および垂直の両方向に射出瞳を分割する構成としてもよい。垂直方向に射出瞳を分割する画素を設けることにより、水平だけでなく垂直方向の被写体のコントラストに対応した位相差AFが可能となる。
As described above, the
(焦点検出動作の説明:コントラストAF)
次に、図4を用いて、コントラストAF(TVAF)について説明する。コントラストAFは、カメラMPU125とTVAF部130が連携してフォーカスレンズの駆動と評価値の算出を繰り返し行うことで実現される。まず、画像処理回路124からRAW画像データがTVAF部130に入力されると、AF評価用信号処理回路401で、ベイヤー配列信号からの緑(G)信号の抽出と、低輝度成分を強調して高輝度成分を抑圧するガンマ補正処理が施される。本実施形態では、TVAFを緑(G)信号で行う場合を説明するが、赤(R)、青(B)、緑(G)の全ての信号を用いてもよい。また、RGB全色用いて輝度(Y)信号を生成してもよい。AF評価用信号処理回路401で生成される出力信号は、用いられた信号の種類によらず、以後の説明では、輝度信号Yと呼ぶ。
(Explanation of focus detection operation: Contrast AF)
Next, contrast AF (TVAF) will be described with reference to FIG. Contrast AF is realized by the
なお、カメラMPU125から、領域設定回路413に焦点検出領域が設定されているものとする。領域設定回路413は、設定された領域内の信号を選択するゲート信号を生成する。ゲート信号は、ラインピーク検出回路402、水平積分回路403、ライン最小値検出回路404、ラインピーク検出回路409、垂直積分回路406、410、垂直ピーク検出回路405、407、411の各回路に入力される。また、各焦点評価値が焦点検出領域内の輝度信号Yで生成されるように、輝度信号Yが各回路に入力するタイミングが制御される。なお、領域設定回路413には、焦点検出領域に合わせて複数の領域が設定可能である。
It is assumed that the focus detection region is set in the
次に、Yピーク評価値の算出方法について説明する。ガンマ補正された輝度信号Yは、ラインピーク検出回路402へ入力され、領域設定回路413に設定された焦点検出領域内で水平ラインごとのYラインピーク値が求められる。ラインピーク検出回路402の出力は、垂直ピーク検出回路405において焦点検出領域内で垂直方向にピークホールドされ、Yピーク評価値が生成される。Yピーク評価値は、高輝度被写体や低照度被写体の判定に有効な指標である。
Next, a method of calculating the Y peak evaluation value will be described. The gamma-corrected luminance signal Y is input to the line
次に、Y積分評価値の算出方法について説明する。ガンマ補正された輝度信号Yは、水平積分回路403へ入力され、焦点検出領域内で水平ラインごとにYの積分値が求められる。さらに、水平積分回路403の出力は、垂直積分回路406において焦点検出領域内で垂直方向に積分されて、Y積分評価値が生成される。Y積分評価値は、焦点検出領域内全体の明るさを判断する指標として用いることができる。
Next, a method of calculating the Y integral evaluation value will be described. The gamma-corrected luminance signal Y is input to the
次に、Max−Min評価値の算出方法について説明する。ガンマ補正された輝度信号Yは、ラインピーク検出回路402に入力され、焦点検出領域内で水平ラインごとのYラインピーク値が求められる。また、ガンマ補正された輝度信号Yは、ライン最小値検出回路404に入力され、焦点検出領域内で水平ラインごとに輝度信号Yの最小値が検出される。検出された水平ラインごとの輝度信号Yのラインピーク値及び最小値は、減算器に入力され、(ラインピーク値−最小値)が垂直ピーク検出回路407に入力される。垂直ピーク検出回路407は、焦点検出領域内で垂直方向にピークホールドを行い、Max−Min評価値を生成する。Max−Min評価値は、低コントラスト・高コントラストの判定に有効な指標である。
Next, a method of calculating the Max-Min evaluation value will be described. The gamma-corrected luminance signal Y is input to the line
次に、領域ピーク評価値の算出方法について説明する。ガンマ補正された輝度信号Yは、BPF408に通すことによって特定の周波数成分が抽出され焦点信号が生成される。この焦点信号は、ラインピーク検出回路409へ入力され、焦点検出領域内で水平ラインごとのラインピーク値が求められる。ラインピーク値は、垂直ピーク検出回路411によって焦点検出領域内でピークホールドされ、領域ピーク評価値が生成される。領域ピーク評価値は、焦点検出領域内で被写体が移動しても変化が少ないので、合焦状態から再度合焦点を探す処理に移行するかどうかを判定する再起動判定に有効な指標である。
Next, a method of calculating the region peak evaluation value will be described. The gamma-corrected luminance signal Y is passed through the
次に、全ライン積分評価値の算出方法について説明する。領域ピーク評価値と同様に、ラインピーク検出回路409は、焦点検出領域内で水平ラインごとのラインピーク値を求める。信号がラインピーク値を垂直積分回路410に入力し、焦点検出領域内で垂直方向に全水平走査ライン数について積分して全ライン積分評価値を生成する。高周波全ライン積分評価値は、積分の効果でダイナミックレンジが広く、感度が高いので、主要なAF評価値である。従って、本実施形態では、単に焦点評価値と記載した場合は、全ライン積分評価値を意味する。
Next, a method of calculating the total line integral evaluation value will be described. Similar to the region peak evaluation value, the line
カメラMPU125のAF制御部151は、上述したそれぞれの焦点評価値を取得し、レンズMPU117を通じてフォーカスレンズ104を光軸方向に沿って所定方向に所定量移動させる。そして、新たに得られた画像データに基づいて上述した各種の評価値を算出し、全ライン積分評価値が最大値となるフォーカスレンズ位置を検出する。本実施形態では、各種のAF用評価値を水平ライン方向および垂直ライン方向で算出する。これにより、水平、垂直の直交する2方向の被写体のコントラスト情報に対して焦点検出を行うことができる。
The
(焦点検出処理の流れの説明)
次に、本実施形態のデジタルカメラにおける自動焦点検出(AF)動作について説明する。AF処理の概要を説明した後、詳細な説明を行う。本実施形態では、まず、カメラMPU125は、後述する焦点検出領域について、位相差AFもしくはコントラストAFを適用して焦点ずれ量(デフォーカス量)を求める。いずれかの方法により焦点検出を終えると、カメラMPU125は、自動焦点検出の結果を補正するための焦点検出補正値を算出し、焦点検出結果を補正する。そして、カメラMPU125は、補正後の焦点検出結果に基づいてフォーカスレンズ104を駆動する。
(Explanation of the flow of focus detection processing)
Next, the automatic focus detection (AF) operation in the digital camera of the present embodiment will be described. After explaining the outline of the AF process, a detailed explanation will be given. In the present embodiment, first, the
次に、上述したAF処理の詳細を、図5および図6に示すフローチャートを用いて説明する。図5は、AF処理全体のフローを、図6は図5のステップS5における自動焦点検出の結果を補正するための焦点検出補正値を算出するフローを示している。以下のAF処理動作は、他の主体が明記されている場合を除き、カメラMPU125が主体となって実行される。また、カメラMPU125がレンズMPU117にコマンド等を送信することによってレンズユニット100の駆動や制御を行う場合、説明を簡潔にするために動作主体をカメラMPU125として記載する場合がある。
Next, the details of the AF process described above will be described with reference to the flowcharts shown in FIGS. 5 and 6. FIG. 5 shows the flow of the entire AF process, and FIG. 6 shows the flow of calculating the focus detection correction value for correcting the result of the automatic focus detection in step S5 of FIG. The following AF processing operations are mainly executed by the
まず、ステップS1で、カメラMPU125は、焦点検出領域を設定する。ここで設定される焦点検出領域219は、図7に示す主被写体220によって決められるものでもよく、予め設定された焦点検出領域でもよい。本実施形態では、焦点検出領域に対して、焦点検出領域219を代表する座標(x1、y1)を設定する。この時の代表座標(x1、y1)は、例えば、焦点検出領域219に対する重心位置に合わせてもよい。
First, in step S1, the
次に、ステップS2で、カメラMPU125は、自動焦点検出に用いる焦点検出信号を取得する。自動焦点検出が位相差AFの場合には、同一画素行に配置された所定範囲内の複数の画素211について、光電変換部211aの出力をつなぎ合わせて編成したAF用A像、光電変換部211bの出力をつなぎ合わせて編成したAF用B像を取得する。自動焦点検出がコントラストAFの場合には、画像処理回路124からRAW画像データをTVAF部130に入力する。そして、AF評価用信号処理回路401で、ベイヤー配列信号からの緑(G)信号の抽出と、低輝度成分を強調して高輝度成分を抑圧するガンマ補正処理が施した信号を取得する。
Next, in step S2, the
次に、ステップS3で、カメラMPU125は、上述した位相差AFまたはコントラストAFの処理に基づいて焦点検出を行う。次に、S4で、カメラMPU125は、焦点検出補正値の算出に必要な補正値算出条件を取得する。焦点検出補正値は、フォーカスレンズ104の位置、ズーム状態を示す第1レンズ群101の位置、焦点検出領域の位置座標(x1、y1)など、撮影光学系の変化や焦点検出光学系の変化に伴い変化する。そのため、カメラMPU125は、ステップS2で、例えば、フォーカスレンズ104の位置、ズーム状態を示す第1レンズ群101の位置、及び焦点検出領域の位置座標(x1、y1)などの情報を取得する。この他にも、焦点状態を評価するコントラストの方向(水平、垂直)と色(赤、緑、青)、空間周波数の各組み合わせに応じて焦点検出補正値は、変化する。そのため、後述の図8(D)に示すようなコントラストの方向(水平、垂直)と色(赤、緑、青)、空間周波数の各組み合わせに対する、重み付けの大きさなどの情報も取得する。
Next, in step S3, the
次に、ステップS5で、カメラMPU125は、自動焦点検出の結果を補正するための焦点検出補正値を演算する。具体的には、撮影画像の画像特性または評価特性から算出される撮像合焦位置と、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置との差分と、位相差補正情報から算出される位相差焦点検出合焦位置とから、焦点検出補正値を演算する。撮影画像の画像特性または評価特性、焦点検出手段の焦点検出特性の詳細については後述する。なお、カメラMPU125は、焦点検出補正量算出手段として機能する。また、ステップS5における焦点検出補正値算出方法の詳細については、図6を用いて後述する。
Next, in step S5, the
次に、ステップS6で、カメラMPU125は、ステップS5で算出された自動焦点検出の結果を補正するための補正値(BP)を用いて以下の式により焦点検出結果DEF_0を補正し、補正後の焦点検出結果DEFを算出する。
DEF=DEF_0+BP
Next, in step S6, the
DEF = DEF_0 + BP
次に、ステップS7で、カメラMPU125は、補正後の焦点検出結果DEFの合焦位置へフォーカスレンズ104を駆動する。なお、カメラMPU125は、制御手段として機能する。次に、ステップS8で、カメラMPU125は合焦判定を行い、合焦でないと判定された場合(NO)、ステップS1へ処理を進め、合焦と判定された場合(YES)、AF処理を終了する。
Next, in step S7, the
(焦点検出補正値算出の説明)
以下、図5を用いて上述したAF処理全体のフローのステップS5における自動焦点検出の結果を補正するための焦点検出補正値の算出について図6を用いて説明する。なお、ステップS101〜S104は、撮像合焦位置と焦点検出合焦位置との差分である第1補正値の算出に関する処理であり、ステップS107〜S111は、焦点検出合焦位置と位相差焦点検出合焦位の差分である第2補正値の算出に関する処理である。
(Explanation of focus detection correction value calculation)
Hereinafter, the calculation of the focus detection correction value for correcting the result of the automatic focus detection in step S5 of the flow of the entire AF process described above with reference to FIG. 5 will be described with reference to FIG. Steps S101 to S104 are processes related to calculation of the first correction value which is the difference between the imaging in-focus position and the focus detection in-focus position, and steps S107 to S111 are the focus detection in-focus position and the phase difference focus detection. This is a process related to the calculation of the second correction value, which is the difference in the in-focus position.
まず、ステップS101(取得工程)で、カメラMPU125は、収差情報を取得する。本実施形態での収差情報は、光学系の収差状態を表す情報であり、例えば、被写体の色、方向、空間周波数ごとの撮影光学系の結像位置に関する情報である。
First, in step S101 (acquisition step), the
ここで、図8(A)、図8(B)を用いてレンズメモリ118に格納されている空間周波数収差情報について説明する。図8(A)は、撮影光学系のデフォーカスMTFを示している。横軸は、フォーカスレンズ104の位置を示しており、縦軸は、MTFの強度を示している。図8(A)に描かれている4種の曲線は、空間周波数ごとのMTF曲線で、MTF1、MTF2、MTF3、MTF4の順に、空間周波数が低い方から高い方に変化した場合を示している。空間周波数F1(lp/mm)のMTF曲線がMTF1と対応し、同様に、空間周波数F2、F3、F4(lp/mm)とMTF2、MTF3、MTF4が対応する。また、LP4、LP5、LP6、LP7は、各デフォーカスMTF曲線の極大値に対応するフォーカスレンズ104位置を示している。
Here, the spatial frequency aberration information stored in the
図8(B)は、本実施形態における収差情報を示す図である。図8(B)は、図8(A)のデフォーカスMTFの極大値を示すフォーカスレンズ104位置の情報MTF_P_RHの式を示している。本実施形態での収差情報は、例えば、上述した色と方向との6通りの組み合わせの各々について、空間周波数fと撮像素子上の焦点検出領域の位置座標(x1,y1)を変数とした以下の式で表現される。
MTF_P_RH(f,x,y)=(rh(0)×x+rh(1)×y+rh(2))×f2+(rh(3)×x+rh(4)×y+rh(5))×f+(rh(6)×x+rh(7)×y+rh(8)) (1)
FIG. 8B is a diagram showing aberration information in this embodiment. FIG. 8B shows the equation of the information MTF_P_RH of the
MTF_P_RH (f, x, y) = (rh (0) x x + rh (1) x y + rh (2)) x f2 + (rh (3) x x + rh (4) x y + rh (5)) x f + (rh (6)) × x + rh (7) × y + rh (8)) (1)
なお、式(1)は、赤(R)色の信号について水平(H)方向に対応した空間周波数ごとのデフォーカスMTFの極大値を示すフォーカスレンズ104位置の情報MTF_P_RHの式を示しているが、他の組み合わせについても同様の式で表される。また、本実施形態において、rh(n)(0≦n≦8)は、レンズユニット100のレンズメモリ118にあらかじめ記憶され、カメラMPU125は、レンズMPU117に要求してrh(n)(0≦n≦8)を取得するものとする。しかし、rh(n)(0≦n≦8)は、カメラRAM125bの不揮発性領域に記憶されていてもよい。
The equation (1) shows the equation of the information MTF_P_RH of the
また、第1補正値の製造誤差への対応として、rh(n)に対する第1補正値の製造誤差補正情報rhd(n)をレンズメモリ118またはカメラRAM125bの不揮発性領域に記憶する。第1補正値の製造誤差補正を行う場合には、レンズメモリ118またはカメラRAM125bの不揮発性領域よりrhd(n)を取得し、rh(n)にrhd(n)を加算し、製造誤差補正を行う。なお、カメラMPU125は、本実施形態の第1製造誤差補正手段として機能する。
Further, as a response to the manufacturing error of the first correction value, the manufacturing error correction information rhd (n) of the first correction value with respect to rh (n) is stored in the non-volatile region of the
赤と垂直(MTF_P_RV)、緑と水平(MTF_P_GH)、緑と垂直(MTF_P_GV)、青と水平(MTF_P_BH)、青と垂直(MTF_P_BV)の各組み合わせにおける係数(rv,gh,gv,bh,bv)も同様に記憶、取得できる。このように、収差情報を関数化し、各項の係数を収差情報として記憶することでレンズメモリ118やカメラRAM125bのデータ量削減しつつ、撮影光学系の変化や焦点検出光学系の変化に対応した収差情報の記憶が可能になる。
Coefficients (rv, gh, gv, bh, bv) in each combination of red and vertical (MTF_P_RV), green and horizontal (MTF_P_GH), green and vertical (MTF_P_GV), blue and horizontal (MTF_P_BH), blue and vertical (MTF_P_BV) Can be memorized and acquired in the same way. In this way, by converting the aberration information into a function and storing the coefficients of each term as aberration information, the amount of data in the
また、図8(D)は、図5のステップS4で取得した補正値算出条件の焦点状態を評価するコントラストの方向(水平、垂直)と色(赤、緑、青)、空間周波数の各組み合わせに対する、重み付けの大きさに関する例を示す。図8(D)に示す条件は、撮影画像の画像特性もしくは評価特性から算出される撮像合焦位置、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置の算出に用いる重み付け係数である。 Further, FIG. 8D shows a combination of contrast direction (horizontal, vertical), color (red, green, blue), and spatial frequency for evaluating the focal state of the correction value calculation condition acquired in step S4 of FIG. An example of the magnitude of the weighting is shown. The conditions shown in FIG. 8D are the weighting coefficient used to calculate the imaging in-focus position calculated from the image characteristics or evaluation characteristics of the captured image and the focus detection in-focus position calculated from the focus detection characteristics of the focus detection means. is there.
ここで、図6に戻って、ステップS102、ステップS103では、カメラMPU125は、ステップS4で取得した図8(D)に示す重みづけの係数と、ステップS101で取得された収差情報から、各合焦位置を算出する。つまり、撮影画像の画像特性または評価特性から算出される撮像合焦位置(P_IMG)、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)を算出する。なお、カメラMPU125は、本実施形態の合焦位置算出手段として機能する。具体的には、まず、式(1)のx,yに焦点検出領域の位置情報(x1、y1)を代入する。この計算により式(1)は、以下の式(2)のような形式で表される。
MTF_P_RH(f)=Arh×f2+Brh×f+Crh (2)
Here, returning to FIG. 6, in step S102 and step S103, the
MTF_P_RH (f) = Arh × f2 + Brh × f + Chr (2)
カメラMPU125は、MTF_P_RV(f)、MTF_P_GH(f)、MTF_P_GV(f)、MTF_P_BH(f)、MTF_P_BV(f)についても同様に計算する。図8(B)は、ステップS1で焦点検出領域の位置情報を代入した後の収差情報の例を示し、横軸は空間周波数を、縦軸は、デフォーカスMTFの極大値を示すフォーカスレンズ104の位置(ピーク位置)である。図示の通り、色収差が大きい場合には、色ごとの曲線が乖離し、縦横差が大きい場合には、図中の水平方向と垂直方向の曲線が乖離する。このように、本実施形態では、色(RGB)と評価方向(HとV)との組み合わせごとに、空間周波数に対応したデフォーカスMTF情報を有する。
The
次に、カメラMPU125は、ステップS4で取得している補正値算出条件の合焦位置の算出に用いる重み付け係数を構成する係数(図8(D))で、収差情報を重み付けする。これにより、設定情報が、焦点検出、撮像で評価する色、方向に関して重み付けされる。具体的には、カメラMPU125は、焦点検出用の空間周波数特性MTF_P_AF(f)と撮影画像用の空間周波数特性MTF_P_IMG(f)を、式(3)および式(4)を用いて算出する。
MTF_P_AF(f)=
K_AF_R×K_AF_H×MTF_P_RH(f)
+K_AF_R×K_AF_V×MTF_P_RV(f)
+K_AF_G×K_AF_H×MTF_P_GH(f)
+K_AF_G×K_AF_V×MTF_P_GV(f)
+K_AF_B×K_AF_H×MTF_P_BH(f)
+K_AF_B×K_AF_V×MTF_P_BV(f) (3)
MTF_P_IMG(f)=
K_IMG_R×K_IMG_H×MTF_P_RH(f)
+K_IMG_R×K_IMG_V×MTF_P_RV(f)
+K_IMG_G×K_IMG_H×MTF_P_GH(f)
+K_IMG_G×K_IMG_V×MTF_P_GV(f)
+K_IMG_B×K_IMG_H×MTF_P_BH(f)
+K_IMG_B×K_IMG_V×MTF_P_BV(f) (4)
Next, the
MTF_P_AF (f) =
K_AF_R x K_AF_H x MTF_P_RH (f)
+ K_AF_R x K_AF_V x MTF_P_RV (f)
+ K_AF_G x K_AF_H x MTF_P_GH (f)
+ K_AF_G x K_AF_V x MTF_P_GV (f)
+ K_AF_B x K_AF_H x MTF_P_BH (f)
+ K_AF_B x K_AF_V x MTF_P_BV (f) (3)
MTF_P_IMG (f) =
K_IMG_R x K_IMG_H x MTF_P_RH (f)
+ K_IMG_R x K_IMG_V x MTF_P_RV (f)
+ K_IMG_G x K_IMG_H x MTF_P_GH (f)
+ K_IMG_G x K_IMG_V x MTF_P_GV (f)
+ K_IMG_B x K_IMG_H x MTF_P_BH (f)
+ K_IMG_B x K_IMG_V x MTF_P_BV (f) (4)
図8(C)には、離散的な空間周波数F1からF4について、式(3)に代入して得られるデフォーカスMTFがピーク(極大値)となるフォーカスレンズ位置(ピーク位置)LP4_AF、LP5_AF、LP6_AF、LP7_AFが縦軸に示されている。カメラMPU125は、撮影画像の画像特性または評価特性から算出される撮像合焦位置(P_IMG)と焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)を、以下の式(5)および(6)に従って算出する。
In FIG. 8C, focus lens positions (peak positions) LP4_AF, LP5_AF, in which the defocus MTF obtained by substituting the discrete spatial frequencies F1 to F4 into the equation (3) has a peak (maximum value), are shown. LP6_AF and LP7_AF are shown on the vertical axis. The
焦点検出合焦位置の算出は、式(3)および式(4)で得た図8(C)で示す空間周波数ごとのデフォーカスMTFの極大値情報と、ステップS4でステップS4で得た撮影画像やAFの評価帯域で重みづけ加算する。すなわち、空間周波数ごとのデフォーカスMTFの極大値情報MTF_P_AF(f)、MTF_P_IMG(f)と、ステップS4で得た撮影画像やAFの評価帯域K_IMG_FQ(n),K_AF_FQ(n)で重みづけ加算する。
P_IMG=MTF_P_IMG(1)×K_IMG_FQ(1)+MTF_P_IMG(2)×K_IMG_FQ(2)+MTF_P_IMG(3)×K_IMG_FQ(3)+MTF_P_IMG(4)×K_IMG_FQ(4) (5)
P_AF=MTF_P_AF(1)×K_AF_FQ(1)+MTF_P_AF(2)×K_AF_FQ(2)+MTF_P_AF(3)×K_AF_FQ(3)+MTF_P_AF(4)×K_AF_FQ(4) (6)
The focus detection focusing position is calculated by using the maximum value information of the defocus MTF for each spatial frequency shown in FIGS. 8 (C) obtained by the equations (3) and (4) and the imaging obtained in step S4 in step S4. Weight and add in the evaluation band of the image and AF. That is, the maximum value information MTF_P_AF (f) and MTF_P_IMG (f) of the defocus MTF for each spatial frequency are weighted and added by the captured image obtained in step S4 and the evaluation band K_IMG_FQ (n) and K_AF_FQ (n) of AF. ..
P_IMG = MTF_P_IMG (1) x K_IMG_FQ (1) + MTF_P_IMG (2) x K_IMG_FQ (2) + MTF_P_IMG (3) x K_IMG_FQ (3) + MTF_P_IMG (4) x K_IMG_FQ (4) (5)
P_AF = MTF_P_AF (1) x K_AF_FQ (1) + MTF_P_AF (2) x K_AF_FQ (2) + MTF_P_AF (3) x K_AF_FQ (3) + MTF_P_AF (4) x K_AF_FQ (4) (6)
ここで、撮影画像の画像特性または評価特性、焦点検出手段の焦点検出特性について説明する。撮影画像の画像特性または評価特性は、撮影画像を評価する際の特性、つまり人の目で見る際の評価に対する特性を意味している。焦点検出手段の焦点検出特性は、焦点検出する際の特性、つまりAF処理の際に評価する特性を意味している。 Here, the image characteristics or evaluation characteristics of the captured image and the focus detection characteristics of the focus detection means will be described. The image characteristic or evaluation characteristic of the captured image means a characteristic when evaluating the captured image, that is, a characteristic for evaluation when viewed by the human eye. The focus detection characteristic of the focus detection means means a characteristic at the time of focus detection, that is, a characteristic to be evaluated at the time of AF processing.
具体的な例を以下に示す。図8(D)に示す焦点検出情報による重みづけの係数、K_AF_H、K_AF_V、K_IMG_H、K_IMG_Vに関して、焦点検出方向が図3(B)のような瞳分割形状で水平H方向のみの場合、
K_AF_H=1
K_AF_V=0
K_IMG_H=0.5
K_IMG_V=0.5
と設定する。これは、AF処理によるピント位置評価は水平方向Hによる収差に寄与するところが大きく、人の目で見る際のピント位置評価は水平方向Hと垂直方法Vを1:1で平均した収差状態でピント位置を判断することが一般的であるためである。
A specific example is shown below. Regarding the weighting coefficients K_AF_H, K_AF_V, K_IMG_H, and K_IMG_V based on the focus detection information shown in FIG. 8 (D), when the focus detection direction is the pupil division shape as shown in FIG.
K_AF_H = 1
K_AF_V = 0
K_IMG_H = 0.5
K_IMG_V = 0.5
And set. This is because the focus position evaluation by AF processing largely contributes to the aberration due to the horizontal direction H, and the focus position evaluation when viewed by the human eye is focused in the aberration state in which the horizontal direction H and the vertical method V are averaged at a ratio of 1: 1. This is because it is common to determine the position.
色の重みづけ係数K_AF_R、K_AF_G、K_AF_B、K_IMG_R、K_IMG_G、K_IMG_Bに関しては、例えば、
K_AF_R=0.25
K_AF_G=0.5
K_AF_B=0.25
K_IMG_R=0.3
K_IMG_G=0.5
K_IMG_B=0.2
と設定する。これは焦点検出時には、ベイヤー配列のセンサより取得した信号に基づきピント位置を評価するが、撮像画像は所望のホワイトバランス係数によって与えられた重みづけの各色の色収差による影響でピント位置が変動することに因る。
Regarding the color weighting coefficients K_AF_R, K_AF_G, K_AF_B, K_IMG_R, K_IMG_G, K_IMG_B, for example,
K_AF_R = 0.25
K_AF_G = 0.5
K_AF_B = 0.25
K_IMG_R = 0.3
K_IMG_G = 0.5
K_IMG_B = 0.2
And set. At the time of focus detection, the focus position is evaluated based on the signal acquired from the sensor of the Bayer array, but the captured image fluctuates due to the influence of the chromatic aberration of each weighted color given by the desired white balance coefficient. Due to.
空間周波数の重みづけ係数K_AF_fq(1)〜K_AF_fq(4)、K_IMG_fq(1)〜K_IMG_fq(4)に関しては、例えば、
AF_fq(1)=0.8
AF_fq(2)=0.2
AF_fq(3)=0
AF_fq(4)=0
K_IMG_fq(1)=0
K_IMG_fq(2)=0
K_IMG_fq(3)=0.5
K_IMG_fq(4)=0.5
と設定する。これは、一般的に、焦点検出時には、ピント位置を空間周波数の低い帯域で評価しており、撮像画像は、ピント位置を空間周波数の高い帯域で評価しているためである。
Regarding the spatial frequency weighting coefficients K_AF_fq (1) to K_AF_fq (4) and K_IMG_fq (1) to K_IMG_fq (4), for example,
AF_fq (1) = 0.8
AF_fq (2) = 0.2
AF_fq (3) = 0
AF_fq (4) = 0
K_IMG_fq (1) = 0
K_IMG_fq (2) = 0
K_IMG_fq (3) = 0.5
K_IMG_fq (4) = 0.5
And set. This is because, in general, the focus position is evaluated in the band having a low spatial frequency at the time of focus detection, and the focused image is evaluated in the band having a high spatial frequency in the captured image.
ここで、図6に戻って、ステップS104(第1算出工程)では、カメラMPU125は、焦点検出補正値(BP)の被写体の色、方向、空間周波数に依存する成分である第1補正値(BP1)を、以下の式(7)により算出する。
BP1=P_AF−P_IMG (7)
Here, returning to FIG. 6, in step S104 (first calculation step), the
BP1 = P_AF-P_IMG (7)
本実施形態では、焦点検出領域の位置、評価信号の色やコントラスト方向に関する処理を、評価帯域に関する処理よりも先行して実行している。これは、撮影者が焦点検出領域の位置を設定により決定している場合、焦点検出領域の位置や、評価する色や方向に関する情報が変更される頻度が低いためである。一方で、信号の評価帯域については、撮像素子の読出しモードやAF評価信号のデジタルフィルタなどにより変更される頻度が高い。例えば、信号のS/Nが低下する低照度環境では、デジタルフィルタの帯域をより低帯域に変更することなどが考えられる。本実施形態では、このような場合に、変更の頻度が低い係数(ピーク係数)を算出した後に記憶し、変更の頻度の高い係数(評価帯域)のみを必要に応じて計算し、第1補正値算出を行う。これにより、撮影者が焦点検出領域の位置を設定している場合などには、演算量の低減を行うことができる。 In the present embodiment, the processing related to the position of the focus detection region, the color of the evaluation signal, and the contrast direction is executed prior to the processing related to the evaluation band. This is because when the photographer determines the position of the focus detection area by setting, the information regarding the position of the focus detection area and the color and direction to be evaluated is rarely changed. On the other hand, the signal evaluation band is frequently changed by the read mode of the image sensor, the digital filter of the AF evaluation signal, and the like. For example, in a low-light environment where the signal S / N decreases, it is conceivable to change the band of the digital filter to a lower band. In this embodiment, in such a case, a coefficient with a low frequency of change (peak coefficient) is calculated and then stored, and only a coefficient with a high frequency of change (evaluation band) is calculated as necessary, and the first correction is performed. Calculate the value. As a result, the amount of calculation can be reduced when the photographer has set the position of the focus detection region.
次に、ステップS105で、第1補正値の製造誤差補正情報をステート毎に保持し、焦点検出条件に応じた製造誤差補正情報を取得し製造誤差補正を行う。なお、第1補正値の製造誤差補正情報を、特定のステートでのみ保持し、保持していないステートに関しては、第1補正値のステート間での変化率から算出してもよい。 Next, in step S105, the manufacturing error correction information of the first correction value is held for each state, the manufacturing error correction information corresponding to the focus detection condition is acquired, and the manufacturing error correction is performed. The manufacturing error correction information of the first correction value may be held only in a specific state, and the state not held may be calculated from the rate of change between the states of the first correction value.
(焦点検出補正値算出の説明)
次に、ステップS106で、カメラMPU125は、焦点検出方式の判定を行い、ステップS3での焦点検出方式が位相差AFの場合(YES)、ステップS107へ進み、位相差AFでない場合(NO)、ステップS114に進む。つまり、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置と位相差焦点検出(位相差AF)が検出する位相差焦点検出合焦位置の差分であるBP2を、BP2=0としてステップS114へ進む。このように、焦点検出方式を判定し焦点検出補正値を算出することで、焦点検出方式に応じてピントずれ量を高精度に補正することを可能としている。
(Explanation of focus detection correction value calculation)
Next, in step S106, the
次に、S107で、カメラMPU125は、補正値算出条件の判定を行う。そして、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)と位相差AFが検出する位相差焦点検出合焦位置(P_AF2)の差分が小さい条件の場合(YES)、ステップS114へ進む。つまり、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置と位相差AFが検出する位相差焦点検出合焦位置の差分であるBP2を、BP2=0としてステップS114へ進む。一方、小さい条件でない場合(NO)、ステップS108へ進む。
Next, in S107, the
以下、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)と位相差AFが検出する位相差焦点検出合焦位置(P_AF2)の差分が小さい条件について説明する。位相差AFは、デフォーカスによる線像強度分布の重心ずれ量を検出し、合焦位置を算出する。ここで、図9は、デフォーカスによる線像強度分布の重心ずれ量を説明するための図である。図9は、重心ずれ量、相関演算結果(線像強度分布の位置ずれ量)の少なくとも1つに差を与える収差(以下コマ収差等の収差)、絞り102等によるケラレがない状態である。図9に示す状態の場合、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)と位相差AFが検出する位相差焦点検出合焦位置(P_AF2)に差分が生じない。
Hereinafter, the condition that the difference between the focus detection focusing position (P_AF) calculated from the focus detection characteristic of the focus detection means and the phase difference focus detection focus position (P_AF2) detected by the phase difference AF is small will be described. The phase difference AF detects the amount of deviation of the center of gravity of the line image intensity distribution due to defocus and calculates the in-focus position. Here, FIG. 9 is a diagram for explaining the amount of deviation of the center of gravity of the line image intensity distribution due to defocus. FIG. 9 shows a state in which there is no vignetting due to the amount of deviation of the center of gravity, the aberration (hereinafter referred to as aberration such as coma) that gives a difference to at least one of the correlation calculation results (the amount of displacement of the line image intensity distribution), and the
デフォーカス位置1201_P、1202_Pはそれぞれ異なる位置を示す。一対の線像強度分布1201_A、1201_Bは、デフォーカス位置1201_Pにおける分割された光電変換部211a、211bに対応した一対の線像強度分布で示す。一対の線像強度分布1202_A、1202_Bは、デフォーカス位置1202_Pにおける分割された光電変換部211a、211bに対応した一対の線像強度分布を示す。また、重心位置1201_GA、1201_GBは、一対の線像強度分布1201_A、1201_Bの重心位置を示す。重心位置1202_GA、1202_GBは、一対の線像強度分布1202_A、1202_Bの重心位置示す。さらに、重心ずれ量1201_difGは、重心位置1201_GA、1201_GBの差分を、重心ずれ量1202_difGは、重心位置1202_GA、1202_GBの差分を示す。また、図9に示すように、コマ収差等の収差、絞り102等によるケラレがない場合には、デフォーカスに応じて、重心ずれ量1201_difG、1202_difGが大きくなる。これら重心ずれ量を検出することで、位相差AFはデフォーカス量を算出している。
The defocus positions 1201_P and 1202_P indicate different positions. The pair of line image intensity distributions 1201_A and 1201_B are shown by a pair of line image intensity distributions corresponding to the divided
次に、撮影光学系のコマ収差等の収差、絞り102等によるケラレが大きい場合について説明する。図10に、撮影光学系のコマ収差等の収差、絞り102等によるケラレが大きい場合の一対の線像強度分布を示す。図10の点線で示す1301_Aは、光電変換部211aに対応する線像強度分布を、実線で示す1301_Bは、光電変換部211bに対応する線像強度分布を示す。また、一点鎖線G_Aが1301_Aの重心位置を、一点鎖線G_Bが1301_Bの重心位置を示す。図10に示すように線像強度分布1301_A、1301_Bは、光学系のコマ収差等の収差の影響を受け線像強度分布が片側に尾を引いたような非対称形状となっている。このように、線像強度分布が片側に尾を引いたような非対称形状の場合、線像強度分布の重心位置が尾を引いた側に引っ張られ、重心ずれが生じる。
Next, a case where aberrations such as coma of the photographing optical system and vignetting due to the
また、線像強度分布1301_Aおよび1301_Bは、撮影光学系の絞り102等によるケラレの影響を受け、線像強度分布間で光量差が生じる。そして、よりケラレの大きい線像強度分布1301_Aの方がコマ収差等の収差の影響を大きく受け、非対称度合いが大きくなる。このように、非対称度合いが線像強度分布1301_Aおよび線像強度分布1301_Bで異なることで、それぞれの重心位置G_AおよびG_Bのずれ量が異なり、重心ずれ量差が生じる。
Further, the line image intensity distributions 1301_A and 1301_B are affected by vignetting due to the
線像強度分布1301_IMGは、線像強度分布1301_Aおよび1301_Bを足し合わせた、光電変換部211a、211bの光電変換信号の和に対応した線像強度分布を示す。デフォーカス位置が異なり、点線で示す1302_Aの線像強度分布と、実線で示す1301_Bの線像強度分布の重心位置が一致した状態を表している。線像強度分布1302_IMGは、線像強度分布1302_Aおよび1302_Bを足し合わせた線像強度分布を表している。
The line image intensity distribution 1301_IMG shows a line image intensity distribution corresponding to the sum of the photoelectric conversion signals of the
線像強度分布1301_IMGと線像強度分布1302_IMG比較すると、重心位置の異なる線像強度分布の和の1301_IMGの方が、重心位置が一致した線像強度分布の和の1302_IMGよりも線像強度分布形状がシャープであることがわかる。撮影画像の信号に対応する線像強度分布1301_IMG、1302_IMGの形状が最もシャープである位置が、合焦位置を意味している。そのため、重心位置の異なる状態が合焦位置であり、重心位置が一致した状態は合焦位置からデフォーカスした位置であるといえる。 Comparing the line image intensity distribution 1301_IMG and the line image intensity distribution 1302_IMG, the line image intensity distribution shape of 1301_IMG, which is the sum of the line image intensity distributions with different center of gravity positions, is larger than that of the line image intensity distribution sum 1302_IMG, which has the same center of gravity position. Can be seen to be sharp. The position where the shape of the line image intensity distribution 1301_IMG and 1302_IMG corresponding to the signal of the captured image is the sharpest means the in-focus position. Therefore, it can be said that the states in which the positions of the centers of gravity are different are the focusing positions, and the states in which the positions of the centers of gravity are the same are the positions defocused from the focusing positions.
このことから、非対称度合いが一対の線像強度分布間で異なり、重心ずれ量差が生じている場合には、重心位置が一致する位置が合焦位置とはならず、重心位置が異なる位置が合焦位置となる。以上のように、線像強度分布1301_Aおよび1301_Bのような撮影光学系のコマ収差等の収差、絞り102等によるケラレが大きい場合、デフォーカスによる重心ずれ量に加えて、線像強度分布の非対称度合いに起因した重心ずれ量差が生じる。これにより、本来合焦と検出するべきデフォーカス位置で、位相差AFは、ピントずれがあると検出してしまう。
From this, when the degree of asymmetry differs between the pair of line image intensity distributions and there is a difference in the amount of deviation of the center of gravity, the position where the positions of the centers of gravity match does not become the focusing position, and the positions where the positions of the centers of gravity differ are different. It will be in focus position. As described above, when aberrations such as coma of the photographing optical system such as the line image intensity distributions 1301_A and 1301_B and vignetting due to the
また、位相差AFでピントずれ量を検出する際に用いられる相関演算においては、線像強度分布1301_Aおよび1301_Bのように形状差がある場合には検出誤差が生じる。形状差がない場合には一対の線像強度分布が完全に重なるところで、信号の一致度を表す相関量が0となる。しかしながら、形状差がある1301_Aおよび1301_Bのような場合には、1301_Aと1301_Bが完全に重なるところはなく、信号の一致度を表す相関量が0とはならず、少しずれたとことで相関量が極小値をとる。このように、一対の線像強度分布間に形状差がある場合には検出誤差が生じる。 Further, in the correlation calculation used when detecting the amount of focus shift by the phase difference AF, a detection error occurs when there is a shape difference such as the line image intensity distributions 1301_A and 1301_B. When there is no shape difference, the correlation amount representing the degree of coincidence of the signals becomes 0 where the pair of line image intensity distributions completely overlap. However, in the case of 1301_A and 1301_B having a shape difference, 1301_A and 1301_B do not completely overlap, and the correlation amount indicating the degree of signal matching does not become 0, and the correlation amount is slightly deviated. Take a minimum value. As described above, when there is a shape difference between the pair of line image intensity distributions, a detection error occurs.
以上のことから、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)と位相差AFが検出する位相差焦点検出合焦位置(P_AF2)の差分が小さい条件は、撮影光学系のコマ収差等の収差、絞り102等によるケラレが小さい場合となる。また、焦点検出領域の位置座標(x1、y1)が中央像高付近の場合には、光学系のコマ収差等の収差が小さく、光学系の絞り102等によるケラレが小さいのが一般的である。そのため、焦点検出領域の位置座標(x1、y1)が中央像高付近の場合も、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)と位相差AFが検出する位相差焦点検出合焦位置(P_AF2)の差分が小さい条件といえる。
From the above, the condition that the difference between the focus detection focus position (P_AF) calculated from the focus detection characteristic of the focus detection means and the phase difference focus detection focus position (P_AF2) detected by the phase difference AF is small is the imaging optics. This is a case where aberrations such as coma of the system and vignetting due to the
次に、図6に戻って、ステップS108で、カメラMPU125は、位相差補正情報を取得する。位相差補正情報は、位相差AFが検出する位相差焦点検出合焦位置に関連する情報である。本実施形態では、ステップS103で算出した、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)における分割された光電変換部211a、211bに対応した撮影光学系の線像強度分布、LSF_A、LSF_Bを取得する。また、撮影光学系の線像強度分布は、デフォーカス状態を示すフォーカスレンズ104の位置、ズーム状態を示す第1レンズ群101の位置、焦点検出領域の位置座標(x1、y1)など、撮影光学系の変化や焦点検出光学系の変化に伴い変化する。そのため、取得する線像強度分布は、ステップS4で取得した、補正値算出条件に基づいて決定する。
Next, returning to FIG. 6, in step S108, the
次に、ステップS109で、カメラMPU125は、ステップS108で取得したLSF_A、LSF_Bに、それぞれ、シェーディング補正処理(光学補正処理)を行う。ここで、図11に、撮像素子の周辺像高における光電変換部211aの第1瞳部分領域501、光電変換部211bの第2瞳部分領域502、および結像光学系の射出瞳400の関係を示す。瞳の水平方向をX軸、瞳の垂直方向をY軸としている。
Next, in step S109, the
図11(A)は、結像光学系の射出瞳距離Dlと撮像素子の設定瞳距離Dsが同じ状態を示す図である。この場合、第1瞳部分領域501と第2瞳部分領域502により、結像光学系の射出瞳400が、概ね、均等に瞳分割される。これに対して、図11(B)に示した結像光学系の射出瞳距離Dlが撮像素子の設定瞳距離Dsより短い場合、撮像素子の周辺像高では、結像光学系の射出瞳と撮像素子の入射瞳の瞳ずれを生じ、結像光学系の射出瞳400が、不均一に瞳分割されてしまう。同様に、図11(C)に示した結像光学系の射出瞳距離Dlが撮像素子の設定瞳距離Dsより長い場合、撮像素子の周辺像高では、結像光学系の射出瞳と撮像素子の入射瞳の瞳ずれを生じ、結像光学系の射出瞳400が、不均一に瞳分割されてしまう。周辺像高で瞳分割が不均一になるのに伴い、LSF_A、LSF_Bの強度も不均一になり、LSF_A、LSF_Bのいずれか一方の強度が大きくなり、他方の強度が小さくなるシェーディングが生じる。
FIG. 11A is a diagram showing a state in which the exit pupil distance Dl of the imaging optical system and the set pupil distance Ds of the image sensor are the same. In this case, the
図6に戻って、ステップS109では、焦点検出領域の像高と、撮像レンズ(結像光学系)のF値、射出瞳距離に応じて、LSF_Aの第1シェーディング補正係数と、LSF_Bの第2シェーディング補正係数を、それぞれ生成する。第1シェーディング補正係数をLSF_Aに乗算し、第2シェーディング補正係数をLSF_Bに乗算して、LSF_AとLSF_Bのシェーディング補正処理(光学補正処理)を行う。 Returning to FIG. 6, in step S109, the first shading correction coefficient of LSF_A and the second shading correction coefficient of LSF_B are determined according to the image height of the focus detection region, the F value of the imaging lens (imaging optical system), and the exit pupil distance. Shading correction coefficients are generated respectively. The first shading correction coefficient is multiplied by LSF_A, the second shading correction coefficient is multiplied by LSF_B, and shading correction processing (optical correction processing) of LSF_A and LSF_B is performed.
本実施形態では、LSF_AとLSF_Bの相関(信号の一致度)を基に、第2補正値の算出を行う。瞳ずれによるシェーディングが生じるとLSF_AとLSF_Bの相関(信号の一致度)が低下する場合がある。瞳ずれによるシェーディングが生じるとLSF_AとLSF_Bの相関(信号の一致度)が低下する場合がある。従って、LSF_AとLSF_Bの相関(信号の一致度)を改善し、焦点検出性能を良好とするために、シェーディング補正処理(光学補正処理)を行うことが望ましい。 In the present embodiment, the second correction value is calculated based on the correlation between LSF_A and LSF_B (the degree of signal matching). When shading occurs due to pupil displacement, the correlation between LSF_A and LSF_B (the degree of signal matching) may decrease. When shading occurs due to pupil displacement, the correlation between LSF_A and LSF_B (the degree of signal matching) may decrease. Therefore, it is desirable to perform shading correction processing (optical correction processing) in order to improve the correlation (signal matching degree) between LSF_A and LSF_B and improve the focus detection performance.
次に、ステップS110で、カメラMPU125は、LSF_AとLSF_Bに、フィルタ処理を行う。ここで、本実施形態のフィルタ処理の通過帯域の一例を、図12に示す。横軸は空間周波数、縦軸はフィルタ係数を表している。本実施形態では、位相差AFの焦点検出の評価帯域に応じて、焦点検出時のフィルタ処理の通過帯域を、図12の実線または1点鎖線のように、調整するのが望ましい。
Next, in step S110, the
次に、ステップS111では、カメラMPU125は、フィルタ処理後のLSF_AとLSF_Bを相対的に瞳分割方向にシフトさせるシフト処理を行い、信号の一致度を表す相関量を算出する(相関演算)。本実施形態では、フィルタ処理後のk番目のLSF_AをA(k)、LSF_BをB(k)、焦点検出領域に対応する番号kの範囲をWとする。シフト処理によるシフト量をs1、シフト量s1のシフト範囲をΓ1として、相関量CORは、式(8)により算出される。
シフト量s1のシフト処理により、k番目のA(k)とk−s1番目のB(k−s1)を対応させ減算し、シフト減算信号を生成する。生成されたシフト減算信号の絶対値を計算し、焦点検出領域に対応する範囲W内で番号kの和を取り、相関量COR(s1)を算出する。必要に応じて、各行毎に算出された相関量(評価値)を、シフト量毎に、複数行に渡って加算しても良い。算出された相関量から、サブピクセル演算により、相関量が最小値となる実数値のシフト量を算出して像ずれ量p1を算出する。本実施形態では、像ずれ量p1を、LSF_AとLSF_Bの信号の一致度を示す相関量(相関演算)に基づいて導出したが、LSF_AとLSF_Bの信号の重心ずれ量に基づいて算出してもよい。 By the shift processing of the shift amount s1, the k-th A (k) and the k-s1st B (k-s1) are associated and subtracted to generate a shift subtraction signal. The absolute value of the generated shift / subtraction signal is calculated, the sum of the numbers k is taken within the range W corresponding to the focus detection region, and the correlation amount COR (s1) is calculated. If necessary, the correlation amount (evaluation value) calculated for each row may be added over a plurality of rows for each shift amount. From the calculated correlation amount, the shift amount of the real value at which the correlation amount is the minimum value is calculated by the sub-pixel calculation, and the image shift amount p1 is calculated. In the present embodiment, the image shift amount p1 is derived based on the correlation amount (correlation calculation) indicating the degree of coincidence between the LSF_A and LSF_B signals, but it may be calculated based on the center of gravity shift amount of the LSF_A and LSF_B signals. Good.
次に、ステップS112(第2算出工程)で、カメラMPU125は、ステップS111で算出した像ずれ量p1に、焦点検出領域の位置座標(x1、y1)と、光学系の絞り値、射出瞳距離に応じた変換係数Kをかけて、第2補正値(BP2)を算出する。次に、ステップS113で、第2補正値の製造誤差補正を行う。
Next, in step S112 (second calculation step), the
本実施形態では、第2補正値の製造誤差補正情報を、撮影光学系の像面倒れ量に応じて保持した場合について説明する。なお、カメラMPU125は、本実施形態の第2製造誤差補正手段として機能する。ここで、図13〜15に撮影光学系の像面倒れに応じて第2補正値の製造誤差が変化することを説明するための図を示す。図13(A)及び図14(A)は、撮影光学系の像面倒れがない場合を示しており、図13(A)は、右側像高、図14(A)は、左側像高の様子を表している。線像強度分布1501_A、1503_Aは、分割された光電変換部211aに対応した線像強度分布であり、線像強度分布1501_B、1503_Bは、分割された光電変換部211bに対応した線像強度分布である。
In the present embodiment, a case where the manufacturing error correction information of the second correction value is held according to the amount of image plane tilt of the photographing optical system will be described. The
図13(B)及び図14(B)は、撮影光学系の像面倒れがある場合を示しており、図13(B)は右側像高、図14(B)は左側像高の様子を表している。線像強度分布1502_A、1504_Aは、分割された光電変換部211aに対応した線像強度分布であり、線像強度分布1502_B、1504_Bは、分割された光電変換部211bに対応した線像強度分布である。横収差量1510は、像面倒れのない場合の横収差量を、横収差量1511は、像面倒れがある場合の横収差量を表している。また、重心位置1501_G_A〜1504_G_Aは、線像強度分布1501_A〜1504_Aの重心位置を、重心位置1501_G_B〜1504_G_Bは、線像強度分布1501_B〜1504_Bの重心位置を表している。
13 (B) and 14 (B) show the case where the image plane of the photographing optical system is tilted. FIG. 13 (B) shows the right image height, and FIG. 14 (B) shows the left image height. Represents. The line image intensity distributions 1502_A and 1504_A are line image intensity distributions corresponding to the divided
図13(A)と図14(A)を比較すると、線像強度分布1501_Aと線像強度分布1502_B、線像強度分布1501_Bと線像強度分布1502Aが同形状であることがわかる。このように、像面倒れがない場合には、左右像高で光電変換部211a、211bそれぞれに対応する線像強度分布が入れ替わり反転するだけで、形状に違いがないことがわかる。
Comparing FIGS. 13 (A) and 14 (A), it can be seen that the line image intensity distribution 1501_A and the line image intensity distribution 1502_B, and the line image intensity distribution 1501_B and the line image intensity distribution 1502A have the same shape. As described above, when there is no image plane tilt, it can be seen that there is no difference in shape only by switching and inverting the line image intensity distributions corresponding to the
次に、図13(B)と図13(A)を比較すると、像面の倒れにより横収差量が拡大した側を主に通過した光線により形成される線像強度分布1502_Aはより外側に尾を引く方向に形状が変化している。それに対して、横収差が減少した側を主に通過した光線により形成される線像強度分布1502_Bは尾が小さくなる方向に形状が変化する。このことから、線像強度分布1502_G_Aは、線像強度分布1501_G_Aよりも外側に、線像強度分布1502_G_Bは、線像強度分布1501_G_Bよりも内側に移動する。 Next, when FIG. 13 (B) and FIG. 13 (A) are compared, the line image intensity distribution 1502_A formed by the light rays mainly passing through the side where the amount of lateral aberration is expanded due to the tilt of the image plane is tailed to the outer side. The shape is changing in the direction of pulling. On the other hand, the shape of the line image intensity distribution 1502_B formed by the light rays mainly passing through the side where the lateral aberration is reduced changes in the direction in which the tail becomes smaller. From this, the line image intensity distribution 1502_G_A moves outward from the line image intensity distribution 1501_G_A, and the line image intensity distribution 1502_G_B moves inward from the line image intensity distribution 1501_G_B.
次に、図14(B)と図14(A)を比較すると、像面の倒れにより横収差量が拡大した側を主に通過した光線により形成される線像強度分布1504_Aはより外側に尾を引く方向に形状が変化している。それに対して、横収差が減少した側を主に通過した光線により形成される線像強度分布1504_Bは、尾が小さくなる方向に形状が変化する。このことから、線像強度分布1504_G_Aは、線像強度分布1503_G_Aよりも外側に、線像強度分布1504_G_Aは、線像強度分布1503_G_Aよりも内側に移動する。 Next, when FIG. 14 (B) and FIG. 14 (A) are compared, the line image intensity distribution 1504_A formed by the light rays mainly passing through the side where the amount of lateral aberration is expanded due to the tilt of the image plane is tailed to the outer side. The shape is changing in the direction of pulling. On the other hand, the shape of the line image intensity distribution 1504_B formed by the light rays mainly passing through the side where the lateral aberration is reduced changes in the direction in which the tail becomes smaller. From this, the line image intensity distribution 1504_G_A moves outward from the line image intensity distribution 1503_G_A, and the line image intensity distribution 1504_G_A moves inward from the line image intensity distribution 1503_G_A.
図15(A)に、右側像高における像面倒れがない場合と、像面倒れがある場合の重心位置差の違いを説明するための図を示す。重心位置差δG1は、像面倒れがない場合の線像強度分布1501_Aと1501_Bの重心位置差を、重心位置差δG2は、像面倒れがある場合の線像強度分布1502_Aと1502_Bの重心位置差を示している。 FIG. 15A shows a diagram for explaining the difference in the position difference of the center of gravity between the case where there is no image plane tilt at the right image height and the case where there is an image plane tilt. The center of gravity position difference δG1 is the center of gravity position difference between the line image intensity distributions 1501_A and 1501_B when there is no image plane tilt, and the center of gravity position difference δG2 is the center of gravity position difference between the line image intensity distributions 1502_A and 1502_B when there is no image plane tilt. Is shown.
図15(B)は、左側像高における像面倒れがない場合と、像面倒れがある場合の重心ずれ量の違いを説明するための図である。重心ずれ量δG3は、1503_Aと1503_Bの重心ずれ量を、重心ずれ量δG4は、1504_Aと1504_Bの重心ずれ量を示している。図15(A)の通り、像面倒れにより、線像強度分布1501_G_Aが外側へ移動し線像強度分布1502_G_Aに、線像強度分布1501_G_Bが内側へ移動し線像強度分布1502_G_Bとなり重心ずれ量がδG1からδG2へと小さくなる。また、図15(B)に示す通り、像面倒れにより、線像強度分布1503_G_Aが外側へ移動し線像強度分布1504_G_Aに、線像強度分布1503_G_Bが内側へ移動し線像強度分布1504_G_Bとなり重心ずれ量がδG3からδG4へと大きくなる。 FIG. 15B is a diagram for explaining the difference in the amount of center of gravity shift between the case where there is no image plane tilt at the left image height and the case where there is an image plane tilt. The center of gravity shift amount δG3 indicates the center of gravity shift amount of 1503_A and 1503_B, and the center of gravity shift amount δG4 indicates the center of gravity shift amount of 1504_A and 1504_B. As shown in FIG. 15 (A), the line image intensity distribution 1501_G_A moves outward to the line image intensity distribution 1502_G_A, and the line image intensity distribution 1501_G_B moves inward to become the line image intensity distribution 1502_G_B. It becomes smaller from δG1 to δG2. Further, as shown in FIG. 15B, the line image intensity distribution 1503_G_A moves outward to the line image intensity distribution 1504_G_A, and the line image intensity distribution 1503_G_B moves inward to become the line image intensity distribution 1504_G_B due to the image plane tilt. The amount of deviation increases from δG3 to δG4.
以上のことから、重心ずれ量は、像面倒れに応じて変化し、片方の像高は減少し、もう片方の像高は増加することがわかる。重心ずれ量は、位相差AF起因のピントずれ量となるため、像面倒れに応じて位相差AF起因のピントずれ量は変化するといえる。従って、第2補正値の製造誤差に関する情報を、撮影光学系の像面倒れ量(T)として、レンズメモリ118にあらかじめ記憶しておき、第2製造誤差補正値(BP2d)を、焦点検出条件に応じた像面倒れ量(T)を取得し、式(9)に従って算出する。
BP2d=BP2×T×α (9)
ここで、αは、像面倒れ量(T)とBP2からDELTA_BP2を算出するための換算係数である。以上のように、ステップS113では、算出したBP2dを用いて、カメラMPU125が、BP2にBP2dを加算し、第2製造誤差補正を行う。なお、カメラMPU125は、第2製造誤差補正手段として機能する。
From the above, it can be seen that the amount of center of gravity shift changes according to the image plane tilt, the image height of one decreases, and the image height of the other increases. Since the amount of center of gravity shift is the amount of focus shift due to phase difference AF, it can be said that the amount of focus shift due to phase difference AF changes according to the image plane tilt. Therefore, the information regarding the manufacturing error of the second manufacturing error is stored in advance in the
BP2d = BP2 × T × α (9)
Here, α is a conversion coefficient for calculating DELTA_BP2 from the image plane tilt amount (T) and BP2. As described above, in step S113, the
なお、本実施形態では、第2補正値の製造誤差に関する情報をステート毎に保持し、焦点検出条件に応じた製造誤差補正情報を取得し製造誤差補正値を算出した。しかしながら、製造誤差補正情報を、特定のステートでのみ保持し、保持していないステートに関しては、第2補正値のステート間での変化率から算出してもよい。 In the present embodiment, the information regarding the manufacturing error of the second correction value is held for each state, the manufacturing error correction information according to the focus detection condition is acquired, and the manufacturing error correction value is calculated. However, the manufacturing error correction information may be held only in a specific state, and the state not held may be calculated from the rate of change of the second correction value between the states.
このように、被写体の色、方向、空間周波数に依存する製造誤差補正と、位相差AFに依存する製造誤差補正を分けて行うことで、要因毎に製造誤差補正を実施することができ、高精度な製造誤差補正を可能としている。第1補正値(BP1)、第2補正値(BP2)を分けて算出し、要因の異なる第1補正値(BP1)、第2補正値(BP2)毎に製造誤差補正を実施できない場合、位相差AFとコントラストAFで同製造誤差補正を行うことしかできない。これにより、片方の製造誤差補正の精度が低下してしまう。 In this way, by separately performing the manufacturing error correction that depends on the color, direction, and spatial frequency of the subject and the manufacturing error correction that depends on the phase difference AF, it is possible to carry out the manufacturing error correction for each factor. Accurate manufacturing error correction is possible. If the manufacturing error correction cannot be performed for each of the first correction value (BP1) and the second correction value (BP2) having different factors, the first correction value (BP1) and the second correction value (BP2) are calculated separately. The same manufacturing error correction can only be performed with phase difference AF and contrast AF. As a result, the accuracy of one of the manufacturing error corrections is lowered.
(焦点検出補正値算出)
次に、図6に戻って、ステップS114(第3算出工程)で、カメラMPU125は、焦点検出補正値(BP)を、以下の式(10)により算出する。
BP=BP1+BP2 (10)
本実施形態では、焦点検出補正値(BP)を、被写体の色、方向、空間周波数に依存する第1補正値(BP1)と、位相差AFに依存する第2補正値(BP2)とに分けて算出する。これにより、位相差AFにおける自動焦点検出のピントずれ量を高精度に補正することが可能となる。
(Focus detection correction value calculation)
Next, returning to FIG. 6, in step S114 (third calculation step), the
BP = BP1 + BP2 (10)
In the present embodiment, the focus detection correction value (BP) is divided into a first correction value (BP1) that depends on the color, direction, and spatial frequency of the subject and a second correction value (BP2) that depends on the phase difference AF. To calculate. This makes it possible to correct the amount of focus shift of automatic focus detection in phase difference AF with high accuracy.
ここで、図16に、第1補正値(BP1)と、第2補正値(BP2)とに分けて算出することにより高精度に補正できることを説明する図を示す。図16の位置P_IMGは、ステップS102で算出した撮影画像の画像特性もしくは評価特性から算出される撮像合焦位置を、位置P_AFは、ステップS103で算出した焦点検出手段の焦点検出特性から算出される焦点検出合焦位置を示す。また、補正値BP1は、ステップS104にて算出される第1補正値を、補正値BP2は、ステップS112にて算出される第2補正値を、補正値BPは、ステップS114にて算出される焦点検出補正値を表している。また差分、BP’は、第1補正値と第2補正値とを分けずに、位置P_IMGでの線像強度分布に基づいて、図6のフローに基づいて算出した補正値を、差分δBPは、本来算出したい補正値との差分(BP’−BP)を表している。横軸は設定def(実際のデフォーカス量)、縦軸は検出def(自動焦点検出手段にて算出されるdef量)を示す。 Here, FIG. 16 shows a diagram for explaining that the correction can be performed with high accuracy by separately calculating the first correction value (BP1) and the second correction value (BP2). The position P_IMG in FIG. 16 is calculated from the image in-focus position calculated from the image characteristics or evaluation characteristics of the captured image calculated in step S102, and the position P_AF is calculated from the focus detection characteristics of the focus detection means calculated in step S103. Indicates the focus detection focus position. The correction value BP1 is the first correction value calculated in step S104, the correction value BP2 is the second correction value calculated in step S112, and the correction value BP is calculated in step S114. Indicates the focus detection correction value. Further, the difference BP'is a correction value calculated based on the flow of FIG. 6 based on the line image intensity distribution at the position P_IMG without separating the first correction value and the second correction value, and the difference δBP is , Represents the difference (BP'-BP) from the correction value originally desired to be calculated. The horizontal axis shows the set def (actual defocus amount), and the vertical axis shows the detection def (def amount calculated by the automatic focus detection means).
図16に示すように、設定defと検出defの関係が線形でない場合、撮影画像の画像特性または評価特性から算出される撮像合焦位置(P_IMG)の位置でのLSFに基づいて補正値を算出する。この場合、検出した像ずれ量をデフォーカス量に換算する際に、設定defと検出defの非線形性に起因して誤差δBPが生じる。それに対し、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)の位置でのLSFに基づいて補正値を算出する場合には、算出する補正値が小さくなるため、設定defと検出defの非線形性に起因して誤差の影響が小さくなる。 As shown in FIG. 16, when the relationship between the setting def and the detection def is not linear, the correction value is calculated based on the LSF at the imaging focusing position (P_IMG) calculated from the image characteristics or the evaluation characteristics of the captured image. To do. In this case, when the detected image shift amount is converted into the defocus amount, an error δBP occurs due to the non-linearity between the set def and the detected def. On the other hand, when the correction value is calculated based on the LSF at the focus detection focusing position (P_AF) calculated from the focus detection characteristic of the focus detection means, the calculated correction value becomes small, so the setting def And the influence of the error becomes small due to the non-linearity of the detection def.
以上、本実施形態によれば、焦点検出補正値(BP)を、被写体の色、方向、空間周波数に依存する第1補正値(BP1)と、位相差AFに依存する第2補正値(BP2)とに分けて算出する。これにより、位相差AFにおける自動焦点検出のピントずれ量を高精度に補正することが可能となる。 As described above, according to the present embodiment, the focus detection correction value (BP) is the first correction value (BP1) that depends on the color, direction, and spatial frequency of the subject, and the second correction value (BP2) that depends on the phase difference AF. ) And the calculation. This makes it possible to correct the amount of focus shift of automatic focus detection in phase difference AF with high accuracy.
(第2実施形態)
次に、第2の実施形態について説明する。第1の実施形態との主な違いは、ステップS107で取得した位相差補正情報が線像強度分布ではなく、位相差AFが検出する位相差焦点検出合焦位置と焦点検出手段の焦点検出特性から算出される焦点検出合焦位置との差分である点である。また、第1実施形態では、焦点検出補正値を第1補正値と第2補正値とに分けて算出した。しかしながら、本実施形態では、P_AFを算出する際に、位相差AFが検出する位相差焦点検出合焦位置と焦点検出手段の焦点検出特性から算出される焦点検出合焦位置との差分である第2補正値(BP2)を加味して算出する。
(Second Embodiment)
Next, the second embodiment will be described. The main difference from the first embodiment is that the phase difference correction information acquired in step S107 is not the line image intensity distribution, but the phase difference focus detection focusing position detected by the phase difference AF and the focus detection characteristic of the focus detection means. This is the difference from the focus detection focusing position calculated from. Further, in the first embodiment, the focus detection correction value is calculated separately for the first correction value and the second correction value. However, in the present embodiment, when calculating P_AF, it is the difference between the phase difference focus detection focus position detected by the phase difference AF and the focus detection focus position calculated from the focus detection characteristic of the focus detection means. 2 Calculated by adding the correction value (BP2).
図5、図17を参照して、本実施形態のデジタルカメラにおける自動焦点検出(AF)動作について説明する。図5の処理は、第1の実施形態と同様の処理のため割愛する。以下、第1の実施形態にて、図5を用いて説明したAF処理全体のフローのステップS5における自動焦点検出の結果を補正するための焦点検出補正値の算出について図17を用いて説明する。 The automatic focus detection (AF) operation in the digital camera of the present embodiment will be described with reference to FIGS. 5 and 17. The process of FIG. 5 is omitted because it is the same process as that of the first embodiment. Hereinafter, in the first embodiment, the calculation of the focus detection correction value for correcting the result of the automatic focus detection in step S5 of the flow of the entire AF process described with reference to FIG. 5 will be described with reference to FIG. ..
まず、ステップS1601で、カメラMPU125は、収差情報を取得する。ここでの収差情報は、光学系の収差状態を表す情報であり、例えば、被写体の色、方向、空間周波数ごとの撮影光学系の結像位置に関する情報である。次に、ステップS1602で、カメラMPU125は、位相差補正情報を取得する。位相差補正情報は、位相差AFが検出する位相差焦点検出合焦位置に関連する情報である。本実施形態では、位相差AFが検出する位相差焦点検出合焦位置と焦点検出手段の焦点検出特性から算出される焦点検出合焦位置との差分を取得する。また、位相差AFが検出する位相差焦点検出合焦位置と焦点検出手段の焦点検出特性から算出される焦点検出合焦位置との差分は、撮影光学系の変化や焦点検出光学系の変化に伴い変化する。すなわち、デフォーカス状態を示すフォーカスレンズ104の位置、ズーム状態を示す第1レンズ群101の位置、焦点検出領域の位置座標(x1、y1)など、撮影光学系の変化や焦点検出光学系の変化に伴い変化する。そのため、取得する位相差AFが検出する位相差焦点検出合焦位置と焦点検出手段の焦点検出特性から算出される焦点検出合焦位置との差分は、図5のステップS4で取得した、補正値算出条件に基づいて決定する。
First, in step S1601, the
次に、ステップS1603、ステップS1604で、カメラMPU125は、ステップS1601で取得した収差情報と、ステップS1602で取得した位相差補正情報から、撮像合焦位置(P_IMG)、焦点検出合焦位置(P_AF)を算出する。つまり、撮影画像の画像特性または評価特性から算出される撮像合焦位置(P_IMG)、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)を算出する。
Next, in step S1603 and step S1604, the
本実施形態では、第1の実施形態における図8(D)に示す合焦位置の算出に用いる重み付け係数を構成する係数のうち、以下の係数を設定した場合を例にして説明する。
K_AF_H=1
K_AF_V=0
K_IMG_H=0.5
K_IMG_V=0.5
K_IMG_FQ(1)=1
K_IMG_FQ(2)=0
K_IMG_FQ(3)=0
K_IMG_FQ(4)=0
K_AF_R=0
K_AF_G=1
K_AF_B=0
K_IMG_R=0.3
K_IMG_G=0.5
K_IMG_B=0.2
In this embodiment, the case where the following coefficients are set among the coefficients constituting the weighting coefficient used for calculating the in-focus position shown in FIG. 8D in the first embodiment will be described as an example.
K_AF_H = 1
K_AF_V = 0
K_IMG_H = 0.5
K_IMG_V = 0.5
K_IMG_FQ (1) = 1
K_IMG_FQ (2) = 0
K_IMG_FQ (3) = 0
K_IMG_FQ (4) = 0
K_AF_R = 0
K_AF_G = 1
K_AF_B = 0
K_IMG_R = 0.3
K_IMG_G = 0.5
K_IMG_B = 0.2
また、第1の実施形態における式(1)の緑(G)色の信号について水平(H)方向に対応した空間周波数ごとのデフォーカスMTFの極大値を示すフォーカスレンズ104位置の情報MTF_P_GHは式(11)で表される。
MTF_P_GH(f,x,y)=(gh(0)×x+gh(1)×y+gh(2))×f2+(gh(3)×x+gh(4)×y+gh(5))×f+(gh(6)×x+gh(7)×y+gh(8)) (11)
Further, the information MTF_P_GH of the
MTF_P_GH (f, x, y) = (gh (0) x x + gh (1) x y + gh (2)) x f2 + (gh (3) x x + gh (4) x y + gh (5)) x f + (gh (6)) × x + gh (7) × y + gh (8)) (11)
まず、本実施形態では、緑(G)色の信号について水平(H)方向に対応した、式(10)のgh(8)項に、第2補正値(BP2)の2倍を加算する。つまり、位相差AFが検出する位相差焦点検出合焦位置と焦点検出手段の焦点検出特性から算出される焦点検出合焦位置との差分である第2補正値(BP2)の2倍を加算する。加算後のMTF_P_GH(f,x,y)を加算前と区別するために、MTF_P_GH_BP2(f,x,y)と表記する。加算後の式(11)を式(12)に示す。
MTF_P_GH_BP2(f,x,y)=(gh(0)×x+gh(1)×y+gh(2))×f2+(gh(3)×x+gh(4)×y+gh(5))×f+(gh(6)×x+gh(7)×y+(gh(8)+BP2×2)) (12)
First, in the present embodiment, twice the second correction value (BP2) is added to the gh (8) term of the equation (10) corresponding to the horizontal (H) direction for the green (G) color signal. That is, twice the second correction value (BP2), which is the difference between the phase difference focus detection focus position detected by the phase difference AF and the focus detection focus position calculated from the focus detection characteristic of the focus detection means, is added. .. In order to distinguish MTF_P_GH (f, x, y) after addition from that before addition, it is expressed as MTF_P_GH_BP2 (f, x, y). The equation (11) after addition is shown in equation (12).
MTF_P_GH_BP2 (f, x, y) = (gh (0) x x + gh (1) x y + gh (2)) x f2 + (gh (3) x x + gh (4) x y + gh (5)) x f + (gh (6)) × x + gh (7) × y + (gh (8) + BP2 × 2)) (12)
なお、式(12)は、緑(G)色の信号について水平(H)方向に対応した空間周波数ごとのデフォーカスMTFの極大値を示すフォーカスレンズ104位置の情報MTF_P_GH_BP2の式を示している。なお、赤(R)色、青(B)色の信号の水平(H)方向も同様である。赤(R)色、緑(G)色、青(B)色の信号の垂直(V)方向に関しては、第1の実施形態の式(1)同様である。
The equation (12) shows the equation of the information MTF_P_GH_BP2 of the
また、本実施形態では、カメラMPU125がgh(8)、BP2を取得し、式(12)により、第2補正値(BP2)の2倍を算出した。しかしながら、レンズMPU117であらかじめ第2補正値(BP2)の2倍を加算したgh(8)+BP2×2をカメラMPU125が取得してもよい。そうすることで、レンズMPU117とカメラMPU125間の通信を削減可能となる。
Further, in the present embodiment, the
また、レンズユニット100のレンズメモリ118に、gh(8)の代わりにgh(8)+BP2×2をgh(8)_BP2としてあらかじめ記憶しておき、カメラMPU125が、レンズMPU117に要求してgh(8)_BP2を取得してもよい。なお、gh(8)_BP2は、カメラRAM125bの不揮発性領域に記憶されていてもよい。この場合、レンズメモリ118またはカメラRAM125bの記憶容量を削減可能となる。
Further, in the
次に、式(12)のx,yに焦点検出領域の位置情報(x1、y1)を代入する。この計算により式(12)は、以下の式(13)のような形式で表される。
MTF_P_GH_BP2(f)=Agh×f2+Bgh×f+Cgh+BP×2
=MTF_P_GH(f)+BP×2 (13)
Agh、Bgh、Cghは第1の実施形態と同係数を表している。ここで、カメラMPU125は、MTF_P_RH_BP2(f)、MTF_P_BH_BP2(f)についても同様に計算する。
Next, the position information (x1, y1) of the focus detection region is substituted into x and y of the equation (12). By this calculation, the equation (12) is expressed in the form of the following equation (13).
MTF_P_GH_BP2 (f) = Agh x f2 + Bgh x f + Cgh + BP x 2
= MTF_P_GH (f) + BP x 2 (13)
Agh, Bgh, and Cgh represent the same coefficients as in the first embodiment. Here, the
次に、カメラMPU125は、第1の実施形態の図5のステップS4で取得している補正値算出条件の合焦位置の算出に用いる重み付け係数を構成する係数(図8(D))で、収差情報を重み付けする。ただし、K_AF_H、K_AF_V、K_IMG_H、K_IMG_V、K_IMG_FQ(1)、K_IMG_FQ(2)、K_IMG_FQ(3)、K_IMG_FQ(4)は上述した値を用いる。
Next, the
具体的には、第1の実施形態の式(3)、式(4)に式(13)および上述した、係数を代入する。代入して整理すると式(14)、式(15)となる。
MTF_P_AF_BP2(f)= MTF_P_GH(f)+BP2×2 (14)
MTF_P_IMG_BP2(f)=
0.15×MTF_P_RH(f)
+0.15×MTF_P_RV(f)
+0.25×MTF_P_GH(f)
+0.25MTF_P_GV(f)
+0.25×MTF_P_BH(f)
+0.25×MTF_P_BV(f)
+BP2 (15)
Specifically, the equation (13) and the above-mentioned coefficients are substituted into the equations (3) and (4) of the first embodiment. When substituting and rearranging, equations (14) and (15) are obtained.
MTF_P_AF_BP2 (f) = MTF_P_GH (f) + BP2 × 2 (14)
MTF_P_IMG_BP2 (f) =
0.15 × MTF_P_RH (f)
+0.15 × MTF_P_RV (f)
+0.25 × MTF_P_GH (f)
+0.25 MTF_P_GV (f)
+0.25 × MTF_P_BH (f)
+0.25 × MTF_P_BV (f)
+ BP2 (15)
また、第1の実施形態の式(3)、式(4)に、上述の係数を代入して整理すると式(16)、式(17)となる。
MTF_P_AF(f)= MTF_P_GH(f) (16)
MTF_P_IMG=
0.15×MTF_P_RH(f)
+015×MTF_P_RV(f)
+0.25×MTF_P_GH(f)
+0.25MTF_P_GV(f)
+0.25×MTF_P_BH(f)
+0.25×MTF_P_BV(f) (17)
Further, when the above-mentioned coefficients are substituted into the equations (3) and (4) of the first embodiment and arranged, the equations (16) and (17) are obtained.
MTF_P_AF (f) = MTF_P_GH (f) (16)
MTF_P_IMG =
0.15 × MTF_P_RH (f)
+015 × MTF_P_RV (f)
+0.25 × MTF_P_GH (f)
+0.25 MTF_P_GV (f)
+0.25 × MTF_P_BH (f)
+0.25 × MTF_P_BV (f) (17)
式(14)、式(15)を、式(16)、式(17)をもちいて整理すると式(18)、式(19)となる。
MTF_P_AF_BP2(f)=MTF_P_AF(f)+BP2×2 (18)
MTF_P_IMG_BP2(f)=MTF_P_IMG(f)+BP2 (19)
When the equations (14) and (15) are rearranged using the equations (16) and (17), the equations (18) and (19) are obtained.
MTF_P_AF_BP2 (f) = MTF_P_AF (f) + BP2 × 2 (18)
MTF_P_IMG_BP2 (f) = MTF_P_IMG (f) + BP2 (19)
次に、カメラMPU125は、位相差AFに依存する第2補正値(BP2)を考慮した撮像合焦位置(P_IMG)と焦点検出合焦位置(P_AF)を、以下の式(20)および(21)に従って算出する。つまり、第2補正値(BP2)を考慮した撮影画像の画像特性もしくは評価特性から算出される撮像合焦位置(P_IMG)と焦点検出手段の焦点検出特性から算出される焦点検出合焦位置(P_AF)を、以下の式(20)および(21)に従って算出する。
Next, the
焦点検出合焦位置の算出は、式(14)および式(15)で得た空間周波数ごとのデフォーカスMTFの極大値情報と、ステップS4で得た撮影画像やAFの評価帯域で重みづけ加算する。つまり、空間周波数ごとのデフォーカスMTFの極大値情報MTF_P_AF_BP2(f)、MTF_P_IMG_BP2(f)と、ステップS4で得た撮影画像やAFの評価帯域K_IMG_FQ(n),K_AF_FQ(n)で重みづけ加算する。ただし、本実施例では上述した、K_IMG_FQ(1)、K_IMG_FQ(2)、K_IMG_FQ(3)、K_IMG_FQ(4)を用いて算出する。
P_IMG_BP2=MTF_P_IMG_BP2(1)
=MTF_P_IMG(1)+BP2 (20)
P_AF_BP2=MTF_P_AF_BP2(1)
=MTF_P_AF(1)+BP2×2 (21)
The focus detection focus position is calculated by weighting and adding the maximum value information of the defocus MTF for each spatial frequency obtained by the equations (14) and (15) and the photographed image and the AF evaluation band obtained in step S4. To do. That is, the maximum value information MTF_P_AF_BP2 (f) and MTF_P_IMG_BP2 (f) of the defocus MTF for each spatial frequency are weighted and added by the captured image obtained in step S4 and the AF evaluation bands K_IMG_FQ (n) and K_AF_FQ (n). .. However, in this embodiment, the calculation is performed using the above-mentioned K_IMG_FQ (1), K_IMG_FQ (2), K_IMG_FQ (3), and K_IMG_FQ (4).
P_IMG_BP2 = MTF_P_IMG_BP2 (1)
= MTF_P_IMG (1) + BP2 (20)
P_AF_BP2 = MTF_P_AF_BP2 (1)
= MTF_P_AF (1) + BP2 × 2 (21)
次に、ステップS1605で、カメラMPU125は、焦点検出補正値(BP)を、以下の式(22)により算出する。
BP=P_AF_BP2−P_IMG_BP2
=MTF_P_AF(1)−MTF_P_IMG(1)+BP2
=BP1+BP2 (22)
Next, in step S1605, the
BP = P_AF_BP2-P_IMG_BP2
= MTF_P_AF (1) -MTF_P_IMG (1) + BP2
= BP1 + BP2 (22)
以上のように、式(11)のgh(8)項に、第2補正値(BP2)の2倍を加算し、計算することで、第1補正値(BP1)と、第2補正値(BP2)を合わせた焦点検出補正値(BP)を算出可能となる。以上、本実施形態によれば、被写体の色、方向、空間周波数に依存する補正と、位相差AFに依存する補正を分けて補正することにより、光学系の収差による位相差AFの焦点検出誤差を精度良く補正可能な焦点検出方法を提供できる。 As described above, the first correction value (BP1) and the second correction value (BP1) are calculated by adding twice the second correction value (BP2) to the gh (8) term of the equation (11). The focus detection correction value (BP) including BP2) can be calculated. As described above, according to the present embodiment, the focus detection error of the phase difference AF due to the aberration of the optical system is corrected by separately correcting the correction depending on the color, direction, and spatial frequency of the subject and the correction depending on the phase difference AF. Can be provided with a focus detection method capable of accurately correcting.
また、本発明の好ましい実施形態について説明したが、本発明は、これらの実施形態に限定されず、その要旨の範囲内で種々の変形および変更が可能である。 Moreover, although the preferred embodiment of the present invention has been described, the present invention is not limited to these embodiments, and various modifications and modifications can be made within the scope of the gist thereof.
Claims (8)
撮影光学系の収差情報を取得する取得手段と、
前記取得した収差情報から、画像の画像特性または評価特性から算出される撮像合焦位置と、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置から第1補正値を算出し、
一対の線像強度分布の形状が互いに異なることで生じる重心ずれ量差に応じた補正値であって、前記焦点検出合焦位置における前記撮像手段の一対の光電変換部に対応した前記撮影光学系の線像強度分布に基づいて位相差焦点検出方式で検出される位相差焦点検出合焦位置から第2補正値を算出し、
前記第1補正値と前記第2補正値から焦点検出補正値を算出する算出手段と、
を有する
ことを特徴とする焦点検出装置。 An imaging means having a plurality of pixels capable of photoelectrically converting a light flux passing through different pupil regions of an imaging optical system and outputting a pair of photoelectric conversion signals.
An acquisition means for acquiring aberration information of the photographing optical system, and
From the acquired aberration information, the first correction value is calculated from the imaging in-focus position calculated from the image characteristic or the evaluation characteristic of the image and the focus detection in-focus position calculated from the focus detection characteristic of the focus detection means.
A correction value corresponding to the gravity center displacement amount difference caused by the shape of the pair of line image intensity distributions are different from each other, the imaging optical system corresponding to the pair of photoelectric conversion units of the image pickup means in the focus detecting focus position and based on the line image intensity distribution by calculating a second correction value from the phase difference focus detection in-focus position detected by the phase difference focus detection method,
A calculation means for calculating the focus detection correction value from the first correction value and the second correction value, and
A focus detector characterized by having.
ことを特徴とする請求項1に記載の焦点検出装置。 The first correction value is the difference between the imaging focus position and the focus detection focus position, and the second correction value is the difference between the focus detection focus position and the phase difference focus detection focus position. The focus detection device according to claim 1, wherein the focus detection device is characterized by the above.
ことを特徴とする請求項1または2に記載の焦点検出装置。 According to claim 1 or 2, the phase difference focus detection focusing position is calculated based on the amount of misalignment of the line image intensity distribution of the photographing optical system detected by the phase difference focus detection method. The focus detector of the description.
ことを特徴とする請求項1〜3のいずれか1項に記載の焦点検出装置。 Any one of claims 1 to 3, wherein the calculation means calculates the focus detection correction value using only the first correction value when the phase difference focus detection method is not used. The focus detector according to.
ことを特徴とする請求項1〜4のいずれか1項に記載の焦点検出装置。 The calculating means, when the difference between the phase difference focus detection focus position and the focus detection focus position is small, by using only the first correction value to calculate the focus detection correction value, the difference is not smaller The focus detection device according to any one of claims 1 to 4, wherein the focus detection correction value is calculated from the first correction value and the second correction value.
ことを特徴とする請求項1〜5のいずれか1項に記載の焦点検出装置。 The focus detection device according to any one of claims 1 to 5, wherein the aberration information of the photographing optical system is information regarding the imaging position of the photographing optical system for each of a plurality of different spatial frequencies.
前記焦点検出補正値によって補正された焦点検出の結果に基づいて前記撮影光学系が有するフォーカスレンズの位置を制御する制御手段と、
を備える
ことを特徴とする撮像装置。 The focus detection device according to any one of claims 1 to 6.
A control means for controlling the position of the focus lens of the photographing optical system based on the result of the focus detection corrected by the focus detection correction value, and
An imaging device characterized by comprising.
撮影光学系の収差情報から、画像の画像特性または評価特性から算出される撮像合焦位置と、焦点検出手段の焦点検出特性から算出される焦点検出合焦位置から第1補正値を算出する第1算出工程と、
一対の線像強度分布の形状が互いに異なることで生じる重心ずれ量差に応じた補正値であって、前記焦点検出合焦位置における前記撮像手段の一対の光電変換部に対応した前記撮影光学系の線像強度分布に基づいて位相差焦点検出方式で検出される位相差焦点検出合焦位置から第2補正値を算出する第2算出工程と、
前記第1補正値と前記第2補正値から焦点検出補正値を算出する第3算出工程と、
を有する
ことを特徴とする焦点検出方法。 A focus detection method of a focus detection device having an imaging means having a plurality of pixels capable of photoelectrically converting a light flux passing through different pupil regions of an imaging optical system and outputting a pair of photoelectric conversion signals.
The first correction value is calculated from the imaging in-focus position calculated from the image characteristics or evaluation characteristics of the image from the aberration information of the photographing optical system and the focus detection in-focus position calculated from the focus detection characteristics of the focus detection means. 1 calculation process and
The imaging optical system corresponding to the pair of photoelectric conversion units of the imaging means at the focus detection focusing position, which is a correction value corresponding to the difference in the amount of center of gravity shift caused by the shapes of the pair of line image intensity distributions being different from each other. The second calculation step of calculating the second correction value from the phase difference focus detection focusing position detected by the phase difference focus detection method based on the line image intensity distribution of
A third calculation step of calculating the focus detection correction value from the first correction value and the second correction value, and
A focus detection method characterized by having.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2016151419A JP6890937B2 (en) | 2016-08-01 | 2016-08-01 | Focus detector, image pickup device, and focus detection method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2016151419A JP6890937B2 (en) | 2016-08-01 | 2016-08-01 | Focus detector, image pickup device, and focus detection method |
Publications (3)
Publication Number | Publication Date |
---|---|
JP2018021971A JP2018021971A (en) | 2018-02-08 |
JP2018021971A5 JP2018021971A5 (en) | 2019-09-12 |
JP6890937B2 true JP6890937B2 (en) | 2021-06-18 |
Family
ID=61164472
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2016151419A Active JP6890937B2 (en) | 2016-08-01 | 2016-08-01 | Focus detector, image pickup device, and focus detection method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP6890937B2 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2020003686A (en) * | 2018-06-29 | 2020-01-09 | キヤノン株式会社 | Focus detection device, imaging apparatus, and interchangeable lens device |
TWI781490B (en) * | 2020-02-27 | 2022-10-21 | 日商斯庫林集團股份有限公司 | Focusing position detection method, focusing position detector, recording medium, and focusing position detection program |
CN114324423B (en) * | 2021-12-24 | 2023-07-25 | 武汉联影生命科学仪器有限公司 | Focus correction method, apparatus, system, computer device, and readable storage medium |
Family Cites Families (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5300414B2 (en) * | 2008-10-30 | 2013-09-25 | キヤノン株式会社 | Camera and camera system |
JP2015049330A (en) * | 2013-08-30 | 2015-03-16 | キヤノン株式会社 | Interchangeable lens, imaging device, control method of interchangeable lens and imaging device, and control program thereof |
JP6313685B2 (en) * | 2014-05-01 | 2018-04-18 | キヤノン株式会社 | Imaging apparatus and control method thereof |
-
2016
- 2016-08-01 JP JP2016151419A patent/JP6890937B2/en active Active
Also Published As
Publication number | Publication date |
---|---|
JP2018021971A (en) | 2018-02-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11099459B2 (en) | Focus adjustment device and method capable of executing automatic focus detection, and imaging optical system storing information on aberrations thereof | |
US10313578B2 (en) | Image capturing apparatus and method for controlling image capturing apparatus | |
JP6478457B2 (en) | Focus adjustment device and focus adjustment method | |
JP6429546B2 (en) | Imaging apparatus, control method, program, and storage medium | |
US9641769B2 (en) | Image capture apparatus and method for controlling the same | |
JP6682310B2 (en) | Focus detection apparatus and method, and imaging apparatus | |
JP6486288B2 (en) | Imaging apparatus, control method, program, storage medium | |
JP6298362B2 (en) | Imaging apparatus, control method therefor, and imaging system | |
JP6843604B2 (en) | Information processing device and information processing method | |
US10326924B2 (en) | Focus detection apparatus and method, image capturing apparatus, and lens unit | |
JP6890937B2 (en) | Focus detector, image pickup device, and focus detection method | |
JP7091053B2 (en) | Imaging device and focus detection method | |
JP6854619B2 (en) | Focus detection device and method, imaging device, lens unit and imaging system | |
JP7037271B2 (en) | Focus detectors and focus detectors, imaging devices, programs and storage media | |
JP6744933B2 (en) | Lens part and its control method | |
JP6685769B2 (en) | Information processing device, imaging device, and information processing method | |
JP6686191B2 (en) | Focus detection device, imaging device, and focus detection method | |
JP6686239B1 (en) | Lens unit, transmitter, and receiver | |
JP6548626B2 (en) | Image pickup apparatus, control method for image pickup apparatus, and focus control program | |
JP2020003686A (en) | Focus detection device, imaging apparatus, and interchangeable lens device | |
JP6415054B2 (en) | Imaging apparatus and imaging method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20190730 |
|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20190730 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20200630 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20200707 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20200904 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20201222 |
|
A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20210219 |
|
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: 20210427 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20210526 |
|
R151 | Written notification of patent or utility model registration |
Ref document number: 6890937 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R151 |