[go: up one dir, main page]

JP2014074851A - Focus detection device and image capturing device - Google Patents

Focus detection device and image capturing device Download PDF

Info

Publication number
JP2014074851A
JP2014074851A JP2012223199A JP2012223199A JP2014074851A JP 2014074851 A JP2014074851 A JP 2014074851A JP 2012223199 A JP2012223199 A JP 2012223199A JP 2012223199 A JP2012223199 A JP 2012223199A JP 2014074851 A JP2014074851 A JP 2014074851A
Authority
JP
Japan
Prior art keywords
filter
focus
image
detection
focus detection
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.)
Pending
Application number
JP2012223199A
Other languages
Japanese (ja)
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 JP2012223199A priority Critical patent/JP2014074851A/en
Publication of JP2014074851A publication Critical patent/JP2014074851A/en
Pending legal-status Critical Current

Links

Images

Landscapes

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

Abstract

【課題】光学系の焦点検出を適切に行なうことができる焦点検出装置を提供すること。
【解決手段】第1圧縮度で圧縮された画像信号から前記光学系による像面のずれ量に対応する像ずれ信号を取得し、検出可能な周波数帯域が最も高い第1フィルタを除く複数のフィルタのなかから、取得した像ずれ信号に適した周波数帯域を検出可能なフィルタを選択して、選択したフィルタによりフィルタ処理された像ずれ信号に基づいて、ずれ量を検出し、光学系の焦点状態が合焦範囲を含む合焦位置近傍にあると判定され、かつ、ずれ量を検出した際に用いられたフィルタが、検出可能な周波数帯域が2番目に高い第2フィルタであった場合には、第1圧縮度よりも圧縮度合いの低い第2圧縮度で圧縮した画像信号、または圧縮がされていない画像信号から光学系による像面のずれ量に対応する像ずれ信号を取得し、検出可能な周波数帯域が最も高い第1フィルタによりフィルタ処理された像ずれ信号に基づいて、ずれ量を検出することを特徴とする焦点検出装置。
【選択図】 図1
A focus detection apparatus capable of appropriately detecting the focus of an optical system is provided.
An image shift signal corresponding to an image plane shift amount by the optical system is obtained from an image signal compressed at a first compression degree, and a plurality of filters excluding a first filter having the highest detectable frequency band. A filter capable of detecting a frequency band suitable for the acquired image shift signal is selected, and the shift amount is detected based on the image shift signal filtered by the selected filter, and the focus state of the optical system. Is determined to be in the vicinity of the in-focus position including the in-focus range, and the filter used when detecting the shift amount is the second filter having the second highest detectable frequency band. An image shift signal corresponding to the image plane shift amount by the optical system can be acquired from an image signal compressed at a second compression level lower than the first compression level or an uncompressed image signal, and can be detected. Frequency Based the frequency is highest first filter filtered image shift signals, the focus detection device and detects the shift amount.
[Selection] Figure 1

Description

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

従来より、撮影光学系による像を撮像するための撮像素子に、結像光学系の異なる領域を通過した光束を受光する焦点検出用の画素を混在させて、該焦点検出用の画素の出力を用いて、撮影光学系の焦点状態の検出を行う技術が知られている(たとえば、特許文献1参照)。   Conventionally, a focus detection pixel that receives a light beam that has passed through different areas of the imaging optical system is mixed in an image sensor for capturing an image by the photographing optical system, and the output of the focus detection pixel is output. A technique for detecting the focus state of a photographing optical system using the same is known (for example, see Patent Document 1).

特開2009−75407号公報JP 2009-75407 A

しかしながら、従来技術では、撮像素子からの出力を用いて焦点状態の検出をするための演算を行うため、演算に用いるデータ量が多くなり、そのため、演算負荷が大きいという問題があった。   However, in the prior art, since the calculation for detecting the focus state is performed using the output from the image sensor, the amount of data used for the calculation increases, and there is a problem that the calculation load is large.

本発明が解決しようとする課題は、光学系の焦点検出を適切に行なうことができる焦点検出装置を提供することにある。   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]本発明の焦点検出装置は、光学系(31,32,33)による像を撮像し、撮像した像に対応する画像信号を生成し、生成した画像信号を出力する撮像部(22)と、
所定の第1圧縮度で圧縮した画像信号、前記第1圧縮度よりも圧縮度合いの低い第2圧縮度で圧縮した画像信号、または圧縮がされていない画像信号の生成をするように前記撮像部を制御する撮像制御部(21)と、前記撮像部により出力された画像信号に基づいて、位相差を用いて、前記光学系による像面のずれ量を検出することで、前記光学系の焦点状態を検出する焦点検出部(21)と、前記光学系の焦点状態が、合焦位置近傍にあるか否かを判断する判断部(21)と、検出可能な周波数帯域が所定周波数帯域の第1フィルタと、検出可能な周波数帯域が前記第1フィルタよりも低い周波数である第2フィルタと、検出可能な周波数帯域が前記第2フィルタよりも低い周波数である第3フィルタとを有するフィルタ部(21)とを備え、前記焦点検出部は、前記第1圧縮度で圧縮された画像信号から前記光学系による像面のずれ量に対応する像ずれ信号を取得し、前記複数のフィルタのうち、前記第1フィルタを除く複数のフィルタのなかから、前記取得した像ずれ信号に適した周波数帯域を検出可能なフィルタを選択して、選択したフィルタによりフィルタ処理された像ずれ信号に基づいて、前記ずれ量を検出し、前記判断部により、前記光学系の焦点状態が前記合焦位置近傍にあると判断され、かつ、前記焦点検出部によって前記ずれ量を検出した際に用いられたフィルタが、前記第2フィルタであった場合には、前記第2圧縮度で圧縮された画像信号、または圧縮がされていない画像信号から前記光学系による像面のずれ量に対応する像ずれ信号を取得し、前記フィルタ部の前記複数のフィルタのうち、前記第1フィルタを選択して、前記第1フィルタによりフィルタ処理された像ずれ信号に基づいて、前記ずれ量を検出することを特徴とする。
[1] The focus detection apparatus of the present invention captures an image by the optical system (31, 32, 33), generates an image signal corresponding to the captured image, and outputs the generated image signal (22). When,
The imaging unit is configured to generate an image signal compressed at a predetermined first compression degree, an image signal compressed at a second compression degree lower than the first compression degree, or an uncompressed image signal. And an image control unit (21) that controls the image, and based on the image signal output from the image pickup unit, the amount of displacement of the image plane by the optical system is detected using the phase difference, thereby focusing the optical system. A focus detection unit (21) for detecting the state, a determination unit (21) for determining whether the focus state of the optical system is in the vicinity of the in-focus position, and a detectable frequency band having a predetermined frequency band. A filter unit having one filter, a second filter whose detectable frequency band is lower than the first filter, and a third filter whose detectable frequency band is lower than the second filter ( 21) and The focus detection unit obtains an image shift signal corresponding to an image plane shift amount by the optical system from the image signal compressed at the first compression degree, and selects the first filter among the plurality of filters. A filter capable of detecting a frequency band suitable for the acquired image shift signal is selected from a plurality of filters excluding the filter, and the shift amount is detected based on the image shift signal filtered by the selected filter. The filter used when the determination unit determines that the focus state of the optical system is in the vicinity of the in-focus position and the shift amount is detected by the focus detection unit is the second filter. If there is, an image shift signal corresponding to an image plane shift amount by the optical system is acquired from the image signal compressed at the second compression degree or the image signal not compressed, and the image signal is acquired. Among the plurality of filter data section, by selecting the first filter, on the basis of the first filtered image shift signals by the filter, and detects the shift amount.

[2]本発明の焦点検出装置において、合焦状態であるか否かを判定する合焦判定部(21)をさらに有し、前記合焦判定部が、一度、前記焦点検出部(21)により、前記ずれ量の検出が前記第1フィルタを用いて行われた後、再度、前記焦点検出部により、前記ずれ量の検出が前記第1フィルタを用いて行われるまで、合焦判定を行わないように構成することができる。   [2] The focus detection apparatus of the present invention further includes a focus determination unit (21) that determines whether or not the focus state is in focus, and the focus determination unit is once configured to be the focus detection unit (21). Thus, after the detection of the shift amount is performed using the first filter, the focus determination is performed again by the focus detection unit until the detection of the shift amount is performed using the first filter. It can be configured not to.

[3]本発明の焦点検出装置において、前記撮像制御部(21)が、前記撮像部(22)に備えられた光電変換素子の出力を加算する処理、または前記光電変換素子の出力を間引く処理により、前記撮像部に、圧縮された画像信号の生成を行わせるように構成することができる。   [3] In the focus detection apparatus of the present invention, the imaging control unit (21) adds the outputs of the photoelectric conversion elements provided in the imaging unit (22) or thins out the outputs of the photoelectric conversion elements. Thus, the imaging unit can be configured to generate a compressed image signal.

[4]本発明に係る撮像装置は、上記焦点検出装置を備えることを特徴とする。   [4] 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の焦点検出画素列22a付近を拡大して焦点検出画素222a,222bの配列を模式的に示す正面図である。FIG. 3 is a front view schematically showing the arrangement of the focus detection pixels 222a and 222b by enlarging the vicinity of the focus detection pixel row 22a of FIG. 図4(A)は、撮像画素221の一つを拡大して示す正面図、図4(B)は、焦点検出画素222aの一つを拡大して示す正面図、図4(C)は、焦点検出画素222bの一つを拡大して示す正面図、図4(D)は、撮像画素221の一つを拡大して示す断面図、図4(E)は、焦点検出画素222aの一つを拡大して示す断面図、図4(F)は、焦点検出画素222bの一つを拡大して示す断面図である。4A is an enlarged front view showing one of the imaging pixels 221, FIG. 4B is an enlarged front view showing one of the focus detection pixels 222a, and FIG. FIG. 4D is an enlarged front view showing one of the focus detection pixels 222b, FIG. 4D is a cross-sectional view showing one of the imaging pixels 221 in an enlarged manner, and FIG. 4E is one of the focus detection pixels 222a. FIG. 4F is an enlarged sectional view showing one of the focus detection pixels 222b. 図5は、図3のV-V線に沿う断面図である。FIG. 5 is a cross-sectional view taken along the line VV in FIG. 図6は、本実施形態に係るカメラの動作を示すフローチャートある。FIG. 6 is a flowchart showing the operation of the camera according to the present embodiment.

以下、本発明の実施形態を図面に基づいて説明する。   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によってその位置が調節される。なお、エンコーダ35で検出されたフォーカスレンズ32の現在位置情報は、レンズ制御部37を介して後述するカメラ制御部21へ送出され、フォーカスレンズ駆動モータ36は、この情報に基づいて演算されたフォーカスレンズ32の駆動位置が、カメラ制御部21からレンズ制御部37を介して送出されることにより駆動する。   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. Note that 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の構造の詳細は後述する。   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 camera memory 24 which is a recording medium. The camera memory 24 can be either a removable card type memory or a built-in memory. 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. Are output to the liquid crystal drive circuit 25 and the camera 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の各種動作モードを設定するための入力スイッチであり、オートフォーカスモード/マニュアルフォーカスモードの切換や、オードフォーカスモードの中でも、ワンショットモード/コンティニュアスモードの切換が行えるようになっている。この操作部28により設定された各種モードはカメラ制御部21へ送出され、当該カメラ制御部21によりカメラ1全体の動作が制御される。また、シャッターレリーズボタンは、ボタンの半押しでONとなる第1スイッチSW1と、ボタンの全押しでONとなる第2スイッチSW2とを含む。   The operation unit 28 is an input switch for a photographer to set various operation modes of the camera 1 such as a shutter release button and a moving image shooting start switch. The operation unit 28 switches between an auto focus mode / manual focus mode and an auto focus mode. In particular, the one-shot mode / continuous mode can be switched. 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の焦点検出画素列22a付近を拡大して焦点検出画素222a,222bの配列を模式的に示す正面図である。   FIG. 2 is a front view showing the imaging surface of the imaging element 22, and FIG. 3 is a front view schematically showing the arrangement of the focus detection pixels 222a and 222b by enlarging the vicinity of the focus detection pixel row 22a in 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(A)は、撮像画素221の一つを拡大して示す正面図、図4(D)は断面図である。一つの撮像画素221は、マイクロレンズ2211と、光電変換部2212と、図示しないカラーフィルタから構成され、図4(D)の断面図に示すように、撮像素子22の半導体回路基板2213の表面に光電変換部2212が造り込まれ、その表面にマイクロレンズ2211が形成されている。光電変換部2212は、マイクロレンズ2211により撮影光学系の射出瞳(たとえばF1.0)を通過する撮像光束を受光する形状とされ、撮像光束を受光する。   4A is an enlarged front view showing one of the imaging pixels 221 and FIG. 4D is a cross-sectional view. One imaging pixel 221 includes a microlens 2211, a photoelectric conversion unit 2212, and a color filter (not shown), and on the surface of the semiconductor circuit substrate 2213 of the imaging element 22 as shown in the cross-sectional view of FIG. A photoelectric conversion portion 2212 is built, and a microlens 2211 is formed on the surface thereof. 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の撮像面には、上述した撮像画素221に代えて焦点検出画素222a,222bが配列された5つの焦点検出画素列22a〜22eが設けられている。そして、図3に示すように、一つの焦点検出画素列は、複数の焦点検出画素222aおよび222bが、互いに隣接して交互に、横一列に配列されて構成されている。本実施形態においては、焦点検出画素222aおよび222bは、ベイヤー配列された撮像画素221の緑画素Gと青画素Bとの位置にギャップを設けることなく密に配列されている。   Further, on the imaging surface of the imaging element 22, five focus detection pixel rows 22a to 22e in which focus detection pixels 222a and 222b are arranged instead of the above-described imaging pixel 221 are provided. As shown in FIG. 3, one focus detection pixel column is configured by a plurality of focus detection pixels 222 a and 222 b being alternately arranged adjacent to each other in a horizontal row. 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〜22eの位置は図示する位置にのみ限定されず、何れか一箇所、二箇所、三箇所、あるいは四箇所とすることもでき、また、六箇所以上の位置に配置することもできる。また、図3においては、16個の焦点検出画素222a,222bにより、焦点検出画素列を構成する例を示しているが、焦点検出画素列を構成する焦点検出画素の数は、この例に限定されるものではない。   Note that the positions of the focus detection pixel rows 22a to 22e shown in FIG. 2 are not limited to the illustrated positions, and may be any one, two, three, or four locations, and more than six locations. It can also be arranged at the position. FIG. 3 shows an example in which the focus detection pixel array is configured by 16 focus detection pixels 222a and 222b, but the number of focus detection pixels configuring the focus detection pixel array is limited to this example. Is not to be done.

図4(B)は、焦点検出画素222aの一つを拡大して示す正面図、図4(E)は、焦点検出画素222aの断面図である。また、図4(C)は、焦点検出画素222bの一つを拡大して示す正面図、図4(F)は、焦点検出画素222bの断面図である。焦点検出画素222aは、図4(B)に示すように、マイクロレンズ2221aと、半円形状の光電変換部2222aとから構成され、図4(E)の断面図に示すように、撮像素子22の半導体回路基板2213の表面に光電変換部2222aが造り込まれ、その表面にマイクロレンズ2221aが形成されている。また、焦点検出画素222bは、図4(C)に示すように、マイクロレンズ2221bと、光電変換部2222bとから構成され、図4(F)の断面図に示すように、撮像素子22の半導体回路基板2213の表面に光電変換部2222bが造り込まれ、その表面にマイクロレンズ2221bが形成されている。そして、これら焦点検出画素222aおよび222bは、図3に示すように、互いに隣接して交互に、横一列に配列されることにより、図2に示す焦点検出画素列22a〜22cを構成する。   4B is an enlarged front view of one of the focus detection pixels 222a, and FIG. 4E is a cross-sectional view of the focus detection pixel 222a. 4C is an enlarged front view showing one of the focus detection pixels 222b, and FIG. 4F is a cross-sectional view of the focus detection pixel 222b. As shown in FIG. 4B, 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. 4C, and a semiconductor of the image sensor 22 as shown in the cross-sectional view of FIG. 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.

また、図4(B)、図4(C)に示す焦点検出画素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. 4B and 4C have a semicircular shape, the shape of the photoelectric conversion units 2222a and 2222b is 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.

図5は、図3のV-V線に沿う断面図であり、撮影光軸L1近傍に配置され、互いに隣接する焦点検出画素222a−1,222b−1,222a−2,222b−2が、射出瞳350の測距瞳351,352から照射される光束AB1−1,AB2−1,AB1−2,AB2−2をそれぞれ受光していることを示している。なお、図5においては、複数の焦点検出画素222a,222bのうち、撮影光軸L1近傍に位置するもののみを例示して示したが、図5に示す焦点検出画素以外のその他の焦点検出画素についても、同様に、一対の測距瞳351,352から照射される光束をそれぞれ受光するように構成されている。   FIG. 5 is a cross-sectional view taken along the line V-V in FIG. 3. 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. In FIG. 5, only the focus detection pixels 222 a and 222 b that are located in the vicinity of the photographing optical axis L <b> 1 are illustrated, but other focus detection pixels other than the focus detection pixels illustrated in FIG. 5 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.

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

また、図5に示すように、焦点検出画素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. 5, 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.

図5に示すように、焦点検出画素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. 5, the photoelectric conversion unit 2222a-1 of the focus detection pixel 222a-1 is formed on the microlens 2221a-1 by a 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. Next, filter processing is performed on the intensity distribution data of the pair of images to calculate post-filter processing data.

ここで、本実施形態においては、一対の像の強度分布データに対応する被写体の空間周波数に対応するように、検波周波数帯域(すなわち、検出可能な周波数帯域)の異なる複数の検波フィルタをカメラ制御部21に記憶している。すなわち、カメラ制御部21は、低周波被写体から高周波被写体まで、あらゆる被写体の空間周波数に対応できるように、検波周波数帯域の異なる複数の検波フィルタを記憶しており、本実施形態では、検波周波数帯域の異なる検波フィルタを3つ以上記憶しており、たとえば、検波周波数帯域の高い方から順に、第1フィルタf1、第2フィルタf2、第3フィルタf3、第4フィルタf4、第5フィルタf5の5つのフィルタが記憶されているような態様とすることができるが、特にこれに限定されるものではない。   Here, in the present embodiment, a plurality of detection filters having different detection frequency bands (that is, detectable frequency bands) are controlled by the camera so as to correspond to the spatial frequency of the subject corresponding to the intensity distribution data of the pair of images. Stored in the unit 21. That is, the camera control unit 21 stores a plurality of detection filters having different detection frequency bands so as to correspond to the spatial frequencies of all objects from a low-frequency subject to a high-frequency subject. Three or more detection filters having different detection frequencies are stored. For example, the first filter f1, the second filter f2, the third filter f3, the fourth filter f4, and the fifth filter f5 are arranged in order from the highest detection frequency band. Although it is possible to adopt a mode in which two filters are stored, the present invention is not particularly limited to this.

そして、本実施形態では、上記にて得られた一対の像の強度分布データに対し、検波周波数帯域の異なる複数の検波フィルタのうちから、1つの検波フィルタを選択し、選択した検波フィルタを用いて、フィルタ処理を行なうことで、フィルタ処理後データを算出する。なお、検波フィルタの選択方法については後述する。そして、得られたフィルタ処理後データに対して、像ズレ検出演算処理(相関演算処理)を施すことにより、いわゆる位相差検出方式によるデフォーカス量を算出する。   In the present embodiment, for the intensity distribution data of the pair of images obtained above, one detection filter is selected from a plurality of detection filters having different detection frequency bands, and the selected detection filter is used. Then, the filtered data is calculated by performing the filtering process. A detection filter selection method will be described later. Then, an image shift detection calculation process (correlation calculation process) is performed on the obtained post-filter data, thereby calculating a defocus amount by a so-called phase difference detection method.

具体的には、カメラ制御部21は、各焦点検出画素222aから読み出され、次いで、フィルタ処理することにより得られたフィルタ処理後第1像データ列a,a,...,aと、各焦点検出画素222bから読み出され、次いで、フィルタ処理することにより得られたフィルタ処理後第2像データ列b,b,...bとを、一次元状に相対的にシフトさせながら、下記式(1)に示す相関演算を行う。
C(k)=Σ|a(n+k)−b(n)| …(1)
なお、上記式(1)において、Σ演算はnについての累積演算(相和演算)を示し、像ずらし量kに応じてa(n+k)、b(n)のデータが存在する範囲に限定される。また、像ずらし量kは整数であり、各焦点検出画素222a,222bの画素間隔を単位としたシフト量である。なお、上記式(1)の演算結果においては、一対の像データの相関が高いシフト量において、相関量C(k)は極小(小さいほど相関度が高い)になる。
Specifically, the camera control unit 21 reads the first image data strings a 1 , a 2 ,... After filtering, which are read out from each focus detection pixel 222a and then obtained by filtering. . . , An, and the filtered second image data sequence b 1 , b 2 ,. . . and b n, while relatively shifting one-dimensionally, performs correlation calculation of the following formula (1).
C (k) = Σ | a (n + k) −b (n) | (1)
In the above equation (1), the Σ operation indicates a cumulative operation (phase sum operation) for n, and is limited to a range in which data of a (n + k) and b (n) exist according to the image shift amount k. The The image shift amount k is an integer, and is a shift amount in units of pixel intervals between the focus detection pixels 222a and 222b. In the calculation result of the above formula (1), the correlation amount C (k) is minimal (the correlation degree is higher as it is smaller) in the shift amount where the correlation between the pair of image data is high.

次いで、カメラ制御部21は、算出した相関量C(k)に基づいて、相関量の極小値を算出する。本実施形態では、たとえば、以下の下記式(2)〜(5)に示す3点内挿の手法を用いて、連続的な相関量に対する極小値C(x)と、極小値C(x)を与えるシフト量xを算出し、これを像ズレ量とする。なお、下記式に示すC(kj)は、上記式(1)で得られた相関量C(k)のうち、C(k−1)≧C(k)およびC(k+1)>C(k)の条件を満たす値である。
D={C(kj−1)−C(kj+1)}/2 …(2)
C(x)= C(kj)−|D| …(3)
x=kj+D/SLOP …(4)
SLOP=MAX{C(kj+1)−C(kj),C(kj−1)−C(kj)} …(5)
Next, the camera control unit 21 calculates a minimum value of the correlation amount based on the calculated correlation amount C (k). In the present embodiment, for example, the minimum value C (x) and the minimum value C (x) with respect to the continuous correlation amount are obtained by using the three-point interpolation method shown in the following formulas (2) to (5). The shift amount x that gives is calculated as an image shift amount. Note that C (kj) shown in the following equation is C (k−1) ≧ C (k) and C (k + 1)> C (k) among the correlation amounts C (k) obtained in the above equation (1). ) Satisfying the condition of
D = {C (kj−1) −C (kj + 1)} / 2 (2)
C (x) = C (kj) − | D | (3)
x = kj + D / SLOP (4)
SLOP = MAX {C (kj + 1) -C (kj), C (kj-1) -C (kj)} (5)

そして、カメラ制御部21は、相関量の極小値C(x)が得られるシフト量xに基づいて、下記式(6)に従い、デフォーカス量dfを算出する。なお、上記式(6)において、kは、相関量の極小値C(x)が得られるシフト量xをデフォーカス量に変換するための変換係数(kファクター)である。
df=x・k …(6)
Then, the camera control unit 21 calculates the defocus amount df according to the following equation (6) based on the shift amount x from which the minimum value C (x) of the correlation amount is obtained. In the above equation (6), k is a conversion coefficient (k factor) for converting the shift amount x from which the minimum value C (x) of the correlation amount is obtained into the defocus amount.
df = x · k (6)

また、カメラ制御部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に制御信号を送出してフォーカスレンズ32を所定のサンプリング間隔(距離)で駆動させ、それぞれの位置における焦点評価値を求め、該焦点評価値が最大となるフォーカスレンズ32の位置を合焦位置として求める、コントラスト検出方式による焦点検出を実行する。なお、この合焦位置は、たとえば、フォーカスレンズ32を駆動させながら焦点評価値を算出した場合に、焦点評価値が、2回上昇した後、さらに、2回下降して推移した場合に、これらの焦点評価値を用いて、内挿法などの演算を行うことで求めることができる。   Then, the camera control unit 21 sends a control signal to the lens control unit 37 to drive the focus lens 32 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 32 is determined as the in-focus position. Note that this in-focus position is obtained when, for example, when the focus evaluation value is calculated while driving the focus lens 32, 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の動作例を、図6に示すフローチャートに沿って説明する。なお、以下における動作は、カメラ1の電源がオンされることにより開始される。   Next, an example of the operation of the camera 1 in the present embodiment will be described along the flowchart shown in FIG. The following operation is started when the camera 1 is turned on.

まず、ステップS1では、カメラ制御部21によるスルー画像の生成、および観察光学系の電子ビューファインダ26による、スルー画像の表示が開始される。具体的には、カメラ制御部21が、撮像素子22に露光動作を行わせるための信号を送信し、これにより撮像素子22の露光動作が実行される。なお、この際において、カメラ制御部21は、撮像素子22に、図3に示す複数の撮像画素221の画素データおよび複数の焦点検出画素222a,222bの画素データのうち、一部を間引いて、カメラ制御部21に送信するように指令する。すなわち、撮像素子22は、図3に示す複数の撮像画素221の画素データおよび複数の焦点検出画素222a,222bのうち、一部の画素の画素データのみを間引いて読み出し、カメラ制御部21には、一部が間引かれた画素データが出力される。たとえば、焦点検出画素222a,222bを例示して説明すると、図3中において、焦点検出画素222a,222bが、交互に16個並んでいる構成となっているが、2個おきに間引きを行い、合計8個の焦点検出画素222a,222bからの画素データのみを、カメラ制御部21に出力するような構成とすることができる。また、この場合においては、撮像画素221についても、同様に縦方向において2個おきに間引きを行うことができる。
あるいは、ステップS1においては、カメラ制御部21は、図3に示す複数の撮像画素221の画素データおよび複数の焦点検出画素222a,222bの全ての画素の画素データをカメラ制御部21に送信するように指令し、カメラ制御部21は、全ての画素の画素データを取得して、カメラ制御部21により、一部の画素の画素データのみを間引くような構成としてもよい。
First, in step S1, generation of a through image by the camera control unit 21 and display of a through image by the electronic viewfinder 26 of the observation optical system are started. Specifically, the camera control unit 21 transmits a signal for causing the image sensor 22 to perform an exposure operation, whereby the exposure operation of the image sensor 22 is executed. At this time, the camera control unit 21 thins out a part of the pixel data of the plurality of imaging pixels 221 and the pixel data of the plurality of focus detection pixels 222a and 222b shown in FIG. Commands the camera control unit 21 to transmit. That is, the image sensor 22 thins out and reads out only pixel data of some of the pixel data of the plurality of imaging pixels 221 and the plurality of focus detection pixels 222a and 222b shown in FIG. , Pixel data partially thinned is output. For example, the focus detection pixels 222a and 222b will be described as an example. In FIG. 3, 16 focus detection pixels 222a and 222b are arranged alternately. Only pixel data from a total of eight focus detection pixels 222 a and 222 b can be output to the camera control unit 21. In this case, the image pickup pixel 221 can also be thinned out every two pixels in the vertical direction.
Alternatively, in step S1, the camera control unit 21 transmits the pixel data of the plurality of imaging pixels 221 and the pixel data of all the pixels of the plurality of focus detection pixels 222a and 222b illustrated in FIG. 3 to the camera control unit 21. The camera control unit 21 may acquire pixel data of all pixels, and the camera control unit 21 may thin out only the pixel data of some pixels.

そして、カメラ制御部21は、読み出したデータに基づきスルー画像を生成し、生成されたスルー画像は液晶駆動回路25に送出され、観察光学系の電子ビューファインダ26に表示される。そして、これにより、接眼レンズ27を介して、ユーザは被写体の動画を視認することが可能となる。なお、このような画素データの生成・出力、スルー画像の生成、およびスルー画像の表示は、所定の間隔で繰り返し実行される。   Then, the camera control unit 21 generates a through image based on the read data, and the generated through image is sent to the liquid crystal drive circuit 25 and displayed on the electronic viewfinder 26 of the observation optical system. As a result, the user can view the moving image of the subject through the eyepiece lens 27. Note that such pixel data generation / output, through image generation, and through image display are repeatedly executed at predetermined intervals.

ステップS2では、カメラ制御部21により、位相差検出方式によるデフォーカス量の検出処理が開始される。本実施形態では、位相差検出方式によるデフォーカス量の検出処理は、次のように行なわれる。すなわち、まず、カメラ制御部21により、撮像素子22の5つの焦点検出画素列22a〜22dを構成する各焦点検出画素222a,222bの画素データから一対の像に対応した一対の像データ(一対の像の強度分布に関するデータ)を生成する。なお、この際においては、上述したように、撮像素子21から出力される画素データは、所定の割合で間引かれたものであるため、間引かれた画素データを用いる。
あるいは、ステップS1において、カメラ制御部21により、全ての画素の画素データを取得して、カメラ制御部21により、一部の画素の画素データのみを間引くような構成とした場合には、カメラ制御部21は、この間引かれた画素データを用いて、一対の像データを生成する。
In step S2, the camera control unit 21 starts defocus amount detection processing by the phase difference detection method. In the present embodiment, the defocus amount detection processing by the phase difference detection method is performed as follows. That is, first, the camera control unit 21 uses a pair of image data (a pair of image data) corresponding to a pair of images from the pixel data of the focus detection pixels 222a and 222b constituting the five focus detection pixel rows 22a to 22d of the image sensor 22. Data on the intensity distribution of the image). At this time, as described above, since the pixel data output from the image sensor 21 is thinned out at a predetermined rate, the thinned pixel data is used.
Alternatively, in step S1, the camera control unit 21 acquires pixel data of all pixels, and the camera control unit 21 thins out only some pixel data. The unit 21 generates a pair of image data using the thinned pixel data.

そして、カメラ制御部21は、カメラ制御部21に記憶されている検波周波数帯域の異なる複数の検波フィルタのうち、検波周波数帯域が最も高い検波フィルタを除いた複数の検波フィルタのうち、生成した一対の像データに適した検波フィルタの選択を行う。ここで、一例として、カメラ制御部21に、検波周波数帯域の異なる複数の検波フィルタとして、検波周波数帯域の高い方から順に、第1フィルタf1、第2フィルタf2、第3フィルタf3、第4フィルタf4、第5フィルタf5の5つのフィルタが記憶されている場合を例示して説明すると、検波周波数帯域が最も高い検波フィルタである第1フィルタf1を除いた第2〜第5フィルタf2〜f5から、生成した一対の像データに適した検波フィルタを選択する処理がなされる。なお、以下においては、これら第1〜第5フィルタf1〜f5を備えている場合を例示して説明を行う。   Then, the camera control unit 21 generates the generated pair of detection filters other than the detection filter having the highest detection frequency band among the plurality of detection filters having different detection frequency bands stored in the camera control unit 21. The detection filter suitable for the image data is selected. Here, as an example, the camera control unit 21 has a first filter f1, a second filter f2, a third filter f3, and a fourth filter in order from the highest detection frequency band as a plurality of detection filters having different detection frequency bands. The case where five filters of f4 and fifth filter f5 are stored will be described as an example. From the second to fifth filters f2 to f5 excluding the first filter f1 which is the detection filter having the highest detection frequency band. Then, a process of selecting a detection filter suitable for the generated pair of image data is performed. In the following, the case where the first to fifth filters f1 to f5 are provided will be described as an example.

また、第2〜第5フィルタf2〜f5から、生成した一対の像データに適した検波フィルタを選択する方法としては、たとえば、生成した一対の像データに含まれる周波数成分に応じて選択する方法などが挙げられる。すなわち、この方法においては、たとえば、生成した一対の像データに含まれる周波数成分の周波数帯域が高いほど、検波周波数帯域の高い検波フィルタが選択され、一方、生成した一対の像データに含まれる周波数成分の周波数帯域が低いほど、検波周波数帯域の低い検波フィルタが選択されることとなる。   Moreover, as a method of selecting a detection filter suitable for the generated pair of image data from the second to fifth filters f2 to f5, for example, a method of selecting according to the frequency component included in the generated pair of image data Etc. That is, in this method, for example, as the frequency band of the frequency component included in the generated pair of image data is higher, a detection filter having a higher detection frequency band is selected. On the other hand, the frequency included in the generated pair of image data The detection filter with the lower detection frequency band is selected as the frequency band of the component is lower.

次いで、カメラ制御部21は、第2〜第5フィルタf2〜f5のなかから、選択された検波フィルタを用いて、生成した一対の像データについてフィルタ処理を行い、フィルタ処理後データに基づいて像ズレ検出演算処理(相関演算処理)を実行する。具体的には、カメラ制御部21は、フィルタ処理後データに基づいて、上述した方法にしたがって像ズレ量を演算し、さらに像ズレ量をデフォーカス量に変換することで、デフォーカス量を算出する。   Next, the camera control unit 21 performs a filtering process on the generated pair of image data using the detection filter selected from the second to fifth filters f2 to f5, and performs image processing based on the filtered data. A deviation detection calculation process (correlation calculation process) is executed. Specifically, the camera control unit 21 calculates the defocus amount by calculating the image shift amount according to the above-described method based on the filtered data, and further converting the image shift amount into the defocus amount. To do.

そして、このような第1フィルタf1以外の検波フィルタを用いたデフォーカス量の検出処理は、所定の間隔で繰り返し実行される。   Such defocus amount detection processing using a detection filter other than the first filter f1 is repeatedly executed at predetermined intervals.

ステップS3では、カメラ制御部21により、操作部28に備えられたシャッターレリーズボタンの半押し(第1スイッチSW1のオン)がされたかどうかの判断が行なわれる。第1スイッチSW1がオンした場合はステップS6に進む。一方、第1スイッチSW1がオンしていない場合は、第1スイッチSW1がオンされるまで、ステップS5を繰り返す。すなわち、第1スイッチSW1がオンされるまで、スルー画像の生成・表示、および位相差検出方式によるデフォーカス量の検出処理が繰り返し実行される。   In step S3, the camera control unit 21 determines whether or not the shutter release button provided in the operation unit 28 is half-pressed (the first switch SW1 is turned on). If the first switch SW1 is turned on, the process proceeds to step S6. On the other hand, if the first switch SW1 is not turned on, step S5 is repeated until the first switch SW1 is turned on. In other words, until the first switch SW1 is turned on, the through image generation / display and the defocus amount detection processing by the phase difference detection method are repeatedly executed.

ステップS4では、カメラ制御部21によって、位相差検出方式によるデフォーカス量の検出処理により、デフォーカス量の算出ができたか否かの判定が行なわれる。デフォーカス量が算出できた場合には、測距可能と判断して、ステップS5に進む。一方、デフォーカス量が算出できなかった場合には、測距不能と判断して、ステップS13に進む。そして、ステップS13において、第1スイッチSW1がオンされてから予め定められた所定時間tが経過したと判断された場合には、ステップS16に進み、非合焦処理がされ、所定時間tが経過していない場合には、ステップS4に戻る。なお、本実施形態においては、デフォーカス量の算出ができた場合でも、算出されたデフォーカス量の信頼性が低い場合には、デフォーカス量の算出ができなかったものとして扱い、ステップS13に進むこととする。本実施形態においては、たとえば、被写体のコントラストが低い場合、被写体が超低輝度被写体である場合、あるいは被写体が超高輝度被写体である場合などにおいて、デフォーカス量の信頼性が低いと判断される。また、ステップS16で行われる非合焦処理としては、たとえば、非合焦を示す表示を、電子ビューファインダ26に表示するとともに、フォーカスレンズ32を予め定められた所定の位置に駆動させることにより実行される。   In step S4, the camera control unit 21 determines whether or not the defocus amount has been calculated by the defocus amount detection process using the phase difference detection method. If the defocus amount can be calculated, it is determined that distance measurement is possible, and the process proceeds to step S5. On the other hand, if the defocus amount cannot be calculated, it is determined that distance measurement is impossible, and the process proceeds to step S13. In step S13, if it is determined that a predetermined time t has elapsed since the first switch SW1 was turned on, the process proceeds to step S16, the in-focus process is performed, and the predetermined time t has elapsed. If not, the process returns to step S4. In the present embodiment, even when the defocus amount can be calculated, if the reliability of the calculated defocus amount is low, it is treated that the defocus amount cannot be calculated, and the process proceeds to step S13. Let's go ahead. In the present embodiment, for example, when the subject has a low contrast, the subject is an ultra-low brightness subject, or the subject is an ultra-high brightness subject, it is determined that the reliability of the defocus amount is low. . Further, as the out-of-focus processing performed in step S16, for example, a display indicating out-of-focus is displayed on the electronic viewfinder 26 and the focus lens 32 is driven to a predetermined position. Is done.

ステップS5では、位相差検出方式によるデフォーカス量の検出処理により算出されたデフォーカス量に基づいて、フォーカスレンズ33の駆動を開始させる処理が行われる。具体的には、カメラ制御部21により、位相差検出方式により算出されたデフォーカス量から、フォーカスレンズ33を合焦位置まで駆動させるのに必要となるレンズ駆動量の算出が行なわれ、算出されたレンズ駆動量が、レンズ制御部36を介して、レンズ駆動モータ36に送出される。そして、レンズ駆動モータ36は、カメラ制御部21により算出されたレンズ駆動量に基づいて、フォーカスレンズ33を合焦位置まで駆動させる。なお、本実施形態においては、レンズ駆動モータ36を駆動させ、フォーカスレンズ33を合焦位置まで駆動させている間においても、カメラ制御部21は、位相差検出方式によるデフォーカス量の算出を繰り返し行っているため、その結果、新たなデフォーカス量が算出された場合には、カメラ制御部21は、新たなデフォーカス量に基づいて、フォーカスレンズ33を駆動させる。   In step S5, a process of starting driving the focus lens 33 is performed based on the defocus amount calculated by the defocus amount detection process using the phase difference detection method. Specifically, the camera control unit 21 calculates and calculates the lens driving amount necessary to drive the focus lens 33 to the in-focus position from the defocus amount calculated by the phase difference detection method. The lens driving amount is sent to the lens driving motor 36 via the lens control unit 36. Then, the lens driving motor 36 drives the focus lens 33 to the in-focus position based on the lens driving amount calculated by the camera control unit 21. In the present embodiment, the camera control unit 21 repeatedly calculates the defocus amount by the phase difference detection method even while the lens driving motor 36 is driven and the focus lens 33 is driven to the in-focus position. As a result, when a new defocus amount is calculated as a result, the camera control unit 21 drives the focus lens 33 based on the new defocus amount.

ステップS6では、カメラ制御部21により、位相差検出方式によるデフォーカス量の検出処理により算出されたデフォーカス量に基づいて、光学系の焦点状態が、所定の第1合焦範囲Dα内にあるか否かの判定が行われる。光学系の焦点状態が、第1合焦範囲Dα内にあると判定された場合には、ステップS7に進む。一方、光学系の焦点状態が、第1合焦範囲Dα内にないと判定された場合には、ステップS14に進む。そして、ステップS14において、第1スイッチSW1がオンされてから予め定められた所定時間tが経過したと判断された場合には、ステップS16に進み、非合焦処理がされ、所定時間tが経過していない場合には、ステップS6に戻る。なお、第1合焦範囲Dαは、合焦範囲を含む合焦位置近傍、たとえば、被写界深度あるいは焦点深度の2倍の範囲とすることができる。 In step S6, the camera control unit 21 based on the defocus amount calculated by the process of detecting the defocus amount by the phase difference detection method, the focus state of the optical system, a predetermined first within the focusing range D alpha A determination is made whether or not there is. Focus state of the optical system, when it is determined that in the first focusing range D alpha, the process proceeds to step S7. On the other hand, the focus state of the optical system, when it is determined not in the first focusing range D alpha, the process proceeds to step S14. In step S14, if it is determined that a predetermined time t has elapsed since the first switch SW1 was turned on, the process proceeds to step S16, the in-focus process is performed, and the predetermined time t has elapsed. If not, the process returns to step S6. Incidentally, the first focusing range D alpha, focus position near containing focusing range, for example, it can be two times the depth of field or depth of focus.

次いで、ステップS7では、直前に行った位相差検出方式によるデフォーカス量の検出処理が、検波フィルタとして、第2フィルタf2(すなわち、カメラ制御部21に記憶されている複数の検波フィルタのうち、検波周波数帯域が2番目に高い検波フィルタ)を使用して行われたか否かの判定が行われる。検波フィルタとして、第2フィルタf2を使用して位相差検出方式によるデフォーカス量の検出処理が行われた場合には、ステップS8に進む。一方、第2フィルタf2以外の検波フィルタ、すなわち、第3〜第5フィルタf3〜f5(すなわち、第2フィルタf2よりも検波周波数帯域が低い検波フィルタ)を使用して位相差検出方式によるデフォーカス量の検出処理が行われた場合には、ステップ12に進む。そして、ステップS12において、合焦したとの判定がなされ、合焦ロック(フォーカスレンズ32の駆動を禁止する処理)が行なわれる。なお、この際においては、電子ビューファインダ26により、合焦表示を行なうような構成としてもよい。また、第2フィルタf2以外の検波フィルタ、すなわち、第3〜第5フィルタf3〜f5を使用して位相差検出方式によるデフォーカス量の検出処理が行われた場合には、光学系の焦点状態が、第1合焦範囲Dαよりも、より狭い範囲である第3合焦範囲Dγ内となった後に、合焦ロックを行うような構成としてもよい。ここで、第3合焦範囲Dγとしては、たとえば、被写界深度あるいは焦点深度以下の範囲(被写界深度あるいは焦点深度の1倍以下の範囲)とすることができる。 Next, in step S7, the defocus amount detection process performed immediately before by the phase difference detection method is performed as a detection filter using the second filter f2 (that is, among the plurality of detection filters stored in the camera control unit 21). It is determined whether or not the detection is performed using a detection filter having the second highest detection frequency band. When the detection process of the defocus amount by the phase difference detection method is performed using the second filter f2 as the detection filter, the process proceeds to step S8. On the other hand, a defocus by the phase difference detection method using a detection filter other than the second filter f2, that is, the third to fifth filters f3 to f5 (that is, a detection filter having a detection frequency band lower than that of the second filter f2). If the amount detection process is performed, the process proceeds to step 12. In step S12, it is determined that the subject is in focus, and focus lock (processing for prohibiting driving of the focus lens 32) is performed. In this case, the electronic viewfinder 26 may be configured to perform in-focus display. Further, when the detection filter other than the second filter f2, that is, the third to fifth filters f3 to f5, is used to detect the defocus amount by the phase difference detection method, the focus state of the optical system but than the first focusing range D alpha, after a third within the focusing range D gamma is a narrower range may be configured as perform focus lock. Here, the third in-focus range D γ can be set to, for example, a depth of field or a depth of focus or less (a range of depth of field or less than 1 time of the depth of focus).

なお、本実施形態において、ステップS7にて、直前に行った位相差検出方式によるデフォーカス量の検出処理が、検波フィルタとして、第2フィルタf2を使用して行われたと判定された場合には、デフォーカス量の検出の対象となる主要被写体が、空間周波数が高い高周波成分を有する被写体である可能性が高いと考えられる。そのため、本実施形態においては、このような場合には、以下に説明するように、検波周波数帯域が最も高い検波フィルタである第1フィルタf1を用いて、位相差検出方式によるデフォーカス量の検出処理を行う。   In the present embodiment, when it is determined in step S7 that the defocus amount detection processing by the phase difference detection method performed immediately before is performed using the second filter f2 as a detection filter. Therefore, it is considered that there is a high possibility that the main subject for which the defocus amount is to be detected is a subject having a high frequency component with a high spatial frequency. Therefore, in this embodiment, in such a case, as described below, the defocus amount is detected by the phase difference detection method using the first filter f1 that is the detection filter having the highest detection frequency band. Process.

すなわち、まず、ステップS8において、カメラ制御部21は、撮像素子22に、図3に示す複数の撮像画素221の画素データおよび複数の焦点検出画素222a,222bの全ての画素の画素データを、カメラ制御部21に送信するように指令する。すなわち、ステップS8においては、カメラ制御部21は、撮像素子22に、図3に示す複数の撮像画素221の画素データおよび複数の焦点検出画素222a,222bの画素データのうち、一部を間引いた画素データを出力させていたのに対し、全ての画素の画素データを出力するように指令する。そして、ステップS8以降において、全ての画素の画素データを生成・出力する処理が、スルー画像の生成、およびスルー画像の表示とともに、所定の間隔で繰り返し実行される。   That is, first, in step S8, the camera control unit 21 sends the pixel data of the plurality of imaging pixels 221 and the pixel data of all the pixels of the plurality of focus detection pixels 222a and 222b shown in FIG. Commands the control unit 21 to transmit. That is, in step S8, the camera control unit 21 thins out part of the pixel data of the plurality of imaging pixels 221 and the pixel data of the plurality of focus detection pixels 222a and 222b illustrated in FIG. In contrast to outputting pixel data, it instructs to output pixel data of all pixels. In step S8 and subsequent steps, the process of generating and outputting the pixel data of all the pixels is repeatedly executed at predetermined intervals together with the generation of the through image and the display of the through image.

次いで、ステップS9に進み、ステップS9では、カメラ制御部21により、第1フィルタf1(すなわち、カメラ制御部21に記憶されている複数の検波フィルタのうち、検波周波数帯域が最も高い検波フィルタ)を用いたデフォーカス量の検出処理が開始される。すなわち、ステップS9においては、第1フィルタf1以外の検波フィルタを用いたデフォーカス量の検出処理を終了し、第1フィルタf1を用いたデフォーカス量の検出処理が開始される。なお、第1フィルタf1を用いたデフォーカス量の検出処理は、第2〜第5フィルタf2〜f5の代わりに、第1フィルタf1を用いる以外は、第1フィルタf1以外の検波フィルタを用いたデフォーカス量の検出処理と同様にして行われる。また、この際においては、上述したように、撮像素子21から出力される画素データは、間引かれていない全ての画素の画素データであるため、図3に示す複数の焦点検出画素222a,222bの画素データから一対の像に対応した一対の像データを生成する際には、焦点検出画素222a,222bの画素データとして、間引かれていない全ての画素データを用いる。そして、ステップS9以降においては、第1フィルタf1を用いたデフォーカス量の検出処理が、所定の間隔で繰り返し実行される。   Next, the process proceeds to step S9. In step S9, the camera control unit 21 causes the first filter f1 (that is, the detection filter having the highest detection frequency band among the plurality of detection filters stored in the camera control unit 21). Detection processing of the used defocus amount is started. That is, in step S9, the defocus amount detection process using the detection filter other than the first filter f1 is terminated, and the defocus amount detection process using the first filter f1 is started. The detection process of the defocus amount using the first filter f1 uses a detection filter other than the first filter f1 except that the first filter f1 is used instead of the second to fifth filters f2 to f5. This is performed in the same manner as the defocus amount detection process. At this time, as described above, since the pixel data output from the image sensor 21 is pixel data of all the pixels that are not thinned out, the plurality of focus detection pixels 222a and 222b shown in FIG. When generating a pair of image data corresponding to a pair of images from the pixel data, all pixel data not thinned out are used as the pixel data of the focus detection pixels 222a and 222b. After step S9, the defocus amount detection process using the first filter f1 is repeatedly executed at predetermined intervals.

次いで、ステップS10では、カメラ制御部21により、第1フィルタf1を用いたデフォーカス量の検出処理により算出されたデフォーカス量に基づいて、光学系の焦点状態が、所定の第2合焦範囲Dβ内にあるか否かの判定が行われる。光学系の焦点状態が、第2合焦範囲Dβ内にあると判定された場合には、ステップS7に進む。一方、光学系の焦点状態が、第2合焦範囲Dβ内にないと判定された場合には、ステップS15に進む。そして、ステップS15において、第1スイッチSW1がオンされてから予め定められた所定時間tが経過したと判断された場合には、ステップS16に進み、非合焦処理がされ、所定時間tが経過していない場合には、ステップS10に戻る。なお、第2合焦範囲Dβは、たとえば、被写界深度あるいは焦点深度以下の範囲(被写界深度あるいは焦点深度の1倍以下の範囲)とすることができる。 Next, in step S10, the focus state of the optical system is set to a predetermined second focusing range based on the defocus amount calculated by the defocus amount detection process using the first filter f1 by the camera control unit 21. A determination is made whether it is within . Focus state of the optical system, when it is determined that the second within the focusing range D beta, the process proceeds to step S7. On the other hand, the focus state of the optical system, when it is determined not within the second focusing range D beta, the process proceeds to step S15. In step S15, if it is determined that a predetermined time t has elapsed since the first switch SW1 was turned on, the process proceeds to step S16, the in-focus process is performed, and the predetermined time t has elapsed. If not, the process returns to step S10. Note that the second focus range can be set to, for example, a range equal to or less than the depth of field or the depth of focus (a range equal to or less than one time the depth of field or the depth of focus).

次いで、ステップS11では、カメラ制御部21により、第1フィルタf1を用いたデフォーカス量の検出処理が2回以上実行されたか否かの判定が行われる。第1フィルタf1を用いたデフォーカス量の検出処理が2回以上実行された場合には、ステップS12に進み、ステップS12において、合焦したとの判定がなされ、合焦ロックが行われる。一方、第1フィルタf1を用いたデフォーカス量の検出処理が1回しか行われていない場合には、ステップS10に戻る。すなわち、本実施形態においては、デフォーカス量の検出の対象となる主要被写体が、空間周波数が高い高周波成分を有する被写体である場合には、第1フィルタf1を用いたデフォーカス量の検出処理により、デフォーカス量の検出精度が向上することが期待できる。そのため、本実施形態では、第1フィルタf1を用いたデフォーカス量の検出処理が1回しか行われていない場合には、該検出処理の結果に基づくフォーカスレンズ32の駆動が行われ、再度、第1フィルタf1を用いたデフォーカス量の検出処理を行った後(すなわち、ステップS11=Yes)に、合焦したとの判定を行う。   Next, in step S11, the camera control unit 21 determines whether or not the defocus amount detection process using the first filter f1 has been executed twice or more. If the defocus amount detection process using the first filter f1 has been executed twice or more, the process proceeds to step S12. In step S12, it is determined that the in-focus state is achieved, and the focus lock is performed. On the other hand, if the defocus amount detection process using the first filter f1 has been performed only once, the process returns to step S10. In other words, in the present embodiment, when the main subject to be detected for the defocus amount is a subject having a high frequency component with a high spatial frequency, the defocus amount detection process using the first filter f1 is performed. It can be expected that the detection accuracy of the defocus amount is improved. Therefore, in the present embodiment, when the defocus amount detection process using the first filter f1 is performed only once, the focus lens 32 is driven based on the result of the detection process, and again, After performing the defocus amount detection process using the first filter f1 (that is, step S11 = Yes), it is determined that the in-focus state is achieved.

以上のように、本実施形態に係るカメラ1は動作する。   As described above, the camera 1 according to this embodiment operates.

本実施形態においては、位相差検出方式によるデフォーカス量の検出処理を行う際に、図3に示す複数の焦点検出画素222a,222bの画素データのうち、一部が間引かれた画素データを用いて一対の像データを生成し、さらに、一対の像データについて、検波フィルタを用いてフィルタ処理する際に、検波周波数帯域が最も高い検波フィルタである第1フィルタf1以外の検波フィルタ、すなわち、第2〜第5フィルタf2〜f5を用いる(上述したステップS1、S2参照)。そして、本実施形態によれば、位相差検出方式によるデフォーカス量の検出処理を行う際には、図3に示す複数の焦点検出画素222a,222bの画素データのうち、一部が間引かれた画素データを用いるため、位相差検出方式によるデフォーカス量の検出処理に要する演算負荷を低減することができ、さらには、検波周波数帯域が最も高い検波フィルタである第1フィルタf1を用いないことにより、ノイズ成分などの高周波数成分が誤検出されてしまうことを有効に防止することができる。特に、空間周波数が比較的低い低周波被写体を検出する際には、焦点検出画素222a,222bの画素データのうち、一部を間引いた画素データを用いた場合でも、良好に検出できるため、一部を間引いた画素データを用いた場合でも、高精度に焦点状態の検出を行うことができる。   In the present embodiment, when performing the defocus amount detection process by the phase difference detection method, pixel data partially thinned out of the pixel data of the plurality of focus detection pixels 222a and 222b shown in FIG. To generate a pair of image data, and when filtering the pair of image data using a detection filter, a detection filter other than the first filter f1, which is a detection filter having the highest detection frequency band, that is, The second to fifth filters f2 to f5 are used (see steps S1 and S2 described above). According to the present embodiment, when performing the defocus amount detection process by the phase difference detection method, a part of the pixel data of the plurality of focus detection pixels 222a and 222b shown in FIG. 3 is thinned out. Therefore, the calculation load required for the defocus amount detection processing by the phase difference detection method can be reduced, and further, the first filter f1 that is the detection filter having the highest detection frequency band is not used. Accordingly, it is possible to effectively prevent a high frequency component such as a noise component from being erroneously detected. In particular, when detecting a low-frequency subject having a relatively low spatial frequency, even if pixel data obtained by thinning out a part of the pixel data of the focus detection pixels 222a and 222b can be detected satisfactorily, Even when pixel data with thinned portions is used, the focus state can be detected with high accuracy.

加えて、本実施形態においては、第1フィルタf1以外の検波フィルタを用いて、位相差検出方式によるデフォーカス量の検出処理を行った際に、光学系の焦点状態が、第1合焦範囲Dα内であり、かつ、検波フィルタとして、第2フィルタf2を使用して行われた場合(上述したステップS6,S7参照)には、デフォーカス量の検出の対象となる主要被写体が、空間周波数が高い高周波被写体である可能性が高いため、焦点検出画素222a,222bの画素データとして、間引かれていない全ての画素データを用いるとともに、検波フィルタとして、検波周波数帯域が最も高い検波フィルタである第1フィルタf1を用いて、位相差検出方式によるデフォーカス量の検出処理を行う(上述したステップS8,S9参照)。そして、本実施形態によれば、焦点検出画素222a,222bの画素データとして、間引かれていない全ての画素データを用いることで、空間周波数が比較的高い高周波被写体に対応する対の像データを適切に取得することができ、しかも、高周波被写体に適した検波フィルタを用いてフィルタ処理を行うため、高周波被写体についても、良好に検出でき、この場合でも、高精度に焦点状態の検出を行うことができる。 In addition, in the present embodiment, when the detection process other than the first filter f1 is used to detect the defocus amount by the phase difference detection method, the focus state of the optical system is the first focus range. When the second filter f2 is used as a detection filter within D α (see Steps S6 and S7 described above), the main subject for which the defocus amount is to be detected is the space. Since there is a high possibility that the subject is a high-frequency subject having a high frequency, all the pixel data not thinned out are used as the pixel data of the focus detection pixels 222a and 222b, and the detection filter having the highest detection frequency band is used as the detection filter. A defocus amount detection process is performed by a phase difference detection method using a certain first filter f1 (see steps S8 and S9 described above). According to the present embodiment, by using all pixel data that has not been thinned out as pixel data of the focus detection pixels 222a and 222b, a pair of image data corresponding to a high-frequency subject having a relatively high spatial frequency is obtained. High-frequency subjects can be detected satisfactorily because the filter processing is performed using a detection filter suitable for high-frequency subjects, and even in this case, the focus state can be detected with high accuracy. Can do.

なお、以上説明した実施形態は、本発明の理解を容易にするために記載されたものであって、本発明を限定するために記載されたものではない。したがって、上記の実施形態に開示された各要素は、本発明の技術的範囲に属する全ての設計変更や均等物をも含む趣旨である。   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.

たとえば、上述した実施形態においては、第1フィルタf1以外の検波フィルタを用いて、位相差検出方式によるデフォーカス量の検出処理を行う際に、焦点検出画素222a,222bについて、2個おきに画素データの間引きを行い、2個おきに間引かれた画素データを用いる例を示したが(上述のステップS1参照)、たとえば、4個おきに画素データの間引きを行い、4個おきに間引かれた画素データを用いるような態様としてもよい。さらに、このような場合においては、第1フィルタf1を用いて、位相差検出方式によるデフォーカス量の検出処理を行う際において、焦点検出画素222a,222bについて、画素データの間引きを行わずに、間引かれていない画素データを用いる例を示したが(上述のステップS8参照)、たとえば、2個おきに画素データの間引きを行い、2個おきに間引かれた画素データを用いるような態様とすることができる。
なお、この場合において、カメラ制御部21により、全ての画素の画素データを取得して、カメラ制御部21により、一部の画素の画素データのみを間引くような構成とする場合においても、同様に、間引き数を変更するような構成とすることができる。
For example, in the above-described embodiment, when the detection process other than the first filter f1 is used to detect the defocus amount by the phase difference detection method, every two focus detection pixels 222a and 222b are detected. Although an example has been shown in which pixel data is thinned out and pixel data thinned out every second number is used (see step S1 above), for example, pixel data is thinned out every fourth piece and thinned out every fourth piece. It is also possible to use such pixel data. Further, in such a case, when performing the defocus amount detection process by the phase difference detection method using the first filter f1, the pixel data is not thinned out for the focus detection pixels 222a and 222b. Although an example using pixel data that has not been thinned out has been shown (see step S8 above), for example, every second pixel data is thinned, and every second thinned pixel data is used. It can be.
In this case, the same applies to the case where the camera control unit 21 acquires the pixel data of all the pixels and the camera control unit 21 thins out only some of the pixel data. The thinning number can be changed.

また、上述した実施形態においては、第1フィルタf1以外の検波フィルタを用いて、位相差検出方式によるデフォーカス量の検出処理を行う際に、焦点検出画素222a,222bについて、画素データの間引きを行う例を示したが(上述のステップS1参照)、画素データの間引きに代えて、画素データを加算する処理を行うことで、画素データを圧縮するような態様としてもよい。そして、この場合においては、第1フィルタf1を用いて、位相差検出方式によるデフォーカス量の検出処理においては、加算する処理が行われていない画素データを用いてもよいし、あるいは、第1フィルタf1以外の検波フィルタを用いて、位相差検出方式によるデフォーカス量の検出を行う場合と比較して、加算度合いの低い(圧縮度合いの低い)態様で加算する処理がされた画素データを用いるような態様とすることができる。
なお、この場合においても、カメラ制御部21は、図3に示す複数の撮像画素221の画素データおよび複数の焦点検出画素222a,222bの全ての画素の画素データをカメラ制御部21に送信するように指令し、カメラ制御部21は、全ての画素の画素データを取得して、カメラ制御部21により、画素データを加算する処理するような態様とすることができる。
In the above-described embodiment, pixel data is thinned out for the focus detection pixels 222a and 222b when the detection filter other than the first filter f1 is used to perform the defocus amount detection process by the phase difference detection method. Although an example of performing is shown (see step S1 above), the pixel data may be compressed by performing a process of adding the pixel data instead of thinning out the pixel data. In this case, in the defocus amount detection processing by the phase difference detection method using the first filter f1, pixel data that has not been subjected to addition processing may be used, or the first filter f1 may be used. Compared with the case where the detection filter other than the filter f1 is used to detect the defocus amount by the phase difference detection method, the pixel data subjected to the addition processing in a mode in which the addition degree is low (compression degree is low) is used. It can be set as such an aspect.
Even in this case, the camera control unit 21 transmits the pixel data of the plurality of imaging pixels 221 and the pixel data of all the pixels of the plurality of focus detection pixels 222a and 222b illustrated in FIG. 3 to the camera control unit 21. The camera control unit 21 can acquire the pixel data of all the pixels, and the camera control unit 21 can add the pixel data.

さらに、上述した実施形態では、第1フィルタf1以外の検波フィルタを用いて、位相差検出方式によるデフォーカス量の検出処理を行う際に、焦点検出画素222a,222bの画素データから一対の像に対応した一対の像データ(一対の像の強度分布に関するデータ)を生成し、生成した像データに適した検波フィルタを、第2〜第5フィルタf2〜f5のうちから選択し、選択した検波フィルタのみを用いて、一対の像データについてフィルタ処理を行うような態様を例示したが、たとえば、次のような態様としてもよい。すなわち、たとえば、生成した像データについて、第2〜第5フィルタf2〜f5のそれぞれを用いてフィルタ処理を行い、フィルタ処理後データを4個算出し、算出した4個のフィルタ処理後データに対して、像ズレ検出演算処理(相関演算処理)を施すことで、4個のデフォーカス量を算出する。そして、相関演算処理における演算結果等から、第2〜第5フィルタf2〜f5から、対応する被写体に適した検波周波数帯域を有する検波フィルタを選択し、選択された検波フィルタを用いて得られたデフォーカス量を、最終的なデフォーカス量として決定するような態様としてもよい。   Further, in the above-described embodiment, when performing detection processing of the defocus amount by the phase difference detection method using the detection filter other than the first filter f1, the pixel data of the focus detection pixels 222a and 222b is converted into a pair of images. A corresponding pair of image data (data relating to the intensity distribution of the pair of images) is generated, a detection filter suitable for the generated image data is selected from the second to fifth filters f2 to f5, and the selected detection filter is selected. Although an example in which filter processing is performed on a pair of image data using only the image data is illustrated, for example, the following aspect may be adopted. That is, for example, the generated image data is filtered using each of the second to fifth filters f2 to f5, four pieces of filtered data are calculated, and the calculated four pieces of filtered data are calculated. Then, four defocus amounts are calculated by performing image shift detection calculation processing (correlation calculation processing). Then, a detection filter having a detection frequency band suitable for the corresponding subject is selected from the second to fifth filters f2 to f5 based on the calculation result in the correlation calculation processing, and the detection filter is used. The defocus amount may be determined as the final defocus amount.

また、上述した実施形態では、カメラ制御部21に、第1〜第5フィルタf1〜f5を記憶しているような態様とし、これらの検波フィルタを用いて、相差検出方式によるデフォーカス量の検出処理を行うような態様としたが、第1〜第5フィルタf1〜f5に加えて、検波周波数帯域が第1フィルタf1よりも低く、第2フィルタf2よりも高い第6フィルタf6をさらに備えるような構成としてもよい。そして、この場合には、まず、第1フィルタf1、第6フィルタf6を除いた検波フィルタ、すなわち、第2〜第5フィルタf2〜f5を用いて、相差検出方式によるデフォーカス量の検出処理を行い、光学系の焦点状態が、第1合焦範囲Dα内であり、かつ、検波フィルタとして、第2フィルタf2を使用して行われた場合には、第1フィルタf1および第6フィルタf6のうちいずれかを用いて、相差検出方式によるデフォーカス量の検出処理を行うような態様としてもよい。なお、この場合において、第1フィルタf1および第6フィルタf6のうちいずれかを用いて、相差検出方式によるデフォーカス量の検出処理を行う際には、第2〜第5フィルタf2〜f5を用いる場合と同様に、第1フィルタf1および第6フィルタf6のうち、生成した一対の像データに適した検波フィルタを選択して用いるような態様とすればよい。 In the embodiment described above, the camera control unit 21 stores the first to fifth filters f1 to f5, and these detection filters are used to detect the defocus amount by the phase difference detection method. In this embodiment, in addition to the first to fifth filters f1 to f5, a sixth filter f6 having a detection frequency band lower than the first filter f1 and higher than the second filter f2 is further provided. It is good also as a simple structure. In this case, first, detection processing of the defocus amount by the phase difference detection method is performed using the detection filters excluding the first filter f1 and the sixth filter f6, that is, the second to fifth filters f2 to f5. performed, the focus state of the optical system is a first in-focus range D alpha, and, as a detection filter, when made using the second filter f2, the first filter f1 and the sixth filter f6 Any one of them may be used to perform a defocus amount detection process using a phase difference detection method. In this case, the second to fifth filters f2 to f5 are used when performing the defocus amount detection process by the phase difference detection method using either the first filter f1 or the sixth filter f6. Similarly to the case, a mode in which a detection filter suitable for the generated pair of image data is selected from the first filter f1 and the sixth filter f6 may be used.

1…デジタルカメラ
2…カメラ本体
21…カメラ制御部
22…撮像素子
221…撮像画素
222a,222b…焦点検出画素
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 3 ... Lens barrel 32 ... Focus lens 36 ... Focus lens drive motor 37 ... Lens control part

Claims (4)

光学系による像を撮像し、撮像した像に対応する画像信号を生成し、生成した画像信号を出力する撮像部と、
所定の第1圧縮度で圧縮した画像信号、前記第1圧縮度よりも圧縮度合いの低い第2圧縮度で圧縮した画像信号、または圧縮がされていない画像信号の生成をするように前記撮像部を制御する撮像制御部と、
前記撮像部により出力された画像信号に基づいて、位相差を用いて、前記光学系による像面のずれ量を検出することで、前記光学系の焦点状態を検出する焦点検出部と、
前記光学系の焦点状態が、合焦位置近傍にあるか否かを判断する判断部と、
検出可能な周波数帯域が所定周波数帯域の第1フィルタと、検出可能な周波数帯域が前記第1フィルタよりも低い周波数である第2フィルタと、検出可能な周波数帯域が前記第2フィルタよりも低い周波数である第3フィルタとを有するフィルタ部とを備え、
前記焦点検出部は、前記第1圧縮度で圧縮された画像信号から前記光学系による像面のずれ量に対応する像ずれ信号を取得し、前記複数のフィルタのうち、前記第1フィルタを除く複数のフィルタのなかから、前記取得した像ずれ信号に適した周波数帯域を検出可能なフィルタを選択して、選択したフィルタによりフィルタ処理された像ずれ信号に基づいて、前記ずれ量を検出し、
前記判断部により、前記光学系の焦点状態が前記合焦位置近傍にあると判断され、かつ、前記焦点検出部によって前記ずれ量を検出した際に用いられたフィルタが、前記第2フィルタであった場合には、前記第2圧縮度で圧縮された画像信号、または圧縮がされていない画像信号から前記光学系による像面のずれ量に対応する像ずれ信号を取得し、前記フィルタ部の前記複数のフィルタのうち、前記第1フィルタを選択して、前記第1フィルタによりフィルタ処理された像ずれ信号に基づいて、前記ずれ量を検出することを特徴とする焦点検出装置。
An imaging unit that captures an image by the optical system, generates an image signal corresponding to the captured image, and outputs the generated image signal;
The imaging unit is configured to generate an image signal compressed at a predetermined first compression degree, an image signal compressed at a second compression degree lower than the first compression degree, or an uncompressed image signal. An imaging control unit for controlling
A focus detection unit that detects a focus state of the optical system by detecting a shift amount of an image plane by the optical system using a phase difference based on an image signal output by the imaging unit;
A determination unit that determines whether or not a focus state of the optical system is in the vicinity of a focus position;
A first filter whose detectable frequency band is a predetermined frequency band, a second filter whose detectable frequency band is lower than the first filter, and a frequency whose detectable frequency band is lower than the second filter A filter unit having a third filter which is
The focus detection unit acquires an image shift signal corresponding to an image plane shift amount by the optical system from an image signal compressed at the first compression degree, and removes the first filter from the plurality of filters. Select a filter capable of detecting a frequency band suitable for the acquired image shift signal from a plurality of filters, detect the shift amount based on the image shift signal filtered by the selected filter,
The filter used when the determination unit determines that the focus state of the optical system is in the vicinity of the in-focus position and the shift amount is detected by the focus detection unit is the second filter. In this case, an image shift signal corresponding to an image plane shift amount by the optical system is acquired from an image signal compressed at the second compression degree or an image signal not compressed, and the filter unit A focus detection apparatus, wherein the first filter is selected from among a plurality of filters, and the shift amount is detected based on an image shift signal filtered by the first filter.
請求項1に記載の焦点検出装置において、
合焦状態であるか否かを判定する合焦判定部をさらに有し、
前記合焦判定部は、一度、前記焦点検出部により、前記ずれ量の検出が前記第1フィルタを用いて行われた後、再度、前記焦点検出部により、前記ずれ量の検出が前記第1フィルタを用いて行われるまで、合焦判定を行わないことを特徴とする焦点検出装置。
The focus detection apparatus according to claim 1,
It further has a focus determination unit that determines whether or not it is in focus,
The focus determination unit is configured to detect the shift amount by the focus detection unit again after the detection of the shift amount is performed by the focus detection unit using the first filter. A focus detection apparatus that does not perform focus determination until it is performed using a filter.
請求項1または2に記載の焦点検出装置において、
前記撮像制御部は、前記撮像部に備えられた光電変換素子の出力を加算する処理、または前記光電変換素子の出力を間引く処理により、前記撮像部に、圧縮された画像信号の生成を行わせることを特徴とする焦点検出装置。
The focus detection apparatus according to claim 1 or 2,
The imaging control unit causes the imaging unit to generate a compressed image signal by a process of adding the outputs of the photoelectric conversion elements provided in the imaging unit or a process of thinning out the outputs of the photoelectric conversion elements. A focus detection apparatus.
請求項1〜3のいずれかに記載の焦点検出装置を備えた撮像装置。   The imaging device provided with the focus detection apparatus in any one of Claims 1-3.
JP2012223199A 2012-10-05 2012-10-05 Focus detection device and image capturing device Pending JP2014074851A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2012223199A JP2014074851A (en) 2012-10-05 2012-10-05 Focus detection device and image capturing device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012223199A JP2014074851A (en) 2012-10-05 2012-10-05 Focus detection device and image capturing device

Publications (1)

Publication Number Publication Date
JP2014074851A true JP2014074851A (en) 2014-04-24

Family

ID=50749024

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012223199A Pending JP2014074851A (en) 2012-10-05 2012-10-05 Focus detection device and image capturing device

Country Status (1)

Country Link
JP (1) JP2014074851A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016080161A1 (en) * 2014-11-18 2016-05-26 富士フイルム株式会社 Focus control device, focus control method, focus control program, lens device, and imaging device
JP2016224159A (en) * 2015-05-28 2016-12-28 株式会社ニコン Focus detection device and imaging device
US12047680B2 (en) 2020-11-18 2024-07-23 Canon Kabushiki Kaisha Image pickup apparatus

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016080161A1 (en) * 2014-11-18 2016-05-26 富士フイルム株式会社 Focus control device, focus control method, focus control program, lens device, and imaging device
CN107003500A (en) * 2014-11-18 2017-08-01 富士胶片株式会社 Focusing control apparatus, focusing control method, focusing control program, lens assembly, camera device
JPWO2016080161A1 (en) * 2014-11-18 2017-08-31 富士フイルム株式会社 Focus control device, focus control method, focus control program, lens device, imaging device
US10001621B2 (en) 2014-11-18 2018-06-19 Fujifilm Corporation Focusing control device, focusing control method, focusing control program, lens device, and imaging device
CN107003500B (en) * 2014-11-18 2019-11-12 富士胶片株式会社 Focus control device, focus control method, lens device, camera device
JP2016224159A (en) * 2015-05-28 2016-12-28 株式会社ニコン Focus detection device and imaging device
US12047680B2 (en) 2020-11-18 2024-07-23 Canon Kabushiki Kaisha Image pickup apparatus

Similar Documents

Publication Publication Date Title
JP2013025144A (en) Focus adjustment device and imaging apparatus
JP2019091090A (en) Detector, imaging element, and imaging device
JP6642628B2 (en) Imaging device and imaging device
JP2013050690A (en) Focus adjusting device and imaging apparatus
JP5831070B2 (en) Imaging device
JP5966267B2 (en) Focus adjustment device and imaging device
JP5845660B2 (en) Focus detection apparatus and imaging apparatus
JP2014074851A (en) Focus detection device and image capturing device
JP2013003486A (en) Focus detector and imaging apparatus
JP6047861B2 (en) Focus adjustment device and camera body
JP6399140B2 (en) Imaging device
JP2014211589A (en) Focus adjustment device and imaging device
JP6127730B2 (en) Imaging device
JP2014074850A (en) Focus adjustment device, focus detection device, and image capturing device
JP2012226247A (en) Focus detector and imaging apparatus
JP2012255919A (en) Focus adjustment device and imaging apparatus
JP5923900B2 (en) Focus detection apparatus and imaging apparatus
JP2013054326A (en) Focus detector and imaging apparatus
JP6035777B2 (en) Imaging device
JP2019095810A (en) Focus adjustment device and imaging device
JP5423734B2 (en) Lens barrel and imaging device
JP2013054261A (en) Focus detector and imaging device
JP6442824B2 (en) Focus detection device
JP2015049473A (en) Focus adjustment device and imaging device
JP2024040227A (en) Focus detection device and image sensor